Posts de Instagram
Prepara el post de Instagram de un vehículo (pie de foto escrito con el estilo de la automotora y las primeras fotos) y apruébalo para publicarlo o programarlo. Nada se publica sin la aprobación.
Descarga la proyección completa de la API pública: openapi.json.
| Método | Ruta | Qué hace |
|---|---|---|
POST | /instagram-posts/{id}/approve | Approve and publish (or schedule) a prepared Instagram post |
POST | /instagram-posts/vehicles/{vehicleId}/drafts | Prepare an Instagram post for one-click approval |
POST /instagram-posts/{id}/approve
Approve and publish (or schedule) a prepared Instagram post
Publishes a pending_approval post, optionally with an edited caption / photo selection, or schedules it when scheduled_at is present. Like the compose POST, a publish that Instagram refuses answers 200 with status: "failed" and the reason — branch on status. 409 when the post is no longer waiting for approval.
| Parámetro | En | Tipo | Obligatorio | Restricciones |
|---|---|---|---|---|
id | path | uuid | sí |
Cuerpo
| Campo | Tipo | Obligatorio | Restricciones |
|---|---|---|---|
photos | object[] | — | |
caption | string | — | máx. 2200 |
scheduled_at | string | — | date-time |
curl -X POST https://api.vitrinadev.com/api/v1/instagram-posts/<id>/approve \
-H "Authorization: Bearer $VITRINA_KEY" \
-H "Content-Type: application/json" \
-d '{
"caption": "⚡️Se vende! Toyota RAV4 Híbrido 2022\n\n$24.990.000\n\n- Automática\n- 38.000 km\n\nEscríbenos por DM.",
"scheduled_at": "2026-10-16T13:00:00.000Z"
}'Ejemplo de respuesta (200)
{
"data": {
"id": "1a5ea0c1-0000-4000-8000-000000000001",
"vehicle_id": "c4c4c4c4-0000-4000-8000-000000000001",
"status": "scheduled",
"caption": "⚡️Se vende! Toyota RAV4 Híbrido 2022\n\n$24.990.000\n\n- Automática\n- 38.000 km\n\nEscríbenos por DM.",
"photos": [
{
"photo_index": 0,
"crop": null,
"resolved_url": "https://cdn.vitrinadev.com/vehicles/rav4-1.jpg"
},
{
"photo_index": 1,
"crop": null,
"resolved_url": "https://cdn.vitrinadev.com/vehicles/rav4-2.jpg"
}
],
"scheduled_at": "2026-10-16T13:00:00.000Z",
"published_at": null,
"published_media_id": null,
"messaging_account_id": null,
"error": null,
"created_by": "5e5e5e5e-0000-4000-8000-000000000001",
"created_at": "2026-10-15T14:00:00.000Z",
"updated_at": "2026-10-15T14:02:10.000Z"
}
}Responde: 200 · 400 · 401 · 403 · 404 · 409 · 429
POST /instagram-posts/vehicles/{vehicleId}/drafts
Prepare an Instagram post for one-click approval
What choosing Instagram in a vehicle's "Publicar" step does: prepares a post in pending_approval (server-generated caption, the first 10 photos of the gallery) and publishes NOTHING. 201 when created; 200 with the existing post when the vehicle already has one waiting. 422 when the vehicle has no photos or no Instagram account is connected.
| Parámetro | En | Tipo | Obligatorio | Restricciones |
|---|---|---|---|---|
vehicleId | path | uuid | sí |
curl -X POST https://api.vitrinadev.com/api/v1/instagram-posts/vehicles/<id>/drafts \
-H "Authorization: Bearer $VITRINA_KEY"Ejemplo de respuesta (201)
{
"data": {
"id": "1a5ea0c1-0000-4000-8000-000000000001",
"vehicle_id": "c4c4c4c4-0000-4000-8000-000000000001",
"status": "pending_approval",
"caption": "⚡️Se vende! Toyota RAV4 Híbrido 2022\n\n$24.990.000\n\n- Automática\n- 38.000 km\n\nEscríbenos por DM.",
"photos": [
{
"photo_index": 0,
"crop": null,
"resolved_url": "https://cdn.vitrinadev.com/vehicles/rav4-1.jpg"
},
{
"photo_index": 1,
"crop": null,
"resolved_url": "https://cdn.vitrinadev.com/vehicles/rav4-2.jpg"
}
],
"scheduled_at": null,
"published_at": null,
"published_media_id": null,
"messaging_account_id": null,
"error": null,
"created_by": "5e5e5e5e-0000-4000-8000-000000000001",
"created_at": "2026-10-15T14:00:00.000Z",
"updated_at": "2026-10-15T14:00:00.000Z"
}
}Responde: 200 · 201 · 400 · 401 · 403 · 404 · 409 · 429
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.
Integraciones · Meta Ads
La conexión de la cuenta publicitaria de Meta: iniciarla, resolver la selección de cuenta cuando hay más de una, desconectarla y leer los anuncios de click-to-WhatsApp del workspace.