Skip to Content
My App
Api

Contact

Full create / read / update / delete over your contacts and leads, including search by number, tags and custom attributes.

GET
/contacts

Authorization

http
headerAuthorizationBearer <token>

Response Body

application/json
  1. response
data*array<array<unknown>>
meta*
Example Request
curl -X GET 'https://aexrux.com/api/v1/contacts'
Example Response200
{  "data": [    [      null    ]  ],  "meta": {    "page": {},    "per_page": {},    "total": 0,    "last_page": 0  }}
POST
/contacts

Authorization

http
headerAuthorizationBearer <token>

Request Body

application/json
  1. body

Create a contact in the current workspace. Scramble reads these rules to document the request body. Mirrors the validation in the existing ContactsController::store.

name?|

Contact's full display name. Required when first_name is omitted.

Lengthlength <= 191
first_name?|

Optional name parts. Combined into name when name is blank.

Lengthlength <= 191
middle_name?|
Lengthlength <= 191
last_name?|
Lengthlength <= 191
title?|

Optional salutation/title (e.g. Mr, Dr).

Lengthlength <= 50
phone*string

Phone number in international format (digits, E.164). Required.

Lengthlength <= 32
country_code?|

Country dial code (e.g. +91). Prefixed onto the phone if missing.

Lengthlength <= 10
email?|

Optional email address.

Formatemail
Lengthlength <= 191
language?|

Optional preferred language / locale.

Lengthlength <= 80
address?|

Optional postal address.

Lengthlength <= 1000
note?|

Optional free-text note attached to the contact.

Lengthlength <= 2000
attributes?array<string>|

Free-form key/value attributes stored against the contact.

is_unsubscribed?|

Whether the contact has opted out of messages. Defaults to false.

group_ids?array<>|

Group ids the contact belongs to. Each must exist.

Response Body

application/json
  1. response
data*array<unknown>
meta*string
Example Request
curl -X POST 'https://aexrux.com/api/v1/contacts' \  -H 'Content-Type: application/json' \  -d '{  "phone": "string"}'
Example Response
{  "data": [    null  ],  "meta": "string"}
GET
/contacts/{id}

Authorization

http
headerAuthorizationBearer <token>

Path Parameters

id*integer

Response Body

application/json
  1. response
data*array<unknown>
meta*string
Example Request
curl -X GET 'https://aexrux.com/api/v1/contacts/0'
Example Response
{  "data": [    null  ],  "meta": "string"}
DELETE
/contacts/{id}

Authorization

http
headerAuthorizationBearer <token>

Path Parameters

id*integer

Response Body

application/json
  1. response
data*
meta*string
Example Request
curl -X DELETE 'https://aexrux.com/api/v1/contacts/0'
Example Response
{  "data": {    "id": 0,    "deleted": true  },  "meta": "string"}
PUT
/contacts/{id}

Authorization

http
headerAuthorizationBearer <token>

Path Parameters

id*integer

Request Body

application/json
  1. body

Update an existing contact in the current workspace. Every field is optional — only the keys present in the request body are changed. Scramble reads these rules to document the request body.

name?|

Contact's full display name.

Lengthlength <= 191
first_name?|

Optional name parts.

Lengthlength <= 191
middle_name?|
Lengthlength <= 191
last_name?|
Lengthlength <= 191
title?|

Optional salutation/title (e.g. Mr, Dr).

Lengthlength <= 50
phone?|

Phone number in international format (digits, E.164).

Lengthlength <= 32
country_code?|

Country dial code (e.g. +91). Prefixed onto the phone if missing.

Lengthlength <= 10
email?|

Email address.

Formatemail
Lengthlength <= 191
language?|

Preferred language / locale.

Lengthlength <= 80
address?|

Postal address.

Lengthlength <= 1000
note?|

Free-text note attached to the contact.

Lengthlength <= 2000
attributes?array<string>|

Free-form key/value attributes stored against the contact.

is_unsubscribed?|

Whether the contact has opted out of messages.

group_ids?array<>|

Group ids the contact belongs to (replaces the existing set).

Response Body

application/json
  1. response
data*array<unknown>
meta*string
Example Request
curl -X PUT 'https://aexrux.com/api/v1/contacts/0' \  -H 'Content-Type: application/json' \  -d '{}'
Example Response
{  "data": [    null  ],  "meta": "string"}