Visitors
Convert a visitor
You can merge a Visitor to a Contact of role type lead or user.
📘 What happens upon a visitor being converted?
If the User exists, then the Visitor will be merged into it, the Visitor deleted and the User returned. If the User does not exist, the Visitor will be converted to a User, with the User identifiers replacing it's Visitor identifiers.
post/visitors/convert
Headers
Intercom-Version'1.0' | '1.1' | '1.2' | '1.3' | '1.4' | '2.0' | '2.1' | '2.2' | '2.3' | '2.4' | '2.5' | '2.6' | '2.7' | '2.8' | '2.9' | '2.10' | '2.11' | '2.12' | '2.13' | '2.14'
Intercom API version.</br>By default, it's equal to the version set in the app package.
Example:2.14
Request body
Example request
{
"type": "user",
"user": {
"id": "8a88a590-e1c3-41e2-a502-e0649dbf721c",
"user_id": "8a88a590-e1c3-41e2-a502-e0649dbf721c",
"email": "winstonsmith@truth.org"
},
"visitor": {
"id": "8a88a590-e1c3-41e2-a502-e0649dbf721c",
"user_id": "8a88a590-e1c3-41e2-a502-e0649dbf721c",
"email": "winstonsmith@truth.org"
}
}Response
successful
Example response
{
"type": "contact",
"id": "5ba682d23d7cf92bef87bfd4",
"external_id": "f3b87a2e09d514c6c2e79b9a",
"workspace_id": "ecahpwf5",
"role": "user",
"email": "joe@example.com",
"email_domain": "example.com",
"phone": "+1123456789",
"name": "John Doe",
"owner_id": 123,
"has_hard_bounced": true,
"marked_email_as_spam": true,
"unsubscribed_from_emails": true,
"created_at": 1571672154,
"updated_at": 1571672154,
"signed_up_at": 1571672154,
"last_seen_at": 1571672154,
"last_replied_at": 1571672154,
"last_contacted_at": 1571672154,
"last_email_opened_at": 1571672154,
"last_email_clicked_at": 1571672154,
"language_override": "en",
"browser": "Chrome",
"browser_version": "80.0.3987.132",
"browser_language": "en-US",
"os": "Mac OS X",
"android_app_name": "Intercom",
"android_app_version": "5.0.0",
"android_device": "Pixel 3",
"android_os_version": "10",
"android_sdk_version": "28",
"android_last_seen_at": 1571672154,
"ios_app_name": "Intercom",
"ios_app_version": "5.0.0",
"ios_device": "iPhone 11",
"ios_os_version": "13.3.1",
"ios_sdk_version": "13.3.1",
"ios_last_seen_at": 1571672154,
"avatar": {
"type": "avatar",
"image_url": "https://example.org/128Wash.jpg"
},
"tags": {
"data": [
{
"type": "note",
"id": "123",
"url": "/contacts/5ba682d23d7cf92bef87bfd4/notes"
}
],
"url": "/contacts/5ba682d23d7cf92bef87bfd4/tags",
"total_count": 100,
"has_more": true
},
"notes": {
"data": [
{
"type": "note",
"id": "123",
"url": "/contacts/5ba682d23d7cf92bef87bfd4/notes"
}
],
"url": "/contacts/5ba682d23d7cf92bef87bfd4/notes",
"total_count": 100,
"has_more": true
},
"companies": {
"data": [
{
"id": "5ba682d23d7cf92bef87bfd4",
"type": "company",
"url": "/companies/5ba682d23d7cf92bef87bfd4"
}
],
"url": "/contacts/5ba682d23d7cf92bef87bfd4/companies",
"total_count": 100,
"has_more": true
},
"location": {
"type": "location",
"country": "Ireland",
"region": "Dublin",
"city": "Dublin"
},
"social_profiles": {
"data": [
{
"type": "social_profile",
"name": "Facebook",
"url": "http://twitter.com/th1sland"
}
]
}
}