getCrmClients
The method allows you to retrieve a list of CRM clients. The client list can be limited using the filters described in the method parameters. A maximum of 100 clients are returned at a time. To retrieve full client details (including notes), use the getCrmClientData method.
Input parameters
Output data:
A sample request in PHP:
| page | int | Results page number (100 results per page, numbered from 1). |
| filter_crm_client_id | int | Filter by exact CRM client ID. |
| filter_email | varchar(220) | Filter by email (partial match). |
| filter_phone | varchar(156) | Filter by phone (partial match). |
| filter_login | varchar(156) | Filter by login (partial match). |
| filter_invoice_company | varchar(500) | Filter by invoice company name (partial match). |
| filter_invoice_tax_id | varchar(50) | Filter by invoice tax ID (partial match). |
| filter_invoice_fullname | varchar(500) | Filter by invoice full name (partial match). |
| filter_status_id | int | Filter by exact status ID. |
Output data
The method returns the data in JSON format.
| status | varchar(30) | SUCCESS - request executed correctly ERROR - an error occurred during an API request. Error details will be described in 2 additional returned fields: error_message and error_code |
| clients | array | An array of CRM clients containing the fields listed below. The notes field is not included in the list - use getCrmClientData method to retrieve full client details. |
| | - crm_client_id | int | CRM client ID. |
| | - status_id | int | Client status ID. |
| | - star | int | Star type. Values from 0 to 5. 0 means no star. |
| | - login | text | Client login. |
| | - phone | text | Client phone. |
| text | Client email. | |
| | - contractor_id | int | Base Connect contractor ID associated with the client (0 if none). The list can be retrieved with getConnectIntegrationContractors method. |
| | - invoice_company | text | Invoice company name. |
| | - invoice_fullname | text | Invoice full name. |
| | - invoice_address | text | Invoice address. |
| | - invoice_postcode | text | Invoice postcode. |
| | - invoice_city | text | Invoice city. |
| | - invoice_state | text | Invoice state/province. |
| | - invoice_country_code | text | Invoice country code. |
| | - invoice_tax_id | text | Invoice tax ID. |
| | - delivery_company | text | Delivery company name. |
| | - delivery_fullname | text | Delivery full name. |
| | - delivery_address | text | Delivery address. |
| | - delivery_postcode | text | Delivery postcode. |
| | - delivery_city | text | Delivery city. |
| | - delivery_state | text | Delivery state/province. |
| | - delivery_country_code | text | Delivery country code. |
Sample
Input data:Output data:
A sample request in PHP: