Conversation ID

Conversation participants are assigned IDs based on whether they've provided contact information or registered as a site member. The typical lifecycle is anonymous visitor > contact > site member, although it's possible to skip a step or to become a contact and site member at the same time.

TypeID propertyDetails
Anonymous visitoranonymousVisitorIdWhen the participant first opens the site, they're an anonymous visitor.
ContactcontactId
  • An anonymous visitor converts to a contact when they provide some contact information, such as a name, phone number, or email address. This most often happens when they submit a contact form, purchase something, or become a site member.
  • When a visitor converts to a contact, they’re added to the site’s Contact List.
MembermemberId
  • An anonymous visitor or contact becomes a member when they're registered as a site member.
  • Members are always linked to a contact, so they have both a member ID and a contact ID.

Behind the scenes, when a participant changes type, a new conversation is created and the previous conversation is merged into the new one. Before sending a message, you can ensure you're using the most current conversation ID by calling Get or Create Conversation with the participant's visitor, contact, or member ID.

The sections below tell you how your app can get the relevant ID to use the Inbox API.

Anonymous visitor ID

Anonymous visitor IDs are available to your app only after the visitor sends a message to the business using the Message Sent To Business Webhook. The ID is available at actionEvent.body.message.sender.anonymousVisitorId.

Contact ID

When a visitor provides contact details to the site, they're converted to a contact. Once this happens, the ID used to access the visitor's conversations changes to the contact ID:

  • Like the anonymous visitor, the contact ID is available when the contact sends a message to the business using the Message Sent To Business Webhook. The ID is available at actionEvent.body.message.sender.contactId.
  • You can also use Query Contacts or List Contacts in the Contacts API to retrieve the contact.

Member ID

If the visitor is a site member, the conversation must be accessed using the member ID:

  • Like the anonymous visitor and contact, the member ID is available when the contact sends a message to the business using the Message Sent To Business Webhook. The ID is available at actionEvent.body.message.sender.memberId.
  • You can also use Query Members or List Members in the Members API to retrieve the member.
Was this helpful?
Yes
No

Conversation Object

Properties
idstringRead-onlyformat GUID

Conversation ID.


participantobject

ID of the visitor, contact, or member who is chatting with the business.


channelsArray <string>Read-only

List of communication channels where the visitor, contact, or member can receive messages.


businessDisplayDataobject

Display name and avatar for the business.


participantDisplayDataobject

Display name and avatar for the visitor, contact, or member.

Was this helpful?
Yes
No

GetGet Conversation

Developer Preview

This API is subject to change. Bug fixes and new features will be released based on developer feedback throughout the preview period.

Retrieves a conversation by conversation ID.

If you don't have the conversation ID, use Get Or Create Conversation to retrieve the conversation with the visitor, contact, or member ID.

Permission Scopes

For app development, you must have one of the following permission scopes:
Read Inbox Messages
Learn more about permission scopes.
Endpoint
GET
https://www.wixapis.com/inbox/v2/conversations/{conversationId}

Was this helpful?
Yes
No

PostGet Or Create Conversation

Developer Preview

This API is subject to change. Bug fixes and new features will be released based on developer feedback throughout the preview period.

Retrieves a conversation for the specified visitor, contact, or member ID, or creates one if it doesn't exist.

Permission Scopes

For app development, you must have one of the following permission scopes:
Manage Inbox Messages
Learn more about permission scopes.
Endpoint
POST
https://www.wixapis.com/inbox/v2/conversations

Was this helpful?
Yes
No

Conversations Merged

Developer Preview

This API is subject to change. Bug fixes and new features will be released based on developer feedback throughout the preview period.

Triggered when the conversation is merged, for example when contacts are merged or when a visitor becomes a contact.

If messages exist in both conversations when they merge, the messages are preserved in chronological order.

Event BodyEvent Body Event data is received as a JSON Web Token (JWT). It may be delayed. Be sure to verify the data was sent by Wix.
Event Data
idstring

Unique event ID. Allows clients to ignore duplicate webhooks.


entityFqdnstring

Fully qualified domain name of the entity associated with the event. Expected wix.crm.inbox.v2.conversation.


slugstring

Event name. Expected conversations_merged.


entityIdstring

ID of the entity associated with the event.


eventTimestringformat date-time

Event timestamp.


triggeredByAnonymizeRequestboolean

Whether the event was triggered as a result of a privacy regulation application (for example, GDPR).


originatedFromstring

If present, indicates the action that triggered the event.


actionEventobject

Event information.


Was this helpful?
Yes
No