-
URL:
https://api.nxcloud.com/saas/cdp/openapi/customers/query
-
Method:
POST
-
Content-Type:
application/json
-
Authentication Required: Yes
Header Parameters:
Parameter Name |
Type |
Required |
Example Value |
Description |
accessKey |
String |
Yes |
fme2na3kdi3ki |
User identity token |
ts |
String |
Yes |
1655710885431 |
Timestamp of the current request (in milliseconds). The maximum time difference allowed by NX service is 60 seconds. |
bizType |
String |
Yes |
2 |
WhatsApp business type, fixed value: "2" |
action |
String |
Yes |
mt |
WhatsApp business action, fixed value: "mt" |
sign |
String |
Yes |
6e9506557d1f289501d333ee2c365826 |
API input parameter signature, see common conventions |
Parameter Name |
Type |
Required |
Example Value |
Description |
tenant_id |
Integer |
Yes |
123 |
Tenant ID |
app_key |
String |
Yes |
46oKF=os |
App key |
start_time |
String |
No |
2024-05-07 00:00:00 |
Start time |
end_time |
String |
No |
2024-05-08 00:00:00 |
End time |
tags |
List
|
No |
[1, 2, 3] |
Tag IDs |
source_type |
Integer |
No |
1 |
Source: 0: Unknown, 1: New, 2: Excel Import, 3: Client Initiated, 4: SMS Broadcast, 5: Voice Broadcast, 6: Third-party API, 7: Callbot, 8: Client Initiated - Call Center, 9: Email Channel, 10: Form Add, 11: Client Initiated, 12: Client Initiated - Viber, 13: Client Initiated - Messenger, 14: Client Initiated - Instagram, 15: Client Initiated - Line |
name |
String |
No |
test |
First name |
tags_logic_type |
String |
No |
and |
Logic type for tag list: "and" (AND), "or" (OR), or an empty string |
source_channel_key |
String |
No |
xx |
Source channel |
sms_phone |
String |
No |
8618593272678 |
Phone number |
whatsApp_phone |
String |
No |
8618593272678 |
WhatsApp phone number |
email |
String |
No |
[email protected] |
Email address |
viber_phone |
String |
No |
8618593272678 |
Viber phone number |
after |
Long |
No |
693324 |
Cursor for pagination (forward) |
before |
Long |
No |
693324 |
Cursor for pagination (backward) |
limit |
Long |
Yes |
25 |
Page size, range 1-50 |
Parameter Name |
Type |
Required |
Example Value |
Description |
after |
Long |
Yes |
- |
Cursor pointing to the end of the current page of returned data |
before |
Long |
Yes |
- |
Cursor pointing to the start of the current page of returned data |
previous |
Long |
No |
- |
Start cursor for the previous page. If null , the first page data is shown |
next |
Long |
No |
- |
Start cursor for the next page. If null , the last page data is shown |
Parameter Name |
Type |
Required |
Example Value |
Description |
id |
Long |
Yes |
1021110718827683840 |
Customer ID, also used as the pagination cursor |
first_name |
String |
No |
simon |
First name |
last_name |
String |
No |
kang |
Last name |
full_name |
String |
No |
simon kang |
Full name |
sms_phone |
String |
No |
8618593271111 |
SMS phone number |
whatsApp_phone |
String |
No |
8618593271111 |
WhatsApp phone number |
viber_phone |
String |
No |
8618593271111 |
Viber phone number |
line |
String |
No |
xxx |
Line ID |
messenger |
String |
No |
xxx |
Messenger ID |
instagram |
String |
No |
xxx |
Instagram ID |
email |
String |
No |
xxx |
Email address |
country |
String |
No |
CN |
Country |
birthday |
String |
No |
2024-08-01 |
Birthday |
remark |
String |
No |
xxx |
Remarks |
source_type |
Integer |
No |
1 |
Source type (see list of source values above) |
source_channel_key |
String |
No |
xx |
Source channel key |
gender |
Integer |
No |
0 |
Gender (0: Female, 1: Male) |
created_at |
String |
Yes |
2024-07-19T17:29:27 |
Creation time |
updated_at |
String |
Yes |
2024-07-19T17:29:27 |
Last updated time |
status |
Integer |
No |
1 |
Status (0: Disabled, 1: Enabled) |
whatApp_subscribe |
String |
No |
1 |
WhatsApp subscription status |
sms_subscribe |
String |
No |
1 |
SMS subscription status |
customize_field |
String |
No |
1 |
Custom field |
tenant_id |
Long |
Yes |
1 |
Tenant ID |
weight |
Long |
No |
1 |
Customer weight level |
Request body (application/json
) parameters:
{
"tenant_id": 123,
"limit": 5,
"after": 1022100838976413697,
"whatsApp_phone": "861360301975912",
"app_key": "8eos"
}
Parameter Name |
Type |
Description |
code |
Integer |
Result code |
data |
JsonObject |
Response result |
message |
String |
Response message |
traceId |
String |
Trace ID for tracking the request |
{
"code": 0,
"message": null,
"traceId": "44988d9de672422b920182d6960de0a0",
"data": {
"paging": {
"after": 1021110718827683840,
"before": 1021110718827683840,
"previous": null,
"next": null
},
"customer_list": [
{
"id": 1021110718827683840,
"first_name": "Simon",
"last_name": null,
"full_name": "Simon",
"sms_phone": null,
"whatsApp_phone": "861360301975912",
"viber_phone": null,
"line": null,
"messenger": null,
"instagram": null,
"email": null,
"country": "CN",
"birthday": null,
"remark": null,
"source_type": 3,
"source_channel_key": "18506008399",
"gender": null,
"created_at": "2024-07-19T17:29:27",
"status": 1,
"updated_at": "2024-07-30T17:56:39",
"tags": [
{
"id": 27237,
"user_id": 195,
"tenant_id": 123,
"group_id":
123,
"type": 0,
"value": "Test Tag",
"created_at": "2024-06-19T10:56:08",
"updated_at": "2024-06-19T10:56:08"
}
]
}
]
}
}