« Back to Documentation Overview

get_newsletter_statuses

Section: Messages
Version: 1.5.0


Get statuses of newsletter messages.
Conditions:

    Conditions:
  • campaigns / get_campaigns (optional) – Count only in given campaigns. Uses OR logic. If those params are not given count, is performed in all campaigns in the account. Check IDs in conditions for detailed explanation
  • send_on (optional) – Use time operators to narrow down count results to specific sending date. Multiple operators are allowed and logic AND is used so date range can also be expressed. Works only for newsletters because other message types do not have fixed sending point in time. If message was sent with Time Travel then it may appear in search results for two different days as sending period equals 24 hours.
  • created_on (optional) – Use time operators to narrow down count results to specific message creation date. Multiple operators are allowed and logic AND is used so date range can also be expressed.


Parameters
stringAPI_KEY
object
arraycampaigns
stringCAMPAIGN_ID
stringCAMPAIGN_ID
objectget_campaigns
objectname
stringCONTAINSmy_campaign_%
objectsend_on
stringOPERATORvalue
objectcreated_on
stringOPERATORvalue
Return Value
arrayscheduled
stringMESSAGE_ID
stringMESSAGE_ID
stringMESSAGE_ID
arrayin_progress
stringMESSAGE_ID
arraydelivered
stringMESSAGE_ID
stringMESSAGE_ID
stringMESSAGE_ID
stringMESSAGE_ID

Example Request JSON

[
    "API_KEY",
    {
        "campaigns": [
            "CAMPAIGN_ID",
            "CAMPAIGN_ID"
        ],
        "get_campaigns": {
            "name": {
                "CONTAINS": "my_campaign_%"
            }
        },
        "send_on": {
            "OPERATOR": "value"
        },
        "created_on": {
            "OPERATOR": "value"
        }
    }
]

Example Response JSON

{
    "scheduled": [
        "MESSAGE_ID",
        "MESSAGE_ID",
        "MESSAGE_ID"
    ],
    "in_progress": [
        "MESSAGE_ID"
    ],
    "delivered": [
        "MESSAGE_ID",
        "MESSAGE_ID",
        "MESSAGE_ID",
        "MESSAGE_ID"
    ]
}
API-wide Errors
API key verification failed API key verification failed
API client IP not allowed API client IP not allowed
Invalid params Attribute params must be reference to hash