Get an attachment thumbnail by its preview ID
GET
/openapi/bytefiles/{id}
const url = 'https://open-api.replyco.com/openapi/bytefiles/2489E9AD-2EE2-8E00-8EC9-32D5F69181C0';const options = {method: 'GET', headers: {Authorization: 'Bearer <token>'}};
try { const response = await fetch(url, options); const data = await response.json(); console.log(data);} catch (error) { console.error(error);}curl --request GET \ --url https://open-api.replyco.com/openapi/bytefiles/2489E9AD-2EE2-8E00-8EC9-32D5F69181C0 \ --header 'Authorization: Bearer <token>'Returns the thumbnail of an attachment, not the original file. The thumbnail is a small 180x120 image, cropped to fit, generated when the attachment was received. It is returned base64-encoded in the ‘base64’ field.
Use the ‘previewId’ of a message attachment as the ID. Attachments hosted by eBay have no thumbnail.
To download the original, full-resolution file, use GET /openApi/byteFiles/messageAttachments/{messageId}/links.
Authorizations
Section titled “Authorizations”Parameters
Section titled “Parameters”Path Parameters
Section titled “Path Parameters”id
required
string format: uuid
The ‘previewId’ of the attachment
Responses
Section titled “Responses”Returns the thumbnail
Media typeapplication/json
object
id
string format: uuid
base64
Base64-encoded 180x120 cropped thumbnail of the attachment. It is not the original file
string
Example generated
{ "id": "2489E9AD-2EE2-8E00-8EC9-32D5F69181C0", "base64": "example"}No thumbnail exists with the specified ID
User is not authenticated or authorized