Search.../
  1. Home
  2. Getting Started
  3. Overview
Generate a test token to explore our APIs

CRM

APIs
  • Contacts

    Manage Contact list and contact details

Contacts

Manage Contact list and contact details Learn more.

Guides

Additional information about this section

Main Entity

The API's main object

Endpoints

The endpoints exposed by this API

  • GET

    Returns a contact with the provided ID

  • GET

    Returns a list of contacts, given the provided paging (offset, limit) and order (firstName, lastName, email (first email), metadata.updatedAt)

Webhooks

About Contacts

The Contacts service manages Wix sites' contacts. A contact is someone relevant to the site's business – either a site visitor who has performed a meaningful interaction within the site, or a person who was added manually.

In a Wix site, the site owner and anyone they have added as a contributor can view and manage the site's contacts.

A contact can be created in the following ways:

  • A site visitor fills in a form with their communication details
  • A site visitor signs up to the site
  • The site owner or a contributor enters the contact manually or using the import contacts feature

A contact has the following fields:

  • id - Unique identifier associated with the contact (read-only)
  • first_name - Contact's first name
  • last_name - Contact's last name
  • emails - Email address(es) associated with the contact
  • phones - Phone number(s) associated with the contact
  • addresses - Street address(es) associated with the contact

Was this helpful?

Contact Object

Attributes

NAME
TYPE
DESCRIPTION
source

object

Contact Source

phones

Array<object>

Contact phone number data

lastName

string

Contact Last name

firstName

string

Contact first name

id

string

Contact ID (unique)

metadata

object

Contact metadata

emails

Array<object>

Contact email address data

addresses

Array<object>

Contact address data

Was this helpful?

Object

json

1
2{
3 "id": "8046df3c-7575-4098-a5ab-c91ad8f33c47",
4 "firstName": "Some",
5 "lastName": "One",
6 "emails": [ {
7 "tag": "MAIN",
8 "email": "email@test.rocks"
9 }],
10 "phones": [
11 {
12 "tag": "HOME",
13 "phone": "2075556300"
14 },
15 {
16 "tag": "MOBILE",
17 "phone": "2075555217"
18 }
19 ],
20 "addresses": [ {
21 "tag": "HOME",
22 "street": "1772 Fantages Way",
23 "city": "Richmond",
24 "region": "ME",
25 "country": "US",
26 "postalCode": "04357"
27 }],
28 "metadata": {
29 "createdAt": "2019-10-30T17:22:10.299Z",
30 "updatedAt": "2019-11-13T20:14:49.458Z"
31 }
32}

Get Contact

Returns a contact with the provided ID

Authorization

This API requires an authorization header - pass the access token from the OAuth installation flow.

Permissions

The API requires CONTACTS.VIEW

GET

https://www.wixapis.com/crm/v1/contacts/{id}

Path Params

NAME
TYPE
DESCRIPTION
id
Required

string

Contact ID

Response Object

Get Contact Response

NAME
TYPE
DESCRIPTION
contact

object

Status/Error Codes

The response will include an HTTP status code.

Was this helpful?

Request

curl

Copy Code
1curl -X GET \
2 'https://www.wixapis.com/crm/v1/contacts/8046df3c-7575-4098-a5ab-c91ad8f33c47' \
3 -H 'Authorization: <AUTH>'

Response

json

1
2{"contact": {
3 "id": "8046df3c-7575-4098-a5ab-c91ad8f33c47",
4 "firstName": "Some",
5 "lastName": "One",
6 "emails": [ {
7 "tag": "MAIN",
8 "email": "email@test.rocks"
9 }],
10 "phones": [
11 {
12 "tag": "HOME",
13 "phone": "2075556300"
14 },
15 {
16 "tag": "MOBILE",
17 "phone": "2075555217"
18 }
19 ],
20 "addresses": [ {
21 "tag": "HOME",
22 "street": "1772 Fantages Way",
23 "city": "Richmond",
24 "region": "ME",
25 "country": "US",
26 "postalCode": "04357"
27 }],
28 "metadata": {
29 "createdAt": "2019-10-30T17:22:10.299Z",
30 "updatedAt": "2019-11-13T20:14:49.458Z"
31 }
32}}

List Contacts

Returns a list of contacts, given the provided paging (offset, limit) and order (firstName, lastName, email (first email), metadata.updatedAt)

Authorization

This API requires an authorization header - pass the access token from the OAuth installation flow.

Permissions

The API requires CONTACTS.VIEW

GET

https://www.wixapis.com/crm/v1/contacts

Query Params

NAME
TYPE
DESCRIPTION
sort.fieldName

string

Name of the field to sort by

sort.order

string

One of ASC, DESC.

Sort order (ASC/DESC). Defaults to ASC

paging.limit

integer

The number of items to load

paging.offset

integer

number of items to skip in the current sort order

Response Object

List Contacts Response

NAME
TYPE
DESCRIPTION
contacts

Array<object>

metadata

object

Status/Error Codes

The response will include an HTTP status code.

Was this helpful?

Example 1

Request

curl

Copy Code
1curl -X GET \
2 'https://www.wixapis.com/crm/v1/contacts' \
3 -H 'Authorization: <AUTH>'

Response

json

