# Get single email campaign logs

You can return all delivery logs of the specific email campaign. These results can be filtered by conditions defined as request parameters.

Lookup Description Allowed values
status Status of the deliveires. Pending = 1
Success = 2
Failure = 3
Retried = 4
Webhook = 5
reason Type of the bounce.
Might be used if Webhook status has been chosen.
Softbounce = 1
Spambounce = 2

GET /email-campaign/:id/logs/

# Request

  • CURL
  • JavaScript
  • PHP
  • Python
curl -X GET -H "Authorization: Token <your_64_char_api_key>"
-H "Accept: */*; version=2"
"https://<your_app_subdomain>.user.com/api/public/email-campaign/:id/logs/"

# Response

{
  "count": 2,
  "next": null,
  "previous": null,
  "results": {
    "campaign_id": 34,
    "campaign_pk": 34,
    "campaign_name": "Test campaign",
    "logs": [
      {
        "id": 36,
        "delivery_task_id": null,
        "status": 2,
        "failure_reason": "",
        "sent_at": "2024-04-09T07:48:20.492926Z",
        "opened_at": "2024-04-16T12:15:12.496800Z",
        "clicked_at": null,
        "unsubscribed_at": null,
        "created_at": "2024-04-09T07:48:18.609826Z",
        "campaign": 34,
        "client_user": 23,
        "variation": 69,
        "rendered_email": null,
        "preview": "https://test7.user.com/emails/show/mvzurfh0stcp/EwDZ8zPV95vo4WK4WpGBN2el3Mj/36/",
        "subject": "dsmtp1",
        "user_id": 23,
        "user": "some1@test.email",
        "user_email": "some1@test.email",
        "sender": "some@smtp.com <some@smtp.com>",
        "recipient": null,
        "has_preview": false
      },
      {
        "id": 35,
        "delivery_task_id": null,
        "status": 2,
        "failure_reason": "",
        "sent_at": "2024-04-09T07:48:25.154269Z",
        "opened_at": "2024-04-17T13:40:04.575322Z",
        "clicked_at": null,
        "unsubscribed_at": null,
        "created_at": "2024-04-09T07:48:18.606098Z",
        "campaign": 34,
        "client_user": 17,
        "variation": 69,
        "rendered_email": null,
        "preview": "https://test7.user.com/emails/show/98zvzkprybyb/w4XArkNRDdL6oLMPGKqyzlJE82p/35/",
        "subject": "dsmtp1",
        "user_id": 17,
        "user": "some2@test.email",
        "user_email": "some2@test.email",
        "sender": "some@smtp.com <some@smtp.com>",
        "recipient": null,
        "has_preview": false
      }
    ]
  }
}