Every user or customer account has its own storage folder in Sasta Mail platform. You can upload assets (images, video, other file types, etc.) to the customer or user's storage via API. These assets will be then added or attached to the user's email content.
Parameters
api_token
string
Your API token. You can find it in your API main page when logged in.
files
string
File url(s)
subdirectory
string
Custom subdirectory. Default: user root directory
$client = new Acelle\Client(
'https://app.sastamail.com/api/v1',
'*|api_token|*'
);
$client->file()->upload([
'files' => '[{"url":"http://app.sastamail.com/images/logo_big.svg","subdirectory":"path/to/file"},{"url":"http://app.sastamail.com/images/logo_big.svg","subdirectory":"path/to/file2"}]',
]);
[
{
"file": "http:\/\/app.sastamail.comm\/images\/logo_big.svg",
"status": 1,
"message": "File uploaded"
},
{
"file": "http:\/\/app.sastamail.com\/images\/logo_big.svg",
"status": 1,
"message": "File uploaded"
}
]