# Intercom schema ERD

Table and field reference for the Fivetran Intercom connector.

## Table & Field Reference

### collection_history

| Column | Type | Keys |
| --- | --- | --- |
| id | String | PK |
| help_center_id | String | FK |
| created_at | Instant |  |
| default_locale | String |  |
| description | String |  |
| icon | String |  |
| name | String |  |
| order | Int |  |
| parent_id | String |  |
| type | String |  |
| updated_at | Instant |  |
| url | String |  |
| workspace_id | String |  |

### conversation_history

| Column | Type | Keys |
| --- | --- | --- |
| id | String | PK |
| conversation_rating_contact_id | String | FK |
| source_author_id | String | FK |
| assignee_id | String |  |
| company_id | String |  |
| created_at | Instant |  |
| first_contact_reply_created_at | Instant |  |
| first_contact_reply_type | String |  |
| first_contact_reply_url | String |  |
| open | Boolean |  |
| priority | String |  |
| read | Boolean |  |
| sla_name | String |  |
| sla_status | String |  |
| snoozed_until | Instant |  |
| state | String |  |
| team_assignee_id | String |  |
| title | String |  |
| updated_at | Instant |  |
| waiting_since | Instant |  |
| ai_agent_** |  |  |
| conversation_rating_** |  |  |
| source_** |  |  |
| statistics_** |  |  |

### survey_question

| Column | Type | Keys |
| --- | --- | --- |
| question_id | Long | PK |
| receipt_id | Long | PK, FK |
| question | String |  |
| response_type | String |  |

### subscription_type_content_type

| Column | Type | Keys |
| --- | --- | --- |
| value | String | PK |
| subscription_type_id | String | PK, FK |

### contact_tag_history

| Column | Type | Keys |
| --- | --- | --- |
| contact_id | String | PK, FK |
| tag_id | String | PK, FK |
| contact_updated_at | Instant | FK |

### conversation_topic_history

| Column | Type | Keys |
| --- | --- | --- |
| id | String | PK |
| conversation_id | String | PK, FK |
| conversation_updated_at | Instant | FK |
| name | String |  |
| type | String |  |

### subscription_type_translation

| Column | Type | Keys |
| --- | --- | --- |
| name | String | PK |
| subscription_type_id | String | PK, FK |
| description | String |  |
| locale | String |  |

### message_open

| Column | Type | Keys |
| --- | --- | --- |
| opened_at | Instant | PK |
| receipt_id | Long | PK, FK |

### news_item_history

| Column | Type | Keys |
| --- | --- | --- |
| id | String | PK |
| body | String |  |
| cover_image_url | String |  |
| created_at | Instant |  |
| deliver_silently | Boolean |  |
| sender_id | String |  |
| state | String |  |
| title | String |  |
| type | String |  |
| updated_at | Instant |  |
| workspace_id | String |  |

### help_center_history

| Column | Type | Keys |
| --- | --- | --- |
| id | String | PK |
| created_at | Instant |  |
| custom_domain | String |  |
| display_name | String |  |
| identifier | String |  |
| updated_at | Instant |  |
| url | String |  |
| website_turned_on | Boolean |  |
| workspace_id | String |  |

### contact_data_event

| Column | Type | Keys |
| --- | --- | --- |
| id | String | PK |
| intercom_user_id | String | FK |
| created_at | Instant |  |
| email | String |  |
| event_name | String |  |
| type | String |  |
| user_id | String |  |

### company_tag_history

| Column | Type | Keys |
| --- | --- | --- |
| company_id | String | PK, FK |
| tag_id | String | PK, FK |
| company_updated_at | Instant | FK |

### ticket_type_attribute_history

| Column | Type | Keys |
| --- | --- | --- |
| id | String | PK |
| ticket_type_id | String | FK |
| archived | Boolean |  |
| created_at | Instant |  |
| data_type | String |  |
| default | Boolean |  |
| description | String |  |
| input_options | Json |  |
| name | String |  |
| order | Long |  |
| required_to_create | Boolean |  |
| required_to_create_for_contacts | Boolean |  |
| type | String |  |
| updated_at | Instant |  |
| visible_on_create | Boolean |  |
| visible_to_contacts | Boolean |  |
| workspace_id | String |  |

