Add transformations to embed and download links
You can add transformations to your embed and download links, just like you can in the Orange Logic interface.
For example, let’s say you want to create a link to an image with the following transformations:
- Resize the asset to 500 px by 500 px, ignoring the aspect ratio.
- Rotate the asset 90 degrees.
To create a link to the transformation of a single image, use this call:
curl -X 'GET' \
'https://mangovations.com/webapi/objectmanagement/share/getlink_4HZ_v1?Identifier=ZZ111PI&Format=TR1&StickToCurrentVersion=true&LogViews=true&CreateDownloadLink=true&ExpirationDate=2024-12-31T23%3A59%3A59&FileExtension=.jpg&ImageResizingMethod=Stretch&Transformations=re_w_500%2Cre_h_500%2Cr_a_90' \
-H 'accept: text/plain'
To create links to transformations of multiple images, use this call:
curl -X 'POST' \
'https://mangovations.com/webapi/objectmanagement/share/getlinks_45W_v1' \
-H 'accept: text/plain' \
-H 'Content-Type: application/json-patch+json' \
-d '{
"assets": [
{
"identifier": "ZZ13GMR",
"format": "TR1",
"stickToCurrentVersion": true,
"logViews": true,
"createDownloadLink": false,
"expirationDate": "2024-10-08T03:37:04.831Z",
"transformations": [
"re_w_500,re_h_500,re_rm_Stretch",
"r_a_90"
]
},
{
"identifier": "ZZ13F",
"format": "TR1",
"stickToCurrentVersion": true,
"logViews": true,
"createDownloadLink": false,
"expirationDate": "2024-10-08T03:37:04.831Z",
"transformations": [
"re_w_500,re_h_500,re_rm_Stretch",
"r_a_90"
]
}
],
"useSession": true
}'
Feature documentation
Orange Logic users with a Link account can go to the transformation syntax article to learn more.
