Endpoint
/v1/contact-groups/:id/contacts
Bearer token avec votre Secret Key (format: Bearer sk_...)
URL Parameters
L’identifiant de la liste
Query Parameters
Nombre de contacts par page
Position de départ pour la pagination
Exemples de requêtes
curl -X GET "https://api.wachap.com/v1/contact-groups/65f1234567890abcdef12345/contacts?limit=20&offset=0" \
-H "Authorization: Bearer VOTRE_CLE_SECRETE"
Exemple de réponse
{
"success": true,
"listId": "65f1234567890abcdef12345",
"contacts": [
{
"contactIndex": 0,
"phone": "+22962861571",
"name": "John Doe",
"city": "Abidjan",
"email": "[email protected]"
},
{
"contactIndex": 1,
"phone": "+33612345678",
"name": "Marie Dupont",
"city": "Paris",
"email": "[email protected]"
}
],
"total": 150,
"limit": 20,
"offset": 0
}
Pour naviguer à travers une grande liste :
- Page 1 (0-49):
?limit=50&offset=0
- Page 2 (50-99):
?limit=50&offset=50
- Page 3 (100-149):
?limit=50&offset=100
Codes d’erreur
| Code | Description |
|---|
401 | INVALID_SECRET_KEY - Clé secrète invalide |
404 | Liste non trouvée |
500 | GET_CONTACTS_ERROR - Erreur serveur |
Bearer authentication header of the form Bearer <token>, where <token> is your auth token.