### conversation_tag_history

| Column | Type | Keys |
| --- | --- | --- |
| conversation_id | String | PK, FK |
| tag_id | String | PK, FK |
| conversation_updated_at | Instant | FK |
| applied_at | Instant |  |
| applied_by_id | String |  |
| applied_by_type | String |  |
| tag_name | String |  |

### call_transcript

| Column | Type | Keys |
| --- | --- | --- |
| _fivetran_id | String | PK |
| call_id | Long | PK, FK |
| content | String |  |
| end_time | String |  |
| speaker | String |  |
| speaker_label | String |  |
| start_time | String |  |

### ticket_part_attachment_history

| Column | Type | Keys |
| --- | --- | --- |
| index | Int | PK |
| ticket_id | String | PK, FK |
| ticket_part_id | String | PK, FK |
| content_type | String |  |
| filesize | Long |  |
| height | Int |  |
| name | String |  |
| type | String |  |
| url | String |  |
| width | Int |  |

### article_history

| Column | Type | Keys |
| --- | --- | --- |
| id | String | PK |
| collection_id | String | FK |
| author_id | String |  |
| body | String |  |
| created_at | Instant |  |
| default_locale | String |  |
| description | String |  |
| parent_id | String |  |
| parent_type | String |  |
| section_id | String |  |
| state | String |  |
| title | String |  |
| type | String |  |
| updated_at | Instant |  |
| url | String |  |
| workspace_id | String |  |
| statistics_** |  |  |

### article_parent

| Column | Type | Keys |
| --- | --- | --- |
| parent_id | String | PK |
| article_id | String | PK, FK |

### conversation_ai_agent_content_source

| Column | Type | Keys |
| --- | --- | --- |
| index | Long | PK |
| conversation_id | String | PK, FK |
| content_type | String |  |
| locale | String |  |
| title | String |  |
| url | String |  |

### conversation_part_history

| Column | Type | Keys |
| --- | --- | --- |
| id | String | PK |
| conversation_id | String | FK |
| conversation_updated_at | Instant | FK |
| app_package_code | String |  |
| assigned_to_id | String |  |
| assigned_to_type | String |  |
| body | String |  |
| created_at | Instant |  |
| email_message_metadata_message_id | String |  |
| email_message_metadata_subject | String |  |
| notified_at | Instant |  |
| part_type | String |  |
| state | String |  |
| updated_at | Instant |  |
| author_** |  |  |

### news_item_label_history

| Column | Type | Keys |
| --- | --- | --- |
| value | String | PK |
| news_item_id | String | PK, FK |

### ticket_link_history

| Column | Type | Keys |
| --- | --- | --- |
| id | String | PK |
| ticket_id | String | PK, FK |
| category | String |  |
| type | String |  |

### conversation_admin_history

| Column | Type | Keys |
| --- | --- | --- |
| admin_id | String | PK, FK |
| conversation_id | String | PK, FK |
| conversation_updated_at | Instant | FK |

### contact_segment_history

| Column | Type | Keys |
| --- | --- | --- |
| contact_id | String | PK, FK |
| segment_id | String | PK, FK |
| contact_updated_at | Instant | FK |

### ticket_contact_history

| Column | Type | Keys |
| --- | --- | --- |
| id | String | PK, FK |
| ticket_id | String | PK, FK |
| external_id | String |  |
| type | String |  |

### contact_subscription_history

| Column | Type | Keys |
| --- | --- | --- |
| contact_id | String | PK, FK |
| subscription_id | String | PK, FK |
| contact_updated_at | Instant | FK |
| consent_type | String |  |

### admin

| Column | Type | Keys |
| --- | --- | --- |
| id | String | PK |
| away_mode_enabled | Boolean |  |
| away_mode_reassign | Boolean |  |
| email | String |  |
| has_inbox_seat | Boolean |  |
| job_title | String |  |
| name | String |  |

### ticket_type_history

| Column | Type | Keys |
| --- | --- | --- |
| id | String | PK |
| archived | Boolean |  |
| category | String |  |
| created_at | Instant |  |
| description | String |  |
| icon | String |  |
| is_internal | Boolean |  |
| name | String |  |
| type | String |  |
| updated_at | Instant |  |
| workspace_id | String |  |

