Show all list subscribers

Returns all subscribers in the requested list.

GET https://go.smartrmail.com/api/v1/lists/:list_id/list_subscribers

Parameters

:list_id The ID of the requested list.

Expected response

HTTP/1.1 200 OK
Content-Type: application/json; charset=utf-8

[
  {
    "id": "asdf",
    "email": "vanhalen@example.com",
    "first_name": "van",
    "last_name": "halen",
    "status": "Subscribed",
    "unsubscribed_at": null,
    "complained": false,
    "delivered_count": 100,
    "opened_count": 100,
    "clicked_count": 100,
    "joined_at": "2013-03-11 01:00:00 UTC",
    "subscribed": true,
  },
  {
    "id": "zxcv",
    "email": "foo@bar.com",
    "first_name": "foo",
    "last_name": "bar",
    "status": "Subscribed",
    "unsubscribed_at": null,
    "complained": false,
    "delivered_count": 100,
    "opened_count": 100,
    "clicked_count": 100,
    "joined_at": "2015-03-11 01:00:00 UTC",
    "subscribed": true,
  }
]

Create list of subscribers

Creates many subscribers and adds them to the requested list. Existing subscribers will not be updated.

POST https://go.smartrmail.com/api/v1/lists/:list_id/list_subscribers

Parameters

:list_id The ID of the requested list.

Expected request for one subscriber

Accept: application/json
Authorization: token YOUR_API_TOKEN
Content-Type: application/json

{
  subscribers:
  [
    {
      "email": "vanhalen@example.com",
      "first_name": "van",
      "last_name": "halen",
      "subscribed": true
    }
  ]
}

Expected request for many subscribers

Accept: application/json
Authorization: token YOUR_API_TOKEN
Content-Type: application/json

{
  subscribers:
    [
      {
        "email": "vanhalen@example.com",
        "first_name": "van",
        "last_name": "halen",
        "subscribed": true
      },
      {
        "email": "foo@example.com",
        "first_name": "foo",
        "last_name": "bar",
        "subscribed": true
      }
    ]
}

Expected response

HTTP/1.1 200 Ok
Content-Type: application/json; charset=utf-8

[
  {
    "id": "asdf",
    "email": "vanhalen@example.com",
    "first_name": "van",
    "last_name": "halen",
    "status": "Subscribed",
    "unsubscribed_at": null,
    "complained": false,
    "delivered_count": 100,
    "opened_count": 100,
    "clicked_count": 100,
    "joined_at": "2013-03-11 01:00:00 UTC",
    "subscribed": true,
  },
  {
    "id": "zxcv",
    "email": "foo@bar.com",
    "first_name": "foo",
    "last_name": "bar",
    "status": "Subscribed",
    "unsubscribed_at": null,
    "complained": false,
    "delivered_count": 100,
    "opened_count": 100,
    "clicked_count": 100,
    "joined_at": "2015-03-11 01:00:00 UTC",
    "subscribed": true,
  }
]

Expected response with failure

HTTP/1.1 422 Unprocessable entity
Content-Type: application/json; charset=utf-8

Delete a list subscriber

Remove the requested subscriber from the list.

DELETE https://go.smartrmail.com/api/v1/lists/:list_id/subscribers/:subscriber_email

Parameters

:list_id The ID of the requested list.

:subscriber_email The email address of the requested list subscriber.

Expected response

HTTP/1.1 200 OK
Did this answer your question?