Crear un nuevo contacto manualmente.
curl -X POST https://app.horneross.com/api/contacts \ -H "Authorization: Bearer sk_live_xxx" \ -H "Content-Type: application/json" \ -d '{ "email": "nuevo@ejemplo.com", "firstName": "Carlos", "lastName": "López", "phoneNumber": "+5491198765432" }'
{ "id": "contact_new789", "email": "nuevo@ejemplo.com", "phoneNumber": "+5491198765432", "firstName": "Carlos", "lastName": "López", "instagramId": null, "organizationId": "org_xyz", "createdAt": "2024-01-21T16:00:00Z", "updatedAt": "2024-01-21T16:00:00Z" }
POST /api/contacts
Bearer sk_live_xxx
application/json
+5491123456789
const response = await fetch('https://app.horneross.com/api/contacts', { method: 'POST', headers: { 'Authorization': 'Bearer sk_live_xxx', 'Content-Type': 'application/json', }, body: JSON.stringify({ email: 'cliente@ejemplo.com', firstName: 'Ana', conversationId: 'conv_xyz123', // Vincular a conversación }), });
Was this page helpful?