Sample requests
These sample requests are autogenerated by the OpenAPI spec.
import requests
url = "https://api.buttondown.com/v1/bulk_actions"
payload = {
"type": "delete_emails",
"metadata": { "ids": ["611c8825-6f21-4544-bb47-9f50453e9cb0", "418c701a-efe3-4e3d-a404-e635a2f28775"] }
}
headers = {
"accept": "application/json",
"authorization": "Token $BUTTONDOWN_API_KEY",
"content-type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text)
Sample responses
The IDs and values referenced in these responses are fake; please only rely on these responses for overall structure.
{
"creation_date": "2019-08-24T14:15:22Z",
"completion_date": "2019-08-24T14:17:22Z",
"id": "497f6eca-6276-4993-bfeb-53cbbbba6f08",
"status": "completed",
"type": "delete_subscribers",
"metadata": {
"ids": [
"497f6eca-6276-4993-bfeb-53cbbbba6f08"
]
}
}
Body parameters
All parameters are optional unless explicitly specified.
Type
object · required
Example
{
"ids": [
"611c8825-6f21-4544-bb47-9f50453e9cb0",
"418c701a-efe3-4e3d-a404-e635a2f28775"
]
}