### conversation_part_attachment_history

| Column | Type | Keys |
| --- | --- | --- |
| url | String | PK |
| conversation_part_id | String | PK, FK |
| conversation_part_updated_at | Instant | FK |
| name | String |  |

### away_status_reason

| Column | Type | Keys |
| --- | --- | --- |
| id | String | PK |
| created_at | Instant |  |
| deleted | Boolean |  |
| emoji | String |  |
| label | String |  |
| orders | Int |  |
| updated_at | Instant |  |

### newsfeed_history

| Column | Type | Keys |
| --- | --- | --- |
| id | String | PK |
| created_at | Instant |  |
| name | String |  |
| type | String |  |
| updated_at | Instant |  |

### team

| Column | Type | Keys |
| --- | --- | --- |
| id | String | PK |
| name | String |  |

### conversation_source_attachment_history

| Column | Type | Keys |
| --- | --- | --- |
| url | String | PK |
| conversation_id | String | PK, FK |
| conversation_updated_at | Instant | FK |
| content_type | String |  |
| filesize | Long |  |
| height | Long |  |
| name | String |  |
| type | String |  |
| width | Long |  |

### survey_answer

| Column | Type | Keys |
| --- | --- | --- |
| question_id | Long | PK, FK |
| receipt_id | Long | PK, FK |
| answered_at | Instant |  |
| response | String |  |

### receipt_response

| Column | Type | Keys |
| --- | --- | --- |
| content_id | Long | PK |
| receipt_id | Long | PK |
| ruleset_id | Long | PK |
| company_external_id | String |  |
| company_id | String |  |
| content_title | String |  |
| content_type | String |  |
| conversation_id | Long |  |
| created_via | String |  |
| device | String |  |
| email | String |  |
| first_answer | Instant |  |
| first_button_tap | Instant |  |
| first_checklist_step_click | Instant |  |
| first_checklist_step_completion | Instant |  |
| first_checklist_step_open | Instant |  |
| first_checklist_step_receipt | Instant |  |
| first_click | Instant |  |
| first_collected_email | Instant |  |
| first_completion | Instant |  |
| first_dismissal | Instant |  |
| first_fin_helpful_answer | Instant |  |
| first_fin_step_reached | Instant |  |
| first_goal_success | Instant |  |
| first_hard_bounce | Instant |  |
| first_keyword_reply | Instant |  |
| first_open | Instant |  |
| first_people_reached_receipt | Instant |  |
| first_permission_grant | Instant |  |
| first_push_failure | Instant |  |
| first_reaction | Instant |  |
| first_reply | Instant |  |
| first_screen_view | Instant |  |
| first_series_completion | Instant |  |
| first_series_disengagement | Instant |  |
| first_series_exit | Instant |  |
| first_sms_failure | Instant |  |
| first_soft_bounce | Instant |  |
| first_spam_complaint | Instant |  |
| first_tour_step_failure | Instant |  |
| first_tour_step_view | Instant |  |
| first_unsubscribe | Instant |  |
| first_webhook_failure | Instant |  |
| first_whatsapp_failure | Instant |  |
| name | String |  |
| node_id | String |  |
| received_at | Instant |  |
| ruleset_version_id | Long |  |
| series_id | Long |  |
| series_title | String |  |
| user_external_id | String |  |
| user_id | String |  |

### contact_company_history

| Column | Type | Keys |
| --- | --- | --- |
| company_id | String | PK, FK |
| contact_id | String | PK, FK |
| contact_updated_at | Instant | FK |

### ticket_part_history

| Column | Type | Keys |
| --- | --- | --- |
| id | String | PK |
| ticket_id | String | PK, FK |
| app_package_code | String |  |
| assigned_to_id | String |  |
| assigned_to_type | String |  |
| body | String |  |
| created_at | Instant |  |
| external_id | String |  |
| part_type | String |  |
| previous_ticket_state | String |  |
| redacted | Boolean |  |
| ticket_state | String |  |
| type | String |  |
| updated_at | Instant |  |
| author_** |  |  |

