Is it possible to replicate Zendesk Ticket Comments via Genesys Cloud Digital Engagement APIs?

Is it possible to map the rich text and attachment metadata from legacy Zendesk ticket comments directly into Genesys Cloud digital engagement transcripts during our migration?

We are currently migrating a support queue from Zendesk to Genesys Cloud. In Zendesk, every ticket comment was a discrete object with its own timestamp, author, and optional attachments. We are trying to preserve this history in Genesys Cloud using the Digital Engagement API. However, the API seems to treat the entire conversation as a single stream of messages rather than distinct, importable comment blocks.

When we attempt to batch-import historical data, the system rejects the payload if we try to include multiple author objects within a single engagement creation request. The error response is quite specific:

“Invalid engagement structure: multiple author identifiers detected in a single message batch. Genesys Cloud engagements require a single participant context for initial creation.”

In Zendesk, we could easily query tickets and export comments as a flat CSV with fields like comment_id, body, author_email, and created_at. The expectation was that we could mirror this in Genesys Cloud by creating a historical engagement for each ticket and populating the message history.

The current workaround involves creating a single engagement per ticket and then manually appending messages, but this is incredibly slow and doesn’t seem to preserve the original created_at timestamps accurately. The messages appear to be timestamped with the current server time rather than the legacy Zendesk timestamp.

Is there a specific migration tool or API parameter we are missing to handle this many-to-one mapping of Zendesk comments to Genesys Cloud messages? We need to maintain the chronological integrity of the customer interaction history for compliance reporting. Any guidance on handling this structural difference between the two platforms would be appreciated.

{
 "type": "message",
 "from": {
 "id": "system_migration_bot"
 },
 "to": {
 "id": "{{conversationId}}"
 },
 "text": "<b>Legacy Zendesk Comment:</b> \n{{commentBody}}\n\n<b>Author:</b> {{authorName}}\n<b>Timestamp:</b> {{timestamp}}"
}

Direct mapping of Zendesk ticket comments into Genesys Cloud digital engagement transcripts requires careful handling of the message type and payload structure. The Genesys Cloud Digital Engagement API does not natively support importing historical chat messages as part of an active session. Instead, the approach involves reconstructing the conversation history within the transcript view using the POST /api/v2/conversations/messages endpoint.

Each Zendesk comment must be transformed into a Genesys Cloud message object. The from field should reflect the original author, while the text field contains the rich text content. Attachments need to be uploaded separately via the appropriate attachment upload endpoint, and their IDs referenced in the message payload.

For example, if a Zendesk comment includes an attachment, the process involves:

  1. Uploading the attachment to Genesys Cloud.
  2. Creating a message object with the attachment ID linked.
  3. Posting the message to the conversation.

This method ensures that the historical data is preserved and visible in the transcript. However, it is crucial to note that these messages will not trigger real-time notifications or updates in the agent interface. They serve as static historical records within the conversation thread.

The error message you are receiving - “Invalid engagement structure: multiple author identifiers detected in a single message batch. Genesys Cloud engagements require a single participant context for initial creation” - confirms that attempting to create an entire engagement with multiple authors is not supported. The platform expects a single initiating participant for each engagement.

The workaround of creating an engagement per ticket and then appending messages via the API is a viable solution, though it can be resource intensive for large datasets. Consider optimizing this process by batching the requests to reduce the number of API calls.

Another optimization is to use the Genesys Cloud Data Action framework. You could create a custom Data Action that transforms the Zendesk data into the required Genesys Cloud message format and then uses the API to post the messages to the conversation. This approach allows for greater control over the data transformation and can improve performance.

When dealing with attachments, ensure that the file size and type adhere to the Genesys Cloud API limits. The API documentation provides detailed information on supported file types and size restrictions. consider the storage implications of uploading a large number of attachments.

Regarding the author field, experiment with using a consistent identifier for the system migration bot. This could be a dedicated user ID within Genesys Cloud, ensuring that all historical messages are attributed to a single source. This approach helps avoid the “multiple author identifiers” error while clearly indicating that these messages are imported from the legacy system.

Finally, thoroughly test the migration process in a non-production environment before migrating to production. This allows you to identify and address any potential issues or performance bottlenecks. Pay close attention to the API rate limits and adjust the migration strategy accordingly.

The documentation actually says Digital Engagement transcripts are immutable once archived. You cannot inject historical data into an active session via API.

Use the Archived Conversations API for bulk migration instead. Map Zendesk comments to message objects in a JSON payload.

{
 "messages": [
 {
 "type": "text",
 "from": "external",
 "text": "<p>Legacy comment</p>",
 "timestamp": "2023-01-01T00:00:00.000Z"
 }
 ]
}

the conversation retrieval route is the way to go. trying to push into active digital sessions is a dead end, as the suggestion above noted.

here’s a quick curl to verify the payload structure for bulk import. keep the type as text and ensure the from field matches your external source identifier.

curl -X GET "https://myorg.mygenesyscloud.com/api/v2/conversations/legacy-ticket-123" \
 -H "Authorization: Bearer $TOKEN" \
 -H "Content-Type: application/json"

watch out for the timestamp format. it needs to be ISO 8601 or the API throws a 400. also, if you have attachments, you’ll need to host them externally and link them in the annotations field, since Genesys doesn’t ingest binary blobs directly into the transcript JSON.

1 Like

yep, that archived conversation endpoint is the only way. just make sure your from field is set to external or the system rejects the payload immediately.

2 Likes