Vistas del inbox
Filtros guardados de la bandeja, del equipo o personales, por atributos de la conversación; una vista del equipo puede sacar sus conversaciones de Esperando respuesta.
Descarga la proyección completa de la API pública: openapi.json.
Responder hilos y resolver tickets explica este recurso en prosa, con ejemplos ejecutables.
| Método | Ruta | Qué hace |
|---|---|---|
GET | /inbox-views | List the inbox views you see, with their counts |
POST | /inbox-views | Create an inbox view |
DELETE | /inbox-views/{id} | Delete an inbox view |
GET | /inbox-views/{id} | Fetch one inbox view |
PATCH | /inbox-views/{id} | Update an inbox view |
GET | /inbox-views/attribute-keys | Conversation-attribute keys and their common values |
POST | /inbox-views/reorder | Reorder inbox views |
GET /inbox-views
List the inbox views you see, with their counts
The workspace views (position order), then your personal views. A view: \{ id, name, scope: workspace|personal, owner_user_id, filters, exclude_from_waiting, position, created_by, created_at, updated_at, editable \} — editable says whether the caller may change it.
Each view carries count — exactly the total of GET /conversations?viewId=<id> for you (your row visibility applies) — and waiting_count, how many of its matches have a customer waiting on a human (the sidebar badge of a view with exclude_from_waiting). counts=false skips both.
| Parámetro | En | Tipo | Obligatorio | Restricciones |
|---|---|---|---|---|
counts | query | boolean | null | no |
curl https://api.vitrinadev.com/api/v1/inbox-views \
-H "Authorization: Bearer $VITRINA_KEY"Ejemplo de respuesta (200)
{
"data": [
{
"id": "6a1f0c7e-3b8d-4e52-9a51-0c2d7b1e9f44",
"name": "Piden 18 Pro Max",
"scope": "workspace",
"owner_user_id": null,
"filters": {
"active": true,
"attributes": [
{
"key": "*",
"op": "contains",
"value": "18 pro max"
}
]
},
"exclude_from_waiting": true,
"position": 0,
"created_by": "0b9e2f4a-8c1d-4f37-b6a2-5d3e7c9a1b20",
"created_at": "2026-11-04T12:00:00.000Z",
"updated_at": "2026-11-04T12:00:00.000Z",
"editable": true,
"count": 21,
"waiting_count": 15
}
]
}Responde: 200 · 400 · 401 · 403 · 404 · 409 · 429
POST /inbox-views
Create an inbox view
scope: personal (the default) is yours alone; scope: workspace is the whole team’s and needs routing:write (a workspace admin). filters takes the InboxViewFilters subset of GET /conversations filters and needs at least one criterion besides waiting. An attribute condition \{ key, op, value \} compares the value case- and accent-insensitively; key: "*" matches it under any attribute key (one view for modelo_buscado and handoff.reason alike). exclude_from_waiting: true («Sacar de Esperando respuesta») is refused (400) on a personal view; on a workspace view it never takes out an urgent (handoff_urgent) thread. A name already used in the same scope (case-insensitive) is a 409. At most 50 views per scope. Answers 201 with the view.
Cuerpo
| Campo | Tipo | Obligatorio | Restricciones |
|---|---|---|---|
name | string | sí | mín. 1, máx. 80 |
scope | workspace \ | personal | — |
filters | InboxViewFilters | sí | |
exclude_from_waiting | boolean | — | por defecto false |
curl -X POST https://api.vitrinadev.com/api/v1/inbox-views \
-H "Authorization: Bearer $VITRINA_KEY" \
-H "Content-Type: application/json" \
-d '{
"name": "Piden 18 Pro Max",
"scope": "workspace",
"filters": {
"active": true,
"attributes": [
{
"key": "*",
"op": "contains",
"value": "18 pro max"
}
]
},
"exclude_from_waiting": true
}'Ejemplo de respuesta (201)
{
"data": {
"id": "6a1f0c7e-3b8d-4e52-9a51-0c2d7b1e9f44",
"name": "Piden 18 Pro Max",
"scope": "workspace",
"owner_user_id": null,
"filters": {
"active": true,
"attributes": [
{
"key": "*",
"op": "contains",
"value": "18 pro max"
}
]
},
"exclude_from_waiting": true,
"position": 0,
"created_by": "0b9e2f4a-8c1d-4f37-b6a2-5d3e7c9a1b20",
"created_at": "2026-11-04T12:00:00.000Z",
"updated_at": "2026-11-04T12:00:00.000Z",
"editable": true,
"count": 21,
"waiting_count": 15
}
}Responde: 201 · 400 · 401 · 403 · 404 · 409 · 429
DELETE /inbox-views/{id}
Delete an inbox view
Deletes the view (never a conversation). A view with exclude_from_waiting puts its matches back in «Esperando respuesta». Answers 204.
| Parámetro | En | Tipo | Obligatorio | Restricciones |
|---|---|---|---|---|
id | path | uuid | sí |
curl -X DELETE https://api.vitrinadev.com/api/v1/inbox-views/<id> \
-H "Authorization: Bearer $VITRINA_KEY"Responde: 204 · 400 · 401 · 403 · 404 · 409 · 429
GET /inbox-views/{id}
Fetch one inbox view
A view: \{ id, name, scope: workspace|personal, owner_user_id, filters, exclude_from_waiting, position, created_by, created_at, updated_at, editable \} — editable says whether the caller may change it. Another member’s personal view is a 404.
| Parámetro | En | Tipo | Obligatorio | Restricciones |
|---|---|---|---|---|
id | path | uuid | sí |
curl https://api.vitrinadev.com/api/v1/inbox-views/<id> \
-H "Authorization: Bearer $VITRINA_KEY"Ejemplo de respuesta (200)
{
"data": {
"id": "6a1f0c7e-3b8d-4e52-9a51-0c2d7b1e9f44",
"name": "Piden 18 Pro Max",
"scope": "workspace",
"owner_user_id": null,
"filters": {
"active": true,
"attributes": [
{
"key": "*",
"op": "contains",
"value": "18 pro max"
}
]
},
"exclude_from_waiting": true,
"position": 0,
"created_by": "0b9e2f4a-8c1d-4f37-b6a2-5d3e7c9a1b20",
"created_at": "2026-11-04T12:00:00.000Z",
"updated_at": "2026-11-04T12:00:00.000Z",
"editable": true,
"count": 21,
"waiting_count": 15
}
}Responde: 200 · 400 · 401 · 403 · 404 · 409 · 429
PATCH /inbox-views/{id}
Update an inbox view
Any of name, filters (replaced whole), exclude_from_waiting, position. Same rules as create; the scope cannot change. Turning exclude_from_waiting off puts the matches back in «Esperando respuesta» on the next read.
| Parámetro | En | Tipo | Obligatorio | Restricciones |
|---|---|---|---|---|
id | path | uuid | sí |
Cuerpo
| Campo | Tipo | Obligatorio | Restricciones |
|---|---|---|---|
name | string | — | mín. 1, máx. 80 |
filters | InboxViewFilters | — | |
exclude_from_waiting | boolean | — | |
position | integer | — | ≥ 0, ≤ 10000 |
curl -X PATCH https://api.vitrinadev.com/api/v1/inbox-views/<id> \
-H "Authorization: Bearer $VITRINA_KEY" \
-H "Content-Type: application/json" \
-d '{
"name": "Piden 18 Pro Max (sin respuesta)",
"exclude_from_waiting": false
}'Ejemplo de respuesta (200)
{
"data": {
"id": "6a1f0c7e-3b8d-4e52-9a51-0c2d7b1e9f44",
"name": "Piden 18 Pro Max",
"scope": "workspace",
"owner_user_id": null,
"filters": {
"active": true,
"attributes": [
{
"key": "*",
"op": "contains",
"value": "18 pro max"
}
]
},
"exclude_from_waiting": true,
"position": 0,
"created_by": "0b9e2f4a-8c1d-4f37-b6a2-5d3e7c9a1b20",
"created_at": "2026-11-04T12:00:00.000Z",
"updated_at": "2026-11-04T12:00:00.000Z",
"editable": true,
"count": 21,
"waiting_count": 15
}
}Responde: 200 · 400 · 401 · 403 · 404 · 409 · 429
GET /inbox-views/attribute-keys
Conversation-attribute keys and their common values
The workspace’s conversation-attribute keys (what the AI agent recorded with add_metadata, or a person set), most used first, each with count (conversations carrying it) and top_values — the top most frequent scalar values, cut to 120 characters — for a view editor’s picker. key narrows to one key.
| Parámetro | En | Tipo | Obligatorio | Restricciones |
|---|---|---|---|---|
key | query | string | no | mín. 1, máx. 120 |
limit | query | integer | no | ≥ 1, ≤ 200, por defecto 50 |
top | query | integer | null | no | ≥ 0, ≤ 50, por defecto 5 |
curl https://api.vitrinadev.com/api/v1/inbox-views/attribute-keys \
-H "Authorization: Bearer $VITRINA_KEY"Ejemplo de respuesta (200)
{
"data": [
{
"key": "modelo",
"count": 1334,
"top_values": [
{
"value": "iPhone 18 Pro 256 GB",
"count": 72
},
{
"value": "iPhone 18 Pro Max",
"count": 26
}
]
}
]
}Responde: 200 · 400 · 401 · 403 · 404 · 409 · 429
POST /inbox-views/reorder
Reorder inbox views
Sets each listed view’s position to its index in ids. All ids must be views of scope that you write (workspace: routing:write; personal: your own); views left out keep their position. Answers the views you see, in their new order.
Cuerpo
| Campo | Tipo | Obligatorio | Restricciones |
|---|---|---|---|
scope | workspace \ | personal | sí |
ids | uuid[] | sí |
curl -X POST https://api.vitrinadev.com/api/v1/inbox-views/reorder \
-H "Authorization: Bearer $VITRINA_KEY" \
-H "Content-Type: application/json" \
-d '{
"scope": "workspace",
"ids": [
"6a1f0c7e-3b8d-4e52-9a51-0c2d7b1e9f44",
"9d4b7a10-52c3-4e8f-a1b6-7e0c3f2d8a55"
]
}'Ejemplo de respuesta (200)
{
"data": [
{
"id": "6a1f0c7e-3b8d-4e52-9a51-0c2d7b1e9f44",
"name": "Piden 18 Pro Max",
"scope": "workspace",
"owner_user_id": null,
"filters": {
"active": true,
"attributes": [
{
"key": "*",
"op": "contains",
"value": "18 pro max"
}
]
},
"exclude_from_waiting": true,
"position": 0,
"created_by": "0b9e2f4a-8c1d-4f37-b6a2-5d3e7c9a1b20",
"created_at": "2026-11-04T12:00:00.000Z",
"updated_at": "2026-11-04T12:00:00.000Z",
"editable": true,
"count": 21,
"waiting_count": 15
}
]
}Responde: 200 · 400 · 401 · 403 · 404 · 409 · 429
Régimen IVA
Si un auto se vende con IVA (afecto) o sin IVA (exento): el predeterminado de la automotora y la decisión por unidad, que se captura al ingresar el auto y no cambia con el predeterminado.
Indicadores de la automotora
La exportación de Comisiones para el cierre de mes, en Excel o CSV: una fila por vendedor y negocio con el cálculo de la comisión a la vista, y un resumen de lo que corresponde pagar a cada persona.