Add email history to conversation source (Unstable spec)#421
Merged
VarshSuresh merged 1 commit intomainfrom Mar 25, 2026
Merged
Conversation
Implements four schema changes to support email history in conversation sources:
1. Add `include_email_history` query parameter to GET /conversations/{id}
2. Add response example showing email conversation with history metadata
3. Add `email_message_metadata` field to conversation_source schema
4. Add new `source_email_message_metadata` schema with history field
This enables API clients to retrieve quoted/forwarded email threads when
fetching conversation details with `?include_email_history=true`.
Aligns with intercom/developer-docs#795 and intercom/intercom#467590.
Co-Authored-By: Claude Haiku 4.5 <noreply@anthropic.com>
dan0505
approved these changes
Mar 25, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Why?
Customers need access to quoted/forwarded email threads when retrieving conversation details. This change implements the email history feature documented in intercom/developer-docs#795 (which was mirrored from intercom/intercom#467590), adding the ability to opt-in via the
include_email_historyquery parameter.How?
Added four schema changes to support email history in the Unstable API spec:
include_email_historyon GET/conversations/{id}to opt-in to email historyemail_message_metadatacontaining thehistoryfieldemail_message_metadatareference toconversation_sourceschemasource_email_message_metadatacomponent withmessage_id,subject,email_address_headers, andhistoryfieldsThe schema is separate from the existing
email_message_metadata(used by conversation parts) to keep email source metadata domain-specific.Validated with
fern check— 0 errors.Swagger
Generated with Claude Code