1
2{
3 "contacts": [
4 {
5 "id": "7a585d4b-74f1-4ff5-9d42-489299bf5259",
6 "firstName": "Sample",
7 "lastName": "Contact",
8 "emails": [ {
9 "tag": "WORK",
10 "email": "sample@contact.com"
11 }],
12 "phones": [ {
13 "tag": "UNTAGGED",
14 "phone": "+12225554444"
15 }],
16 "addresses": [ {
17 "tag": "UNTAGGED",
18 "street": "1 road",
19 "city": "Milano",
20 "countryCode": "IT",
21 "postalCode": "72662"
22 }],
23 "metadata": {
24 "createdAt": "2019-10-29T16:35:36.756Z",
25 "updatedAt": "2019-11-20T21:47:35.736Z"
26 }
27 },
28 {
29 "id": "8046df3c-7575-4098-a5ab-c91ad8f33c47",
30 "firstName": "Some",
31 "lastName": "One",
32 "emails": [ {
33 "tag": "MAIN",
34 "email": "email@test.rocks"
35 }],
36 "phones": [
37 {
38 "tag": "HOME",
39 "phone": "2075556300"
40 },
41 {
42 "tag": "MOBILE",
43 "phone": "2075555217"
44 }
45 ],
46 "addresses": [ {
47 "tag": "HOME",
48 "street": "1772 Fantages Way",
49 "city": "Richmond",
50 "region": "ME",
51 "countryCode": "US",
52 "postalCode": "04357"
53 }],
54 "metadata": {
55 "createdAt": "2019-10-30T17:22:10.299Z",
56 "updatedAt": "2019-11-13T20:14:49.458Z"
57 }
58 },
59 {
60 "id": "cb3cac0b-9a96-4ce9-8d6e-df6fc65e5f88",
61 "firstName": "Third",
62 "lastName": "Three",
63 "emails": [ {
64 "tag": "UNTAGGED",
65 "email": "three@four.to"
66 }],
67 "phones": [ {
68 "tag": "UNTAGGED",
69 "phone": "3333333"
70 }],
71 "addresses": [ {
72 "tag": "UNTAGGED",
73 "street": "30 3rd Ave",
74 "city": "Three Rivers",
75 "countryCode": "BR",
76 "postalCode": "28123"
77 }],
78 "metadata": {
79 "createdAt": "2019-11-20T21:49:02.804Z",
80 "updatedAt": "2019-11-20T21:49:02.811Z"
81 }
82 }
83 ],
84 "metadata": {
85 "items": 3,
86 "offset": 0,
87 "hasMore": false
88 }
89}
Example 2

Contact Created Webhook

Sent when a contact is created

Authorization

This API requires an authorization header - pass the access token from the OAuth installation flow.

Permissions

The API requires CONTACTS.VIEW

Event Body

The event's data is received as a JSON Web Token (JWT). Make sure to verify that the data was received by Wix - read more about it in the Webhooks article.

Payload

NAME
TYPE
DESCRIPTION
contact

object

Contact data

Was this helpful?

The data payload will include the following as an encoded JWT:

Event Body

json

1{
2 "data": {
3 "eventType": "<event-type>",
4 "instanceId": "<app-instance-id>",
5 "data": "<stringified-JSON>"
6 }
7}

The parsed data will include:

Sample Data

json

1
2{"contact": {
3 "id": "8046df3c-7575-4098-a5ab-c91ad8f33c47",
4 "firstName": "Some",
5 "lastName": "One",
6 "emails": [ {
7 "tag": "MAIN",
8 "email": "email@test.rocks"
9 }],
10 "phones": [ {
11 "tag": "HOME",
12 "phone": "2075556300"
13 }],
14 "addresses": [],
15 "metadata": {
16 "createdAt": "2019-10-30T17:22:10.299Z",
17 "updatedAt": "2019-10-30T17:22:10.299Z"
18 }
19}}

Contact Changed Webhook

Sent when a contact is updated

Authorization

This API requires an authorization header - pass the access token from the OAuth installation flow.

Permissions

The API requires CONTACTS.VIEW

Event Body

The event's data is received as a JSON Web Token (JWT). Make sure to verify that the data was received by Wix - read more about it in the Webhooks article.

Payload

NAME
TYPE
DESCRIPTION
contact

object

Updated contact

Was this helpful?

The data payload will include the following as an encoded JWT:

Event Body

json

1{
2 "data": {
3 "eventType": "<event-type>",
4 "instanceId": "<app-instance-id>",
5 "data": "<stringified-JSON>"
6 }
7}

The parsed data will include:

Sample Data

json

1
2{"contact": {
3 "id": "8046df3c-7575-4098-a5ab-c91ad8f33c47",
4 "firstName": "Some",
5 "lastName": "One",
6 "emails": [ {
7 "tag": "MAIN",
8 "email": "email@test.rocks"
9 }],
10 "phones": [
11 {
12 "tag": "HOME",
13 "phone": "2075556300"
14 },
15 {
16 "tag": "MOBILE",
17 "phone": "2075555217"
18 }
19 ],
20 "addresses": [ {
21 "tag": "HOME",
22 "street": "1772 Fantages Way",
23 "city": "Richmond",
24 "region": "ME",
25 "country": "US",
26 "postalCode": "04357"
27 }],
28 "metadata": {
29 "createdAt": "2019-10-30T17:22:10.299Z",
30 "updatedAt": "2019-11-13T20:14:49.458Z"
31 }
32}}

Contact Deleted Webhook

Sent when a contact is deleted

Authorization

This API requires an authorization header - pass the access token from the OAuth installation flow.

Permissions

The API requires CONTACTS.VIEW

Event Body

The event's data is received as a JSON Web Token (JWT). Make sure to verify that the data was received by Wix - read more about it in the Webhooks article.

Payload

NAME
TYPE
DESCRIPTION
contactId

string

ID of deleted Contact

Was this helpful?

The data payload will include the following as an encoded JWT:

Event Body

json

1{
2 "data": {
3 "eventType": "<event-type>",
4 "instanceId": "<app-instance-id>",
5 "data": "<stringified-JSON>"
6 }
7}

The parsed data will include:

Sample Data

json

1
2{"contactId": "8046df3c-7575-4098-a5ab-c91ad8f33c47"}
)}