List contacts

Clients and suppliers with name, tax ID, email and phone.

GET https://cotlet.dev/api/v1/alegra/contacts

read

Lists contacts from the Contactos menu. Search matches the name or the identification number. A contact is a client, a supplier or both. Use contact_id from each item for create_invoice and list_invoices. Pass next_cursor back as cursor for the next page.

Parameters

Parameters: list_contacts
NameTypeDescription
query string string Part of the name or the identification number.
kind enum enum client or supplier. Default: both.
limit integer integer Contacts per page.
cursor string string Next page cursor from the previous call.

Request

cURL
curl https://cotlet.dev/api/v1/alegra/contacts \
  -H "Authorization: Bearer $COTLET_API_KEY"
Python
result = client.call("alegra", "list_contacts")
Node.js
const result = await cotlet.call('alegra', 'list_contacts');
CLI
cotlet call alegra list_contacts

Example response

JSON

{
  "contacts": [
    {
      "contact_id": "20",
      "name": "Northwind Studio",
      "identification": "900123456",
      "kind": "client",
      "email": "accounts@northwind.example",
      "mobile": "+57 300 555 0142",
      "city": "Bogota"
    }
  ],
  "next_cursor": null
}

Sign in once. Your agent does the rest.

Sign up and add the apps you need. Free 7-day trial with 2,000 credits, no card needed.