### conversation_contact_history

| Column | Type | Keys |
| --- | --- | --- |
| contact_id | String | PK, FK |
| conversation_id | String | PK, FK |
| conversation_updated_at | Instant | FK |

### company_segment_history

| Column | Type | Keys |
| --- | --- | --- |
| company_id | String | PK, FK |
| segment_id | String | PK, FK |
| company_updated_at | Instant | FK |

### admin_activity_log

| Column | Type | Keys |
| --- | --- | --- |
| id | String | PK |
| performed_by_id | String | FK |
| activity_description | String |  |
| activity_type | String |  |
| created_at | Instant |  |
| metadata | Json |  |
| performed_by_ip | String |  |
| performed_by_type | String |  |

### email_address_header

| Column | Type | Keys |
| --- | --- | --- |
| _fivetran_id | String | PK |
| conversation_part_id | String | PK, FK |
| email_address | String |  |
| name | String |  |
| type | String |  |

### company_history

| Column | Type | Keys |
| --- | --- | --- |
| id | String | PK |
| app_id | String |  |
| company_id | String |  |
| created_at | Instant |  |
| industry | String |  |
| last_request_at | Instant |  |
| monthly_spend | Int |  |
| name | String |  |
| plan_id | String |  |
| plan_name | String |  |
| remote_created_at | Instant |  |
| session_count | Int |  |
| size | Int |  |
| updated_at | Instant |  |
| user_count | Int |  |
| website | String |  |

### newsfeed_assignment

| Column | Type | Keys |
| --- | --- | --- |
| news_item_id | String | PK, FK |
| newsfeed_id | String | PK, FK |
| published_at | Instant |  |

### contact_history

| Column | Type | Keys |
| --- | --- | --- |
| id | String | PK |
| admin_id | Long | FK |
| android_app_name | String |  |
| android_app_version | String |  |
| android_device | String |  |
| android_last_seen_at | Instant |  |
| android_os_version | String |  |
| android_sdk_version | String |  |
| avatar | String |  |
| browser | String |  |
| browser_language | String |  |
| browser_version | String |  |
| created_at | Instant |  |
| email | String |  |
| enabled_push_messaging | Boolean |  |
| external_id | String |  |
| formatted_phone | String |  |
| has_hard_bounced | Boolean |  |
| ios_app_name | String |  |
| ios_app_version | String |  |
| ios_device | String |  |
| ios_last_seen_at | Instant |  |
| ios_os_version | String |  |
| ios_sdk_version | String |  |
| language_override | String |  |
| last_contacted_at | Instant |  |
| last_email_clicked_at | Instant |  |
| last_email_opened_at | Instant |  |
| last_replied_at | Instant |  |
| last_seen_at | Instant |  |
| location_city | String |  |
| location_country | String |  |
| location_region | String |  |
| marked_email_as_spam | Boolean |  |
| name | String |  |
| os | String |  |
| phone | String |  |
| referrer | String |  |
| role | String |  |
| signed_up_at | Instant |  |
| unsubscribed_from_emails | Boolean |  |
| updated_at | Instant |  |
| utm_campaign | String |  |
| utm_content | String |  |
| utm_medium | String |  |
| utm_source | String |  |
| utm_term | String |  |
| workspace_id | String |  |

### contact_social_profile_history

| Column | Type | Keys |
| --- | --- | --- |
| name | String | PK |
| user_id | String | PK, FK |
| user_updated_at | Instant | FK |
| url | String |  |

### news_item_reaction_history

| Column | Type | Keys |
| --- | --- | --- |
| value | String | PK |
| news_item_id | String | PK, FK |

### tag

| Column | Type | Keys |
| --- | --- | --- |
| id | String | PK |
| name | String |  |

### call

| Column | Type | Keys |
| --- | --- | --- |
| id | Long | PK |
| admin_id | String | FK |
| contact_id | String | FK |
| conversation_id | String | FK |
| answered_at | Instant |  |
| call_type | String |  |
| created_at | Instant |  |
| direction | String |  |
| ended_at | Instant |  |
| ended_reason | String |  |
| fin_recording_url | String |  |
| fin_transcription_url | String |  |
| initiated_at | Instant |  |
| phone | String |  |
| recording_url | String |  |
| state | String |  |
| transcript_status | String |  |
| transcription_url | String |  |
| type | String |  |
| updated_at | Instant |  |

