Clientes
Maneja todas las operaciones CRUD para los clientes en la API.
Endpoints
Section titled “Endpoints”Obtener todos los clientes
Section titled “Obtener todos los clientes”GET /customers
[ { "id": "5499465c-2d73-485d-ae52-b642f1b8d3ce", "deletedAt": null, "createdAt": "2025-06-19T21:04:48.538Z", "updatedAt": "2025-06-19T21:04:48.538Z", "tenantId": "dbb93ac6-e551-491d-8378-b7cf6c0f389f", "identification": "9999999999", "type": "05", "name": "Cliente Final", "phone": "9999999999", "address": "Sin dirección", "taxpayerId": "e1466ac6-d6d6-4e0f-ae84-312243b7905d" }]
Obtener un cliente por ID
Section titled “Obtener un cliente por ID”GET /customers/{id}
Parámetros de URL:
id
: ID del cliente a buscar
{ "id": "3d192eea-4c2c-4dd5-b853-c93f997446b5", "deletedAt": null, "createdAt": "2025-06-21T01:56:45.566Z", "updatedAt": "2025-06-21T01:56:45.566Z", "tenantId": "dbb93ac6-e551-491d-8378-b7cf6c0f389f", "identification": "09254987630", "type": "04", "name": "Juan Pérez", "phone": "0987654321", "address": "Av. Siempre Viva 742", "taxpayerId": "840f6f18-1a7b-450c-8c0b-542d60417c87"}
Crear un nuevo cliente
Section titled “Crear un nuevo cliente”POST /customers
{ "identification": "09254987630", "type": "04", "name": "Juan Pérez", "phone": "0987654321", "address": "Av. Siempre Viva 742", "taxpayerId": "840f6f18-1a7b-450c-8c0b-542d60417c87"}
{ "tenantId": "dbb93ac6-e551-491d-8378-b7cf6c0f389f", "identification": "09254987630", "type": "04", "name": "Juan Pérez", "phone": "0987654321", "address": "Av. Siempre Viva 742", "taxpayerId": "840f6f18-1a7b-450c-8c0b-542d60417c87", "id": "3d192eea-4c2c-4dd5-b853-c93f997446b5", "deletedAt": null, "createdAt": "2025-06-21T01:56:45.566Z", "updatedAt": "2025-06-21T01:56:45.566Z"}
Actualizar un cliente existente
Section titled “Actualizar un cliente existente”PUT /customers/{id}
Parámetros de URL:
id
: ID del cliente a actualizar
{ "identification": "1234567890", "type": "05", "name": "Juana Pérez", "phone": "0987654321", "address": "Av. Quito 742", "taxpayerId": "840f6f18-1a7b-450c-8c0b-542d60417c87"}
{ "id": "9b81d94c-803c-460b-b545-232035b7949b", "deletedAt": null, "createdAt": "2025-06-21T01:59:19.927Z", "updatedAt": "2025-06-21T02:01:52.275Z", "tenantId": "dbb93ac6-e551-491d-8378-b7cf6c0f389f", "identification": "1234567890", "type": "05", "name": "Juana Pérez", "phone": "0987654321", "address": "Av. Quito 742", "taxpayerId": "840f6f18-1a7b-450c-8c0b-542d60417c87", "invoices": []}
Eliminar un cliente
Section titled “Eliminar un cliente”DELETE /customers/{id}
Parámetros de URL:
id
: ID del cliente a eliminar
No content