Download Email body content

We are looking for Rest API to DOwnload the email body and Attachment based on EachMessageID associated in a conversation. Please help.

Thanks,
Rajnish

Hi Ranjnish,

The endpoint you want to look at is /api/v2/conversations/emails/{conversationId}/messages/{messageId}. The API documentation can be found here.

Thanks,
John Carnell
Manager, Developer Engagement

Hello John,

Thanks for your Reply.
This return me, Email content as HTML body and Textbody along with Other email Details and Attachment collection.

We would need to download attachments one by one from Attachment collection URI.

Under Genesys Interaction View, We have option to download email as Outlook format. Do we have any specific API to replicate that.

Thanks,
Rajnish

Try this link for information: https://developer.genesys.cloud/api/rest/v2/conversations/#get-api-v2-conversations-emails--conversationId--messages--messageId-

You would want to parse the list of attachments to get the contentUri of each attachment, then use a GET request for each returned contentUri

Thanks,
Dan

First, you need to access: "/api/v2/conversations/" + conversationId + "/recordings/
As a result of this, you need to get the "EmailTranscript" class
Then get the "Attachments" subclass
In this class you will have the property "ContentPath"
The "ContentPath" contains the URL for you to download the Attachment.

If you can't, I can think of building something for you.

This topic was automatically closed 31 days after the last reply. New replies are no longer allowed.