Files
This section of the documentation describes how to upload files you may want to include in your emails.
REQUIREMENT
The base URL for all API requests is https://platform.sendbound.com/api/v1REQUIREMENT
The API token MUST be included as a query parameter in all subsequent requests. The token value is assigned to the api_token parameter as a query parameter.File
Upload file(s) to customer's storage
POST /file/upload
api_token=NAim6P4gapLXU2ZUad7i46RAgtSnqTqRtFBX7BZpbyFTntUYZ8Dgtppf0byD
{
"files":[
{
"url":"https://images.pexels.com/photos/10176829/pexels-photo-10176829.jpeg",
"subdirectory":"."
}
]
}
curl --location --request POST 'https://platform.sendbound.com/api/v1/file/upload?api_token=NAim6P4gapLXU2ZUad7i46RAgtSnqTqRtFBX7BZpbyFTntUYZ8Dgtppf0byD' \
--header 'Content-Type: application/json' \
--data-raw '{
"files":[
{
"url":"https://images.pexels.com/photos/10176829/pexels-photo-10176829.jpeg",
"subdirectory":"."
}
]
}'
Query Parameters
api_token
Kindly reference here to obtain the API token.
Request Parameters
files
This references an arry of file objects.
Each file object is contains the url
to the location of the file and subdirectory
which is the path to save the file.