### team_admin

| Column | Type | Keys |
| --- | --- | --- |
| admin_id | String | PK, FK |
| team_id | String | PK, FK |

### data_attribute_option

| Column | Type | Keys |
| --- | --- | --- |
| value | String | PK |
| data_attribute_model | String | PK, FK |
| data_attribute_name | String | PK, FK |

### ticket_state

| Column | Type | Keys |
| --- | --- | --- |
| id | String | PK |
| archived | Boolean |  |
| category | String |  |
| external_label | String |  |
| internal_label | String |  |
| type | String |  |

### segment

| Column | Type | Keys |
| --- | --- | --- |
| id | String | PK |
| count | Int |  |
| created_at | Instant |  |
| name | String |  |
| person_type | String |  |
| type | String |  |
| updated_at | Instant |  |

### series_disengagement

| Column | Type | Keys |
| --- | --- | --- |
| disengaged_at | Instant | PK |
| receipt_id | Long | PK, FK |
| disengaged_node_ruleset_id | String |  |

### team_admin_priority_level

| Column | Type | Keys |
| --- | --- | --- |
| admin_id | String | PK, FK |
| team_id | String | PK, FK |
| priority | String |  |

### data_attribute

| Column | Type | Keys |
| --- | --- | --- |
| model | String | PK |
| name | String | PK |
| admin_id | String | FK |
| api_writable | Boolean |  |
| archived | Boolean |  |
| created_at | Instant |  |
| custom | Boolean |  |
| data_type | String |  |
| description | String |  |
| full_name | String |  |
| id | String |  |
| label | String |  |
| messenger_writable | Boolean |  |
| type | String |  |
| ui_writable | Boolean |  |
| updated_at | Instant |  |

### subscription_type

| Column | Type | Keys |
| --- | --- | --- |
| id | String | PK |
| consent_type | String |  |
| default_translation_description | String |  |
| default_translation_locale | String |  |
| default_translation_name | String |  |
| state | String |  |
| type | String |  |

### ticket_history

| Column | Type | Keys |
| --- | --- | --- |
| id | String | PK, FK |
| ticket_state_id | String | FK |
| ticket_type_id | String | FK |
| admin_assignee_id | String |  |
| category | String |  |
| created_at | Instant |  |
| is_shared | Boolean |  |
| linked_objects_has_more | Boolean |  |
| linked_objects_total_count | Long |  |
| open | Boolean |  |
| snoozed_until | Instant |  |
| team_assignee_id | String |  |
| ticket_id | String |  |
| ticket_parts_total_count | Long |  |
| ticket_state | String |  |
| ticket_state_external_label | String |  |
| ticket_state_internal_label | String |  |
| type | String |  |
| updated_at | Instant |  |

### conversation_part_tag_history

| Column | Type | Keys |
| --- | --- | --- |
| conversation_part_id | String | PK, FK |
| tag_id | String | PK, FK |
| conversation_part_updated_at | Instant | FK |

## Relationships

