Subscription lists


Fetch subscription lists

Return json data about subscription lists

URL

/subscription_lists

Method

GET

Success response

Code:200
Content:

{
"data": [
{
"id": "string",
"type": "subscription_list",
"attributes": {
"name": "string",
"is_default": "bool",
"subscriber_count": "number",
"form_id": "string" // for use with Paubox Secure Forms
}
}
]
}

Create subscription list

Creates a subscription list record

URL

/subscription_lists

Method

POST

Data parameters

{
"subscription_list": {
"name": "string" // can't be == 'default'
}
}

Success response

Code: 200
Content:

{
"data": {
"id": "string",
"type": "subscription_list",
"attributes": {
"name": "string",
"is_default": false,
"subscriber_count": 0
}
}
}

Update subscription list

Updates a subscription list record

URL

/subscription_lists/:subscription_list_id

Method

PATCH | PUT

Data parameters

{
"subscription_list": {
"name": "string"
}
}

Success response

Code: 200
Content:

{
"data": {
"id": "string",
"type": "subscription_list",
"attributes": {
"name": "string",
"is_default": false,
"subscriber_count": "number"
}
}
}

Delete subscription list

Deletes subscription list record

Can not delete default/all contacts list

URL

/subscription_lists/:subscription_list_id

Method

DELETE

Success response

Code: 200
Content:

{}