Images

Images are, well, images! Buttondown allows you to upload images to its secure S3 bucket and do with them what you will. This is sort of an odd duck of an API, to be sure, but if you want to be able to do things like draft and send emails completely on your iPad you need a surefire way of creating images.

The image object

An image looks like this:

{
"creation_date": "2019-08-24T14:15:22Z",
"id": "497f6eca-6276-4993-bfeb-53cbbbba6f08",
"image": "string"
}

fieldtypedescription
creation_datedatetime
iduuid
imagestring

Listing images

GET https://api.buttondown.email/v1/images

Parameters

parametertypedescriptionoptional
pagestringA page number within the paginated result set.

Responses

StatusDescriptionSample Response
200
{
"count": 1,
"next": "foo",
"previous": null,
"results": [
{
"creation_date": "2019-08-24T14:15:22Z",
"id": "497f6eca-6276-4993-bfeb-53cbbbba6f08",
"image": "string"
}
]
}

Uploading a new image

POST https://api.buttondown.email/v1/images

Parameters

parametertypedescriptionoptional
imagestring <binary>

Responses

StatusDescriptionSample Response
201
{
"creation_date": "2019-08-24T14:15:22Z",
"id": "497f6eca-6276-4993-bfeb-53cbbbba6f08",
"image": "string"
}

Deleting an image

DELETE https://api.buttondown.email/v1/images/<id>

Responses

StatusDescriptionSample Response
204
{}

Retrieving a specific image

GET https://api.buttondown.email/v1/images/<id>

Responses

StatusDescriptionSample Response
200
{
"creation_date": "2019-08-24T14:15:22Z",
"id": "497f6eca-6276-4993-bfeb-53cbbbba6f08",
"image": "string"
}