Skip to end of banner
Go to start of banner

GET v2/EviSMS/Batches/{batchid}

Skip to end of metadata
Go to start of metadata

You are viewing an old version of this content. View the current version.

Compare with Current View Version History

Version 1 Current »

HTTP Method: GET

Description:

This endpoint retrieves the details of a bulk email batch previously created in the system. The batchid parameter in the URL is the unique identifier returned by the initial batch creation (Submit) endpoint. Additional query parameters allow customization of the level of detail in the response.

Output Parameters

  • Id (Guid): Unique identifier for the batch.

  • Submitter (text): User who generates the batch.

  • SubmitterId (Guid): Identifier of the user who generates the batch.

  • SiteName (text): Name of the site associated with the batch.

  • SiteId (Guid): Site identifier associated with the batch.

  • State (string): The current state of the bulk email (e.g., Draft, Scheduled, Sent).

  • CreationDate (datetime): The creation date of the batch in UTC.

  • LastUpdate (datetime): The last update time of the batch in UTC.

  • Description (string): Description of the bulk email batch.

  • SentCount (int): Counter of the shipments made so far.

  • FailedCount (int): Counter of failed shipments so far.

  • ProgessPercentage (int): Percentage of progress to date.

  • Outcome (text): Final result of the shipment process.

  • TotalCount (int?, optional): The total number of recipients (if IncludeRecipientsCount is true).

  • Options (object, optional, if IncludeOptions is true): Configuration details for the batch, including:

    • IssuerName (string): The sender's name.

    • CostCentre (string)

    • CertificationLevel (string)

    • LtaStorage (bool)

    • AffidavidKind (array)

    • Language (string)

    • AffidavitLanguage (string)

    • OnlineRetentionPeriod (int)

    • PushNotificationUrl (string)

    • PushNotificationFilter (array)

    • PushNotificationExtraData (string)

    • HideBanners (bool)

    • BatchPushNotificationUrl (string)

Request Example

Basic Request:

Content-Type: application/json
Authorization: Bearer YOUR_ACCESS_TOKEN

GET /v2/EviSMS/Batches/{batchid}

Request with Query Parameters:

Content-Type: application/json
Authorization: Bearer YOUR_ACCESS_TOKEN

GET /v2/EviSMS/Batches/{batchid}?IncludeOptions=true&IncludeRecipientsCount=true&IncludeAttachments=true

Response Example

Response with All Details:

{
    "Body": "Dear {{FirstName}}, we are excited to have you onboard!",
    "Subject": "Welcome {{FirstName}}!",
    "ScheduledFor": "2024-11-15T10:00:00Z",
    "State": "Scheduled",
    "CreationDate": "2024-11-10T15:30:00Z",
    "Description": "Welcome campaign batch",
    "BatchId": "a5b1f3f2-5c73-4b6d-88b9-73d81a9c5f8e",
    "IssuerName": "Marketing Team",
    "RecipientsCount": 150,
    "Attachments": [
        {
            "DisplayName": "User Guide",
            "Data": "JVBERi0xLjQKJcfs...Base64EncodedContent...",
            "FileName": "user_guide.pdf"
        }
    ],
    "Options": {
        "CostCentre": "Marketing",
        "CertificationLevel": "Basic",
        "LtaStorage": true,
        "Language": "en",
        "AffidavitLanguage": "en",
        "OnlineRetentionPeriod": 5,
        "PushNotificationUrl": "https://client.callback.url/notifications",
        "PushNotificationFilter": ["StatusChange", "DeliveryConfirmation"],
        "CommitmentOptions": "AcceptOrReject",
        "CommitmentCommentsAllowed": true,
        "RejectReasons": ["Content not relevant", "Incorrect recipient"],
        "AcceptReasons": ["Confirmed interest", "Interested in details"],
        "RequireRejectReasons": false,
        "RequireAcceptReasons": false,
        "HideBanners": true
    }
}

Notes

  • Flexible Detail Levels:

    • Use query parameters (IncludeOptions, IncludeRecipientsCount, IncludeAttachments) to control the detail level in the response.

    • By default, all optional properties (Options, RecipientsCount, Attachments) are excluded.

  • Batch ID:

    • The batchid in the URL must correspond to an existing batch created in the system.

  • Efficient Retrieval:

    • Avoid setting unnecessary query parameters to reduce response size and improve performance.

  • No labels