- collection_history(help_center_id) → help_center_history(id)
- conversation_history(source_author_id) → contact_history(id)
- conversation_history(conversation_rating_contact_id) → contact_history(id)
- survey_question(receipt_id) → receipt_response(receipt_id)
- subscription_type_content_type(subscription_type_id) → subscription_type(id)
- contact_tag_history(contact_id) → contact_history(id)
- contact_tag_history(contact_updated_at) → contact_history(id)
- contact_tag_history(tag_id) → tag(id)
- conversation_topic_history(conversation_id) → conversation_history(id)
- conversation_topic_history(conversation_updated_at) → conversation_history(id)
- subscription_type_translation(subscription_type_id) → subscription_type(id)
- message_open(receipt_id) → receipt_response(receipt_id)
- contact_data_event(intercom_user_id) → contact_history(id)
- company_tag_history(tag_id) → tag(id)
- company_tag_history(company_id) → company_history(id)
- company_tag_history(company_updated_at) → company_history(id)
- ticket_type_attribute_history(ticket_type_id) → ticket_type_history(id)
- conversation_tag_history(conversation_id) → conversation_history(id)
- conversation_tag_history(conversation_updated_at) → conversation_history(id)
- conversation_tag_history(tag_id) → tag(id)
- call_transcript(call_id) → call(id)
- ticket_part_attachment_history(ticket_part_id) → ticket_part_history(id)
- ticket_part_attachment_history(ticket_id) → ticket_history(id)
- article_history(collection_id) → collection_history(id)
- article_parent(article_id) → article_history(id)
- conversation_ai_agent_content_source(conversation_id) → conversation_history(id)
- conversation_part_history(conversation_id) → conversation_history(id)
- conversation_part_history(conversation_updated_at) → conversation_history(id)
- news_item_label_history(news_item_id) → news_item_history(id)
- ticket_link_history(ticket_id) → ticket_history(id)
- conversation_admin_history(conversation_id) → conversation_history(id)
- conversation_admin_history(conversation_updated_at) → conversation_history(id)
- conversation_admin_history(admin_id) → admin(id)
- contact_segment_history(segment_id) → segment(id)
- contact_segment_history(contact_id) → contact_history(id)
- contact_segment_history(contact_updated_at) → contact_history(id)
- ticket_contact_history(id) → contact_history(id)
- ticket_contact_history(ticket_id) → ticket_history(id)
- contact_subscription_history(subscription_id) → subscription_type(id)
- contact_subscription_history(contact_id) → contact_history(id)
- contact_subscription_history(contact_updated_at) → contact_history(id)
- conversation_part_attachment_history(conversation_part_id) → conversation_part_history(id)
- conversation_part_attachment_history(conversation_part_updated_at) → conversation_part_history(id)
- conversation_source_attachment_history(conversation_id) → conversation_history(id)
- conversation_source_attachment_history(conversation_updated_at) → conversation_history(id)
- survey_answer(receipt_id) → survey_question(receipt_id)
- survey_answer(question_id) → survey_question(question_id)
- contact_company_history(company_id) → company_history(id)
- contact_company_history(contact_id) → contact_history(id)
- contact_company_history(contact_updated_at) → contact_history(id)
- ticket_part_history(ticket_id) → ticket_history(id)
- conversation_contact_history(conversation_id) → conversation_history(id)
- conversation_contact_history(conversation_updated_at) → conversation_history(id)
- conversation_contact_history(contact_id) → contact_history(id)
- company_segment_history(segment_id) → segment(id)
- company_segment_history(company_id) → company_history(id)
- company_segment_history(company_updated_at) → company_history(id)
- admin_activity_log(performed_by_id) → admin(id)
- email_address_header(conversation_part_id) → conversation_part_history(id)
- newsfeed_assignment(newsfeed_id) → newsfeed_history(id)
- newsfeed_assignment(news_item_id) → news_item_history(id)
- contact_history(admin_id) → admin(id)
- contact_social_profile_history(user_id) → contact_history(id)
- contact_social_profile_history(user_updated_at) → contact_history(id)
- news_item_reaction_history(news_item_id) → news_item_history(id)
- call(conversation_id) → conversation_history(id)
- call(admin_id) → admin(id)
- call(contact_id) → contact_history(id)
- team_admin(admin_id) → admin(id)
- team_admin(team_id) → team(id)
- data_attribute_option(data_attribute_name) → data_attribute(name)
- data_attribute_option(data_attribute_model) → data_attribute(name)
- series_disengagement(receipt_id) → receipt_response(receipt_id)
- team_admin_priority_level(admin_id) → admin(id)
- team_admin_priority_level(team_id) → team(id)
- data_attribute(admin_id) → admin(id)
- ticket_history(id) → conversation_history(id)
- ticket_history(ticket_type_id) → ticket_type_history(id)
- ticket_history(ticket_state_id) → ticket_state(id)
- conversation_part_tag_history(conversation_part_id) → conversation_part_history(id)
- conversation_part_tag_history(conversation_part_updated_at) → conversation_part_history(id)
- conversation_part_tag_history(tag_id) → tag(id)
