Clients

Definitions of the types and format of the data used in the endpoints can be found at the bottom of the page.

Endpoints

Get Clients

GET https://cubicl.io/api/v1/crm/customers

Gets clients matching the search criteria.

Query Parameters

NameTypeDescription

name

string

Text to be searched in client name.

A match will occur only if a word in the client name starts with the given search text.

Search is case insensitive.

email

string

Text to be searched in client or contact mail addresses.

Search is case insensitive.

includeAllFields

string

true to get all client fields.

false to get only name.

Default is false.

skip

number

Default is 0.

limit

number

Default is 10.

Client[]

Get Client By Id

GET https://cubicl.io/api/v1/crm/customers/:id

Path Parameters

NameTypeDescription

id*

string

Client ID

Client

Create Client

POST https://cubicl.io/api/v1/crm/customers

Check the Client type definition below for field descriptions.

Request Body

NameTypeDescription

name*

string

fullname

string

email

string

phone

string

contacts

Contact[]

customFields

object

portalCustomerManagerIds

string[]

Client

Update Client

PUT https://cubicl.io/api/v1/crm/customers/:id

Check the Client type definition below for field descriptions.

Request Body

NameTypeDescription

name*

string

fullname

string

email

string

phone

string

contacts

Contact[]

customFields

object

portalCustomerManagerIds

string[]

Client

Delete Client

DELETE https://cubicl.io/api/v1/crm/customers/:id

Data

Clients

type Client = {
    _id: string;
    name: string; // A short name shown in UI and used for search
    phone: string;
    email: string;
    fullname: string;
    // People working at this client you are in contact with
    contacts: Contact[];
    // An object where keys are custom field ids and values are field values
    // customFields can be null
    customFields: {
        [fieldId: string]: string | null
    } | null;
    // List of user ids who get notifications for activities from portal users
    // of this client
    portalCustomerManagerIds: string[];
    createdAt: number;
}

Contacts

type Contact = {
    name: string;
    position: string;
    phone: string;
    email: string;
}

Last updated