List Contacts
View all contacts with search and pagination support
Reading time: 1 minute
List Contacts
View all contacts with search and pagination support.
GET
{{base_url}}/contactsQuery Parameters
| Parameter | Type | Required | Description | Default |
|---|---|---|---|---|
phone_number_id | string | Yes | Phone number ID of the sender | - |
page | integer | No | Page number | 1 |
limit | integer | No | Number of results per page | 10 |
searchTerm | string | No | Search by name or phone number | - |
Tip: Use the searchTerm parameter for quick search by name or phone number.
Example Request
Example Requestbash
curl -X GET "{{base_url}}/contacts?page=1&limit=10&phone_number_id=123456&searchTerm=Ahmed" \
-H "Accept: application/json" \
-H "X-Awal-Signature-256: sha256=abc..." \
-H "X-Timestamp: 1704124800" \
-H "X-Domain: your-workspace" \
-H "X-Client-ID: your-client-id"Example Response
Response200 OK
{
"status": true,
"data": [
{
"id": 1,
"name": "Ahmed Mohammed",
"phone": "96650000000",
"email": "ahmed@example.com",
"branch_id": 1,
"contact_group_id": 1,
"is_favorite": false,
"avatar": "https://example.com/avatar.jpg",
"created_at": "2024-01-15T10:30:00Z"
}
],
"meta": {
"current_page": 1,
"per_page": 10,
"total": 50,
"last_page": 5
}
}Related
ā Back to Contacts
View Guide