Media Uploads
Media Upload Model
Attributes
Create a presigned URL for Media Upload experimental
This endpoint allows you to upload a media file to Centrapay. It returns a presigned URL that can be used to download the media file.
Attributes
-
accountId
string required -
mimeType
string required -
fileName
string required
curl -X POST \ https://service.centrapay.com/api/media-uploads \ -H 'content-type: application/json' \ -H 'x-api-key: <TOKEN>' \ -d '{ "accountId": "Jaim1Cu1Q55uooxSens6yk", "mimeType": "image/png", "fileName": "image.png"}'
{ "id": "DKTs3U38hdhfEqwF1JKoT2", "uploadUrl": "https://media-upload.centrapay.com/image.png?jhbdsfau67ewejshb=487hsdjhbdgs743"}
Get Media Upload Location experimental
This endpoint allows you to retrieve the upload location of a media file.
curl -X GET \ https://service.centrapay.com/api/media-uploads/DKTs3U38hdhfEqwF1JKoT2/location \ -H 'x-api-key: <TOKEN>'
{ "url": "https://media-upload.centrapay.com/image.png?jhbdsfau67ewejshb=487hsdjhbdgs743"}