Empresas
Las organizaciones a las que pertenecen los contactos. Agrupan personas; la identidad legal vive en el contacto que representa a la empresa.
Descarga la proyección completa de la API pública: openapi.json.
Buscar, crear y fusionar contactos explica este recurso en prosa, con ejemplos ejecutables.
| Método | Ruta | Qué hace |
|---|---|---|
GET | /companies | List the workspace’s companies |
POST | /companies | Create a company |
DELETE | /companies/{id} | Delete a company |
GET | /companies/{id} | Get a company |
PUT | /companies/{id} | Update a company |
GET /companies
List the workspace’s companies
Every company in alphabetical order, each with a contact_count — how many LIVE contacts name it (an archived or merged contact is not counted). q narrows the LIST by name; it does not narrow the counts, which describe the company rather than the search.
This list does not page and carries no meta: a workspace has companies, not hundreds of thousands of them. If that stops being true for a customer, it is a real change here rather than a limit they can guess at.
| Parámetro | En | Tipo | Obligatorio | Restricciones |
|---|---|---|---|---|
q | query | string | no | máx. 200 |
curl https://api.vitrinadev.com/api/v1/companies \
-H "Authorization: Bearer $VITRINA_KEY"Ejemplo de respuesta (200)
{
"data": [
{
"id": "15151515-0000-4000-8000-000000000001",
"tenant_id": "a1a1a1a1-0000-4000-8000-000000000001",
"name": "Constructora Andes SpA",
"domain": "andes.cl",
"industry": "Construcción",
"size": "51-200",
"website": "https://andes.cl",
"phone": "+56223456789",
"notes": "Cuenta corporativa — factura a fin de mes.",
"metadata": {},
"created_at": "2026-09-20T09:12:00.000Z",
"updated_at": "2026-09-20T09:12:00.000Z",
"contact_count": 7
}
]
}Responde: 200 · 400 · 401 · 403 · 404 · 409 · 429
POST /companies
Create a company
Only name is required. Nothing here is unique or validated against anything: two companies may share a domain, and creating the same name twice creates two rows — there is no dedup and no merge for companies, unlike contacts.
metadata is a free object an integration can use to keep its own ids and fields; it is stored verbatim and never interpreted.
Creating a company links nobody to it. Attach contacts afterwards with PATCH /contacts/\{id\} and company_id.
Cuerpo
| Campo | Tipo | Obligatorio | Restricciones |
|---|---|---|---|
name | string | sí | mín. 1, máx. 300 |
domain | string | null | — | máx. 255 |
industry | string | null | — | máx. 200 |
size | string | null | — | máx. 100 |
website | string | null | — | máx. 500 |
phone | string | null | — | máx. 100 |
notes | string | null | — | máx. 5000 |
metadata | object | — |
curl -X POST https://api.vitrinadev.com/api/v1/companies \
-H "Authorization: Bearer $VITRINA_KEY" \
-H "Content-Type: application/json" \
-d '{
"name": "Constructora Andes SpA",
"domain": "andes.cl",
"industry": "Construcción",
"size": "51-200",
"website": "https://andes.cl",
"phone": "+56223456789"
}'Ejemplo de respuesta (201)
{
"data": {
"id": "15151515-0000-4000-8000-000000000001",
"tenant_id": "a1a1a1a1-0000-4000-8000-000000000001",
"name": "Constructora Andes SpA",
"domain": "andes.cl",
"industry": "Construcción",
"size": "51-200",
"website": "https://andes.cl",
"phone": "+56223456789",
"notes": "Cuenta corporativa — factura a fin de mes.",
"metadata": {},
"created_at": "2026-09-20T09:12:00.000Z",
"updated_at": "2026-09-20T09:12:00.000Z"
}
}Responde: 201 · 400 · 401 · 403 · 404 · 409 · 429
DELETE /companies/{id}
Delete a company
⚠ Permanent — there is no archive for a company. The contacts survive: contact.company_id is set to null, so the people stay and only the grouping is gone. Nothing else references a company, so nothing else breaks.
Deleting a company from another workspace is a 404.
| Parámetro | En | Tipo | Obligatorio | Restricciones |
|---|---|---|---|---|
id | path | uuid | sí |
curl -X DELETE https://api.vitrinadev.com/api/v1/companies/<id> \
-H "Authorization: Bearer $VITRINA_KEY"Responde: 204 · 400 · 401 · 403 · 404 · 409 · 429
GET /companies/{id}
Get a company
One company by uuid. A company from another workspace is a 404, never a 403 — the API does not confirm that an id it will not serve exists.
The single read does not carry contact_count; the list does. To get the people, ask GET /contacts/search?company_id=<uuid>.
| Parámetro | En | Tipo | Obligatorio | Restricciones |
|---|---|---|---|---|
id | path | uuid | sí |
curl https://api.vitrinadev.com/api/v1/companies/<id> \
-H "Authorization: Bearer $VITRINA_KEY"Ejemplo de respuesta (200)
{
"data": {
"id": "15151515-0000-4000-8000-000000000001",
"tenant_id": "a1a1a1a1-0000-4000-8000-000000000001",
"name": "Constructora Andes SpA",
"domain": "andes.cl",
"industry": "Construcción",
"size": "51-200",
"website": "https://andes.cl",
"phone": "+56223456789",
"notes": "Cuenta corporativa — factura a fin de mes.",
"metadata": {},
"created_at": "2026-09-20T09:12:00.000Z",
"updated_at": "2026-09-20T09:12:00.000Z"
}
}Responde: 200 · 400 · 401 · 403 · 404 · 409 · 429
PUT /companies/{id}
Update a company
A PUT that behaves as a PATCH: send only the fields you are changing — at least one is required, and everything you leave out is kept. null clears a nullable field.
metadata is REPLACED as a whole when you send it, not merged key by key. Read it, change what you need, and write the complete object back.
| Parámetro | En | Tipo | Obligatorio | Restricciones |
|---|---|---|---|---|
id | path | uuid | sí |
Cuerpo
| Campo | Tipo | Obligatorio | Restricciones |
|---|---|---|---|
name | string | — | mín. 1, máx. 300 |
domain | string | null | — | máx. 255 |
industry | string | null | — | máx. 200 |
size | string | null | — | máx. 100 |
website | string | null | — | máx. 500 |
phone | string | null | — | máx. 100 |
notes | string | null | — | máx. 5000 |
metadata | object | — |
curl -X PUT https://api.vitrinadev.com/api/v1/companies/<id> \
-H "Authorization: Bearer $VITRINA_KEY" \
-H "Content-Type: application/json" \
-d '{
"industry": "Construcción e inmobiliaria",
"size": "201-500"
}'Ejemplo de respuesta (200)
{
"data": {
"id": "15151515-0000-4000-8000-000000000001",
"tenant_id": "a1a1a1a1-0000-4000-8000-000000000001",
"name": "Constructora Andes SpA",
"domain": "andes.cl",
"industry": "Construcción e inmobiliaria",
"size": "201-500",
"website": "https://andes.cl",
"phone": "+56223456789",
"notes": "Cuenta corporativa — factura a fin de mes.",
"metadata": {},
"created_at": "2026-09-20T09:12:00.000Z",
"updated_at": "2026-09-22T11:30:18.000Z"
}
}Responde: 200 · 400 · 401 · 403 · 404 · 409 · 429
Feed bancario de la clínica
Los movimientos bancarios de la clínica, desde correo, Fintoc o la API del banco, normalizados a un mismo formato para conciliar la caja.
Consignaciones
El contrato bajo el cual una automotora vende el auto de otra persona: crear, editar, devolver y vender con su liquidación.