Este endpoint realiza la creación de un cliente
HTTP Request
POST https://admin.cmmshere.com/api/v1/clients
Body / Form Data
Provee información para el nuevo cliente
| Parámetro | Tipo | Requerido | Observaciones |
|---|---|---|---|
| tipo_registro | String | true | Indica el tipo de cliente a registrarse: C: Cliente M: Cliente proveedor de materiales S: Cliente proveedor de servicios |
| nombre_comercial | String | true | Debe ser único |
| nombre_legal | String | false | |
| tipo_identificacion | String | true | Tipo de documento: NIT, CI, DNI, etc. |
| nro_identificacion | String | true | Debe ser único |
| nivel_cliente | String | false | Un número del 1 al 5, nivel de importancia o ranking del cliente |
| email_corporativo | String | false | |
| telefono_corporativo | String | false | |
| helpdesk_dominio | String | false | |
| helpdesk_email | String | false | Según habilitación |
| latitud | Number | false | |
| longitud | Number | false | |
| caracteristicas | String | false | Características o información adicional |
| direccion | String | true | Máximo 300 caracteres |
| area | String | false | Área (Debe ser un ID de la paramétrica áreas de los clientes) |
| ciudad | String | true | |
| pais | String | true | |
| fee_trabajo_presupuestado | Numeric | false | Valor porcentual de Fee por trabajo presupuestado |
| father_id | Int | false | ID de cliente padre |
Campos para contacto
| Parámetro | Tipo | Requerido | Observaciones |
|---|---|---|---|
| nombre | String | true | |
| cargo | String | true | |
| dpto | String | false | |
| telf | String | true | |
| celular | String | false | |
| String | True | ||
| ciudad_contacto | String | false | |
| observacion | String | false | |
| contacto_favorito | String | false |
Campos adicionales si tipo_registro es 'C'
| Parámetro | Tipo | Requerido | Observaciones |
|---|---|---|---|
| tipo_cliente_id | Int | true | ID de tipo cliente al que corresponderá el nuevo cliente |
| area_trabajo_ids | Array | true | Listado de ID's de las áreas de trabajo a vincularse |
| asignar_todas_las_areas | Int | false | Indica si se asociará con todas las áreas de trabajo válidas: 1: Sí 0: No |
Campos adicionales si tipo_registro es 'S'
| Parámetro | Tipo | Requerido | Observaciones |
|---|---|---|---|
| tipo_servicio_id | Int | true | ID de tipo servicio al que corresponderá el nuevo cliente proveedor de servicios |
| area_trabajo_ids | Array | true | Listado de ID's de las áreas de trabajo a vincularse |
| asignar_todas_las_areas | Int | false | Indica si se asociará con todas las áreas de trabajo válidas: 1: Sí 0: No |
Campos adicionales si tipo_registro es 'M'
| Parámetro | Tipo | Requerido | Observaciones |
|---|---|---|---|
| tipo_material_id | Int | true | ID de tipo material al que corresponderá el nuevo cliente proveedor de materiales |
Ejemplo de petición
curl --location 'https://admin.cmmshere.com/api/v1/clients' \
--header 'Authorization: Bearer 1046|unbbDW7pddViEjpz1EChW9sIdYykKjEU7DbhCPne' \
--header 'Cookie: XSRF-TOKEN=eyJpdiI6IlpRcXJiUVV4TTJsVnhXaWdVdjNsbUE9PSIsInZhbHVlIjoiRVJRc3lWcDk2UWtzYUFmeDBqd01SWGFnUTMrQ2RPcm9vTC9XV3dqTURJZ3M3MFhKYVNXK1JvNlpDUStjc3hxUitGZHBSQ1NoZU85d2JRV3R4b3hIZzZwcTZtcWtNZ0tzUFo2N0dPTGhIQllEczJ5VHM1cjBuc2dRSTZUM0dHc2IiLCJtYWMiOiIzZmRmN2ViMjk0MmM3OGYxZTBhMWRjM2NjZTkzYjhjM2JjNWEyMjFlNzA4Zjc3MTZkOWI3Yzg1NjBkODc5YTk0In0%3D; laravel_session=eyJpdiI6ImJNdnAzRTl4OEQvVWJtOEVRNHBGWlE9PSIsInZhbHVlIjoiNlhQUGFsbk9vYnk5OFE2Q1ZKR0ZGeWo4QXl0WGZvVXgyTnVPQjVnVkVRRzFrRUxENW9hNWl0SHUzVVJPSlovZTl3NzZyZzMyQ3JJTmY0QlQxNlhaeVAyaEFWYkVNOU1uN1Q1T1QxaDJPWDd5cWNjc3d3YldIQWg2UU9KYm0xODMiLCJtYWMiOiIzZTliODI5ODI4YmRkODZiNjk2ZTFiZmE3YjRhZmVkNjRlYWU1ZWQzMjcyODQ5YjkxYTFkM2RiYTA0OGI5MDE4In0%3D' \
--form 'nombre_legal="KashorakoKotoba LLCC."' \
--form 'nombre_comercial="Prueba kotoba example"' \
--form 'email_corporativo="[email protected]"' \
--form 'caracteristicas="Ejemplo de caracteristicas"' \
--form 'tipo_registro="C"' \
--form 'tipo_identificacion="Num. Patente"' \
--form 'nro_identificacion="3341345"' \
--form 'direccion="Av. Litoral"' \
--form 'nombre="Aranibal Warnes"' \
--form 'cargo="Software Developer"' \
--form 'telf="2521653"' \
--form 'email="[email protected]"' \
--form 'tipo_cliente_id="13"' \
--form 'area_trabajo_ids[]="15"' \
--form 'area_trabajo_ids[]="21"'
La petición de arriba devuelve un JSON estructurado de la siguiente manera
{
"success": true,
"code": 200,
"result": {
"id": 8056,
"cod": "C0001785",
"registration_type": "C",
"com_name": "Prueba kotoba example",
"leg_name": "KashorakoKotoba LLCC.",
"info": "Ejemplo de caracteristicas",
"doc_type": "Num. Patente",
"id_number": "3341345",
"client_type_id": "13",
"area_id": null,
"address": "Av. Litoral",
"country": null,
"city": null,
"client_level": null,
"creator_id": 21,
"status": "1",
"email": "[email protected]",
"helpdesk_domain": null,
"lat": null,
"lng": null,
"phone": null,
"father_id": null,
"fee_quoted_work": null,
"created_at": "2026-06-24T15:30:13.000000Z"
}
}