{
  "components": {
    "responses": {
      "ApiErrorAuth": {
        "content": {
          "application/json": {
            "example": {
              "error": {
                "code": "invalid_api_key",
                "message": "API key inválida, revocada o expirada.",
                "type": "authentication_error"
              },
              "request_id": "req_01J8XYZ…",
              "success": false
            },
            "schema": {
              "$ref": "#/components/schemas/ApiError"
            }
          }
        },
        "description": "API key ausente, inválida, revocada o expirada — o el workspace está bloqueado."
      },
      "ApiErrorConflict": {
        "content": {
          "application/json": {
            "example": {
              "error": {
                "code": "idempotency_key_reuse",
                "message": "El Idempotency-Key ya se usó con un request distinto.",
                "type": "invalid_request_error"
              },
              "request_id": "req_01J8XYZ…",
              "success": false
            },
            "schema": {
              "$ref": "#/components/schemas/ApiError"
            }
          }
        },
        "description": "La operación entra en conflicto con el estado actual o con un Idempotency-Key en uso. No reintentes con el mismo key y un body distinto."
      },
      "ApiErrorForbidden": {
        "content": {
          "application/json": {
            "example": {
              "error": {
                "code": "missing_scope",
                "message": "La key no tiene el scope requerido: partner:leads:write.",
                "type": "invalid_request_error"
              },
              "request_id": "req_01J8XYZ…",
              "success": false
            },
            "schema": {
              "$ref": "#/components/schemas/ApiError"
            }
          }
        },
        "description": "La key está autenticada pero no puede ejecutar esta operación: scope faltante, capacidad deshabilitada, modo test restringido o recurso fuera de su cartera."
      },
      "ApiErrorInvalidRequest": {
        "content": {
          "application/json": {
            "example": {
              "error": {
                "code": "validation_error",
                "message": "El campo email debe ser una dirección válida.",
                "type": "invalid_request_error"
              },
              "request_id": "req_01J8XYZ…",
              "success": false
            },
            "schema": {
              "$ref": "#/components/schemas/ApiError"
            }
          }
        },
        "description": "La request no es válida: un campo no pasa validación, falta un parámetro requerido o el recurso no admite la transición solicitada."
      },
      "ApiErrorNotFound": {
        "content": {
          "application/json": {
            "example": {
              "error": {
                "code": "not_found",
                "message": "Recurso no encontrado.",
                "type": "invalid_request_error"
              },
              "request_id": "req_01J8XYZ…",
              "success": false
            },
            "schema": {
              "$ref": "#/components/schemas/ApiError"
            }
          }
        },
        "description": "El recurso no existe o no está disponible dentro del alcance de la key. No revela la existencia de recursos de otros tenants."
      },
      "ApiErrorRateLimit": {
        "content": {
          "application/json": {
            "example": {
              "error": {
                "code": "quota_exceeded",
                "message": "Se superó la cuota mensual de requests del plan.",
                "type": "rate_limit_error"
              },
              "request_id": "req_01J8XYZ…",
              "success": false
            },
            "schema": {
              "$ref": "#/components/schemas/ApiError"
            }
          }
        },
        "description": "Se superó el límite por minuto de la key o la cuota del plan. Respeta `Retry-After`; el SDK ya reintenta solo."
      },
      "ApiErrorServer": {
        "content": {
          "application/json": {
            "example": {
              "error": {
                "code": "internal_error",
                "message": "Ocurrió un error inesperado.",
                "type": "api_error"
              },
              "request_id": "req_01J8XYZ…",
              "success": false
            },
            "schema": {
              "$ref": "#/components/schemas/ApiError"
            }
          }
        },
        "description": "Error del servidor o del Met que ejecutaba. El SDK reintenta los 5xx con backoff."
      }
    },
    "schemas": {
      "ActivateIntegrationDto": {
        "properties": {
          "credentials": {
            "type": "object"
          }
        },
        "type": "object"
      },
      "ActiveMcpResponseDto": {
        "properties": {
          "activated_at": {
            "description": "Cuándo se activó en el workspace. `null` si el dato no quedó registrado.",
            "example": "2026-07-30T04:12:33.120Z",
            "nullable": true,
            "type": "string"
          },
          "activated_by": {
            "description": "Quién lo activó. `null` si el usuario ya no existe.",
            "example": 512,
            "nullable": true,
            "type": "number"
          },
          "code": {
            "description": "`@handle` del ítem del MCP. `null` si el ítem ya no existe.",
            "example": "GCAL_MCP",
            "nullable": true,
            "type": "string"
          },
          "connection_status": {
            "description": "Resultado de la última prueba de conexión. `null` si nunca se probó.",
            "example": "ok",
            "nullable": true,
            "type": "string"
          },
          "created_at": {
            "example": "2026-07-12T10:00:00.000Z",
            "nullable": true,
            "type": "string"
          },
          "descripcion": {
            "example": "Agenda eventos y consulta disponibilidad",
            "type": "string"
          },
          "endpoint_override": {
            "description": "Endpoint propio del workspace, si sobreescribe al del catálogo.",
            "example": "https://mcp.example.com/sse",
            "nullable": true,
            "type": "string"
          },
          "id": {
            "description": "`id` de la fila de configuración, **no** el id del ítem del MCP.",
            "example": 771,
            "type": "number"
          },
          "integration_key": {
            "description": "Clave de integración: `native_handler` para MCP nativos, `http:<mcp_id>`\npara los HTTP. `null` en filas legacy sin backfill.",
            "example": "google_calendar",
            "nullable": true,
            "type": "string"
          },
          "is_active": {
            "example": true,
            "type": "boolean"
          },
          "last_tested_at": {
            "example": "2026-08-02T18:05:00.000Z",
            "nullable": true,
            "type": "string"
          },
          "mcp_data": {
            "additionalProperties": true,
            "description": "Config del MCP: `mcp_type`, `native_handler`, `tools_cache` y\n`credentials_required`.\n\n`credentials_required` son los **nombres** de las credenciales que el MCP\npide (la UI los usa para pintar el formulario). Nombres, nunca valores: los\nvalores viven en la columna `credentials`, que no sale por este endpoint.",
            "type": "object"
          },
          "mcp_id": {
            "description": "ID del ítem del MCP. Es `VARCHAR` en la tabla, aunque referencie un `items.id`.",
            "example": "512",
            "type": "string"
          },
          "nombre": {
            "description": "Nombre mostrable, resuelto del ítem, del `mcp_data` o del registro nativo.",
            "example": "Google Calendar",
            "type": "string"
          },
          "updated_at": {
            "example": "2026-07-30T04:12:33.120Z",
            "nullable": true,
            "type": "string"
          },
          "workspace_id": {
            "example": 134,
            "type": "number"
          }
        },
        "required": [
          "id",
          "mcp_id",
          "workspace_id",
          "is_active",
          "activated_at",
          "activated_by",
          "connection_status",
          "last_tested_at",
          "endpoint_override",
          "integration_key",
          "created_at",
          "updated_at",
          "nombre",
          "descripcion",
          "code",
          "mcp_data"
        ],
        "type": "object"
      },
      "ActiveSkillResponseDto": {
        "properties": {
          "activated_at": {
            "example": "2026-07-30T04:12:33.120Z",
            "nullable": true,
            "type": "string"
          },
          "activated_by": {
            "description": "Quién la activó. `null` si el usuario ya no existe.",
            "example": 512,
            "nullable": true,
            "type": "number"
          },
          "created_at": {
            "example": "2026-07-12T10:00:00.000Z",
            "nullable": true,
            "type": "string"
          },
          "id": {
            "description": "`id` de la fila de configuración, **no** el id del ítem de la habilidad.",
            "example": 331,
            "type": "number"
          },
          "is_active": {
            "example": true,
            "type": "boolean"
          },
          "skill_id": {
            "description": "ID del ítem de la habilidad. Es `VARCHAR` en la tabla.",
            "example": "3120",
            "type": "string"
          },
          "updated_at": {
            "example": "2026-07-30T04:12:33.120Z",
            "nullable": true,
            "type": "string"
          },
          "workspace_id": {
            "example": 134,
            "type": "number"
          }
        },
        "required": [
          "id",
          "workspace_id",
          "skill_id",
          "is_active",
          "activated_at",
          "activated_by",
          "created_at",
          "updated_at"
        ],
        "type": "object"
      },
      "AddAgentGroupMemberDto": {
        "properties": {
          "user_id": {
            "type": "number"
          }
        },
        "required": [
          "user_id"
        ],
        "type": "object"
      },
      "AddonResponseDto": {
        "properties": {
          "addon_type": {
            "description": "`one_time` se paga una vez; `recurring` se cobra cada período.",
            "enum": [
              "one_time",
              "recurring"
            ],
            "example": "recurring",
            "type": "string"
          },
          "category": {
            "description": "Agrupador para mostrarlos ordenados.",
            "example": "limites",
            "type": "string"
          },
          "created_at": {
            "example": "2026-01-12T10:00:00.000Z",
            "type": "string"
          },
          "description": {
            "example": null,
            "nullable": true,
            "type": "string"
          },
          "display_order": {
            "example": 1,
            "type": "number"
          },
          "grants_automation_daily": {
            "description": "Ejecuciones de automatización por día que suma cada unidad.",
            "example": 0,
            "type": "number"
          },
          "grants_automation_rpm": {
            "description": "Declarada pero sin efecto: la dimensión por minuto quedó fuera del modelo.",
            "example": 0,
            "type": "number"
          },
          "grants_automation_runs": {
            "description": "Obsoleta: grant mensual del modelo anterior, se conserva por compatibilidad.",
            "example": 0,
            "type": "number"
          },
          "grants_contacts": {
            "description": "Contactos que suma cada unidad.",
            "example": 10000,
            "type": "number"
          },
          "grants_members": {
            "description": "Miembros que suma cada unidad.",
            "example": 0,
            "type": "number"
          },
          "grants_wa_lines": {
            "description": "Líneas de WhatsApp que suma cada unidad.",
            "example": 0,
            "type": "number"
          },
          "grants_wabas": {
            "description": "Cuentas de WhatsApp Business que suma cada unidad.",
            "example": 0,
            "type": "number"
          },
          "id": {
            "example": 7,
            "type": "number"
          },
          "name": {
            "example": "10.000 contactos adicionales",
            "type": "string"
          },
          "price_usd": {
            "description": "Precio por unidad, en USD.",
            "example": 15,
            "type": "number"
          },
          "slug": {
            "description": "Identificador estable del complemento.",
            "example": "contactos-10k",
            "type": "string"
          },
          "status": {
            "enum": [
              "active",
              "inactive"
            ],
            "example": "active",
            "type": "string"
          },
          "stripe_price_id": {
            "example": "price_1Om…",
            "nullable": true,
            "type": "string"
          },
          "unit_label": {
            "description": "Cómo se llama una unidad de este complemento.",
            "example": "paquete",
            "nullable": true,
            "type": "string"
          },
          "updated_at": {
            "example": "2026-06-30T18:41:02.000Z",
            "type": "string"
          }
        },
        "required": [
          "id",
          "slug",
          "name",
          "description",
          "category",
          "addon_type",
          "unit_label",
          "price_usd",
          "grants_contacts",
          "grants_members",
          "stripe_price_id",
          "status",
          "display_order",
          "created_at",
          "updated_at"
        ],
        "type": "object"
      },
      "AgentAvailableSkillDto": {
        "properties": {
          "activo": {
            "description": "`false` si el usuario la pausó.",
            "example": true,
            "type": "boolean"
          },
          "descripcion": {
            "example": "Crear y mover eventos del calendario.",
            "nullable": true,
            "type": "string"
          },
          "foto_principal": {
            "description": "Logo de la habilidad. `null` si no tiene.",
            "example": "https://…/logo.png",
            "nullable": true,
            "type": "string"
          },
          "id": {
            "description": "ID del item de la habilidad.",
            "example": 88,
            "type": "number"
          },
          "linked": {
            "description": "`true` si este Met ya la tiene vinculada.",
            "example": false,
            "type": "boolean"
          },
          "mcp_handler": {
            "description": "Handler del primer MCP que pide credenciales, para abrir el formulario correcto.",
            "example": "google_calendar",
            "nullable": true,
            "type": "string"
          },
          "mcps_count": {
            "description": "Cuántos MCP distintos trae la habilidad.",
            "example": 1,
            "type": "number"
          },
          "nombre": {
            "example": "Agenda",
            "type": "string"
          },
          "origin": {
            "description": "`workspace` = copia local ya contratada; `store` = plantilla global sin contratar.",
            "enum": [
              "workspace",
              "store"
            ],
            "example": "workspace",
            "type": "string"
          },
          "prompt_base_length": {
            "description": "Largo del prompt base, en caracteres. Va el largo y no el texto: el prompt es\nconfiguración interna de la habilidad, no parte de esta vista.",
            "example": 412,
            "type": "number"
          },
          "requires_credentials": {
            "description": "`true` si algún MCP de la habilidad pide credenciales para funcionar.",
            "example": true,
            "type": "boolean"
          },
          "status": {
            "description": "Estado derivado, no persistido: `active` (lista para invocar tools),\n`pending_credentials` (su MCP necesita credenciales y faltan) o `inactive`\n(pausada por el usuario).",
            "enum": [
              "active",
              "pending_credentials",
              "inactive"
            ],
            "example": "active",
            "type": "string"
          }
        },
        "required": [
          "id",
          "nombre",
          "descripcion",
          "prompt_base_length",
          "mcps_count",
          "linked",
          "origin",
          "status",
          "requires_credentials",
          "mcp_handler",
          "foto_principal",
          "activo"
        ],
        "type": "object"
      },
      "AgentAvailableSkillsResponseDto": {
        "properties": {
          "skills": {
            "items": {
              "$ref": "#/components/schemas/AgentAvailableSkillDto"
            },
            "type": "array"
          }
        },
        "required": [
          "skills"
        ],
        "type": "object"
      },
      "AgentDisabledToolsResponseDto": {
        "properties": {
          "disabled_tools": {
            "example": [
              "mcp_google_calendar_delete_event"
            ],
            "items": {
              "type": "string"
            },
            "type": "array"
          }
        },
        "required": [
          "disabled_tools"
        ],
        "type": "object"
      },
      "AgentFunctionLinksResponseDto": {
        "properties": {
          "linked_ids": {
            "description": "`function_id` de cada función vinculada, sin orden garantizado.",
            "example": [
              812,
              815
            ],
            "items": {
              "type": "number"
            },
            "type": "array"
          }
        },
        "required": [
          "linked_ids"
        ],
        "type": "object"
      },
      "AgentGroupMemberResponseDto": {
        "properties": {
          "email": {
            "example": "ana@empresa.com",
            "type": "string"
          },
          "id": {
            "description": "ID del usuario miembro del grupo.",
            "example": 512,
            "type": "number"
          },
          "name": {
            "example": "Ana Ruiz",
            "type": "string"
          }
        },
        "required": [
          "id",
          "name",
          "email"
        ],
        "type": "object"
      },
      "AgentGroupOkResponseDto": {
        "properties": {
          "ok": {
            "description": "Siempre `true`. Si algo falla, la respuesta es un error, no `ok: false`.",
            "enum": [
              true
            ],
            "example": true,
            "type": "number"
          }
        },
        "required": [
          "ok"
        ],
        "type": "object"
      },
      "AgentGroupResponseDto": {
        "properties": {
          "created_at": {
            "example": "2026-07-30T04:12:33.120Z",
            "type": "string"
          },
          "id": {
            "example": 12,
            "type": "number"
          },
          "members": {
            "description": "Miembros del grupo, ordenados por nombre. Vacío si todavía no tiene ninguno.",
            "items": {
              "$ref": "#/components/schemas/AgentGroupMemberResponseDto"
            },
            "type": "array"
          },
          "name": {
            "description": "Nombre del grupo. Es único dentro del workspace.",
            "example": "Soporte",
            "type": "string"
          }
        },
        "required": [
          "id",
          "name",
          "created_at",
          "members"
        ],
        "type": "object"
      },
      "AgentMcpDto": {
        "properties": {
          "foto_principal": {
            "example": "https://…/logo.png",
            "nullable": true,
            "type": "string"
          },
          "id": {
            "description": "ID del item MCP.",
            "example": 3120,
            "type": "number"
          },
          "native_handler": {
            "description": "Handler del MCP nativo. `null` si es un MCP externo.",
            "example": "google_calendar",
            "nullable": true,
            "type": "string"
          },
          "nombre": {
            "example": "Google Calendar",
            "type": "string"
          },
          "skill_refs": {
            "description": "Habilidades del Met que traen este MCP.",
            "items": {
              "$ref": "#/components/schemas/AgentMcpSkillRefDto"
            },
            "type": "array"
          },
          "tools": {
            "items": {
              "$ref": "#/components/schemas/AgentMcpToolDto"
            },
            "type": "array"
          }
        },
        "required": [
          "id",
          "nombre",
          "foto_principal",
          "native_handler",
          "tools",
          "skill_refs"
        ],
        "type": "object"
      },
      "AgentMcpSkillRefDto": {
        "properties": {
          "enabled_tools": {
            "description": "Allowlist declarada por esa habilidad. `null` = todas las tools.",
            "example": null,
            "items": {
              "type": "string"
            },
            "nullable": true,
            "type": "array"
          },
          "skill_id": {
            "example": 88,
            "type": "number"
          },
          "skill_nombre": {
            "example": "Agenda",
            "type": "string"
          }
        },
        "required": [
          "skill_id",
          "skill_nombre",
          "enabled_tools"
        ],
        "type": "object"
      },
      "AgentMcpToolDto": {
        "properties": {
          "description": {
            "example": "Crea un evento en el calendario.",
            "type": "string"
          },
          "name": {
            "description": "Nombre de la tool dentro del MCP.",
            "example": "create_event",
            "type": "string"
          },
          "tool_key": {
            "description": "Nombre final que ve el modelo. Es la clave que va en `disabled_tools`.",
            "example": "mcp_google_calendar_create_event",
            "type": "string"
          }
        },
        "required": [
          "name",
          "description",
          "tool_key"
        ],
        "type": "object"
      },
      "AgentMcpsResponseDto": {
        "properties": {
          "disabled_tools": {
            "description": "Claves de tool desactivadas para este Met. Vacío si no hay ningún override.",
            "example": [
              "mcp_google_calendar_delete_event"
            ],
            "items": {
              "type": "string"
            },
            "type": "array"
          },
          "mcps": {
            "items": {
              "$ref": "#/components/schemas/AgentMcpDto"
            },
            "type": "array"
          }
        },
        "required": [
          "mcps",
          "disabled_tools"
        ],
        "type": "object"
      },
      "AgentResponseDto": {
        "properties": {
          "active": {
            "description": "`false` si el Met está en pausa (no atiende).",
            "example": true,
            "type": "boolean"
          },
          "created_at": {
            "example": "2026-07-30T04:12:33.120Z",
            "nullable": true,
            "type": "string"
          },
          "disabled_tools": {
            "description": "Tools que este Met NO verá, aunque se las traiga una skill o una Función.\nSon claves de tool (`mcp_<handler>_<tool>`), no nombres visibles.",
            "example": [
              "mcp_meteor_item_delete"
            ],
            "items": {
              "type": "string"
            },
            "type": "array"
          },
          "id": {
            "description": "ID del Met. Es el mismo id del item en la colección `_mets`.",
            "example": 421,
            "type": "number"
          },
          "instructions": {
            "description": "Prompt de sistema del Met, tal cual está configurado. `null` si no tiene.",
            "nullable": true,
            "type": "string"
          },
          "mission": {
            "description": "Para qué existe este Met. `null` si no se definió.",
            "example": "Calificar y responder oportunidades entrantes.",
            "nullable": true,
            "type": "string"
          },
          "model": {
            "description": "Model id configurado para el Met. `null` si usa el default de la plataforma.\n\nEl ejemplo sale del catálogo y no de un literal: escrito a mano ya se había\nquedado una versión atrás del modelo real, que es exactamente cómo se\ndesincroniza el catálogo.",
            "example": "claude-sonnet-5",
            "nullable": true,
            "type": "string"
          },
          "name": {
            "description": "Nombre con el que se lo invoca y con el que aparece en los selectores.",
            "example": "Ventas",
            "type": "string"
          },
          "object": {
            "description": "Siempre `agent`. Distingue el tipo de objeto en respuestas mezcladas.",
            "enum": [
              "agent"
            ],
            "example": "agent",
            "type": "string"
          },
          "tier": {
            "description": "Nivel comercial derivado del modelo. `null` si el Met no fija modelo.",
            "enum": [
              "agil",
              "brillante",
              "genio"
            ],
            "example": "brillante",
            "nullable": true,
            "type": "string"
          },
          "title": {
            "description": "Cargo del Met, el subtítulo que lo describe en una línea. `null` si no tiene.",
            "example": "Asesor comercial",
            "nullable": true,
            "type": "string"
          }
        },
        "required": [
          "id",
          "object",
          "name",
          "title",
          "mission",
          "instructions",
          "active",
          "disabled_tools",
          "model",
          "tier",
          "created_at"
        ],
        "type": "object"
      },
      "AgentSkillLinkResponseDto": {
        "properties": {
          "agent_id": {
            "example": 421,
            "type": "number"
          },
          "linked": {
            "description": "`true` tras vincular, `false` tras desvincular. Las dos operaciones son idempotentes.",
            "example": true,
            "type": "boolean"
          },
          "object": {
            "description": "Siempre `agent_skill_link`.",
            "enum": [
              "agent_skill_link"
            ],
            "example": "agent_skill_link",
            "type": "string"
          },
          "skill_id": {
            "example": 88,
            "type": "number"
          }
        },
        "required": [
          "object",
          "agent_id",
          "skill_id",
          "linked"
        ],
        "type": "object"
      },
      "AgentSkillResponseDto": {
        "properties": {
          "active": {
            "description": "`false` si la skill está pausada; sus tools no se le ofrecen al modelo.",
            "example": true,
            "type": "boolean"
          },
          "description": {
            "example": "Crear y mover eventos del calendario.",
            "nullable": true,
            "type": "string"
          },
          "id": {
            "description": "ID de la skill.",
            "example": 88,
            "type": "number"
          },
          "name": {
            "example": "Agenda",
            "type": "string"
          },
          "object": {
            "description": "Siempre `agent_skill`.",
            "enum": [
              "agent_skill"
            ],
            "example": "agent_skill",
            "type": "string"
          }
        },
        "required": [
          "id",
          "object",
          "name",
          "description",
          "active"
        ],
        "type": "object"
      },
      "AgentToolResponseDto": {
        "properties": {
          "description": {
            "example": "Crea un evento en el calendario del workspace.",
            "nullable": true,
            "type": "string"
          },
          "disabled": {
            "description": "`true` si está desactivada para este Met: existe, pero no se le ofrece al modelo.",
            "example": false,
            "type": "boolean"
          },
          "name": {
            "description": "Nombre final que ve el modelo (`mcp_<handler>_<tool>` o el de la Función).",
            "example": "mcp_agenda_create_event",
            "type": "string"
          },
          "source": {
            "description": "De dónde sale la tool: `function` (una Función IA del Met), `skill` (la trae\nun MCP de una skill vinculada), `collection` (nativa sobre colecciones e\nítems) o `internal` (el resto de la gestión nativa).",
            "enum": [
              "collection",
              "skill",
              "function",
              "internal"
            ],
            "example": "skill",
            "type": "string"
          }
        },
        "required": [
          "name",
          "source",
          "description",
          "disabled"
        ],
        "type": "object"
      },
      "AgentToolsResponseDto": {
        "properties": {
          "tools": {
            "items": {
              "$ref": "#/components/schemas/AgentToolResponseDto"
            },
            "type": "array"
          }
        },
        "required": [
          "tools"
        ],
        "type": "object"
      },
      "ApiEnvelope": {
        "description": "Sobre en el que viaja toda respuesta correcta de la API. El recurso está en `data`. Los SDKs oficiales lo desenvuelven por ti; un cliente hecho a mano tiene que leer `.data`.",
        "properties": {
          "success": {
            "description": "Siempre `true` en una respuesta 2xx.",
            "enum": [
              true
            ],
            "type": "boolean"
          }
        },
        "required": [
          "success"
        ],
        "type": "object"
      },
      "ApiError": {
        "description": "Cuerpo de error de la API pública. `error.type` es una lista cerrada de 5 valores que el SDK mapea 1:1 a clases de excepción; `error.code` es más específico y crece con el tiempo. `request_id` es buscable en el Workbench (Ajustes → Desarrolladores → Actividad → Registros).",
        "properties": {
          "error": {
            "properties": {
              "code": {
                "description": "Código específico, en inglés (contrato de máquina). Ej.: `invalid_api_key`, `missing_scope`, `quota_exceeded`, `test_mode_restricted`.",
                "example": "missing_scope",
                "type": "string"
              },
              "message": {
                "description": "Texto en español, para que lo lea una persona.",
                "type": "string"
              },
              "param": {
                "description": "Campo que causó el error, cuando aplica.",
                "type": "string"
              },
              "type": {
                "description": "Clase del error. Lista cerrada; el SDK la mapea a una excepción tipada.",
                "enum": [
                  "authentication_error",
                  "invalid_request_error",
                  "rate_limit_error",
                  "agent_error",
                  "api_error"
                ],
                "type": "string"
              }
            },
            "required": [
              "type",
              "code",
              "message"
            ],
            "type": "object"
          },
          "request_id": {
            "description": "Identificador de la request. **Guárdalo**: es buscable en el Workbench y es lo primero que pide soporte.",
            "example": "req_01J8XYZ…",
            "type": "string"
          },
          "success": {
            "description": "Siempre `false` en un error.",
            "enum": [
              false
            ],
            "type": "boolean"
          }
        },
        "required": [
          "success",
          "error"
        ],
        "type": "object"
      },
      "AutoRechargeConfigResponseDto": {
        "properties": {
          "amount_usd": {
            "description": "Cuánto se recarga cada vez, en USD. `null` si no se configuró.",
            "example": 50,
            "nullable": true,
            "type": "number"
          },
          "capped": {
            "description": "`true` cuando la PRÓXIMA recarga ya no cabe en el tope — que no es lo mismo\nque haber gastado el tope entero: con tope 200, gastado 180 y monto 50, la\nrecarga ya está frenada. Mientras sea `true` no se cobra; se reanuda solo el\nprimer día del mes siguiente.",
            "example": false,
            "type": "boolean"
          },
          "enabled": {
            "description": "`true` si la recarga automática está encendida.",
            "example": true,
            "type": "boolean"
          },
          "has_card": {
            "description": "`true` si hay una tarjeta guardada para cobrar.",
            "example": true,
            "type": "boolean"
          },
          "last_error": {
            "description": "Motivo del último intento fallido, si lo hubo.",
            "example": null,
            "nullable": true,
            "type": "string"
          },
          "month_spent_usd": {
            "description": "Gasto de la recarga automática en el mes en curso, en USD. El mes corta en\nla zona horaria del workspace, y el contador vuelve a cero solo (no hay que\npedir nada el día 1). Cuenta cobros **automáticos**: una recarga manual es\nun acto deliberado y no consume el tope.",
            "example": 150,
            "type": "number"
          },
          "monthly_cap_usd": {
            "description": "Techo de gasto de la recarga automática por mes, en USD. `null` = sin tope.",
            "example": 200,
            "nullable": true,
            "type": "number"
          },
          "status": {
            "description": "`active` mientras funcione; `failed` tras un cobro rechazado.",
            "example": "active",
            "nullable": true,
            "type": "string"
          },
          "threshold_usd": {
            "description": "Saldo, en USD, por debajo del cual se dispara la recarga.",
            "example": 5,
            "type": "number"
          }
        },
        "required": [
          "enabled",
          "status",
          "threshold_usd",
          "amount_usd",
          "last_error",
          "has_card",
          "monthly_cap_usd",
          "month_spent_usd",
          "capped"
        ],
        "type": "object"
      },
      "AutomationDeletedResponseDto": {
        "properties": {
          "message": {
            "example": "Automatización eliminada",
            "type": "string"
          }
        },
        "required": [
          "message"
        ],
        "type": "object"
      },
      "AutomationResponseDto": {
        "properties": {
          "action_config": {
            "additionalProperties": true,
            "description": "Config extra de la acción. Forma libre; `ai_field` usa `{ field }`.",
            "example": {},
            "type": "object"
          },
          "action_kind": {
            "description": "Qué ejecuta: una tarea, un flujo, un campo de IA o un proceso administrado.",
            "enum": [
              "task",
              "flow",
              "ai_field",
              "system_job"
            ],
            "example": "flow",
            "type": "string"
          },
          "capabilities": {
            "allOf": [
              {
                "$ref": "#/components/schemas/ManagedAutomationCapabilitiesDto"
              }
            ],
            "description": "Contrato explícito de qué puede editar esta fila."
          },
          "category": {
            "example": "Reportes",
            "nullable": true,
            "type": "string"
          },
          "collection_id": {
            "description": "Colección sobre la que aplica, si el tipo de disparador la usa.",
            "example": 42,
            "nullable": true,
            "type": "number"
          },
          "conditions": {
            "additionalProperties": true,
            "description": "Condiciones del disparador, sin la metadata de UI. Su forma depende del\n`trigger_type`: el catálogo declara cuáles acepta cada uno\n(`conditions_schema`).",
            "example": {
              "field": "estado",
              "to": "ganado"
            },
            "type": "object"
          },
          "created_at": {
            "example": "2026-07-20T18:03:11.000Z",
            "type": "string"
          },
          "description": {
            "nullable": true,
            "type": "string"
          },
          "enabled": {
            "example": true,
            "type": "boolean"
          },
          "flow_id": {
            "description": "Flujo que ejecuta. No `null` solo cuando `action_kind` es `flow`.",
            "example": "8f14e45f-ceea-467a-9f0b-4c3d1a2b5e60",
            "nullable": true,
            "type": "string"
          },
          "flow_name": {
            "description": "Nombre del flujo destino, ya resuelto. `null` si la acción no es `flow`.",
            "example": "Recordatorio de pago",
            "nullable": true,
            "type": "string"
          },
          "icon": {
            "description": "Emoji. Cae al del tipo de disparador en el catálogo.",
            "example": "🔔",
            "nullable": true,
            "type": "string"
          },
          "id": {
            "example": "a1b2c3d4-e5f6-7890-abcd-ef1234567890",
            "type": "string"
          },
          "is_system_managed": {
            "description": "`true` para procesos cuyo handler pertenece al backend.",
            "example": true,
            "type": "boolean"
          },
          "last_run": {
            "allOf": [
              {
                "$ref": "#/components/schemas/SystemAutomationRunDto"
              }
            ],
            "nullable": true
          },
          "managed_defaults": {
            "additionalProperties": true,
            "description": "Valores protegidos a los que vuelve “Restaurar configuración”.",
            "example": {
              "flow_id": null,
              "recurrence_pattern": "0 12 * * 1-6"
            },
            "type": "object"
          },
          "managed_revision": {
            "description": "Versión usada para impedir que dos ediciones se sobrescriban.",
            "example": 2,
            "type": "number"
          },
          "manual_run": {
            "example": true,
            "type": "boolean"
          },
          "name": {
            "description": "Nombre visible. Cae al nombre de la tarea/flujo, y si no, a `(sin nombre)`.",
            "example": "Notificar publicación",
            "type": "string"
          },
          "paused_reason": {
            "description": "Por qué quedó pausada. Con texto = la pausó el freno de bucles;\n`null` = la apagó una persona (o está encendida).",
            "example": "Se disparó 200 veces en 5 minutos",
            "nullable": true,
            "type": "string"
          },
          "system_key": {
            "example": "lyp.report.sales.daily",
            "nullable": true,
            "type": "string"
          },
          "target_label": {
            "example": "Asesores y administrador LyP",
            "nullable": true,
            "type": "string"
          },
          "task_id": {
            "description": "Tarea que ejecuta. No `null` solo cuando `action_kind` es `task`.",
            "example": "d4c3b2a1-…",
            "nullable": true,
            "type": "string"
          },
          "task_name": {
            "description": "Nombre de la tarea destino, ya resuelto. `null` si la acción no es `task`.",
            "nullable": true,
            "type": "string"
          },
          "templates": {
            "example": [
              "ventas_dia_general",
              "ventas_dia_vendedor"
            ],
            "items": {
              "type": "string"
            },
            "type": "array"
          },
          "trigger_type": {
            "description": "Tipo del catálogo (`GET /trigger-catalog`).",
            "example": "item.field_changed",
            "type": "string"
          },
          "workspace_id": {
            "example": 40,
            "type": "number"
          }
        },
        "required": [
          "id",
          "task_id",
          "flow_id",
          "trigger_type",
          "collection_id",
          "enabled",
          "paused_reason",
          "name",
          "description",
          "icon",
          "conditions",
          "action_kind",
          "action_config",
          "task_name",
          "flow_name",
          "workspace_id",
          "created_at",
          "is_system_managed",
          "templates",
          "manual_run",
          "managed_revision",
          "managed_defaults",
          "capabilities"
        ],
        "type": "object"
      },
      "AutopilotPauseResultDto": {
        "properties": {
          "paused_until": {
            "description": "`null` cuando se reanudó ahora mismo (`minutes: 0`).",
            "example": "2026-07-30T04:42:33.120Z",
            "nullable": true,
            "type": "string"
          }
        },
        "required": [
          "paused_until"
        ],
        "type": "object"
      },
      "AvailableVariableDto": {
        "properties": {
          "description": {
            "description": "Ayuda para elegirla: la descripción de la variable de workspace, o la\netiqueta del campo de contacto. Ausente en los campos de sistema.",
            "example": "Horario que el Met le informa al cliente",
            "type": "string"
          },
          "source": {
            "description": "De dónde sale el valor al resolver.",
            "enum": [
              "workspace",
              "contact"
            ],
            "example": "workspace",
            "type": "string"
          },
          "type": {
            "description": "Tipo declarado. Los campos de sistema del contacto siempre son `text`.",
            "example": "text",
            "type": "string"
          },
          "variable": {
            "description": "Token sin el `$`: en la plantilla se escribe `$workspace.horario_atencion`.",
            "example": "workspace.horario_atencion",
            "type": "string"
          }
        },
        "required": [
          "variable",
          "type",
          "source"
        ],
        "type": "object"
      },
      "BalanceTransactionResponseDto": {
        "properties": {
          "amount_usd": {
            "description": "Monto del movimiento en USD: positivo acredita, negativo debita.",
            "example": -0.0123,
            "type": "number"
          },
          "balance_after": {
            "example": 42.8687,
            "type": "number"
          },
          "balance_before": {
            "example": 42.881,
            "type": "number"
          },
          "created_at": {
            "example": "2026-07-29T14:02:11.000Z",
            "type": "string"
          },
          "created_by": {
            "example": null,
            "nullable": true,
            "type": "number"
          },
          "id": {
            "example": 48256,
            "type": "number"
          },
          "reason": {
            "example": null,
            "nullable": true,
            "type": "string"
          },
          "reference_id": {
            "example": "exec_01HZ…",
            "nullable": true,
            "type": "string"
          },
          "reference_table": {
            "description": "Qué originó el movimiento; junto con `reference_id` lleva al origen.",
            "example": "ai_executions",
            "nullable": true,
            "type": "string"
          },
          "type": {
            "description": "`recharge` es una compra de Energía, `bonus` un regalo, `plan_credit` la\nEnergía incluida en el plan, `consumption` un débito por uso y `refund` una\ndevolución.",
            "enum": [
              "recharge",
              "bonus",
              "consumption",
              "refund",
              "plan_credit"
            ],
            "example": "consumption",
            "type": "string"
          },
          "workspace_id": {
            "example": 134,
            "type": "number"
          }
        },
        "required": [
          "id",
          "workspace_id",
          "type",
          "amount_usd",
          "balance_before",
          "balance_after",
          "reference_table",
          "reference_id",
          "reason",
          "created_by",
          "created_at"
        ],
        "type": "object"
      },
      "BroadcastDeletedResponseDto": {
        "properties": {
          "deleted": {
            "enum": [
              true
            ],
            "example": true,
            "type": "number"
          }
        },
        "required": [
          "deleted"
        ],
        "type": "object"
      },
      "BroadcastDetailDto": {
        "properties": {
          "created_at": {
            "example": "2026-07-28T16:04:11.220Z",
            "type": "string"
          },
          "created_by": {
            "description": "Usuario que la creó. `null` si la creó una automatización.",
            "example": 42,
            "nullable": true,
            "type": "number"
          },
          "failed_count": {
            "example": 3,
            "type": "number"
          },
          "filters": {
            "description": "Condiciones del segmento, tal como se guardaron. Se combinan con AND; vacío\nsignifica \"todos los contactos\".",
            "items": {
              "additionalProperties": true,
              "type": "object"
            },
            "type": "array"
          },
          "finished_at": {
            "description": "Cuándo llegó a un estado terminal. `null` mientras siga viva.",
            "nullable": true,
            "type": "string"
          },
          "flow_id": {
            "description": "UUID del flujo publicado que se ejecuta por cada contacto del segmento.",
            "example": "9c0d5f2a-11b8-4f3e-8f22-6d3a7c4e1b90",
            "type": "string"
          },
          "flow_name": {
            "description": "Nombre del flujo que ejecuta. `null` si el flujo ya no existe.",
            "example": "Recordatorio de renovación",
            "nullable": true,
            "type": "string"
          },
          "id": {
            "description": "UUID de la difusión.",
            "example": "3f2b1c9e-7a41-4d0c-9c11-8a2f0e5d6b77",
            "type": "string"
          },
          "name": {
            "description": "Nombre con el que la ves en el listado.",
            "example": "Recordatorio de renovación · julio",
            "type": "string"
          },
          "next_run_at": {
            "description": "Próximo disparo calculado de una difusión recurrente.",
            "example": "2026-07-31T13:00:00.000Z",
            "nullable": true,
            "type": "string"
          },
          "recurrence": {
            "enum": [
              "none",
              "daily",
              "weekly",
              "monthly"
            ],
            "example": "none",
            "type": "string"
          },
          "recurrence_dom": {
            "description": "Día del mes del disparo, 1–31 (se ajusta en meses cortos). Solo `monthly`.",
            "example": null,
            "nullable": true,
            "type": "number"
          },
          "recurrence_dow": {
            "description": "Día de la semana del disparo, 0 = domingo. Solo con `recurrence: \"weekly\"`.",
            "example": null,
            "nullable": true,
            "type": "number"
          },
          "recurrence_time": {
            "description": "Hora local del disparo automático, `HH:MM` en 24 h. Solo si es recurrente.",
            "example": "08:00",
            "nullable": true,
            "type": "string"
          },
          "scheduled_at": {
            "description": "ISO 8601. Solo tiene valor con `send_mode: \"scheduled\"`.",
            "example": "2026-08-01T14:00:00.000Z",
            "nullable": true,
            "type": "string"
          },
          "send_mode": {
            "description": "`now` la toma el próximo tick; `scheduled` espera `scheduled_at`; `manual` es\nuna plantilla que dispara un nodo de flujo; `recurring` se dispara sola.",
            "enum": [
              "now",
              "scheduled",
              "manual",
              "recurring"
            ],
            "example": "now",
            "type": "string"
          },
          "sent_count": {
            "example": 640,
            "type": "number"
          },
          "source_broadcast_id": {
            "description": "Si esta fila es una **corrida** disparada desde una plantilla manual o\nrecurrente, aquí va el id de esa plantilla. `null` en las difusiones normales.",
            "example": null,
            "nullable": true,
            "type": "string"
          },
          "started_at": {
            "description": "Cuándo empezó a despacharse. `null` mientras no arrancó.",
            "nullable": true,
            "type": "string"
          },
          "status": {
            "description": "`draft` es la plantilla manual en reposo; `scheduled` espera su turno;\n`running` está despachando; `completed` y `cancelled` son terminales.",
            "enum": [
              "draft",
              "scheduled",
              "running",
              "completed",
              "cancelled"
            ],
            "example": "scheduled",
            "type": "string"
          },
          "throttle_per_minute": {
            "description": "Techo de envíos por minuto que respeta el despachador.",
            "example": 60,
            "type": "number"
          },
          "timezone": {
            "description": "Zona horaria IANA con la que se interpreta `recurrence_time`.",
            "example": "America/Bogota",
            "nullable": true,
            "type": "string"
          },
          "total_recipients": {
            "description": "Contactos que quedaron materializados como destinatarios.",
            "example": 812,
            "type": "number"
          },
          "updated_at": {
            "example": "2026-07-28T16:04:11.220Z",
            "type": "string"
          },
          "workspace_id": {
            "example": 134,
            "type": "number"
          }
        },
        "required": [
          "id",
          "workspace_id",
          "name",
          "flow_id",
          "filters",
          "throttle_per_minute",
          "status",
          "send_mode",
          "source_broadcast_id",
          "scheduled_at",
          "recurrence",
          "recurrence_time",
          "recurrence_dow",
          "recurrence_dom",
          "timezone",
          "next_run_at",
          "total_recipients",
          "sent_count",
          "failed_count",
          "created_by",
          "created_at",
          "updated_at",
          "started_at",
          "finished_at",
          "flow_name"
        ],
        "type": "object"
      },
      "BroadcastListItemDto": {
        "properties": {
          "created_at": {
            "example": "2026-07-28T16:04:11.220Z",
            "type": "string"
          },
          "created_by": {
            "description": "Usuario que la creó. `null` si la creó una automatización.",
            "example": 42,
            "nullable": true,
            "type": "number"
          },
          "failed_count": {
            "example": 3,
            "type": "number"
          },
          "filters": {
            "description": "Condiciones del segmento, tal como se guardaron. Se combinan con AND; vacío\nsignifica \"todos los contactos\".",
            "items": {
              "type": "object",
              "additionalProperties": true
            },
            "type": "array"
          },
          "finished_at": {
            "description": "Cuándo llegó a un estado terminal. `null` mientras siga viva.",
            "nullable": true,
            "type": "string"
          },
          "flow_id": {
            "description": "UUID del flujo publicado que se ejecuta por cada contacto del segmento.",
            "example": "9c0d5f2a-11b8-4f3e-8f22-6d3a7c4e1b90",
            "type": "string"
          },
          "flow_name": {
            "description": "Nombre del flujo que ejecuta. `null` si el flujo ya no existe.",
            "example": "Recordatorio de renovación",
            "nullable": true,
            "type": "string"
          },
          "id": {
            "description": "UUID de la difusión.",
            "example": "3f2b1c9e-7a41-4d0c-9c11-8a2f0e5d6b77",
            "type": "string"
          },
          "last_run_at": {
            "description": "Cuándo se disparó por última vez. Solo en manuales/recurrentes.",
            "example": "2026-07-29T13:00:02.910Z",
            "nullable": true,
            "type": "string"
          },
          "name": {
            "description": "Nombre con el que la ves en el listado.",
            "example": "Recordatorio de renovación · julio",
            "type": "string"
          },
          "next_run_at": {
            "description": "Próximo disparo calculado de una difusión recurrente.",
            "example": "2026-07-31T13:00:00.000Z",
            "nullable": true,
            "type": "string"
          },
          "recurrence": {
            "enum": [
              "none",
              "daily",
              "weekly",
              "monthly"
            ],
            "example": "none",
            "type": "string"
          },
          "recurrence_dom": {
            "description": "Día del mes del disparo, 1–31 (se ajusta en meses cortos). Solo `monthly`.",
            "example": null,
            "nullable": true,
            "type": "number"
          },
          "recurrence_dow": {
            "description": "Día de la semana del disparo, 0 = domingo. Solo con `recurrence: \"weekly\"`.",
            "example": null,
            "nullable": true,
            "type": "number"
          },
          "recurrence_time": {
            "description": "Hora local del disparo automático, `HH:MM` en 24 h. Solo si es recurrente.",
            "example": "08:00",
            "nullable": true,
            "type": "string"
          },
          "runs": {
            "description": "Corridas disparadas desde esta plantilla. Solo en manuales/recurrentes.",
            "items": {
              "$ref": "#/components/schemas/BroadcastListItemDto"
            },
            "type": "array"
          },
          "runs_count": {
            "description": "Cuántas corridas tuvo la plantilla. Solo en manuales/recurrentes.",
            "example": 4,
            "type": "number"
          },
          "scheduled_at": {
            "description": "ISO 8601. Solo tiene valor con `send_mode: \"scheduled\"`.",
            "example": "2026-08-01T14:00:00.000Z",
            "nullable": true,
            "type": "string"
          },
          "send_mode": {
            "description": "`now` la toma el próximo tick; `scheduled` espera `scheduled_at`; `manual` es\nuna plantilla que dispara un nodo de flujo; `recurring` se dispara sola.",
            "enum": [
              "now",
              "scheduled",
              "manual",
              "recurring"
            ],
            "example": "now",
            "type": "string"
          },
          "sent_count": {
            "example": 640,
            "type": "number"
          },
          "source_broadcast_id": {
            "description": "Si esta fila es una **corrida** disparada desde una plantilla manual o\nrecurrente, aquí va el id de esa plantilla. `null` en las difusiones normales.",
            "example": null,
            "nullable": true,
            "type": "string"
          },
          "started_at": {
            "description": "Cuándo empezó a despacharse. `null` mientras no arrancó.",
            "nullable": true,
            "type": "string"
          },
          "status": {
            "description": "`draft` es la plantilla manual en reposo; `scheduled` espera su turno;\n`running` está despachando; `completed` y `cancelled` son terminales.",
            "enum": [
              "draft",
              "scheduled",
              "running",
              "completed",
              "cancelled"
            ],
            "example": "scheduled",
            "type": "string"
          },
          "throttle_per_minute": {
            "description": "Techo de envíos por minuto que respeta el despachador.",
            "example": 60,
            "type": "number"
          },
          "timezone": {
            "description": "Zona horaria IANA con la que se interpreta `recurrence_time`.",
            "example": "America/Bogota",
            "nullable": true,
            "type": "string"
          },
          "total_recipients": {
            "description": "Contactos que quedaron materializados como destinatarios.",
            "example": 812,
            "type": "number"
          },
          "updated_at": {
            "example": "2026-07-28T16:04:11.220Z",
            "type": "string"
          },
          "workspace_id": {
            "example": 134,
            "type": "number"
          }
        },
        "required": [
          "id",
          "workspace_id",
          "name",
          "flow_id",
          "filters",
          "throttle_per_minute",
          "status",
          "send_mode",
          "source_broadcast_id",
          "scheduled_at",
          "recurrence",
          "recurrence_time",
          "recurrence_dow",
          "recurrence_dom",
          "timezone",
          "next_run_at",
          "total_recipients",
          "sent_count",
          "failed_count",
          "created_by",
          "created_at",
          "updated_at",
          "started_at",
          "finished_at",
          "flow_name"
        ],
        "type": "object"
      },
      "BroadcastPreviewCountResponseDto": {
        "properties": {
          "count": {
            "description": "Cuántos contactos cumplen hoy las condiciones que mandaste.",
            "example": 812,
            "type": "number"
          }
        },
        "required": [
          "count"
        ],
        "type": "object"
      },
      "BroadcastResponseDto": {
        "properties": {
          "created_at": {
            "example": "2026-07-28T16:04:11.220Z",
            "type": "string"
          },
          "created_by": {
            "description": "Usuario que la creó. `null` si la creó una automatización.",
            "example": 42,
            "nullable": true,
            "type": "number"
          },
          "failed_count": {
            "example": 3,
            "type": "number"
          },
          "filters": {
            "description": "Condiciones del segmento, tal como se guardaron. Se combinan con AND; vacío\nsignifica \"todos los contactos\".",
            "items": {
              "type": "object",
              "additionalProperties": true
            },
            "type": "array"
          },
          "finished_at": {
            "description": "Cuándo llegó a un estado terminal. `null` mientras siga viva.",
            "nullable": true,
            "type": "string"
          },
          "flow_id": {
            "description": "UUID del flujo publicado que se ejecuta por cada contacto del segmento.",
            "example": "9c0d5f2a-11b8-4f3e-8f22-6d3a7c4e1b90",
            "type": "string"
          },
          "id": {
            "description": "UUID de la difusión.",
            "example": "3f2b1c9e-7a41-4d0c-9c11-8a2f0e5d6b77",
            "type": "string"
          },
          "name": {
            "description": "Nombre con el que la ves en el listado.",
            "example": "Recordatorio de renovación · julio",
            "type": "string"
          },
          "next_run_at": {
            "description": "Próximo disparo calculado de una difusión recurrente.",
            "example": "2026-07-31T13:00:00.000Z",
            "nullable": true,
            "type": "string"
          },
          "recurrence": {
            "enum": [
              "none",
              "daily",
              "weekly",
              "monthly"
            ],
            "example": "none",
            "type": "string"
          },
          "recurrence_dom": {
            "description": "Día del mes del disparo, 1–31 (se ajusta en meses cortos). Solo `monthly`.",
            "example": null,
            "nullable": true,
            "type": "number"
          },
          "recurrence_dow": {
            "description": "Día de la semana del disparo, 0 = domingo. Solo con `recurrence: \"weekly\"`.",
            "example": null,
            "nullable": true,
            "type": "number"
          },
          "recurrence_time": {
            "description": "Hora local del disparo automático, `HH:MM` en 24 h. Solo si es recurrente.",
            "example": "08:00",
            "nullable": true,
            "type": "string"
          },
          "scheduled_at": {
            "description": "ISO 8601. Solo tiene valor con `send_mode: \"scheduled\"`.",
            "example": "2026-08-01T14:00:00.000Z",
            "nullable": true,
            "type": "string"
          },
          "send_mode": {
            "description": "`now` la toma el próximo tick; `scheduled` espera `scheduled_at`; `manual` es\nuna plantilla que dispara un nodo de flujo; `recurring` se dispara sola.",
            "enum": [
              "now",
              "scheduled",
              "manual",
              "recurring"
            ],
            "example": "now",
            "type": "string"
          },
          "sent_count": {
            "example": 640,
            "type": "number"
          },
          "source_broadcast_id": {
            "description": "Si esta fila es una **corrida** disparada desde una plantilla manual o\nrecurrente, aquí va el id de esa plantilla. `null` en las difusiones normales.",
            "example": null,
            "nullable": true,
            "type": "string"
          },
          "started_at": {
            "description": "Cuándo empezó a despacharse. `null` mientras no arrancó.",
            "nullable": true,
            "type": "string"
          },
          "status": {
            "description": "`draft` es la plantilla manual en reposo; `scheduled` espera su turno;\n`running` está despachando; `completed` y `cancelled` son terminales.",
            "enum": [
              "draft",
              "scheduled",
              "running",
              "completed",
              "cancelled"
            ],
            "example": "scheduled",
            "type": "string"
          },
          "throttle_per_minute": {
            "description": "Techo de envíos por minuto que respeta el despachador.",
            "example": 60,
            "type": "number"
          },
          "timezone": {
            "description": "Zona horaria IANA con la que se interpreta `recurrence_time`.",
            "example": "America/Bogota",
            "nullable": true,
            "type": "string"
          },
          "total_recipients": {
            "description": "Contactos que quedaron materializados como destinatarios.",
            "example": 812,
            "type": "number"
          },
          "updated_at": {
            "example": "2026-07-28T16:04:11.220Z",
            "type": "string"
          },
          "workspace_id": {
            "example": 134,
            "type": "number"
          }
        },
        "required": [
          "id",
          "workspace_id",
          "name",
          "flow_id",
          "filters",
          "throttle_per_minute",
          "status",
          "send_mode",
          "source_broadcast_id",
          "scheduled_at",
          "recurrence",
          "recurrence_time",
          "recurrence_dow",
          "recurrence_dom",
          "timezone",
          "next_run_at",
          "total_recipients",
          "sent_count",
          "failed_count",
          "created_by",
          "created_at",
          "updated_at",
          "started_at",
          "finished_at"
        ],
        "type": "object"
      },
      "BulkDeleteContactsDto": {
        "properties": {
          "contact_ids": {
            "items": {
              "type": "number"
            },
            "maxItems": 500,
            "minItems": 1,
            "type": "array"
          }
        },
        "required": [
          "contact_ids"
        ],
        "type": "object"
      },
      "BulkDeleteResultDto": {
        "properties": {
          "deleted": {
            "example": 12,
            "type": "number"
          },
          "requested": {
            "example": 15,
            "type": "number"
          }
        },
        "required": [
          "deleted",
          "requested"
        ],
        "type": "object"
      },
      "BulkTagDto": {
        "properties": {
          "contact_ids": {
            "items": {
              "type": "number"
            },
            "maxItems": 500,
            "minItems": 1,
            "type": "array"
          },
          "tag": {
            "maxLength": 60,
            "minLength": 1,
            "type": "string"
          }
        },
        "required": [
          "contact_ids",
          "tag"
        ],
        "type": "object"
      },
      "BulkTagResultDto": {
        "properties": {
          "requested": {
            "example": 15,
            "type": "number"
          },
          "tag": {
            "description": "La etiqueta, ya normalizada (sin espacios al borde).",
            "example": "lead-caliente",
            "type": "string"
          },
          "updated": {
            "example": 9,
            "type": "number"
          }
        },
        "required": [
          "updated",
          "requested",
          "tag"
        ],
        "type": "object"
      },
      "ChatConversationResponseDto": {
        "additionalProperties": true,
        "properties": {
          "context": {
            "additionalProperties": true,
            "description": "Contexto con el que se abrió la conversación (desde qué pantalla, sobre qué).",
            "type": "object"
          },
          "created_at": {
            "example": "2026-07-30T04:12:33.120Z",
            "nullable": true,
            "type": "string"
          },
          "id": {
            "example": 1842,
            "type": "number"
          },
          "is_archived": {
            "example": false,
            "type": "boolean"
          },
          "is_main": {
            "description": "`true` en la conversación principal, la que el panel abre por defecto. Hay una\nsola por persona y se crea sola la primera vez que se pide.",
            "example": false,
            "type": "boolean"
          },
          "title": {
            "example": "Cierre de mes",
            "nullable": true,
            "type": "string"
          },
          "updated_at": {
            "nullable": true,
            "type": "string"
          },
          "user_id": {
            "description": "Dueño de la conversación. Cada persona tiene las suyas; no se comparten.",
            "example": 41,
            "type": "number"
          },
          "workspace_id": {
            "example": 3,
            "type": "number"
          }
        },
        "required": [
          "id",
          "workspace_id",
          "user_id",
          "title"
        ],
        "type": "object"
      },
      "ChatMessageResponseDto": {
        "additionalProperties": true,
        "properties": {
          "content": {
            "example": "Listo, agendé el recordatorio para mañana.",
            "type": "string"
          },
          "conversation_id": {
            "example": 1842,
            "type": "number"
          },
          "created_at": {
            "example": "2026-07-30T04:12:33.120Z",
            "nullable": true,
            "type": "string"
          },
          "id": {
            "example": 90312,
            "type": "number"
          },
          "metadata": {
            "additionalProperties": true,
            "description": "Metadata del turno: adjuntos, traza del orquestador, acciones ejecutadas.\n\nLas URL de `metadata.attachments` se **re-firman en cada lectura** porque el\narchivo vive en el bucket privado. Son temporales por definición — no las\nguardes ni las compartas, pedí los mensajes de nuevo cuando las necesites.",
            "nullable": true,
            "type": "object"
          },
          "role": {
            "enum": [
              "user",
              "assistant"
            ],
            "example": "assistant",
            "type": "string"
          },
          "thread_id": {
            "description": "`null` en los mensajes del hilo principal; con valor, el mensaje vive en un hilo.",
            "example": null,
            "nullable": true,
            "type": "number"
          },
          "tokens_used": {
            "nullable": true,
            "type": "number"
          }
        },
        "required": [
          "id",
          "conversation_id",
          "thread_id",
          "role",
          "content",
          "metadata"
        ],
        "type": "object"
      },
      "ChatMessagesResponseDto": {
        "properties": {
          "messages": {
            "items": {
              "$ref": "#/components/schemas/ChatMessageResponseDto"
            },
            "type": "array"
          },
          "threads": {
            "items": {
              "$ref": "#/components/schemas/ChatThreadResponseDto"
            },
            "type": "array"
          }
        },
        "required": [
          "messages",
          "threads"
        ],
        "type": "object"
      },
      "ChatThreadMessagesResponseDto": {
        "properties": {
          "messages": {
            "items": {
              "$ref": "#/components/schemas/ChatMessageResponseDto"
            },
            "type": "array"
          },
          "thread": {
            "$ref": "#/components/schemas/ChatThreadSummaryDto"
          }
        },
        "required": [
          "messages",
          "thread"
        ],
        "type": "object"
      },
      "ChatThreadResponseDto": {
        "additionalProperties": true,
        "properties": {
          "context_data": {
            "additionalProperties": true,
            "type": "object"
          },
          "context_id": {
            "description": "Id numérico de la entidad del contexto (ítem, colección). `null` si no aplica.",
            "example": 9812,
            "nullable": true,
            "type": "number"
          },
          "context_id_text": {
            "description": "Id de texto del contexto, para entidades cuyo id no es numérico (tareas).",
            "nullable": true,
            "type": "string"
          },
          "context_type": {
            "description": "Sobre qué se abrió el hilo.",
            "enum": [
              "item",
              "collection",
              "task",
              "general"
            ],
            "example": "item",
            "type": "string"
          },
          "conversation_id": {
            "example": 1842,
            "type": "number"
          },
          "created_at": {
            "nullable": true,
            "type": "string"
          },
          "id": {
            "example": 771,
            "type": "number"
          },
          "is_closed": {
            "example": false,
            "type": "boolean"
          },
          "title": {
            "example": "Propuesta Acme",
            "nullable": true,
            "type": "string"
          },
          "updated_at": {
            "nullable": true,
            "type": "string"
          }
        },
        "required": [
          "id",
          "conversation_id",
          "context_type",
          "context_id",
          "context_id_text",
          "title"
        ],
        "type": "object"
      },
      "ChatThreadSummaryDto": {
        "properties": {
          "context_id": {
            "example": 9812,
            "nullable": true,
            "type": "number"
          },
          "context_id_text": {
            "nullable": true,
            "type": "string"
          },
          "context_type": {
            "enum": [
              "item",
              "collection",
              "task",
              "general"
            ],
            "example": "item",
            "type": "string"
          },
          "conversation_id": {
            "example": 1842,
            "type": "number"
          },
          "id": {
            "example": 771,
            "type": "number"
          },
          "title": {
            "example": "Propuesta Acme",
            "nullable": true,
            "type": "string"
          }
        },
        "required": [
          "id",
          "conversation_id",
          "context_type",
          "context_id",
          "context_id_text",
          "title"
        ],
        "type": "object"
      },
      "ClientConsumptionRowDto": {
        "properties": {
          "dim_key": {
            "description": "Identificador del elemento agrupado. Qué representa depende del `by` que\npediste: el contacto, el miembro del equipo, la conversación o el Met.",
            "example": 41207,
            "type": "number"
          },
          "energia_usd": {
            "description": "Energía consumida por ese elemento, en USD.",
            "example": 1.2043,
            "type": "number"
          },
          "executions": {
            "example": 214,
            "type": "number"
          },
          "time_saved_minutes": {
            "example": 856,
            "type": "number"
          }
        },
        "required": [
          "dim_key",
          "energia_usd",
          "executions",
          "time_saved_minutes"
        ],
        "type": "object"
      },
      "ClientExecutionDto": {
        "properties": {
          "cost_final_usd": {
            "description": "Energía debitada por esta ejecución, en USD.",
            "example": 0.0123,
            "type": "number"
          },
          "created_at": {
            "example": "2026-07-29T14:02:11.000Z",
            "type": "string"
          },
          "executed_at": {
            "example": "2026-07-29T14:02:11.000Z",
            "type": "string"
          },
          "execution_id": {
            "description": "Identificador de la ejecución. Es la llave para cruzarla con su traza.",
            "example": "exec_01HZ…",
            "type": "string"
          },
          "execution_type": {
            "description": "Qué originó la ejecución.",
            "example": "chat",
            "type": "string"
          },
          "met_id": {
            "description": "Met que la ejecutó.",
            "example": 41207,
            "nullable": true,
            "type": "number"
          },
          "met_name": {
            "example": "Ventas",
            "nullable": true,
            "type": "string"
          },
          "model_display": {
            "description": "Nombre de marca del modelo.",
            "example": "Brillante",
            "nullable": true,
            "type": "string"
          },
          "status": {
            "example": "completed",
            "type": "string"
          },
          "time_saved_minutes": {
            "description": "Minutos de trabajo humano que la ejecución ahorró, según su tipo.",
            "example": 4,
            "nullable": true,
            "type": "number"
          }
        },
        "required": [
          "execution_id",
          "executed_at",
          "created_at",
          "met_id",
          "met_name",
          "model_display",
          "execution_type",
          "cost_final_usd",
          "time_saved_minutes",
          "status"
        ],
        "type": "object"
      },
      "ClientExecutionTotalsDto": {
        "properties": {
          "cost_final_usd": {
            "description": "Energía total debitada, en USD.",
            "example": 12.4183,
            "type": "number"
          },
          "time_saved_minutes": {
            "example": 940,
            "type": "number"
          }
        },
        "required": [
          "cost_final_usd",
          "time_saved_minutes"
        ],
        "type": "object"
      },
      "ClientExecutionsPageDto": {
        "properties": {
          "limit": {
            "example": 50,
            "type": "number"
          },
          "offset": {
            "example": 0,
            "type": "number"
          },
          "rows": {
            "items": {
              "$ref": "#/components/schemas/ClientExecutionDto"
            },
            "type": "array"
          },
          "total": {
            "description": "Cuántas ejecuciones cumplen el filtro, más allá de esta página.",
            "example": 3120,
            "type": "number"
          },
          "totals": {
            "allOf": [
              {
                "$ref": "#/components/schemas/ClientExecutionTotalsDto"
              }
            ],
            "description": "`null` si el cálculo de totales falló; las filas igual son válidas.",
            "nullable": true
          }
        },
        "required": [
          "rows",
          "total",
          "limit",
          "offset",
          "totals"
        ],
        "type": "object"
      },
      "CollectionFieldResponseDto": {
        "additionalProperties": true,
        "properties": {
          "collection_id": {
            "example": 12,
            "type": "number"
          },
          "created_at": {
            "example": "2026-07-30T04:12:33.120Z",
            "nullable": true,
            "type": "string"
          },
          "id": {
            "example": 4471,
            "type": "number"
          },
          "label": {
            "description": "Nombre visible, con mayúsculas, tildes y espacios. `null` = se muestra `name`.",
            "example": "Monto estimado",
            "nullable": true,
            "type": "string"
          },
          "name": {
            "description": "Slug de la columna. Es la **clave** con la que el valor vive dentro de\n`item.data`, y por eso no se puede renombrar: cambiarla desconectaría los\nítems existentes.",
            "example": "monto_estimado",
            "type": "string"
          },
          "required": {
            "example": false,
            "type": "boolean"
          },
          "type": {
            "description": "Tipo de la columna. El catálogo lo fija un CHECK en la base.",
            "example": "number",
            "type": "string"
          },
          "validation_rules": {
            "additionalProperties": true,
            "description": "Config del tipo. Para `select` trae `options` (el conjunto CERRADO de valores\nadmitidos al escribir); para columnas computadas, la fórmula o el lookup.",
            "nullable": true,
            "type": "object"
          }
        },
        "required": [
          "id",
          "collection_id",
          "name",
          "type"
        ],
        "type": "object"
      },
      "CollectionMessageResponseDto": {
        "properties": {
          "message": {
            "description": "Texto fijo en inglés — es un acuse, no copy de producto.",
            "example": "Collection deleted",
            "type": "string"
          }
        },
        "required": [
          "message"
        ],
        "type": "object"
      },
      "CollectionMoveResponseDto": {
        "properties": {
          "folder_id": {
            "description": "La carpeta destino. `null` = quedó en la raíz del workspace.",
            "example": "5f0a1e3c-9b2d-4a77-8f31-6c1d0e2b4a99",
            "nullable": true,
            "type": "string"
          },
          "id": {
            "example": 12,
            "type": "number"
          }
        },
        "required": [
          "id",
          "folder_id"
        ],
        "type": "object"
      },
      "CollectionPinResponseDto": {
        "properties": {
          "id": {
            "example": 12,
            "type": "number"
          },
          "pinned_to_menu": {
            "example": true,
            "type": "boolean"
          },
          "workspace_id": {
            "example": 134,
            "type": "number"
          }
        },
        "required": [
          "id",
          "pinned_to_menu",
          "workspace_id"
        ],
        "type": "object"
      },
      "CollectionResponseDto": {
        "additionalProperties": true,
        "properties": {
          "code": {
            "nullable": true,
            "type": "object"
          },
          "created_at": {
            "nullable": true,
            "type": "object"
          },
          "id": {
            "example": 12,
            "type": "number"
          },
          "name": {
            "example": "Inmuebles",
            "type": "string"
          },
          "slug": {
            "example": "inmuebles",
            "nullable": true,
            "type": "object"
          }
        },
        "required": [
          "id",
          "name"
        ],
        "type": "object"
      },
      "CollectionSearchResultDto": {
        "properties": {
          "code": {
            "example": "AB3K9Z",
            "nullable": true,
            "type": "string"
          },
          "folder_id": {
            "nullable": true,
            "type": "string"
          },
          "id": {
            "example": 12,
            "type": "number"
          },
          "name": {
            "example": "Inmuebles",
            "type": "string"
          },
          "slug": {
            "example": "inmuebles",
            "nullable": true,
            "type": "string"
          },
          "visibility": {
            "example": "private",
            "type": "string"
          }
        },
        "required": [
          "id",
          "name",
          "slug",
          "code",
          "visibility",
          "folder_id"
        ],
        "type": "object"
      },
      "CollectionViewResponseDto": {
        "properties": {
          "collection_id": {
            "example": 12,
            "type": "number"
          },
          "column_order": {
            "description": "Orden de las columnas, por `name`. Vacío = el orden del esquema.",
            "items": {
              "type": "string"
            },
            "type": "array"
          },
          "column_widths": {
            "additionalProperties": {
              "type": "number"
            },
            "description": "Ancho en px por columna, indexado por `name`.",
            "type": "object"
          },
          "compact": {
            "example": false,
            "type": "boolean"
          },
          "created_at": {
            "example": "2026-07-30T04:12:33.120Z",
            "type": "string"
          },
          "created_by": {
            "example": 91,
            "nullable": true,
            "type": "number"
          },
          "filters": {
            "description": "Filtros aplicados. Cada elemento es una condición; la forma la fija el cliente.",
            "items": {
              "additionalProperties": true,
              "type": "object"
            },
            "type": "array"
          },
          "hidden_columns": {
            "description": "`name` de las columnas ocultas en esta vista.",
            "example": [
              "notas_internas"
            ],
            "items": {
              "type": "string"
            },
            "type": "array"
          },
          "id": {
            "example": 88,
            "type": "number"
          },
          "kanban_field": {
            "description": "Columna que agrupa las tarjetas en modo kanban.",
            "example": "etapa",
            "nullable": true,
            "type": "string"
          },
          "kanban_subtitle_field": {
            "nullable": true,
            "type": "string"
          },
          "kanban_title_field": {
            "nullable": true,
            "type": "string"
          },
          "kanban_total_field": {
            "description": "Columna numérica que se suma en el encabezado de cada columna del kanban.",
            "nullable": true,
            "type": "string"
          },
          "mode": {
            "description": "Cómo se pinta la vista: tabla, kanban, calendario…",
            "example": "list",
            "type": "string"
          },
          "name": {
            "example": "Cierres del trimestre",
            "type": "string"
          },
          "position": {
            "description": "Posición de la pestaña. Lo persiste el arrastre de pestañas.",
            "example": 0,
            "type": "number"
          },
          "sort": {
            "allOf": [
              {
                "$ref": "#/components/schemas/CollectionViewSortDto"
              }
            ],
            "nullable": true
          },
          "updated_at": {
            "example": "2026-07-30T04:12:33.120Z",
            "type": "string"
          }
        },
        "required": [
          "id",
          "collection_id",
          "name",
          "mode",
          "filters",
          "sort",
          "hidden_columns",
          "kanban_field",
          "kanban_title_field",
          "kanban_subtitle_field",
          "kanban_total_field",
          "compact",
          "column_widths",
          "column_order",
          "position",
          "created_by",
          "created_at",
          "updated_at"
        ],
        "type": "object"
      },
      "CollectionViewSortDto": {
        "properties": {
          "direction": {
            "enum": [
              "asc",
              "desc"
            ],
            "example": "desc",
            "type": "string"
          },
          "field": {
            "description": "`name` de la columna por la que se ordena.",
            "example": "monto_estimado",
            "type": "string"
          }
        },
        "required": [
          "field",
          "direction"
        ],
        "type": "object"
      },
      "ConnectFlowDto": {
        "properties": {
          "flow_id": {
            "description": "ID (uuid) del flow a ejecutar cuando llegue un evento a este webhook.",
            "minLength": 1,
            "type": "string"
          }
        },
        "required": [
          "flow_id"
        ],
        "type": "object"
      },
      "ConnectedFlowDto": {
        "properties": {
          "id": {
            "example": "5f0a1e3c-9b2d-4a77-8f31-6c1d0e2b4a99",
            "type": "string"
          },
          "name": {
            "example": "Alta de pedido",
            "type": "string"
          }
        },
        "required": [
          "id",
          "name"
        ],
        "type": "object"
      },
      "ContactCountsChannelDto": {
        "properties": {
          "id": {
            "example": 5,
            "type": "number"
          },
          "name": {
            "example": "WhatsApp Ventas",
            "type": "string"
          },
          "type": {
            "example": "whatsapp",
            "nullable": true,
            "type": "string"
          }
        },
        "required": [
          "id",
          "name",
          "type"
        ],
        "type": "object"
      },
      "ContactCountsDto": {
        "properties": {
          "archived": {
            "example": 25,
            "type": "number"
          },
          "byChannel": {
            "additionalProperties": {
              "type": "number"
            },
            "description": "Conteo por canal. La clave es el **nombre** del canal, no su id.",
            "example": {
              "WhatsApp Ventas": 812
            },
            "type": "object"
          },
          "byGroup": {
            "additionalProperties": {
              "type": "number"
            },
            "description": "Conteo por grupo de atención. La clave es el id del grupo como string.",
            "example": {
              "3": 120
            },
            "type": "object"
          },
          "byUser": {
            "additionalProperties": {
              "type": "number"
            },
            "description": "Conteo por asesor. La clave es el id del usuario como string.",
            "example": {
              "42": 18
            },
            "type": "object"
          },
          "channels": {
            "items": {
              "$ref": "#/components/schemas/ContactCountsChannelDto"
            },
            "type": "array"
          },
          "finished": {
            "example": 900,
            "type": "number"
          },
          "human_requested": {
            "description": "Conversaciones donde el contacto pidió hablar con una persona.",
            "example": 7,
            "type": "number"
          },
          "mine": {
            "description": "Asignadas al usuario que consulta. Con una API key es 0 (no hay asesor).",
            "example": 18,
            "type": "number"
          },
          "open": {
            "example": 312,
            "type": "number"
          },
          "pending": {
            "example": 40,
            "type": "number"
          },
          "scopeTotal": {
            "description": "Universo de la carpeta elegida (asesor, grupo o canal), ignorando estado,\nbúsqueda y filtro avanzado. Es el denominador honesto de \"viendo N de M\":\n`total` cambia con cada filtro, así que no sirve para decir de cuánto se\nestá viendo una parte.",
            "example": 164,
            "type": "number"
          },
          "total": {
            "description": "Bandeja \"Todos\": cumple los filtros activos **menos** el de asignación. Sin\nfiltros, el total del workspace.",
            "example": 1284,
            "type": "number"
          },
          "unassigned": {
            "example": 96,
            "type": "number"
          }
        },
        "required": [
          "total",
          "scopeTotal",
          "open",
          "pending",
          "human_requested",
          "finished",
          "archived",
          "mine",
          "unassigned",
          "byChannel",
          "byGroup",
          "byUser",
          "channels"
        ],
        "type": "object"
      },
      "ContactDeletedDto": {
        "properties": {
          "id": {
            "example": 4821,
            "type": "number"
          },
          "message": {
            "example": "Contact deleted",
            "type": "string"
          }
        },
        "required": [
          "message",
          "id"
        ],
        "type": "object"
      },
      "ContactDuplicatesResponseDto": {
        "properties": {
          "data": {
            "items": {
              "$ref": "#/components/schemas/DuplicateCandidateDto"
            },
            "type": "array"
          }
        },
        "required": [
          "data"
        ],
        "type": "object"
      },
      "ContactEnrichResultDto": {
        "properties": {
          "filled": {
            "description": "Claves de los campos que se completaron (`empresa`, `cargo`, `$city`, `$country`).",
            "example": [
              "empresa",
              "cargo"
            ],
            "items": {
              "type": "string"
            },
            "type": "array"
          },
          "sources": {
            "description": "URLs de donde salió cada dato. También quedan en una nota del contacto.",
            "example": [
              "https://ejemplo.com/equipo"
            ],
            "items": {
              "type": "string"
            },
            "type": "array"
          }
        },
        "required": [
          "filled",
          "sources"
        ],
        "type": "object"
      },
      "ContactExtractResultDto": {
        "properties": {
          "filled": {
            "description": "Claves de los campos que se completaron. Nunca pisa un dato que ya existía.",
            "example": [
              "empresa",
              "presupuesto"
            ],
            "items": {
              "type": "string"
            },
            "type": "array"
          },
          "lead_score": {
            "description": "Qué tan cerca de comprar está (0-100). A diferencia de los campos, se\n**recalcula en cada llamada**: es un juicio, no un dato. `null` si no se\ncalculó. El motivo queda en `data.lead_score_motivo` del contacto.",
            "example": 72,
            "nullable": true,
            "type": "number"
          }
        },
        "required": [
          "filled"
        ],
        "type": "object"
      },
      "ContactFieldDefinitionDto": {
        "properties": {
          "created_at": {
            "example": "2026-07-30T04:12:33.120Z",
            "type": "string"
          },
          "description": {
            "example": "Ciudad donde se entrega el pedido",
            "nullable": true,
            "type": "string"
          },
          "field_key": {
            "description": "Clave del campo: se usa en las plantillas como `$contact.<field_key>`.",
            "example": "ciudad_entrega",
            "type": "string"
          },
          "id": {
            "example": 17,
            "type": "number"
          },
          "label": {
            "description": "Nombre visible del campo en la interfaz.",
            "example": "Ciudad de entrega",
            "type": "string"
          },
          "options": {
            "description": "Config extra del tipo: para `select`, los valores permitidos; para `currency`,\nel código ISO de la moneda (un solo elemento). Vacío para los demás tipos.",
            "example": [
              "Bogotá",
              "Medellín",
              "Cali"
            ],
            "items": {
              "type": "string"
            },
            "type": "array"
          },
          "type": {
            "enum": [
              "text",
              "number",
              "boolean",
              "date",
              "datetime",
              "json",
              "select",
              "currency"
            ],
            "example": "select",
            "type": "string"
          },
          "workspace_id": {
            "example": 134,
            "type": "number"
          }
        },
        "required": [
          "id",
          "workspace_id",
          "field_key",
          "label",
          "type",
          "description",
          "options",
          "created_at"
        ],
        "type": "object"
      },
      "ContactImportErrorDto": {
        "properties": {
          "reason": {
            "example": "phone o email es obligatorio",
            "type": "string"
          },
          "row": {
            "description": "Posición de la fila dentro del array `contacts` que mandaste (base 0).",
            "example": 17,
            "type": "number"
          }
        },
        "required": [
          "row",
          "reason"
        ],
        "type": "object"
      },
      "ContactImportResultDto": {
        "properties": {
          "created": {
            "example": 412,
            "type": "number"
          },
          "errors": {
            "items": {
              "$ref": "#/components/schemas/ContactImportErrorDto"
            },
            "type": "array"
          },
          "skipped": {
            "example": 8,
            "type": "number"
          },
          "updated": {
            "description": "Existían y se les rellenaron los campos vacíos (merge fill-only).",
            "example": 63,
            "type": "number"
          }
        },
        "required": [
          "created",
          "updated",
          "skipped",
          "errors"
        ],
        "type": "object"
      },
      "ContactListResponseDto": {
        "properties": {
          "data": {
            "items": {
              "$ref": "#/components/schemas/ContactRecordDto"
            },
            "type": "array"
          },
          "has_more": {
            "example": true,
            "type": "boolean"
          },
          "total": {
            "example": 1284,
            "type": "number"
          }
        },
        "required": [
          "data",
          "total",
          "has_more"
        ],
        "type": "object"
      },
      "ContactMessageAttachmentDto": {
        "properties": {
          "kind": {
            "type": "string"
          },
          "mime_type": {
            "type": "string"
          },
          "name": {
            "type": "string"
          },
          "size": {
            "type": "number"
          },
          "url": {
            "type": "string"
          }
        },
        "required": [
          "url"
        ],
        "type": "object"
      },
      "ContactMessageDto": {
        "additionalProperties": true,
        "properties": {
          "agent_id": {
            "description": "Met que produjo el mensaje, cuando `role` es `agent`.",
            "example": 77,
            "nullable": true,
            "type": "number"
          },
          "attachments": {
            "description": "Adjuntos del mensaje (`{ url, mime_type, name, size, kind }`).",
            "items": {
              "additionalProperties": true,
              "type": "object"
            },
            "type": "array"
          },
          "channel_id": {
            "example": 5,
            "type": "number"
          },
          "contact_id": {
            "example": 4821,
            "type": "number"
          },
          "content": {
            "description": "Texto del mensaje. En mensajes de solo adjunto puede venir vacío.",
            "example": "¿Todavía tienen disponibilidad para el viernes?",
            "type": "string"
          },
          "created_at": {
            "example": "2026-07-30T04:12:33.120Z",
            "nullable": true,
            "type": "string"
          },
          "id": {
            "example": 918273,
            "type": "number"
          },
          "message_type": {
            "description": "Qué clase de mensaje es: `text`, `image`, `audio`, `video`, `document`,\n`location`, `template`, `note` (nota interna, nunca se envió al contacto),\n`system_event` o `tool_use`.",
            "example": "text",
            "type": "string"
          },
          "metadata": {
            "additionalProperties": true,
            "description": "Metadatos del mensaje. En `template` lleva `template.{name,language,params}`;\nen `tool_use` el JSON de la invocación; en los de WhatsApp el estado de\nentrega que reporta Meta.",
            "type": "object"
          },
          "role": {
            "description": "Quién habló: el contacto (`user`), tu equipo (`operator`) o el Met (`agent`).",
            "enum": [
              "user",
              "operator",
              "agent"
            ],
            "example": "user",
            "type": "string"
          },
          "sent_by_name": {
            "description": "Nombre visible de `sent_by_user_id`, ya resuelto. `null` cuando no lo mandó\nuna persona. **Solo viene en `GET /contacts/{id}/messages`**; el mensaje que\ndevuelve un envío no lo trae.",
            "example": "Ana Ruiz",
            "nullable": true,
            "type": "string"
          },
          "sent_by_user_id": {
            "description": "Persona de tu equipo que lo envió, cuando `role` es `operator`.",
            "example": 42,
            "nullable": true,
            "type": "number"
          },
          "source": {
            "description": "De dónde entró o salió el mensaje. `null` para los que no lo declaran.",
            "example": "whatsapp",
            "nullable": true,
            "type": "string"
          }
        },
        "required": [
          "id",
          "contact_id",
          "channel_id",
          "role",
          "content",
          "message_type"
        ],
        "type": "object"
      },
      "ContactMessageSearchResultDto": {
        "properties": {
          "content": {
            "nullable": true,
            "type": "string"
          },
          "created_at": {
            "example": "2026-07-30T04:12:33.120Z",
            "nullable": true,
            "type": "string"
          },
          "id": {
            "example": 918273,
            "type": "number"
          },
          "role": {
            "enum": [
              "user",
              "operator",
              "agent"
            ],
            "example": "user",
            "type": "string"
          }
        },
        "required": [
          "id",
          "content",
          "role",
          "created_at"
        ],
        "type": "object"
      },
      "ContactNoteDto": {
        "properties": {
          "content": {
            "example": "Pidió una demo para el viernes.",
            "type": "string"
          },
          "created_at": {
            "example": "2026-07-30T04:12:33.120Z",
            "nullable": true,
            "type": "string"
          },
          "id": {
            "example": 918274,
            "type": "number"
          },
          "metadata": {
            "additionalProperties": true,
            "type": "object"
          },
          "role": {
            "description": "Siempre `operator`: las notas las escribe una persona.",
            "example": "operator",
            "type": "string"
          },
          "sent_by_user_id": {
            "example": 42,
            "nullable": true,
            "type": "number"
          }
        },
        "required": [
          "id",
          "content",
          "role",
          "created_at",
          "sent_by_user_id"
        ],
        "type": "object"
      },
      "ContactRecordDto": {
        "additionalProperties": true,
        "properties": {
          "channel_id": {
            "description": "Canal por el que se conversa con este contacto (resuelto desde `data.$channel_id`).",
            "example": 5,
            "nullable": true,
            "type": "number"
          },
          "channel_name": {
            "example": "WhatsApp Ventas",
            "nullable": true,
            "type": "string"
          },
          "channel_type": {
            "example": "whatsapp",
            "nullable": true,
            "type": "string"
          },
          "code": {
            "description": "Código corto del registro. No es la identidad del contacto en el canal.",
            "example": "K7F2QA",
            "nullable": true,
            "type": "string"
          },
          "collection_id": {
            "description": "Colección `_contacts` del workspace a la que pertenece.",
            "example": 137,
            "type": "number"
          },
          "created_at": {
            "example": "2026-07-30T04:12:33.120Z",
            "nullable": true,
            "type": "string"
          },
          "data": {
            "additionalProperties": true,
            "description": "Los campos del contacto. Sistema con `$` (`$name`, `$phone`, `$email`,\n`$status`, `$tags`, `$channel_id`, `$user_ns`, `$assigned_user_id`,\n`$autopilot_enabled`, `$last_message_at`); personalizados con su `field_key`\npelado. Descubrí los personalizados del workspace con\n`GET /variables/contact-fields`.",
            "example": {
              "$name": "Ada Lovelace",
              "$phone": "+573001112233",
              "etapa": "Negociación"
            },
            "type": "object"
          },
          "id": {
            "example": 4821,
            "type": "number"
          },
          "updated_at": {
            "nullable": true,
            "type": "string"
          }
        },
        "required": [
          "id",
          "collection_id",
          "data",
          "channel_id",
          "channel_name",
          "channel_type"
        ],
        "type": "object"
      },
      "ContactTagDeletedResponseDto": {
        "properties": {
          "ok": {
            "example": true,
            "type": "boolean"
          }
        },
        "required": [
          "ok"
        ],
        "type": "object"
      },
      "ContactTagResponseDto": {
        "properties": {
          "id": {
            "example": 74,
            "type": "number"
          },
          "name": {
            "description": "Único por workspace, sin distinguir mayúsculas: `Lead` y `lead` chocan.",
            "example": "lead-caliente",
            "type": "string"
          }
        },
        "required": [
          "id",
          "name"
        ],
        "type": "object"
      },
      "ContactTimelineResponseDto": {
        "properties": {
          "data": {
            "items": {
              "$ref": "#/components/schemas/TimelineEntryDto"
            },
            "type": "array"
          },
          "has_more": {
            "example": false,
            "type": "boolean"
          }
        },
        "required": [
          "data",
          "has_more"
        ],
        "type": "object"
      },
      "ContactToolCallDto": {
        "properties": {
          "agent_id": {
            "description": "Qué Met la invocó.",
            "example": 77,
            "nullable": true,
            "type": "number"
          },
          "created_at": {
            "example": "2026-07-30T04:12:33.120Z",
            "nullable": true,
            "type": "string"
          },
          "duration_ms": {
            "example": 812,
            "nullable": true,
            "type": "number"
          },
          "error": {
            "nullable": true,
            "type": "string"
          },
          "id": {
            "example": 918273,
            "type": "number"
          },
          "input": {
            "additionalProperties": true,
            "description": "Argumentos con los que se invocó. Recortado a 50 KB al persistir.",
            "nullable": true,
            "type": "object"
          },
          "method": {
            "example": "events.create",
            "nullable": true,
            "type": "string"
          },
          "output": {
            "additionalProperties": true,
            "description": "Salida de la tool. Recortada a 50 KB al persistir.",
            "nullable": true,
            "type": "object"
          },
          "status": {
            "example": "ok",
            "nullable": true,
            "type": "string"
          },
          "tool": {
            "description": "Nombre de la integración o de la tool invocada.",
            "example": "google_calendar",
            "nullable": true,
            "type": "string"
          }
        },
        "required": [
          "id",
          "tool",
          "method",
          "status",
          "duration_ms",
          "input",
          "output",
          "error",
          "agent_id",
          "created_at"
        ],
        "type": "object"
      },
      "ContactsDeletedAllDto": {
        "properties": {
          "contacts_deleted": {
            "description": "Cuántos se borraron. Ausente si el workspace no tenía contactos.",
            "example": 1284,
            "type": "number"
          },
          "message": {
            "example": "All contacts deleted",
            "type": "string"
          }
        },
        "required": [
          "message"
        ],
        "type": "object"
      },
      "ContentBlockRemovedResponseDto": {
        "properties": {
          "ok": {
            "enum": [
              true
            ],
            "example": true,
            "type": "number"
          }
        },
        "required": [
          "ok"
        ],
        "type": "object"
      },
      "ContentBlockResponseDto": {
        "properties": {
          "created_at": {
            "example": "2026-07-30T04:12:33.120Z",
            "type": "string"
          },
          "data": {
            "additionalProperties": true,
            "description": "Contenido del bloque. **La forma depende de `type`** — `text` trae `html`,\n`image` trae `storage_path`, `task` trae `task_id`, y las referencias traen el\nid de lo que apuntan.\n\nAl **leer**, cada bloque que referencia otra entidad trae además\n`data.__hydrated` con su estado actual (nombre, estado, contadores) para\npintarlo sin un fetch extra. Si la entidad fue borrada, llega\n`__hydrated: { deleted: true }`. Ese bloque es **solo de lectura**: no se\nmanda de vuelta al escribir.",
            "type": "object"
          },
          "id": {
            "description": "UUID v4. Lo genera el backend al crear, salvo que el cliente mande el suyo.",
            "example": "5f0a1e3c-9b2d-4a77-8f31-6c1d0e2b4a99",
            "type": "string"
          },
          "type": {
            "enum": [
              "text",
              "heading",
              "image",
              "task",
              "file",
              "collection_ref",
              "item_ref",
              "contact_ref",
              "page_ref",
              "web_fields_ref"
            ],
            "example": "text",
            "type": "string"
          },
          "updated_at": {
            "example": "2026-07-30T04:12:33.120Z",
            "type": "string"
          }
        },
        "required": [
          "id",
          "type",
          "data",
          "created_at",
          "updated_at"
        ],
        "type": "object"
      },
      "CreateAgentDto": {
        "properties": {
          "instructions": {
            "description": "Instrucciones/prompt del agente. → data.system_prompt",
            "maxLength": 100000,
            "type": "string"
          },
          "mission": {
            "description": "Misión/descripción corta. → data.mision",
            "maxLength": 2000,
            "type": "string"
          },
          "model": {
            "description": "Cuánta cabeza le ponés al Met: `agil`, `brillante` o `genio`.\n\n→ `data.modelo`. Omitido = el default de la plataforma.\n\nEl enum publicado son los tres tiers y nada más. El validador todavía\nacepta ids de modelo (`ACCEPTED_MODEL_INPUTS`) para no romper integraciones\nviejas, pero **ya no se preservan**: se normalizan al modelo vigente del\ntier. Publicar menos de lo que se acepta es lo que hace que sacar los ids\ndel contrato no sea un breaking change.",
            "enum": [
              "agil",
              "brillante",
              "genio"
            ],
            "example": "brillante",
            "type": "string"
          },
          "name": {
            "maxLength": 120,
            "type": "string"
          },
          "title": {
            "description": "Cargo/rol del agente (ej. \"Vendedor\"). → data.cargo",
            "maxLength": 200,
            "type": "string"
          }
        },
        "required": [
          "name"
        ],
        "type": "object"
      },
      "CreateAgentGroupDto": {
        "properties": {
          "name": {
            "maxLength": 120,
            "type": "string"
          }
        },
        "required": [
          "name"
        ],
        "type": "object"
      },
      "CreateBlockDto": {
        "properties": {
          "endsAt": {
            "example": "2026-08-14T16:00:00.000Z",
            "type": "string"
          },
          "resourceId": {
            "description": "null = bloquea todo el negocio",
            "type": "number"
          },
          "startsAt": {
            "example": "2026-08-14T14:00:00.000Z",
            "type": "string"
          },
          "title": {
            "example": "Almuerzo",
            "maxLength": 160,
            "type": "string"
          }
        },
        "required": [
          "startsAt",
          "endsAt"
        ],
        "type": "object"
      },
      "CreateBroadcastDto": {
        "properties": {
          "filters": {
            "description": "Condiciones del segmento (AND). Vacío = todos los contactos.",
            "items": {
              "$ref": "#/components/schemas/SegmentConditionDto"
            },
            "type": "array"
          },
          "flow_id": {
            "description": "UUID del flujo publicado a ejecutar por cada contacto.",
            "type": "string"
          },
          "name": {
            "maxLength": 255,
            "type": "string"
          },
          "recurrence": {
            "enum": [
              "none",
              "daily",
              "weekly",
              "monthly"
            ],
            "type": "string"
          },
          "recurrence_dom": {
            "description": "Día del mes 1..31 (se clampa a meses cortos). Solo monthly.",
            "maximum": 31,
            "minimum": 1,
            "type": "number"
          },
          "recurrence_dow": {
            "description": "Día de la semana 0..6 (dom..sáb). Solo weekly.",
            "maximum": 6,
            "minimum": 0,
            "type": "number"
          },
          "recurrence_time": {
            "description": "Hora local del disparo, formato 'HH:MM' (24h).",
            "pattern": "/^([01]?\\d|2[0-3]):[0-5]\\d$/",
            "type": "string"
          },
          "scheduled_at": {
            "description": "ISO 8601. Solo aplica a send_mode='scheduled'.",
            "nullable": true,
            "type": "string"
          },
          "send_mode": {
            "description": "Cuándo/cómo se envía:\n  now       — la toma el próximo tick (default).\n  scheduled — espera scheduled_at.\n  manual    — plantilla disparable desde un nodo `broadcast.run` (nace en draft).\n  recurring — plantilla que se dispara sola cada día/semana/mes a una hora.",
            "enum": [
              "now",
              "scheduled",
              "manual",
              "recurring"
            ],
            "type": "string"
          },
          "throttle_per_minute": {
            "maximum": 1000,
            "minimum": 1,
            "type": "number"
          },
          "timezone": {
            "description": "Zona horaria del negocio (IANA). Default lógico: America/Bogota.",
            "maxLength": 64,
            "type": "string"
          }
        },
        "required": [
          "name",
          "flow_id"
        ],
        "type": "object"
      },
      "CreateCollectionDto": {
        "properties": {
          "artifact_config": {
            "description": "Objeto de configuración que recibe el artifact al renderizar items",
            "type": "object"
          },
          "artifact_slug": {
            "description": "Slug del artifact que renderiza los items en vista de grilla",
            "type": "string"
          },
          "description": {
            "type": "string"
          },
          "expose_to_agent": {
            "default": true,
            "description": "Si false, la colección no se expone al LLM (contexto ni tools mcp_meteor_*) en ningún ejecutor. Default true.",
            "type": "boolean"
          },
          "fields": {
            "items": {
              "$ref": "#/components/schemas/FieldDto"
            },
            "type": "array"
          },
          "folder_id": {
            "description": "Carpeta donde se crea la colección; null/omitido = raíz",
            "type": "string"
          },
          "gradient_background": {
            "example": "linear-gradient(135deg, #A78BFA 0%, #7C3AED 100%)",
            "type": "string"
          },
          "met_photo": {
            "description": "URL de la imagen de la mascota Met de esta colección",
            "type": "string"
          },
          "name": {
            "example": "My Collection",
            "maxLength": 255,
            "type": "string"
          },
          "slug": {
            "type": "string"
          },
          "visibility": {
            "enum": [
              "private",
              "visible",
              "listed"
            ],
            "type": "string"
          }
        },
        "required": [
          "name"
        ],
        "type": "object"
      },
      "CreateContactDto": {
        "properties": {
          "channel_id": {
            "type": "number"
          },
          "email": {
            "format": "email",
            "type": "string"
          },
          "first_name": {
            "maxLength": 80,
            "minLength": 1,
            "type": "string"
          },
          "gender": {
            "maxLength": 16,
            "minLength": 1,
            "type": "string"
          },
          "image": {
            "maxLength": 1024,
            "minLength": 1,
            "type": "string"
          },
          "last_name": {
            "maxLength": 80,
            "minLength": 1,
            "type": "string"
          },
          "name": {
            "maxLength": 160,
            "minLength": 1,
            "type": "string"
          },
          "phone": {
            "maxLength": 32,
            "minLength": 5,
            "type": "string"
          }
        },
        "type": "object"
      },
      "CreateContactTagDto": {
        "properties": {
          "name": {
            "maxLength": 60,
            "type": "string"
          }
        },
        "required": [
          "name"
        ],
        "type": "object"
      },
      "CreateConversionDto": {
        "properties": {
          "bucket": {
            "description": "Unidad de unicidad del hito (order_id, appointment_id…). Default: el contacto.",
            "maxLength": 120,
            "type": "string"
          },
          "contact_id": {
            "description": "items.id del contacto (`_contacts`).",
            "minimum": 1,
            "type": "number"
          },
          "currency": {
            "maxLength": 3,
            "type": "string"
          },
          "event_name": {
            "description": "Nombre del evento (debe estar en la taxonomía del workspace). Para WhatsApp\nbusiness_messaging, Meta exige nombres como Purchase / LeadSubmitted /\nInitiateCheckout (no los del Pixel web).",
            "maxLength": 120,
            "type": "string"
          },
          "evidence": {
            "description": "Justificación del hito (para eventos que exigen corroboración).",
            "maxLength": 2000,
            "type": "string"
          },
          "value": {
            "type": "number"
          }
        },
        "required": [
          "contact_id",
          "event_name"
        ],
        "type": "object"
      },
      "CreateFieldDefinitionDto": {
        "properties": {
          "description": {
            "example": "Whether this contact is a VIP customer",
            "type": "string"
          },
          "field_key": {
            "example": "vip_status",
            "type": "string"
          },
          "label": {
            "example": "VIP Status",
            "type": "string"
          },
          "options": {
            "description": "`select`: opciones válidas del campo (texto plano — cada opción es a la vez\nel valor guardado y la etiqueta visible).\n`currency`: un único elemento con el código ISO de la moneda (`['COP']`).\nReusa la misma columna JSONB; para el resto de los tipos se ignora.",
            "example": [
              "Activo",
              "Inactivo",
              "Pausado"
            ],
            "items": {
              "type": "string"
            },
            "type": "array"
          },
          "type": {
            "enum": [
              "text",
              "number",
              "boolean",
              "date",
              "datetime",
              "json",
              "select",
              "currency"
            ],
            "type": "string"
          }
        },
        "required": [
          "field_key",
          "label",
          "type"
        ],
        "type": "object"
      },
      "CreateFieldDto": {
        "properties": {
          "label": {
            "description": "Nombre visible (con mayusculas, tildes, espacios). El `name` queda\ninmutable como key del JSON `item.data`; `label` es lo que se muestra.\nSi no viene, se asume que el `name` sirve como label.",
            "example": "Email Address",
            "type": "string"
          },
          "name": {
            "example": "email_address",
            "type": "string"
          },
          "required": {
            "default": false,
            "type": "boolean"
          },
          "type": {
            "enum": [
              "text",
              "number",
              "currency",
              "email",
              "date",
              "datetime",
              "boolean",
              "url",
              "select",
              "prompt",
              "usuario",
              "contact",
              "page",
              "sitio",
              "image",
              "file"
            ],
            "example": "email",
            "type": "string"
          },
          "validation_rules": {
            "type": "object"
          }
        },
        "required": [
          "name",
          "type"
        ],
        "type": "object"
      },
      "CreateFlowDto": {
        "properties": {
          "description": {
            "type": "string"
          },
          "name": {
            "example": "Recordatorio de pago",
            "type": "string"
          },
          "slug": {
            "type": "string"
          }
        },
        "required": [
          "name"
        ],
        "type": "object"
      },
      "CreateFolderDto": {
        "properties": {
          "description": {
            "type": "string"
          },
          "name": {
            "example": "My Folder",
            "maxLength": 255,
            "type": "string"
          },
          "parent_folder_id": {
            "format": "uuid",
            "type": "string"
          },
          "visibility": {
            "enum": [
              "private",
              "visible",
              "listed"
            ],
            "type": "string"
          }
        },
        "required": [
          "name"
        ],
        "type": "object"
      },
      "CreateItemCommentDto": {
        "properties": {
          "attachments": {
            "description": "Archivos + referencias a items adjuntos. Cada elemento { type, ... }.",
            "type": "array"
          },
          "body": {
            "description": "Texto del comentario. Puede ser vacío si hay attachments.",
            "type": "string"
          },
          "field": {
            "description": "Ancla de celda: nombre del campo (col.key). Si se omite, el comentario es a nivel item.",
            "type": "string"
          }
        },
        "type": "object"
      },
      "CreateItemDto": {
        "properties": {
          "collection_id": {
            "type": "number"
          },
          "data": {
            "type": "object"
          },
          "emoji": {
            "maxLength": 16,
            "type": "string"
          },
          "name": {
            "deprecated": true,
            "description": "DEPRECATED: usa data[primer_field_del_schema] en su lugar.",
            "maxLength": 500,
            "type": "string"
          },
          "slug": {
            "type": "string"
          },
          "visibility": {
            "enum": [
              "private",
              "visible",
              "listed"
            ],
            "type": "string"
          }
        },
        "required": [
          "data"
        ],
        "type": "object"
      },
      "CreateNoteDto": {
        "properties": {
          "content": {
            "maxLength": 10000,
            "type": "string"
          }
        },
        "required": [
          "content"
        ],
        "type": "object"
      },
      "CreateReminderDto": {
        "properties": {
          "channel_id": {
            "description": "Canal con el que se guarda el recordatorio. No decide por dónde sale: al\nenviar, el canal se resuelve desde el contacto.",
            "type": "number"
          },
          "contact_id": {
            "description": "A quién se le va a escribir: el id del contacto del CRM.",
            "type": "number"
          },
          "language": {
            "type": "string"
          },
          "message": {
            "description": "El texto que va a leer el contacto; en el camino por defecto se inyecta como {{1}} en la plantilla.",
            "maxLength": 1024,
            "type": "string"
          },
          "namespace": {
            "type": "string"
          },
          "note": {
            "description": "Nota para el equipo. Es el único campo que NO se le envía al contacto.",
            "maxLength": 500,
            "type": "string"
          },
          "scheduled_for": {
            "description": "ISO 8601. Con offset/Z = instante absoluto; sin offset se interpreta en la tz del workspace.",
            "type": "string"
          },
          "template_name": {
            "type": "string"
          },
          "variables": {
            "type": "object"
          }
        },
        "required": [
          "contact_id",
          "scheduled_for"
        ],
        "type": "object"
      },
      "CreateRunDto": {
        "properties": {
          "attachments": {
            "description": "Adjuntos de entrada (imágenes/archivos) para que el Met los \"vea\" — p.ej. una\nfoto para clasificar o cotizar. Cada uno: `{ url, mime_type?, name?, kind? }`.",
            "items": {
              "type": "string"
            },
            "type": "array"
          },
          "conversation_id": {
            "description": "Conversación existente para dar memoria al run. Sin ella → efímera.",
            "type": "number"
          },
          "input": {
            "maxLength": 100000,
            "type": "string"
          },
          "met": {
            "description": "Met a ejecutar directo: nombre (case-insensitive) o id de un Met del\nworkspace. Bind directo, sin orquestador. Con `conversation_id` fija el\ndefault de la conversación (ver docstring de la clase). Si no matchea ningún\nMet → 400.",
            "maxLength": 200,
            "type": "string"
          },
          "stream": {
            "description": "Respuesta SSE con los eventos del run en vivo.",
            "type": "boolean"
          }
        },
        "required": [
          "input"
        ],
        "type": "object"
      },
      "CreateStepDto": {
        "properties": {
          "approval_message": {
            "type": "string"
          },
          "assigned_to_met_id": {
            "description": "Met asignado al step (FK a items donde collection=_mets). Para type=prompt sin assigned_to_user_id, este Met ejecuta el prompt en vez del orquestador.",
            "nullable": true,
            "type": "number"
          },
          "assigned_to_user_id": {
            "description": "Usuario asignado al step. Para approval: sugerencia de aprobador (cualquier admin puede aprobar). Para human_task: requerido — quien debe completar el trabajo.",
            "nullable": true,
            "type": "number"
          },
          "description": {
            "type": "string"
          },
          "name": {
            "type": "string"
          },
          "output_format": {
            "type": "string"
          },
          "prompt": {
            "type": "string"
          },
          "result_content": {
            "description": "Bloques con el resultado del step (donde Met o el humano deja el output tangible). Validados por BlockValidatorService. Sustituye el array completo.",
            "type": "array"
          },
          "skill_id": {
            "type": "string"
          },
          "skill_input_mapping": {
            "type": "object"
          },
          "status": {
            "description": "Estado del step. Aceptado solo en update — al crear el step queda en pending. Util para que el usuario marque un step como completado manualmente desde el bloque tarea del item.",
            "type": "string"
          },
          "type": {
            "description": "type ya es opcional en la practica: el nuevo flujo permite crear steps\ncon solo `name` (Met genera un step minimo). Default = 'prompt'.",
            "type": "string"
          }
        },
        "required": [
          "name"
        ],
        "type": "object"
      },
      "CreateTaskCommentDto": {
        "properties": {
          "attachments": {
            "description": "Archivos + referencias a items adjuntos. Cada elemento { type, ... }.",
            "type": "array"
          },
          "body": {
            "description": "Texto del comentario. Puede ser vacío si hay attachments.",
            "type": "string"
          },
          "task_execution_id": {
            "description": "Si el comentario se origina dentro de una ejecución específica.",
            "type": "string"
          }
        },
        "type": "object"
      },
      "CreateTaskDto": {
        "properties": {
          "contact_id": {
            "description": "Contacto del CRM al que da seguimiento esta tarea (FK a items de la colección _contacts). NULL para tareas que no son de seguimiento.",
            "type": "number"
          },
          "deadline": {
            "description": "Fecha límite opcional de la tarea (ISO 8601, TIMESTAMPTZ). Enviar null para dejarla sin fecha.",
            "nullable": true,
            "type": "string"
          },
          "description": {
            "type": "string"
          },
          "execution_config": {
            "type": "object"
          },
          "name": {
            "example": "Daily Report",
            "maxLength": 255,
            "type": "string"
          },
          "responsible_met_id": {
            "description": "Met responsable (FK a items donde collection=_mets). Es el ente Met al que se le asigna la tarea como dueño.",
            "type": "number"
          },
          "responsible_user_id": {
            "description": "Usuario humano responsable de la tarea. Mutuamente excluyente con responsible_met_id — la tarea tiene UN dueno principal, humano o Met.",
            "type": "number"
          },
          "source_item_id": {
            "description": "Item desde el que se creó esta tarea (vía bloque de tipo task en items.content). NULL para tareas creadas desde el sistema de tareas directamente.",
            "type": "number"
          }
        },
        "required": [
          "name"
        ],
        "type": "object"
      },
      "CreateTaskViewDto": {
        "properties": {
          "column_order": {
            "description": "Orden custom de column keys. Vacío = orden default.",
            "items": {
              "type": "string"
            },
            "type": "array"
          },
          "column_widths": {
            "description": "Ancho en px por column key",
            "type": "object"
          },
          "filters": {
            "items": {
              "type": "object"
            },
            "type": "array"
          },
          "group_by": {
            "description": "Campo por el que se agrupa la lista (assignee/status/deadline). null = sin agrupar.",
            "nullable": true,
            "type": "string"
          },
          "hidden_columns": {
            "items": {
              "type": "string"
            },
            "type": "array"
          },
          "mode": {
            "enum": [
              "list",
              "grid",
              "kanban",
              "excel",
              "calendar"
            ],
            "type": "string"
          },
          "name": {
            "maxLength": 120,
            "type": "string"
          },
          "sort": {
            "properties": {
              "direction": {
                "type": "object"
              },
              "field": {
                "type": "string"
              }
            },
            "required": [
              "field",
              "direction"
            ],
            "type": "object"
          }
        },
        "required": [
          "name"
        ],
        "type": "object"
      },
      "CreateTriggerAutomationDto": {
        "properties": {
          "action_config": {
            "description": "Config adicional de la acción (forma libre).",
            "example": {},
            "type": "object"
          },
          "action_kind": {
            "description": "Qué ejecuta el disparador.",
            "enum": [
              "task",
              "flow"
            ],
            "example": "flow",
            "type": "string"
          },
          "collection_id": {
            "description": "Colección sobre la que aplica el disparador (si corresponde).",
            "example": 42,
            "type": "number"
          },
          "conditions": {
            "description": "Condiciones del disparador (forma libre según trigger_type).",
            "example": {
              "field": "estado",
              "to": "ganado"
            },
            "type": "object"
          },
          "description": {
            "description": "Descripción del disparador.",
            "example": "Avisa por WhatsApp cuando un deal pasa a ganado.",
            "type": "string"
          },
          "enabled": {
            "description": "Habilitado.",
            "example": true,
            "type": "boolean"
          },
          "flow_id": {
            "description": "ID del flujo destino. Requerido si action_kind='flow'.",
            "example": "f1e2d3c4-…",
            "type": "string"
          },
          "icon": {
            "description": "Emoji/ícono para la UI.",
            "example": "🔔",
            "type": "string"
          },
          "name": {
            "description": "Nombre visible del disparador.",
            "example": "Notificar publicación",
            "type": "string"
          },
          "task_id": {
            "description": "ID de la tarea destino. Requerido si action_kind='task' (o si viene undefined).",
            "example": "a1b2c3d4-…",
            "type": "string"
          },
          "trigger_type": {
            "description": "Tipo de disparador del catálogo (GET /trigger-catalog).",
            "example": "item.field_changed",
            "type": "string"
          }
        },
        "required": [
          "name",
          "trigger_type"
        ],
        "type": "object"
      },
      "CreateTriggerDto": {
        "properties": {
          "available_parameters": {
            "type": "object"
          },
          "collection_id": {
            "type": "number"
          },
          "enabled": {
            "description": "Si false, el trigger queda pausado: scheduler y dispatcher lo ignoran hasta que vuelva a true.",
            "type": "boolean"
          },
          "recurrence_pattern": {
            "type": "string"
          },
          "scheduled_date": {
            "type": "string"
          },
          "trigger_conditions": {
            "type": "object"
          },
          "trigger_type": {
            "type": "string"
          }
        },
        "required": [
          "trigger_type"
        ],
        "type": "object"
      },
      "CreateVariableDto": {
        "properties": {
          "description": {
            "example": "Company brand name",
            "type": "string"
          },
          "is_encrypted": {
            "default": false,
            "type": "boolean"
          },
          "name": {
            "example": "brand_name",
            "type": "string"
          },
          "type": {
            "enum": [
              "text",
              "number",
              "boolean",
              "date",
              "datetime",
              "json",
              "prompt"
            ],
            "type": "string"
          },
          "value": {
            "description": "Variable value (stored as JSONB)",
            "type": "object"
          }
        },
        "required": [
          "name",
          "type"
        ],
        "type": "object"
      },
      "CreateViewDto": {
        "properties": {
          "column_order": {
            "description": "Orden custom de field names. Vacío = orden default del schema.",
            "items": {
              "type": "string"
            },
            "type": "array"
          },
          "column_widths": {
            "description": "Ancho en px por field name",
            "type": "object"
          },
          "compact": {
            "type": "boolean"
          },
          "filters": {
            "items": {
              "type": "object"
            },
            "type": "array"
          },
          "hidden_columns": {
            "items": {
              "type": "string"
            },
            "type": "array"
          },
          "kanban_field": {
            "nullable": true,
            "type": "string"
          },
          "kanban_subtitle_field": {
            "nullable": true,
            "type": "string"
          },
          "kanban_title_field": {
            "nullable": true,
            "type": "string"
          },
          "kanban_total_field": {
            "description": "Field name cuyo valor numérico se suma por columna del tablero (currency/number).",
            "nullable": true,
            "type": "string"
          },
          "mode": {
            "enum": [
              "list",
              "grid",
              "kanban",
              "excel",
              "calendar"
            ],
            "type": "string"
          },
          "name": {
            "maxLength": 120,
            "type": "string"
          },
          "sort": {
            "properties": {
              "direction": {
                "type": "object"
              },
              "field": {
                "type": "string"
              }
            },
            "required": [
              "field",
              "direction"
            ],
            "type": "object"
          }
        },
        "required": [
          "name"
        ],
        "type": "object"
      },
      "CreateWebConversionDto": {
        "properties": {
          "client_ip_address": {
            "description": "IP del navegador del USUARIO FINAL (no la del servidor que reporta). El caller\nserver-side la reenvía; mejora el match de Meta. Best-effort.",
            "maxLength": 64,
            "type": "string"
          },
          "client_user_agent": {
            "description": "User-Agent del navegador del usuario final. El caller lo reenvía. Best-effort.",
            "maxLength": 500,
            "type": "string"
          },
          "currency": {
            "maxLength": 3,
            "type": "string"
          },
          "email": {
            "description": "Email en claro — se hashea SHA-256 antes de salir.",
            "maxLength": 320,
            "type": "string"
          },
          "event_id": {
            "description": "El MISMO `eventID` que disparó el Pixel client-side. Clave del dedup.",
            "maxLength": 200,
            "type": "string"
          },
          "event_name": {
            "description": "Nombre del evento web (debe estar en la taxonomía del workspace).",
            "maxLength": 120,
            "type": "string"
          },
          "event_source_url": {
            "description": "URL donde ocurrió el evento (`event_source_url`).",
            "maxLength": 2000,
            "type": "string"
          },
          "external_id": {
            "description": "Id externo del cliente (order_id, user_id…) — se hashea SHA-256.",
            "maxLength": 200,
            "type": "string"
          },
          "fbc": {
            "description": "Cookie `_fbc` del navegador (click de anuncio). No se hashea.",
            "maxLength": 400,
            "type": "string"
          },
          "fbp": {
            "description": "Cookie `_fbp` del navegador (Pixel). No se hashea.",
            "maxLength": 200,
            "type": "string"
          },
          "phone": {
            "description": "Teléfono en claro — se normaliza a dígitos y se hashea SHA-256.",
            "maxLength": 40,
            "type": "string"
          },
          "value": {
            "type": "number"
          }
        },
        "required": [
          "event_name",
          "event_id"
        ],
        "type": "object"
      },
      "CreateWebhookDto": {
        "properties": {
          "binding_type": {
            "description": "'task' → ejecuta directo una tarea. 'generic' → solo emite evento.",
            "enum": [
              "task",
              "generic"
            ],
            "type": "string"
          },
          "dedupe_events": {
            "description": "true → deduplica reintentos por external_id (idempotencia). false (default)\n→ cada entrega se registra y despacha. Ver migración webhook_dedupe_toggle.",
            "type": "boolean"
          },
          "description": {
            "maxLength": 2000,
            "type": "string"
          },
          "name": {
            "maxLength": 120,
            "minLength": 3,
            "type": "string"
          },
          "signature_header": {
            "description": "Header del que se lee la firma. Default 'x-signature'.",
            "maxLength": 64,
            "type": "string"
          },
          "task_id": {
            "description": "Requerido si binding_type='task'. Ignorado si 'generic'.",
            "type": "number"
          },
          "verifier_type": {
            "description": "'hmac_sha256' → genera secret automáticamente y se devuelve UNA VEZ.\n'none' → sin firma (badge inseguro en UI).",
            "enum": [
              "hmac_sha256",
              "none"
            ],
            "type": "string"
          }
        },
        "required": [
          "name",
          "binding_type",
          "verifier_type"
        ],
        "type": "object"
      },
      "CreateWebhookSubscriptionDto": {
        "properties": {
          "description": {
            "description": "Etiqueta libre para distinguirlo en el listado.",
            "example": "Producción",
            "maxLength": 200,
            "type": "string"
          },
          "enabled_events": {
            "description": "Qué eventos quieres recibir. `*` no es un tipo de evento: es el comodín\n«todos los del catálogo, incluidos los que se agreguen después».\n`GET /webhook-endpoints/event-types` devuelve el catálogo vivo con la\ndescripción y el scope de cada uno.",
            "enum": [
              "*",
              "run.completed",
              "run.failed",
              "channel.run.completed",
              "channel.run.failed",
              "contact.created",
              "contact.updated",
              "contact.message.received",
              "conversation.handoff",
              "task.completed",
              "billing.threshold",
              "app.authorized",
              "app.revoked",
              "snapshot.published",
              "snapshot.install.completed",
              "snapshot.install.failed",
              "conversion.sent",
              "conversion.discarded"
            ],
            "example": [
              "run.completed",
              "contact.created"
            ],
            "items": {
              "enum": [
                "*",
                "run.completed",
                "run.failed",
                "channel.run.completed",
                "channel.run.failed",
                "contact.created",
                "contact.updated",
                "contact.message.received",
                "conversation.handoff",
                "task.completed",
                "billing.threshold",
                "app.authorized",
                "app.revoked",
                "snapshot.published",
                "snapshot.install.completed",
                "snapshot.install.failed",
                "conversion.sent",
                "conversion.discarded"
              ],
              "type": "string"
            },
            "minItems": 1,
            "type": "array"
          },
          "url": {
            "description": "A dónde Meteor entrega los eventos. Debe traer protocolo (`https://…`).",
            "example": "https://tu-app.com/hooks/meteor",
            "format": "uri",
            "type": "string"
          }
        },
        "required": [
          "url",
          "enabled_events"
        ],
        "type": "object"
      },
      "CurrentSubscriptionResponseDto": {
        "properties": {
          "plan": {
            "allOf": [
              {
                "$ref": "#/components/schemas/PlanWithFeaturesDto"
              }
            ],
            "nullable": true
          },
          "subscription": {
            "allOf": [
              {
                "$ref": "#/components/schemas/WorkspaceSubscriptionDto"
              }
            ],
            "nullable": true
          }
        },
        "required": [
          "subscription",
          "plan"
        ],
        "type": "object"
      },
      "DuplicateCandidateDto": {
        "properties": {
          "blocked_reason": {
            "example": "Los dos contactos tienen conversación propia",
            "nullable": true,
            "type": "string"
          },
          "can_merge": {
            "description": "`false` = fusionarlos rompería la identidad del inbound (ver `blocked_reason`).",
            "example": true,
            "type": "boolean"
          },
          "created_at": {
            "example": "2026-07-30T04:12:33.120Z",
            "type": "string"
          },
          "email": {
            "nullable": true,
            "type": "string"
          },
          "id": {
            "example": 4822,
            "type": "number"
          },
          "matched_by": {
            "description": "Por qué se parecen. `identidad` es el match más fuerte: los dos son la misma\nconversación (mismo `user_ns`, canal y línea), o sea un gemelo exacto.",
            "example": [
              "phone"
            ],
            "items": {
              "enum": [
                "phone",
                "email",
                "identidad"
              ],
              "type": "string"
            },
            "type": "array"
          },
          "name": {
            "example": "Ada Lovelace",
            "nullable": true,
            "type": "string"
          },
          "phone": {
            "example": "+573001112233",
            "nullable": true,
            "type": "string"
          }
        },
        "required": [
          "id",
          "name",
          "phone",
          "email",
          "created_at",
          "matched_by",
          "can_merge",
          "blocked_reason"
        ],
        "type": "object"
      },
      "EditImageDto": {
        "properties": {
          "image_base64": {
            "minLength": 1,
            "type": "string"
          },
          "model": {
            "maxLength": 120,
            "type": "string"
          },
          "prompt": {
            "maxLength": 4000,
            "minLength": 1,
            "type": "string"
          }
        },
        "required": [
          "prompt",
          "image_base64"
        ],
        "type": "object"
      },
      "EventEnvelopeDto": {
        "properties": {
          "created": {
            "description": "Momento del evento, en segundos unix.",
            "example": 1785729153,
            "type": "number"
          },
          "data": {
            "additionalProperties": true,
            "description": "El recurso al que se refiere el evento. Su forma depende del `type`.",
            "type": "object"
          },
          "id": {
            "example": "evt_01HXYZ",
            "type": "string"
          },
          "livemode": {
            "description": "`false` si lo produjo una key de prueba (`met_test_`).",
            "example": true,
            "type": "boolean"
          },
          "object": {
            "description": "Siempre `event`. Distingue el tipo de objeto en respuestas mezcladas.",
            "enum": [
              "event"
            ],
            "example": "event",
            "type": "string"
          },
          "type": {
            "description": "Tipo del catálogo de eventos (ej. `contact.created`, `run.completed`).",
            "example": "contact.created",
            "type": "string"
          }
        },
        "required": [
          "id",
          "object",
          "type",
          "created",
          "livemode",
          "data"
        ],
        "type": "object"
      },
      "EventResponseDto": {
        "properties": {
          "action": {
            "description": "Qué se hizo: `create`, `update`, `delete`…",
            "example": "update",
            "type": "string"
          },
          "after_data": {
            "additionalProperties": true,
            "description": "Estado posterior completo. `null` en los borrados.",
            "nullable": true,
            "type": "object"
          },
          "before_data": {
            "additionalProperties": true,
            "description": "Estado anterior completo. `null` en las creaciones.",
            "nullable": true,
            "type": "object"
          },
          "collection_id": {
            "description": "Colección de la entidad, cuando aplica.",
            "example": 42,
            "nullable": true,
            "type": "number"
          },
          "created_at": {
            "example": "2026-07-30T04:12:33.120Z",
            "type": "string"
          },
          "diff": {
            "additionalProperties": true,
            "description": "Solo lo que cambió, indexado por campo: `{ \"<campo>\": { from, to } }`. Las\nclaves que empiezan con `__` son internas y la UI las omite.",
            "example": {
              "estado": {
                "from": "abierto",
                "to": "ganado"
              }
            },
            "nullable": true,
            "type": "object"
          },
          "entity_id": {
            "description": "ID de esa entidad.",
            "example": 55231,
            "type": "number"
          },
          "entity_type": {
            "description": "Qué tipo de entidad se tocó (`item`, `contact`, `flow`…).",
            "example": "item",
            "type": "string"
          },
          "id": {
            "example": 918273,
            "type": "number"
          },
          "metadata": {
            "additionalProperties": true,
            "description": "Contexto extra del origen del evento. Forma libre.",
            "nullable": true,
            "type": "object"
          },
          "user_id": {
            "description": "Quién lo hizo. `null` cuando lo hizo un Met, un canal o una key de API.",
            "example": 12,
            "nullable": true,
            "type": "number"
          },
          "workspace_id": {
            "example": 40,
            "type": "number"
          }
        },
        "required": [
          "id",
          "workspace_id",
          "entity_type",
          "entity_id",
          "collection_id",
          "action",
          "before_data",
          "after_data",
          "diff",
          "user_id",
          "metadata",
          "created_at"
        ],
        "type": "object"
      },
      "FieldDefinitionDeletedResponseDto": {
        "properties": {
          "message": {
            "example": "Field definition deleted",
            "type": "string"
          }
        },
        "required": [
          "message"
        ],
        "type": "object"
      },
      "FieldDto": {
        "properties": {
          "name": {
            "type": "string"
          },
          "required": {
            "type": "boolean"
          },
          "type": {
            "type": "string"
          },
          "validation_rules": {
            "type": "object"
          }
        },
        "required": [
          "name",
          "type"
        ],
        "type": "object"
      },
      "FieldMappingDto": {
        "properties": {
          "dest_key": {
            "maxLength": 120,
            "type": "string"
          },
          "dest_kind": {
            "enum": [
              "contact",
              "workspace_var"
            ],
            "type": "string"
          },
          "fallback": {
            "maxLength": 5000,
            "nullable": true,
            "type": "string"
          },
          "json_path": {
            "maxLength": 200,
            "type": "string"
          }
        },
        "required": [
          "json_path",
          "dest_kind",
          "dest_key"
        ],
        "type": "object"
      },
      "FileAttachmentDto": {
        "properties": {
          "mime_type": {
            "type": "string"
          },
          "original_name": {
            "type": "string"
          },
          "size": {
            "type": "number"
          },
          "storage_path": {
            "type": "string"
          },
          "type": {
            "enum": [
              "file"
            ],
            "type": "string"
          },
          "url": {
            "type": "string"
          }
        },
        "required": [
          "type",
          "url",
          "storage_path",
          "mime_type",
          "size",
          "original_name"
        ],
        "type": "object"
      },
      "FlowArchivedResponseDto": {
        "properties": {
          "message": {
            "example": "Flow archivado",
            "type": "string"
          }
        },
        "required": [
          "message"
        ],
        "type": "object"
      },
      "FlowAutomationSummaryDto": {
        "properties": {
          "enabled": {
            "example": true,
            "type": "boolean"
          },
          "id": {
            "example": "a1b2c3d4-e5f6-7890-abcd-ef1234567890",
            "type": "string"
          },
          "name": {
            "description": "Nombre visible. `(automatización sin nombre)` si nunca se le puso uno.",
            "example": "Cuando el deal pasa a ganado",
            "type": "string"
          },
          "trigger_type": {
            "description": "Tipo del catálogo de disparadores (`GET /trigger-catalog`).",
            "example": "item.field_changed",
            "type": "string"
          }
        },
        "required": [
          "id",
          "name",
          "trigger_type",
          "enabled"
        ],
        "type": "object"
      },
      "FlowDefinitionDto": {
        "properties": {
          "edges": {
            "items": {
              "$ref": "#/components/schemas/FlowEdgeDto"
            },
            "type": "array"
          },
          "nodes": {
            "items": {
              "$ref": "#/components/schemas/FlowNodeDto"
            },
            "type": "array"
          }
        },
        "required": [
          "nodes",
          "edges"
        ],
        "type": "object"
      },
      "FlowDependencyDto": {
        "properties": {
          "kind": {
            "description": "`skill`, `mcp`, `collection`, `met`, `function`, `channel`, `flow`, `agent_group`.",
            "example": "skill",
            "type": "string"
          },
          "name": {
            "description": "Nombre humano en el origen: se muestra al importar y sirve para el match automático.",
            "example": "Asesor de ventas",
            "type": "string"
          },
          "origin_id": {
            "description": "ID en el workspace origen. Informativo: **no** se usa al importar.",
            "example": 412,
            "oneOf": [
              {
                "type": "string"
              },
              {
                "type": "number"
              }
            ]
          },
          "ref": {
            "description": "Ref estable sin el prefijo `@snapshot:` (ej. `skill:asesor-ventas`).",
            "example": "skill:asesor-ventas",
            "type": "string"
          },
          "system_code": {
            "description": "Código de sistema de la colección (`_contacts`, `_mets`…), si aplica.",
            "example": "_contacts",
            "nullable": true,
            "type": "string"
          }
        },
        "required": [
          "ref",
          "kind",
          "name",
          "origin_id"
        ],
        "type": "object"
      },
      "FlowDetailResponseDto": {
        "properties": {
          "automations": {
            "items": {
              "$ref": "#/components/schemas/FlowAutomationSummaryDto"
            },
            "type": "array"
          },
          "created_at": {
            "example": "2026-07-20T18:03:11.000Z",
            "type": "string"
          },
          "created_by": {
            "description": "Usuario que lo creó. `null` si lo creó el sistema o una key de API.",
            "example": 12,
            "nullable": true,
            "type": "number"
          },
          "description": {
            "example": "Avisa 3 días antes del vencimiento.",
            "nullable": true,
            "type": "string"
          },
          "draft_definition": {
            "allOf": [
              {
                "$ref": "#/components/schemas/FlowDefinitionDto"
              }
            ],
            "description": "Versión editable del lienzo: lo que se ve y se guarda en el editor."
          },
          "id": {
            "description": "UUID del flujo.",
            "example": "8f14e45f-ceea-467a-9f0b-4c3d1a2b5e60",
            "type": "string"
          },
          "is_system": {
            "description": "Flujo de sistema (el Flujo principal): no se puede archivar ni borrar.",
            "example": false,
            "type": "boolean"
          },
          "name": {
            "example": "Recordatorio de pago",
            "type": "string"
          },
          "published_at": {
            "description": "Cuándo se publicó por última vez. `null` si nunca se publicó.",
            "example": "2026-07-30T04:12:33.120Z",
            "nullable": true,
            "type": "string"
          },
          "published_definition": {
            "allOf": [
              {
                "$ref": "#/components/schemas/FlowDefinitionDto"
              }
            ],
            "description": "Snapshot inmutable que ejecutan los disparadores automáticos. `null` hasta el\nprimer `POST /flows/{id}/publish`.",
            "nullable": true
          },
          "slug": {
            "description": "Identificador legible, único por workspace. `null` si no se le puso uno.",
            "example": "recordatorio-pago",
            "nullable": true,
            "type": "string"
          },
          "status": {
            "enum": [
              "draft",
              "published",
              "archived"
            ],
            "example": "published",
            "type": "string"
          },
          "updated_at": {
            "example": "2026-07-30T04:12:33.120Z",
            "type": "string"
          },
          "workspace_id": {
            "example": 40,
            "type": "number"
          }
        },
        "required": [
          "id",
          "workspace_id",
          "name",
          "description",
          "slug",
          "draft_definition",
          "published_definition",
          "published_at",
          "status",
          "created_by",
          "created_at",
          "updated_at",
          "automations"
        ],
        "type": "object"
      },
      "FlowEdgeDto": {
        "properties": {
          "id": {
            "example": "e_1",
            "type": "string"
          },
          "source": {
            "description": "`id` del nodo origen.",
            "example": "n_7f3c1a",
            "type": "string"
          },
          "sourceHandle": {
            "description": "Handle de salida del origen — relevante en condición (sí/no) y en bifurcaciones.",
            "example": "out",
            "nullable": true,
            "type": "string"
          },
          "target": {
            "description": "`id` del nodo destino.",
            "example": "n_9b2d40",
            "type": "string"
          },
          "targetHandle": {
            "nullable": true,
            "type": "string"
          }
        },
        "required": [
          "id",
          "source",
          "target"
        ],
        "type": "object"
      },
      "FlowImportCandidateDto": {
        "properties": {
          "id": {
            "example": 87,
            "oneOf": [
              {
                "type": "string"
              },
              {
                "type": "number"
              }
            ]
          },
          "name": {
            "example": "Asesor de ventas",
            "type": "string"
          }
        },
        "required": [
          "id",
          "name"
        ],
        "type": "object"
      },
      "FlowImportPreviewDependencyDto": {
        "properties": {
          "candidates": {
            "description": "Entidades locales del mismo `kind`, para elegir a mano.",
            "items": {
              "$ref": "#/components/schemas/FlowImportCandidateDto"
            },
            "type": "array"
          },
          "kind": {
            "description": "`skill`, `mcp`, `collection`, `met`, `function`, `channel`, `flow`, `agent_group`.",
            "example": "skill",
            "type": "string"
          },
          "local_id": {
            "description": "ID local si se resolvió automáticamente por nombre o código.",
            "nullable": true,
            "oneOf": [
              {
                "type": "string"
              },
              {
                "type": "number"
              }
            ]
          },
          "name": {
            "description": "Nombre humano en el origen: se muestra al importar y sirve para el match automático.",
            "example": "Asesor de ventas",
            "type": "string"
          },
          "origin_id": {
            "description": "ID en el workspace origen. Informativo: **no** se usa al importar.",
            "example": 412,
            "oneOf": [
              {
                "type": "string"
              },
              {
                "type": "number"
              }
            ]
          },
          "ref": {
            "description": "Ref estable sin el prefijo `@snapshot:` (ej. `skill:asesor-ventas`).",
            "example": "skill:asesor-ventas",
            "type": "string"
          },
          "status": {
            "description": "`unresolved` = hay que elegir a mano (o omitir) antes de importar.",
            "enum": [
              "resolved",
              "unresolved"
            ],
            "example": "resolved",
            "type": "string"
          },
          "system_code": {
            "description": "Código de sistema de la colección (`_contacts`, `_mets`…), si aplica.",
            "example": "_contacts",
            "nullable": true,
            "type": "string"
          }
        },
        "required": [
          "ref",
          "kind",
          "name",
          "origin_id",
          "status",
          "local_id",
          "candidates"
        ],
        "type": "object"
      },
      "FlowImportPreviewResponseDto": {
        "properties": {
          "dependencies": {
            "items": {
              "$ref": "#/components/schemas/FlowImportPreviewDependencyDto"
            },
            "type": "array"
          },
          "edge_count": {
            "example": 13,
            "type": "number"
          },
          "existing_flow_id": {
            "description": "ID del flujo local con el mismo slug. Pásalo como `target_flow_id` al\nimportar para **actualizarlo** en vez de crear un duplicado (idempotente).",
            "nullable": true,
            "type": "string"
          },
          "flow_name": {
            "example": "Recordatorio de pago",
            "type": "string"
          },
          "node_count": {
            "example": 12,
            "type": "number"
          },
          "slug": {
            "example": "recordatorio-pago",
            "nullable": true,
            "type": "string"
          },
          "slug_collision": {
            "description": "Ya existe un flujo con ese `slug` en el destino.",
            "example": false,
            "type": "boolean"
          },
          "warnings": {
            "items": {
              "$ref": "#/components/schemas/FlowLintWarningDto"
            },
            "type": "array"
          }
        },
        "required": [
          "flow_name",
          "node_count",
          "edge_count",
          "slug",
          "slug_collision",
          "existing_flow_id",
          "dependencies",
          "warnings"
        ],
        "type": "object"
      },
      "FlowImportResultResponseDto": {
        "properties": {
          "flow": {
            "$ref": "#/components/schemas/FlowResponseDto"
          },
          "mode": {
            "description": "`updated` cuando se mandó `target_flow_id`; `created` en caso contrario.",
            "enum": [
              "created",
              "updated"
            ],
            "example": "created",
            "type": "string"
          },
          "warnings": {
            "items": {
              "$ref": "#/components/schemas/FlowLintWarningDto"
            },
            "type": "array"
          }
        },
        "required": [
          "flow",
          "warnings",
          "mode"
        ],
        "type": "object"
      },
      "FlowLastNodeOutputsResponseDto": {
        "properties": {
          "outputs": {
            "additionalProperties": true,
            "example": {
              "n_7f3c1a": {
                "text": "Hola"
              }
            },
            "type": "object"
          }
        },
        "required": [
          "outputs"
        ],
        "type": "object"
      },
      "FlowLintWarningDto": {
        "properties": {
          "code": {
            "enum": [
              "unresolved_ref",
              "dropped_reference",
              "possible_secret",
              "skipped_entity",
              "missing_variable"
            ],
            "example": "unresolved_ref",
            "type": "string"
          },
          "message": {
            "type": "string"
          },
          "where": {
            "description": "Ubicación aproximada: ref de la entidad + ruta del campo.",
            "type": "string"
          }
        },
        "required": [
          "code",
          "message"
        ],
        "type": "object"
      },
      "FlowMcpDto": {
        "properties": {
          "description": {
            "type": "string"
          },
          "handler_key": {
            "description": "Clave del handler nativo. `null` si es un MCP HTTP del workspace.",
            "example": "google_calendar",
            "nullable": true,
            "type": "string"
          },
          "mcp_id": {
            "description": "ID del ítem de la colección de MCPs. `null` en los nativos sin ítem.",
            "example": "3140",
            "nullable": true,
            "type": "string"
          },
          "name": {
            "example": "Google Calendar",
            "type": "string"
          },
          "requires_credentials": {
            "description": "`true` si todavía le faltan credenciales: aparece, pero no se puede ejecutar.",
            "example": false,
            "type": "boolean"
          },
          "tools": {
            "items": {
              "$ref": "#/components/schemas/FlowMcpToolDto"
            },
            "type": "array"
          }
        },
        "required": [
          "handler_key",
          "mcp_id",
          "name",
          "description",
          "requires_credentials",
          "tools"
        ],
        "type": "object"
      },
      "FlowMcpToolDto": {
        "properties": {
          "description": {
            "type": "string"
          },
          "input_schema": {
            "additionalProperties": true,
            "description": "JSON Schema de los argumentos, tal como lo publica el MCP.",
            "type": "object"
          },
          "name": {
            "example": "search_contacts",
            "type": "string"
          }
        },
        "required": [
          "name",
          "description",
          "input_schema"
        ],
        "type": "object"
      },
      "FlowMcpsResponseDto": {
        "properties": {
          "mcps": {
            "items": {
              "$ref": "#/components/schemas/FlowMcpDto"
            },
            "type": "array"
          }
        },
        "required": [
          "mcps"
        ],
        "type": "object"
      },
      "FlowNodeDto": {
        "properties": {
          "data": {
            "additionalProperties": true,
            "description": "Config del nodo. Su forma depende del `type`: los campos válidos de cada uno\nestán declarados en `GET /node-registry` (`fields[]`).",
            "type": "object"
          },
          "id": {
            "description": "UUID generado por el cliente al arrastrar el nodo a la paleta.",
            "example": "n_7f3c1a",
            "type": "string"
          },
          "position": {
            "$ref": "#/components/schemas/FlowNodePositionDto"
          },
          "type": {
            "description": "Tipo declarado en el node-registry (`GET /node-registry`).",
            "example": "agent.ask",
            "type": "string"
          }
        },
        "required": [
          "id",
          "type",
          "position",
          "data"
        ],
        "type": "object"
      },
      "FlowNodePositionDto": {
        "properties": {
          "x": {
            "example": 120,
            "type": "number"
          },
          "y": {
            "example": 340,
            "type": "number"
          }
        },
        "required": [
          "x",
          "y"
        ],
        "type": "object"
      },
      "FlowPortableDocDto": {
        "properties": {
          "content_hash": {
            "description": "Hash del JSON canónico de `{ flow, dependencies }` — para detectar cambios.",
            "example": "a3f1c9…",
            "type": "string"
          },
          "dependencies": {
            "items": {
              "$ref": "#/components/schemas/FlowDependencyDto"
            },
            "type": "array"
          },
          "exported_at": {
            "example": "2026-07-30T04:12:33.120Z",
            "type": "string"
          },
          "flow": {
            "$ref": "#/components/schemas/FlowPortableFlowDto"
          },
          "kind": {
            "enum": [
              "meteor.flow"
            ],
            "example": "meteor.flow",
            "type": "string"
          },
          "schema_version": {
            "example": 1,
            "type": "number"
          },
          "source": {
            "$ref": "#/components/schemas/FlowPortableSourceDto"
          },
          "warnings": {
            "items": {
              "$ref": "#/components/schemas/FlowLintWarningDto"
            },
            "type": "array"
          }
        },
        "required": [
          "schema_version",
          "kind",
          "exported_at",
          "source",
          "flow",
          "dependencies",
          "content_hash"
        ],
        "type": "object"
      },
      "FlowPortableFlowDto": {
        "properties": {
          "definition": {
            "additionalProperties": true,
            "description": "El lienzo, con los ids de entidades reescritos como marcadores\n`@snapshot:<ref>` — por eso `nodes`/`edges` van sin tipar aquí.",
            "example": {
              "edges": [],
              "nodes": []
            },
            "type": "object"
          },
          "description": {
            "nullable": true,
            "type": "string"
          },
          "name": {
            "example": "Recordatorio de pago",
            "type": "string"
          },
          "ref": {
            "example": "flow:recordatorio-pago",
            "type": "string"
          },
          "slug": {
            "example": "recordatorio-pago",
            "nullable": true,
            "type": "string"
          }
        },
        "required": [
          "ref",
          "name",
          "description",
          "slug",
          "definition"
        ],
        "type": "object"
      },
      "FlowPortableSourceDto": {
        "properties": {
          "flow_ref": {
            "example": "flow:recordatorio-pago",
            "type": "string"
          },
          "workspace_id": {
            "example": 40,
            "type": "number"
          }
        },
        "required": [
          "workspace_id",
          "flow_ref"
        ],
        "type": "object"
      },
      "FlowResponseDto": {
        "properties": {
          "created_at": {
            "example": "2026-07-20T18:03:11.000Z",
            "type": "string"
          },
          "created_by": {
            "description": "Usuario que lo creó. `null` si lo creó el sistema o una key de API.",
            "example": 12,
            "nullable": true,
            "type": "number"
          },
          "description": {
            "example": "Avisa 3 días antes del vencimiento.",
            "nullable": true,
            "type": "string"
          },
          "draft_definition": {
            "allOf": [
              {
                "$ref": "#/components/schemas/FlowDefinitionDto"
              }
            ],
            "description": "Versión editable del lienzo: lo que se ve y se guarda en el editor."
          },
          "id": {
            "description": "UUID del flujo.",
            "example": "8f14e45f-ceea-467a-9f0b-4c3d1a2b5e60",
            "type": "string"
          },
          "is_system": {
            "description": "Flujo de sistema (el Flujo principal): no se puede archivar ni borrar.",
            "example": false,
            "type": "boolean"
          },
          "name": {
            "example": "Recordatorio de pago",
            "type": "string"
          },
          "published_at": {
            "description": "Cuándo se publicó por última vez. `null` si nunca se publicó.",
            "example": "2026-07-30T04:12:33.120Z",
            "nullable": true,
            "type": "string"
          },
          "published_definition": {
            "allOf": [
              {
                "$ref": "#/components/schemas/FlowDefinitionDto"
              }
            ],
            "description": "Snapshot inmutable que ejecutan los disparadores automáticos. `null` hasta el\nprimer `POST /flows/{id}/publish`.",
            "nullable": true
          },
          "slug": {
            "description": "Identificador legible, único por workspace. `null` si no se le puso uno.",
            "example": "recordatorio-pago",
            "nullable": true,
            "type": "string"
          },
          "status": {
            "enum": [
              "draft",
              "published",
              "archived"
            ],
            "example": "published",
            "type": "string"
          },
          "updated_at": {
            "example": "2026-07-30T04:12:33.120Z",
            "type": "string"
          },
          "workspace_id": {
            "example": 40,
            "type": "number"
          }
        },
        "required": [
          "id",
          "workspace_id",
          "name",
          "description",
          "slug",
          "draft_definition",
          "published_definition",
          "published_at",
          "status",
          "created_by",
          "created_at",
          "updated_at"
        ],
        "type": "object"
      },
      "FlowRunDetailResponseDto": {
        "properties": {
          "nodes": {
            "items": {
              "$ref": "#/components/schemas/FlowRunNodeResponseDto"
            },
            "type": "array"
          },
          "run": {
            "$ref": "#/components/schemas/FlowRunResponseDto"
          }
        },
        "required": [
          "run",
          "nodes"
        ],
        "type": "object"
      },
      "FlowRunNodeResponseDto": {
        "properties": {
          "duration_ms": {
            "example": 1203,
            "nullable": true,
            "type": "number"
          },
          "error": {
            "nullable": true,
            "type": "string"
          },
          "finished_at": {
            "nullable": true,
            "type": "string"
          },
          "id": {
            "example": "5d1f2a3b-4c5d-6e7f-8091-a2b3c4d5e6f7",
            "type": "string"
          },
          "input_snapshot": {
            "additionalProperties": true,
            "description": "Lo que entró al nodo, ya con las referencias `@{…}` resueltas. Forma libre.",
            "nullable": true,
            "type": "object"
          },
          "media_ref_ids": {
            "description": "IDs de los archivos de Mediateca que el nodo generó o adjuntó.",
            "example": [
              3312,
              3313
            ],
            "items": {
              "type": "number"
            },
            "nullable": true,
            "type": "array"
          },
          "node_id": {
            "description": "`id` del nodo en el lienzo — así se cruza con `definition.nodes[]`.",
            "example": "n_7f3c1a",
            "type": "string"
          },
          "node_type": {
            "example": "agent.ask",
            "type": "string"
          },
          "output_artifact": {
            "additionalProperties": true,
            "description": "Lo que produjo el nodo. Su forma depende del `node_type`.",
            "nullable": true,
            "type": "object"
          },
          "run_id": {
            "example": "c3a5d7e9-1122-4455-8899-aabbccddeeff",
            "type": "string"
          },
          "started_at": {
            "nullable": true,
            "type": "string"
          },
          "status": {
            "description": "`waiting` = el nodo mandó su mensaje interactivo y espera la respuesta.",
            "enum": [
              "pending",
              "running",
              "success",
              "failed",
              "skipped",
              "waiting"
            ],
            "example": "success",
            "type": "string"
          }
        },
        "required": [
          "id",
          "run_id",
          "node_id",
          "node_type",
          "status",
          "input_snapshot",
          "output_artifact",
          "media_ref_ids",
          "error",
          "started_at",
          "finished_at",
          "duration_ms"
        ],
        "type": "object"
      },
      "FlowRunResponseDto": {
        "properties": {
          "created_by": {
            "example": 12,
            "nullable": true,
            "type": "number"
          },
          "definition_id": {
            "description": "Referencia a la definición ejecutada, en el catálogo `flow_definitions`.",
            "example": 918,
            "nullable": true,
            "type": "number"
          },
          "definition_used": {
            "allOf": [
              {
                "$ref": "#/components/schemas/FlowDefinitionDto"
              }
            ],
            "description": "Copia inline de la definición ejecutada. Solo en corridas viejas; las nuevas\nreferencian el catálogo deduplicado vía `definition_id`.",
            "nullable": true
          },
          "duration_ms": {
            "example": 4821,
            "nullable": true,
            "type": "number"
          },
          "error": {
            "description": "Mensaje del fallo cuando `status` es `failed`; `null` en cualquier otro caso.",
            "nullable": true,
            "type": "string"
          },
          "finished_at": {
            "description": "Cuándo llegó a un estado terminal. `null` si sigue corriendo o esperando.",
            "nullable": true,
            "type": "string"
          },
          "flow_id": {
            "example": "8f14e45f-ceea-467a-9f0b-4c3d1a2b5e60",
            "type": "string"
          },
          "id": {
            "example": "c3a5d7e9-1122-4455-8899-aabbccddeeff",
            "type": "string"
          },
          "result_text": {
            "description": "Texto que el nodo `function.result` devuelve al Met. `null` si el flujo no tiene uno.",
            "nullable": true,
            "type": "string"
          },
          "source": {
            "description": "Qué originó la corrida.",
            "enum": [
              "manual",
              "automation",
              "parent_flow",
              "broadcast",
              "function",
              "channel"
            ],
            "example": "automation",
            "type": "string"
          },
          "source_id": {
            "description": "ID de lo que la originó (la automatización, el flujo padre, el canal…).",
            "nullable": true,
            "type": "string"
          },
          "started_at": {
            "example": "2026-07-30T04:12:33.120Z",
            "type": "string"
          },
          "status": {
            "description": "`waiting` = suspendida por un nodo interactivo que espera respuesta del contacto.",
            "enum": [
              "running",
              "success",
              "failed",
              "cancelled",
              "waiting"
            ],
            "example": "success",
            "type": "string"
          },
          "trigger_payload": {
            "allOf": [
              {
                "$ref": "#/components/schemas/TriggerPayloadDto"
              }
            ],
            "nullable": true
          },
          "workspace_id": {
            "example": 40,
            "type": "number"
          }
        },
        "required": [
          "id",
          "flow_id",
          "workspace_id",
          "definition_used",
          "source",
          "source_id",
          "trigger_payload",
          "status",
          "error",
          "result_text",
          "started_at",
          "finished_at",
          "duration_ms",
          "created_by"
        ],
        "type": "object"
      },
      "FlowRunStartedResponseDto": {
        "properties": {
          "run_id": {
            "example": "c3a5d7e9-1122-4455-8899-aabbccddeeff",
            "type": "string"
          }
        },
        "required": [
          "run_id"
        ],
        "type": "object"
      },
      "FlowTestNodeResponseDto": {
        "properties": {
          "output_artifact": {
            "additionalProperties": true,
            "description": "Lo que produjo el nodo. Forma libre: depende del tipo. `null` si no produjo nada.",
            "nullable": true,
            "type": "object"
          }
        },
        "required": [
          "output_artifact"
        ],
        "type": "object"
      },
      "FolderCollectionSummaryDto": {
        "properties": {
          "code": {
            "description": "Identificador estable de la colección. A diferencia del slug, no cambia.",
            "example": "AB3K9Z",
            "nullable": true,
            "type": "string"
          },
          "created_at": {
            "description": "Solo en el detalle de una carpeta.",
            "example": "2026-07-30T04:12:33.120Z",
            "nullable": true,
            "type": "string"
          },
          "created_by": {
            "example": 91,
            "nullable": true,
            "type": "number"
          },
          "description": {
            "description": "Solo en el detalle de una carpeta.",
            "nullable": true,
            "type": "string"
          },
          "emoji": {
            "description": "Solo en el árbol de jerarquía.",
            "example": "🏠",
            "nullable": true,
            "type": "string"
          },
          "folder_id": {
            "nullable": true,
            "type": "string"
          },
          "id": {
            "example": 12,
            "type": "number"
          },
          "name": {
            "example": "Inmuebles",
            "type": "string"
          },
          "pinned_to_menu": {
            "example": false,
            "type": "boolean"
          },
          "position": {
            "example": 0,
            "type": "number"
          },
          "slug": {
            "example": "inmuebles",
            "nullable": true,
            "type": "string"
          },
          "visibility": {
            "example": "private",
            "type": "string"
          }
        },
        "required": [
          "id",
          "name",
          "slug",
          "code",
          "folder_id",
          "position",
          "visibility",
          "pinned_to_menu",
          "created_by"
        ],
        "type": "object"
      },
      "FolderDetailResponseDto": {
        "properties": {
          "collections": {
            "items": {
              "$ref": "#/components/schemas/FolderCollectionSummaryDto"
            },
            "type": "array"
          },
          "folder": {
            "$ref": "#/components/schemas/FolderResponseDto"
          },
          "subfolders": {
            "description": "Carpetas hijas directas. No baja más niveles: para el árbol completo, `/hierarchy`.",
            "items": {
              "$ref": "#/components/schemas/FolderResponseDto"
            },
            "type": "array"
          }
        },
        "required": [
          "folder",
          "subfolders",
          "collections"
        ],
        "type": "object"
      },
      "FolderHierarchyNodeDto": {
        "additionalProperties": true,
        "properties": {
          "collections": {
            "description": "Las colecciones que viven directamente en esta carpeta.",
            "items": {
              "$ref": "#/components/schemas/FolderCollectionSummaryDto"
            },
            "type": "array"
          },
          "id": {
            "example": "5f0a1e3c-9b2d-4a77-8f31-6c1d0e2b4a99",
            "type": "string"
          },
          "name": {
            "example": "Comercial",
            "type": "string"
          },
          "parent_folder_id": {
            "nullable": true,
            "type": "string"
          },
          "subfolders": {
            "description": "Sus carpetas hijas, ya anidadas. Vacío en las hojas.",
            "items": {
              "$ref": "#/components/schemas/FolderHierarchyNodeDto"
            },
            "type": "array"
          },
          "type": {
            "description": "Siempre `folder`. Distingue el nodo de una colección en respuestas mezcladas.",
            "enum": [
              "folder"
            ],
            "example": "folder",
            "type": "string"
          }
        },
        "required": [
          "id",
          "name",
          "parent_folder_id",
          "type",
          "subfolders",
          "collections"
        ],
        "type": "object"
      },
      "FolderHierarchyResponseDto": {
        "properties": {
          "collections": {
            "description": "Colecciones sin carpeta.",
            "items": {
              "$ref": "#/components/schemas/FolderCollectionSummaryDto"
            },
            "type": "array"
          },
          "folders": {
            "items": {
              "$ref": "#/components/schemas/FolderHierarchyNodeDto"
            },
            "type": "array"
          }
        },
        "required": [
          "folders",
          "collections"
        ],
        "type": "object"
      },
      "FolderMessageResponseDto": {
        "properties": {
          "message": {
            "description": "Texto fijo en inglés — es un acuse, no copy de producto.",
            "example": "Folder deleted",
            "type": "string"
          }
        },
        "required": [
          "message"
        ],
        "type": "object"
      },
      "FolderResponseDto": {
        "additionalProperties": true,
        "properties": {
          "created_at": {
            "example": "2026-07-30T04:12:33.120Z",
            "nullable": true,
            "type": "string"
          },
          "created_by": {
            "example": 91,
            "nullable": true,
            "type": "number"
          },
          "description": {
            "nullable": true,
            "type": "string"
          },
          "id": {
            "description": "UUID. A diferencia del id de una colección, no es numérico.",
            "example": "5f0a1e3c-9b2d-4a77-8f31-6c1d0e2b4a99",
            "type": "string"
          },
          "name": {
            "example": "Comercial",
            "type": "string"
          },
          "parent_folder_id": {
            "description": "Carpeta madre. `null` = la carpeta cuelga de la raíz del workspace.",
            "example": null,
            "nullable": true,
            "type": "string"
          },
          "position": {
            "description": "Orden dentro de su nivel. Lo persiste el arrastre en el menú.",
            "example": 0,
            "type": "number"
          },
          "visibility": {
            "example": "private",
            "type": "string"
          },
          "workspace_id": {
            "example": 134,
            "type": "number"
          }
        },
        "required": [
          "id",
          "workspace_id",
          "name",
          "parent_folder_id"
        ],
        "type": "object"
      },
      "FolderSearchResultDto": {
        "properties": {
          "id": {
            "example": "5f0a1e3c-9b2d-4a77-8f31-6c1d0e2b4a99",
            "type": "string"
          },
          "name": {
            "example": "Comercial",
            "type": "string"
          },
          "parent_folder_id": {
            "nullable": true,
            "type": "string"
          },
          "visibility": {
            "example": "private",
            "type": "string"
          }
        },
        "required": [
          "id",
          "name",
          "parent_folder_id",
          "visibility"
        ],
        "type": "object"
      },
      "FunctionDeleteResponseDto": {
        "properties": {
          "ok": {
            "example": true,
            "type": "boolean"
          },
          "unlinked_mets_count": {
            "description": "Cuántos vínculos Met → Función se borraron junto con la función.",
            "example": 2,
            "type": "number"
          }
        },
        "required": [
          "ok",
          "unlinked_mets_count"
        ],
        "type": "object"
      },
      "FunctionHttpConfigDto": {
        "properties": {
          "auth_workspace_variable": {
            "description": "Nombre de la variable del workspace que guarda el Bearer token. El token en sí\nno se devuelve nunca.",
            "example": "API_TOKEN_PEDIDOS",
            "type": "string"
          },
          "headers": {
            "additionalProperties": {
              "type": "string"
            },
            "description": "Headers estáticos **no sensibles**. `Content-Type` lo pone Meteor solo si hay\ncuerpo JSON.",
            "type": "object"
          },
          "method": {
            "enum": [
              "GET",
              "POST",
              "PUT",
              "PATCH",
              "DELETE"
            ],
            "example": "POST",
            "type": "string"
          },
          "sign_secret_variable": {
            "description": "Nombre de la variable del workspace con el secreto que firma `X-Met-Signature`.\nEl secreto en sí no se devuelve nunca.",
            "example": "FIRMA_PEDIDOS",
            "type": "string"
          },
          "timeout_ms": {
            "description": "Timeout de la llamada, en milisegundos. Default 30 000, tope 60 000.",
            "example": 30000,
            "type": "number"
          },
          "url": {
            "description": "Endpoint del cliente que se invoca cuando el Met usa la tool.",
            "example": "https://api.tu-empresa.com/pedidos",
            "type": "string"
          }
        },
        "required": [
          "url"
        ],
        "type": "object"
      },
      "FunctionLinkResponseDto": {
        "properties": {
          "already": {
            "description": "`true` si el vínculo ya existía y no se creó nada nuevo.",
            "example": false,
            "type": "boolean"
          },
          "id": {
            "description": "ID de la fila de vínculo (`item_links`).",
            "example": 4471,
            "type": "number"
          }
        },
        "required": [
          "id",
          "already"
        ],
        "type": "object"
      },
      "FunctionListResponseDto": {
        "properties": {
          "functions": {
            "items": {
              "$ref": "#/components/schemas/FunctionResponseDto"
            },
            "type": "array"
          }
        },
        "required": [
          "functions"
        ],
        "type": "object"
      },
      "FunctionParameterDto": {
        "properties": {
          "description": {
            "description": "Qué es el parámetro. El Met lo lee para saber qué recolectar.",
            "example": "Número de la orden que el cliente quiere consultar",
            "type": "string"
          },
          "enum_values": {
            "description": "Valores permitidos (enum del JSON schema). `null` = valor libre.",
            "example": [
              "abierto",
              "cerrado"
            ],
            "items": {
              "type": "string"
            },
            "nullable": true,
            "type": "array"
          },
          "memory": {
            "description": "Flag \"Memoria\" heredado de uChat. Se persiste; reservado para uso futuro.",
            "example": false,
            "type": "boolean"
          },
          "name": {
            "description": "Nombre EN INGLÉS — entra al JSON schema de la tool como propiedad.",
            "example": "order_id",
            "type": "string"
          },
          "required": {
            "description": "`true` = el Met no puede invocar la tool sin este valor.",
            "example": true,
            "type": "boolean"
          },
          "save_to": {
            "description": "`field_key` del contacto (o `workspace.<nombre>`) donde persistir el valor\nque el Met recolectó. `null` = no se guarda en ningún lado.",
            "example": "ultimo_pedido",
            "nullable": true,
            "type": "string"
          },
          "type": {
            "description": "Tipo del parámetro en el JSON schema de la tool.",
            "enum": [
              "string",
              "number",
              "boolean"
            ],
            "example": "string",
            "type": "string"
          }
        },
        "required": [
          "name",
          "description",
          "required",
          "save_to",
          "memory",
          "enum_values",
          "type"
        ],
        "type": "object"
      },
      "FunctionResponseDto": {
        "properties": {
          "activo": {
            "description": "`false` = la función existe pero no se le ofrece al modelo.",
            "example": true,
            "type": "boolean"
          },
          "descripcion": {
            "description": "Para qué sirve la función. Es la descripción de la tool.",
            "example": "Consulta el estado de un pedido por su número",
            "type": "string"
          },
          "flow_id": {
            "description": "UUID del flujo que atiende la tool. `null` si el handler no es un flujo.",
            "example": "5f0a1e3c-9b2d-4a77-8f31-6c1d0e2b4a99",
            "nullable": true,
            "type": "string"
          },
          "function_id": {
            "description": "ID de la función. Es el que se usa en las rutas `functions/{functionId}`.",
            "example": 812,
            "type": "number"
          },
          "function_prompt": {
            "description": "\"Indicador de función\": guía de cuándo y cómo usarla.",
            "example": "Úsala solo cuando el cliente mencione un número de pedido.",
            "type": "string"
          },
          "http": {
            "allOf": [
              {
                "$ref": "#/components/schemas/FunctionHttpConfigDto"
              }
            ],
            "description": "Config del handler HTTP directo. `null` si el handler no es HTTP.",
            "nullable": true
          },
          "nombre": {
            "description": "Nombre EN INGLÉS — se sanitiza al nombre de la tool que ve el modelo.",
            "example": "consultar_pedido",
            "type": "string"
          },
          "parameters": {
            "items": {
              "$ref": "#/components/schemas/FunctionParameterDto"
            },
            "type": "array"
          }
        },
        "required": [
          "function_id",
          "nombre",
          "descripcion",
          "function_prompt",
          "parameters",
          "flow_id",
          "http",
          "activo"
        ],
        "type": "object"
      },
      "FunctionUnlinkResponseDto": {
        "properties": {
          "ok": {
            "example": true,
            "type": "boolean"
          }
        },
        "required": [
          "ok"
        ],
        "type": "object"
      },
      "GenerateImageDto": {
        "properties": {
          "aspect_ratio": {
            "maxLength": 20,
            "type": "string"
          },
          "model": {
            "maxLength": 120,
            "type": "string"
          },
          "prompt": {
            "maxLength": 4000,
            "minLength": 1,
            "type": "string"
          }
        },
        "required": [
          "prompt"
        ],
        "type": "object"
      },
      "GenerateVideoDto": {
        "properties": {
          "duration_seconds": {
            "minimum": 1,
            "type": "number"
          },
          "image_base64": {
            "minLength": 1,
            "type": "string"
          },
          "model": {
            "maxLength": 120,
            "type": "string"
          },
          "prompt": {
            "maxLength": 4000,
            "minLength": 1,
            "type": "string"
          }
        },
        "required": [
          "prompt"
        ],
        "type": "object"
      },
      "IdentityApiKeyDto": {
        "properties": {
          "env": {
            "description": "`test` para las keys `met_test_`, `live` para las `met_live_`.",
            "enum": [
              "live",
              "test"
            ],
            "example": "live",
            "type": "string"
          },
          "id": {
            "description": "ID de la key — el mismo que muestra el panel y el que se registra en los\nlogs de request. No es una credencial: no autentica nada por sí solo.",
            "example": "key_01HXYZ",
            "type": "string"
          },
          "monthly_quota": {
            "description": "Cupo de requests del mes en curso, con el mismo criterio. `null` = sin tope.",
            "example": 100000,
            "nullable": true,
            "type": "number"
          },
          "object": {
            "enum": [
              "api_key"
            ],
            "example": "api_key",
            "type": "string"
          },
          "owner_type": {
            "description": "Quién es el dueño de la key. `workspace` es una key de un cliente,\n`partner` una key de Tech Partner y `staff` una credencial interna del CLI\nde Meteor (no se emite desde el panel de un cliente).",
            "enum": [
              "workspace",
              "partner",
              "staff"
            ],
            "example": "workspace",
            "type": "string"
          },
          "rate_limit_rpm": {
            "description": "Techo de requests por minuto que se te aplica: el más estricto entre el de la\nkey y el del plan del workspace. `null` = sin tope. Es el número con el que\nte vas a encontrar en un `429`, así que poder leerlo antes evita descubrirlo\na golpes.",
            "example": 120,
            "nullable": true,
            "type": "number"
          },
          "scopes": {
            "description": "Los scopes que porta la key, ordenados alfabéticamente para que la respuesta\nsea estable entre llamadas.\n\nOjo con `owner_type: 'staff'`: ahí los valores **no** son scopes de la API\npública sino claves del catálogo de permisos del panel, y los permisos\nefectivos son la intersección con los de la persona dueña de la key.",
            "example": [
              "items:read",
              "runs:execute",
              "runs:read"
            ],
            "items": {
              "type": "string"
            },
            "type": "array"
          }
        },
        "required": [
          "id",
          "object",
          "owner_type",
          "env",
          "scopes",
          "rate_limit_rpm",
          "monthly_quota"
        ],
        "type": "object"
      },
      "IdentityPartnerDto": {
        "properties": {
          "id": {
            "example": "a3f1c2de-0000-4c1f-9a11-6b2f4d8e7c01",
            "type": "string"
          },
          "object": {
            "enum": [
              "partner"
            ],
            "example": "partner",
            "type": "string"
          }
        },
        "required": [
          "object",
          "id"
        ],
        "type": "object"
      },
      "IdentityResponseDto": {
        "properties": {
          "api_key": {
            "$ref": "#/components/schemas/IdentityApiKeyDto"
          },
          "livemode": {
            "description": "`false` si la key es de modo de prueba (`met_test_`). Refleja `env` — es el\nmismo dato en la forma que ya usa el resto del contrato (§6 de las\nconvenciones), para no obligar a nadie a comparar strings.",
            "example": true,
            "type": "boolean"
          },
          "object": {
            "enum": [
              "identity"
            ],
            "example": "identity",
            "type": "string"
          },
          "partner": {
            "allOf": [
              {
                "$ref": "#/components/schemas/IdentityPartnerDto"
              }
            ],
            "description": "El partner dueño de la key, o `null` si la key no es de partner.",
            "nullable": true
          },
          "workspace": {
            "allOf": [
              {
                "$ref": "#/components/schemas/IdentityWorkspaceDto"
              }
            ],
            "description": "El workspace sobre el que opera este request. Para una key de workspace es\nsiempre el suyo; para una key de partner es el workspace atribuido que estás\noperando. `null` cuando la key no está operando ninguno.",
            "nullable": true
          }
        },
        "required": [
          "object",
          "livemode",
          "api_key",
          "workspace",
          "partner"
        ],
        "type": "object"
      },
      "IdentityWorkspaceDto": {
        "properties": {
          "id": {
            "example": 7,
            "type": "number"
          },
          "object": {
            "enum": [
              "workspace"
            ],
            "example": "workspace",
            "type": "string"
          },
          "slug": {
            "description": "Slug del workspace, el mismo de la URL del panel. `null` si no se resolvió.",
            "example": "acme",
            "nullable": true,
            "type": "string"
          }
        },
        "required": [
          "object",
          "id",
          "slug"
        ],
        "type": "object"
      },
      "ImageProviderDto": {
        "properties": {
          "id": {
            "example": "nano-banana-2",
            "type": "string"
          },
          "label": {
            "example": "Nano Banana 2",
            "type": "string"
          },
          "supports_reference_images": {
            "description": "Si acepta imágenes de referencia además del prompt.",
            "example": true,
            "type": "boolean"
          }
        },
        "required": [
          "id",
          "label",
          "supports_reference_images"
        ],
        "type": "object"
      },
      "ImageResultDto": {
        "properties": {
          "format": {
            "description": "Tipo MIME del archivo generado.",
            "example": "image/png",
            "type": "string"
          },
          "model": {
            "description": "Modelo que la generó, resuelto (el que pediste, o el default del handler).",
            "example": "gemini-3-pro-image-preview",
            "type": "string"
          },
          "size_bytes": {
            "description": "Peso del archivo en bytes. Ausente si el proveedor no lo informa.",
            "example": 1048576,
            "type": "number"
          },
          "url": {
            "description": "URL del archivo generado, ya alojado por Meteor (no la URL temporal del\nproveedor). Es el **original**, a resolución completa: úsalo para el visor a\npantalla completa y para la descarga. Para mostrarlo en chico —una miniatura,\nuna fila de lista, un avatar— pide la versión ya dimensionada agregando\n`?width=…&height=…` a la ruta de render de Storage, en vez de descargar\nmegabytes para pintar un cuadradito.\n\nSi el almacenamiento no está disponible, viene como `data:` URI en línea.",
            "example": "https://…supabase.co/storage/v1/object/public/generated-images/gemini/1753848291233-a1b2c3d4.png",
            "type": "string"
          }
        },
        "required": [
          "url",
          "format",
          "model"
        ],
        "type": "object"
      },
      "ImportContactRow": {
        "properties": {
          "custom": {
            "description": "Campos personalizados del workspace, con su `field_key` PELADO como clave\n(`{ etapa: 'Nuevo', monto: '6300000' }`) — la convención de `items.data`:\nsistema con `$`, personalizados sin nada.\n\nExiste porque el archivo del cliente casi nunca trae las columnas con\nnuestros nombres: el frontend mapea sus encabezados a campos y manda acá lo\nque no es de sistema. Solo se aceptan claves que YA existen como\nfield-definition del workspace; el resto se descarta (importBatch valida).",
            "type": "object"
          },
          "email": {
            "maxLength": 200,
            "minLength": 0,
            "type": "string"
          },
          "first_name": {
            "maxLength": 100,
            "minLength": 0,
            "type": "string"
          },
          "gender": {
            "maxLength": 32,
            "minLength": 0,
            "type": "string"
          },
          "image": {
            "maxLength": 1024,
            "minLength": 0,
            "type": "string"
          },
          "last_message_at": {
            "maxLength": 64,
            "minLength": 0,
            "type": "string"
          },
          "last_name": {
            "maxLength": 100,
            "minLength": 0,
            "type": "string"
          },
          "locale": {
            "maxLength": 32,
            "minLength": 0,
            "type": "string"
          },
          "name": {
            "maxLength": 200,
            "minLength": 0,
            "type": "string"
          },
          "phone": {
            "maxLength": 64,
            "minLength": 0,
            "type": "string"
          },
          "status": {
            "maxLength": 32,
            "minLength": 0,
            "type": "string"
          },
          "summary": {
            "maxLength": 8000,
            "minLength": 0,
            "type": "string"
          },
          "tags": {
            "maxLength": 2000,
            "minLength": 0,
            "type": "string"
          },
          "user_ns": {
            "maxLength": 128,
            "minLength": 0,
            "type": "string"
          }
        },
        "type": "object"
      },
      "ImportContactsDto": {
        "properties": {
          "contacts": {
            "items": {
              "$ref": "#/components/schemas/ImportContactRow"
            },
            "maxItems": 500,
            "minItems": 1,
            "type": "array"
          }
        },
        "required": [
          "contacts"
        ],
        "type": "object"
      },
      "ImportItemsDto": {
        "properties": {
          "keyField": {
            "description": "Field clave para upsert (match por data->>keyField). Si se omite → modo insert-only: inserta todas las filas sin deduplicar.",
            "type": "string"
          },
          "rows": {
            "description": "Filas a importar (máx 5000), keyed por field name.",
            "items": {
              "type": "object"
            },
            "maxItems": 5000,
            "type": "array"
          }
        },
        "required": [
          "rows"
        ],
        "type": "object"
      },
      "InboundWebhookCreatedDto": {
        "properties": {
          "binding_target": {
            "additionalProperties": true,
            "description": "A qué apunta el binding. `{ \"task_id\": 17 }` para `task`,\n`{ \"mcp_key\": \"mercadopago\", \"workspace_mcp_id\": 42 }` para `mcp`, `null`\npara `generic`.",
            "nullable": true,
            "type": "object"
          },
          "binding_type": {
            "description": "Qué hace Meteor al recibir un evento: `task` ejecuta una tarea, `generic`\nsolo lo registra y emite el evento, `mcp` pertenece a una integración (esos\nno se crean ni se borran por esta API).",
            "enum": [
              "mcp",
              "task",
              "generic"
            ],
            "example": "generic",
            "type": "string"
          },
          "created_at": {
            "example": "2026-07-30T04:12:33.120Z",
            "type": "string"
          },
          "created_by": {
            "description": "Usuario que creó el endpoint.",
            "example": 77,
            "nullable": true,
            "type": "number"
          },
          "dedupe_events": {
            "description": "`true` = el mismo `external_id` entra una sola vez, para que un reintento del\nproveedor no dispare la tarea dos veces.",
            "example": false,
            "type": "boolean"
          },
          "description": {
            "example": "Avisos de la plataforma de e-commerce",
            "nullable": true,
            "type": "string"
          },
          "enabled": {
            "description": "`false` = el endpoint responde pero no procesa nada.",
            "example": true,
            "type": "boolean"
          },
          "field_mappings": {
            "description": "Mapeo de payload → campos. Solo en el detalle y al guardar el mapeo.",
            "items": {
              "$ref": "#/components/schemas/WebhookFieldMappingDto"
            },
            "nullable": true,
            "type": "array"
          },
          "id": {
            "example": 91,
            "type": "number"
          },
          "link_contact": {
            "description": "`true` = el mapeo resuelve (o crea) el contacto cuando el payload trae\nteléfono, correo o `user_ns`.",
            "example": false,
            "type": "boolean"
          },
          "name": {
            "example": "Pedidos de la tienda",
            "type": "string"
          },
          "paused_at": {
            "description": "Cuándo Meteor pausó el endpoint sola por superar su techo diario. `null` si\nno está pausado.",
            "example": null,
            "nullable": true,
            "type": "string"
          },
          "paused_reason": {
            "description": "Por qué se pausó. `null` si no está pausado.",
            "example": null,
            "nullable": true,
            "type": "string"
          },
          "secret": {
            "description": "Secreto HMAC con el que firmar los envíos. `null` cuando\n`verifier_type` es `none`.",
            "example": "a1b2c3d4e5f60718293a4b5c6d7e8f90",
            "nullable": true,
            "type": "string"
          },
          "signature_header": {
            "description": "Cabecera de la que se lee la firma HMAC, siempre en minúsculas.",
            "example": "x-signature",
            "type": "string"
          },
          "slug": {
            "description": "Parte opaca de la URL pública de recepción. No lleva el `workspace_id`, para\nque nadie pueda enumerar endpoints ajenos.",
            "example": "k3f9x2mq7rt1vb8z",
            "type": "string"
          },
          "updated_at": {
            "example": "2026-07-30T04:12:33.120Z",
            "type": "string"
          },
          "verifier_type": {
            "description": "Cómo se verifica que el evento venga de quien dice.",
            "enum": [
              "mcp_native",
              "hmac_sha256",
              "none"
            ],
            "example": "hmac_sha256",
            "type": "string"
          },
          "workspace_id": {
            "example": 134,
            "type": "number"
          }
        },
        "required": [
          "id",
          "slug",
          "name",
          "description",
          "binding_type",
          "binding_target",
          "verifier_type",
          "signature_header",
          "enabled",
          "created_at",
          "updated_at",
          "workspace_id",
          "secret",
          "created_by"
        ],
        "type": "object"
      },
      "InboundWebhookDetailDto": {
        "properties": {
          "binding_target": {
            "additionalProperties": true,
            "description": "A qué apunta el binding. `{ \"task_id\": 17 }` para `task`,\n`{ \"mcp_key\": \"mercadopago\", \"workspace_mcp_id\": 42 }` para `mcp`, `null`\npara `generic`.",
            "nullable": true,
            "type": "object"
          },
          "binding_type": {
            "description": "Qué hace Meteor al recibir un evento: `task` ejecuta una tarea, `generic`\nsolo lo registra y emite el evento, `mcp` pertenece a una integración (esos\nno se crean ni se borran por esta API).",
            "enum": [
              "mcp",
              "task",
              "generic"
            ],
            "example": "generic",
            "type": "string"
          },
          "connected_flow": {
            "allOf": [
              {
                "$ref": "#/components/schemas/ConnectedFlowDto"
              }
            ],
            "description": "El flujo que se ejecuta al recibir un evento. `null` si no hay ninguno.",
            "nullable": true
          },
          "created_at": {
            "example": "2026-07-30T04:12:33.120Z",
            "type": "string"
          },
          "dedupe_events": {
            "description": "`true` = el mismo `external_id` entra una sola vez, para que un reintento del\nproveedor no dispare la tarea dos veces.",
            "example": false,
            "type": "boolean"
          },
          "description": {
            "example": "Avisos de la plataforma de e-commerce",
            "nullable": true,
            "type": "string"
          },
          "enabled": {
            "description": "`false` = el endpoint responde pero no procesa nada.",
            "example": true,
            "type": "boolean"
          },
          "field_mappings": {
            "description": "Mapeo de payload → campos. Solo en el detalle y al guardar el mapeo.",
            "items": {
              "$ref": "#/components/schemas/WebhookFieldMappingDto"
            },
            "nullable": true,
            "type": "array"
          },
          "id": {
            "example": 91,
            "type": "number"
          },
          "link_contact": {
            "description": "`true` = el mapeo resuelve (o crea) el contacto cuando el payload trae\nteléfono, correo o `user_ns`.",
            "example": false,
            "type": "boolean"
          },
          "name": {
            "example": "Pedidos de la tienda",
            "type": "string"
          },
          "paused_at": {
            "description": "Cuándo Meteor pausó el endpoint sola por superar su techo diario. `null` si\nno está pausado.",
            "example": null,
            "nullable": true,
            "type": "string"
          },
          "paused_reason": {
            "description": "Por qué se pausó. `null` si no está pausado.",
            "example": null,
            "nullable": true,
            "type": "string"
          },
          "signature_header": {
            "description": "Cabecera de la que se lee la firma HMAC, siempre en minúsculas.",
            "example": "x-signature",
            "type": "string"
          },
          "slug": {
            "description": "Parte opaca de la URL pública de recepción. No lleva el `workspace_id`, para\nque nadie pueda enumerar endpoints ajenos.",
            "example": "k3f9x2mq7rt1vb8z",
            "type": "string"
          },
          "updated_at": {
            "example": "2026-07-30T04:12:33.120Z",
            "type": "string"
          },
          "verifier_type": {
            "description": "Cómo se verifica que el evento venga de quien dice.",
            "enum": [
              "mcp_native",
              "hmac_sha256",
              "none"
            ],
            "example": "hmac_sha256",
            "type": "string"
          }
        },
        "required": [
          "id",
          "slug",
          "name",
          "description",
          "binding_type",
          "binding_target",
          "verifier_type",
          "signature_header",
          "enabled",
          "created_at",
          "updated_at",
          "connected_flow"
        ],
        "type": "object"
      },
      "InboundWebhookDto": {
        "properties": {
          "binding_target": {
            "additionalProperties": true,
            "description": "A qué apunta el binding. `{ \"task_id\": 17 }` para `task`,\n`{ \"mcp_key\": \"mercadopago\", \"workspace_mcp_id\": 42 }` para `mcp`, `null`\npara `generic`.",
            "nullable": true,
            "type": "object"
          },
          "binding_type": {
            "description": "Qué hace Meteor al recibir un evento: `task` ejecuta una tarea, `generic`\nsolo lo registra y emite el evento, `mcp` pertenece a una integración (esos\nno se crean ni se borran por esta API).",
            "enum": [
              "mcp",
              "task",
              "generic"
            ],
            "example": "generic",
            "type": "string"
          },
          "created_at": {
            "example": "2026-07-30T04:12:33.120Z",
            "type": "string"
          },
          "dedupe_events": {
            "description": "`true` = el mismo `external_id` entra una sola vez, para que un reintento del\nproveedor no dispare la tarea dos veces.",
            "example": false,
            "type": "boolean"
          },
          "description": {
            "example": "Avisos de la plataforma de e-commerce",
            "nullable": true,
            "type": "string"
          },
          "enabled": {
            "description": "`false` = el endpoint responde pero no procesa nada.",
            "example": true,
            "type": "boolean"
          },
          "field_mappings": {
            "description": "Mapeo de payload → campos. Solo en el detalle y al guardar el mapeo.",
            "items": {
              "$ref": "#/components/schemas/WebhookFieldMappingDto"
            },
            "nullable": true,
            "type": "array"
          },
          "id": {
            "example": 91,
            "type": "number"
          },
          "link_contact": {
            "description": "`true` = el mapeo resuelve (o crea) el contacto cuando el payload trae\nteléfono, correo o `user_ns`.",
            "example": false,
            "type": "boolean"
          },
          "name": {
            "example": "Pedidos de la tienda",
            "type": "string"
          },
          "paused_at": {
            "description": "Cuándo Meteor pausó el endpoint sola por superar su techo diario. `null` si\nno está pausado.",
            "example": null,
            "nullable": true,
            "type": "string"
          },
          "paused_reason": {
            "description": "Por qué se pausó. `null` si no está pausado.",
            "example": null,
            "nullable": true,
            "type": "string"
          },
          "signature_header": {
            "description": "Cabecera de la que se lee la firma HMAC, siempre en minúsculas.",
            "example": "x-signature",
            "type": "string"
          },
          "slug": {
            "description": "Parte opaca de la URL pública de recepción. No lleva el `workspace_id`, para\nque nadie pueda enumerar endpoints ajenos.",
            "example": "k3f9x2mq7rt1vb8z",
            "type": "string"
          },
          "updated_at": {
            "example": "2026-07-30T04:12:33.120Z",
            "type": "string"
          },
          "verifier_type": {
            "description": "Cómo se verifica que el evento venga de quien dice.",
            "enum": [
              "mcp_native",
              "hmac_sha256",
              "none"
            ],
            "example": "hmac_sha256",
            "type": "string"
          }
        },
        "required": [
          "id",
          "slug",
          "name",
          "description",
          "binding_type",
          "binding_target",
          "verifier_type",
          "signature_header",
          "enabled",
          "created_at",
          "updated_at"
        ],
        "type": "object"
      },
      "InboundWebhookListItemDto": {
        "properties": {
          "binding_target": {
            "additionalProperties": true,
            "description": "A qué apunta el binding. `{ \"task_id\": 17 }` para `task`,\n`{ \"mcp_key\": \"mercadopago\", \"workspace_mcp_id\": 42 }` para `mcp`, `null`\npara `generic`.",
            "nullable": true,
            "type": "object"
          },
          "binding_type": {
            "description": "Qué hace Meteor al recibir un evento: `task` ejecuta una tarea, `generic`\nsolo lo registra y emite el evento, `mcp` pertenece a una integración (esos\nno se crean ni se borran por esta API).",
            "enum": [
              "mcp",
              "task",
              "generic"
            ],
            "example": "generic",
            "type": "string"
          },
          "connected_flow": {
            "allOf": [
              {
                "$ref": "#/components/schemas/ConnectedFlowDto"
              }
            ],
            "description": "El flujo que se ejecuta al recibir un evento. `null` si no hay ninguno.",
            "nullable": true
          },
          "created_at": {
            "example": "2026-07-30T04:12:33.120Z",
            "type": "string"
          },
          "dedupe_events": {
            "description": "`true` = el mismo `external_id` entra una sola vez, para que un reintento del\nproveedor no dispare la tarea dos veces.",
            "example": false,
            "type": "boolean"
          },
          "description": {
            "example": "Avisos de la plataforma de e-commerce",
            "nullable": true,
            "type": "string"
          },
          "enabled": {
            "description": "`false` = el endpoint responde pero no procesa nada.",
            "example": true,
            "type": "boolean"
          },
          "field_mappings": {
            "description": "Mapeo de payload → campos. Solo en el detalle y al guardar el mapeo.",
            "items": {
              "$ref": "#/components/schemas/WebhookFieldMappingDto"
            },
            "nullable": true,
            "type": "array"
          },
          "id": {
            "example": 91,
            "type": "number"
          },
          "link_contact": {
            "description": "`true` = el mapeo resuelve (o crea) el contacto cuando el payload trae\nteléfono, correo o `user_ns`.",
            "example": false,
            "type": "boolean"
          },
          "name": {
            "example": "Pedidos de la tienda",
            "type": "string"
          },
          "paused_at": {
            "description": "Cuándo Meteor pausó el endpoint sola por superar su techo diario. `null` si\nno está pausado.",
            "example": null,
            "nullable": true,
            "type": "string"
          },
          "paused_reason": {
            "description": "Por qué se pausó. `null` si no está pausado.",
            "example": null,
            "nullable": true,
            "type": "string"
          },
          "recent_events_24h": {
            "description": "Cuántos eventos entraron en las últimas 24 horas.",
            "example": 12,
            "type": "number"
          },
          "signature_header": {
            "description": "Cabecera de la que se lee la firma HMAC, siempre en minúsculas.",
            "example": "x-signature",
            "type": "string"
          },
          "slug": {
            "description": "Parte opaca de la URL pública de recepción. No lleva el `workspace_id`, para\nque nadie pueda enumerar endpoints ajenos.",
            "example": "k3f9x2mq7rt1vb8z",
            "type": "string"
          },
          "updated_at": {
            "example": "2026-07-30T04:12:33.120Z",
            "type": "string"
          },
          "verifier_type": {
            "description": "Cómo se verifica que el evento venga de quien dice.",
            "enum": [
              "mcp_native",
              "hmac_sha256",
              "none"
            ],
            "example": "hmac_sha256",
            "type": "string"
          }
        },
        "required": [
          "id",
          "slug",
          "name",
          "description",
          "binding_type",
          "binding_target",
          "verifier_type",
          "signature_header",
          "enabled",
          "created_at",
          "updated_at",
          "recent_events_24h",
          "connected_flow"
        ],
        "type": "object"
      },
      "InstallSnapshotDto": {
        "properties": {
          "variables": {
            "description": "Valores del wizard de variables: { nombre_negocio: 'Mi Tienda', ... }",
            "type": "object"
          }
        },
        "type": "object"
      },
      "IntegrationActivatedResponseDto": {
        "properties": {
          "connected": {
            "example": true,
            "type": "boolean"
          },
          "connection_status": {
            "description": "Estado de la conexión tras activar. `null` si todavía no se probó.",
            "example": "connected",
            "nullable": true,
            "type": "string"
          },
          "id": {
            "example": "mercadopago",
            "type": "string"
          },
          "object": {
            "enum": [
              "integration"
            ],
            "example": "integration",
            "type": "string"
          }
        },
        "required": [
          "id",
          "object",
          "connected",
          "connection_status"
        ],
        "type": "object"
      },
      "IntegrationDeactivatedResponseDto": {
        "properties": {
          "connected": {
            "example": false,
            "type": "boolean"
          },
          "id": {
            "example": "mercadopago",
            "type": "string"
          },
          "object": {
            "enum": [
              "integration"
            ],
            "example": "integration",
            "type": "string"
          }
        },
        "required": [
          "id",
          "object",
          "connected"
        ],
        "type": "object"
      },
      "IntegrationRegisteredResponseDto": {
        "properties": {
          "connected": {
            "description": "Queda activa de una vez: no hace falta llamar a `activate`.",
            "example": true,
            "type": "boolean"
          },
          "endpoint": {
            "description": "El endpoint MCP que registraste. Las credenciales no se devuelven.",
            "example": "https://mcp.mi-erp.com/rpc",
            "type": "string"
          },
          "id": {
            "description": "Úsalo como `key` en `tools`, `execute` y `deactivate`.",
            "example": "ws134_mi_erp",
            "type": "string"
          },
          "name": {
            "example": "Mi ERP",
            "type": "string"
          },
          "object": {
            "enum": [
              "integration"
            ],
            "example": "integration",
            "type": "string"
          },
          "tools_count": {
            "description": "Cuántas tools descubrió Meteor al conectarse por primera vez.",
            "example": 7,
            "type": "number"
          }
        },
        "required": [
          "id",
          "object",
          "connected",
          "name",
          "endpoint",
          "tools_count"
        ],
        "type": "object"
      },
      "IntegrationResponseDto": {
        "properties": {
          "connected": {
            "description": "`true` si el workspace la tiene activa.",
            "example": true,
            "type": "boolean"
          },
          "connection_status": {
            "description": "Resultado de la última prueba de conexión (`connected`, `error`, …). `null`\nsi nunca se probó.",
            "example": "connected",
            "nullable": true,
            "type": "string"
          },
          "description": {
            "example": "Cobros y estado de pagos",
            "nullable": true,
            "type": "string"
          },
          "id": {
            "description": "ID de la integración. Es el `key` de las rutas `integrations/{key}/…`.",
            "example": "mercadopago",
            "type": "string"
          },
          "last_tested_at": {
            "description": "Cuándo se probó la conexión por última vez. `null` si nunca.",
            "example": "2026-07-30T04:12:33.120Z",
            "nullable": true,
            "type": "string"
          },
          "name": {
            "example": "Mercado Pago",
            "type": "string"
          },
          "object": {
            "description": "Siempre `integration`. Distingue el tipo de objeto en respuestas mezcladas.",
            "enum": [
              "integration"
            ],
            "example": "integration",
            "type": "string"
          }
        },
        "required": [
          "id",
          "object",
          "name",
          "description",
          "connected",
          "connection_status",
          "last_tested_at"
        ],
        "type": "object"
      },
      "IntegrationToolExecutionResponseDto": {
        "properties": {
          "execution_time_ms": {
            "description": "Cuánto tardó la ejecución, en milisegundos.",
            "example": 412,
            "type": "number"
          },
          "object": {
            "enum": [
              "tool_execution"
            ],
            "example": "tool_execution",
            "type": "string"
          },
          "output": {
            "additionalProperties": true,
            "description": "Lo que devolvió la tool. La forma la define el servidor MCP de la\nintegración, así que es libre. `null` si la tool no devolvió nada.",
            "nullable": true,
            "type": "object"
          },
          "status": {
            "description": "Siempre `success`: un fallo de la integración no llega acá, sale como error\n`integration_upstream_error` (502).",
            "enum": [
              "success"
            ],
            "example": "success",
            "type": "string"
          }
        },
        "required": [
          "object",
          "status",
          "output",
          "execution_time_ms"
        ],
        "type": "object"
      },
      "IntegrationToolResponseDto": {
        "properties": {
          "description": {
            "example": "Busca pagos por rango de fechas",
            "nullable": true,
            "type": "string"
          },
          "input_schema": {
            "additionalProperties": true,
            "description": "JSON Schema de los argumentos que acepta la tool. Lo define el servidor MCP\nde la integración, así que su forma es libre.",
            "type": "object"
          },
          "name": {
            "description": "Nombre de la tool: es el `{tool}` de la ruta de ejecución.",
            "example": "search_payments",
            "type": "string"
          }
        },
        "required": [
          "name",
          "description",
          "input_schema"
        ],
        "type": "object"
      },
      "InteractiveButtonDto": {
        "properties": {
          "id": {
            "maxLength": 256,
            "minLength": 1,
            "type": "string"
          },
          "title": {
            "maxLength": 20,
            "minLength": 1,
            "type": "string"
          }
        },
        "required": [
          "id",
          "title"
        ],
        "type": "object"
      },
      "InteractiveListRowDto": {
        "properties": {
          "description": {
            "maxLength": 72,
            "type": "string"
          },
          "id": {
            "maxLength": 200,
            "minLength": 1,
            "type": "string"
          },
          "title": {
            "maxLength": 24,
            "minLength": 1,
            "type": "string"
          }
        },
        "required": [
          "id",
          "title"
        ],
        "type": "object"
      },
      "InteractiveListSectionDto": {
        "properties": {
          "rows": {
            "items": {
              "$ref": "#/components/schemas/InteractiveListRowDto"
            },
            "maxItems": 10,
            "minItems": 1,
            "type": "array"
          },
          "title": {
            "maxLength": 24,
            "type": "string"
          }
        },
        "required": [
          "rows"
        ],
        "type": "object"
      },
      "InvoiceResponseDto": {
        "properties": {
          "amount_due": {
            "description": "Importe adeudado, en la moneda de `currency` y ya en unidad mayor (no en\ncentavos). Las monedas sin decimales no se dividen.",
            "example": 99,
            "type": "number"
          },
          "amount_paid": {
            "description": "Importe efectivamente pagado, en la moneda de `currency`.",
            "example": 99,
            "type": "number"
          },
          "created": {
            "example": "2026-07-01T00:00:07.000Z",
            "nullable": true,
            "type": "string"
          },
          "currency": {
            "description": "Moneda de la factura, en minúsculas. Puede no ser USD.",
            "example": "usd",
            "type": "string"
          },
          "description": {
            "example": "Plan Crecimiento — julio 2026",
            "nullable": true,
            "type": "string"
          },
          "hosted_invoice_url": {
            "description": "Página de la factura alojada por Stripe, también temporal.",
            "example": "https://invoice.stripe.com/i/acct_…",
            "nullable": true,
            "type": "string"
          },
          "id": {
            "example": "in_1Ok…",
            "nullable": true,
            "type": "string"
          },
          "invoice_pdf": {
            "description": "PDF de la factura. Es un enlace temporal que emite Stripe.",
            "example": "https://pay.stripe.com/invoice/…/pdf",
            "nullable": true,
            "type": "string"
          },
          "number": {
            "description": "Número visible de la factura.",
            "example": "B1C2D3-0007",
            "nullable": true,
            "type": "string"
          },
          "period_end": {
            "example": "2026-08-01T00:00:00.000Z",
            "nullable": true,
            "type": "string"
          },
          "period_start": {
            "example": "2026-07-01T00:00:00.000Z",
            "nullable": true,
            "type": "string"
          },
          "status": {
            "example": "paid",
            "nullable": true,
            "type": "string"
          }
        },
        "required": [
          "id",
          "number",
          "status",
          "amount_due",
          "amount_paid",
          "currency",
          "created",
          "period_start",
          "period_end",
          "invoice_pdf",
          "hosted_invoice_url",
          "description"
        ],
        "type": "object"
      },
      "ItemCodeResponseDto": {
        "properties": {
          "code": {
            "description": "El código ya normalizado: mayúsculas, `A-Z0-9_`, y sufijo `_MET` si es un Met.",
            "example": "VENTAS_MET",
            "type": "string"
          },
          "id": {
            "example": 9812,
            "type": "number"
          }
        },
        "required": [
          "id",
          "code"
        ],
        "type": "object"
      },
      "ItemCommentAuthorDto": {
        "properties": {
          "avatar_url": {
            "description": "Solo para autores humanos.",
            "nullable": true,
            "type": "string"
          },
          "emoji": {
            "description": "Solo para autores Met.",
            "example": "🤖",
            "nullable": true,
            "type": "string"
          },
          "id": {
            "description": "Ausente cuando `type` es `system`.",
            "example": 91,
            "type": "number"
          },
          "name": {
            "example": "Ada Lovelace",
            "type": "string"
          },
          "photo_url": {
            "description": "Solo para autores Met.",
            "nullable": true,
            "type": "string"
          },
          "type": {
            "enum": [
              "human",
              "met",
              "system"
            ],
            "example": "human",
            "type": "string"
          }
        },
        "required": [
          "type",
          "name"
        ],
        "type": "object"
      },
      "ItemCommentFileAttachmentDto": {
        "properties": {
          "mime_type": {
            "type": "string"
          },
          "original_name": {
            "type": "string"
          },
          "size": {
            "type": "number"
          },
          "storage_path": {
            "type": "string"
          },
          "type": {
            "enum": [
              "file"
            ],
            "type": "string"
          },
          "url": {
            "type": "string"
          }
        },
        "required": [
          "type",
          "url",
          "storage_path",
          "mime_type",
          "size",
          "original_name"
        ],
        "type": "object"
      },
      "ItemCommentMessageResponseDto": {
        "properties": {
          "message": {
            "description": "Texto fijo en inglés — es un acuse, no copy de producto.",
            "example": "Comment deleted",
            "type": "string"
          }
        },
        "required": [
          "message"
        ],
        "type": "object"
      },
      "ItemCommentResponseDto": {
        "properties": {
          "attachments": {
            "description": "Archivos y referencias a ítems adjuntos, discriminados por `type`\n(`file` | `item`). Las URL de archivo **se vuelven a firmar en cada lectura**:\nson temporales, no las guardes — guarda `storage_path`.",
            "items": {
              "additionalProperties": true,
              "type": "object"
            },
            "type": "array"
          },
          "author": {
            "$ref": "#/components/schemas/ItemCommentAuthorDto"
          },
          "body": {
            "description": "Puede ser `null` si el comentario es solo adjuntos.",
            "example": "Confirmado con el cliente.",
            "nullable": true,
            "type": "string"
          },
          "created_at": {
            "example": "2026-07-30T04:12:33.120Z",
            "type": "string"
          },
          "field": {
            "description": "Ancla de celda: el `name` de la columna comentada. `null` = el comentario es\ndel ítem entero. Los dos hilos no se mezclan: sin `?field=` solo vuelven los\nde nivel ítem.",
            "example": "monto_estimado",
            "nullable": true,
            "type": "string"
          },
          "id": {
            "example": 5521,
            "type": "number"
          },
          "item_id": {
            "example": 9812,
            "type": "number"
          },
          "updated_at": {
            "example": "2026-07-30T04:12:33.120Z",
            "nullable": true,
            "type": "string"
          }
        },
        "required": [
          "id",
          "item_id",
          "field",
          "body",
          "attachments",
          "author",
          "created_at",
          "updated_at"
        ],
        "type": "object"
      },
      "ItemCommentRowResponseDto": {
        "additionalProperties": true,
        "properties": {
          "attachments": {
            "description": "Tal como se guardó. A diferencia del listado, aquí **no** se re-firman las URL.",
            "items": {
              "additionalProperties": true,
              "type": "object"
            },
            "type": "array"
          },
          "author_met_id": {
            "nullable": true,
            "type": "number"
          },
          "author_type": {
            "enum": [
              "human",
              "met",
              "system"
            ],
            "example": "human",
            "type": "string"
          },
          "author_user_id": {
            "description": "Sin resolver: el listado es el que devuelve el objeto `author` completo.",
            "example": 91,
            "nullable": true,
            "type": "number"
          },
          "body": {
            "nullable": true,
            "type": "string"
          },
          "created_at": {
            "example": "2026-07-30T04:12:33.120Z",
            "nullable": true,
            "type": "string"
          },
          "field": {
            "example": "monto_estimado",
            "nullable": true,
            "type": "string"
          },
          "id": {
            "example": 5521,
            "type": "number"
          },
          "item_id": {
            "example": 9812,
            "type": "number"
          },
          "workspace_id": {
            "example": 134,
            "type": "number"
          }
        },
        "required": [
          "id",
          "item_id",
          "workspace_id",
          "author_type",
          "author_user_id",
          "author_met_id",
          "body",
          "field",
          "attachments"
        ],
        "type": "object"
      },
      "ItemContentResponseDto": {
        "properties": {
          "blocks": {
            "description": "Los bloques ya hidratados, en el orden en que se muestran. Máximo 500.",
            "items": {
              "$ref": "#/components/schemas/ContentBlockResponseDto"
            },
            "type": "array"
          },
          "item_id": {
            "example": 9812,
            "type": "number"
          }
        },
        "required": [
          "item_id",
          "blocks"
        ],
        "type": "object"
      },
      "ItemContentUploadResponseDto": {
        "properties": {
          "mime_type": {
            "example": "image/png",
            "type": "string"
          },
          "size": {
            "description": "Tamaño del archivo subido, en bytes.",
            "example": 148213,
            "type": "number"
          },
          "storage_path": {
            "description": "Ruta del objeto en Storage. No es una URL: el frontend pide la firma al pintar.",
            "example": "item-content/ws-134/items-9812/5f0a1e3c.png",
            "type": "string"
          }
        },
        "required": [
          "storage_path",
          "size",
          "mime_type"
        ],
        "type": "object"
      },
      "ItemFileDeletedResponseDto": {
        "properties": {
          "message": {
            "example": "File deleted",
            "type": "string"
          }
        },
        "required": [
          "message"
        ],
        "type": "object"
      },
      "ItemFileResponseDto": {
        "properties": {
          "asset_id": {
            "description": "Link al mismo archivo en la Mediateca del workspace. `null` en los adjuntos\nanteriores a la Mediateca.",
            "example": null,
            "nullable": true,
            "type": "string"
          },
          "created_at": {
            "example": "2026-07-30T04:44:51.233Z",
            "nullable": true,
            "type": "string"
          },
          "created_by": {
            "description": "Usuario que lo subió.",
            "example": 42,
            "nullable": true,
            "type": "number"
          },
          "filename": {
            "description": "Nombre saneado con el que se guardó en Storage (`{timestamp}-{nombre}`).\nNo es el nombre que ve el usuario: ese es `original_name`.",
            "example": "1753848291233-propuesta-comercial.pdf",
            "type": "string"
          },
          "id": {
            "example": 8123,
            "type": "number"
          },
          "item_id": {
            "description": "Item al que está adjunto.",
            "example": 41207,
            "type": "number"
          },
          "mime_type": {
            "example": "application/pdf",
            "nullable": true,
            "type": "string"
          },
          "original_name": {
            "description": "Nombre legible, tal como se subió. Es el que se muestra y el que se descarga.",
            "example": "Propuesta comercial (v2).pdf",
            "type": "string"
          },
          "size": {
            "description": "Tamaño en bytes.",
            "example": 184320,
            "nullable": true,
            "type": "number"
          },
          "storage_path": {
            "description": "**La fuente de verdad del archivo.** La ruta dentro del bucket privado; es lo\núnico estable. Guarda esto, no la URL: una URL firmada vence, y una URL\npública vieja puede haber dejado de resolver cuando el objeto se privatizó.",
            "example": "items/41207/1753848291233-propuesta-comercial.pdf",
            "type": "string"
          }
        },
        "required": [
          "id",
          "item_id",
          "filename",
          "original_name",
          "mime_type",
          "size",
          "storage_path",
          "created_by",
          "created_at",
          "asset_id"
        ],
        "type": "object"
      },
      "ItemFileUploadResponseDto": {
        "properties": {
          "asset_id": {
            "description": "Link al mismo archivo en la Mediateca del workspace. `null` en los adjuntos\nanteriores a la Mediateca.",
            "example": null,
            "nullable": true,
            "type": "string"
          },
          "created_at": {
            "example": "2026-07-30T04:44:51.233Z",
            "nullable": true,
            "type": "string"
          },
          "created_by": {
            "description": "Usuario que lo subió.",
            "example": 42,
            "nullable": true,
            "type": "number"
          },
          "download_url": {
            "description": "URL de descarga **firmada y temporal** (vence a los 7 días). No es una URL\npública y no sirve para guardar: el archivo vive en un bucket privado y esta\nfirma caduca. Para un enlace estable, usa\n`GET /item-files/{fileId}/download`, que valida la sesión en cada llamada, o\nvuelve a pedir el archivo para recibir una firma nueva.\n\n`null` si la firma falló; el archivo igual quedó guardado.",
            "example": "https://…supabase.co/storage/v1/object/sign/meteorus-privado/items/41207/…?token=…",
            "nullable": true,
            "type": "string"
          },
          "filename": {
            "description": "Nombre saneado con el que se guardó en Storage (`{timestamp}-{nombre}`).\nNo es el nombre que ve el usuario: ese es `original_name`.",
            "example": "1753848291233-propuesta-comercial.pdf",
            "type": "string"
          },
          "id": {
            "example": 8123,
            "type": "number"
          },
          "item_id": {
            "description": "Item al que está adjunto.",
            "example": 41207,
            "type": "number"
          },
          "mime_type": {
            "example": "application/pdf",
            "nullable": true,
            "type": "string"
          },
          "original_name": {
            "description": "Nombre legible, tal como se subió. Es el que se muestra y el que se descarga.",
            "example": "Propuesta comercial (v2).pdf",
            "type": "string"
          },
          "size": {
            "description": "Tamaño en bytes.",
            "example": 184320,
            "nullable": true,
            "type": "number"
          },
          "storage_path": {
            "description": "**La fuente de verdad del archivo.** La ruta dentro del bucket privado; es lo\núnico estable. Guarda esto, no la URL: una URL firmada vence, y una URL\npública vieja puede haber dejado de resolver cuando el objeto se privatizó.",
            "example": "items/41207/1753848291233-propuesta-comercial.pdf",
            "type": "string"
          }
        },
        "required": [
          "id",
          "item_id",
          "filename",
          "original_name",
          "mime_type",
          "size",
          "storage_path",
          "created_by",
          "created_at",
          "asset_id",
          "download_url"
        ],
        "type": "object"
      },
      "ItemImageUploadResponseDto": {
        "properties": {
          "path": {
            "description": "Ruta del objeto en Storage. Es la fuente de verdad; la URL se re-emite.",
            "example": "item-images/ws-134/item-9812/1753-foto.jpg",
            "type": "string"
          },
          "url": {
            "description": "URL para mostrar la imagen. Pide una miniatura si la vas a pintar chica.",
            "example": "https://…/item-images/ws-134/item-9812/1753.jpg",
            "type": "string"
          }
        },
        "required": [
          "url",
          "path"
        ],
        "type": "object"
      },
      "ItemImportErrorDto": {
        "properties": {
          "reason": {
            "example": "clave duplicada en el archivo",
            "type": "string"
          },
          "row": {
            "description": "Índice de la fila en el arreglo que mandaste, empezando en 0.",
            "example": 14,
            "type": "number"
          }
        },
        "required": [
          "row",
          "reason"
        ],
        "type": "object"
      },
      "ItemImportResultDto": {
        "properties": {
          "created": {
            "description": "Filas que se insertaron como ítems nuevos.",
            "example": 120,
            "type": "number"
          },
          "errors": {
            "items": {
              "$ref": "#/components/schemas/ItemImportErrorDto"
            },
            "type": "array"
          },
          "skipped": {
            "description": "Filas que matchearon pero no traían ningún cambio. Siempre 0 sin `keyField`.",
            "example": 3,
            "type": "number"
          },
          "updated": {
            "description": "Filas que matchearon por `keyField` y cambiaron algún valor. Siempre 0 sin `keyField`.",
            "example": 8,
            "type": "number"
          }
        },
        "required": [
          "created",
          "updated",
          "skipped",
          "errors"
        ],
        "type": "object"
      },
      "ItemLinkResponseDto": {
        "additionalProperties": true,
        "properties": {
          "created_at": {
            "example": "2026-07-30T04:12:33.120Z",
            "nullable": true,
            "type": "string"
          },
          "id": {
            "example": 4471,
            "type": "number"
          },
          "link_type": {
            "description": "Qué relación expresa el enlace. El catálogo lo fija quien lo crea.",
            "example": "uses_skill",
            "type": "string"
          },
          "source": {
            "additionalProperties": true,
            "description": "El ítem de origen, embebido. Su forma es la de un ítem (campos del usuario).",
            "nullable": true,
            "type": "object"
          },
          "source_item_id": {
            "example": 9812,
            "type": "number"
          },
          "target": {
            "additionalProperties": true,
            "description": "El ítem de destino, embebido.",
            "nullable": true,
            "type": "object"
          },
          "target_item_id": {
            "example": 9840,
            "type": "number"
          }
        },
        "required": [
          "id",
          "source_item_id",
          "target_item_id",
          "link_type"
        ],
        "type": "object"
      },
      "ItemMessageResponseDto": {
        "properties": {
          "message": {
            "description": "Texto fijo en inglés — es un acuse, no copy de producto.",
            "example": "Item deleted",
            "type": "string"
          }
        },
        "required": [
          "message"
        ],
        "type": "object"
      },
      "ItemOkResponseDto": {
        "properties": {
          "ok": {
            "enum": [
              true
            ],
            "example": true,
            "type": "number"
          }
        },
        "required": [
          "ok"
        ],
        "type": "object"
      },
      "ItemPaginationDto": {
        "properties": {
          "limit": {
            "example": 50,
            "type": "number"
          },
          "page": {
            "description": "Página devuelta, empezando en 1.",
            "example": 1,
            "type": "number"
          },
          "pages": {
            "description": "Cuántas páginas hay con este `limit`.",
            "example": 3,
            "type": "number"
          },
          "total": {
            "description": "Total de ítems que matchean, no de la página.",
            "example": 128,
            "type": "number"
          }
        },
        "required": [
          "page",
          "limit",
          "total",
          "pages"
        ],
        "type": "object"
      },
      "ItemResponseDto": {
        "additionalProperties": true,
        "properties": {
          "collection_id": {
            "example": 12,
            "nullable": true,
            "type": "object"
          },
          "computed": {
            "additionalProperties": {
              "type": "number"
            },
            "type": "object"
          },
          "created_at": {
            "nullable": true,
            "type": "object"
          },
          "data": {
            "additionalProperties": true,
            "type": "object"
          },
          "id": {
            "example": 9812,
            "type": "number"
          },
          "status": {
            "nullable": true,
            "type": "object"
          }
        },
        "required": [
          "id"
        ],
        "type": "object"
      },
      "ItemSearchResultDto": {
        "properties": {
          "collection_code": {
            "example": "inmuebles",
            "nullable": true,
            "type": "string"
          },
          "collection_emoji": {
            "description": "Siempre `null` hoy: `collections` no tiene columna `emoji`.",
            "nullable": true,
            "type": "string"
          },
          "collection_id": {
            "example": 12,
            "nullable": true,
            "type": "number"
          },
          "collection_name": {
            "example": "Inmuebles",
            "nullable": true,
            "type": "string"
          },
          "emoji": {
            "example": "🏠",
            "nullable": true,
            "type": "string"
          },
          "id": {
            "example": 9812,
            "type": "number"
          },
          "name": {
            "description": "Título mostrable, derivado de `data` con una cascada\n(`title`/`titulo`/`nombre`/`name`/`$name`). El buscador no conoce el esquema\nde cada colección, así que esto es heurística, no un campo de la tabla.",
            "example": "Casa en Chapinero",
            "nullable": true,
            "type": "string"
          }
        },
        "required": [
          "id",
          "name",
          "emoji",
          "collection_id",
          "collection_name",
          "collection_emoji",
          "collection_code"
        ],
        "type": "object"
      },
      "ItemStatusResponseDto": {
        "properties": {
          "collection_id": {
            "example": 12,
            "nullable": true,
            "type": "number"
          },
          "id": {
            "example": 9812,
            "type": "number"
          },
          "status": {
            "description": "`vacation` = el orquestador lo saltea.",
            "enum": [
              "active",
              "vacation"
            ],
            "example": "active",
            "type": "string"
          }
        },
        "required": [
          "id",
          "status",
          "collection_id"
        ],
        "type": "object"
      },
      "ItemThumbnailResponseDto": {
        "properties": {
          "url": {
            "example": "https://…/pages/ws-134/item-9812/1753.png",
            "type": "string"
          }
        },
        "required": [
          "url"
        ],
        "type": "object"
      },
      "ItemVisibilityResponseDto": {
        "properties": {
          "collection_id": {
            "example": 12,
            "nullable": true,
            "type": "number"
          },
          "id": {
            "example": 9812,
            "type": "number"
          },
          "visibility": {
            "enum": [
              "private",
              "listed",
              "public"
            ],
            "example": "listed",
            "type": "string"
          }
        },
        "required": [
          "id",
          "visibility",
          "collection_id"
        ],
        "type": "object"
      },
      "LinkAgentSkillResponseDto": {
        "properties": {
          "already": {
            "description": "`true` si el vínculo ya existía: la operación es idempotente.",
            "example": false,
            "type": "boolean"
          },
          "id": {
            "description": "ID del vínculo Met↔habilidad.",
            "example": 9012,
            "type": "number"
          },
          "mcp_handler": {
            "description": "Handler del MCP cuyas credenciales faltan. `null` si no falta ninguna.",
            "example": "google_calendar",
            "nullable": true,
            "type": "string"
          },
          "requires_credentials": {
            "example": true,
            "type": "boolean"
          },
          "skill_id": {
            "example": 88,
            "type": "number"
          },
          "status": {
            "enum": [
              "active",
              "pending_credentials",
              "inactive"
            ],
            "example": "pending_credentials",
            "type": "string"
          }
        },
        "required": [
          "id",
          "skill_id",
          "already",
          "status",
          "requires_credentials",
          "mcp_handler"
        ],
        "type": "object"
      },
      "LinkedItemDto": {
        "properties": {
          "code": {
            "example": "K7F2QA",
            "nullable": true,
            "type": "string"
          },
          "collection_id": {
            "example": 12,
            "type": "number"
          },
          "collection_name": {
            "example": "Inmuebles",
            "type": "string"
          },
          "data": {
            "additionalProperties": true,
            "description": "Los valores del ítem, con las claves del esquema de su colección.",
            "type": "object"
          },
          "field": {
            "description": "`field_key` del campo tipo `contact` que produjo el vínculo.",
            "example": "propietario",
            "type": "string"
          },
          "field_label": {
            "example": "Propietario",
            "type": "string"
          },
          "id": {
            "example": 9812,
            "type": "number"
          },
          "principal_image": {
            "nullable": true,
            "type": "string"
          },
          "title": {
            "description": "Título del ítem: el primer campo de su esquema.",
            "example": "Apto 501 · Chapinero",
            "type": "string"
          }
        },
        "required": [
          "id",
          "collection_id",
          "collection_name",
          "field",
          "field_label",
          "title",
          "principal_image",
          "code",
          "data"
        ],
        "type": "object"
      },
      "ManagedAutomationCapabilitiesDto": {
        "properties": {
          "can_restore": {
            "example": true,
            "type": "boolean"
          },
          "editable_fields": {
            "example": [
              "schedule",
              "flow"
            ],
            "items": {
              "type": "string"
            },
            "type": "array"
          },
          "locked_fields": {
            "example": [
              "handler",
              "tool_name",
              "templates",
              "recipients"
            ],
            "items": {
              "type": "string"
            },
            "type": "array"
          }
        },
        "required": [
          "editable_fields",
          "locked_fields",
          "can_restore"
        ],
        "type": "object"
      },
      "ManagedAutomationHistoryDto": {
        "properties": {
          "after_config": {
            "additionalProperties": true,
            "type": "object"
          },
          "before_config": {
            "additionalProperties": true,
            "type": "object"
          },
          "changed_by_user_id": {
            "example": "42",
            "nullable": true,
            "type": "string"
          },
          "created_at": {
            "example": "2026-08-14T17:00:02.000Z",
            "type": "string"
          },
          "id": {
            "example": "d4c3b2a1-0000-4000-8000-123456789abc",
            "type": "string"
          },
          "operation": {
            "enum": [
              "update",
              "restore"
            ],
            "example": "update",
            "type": "string"
          },
          "revision": {
            "example": 3,
            "type": "number"
          }
        },
        "required": [
          "id",
          "revision",
          "operation",
          "before_config",
          "after_config",
          "created_at"
        ],
        "type": "object"
      },
      "MarketplaceSkillDto": {
        "properties": {
          "code": {
            "example": "SK-3120",
            "type": "string"
          },
          "collection_id": {
            "description": "Colección `_skills` en la que vive.",
            "example": 91,
            "type": "number"
          },
          "created_at": {
            "example": "2026-07-12T10:00:00.000Z",
            "type": "string"
          },
          "data": {
            "additionalProperties": true,
            "description": "Configuración de la habilidad: nombre, descripción, prompt base y los MCP que\ntrae. Es un JSON de forma libre — cada habilidad declara lo suyo.",
            "type": "object"
          },
          "id": {
            "example": 3120,
            "type": "number"
          },
          "is_public": {
            "example": false,
            "type": "boolean"
          },
          "slug": {
            "example": "agenda",
            "nullable": true,
            "type": "string"
          },
          "source_template_id": {
            "description": "Plantilla global de la que se copió esta habilidad. `null` si es original.",
            "example": 2044,
            "nullable": true,
            "type": "number"
          },
          "status": {
            "example": "active",
            "type": "string"
          },
          "updated_at": {
            "example": "2026-07-30T04:12:33.120Z",
            "type": "string"
          },
          "visibility": {
            "description": "`private` | `listed` | `public`. Las plantillas del catálogo son `public`.",
            "example": "public",
            "type": "string"
          },
          "workspace_config": {
            "allOf": [
              {
                "$ref": "#/components/schemas/WorkspaceSkillConfigDto"
              }
            ],
            "nullable": true
          }
        },
        "required": [
          "id",
          "collection_id",
          "data",
          "code",
          "slug",
          "visibility",
          "source_template_id",
          "is_public",
          "status",
          "created_at",
          "updated_at"
        ],
        "type": "object"
      },
      "McpJsonRpcErrorDto": {
        "properties": {
          "code": {
            "description": "Código de error JSON-RPC (`-32601` método desconocido, `-32603` interno, …).",
            "example": -32603,
            "type": "number"
          },
          "data": {
            "additionalProperties": true,
            "description": "Detalle opcional del error. Su forma la define quien lo emite.",
            "type": "object"
          },
          "message": {
            "example": "Internal server error",
            "type": "string"
          }
        },
        "required": [
          "code",
          "message"
        ],
        "type": "object"
      },
      "McpJsonRpcResponseDto": {
        "properties": {
          "error": {
            "allOf": [
              {
                "$ref": "#/components/schemas/McpJsonRpcErrorDto"
              }
            ],
            "description": "Presente solo si el método falló. Nunca viene junto con `result`."
          },
          "id": {
            "description": "El mismo `id` que mandaste en la petición. Es `null` cuando el servidor no\npudo siquiera leerlo (petición malformada).",
            "example": 1,
            "nullable": true,
            "oneOf": [
              {
                "type": "string"
              },
              {
                "type": "number"
              }
            ]
          },
          "jsonrpc": {
            "enum": [
              "2.0"
            ],
            "example": "2.0",
            "type": "string"
          },
          "result": {
            "additionalProperties": true,
            "description": "Resultado del método invocado, presente solo si no hubo error. Su forma la\ndefine la especificación de MCP según el método: `initialize` devuelve las\ncapacidades del servidor, `tools/list` el catálogo de tools que alcanzan los\nscopes de tu key, `tools/call` el contenido que produjo la tool.",
            "type": "object"
          }
        },
        "required": [
          "jsonrpc",
          "id"
        ],
        "type": "object"
      },
      "MessageDeliveryDto": {
        "properties": {
          "error": {
            "description": "Por qué falló la entrega. Solo viene con `ok: false`.",
            "example": "Contacto sin teléfono",
            "nullable": true,
            "type": "string"
          },
          "ok": {
            "description": "`false` no revierte nada: el mensaje ya quedó guardado en la conversación.",
            "example": true,
            "type": "boolean"
          },
          "reason": {
            "nullable": true,
            "type": "string"
          },
          "skipped": {
            "description": "`true` cuando el canal no requiere entrega externa (ej. chat web).",
            "example": false,
            "type": "boolean"
          }
        },
        "required": [
          "ok"
        ],
        "type": "object"
      },
      "MoveFolderDto": {
        "properties": {
          "parent_folder_id": {
            "format": "uuid",
            "nullable": true,
            "type": "string"
          }
        },
        "type": "object"
      },
      "NodeDataOutputsDto": {
        "properties": {
          "fallback": {
            "allOf": [
              {
                "$ref": "#/components/schemas/NodeHandleDto"
              }
            ],
            "description": "Rama de reserva (\"Sin respuesta\" / \"Si no\")."
          },
          "field": {
            "example": "buttons",
            "type": "string"
          },
          "id_key": {
            "example": "id",
            "type": "string"
          },
          "label_key": {
            "example": "title",
            "type": "string"
          }
        },
        "required": [
          "field",
          "id_key",
          "label_key"
        ],
        "type": "object"
      },
      "NodeDynamicOutputsDto": {
        "properties": {
          "field": {
            "description": "Campo de `node.data` que lleva el contador.",
            "example": "num_outputs",
            "type": "string"
          },
          "handle_prefix": {
            "description": "Los handles quedan `<handle_prefix>-0` … `<handle_prefix>-(N-1)`.",
            "example": "img",
            "type": "string"
          },
          "items_key": {
            "description": "Clave del array dentro del `output_artifact` (ej. `images`).",
            "example": "images",
            "type": "string"
          },
          "label": {
            "example": "Imagen",
            "type": "string"
          },
          "max": {
            "example": 4,
            "type": "number"
          }
        },
        "required": [
          "field",
          "max",
          "handle_prefix",
          "label",
          "items_key"
        ],
        "type": "object"
      },
      "NodeFieldOptionDto": {
        "properties": {
          "label": {
            "example": "Nano Banana 2",
            "type": "string"
          },
          "value": {
            "example": "nano-banana-2",
            "type": "string"
          }
        },
        "required": [
          "value",
          "label"
        ],
        "type": "object"
      },
      "NodeFieldSpecDto": {
        "properties": {
          "default_value": {
            "description": "Valor inicial sugerido al crear el nodo.",
            "type": "object"
          },
          "description": {
            "type": "string"
          },
          "empty_label": {
            "description": "Texto de la opción vacía en los selects que la ofrecen.",
            "type": "string"
          },
          "label": {
            "example": "Instrucción",
            "type": "string"
          },
          "name": {
            "description": "Clave dentro de `node.data`.",
            "example": "prompt",
            "type": "string"
          },
          "only_for_cargo": {
            "description": "Si el campo solo aplica cuando la carga inicial es de cierto tipo.",
            "items": {
              "enum": [
                "contact",
                "item",
                "product",
                "post",
                "event",
                "empty"
              ],
              "type": "string"
            },
            "type": "array"
          },
          "options": {
            "description": "Solo cuando `type` es `select`.",
            "items": {
              "$ref": "#/components/schemas/NodeFieldOptionDto"
            },
            "type": "array"
          },
          "required": {
            "example": true,
            "type": "boolean"
          },
          "type": {
            "description": "Cómo se edita: `text`, `longtext`, `number`, `select`, `reference`,\n`image_ref`, `met_ref`, `collection_ref`, `contact_ref`, `color`, `json`,\n`string_list`.",
            "example": "longtext",
            "type": "string"
          }
        },
        "required": [
          "name",
          "label",
          "type"
        ],
        "type": "object"
      },
      "NodeHandleDto": {
        "properties": {
          "id": {
            "example": "out",
            "type": "string"
          },
          "label": {
            "example": "Salida",
            "type": "string"
          }
        },
        "required": [
          "id",
          "label"
        ],
        "type": "object"
      },
      "NodeInputHandleSpecDto": {
        "properties": {
          "binds_field": {
            "description": "Conectar aquí autoescribe `@{node:<origen>}` en este campo del destino.",
            "example": "reference_image",
            "type": "string"
          },
          "id": {
            "example": "image_in",
            "type": "string"
          },
          "kind": {
            "enum": [
              "control",
              "image",
              "text"
            ],
            "example": "image",
            "type": "string"
          },
          "label": {
            "example": "Imagen de referencia",
            "type": "string"
          },
          "multi": {
            "description": "Si acepta N conexiones entrantes (`binds_field` se mantiene como lista).",
            "example": false,
            "type": "boolean"
          }
        },
        "required": [
          "id",
          "kind",
          "label"
        ],
        "type": "object"
      },
      "NodeRegistryResponseDto": {
        "properties": {
          "image_providers": {
            "items": {
              "$ref": "#/components/schemas/ImageProviderDto"
            },
            "type": "array"
          },
          "nodes": {
            "items": {
              "$ref": "#/components/schemas/NodeTypeDefinitionDto"
            },
            "type": "array"
          },
          "video_providers": {
            "items": {
              "$ref": "#/components/schemas/VideoProviderDto"
            },
            "type": "array"
          }
        },
        "required": [
          "nodes",
          "image_providers",
          "video_providers"
        ],
        "type": "object"
      },
      "NodeTypeDefinitionDto": {
        "properties": {
          "accepts_cargo": {
            "description": "Tipos de carga inicial que consume. `empty` = funciona sin carga.",
            "items": {
              "enum": [
                "contact",
                "item",
                "product",
                "post",
                "event",
                "empty"
              ],
              "type": "string"
            },
            "type": "array"
          },
          "category": {
            "enum": [
              "control",
              "messaging",
              "intelligence",
              "data",
              "contact",
              "integration"
            ],
            "example": "intelligence",
            "type": "string"
          },
          "data_outputs": {
            "$ref": "#/components/schemas/NodeDataOutputsDto"
          },
          "default_tier": {
            "description": "Nivel de modelo por defecto, si el nodo consume IA.",
            "enum": [
              "agil",
              "inteligente",
              "genio"
            ],
            "type": "string"
          },
          "description": {
            "type": "string"
          },
          "dynamic_outputs": {
            "$ref": "#/components/schemas/NodeDynamicOutputsDto"
          },
          "fields": {
            "items": {
              "$ref": "#/components/schemas/NodeFieldSpecDto"
            },
            "type": "array"
          },
          "icon": {
            "description": "Emoji o slug de ícono.",
            "example": "🤖",
            "type": "string"
          },
          "input_handle_specs": {
            "items": {
              "$ref": "#/components/schemas/NodeInputHandleSpecDto"
            },
            "type": "array"
          },
          "input_handles": {
            "enum": [
              "single",
              "multiple"
            ],
            "example": "single",
            "type": "string"
          },
          "label": {
            "example": "Preguntar al Met",
            "type": "string"
          },
          "output_handles": {
            "description": "Handles de salida fijos. Si se omite, el nodo tiene uno solo (`out`).",
            "items": {
              "$ref": "#/components/schemas/NodeHandleDto"
            },
            "type": "array"
          },
          "supports_error_handling": {
            "description": "Si acepta la política `on_error` configurable (parar / seguir / ramificar).",
            "example": true,
            "type": "boolean"
          },
          "supports_response_mapping": {
            "description": "Si su respuesta se puede mapear a campos de contacto o variables.",
            "example": false,
            "type": "boolean"
          },
          "supports_test_run": {
            "description": "Si se puede correr solo, con un payload de muestra (`POST …/nodes/{nodeId}/test`).",
            "example": false,
            "type": "boolean"
          },
          "type": {
            "description": "Lo que va en `node.type`.",
            "example": "agent.ask",
            "type": "string"
          },
          "workspace_checks": {
            "items": {
              "$ref": "#/components/schemas/NodeWorkspaceCheckDto"
            },
            "type": "array"
          }
        },
        "required": [
          "type",
          "label",
          "category",
          "description",
          "icon",
          "accepts_cargo",
          "fields"
        ],
        "type": "object"
      },
      "NodeWorkspaceCheckDto": {
        "properties": {
          "kind": {
            "enum": [
              "channel",
              "template",
              "integration",
              "plan"
            ],
            "example": "channel",
            "type": "string"
          },
          "message": {
            "example": "Necesitas un canal de WhatsApp conectado.",
            "type": "string"
          },
          "ref": {
            "description": "Qué en concreto (ej. `whatsapp` para un canal).",
            "example": "whatsapp",
            "type": "string"
          },
          "resolution": {
            "description": "Sugerencia de cómo resolverlo.",
            "type": "string"
          }
        },
        "required": [
          "kind",
          "message"
        ],
        "type": "object"
      },
      "OkResultDto": {
        "properties": {
          "ok": {
            "example": true,
            "type": "boolean"
          }
        },
        "required": [
          "ok"
        ],
        "type": "object"
      },
      "PatchFieldDto": {
        "properties": {
          "field": {
            "type": "string"
          },
          "value": {
            "type": "object"
          }
        },
        "type": "object"
      },
      "PatchItemDto": {
        "properties": {
          "data": {
            "description": "Claves a fusionar sobre data (merge). NO reemplaza el objeto data completo.",
            "example": {
              "estado": "ganado",
              "monto": 1500
            },
            "type": "object"
          },
          "emoji": {
            "maxLength": 16,
            "nullable": true,
            "type": "string"
          },
          "slug": {
            "type": "string"
          },
          "visibility": {
            "enum": [
              "private",
              "visible",
              "listed"
            ],
            "type": "string"
          }
        },
        "type": "object"
      },
      "PauseAutopilotDto": {
        "properties": {
          "minutes": {
            "description": "Minutos de pausa del piloto automático. `0` = reactivar de inmediato\n(limpia la ventana). Máx 1 año (525600 min), espejo del set de duraciones\ndel menú de pausa manual en el chat.",
            "maximum": 525600,
            "minimum": 0,
            "type": "number"
          }
        },
        "required": [
          "minutes"
        ],
        "type": "object"
      },
      "PipelineStageDto": {
        "properties": {
          "amount": {
            "description": "Suma del campo de monto de esos contactos. 0 si ninguno lo tiene.",
            "example": 45000000,
            "type": "number"
          },
          "contacts": {
            "example": 12,
            "type": "number"
          },
          "stage": {
            "description": "Valor del campo de etapa. Los contactos sin etapa se agrupan en `__no_value__`.",
            "example": "Negociación",
            "type": "string"
          }
        },
        "required": [
          "stage",
          "contacts",
          "amount"
        ],
        "type": "object"
      },
      "PipelineSummaryResponseDto": {
        "properties": {
          "amount_field": {
            "example": "monto",
            "type": "string"
          },
          "stage_field": {
            "example": "etapa",
            "type": "string"
          },
          "stages": {
            "items": {
              "$ref": "#/components/schemas/PipelineStageDto"
            },
            "type": "array"
          }
        },
        "required": [
          "stage_field",
          "amount_field",
          "stages"
        ],
        "type": "object"
      },
      "PlanWithFeaturesDto": {
        "properties": {
          "allow_custom": {
            "description": "`true` si admite condiciones negociadas por fuera del precio de lista.",
            "example": false,
            "type": "boolean"
          },
          "allowed_models": {
            "description": "Modelos habilitados por el plan, con su nombre de marca.",
            "example": [
              "Ágil",
              "Brillante"
            ],
            "items": {
              "type": "string"
            },
            "type": "array"
          },
          "automation_daily_quota": {
            "description": "Ejecuciones de automatización incluidas por día (UTC). Ausente = sin techo.",
            "example": 2000,
            "nullable": true,
            "type": "number"
          },
          "automation_monthly_quota": {
            "description": "Obsoleta: el límite pasó a ser diario. Se conserva vacía por compatibilidad.",
            "example": null,
            "nullable": true,
            "type": "number"
          },
          "automation_rate_limit_rpm": {
            "description": "Declarada pero sin efecto: ningún camino la aplica hoy.",
            "example": null,
            "nullable": true,
            "type": "number"
          },
          "call_minutes_monthly_quota": {
            "description": "Techo de minutos/mes de llamada atendida por el Met. `null` = ilimitado.",
            "example": 500,
            "nullable": true,
            "type": "number"
          },
          "call_outbound_daily_quota": {
            "description": "Techo de llamadas salientes al día. `null` = ilimitado.",
            "example": 100,
            "nullable": true,
            "type": "number"
          },
          "call_recording_days": {
            "description": "Días que se conserva el audio de la llamada. Máximo 90.",
            "example": 30,
            "nullable": true,
            "type": "number"
          },
          "created_at": {
            "example": "2026-01-12T10:00:00.000Z",
            "type": "string"
          },
          "description": {
            "example": "Para equipos que ya venden todos los días.",
            "nullable": true,
            "type": "string"
          },
          "display_order": {
            "description": "Orden en el que se muestra en la página de precios, ascendente.",
            "example": 2,
            "type": "number"
          },
          "feature_keys": {
            "description": "Claves de las funcionalidades incluidas en el plan.",
            "example": [
              "crm",
              "flows",
              "broadcasts"
            ],
            "items": {
              "type": "string"
            },
            "type": "array"
          },
          "icon_url": {
            "nullable": true,
            "type": "string"
          },
          "id": {
            "example": 3,
            "type": "number"
          },
          "initial_bonus_usd": {
            "description": "Energía de regalo que se acredita al activar el plan, en USD.",
            "example": 20,
            "type": "number"
          },
          "max_contacts": {
            "description": "Techo de contactos en el CRM.",
            "example": 10000,
            "type": "number"
          },
          "max_members": {
            "description": "Techo de miembros del equipo.",
            "example": 10,
            "type": "number"
          },
          "max_mets": {
            "description": "Techo de Mets configurables.",
            "example": 5,
            "type": "number"
          },
          "name": {
            "example": "Crecimiento",
            "type": "string"
          },
          "price_monthly_usd": {
            "example": 99,
            "type": "number"
          },
          "price_yearly_usd": {
            "example": 990,
            "type": "number"
          },
          "sdk_only": {
            "description": "`true` en el plan para desarrolladores, que no aparece en el pricing normal.",
            "example": false,
            "type": "boolean"
          },
          "slug": {
            "description": "Identificador estable del plan. Es el que conviene guardar, no el `id`.",
            "example": "crecimiento",
            "type": "string"
          },
          "status": {
            "description": "Solo los `active` aparecen en el listado público de planes.",
            "enum": [
              "active",
              "inactive",
              "hidden"
            ],
            "example": "active",
            "type": "string"
          },
          "stripe_price_id_monthly": {
            "description": "Precio de Stripe que usa el checkout mensual.",
            "example": "price_1Ok…",
            "nullable": true,
            "type": "string"
          },
          "stripe_price_id_yearly": {
            "description": "Precio de Stripe que usa el checkout anual.",
            "example": "price_1Ol…",
            "nullable": true,
            "type": "string"
          },
          "support_tier": {
            "description": "Nivel de soporte incluido, que define el SLA.",
            "enum": [
              "community",
              "basic",
              "custom",
              "priority"
            ],
            "example": "basic",
            "nullable": true,
            "type": "string"
          },
          "updated_at": {
            "example": "2026-06-30T18:41:02.000Z",
            "type": "string"
          }
        },
        "required": [
          "id",
          "slug",
          "name",
          "description",
          "icon_url",
          "status",
          "price_monthly_usd",
          "price_yearly_usd",
          "max_members",
          "max_contacts",
          "max_mets",
          "allowed_models",
          "initial_bonus_usd",
          "stripe_price_id_monthly",
          "stripe_price_id_yearly",
          "display_order",
          "allow_custom",
          "support_tier",
          "created_at",
          "updated_at",
          "feature_keys"
        ],
        "type": "object"
      },
      "PreviewCountDto": {
        "properties": {
          "filters": {
            "items": {
              "$ref": "#/components/schemas/SegmentConditionDto"
            },
            "maxItems": 50,
            "type": "array"
          }
        },
        "type": "object"
      },
      "ProvisionWorkspaceDto": {
        "properties": {
          "business_name": {
            "description": "Nombre del negocio; da nombre al workspace.",
            "example": "Inmobiliaria Andes",
            "maxLength": 120,
            "minLength": 2,
            "type": "string"
          },
          "country": {
            "description": "ISO 3166-1 alpha-2. Define la zona horaria del workspace.",
            "example": "CO",
            "pattern": "/^[A-Za-z]{2}$/",
            "type": "string"
          },
          "owner_email": {
            "description": "Correo del dueño de la cuenta.",
            "example": "ana@andes.co",
            "format": "email",
            "type": "string"
          },
          "owner_name": {
            "example": "Ana Gómez",
            "maxLength": 120,
            "minLength": 2,
            "type": "string"
          },
          "owner_phone": {
            "description": "Con indicativo de país.",
            "example": "+573001234567",
            "pattern": "/^\\+\\d{7,15}$/",
            "type": "string"
          }
        },
        "required": [
          "business_name",
          "owner_email",
          "owner_name",
          "owner_phone"
        ],
        "type": "object"
      },
      "RechargeWorkspaceDto": {
        "properties": {
          "amount_usd": {
            "description": "Monto en USD a acreditar en la cuenta.",
            "example": 50,
            "minimum": 5,
            "type": "number"
          },
          "off_session": {
            "default": false,
            "description": "Con `true` cobra a tu medio de pago guardado y no devuelve enlace. Requiere tener uno; si no, responde 409.",
            "type": "boolean"
          }
        },
        "required": [
          "amount_usd"
        ],
        "type": "object"
      },
      "RegisterIntegrationDto": {
        "properties": {
          "auth_header": {
            "maxLength": 2000,
            "type": "string"
          },
          "credentials": {
            "type": "object"
          },
          "endpoint": {
            "format": "uri",
            "type": "string"
          },
          "name": {
            "maxLength": 120,
            "type": "string"
          }
        },
        "required": [
          "name",
          "endpoint"
        ],
        "type": "object"
      },
      "ReminderCancelResponseDto": {
        "properties": {
          "cancelled": {
            "example": true,
            "type": "boolean"
          }
        },
        "required": [
          "cancelled"
        ],
        "type": "object"
      },
      "ReminderResponseDto": {
        "properties": {
          "channel_id": {
            "description": "Canal con el que se guardó el recordatorio. **No decide por dónde sale**: al\nenviar, el canal se resuelve desde el contacto. Es informativo.",
            "example": 17,
            "nullable": true,
            "type": "number"
          },
          "contact_id": {
            "description": "A quién se le va a escribir. Es el `id` del contacto del CRM.",
            "example": 4821,
            "type": "number"
          },
          "created_at": {
            "example": "2026-07-30T04:12:33.120Z",
            "type": "string"
          },
          "created_by": {
            "description": "Quién lo agendó: una persona desde el panel, o un Met.",
            "enum": [
              "agent",
              "user"
            ],
            "example": "user",
            "type": "string"
          },
          "created_by_agent_id": {
            "nullable": true,
            "type": "number"
          },
          "created_by_user_id": {
            "example": 41,
            "nullable": true,
            "type": "number"
          },
          "error": {
            "description": "Motivo del fallo cuando `status` es `failed`; `null` en cualquier otro caso.",
            "nullable": true,
            "type": "string"
          },
          "id": {
            "example": 3312,
            "type": "number"
          },
          "language": {
            "example": "es",
            "type": "string"
          },
          "message": {
            "description": "El texto que va a leer el contacto. En el camino por defecto se inyecta como la\nvariable `1` de la plantilla.",
            "example": "Te esperamos mañana a las 10:00.",
            "nullable": true,
            "type": "string"
          },
          "namespace": {
            "nullable": true,
            "type": "string"
          },
          "note": {
            "description": "Nota para el equipo. Es el **único** campo que no viaja al contacto.",
            "example": "Confirmó por teléfono el lunes.",
            "nullable": true,
            "type": "string"
          },
          "scheduled_for": {
            "description": "Cuándo se envía, en UTC. Un valor sin offset se interpretó en la zona del workspace.",
            "example": "2026-08-01T13:00:00.000Z",
            "type": "string"
          },
          "sent_at": {
            "description": "Cuándo salió de verdad. `null` mientras siga pendiente.",
            "nullable": true,
            "type": "string"
          },
          "sent_message_id": {
            "description": "El mensaje que se creó en la conversación del contacto al enviarlo.",
            "example": 90312,
            "nullable": true,
            "type": "number"
          },
          "status": {
            "description": "`pending` = agendado y todavía va a salir. `sent` = ya se le escribió al\ncontacto. `cancelled` = se canceló antes de la hora. `failed` = la hora llegó y\nla entrega falló; el motivo está en `error`.",
            "enum": [
              "pending",
              "sent",
              "cancelled",
              "failed"
            ],
            "example": "pending",
            "type": "string"
          },
          "template_name": {
            "description": "Plantilla de WhatsApp aprobada con la que se envía. Queda congelada al crear.",
            "example": "recordatorio_cita",
            "type": "string"
          },
          "updated_at": {
            "type": "string"
          },
          "variables": {
            "additionalProperties": {
              "type": "string"
            },
            "description": "Variables de la plantilla, por posición (`{\"1\": \"...\"}`).",
            "type": "object"
          },
          "workspace_id": {
            "example": 3,
            "type": "number"
          }
        },
        "required": [
          "id",
          "workspace_id",
          "contact_id",
          "channel_id",
          "scheduled_for",
          "status",
          "message",
          "template_name",
          "language",
          "namespace",
          "variables",
          "note",
          "created_by",
          "created_by_agent_id",
          "created_by_user_id",
          "sent_at",
          "sent_message_id",
          "error",
          "created_at",
          "updated_at"
        ],
        "type": "object"
      },
      "RemoveWorkspaceSkillResponseDto": {
        "properties": {
          "ok": {
            "enum": [
              true
            ],
            "example": true,
            "type": "number"
          },
          "unlinked_mets_count": {
            "description": "Cuántos Mets quedaron sin ella al borrarla.",
            "example": 3,
            "type": "number"
          }
        },
        "required": [
          "ok",
          "unlinked_mets_count"
        ],
        "type": "object"
      },
      "ReorderContentDto": {
        "properties": {
          "order": {
            "items": {
              "format": "uuid",
              "type": "string"
            },
            "maxItems": 500,
            "type": "array"
          }
        },
        "required": [
          "order"
        ],
        "type": "object"
      },
      "ReorderTaskViewItemDto": {
        "properties": {
          "id": {
            "type": "number"
          },
          "position": {
            "type": "number"
          }
        },
        "required": [
          "id",
          "position"
        ],
        "type": "object"
      },
      "ReorderTaskViewsDto": {
        "properties": {
          "items": {
            "items": {
              "$ref": "#/components/schemas/ReorderTaskViewItemDto"
            },
            "type": "array"
          }
        },
        "required": [
          "items"
        ],
        "type": "object"
      },
      "ReorderViewItemDto": {
        "properties": {
          "id": {
            "type": "number"
          },
          "position": {
            "type": "number"
          }
        },
        "required": [
          "id",
          "position"
        ],
        "type": "object"
      },
      "ReorderViewsDto": {
        "properties": {
          "items": {
            "items": {
              "$ref": "#/components/schemas/ReorderViewItemDto"
            },
            "type": "array"
          }
        },
        "required": [
          "items"
        ],
        "type": "object"
      },
      "ReplaceContentDto": {
        "properties": {
          "blocks": {
            "items": {
              "type": "object"
            },
            "maxItems": 500,
            "type": "array"
          }
        },
        "required": [
          "blocks"
        ],
        "type": "object"
      },
      "ResolveVariablesDto": {
        "properties": {
          "contact_id": {
            "description": "ID del contacto para resolver las variables $contact.*",
            "type": "number"
          },
          "template": {
            "example": "Hola $contact.name, bienvenido a $workspace.brand_name",
            "type": "string"
          }
        },
        "required": [
          "template"
        ],
        "type": "object"
      },
      "ResolveVariablesResponseDto": {
        "properties": {
          "resolved": {
            "description": "La plantilla resuelta. Un token que no existe se deja **tal cual** en el\ntexto: no se borra ni se reemplaza por vacío.",
            "example": "Te atendemos Lunes a viernes, 8am a 6pm.",
            "type": "string"
          }
        },
        "required": [
          "resolved"
        ],
        "type": "object"
      },
      "ResolvedCodeCollectionDto": {
        "properties": {
          "code": {
            "description": "Código corto de la colección, único dentro del workspace.",
            "example": "PROPS",
            "type": "string"
          },
          "id": {
            "example": 118,
            "type": "number"
          },
          "is_global": {
            "description": "`true` en las colecciones de plataforma, visibles desde cualquier workspace.",
            "example": false,
            "type": "boolean"
          },
          "name": {
            "example": "Propiedades",
            "type": "string"
          },
          "slug": {
            "description": "El slug con el que se resolvió.",
            "example": "propiedades",
            "nullable": true,
            "type": "string"
          },
          "type": {
            "description": "Discriminador: qué tipo de recurso resolvió el código.",
            "enum": [
              "collection"
            ],
            "example": "collection",
            "type": "string"
          },
          "visibility": {
            "example": "private",
            "type": "string"
          },
          "workspace_id": {
            "example": 134,
            "type": "number"
          }
        },
        "required": [
          "id",
          "workspace_id",
          "name",
          "slug",
          "code",
          "type"
        ],
        "type": "object"
      },
      "ResolvedCodeItemDto": {
        "properties": {
          "code": {
            "example": "K7M2QX",
            "type": "string"
          },
          "collection_id": {
            "example": 118,
            "type": "number"
          },
          "id": {
            "example": 41207,
            "type": "number"
          },
          "slug": {
            "example": "apartamento-chico-norte",
            "nullable": true,
            "type": "string"
          },
          "type": {
            "description": "Discriminador: qué tipo de recurso resolvió el código.",
            "enum": [
              "item"
            ],
            "example": "item",
            "type": "string"
          }
        },
        "required": [
          "type",
          "id",
          "code",
          "slug",
          "collection_id"
        ],
        "type": "object"
      },
      "ResolvedCollectionDto": {
        "properties": {
          "code": {
            "description": "Código corto de la colección, único dentro del workspace.",
            "example": "PROPS",
            "type": "string"
          },
          "id": {
            "example": 118,
            "type": "number"
          },
          "is_global": {
            "description": "`true` en las colecciones de plataforma, visibles desde cualquier workspace.",
            "example": false,
            "type": "boolean"
          },
          "name": {
            "example": "Propiedades",
            "type": "string"
          },
          "slug": {
            "description": "El slug con el que se resolvió.",
            "example": "propiedades",
            "nullable": true,
            "type": "string"
          },
          "visibility": {
            "example": "private",
            "type": "string"
          },
          "workspace_id": {
            "example": 134,
            "type": "number"
          }
        },
        "required": [
          "id",
          "workspace_id",
          "name",
          "slug",
          "code"
        ],
        "type": "object"
      },
      "ResolvedFolderDto": {
        "properties": {
          "created_at": {
            "example": "2026-05-11T09:02:41.000Z",
            "type": "string"
          },
          "created_by": {
            "example": 42,
            "nullable": true,
            "type": "number"
          },
          "description": {
            "example": null,
            "nullable": true,
            "type": "string"
          },
          "id": {
            "example": "7d9c1e35-2b48-4a90-b3f1-6c5e2d8a147b",
            "type": "string"
          },
          "name": {
            "example": "Inmuebles",
            "type": "string"
          },
          "parent_folder_id": {
            "description": "Carpeta padre. `null` = es una carpeta raíz.",
            "example": null,
            "nullable": true,
            "type": "string"
          },
          "position": {
            "description": "Orden entre hermanas, ascendente.",
            "example": 0,
            "type": "number"
          },
          "updated_at": {
            "example": "2026-05-11T09:02:41.000Z",
            "type": "string"
          },
          "visibility": {
            "enum": [
              "private",
              "visible",
              "listed"
            ],
            "example": "private",
            "type": "string"
          },
          "workspace_id": {
            "example": 134,
            "type": "number"
          }
        },
        "required": [
          "id",
          "workspace_id",
          "name",
          "description",
          "parent_folder_id",
          "position",
          "visibility",
          "created_by",
          "created_at",
          "updated_at"
        ],
        "type": "object"
      },
      "ResolvedItemDto": {
        "properties": {
          "code": {
            "description": "Código corto del item, único dentro de su colección.",
            "example": "K7M2QX",
            "type": "string"
          },
          "collection_id": {
            "description": "Colección a la que pertenece.",
            "example": 118,
            "type": "number"
          },
          "data": {
            "additionalProperties": true,
            "description": "Los datos del item. Las claves son los campos que definió su colección, así\nque la forma cambia de una colección a otra.",
            "type": "object"
          },
          "id": {
            "example": 41207,
            "type": "number"
          },
          "slug": {
            "example": "apartamento-chico-norte",
            "nullable": true,
            "type": "string"
          },
          "visibility": {
            "example": "private",
            "type": "string"
          }
        },
        "required": [
          "id",
          "collection_id",
          "code",
          "slug"
        ],
        "type": "object"
      },
      "ResolvedPathDto": {
        "properties": {
          "collection": {
            "$ref": "#/components/schemas/ResolvedCollectionDto"
          },
          "item": {
            "$ref": "#/components/schemas/ResolvedItemDto"
          }
        },
        "required": [
          "collection",
          "item"
        ],
        "type": "object"
      },
      "RestoreManagedAutomationConfigDto": {
        "properties": {
          "expected_revision": {
            "description": "Versión recibida al abrir el editor.",
            "example": 2,
            "type": "number"
          }
        },
        "required": [
          "expected_revision"
        ],
        "type": "object"
      },
      "RunEnergyByModelDto": {
        "properties": {
          "cost_usd": {
            "description": "Energía consumida por este modelo, en USD.",
            "example": 0.0123,
            "type": "number"
          },
          "count": {
            "description": "Cuántas ejecuciones de este modelo entraron en el run.",
            "example": 2,
            "type": "number"
          },
          "model": {
            "description": "Nombre de marca del modelo (`Ágil`, `Brillante`, `Genio`), no el id técnico.",
            "example": "Brillante",
            "type": "string"
          }
        },
        "required": [
          "model",
          "cost_usd",
          "count"
        ],
        "type": "object"
      },
      "RunEnergyDto": {
        "properties": {
          "by_model": {
            "items": {
              "$ref": "#/components/schemas/RunEnergyByModelDto"
            },
            "type": "array"
          },
          "cost_usd": {
            "description": "Total debitado por el run, en USD.",
            "example": 0.0184,
            "type": "number"
          },
          "executions": {
            "description": "Cuántas ejecuciones de modelo hubo en total.",
            "example": 3,
            "type": "number"
          }
        },
        "required": [
          "cost_usd",
          "executions",
          "by_model"
        ],
        "type": "object"
      },
      "RunEventDto": {
        "properties": {
          "data": {
            "additionalProperties": true,
            "description": "Contenido del paso. La forma depende del `type`, y el texto libre va topeado\npara no volcar payloads enteros en la respuesta.",
            "nullable": true,
            "type": "object"
          },
          "type": {
            "description": "Qué pasó en este paso del run.",
            "example": "tool_call",
            "type": "object"
          }
        },
        "required": [
          "type",
          "data"
        ],
        "type": "object"
      },
      "RunListResponseDto": {
        "properties": {
          "data": {
            "items": {
              "$ref": "#/components/schemas/RunResponseDto"
            },
            "type": "array"
          },
          "has_more": {
            "description": "`true` si hay más resultados; pedí la página siguiente con `starting_after`.",
            "example": false,
            "type": "boolean"
          }
        },
        "required": [
          "data",
          "has_more"
        ],
        "type": "object"
      },
      "RunResponseDto": {
        "properties": {
          "completed_at": {
            "description": "Cuándo llegó a un estado terminal. `null` si sigue en curso.",
            "nullable": true,
            "type": "string"
          },
          "conversation_id": {
            "description": "Conversación en la que quedó el run, para darle continuidad al hilo.",
            "example": 1842,
            "nullable": true,
            "type": "number"
          },
          "created_at": {
            "example": "2026-07-30T04:12:33.120Z",
            "type": "string"
          },
          "energy": {
            "allOf": [
              {
                "$ref": "#/components/schemas/RunEnergyDto"
              }
            ],
            "description": "Solo en el detalle de un run, no en el listado."
          },
          "error": {
            "description": "Mensaje del fallo cuando `status` es `failed`; `null` en cualquier otro caso.",
            "nullable": true,
            "type": "string"
          },
          "events": {
            "description": "Los pasos del run. Vienen en el detalle (`GET /runs/{id}`) y al crearlo; **no** en\nel listado, que sería una respuesta enorme para nada.",
            "items": {
              "$ref": "#/components/schemas/RunEventDto"
            },
            "type": "array"
          },
          "id": {
            "description": "ID del run, con prefijo `run_`.",
            "example": "run_01HXYZ",
            "type": "string"
          },
          "input": {
            "description": "La instrucción que mandaste.",
            "type": "string"
          },
          "livemode": {
            "description": "`false` si el run lo disparó una key de test (`met_test_`): no debita Energía.",
            "example": true,
            "type": "boolean"
          },
          "met": {
            "description": "Qué Met atendió el run. `null` si el orquestador no lo resolvió a uno concreto.",
            "example": "ventas",
            "nullable": true,
            "type": "string"
          },
          "metadata": {
            "additionalProperties": true,
            "description": "Lo que mandaste en `metadata` al crear el run, tal cual.",
            "type": "object"
          },
          "object": {
            "description": "Siempre `run`. Sirve para distinguir el tipo de objeto en respuestas mezcladas.",
            "enum": [
              "run"
            ],
            "example": "run",
            "type": "string"
          },
          "output": {
            "description": "La salida del Met. `null` mientras el run no terminó, y si falló.",
            "nullable": true,
            "type": "string"
          },
          "status": {
            "enum": [
              "queued",
              "running",
              "completed",
              "failed"
            ],
            "example": "completed",
            "type": "string"
          }
        },
        "required": [
          "id",
          "object",
          "status",
          "met",
          "input",
          "output",
          "error",
          "conversation_id",
          "livemode",
          "metadata",
          "created_at",
          "completed_at"
        ],
        "type": "object"
      },
      "RunSystemAutomationDto": {
        "properties": {
          "input": {
            "additionalProperties": true,
            "type": "object"
          }
        },
        "type": "object"
      },
      "SegmentConditionDto": {
        "properties": {
          "field": {
            "description": "Clave en items.data: '$status', '$city', '$tags', o un campo custom.",
            "maxLength": 120,
            "type": "string"
          },
          "operator": {
            "enum": [
              "equals",
              "not_equals",
              "contains",
              "starts_with",
              "gt",
              "lt",
              "is_true",
              "is_false",
              "is_set",
              "is_not_set",
              "is_any_of",
              "has_tag",
              "between"
            ],
            "type": "string"
          },
          "value": {
            "description": "Valor a comparar. Array para `is_any_of`; `[desde, hasta]` para `between`\n(un extremo vacío = rango abierto por ese lado). Opcional para is_set/etc.",
            "type": "object"
          }
        },
        "required": [
          "field",
          "operator"
        ],
        "type": "object"
      },
      "SendContactMessageDto": {
        "properties": {
          "attachments": {
            "items": {
              "$ref": "#/components/schemas/ContactMessageAttachmentDto"
            },
            "type": "array"
          },
          "content": {
            "description": "Puede venir vacío cuando el mensaje es solo adjuntos (ej. nota de voz sin\ntexto) — el \"ni texto ni adjuntos\" lo rechaza el servicio, no el DTO.",
            "maxLength": 10000,
            "type": "string"
          }
        },
        "required": [
          "content"
        ],
        "type": "object"
      },
      "SendMessageResponseDto": {
        "properties": {
          "delivery": {
            "$ref": "#/components/schemas/MessageDeliveryDto"
          },
          "message": {
            "$ref": "#/components/schemas/ContactMessageDto"
          },
          "paused_until": {
            "description": "Hasta cuándo queda pausado el piloto automático por esta intervención humana.\n`null` si el workspace tiene la pausa en 0 o si no se pudo aplicar.",
            "example": "2026-07-30T04:42:33.120Z",
            "nullable": true,
            "type": "string"
          }
        },
        "required": [
          "message",
          "delivery",
          "paused_until"
        ],
        "type": "object"
      },
      "SendTemplateDto": {
        "properties": {
          "language": {
            "maxLength": 20,
            "type": "string"
          },
          "metadata": {
            "type": "object"
          },
          "name": {
            "maxLength": 512,
            "type": "string"
          },
          "namespace": {
            "maxLength": 512,
            "type": "string"
          },
          "params": {
            "type": "object"
          },
          "rendered_text": {
            "maxLength": 10000,
            "type": "string"
          }
        },
        "required": [
          "name",
          "language",
          "namespace"
        ],
        "type": "object"
      },
      "SendTemplateResponseDto": {
        "properties": {
          "delivery": {
            "$ref": "#/components/schemas/TemplateDeliveryDto"
          },
          "message": {
            "$ref": "#/components/schemas/ContactMessageDto"
          }
        },
        "required": [
          "message",
          "delivery"
        ],
        "type": "object"
      },
      "SendWhatsappButtonsDto": {
        "properties": {
          "body_text": {
            "maxLength": 1024,
            "minLength": 1,
            "type": "string"
          },
          "buttons": {
            "items": {
              "$ref": "#/components/schemas/InteractiveButtonDto"
            },
            "maxItems": 3,
            "minItems": 1,
            "type": "array"
          },
          "contact_id": {
            "type": "number"
          },
          "footer_text": {
            "maxLength": 60,
            "type": "string"
          },
          "header_text": {
            "maxLength": 60,
            "type": "string"
          }
        },
        "required": [
          "contact_id",
          "body_text",
          "buttons"
        ],
        "type": "object"
      },
      "SendWhatsappContactDto": {
        "properties": {
          "contact_id": {
            "description": "ID del contacto destinatario del mensaje.",
            "example": 12345,
            "type": "number"
          },
          "email": {
            "description": "Email del contacto compartido.",
            "example": "cristhian@tincorp.co",
            "maxLength": 200,
            "type": "string"
          },
          "full_name": {
            "description": "Nombre completo del contacto compartido (vCard).",
            "example": "Cristhian Martínez",
            "maxLength": 200,
            "minLength": 1,
            "type": "string"
          },
          "organization": {
            "description": "Organización del contacto compartido.",
            "example": "Tincorp",
            "maxLength": 200,
            "type": "string"
          },
          "phone": {
            "description": "Teléfono del contacto compartido (E.164 recomendado).",
            "example": "+573001112233",
            "maxLength": 50,
            "minLength": 1,
            "type": "string"
          }
        },
        "required": [
          "contact_id",
          "full_name",
          "phone"
        ],
        "type": "object"
      },
      "SendWhatsappListDto": {
        "properties": {
          "body_text": {
            "maxLength": 1024,
            "minLength": 1,
            "type": "string"
          },
          "button_text": {
            "maxLength": 20,
            "minLength": 1,
            "type": "string"
          },
          "contact_id": {
            "type": "number"
          },
          "footer_text": {
            "maxLength": 60,
            "type": "string"
          },
          "header_text": {
            "maxLength": 60,
            "type": "string"
          },
          "sections": {
            "items": {
              "$ref": "#/components/schemas/InteractiveListSectionDto"
            },
            "maxItems": 10,
            "minItems": 1,
            "type": "array"
          }
        },
        "required": [
          "contact_id",
          "body_text",
          "button_text",
          "sections"
        ],
        "type": "object"
      },
      "SendWhatsappLocationDto": {
        "properties": {
          "address": {
            "description": "Dirección legible.",
            "example": "Cra 7 #71-21, Bogotá",
            "maxLength": 1000,
            "type": "string"
          },
          "contact_id": {
            "description": "ID del contacto destinatario.",
            "example": 12345,
            "type": "number"
          },
          "latitude": {
            "description": "Latitud (-90 a 90).",
            "example": 4.711,
            "maximum": 90,
            "minimum": -90,
            "type": "number"
          },
          "longitude": {
            "description": "Longitud (-180 a 180).",
            "example": -74.0721,
            "maximum": 180,
            "minimum": -180,
            "type": "number"
          },
          "name": {
            "description": "Nombre del lugar.",
            "example": "Oficina Meteor",
            "maxLength": 1000,
            "type": "string"
          }
        },
        "required": [
          "contact_id",
          "latitude",
          "longitude"
        ],
        "type": "object"
      },
      "SendWhatsappReactionDto": {
        "properties": {
          "contact_id": {
            "description": "ID del contacto (item de la colección _contacts) destinatario.",
            "example": 12345,
            "type": "number"
          },
          "emoji": {
            "description": "Emoji, o '' para quitar la reacción previa. Hasta 16 chars (emojis combinados).",
            "example": "👍",
            "maxLength": 16,
            "type": "string"
          },
          "wa_message_id": {
            "description": "wa_message_id del mensaje a reaccionar.",
            "example": "wamid.HBgLNTQ5…",
            "maxLength": 256,
            "minLength": 1,
            "type": "string"
          }
        },
        "required": [
          "contact_id",
          "wa_message_id",
          "emoji"
        ],
        "type": "object"
      },
      "SendWhatsappReplyDto": {
        "properties": {
          "body": {
            "description": "Texto de la respuesta.",
            "example": "Gracias por tu mensaje, ya lo revisamos.",
            "maxLength": 4096,
            "minLength": 1,
            "type": "string"
          },
          "contact_id": {
            "description": "ID del contacto destinatario.",
            "example": 12345,
            "type": "number"
          },
          "wa_message_id": {
            "description": "wa_message_id del mensaje que se cita/responde.",
            "example": "wamid.HBgLNTQ5…",
            "maxLength": 256,
            "minLength": 1,
            "type": "string"
          }
        },
        "required": [
          "contact_id",
          "wa_message_id",
          "body"
        ],
        "type": "object"
      },
      "SendWhatsappTemplateDto": {
        "properties": {
          "components": {
            "description": "Components de la plantilla (header/body/buttons con sus parameters), tal como los define Meta.",
            "example": [
              {
                "parameters": [
                  {
                    "text": "Cristhian",
                    "type": "text"
                  },
                  {
                    "text": "$1.500.000",
                    "type": "text"
                  }
                ],
                "type": "body"
              }
            ],
            "items": {
              "type": "object"
            },
            "type": "array"
          },
          "contact_id": {
            "description": "ID del contacto destinatario.",
            "example": 12345,
            "type": "number"
          },
          "language": {
            "description": "Código de idioma de la plantilla (ISO + variante). Meta es estricto: 'es', 'es_CO', 'en_US'.",
            "example": "es_CO",
            "maxLength": 10,
            "minLength": 2,
            "type": "string"
          },
          "template_name": {
            "description": "Nombre exacto de la plantilla HSM aprobada en Meta.",
            "example": "recordatorio_pago",
            "maxLength": 200,
            "minLength": 1,
            "type": "string"
          }
        },
        "required": [
          "contact_id",
          "template_name",
          "language"
        ],
        "type": "object"
      },
      "SetAutopilotDto": {
        "properties": {
          "enabled": {
            "type": "boolean"
          }
        },
        "type": "object"
      },
      "SetCodeDto": {
        "properties": {
          "code": {
            "maxLength": 30,
            "type": "string"
          }
        },
        "required": [
          "code"
        ],
        "type": "object"
      },
      "SetSkillMcpsResponseDto": {
        "properties": {
          "mcps": {
            "items": {
              "$ref": "#/components/schemas/SkillMcpRefDto"
            },
            "type": "array"
          },
          "ok": {
            "enum": [
              true
            ],
            "example": true,
            "type": "number"
          }
        },
        "required": [
          "ok",
          "mcps"
        ],
        "type": "object"
      },
      "SetStatusDto": {
        "properties": {
          "status": {
            "enum": [
              "active",
              "vacation"
            ],
            "type": "string"
          }
        },
        "required": [
          "status"
        ],
        "type": "object"
      },
      "SetVisibilityDto": {
        "properties": {
          "visibility": {
            "enum": [
              "private",
              "visible",
              "public"
            ],
            "type": "string"
          }
        },
        "required": [
          "visibility"
        ],
        "type": "object"
      },
      "SetupPaymentMethodDto": {
        "properties": {
          "cancel_url": {
            "description": "A dónde vuelve si cancela.",
            "example": "https://partners.meteor.com.co/ingresos?vista=cuentas",
            "format": "uri",
            "type": "string"
          },
          "success_url": {
            "description": "A dónde vuelve el partner cuando termina de guardar la tarjeta.",
            "example": "https://partners.meteor.com.co/ingresos?vista=cuentas&setup=ok",
            "format": "uri",
            "type": "string"
          }
        },
        "required": [
          "success_url",
          "cancel_url"
        ],
        "type": "object"
      },
      "SkillMcpCredentialFieldDto": {
        "properties": {
          "description": {
            "example": "La llave de la consola del proveedor.",
            "type": "string"
          },
          "name": {
            "example": "api_key",
            "type": "string"
          },
          "type": {
            "example": "string",
            "type": "string"
          }
        },
        "required": [
          "name",
          "type"
        ],
        "type": "object"
      },
      "SkillMcpDetailDto": {
        "properties": {
          "connected": {
            "description": "`true` si el workspace ya tiene credenciales válidas cargadas para este MCP.",
            "example": false,
            "type": "boolean"
          },
          "credentials_required": {
            "items": {
              "$ref": "#/components/schemas/SkillMcpCredentialFieldDto"
            },
            "type": "array"
          },
          "foto_principal": {
            "example": "https://…/logo.png",
            "nullable": true,
            "type": "string"
          },
          "has_webhook": {
            "description": "`true` si el MCP recibe eventos por webhook además de exponer tools.",
            "example": false,
            "type": "boolean"
          },
          "mcp_id": {
            "example": "3120",
            "type": "string"
          },
          "native_handler": {
            "description": "Handler del MCP nativo. `null` si es externo.",
            "example": "google_calendar",
            "nullable": true,
            "type": "string"
          },
          "nombre": {
            "example": "Google Calendar",
            "type": "string"
          },
          "requires_credentials": {
            "example": true,
            "type": "boolean"
          },
          "tools": {
            "items": {
              "$ref": "#/components/schemas/SkillMcpToolDto"
            },
            "type": "array"
          }
        },
        "required": [
          "mcp_id",
          "nombre",
          "foto_principal",
          "native_handler",
          "requires_credentials",
          "connected",
          "has_webhook",
          "credentials_required",
          "tools"
        ],
        "type": "object"
      },
      "SkillMcpRefDto": {
        "properties": {
          "enabled_tools": {
            "description": "Allowlist de tools del MCP. `null` = todas habilitadas; lista vacía = ninguna,\no sea el MCP queda efectivamente apagado para esta habilidad.",
            "example": [
              "create_event"
            ],
            "items": {
              "type": "string"
            },
            "nullable": true,
            "type": "array"
          },
          "mcp_id": {
            "description": "ID del item MCP referenciado.",
            "example": "3120",
            "type": "string"
          }
        },
        "required": [
          "mcp_id",
          "enabled_tools"
        ],
        "type": "object"
      },
      "SkillMcpToolDto": {
        "properties": {
          "description": {
            "example": "Crea un evento en el calendario.",
            "type": "string"
          },
          "enabled": {
            "description": "`false` si la habilidad la dejó fuera de su allowlist.",
            "example": true,
            "type": "boolean"
          },
          "name": {
            "example": "create_event",
            "type": "string"
          }
        },
        "required": [
          "name",
          "description",
          "enabled"
        ],
        "type": "object"
      },
      "SkillMcpsResponseDto": {
        "properties": {
          "mcps": {
            "items": {
              "$ref": "#/components/schemas/SkillMcpDetailDto"
            },
            "type": "array"
          }
        },
        "required": [
          "mcps"
        ],
        "type": "object"
      },
      "SkillOkResponseDto": {
        "properties": {
          "ok": {
            "description": "Siempre `true`. Si algo falla, la respuesta es un error, no `ok: false`.",
            "enum": [
              true
            ],
            "example": true,
            "type": "number"
          }
        },
        "required": [
          "ok"
        ],
        "type": "object"
      },
      "SkillStatusResponseDto": {
        "properties": {
          "mcp_handler": {
            "description": "Handler del MCP que pide credenciales. `null` si ninguno las pide.",
            "example": null,
            "nullable": true,
            "type": "string"
          },
          "requires_credentials": {
            "example": false,
            "type": "boolean"
          },
          "status": {
            "enum": [
              "active",
              "pending_credentials",
              "inactive"
            ],
            "example": "active",
            "type": "string"
          }
        },
        "required": [
          "status",
          "requires_credentials",
          "mcp_handler"
        ],
        "type": "object"
      },
      "SkillTestResultDto": {
        "properties": {
          "input": {
            "additionalProperties": true,
            "description": "El `input` que se envió, devuelto para poder cotejar la salida.",
            "type": "object"
          },
          "result": {
            "description": "Resultado de la prueba, tal cual lo devolvió la habilidad.",
            "example": "[Skill test execution] Agenda",
            "type": "string"
          }
        },
        "required": [
          "result",
          "input"
        ],
        "type": "object"
      },
      "SlugUpdatedResponseDto": {
        "properties": {
          "id": {
            "example": 41207,
            "type": "number"
          },
          "slug": {
            "example": "apartamento-chico-norte",
            "nullable": true,
            "type": "string"
          }
        },
        "required": [
          "id",
          "slug"
        ],
        "type": "object"
      },
      "SnapshotCatalogDetailDto": {
        "properties": {
          "counts": {
            "additionalProperties": true,
            "description": "Cuántas piezas de cada tipo trae la plantilla (Mets, flujos, colecciones…).\nLas claves dependen de lo que capturó la versión.",
            "example": {
              "agents": 3,
              "flows": 5
            },
            "type": "object"
          },
          "description": {
            "example": "Mets, flujos y colecciones listos para una inmobiliaria.",
            "nullable": true,
            "type": "string"
          },
          "guide_preview": {
            "description": "Solo los primeros tres pasos de la guía: el resto llega al instalar.",
            "items": {
              "$ref": "#/components/schemas/SnapshotCatalogGuideStepDto"
            },
            "type": "array"
          },
          "id": {
            "example": "d5f1a2b3-4c5d-4e6f-8a9b-0c1d2e3f4a5b",
            "type": "string"
          },
          "listing": {
            "allOf": [
              {
                "$ref": "#/components/schemas/SnapshotCatalogListingDto"
              }
            ],
            "description": "`null` cuando la plantilla no tiene un listing publicado.",
            "nullable": true
          },
          "locale": {
            "example": "es",
            "nullable": true,
            "type": "string"
          },
          "name": {
            "example": "Inmobiliaria — captación y seguimiento",
            "type": "string"
          },
          "published_at": {
            "example": "2026-07-14T15:31:09.000Z",
            "nullable": true,
            "type": "string"
          },
          "requirements": {
            "$ref": "#/components/schemas/SnapshotRequirementsDto"
          },
          "slug": {
            "description": "Identificador legible; es lo que se usa para pedir la ficha.",
            "example": "inmobiliaria-captacion",
            "nullable": true,
            "type": "string"
          },
          "variables": {
            "description": "Las variables que se completan al instalar.",
            "items": {
              "$ref": "#/components/schemas/SnapshotCatalogVariableDto"
            },
            "type": "array"
          },
          "vertical": {
            "description": "Sector al que apunta la plantilla. Sirve para filtrar la galería.",
            "example": "inmobiliaria",
            "nullable": true,
            "type": "string"
          }
        },
        "required": [
          "id",
          "name",
          "slug",
          "description",
          "vertical",
          "locale",
          "published_at",
          "counts",
          "requirements",
          "variables",
          "guide_preview",
          "listing"
        ],
        "type": "object"
      },
      "SnapshotCatalogGuideStepDto": {
        "properties": {
          "title": {
            "example": "Conecta tu WhatsApp",
            "type": "string"
          }
        },
        "required": [
          "title"
        ],
        "type": "object"
      },
      "SnapshotCatalogItemDto": {
        "properties": {
          "counts": {
            "additionalProperties": true,
            "description": "Cuántas piezas de cada tipo trae la plantilla (Mets, flujos, colecciones…).\nLas claves dependen de lo que capturó la versión.",
            "example": {
              "agents": 3,
              "flows": 5
            },
            "type": "object"
          },
          "description": {
            "example": "Mets, flujos y colecciones listos para una inmobiliaria.",
            "nullable": true,
            "type": "string"
          },
          "id": {
            "example": "d5f1a2b3-4c5d-4e6f-8a9b-0c1d2e3f4a5b",
            "type": "string"
          },
          "locale": {
            "example": "es",
            "nullable": true,
            "type": "string"
          },
          "name": {
            "example": "Inmobiliaria — captación y seguimiento",
            "type": "string"
          },
          "published_at": {
            "example": "2026-07-14T15:31:09.000Z",
            "nullable": true,
            "type": "string"
          },
          "requirements": {
            "$ref": "#/components/schemas/SnapshotRequirementsDto"
          },
          "slug": {
            "description": "Identificador legible; es lo que se usa para pedir la ficha.",
            "example": "inmobiliaria-captacion",
            "nullable": true,
            "type": "string"
          },
          "vertical": {
            "description": "Sector al que apunta la plantilla. Sirve para filtrar la galería.",
            "example": "inmobiliaria",
            "nullable": true,
            "type": "string"
          }
        },
        "required": [
          "id",
          "name",
          "slug",
          "description",
          "vertical",
          "locale",
          "published_at",
          "counts",
          "requirements"
        ],
        "type": "object"
      },
      "SnapshotCatalogListingDto": {
        "properties": {
          "billing_type": {
            "description": "`free` se reclama sin pagar; el resto pasa por el checkout.",
            "enum": [
              "free",
              "one_time",
              "subscription"
            ],
            "example": "free",
            "type": "string"
          },
          "price_monthly_usd": {
            "description": "Precio mensual, en USD. `null` si no aplica.",
            "example": null,
            "nullable": true,
            "type": "number"
          },
          "price_usd": {
            "description": "Precio de compra única, en USD. `null` si no aplica.",
            "example": null,
            "nullable": true,
            "type": "number"
          }
        },
        "required": [
          "billing_type",
          "price_usd",
          "price_monthly_usd"
        ],
        "type": "object"
      },
      "SnapshotCatalogVariableDto": {
        "properties": {
          "key": {
            "example": "nombre_negocio",
            "type": "string"
          },
          "label": {
            "example": "Nombre del negocio",
            "nullable": true,
            "type": "string"
          },
          "required": {
            "example": true,
            "type": "boolean"
          }
        },
        "required": [
          "key",
          "label",
          "required"
        ],
        "type": "object"
      },
      "SnapshotEntitlementDto": {
        "properties": {
          "id": {
            "example": "9a8b7c6d-5e4f-4a3b-8c2d-1e0f9a8b7c6d",
            "type": "string"
          },
          "source": {
            "description": "De dónde salió el permiso. `free` es el que otorga reclamar la plantilla.",
            "example": "free",
            "type": "string"
          }
        },
        "required": [
          "id",
          "source"
        ],
        "type": "object"
      },
      "SnapshotInstallStartedDto": {
        "properties": {
          "id": {
            "description": "ID de la instalación. Consulta su avance con el detalle de la instalación.",
            "example": "b1c2d3e4-5f60-4718-9a2b-3c4d5e6f7a8b",
            "type": "string"
          },
          "status": {
            "description": "Siempre `pending`: la instalación arranca en segundo plano y esta respuesta\nvuelve enseguida, sin esperar a que termine.",
            "enum": [
              "pending"
            ],
            "example": "pending",
            "type": "string"
          }
        },
        "required": [
          "id",
          "status"
        ],
        "type": "object"
      },
      "SnapshotRequirementsDto": {
        "properties": {
          "channels": {
            "description": "Canales que la plantilla espera conectados (por ejemplo `whatsapp`).",
            "example": [
              "whatsapp"
            ],
            "items": {
              "type": "string"
            },
            "type": "array"
          },
          "native_mcps": {
            "description": "Integraciones nativas que la plantilla espera activas.",
            "example": [
              "calcom"
            ],
            "items": {
              "type": "string"
            },
            "type": "array"
          }
        },
        "required": [
          "channels",
          "native_mcps"
        ],
        "type": "object"
      },
      "SnapshotSubmittedDto": {
        "properties": {
          "id": {
            "example": "d5f1a2b3-4c5d-4e6f-8a9b-0c1d2e3f4a5b",
            "type": "string"
          },
          "review_status": {
            "description": "Queda en `in_review` hasta que el equipo editorial lo apruebe o lo rechace.",
            "example": "in_review",
            "type": "string"
          },
          "visibility": {
            "description": "Pasa a `marketplace` al enviarse; vuelve a `private` si se retira.",
            "example": "marketplace",
            "type": "string"
          }
        },
        "required": [
          "id",
          "review_status",
          "visibility"
        ],
        "type": "object"
      },
      "SystemAutomationRunDto": {
        "properties": {
          "error_message": {
            "nullable": true,
            "type": "string"
          },
          "finished_at": {
            "example": "2026-08-14T17:00:09.000Z",
            "nullable": true,
            "type": "string"
          },
          "id": {
            "example": "d4c3b2a1-0000-4000-8000-123456789abc",
            "type": "string"
          },
          "initiated_by_user_id": {
            "example": "42",
            "nullable": true,
            "type": "string"
          },
          "result": {
            "additionalProperties": true,
            "example": {
              "enviados": 7,
              "ok": true
            },
            "type": "object"
          },
          "run_key": {
            "example": "2026-08-14",
            "type": "string"
          },
          "scheduled_for": {
            "example": "2026-08-14T17:00:00.000Z",
            "nullable": true,
            "type": "string"
          },
          "source": {
            "enum": [
              "scheduled",
              "manual"
            ],
            "example": "scheduled",
            "type": "string"
          },
          "started_at": {
            "example": "2026-08-14T17:00:02.000Z",
            "type": "string"
          },
          "status": {
            "enum": [
              "queued",
              "processing",
              "succeeded",
              "failed"
            ],
            "example": "succeeded",
            "type": "string"
          }
        },
        "required": [
          "id",
          "source",
          "status",
          "run_key",
          "result",
          "started_at"
        ],
        "type": "object"
      },
      "TaskActivityResponseDto": {
        "additionalProperties": true,
        "properties": {
          "created_at": {
            "nullable": true,
            "type": "string"
          },
          "event_type": {
            "description": "Qué pasó, en clave de máquina (`step:approved`, `execution:completed`, …).",
            "example": "step:approved",
            "type": "string"
          },
          "execution_id": {
            "nullable": true,
            "type": "string"
          },
          "id": {
            "example": 91284,
            "type": "number"
          },
          "message": {
            "description": "Descripción legible del evento.",
            "nullable": true,
            "type": "string"
          },
          "payload": {
            "additionalProperties": true,
            "type": "object"
          },
          "step_id": {
            "nullable": true,
            "type": "string"
          },
          "task_id": {
            "nullable": true,
            "type": "string"
          },
          "user_id": {
            "description": "Quién lo provocó. `null` cuando lo escribió el ejecutor y no una persona.",
            "nullable": true,
            "type": "number"
          }
        },
        "required": [
          "id",
          "event_type"
        ],
        "type": "object"
      },
      "TaskCommentAuthorDto": {
        "properties": {
          "avatar_url": {
            "description": "Solo autores humanos.",
            "nullable": true,
            "type": "string"
          },
          "emoji": {
            "description": "Solo autores Met.",
            "nullable": true,
            "type": "string"
          },
          "id": {
            "description": "Id del usuario o del Met. Ausente cuando el autor es el sistema.",
            "type": "number"
          },
          "name": {
            "example": "Ada Lovelace",
            "type": "string"
          },
          "photo_url": {
            "description": "Solo autores Met.",
            "nullable": true,
            "type": "string"
          },
          "type": {
            "enum": [
              "human",
              "met",
              "system"
            ],
            "example": "human",
            "type": "string"
          }
        },
        "required": [
          "type",
          "name"
        ],
        "type": "object"
      },
      "TaskCommentCreatedResponseDto": {
        "additionalProperties": true,
        "properties": {
          "attachments": {
            "items": {
              "additionalProperties": true,
              "type": "object"
            },
            "type": "array"
          },
          "author_met_id": {
            "nullable": true,
            "type": "number"
          },
          "author_type": {
            "enum": [
              "human",
              "met",
              "system"
            ],
            "example": "human",
            "type": "string"
          },
          "author_user_id": {
            "nullable": true,
            "type": "number"
          },
          "body": {
            "nullable": true,
            "type": "string"
          },
          "created_at": {
            "nullable": true,
            "type": "string"
          },
          "id": {
            "example": 4471,
            "type": "number"
          },
          "task_execution_id": {
            "nullable": true,
            "type": "string"
          },
          "task_id": {
            "example": "b3e1c0d2-4f5a-4e6b-8c7d-9a0b1c2d3e4f",
            "type": "string"
          },
          "updated_at": {
            "nullable": true,
            "type": "string"
          }
        },
        "required": [
          "id",
          "task_id",
          "author_type",
          "body",
          "attachments"
        ],
        "type": "object"
      },
      "TaskCommentResponseDto": {
        "properties": {
          "attachments": {
            "items": {
              "additionalProperties": true,
              "type": "object"
            },
            "type": "array"
          },
          "author": {
            "$ref": "#/components/schemas/TaskCommentAuthorDto"
          },
          "body": {
            "example": "Listo, quedó enviado al cliente.",
            "nullable": true,
            "type": "string"
          },
          "created_at": {
            "example": "2026-07-30T04:12:33.120Z",
            "type": "string"
          },
          "id": {
            "example": 4471,
            "type": "number"
          },
          "task_execution_id": {
            "description": "La ejecución que lo generó, si el comentario lo escribió el ejecutor.",
            "example": "texec_01HXYZ",
            "nullable": true,
            "type": "string"
          },
          "task_id": {
            "example": "b3e1c0d2-4f5a-4e6b-8c7d-9a0b1c2d3e4f",
            "type": "string"
          },
          "updated_at": {
            "type": "string"
          }
        },
        "required": [
          "id",
          "task_id",
          "task_execution_id",
          "body",
          "attachments",
          "author",
          "created_at",
          "updated_at"
        ],
        "type": "object"
      },
      "TaskExecutionResponseDto": {
        "additionalProperties": true,
        "properties": {
          "created_at": {
            "nullable": true,
            "type": "object"
          },
          "id": {
            "example": "texec_01HXYZ",
            "type": "string"
          },
          "status": {
            "enum": [
              "running",
              "completed",
              "failed",
              "cancelled"
            ],
            "example": "completed",
            "type": "string"
          },
          "task_id": {
            "example": "tsk_01HXYZ",
            "type": "string"
          }
        },
        "required": [
          "id",
          "status"
        ],
        "type": "object"
      },
      "TaskLinkedItemResponseDto": {
        "properties": {
          "collection_code": {
            "nullable": true,
            "type": "string"
          },
          "collection_emoji": {
            "description": "Siempre `null`: `collections` no tiene columna de emoji. Se conserva por contrato.\n\nEl `type: String` es necesario, no decorativo: sin él, el plugin de Swagger no\npuede inferir nada de una propiedad cuyo tipo es el literal `null` y aborta la\ngeneración entera con un falso \"circular dependency\".",
            "nullable": true,
            "type": "string"
          },
          "collection_id": {
            "example": 12,
            "type": "number"
          },
          "collection_name": {
            "example": "Oportunidades",
            "type": "string"
          },
          "collection_slug": {
            "example": "oportunidades",
            "nullable": true,
            "type": "string"
          },
          "emoji": {
            "example": "📄",
            "nullable": true,
            "type": "string"
          },
          "id": {
            "example": 9812,
            "type": "number"
          },
          "item_code": {
            "nullable": true,
            "type": "string"
          },
          "item_slug": {
            "example": "propuesta-acme",
            "nullable": true,
            "type": "string"
          },
          "name": {
            "description": "Título del ítem, resuelto del primer campo de su colección.",
            "example": "Propuesta Acme",
            "type": "string"
          }
        },
        "required": [
          "id",
          "name",
          "emoji",
          "collection_id",
          "collection_name",
          "collection_emoji",
          "item_slug",
          "item_code",
          "collection_slug",
          "collection_code"
        ],
        "type": "object"
      },
      "TaskMessageResponseDto": {
        "properties": {
          "message": {
            "example": "Task deleted",
            "type": "string"
          }
        },
        "required": [
          "message"
        ],
        "type": "object"
      },
      "TaskResponseDto": {
        "additionalProperties": true,
        "properties": {
          "created_at": {
            "example": "2026-07-30T04:12:33.120Z",
            "nullable": true,
            "type": "object"
          },
          "description": {
            "nullable": true,
            "type": "object"
          },
          "id": {
            "example": "tsk_01HXYZ",
            "type": "string"
          },
          "name": {
            "example": "Reporte diario de ventas",
            "type": "string"
          },
          "status": {
            "example": "pendiente",
            "type": "string"
          }
        },
        "required": [
          "id",
          "name",
          "status"
        ],
        "type": "object"
      },
      "TaskStepExecutionResponseDto": {
        "additionalProperties": true,
        "properties": {
          "approval_at": {
            "nullable": true,
            "type": "string"
          },
          "approval_by_user": {
            "description": "Quién aprobó, rechazó o completó el paso.",
            "nullable": true,
            "type": "number"
          },
          "approval_comment": {
            "description": "Comentario que dejó quien resolvió el paso; queda como salida del paso humano.",
            "nullable": true,
            "type": "string"
          },
          "completed_at": {
            "nullable": true,
            "type": "string"
          },
          "error_message": {
            "nullable": true,
            "type": "string"
          },
          "execution_id": {
            "description": "La ejecución de tarea a la que pertenece este paso.",
            "example": "texec_01HXYZ",
            "type": "string"
          },
          "id": {
            "example": "d1e2f3a4-5b6c-4d7e-8f90-1a2b3c4d5e6f",
            "type": "string"
          },
          "output": {
            "additionalProperties": true,
            "nullable": true,
            "type": "object"
          },
          "started_at": {
            "nullable": true,
            "type": "string"
          },
          "status": {
            "enum": [
              "pending",
              "running",
              "completed",
              "failed",
              "waiting_for_approval",
              "waiting_for_human",
              "approved",
              "rejected"
            ],
            "example": "approved",
            "type": "string"
          },
          "step_id": {
            "description": "El paso de la definición de la tarea que se está ejecutando.",
            "example": "9f1c2a54-0d1e-4b3a-9a77-2c5f0d6e1b21",
            "type": "string"
          }
        },
        "required": [
          "id",
          "execution_id",
          "step_id",
          "status"
        ],
        "type": "object"
      },
      "TaskStepResponseDto": {
        "additionalProperties": true,
        "properties": {
          "assigned_to_met_id": {
            "description": "Met asignado al paso. Es el `id` del ítem del Met, no un nombre.",
            "nullable": true,
            "type": "number"
          },
          "assigned_to_user_id": {
            "description": "Persona asignada cuando `type` es `human_task`.",
            "nullable": true,
            "type": "number"
          },
          "created_at": {
            "example": "2026-07-30T04:12:33.120Z",
            "nullable": true,
            "type": "string"
          },
          "description": {
            "nullable": true,
            "type": "string"
          },
          "id": {
            "example": "9f1c2a54-0d1e-4b3a-9a77-2c5f0d6e1b21",
            "type": "string"
          },
          "name": {
            "example": "Resumir las ventas del día",
            "type": "string"
          },
          "output_format": {
            "example": "text",
            "type": "string"
          },
          "prompt": {
            "description": "Instrucción para el Met cuando `type` es `prompt`.",
            "nullable": true,
            "type": "string"
          },
          "result_content": {
            "description": "Resultado del paso como bloques de contenido. Viene hidratado (las referencias\ntraen su `__hydrated`) cuando la respuesta sale de un endpoint que lo tocó.",
            "items": {
              "$ref": "#/components/schemas/TaskStepResultBlockDto"
            },
            "type": "array"
          },
          "skill_id": {
            "nullable": true,
            "type": "string"
          },
          "status": {
            "enum": [
              "pending",
              "running",
              "completed",
              "failed",
              "cancelled"
            ],
            "example": "pending",
            "type": "string"
          },
          "step_order": {
            "description": "Posición dentro del checklist, 1-based. El orden lo fija `POST /steps/reorder`.",
            "example": 1,
            "type": "number"
          },
          "task_id": {
            "example": "b3e1c0d2-4f5a-4e6b-8c7d-9a0b1c2d3e4f",
            "type": "string"
          },
          "type": {
            "description": "Quién ejecuta el paso. `prompt` lo resuelve un Met, `skill` corre una skill del\nworkspace, `human_task` espera a la persona asignada y `approval` pausa la\nejecución hasta que alguien apruebe.",
            "example": "prompt",
            "type": "string"
          },
          "updated_at": {
            "nullable": true,
            "type": "string"
          }
        },
        "required": [
          "id",
          "task_id",
          "step_order",
          "name",
          "type"
        ],
        "type": "object"
      },
      "TaskStepResultBlockDto": {
        "properties": {
          "created_at": {
            "example": "2026-07-30T04:12:33.120Z",
            "type": "string"
          },
          "data": {
            "additionalProperties": true,
            "type": "object"
          },
          "id": {
            "example": "3f6c1e2a-77d9-4c1b-9f0e-5a4b3c2d1e0f",
            "type": "string"
          },
          "type": {
            "enum": [
              "text",
              "heading",
              "image",
              "task",
              "file",
              "collection_ref",
              "item_ref",
              "contact_ref",
              "page_ref",
              "web_fields_ref"
            ],
            "example": "text",
            "type": "string"
          },
          "updated_at": {
            "type": "string"
          }
        },
        "required": [
          "id",
          "type",
          "data",
          "created_at",
          "updated_at"
        ],
        "type": "object"
      },
      "TaskTriggerResponseDto": {
        "additionalProperties": true,
        "properties": {
          "available_parameters": {
            "additionalProperties": true,
            "nullable": true,
            "type": "object"
          },
          "collection_id": {
            "nullable": true,
            "type": "number"
          },
          "created_at": {
            "nullable": true,
            "type": "string"
          },
          "enabled": {
            "description": "`false` deja el disparador definido pero inerte.",
            "example": true,
            "type": "boolean"
          },
          "id": {
            "example": "c7d8e9f0-1a2b-4c3d-8e5f-6a7b8c9d0e1f",
            "type": "string"
          },
          "recurrence_pattern": {
            "example": "0 9 * * 1",
            "nullable": true,
            "type": "string"
          },
          "scheduled_date": {
            "example": "2026-08-01T13:00:00.000Z",
            "nullable": true,
            "type": "string"
          },
          "task_id": {
            "example": "b3e1c0d2-4f5a-4e6b-8c7d-9a0b1c2d3e4f",
            "type": "string"
          },
          "trigger_conditions": {
            "additionalProperties": true,
            "nullable": true,
            "type": "object"
          },
          "trigger_type": {
            "description": "Qué hace disparar la tarea: agendada, recurrente, o un evento de una colección.",
            "example": "scheduled",
            "type": "string"
          }
        },
        "required": [
          "id",
          "task_id",
          "trigger_type"
        ],
        "type": "object"
      },
      "TaskViewResponseDto": {
        "properties": {
          "column_order": {
            "description": "Orden propio de las columnas. Vacío = el orden por defecto.",
            "items": {
              "type": "string"
            },
            "type": "array"
          },
          "column_widths": {
            "additionalProperties": {
              "type": "number"
            },
            "description": "Ancho en px por clave de columna.",
            "type": "object"
          },
          "created_at": {
            "example": "2026-07-30T04:12:33.120Z",
            "type": "string"
          },
          "created_by": {
            "example": 41,
            "nullable": true,
            "type": "number"
          },
          "filters": {
            "description": "Filtros aplicados, en el mismo formato que los guarda el tablero.",
            "items": {
              "additionalProperties": true,
              "type": "object"
            },
            "type": "array"
          },
          "group_by": {
            "description": "Campo por el que agrupa la lista (`assignee`, `status`, `deadline`). `null` = sin agrupar.",
            "example": "status",
            "nullable": true,
            "type": "string"
          },
          "hidden_columns": {
            "description": "Columnas ocultas, por su clave.",
            "example": [
              "description"
            ],
            "items": {
              "type": "string"
            },
            "type": "array"
          },
          "id": {
            "example": 12,
            "type": "number"
          },
          "mode": {
            "enum": [
              "list",
              "grid",
              "kanban",
              "excel",
              "calendar"
            ],
            "example": "list",
            "type": "string"
          },
          "name": {
            "example": "Vencen esta semana",
            "type": "string"
          },
          "position": {
            "description": "Posición de la pestaña, 0-based. La reordena `PATCH /task-views/reorder`.",
            "example": 0,
            "type": "number"
          },
          "sort": {
            "allOf": [
              {
                "$ref": "#/components/schemas/TaskViewSortDto"
              }
            ],
            "nullable": true
          },
          "updated_at": {
            "type": "string"
          },
          "workspace_id": {
            "example": 3,
            "type": "number"
          }
        },
        "required": [
          "id",
          "workspace_id",
          "name",
          "mode",
          "filters",
          "sort",
          "hidden_columns",
          "group_by",
          "column_widths",
          "column_order",
          "position",
          "created_by",
          "created_at",
          "updated_at"
        ],
        "type": "object"
      },
      "TaskViewSortDto": {
        "properties": {
          "direction": {
            "enum": [
              "asc",
              "desc"
            ],
            "example": "asc",
            "type": "string"
          },
          "field": {
            "example": "deadline",
            "type": "string"
          }
        },
        "required": [
          "field",
          "direction"
        ],
        "type": "object"
      },
      "TemplateDeliveryDto": {
        "properties": {
          "error": {
            "nullable": true,
            "type": "string"
          },
          "ok": {
            "example": true,
            "type": "boolean"
          },
          "upstream": {
            "additionalProperties": true,
            "description": "Respuesta cruda del proveedor. Su forma es del proveedor, no de Meteor.",
            "type": "object"
          }
        },
        "required": [
          "ok"
        ],
        "type": "object"
      },
      "TestSkillDto": {
        "properties": {
          "input": {
            "type": "object"
          },
          "tool_name": {
            "maxLength": 100,
            "type": "string"
          }
        },
        "type": "object"
      },
      "TimelineEntryDto": {
        "properties": {
          "actor_name": {
            "description": "Nombre del actor ya resuelto. `null` cuando lo hizo el Met o el sistema.",
            "example": "Ana Ruiz",
            "nullable": true,
            "type": "string"
          },
          "actor_user_id": {
            "example": 42,
            "nullable": true,
            "type": "number"
          },
          "created_at": {
            "example": "2026-07-30T04:12:33.120Z",
            "type": "string"
          },
          "data": {
            "additionalProperties": true,
            "description": "Detalle de la entrada. Su forma depende de `type`.",
            "type": "object"
          },
          "id": {
            "example": "msg:918273",
            "type": "string"
          },
          "title": {
            "example": "Ana Ruiz cambió la etapa",
            "type": "string"
          },
          "type": {
            "enum": [
              "field_change",
              "system_event",
              "note",
              "task",
              "contact_created"
            ],
            "example": "field_change",
            "type": "string"
          }
        },
        "required": [
          "type",
          "id",
          "created_at",
          "actor_user_id",
          "title",
          "data"
        ],
        "type": "object"
      },
      "TriggerCatalogEntryDto": {
        "properties": {
          "category": {
            "enum": [
              "items",
              "crm",
              "chat",
              "channels",
              "tiempo",
              "sistema",
              "webhook"
            ],
            "example": "items",
            "type": "string"
          },
          "conditions_schema": {
            "$ref": "#/components/schemas/TriggerConditionsSchemaDto"
          },
          "description": {
            "type": "string"
          },
          "enabled": {
            "description": "`false` = está en el catálogo pero el despachador todavía no reacciona a él.\nLa UI lo muestra como \"próximamente\" y crearlo devuelve 400.",
            "example": true,
            "type": "boolean"
          },
          "exposes": {
            "description": "Variables que el evento entrega a la tarea o al flujo, en su contexto.",
            "example": [
              "item_id",
              "collection_id",
              "item_data"
            ],
            "items": {
              "type": "string"
            },
            "type": "array"
          },
          "icon": {
            "example": "➕",
            "type": "string"
          },
          "label": {
            "example": "Item creado en colección",
            "type": "string"
          },
          "type": {
            "description": "Lo que va en `trigger_type` al crear la automatización.",
            "example": "item.created",
            "type": "string"
          }
        },
        "required": [
          "type",
          "category",
          "label",
          "description",
          "icon",
          "conditions_schema",
          "exposes",
          "enabled"
        ],
        "type": "object"
      },
      "TriggerConditionPropertyDto": {
        "properties": {
          "description": {
            "type": "string"
          },
          "enum": {
            "description": "Valores permitidos, si el parámetro es de opción cerrada.",
            "items": {
              "type": "string"
            },
            "type": "array"
          },
          "ref_collection": {
            "description": "Pista para la UI: pintar un selector de colecciones.",
            "example": true,
            "type": "boolean"
          },
          "ref_contact_field": {
            "description": "Pista para la UI: pintar un selector de campos del contacto.",
            "type": "boolean"
          },
          "ref_field": {
            "description": "Pista para la UI: pintar un selector de campos de la colección elegida.",
            "type": "string"
          },
          "title": {
            "example": "Colección",
            "type": "string"
          },
          "type": {
            "example": "number",
            "type": "string"
          }
        },
        "required": [
          "type",
          "title"
        ],
        "type": "object"
      },
      "TriggerConditionsSchemaDto": {
        "properties": {
          "properties": {
            "additionalProperties": {
              "$ref": "#/components/schemas/TriggerConditionPropertyDto"
            },
            "type": "object"
          },
          "required": {
            "description": "Cuáles de esos parámetros son obligatorios.",
            "example": [
              "collection_id"
            ],
            "items": {
              "type": "string"
            },
            "type": "array"
          },
          "type": {
            "enum": [
              "object"
            ],
            "example": "object",
            "type": "string"
          }
        },
        "required": [
          "type",
          "properties"
        ],
        "type": "object"
      },
      "TriggerPayloadDto": {
        "properties": {
          "kind": {
            "description": "Qué tipo de entidad disparó el flujo. `empty` = disparo sin carga.",
            "enum": [
              "contact",
              "item",
              "product",
              "post",
              "event",
              "empty"
            ],
            "example": "contact",
            "type": "string"
          },
          "payload": {
            "additionalProperties": true,
            "description": "Los datos de esa entidad. Forma libre: depende del `kind`.",
            "type": "object"
          }
        },
        "required": [
          "kind",
          "payload"
        ],
        "type": "object"
      },
      "UpdateAgentDto": {
        "properties": {
          "active": {
            "description": "Activo (true) o de vacaciones (false). → items.status",
            "type": "boolean"
          },
          "disabled_tools": {
            "description": "Nombres de tools a DESACTIVAR para este Met (nombres finales, ej.\n`mcp_meteor_list_items`). Se ocultan del catálogo del LLM y se rechazan en\nruntime. Reemplaza la lista completa (envía todas las que quieras activas\nfuera). → `prompt_config.disabled_tools`.",
            "items": {
              "type": "string"
            },
            "type": "array"
          },
          "instructions": {
            "maxLength": 100000,
            "type": "string"
          },
          "mission": {
            "maxLength": 2000,
            "type": "string"
          },
          "model": {
            "description": "Cuánta cabeza le ponés al Met: `agil`, `brillante` o `genio`. → `data.modelo`.\n\nMismo criterio que en `CreateAgentDto`: se publican los tres tiers, se\naceptan además los ids viejos y se normalizan al modelo vigente del tier.",
            "enum": [
              "agil",
              "brillante",
              "genio"
            ],
            "example": "brillante",
            "type": "string"
          },
          "name": {
            "maxLength": 120,
            "type": "string"
          },
          "title": {
            "maxLength": 200,
            "type": "string"
          }
        },
        "type": "object"
      },
      "UpdateAgentGroupDto": {
        "properties": {
          "name": {
            "maxLength": 120,
            "type": "string"
          }
        },
        "required": [
          "name"
        ],
        "type": "object"
      },
      "UpdateBlockDto": {
        "properties": {
          "data": {
            "type": "object"
          }
        },
        "required": [
          "data"
        ],
        "type": "object"
      },
      "UpdateBroadcastDto": {
        "properties": {
          "filters": {
            "items": {
              "$ref": "#/components/schemas/SegmentConditionDto"
            },
            "type": "array"
          },
          "flow_id": {
            "type": "string"
          },
          "name": {
            "maxLength": 255,
            "type": "string"
          },
          "recurrence": {
            "enum": [
              "none",
              "daily",
              "weekly",
              "monthly"
            ],
            "type": "string"
          },
          "recurrence_dom": {
            "maximum": 31,
            "minimum": 1,
            "type": "number"
          },
          "recurrence_dow": {
            "maximum": 6,
            "minimum": 0,
            "type": "number"
          },
          "recurrence_time": {
            "pattern": "/^([01]?\\d|2[0-3]):[0-5]\\d$/",
            "type": "string"
          },
          "scheduled_at": {
            "nullable": true,
            "type": "string"
          },
          "send_mode": {
            "enum": [
              "now",
              "scheduled",
              "manual",
              "recurring"
            ],
            "type": "string"
          },
          "throttle_per_minute": {
            "maximum": 1000,
            "minimum": 1,
            "type": "number"
          },
          "timezone": {
            "maxLength": 64,
            "type": "string"
          }
        },
        "type": "object"
      },
      "UpdateCollectionDto": {
        "properties": {
          "allow_any_user_create": {
            "type": "boolean"
          },
          "allow_public_items": {
            "type": "boolean"
          },
          "artifact_config": {
            "type": "object"
          },
          "artifact_slug": {
            "type": "string"
          },
          "default_view_mode": {
            "enum": [
              "list",
              "grid",
              "kanban",
              "excel",
              "calendar"
            ],
            "type": "string"
          },
          "description": {
            "type": "string"
          },
          "emoji": {
            "maxLength": 16,
            "nullable": true,
            "type": "string"
          },
          "expose_to_agent": {
            "description": "Si false, la colección no se expone al LLM (contexto ni tools mcp_meteor_*) en ningún ejecutor.",
            "type": "boolean"
          },
          "gradient_background": {
            "type": "string"
          },
          "met_photo": {
            "type": "string"
          },
          "name": {
            "maxLength": 255,
            "type": "string"
          },
          "pinned_to_menu": {
            "type": "boolean"
          },
          "slug": {
            "type": "string"
          },
          "ui_state": {
            "type": "object"
          },
          "visibility": {
            "enum": [
              "private",
              "visible",
              "listed"
            ],
            "type": "string"
          }
        },
        "type": "object"
      },
      "UpdateContactDto": {
        "properties": {
          "data": {
            "type": "object"
          }
        },
        "required": [
          "data"
        ],
        "type": "object"
      },
      "UpdateContactTagDto": {
        "properties": {
          "name": {
            "maxLength": 60,
            "type": "string"
          }
        },
        "required": [
          "name"
        ],
        "type": "object"
      },
      "UpdateFieldDefinitionDto": {
        "properties": {
          "description": {
            "example": "Whether this contact is a VIP customer",
            "type": "string"
          },
          "label": {
            "example": "VIP Status",
            "type": "string"
          },
          "options": {
            "example": [
              "Activo",
              "Inactivo",
              "Pausado"
            ],
            "items": {
              "type": "string"
            },
            "type": "array"
          }
        },
        "type": "object"
      },
      "UpdateFieldDto": {
        "properties": {
          "label": {
            "example": "Palabra Principal",
            "maxLength": 255,
            "nullable": true,
            "type": "string"
          },
          "type": {
            "enum": [
              "text",
              "number",
              "currency",
              "email",
              "date",
              "datetime",
              "boolean",
              "url",
              "select",
              "prompt",
              "usuario",
              "contact",
              "page",
              "sitio",
              "image",
              "file"
            ],
            "example": "contact",
            "type": "string"
          },
          "validation_rules": {
            "nullable": true,
            "type": "object"
          }
        },
        "type": "object"
      },
      "UpdateFlowDto": {
        "properties": {
          "description": {
            "type": "string"
          },
          "draft_definition": {
            "description": "Canvas borrador: { nodes:[...], edges:[...] }",
            "type": "object"
          },
          "name": {
            "type": "string"
          },
          "slug": {
            "type": "string"
          }
        },
        "type": "object"
      },
      "UpdateItemDto": {
        "properties": {
          "data": {
            "type": "object"
          },
          "emoji": {
            "maxLength": 16,
            "nullable": true,
            "type": "string"
          },
          "name": {
            "deprecated": true,
            "description": "DEPRECATED: usa data[primer_field_del_schema] en su lugar.",
            "maxLength": 500,
            "nullable": true,
            "type": "string"
          },
          "slug": {
            "type": "string"
          },
          "visibility": {
            "enum": [
              "private",
              "visible",
              "listed"
            ],
            "type": "string"
          }
        },
        "type": "object"
      },
      "UpdateManagedAutomationConfigDto": {
        "properties": {
          "expected_revision": {
            "description": "Versión recibida al abrir el editor.",
            "example": 2,
            "type": "number"
          },
          "flow_id": {
            "description": "Flujo publicado que se ejecuta después del handler. null desconecta el flujo.",
            "nullable": true,
            "type": "object"
          },
          "recurrence_pattern": {
            "description": "Cron seguro de cinco partes. Solo procesos recurrentes.",
            "example": "0 12 * * 1-6",
            "type": "string"
          }
        },
        "required": [
          "expected_revision"
        ],
        "type": "object"
      },
      "UpdateManagedScheduleDto": {
        "properties": {
          "recurrence_pattern": {
            "description": "Cron de cinco partes para hora fija y días de semana (por ejemplo, 0 12 * * 1-6).",
            "example": "0 12 * * 1-6",
            "type": "string"
          }
        },
        "required": [
          "recurrence_pattern"
        ],
        "type": "object"
      },
      "UpdateMappingsDto": {
        "properties": {
          "field_mappings": {
            "items": {
              "$ref": "#/components/schemas/FieldMappingDto"
            },
            "maxItems": 200,
            "type": "array"
          },
          "link_contact": {
            "type": "boolean"
          }
        },
        "required": [
          "field_mappings"
        ],
        "type": "object"
      },
      "UpdateReminderDto": {
        "properties": {
          "message": {
            "description": "El texto que va a leer el contacto. Cambiarlo cambia el mensaje que se envía.",
            "maxLength": 1024,
            "type": "string"
          },
          "note": {
            "description": "Nota para el equipo. Es el único campo que NO se le envía al contacto.",
            "maxLength": 500,
            "type": "string"
          },
          "scheduled_for": {
            "description": "ISO 8601 y futuro. Sin offset se interpreta en la tz del workspace.",
            "type": "string"
          }
        },
        "type": "object"
      },
      "UpdateSkillCredentialsDto": {
        "properties": {
          "credentials": {
            "type": "object"
          }
        },
        "required": [
          "credentials"
        ],
        "type": "object"
      },
      "UpdateSlugDto": {
        "properties": {
          "slug": {
            "maxLength": 200,
            "pattern": "/^[a-z0-9-]+$/",
            "type": "string"
          }
        },
        "required": [
          "slug"
        ],
        "type": "object"
      },
      "UpdateTaskDto": {
        "properties": {
          "context_content": {
            "description": "Bloques con insumos de la tarea (brief, archivos, items, referencias). Validados por BlockValidatorService. Sustituye el array completo — no es append.",
            "type": "array"
          },
          "deadline": {
            "description": "Fecha límite opcional de la tarea (ISO 8601, TIMESTAMPTZ). Enviar null para limpiarla.",
            "nullable": true,
            "type": "string"
          },
          "deliverables_content": {
            "description": "Bloques con el entregable agregado de la tarea. Validados por BlockValidatorService. Sustituye el array completo.",
            "type": "array"
          },
          "description": {
            "type": "string"
          },
          "execution_config": {
            "type": "object"
          },
          "name": {
            "maxLength": 255,
            "type": "string"
          },
          "responsible_met_id": {
            "nullable": true,
            "type": "number"
          },
          "responsible_user_id": {
            "nullable": true,
            "type": "number"
          },
          "status": {
            "type": "string"
          }
        },
        "type": "object"
      },
      "UpdateTaskStatusDto": {
        "properties": {
          "status": {
            "enum": [
              "pending",
              "running",
              "paused",
              "completed",
              "failed",
              "cancelled"
            ],
            "type": "string"
          }
        },
        "required": [
          "status"
        ],
        "type": "object"
      },
      "UpdateTaskViewDto": {
        "properties": {
          "column_order": {
            "items": {
              "type": "string"
            },
            "type": "array"
          },
          "column_widths": {
            "description": "Ancho en px por column key",
            "type": "object"
          },
          "filters": {
            "items": {
              "type": "object"
            },
            "type": "array"
          },
          "group_by": {
            "nullable": true,
            "type": "string"
          },
          "hidden_columns": {
            "items": {
              "type": "string"
            },
            "type": "array"
          },
          "mode": {
            "enum": [
              "list",
              "grid",
              "kanban",
              "excel",
              "calendar"
            ],
            "type": "string"
          },
          "name": {
            "maxLength": 120,
            "type": "string"
          },
          "position": {
            "type": "number"
          },
          "sort": {
            "properties": {
              "direction": {
                "type": "object"
              },
              "field": {
                "type": "string"
              }
            },
            "required": [
              "field",
              "direction"
            ],
            "type": "object"
          }
        },
        "type": "object"
      },
      "UpdateTriggerAutomationDto": {
        "properties": {
          "action_config": {
            "description": "Config adicional de la acción (forma libre).",
            "example": {},
            "type": "object"
          },
          "action_kind": {
            "description": "Qué ejecuta el disparador.",
            "enum": [
              "task",
              "flow"
            ],
            "example": "flow",
            "type": "string"
          },
          "collection_id": {
            "description": "Colección sobre la que aplica el disparador.",
            "example": 42,
            "type": "number"
          },
          "conditions": {
            "description": "Condiciones del disparador (forma libre según trigger_type).",
            "example": {
              "field": "estado",
              "to": "ganado"
            },
            "type": "object"
          },
          "description": {
            "description": "Descripción del disparador.",
            "type": "string"
          },
          "enabled": {
            "description": "Habilitado.",
            "example": true,
            "type": "boolean"
          },
          "flow_id": {
            "description": "Cambia el flujo destino (si action_kind='flow').",
            "type": "string"
          },
          "icon": {
            "description": "Emoji/ícono para la UI.",
            "example": "🔔",
            "type": "string"
          },
          "name": {
            "description": "Nombre visible del disparador.",
            "example": "Notificar publicación",
            "type": "string"
          },
          "task_id": {
            "description": "Cambia la tarea destino (si action_kind='task').",
            "type": "string"
          }
        },
        "type": "object"
      },
      "UpdateVariableDto": {
        "properties": {
          "description": {
            "example": "Company brand name",
            "type": "string"
          },
          "is_encrypted": {
            "default": false,
            "type": "boolean"
          },
          "name": {
            "example": "brand_name",
            "type": "string"
          },
          "type": {
            "enum": [
              "text",
              "number",
              "boolean",
              "date",
              "datetime",
              "json",
              "prompt"
            ],
            "type": "string"
          },
          "value": {
            "description": "Variable value (stored as JSONB)",
            "type": "object"
          }
        },
        "type": "object"
      },
      "UpdateViewDto": {
        "properties": {
          "column_order": {
            "description": "Orden custom de field names. Vacío = orden default del schema.",
            "items": {
              "type": "string"
            },
            "type": "array"
          },
          "column_widths": {
            "description": "Ancho en px por field name",
            "type": "object"
          },
          "compact": {
            "type": "boolean"
          },
          "filters": {
            "items": {
              "type": "object"
            },
            "type": "array"
          },
          "hidden_columns": {
            "items": {
              "type": "string"
            },
            "type": "array"
          },
          "kanban_field": {
            "nullable": true,
            "type": "string"
          },
          "kanban_subtitle_field": {
            "nullable": true,
            "type": "string"
          },
          "kanban_title_field": {
            "nullable": true,
            "type": "string"
          },
          "kanban_total_field": {
            "description": "Field name cuyo valor numérico se suma por columna del tablero (currency/number).",
            "nullable": true,
            "type": "string"
          },
          "mode": {
            "enum": [
              "list",
              "grid",
              "kanban",
              "excel",
              "calendar"
            ],
            "type": "string"
          },
          "name": {
            "maxLength": 120,
            "type": "string"
          },
          "position": {
            "type": "number"
          },
          "sort": {
            "properties": {
              "direction": {
                "type": "object"
              },
              "field": {
                "type": "string"
              }
            },
            "required": [
              "field",
              "direction"
            ],
            "type": "object"
          }
        },
        "type": "object"
      },
      "UpdateWebhookDto": {
        "properties": {
          "binding_target": {
            "type": "object"
          },
          "dedupe_events": {
            "type": "boolean"
          },
          "description": {
            "maxLength": 2000,
            "type": "string"
          },
          "enabled": {
            "type": "boolean"
          },
          "name": {
            "maxLength": 120,
            "type": "string"
          }
        },
        "type": "object"
      },
      "UpgradeWorkspaceDto": {
        "properties": {
          "billing_cycle": {
            "description": "Ciclo de cobro de la suscripción.",
            "enum": [
              "monthly",
              "yearly"
            ],
            "example": "monthly",
            "type": "string"
          },
          "plan_slug": {
            "description": "Slug del plan comercial. `tech_partner` no vale: es el plan de origen.",
            "example": "estudio",
            "maxLength": 64,
            "type": "string"
          }
        },
        "required": [
          "plan_slug",
          "billing_cycle"
        ],
        "type": "object"
      },
      "VariableDeletedResponseDto": {
        "properties": {
          "message": {
            "example": "Variable deleted",
            "type": "string"
          }
        },
        "required": [
          "message"
        ],
        "type": "object"
      },
      "VideoProviderDto": {
        "properties": {
          "duration_default": {
            "example": 5,
            "type": "number"
          },
          "duration_max": {
            "description": "Duración máxima en segundos.",
            "example": 8,
            "type": "number"
          },
          "duration_min": {
            "description": "Duración mínima en segundos.",
            "example": 4,
            "type": "number"
          },
          "id": {
            "example": "veo-3.1",
            "type": "string"
          },
          "label": {
            "example": "Veo 3.1",
            "type": "string"
          },
          "supports_reference_images": {
            "example": true,
            "type": "boolean"
          }
        },
        "required": [
          "id",
          "label",
          "supports_reference_images",
          "duration_min",
          "duration_max",
          "duration_default"
        ],
        "type": "object"
      },
      "VideoResultDto": {
        "properties": {
          "duration_seconds": {
            "description": "Duración facturada, en segundos.",
            "example": 5,
            "type": "number"
          },
          "format": {
            "description": "Tipo MIME del video.",
            "example": "video/mp4",
            "type": "string"
          },
          "model": {
            "description": "Modelo que lo generó, resuelto.",
            "example": "kling-v2.1",
            "type": "string"
          },
          "url": {
            "description": "URL del video generado. **Es temporal**: la sirve el proveedor y caduca a las\npocas horas, a diferencia de la de imagen. Si lo necesitas después, descárgalo\ny guárdalo por tu cuenta.\n\nNunca lo precargues en una grilla: no hay transformación que achique un video,\nasí que cualquier `preload` distinto de `none` baja bytes del original y abre\nuna conexión por tarjeta. En una grilla va el ícono del tipo; el archivo se\ncarga al abrir el reproductor.",
            "example": "https://replicate.delivery/…/out.mp4",
            "type": "string"
          }
        },
        "required": [
          "url",
          "format",
          "model",
          "duration_seconds"
        ],
        "type": "object"
      },
      "WebhookConnectedFlowResponseDto": {
        "properties": {
          "connected_flow": {
            "allOf": [
              {
                "$ref": "#/components/schemas/ConnectedFlowDto"
              }
            ],
            "nullable": true
          }
        },
        "required": [
          "connected_flow"
        ],
        "type": "object"
      },
      "WebhookDeletedResponseDto": {
        "properties": {
          "ok": {
            "example": true,
            "type": "boolean"
          }
        },
        "required": [
          "ok"
        ],
        "type": "object"
      },
      "WebhookDeliveryDto": {
        "properties": {
          "attempts": {
            "description": "Cuántas veces se intentó, incluido el intento en curso.",
            "example": 1,
            "type": "number"
          },
          "created_at": {
            "example": "2026-07-30T04:12:33.120Z",
            "type": "string"
          },
          "delivered_at": {
            "description": "Cuándo se entregó con éxito. `null` mientras no lo esté.",
            "example": "2026-07-30T04:12:34.900Z",
            "nullable": true,
            "type": "string"
          },
          "error": {
            "description": "Motivo del fallo del último intento. `null` si no falló.",
            "example": "timeout",
            "nullable": true,
            "type": "string"
          },
          "event_id": {
            "description": "ID público del evento entregado (`evt_…`). El mismo que va en el cuerpo.",
            "example": "evt_01HXYZQ7M4N8",
            "type": "string"
          },
          "event_type": {
            "description": "Tipo del evento. Las entregas de prueba usan `ping`.",
            "example": "run.completed",
            "type": "string"
          },
          "id": {
            "example": "0f2b7c14-8a5d-4e39-b0c6-9d1a2e4f6b83",
            "type": "string"
          },
          "response_status": {
            "description": "Código HTTP que respondió tu servidor. `null` si no alcanzó a responder.",
            "example": 200,
            "nullable": true,
            "type": "number"
          },
          "status": {
            "description": "`pending` = todavía quedan reintentos por delante.",
            "enum": [
              "pending",
              "succeeded",
              "failed"
            ],
            "example": "succeeded",
            "type": "string"
          }
        },
        "required": [
          "id",
          "event_id",
          "event_type",
          "status",
          "attempts",
          "response_status",
          "error",
          "created_at",
          "delivered_at"
        ],
        "type": "object"
      },
      "WebhookDeliveryListResponseDto": {
        "properties": {
          "data": {
            "items": {
              "$ref": "#/components/schemas/WebhookDeliveryDto"
            },
            "type": "array"
          },
          "object": {
            "enum": [
              "list"
            ],
            "example": "list",
            "type": "string"
          }
        },
        "required": [
          "object",
          "data"
        ],
        "type": "object"
      },
      "WebhookEndpointCreatedResponseDto": {
        "properties": {
          "created_at": {
            "example": "2026-07-30T04:12:33.120Z",
            "type": "string"
          },
          "description": {
            "example": "Producción",
            "nullable": true,
            "type": "string"
          },
          "enabled_events": {
            "description": "Tipos de evento suscritos. `*` no es un tipo de evento: es el comodín\n«todos los del catálogo, incluidos los que se agreguen después», así que\n`[\"*\"]` significa todos. La lista sale de `WEBHOOK_EVENTS` — el catálogo\nvivo, con descripción y scope, está en `GET /webhook-endpoints/event-types`.",
            "example": [
              "run.completed",
              "contact.created"
            ],
            "items": {
              "enum": [
                "*",
                "run.completed",
                "run.failed",
                "channel.run.completed",
                "channel.run.failed",
                "contact.created",
                "contact.updated",
                "contact.message.received",
                "conversation.handoff",
                "task.completed",
                "billing.threshold",
                "app.authorized",
                "app.revoked",
                "snapshot.published",
                "snapshot.install.completed",
                "snapshot.install.failed",
                "conversion.sent",
                "conversion.discarded"
              ],
              "type": "string"
            },
            "type": "array"
          },
          "id": {
            "description": "ID del endpoint (UUID).",
            "example": "b3f1c9a2-6d4e-4f88-9a01-2c7e5d3b1f40",
            "type": "string"
          },
          "last_delivery_at": {
            "description": "Cuándo se le entregó un evento por última vez. `null` si nunca.",
            "example": "2026-07-30T05:01:12.000Z",
            "nullable": true,
            "type": "string"
          },
          "object": {
            "description": "Siempre `webhook_endpoint`.",
            "enum": [
              "webhook_endpoint"
            ],
            "example": "webhook_endpoint",
            "type": "string"
          },
          "secret": {
            "description": "Secreto de firma HMAC. Solo aparece en esta respuesta.",
            "example": "whsec_9Bq1s0YkV2m4Xz7pL3nR8tGh",
            "type": "string"
          },
          "status": {
            "description": "`disabled` = el endpoint existe pero no recibe entregas.",
            "enum": [
              "active",
              "disabled"
            ],
            "example": "active",
            "type": "string"
          },
          "url": {
            "description": "A dónde Meteor entrega los eventos.",
            "example": "https://tu-app.com/hooks/meteor",
            "type": "string"
          }
        },
        "required": [
          "id",
          "object",
          "url",
          "enabled_events",
          "description",
          "status",
          "created_at",
          "last_delivery_at",
          "secret"
        ],
        "type": "object"
      },
      "WebhookEndpointDeletedResponseDto": {
        "properties": {
          "deleted": {
            "example": true,
            "type": "boolean"
          },
          "id": {
            "example": "b3f1c9a2-6d4e-4f88-9a01-2c7e5d3b1f40",
            "type": "string"
          },
          "object": {
            "enum": [
              "webhook_endpoint"
            ],
            "example": "webhook_endpoint",
            "type": "string"
          }
        },
        "required": [
          "id",
          "object",
          "deleted"
        ],
        "type": "object"
      },
      "WebhookEndpointResponseDto": {
        "properties": {
          "created_at": {
            "example": "2026-07-30T04:12:33.120Z",
            "type": "string"
          },
          "description": {
            "example": "Producción",
            "nullable": true,
            "type": "string"
          },
          "enabled_events": {
            "description": "Tipos de evento suscritos. `*` no es un tipo de evento: es el comodín\n«todos los del catálogo, incluidos los que se agreguen después», así que\n`[\"*\"]` significa todos. La lista sale de `WEBHOOK_EVENTS` — el catálogo\nvivo, con descripción y scope, está en `GET /webhook-endpoints/event-types`.",
            "example": [
              "run.completed",
              "contact.created"
            ],
            "items": {
              "type": "string",
              "enum": [
                "*",
                "run.completed",
                "run.failed",
                "channel.run.completed",
                "channel.run.failed",
                "contact.created",
                "contact.updated",
                "contact.message.received",
                "conversation.handoff",
                "task.completed",
                "billing.threshold",
                "app.authorized",
                "app.revoked",
                "snapshot.published",
                "snapshot.install.completed",
                "snapshot.install.failed",
                "conversion.sent",
                "conversion.discarded"
              ]
            },
            "type": "array"
          },
          "id": {
            "description": "ID del endpoint (UUID).",
            "example": "b3f1c9a2-6d4e-4f88-9a01-2c7e5d3b1f40",
            "type": "string"
          },
          "last_delivery_at": {
            "description": "Cuándo se le entregó un evento por última vez. `null` si nunca.",
            "example": "2026-07-30T05:01:12.000Z",
            "nullable": true,
            "type": "string"
          },
          "object": {
            "description": "Siempre `webhook_endpoint`.",
            "enum": [
              "webhook_endpoint"
            ],
            "example": "webhook_endpoint",
            "type": "string"
          },
          "status": {
            "description": "`disabled` = el endpoint existe pero no recibe entregas.",
            "enum": [
              "active",
              "disabled"
            ],
            "example": "active",
            "type": "string"
          },
          "url": {
            "description": "A dónde Meteor entrega los eventos.",
            "example": "https://tu-app.com/hooks/meteor",
            "type": "string"
          }
        },
        "required": [
          "id",
          "object",
          "url",
          "enabled_events",
          "description",
          "status",
          "created_at",
          "last_delivery_at"
        ],
        "type": "object"
      },
      "WebhookEventDto": {
        "properties": {
          "event_kind": {
            "description": "Tipo normalizado por el verificador o el handler (ej. `payment.approved`).\n`null` cuando el binding es `generic` o nadie lo clasificó.",
            "example": "payment.approved",
            "nullable": true,
            "type": "string"
          },
          "external_id": {
            "description": "ID del evento en el sistema externo. Es la clave del deduplicado.",
            "example": "124199384",
            "nullable": true,
            "type": "string"
          },
          "headers": {
            "additionalProperties": true,
            "description": "Cabeceras con las que llegó la petición, tal como las mandó el sistema\nexterno. Ahí está, entre otras, la cabecera de firma.",
            "type": "object"
          },
          "id": {
            "example": 55210,
            "type": "number"
          },
          "processed_at": {
            "description": "Cuándo terminó de procesarse. `null` si no se procesó (firma inválida, o en curso).",
            "example": "2026-07-30T04:12:33.480Z",
            "nullable": true,
            "type": "string"
          },
          "processing_error": {
            "description": "Error del procesamiento. `null` si salió bien.",
            "example": null,
            "nullable": true,
            "type": "string"
          },
          "raw_body": {
            "additionalProperties": true,
            "description": "El cuerpo recibido, sin tocar. Su forma la define quien lo envía.",
            "type": "object"
          },
          "received_at": {
            "example": "2026-07-30T04:12:33.120Z",
            "type": "string"
          },
          "signature_error": {
            "description": "Por qué falló la verificación de firma. `null` si validó.",
            "example": null,
            "nullable": true,
            "type": "string"
          },
          "signature_valid": {
            "description": "`false` = la firma no validó. El evento se registra igual, para que puedas verlo.",
            "example": true,
            "type": "boolean"
          }
        },
        "required": [
          "id",
          "received_at",
          "event_kind",
          "external_id",
          "signature_valid",
          "signature_error",
          "processed_at",
          "processing_error",
          "headers",
          "raw_body"
        ],
        "type": "object"
      },
      "WebhookEventTypeDto": {
        "properties": {
          "description": {
            "example": "Un Run terminó con éxito.",
            "type": "string"
          },
          "scope": {
            "description": "Scope que debe portar la key para poder suscribirse a este evento.",
            "example": "runs:read",
            "type": "string"
          },
          "type": {
            "description": "El string que va en `enabled_events`. Renombrarlo sería breaking. El `enum`\nson los tipos del catálogo — sin el comodín `*`, que es un valor válido de\n`enabled_events` pero no un evento y por eso nunca sale en esta lista.",
            "enum": [
              "run.completed",
              "run.failed",
              "channel.run.completed",
              "channel.run.failed",
              "contact.created",
              "contact.updated",
              "contact.message.received",
              "conversation.handoff",
              "task.completed",
              "billing.threshold",
              "app.authorized",
              "app.revoked",
              "snapshot.published",
              "snapshot.install.completed",
              "snapshot.install.failed",
              "conversion.sent",
              "conversion.discarded"
            ],
            "example": "run.completed",
            "type": "string"
          }
        },
        "required": [
          "type",
          "description",
          "scope"
        ],
        "type": "object"
      },
      "WebhookEventTypeListResponseDto": {
        "properties": {
          "data": {
            "items": {
              "$ref": "#/components/schemas/WebhookEventTypeDto"
            },
            "type": "array"
          },
          "object": {
            "enum": [
              "list"
            ],
            "example": "list",
            "type": "string"
          }
        },
        "required": [
          "object",
          "data"
        ],
        "type": "object"
      },
      "WebhookFieldMappingDto": {
        "properties": {
          "dest_key": {
            "description": "`field_key` del contacto o nombre de la variable, según `dest_kind`.",
            "example": "email",
            "type": "string"
          },
          "dest_kind": {
            "description": "Si el destino es un campo del contacto o una variable del workspace.",
            "enum": [
              "contact",
              "workspace_var"
            ],
            "example": "contact",
            "type": "string"
          },
          "fallback": {
            "description": "Valor a usar cuando `json_path` no viene en el payload.",
            "example": "sin dato",
            "nullable": true,
            "type": "string"
          },
          "json_path": {
            "description": "Ruta JSON dentro del cuerpo recibido.",
            "example": "data.customer.email",
            "type": "string"
          }
        },
        "required": [
          "json_path",
          "dest_kind",
          "dest_key"
        ],
        "type": "object"
      },
      "WebhookRotatedSecretDto": {
        "properties": {
          "secret": {
            "example": "a1b2c3d4e5f60718293a4b5c6d7e8f90",
            "type": "string"
          }
        },
        "required": [
          "secret"
        ],
        "type": "object"
      },
      "WebhookSampleDto": {
        "properties": {
          "id": {
            "example": 55210,
            "type": "number"
          },
          "raw_body": {
            "additionalProperties": true,
            "description": "El cuerpo recibido, sin tocar.",
            "type": "object"
          },
          "received_at": {
            "example": "2026-07-30T04:12:33.120Z",
            "type": "string"
          }
        },
        "required": [
          "id",
          "received_at",
          "raw_body"
        ],
        "type": "object"
      },
      "WhatsappSendResponseDto": {
        "properties": {
          "success": {
            "description": "Siempre `true`. Un envío que WhatsApp rechaza no devuelve este cuerpo: sale por\nel catálogo de errores con `400`.",
            "enum": [
              true
            ],
            "example": true,
            "type": "number"
          },
          "wa_message_id": {
            "description": "ID del mensaje que asignó WhatsApp (`wamid.…`). Es la llave con la que llegan\ndespués los estados de entrega por webhook. Puede venir ausente si Meta aceptó\nel envío sin devolver el id.",
            "example": "wamid.HBgMNTczMDAxMTEyMjMzFQIAERgSN0EyM…",
            "type": "string"
          }
        },
        "required": [
          "success"
        ],
        "type": "object"
      },
      "WhatsappTemplateDryRunPayloadDto": {
        "properties": {
          "phone_number_id": {
            "description": "Línea de WhatsApp por la que saldría el mensaje. Es un identificador de la\ncuenta de Meta; **no** es una credencial y el `access_token` nunca se devuelve.",
            "example": "109876543210987",
            "type": "string"
          },
          "recipient": {
            "description": "Identificador del destinatario cuando no tenemos su teléfono\n(business-scoped user ID de Meta). Es específico de nuestra cuenta: el\nmismo usuario tiene otro identificador en otro negocio.",
            "example": "CO.13491208655302741918",
            "type": "string"
          },
          "template": {
            "$ref": "#/components/schemas/WhatsappTemplateDryRunTemplateDto"
          },
          "to": {
            "description": "Número destino resuelto del contacto, en formato Meta (sin `+`).\n\nAusente cuando el contacto adoptó un username de WhatsApp y Meta ya no\nexpone su número: en ese caso viene `recipient` en su lugar. Siempre llega\nuno de los dos, nunca los dos a la vez.",
            "example": "573001112233",
            "type": "string"
          }
        },
        "required": [
          "phone_number_id",
          "template"
        ],
        "type": "object"
      },
      "WhatsappTemplateDryRunResponseDto": {
        "properties": {
          "dry_run": {
            "description": "Siempre `true`: distingue esta respuesta de la de un envío real.",
            "enum": [
              true
            ],
            "example": true,
            "type": "number"
          },
          "would_send": {
            "$ref": "#/components/schemas/WhatsappTemplateDryRunPayloadDto"
          }
        },
        "required": [
          "dry_run",
          "would_send"
        ],
        "type": "object"
      },
      "WhatsappTemplateDryRunTemplateDto": {
        "properties": {
          "components": {
            "description": "Los `components` que mandaste, tal cual. Ausente si no mandaste ninguno.",
            "items": {
              "additionalProperties": true,
              "type": "object"
            },
            "type": "array"
          },
          "language": {
            "description": "Código de idioma de la plantilla (`es`, `es_CO`, `en_US`).",
            "example": "es",
            "type": "string"
          },
          "name": {
            "description": "Nombre de la plantilla HSM aprobada.",
            "example": "recordatorio_cita",
            "type": "string"
          }
        },
        "required": [
          "name",
          "language"
        ],
        "type": "object"
      },
      "WorkspaceAccessLimitsDto": {
        "properties": {
          "contacts_max": {
            "example": 10000,
            "type": "number"
          },
          "contacts_used": {
            "example": 8412,
            "type": "number"
          },
          "members_max": {
            "example": 10,
            "type": "number"
          },
          "members_used": {
            "example": 7,
            "type": "number"
          },
          "mets_max": {
            "example": 5,
            "type": "number"
          },
          "mets_used": {
            "example": 3,
            "type": "number"
          }
        },
        "required": [
          "contacts_used",
          "contacts_max",
          "members_used",
          "members_max",
          "mets_used",
          "mets_max"
        ],
        "type": "object"
      },
      "WorkspaceAccessResponseDto": {
        "properties": {
          "blocked": {
            "description": "`true` = las escrituras están rechazándose.",
            "example": false,
            "type": "boolean"
          },
          "current_period_end": {
            "example": "2026-08-01T00:00:00.000Z",
            "nullable": true,
            "type": "string"
          },
          "limits": {
            "$ref": "#/components/schemas/WorkspaceAccessLimitsDto"
          },
          "message": {
            "description": "Explicación para mostrarle a una persona.",
            "example": null,
            "nullable": true,
            "type": "string"
          },
          "over_limit": {
            "allOf": [
              {
                "$ref": "#/components/schemas/WorkspaceOverLimitDto"
              }
            ],
            "description": "Ausente en workspaces cuyo estado de sobrecupo todavía no se calculó."
          },
          "plan_id": {
            "example": 3,
            "nullable": true,
            "type": "number"
          },
          "plan_name": {
            "example": "Crecimiento",
            "nullable": true,
            "type": "string"
          },
          "plan_slug": {
            "example": "crecimiento",
            "nullable": true,
            "type": "string"
          },
          "reason": {
            "description": "Qué lo bloquea. `null` cuando `blocked` es `false`.",
            "enum": [
              "trial_expired",
              "plan_inactive",
              "plan_deactivated",
              "period_expired",
              "contacts_limit",
              "over_limit",
              "suspended"
            ],
            "example": null,
            "nullable": true,
            "type": "string"
          },
          "severity": {
            "description": "`warn` avisa sin bloquear; `block` ya está rechazando escrituras.",
            "enum": [
              "none",
              "warn",
              "block"
            ],
            "example": "none",
            "type": "string"
          },
          "subscription_status": {
            "example": "active",
            "nullable": true,
            "type": "string"
          },
          "trial_ends_at": {
            "example": null,
            "nullable": true,
            "type": "string"
          }
        },
        "required": [
          "blocked",
          "reason",
          "message",
          "severity",
          "subscription_status",
          "plan_id",
          "plan_slug",
          "plan_name",
          "trial_ends_at",
          "current_period_end",
          "limits"
        ],
        "type": "object"
      },
      "WorkspaceAddonWithDetailDto": {
        "properties": {
          "addon": {
            "$ref": "#/components/schemas/AddonResponseDto"
          },
          "addon_id": {
            "example": 7,
            "type": "number"
          },
          "canceled_at": {
            "example": null,
            "nullable": true,
            "type": "string"
          },
          "created_at": {
            "example": "2026-05-02T11:20:00.000Z",
            "type": "string"
          },
          "expires_at": {
            "example": null,
            "nullable": true,
            "type": "string"
          },
          "id": {
            "example": 991,
            "type": "number"
          },
          "pending_effective_at": {
            "description": "Cuándo se aplica `pending_quantity`.",
            "example": null,
            "nullable": true,
            "type": "string"
          },
          "pending_quantity": {
            "description": "Cantidad a la que baja al terminar el período ya pagado (`0` = se da de\nbaja). Bajar y cancelar nunca aplican de inmediato.",
            "example": null,
            "nullable": true,
            "type": "number"
          },
          "purchased_at": {
            "example": "2026-05-02T11:20:00.000Z",
            "type": "string"
          },
          "quantity": {
            "description": "Cuántas unidades están activas hoy.",
            "example": 2,
            "type": "number"
          },
          "status": {
            "enum": [
              "active",
              "canceled",
              "expired"
            ],
            "example": "active",
            "type": "string"
          },
          "stripe_checkout_session_id": {
            "example": null,
            "nullable": true,
            "type": "string"
          },
          "stripe_subscription_id": {
            "example": "sub_1Om…",
            "nullable": true,
            "type": "string"
          },
          "updated_at": {
            "example": "2026-05-02T11:20:00.000Z",
            "type": "string"
          },
          "workspace_id": {
            "example": 134,
            "type": "number"
          }
        },
        "required": [
          "id",
          "workspace_id",
          "addon_id",
          "quantity",
          "status",
          "stripe_subscription_id",
          "stripe_checkout_session_id",
          "purchased_at",
          "expires_at",
          "canceled_at",
          "pending_quantity",
          "pending_effective_at",
          "created_at",
          "updated_at",
          "addon"
        ],
        "type": "object"
      },
      "WorkspaceAssetCleanupResponseDto": {
        "properties": {
          "deleted": {
            "description": "Cuántas huérfanas se borraron. `0` en la simulación.",
            "example": 25,
            "type": "number"
          },
          "moved": {
            "description": "Cuántas usadas se movieron a la carpeta dedicada. `0` en la simulación.",
            "example": 12,
            "type": "number"
          },
          "orphans": {
            "description": "Cuántas no las usa ninguna página. Son las candidatas a borrarse.",
            "example": 25,
            "type": "number"
          },
          "total": {
            "description": "Cuántas provisionales se encontraron.",
            "example": 37,
            "type": "number"
          },
          "used": {
            "description": "Cuántas siguen referenciadas por alguna página. Estas nunca se borran.",
            "example": 12,
            "type": "number"
          }
        },
        "required": [
          "total",
          "used",
          "orphans",
          "moved",
          "deleted"
        ],
        "type": "object"
      },
      "WorkspaceAssetDeletedResponseDto": {
        "properties": {
          "deleted": {
            "example": true,
            "type": "boolean"
          }
        },
        "required": [
          "deleted"
        ],
        "type": "object"
      },
      "WorkspaceAssetFolderNodeDto": {
        "properties": {
          "children": {
            "items": {
              "$ref": "#/components/schemas/WorkspaceAssetFolderNodeDto"
            },
            "type": "array"
          },
          "created_at": {
            "example": "2026-07-25T18:20:04.110Z",
            "type": "string"
          },
          "created_by": {
            "example": 42,
            "nullable": true,
            "type": "number"
          },
          "id": {
            "example": "1a2b3c4d-5e6f-4a7b-8c9d-0e1f2a3b4c5d",
            "type": "string"
          },
          "name": {
            "example": "Marca",
            "type": "string"
          },
          "parent_id": {
            "description": "Carpeta padre. `null` = es una carpeta raíz.",
            "example": null,
            "nullable": true,
            "type": "string"
          },
          "position": {
            "description": "Orden entre hermanas, ascendente.",
            "example": 0,
            "type": "number"
          },
          "updated_at": {
            "example": "2026-07-25T18:20:04.110Z",
            "type": "string"
          },
          "workspace_id": {
            "example": 134,
            "type": "number"
          }
        },
        "required": [
          "id",
          "workspace_id",
          "name",
          "parent_id",
          "position",
          "created_by",
          "created_at",
          "updated_at",
          "children"
        ],
        "type": "object"
      },
      "WorkspaceAssetFolderResponseDto": {
        "properties": {
          "created_at": {
            "example": "2026-07-25T18:20:04.110Z",
            "type": "string"
          },
          "created_by": {
            "example": 42,
            "nullable": true,
            "type": "number"
          },
          "id": {
            "example": "1a2b3c4d-5e6f-4a7b-8c9d-0e1f2a3b4c5d",
            "type": "string"
          },
          "name": {
            "example": "Marca",
            "type": "string"
          },
          "parent_id": {
            "description": "Carpeta padre. `null` = es una carpeta raíz.",
            "example": null,
            "nullable": true,
            "type": "string"
          },
          "position": {
            "description": "Orden entre hermanas, ascendente.",
            "example": 0,
            "type": "number"
          },
          "updated_at": {
            "example": "2026-07-25T18:20:04.110Z",
            "type": "string"
          },
          "workspace_id": {
            "example": 134,
            "type": "number"
          }
        },
        "required": [
          "id",
          "workspace_id",
          "name",
          "parent_id",
          "position",
          "created_by",
          "created_at",
          "updated_at"
        ],
        "type": "object"
      },
      "WorkspaceAssetWithUrlDto": {
        "properties": {
          "created_at": {
            "example": "2026-07-25T18:20:04.110Z",
            "type": "string"
          },
          "created_by": {
            "description": "Usuario que lo subió. `null` si lo generó una automatización.",
            "example": 42,
            "nullable": true,
            "type": "number"
          },
          "folder_id": {
            "description": "Carpeta que lo contiene. `null` = está en la raíz de la Mediateca.",
            "example": null,
            "nullable": true,
            "type": "string"
          },
          "id": {
            "description": "UUID del asset. También es el nombre del archivo en Storage.",
            "example": "c4f8a1e2-9d33-4b77-8e10-5a2b6c7d8e9f",
            "type": "string"
          },
          "metadata": {
            "additionalProperties": true,
            "description": "Datos extra del productor del asset. Forma libre.",
            "example": {},
            "type": "object"
          },
          "mime_type": {
            "example": "image/png",
            "nullable": true,
            "type": "string"
          },
          "name": {
            "description": "Nombre visible, editable. No condiciona la ruta en Storage.",
            "example": "Logo horizontal.png",
            "type": "string"
          },
          "size_bytes": {
            "description": "Peso del archivo en bytes.",
            "example": 184320,
            "nullable": true,
            "type": "number"
          },
          "source": {
            "description": "De dónde salió: `upload` lo subió una persona, `item_upload` llegó como\nadjunto de un item, `generated` lo produjo un modelo y `flow_run` es la\nsalida pesada de un nodo de flujo.",
            "enum": [
              "upload",
              "item_upload",
              "generated",
              "flow_run"
            ],
            "example": "upload",
            "type": "string"
          },
          "storage_path": {
            "description": "**La fuente de verdad del archivo**: su ruta dentro del bucket. `url` se\nderiva de esto en cada respuesta, así que guarda el path, no la URL.",
            "example": "workspace-assets/134/c4f8a1e2-9d33-4b77-8e10-5a2b6c7d8e9f.png",
            "type": "string"
          },
          "updated_at": {
            "example": "2026-07-25T18:20:04.110Z",
            "type": "string"
          },
          "url": {
            "description": "URL del **archivo original**, a tamaño completo. Los assets de la Mediateca\nse sirven desde un prefijo público, así que no caduca.\n\nÚsala tal cual solo para el visor a pantalla completa y para la descarga.\nPara pintarla en chico —una miniatura de grilla, un avatar, una fila de\nlista— pide la versión ya dimensionada por Storage\n(`/render/image/public/…?width=…&height=…`) con la medida real de la caja:\nun JPEG de 870 KB baja a ~15 KB a 400×400. Y si el asset es un video, no lo\nprecargues en una grilla: no hay transformación que lo achique.",
            "example": "https://…supabase.co/storage/v1/object/public/meteorus-bucket/workspace-assets/134/c4f8a1e2….png",
            "type": "string"
          },
          "workspace_id": {
            "example": 134,
            "type": "number"
          }
        },
        "required": [
          "id",
          "workspace_id",
          "folder_id",
          "name",
          "storage_path",
          "mime_type",
          "size_bytes",
          "source",
          "metadata",
          "created_by",
          "created_at",
          "updated_at",
          "url"
        ],
        "type": "object"
      },
      "WorkspaceOverLimitDto": {
        "properties": {
          "cause": {
            "description": "`downgrade` otorga días de gracia; `other` bloquea de inmediato.",
            "enum": [
              "downgrade",
              "other"
            ],
            "example": null,
            "nullable": true,
            "type": "string"
          },
          "contacts_near": {
            "example": false,
            "type": "boolean"
          },
          "contacts_over": {
            "example": false,
            "type": "boolean"
          },
          "grace_until": {
            "description": "Hasta cuándo hay margen antes de que se congelen las escrituras.",
            "example": null,
            "nullable": true,
            "type": "string"
          },
          "members_near": {
            "description": "`true` cuando el uso se acerca al techo, antes de pasarlo.",
            "example": true,
            "type": "boolean"
          },
          "members_over": {
            "example": false,
            "type": "boolean"
          },
          "mets_over": {
            "example": false,
            "type": "boolean"
          },
          "over": {
            "description": "`true` si alguna dimensión está por encima del límite.",
            "example": false,
            "type": "boolean"
          },
          "since": {
            "description": "Desde cuándo está en sobrecupo.",
            "example": null,
            "nullable": true,
            "type": "string"
          }
        },
        "required": [
          "over",
          "members_over",
          "contacts_over",
          "mets_over",
          "members_near",
          "contacts_near",
          "since",
          "grace_until",
          "cause"
        ],
        "type": "object"
      },
      "WorkspaceSkillConfigDto": {
        "properties": {
          "activated_at": {
            "description": "Cuándo se activó. `null` si nunca se activó.",
            "example": "2026-07-30T04:12:33.120Z",
            "nullable": true,
            "type": "string"
          },
          "activated_by": {
            "description": "Quién la activó. `null` si el usuario ya no existe o si nunca se activó.",
            "example": 512,
            "nullable": true,
            "type": "number"
          },
          "created_at": {
            "example": "2026-07-12T10:00:00.000Z",
            "type": "string"
          },
          "id": {
            "example": 77,
            "type": "number"
          },
          "is_active": {
            "description": "`true` si la habilidad está activada para el workspace.",
            "example": true,
            "type": "boolean"
          },
          "skill_id": {
            "description": "ID de la habilidad a la que aplica esta configuración.",
            "example": "3120",
            "type": "string"
          },
          "updated_at": {
            "example": "2026-07-30T04:12:33.120Z",
            "type": "string"
          },
          "workspace_id": {
            "example": 134,
            "type": "number"
          }
        },
        "required": [
          "id",
          "workspace_id",
          "skill_id",
          "is_active",
          "activated_at",
          "activated_by",
          "created_at",
          "updated_at"
        ],
        "type": "object"
      },
      "WorkspaceSkillItemDto": {
        "properties": {
          "code": {
            "example": "SK-3120",
            "type": "string"
          },
          "collection_id": {
            "description": "Colección `_skills` en la que vive.",
            "example": 91,
            "type": "number"
          },
          "created_at": {
            "example": "2026-07-12T10:00:00.000Z",
            "type": "string"
          },
          "data": {
            "additionalProperties": true,
            "description": "Configuración de la habilidad: nombre, descripción, prompt base y los MCP que\ntrae. Es un JSON de forma libre — cada habilidad declara lo suyo.",
            "type": "object"
          },
          "id": {
            "example": 3120,
            "type": "number"
          },
          "is_public": {
            "example": false,
            "type": "boolean"
          },
          "slug": {
            "example": "agenda",
            "nullable": true,
            "type": "string"
          },
          "source_template_id": {
            "description": "Plantilla global de la que se copió esta habilidad. `null` si es original.",
            "example": 2044,
            "nullable": true,
            "type": "number"
          },
          "status": {
            "example": "active",
            "type": "string"
          },
          "updated_at": {
            "example": "2026-07-30T04:12:33.120Z",
            "type": "string"
          },
          "visibility": {
            "description": "`private` | `listed` | `public`. Las plantillas del catálogo son `public`.",
            "example": "public",
            "type": "string"
          }
        },
        "required": [
          "id",
          "collection_id",
          "data",
          "code",
          "slug",
          "visibility",
          "source_template_id",
          "is_public",
          "status",
          "created_at",
          "updated_at"
        ],
        "type": "object"
      },
      "WorkspaceSkillStatusDto": {
        "properties": {
          "linked_mets_count": {
            "description": "Cuántos Mets la tienen vinculada. `0` = copia huérfana.",
            "example": 2,
            "type": "number"
          },
          "mcp_handler": {
            "example": null,
            "nullable": true,
            "type": "string"
          },
          "requires_credentials": {
            "example": false,
            "type": "boolean"
          },
          "skill_id": {
            "example": 88,
            "type": "number"
          },
          "status": {
            "enum": [
              "active",
              "pending_credentials",
              "inactive"
            ],
            "example": "active",
            "type": "string"
          }
        },
        "required": [
          "skill_id",
          "status",
          "requires_credentials",
          "mcp_handler",
          "linked_mets_count"
        ],
        "type": "object"
      },
      "WorkspaceSkillsStatusResponseDto": {
        "properties": {
          "skills": {
            "items": {
              "$ref": "#/components/schemas/WorkspaceSkillStatusDto"
            },
            "type": "array"
          }
        },
        "required": [
          "skills"
        ],
        "type": "object"
      },
      "WorkspaceSubscriptionDto": {
        "properties": {
          "billing_cycle": {
            "enum": [
              "monthly",
              "yearly"
            ],
            "example": "monthly",
            "type": "string"
          },
          "canceled_at": {
            "description": "Cuándo se pidió la cancelación. El servicio sigue hasta `current_period_end`.",
            "example": null,
            "nullable": true,
            "type": "string"
          },
          "created_at": {
            "example": "2026-01-12T10:00:00.000Z",
            "type": "string"
          },
          "current_period_end": {
            "description": "Cuándo vence el período ya pagado.",
            "example": "2026-08-01T00:00:00.000Z",
            "nullable": true,
            "type": "string"
          },
          "current_period_start": {
            "example": "2026-07-01T00:00:00.000Z",
            "nullable": true,
            "type": "string"
          },
          "id": {
            "example": 512,
            "type": "number"
          },
          "last_change_source": {
            "description": "Qué originó el último cambio de estado.",
            "enum": [
              "admin",
              "stripe",
              "user",
              "system"
            ],
            "example": "stripe",
            "nullable": true,
            "type": "string"
          },
          "last_changed_at": {
            "example": "2026-07-01T00:00:11.900Z",
            "nullable": true,
            "type": "string"
          },
          "plan_id": {
            "example": 3,
            "type": "number"
          },
          "referred_by": {
            "description": "Partner o miembro que refirió el workspace.",
            "example": null,
            "nullable": true,
            "type": "number"
          },
          "status": {
            "description": "`trial` y `active` operan con normalidad; `grace_period` es el margen tras un\ncobro fallido; `inactive` nunca llegó a pagar y `deactivated` pagó y se fue;\n`energy_depleted`, `suspended` y `contacts_limit` son bloqueos operativos.",
            "enum": [
              "trial",
              "active",
              "grace_period",
              "inactive",
              "deactivated",
              "energy_depleted",
              "suspended",
              "contacts_limit"
            ],
            "example": "active",
            "type": "string"
          },
          "stripe_customer_id": {
            "description": "Cliente de Stripe del workspace. Es un identificador, no un medio de pago.",
            "example": "cus_QX…",
            "nullable": true,
            "type": "string"
          },
          "stripe_subscription_id": {
            "example": "sub_1Ok…",
            "nullable": true,
            "type": "string"
          },
          "trial_ends_at": {
            "example": null,
            "nullable": true,
            "type": "string"
          },
          "updated_at": {
            "example": "2026-07-01T00:00:11.900Z",
            "type": "string"
          },
          "workspace_id": {
            "example": 134,
            "type": "number"
          }
        },
        "required": [
          "id",
          "workspace_id",
          "plan_id",
          "billing_cycle",
          "status",
          "current_period_start",
          "current_period_end",
          "trial_ends_at",
          "canceled_at",
          "stripe_customer_id",
          "stripe_subscription_id",
          "referred_by",
          "last_change_source",
          "last_changed_at",
          "created_at",
          "updated_at"
        ],
        "type": "object"
      },
      "WorkspaceVariableDto": {
        "properties": {
          "created_at": {
            "example": "2026-07-30T04:12:33.120Z",
            "type": "string"
          },
          "description": {
            "description": "Para qué sirve la variable. Lo ve quien la elige en el autocompletar.",
            "example": "Horario que el Met le informa al cliente",
            "nullable": true,
            "type": "string"
          },
          "id": {
            "example": 41,
            "type": "number"
          },
          "is_encrypted": {
            "description": "Marca de \"esto es un secreto\". Sirve para que otras partes del producto no lo\nexpongan (no viaja en una plantilla exportada, no entra al prompt del Met),\npero **no cifra el valor** ni lo oculta de esta API: `value` se devuelve\nigual en `GET /variables` y `GET /variables/{id}` con scope `variables:read`.",
            "example": false,
            "type": "boolean"
          },
          "name": {
            "description": "Nombre sin el prefijo: se usa en las plantillas como `$workspace.<name>`.",
            "example": "horario_atencion",
            "type": "string"
          },
          "type": {
            "description": "Cómo se interpreta `value` al resolver la variable.",
            "enum": [
              "text",
              "number",
              "boolean",
              "date",
              "datetime",
              "json",
              "prompt"
            ],
            "example": "text",
            "type": "string"
          },
          "updated_at": {
            "example": "2026-07-30T04:12:33.120Z",
            "type": "string"
          },
          "value": {
            "description": "El valor, guardado como JSON. Su forma depende de `type`: un `text` es un\nstring, un `json` puede ser cualquier objeto o arreglo.",
            "example": "Lunes a viernes, 8am a 6pm",
            "nullable": true,
            "oneOf": [
              {
                "type": "string"
              },
              {
                "type": "number"
              },
              {
                "type": "boolean"
              },
              {
                "additionalProperties": true,
                "type": "object"
              },
              {
                "items": {},
                "type": "array"
              }
            ]
          },
          "workspace_id": {
            "description": "Workspace dueño de la variable.",
            "example": 134,
            "type": "number"
          }
        },
        "required": [
          "id",
          "workspace_id",
          "name",
          "type",
          "value",
          "description",
          "is_encrypted",
          "created_at",
          "updated_at"
        ],
        "type": "object"
      }
    },
    "securitySchemes": {
      "api-key": {
        "bearerFormat": "JWT",
        "description": "API key met_live_… / met_test_…",
        "scheme": "bearer",
        "type": "http"
      }
    }
  },
  "info": {
    "contact": {},
    "description": "Superficie pública de Meteor — infraestructura agéntica como servicio. Generado del código (@ApiPublic); no editar a mano.\n\n**Idempotencia:** cualquier `POST` acepta la cabecera `Idempotency-Key`. Un reintento con la misma key y el mismo cuerpo devuelve la respuesta original (no crea duplicados); con la misma key y un cuerpo distinto responde `409 idempotency_key_reuse`. Las keys se retienen 24 h. Recomendado en Workers/integraciones donde el reintento es inevitable.",
    "title": "Met Public API",
    "version": "2.39.0"
  },
  "openapi": "3.0.0",
  "paths": {
    "/agent-groups": {
      "get": {
        "externalDocs": {
          "description": "Guía: Mets y sus herramientas",
          "url": "https://developers.meteor.com.co/guias/mets-y-herramientas.html"
        },
        "operationId": "AgentGroupsController_list",
        "parameters": [],
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "allOf": [
                    {
                      "$ref": "#/components/schemas/ApiEnvelope"
                    },
                    {
                      "properties": {
                        "data": {
                          "items": {
                            "$ref": "#/components/schemas/AgentGroupResponseDto"
                          },
                          "type": "array"
                        }
                      },
                      "required": [
                        "data"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": ""
          },
          "400": {
            "$ref": "#/components/responses/ApiErrorInvalidRequest"
          },
          "401": {
            "$ref": "#/components/responses/ApiErrorAuth"
          },
          "403": {
            "$ref": "#/components/responses/ApiErrorForbidden"
          },
          "404": {
            "$ref": "#/components/responses/ApiErrorNotFound"
          },
          "429": {
            "$ref": "#/components/responses/ApiErrorRateLimit"
          },
          "500": {
            "$ref": "#/components/responses/ApiErrorServer"
          }
        },
        "security": [
          {
            "bearer": []
          },
          {
            "api-key": []
          }
        ],
        "summary": "Listar grupos de agentes del workspace (con miembros)",
        "tags": [
          "Agents"
        ],
        "x-scope": "agents:read"
      },
      "post": {
        "externalDocs": {
          "description": "Guía: Mets y sus herramientas",
          "url": "https://developers.meteor.com.co/guias/mets-y-herramientas.html"
        },
        "operationId": "AgentGroupsController_create",
        "parameters": [],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/CreateAgentGroupDto"
              }
            }
          },
          "required": true
        },
        "responses": {
          "201": {
            "content": {
              "application/json": {
                "schema": {
                  "allOf": [
                    {
                      "$ref": "#/components/schemas/ApiEnvelope"
                    },
                    {
                      "properties": {
                        "data": {
                          "$ref": "#/components/schemas/AgentGroupResponseDto"
                        }
                      },
                      "required": [
                        "data"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": ""
          },
          "400": {
            "$ref": "#/components/responses/ApiErrorInvalidRequest"
          },
          "401": {
            "$ref": "#/components/responses/ApiErrorAuth"
          },
          "403": {
            "$ref": "#/components/responses/ApiErrorForbidden"
          },
          "404": {
            "$ref": "#/components/responses/ApiErrorNotFound"
          },
          "409": {
            "$ref": "#/components/responses/ApiErrorConflict"
          },
          "429": {
            "$ref": "#/components/responses/ApiErrorRateLimit"
          },
          "500": {
            "$ref": "#/components/responses/ApiErrorServer"
          }
        },
        "security": [
          {
            "bearer": []
          },
          {
            "api-key": []
          }
        ],
        "summary": "Crear un grupo de agentes",
        "tags": [
          "Agents"
        ],
        "x-scope": "agents:write"
      }
    },
    "/agent-groups/{id}": {
      "delete": {
        "externalDocs": {
          "description": "Guía: Mets y sus herramientas",
          "url": "https://developers.meteor.com.co/guias/mets-y-herramientas.html"
        },
        "operationId": "AgentGroupsController_remove",
        "parameters": [
          {
            "description": "ID del recurso de esta ruta.",
            "in": "path",
            "name": "id",
            "required": true,
            "schema": {
              "type": "number"
            }
          }
        ],
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "allOf": [
                    {
                      "$ref": "#/components/schemas/ApiEnvelope"
                    },
                    {
                      "properties": {
                        "data": {
                          "$ref": "#/components/schemas/AgentGroupOkResponseDto"
                        }
                      },
                      "required": [
                        "data"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": ""
          },
          "400": {
            "$ref": "#/components/responses/ApiErrorInvalidRequest"
          },
          "401": {
            "$ref": "#/components/responses/ApiErrorAuth"
          },
          "403": {
            "$ref": "#/components/responses/ApiErrorForbidden"
          },
          "404": {
            "$ref": "#/components/responses/ApiErrorNotFound"
          },
          "409": {
            "$ref": "#/components/responses/ApiErrorConflict"
          },
          "429": {
            "$ref": "#/components/responses/ApiErrorRateLimit"
          },
          "500": {
            "$ref": "#/components/responses/ApiErrorServer"
          }
        },
        "security": [
          {
            "bearer": []
          },
          {
            "api-key": []
          }
        ],
        "summary": "Eliminar un grupo de agentes",
        "tags": [
          "Agents"
        ],
        "x-scope": "agents:write"
      },
      "patch": {
        "externalDocs": {
          "description": "Guía: Mets y sus herramientas",
          "url": "https://developers.meteor.com.co/guias/mets-y-herramientas.html"
        },
        "operationId": "AgentGroupsController_rename",
        "parameters": [
          {
            "description": "ID del recurso de esta ruta.",
            "in": "path",
            "name": "id",
            "required": true,
            "schema": {
              "type": "number"
            }
          }
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/UpdateAgentGroupDto"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "allOf": [
                    {
                      "$ref": "#/components/schemas/ApiEnvelope"
                    },
                    {
                      "properties": {
                        "data": {
                          "$ref": "#/components/schemas/AgentGroupResponseDto"
                        }
                      },
                      "required": [
                        "data"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": ""
          },
          "400": {
            "$ref": "#/components/responses/ApiErrorInvalidRequest"
          },
          "401": {
            "$ref": "#/components/responses/ApiErrorAuth"
          },
          "403": {
            "$ref": "#/components/responses/ApiErrorForbidden"
          },
          "404": {
            "$ref": "#/components/responses/ApiErrorNotFound"
          },
          "409": {
            "$ref": "#/components/responses/ApiErrorConflict"
          },
          "429": {
            "$ref": "#/components/responses/ApiErrorRateLimit"
          },
          "500": {
            "$ref": "#/components/responses/ApiErrorServer"
          }
        },
        "security": [
          {
            "bearer": []
          },
          {
            "api-key": []
          }
        ],
        "summary": "Renombrar un grupo de agentes",
        "tags": [
          "Agents"
        ],
        "x-scope": "agents:write"
      }
    },
    "/agent-groups/{id}/members": {
      "get": {
        "externalDocs": {
          "description": "Guía: Mets y sus herramientas",
          "url": "https://developers.meteor.com.co/guias/mets-y-herramientas.html"
        },
        "operationId": "AgentGroupsController_listMembers",
        "parameters": [
          {
            "description": "ID del recurso de esta ruta.",
            "in": "path",
            "name": "id",
            "required": true,
            "schema": {
              "type": "number"
            }
          }
        ],
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "allOf": [
                    {
                      "$ref": "#/components/schemas/ApiEnvelope"
                    },
                    {
                      "properties": {
                        "data": {
                          "items": {
                            "$ref": "#/components/schemas/AgentGroupMemberResponseDto"
                          },
                          "type": "array"
                        }
                      },
                      "required": [
                        "data"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": ""
          },
          "400": {
            "$ref": "#/components/responses/ApiErrorInvalidRequest"
          },
          "401": {
            "$ref": "#/components/responses/ApiErrorAuth"
          },
          "403": {
            "$ref": "#/components/responses/ApiErrorForbidden"
          },
          "404": {
            "$ref": "#/components/responses/ApiErrorNotFound"
          },
          "429": {
            "$ref": "#/components/responses/ApiErrorRateLimit"
          },
          "500": {
            "$ref": "#/components/responses/ApiErrorServer"
          }
        },
        "security": [
          {
            "bearer": []
          },
          {
            "api-key": []
          }
        ],
        "summary": "Listar los miembros de un grupo",
        "tags": [
          "Agents"
        ],
        "x-scope": "agents:read"
      },
      "post": {
        "externalDocs": {
          "description": "Guía: Mets y sus herramientas",
          "url": "https://developers.meteor.com.co/guias/mets-y-herramientas.html"
        },
        "operationId": "AgentGroupsController_addMember",
        "parameters": [
          {
            "description": "ID del recurso de esta ruta.",
            "in": "path",
            "name": "id",
            "required": true,
            "schema": {
              "type": "number"
            }
          }
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/AddAgentGroupMemberDto"
              }
            }
          },
          "required": true
        },
        "responses": {
          "201": {
            "content": {
              "application/json": {
                "schema": {
                  "allOf": [
                    {
                      "$ref": "#/components/schemas/ApiEnvelope"
                    },
                    {
                      "properties": {
                        "data": {
                          "$ref": "#/components/schemas/AgentGroupMemberResponseDto"
                        }
                      },
                      "required": [
                        "data"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": ""
          },
          "400": {
            "$ref": "#/components/responses/ApiErrorInvalidRequest"
          },
          "401": {
            "$ref": "#/components/responses/ApiErrorAuth"
          },
          "403": {
            "$ref": "#/components/responses/ApiErrorForbidden"
          },
          "404": {
            "$ref": "#/components/responses/ApiErrorNotFound"
          },
          "409": {
            "$ref": "#/components/responses/ApiErrorConflict"
          },
          "429": {
            "$ref": "#/components/responses/ApiErrorRateLimit"
          },
          "500": {
            "$ref": "#/components/responses/ApiErrorServer"
          }
        },
        "security": [
          {
            "bearer": []
          },
          {
            "api-key": []
          }
        ],
        "summary": "Agregar un agente al grupo",
        "tags": [
          "Agents"
        ],
        "x-scope": "agents:write"
      }
    },
    "/agent-groups/{id}/members/{userId}": {
      "delete": {
        "externalDocs": {
          "description": "Guía: Mets y sus herramientas",
          "url": "https://developers.meteor.com.co/guias/mets-y-herramientas.html"
        },
        "operationId": "AgentGroupsController_removeMember",
        "parameters": [
          {
            "description": "ID del recurso de esta ruta.",
            "in": "path",
            "name": "id",
            "required": true,
            "schema": {
              "type": "number"
            }
          },
          {
            "description": "ID numérico del usuario.",
            "in": "path",
            "name": "userId",
            "required": true,
            "schema": {
              "type": "number"
            }
          }
        ],
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "allOf": [
                    {
                      "$ref": "#/components/schemas/ApiEnvelope"
                    },
                    {
                      "properties": {
                        "data": {
                          "$ref": "#/components/schemas/AgentGroupOkResponseDto"
                        }
                      },
                      "required": [
                        "data"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": ""
          },
          "400": {
            "$ref": "#/components/responses/ApiErrorInvalidRequest"
          },
          "401": {
            "$ref": "#/components/responses/ApiErrorAuth"
          },
          "403": {
            "$ref": "#/components/responses/ApiErrorForbidden"
          },
          "404": {
            "$ref": "#/components/responses/ApiErrorNotFound"
          },
          "409": {
            "$ref": "#/components/responses/ApiErrorConflict"
          },
          "429": {
            "$ref": "#/components/responses/ApiErrorRateLimit"
          },
          "500": {
            "$ref": "#/components/responses/ApiErrorServer"
          }
        },
        "security": [
          {
            "bearer": []
          },
          {
            "api-key": []
          }
        ],
        "summary": "Quitar un agente del grupo",
        "tags": [
          "Agents"
        ],
        "x-scope": "agents:write"
      }
    },
    "/agents/{id}": {
      "get": {
        "externalDocs": {
          "description": "Guía: Mets y sus herramientas",
          "url": "https://developers.meteor.com.co/guias/mets-y-herramientas.html"
        },
        "operationId": "ApiAgentsController_get",
        "parameters": [
          {
            "description": "ID del recurso de esta ruta.",
            "in": "path",
            "name": "id",
            "required": true,
            "schema": {
              "type": "number"
            }
          }
        ],
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "allOf": [
                    {
                      "$ref": "#/components/schemas/ApiEnvelope"
                    },
                    {
                      "properties": {
                        "data": {
                          "$ref": "#/components/schemas/AgentResponseDto"
                        }
                      },
                      "required": [
                        "data"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": ""
          },
          "400": {
            "$ref": "#/components/responses/ApiErrorInvalidRequest"
          },
          "401": {
            "$ref": "#/components/responses/ApiErrorAuth"
          },
          "403": {
            "$ref": "#/components/responses/ApiErrorForbidden"
          },
          "404": {
            "$ref": "#/components/responses/ApiErrorNotFound"
          },
          "429": {
            "$ref": "#/components/responses/ApiErrorRateLimit"
          },
          "500": {
            "$ref": "#/components/responses/ApiErrorServer"
          }
        },
        "security": [
          {
            "bearer": []
          },
          {
            "api-key": []
          }
        ],
        "summary": "Detalle de un agente",
        "tags": [
          "Agents"
        ],
        "x-scope": "agents:read"
      },
      "patch": {
        "externalDocs": {
          "description": "Guía: Mets y sus herramientas",
          "url": "https://developers.meteor.com.co/guias/mets-y-herramientas.html"
        },
        "operationId": "ApiAgentsController_update",
        "parameters": [
          {
            "description": "ID del recurso de esta ruta.",
            "in": "path",
            "name": "id",
            "required": true,
            "schema": {
              "type": "number"
            }
          }
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/UpdateAgentDto"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "allOf": [
                    {
                      "$ref": "#/components/schemas/ApiEnvelope"
                    },
                    {
                      "properties": {
                        "data": {
                          "$ref": "#/components/schemas/AgentResponseDto"
                        }
                      },
                      "required": [
                        "data"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": ""
          },
          "400": {
            "$ref": "#/components/responses/ApiErrorInvalidRequest"
          },
          "401": {
            "$ref": "#/components/responses/ApiErrorAuth"
          },
          "403": {
            "$ref": "#/components/responses/ApiErrorForbidden"
          },
          "404": {
            "$ref": "#/components/responses/ApiErrorNotFound"
          },
          "409": {
            "$ref": "#/components/responses/ApiErrorConflict"
          },
          "429": {
            "$ref": "#/components/responses/ApiErrorRateLimit"
          },
          "500": {
            "$ref": "#/components/responses/ApiErrorServer"
          }
        },
        "security": [
          {
            "bearer": []
          },
          {
            "api-key": []
          }
        ],
        "summary": "Actualiza un agente (nombre, prompt, misión, estado)",
        "tags": [
          "Agents"
        ],
        "x-scope": "agents:write"
      }
    },
    "/agents/{id}/skills": {
      "get": {
        "externalDocs": {
          "description": "Guía: Mets y sus herramientas",
          "url": "https://developers.meteor.com.co/guias/mets-y-herramientas.html"
        },
        "operationId": "ApiAgentsController_listSkills",
        "parameters": [
          {
            "description": "ID del recurso de esta ruta.",
            "in": "path",
            "name": "id",
            "required": true,
            "schema": {
              "type": "number"
            }
          }
        ],
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "allOf": [
                    {
                      "$ref": "#/components/schemas/ApiEnvelope"
                    },
                    {
                      "properties": {
                        "data": {
                          "items": {
                            "$ref": "#/components/schemas/AgentSkillResponseDto"
                          },
                          "type": "array"
                        }
                      },
                      "required": [
                        "data"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": ""
          },
          "400": {
            "$ref": "#/components/responses/ApiErrorInvalidRequest"
          },
          "401": {
            "$ref": "#/components/responses/ApiErrorAuth"
          },
          "403": {
            "$ref": "#/components/responses/ApiErrorForbidden"
          },
          "404": {
            "$ref": "#/components/responses/ApiErrorNotFound"
          },
          "429": {
            "$ref": "#/components/responses/ApiErrorRateLimit"
          },
          "500": {
            "$ref": "#/components/responses/ApiErrorServer"
          }
        },
        "security": [
          {
            "bearer": []
          },
          {
            "api-key": []
          }
        ],
        "summary": "Skills vinculadas al agente",
        "tags": [
          "Agents"
        ],
        "x-scope": "agents:read"
      }
    },
    "/agents/{id}/skills/{skillId}": {
      "delete": {
        "externalDocs": {
          "description": "Guía: Mets y sus herramientas",
          "url": "https://developers.meteor.com.co/guias/mets-y-herramientas.html"
        },
        "operationId": "ApiAgentsController_unlinkSkill",
        "parameters": [
          {
            "description": "ID del recurso de esta ruta.",
            "in": "path",
            "name": "id",
            "required": true,
            "schema": {
              "type": "number"
            }
          },
          {
            "description": "ID de la skill.",
            "in": "path",
            "name": "skillId",
            "required": true,
            "schema": {
              "type": "number"
            }
          }
        ],
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "allOf": [
                    {
                      "$ref": "#/components/schemas/ApiEnvelope"
                    },
                    {
                      "properties": {
                        "data": {
                          "$ref": "#/components/schemas/AgentSkillLinkResponseDto"
                        }
                      },
                      "required": [
                        "data"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": ""
          },
          "400": {
            "$ref": "#/components/responses/ApiErrorInvalidRequest"
          },
          "401": {
            "$ref": "#/components/responses/ApiErrorAuth"
          },
          "403": {
            "$ref": "#/components/responses/ApiErrorForbidden"
          },
          "404": {
            "$ref": "#/components/responses/ApiErrorNotFound"
          },
          "409": {
            "$ref": "#/components/responses/ApiErrorConflict"
          },
          "429": {
            "$ref": "#/components/responses/ApiErrorRateLimit"
          },
          "500": {
            "$ref": "#/components/responses/ApiErrorServer"
          }
        },
        "security": [
          {
            "bearer": []
          },
          {
            "api-key": []
          }
        ],
        "summary": "Desvincula una skill del agente",
        "tags": [
          "Agents"
        ],
        "x-scope": "agents:write"
      },
      "post": {
        "externalDocs": {
          "description": "Guía: Mets y sus herramientas",
          "url": "https://developers.meteor.com.co/guias/mets-y-herramientas.html"
        },
        "operationId": "ApiAgentsController_linkSkill",
        "parameters": [
          {
            "description": "ID del recurso de esta ruta.",
            "in": "path",
            "name": "id",
            "required": true,
            "schema": {
              "type": "number"
            }
          },
          {
            "description": "ID de la skill.",
            "in": "path",
            "name": "skillId",
            "required": true,
            "schema": {
              "type": "number"
            }
          }
        ],
        "responses": {
          "201": {
            "content": {
              "application/json": {
                "schema": {
                  "allOf": [
                    {
                      "$ref": "#/components/schemas/ApiEnvelope"
                    },
                    {
                      "properties": {
                        "data": {
                          "$ref": "#/components/schemas/AgentSkillLinkResponseDto"
                        }
                      },
                      "required": [
                        "data"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": ""
          },
          "400": {
            "$ref": "#/components/responses/ApiErrorInvalidRequest"
          },
          "401": {
            "$ref": "#/components/responses/ApiErrorAuth"
          },
          "403": {
            "$ref": "#/components/responses/ApiErrorForbidden"
          },
          "404": {
            "$ref": "#/components/responses/ApiErrorNotFound"
          },
          "409": {
            "$ref": "#/components/responses/ApiErrorConflict"
          },
          "429": {
            "$ref": "#/components/responses/ApiErrorRateLimit"
          },
          "500": {
            "$ref": "#/components/responses/ApiErrorServer"
          }
        },
        "security": [
          {
            "bearer": []
          },
          {
            "api-key": []
          }
        ],
        "summary": "Vincula una skill al agente",
        "tags": [
          "Agents"
        ],
        "x-scope": "agents:write"
      }
    },
    "/billing/access": {
      "get": {
        "externalDocs": {
          "description": "Guía: Límites y cuotas",
          "url": "https://developers.meteor.com.co/guias/limites.html"
        },
        "operationId": "BillingController_accessStatus",
        "parameters": [],
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "allOf": [
                    {
                      "$ref": "#/components/schemas/ApiEnvelope"
                    },
                    {
                      "properties": {
                        "data": {
                          "$ref": "#/components/schemas/WorkspaceAccessResponseDto"
                        }
                      },
                      "required": [
                        "data"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": ""
          },
          "400": {
            "$ref": "#/components/responses/ApiErrorInvalidRequest"
          },
          "401": {
            "$ref": "#/components/responses/ApiErrorAuth"
          },
          "403": {
            "$ref": "#/components/responses/ApiErrorForbidden"
          },
          "404": {
            "$ref": "#/components/responses/ApiErrorNotFound"
          },
          "429": {
            "$ref": "#/components/responses/ApiErrorRateLimit"
          },
          "500": {
            "$ref": "#/components/responses/ApiErrorServer"
          }
        },
        "security": [
          {
            "bearer": []
          },
          {
            "api-key": []
          }
        ],
        "summary": "Estado de acceso del workspace (bloqueo/motivo/límites)",
        "tags": [
          "Billing"
        ],
        "x-scope": "billing:read"
      }
    },
    "/billing/addons": {
      "get": {
        "externalDocs": {
          "description": "Guía: Límites y cuotas",
          "url": "https://developers.meteor.com.co/guias/limites.html"
        },
        "operationId": "BillingController_listAddons",
        "parameters": [],
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "allOf": [
                    {
                      "$ref": "#/components/schemas/ApiEnvelope"
                    },
                    {
                      "properties": {
                        "data": {
                          "items": {
                            "$ref": "#/components/schemas/AddonResponseDto"
                          },
                          "type": "array"
                        }
                      },
                      "required": [
                        "data"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": ""
          },
          "400": {
            "$ref": "#/components/responses/ApiErrorInvalidRequest"
          },
          "401": {
            "$ref": "#/components/responses/ApiErrorAuth"
          },
          "403": {
            "$ref": "#/components/responses/ApiErrorForbidden"
          },
          "404": {
            "$ref": "#/components/responses/ApiErrorNotFound"
          },
          "429": {
            "$ref": "#/components/responses/ApiErrorRateLimit"
          },
          "500": {
            "$ref": "#/components/responses/ApiErrorServer"
          }
        },
        "security": [
          {
            "bearer": []
          },
          {
            "api-key": []
          }
        ],
        "summary": "Lista los add-ons disponibles",
        "tags": [
          "Billing"
        ],
        "x-scope": "billing:read"
      }
    },
    "/billing/addons/mine": {
      "get": {
        "externalDocs": {
          "description": "Guía: Límites y cuotas",
          "url": "https://developers.meteor.com.co/guias/limites.html"
        },
        "operationId": "BillingController_myAddons",
        "parameters": [],
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "allOf": [
                    {
                      "$ref": "#/components/schemas/ApiEnvelope"
                    },
                    {
                      "properties": {
                        "data": {
                          "items": {
                            "$ref": "#/components/schemas/WorkspaceAddonWithDetailDto"
                          },
                          "type": "array"
                        }
                      },
                      "required": [
                        "data"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": ""
          },
          "400": {
            "$ref": "#/components/responses/ApiErrorInvalidRequest"
          },
          "401": {
            "$ref": "#/components/responses/ApiErrorAuth"
          },
          "403": {
            "$ref": "#/components/responses/ApiErrorForbidden"
          },
          "404": {
            "$ref": "#/components/responses/ApiErrorNotFound"
          },
          "429": {
            "$ref": "#/components/responses/ApiErrorRateLimit"
          },
          "500": {
            "$ref": "#/components/responses/ApiErrorServer"
          }
        },
        "security": [
          {
            "bearer": []
          },
          {
            "api-key": []
          }
        ],
        "summary": "Lista los add-ons comprados del workspace",
        "tags": [
          "Billing"
        ],
        "x-scope": "billing:read"
      }
    },
    "/billing/auto-recharge": {
      "get": {
        "externalDocs": {
          "description": "Guía: Límites y cuotas",
          "url": "https://developers.meteor.com.co/guias/limites.html"
        },
        "operationId": "BillingController_getAutoRecharge",
        "parameters": [],
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "allOf": [
                    {
                      "$ref": "#/components/schemas/ApiEnvelope"
                    },
                    {
                      "properties": {
                        "data": {
                          "$ref": "#/components/schemas/AutoRechargeConfigResponseDto"
                        }
                      },
                      "required": [
                        "data"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": ""
          },
          "400": {
            "$ref": "#/components/responses/ApiErrorInvalidRequest"
          },
          "401": {
            "$ref": "#/components/responses/ApiErrorAuth"
          },
          "403": {
            "$ref": "#/components/responses/ApiErrorForbidden"
          },
          "404": {
            "$ref": "#/components/responses/ApiErrorNotFound"
          },
          "429": {
            "$ref": "#/components/responses/ApiErrorRateLimit"
          },
          "500": {
            "$ref": "#/components/responses/ApiErrorServer"
          }
        },
        "security": [
          {
            "bearer": []
          },
          {
            "api-key": []
          }
        ],
        "summary": "Configuración de recarga automática del workspace",
        "tags": [
          "Billing"
        ],
        "x-scope": "billing:read"
      }
    },
    "/billing/consumption": {
      "get": {
        "externalDocs": {
          "description": "Guía: Límites y cuotas",
          "url": "https://developers.meteor.com.co/guias/limites.html"
        },
        "operationId": "BillingController_consumption",
        "parameters": [
          {
            "description": "Campo por el que agrupar.",
            "in": "query",
            "name": "by",
            "required": true,
            "schema": {
              "type": "string"
            }
          },
          {
            "description": "Inicio del rango de fechas (ISO 8601, inclusive).",
            "in": "query",
            "name": "from",
            "required": true,
            "schema": {
              "type": "string"
            }
          },
          {
            "description": "Fin del rango de fechas (ISO 8601, inclusive).",
            "in": "query",
            "name": "to",
            "required": true,
            "schema": {
              "type": "string"
            }
          },
          {
            "description": "Cuántos resultados traer por página.",
            "in": "query",
            "name": "limit",
            "required": true,
            "schema": {
              "type": "string"
            }
          }
        ],
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "allOf": [
                    {
                      "$ref": "#/components/schemas/ApiEnvelope"
                    },
                    {
                      "properties": {
                        "data": {
                          "items": {
                            "$ref": "#/components/schemas/ClientConsumptionRowDto"
                          },
                          "type": "array"
                        }
                      },
                      "required": [
                        "data"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": ""
          },
          "400": {
            "$ref": "#/components/responses/ApiErrorInvalidRequest"
          },
          "401": {
            "$ref": "#/components/responses/ApiErrorAuth"
          },
          "403": {
            "$ref": "#/components/responses/ApiErrorForbidden"
          },
          "404": {
            "$ref": "#/components/responses/ApiErrorNotFound"
          },
          "429": {
            "$ref": "#/components/responses/ApiErrorRateLimit"
          },
          "500": {
            "$ref": "#/components/responses/ApiErrorServer"
          }
        },
        "security": [
          {
            "bearer": []
          },
          {
            "api-key": []
          }
        ],
        "summary": "Consumo del cliente agregado por contacto/actor/conversación/met (solo Energía)",
        "tags": [
          "Billing"
        ],
        "x-scope": "billing:read"
      }
    },
    "/billing/executions": {
      "get": {
        "externalDocs": {
          "description": "Guía: Límites y cuotas",
          "url": "https://developers.meteor.com.co/guias/limites.html"
        },
        "operationId": "BillingController_listExecutions",
        "parameters": [
          {
            "description": "Cuántos resultados traer por página.",
            "in": "query",
            "name": "limit",
            "required": true,
            "schema": {
              "type": "string"
            }
          },
          {
            "description": "Cuántos resultados saltear antes de empezar a devolver.",
            "in": "query",
            "name": "offset",
            "required": true,
            "schema": {
              "type": "string"
            }
          },
          {
            "description": "Inicio del rango de fechas (ISO 8601, inclusive).",
            "in": "query",
            "name": "from",
            "required": true,
            "schema": {
              "type": "string"
            }
          },
          {
            "description": "Fin del rango de fechas (ISO 8601, inclusive).",
            "in": "query",
            "name": "to",
            "required": true,
            "schema": {
              "type": "string"
            }
          },
          {
            "description": "Filtra por tipo.",
            "in": "query",
            "name": "type",
            "required": true,
            "schema": {
              "type": "string"
            }
          },
          {
            "description": "Costo mínimo, inclusive.",
            "in": "query",
            "name": "costMin",
            "required": true,
            "schema": {
              "type": "string"
            }
          },
          {
            "description": "Costo máximo, inclusive.",
            "in": "query",
            "name": "costMax",
            "required": true,
            "schema": {
              "type": "string"
            }
          }
        ],
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "allOf": [
                    {
                      "$ref": "#/components/schemas/ApiEnvelope"
                    },
                    {
                      "properties": {
                        "data": {
                          "$ref": "#/components/schemas/ClientExecutionsPageDto"
                        }
                      },
                      "required": [
                        "data"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": ""
          },
          "400": {
            "$ref": "#/components/responses/ApiErrorInvalidRequest"
          },
          "401": {
            "$ref": "#/components/responses/ApiErrorAuth"
          },
          "403": {
            "$ref": "#/components/responses/ApiErrorForbidden"
          },
          "404": {
            "$ref": "#/components/responses/ApiErrorNotFound"
          },
          "429": {
            "$ref": "#/components/responses/ApiErrorRateLimit"
          },
          "500": {
            "$ref": "#/components/responses/ApiErrorServer"
          }
        },
        "security": [
          {
            "bearer": []
          },
          {
            "api-key": []
          }
        ],
        "summary": "Lista las ejecuciones de IA del workspace",
        "tags": [
          "Billing"
        ],
        "x-scope": "billing:read"
      }
    },
    "/billing/invoices": {
      "get": {
        "externalDocs": {
          "description": "Guía: Límites y cuotas",
          "url": "https://developers.meteor.com.co/guias/limites.html"
        },
        "operationId": "BillingController_listInvoices",
        "parameters": [],
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "allOf": [
                    {
                      "$ref": "#/components/schemas/ApiEnvelope"
                    },
                    {
                      "properties": {
                        "data": {
                          "items": {
                            "$ref": "#/components/schemas/InvoiceResponseDto"
                          },
                          "type": "array"
                        }
                      },
                      "required": [
                        "data"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": ""
          },
          "400": {
            "$ref": "#/components/responses/ApiErrorInvalidRequest"
          },
          "401": {
            "$ref": "#/components/responses/ApiErrorAuth"
          },
          "403": {
            "$ref": "#/components/responses/ApiErrorForbidden"
          },
          "404": {
            "$ref": "#/components/responses/ApiErrorNotFound"
          },
          "429": {
            "$ref": "#/components/responses/ApiErrorRateLimit"
          },
          "500": {
            "$ref": "#/components/responses/ApiErrorServer"
          }
        },
        "security": [
          {
            "bearer": []
          },
          {
            "api-key": []
          }
        ],
        "summary": "Lista las facturas de Stripe del workspace",
        "tags": [
          "Billing"
        ],
        "x-scope": "billing:read"
      }
    },
    "/billing/plans": {
      "get": {
        "externalDocs": {
          "description": "Guía: Límites y cuotas",
          "url": "https://developers.meteor.com.co/guias/limites.html"
        },
        "operationId": "BillingController_listPlans",
        "parameters": [],
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "allOf": [
                    {
                      "$ref": "#/components/schemas/ApiEnvelope"
                    },
                    {
                      "properties": {
                        "data": {
                          "items": {
                            "$ref": "#/components/schemas/PlanWithFeaturesDto"
                          },
                          "type": "array"
                        }
                      },
                      "required": [
                        "data"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": ""
          },
          "400": {
            "$ref": "#/components/responses/ApiErrorInvalidRequest"
          },
          "401": {
            "$ref": "#/components/responses/ApiErrorAuth"
          },
          "403": {
            "$ref": "#/components/responses/ApiErrorForbidden"
          },
          "404": {
            "$ref": "#/components/responses/ApiErrorNotFound"
          },
          "429": {
            "$ref": "#/components/responses/ApiErrorRateLimit"
          },
          "500": {
            "$ref": "#/components/responses/ApiErrorServer"
          }
        },
        "security": [
          {
            "bearer": []
          },
          {
            "api-key": []
          }
        ],
        "summary": "Lista pública de planes activos (para la página de precios)",
        "tags": [
          "Billing"
        ],
        "x-scope": "billing:read"
      }
    },
    "/billing/subscription": {
      "get": {
        "externalDocs": {
          "description": "Guía: Límites y cuotas",
          "url": "https://developers.meteor.com.co/guias/limites.html"
        },
        "operationId": "BillingController_currentSubscription",
        "parameters": [],
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "allOf": [
                    {
                      "$ref": "#/components/schemas/ApiEnvelope"
                    },
                    {
                      "properties": {
                        "data": {
                          "$ref": "#/components/schemas/CurrentSubscriptionResponseDto"
                        }
                      },
                      "required": [
                        "data"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": ""
          },
          "400": {
            "$ref": "#/components/responses/ApiErrorInvalidRequest"
          },
          "401": {
            "$ref": "#/components/responses/ApiErrorAuth"
          },
          "403": {
            "$ref": "#/components/responses/ApiErrorForbidden"
          },
          "404": {
            "$ref": "#/components/responses/ApiErrorNotFound"
          },
          "429": {
            "$ref": "#/components/responses/ApiErrorRateLimit"
          },
          "500": {
            "$ref": "#/components/responses/ApiErrorServer"
          }
        },
        "security": [
          {
            "bearer": []
          },
          {
            "api-key": []
          }
        ],
        "summary": "Suscripción y plan actual del workspace",
        "tags": [
          "Billing"
        ],
        "x-scope": "billing:read"
      }
    },
    "/billing/transactions": {
      "get": {
        "externalDocs": {
          "description": "Guía: Límites y cuotas",
          "url": "https://developers.meteor.com.co/guias/limites.html"
        },
        "operationId": "BillingController_listTransactions",
        "parameters": [
          {
            "description": "Cuántos resultados traer por página.",
            "in": "query",
            "name": "limit",
            "required": true,
            "schema": {
              "type": "string"
            }
          },
          {
            "description": "Cuántos resultados saltear antes de empezar a devolver.",
            "in": "query",
            "name": "offset",
            "required": true,
            "schema": {
              "type": "string"
            }
          },
          {
            "description": "Filtra por tipo.",
            "in": "query",
            "name": "type",
            "required": true,
            "schema": {
              "type": "string"
            }
          }
        ],
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "allOf": [
                    {
                      "$ref": "#/components/schemas/ApiEnvelope"
                    },
                    {
                      "properties": {
                        "data": {
                          "items": {
                            "$ref": "#/components/schemas/BalanceTransactionResponseDto"
                          },
                          "type": "array"
                        }
                      },
                      "required": [
                        "data"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": ""
          },
          "400": {
            "$ref": "#/components/responses/ApiErrorInvalidRequest"
          },
          "401": {
            "$ref": "#/components/responses/ApiErrorAuth"
          },
          "403": {
            "$ref": "#/components/responses/ApiErrorForbidden"
          },
          "404": {
            "$ref": "#/components/responses/ApiErrorNotFound"
          },
          "429": {
            "$ref": "#/components/responses/ApiErrorRateLimit"
          },
          "500": {
            "$ref": "#/components/responses/ApiErrorServer"
          }
        },
        "security": [
          {
            "bearer": []
          },
          {
            "api-key": []
          }
        ],
        "summary": "Lista los movimientos de saldo del workspace",
        "tags": [
          "Billing"
        ],
        "x-scope": "billing:read"
      }
    },
    "/channels/{channelId}/whatsapp/send-buttons": {
      "post": {
        "externalDocs": {
          "description": "Guía: CRM y contactos",
          "url": "https://developers.meteor.com.co/guias/contactos.html"
        },
        "operationId": "ChannelsController_sendWhatsappButtons",
        "parameters": [
          {
            "description": "ID del canal conectado.",
            "in": "path",
            "name": "channelId",
            "required": true,
            "schema": {
              "type": "string"
            }
          }
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/SendWhatsappButtonsDto"
              }
            }
          },
          "required": true
        },
        "responses": {
          "201": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/WhatsappSendResponseDto"
                }
              }
            },
            "description": ""
          },
          "400": {
            "$ref": "#/components/responses/ApiErrorInvalidRequest"
          },
          "401": {
            "$ref": "#/components/responses/ApiErrorAuth"
          },
          "403": {
            "$ref": "#/components/responses/ApiErrorForbidden"
          },
          "404": {
            "$ref": "#/components/responses/ApiErrorNotFound"
          },
          "409": {
            "$ref": "#/components/responses/ApiErrorConflict"
          },
          "429": {
            "$ref": "#/components/responses/ApiErrorRateLimit"
          },
          "500": {
            "$ref": "#/components/responses/ApiErrorServer"
          }
        },
        "security": [
          {
            "bearer": []
          },
          {
            "api-key": []
          }
        ],
        "summary": "Enviar mensaje interactivo con botones rápidos (máx 3)",
        "tags": [
          "Channels"
        ],
        "x-scope": "channels:send"
      }
    },
    "/channels/{channelId}/whatsapp/send-contact": {
      "post": {
        "externalDocs": {
          "description": "Guía: CRM y contactos",
          "url": "https://developers.meteor.com.co/guias/contactos.html"
        },
        "operationId": "ChannelsController_sendWhatsappContact",
        "parameters": [
          {
            "description": "ID del canal conectado.",
            "in": "path",
            "name": "channelId",
            "required": true,
            "schema": {
              "type": "string"
            }
          }
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/SendWhatsappContactDto"
              }
            }
          },
          "required": true
        },
        "responses": {
          "201": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/WhatsappSendResponseDto"
                }
              }
            },
            "description": ""
          },
          "400": {
            "$ref": "#/components/responses/ApiErrorInvalidRequest"
          },
          "401": {
            "$ref": "#/components/responses/ApiErrorAuth"
          },
          "403": {
            "$ref": "#/components/responses/ApiErrorForbidden"
          },
          "404": {
            "$ref": "#/components/responses/ApiErrorNotFound"
          },
          "409": {
            "$ref": "#/components/responses/ApiErrorConflict"
          },
          "429": {
            "$ref": "#/components/responses/ApiErrorRateLimit"
          },
          "500": {
            "$ref": "#/components/responses/ApiErrorServer"
          }
        },
        "security": [
          {
            "bearer": []
          },
          {
            "api-key": []
          }
        ],
        "summary": "Compartir un contacto (vCard) por WhatsApp",
        "tags": [
          "Channels"
        ],
        "x-scope": "channels:send"
      }
    },
    "/channels/{channelId}/whatsapp/send-list": {
      "post": {
        "externalDocs": {
          "description": "Guía: CRM y contactos",
          "url": "https://developers.meteor.com.co/guias/contactos.html"
        },
        "operationId": "ChannelsController_sendWhatsappList",
        "parameters": [
          {
            "description": "ID del canal conectado.",
            "in": "path",
            "name": "channelId",
            "required": true,
            "schema": {
              "type": "string"
            }
          }
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/SendWhatsappListDto"
              }
            }
          },
          "required": true
        },
        "responses": {
          "201": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/WhatsappSendResponseDto"
                }
              }
            },
            "description": ""
          },
          "400": {
            "$ref": "#/components/responses/ApiErrorInvalidRequest"
          },
          "401": {
            "$ref": "#/components/responses/ApiErrorAuth"
          },
          "403": {
            "$ref": "#/components/responses/ApiErrorForbidden"
          },
          "404": {
            "$ref": "#/components/responses/ApiErrorNotFound"
          },
          "409": {
            "$ref": "#/components/responses/ApiErrorConflict"
          },
          "429": {
            "$ref": "#/components/responses/ApiErrorRateLimit"
          },
          "500": {
            "$ref": "#/components/responses/ApiErrorServer"
          }
        },
        "security": [
          {
            "bearer": []
          },
          {
            "api-key": []
          }
        ],
        "summary": "Enviar mensaje interactivo tipo lista (menú con secciones)",
        "tags": [
          "Channels"
        ],
        "x-scope": "channels:send"
      }
    },
    "/channels/{channelId}/whatsapp/send-location": {
      "post": {
        "externalDocs": {
          "description": "Guía: CRM y contactos",
          "url": "https://developers.meteor.com.co/guias/contactos.html"
        },
        "operationId": "ChannelsController_sendWhatsappLocation",
        "parameters": [
          {
            "description": "ID del canal conectado.",
            "in": "path",
            "name": "channelId",
            "required": true,
            "schema": {
              "type": "string"
            }
          }
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/SendWhatsappLocationDto"
              }
            }
          },
          "required": true
        },
        "responses": {
          "201": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/WhatsappSendResponseDto"
                }
              }
            },
            "description": ""
          },
          "400": {
            "$ref": "#/components/responses/ApiErrorInvalidRequest"
          },
          "401": {
            "$ref": "#/components/responses/ApiErrorAuth"
          },
          "403": {
            "$ref": "#/components/responses/ApiErrorForbidden"
          },
          "404": {
            "$ref": "#/components/responses/ApiErrorNotFound"
          },
          "409": {
            "$ref": "#/components/responses/ApiErrorConflict"
          },
          "429": {
            "$ref": "#/components/responses/ApiErrorRateLimit"
          },
          "500": {
            "$ref": "#/components/responses/ApiErrorServer"
          }
        },
        "security": [
          {
            "bearer": []
          },
          {
            "api-key": []
          }
        ],
        "summary": "Enviar ubicación (coordenadas) por WhatsApp",
        "tags": [
          "Channels"
        ],
        "x-scope": "channels:send"
      }
    },
    "/channels/{channelId}/whatsapp/send-reaction": {
      "post": {
        "externalDocs": {
          "description": "Guía: CRM y contactos",
          "url": "https://developers.meteor.com.co/guias/contactos.html"
        },
        "operationId": "ChannelsController_sendWhatsappReaction",
        "parameters": [
          {
            "description": "ID del canal conectado.",
            "in": "path",
            "name": "channelId",
            "required": true,
            "schema": {
              "type": "string"
            }
          }
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/SendWhatsappReactionDto"
              }
            }
          },
          "required": true
        },
        "responses": {
          "201": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/WhatsappSendResponseDto"
                }
              }
            },
            "description": ""
          },
          "400": {
            "$ref": "#/components/responses/ApiErrorInvalidRequest"
          },
          "401": {
            "$ref": "#/components/responses/ApiErrorAuth"
          },
          "403": {
            "$ref": "#/components/responses/ApiErrorForbidden"
          },
          "404": {
            "$ref": "#/components/responses/ApiErrorNotFound"
          },
          "409": {
            "$ref": "#/components/responses/ApiErrorConflict"
          },
          "429": {
            "$ref": "#/components/responses/ApiErrorRateLimit"
          },
          "500": {
            "$ref": "#/components/responses/ApiErrorServer"
          }
        },
        "security": [
          {
            "bearer": []
          },
          {
            "api-key": []
          }
        ],
        "summary": "Reaccionar a un mensaje WhatsApp con un emoji",
        "tags": [
          "Channels"
        ],
        "x-scope": "channels:send"
      }
    },
    "/channels/{channelId}/whatsapp/send-reply": {
      "post": {
        "externalDocs": {
          "description": "Guía: CRM y contactos",
          "url": "https://developers.meteor.com.co/guias/contactos.html"
        },
        "operationId": "ChannelsController_sendWhatsappReply",
        "parameters": [
          {
            "description": "ID del canal conectado.",
            "in": "path",
            "name": "channelId",
            "required": true,
            "schema": {
              "type": "string"
            }
          }
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/SendWhatsappReplyDto"
              }
            }
          },
          "required": true
        },
        "responses": {
          "201": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/WhatsappSendResponseDto"
                }
              }
            },
            "description": ""
          },
          "400": {
            "$ref": "#/components/responses/ApiErrorInvalidRequest"
          },
          "401": {
            "$ref": "#/components/responses/ApiErrorAuth"
          },
          "403": {
            "$ref": "#/components/responses/ApiErrorForbidden"
          },
          "404": {
            "$ref": "#/components/responses/ApiErrorNotFound"
          },
          "409": {
            "$ref": "#/components/responses/ApiErrorConflict"
          },
          "429": {
            "$ref": "#/components/responses/ApiErrorRateLimit"
          },
          "500": {
            "$ref": "#/components/responses/ApiErrorServer"
          }
        },
        "security": [
          {
            "bearer": []
          },
          {
            "api-key": []
          }
        ],
        "summary": "Responder a un mensaje WhatsApp con quote bubble",
        "tags": [
          "Channels"
        ],
        "x-scope": "channels:send"
      }
    },
    "/channels/{channelId}/whatsapp/send-template": {
      "post": {
        "externalDocs": {
          "description": "Guía: CRM y contactos",
          "url": "https://developers.meteor.com.co/guias/contactos.html"
        },
        "operationId": "ChannelsController_sendWhatsappTemplate",
        "parameters": [
          {
            "description": "ID del canal conectado.",
            "in": "path",
            "name": "channelId",
            "required": true,
            "schema": {
              "type": "string"
            }
          },
          {
            "description": "En `true` valida y devuelve el resultado sin escribir nada.",
            "in": "query",
            "name": "dry_run",
            "required": true,
            "schema": {
              "type": "string"
            }
          }
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/SendWhatsappTemplateDto"
              }
            }
          },
          "required": true
        },
        "responses": {
          "201": {
            "content": {
              "application/json": {
                "schema": {
                  "allOf": [
                    {
                      "$ref": "#/components/schemas/ApiEnvelope"
                    },
                    {
                      "properties": {
                        "data": {
                          "oneOf": [
                            {
                              "$ref": "#/components/schemas/WhatsappSendResponseDto"
                            },
                            {
                              "$ref": "#/components/schemas/WhatsappTemplateDryRunResponseDto"
                            }
                          ]
                        }
                      },
                      "required": [
                        "data"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Envío real: `{success, wa_message_id}`. Con `?dry_run=true`: `{dry_run, would_send}` con la plantilla resuelta y sin enviar nada."
          },
          "400": {
            "$ref": "#/components/responses/ApiErrorInvalidRequest"
          },
          "401": {
            "$ref": "#/components/responses/ApiErrorAuth"
          },
          "403": {
            "$ref": "#/components/responses/ApiErrorForbidden"
          },
          "404": {
            "$ref": "#/components/responses/ApiErrorNotFound"
          },
          "409": {
            "$ref": "#/components/responses/ApiErrorConflict"
          },
          "429": {
            "$ref": "#/components/responses/ApiErrorRateLimit"
          },
          "500": {
            "$ref": "#/components/responses/ApiErrorServer"
          }
        },
        "security": [
          {
            "bearer": []
          },
          {
            "api-key": []
          }
        ],
        "summary": "Enviar una plantilla HSM aprobada por WhatsApp. Con ?dry_run=true valida la plantilla y devuelve el mensaje resuelto sin enviarlo.",
        "tags": [
          "Channels"
        ],
        "x-scope": "channels:send"
      }
    },
    "/collection-views/{viewId}": {
      "delete": {
        "externalDocs": {
          "description": "Guía: Datos: colecciones e ítems",
          "url": "https://developers.meteor.com.co/guias/colecciones-e-items.html"
        },
        "operationId": "CollectionsController_removeView",
        "parameters": [
          {
            "description": "ID de la vista guardada.",
            "in": "path",
            "name": "viewId",
            "required": true,
            "schema": {
              "type": "number"
            }
          }
        ],
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "allOf": [
                    {
                      "$ref": "#/components/schemas/ApiEnvelope"
                    },
                    {
                      "properties": {
                        "data": {
                          "$ref": "#/components/schemas/CollectionMessageResponseDto"
                        }
                      },
                      "required": [
                        "data"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": ""
          },
          "400": {
            "$ref": "#/components/responses/ApiErrorInvalidRequest"
          },
          "401": {
            "$ref": "#/components/responses/ApiErrorAuth"
          },
          "403": {
            "$ref": "#/components/responses/ApiErrorForbidden"
          },
          "404": {
            "$ref": "#/components/responses/ApiErrorNotFound"
          },
          "409": {
            "$ref": "#/components/responses/ApiErrorConflict"
          },
          "429": {
            "$ref": "#/components/responses/ApiErrorRateLimit"
          },
          "500": {
            "$ref": "#/components/responses/ApiErrorServer"
          }
        },
        "security": [
          {
            "bearer": []
          },
          {
            "api-key": []
          }
        ],
        "summary": "Elimina una vista guardada",
        "tags": [
          "Collections"
        ],
        "x-scope": "collections:write"
      },
      "patch": {
        "externalDocs": {
          "description": "Guía: Datos: colecciones e ítems",
          "url": "https://developers.meteor.com.co/guias/colecciones-e-items.html"
        },
        "operationId": "CollectionsController_updateView",
        "parameters": [
          {
            "description": "ID de la vista guardada.",
            "in": "path",
            "name": "viewId",
            "required": true,
            "schema": {
              "type": "number"
            }
          }
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/UpdateViewDto"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "allOf": [
                    {
                      "$ref": "#/components/schemas/ApiEnvelope"
                    },
                    {
                      "properties": {
                        "data": {
                          "$ref": "#/components/schemas/CollectionViewResponseDto"
                        }
                      },
                      "required": [
                        "data"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": ""
          },
          "400": {
            "$ref": "#/components/responses/ApiErrorInvalidRequest"
          },
          "401": {
            "$ref": "#/components/responses/ApiErrorAuth"
          },
          "403": {
            "$ref": "#/components/responses/ApiErrorForbidden"
          },
          "404": {
            "$ref": "#/components/responses/ApiErrorNotFound"
          },
          "409": {
            "$ref": "#/components/responses/ApiErrorConflict"
          },
          "429": {
            "$ref": "#/components/responses/ApiErrorRateLimit"
          },
          "500": {
            "$ref": "#/components/responses/ApiErrorServer"
          }
        },
        "security": [
          {
            "bearer": []
          },
          {
            "api-key": []
          }
        ],
        "summary": "Actualiza una vista guardada",
        "tags": [
          "Collections"
        ],
        "x-scope": "collections:write"
      }
    },
    "/collections": {
      "post": {
        "externalDocs": {
          "description": "Guía: Datos: colecciones e ítems",
          "url": "https://developers.meteor.com.co/guias/colecciones-e-items.html"
        },
        "operationId": "CollectionsController_create",
        "parameters": [],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/CreateCollectionDto"
              }
            }
          },
          "required": true
        },
        "responses": {
          "201": {
            "content": {
              "application/json": {
                "schema": {
                  "allOf": [
                    {
                      "$ref": "#/components/schemas/ApiEnvelope"
                    },
                    {
                      "properties": {
                        "data": {
                          "$ref": "#/components/schemas/CollectionResponseDto"
                        }
                      },
                      "required": [
                        "data"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": ""
          },
          "400": {
            "$ref": "#/components/responses/ApiErrorInvalidRequest"
          },
          "401": {
            "$ref": "#/components/responses/ApiErrorAuth"
          },
          "403": {
            "$ref": "#/components/responses/ApiErrorForbidden"
          },
          "404": {
            "$ref": "#/components/responses/ApiErrorNotFound"
          },
          "409": {
            "$ref": "#/components/responses/ApiErrorConflict"
          },
          "429": {
            "$ref": "#/components/responses/ApiErrorRateLimit"
          },
          "500": {
            "$ref": "#/components/responses/ApiErrorServer"
          }
        },
        "security": [
          {
            "bearer": []
          },
          {
            "api-key": []
          }
        ],
        "summary": "Crea una colección",
        "tags": [
          "Collections"
        ],
        "x-scope": "collections:write"
      }
    },
    "/collections/{collectionId}/fields": {
      "post": {
        "externalDocs": {
          "description": "Guía: Datos: colecciones e ítems",
          "url": "https://developers.meteor.com.co/guias/colecciones-e-items.html"
        },
        "operationId": "CollectionsController_addField",
        "parameters": [
          {
            "description": "ID numérico de la colección.",
            "in": "path",
            "name": "collectionId",
            "required": true,
            "schema": {
              "type": "number"
            }
          }
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/CreateFieldDto"
              }
            }
          },
          "required": true
        },
        "responses": {
          "201": {
            "content": {
              "application/json": {
                "schema": {
                  "allOf": [
                    {
                      "$ref": "#/components/schemas/ApiEnvelope"
                    },
                    {
                      "properties": {
                        "data": {
                          "$ref": "#/components/schemas/CollectionFieldResponseDto"
                        }
                      },
                      "required": [
                        "data"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": ""
          },
          "400": {
            "$ref": "#/components/responses/ApiErrorInvalidRequest"
          },
          "401": {
            "$ref": "#/components/responses/ApiErrorAuth"
          },
          "403": {
            "$ref": "#/components/responses/ApiErrorForbidden"
          },
          "404": {
            "$ref": "#/components/responses/ApiErrorNotFound"
          },
          "409": {
            "$ref": "#/components/responses/ApiErrorConflict"
          },
          "429": {
            "$ref": "#/components/responses/ApiErrorRateLimit"
          },
          "500": {
            "$ref": "#/components/responses/ApiErrorServer"
          }
        },
        "security": [
          {
            "bearer": []
          },
          {
            "api-key": []
          }
        ],
        "summary": "Agrega un campo a la colección",
        "tags": [
          "Collections"
        ],
        "x-scope": "collections:write"
      }
    },
    "/collections/{collectionId}/items": {
      "get": {
        "externalDocs": {
          "description": "Guía: Datos: colecciones e ítems",
          "url": "https://developers.meteor.com.co/guias/colecciones-e-items.html"
        },
        "operationId": "ItemsController_findAll",
        "parameters": [
          {
            "description": "ID numérico de la colección.",
            "in": "path",
            "name": "collectionId",
            "required": true,
            "schema": {
              "type": "number"
            }
          },
          {
            "description": "Número de página, empezando en 1.",
            "in": "query",
            "name": "page",
            "required": true,
            "schema": {
              "type": "number"
            }
          },
          {
            "description": "Cuántos resultados traer por página.",
            "in": "query",
            "name": "limit",
            "required": true,
            "schema": {
              "type": "number"
            }
          },
          {
            "description": "Campo por el que ordenar. Prefija con `-` para orden descendente.",
            "in": "query",
            "name": "sort",
            "required": true,
            "schema": {
              "type": "string"
            }
          },
          {
            "description": "Cursor: devuelve lo que sigue a este ID.",
            "in": "query",
            "name": "after",
            "required": true,
            "schema": {
              "type": "string"
            }
          }
        ],
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "allOf": [
                    {
                      "$ref": "#/components/schemas/ApiEnvelope"
                    },
                    {
                      "properties": {
                        "data": {
                          "$ref": "#/components/schemas/ItemResponseDto"
                        }
                      },
                      "required": [
                        "data"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": ""
          },
          "400": {
            "$ref": "#/components/responses/ApiErrorInvalidRequest"
          },
          "401": {
            "$ref": "#/components/responses/ApiErrorAuth"
          },
          "403": {
            "$ref": "#/components/responses/ApiErrorForbidden"
          },
          "404": {
            "$ref": "#/components/responses/ApiErrorNotFound"
          },
          "429": {
            "$ref": "#/components/responses/ApiErrorRateLimit"
          },
          "500": {
            "$ref": "#/components/responses/ApiErrorServer"
          }
        },
        "security": [
          {
            "bearer": []
          },
          {
            "api-key": []
          }
        ],
        "summary": "Lista los items de una colección (paginado). Admite filtrado del lado del servidor con filter[field]=value (o filter[field][op]=value; op ∈ eq,neq,gt,gte,lt,lte,like,ilike,in) y sort=-updated_at,field.",
        "tags": [
          "Items"
        ],
        "x-scope": "items:read"
      },
      "post": {
        "externalDocs": {
          "description": "Guía: Datos: colecciones e ítems",
          "url": "https://developers.meteor.com.co/guias/colecciones-e-items.html"
        },
        "operationId": "ItemsController_create",
        "parameters": [
          {
            "description": "ID numérico de la colección.",
            "in": "path",
            "name": "collectionId",
            "required": true,
            "schema": {
              "type": "number"
            }
          },
          {
            "description": "Identificador de tu cliente, como cabecera `X-Client-Id`. Opcional, y solo sirve si además escuchas los eventos en tiempo real: el valor que mandes viaja de vuelta en el evento `item:*` que genera esta operación, para que puedas ignorar el eco de tu propio cambio y no pisar lo que ya pintaste. Si no escuchas realtime, no hace nada.",
            "in": "header",
            "name": "x-client-id",
            "required": true,
            "schema": {
              "type": "string"
            }
          }
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/CreateItemDto"
              }
            }
          },
          "required": true
        },
        "responses": {
          "201": {
            "content": {
              "application/json": {
                "schema": {
                  "allOf": [
                    {
                      "$ref": "#/components/schemas/ApiEnvelope"
                    },
                    {
                      "properties": {
                        "data": {
                          "$ref": "#/components/schemas/ItemResponseDto"
                        }
                      },
                      "required": [
                        "data"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": ""
          },
          "400": {
            "$ref": "#/components/responses/ApiErrorInvalidRequest"
          },
          "401": {
            "$ref": "#/components/responses/ApiErrorAuth"
          },
          "403": {
            "$ref": "#/components/responses/ApiErrorForbidden"
          },
          "404": {
            "$ref": "#/components/responses/ApiErrorNotFound"
          },
          "409": {
            "$ref": "#/components/responses/ApiErrorConflict"
          },
          "429": {
            "$ref": "#/components/responses/ApiErrorRateLimit"
          },
          "500": {
            "$ref": "#/components/responses/ApiErrorServer"
          }
        },
        "security": [
          {
            "bearer": []
          },
          {
            "api-key": []
          }
        ],
        "summary": "Crea un item en la colección",
        "tags": [
          "Items"
        ],
        "x-scope": "items:write"
      }
    },
    "/collections/{collectionId}/items/by-slug/{slug}": {
      "get": {
        "externalDocs": {
          "description": "Guía: Datos: colecciones e ítems",
          "url": "https://developers.meteor.com.co/guias/colecciones-e-items.html"
        },
        "operationId": "SlugsController_resolveItemBySlug",
        "parameters": [
          {
            "description": "ID numérico de la colección.",
            "in": "path",
            "name": "collectionId",
            "required": true,
            "schema": {
              "type": "number"
            }
          },
          {
            "description": "Identificador legible del recurso (en minúsculas y con guiones).",
            "in": "path",
            "name": "slug",
            "required": true,
            "schema": {
              "type": "string"
            }
          }
        ],
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "allOf": [
                    {
                      "$ref": "#/components/schemas/ApiEnvelope"
                    },
                    {
                      "properties": {
                        "data": {
                          "additionalProperties": true,
                          "allOf": [
                            {
                              "$ref": "#/components/schemas/ResolvedItemDto"
                            }
                          ]
                        }
                      },
                      "required": [
                        "data"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "El item completo. Los campos dentro de `data` son los que definió su colección, así que cambian de una colección a otra."
          },
          "400": {
            "$ref": "#/components/responses/ApiErrorInvalidRequest"
          },
          "401": {
            "$ref": "#/components/responses/ApiErrorAuth"
          },
          "403": {
            "$ref": "#/components/responses/ApiErrorForbidden"
          },
          "404": {
            "$ref": "#/components/responses/ApiErrorNotFound"
          },
          "429": {
            "$ref": "#/components/responses/ApiErrorRateLimit"
          },
          "500": {
            "$ref": "#/components/responses/ApiErrorServer"
          }
        },
        "security": [
          {
            "bearer": []
          },
          {
            "api-key": []
          }
        ],
        "summary": "Resuelve un item por slug",
        "tags": [
          "Collections"
        ],
        "x-scope": "collections:read"
      }
    },
    "/collections/{collectionId}/items/import": {
      "post": {
        "externalDocs": {
          "description": "Guía: Datos: colecciones e ítems",
          "url": "https://developers.meteor.com.co/guias/colecciones-e-items.html"
        },
        "operationId": "ItemsController_import",
        "parameters": [
          {
            "description": "ID numérico de la colección.",
            "in": "path",
            "name": "collectionId",
            "required": true,
            "schema": {
              "type": "number"
            }
          }
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/ImportItemsDto"
              }
            }
          },
          "required": true
        },
        "responses": {
          "201": {
            "content": {
              "application/json": {
                "schema": {
                  "allOf": [
                    {
                      "$ref": "#/components/schemas/ApiEnvelope"
                    },
                    {
                      "properties": {
                        "data": {
                          "$ref": "#/components/schemas/ItemImportResultDto"
                        }
                      },
                      "required": [
                        "data"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": ""
          },
          "400": {
            "$ref": "#/components/responses/ApiErrorInvalidRequest"
          },
          "401": {
            "$ref": "#/components/responses/ApiErrorAuth"
          },
          "403": {
            "$ref": "#/components/responses/ApiErrorForbidden"
          },
          "404": {
            "$ref": "#/components/responses/ApiErrorNotFound"
          },
          "409": {
            "$ref": "#/components/responses/ApiErrorConflict"
          },
          "429": {
            "$ref": "#/components/responses/ApiErrorRateLimit"
          },
          "500": {
            "$ref": "#/components/responses/ApiErrorServer"
          }
        },
        "security": [
          {
            "bearer": []
          },
          {
            "api-key": []
          }
        ],
        "summary": "Importar items. Con keyField: upsert (crea/actualiza por esa clave). Sin keyField: insert-only (inserta todas las filas sin deduplicar).",
        "tags": [
          "Items"
        ],
        "x-scope": "items:write"
      }
    },
    "/collections/{collectionId}/items/{id}": {
      "patch": {
        "externalDocs": {
          "description": "Guía: Datos: colecciones e ítems",
          "url": "https://developers.meteor.com.co/guias/colecciones-e-items.html"
        },
        "operationId": "ItemsController_patchMerge",
        "parameters": [
          {
            "description": "ID del recurso de esta ruta.",
            "in": "path",
            "name": "id",
            "required": true,
            "schema": {
              "type": "number"
            }
          },
          {
            "description": "Identificador de tu cliente, como cabecera `X-Client-Id`. Opcional, y solo sirve si además escuchas los eventos en tiempo real: el valor que mandes viaja de vuelta en el evento `item:*` que genera esta operación, para que puedas ignorar el eco de tu propio cambio y no pisar lo que ya pintaste. Si no escuchas realtime, no hace nada.",
            "in": "header",
            "name": "x-client-id",
            "required": true,
            "schema": {
              "type": "string"
            }
          }
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/PatchItemDto"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "allOf": [
                    {
                      "$ref": "#/components/schemas/ApiEnvelope"
                    },
                    {
                      "properties": {
                        "data": {
                          "$ref": "#/components/schemas/ItemResponseDto"
                        }
                      },
                      "required": [
                        "data"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": ""
          },
          "400": {
            "$ref": "#/components/responses/ApiErrorInvalidRequest"
          },
          "401": {
            "$ref": "#/components/responses/ApiErrorAuth"
          },
          "403": {
            "$ref": "#/components/responses/ApiErrorForbidden"
          },
          "404": {
            "$ref": "#/components/responses/ApiErrorNotFound"
          },
          "409": {
            "$ref": "#/components/responses/ApiErrorConflict"
          },
          "429": {
            "$ref": "#/components/responses/ApiErrorRateLimit"
          },
          "500": {
            "$ref": "#/components/responses/ApiErrorServer"
          }
        },
        "security": [
          {
            "bearer": []
          },
          {
            "api-key": []
          }
        ],
        "summary": "Actualiza parcialmente un item — fusiona las claves de `data` con las existentes (no reemplaza el objeto completo).",
        "tags": [
          "Items"
        ],
        "x-scope": "items:write",
        "x-since": "1.1.0"
      },
      "put": {
        "externalDocs": {
          "description": "Guía: Datos: colecciones e ítems",
          "url": "https://developers.meteor.com.co/guias/colecciones-e-items.html"
        },
        "operationId": "ItemsController_update",
        "parameters": [
          {
            "description": "ID del recurso de esta ruta.",
            "in": "path",
            "name": "id",
            "required": true,
            "schema": {
              "type": "number"
            }
          },
          {
            "description": "Identificador de tu cliente, como cabecera `X-Client-Id`. Opcional, y solo sirve si además escuchas los eventos en tiempo real: el valor que mandes viaja de vuelta en el evento `item:*` que genera esta operación, para que puedas ignorar el eco de tu propio cambio y no pisar lo que ya pintaste. Si no escuchas realtime, no hace nada.",
            "in": "header",
            "name": "x-client-id",
            "required": true,
            "schema": {
              "type": "string"
            }
          }
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/UpdateItemDto"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "allOf": [
                    {
                      "$ref": "#/components/schemas/ApiEnvelope"
                    },
                    {
                      "properties": {
                        "data": {
                          "$ref": "#/components/schemas/ItemResponseDto"
                        }
                      },
                      "required": [
                        "data"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": ""
          },
          "400": {
            "$ref": "#/components/responses/ApiErrorInvalidRequest"
          },
          "401": {
            "$ref": "#/components/responses/ApiErrorAuth"
          },
          "403": {
            "$ref": "#/components/responses/ApiErrorForbidden"
          },
          "404": {
            "$ref": "#/components/responses/ApiErrorNotFound"
          },
          "409": {
            "$ref": "#/components/responses/ApiErrorConflict"
          },
          "429": {
            "$ref": "#/components/responses/ApiErrorRateLimit"
          },
          "500": {
            "$ref": "#/components/responses/ApiErrorServer"
          }
        },
        "security": [
          {
            "bearer": []
          },
          {
            "api-key": []
          }
        ],
        "summary": "Actualiza el item",
        "tags": [
          "Items"
        ],
        "x-scope": "items:write"
      }
    },
    "/collections/{collectionId}/items/{id}/field": {
      "patch": {
        "externalDocs": {
          "description": "Guía: Datos: colecciones e ítems",
          "url": "https://developers.meteor.com.co/guias/colecciones-e-items.html"
        },
        "operationId": "ItemsController_patchField",
        "parameters": [
          {
            "description": "ID del recurso de esta ruta.",
            "in": "path",
            "name": "id",
            "required": true,
            "schema": {
              "type": "number"
            }
          },
          {
            "description": "Identificador de tu cliente, como cabecera `X-Client-Id`. Opcional, y solo sirve si además escuchas los eventos en tiempo real: el valor que mandes viaja de vuelta en el evento `item:*` que genera esta operación, para que puedas ignorar el eco de tu propio cambio y no pisar lo que ya pintaste. Si no escuchas realtime, no hace nada.",
            "in": "header",
            "name": "x-client-id",
            "required": true,
            "schema": {
              "type": "string"
            }
          }
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/PatchFieldDto"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "allOf": [
                    {
                      "$ref": "#/components/schemas/ApiEnvelope"
                    },
                    {
                      "properties": {
                        "data": {
                          "$ref": "#/components/schemas/ItemResponseDto"
                        }
                      },
                      "required": [
                        "data"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": ""
          },
          "400": {
            "$ref": "#/components/responses/ApiErrorInvalidRequest"
          },
          "401": {
            "$ref": "#/components/responses/ApiErrorAuth"
          },
          "403": {
            "$ref": "#/components/responses/ApiErrorForbidden"
          },
          "404": {
            "$ref": "#/components/responses/ApiErrorNotFound"
          },
          "409": {
            "$ref": "#/components/responses/ApiErrorConflict"
          },
          "429": {
            "$ref": "#/components/responses/ApiErrorRateLimit"
          },
          "500": {
            "$ref": "#/components/responses/ApiErrorServer"
          }
        },
        "security": [
          {
            "bearer": []
          },
          {
            "api-key": []
          }
        ],
        "summary": "Actualiza un solo campo del item",
        "tags": [
          "Items"
        ],
        "x-scope": "items:write"
      }
    },
    "/collections/{collectionId}/move": {
      "post": {
        "externalDocs": {
          "description": "Guía: Datos: colecciones e ítems",
          "url": "https://developers.meteor.com.co/guias/colecciones-e-items.html"
        },
        "operationId": "FoldersController_moveCollection",
        "parameters": [
          {
            "description": "ID numérico de la colección.",
            "in": "path",
            "name": "collectionId",
            "required": true,
            "schema": {
              "type": "number"
            }
          }
        ],
        "responses": {
          "201": {
            "content": {
              "application/json": {
                "schema": {
                  "allOf": [
                    {
                      "$ref": "#/components/schemas/ApiEnvelope"
                    },
                    {
                      "properties": {
                        "data": {
                          "$ref": "#/components/schemas/CollectionMoveResponseDto"
                        }
                      },
                      "required": [
                        "data"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": ""
          },
          "400": {
            "$ref": "#/components/responses/ApiErrorInvalidRequest"
          },
          "401": {
            "$ref": "#/components/responses/ApiErrorAuth"
          },
          "403": {
            "$ref": "#/components/responses/ApiErrorForbidden"
          },
          "404": {
            "$ref": "#/components/responses/ApiErrorNotFound"
          },
          "409": {
            "$ref": "#/components/responses/ApiErrorConflict"
          },
          "429": {
            "$ref": "#/components/responses/ApiErrorRateLimit"
          },
          "500": {
            "$ref": "#/components/responses/ApiErrorServer"
          }
        },
        "security": [
          {
            "bearer": []
          },
          {
            "api-key": []
          }
        ],
        "summary": "Mueve una colección a una carpeta",
        "tags": [
          "Collections"
        ],
        "x-scope": "collections:write"
      }
    },
    "/collections/{collectionId}/slug": {
      "put": {
        "externalDocs": {
          "description": "Guía: Datos: colecciones e ítems",
          "url": "https://developers.meteor.com.co/guias/colecciones-e-items.html"
        },
        "operationId": "SlugsController_updateCollectionSlug",
        "parameters": [
          {
            "description": "ID numérico de la colección.",
            "in": "path",
            "name": "collectionId",
            "required": true,
            "schema": {
              "type": "number"
            }
          }
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/UpdateSlugDto"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "allOf": [
                    {
                      "$ref": "#/components/schemas/ApiEnvelope"
                    },
                    {
                      "properties": {
                        "data": {
                          "$ref": "#/components/schemas/SlugUpdatedResponseDto"
                        }
                      },
                      "required": [
                        "data"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": ""
          },
          "400": {
            "$ref": "#/components/responses/ApiErrorInvalidRequest"
          },
          "401": {
            "$ref": "#/components/responses/ApiErrorAuth"
          },
          "403": {
            "$ref": "#/components/responses/ApiErrorForbidden"
          },
          "404": {
            "$ref": "#/components/responses/ApiErrorNotFound"
          },
          "409": {
            "$ref": "#/components/responses/ApiErrorConflict"
          },
          "429": {
            "$ref": "#/components/responses/ApiErrorRateLimit"
          },
          "500": {
            "$ref": "#/components/responses/ApiErrorServer"
          }
        },
        "security": [
          {
            "bearer": []
          },
          {
            "api-key": []
          }
        ],
        "summary": "Actualiza el slug de la colección",
        "tags": [
          "Collections"
        ],
        "x-scope": "collections:write"
      }
    },
    "/collections/{collectionId}/views": {
      "get": {
        "externalDocs": {
          "description": "Guía: Datos: colecciones e ítems",
          "url": "https://developers.meteor.com.co/guias/colecciones-e-items.html"
        },
        "operationId": "CollectionsController_listViews",
        "parameters": [
          {
            "description": "ID numérico de la colección.",
            "in": "path",
            "name": "collectionId",
            "required": true,
            "schema": {
              "type": "number"
            }
          }
        ],
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "allOf": [
                    {
                      "$ref": "#/components/schemas/ApiEnvelope"
                    },
                    {
                      "properties": {
                        "data": {
                          "items": {
                            "$ref": "#/components/schemas/CollectionViewResponseDto"
                          },
                          "type": "array"
                        }
                      },
                      "required": [
                        "data"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": ""
          },
          "400": {
            "$ref": "#/components/responses/ApiErrorInvalidRequest"
          },
          "401": {
            "$ref": "#/components/responses/ApiErrorAuth"
          },
          "403": {
            "$ref": "#/components/responses/ApiErrorForbidden"
          },
          "404": {
            "$ref": "#/components/responses/ApiErrorNotFound"
          },
          "429": {
            "$ref": "#/components/responses/ApiErrorRateLimit"
          },
          "500": {
            "$ref": "#/components/responses/ApiErrorServer"
          }
        },
        "security": [
          {
            "bearer": []
          },
          {
            "api-key": []
          }
        ],
        "summary": "Lista las vistas guardadas de una colección",
        "tags": [
          "Collections"
        ],
        "x-scope": "collections:read"
      },
      "post": {
        "externalDocs": {
          "description": "Guía: Datos: colecciones e ítems",
          "url": "https://developers.meteor.com.co/guias/colecciones-e-items.html"
        },
        "operationId": "CollectionsController_createView",
        "parameters": [
          {
            "description": "ID numérico de la colección.",
            "in": "path",
            "name": "collectionId",
            "required": true,
            "schema": {
              "type": "number"
            }
          }
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/CreateViewDto"
              }
            }
          },
          "required": true
        },
        "responses": {
          "201": {
            "content": {
              "application/json": {
                "schema": {
                  "allOf": [
                    {
                      "$ref": "#/components/schemas/ApiEnvelope"
                    },
                    {
                      "properties": {
                        "data": {
                          "$ref": "#/components/schemas/CollectionViewResponseDto"
                        }
                      },
                      "required": [
                        "data"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": ""
          },
          "400": {
            "$ref": "#/components/responses/ApiErrorInvalidRequest"
          },
          "401": {
            "$ref": "#/components/responses/ApiErrorAuth"
          },
          "403": {
            "$ref": "#/components/responses/ApiErrorForbidden"
          },
          "404": {
            "$ref": "#/components/responses/ApiErrorNotFound"
          },
          "409": {
            "$ref": "#/components/responses/ApiErrorConflict"
          },
          "429": {
            "$ref": "#/components/responses/ApiErrorRateLimit"
          },
          "500": {
            "$ref": "#/components/responses/ApiErrorServer"
          }
        },
        "security": [
          {
            "bearer": []
          },
          {
            "api-key": []
          }
        ],
        "summary": "Crea una vista guardada",
        "tags": [
          "Collections"
        ],
        "x-scope": "collections:write"
      }
    },
    "/collections/{collectionId}/views/reorder": {
      "patch": {
        "externalDocs": {
          "description": "Guía: Datos: colecciones e ítems",
          "url": "https://developers.meteor.com.co/guias/colecciones-e-items.html"
        },
        "operationId": "CollectionsController_reorderViews",
        "parameters": [
          {
            "description": "ID numérico de la colección.",
            "in": "path",
            "name": "collectionId",
            "required": true,
            "schema": {
              "type": "number"
            }
          }
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/ReorderViewsDto"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "allOf": [
                    {
                      "$ref": "#/components/schemas/ApiEnvelope"
                    },
                    {
                      "properties": {
                        "data": {
                          "items": {
                            "$ref": "#/components/schemas/CollectionViewResponseDto"
                          },
                          "type": "array"
                        }
                      },
                      "required": [
                        "data"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": ""
          },
          "400": {
            "$ref": "#/components/responses/ApiErrorInvalidRequest"
          },
          "401": {
            "$ref": "#/components/responses/ApiErrorAuth"
          },
          "403": {
            "$ref": "#/components/responses/ApiErrorForbidden"
          },
          "404": {
            "$ref": "#/components/responses/ApiErrorNotFound"
          },
          "409": {
            "$ref": "#/components/responses/ApiErrorConflict"
          },
          "429": {
            "$ref": "#/components/responses/ApiErrorRateLimit"
          },
          "500": {
            "$ref": "#/components/responses/ApiErrorServer"
          }
        },
        "security": [
          {
            "bearer": []
          },
          {
            "api-key": []
          }
        ],
        "summary": "Reordena las vistas guardadas (pestañas arrastrables)",
        "tags": [
          "Collections"
        ],
        "x-scope": "collections:write"
      }
    },
    "/collections/{id}": {
      "delete": {
        "externalDocs": {
          "description": "Guía: Datos: colecciones e ítems",
          "url": "https://developers.meteor.com.co/guias/colecciones-e-items.html"
        },
        "operationId": "CollectionsController_remove",
        "parameters": [
          {
            "description": "ID del recurso de esta ruta.",
            "in": "path",
            "name": "id",
            "required": true,
            "schema": {
              "type": "number"
            }
          }
        ],
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "allOf": [
                    {
                      "$ref": "#/components/schemas/ApiEnvelope"
                    },
                    {
                      "properties": {
                        "data": {
                          "$ref": "#/components/schemas/CollectionMessageResponseDto"
                        }
                      },
                      "required": [
                        "data"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": ""
          },
          "400": {
            "$ref": "#/components/responses/ApiErrorInvalidRequest"
          },
          "401": {
            "$ref": "#/components/responses/ApiErrorAuth"
          },
          "403": {
            "$ref": "#/components/responses/ApiErrorForbidden"
          },
          "404": {
            "$ref": "#/components/responses/ApiErrorNotFound"
          },
          "409": {
            "$ref": "#/components/responses/ApiErrorConflict"
          },
          "429": {
            "$ref": "#/components/responses/ApiErrorRateLimit"
          },
          "500": {
            "$ref": "#/components/responses/ApiErrorServer"
          }
        },
        "security": [
          {
            "bearer": []
          },
          {
            "api-key": []
          }
        ],
        "summary": "Elimina una colección",
        "tags": [
          "Collections"
        ],
        "x-scope": "collections:write"
      },
      "get": {
        "externalDocs": {
          "description": "Guía: Datos: colecciones e ítems",
          "url": "https://developers.meteor.com.co/guias/colecciones-e-items.html"
        },
        "operationId": "CollectionsController_findOne",
        "parameters": [
          {
            "description": "ID del recurso de esta ruta.",
            "in": "path",
            "name": "id",
            "required": true,
            "schema": {
              "type": "number"
            }
          }
        ],
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "allOf": [
                    {
                      "$ref": "#/components/schemas/ApiEnvelope"
                    },
                    {
                      "properties": {
                        "data": {
                          "$ref": "#/components/schemas/CollectionResponseDto"
                        }
                      },
                      "required": [
                        "data"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": ""
          },
          "400": {
            "$ref": "#/components/responses/ApiErrorInvalidRequest"
          },
          "401": {
            "$ref": "#/components/responses/ApiErrorAuth"
          },
          "403": {
            "$ref": "#/components/responses/ApiErrorForbidden"
          },
          "404": {
            "$ref": "#/components/responses/ApiErrorNotFound"
          },
          "429": {
            "$ref": "#/components/responses/ApiErrorRateLimit"
          },
          "500": {
            "$ref": "#/components/responses/ApiErrorServer"
          }
        },
        "security": [
          {
            "bearer": []
          },
          {
            "api-key": []
          }
        ],
        "summary": "Obtiene la colección por ID",
        "tags": [
          "Collections"
        ],
        "x-scope": "collections:read"
      },
      "put": {
        "externalDocs": {
          "description": "Guía: Datos: colecciones e ítems",
          "url": "https://developers.meteor.com.co/guias/colecciones-e-items.html"
        },
        "operationId": "CollectionsController_update",
        "parameters": [
          {
            "description": "ID del recurso de esta ruta.",
            "in": "path",
            "name": "id",
            "required": true,
            "schema": {
              "type": "number"
            }
          }
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/UpdateCollectionDto"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "allOf": [
                    {
                      "$ref": "#/components/schemas/ApiEnvelope"
                    },
                    {
                      "properties": {
                        "data": {
                          "$ref": "#/components/schemas/CollectionResponseDto"
                        }
                      },
                      "required": [
                        "data"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": ""
          },
          "400": {
            "$ref": "#/components/responses/ApiErrorInvalidRequest"
          },
          "401": {
            "$ref": "#/components/responses/ApiErrorAuth"
          },
          "403": {
            "$ref": "#/components/responses/ApiErrorForbidden"
          },
          "404": {
            "$ref": "#/components/responses/ApiErrorNotFound"
          },
          "409": {
            "$ref": "#/components/responses/ApiErrorConflict"
          },
          "429": {
            "$ref": "#/components/responses/ApiErrorRateLimit"
          },
          "500": {
            "$ref": "#/components/responses/ApiErrorServer"
          }
        },
        "security": [
          {
            "bearer": []
          },
          {
            "api-key": []
          }
        ],
        "summary": "Actualiza una colección",
        "tags": [
          "Collections"
        ],
        "x-scope": "collections:write"
      }
    },
    "/collections/{id}/pin": {
      "put": {
        "externalDocs": {
          "description": "Guía: Datos: colecciones e ítems",
          "url": "https://developers.meteor.com.co/guias/colecciones-e-items.html"
        },
        "operationId": "CollectionsController_pin",
        "parameters": [
          {
            "description": "ID del recurso de esta ruta.",
            "in": "path",
            "name": "id",
            "required": true,
            "schema": {
              "type": "number"
            }
          }
        ],
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "allOf": [
                    {
                      "$ref": "#/components/schemas/ApiEnvelope"
                    },
                    {
                      "properties": {
                        "data": {
                          "$ref": "#/components/schemas/CollectionPinResponseDto"
                        }
                      },
                      "required": [
                        "data"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": ""
          },
          "400": {
            "$ref": "#/components/responses/ApiErrorInvalidRequest"
          },
          "401": {
            "$ref": "#/components/responses/ApiErrorAuth"
          },
          "403": {
            "$ref": "#/components/responses/ApiErrorForbidden"
          },
          "404": {
            "$ref": "#/components/responses/ApiErrorNotFound"
          },
          "409": {
            "$ref": "#/components/responses/ApiErrorConflict"
          },
          "429": {
            "$ref": "#/components/responses/ApiErrorRateLimit"
          },
          "500": {
            "$ref": "#/components/responses/ApiErrorServer"
          }
        },
        "security": [
          {
            "bearer": []
          },
          {
            "api-key": []
          }
        ],
        "summary": "Ancla o desancla la colección del menú",
        "tags": [
          "Collections"
        ],
        "x-scope": "collections:write"
      }
    },
    "/contact-tags": {
      "get": {
        "description": "El registro es el catálogo: devuelve todas las etiquetas, incluidas las que no está usando ningún contacto. Ordenadas por nombre.",
        "externalDocs": {
          "description": "Guía: CRM y contactos",
          "url": "https://developers.meteor.com.co/guias/contactos.html"
        },
        "operationId": "ContactTagsController_list",
        "parameters": [],
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "allOf": [
                    {
                      "$ref": "#/components/schemas/ApiEnvelope"
                    },
                    {
                      "properties": {
                        "data": {
                          "items": {
                            "$ref": "#/components/schemas/ContactTagResponseDto"
                          },
                          "type": "array"
                        }
                      },
                      "required": [
                        "data"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": ""
          },
          "400": {
            "$ref": "#/components/responses/ApiErrorInvalidRequest"
          },
          "401": {
            "$ref": "#/components/responses/ApiErrorAuth"
          },
          "403": {
            "$ref": "#/components/responses/ApiErrorForbidden"
          },
          "404": {
            "$ref": "#/components/responses/ApiErrorNotFound"
          },
          "429": {
            "$ref": "#/components/responses/ApiErrorRateLimit"
          },
          "500": {
            "$ref": "#/components/responses/ApiErrorServer"
          }
        },
        "security": [
          {
            "bearer": []
          },
          {
            "api-key": []
          }
        ],
        "summary": "Listar el registro de etiquetas del workspace",
        "tags": [
          "Contacts"
        ],
        "x-scope": "contacts:read"
      },
      "post": {
        "description": "Solo la registra en el catálogo; no se la asigna a ningún contacto. El nombre es único por workspace sin distinguir mayúsculas: repetirlo responde 409.",
        "externalDocs": {
          "description": "Guía: CRM y contactos",
          "url": "https://developers.meteor.com.co/guias/contactos.html"
        },
        "operationId": "ContactTagsController_create",
        "parameters": [],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/CreateContactTagDto"
              }
            }
          },
          "required": true
        },
        "responses": {
          "201": {
            "content": {
              "application/json": {
                "schema": {
                  "allOf": [
                    {
                      "$ref": "#/components/schemas/ApiEnvelope"
                    },
                    {
                      "properties": {
                        "data": {
                          "$ref": "#/components/schemas/ContactTagResponseDto"
                        }
                      },
                      "required": [
                        "data"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": ""
          },
          "400": {
            "$ref": "#/components/responses/ApiErrorInvalidRequest"
          },
          "401": {
            "$ref": "#/components/responses/ApiErrorAuth"
          },
          "403": {
            "$ref": "#/components/responses/ApiErrorForbidden"
          },
          "404": {
            "$ref": "#/components/responses/ApiErrorNotFound"
          },
          "409": {
            "$ref": "#/components/responses/ApiErrorConflict"
          },
          "429": {
            "$ref": "#/components/responses/ApiErrorRateLimit"
          },
          "500": {
            "$ref": "#/components/responses/ApiErrorServer"
          }
        },
        "security": [
          {
            "bearer": []
          },
          {
            "api-key": []
          }
        ],
        "summary": "Crear una etiqueta en el registro del workspace",
        "tags": [
          "Contacts"
        ],
        "x-scope": "contacts:write"
      }
    },
    "/contact-tags/{id}": {
      "delete": {
        "description": "La borra del catálogo y la quita de todos los contactos del workspace. No se puede deshacer.",
        "externalDocs": {
          "description": "Guía: CRM y contactos",
          "url": "https://developers.meteor.com.co/guias/contactos.html"
        },
        "operationId": "ContactTagsController_remove",
        "parameters": [
          {
            "description": "ID del recurso de esta ruta.",
            "in": "path",
            "name": "id",
            "required": true,
            "schema": {
              "type": "number"
            }
          }
        ],
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "allOf": [
                    {
                      "$ref": "#/components/schemas/ApiEnvelope"
                    },
                    {
                      "properties": {
                        "data": {
                          "$ref": "#/components/schemas/ContactTagDeletedResponseDto"
                        }
                      },
                      "required": [
                        "data"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": ""
          },
          "400": {
            "$ref": "#/components/responses/ApiErrorInvalidRequest"
          },
          "401": {
            "$ref": "#/components/responses/ApiErrorAuth"
          },
          "403": {
            "$ref": "#/components/responses/ApiErrorForbidden"
          },
          "404": {
            "$ref": "#/components/responses/ApiErrorNotFound"
          },
          "409": {
            "$ref": "#/components/responses/ApiErrorConflict"
          },
          "429": {
            "$ref": "#/components/responses/ApiErrorRateLimit"
          },
          "500": {
            "$ref": "#/components/responses/ApiErrorServer"
          }
        },
        "security": [
          {
            "bearer": []
          },
          {
            "api-key": []
          }
        ],
        "summary": "Eliminar una etiqueta (la quita de los contactos)",
        "tags": [
          "Contacts"
        ],
        "x-scope": "contacts:write"
      },
      "patch": {
        "description": "Reescribe el nombre en todos los contactos que la tenían, para que no queden etiquetas huérfanas. Chocar con un nombre existente responde 409.",
        "externalDocs": {
          "description": "Guía: CRM y contactos",
          "url": "https://developers.meteor.com.co/guias/contactos.html"
        },
        "operationId": "ContactTagsController_rename",
        "parameters": [
          {
            "description": "ID del recurso de esta ruta.",
            "in": "path",
            "name": "id",
            "required": true,
            "schema": {
              "type": "number"
            }
          }
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/UpdateContactTagDto"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "allOf": [
                    {
                      "$ref": "#/components/schemas/ApiEnvelope"
                    },
                    {
                      "properties": {
                        "data": {
                          "$ref": "#/components/schemas/ContactTagResponseDto"
                        }
                      },
                      "required": [
                        "data"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": ""
          },
          "400": {
            "$ref": "#/components/responses/ApiErrorInvalidRequest"
          },
          "401": {
            "$ref": "#/components/responses/ApiErrorAuth"
          },
          "403": {
            "$ref": "#/components/responses/ApiErrorForbidden"
          },
          "404": {
            "$ref": "#/components/responses/ApiErrorNotFound"
          },
          "409": {
            "$ref": "#/components/responses/ApiErrorConflict"
          },
          "429": {
            "$ref": "#/components/responses/ApiErrorRateLimit"
          },
          "500": {
            "$ref": "#/components/responses/ApiErrorServer"
          }
        },
        "security": [
          {
            "bearer": []
          },
          {
            "api-key": []
          }
        ],
        "summary": "Renombrar una etiqueta (propaga a los contactos)",
        "tags": [
          "Contacts"
        ],
        "x-scope": "contacts:write"
      }
    },
    "/contacts": {
      "delete": {
        "externalDocs": {
          "description": "Guía: CRM y contactos",
          "url": "https://developers.meteor.com.co/guias/contactos.html"
        },
        "operationId": "ContactsController_deleteAll",
        "parameters": [],
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "allOf": [
                    {
                      "$ref": "#/components/schemas/ApiEnvelope"
                    },
                    {
                      "properties": {
                        "data": {
                          "$ref": "#/components/schemas/ContactsDeletedAllDto"
                        }
                      },
                      "required": [
                        "data"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": ""
          },
          "400": {
            "$ref": "#/components/responses/ApiErrorInvalidRequest"
          },
          "401": {
            "$ref": "#/components/responses/ApiErrorAuth"
          },
          "403": {
            "$ref": "#/components/responses/ApiErrorForbidden"
          },
          "404": {
            "$ref": "#/components/responses/ApiErrorNotFound"
          },
          "409": {
            "$ref": "#/components/responses/ApiErrorConflict"
          },
          "429": {
            "$ref": "#/components/responses/ApiErrorRateLimit"
          },
          "500": {
            "$ref": "#/components/responses/ApiErrorServer"
          }
        },
        "security": [
          {
            "bearer": []
          },
          {
            "api-key": []
          }
        ],
        "summary": "Elimina TODOS los contactos (masivo) — requiere ADMIN",
        "tags": [
          "Contacts"
        ],
        "x-scope": "contacts:write"
      },
      "get": {
        "description": "Devuelve `{ data, total, has_more }`. Por defecto ordena por recencia de la conversación y pagina con `page`. Para barrer la lista completa usá el cursor: `order=id` en la primera página y `starting_after=<id del último contacto>` en las siguientes — es el único orden estable (el default se reordena con cada mensaje entrante). El SDK lo hace solo con `contacts.iterate()`.",
        "externalDocs": {
          "description": "Guía: CRM y contactos",
          "url": "https://developers.meteor.com.co/guias/contactos.html"
        },
        "operationId": "ContactsController_findAll",
        "parameters": [],
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "allOf": [
                    {
                      "$ref": "#/components/schemas/ApiEnvelope"
                    },
                    {
                      "properties": {
                        "data": {
                          "$ref": "#/components/schemas/ContactListResponseDto"
                        }
                      },
                      "required": [
                        "data"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": ""
          },
          "400": {
            "$ref": "#/components/responses/ApiErrorInvalidRequest"
          },
          "401": {
            "$ref": "#/components/responses/ApiErrorAuth"
          },
          "403": {
            "$ref": "#/components/responses/ApiErrorForbidden"
          },
          "404": {
            "$ref": "#/components/responses/ApiErrorNotFound"
          },
          "429": {
            "$ref": "#/components/responses/ApiErrorRateLimit"
          },
          "500": {
            "$ref": "#/components/responses/ApiErrorServer"
          }
        },
        "security": [
          {
            "bearer": []
          },
          {
            "api-key": []
          }
        ],
        "summary": "Lista los contactos",
        "tags": [
          "Contacts"
        ],
        "x-scope": "contacts:read"
      },
      "post": {
        "externalDocs": {
          "description": "Guía: CRM y contactos",
          "url": "https://developers.meteor.com.co/guias/contactos.html"
        },
        "operationId": "ContactsController_createOne",
        "parameters": [],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/CreateContactDto"
              }
            }
          },
          "required": true
        },
        "responses": {
          "201": {
            "content": {
              "application/json": {
                "schema": {
                  "allOf": [
                    {
                      "$ref": "#/components/schemas/ApiEnvelope"
                    },
                    {
                      "properties": {
                        "data": {
                          "$ref": "#/components/schemas/ContactRecordDto"
                        }
                      },
                      "required": [
                        "data"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": ""
          },
          "400": {
            "$ref": "#/components/responses/ApiErrorInvalidRequest"
          },
          "401": {
            "$ref": "#/components/responses/ApiErrorAuth"
          },
          "403": {
            "$ref": "#/components/responses/ApiErrorForbidden"
          },
          "404": {
            "$ref": "#/components/responses/ApiErrorNotFound"
          },
          "409": {
            "$ref": "#/components/responses/ApiErrorConflict"
          },
          "429": {
            "$ref": "#/components/responses/ApiErrorRateLimit"
          },
          "500": {
            "$ref": "#/components/responses/ApiErrorServer"
          }
        },
        "security": [
          {
            "bearer": []
          },
          {
            "api-key": []
          }
        ],
        "summary": "Crea un contacto. Refleja DELETE /contacts/:id: también crea el suscriptor en Meteor CRM (uChat).",
        "tags": [
          "Contacts"
        ],
        "x-scope": "contacts:write"
      }
    },
    "/contacts/bulk": {
      "delete": {
        "externalDocs": {
          "description": "Guía: CRM y contactos",
          "url": "https://developers.meteor.com.co/guias/contactos.html"
        },
        "operationId": "ContactsController_bulkDelete",
        "parameters": [],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/BulkDeleteContactsDto"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "allOf": [
                    {
                      "$ref": "#/components/schemas/ApiEnvelope"
                    },
                    {
                      "properties": {
                        "data": {
                          "$ref": "#/components/schemas/BulkDeleteResultDto"
                        }
                      },
                      "required": [
                        "data"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": ""
          },
          "400": {
            "$ref": "#/components/responses/ApiErrorInvalidRequest"
          },
          "401": {
            "$ref": "#/components/responses/ApiErrorAuth"
          },
          "403": {
            "$ref": "#/components/responses/ApiErrorForbidden"
          },
          "404": {
            "$ref": "#/components/responses/ApiErrorNotFound"
          },
          "409": {
            "$ref": "#/components/responses/ApiErrorConflict"
          },
          "429": {
            "$ref": "#/components/responses/ApiErrorRateLimit"
          },
          "500": {
            "$ref": "#/components/responses/ApiErrorServer"
          }
        },
        "security": [
          {
            "bearer": []
          },
          {
            "api-key": []
          }
        ],
        "summary": "Eliminar varios contactos seleccionados + sus mensajes",
        "tags": [
          "Contacts"
        ],
        "x-scope": "contacts:write"
      }
    },
    "/contacts/bulk/tags": {
      "delete": {
        "externalDocs": {
          "description": "Guía: CRM y contactos",
          "url": "https://developers.meteor.com.co/guias/contactos.html"
        },
        "operationId": "ContactsController_bulkRemoveTag",
        "parameters": [],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/BulkTagDto"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "allOf": [
                    {
                      "$ref": "#/components/schemas/ApiEnvelope"
                    },
                    {
                      "properties": {
                        "data": {
                          "$ref": "#/components/schemas/BulkTagResultDto"
                        }
                      },
                      "required": [
                        "data"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": ""
          },
          "400": {
            "$ref": "#/components/responses/ApiErrorInvalidRequest"
          },
          "401": {
            "$ref": "#/components/responses/ApiErrorAuth"
          },
          "403": {
            "$ref": "#/components/responses/ApiErrorForbidden"
          },
          "404": {
            "$ref": "#/components/responses/ApiErrorNotFound"
          },
          "409": {
            "$ref": "#/components/responses/ApiErrorConflict"
          },
          "429": {
            "$ref": "#/components/responses/ApiErrorRateLimit"
          },
          "500": {
            "$ref": "#/components/responses/ApiErrorServer"
          }
        },
        "security": [
          {
            "bearer": []
          },
          {
            "api-key": []
          }
        ],
        "summary": "Quitar una etiqueta de varios contactos seleccionados",
        "tags": [
          "Contacts"
        ],
        "x-scope": "contacts:write"
      },
      "post": {
        "externalDocs": {
          "description": "Guía: CRM y contactos",
          "url": "https://developers.meteor.com.co/guias/contactos.html"
        },
        "operationId": "ContactsController_bulkAddTag",
        "parameters": [],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/BulkTagDto"
              }
            }
          },
          "required": true
        },
        "responses": {
          "201": {
            "content": {
              "application/json": {
                "schema": {
                  "allOf": [
                    {
                      "$ref": "#/components/schemas/ApiEnvelope"
                    },
                    {
                      "properties": {
                        "data": {
                          "$ref": "#/components/schemas/BulkTagResultDto"
                        }
                      },
                      "required": [
                        "data"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": ""
          },
          "400": {
            "$ref": "#/components/responses/ApiErrorInvalidRequest"
          },
          "401": {
            "$ref": "#/components/responses/ApiErrorAuth"
          },
          "403": {
            "$ref": "#/components/responses/ApiErrorForbidden"
          },
          "404": {
            "$ref": "#/components/responses/ApiErrorNotFound"
          },
          "409": {
            "$ref": "#/components/responses/ApiErrorConflict"
          },
          "429": {
            "$ref": "#/components/responses/ApiErrorRateLimit"
          },
          "500": {
            "$ref": "#/components/responses/ApiErrorServer"
          }
        },
        "security": [
          {
            "bearer": []
          },
          {
            "api-key": []
          }
        ],
        "summary": "Añadir una etiqueta a varios contactos seleccionados",
        "tags": [
          "Contacts"
        ],
        "x-scope": "contacts:write"
      }
    },
    "/contacts/counts": {
      "get": {
        "description": "Acepta los mismos filtros que `GET /contacts` y devuelve conteos **facetados**: cada bloque se calcula con todos los filtros activos menos el suyo. Con `assigned_to=42`, los cinco contadores de estado cuentan los chats de esa persona; con `status=open`, los de asesor cuentan solo los abiertos. El bloque que se aplicara su propio filtro daría 0 en todas las demás opciones y no habría cómo volver.\n\n`scopeTotal` es aparte: el universo de la carpeta (asesor/grupo/canal) sin estado, búsqueda ni filtro avanzado — el denominador de \"viendo N de M\".\n\nSin parámetros devuelve los totales del workspace, igual que siempre.",
        "externalDocs": {
          "description": "Guía: CRM y contactos",
          "url": "https://developers.meteor.com.co/guias/contactos.html"
        },
        "operationId": "ContactsController_getCounts",
        "parameters": [
          {
            "description": "Filtro avanzado: JSON array de condiciones `{ field, op, value }`, combinadas con AND.",
            "in": "query",
            "name": "filters",
            "required": false,
            "schema": {
              "type": "string"
            }
          },
          {
            "description": "Piloto automático encendido o apagado.",
            "in": "query",
            "name": "autopilot",
            "required": false,
            "schema": {
              "type": "boolean"
            }
          },
          {
            "description": "`true` = solo los que tienen mensajes sin leer.",
            "in": "query",
            "name": "unread",
            "required": false,
            "schema": {
              "type": "boolean"
            }
          },
          {
            "description": "Etiqueta del contacto.",
            "in": "query",
            "name": "tag",
            "required": false,
            "schema": {
              "type": "string"
            }
          },
          {
            "description": "Id del grupo de atención, o `none` para los que no tienen.",
            "in": "query",
            "name": "agent_group",
            "required": false,
            "schema": {
              "type": "string"
            }
          },
          {
            "description": "Id del asesor asignado, o `unassigned`.",
            "in": "query",
            "name": "assigned_to",
            "required": false,
            "schema": {
              "type": "string"
            }
          },
          {
            "description": "Estado del chat.",
            "in": "query",
            "name": "status",
            "required": false,
            "schema": {
              "enum": [
                "open",
                "pending",
                "human_requested",
                "finished",
                "archived"
              ],
              "type": "string"
            }
          },
          {
            "description": "Canal de origen.",
            "in": "query",
            "name": "channel_id",
            "required": false,
            "schema": {
              "type": "string"
            }
          },
          {
            "description": "Búsqueda por nombre, teléfono, email o identificador.",
            "in": "query",
            "name": "q",
            "required": false,
            "schema": {
              "type": "string"
            }
          }
        ],
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "allOf": [
                    {
                      "$ref": "#/components/schemas/ApiEnvelope"
                    },
                    {
                      "properties": {
                        "data": {
                          "$ref": "#/components/schemas/ContactCountsDto"
                        }
                      },
                      "required": [
                        "data"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": ""
          },
          "400": {
            "$ref": "#/components/responses/ApiErrorInvalidRequest"
          },
          "401": {
            "$ref": "#/components/responses/ApiErrorAuth"
          },
          "403": {
            "$ref": "#/components/responses/ApiErrorForbidden"
          },
          "404": {
            "$ref": "#/components/responses/ApiErrorNotFound"
          },
          "429": {
            "$ref": "#/components/responses/ApiErrorRateLimit"
          },
          "500": {
            "$ref": "#/components/responses/ApiErrorServer"
          }
        },
        "security": [
          {
            "bearer": []
          },
          {
            "api-key": []
          }
        ],
        "summary": "Conteos reales por bandeja (total, estado, asignación, canal)",
        "tags": [
          "Contacts"
        ],
        "x-scope": "contacts:read"
      }
    },
    "/contacts/import": {
      "post": {
        "externalDocs": {
          "description": "Guía: CRM y contactos",
          "url": "https://developers.meteor.com.co/guias/contactos.html"
        },
        "operationId": "ContactsController_importContacts",
        "parameters": [],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/ImportContactsDto"
              }
            }
          },
          "required": true
        },
        "responses": {
          "201": {
            "content": {
              "application/json": {
                "schema": {
                  "allOf": [
                    {
                      "$ref": "#/components/schemas/ApiEnvelope"
                    },
                    {
                      "properties": {
                        "data": {
                          "$ref": "#/components/schemas/ContactImportResultDto"
                        }
                      },
                      "required": [
                        "data"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": ""
          },
          "400": {
            "$ref": "#/components/responses/ApiErrorInvalidRequest"
          },
          "401": {
            "$ref": "#/components/responses/ApiErrorAuth"
          },
          "403": {
            "$ref": "#/components/responses/ApiErrorForbidden"
          },
          "404": {
            "$ref": "#/components/responses/ApiErrorNotFound"
          },
          "409": {
            "$ref": "#/components/responses/ApiErrorConflict"
          },
          "429": {
            "$ref": "#/components/responses/ApiErrorRateLimit"
          },
          "500": {
            "$ref": "#/components/responses/ApiErrorServer"
          }
        },
        "security": [
          {
            "bearer": []
          },
          {
            "api-key": []
          }
        ],
        "summary": "Importar un lote de contactos (máx 500). Preserva user_ns; rellena campos vacíos en existentes (merge fill-only), no toca uChat.",
        "tags": [
          "Contacts"
        ],
        "x-scope": "contacts:write"
      }
    },
    "/contacts/pipeline-summary": {
      "get": {
        "description": "Agrega en la base sobre TODOS los contactos, no sobre una página. `stage_field` y `amount_field` son los campos personalizados del workspace (default `etapa` y `monto`). Los contactos sin etapa se agrupan en `__no_value__`. Respeta la visibilidad del asesor.",
        "externalDocs": {
          "description": "Guía: CRM y contactos",
          "url": "https://developers.meteor.com.co/guias/contactos.html"
        },
        "operationId": "ContactsController_getPipelineSummary",
        "parameters": [],
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "allOf": [
                    {
                      "$ref": "#/components/schemas/ApiEnvelope"
                    },
                    {
                      "properties": {
                        "data": {
                          "$ref": "#/components/schemas/PipelineSummaryResponseDto"
                        }
                      },
                      "required": [
                        "data"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": ""
          },
          "400": {
            "$ref": "#/components/responses/ApiErrorInvalidRequest"
          },
          "401": {
            "$ref": "#/components/responses/ApiErrorAuth"
          },
          "403": {
            "$ref": "#/components/responses/ApiErrorForbidden"
          },
          "404": {
            "$ref": "#/components/responses/ApiErrorNotFound"
          },
          "429": {
            "$ref": "#/components/responses/ApiErrorRateLimit"
          },
          "500": {
            "$ref": "#/components/responses/ApiErrorServer"
          }
        },
        "security": [
          {
            "bearer": []
          },
          {
            "api-key": []
          }
        ],
        "summary": "Totales del embudo por etapa (conteo + suma de montos)",
        "tags": [
          "Contacts"
        ],
        "x-scope": "contacts:read"
      }
    },
    "/contacts/tags/distinct": {
      "get": {
        "description": "Un array de strings, ordenado alfabéticamente. Es la unión del catálogo del workspace (incluye etiquetas creadas y todavía sin asignar) con las que estén realmente puestas en algún contacto.",
        "externalDocs": {
          "description": "Guía: CRM y contactos",
          "url": "https://developers.meteor.com.co/guias/contactos.html"
        },
        "operationId": "ContactsController_listWorkspaceTags",
        "parameters": [],
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "allOf": [
                    {
                      "$ref": "#/components/schemas/ApiEnvelope"
                    },
                    {
                      "properties": {
                        "data": {
                          "items": {
                            "type": "string"
                          },
                          "type": "array"
                        }
                      },
                      "required": [
                        "data"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": ""
          },
          "400": {
            "$ref": "#/components/responses/ApiErrorInvalidRequest"
          },
          "401": {
            "$ref": "#/components/responses/ApiErrorAuth"
          },
          "403": {
            "$ref": "#/components/responses/ApiErrorForbidden"
          },
          "404": {
            "$ref": "#/components/responses/ApiErrorNotFound"
          },
          "429": {
            "$ref": "#/components/responses/ApiErrorRateLimit"
          },
          "500": {
            "$ref": "#/components/responses/ApiErrorServer"
          }
        },
        "security": [
          {
            "bearer": []
          },
          {
            "api-key": []
          }
        ],
        "summary": "Lista las etiquetas únicas de contactos del workspace",
        "tags": [
          "Contacts"
        ],
        "x-scope": "contacts:read"
      }
    },
    "/contacts/{contactId}": {
      "delete": {
        "externalDocs": {
          "description": "Guía: CRM y contactos",
          "url": "https://developers.meteor.com.co/guias/contactos.html"
        },
        "operationId": "ContactsController_deleteOne",
        "parameters": [
          {
            "description": "ID del contacto del CRM.",
            "in": "path",
            "name": "contactId",
            "required": true,
            "schema": {
              "type": "number"
            }
          }
        ],
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "allOf": [
                    {
                      "$ref": "#/components/schemas/ApiEnvelope"
                    },
                    {
                      "properties": {
                        "data": {
                          "$ref": "#/components/schemas/ContactDeletedDto"
                        }
                      },
                      "required": [
                        "data"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": ""
          },
          "400": {
            "$ref": "#/components/responses/ApiErrorInvalidRequest"
          },
          "401": {
            "$ref": "#/components/responses/ApiErrorAuth"
          },
          "403": {
            "$ref": "#/components/responses/ApiErrorForbidden"
          },
          "404": {
            "$ref": "#/components/responses/ApiErrorNotFound"
          },
          "409": {
            "$ref": "#/components/responses/ApiErrorConflict"
          },
          "429": {
            "$ref": "#/components/responses/ApiErrorRateLimit"
          },
          "500": {
            "$ref": "#/components/responses/ApiErrorServer"
          }
        },
        "security": [
          {
            "bearer": []
          },
          {
            "api-key": []
          }
        ],
        "summary": "Elimina un contacto y sus mensajes",
        "tags": [
          "Contacts"
        ],
        "x-scope": "contacts:write"
      },
      "get": {
        "externalDocs": {
          "description": "Guía: CRM y contactos",
          "url": "https://developers.meteor.com.co/guias/contactos.html"
        },
        "operationId": "ContactsController_findOne",
        "parameters": [
          {
            "description": "ID del contacto del CRM.",
            "in": "path",
            "name": "contactId",
            "required": true,
            "schema": {
              "type": "number"
            }
          }
        ],
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "allOf": [
                    {
                      "$ref": "#/components/schemas/ApiEnvelope"
                    },
                    {
                      "properties": {
                        "data": {
                          "$ref": "#/components/schemas/ContactRecordDto"
                        }
                      },
                      "required": [
                        "data"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": ""
          },
          "400": {
            "$ref": "#/components/responses/ApiErrorInvalidRequest"
          },
          "401": {
            "$ref": "#/components/responses/ApiErrorAuth"
          },
          "403": {
            "$ref": "#/components/responses/ApiErrorForbidden"
          },
          "404": {
            "$ref": "#/components/responses/ApiErrorNotFound"
          },
          "429": {
            "$ref": "#/components/responses/ApiErrorRateLimit"
          },
          "500": {
            "$ref": "#/components/responses/ApiErrorServer"
          }
        },
        "security": [
          {
            "bearer": []
          },
          {
            "api-key": []
          }
        ],
        "summary": "Obtiene el detalle del contacto",
        "tags": [
          "Contacts"
        ],
        "x-scope": "contacts:read"
      },
      "patch": {
        "description": "Devuelve el contacto ya actualizado. Los campos van dentro de `data` y el merge es **superficial**: las claves que no mandes quedan como estaban, y mandar `null` guarda un null (no borra la clave). Recordá la convención: sistema con `$` (`$name`, `$status`), personalizados con su `field_key` pelado (`etapa`, `monto`).",
        "externalDocs": {
          "description": "Guía: CRM y contactos",
          "url": "https://developers.meteor.com.co/guias/contactos.html"
        },
        "operationId": "ContactsController_update",
        "parameters": [
          {
            "description": "ID del contacto del CRM.",
            "in": "path",
            "name": "contactId",
            "required": true,
            "schema": {
              "type": "number"
            }
          }
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/UpdateContactDto"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "allOf": [
                    {
                      "$ref": "#/components/schemas/ApiEnvelope"
                    },
                    {
                      "properties": {
                        "data": {
                          "$ref": "#/components/schemas/ContactRecordDto"
                        }
                      },
                      "required": [
                        "data"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": ""
          },
          "400": {
            "$ref": "#/components/responses/ApiErrorInvalidRequest"
          },
          "401": {
            "$ref": "#/components/responses/ApiErrorAuth"
          },
          "403": {
            "$ref": "#/components/responses/ApiErrorForbidden"
          },
          "404": {
            "$ref": "#/components/responses/ApiErrorNotFound"
          },
          "409": {
            "$ref": "#/components/responses/ApiErrorConflict"
          },
          "429": {
            "$ref": "#/components/responses/ApiErrorRateLimit"
          },
          "500": {
            "$ref": "#/components/responses/ApiErrorServer"
          }
        },
        "security": [
          {
            "bearer": []
          },
          {
            "api-key": []
          }
        ],
        "summary": "Actualiza el contacto",
        "tags": [
          "Contacts"
        ],
        "x-scope": "contacts:write"
      }
    },
    "/contacts/{contactId}/autopilot": {
      "post": {
        "description": "Devuelve el contacto actualizado: el estado resultante se lee en `data.$autopilot_enabled`. Apagarlo emite el evento saliente `conversation.handoff`; prenderlo descarta cualquier pausa temporal vigente.",
        "externalDocs": {
          "description": "Guía: CRM y contactos",
          "url": "https://developers.meteor.com.co/guias/contactos.html"
        },
        "operationId": "ContactsController_setAutopilot",
        "parameters": [
          {
            "description": "ID del contacto del CRM.",
            "in": "path",
            "name": "contactId",
            "required": true,
            "schema": {
              "type": "number"
            }
          }
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/SetAutopilotDto"
              }
            }
          },
          "required": true
        },
        "responses": {
          "201": {
            "content": {
              "application/json": {
                "schema": {
                  "allOf": [
                    {
                      "$ref": "#/components/schemas/ApiEnvelope"
                    },
                    {
                      "properties": {
                        "data": {
                          "$ref": "#/components/schemas/ContactRecordDto"
                        }
                      },
                      "required": [
                        "data"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": ""
          },
          "400": {
            "$ref": "#/components/responses/ApiErrorInvalidRequest"
          },
          "401": {
            "$ref": "#/components/responses/ApiErrorAuth"
          },
          "403": {
            "$ref": "#/components/responses/ApiErrorForbidden"
          },
          "404": {
            "$ref": "#/components/responses/ApiErrorNotFound"
          },
          "409": {
            "$ref": "#/components/responses/ApiErrorConflict"
          },
          "429": {
            "$ref": "#/components/responses/ApiErrorRateLimit"
          },
          "500": {
            "$ref": "#/components/responses/ApiErrorServer"
          }
        },
        "security": [
          {
            "bearer": []
          },
          {
            "api-key": []
          }
        ],
        "summary": "Configura el autopiloto del contacto (explícito con enabled, alterna si se omite)",
        "tags": [
          "Contacts"
        ],
        "x-scope": "handoff:manage"
      }
    },
    "/contacts/{contactId}/autopilot/pause": {
      "post": {
        "externalDocs": {
          "description": "Guía: CRM y contactos",
          "url": "https://developers.meteor.com.co/guias/contactos.html"
        },
        "operationId": "ContactsController_pauseAutopilot",
        "parameters": [
          {
            "description": "ID del contacto del CRM.",
            "in": "path",
            "name": "contactId",
            "required": true,
            "schema": {
              "type": "number"
            }
          }
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/PauseAutopilotDto"
              }
            }
          },
          "required": true
        },
        "responses": {
          "201": {
            "content": {
              "application/json": {
                "schema": {
                  "allOf": [
                    {
                      "$ref": "#/components/schemas/ApiEnvelope"
                    },
                    {
                      "properties": {
                        "data": {
                          "$ref": "#/components/schemas/AutopilotPauseResultDto"
                        }
                      },
                      "required": [
                        "data"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": ""
          },
          "400": {
            "$ref": "#/components/responses/ApiErrorInvalidRequest"
          },
          "401": {
            "$ref": "#/components/responses/ApiErrorAuth"
          },
          "403": {
            "$ref": "#/components/responses/ApiErrorForbidden"
          },
          "404": {
            "$ref": "#/components/responses/ApiErrorNotFound"
          },
          "409": {
            "$ref": "#/components/responses/ApiErrorConflict"
          },
          "429": {
            "$ref": "#/components/responses/ApiErrorRateLimit"
          },
          "500": {
            "$ref": "#/components/responses/ApiErrorServer"
          }
        },
        "security": [
          {
            "bearer": []
          },
          {
            "api-key": []
          }
        ],
        "summary": "Pausa el autopiloto por N minutos (0 = reanuda ahora)",
        "tags": [
          "Contacts"
        ],
        "x-scope": "handoff:manage"
      }
    },
    "/contacts/{contactId}/linked-items": {
      "get": {
        "externalDocs": {
          "description": "Guía: CRM y contactos",
          "url": "https://developers.meteor.com.co/guias/contactos.html"
        },
        "operationId": "ContactsController_getLinkedItems",
        "parameters": [
          {
            "description": "ID del contacto del CRM.",
            "in": "path",
            "name": "contactId",
            "required": true,
            "schema": {
              "type": "number"
            }
          }
        ],
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "allOf": [
                    {
                      "$ref": "#/components/schemas/ApiEnvelope"
                    },
                    {
                      "properties": {
                        "data": {
                          "items": {
                            "$ref": "#/components/schemas/LinkedItemDto"
                          },
                          "type": "array"
                        }
                      },
                      "required": [
                        "data"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": ""
          },
          "400": {
            "$ref": "#/components/responses/ApiErrorInvalidRequest"
          },
          "401": {
            "$ref": "#/components/responses/ApiErrorAuth"
          },
          "403": {
            "$ref": "#/components/responses/ApiErrorForbidden"
          },
          "404": {
            "$ref": "#/components/responses/ApiErrorNotFound"
          },
          "429": {
            "$ref": "#/components/responses/ApiErrorRateLimit"
          },
          "500": {
            "$ref": "#/components/responses/ApiErrorServer"
          }
        },
        "security": [
          {
            "bearer": []
          },
          {
            "api-key": []
          }
        ],
        "summary": "Items de colecciones que referencian a este contacto (campo tipo contact)",
        "tags": [
          "Contacts"
        ],
        "x-scope": "contacts:read"
      }
    },
    "/contacts/{contactId}/mark-read": {
      "post": {
        "externalDocs": {
          "description": "Guía: CRM y contactos",
          "url": "https://developers.meteor.com.co/guias/contactos.html"
        },
        "operationId": "ContactsController_markRead",
        "parameters": [
          {
            "description": "ID del contacto del CRM.",
            "in": "path",
            "name": "contactId",
            "required": true,
            "schema": {
              "type": "number"
            }
          }
        ],
        "responses": {
          "201": {
            "content": {
              "application/json": {
                "schema": {
                  "allOf": [
                    {
                      "$ref": "#/components/schemas/ApiEnvelope"
                    },
                    {
                      "properties": {
                        "data": {
                          "$ref": "#/components/schemas/OkResultDto"
                        }
                      },
                      "required": [
                        "data"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": ""
          },
          "400": {
            "$ref": "#/components/responses/ApiErrorInvalidRequest"
          },
          "401": {
            "$ref": "#/components/responses/ApiErrorAuth"
          },
          "403": {
            "$ref": "#/components/responses/ApiErrorForbidden"
          },
          "404": {
            "$ref": "#/components/responses/ApiErrorNotFound"
          },
          "409": {
            "$ref": "#/components/responses/ApiErrorConflict"
          },
          "429": {
            "$ref": "#/components/responses/ApiErrorRateLimit"
          },
          "500": {
            "$ref": "#/components/responses/ApiErrorServer"
          }
        },
        "security": [
          {
            "bearer": []
          },
          {
            "api-key": []
          }
        ],
        "summary": "Marca la conversación del contacto como leída",
        "tags": [
          "Contacts"
        ],
        "x-scope": "handoff:manage"
      }
    },
    "/contacts/{contactId}/messages": {
      "get": {
        "description": "Devuelve **un array plano** en orden cronológico, del mensaje más viejo al más nuevo.\n\n**Sin parámetros devuelve el hilo COMPLETO**, como siempre. Es el comportamiento por defecto y no cambió: si ya integrabas contra este endpoint, no tenés que tocar nada.\n\nCon **`limit`** (1–200) devuelve en cambio la ventana MÁS RECIENTE — los últimos N mensajes, igual en orden cronológico. Para seguir hacia atrás, mandá **`before`** con el `id` del mensaje más viejo que ya tenés y recibís la ventana anterior.\n\nNo hay campo `has_more`: si volvieron menos de `limit` mensajes, llegaste al principio de la conversación.\n\nQuién habló se lee en **`role`** (`user` = el contacto, `operator` = tu equipo, `agent` = el Met). No existe un campo `direction`.\n\n**Ojo con el scope**: aunque la ruta cuelga de `/contacts`, este endpoint pide `conversations:read`, no `contacts:read`. Una key emitida solo con `contacts:read` / `contacts:write` lista contactos pero recibe `403 missing_scope` acá. Es la causa más frecuente de error en este endpoint.\n\nUn `404 Contacto no encontrado` no distingue entre \"no existe\", \"no es de tu workspace\" y \"tu usuario no lo tiene a la vista\": se responde igual en los tres casos, a propósito, para no confirmar la existencia de contactos ajenos.",
        "externalDocs": {
          "description": "Guía: CRM y contactos",
          "url": "https://developers.meteor.com.co/guias/contactos.html"
        },
        "operationId": "ContactsController_getMessages",
        "parameters": [
          {
            "description": "ID del contacto del CRM.",
            "in": "path",
            "name": "contactId",
            "required": true,
            "schema": {
              "type": "number"
            }
          },
          {
            "description": "Devuelve solo los últimos N mensajes (1–200). Omitilo para el hilo completo.",
            "in": "query",
            "name": "limit",
            "required": false,
            "schema": {
              "type": "number"
            }
          },
          {
            "description": "Id del mensaje más viejo que ya tenés: devuelve la ventana anterior a ese. Requiere `limit`.",
            "in": "query",
            "name": "before",
            "required": false,
            "schema": {
              "type": "number"
            }
          }
        ],
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "allOf": [
                    {
                      "$ref": "#/components/schemas/ApiEnvelope"
                    },
                    {
                      "properties": {
                        "data": {
                          "items": {
                            "$ref": "#/components/schemas/ContactMessageDto"
                          },
                          "type": "array"
                        }
                      },
                      "required": [
                        "data"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": ""
          },
          "400": {
            "$ref": "#/components/responses/ApiErrorInvalidRequest"
          },
          "401": {
            "$ref": "#/components/responses/ApiErrorAuth"
          },
          "403": {
            "$ref": "#/components/responses/ApiErrorForbidden"
          },
          "404": {
            "$ref": "#/components/responses/ApiErrorNotFound"
          },
          "429": {
            "$ref": "#/components/responses/ApiErrorRateLimit"
          },
          "500": {
            "$ref": "#/components/responses/ApiErrorServer"
          }
        },
        "security": [
          {
            "bearer": []
          },
          {
            "api-key": []
          }
        ],
        "summary": "Obtiene los mensajes del contacto",
        "tags": [
          "Contacts"
        ],
        "x-scope": "conversations:read"
      },
      "post": {
        "description": "El mensaje **siempre** queda guardado en la conversación; `delivery.ok` dice si además salió por el canal. Un `2xx` con `delivery.ok: false` significa \"quedó registrado pero no le llegó al contacto\" — hay que mirarlo, no alcanza con el código HTTP.\n\nEl envío pausa el piloto automático por los minutos que tenga configurados el workspace (`paused_until` en la respuesta).\n\nPide el scope `channels:send`, no `contacts:write`. Una key de test (`met_test_`) no puede ejercerlo: devuelve `403 test_mode_restricted`.",
        "externalDocs": {
          "description": "Guía: CRM y contactos",
          "url": "https://developers.meteor.com.co/guias/contactos.html"
        },
        "operationId": "ContactsController_sendMessage",
        "parameters": [
          {
            "description": "ID del contacto del CRM.",
            "in": "path",
            "name": "contactId",
            "required": true,
            "schema": {
              "type": "number"
            }
          }
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/SendContactMessageDto"
              }
            }
          },
          "required": true
        },
        "responses": {
          "201": {
            "content": {
              "application/json": {
                "schema": {
                  "allOf": [
                    {
                      "$ref": "#/components/schemas/ApiEnvelope"
                    },
                    {
                      "properties": {
                        "data": {
                          "$ref": "#/components/schemas/SendMessageResponseDto"
                        }
                      },
                      "required": [
                        "data"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": ""
          },
          "400": {
            "$ref": "#/components/responses/ApiErrorInvalidRequest"
          },
          "401": {
            "$ref": "#/components/responses/ApiErrorAuth"
          },
          "403": {
            "$ref": "#/components/responses/ApiErrorForbidden"
          },
          "404": {
            "$ref": "#/components/responses/ApiErrorNotFound"
          },
          "409": {
            "$ref": "#/components/responses/ApiErrorConflict"
          },
          "429": {
            "$ref": "#/components/responses/ApiErrorRateLimit"
          },
          "500": {
            "$ref": "#/components/responses/ApiErrorServer"
          }
        },
        "security": [
          {
            "bearer": []
          },
          {
            "api-key": []
          }
        ],
        "summary": "Envía un mensaje al contacto (como operador)",
        "tags": [
          "Contacts"
        ],
        "x-scope": "channels:send"
      }
    },
    "/contacts/{contactId}/messages/search": {
      "get": {
        "description": "Coincidencia por substring, sin distinguir mayúsculas, sobre el texto del mensaje. Del más viejo al más nuevo, topeado en 50. Sin `q` devuelve `[]` sin consultar.",
        "externalDocs": {
          "description": "Guía: CRM y contactos",
          "url": "https://developers.meteor.com.co/guias/contactos.html"
        },
        "operationId": "ContactsController_searchMessages",
        "parameters": [
          {
            "description": "ID del contacto del CRM.",
            "in": "path",
            "name": "contactId",
            "required": true,
            "schema": {
              "type": "number"
            }
          },
          {
            "description": "Texto a buscar.",
            "in": "query",
            "name": "q",
            "required": true,
            "schema": {
              "type": "string"
            }
          }
        ],
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "allOf": [
                    {
                      "$ref": "#/components/schemas/ApiEnvelope"
                    },
                    {
                      "properties": {
                        "data": {
                          "items": {
                            "$ref": "#/components/schemas/ContactMessageSearchResultDto"
                          },
                          "type": "array"
                        }
                      },
                      "required": [
                        "data"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": ""
          },
          "400": {
            "$ref": "#/components/responses/ApiErrorInvalidRequest"
          },
          "401": {
            "$ref": "#/components/responses/ApiErrorAuth"
          },
          "403": {
            "$ref": "#/components/responses/ApiErrorForbidden"
          },
          "404": {
            "$ref": "#/components/responses/ApiErrorNotFound"
          },
          "429": {
            "$ref": "#/components/responses/ApiErrorRateLimit"
          },
          "500": {
            "$ref": "#/components/responses/ApiErrorServer"
          }
        },
        "security": [
          {
            "bearer": []
          },
          {
            "api-key": []
          }
        ],
        "summary": "Busca mensajes en la conversación",
        "tags": [
          "Contacts"
        ],
        "x-scope": "conversations:read"
      }
    },
    "/contacts/{contactId}/messages/template": {
      "post": {
        "description": "Enruta según el canal del contacto: Meteor CRM (uChat) o WhatsApp directo (Cloud API). Cualquier otro tipo de canal se rechaza con 400.\n\nComo en un mensaje normal, la fila queda guardada aunque el proveedor rechace: mirá `delivery.ok` y no solo el código HTTP. `delivery.upstream` es la respuesta cruda del proveedor y su forma la define él, no Meteor.\n\nPide el scope `channels:send`, que una key de test no puede ejercer (`403 test_mode_restricted`).",
        "externalDocs": {
          "description": "Guía: CRM y contactos",
          "url": "https://developers.meteor.com.co/guias/contactos.html"
        },
        "operationId": "ContactsController_sendTemplate",
        "parameters": [
          {
            "description": "ID del contacto del CRM.",
            "in": "path",
            "name": "contactId",
            "required": true,
            "schema": {
              "type": "number"
            }
          }
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/SendTemplateDto"
              }
            }
          },
          "required": true
        },
        "responses": {
          "201": {
            "content": {
              "application/json": {
                "schema": {
                  "allOf": [
                    {
                      "$ref": "#/components/schemas/ApiEnvelope"
                    },
                    {
                      "properties": {
                        "data": {
                          "$ref": "#/components/schemas/SendTemplateResponseDto"
                        }
                      },
                      "required": [
                        "data"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": ""
          },
          "400": {
            "$ref": "#/components/responses/ApiErrorInvalidRequest"
          },
          "401": {
            "$ref": "#/components/responses/ApiErrorAuth"
          },
          "403": {
            "$ref": "#/components/responses/ApiErrorForbidden"
          },
          "404": {
            "$ref": "#/components/responses/ApiErrorNotFound"
          },
          "409": {
            "$ref": "#/components/responses/ApiErrorConflict"
          },
          "429": {
            "$ref": "#/components/responses/ApiErrorRateLimit"
          },
          "500": {
            "$ref": "#/components/responses/ApiErrorServer"
          }
        },
        "security": [
          {
            "bearer": []
          },
          {
            "api-key": []
          }
        ],
        "summary": "Envía una plantilla de WhatsApp al contacto",
        "tags": [
          "Contacts"
        ],
        "x-scope": "channels:send"
      }
    },
    "/contacts/{contactId}/notes": {
      "get": {
        "description": "De la más reciente a la más vieja, topeado en 200. No pagina.",
        "externalDocs": {
          "description": "Guía: CRM y contactos",
          "url": "https://developers.meteor.com.co/guias/contactos.html"
        },
        "operationId": "ContactsController_getNotes",
        "parameters": [
          {
            "description": "ID del contacto del CRM.",
            "in": "path",
            "name": "contactId",
            "required": true,
            "schema": {
              "type": "number"
            }
          }
        ],
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "allOf": [
                    {
                      "$ref": "#/components/schemas/ApiEnvelope"
                    },
                    {
                      "properties": {
                        "data": {
                          "items": {
                            "$ref": "#/components/schemas/ContactNoteDto"
                          },
                          "type": "array"
                        }
                      },
                      "required": [
                        "data"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": ""
          },
          "400": {
            "$ref": "#/components/responses/ApiErrorInvalidRequest"
          },
          "401": {
            "$ref": "#/components/responses/ApiErrorAuth"
          },
          "403": {
            "$ref": "#/components/responses/ApiErrorForbidden"
          },
          "404": {
            "$ref": "#/components/responses/ApiErrorNotFound"
          },
          "429": {
            "$ref": "#/components/responses/ApiErrorRateLimit"
          },
          "500": {
            "$ref": "#/components/responses/ApiErrorServer"
          }
        },
        "security": [
          {
            "bearer": []
          },
          {
            "api-key": []
          }
        ],
        "summary": "Obtiene las notas internas del contacto",
        "tags": [
          "Contacts"
        ],
        "x-scope": "contacts:read"
      },
      "post": {
        "description": "La nota es un mensaje de la conversación con `message_type: \"note\"`: queda en el historial del equipo y **nunca se le envía al contacto**. Por eso exige que el contacto tenga un canal vinculado; sin él responde 400.",
        "externalDocs": {
          "description": "Guía: CRM y contactos",
          "url": "https://developers.meteor.com.co/guias/contactos.html"
        },
        "operationId": "ContactsController_createNote",
        "parameters": [
          {
            "description": "ID del contacto del CRM.",
            "in": "path",
            "name": "contactId",
            "required": true,
            "schema": {
              "type": "number"
            }
          }
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/CreateNoteDto"
              }
            }
          },
          "required": true
        },
        "responses": {
          "201": {
            "content": {
              "application/json": {
                "schema": {
                  "allOf": [
                    {
                      "$ref": "#/components/schemas/ApiEnvelope"
                    },
                    {
                      "properties": {
                        "data": {
                          "$ref": "#/components/schemas/ContactMessageDto"
                        }
                      },
                      "required": [
                        "data"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": ""
          },
          "400": {
            "$ref": "#/components/responses/ApiErrorInvalidRequest"
          },
          "401": {
            "$ref": "#/components/responses/ApiErrorAuth"
          },
          "403": {
            "$ref": "#/components/responses/ApiErrorForbidden"
          },
          "404": {
            "$ref": "#/components/responses/ApiErrorNotFound"
          },
          "409": {
            "$ref": "#/components/responses/ApiErrorConflict"
          },
          "429": {
            "$ref": "#/components/responses/ApiErrorRateLimit"
          },
          "500": {
            "$ref": "#/components/responses/ApiErrorServer"
          }
        },
        "security": [
          {
            "bearer": []
          },
          {
            "api-key": []
          }
        ],
        "summary": "Crea una nota interna para el contacto",
        "tags": [
          "Contacts"
        ],
        "x-scope": "contacts:write"
      }
    },
    "/contacts/{contactId}/tags": {
      "get": {
        "description": "Un array de strings: el contenido de `data.$tags`. Vacío si no tiene ninguna.",
        "externalDocs": {
          "description": "Guía: CRM y contactos",
          "url": "https://developers.meteor.com.co/guias/contactos.html"
        },
        "operationId": "ContactsController_getTags",
        "parameters": [
          {
            "description": "ID del contacto del CRM.",
            "in": "path",
            "name": "contactId",
            "required": true,
            "schema": {
              "type": "number"
            }
          }
        ],
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "allOf": [
                    {
                      "$ref": "#/components/schemas/ApiEnvelope"
                    },
                    {
                      "properties": {
                        "data": {
                          "items": {
                            "type": "string"
                          },
                          "type": "array"
                        }
                      },
                      "required": [
                        "data"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": ""
          },
          "400": {
            "$ref": "#/components/responses/ApiErrorInvalidRequest"
          },
          "401": {
            "$ref": "#/components/responses/ApiErrorAuth"
          },
          "403": {
            "$ref": "#/components/responses/ApiErrorForbidden"
          },
          "404": {
            "$ref": "#/components/responses/ApiErrorNotFound"
          },
          "429": {
            "$ref": "#/components/responses/ApiErrorRateLimit"
          },
          "500": {
            "$ref": "#/components/responses/ApiErrorServer"
          }
        },
        "security": [
          {
            "bearer": []
          },
          {
            "api-key": []
          }
        ],
        "summary": "Obtiene las etiquetas del contacto",
        "tags": [
          "Contacts"
        ],
        "x-scope": "contacts:read"
      },
      "post": {
        "description": "Devuelve el contacto actualizado; las etiquetas se leen en `data.$tags`. Es idempotente: si ya la tenía, devuelve el contacto sin cambios.",
        "externalDocs": {
          "description": "Guía: CRM y contactos",
          "url": "https://developers.meteor.com.co/guias/contactos.html"
        },
        "operationId": "ContactsController_addTag",
        "parameters": [
          {
            "description": "ID del contacto del CRM.",
            "in": "path",
            "name": "contactId",
            "required": true,
            "schema": {
              "type": "number"
            }
          }
        ],
        "responses": {
          "201": {
            "content": {
              "application/json": {
                "schema": {
                  "allOf": [
                    {
                      "$ref": "#/components/schemas/ApiEnvelope"
                    },
                    {
                      "properties": {
                        "data": {
                          "$ref": "#/components/schemas/ContactRecordDto"
                        }
                      },
                      "required": [
                        "data"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": ""
          },
          "400": {
            "$ref": "#/components/responses/ApiErrorInvalidRequest"
          },
          "401": {
            "$ref": "#/components/responses/ApiErrorAuth"
          },
          "403": {
            "$ref": "#/components/responses/ApiErrorForbidden"
          },
          "404": {
            "$ref": "#/components/responses/ApiErrorNotFound"
          },
          "409": {
            "$ref": "#/components/responses/ApiErrorConflict"
          },
          "429": {
            "$ref": "#/components/responses/ApiErrorRateLimit"
          },
          "500": {
            "$ref": "#/components/responses/ApiErrorServer"
          }
        },
        "security": [
          {
            "bearer": []
          },
          {
            "api-key": []
          }
        ],
        "summary": "Agrega una etiqueta al contacto",
        "tags": [
          "Contacts"
        ],
        "x-scope": "contacts:write"
      }
    },
    "/contacts/{contactId}/tags/{tag}": {
      "delete": {
        "description": "Devuelve el contacto actualizado. Si no tenía la etiqueta, devuelve el contacto sin cambios en vez de fallar. La etiqueta va URL-encoded en la ruta.",
        "externalDocs": {
          "description": "Guía: CRM y contactos",
          "url": "https://developers.meteor.com.co/guias/contactos.html"
        },
        "operationId": "ContactsController_removeTag",
        "parameters": [
          {
            "description": "ID del contacto del CRM.",
            "in": "path",
            "name": "contactId",
            "required": true,
            "schema": {
              "type": "number"
            }
          },
          {
            "description": "Nombre de la etiqueta.",
            "in": "path",
            "name": "tag",
            "required": true,
            "schema": {
              "type": "string"
            }
          }
        ],
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "allOf": [
                    {
                      "$ref": "#/components/schemas/ApiEnvelope"
                    },
                    {
                      "properties": {
                        "data": {
                          "$ref": "#/components/schemas/ContactRecordDto"
                        }
                      },
                      "required": [
                        "data"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": ""
          },
          "400": {
            "$ref": "#/components/responses/ApiErrorInvalidRequest"
          },
          "401": {
            "$ref": "#/components/responses/ApiErrorAuth"
          },
          "403": {
            "$ref": "#/components/responses/ApiErrorForbidden"
          },
          "404": {
            "$ref": "#/components/responses/ApiErrorNotFound"
          },
          "409": {
            "$ref": "#/components/responses/ApiErrorConflict"
          },
          "429": {
            "$ref": "#/components/responses/ApiErrorRateLimit"
          },
          "500": {
            "$ref": "#/components/responses/ApiErrorServer"
          }
        },
        "security": [
          {
            "bearer": []
          },
          {
            "api-key": []
          }
        ],
        "summary": "Elimina una etiqueta del contacto",
        "tags": [
          "Contacts"
        ],
        "x-scope": "contacts:write"
      }
    },
    "/contacts/{contactId}/tool-calls": {
      "get": {
        "description": "De la más reciente a la más vieja. `limit` va entre 1 y 200 (default 50). `input` y `output` conservan el JSON de la invocación, recortado a 50 KB al persistir.",
        "externalDocs": {
          "description": "Guía: CRM y contactos",
          "url": "https://developers.meteor.com.co/guias/contactos.html"
        },
        "operationId": "ContactsController_getToolCalls",
        "parameters": [
          {
            "description": "ID del contacto del CRM.",
            "in": "path",
            "name": "contactId",
            "required": true,
            "schema": {
              "type": "number"
            }
          }
        ],
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "allOf": [
                    {
                      "$ref": "#/components/schemas/ApiEnvelope"
                    },
                    {
                      "properties": {
                        "data": {
                          "items": {
                            "$ref": "#/components/schemas/ContactToolCallDto"
                          },
                          "type": "array"
                        }
                      },
                      "required": [
                        "data"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": ""
          },
          "400": {
            "$ref": "#/components/responses/ApiErrorInvalidRequest"
          },
          "401": {
            "$ref": "#/components/responses/ApiErrorAuth"
          },
          "403": {
            "$ref": "#/components/responses/ApiErrorForbidden"
          },
          "404": {
            "$ref": "#/components/responses/ApiErrorNotFound"
          },
          "429": {
            "$ref": "#/components/responses/ApiErrorRateLimit"
          },
          "500": {
            "$ref": "#/components/responses/ApiErrorServer"
          }
        },
        "security": [
          {
            "bearer": []
          },
          {
            "api-key": []
          }
        ],
        "summary": "Tool calls (MCP) realizadas para este contacto, JSON crudo",
        "tags": [
          "Contacts"
        ],
        "x-scope": "conversations:read"
      }
    },
    "/contacts/{id}/duplicates": {
      "get": {
        "description": "Solo lectura. El match de teléfono tolera formatos (con/sin código de país); el de email ignora mayúsculas; el de `identidad` compara el `user_ns` canónico junto con el canal y la línea, y es el que encuentra los gemelos exactos. Cada candidato trae `can_merge`: es `false` cuando los dos contactos tienen conversación propia Y son identidades distintas, porque fusionarlos perdería una. Dos filas de la MISMA identidad sí se pueden fusionar.",
        "externalDocs": {
          "description": "Guía: CRM y contactos",
          "url": "https://developers.meteor.com.co/guias/contactos.html"
        },
        "operationId": "ContactsController_getDuplicates",
        "parameters": [
          {
            "description": "ID del recurso de esta ruta.",
            "in": "path",
            "name": "id",
            "required": true,
            "schema": {
              "type": "number"
            }
          }
        ],
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "allOf": [
                    {
                      "$ref": "#/components/schemas/ApiEnvelope"
                    },
                    {
                      "properties": {
                        "data": {
                          "$ref": "#/components/schemas/ContactDuplicatesResponseDto"
                        }
                      },
                      "required": [
                        "data"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": ""
          },
          "400": {
            "$ref": "#/components/responses/ApiErrorInvalidRequest"
          },
          "401": {
            "$ref": "#/components/responses/ApiErrorAuth"
          },
          "403": {
            "$ref": "#/components/responses/ApiErrorForbidden"
          },
          "404": {
            "$ref": "#/components/responses/ApiErrorNotFound"
          },
          "429": {
            "$ref": "#/components/responses/ApiErrorRateLimit"
          },
          "500": {
            "$ref": "#/components/responses/ApiErrorServer"
          }
        },
        "security": [
          {
            "bearer": []
          },
          {
            "api-key": []
          }
        ],
        "summary": "Posibles duplicados de un contacto (misma identidad, teléfono o email)",
        "tags": [
          "Contacts"
        ],
        "x-scope": "contacts:read"
      }
    },
    "/contacts/{id}/enrich": {
      "post": {
        "description": "Busca al contacto en Google por su nombre (más el dominio de su correo corporativo, si tiene), lee las páginas que encuentra y completa **solo los campos vacíos**: `empresa`, `cargo`, `$city`, `$country`. Devuelve `filled` con lo que completó y `sources` con las URLs de donde salió; también deja una nota en el contacto con esas fuentes.\n\nEs **bajo demanda** a propósito: sale a internet, cuesta más que analizar un chat y puede encontrar a un homónimo. El modelo tiene instrucción de omitir cualquier dato que no pueda confirmar que es de esta persona, pero las fuentes se citan para que un humano lo audite.\n\n**Consume energía.** Requiere que el workspace tenga el enriquecimiento habilitado (`crm_enrichment_enabled`); apagado devuelve `filled: []` sin buscar ni cobrar. Un contacto sin `$name` no se busca.",
        "externalDocs": {
          "description": "Guía: CRM y contactos",
          "url": "https://developers.meteor.com.co/guias/contactos.html"
        },
        "operationId": "ContactsController_enrich",
        "parameters": [
          {
            "description": "ID del recurso de esta ruta.",
            "in": "path",
            "name": "id",
            "required": true,
            "schema": {
              "type": "number"
            }
          }
        ],
        "responses": {
          "201": {
            "content": {
              "application/json": {
                "schema": {
                  "allOf": [
                    {
                      "$ref": "#/components/schemas/ApiEnvelope"
                    },
                    {
                      "properties": {
                        "data": {
                          "$ref": "#/components/schemas/ContactEnrichResultDto"
                        }
                      },
                      "required": [
                        "data"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": ""
          },
          "400": {
            "$ref": "#/components/responses/ApiErrorInvalidRequest"
          },
          "401": {
            "$ref": "#/components/responses/ApiErrorAuth"
          },
          "403": {
            "$ref": "#/components/responses/ApiErrorForbidden"
          },
          "404": {
            "$ref": "#/components/responses/ApiErrorNotFound"
          },
          "409": {
            "$ref": "#/components/responses/ApiErrorConflict"
          },
          "429": {
            "$ref": "#/components/responses/ApiErrorRateLimit"
          },
          "500": {
            "$ref": "#/components/responses/ApiErrorServer"
          }
        },
        "security": [
          {
            "bearer": []
          },
          {
            "api-key": []
          }
        ],
        "summary": "Completa la ficha del contacto buscándolo en la web (IA)",
        "tags": [
          "Contacts"
        ],
        "x-scope": "contacts:write"
      }
    },
    "/contacts/{id}/extract": {
      "post": {
        "description": "Lee la conversación una sola vez y devuelve dos cosas:\n\n- **`filled`**: los campos de ficha que se completaron con lo que el contacto dijo en el chat. Llena SOLO los campos vacíos — nunca pisa un dato existente. Incluye los campos personalizados de tipo `text` del workspace (la descripción del campo es la pista que se le da al modelo); los de otros tipos no, porque el modelo devuelve texto.\n- **`lead_score`**: qué tan cerca de comprar está (0-100), con el motivo en el campo `lead_score_motivo` del contacto. A diferencia de los campos, el score SÍ se recalcula en cada llamada: es un juicio, no un dato. El campo `etapa` es del humano y la IA no lo toca.\n\n**Consume energía** — una sola ejecución para ambas cosas, no dos. Requiere que el workspace tenga el análisis habilitado (`crm_extraction_enabled`); si está apagada devuelve `filled: []` y `lead_score: null` sin llamar al modelo ni cobrar.",
        "externalDocs": {
          "description": "Guía: CRM y contactos",
          "url": "https://developers.meteor.com.co/guias/contactos.html"
        },
        "operationId": "ContactsController_extract",
        "parameters": [
          {
            "description": "ID del recurso de esta ruta.",
            "in": "path",
            "name": "id",
            "required": true,
            "schema": {
              "type": "number"
            }
          }
        ],
        "responses": {
          "201": {
            "content": {
              "application/json": {
                "schema": {
                  "allOf": [
                    {
                      "$ref": "#/components/schemas/ApiEnvelope"
                    },
                    {
                      "properties": {
                        "data": {
                          "$ref": "#/components/schemas/ContactExtractResultDto"
                        }
                      },
                      "required": [
                        "data"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": ""
          },
          "400": {
            "$ref": "#/components/responses/ApiErrorInvalidRequest"
          },
          "401": {
            "$ref": "#/components/responses/ApiErrorAuth"
          },
          "403": {
            "$ref": "#/components/responses/ApiErrorForbidden"
          },
          "404": {
            "$ref": "#/components/responses/ApiErrorNotFound"
          },
          "409": {
            "$ref": "#/components/responses/ApiErrorConflict"
          },
          "429": {
            "$ref": "#/components/responses/ApiErrorRateLimit"
          },
          "500": {
            "$ref": "#/components/responses/ApiErrorServer"
          }
        },
        "security": [
          {
            "bearer": []
          },
          {
            "api-key": []
          }
        ],
        "summary": "Analiza la conversación: completa los campos vacíos y califica al contacto (IA)",
        "tags": [
          "Contacts"
        ],
        "x-scope": "contacts:write"
      }
    },
    "/contacts/{id}/timeline": {
      "get": {
        "description": "Une en una sola lista los hechos del contacto: cambios de campo, eventos de sistema (estado, asignación), notas internas y tareas de seguimiento. Cada entrada trae un `type` discriminador. NO incluye los mensajes de la conversación. Paginación por cursor: `before` = `created_at` de la última entrada recibida. `exclude` (lista separada por comas de `note`,`task`,`field_change`,`system_event`) omite esos tipos — lo usa el panel del chat, que muestra notas y tareas en sus propias secciones.",
        "externalDocs": {
          "description": "Guía: CRM y contactos",
          "url": "https://developers.meteor.com.co/guias/contactos.html"
        },
        "operationId": "ContactsController_getTimeline",
        "parameters": [
          {
            "description": "ID del recurso de esta ruta.",
            "in": "path",
            "name": "id",
            "required": true,
            "schema": {
              "type": "number"
            }
          }
        ],
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "allOf": [
                    {
                      "$ref": "#/components/schemas/ApiEnvelope"
                    },
                    {
                      "properties": {
                        "data": {
                          "$ref": "#/components/schemas/ContactTimelineResponseDto"
                        }
                      },
                      "required": [
                        "data"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": ""
          },
          "400": {
            "$ref": "#/components/responses/ApiErrorInvalidRequest"
          },
          "401": {
            "$ref": "#/components/responses/ApiErrorAuth"
          },
          "403": {
            "$ref": "#/components/responses/ApiErrorForbidden"
          },
          "404": {
            "$ref": "#/components/responses/ApiErrorNotFound"
          },
          "429": {
            "$ref": "#/components/responses/ApiErrorRateLimit"
          },
          "500": {
            "$ref": "#/components/responses/ApiErrorServer"
          }
        },
        "security": [
          {
            "bearer": []
          },
          {
            "api-key": []
          }
        ],
        "summary": "Línea de tiempo del contacto",
        "tags": [
          "Contacts"
        ],
        "x-scope": "contacts:read"
      }
    },
    "/conversions": {
      "post": {
        "externalDocs": {
          "description": "Guía: CRM y contactos",
          "url": "https://developers.meteor.com.co/guias/contactos.html"
        },
        "operationId": "PublicConversionsController_create",
        "parameters": [],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/CreateConversionDto"
              }
            }
          },
          "required": true
        },
        "responses": {
          "201": {
            "description": ""
          },
          "400": {
            "$ref": "#/components/responses/ApiErrorInvalidRequest"
          },
          "401": {
            "$ref": "#/components/responses/ApiErrorAuth"
          },
          "403": {
            "$ref": "#/components/responses/ApiErrorForbidden"
          },
          "404": {
            "$ref": "#/components/responses/ApiErrorNotFound"
          },
          "409": {
            "$ref": "#/components/responses/ApiErrorConflict"
          },
          "429": {
            "$ref": "#/components/responses/ApiErrorRateLimit"
          },
          "500": {
            "$ref": "#/components/responses/ApiErrorServer"
          }
        },
        "security": [
          {
            "bearer": []
          },
          {
            "api-key": []
          }
        ],
        "summary": "Reporta una conversión a Meta para un contacto (pasa por la compuerta)",
        "tags": [
          "Conversions"
        ],
        "x-scope": "conversions:write"
      }
    },
    "/conversions/web": {
      "post": {
        "externalDocs": {
          "description": "Guía: CRM y contactos",
          "url": "https://developers.meteor.com.co/guias/contactos.html"
        },
        "operationId": "PublicConversionsController_createWeb",
        "parameters": [],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/CreateWebConversionDto"
              }
            }
          },
          "required": true
        },
        "responses": {
          "201": {
            "description": ""
          },
          "400": {
            "$ref": "#/components/responses/ApiErrorInvalidRequest"
          },
          "401": {
            "$ref": "#/components/responses/ApiErrorAuth"
          },
          "403": {
            "$ref": "#/components/responses/ApiErrorForbidden"
          },
          "404": {
            "$ref": "#/components/responses/ApiErrorNotFound"
          },
          "409": {
            "$ref": "#/components/responses/ApiErrorConflict"
          },
          "429": {
            "$ref": "#/components/responses/ApiErrorRateLimit"
          },
          "500": {
            "$ref": "#/components/responses/ApiErrorServer"
          }
        },
        "security": [
          {
            "bearer": []
          },
          {
            "api-key": []
          }
        ],
        "summary": "Reporta una conversión web (Pixel) a Meta — espejo server-side con dedup por event_id",
        "tags": [
          "Conversions"
        ],
        "x-scope": "conversions:write"
      }
    },
    "/events/stream": {
      "get": {
        "externalDocs": {
          "description": "Guía: Eventos en vivo",
          "url": "https://developers.meteor.com.co/guias/eventos.html"
        },
        "operationId": "EventsController_stream",
        "parameters": [
          {
            "description": "Lista de tipos separados por coma.",
            "in": "query",
            "name": "types",
            "required": true,
            "schema": {
              "type": "string"
            }
          }
        ],
        "responses": {
          "200": {
            "content": {
              "text/event-stream": {
                "schema": {
                  "$ref": "#/components/schemas/EventEnvelopeDto"
                }
              }
            },
            "description": "Stream `text/event-stream`, no una respuesta que termina. El primer cuadro es `event: ready` con un `EventStreamReadyDto` (confirma workspace y `livemode`); después llega un `event: message` por cada evento, con el envelope que se documenta aquí — el mismo que se firma y se entrega a un webhook saliente."
          },
          "400": {
            "$ref": "#/components/responses/ApiErrorInvalidRequest"
          },
          "401": {
            "$ref": "#/components/responses/ApiErrorAuth"
          },
          "403": {
            "$ref": "#/components/responses/ApiErrorForbidden"
          },
          "404": {
            "$ref": "#/components/responses/ApiErrorNotFound"
          },
          "429": {
            "$ref": "#/components/responses/ApiErrorRateLimit"
          },
          "500": {
            "$ref": "#/components/responses/ApiErrorServer"
          }
        },
        "security": [
          {
            "bearer": []
          },
          {
            "api-key": []
          }
        ],
        "summary": "Stream de eventos del workspace en vivo (SSE) — `met listen`",
        "tags": [
          "Events"
        ],
        "x-scope": "events:read"
      }
    },
    "/fields/{fieldId}": {
      "delete": {
        "externalDocs": {
          "description": "Guía: Datos: colecciones e ítems",
          "url": "https://developers.meteor.com.co/guias/colecciones-e-items.html"
        },
        "operationId": "CollectionsController_removeField",
        "parameters": [
          {
            "description": "ID del campo de la colección.",
            "in": "path",
            "name": "fieldId",
            "required": true,
            "schema": {
              "type": "number"
            }
          }
        ],
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "allOf": [
                    {
                      "$ref": "#/components/schemas/ApiEnvelope"
                    },
                    {
                      "properties": {
                        "data": {
                          "$ref": "#/components/schemas/CollectionMessageResponseDto"
                        }
                      },
                      "required": [
                        "data"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": ""
          },
          "400": {
            "$ref": "#/components/responses/ApiErrorInvalidRequest"
          },
          "401": {
            "$ref": "#/components/responses/ApiErrorAuth"
          },
          "403": {
            "$ref": "#/components/responses/ApiErrorForbidden"
          },
          "404": {
            "$ref": "#/components/responses/ApiErrorNotFound"
          },
          "409": {
            "$ref": "#/components/responses/ApiErrorConflict"
          },
          "429": {
            "$ref": "#/components/responses/ApiErrorRateLimit"
          },
          "500": {
            "$ref": "#/components/responses/ApiErrorServer"
          }
        },
        "security": [
          {
            "bearer": []
          },
          {
            "api-key": []
          }
        ],
        "summary": "Elimina un campo",
        "tags": [
          "Collections"
        ],
        "x-scope": "collections:write"
      },
      "patch": {
        "externalDocs": {
          "description": "Guía: Datos: colecciones e ítems",
          "url": "https://developers.meteor.com.co/guias/colecciones-e-items.html"
        },
        "operationId": "CollectionsController_updateField",
        "parameters": [
          {
            "description": "ID del campo de la colección.",
            "in": "path",
            "name": "fieldId",
            "required": true,
            "schema": {
              "type": "number"
            }
          }
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/UpdateFieldDto"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "allOf": [
                    {
                      "$ref": "#/components/schemas/ApiEnvelope"
                    },
                    {
                      "properties": {
                        "data": {
                          "$ref": "#/components/schemas/CollectionFieldResponseDto"
                        }
                      },
                      "required": [
                        "data"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": ""
          },
          "400": {
            "$ref": "#/components/responses/ApiErrorInvalidRequest"
          },
          "401": {
            "$ref": "#/components/responses/ApiErrorAuth"
          },
          "403": {
            "$ref": "#/components/responses/ApiErrorForbidden"
          },
          "404": {
            "$ref": "#/components/responses/ApiErrorNotFound"
          },
          "409": {
            "$ref": "#/components/responses/ApiErrorConflict"
          },
          "429": {
            "$ref": "#/components/responses/ApiErrorRateLimit"
          },
          "500": {
            "$ref": "#/components/responses/ApiErrorServer"
          }
        },
        "security": [
          {
            "bearer": []
          },
          {
            "api-key": []
          }
        ],
        "summary": "Actualiza un campo (label, validation_rules)",
        "tags": [
          "Collections"
        ],
        "x-scope": "collections:write"
      }
    },
    "/folders/{folderId}": {
      "delete": {
        "externalDocs": {
          "description": "Guía: Datos: colecciones e ítems",
          "url": "https://developers.meteor.com.co/guias/colecciones-e-items.html"
        },
        "operationId": "FoldersController_remove",
        "parameters": [
          {
            "description": "ID numérico de la carpeta.",
            "in": "path",
            "name": "folderId",
            "required": true,
            "schema": {
              "type": "string"
            }
          }
        ],
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "allOf": [
                    {
                      "$ref": "#/components/schemas/ApiEnvelope"
                    },
                    {
                      "properties": {
                        "data": {
                          "$ref": "#/components/schemas/FolderMessageResponseDto"
                        }
                      },
                      "required": [
                        "data"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": ""
          },
          "400": {
            "$ref": "#/components/responses/ApiErrorInvalidRequest"
          },
          "401": {
            "$ref": "#/components/responses/ApiErrorAuth"
          },
          "403": {
            "$ref": "#/components/responses/ApiErrorForbidden"
          },
          "404": {
            "$ref": "#/components/responses/ApiErrorNotFound"
          },
          "409": {
            "$ref": "#/components/responses/ApiErrorConflict"
          },
          "429": {
            "$ref": "#/components/responses/ApiErrorRateLimit"
          },
          "500": {
            "$ref": "#/components/responses/ApiErrorServer"
          }
        },
        "security": [
          {
            "bearer": []
          },
          {
            "api-key": []
          }
        ],
        "summary": "Elimina la carpeta",
        "tags": [
          "Collections"
        ],
        "x-scope": "collections:write"
      },
      "get": {
        "externalDocs": {
          "description": "Guía: Datos: colecciones e ítems",
          "url": "https://developers.meteor.com.co/guias/colecciones-e-items.html"
        },
        "operationId": "FoldersController_findOne",
        "parameters": [
          {
            "description": "ID numérico de la carpeta.",
            "in": "path",
            "name": "folderId",
            "required": true,
            "schema": {
              "type": "string"
            }
          }
        ],
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "allOf": [
                    {
                      "$ref": "#/components/schemas/ApiEnvelope"
                    },
                    {
                      "properties": {
                        "data": {
                          "$ref": "#/components/schemas/FolderDetailResponseDto"
                        }
                      },
                      "required": [
                        "data"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": ""
          },
          "400": {
            "$ref": "#/components/responses/ApiErrorInvalidRequest"
          },
          "401": {
            "$ref": "#/components/responses/ApiErrorAuth"
          },
          "403": {
            "$ref": "#/components/responses/ApiErrorForbidden"
          },
          "404": {
            "$ref": "#/components/responses/ApiErrorNotFound"
          },
          "429": {
            "$ref": "#/components/responses/ApiErrorRateLimit"
          },
          "500": {
            "$ref": "#/components/responses/ApiErrorServer"
          }
        },
        "security": [
          {
            "bearer": []
          },
          {
            "api-key": []
          }
        ],
        "summary": "Obtiene la carpeta por ID",
        "tags": [
          "Collections"
        ],
        "x-scope": "collections:read"
      },
      "put": {
        "externalDocs": {
          "description": "Guía: Datos: colecciones e ítems",
          "url": "https://developers.meteor.com.co/guias/colecciones-e-items.html"
        },
        "operationId": "FoldersController_update",
        "parameters": [
          {
            "description": "ID numérico de la carpeta.",
            "in": "path",
            "name": "folderId",
            "required": true,
            "schema": {
              "type": "string"
            }
          }
        ],
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "allOf": [
                    {
                      "$ref": "#/components/schemas/ApiEnvelope"
                    },
                    {
                      "properties": {
                        "data": {
                          "$ref": "#/components/schemas/FolderResponseDto"
                        }
                      },
                      "required": [
                        "data"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": ""
          },
          "400": {
            "$ref": "#/components/responses/ApiErrorInvalidRequest"
          },
          "401": {
            "$ref": "#/components/responses/ApiErrorAuth"
          },
          "403": {
            "$ref": "#/components/responses/ApiErrorForbidden"
          },
          "404": {
            "$ref": "#/components/responses/ApiErrorNotFound"
          },
          "409": {
            "$ref": "#/components/responses/ApiErrorConflict"
          },
          "429": {
            "$ref": "#/components/responses/ApiErrorRateLimit"
          },
          "500": {
            "$ref": "#/components/responses/ApiErrorServer"
          }
        },
        "security": [
          {
            "bearer": []
          },
          {
            "api-key": []
          }
        ],
        "summary": "Actualiza la carpeta",
        "tags": [
          "Collections"
        ],
        "x-scope": "collections:write"
      }
    },
    "/folders/{folderId}/collections/reorder": {
      "post": {
        "externalDocs": {
          "description": "Guía: Datos: colecciones e ítems",
          "url": "https://developers.meteor.com.co/guias/colecciones-e-items.html"
        },
        "operationId": "FoldersController_reorderCollectionsInFolder",
        "parameters": [
          {
            "description": "ID numérico de la carpeta.",
            "in": "path",
            "name": "folderId",
            "required": true,
            "schema": {
              "type": "string"
            }
          }
        ],
        "responses": {
          "201": {
            "content": {
              "application/json": {
                "schema": {
                  "allOf": [
                    {
                      "$ref": "#/components/schemas/ApiEnvelope"
                    },
                    {
                      "properties": {
                        "data": {
                          "$ref": "#/components/schemas/FolderMessageResponseDto"
                        }
                      },
                      "required": [
                        "data"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": ""
          },
          "400": {
            "$ref": "#/components/responses/ApiErrorInvalidRequest"
          },
          "401": {
            "$ref": "#/components/responses/ApiErrorAuth"
          },
          "403": {
            "$ref": "#/components/responses/ApiErrorForbidden"
          },
          "404": {
            "$ref": "#/components/responses/ApiErrorNotFound"
          },
          "409": {
            "$ref": "#/components/responses/ApiErrorConflict"
          },
          "429": {
            "$ref": "#/components/responses/ApiErrorRateLimit"
          },
          "500": {
            "$ref": "#/components/responses/ApiErrorServer"
          }
        },
        "security": [
          {
            "bearer": []
          },
          {
            "api-key": []
          }
        ],
        "summary": "Reordena las colecciones de una carpeta",
        "tags": [
          "Collections"
        ],
        "x-scope": "collections:write"
      }
    },
    "/folders/{folderId}/move": {
      "post": {
        "externalDocs": {
          "description": "Guía: Datos: colecciones e ítems",
          "url": "https://developers.meteor.com.co/guias/colecciones-e-items.html"
        },
        "operationId": "FoldersController_moveFolder",
        "parameters": [
          {
            "description": "ID numérico de la carpeta.",
            "in": "path",
            "name": "folderId",
            "required": true,
            "schema": {
              "type": "string"
            }
          }
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/MoveFolderDto"
              }
            }
          },
          "required": true
        },
        "responses": {
          "201": {
            "content": {
              "application/json": {
                "schema": {
                  "allOf": [
                    {
                      "$ref": "#/components/schemas/ApiEnvelope"
                    },
                    {
                      "properties": {
                        "data": {
                          "$ref": "#/components/schemas/FolderResponseDto"
                        }
                      },
                      "required": [
                        "data"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": ""
          },
          "400": {
            "$ref": "#/components/responses/ApiErrorInvalidRequest"
          },
          "401": {
            "$ref": "#/components/responses/ApiErrorAuth"
          },
          "403": {
            "$ref": "#/components/responses/ApiErrorForbidden"
          },
          "404": {
            "$ref": "#/components/responses/ApiErrorNotFound"
          },
          "409": {
            "$ref": "#/components/responses/ApiErrorConflict"
          },
          "429": {
            "$ref": "#/components/responses/ApiErrorRateLimit"
          },
          "500": {
            "$ref": "#/components/responses/ApiErrorServer"
          }
        },
        "security": [
          {
            "bearer": []
          },
          {
            "api-key": []
          }
        ],
        "summary": "Mueve la carpeta a un nuevo padre",
        "tags": [
          "Collections"
        ],
        "x-scope": "collections:write"
      }
    },
    "/item-files/{fileId}": {
      "delete": {
        "externalDocs": {
          "description": "Guía: Datos: colecciones e ítems",
          "url": "https://developers.meteor.com.co/guias/colecciones-e-items.html"
        },
        "operationId": "FilesController_remove",
        "parameters": [
          {
            "description": "ID del archivo.",
            "in": "path",
            "name": "fileId",
            "required": true,
            "schema": {
              "type": "number"
            }
          }
        ],
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "allOf": [
                    {
                      "$ref": "#/components/schemas/ApiEnvelope"
                    },
                    {
                      "properties": {
                        "data": {
                          "$ref": "#/components/schemas/ItemFileDeletedResponseDto"
                        }
                      },
                      "required": [
                        "data"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": ""
          },
          "400": {
            "$ref": "#/components/responses/ApiErrorInvalidRequest"
          },
          "401": {
            "$ref": "#/components/responses/ApiErrorAuth"
          },
          "403": {
            "$ref": "#/components/responses/ApiErrorForbidden"
          },
          "404": {
            "$ref": "#/components/responses/ApiErrorNotFound"
          },
          "409": {
            "$ref": "#/components/responses/ApiErrorConflict"
          },
          "429": {
            "$ref": "#/components/responses/ApiErrorRateLimit"
          },
          "500": {
            "$ref": "#/components/responses/ApiErrorServer"
          }
        },
        "security": [
          {
            "bearer": []
          },
          {
            "api-key": []
          }
        ],
        "summary": "Elimina el archivo",
        "tags": [
          "Items"
        ],
        "x-scope": "items:write"
      },
      "put": {
        "externalDocs": {
          "description": "Guía: Datos: colecciones e ítems",
          "url": "https://developers.meteor.com.co/guias/colecciones-e-items.html"
        },
        "operationId": "FilesController_update",
        "parameters": [
          {
            "description": "ID del archivo.",
            "in": "path",
            "name": "fileId",
            "required": true,
            "schema": {
              "type": "number"
            }
          }
        ],
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "allOf": [
                    {
                      "$ref": "#/components/schemas/ApiEnvelope"
                    },
                    {
                      "properties": {
                        "data": {
                          "$ref": "#/components/schemas/ItemFileResponseDto"
                        }
                      },
                      "required": [
                        "data"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": ""
          },
          "400": {
            "$ref": "#/components/responses/ApiErrorInvalidRequest"
          },
          "401": {
            "$ref": "#/components/responses/ApiErrorAuth"
          },
          "403": {
            "$ref": "#/components/responses/ApiErrorForbidden"
          },
          "404": {
            "$ref": "#/components/responses/ApiErrorNotFound"
          },
          "409": {
            "$ref": "#/components/responses/ApiErrorConflict"
          },
          "429": {
            "$ref": "#/components/responses/ApiErrorRateLimit"
          },
          "500": {
            "$ref": "#/components/responses/ApiErrorServer"
          }
        },
        "security": [
          {
            "bearer": []
          },
          {
            "api-key": []
          }
        ],
        "summary": "Renombra el archivo",
        "tags": [
          "Items"
        ],
        "x-scope": "items:write"
      }
    },
    "/item-files/{fileId}/download": {
      "get": {
        "externalDocs": {
          "description": "Guía: Datos: colecciones e ítems",
          "url": "https://developers.meteor.com.co/guias/colecciones-e-items.html"
        },
        "operationId": "FilesController_download",
        "parameters": [
          {
            "description": "ID del archivo.",
            "in": "path",
            "name": "fileId",
            "required": true,
            "schema": {
              "type": "number"
            }
          }
        ],
        "responses": {
          "200": {
            "content": {
              "application/octet-stream": {
                "schema": {
                  "format": "binary",
                  "type": "string"
                }
              }
            },
            "description": "Los bytes del archivo, con `Content-Disposition: attachment`. No es JSON. A diferencia del `download_url` firmado que devuelve el upload, este enlace es estable: valida la sesión en cada llamada y no caduca."
          },
          "400": {
            "$ref": "#/components/responses/ApiErrorInvalidRequest"
          },
          "401": {
            "$ref": "#/components/responses/ApiErrorAuth"
          },
          "403": {
            "$ref": "#/components/responses/ApiErrorForbidden"
          },
          "404": {
            "$ref": "#/components/responses/ApiErrorNotFound"
          },
          "429": {
            "$ref": "#/components/responses/ApiErrorRateLimit"
          },
          "500": {
            "$ref": "#/components/responses/ApiErrorServer"
          }
        },
        "security": [
          {
            "bearer": []
          },
          {
            "api-key": []
          }
        ],
        "summary": "Descarga el archivo",
        "tags": [
          "Items"
        ],
        "x-scope": "items:read"
      }
    },
    "/item-links/{linkId}": {
      "delete": {
        "externalDocs": {
          "description": "Guía: Datos: colecciones e ítems",
          "url": "https://developers.meteor.com.co/guias/colecciones-e-items.html"
        },
        "operationId": "ItemLinksController_remove",
        "parameters": [
          {
            "description": "ID del vínculo.",
            "in": "path",
            "name": "linkId",
            "required": true,
            "schema": {
              "type": "number"
            }
          }
        ],
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "allOf": [
                    {
                      "$ref": "#/components/schemas/ApiEnvelope"
                    },
                    {
                      "properties": {
                        "data": {
                          "$ref": "#/components/schemas/ItemMessageResponseDto"
                        }
                      },
                      "required": [
                        "data"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": ""
          },
          "400": {
            "$ref": "#/components/responses/ApiErrorInvalidRequest"
          },
          "401": {
            "$ref": "#/components/responses/ApiErrorAuth"
          },
          "403": {
            "$ref": "#/components/responses/ApiErrorForbidden"
          },
          "404": {
            "$ref": "#/components/responses/ApiErrorNotFound"
          },
          "409": {
            "$ref": "#/components/responses/ApiErrorConflict"
          },
          "429": {
            "$ref": "#/components/responses/ApiErrorRateLimit"
          },
          "500": {
            "$ref": "#/components/responses/ApiErrorServer"
          }
        },
        "security": [
          {
            "bearer": []
          },
          {
            "api-key": []
          }
        ],
        "summary": "Elimina un enlace",
        "tags": [
          "Item Links"
        ],
        "x-scope": "items:write"
      }
    },
    "/items/orphans": {
      "get": {
        "externalDocs": {
          "description": "Guía: Datos: colecciones e ítems",
          "url": "https://developers.meteor.com.co/guias/colecciones-e-items.html"
        },
        "operationId": "ItemsController_findOrphans",
        "parameters": [],
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "allOf": [
                    {
                      "$ref": "#/components/schemas/ApiEnvelope"
                    },
                    {
                      "properties": {
                        "data": {
                          "items": {
                            "$ref": "#/components/schemas/ItemResponseDto"
                          },
                          "type": "array"
                        }
                      },
                      "required": [
                        "data"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": ""
          },
          "400": {
            "$ref": "#/components/responses/ApiErrorInvalidRequest"
          },
          "401": {
            "$ref": "#/components/responses/ApiErrorAuth"
          },
          "403": {
            "$ref": "#/components/responses/ApiErrorForbidden"
          },
          "404": {
            "$ref": "#/components/responses/ApiErrorNotFound"
          },
          "429": {
            "$ref": "#/components/responses/ApiErrorRateLimit"
          },
          "500": {
            "$ref": "#/components/responses/ApiErrorServer"
          }
        },
        "security": [
          {
            "bearer": []
          },
          {
            "api-key": []
          }
        ],
        "summary": "Lista los items huérfanos",
        "tags": [
          "Items"
        ],
        "x-scope": "items:read"
      }
    },
    "/items/{id}": {
      "delete": {
        "externalDocs": {
          "description": "Guía: Datos: colecciones e ítems",
          "url": "https://developers.meteor.com.co/guias/colecciones-e-items.html"
        },
        "operationId": "ItemsController_remove",
        "parameters": [
          {
            "description": "ID del recurso de esta ruta.",
            "in": "path",
            "name": "id",
            "required": true,
            "schema": {
              "type": "number"
            }
          },
          {
            "description": "Identificador de tu cliente, como cabecera `X-Client-Id`. Opcional, y solo sirve si además escuchas los eventos en tiempo real: el valor que mandes viaja de vuelta en el evento `item:*` que genera esta operación, para que puedas ignorar el eco de tu propio cambio y no pisar lo que ya pintaste. Si no escuchas realtime, no hace nada.",
            "in": "header",
            "name": "x-client-id",
            "required": true,
            "schema": {
              "type": "string"
            }
          }
        ],
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "allOf": [
                    {
                      "$ref": "#/components/schemas/ApiEnvelope"
                    },
                    {
                      "properties": {
                        "data": {
                          "$ref": "#/components/schemas/ItemMessageResponseDto"
                        }
                      },
                      "required": [
                        "data"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": ""
          },
          "400": {
            "$ref": "#/components/responses/ApiErrorInvalidRequest"
          },
          "401": {
            "$ref": "#/components/responses/ApiErrorAuth"
          },
          "403": {
            "$ref": "#/components/responses/ApiErrorForbidden"
          },
          "404": {
            "$ref": "#/components/responses/ApiErrorNotFound"
          },
          "409": {
            "$ref": "#/components/responses/ApiErrorConflict"
          },
          "429": {
            "$ref": "#/components/responses/ApiErrorRateLimit"
          },
          "500": {
            "$ref": "#/components/responses/ApiErrorServer"
          }
        },
        "security": [
          {
            "bearer": []
          },
          {
            "api-key": []
          }
        ],
        "summary": "Elimina el item",
        "tags": [
          "Items"
        ],
        "x-scope": "items:write"
      },
      "get": {
        "externalDocs": {
          "description": "Guía: Datos: colecciones e ítems",
          "url": "https://developers.meteor.com.co/guias/colecciones-e-items.html"
        },
        "operationId": "ItemsController_findOne",
        "parameters": [
          {
            "description": "ID del recurso de esta ruta.",
            "in": "path",
            "name": "id",
            "required": true,
            "schema": {
              "type": "number"
            }
          }
        ],
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "allOf": [
                    {
                      "$ref": "#/components/schemas/ApiEnvelope"
                    },
                    {
                      "properties": {
                        "data": {
                          "$ref": "#/components/schemas/ItemResponseDto"
                        }
                      },
                      "required": [
                        "data"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": ""
          },
          "400": {
            "$ref": "#/components/responses/ApiErrorInvalidRequest"
          },
          "401": {
            "$ref": "#/components/responses/ApiErrorAuth"
          },
          "403": {
            "$ref": "#/components/responses/ApiErrorForbidden"
          },
          "404": {
            "$ref": "#/components/responses/ApiErrorNotFound"
          },
          "429": {
            "$ref": "#/components/responses/ApiErrorRateLimit"
          },
          "500": {
            "$ref": "#/components/responses/ApiErrorServer"
          }
        },
        "security": [
          {
            "bearer": []
          },
          {
            "api-key": []
          }
        ],
        "summary": "Obtiene el item por ID",
        "tags": [
          "Items"
        ],
        "x-scope": "items:read"
      }
    },
    "/items/{id}/code": {
      "patch": {
        "externalDocs": {
          "description": "Guía: Datos: colecciones e ítems",
          "url": "https://developers.meteor.com.co/guias/colecciones-e-items.html"
        },
        "operationId": "ItemsController_setCode",
        "parameters": [
          {
            "description": "ID del recurso de esta ruta.",
            "in": "path",
            "name": "id",
            "required": true,
            "schema": {
              "type": "number"
            }
          }
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/SetCodeDto"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "allOf": [
                    {
                      "$ref": "#/components/schemas/ApiEnvelope"
                    },
                    {
                      "properties": {
                        "data": {
                          "$ref": "#/components/schemas/ItemCodeResponseDto"
                        }
                      },
                      "required": [
                        "data"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": ""
          },
          "400": {
            "$ref": "#/components/responses/ApiErrorInvalidRequest"
          },
          "401": {
            "$ref": "#/components/responses/ApiErrorAuth"
          },
          "403": {
            "$ref": "#/components/responses/ApiErrorForbidden"
          },
          "404": {
            "$ref": "#/components/responses/ApiErrorNotFound"
          },
          "409": {
            "$ref": "#/components/responses/ApiErrorConflict"
          },
          "429": {
            "$ref": "#/components/responses/ApiErrorRateLimit"
          },
          "500": {
            "$ref": "#/components/responses/ApiErrorServer"
          }
        },
        "security": [
          {
            "bearer": []
          },
          {
            "api-key": []
          }
        ],
        "summary": "Renombra el código de un item (@handle). Se pasa a mayúsculas en el servidor; debe ser único.",
        "tags": [
          "Items"
        ],
        "x-scope": "items:write"
      }
    },
    "/items/{id}/status": {
      "patch": {
        "externalDocs": {
          "description": "Guía: Datos: colecciones e ítems",
          "url": "https://developers.meteor.com.co/guias/colecciones-e-items.html"
        },
        "operationId": "ItemsController_setStatus",
        "parameters": [
          {
            "description": "ID del recurso de esta ruta.",
            "in": "path",
            "name": "id",
            "required": true,
            "schema": {
              "type": "number"
            }
          }
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/SetStatusDto"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "allOf": [
                    {
                      "$ref": "#/components/schemas/ApiEnvelope"
                    },
                    {
                      "properties": {
                        "data": {
                          "$ref": "#/components/schemas/ItemStatusResponseDto"
                        }
                      },
                      "required": [
                        "data"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": ""
          },
          "400": {
            "$ref": "#/components/responses/ApiErrorInvalidRequest"
          },
          "401": {
            "$ref": "#/components/responses/ApiErrorAuth"
          },
          "403": {
            "$ref": "#/components/responses/ApiErrorForbidden"
          },
          "404": {
            "$ref": "#/components/responses/ApiErrorNotFound"
          },
          "409": {
            "$ref": "#/components/responses/ApiErrorConflict"
          },
          "429": {
            "$ref": "#/components/responses/ApiErrorRateLimit"
          },
          "500": {
            "$ref": "#/components/responses/ApiErrorServer"
          }
        },
        "security": [
          {
            "bearer": []
          },
          {
            "api-key": []
          }
        ],
        "summary": "Configura el estado del ciclo de vida (active | vacation)",
        "tags": [
          "Items"
        ],
        "x-scope": "items:write"
      }
    },
    "/items/{id}/thumbnail": {
      "delete": {
        "externalDocs": {
          "description": "Guía: Datos: colecciones e ítems",
          "url": "https://developers.meteor.com.co/guias/colecciones-e-items.html"
        },
        "operationId": "ItemsController_clearThumbnail",
        "parameters": [
          {
            "description": "ID del recurso de esta ruta.",
            "in": "path",
            "name": "id",
            "required": true,
            "schema": {
              "type": "number"
            }
          }
        ],
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "allOf": [
                    {
                      "$ref": "#/components/schemas/ApiEnvelope"
                    },
                    {
                      "properties": {
                        "data": {
                          "$ref": "#/components/schemas/ItemOkResponseDto"
                        }
                      },
                      "required": [
                        "data"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": ""
          },
          "400": {
            "$ref": "#/components/responses/ApiErrorInvalidRequest"
          },
          "401": {
            "$ref": "#/components/responses/ApiErrorAuth"
          },
          "403": {
            "$ref": "#/components/responses/ApiErrorForbidden"
          },
          "404": {
            "$ref": "#/components/responses/ApiErrorNotFound"
          },
          "409": {
            "$ref": "#/components/responses/ApiErrorConflict"
          },
          "429": {
            "$ref": "#/components/responses/ApiErrorRateLimit"
          },
          "500": {
            "$ref": "#/components/responses/ApiErrorServer"
          }
        },
        "security": [
          {
            "bearer": []
          },
          {
            "api-key": []
          }
        ],
        "summary": "Borra la miniatura del item. La próxima vista la recaptura.",
        "tags": [
          "Items"
        ],
        "x-scope": "items:write"
      },
      "post": {
        "externalDocs": {
          "description": "Guía: Datos: colecciones e ítems",
          "url": "https://developers.meteor.com.co/guias/colecciones-e-items.html"
        },
        "operationId": "ItemsController_uploadThumbnail",
        "parameters": [
          {
            "description": "ID del recurso de esta ruta.",
            "in": "path",
            "name": "id",
            "required": true,
            "schema": {
              "type": "number"
            }
          }
        ],
        "responses": {
          "201": {
            "content": {
              "application/json": {
                "schema": {
                  "allOf": [
                    {
                      "$ref": "#/components/schemas/ApiEnvelope"
                    },
                    {
                      "properties": {
                        "data": {
                          "$ref": "#/components/schemas/ItemThumbnailResponseDto"
                        }
                      },
                      "required": [
                        "data"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": ""
          },
          "400": {
            "$ref": "#/components/responses/ApiErrorInvalidRequest"
          },
          "401": {
            "$ref": "#/components/responses/ApiErrorAuth"
          },
          "403": {
            "$ref": "#/components/responses/ApiErrorForbidden"
          },
          "404": {
            "$ref": "#/components/responses/ApiErrorNotFound"
          },
          "409": {
            "$ref": "#/components/responses/ApiErrorConflict"
          },
          "429": {
            "$ref": "#/components/responses/ApiErrorRateLimit"
          },
          "500": {
            "$ref": "#/components/responses/ApiErrorServer"
          }
        },
        "security": [
          {
            "bearer": []
          },
          {
            "api-key": []
          }
        ],
        "summary": "Sube una miniatura (PNG dataURL) para un item. La usa la captura de pantalla de la página del lado del cliente.",
        "tags": [
          "Items"
        ],
        "x-scope": "items:write"
      }
    },
    "/items/{id}/upload-image": {
      "post": {
        "externalDocs": {
          "description": "Guía: Datos: colecciones e ítems",
          "url": "https://developers.meteor.com.co/guias/colecciones-e-items.html"
        },
        "operationId": "ItemsController_uploadImage",
        "parameters": [
          {
            "description": "ID del recurso de esta ruta.",
            "in": "path",
            "name": "id",
            "required": true,
            "schema": {
              "type": "number"
            }
          }
        ],
        "responses": {
          "201": {
            "content": {
              "application/json": {
                "schema": {
                  "allOf": [
                    {
                      "$ref": "#/components/schemas/ApiEnvelope"
                    },
                    {
                      "properties": {
                        "data": {
                          "$ref": "#/components/schemas/ItemImageUploadResponseDto"
                        }
                      },
                      "required": [
                        "data"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": ""
          },
          "400": {
            "$ref": "#/components/responses/ApiErrorInvalidRequest"
          },
          "401": {
            "$ref": "#/components/responses/ApiErrorAuth"
          },
          "403": {
            "$ref": "#/components/responses/ApiErrorForbidden"
          },
          "404": {
            "$ref": "#/components/responses/ApiErrorNotFound"
          },
          "409": {
            "$ref": "#/components/responses/ApiErrorConflict"
          },
          "429": {
            "$ref": "#/components/responses/ApiErrorRateLimit"
          },
          "500": {
            "$ref": "#/components/responses/ApiErrorServer"
          }
        },
        "security": [
          {
            "bearer": []
          },
          {
            "api-key": []
          }
        ],
        "summary": "Sube una imagen a un campo tipo `image` del item (máx. 10MB). Devuelve la URL y la ruta en Storage.",
        "tags": [
          "Items"
        ],
        "x-scope": "items:write"
      }
    },
    "/items/{id}/visibility": {
      "patch": {
        "externalDocs": {
          "description": "Guía: Datos: colecciones e ítems",
          "url": "https://developers.meteor.com.co/guias/colecciones-e-items.html"
        },
        "operationId": "ItemsController_setVisibility",
        "parameters": [
          {
            "description": "ID del recurso de esta ruta.",
            "in": "path",
            "name": "id",
            "required": true,
            "schema": {
              "type": "number"
            }
          }
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/SetVisibilityDto"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "allOf": [
                    {
                      "$ref": "#/components/schemas/ApiEnvelope"
                    },
                    {
                      "properties": {
                        "data": {
                          "$ref": "#/components/schemas/ItemVisibilityResponseDto"
                        }
                      },
                      "required": [
                        "data"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": ""
          },
          "400": {
            "$ref": "#/components/responses/ApiErrorInvalidRequest"
          },
          "401": {
            "$ref": "#/components/responses/ApiErrorAuth"
          },
          "403": {
            "$ref": "#/components/responses/ApiErrorForbidden"
          },
          "404": {
            "$ref": "#/components/responses/ApiErrorNotFound"
          },
          "409": {
            "$ref": "#/components/responses/ApiErrorConflict"
          },
          "429": {
            "$ref": "#/components/responses/ApiErrorRateLimit"
          },
          "500": {
            "$ref": "#/components/responses/ApiErrorServer"
          }
        },
        "security": [
          {
            "bearer": []
          },
          {
            "api-key": []
          }
        ],
        "summary": "Configura la visibilidad del item (private|listed|public)",
        "tags": [
          "Items"
        ],
        "x-scope": "items:write"
      }
    },
    "/items/{itemId}/activity": {
      "get": {
        "externalDocs": {
          "description": "Guía: Eventos en vivo",
          "url": "https://developers.meteor.com.co/guias/eventos.html"
        },
        "operationId": "EventsController_getItemActivity",
        "parameters": [
          {
            "description": "ID numérico del ítem (fila de una colección).",
            "in": "path",
            "name": "itemId",
            "required": true,
            "schema": {
              "type": "number"
            }
          }
        ],
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "allOf": [
                    {
                      "$ref": "#/components/schemas/ApiEnvelope"
                    },
                    {
                      "properties": {
                        "data": {
                          "items": {
                            "$ref": "#/components/schemas/EventResponseDto"
                          },
                          "type": "array"
                        }
                      },
                      "required": [
                        "data"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": ""
          },
          "400": {
            "$ref": "#/components/responses/ApiErrorInvalidRequest"
          },
          "401": {
            "$ref": "#/components/responses/ApiErrorAuth"
          },
          "403": {
            "$ref": "#/components/responses/ApiErrorForbidden"
          },
          "404": {
            "$ref": "#/components/responses/ApiErrorNotFound"
          },
          "429": {
            "$ref": "#/components/responses/ApiErrorRateLimit"
          },
          "500": {
            "$ref": "#/components/responses/ApiErrorServer"
          }
        },
        "security": [
          {
            "bearer": []
          },
          {
            "api-key": []
          }
        ],
        "summary": "Obtiene el registro de actividad del item",
        "tags": [
          "Events"
        ],
        "x-scope": "events:read"
      }
    },
    "/items/{itemId}/comments": {
      "get": {
        "externalDocs": {
          "description": "Guía: Datos: colecciones e ítems",
          "url": "https://developers.meteor.com.co/guias/colecciones-e-items.html"
        },
        "operationId": "ItemCommentsController_list",
        "parameters": [
          {
            "description": "ID numérico del ítem (fila de una colección).",
            "in": "path",
            "name": "itemId",
            "required": true,
            "schema": {
              "type": "number"
            }
          },
          {
            "description": "Campo sobre el que aplica la operación.",
            "in": "query",
            "name": "field",
            "required": true,
            "schema": {
              "type": "string"
            }
          }
        ],
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "allOf": [
                    {
                      "$ref": "#/components/schemas/ApiEnvelope"
                    },
                    {
                      "properties": {
                        "data": {
                          "items": {
                            "$ref": "#/components/schemas/ItemCommentResponseDto"
                          },
                          "type": "array"
                        }
                      },
                      "required": [
                        "data"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": ""
          },
          "400": {
            "$ref": "#/components/responses/ApiErrorInvalidRequest"
          },
          "401": {
            "$ref": "#/components/responses/ApiErrorAuth"
          },
          "403": {
            "$ref": "#/components/responses/ApiErrorForbidden"
          },
          "404": {
            "$ref": "#/components/responses/ApiErrorNotFound"
          },
          "429": {
            "$ref": "#/components/responses/ApiErrorRateLimit"
          },
          "500": {
            "$ref": "#/components/responses/ApiErrorServer"
          }
        },
        "security": [
          {
            "bearer": []
          },
          {
            "api-key": []
          }
        ],
        "summary": "Lista comentarios del item (más antiguo primero). Con ?field= devuelve el hilo de esa celda.",
        "tags": [
          "Items"
        ],
        "x-scope": "items:read"
      },
      "post": {
        "externalDocs": {
          "description": "Guía: Datos: colecciones e ítems",
          "url": "https://developers.meteor.com.co/guias/colecciones-e-items.html"
        },
        "operationId": "ItemCommentsController_create",
        "parameters": [
          {
            "description": "ID numérico del ítem (fila de una colección).",
            "in": "path",
            "name": "itemId",
            "required": true,
            "schema": {
              "type": "number"
            }
          }
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/CreateItemCommentDto"
              }
            }
          },
          "required": true
        },
        "responses": {
          "201": {
            "content": {
              "application/json": {
                "schema": {
                  "allOf": [
                    {
                      "$ref": "#/components/schemas/ApiEnvelope"
                    },
                    {
                      "properties": {
                        "data": {
                          "$ref": "#/components/schemas/ItemCommentRowResponseDto"
                        }
                      },
                      "required": [
                        "data"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": ""
          },
          "400": {
            "$ref": "#/components/responses/ApiErrorInvalidRequest"
          },
          "401": {
            "$ref": "#/components/responses/ApiErrorAuth"
          },
          "403": {
            "$ref": "#/components/responses/ApiErrorForbidden"
          },
          "404": {
            "$ref": "#/components/responses/ApiErrorNotFound"
          },
          "409": {
            "$ref": "#/components/responses/ApiErrorConflict"
          },
          "429": {
            "$ref": "#/components/responses/ApiErrorRateLimit"
          },
          "500": {
            "$ref": "#/components/responses/ApiErrorServer"
          }
        },
        "security": [
          {
            "bearer": []
          },
          {
            "api-key": []
          }
        ],
        "summary": "Crear un comentario (autor = user del JWT).",
        "tags": [
          "Items"
        ],
        "x-scope": "items:write"
      }
    },
    "/items/{itemId}/comments/upload": {
      "post": {
        "externalDocs": {
          "description": "Guía: Datos: colecciones e ítems",
          "url": "https://developers.meteor.com.co/guias/colecciones-e-items.html"
        },
        "operationId": "ItemCommentsController_upload",
        "parameters": [
          {
            "description": "ID numérico del ítem (fila de una colección).",
            "in": "path",
            "name": "itemId",
            "required": true,
            "schema": {
              "type": "number"
            }
          }
        ],
        "responses": {
          "201": {
            "content": {
              "application/json": {
                "schema": {
                  "allOf": [
                    {
                      "$ref": "#/components/schemas/ApiEnvelope"
                    },
                    {
                      "properties": {
                        "data": {
                          "$ref": "#/components/schemas/ItemCommentFileAttachmentDto"
                        }
                      },
                      "required": [
                        "data"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": ""
          },
          "400": {
            "$ref": "#/components/responses/ApiErrorInvalidRequest"
          },
          "401": {
            "$ref": "#/components/responses/ApiErrorAuth"
          },
          "403": {
            "$ref": "#/components/responses/ApiErrorForbidden"
          },
          "404": {
            "$ref": "#/components/responses/ApiErrorNotFound"
          },
          "409": {
            "$ref": "#/components/responses/ApiErrorConflict"
          },
          "429": {
            "$ref": "#/components/responses/ApiErrorRateLimit"
          },
          "500": {
            "$ref": "#/components/responses/ApiErrorServer"
          }
        },
        "security": [
          {
            "bearer": []
          },
          {
            "api-key": []
          }
        ],
        "summary": "Sube un archivo y devuelve metadata para incluir en attachments.",
        "tags": [
          "Items"
        ],
        "x-scope": "items:write"
      }
    },
    "/items/{itemId}/comments/{commentId}": {
      "delete": {
        "externalDocs": {
          "description": "Guía: Datos: colecciones e ítems",
          "url": "https://developers.meteor.com.co/guias/colecciones-e-items.html"
        },
        "operationId": "ItemCommentsController_remove",
        "parameters": [
          {
            "description": "ID numérico del ítem (fila de una colección).",
            "in": "path",
            "name": "itemId",
            "required": true,
            "schema": {
              "type": "number"
            }
          },
          {
            "description": "ID del comentario.",
            "in": "path",
            "name": "commentId",
            "required": true,
            "schema": {
              "type": "number"
            }
          }
        ],
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "allOf": [
                    {
                      "$ref": "#/components/schemas/ApiEnvelope"
                    },
                    {
                      "properties": {
                        "data": {
                          "$ref": "#/components/schemas/ItemCommentMessageResponseDto"
                        }
                      },
                      "required": [
                        "data"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": ""
          },
          "400": {
            "$ref": "#/components/responses/ApiErrorInvalidRequest"
          },
          "401": {
            "$ref": "#/components/responses/ApiErrorAuth"
          },
          "403": {
            "$ref": "#/components/responses/ApiErrorForbidden"
          },
          "404": {
            "$ref": "#/components/responses/ApiErrorNotFound"
          },
          "409": {
            "$ref": "#/components/responses/ApiErrorConflict"
          },
          "429": {
            "$ref": "#/components/responses/ApiErrorRateLimit"
          },
          "500": {
            "$ref": "#/components/responses/ApiErrorServer"
          }
        },
        "security": [
          {
            "bearer": []
          },
          {
            "api-key": []
          }
        ],
        "summary": "Eliminar comentario (solo el autor humano).",
        "tags": [
          "Items"
        ],
        "x-scope": "items:write"
      }
    },
    "/items/{itemId}/content": {
      "get": {
        "externalDocs": {
          "description": "Guía: Datos: colecciones e ítems",
          "url": "https://developers.meteor.com.co/guias/colecciones-e-items.html"
        },
        "operationId": "ItemContentController_get",
        "parameters": [
          {
            "description": "ID numérico del ítem (fila de una colección).",
            "in": "path",
            "name": "itemId",
            "required": true,
            "schema": {
              "type": "number"
            }
          }
        ],
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "allOf": [
                    {
                      "$ref": "#/components/schemas/ApiEnvelope"
                    },
                    {
                      "properties": {
                        "data": {
                          "$ref": "#/components/schemas/ItemContentResponseDto"
                        }
                      },
                      "required": [
                        "data"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": ""
          },
          "400": {
            "$ref": "#/components/responses/ApiErrorInvalidRequest"
          },
          "401": {
            "$ref": "#/components/responses/ApiErrorAuth"
          },
          "403": {
            "$ref": "#/components/responses/ApiErrorForbidden"
          },
          "404": {
            "$ref": "#/components/responses/ApiErrorNotFound"
          },
          "429": {
            "$ref": "#/components/responses/ApiErrorRateLimit"
          },
          "500": {
            "$ref": "#/components/responses/ApiErrorServer"
          }
        },
        "security": [
          {
            "bearer": []
          },
          {
            "api-key": []
          }
        ],
        "summary": "Obtiene los bloques de contenido de un item (bloques de tarea hidratados)",
        "tags": [
          "Items"
        ],
        "x-scope": "items:read"
      },
      "put": {
        "externalDocs": {
          "description": "Guía: Datos: colecciones e ítems",
          "url": "https://developers.meteor.com.co/guias/colecciones-e-items.html"
        },
        "operationId": "ItemContentController_replace",
        "parameters": [
          {
            "description": "ID numérico del ítem (fila de una colección).",
            "in": "path",
            "name": "itemId",
            "required": true,
            "schema": {
              "type": "number"
            }
          }
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/ReplaceContentDto"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "allOf": [
                    {
                      "$ref": "#/components/schemas/ApiEnvelope"
                    },
                    {
                      "properties": {
                        "data": {
                          "items": {
                            "$ref": "#/components/schemas/ContentBlockResponseDto"
                          },
                          "type": "array"
                        }
                      },
                      "required": [
                        "data"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": ""
          },
          "400": {
            "$ref": "#/components/responses/ApiErrorInvalidRequest"
          },
          "401": {
            "$ref": "#/components/responses/ApiErrorAuth"
          },
          "403": {
            "$ref": "#/components/responses/ApiErrorForbidden"
          },
          "404": {
            "$ref": "#/components/responses/ApiErrorNotFound"
          },
          "409": {
            "$ref": "#/components/responses/ApiErrorConflict"
          },
          "429": {
            "$ref": "#/components/responses/ApiErrorRateLimit"
          },
          "500": {
            "$ref": "#/components/responses/ApiErrorServer"
          }
        },
        "security": [
          {
            "bearer": []
          },
          {
            "api-key": []
          }
        ],
        "summary": "Reemplaza todo el contenido (usado por Met/importaciones)",
        "tags": [
          "Items"
        ],
        "x-scope": "items:write"
      }
    },
    "/items/{itemId}/content/blocks": {
      "post": {
        "externalDocs": {
          "description": "Guía: Datos: colecciones e ítems",
          "url": "https://developers.meteor.com.co/guias/colecciones-e-items.html"
        },
        "operationId": "ItemContentController_add",
        "parameters": [
          {
            "description": "ID numérico del ítem (fila de una colección).",
            "in": "path",
            "name": "itemId",
            "required": true,
            "schema": {
              "type": "number"
            }
          }
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/CreateBlockDto"
              }
            }
          },
          "required": true
        },
        "responses": {
          "201": {
            "content": {
              "application/json": {
                "schema": {
                  "allOf": [
                    {
                      "$ref": "#/components/schemas/ApiEnvelope"
                    },
                    {
                      "properties": {
                        "data": {
                          "$ref": "#/components/schemas/ContentBlockResponseDto"
                        }
                      },
                      "required": [
                        "data"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": ""
          },
          "400": {
            "$ref": "#/components/responses/ApiErrorInvalidRequest"
          },
          "401": {
            "$ref": "#/components/responses/ApiErrorAuth"
          },
          "403": {
            "$ref": "#/components/responses/ApiErrorForbidden"
          },
          "404": {
            "$ref": "#/components/responses/ApiErrorNotFound"
          },
          "409": {
            "$ref": "#/components/responses/ApiErrorConflict"
          },
          "429": {
            "$ref": "#/components/responses/ApiErrorRateLimit"
          },
          "500": {
            "$ref": "#/components/responses/ApiErrorServer"
          }
        },
        "security": [
          {
            "bearer": []
          },
          {
            "api-key": []
          }
        ],
        "summary": "Agrega un bloque nuevo (o lo inserta después de after_block_id)",
        "tags": [
          "Items"
        ],
        "x-scope": "items:write"
      }
    },
    "/items/{itemId}/content/blocks/{blockId}": {
      "delete": {
        "externalDocs": {
          "description": "Guía: Datos: colecciones e ítems",
          "url": "https://developers.meteor.com.co/guias/colecciones-e-items.html"
        },
        "operationId": "ItemContentController_remove",
        "parameters": [
          {
            "description": "ID numérico del ítem (fila de una colección).",
            "in": "path",
            "name": "itemId",
            "required": true,
            "schema": {
              "type": "number"
            }
          },
          {
            "description": "ID del bloque.",
            "in": "path",
            "name": "blockId",
            "required": true,
            "schema": {
              "type": "string"
            }
          }
        ],
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "allOf": [
                    {
                      "$ref": "#/components/schemas/ApiEnvelope"
                    },
                    {
                      "properties": {
                        "data": {
                          "$ref": "#/components/schemas/ContentBlockRemovedResponseDto"
                        }
                      },
                      "required": [
                        "data"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": ""
          },
          "400": {
            "$ref": "#/components/responses/ApiErrorInvalidRequest"
          },
          "401": {
            "$ref": "#/components/responses/ApiErrorAuth"
          },
          "403": {
            "$ref": "#/components/responses/ApiErrorForbidden"
          },
          "404": {
            "$ref": "#/components/responses/ApiErrorNotFound"
          },
          "409": {
            "$ref": "#/components/responses/ApiErrorConflict"
          },
          "429": {
            "$ref": "#/components/responses/ApiErrorRateLimit"
          },
          "500": {
            "$ref": "#/components/responses/ApiErrorServer"
          }
        },
        "security": [
          {
            "bearer": []
          },
          {
            "api-key": []
          }
        ],
        "summary": "Elimina un bloque del contenido del item",
        "tags": [
          "Items"
        ],
        "x-scope": "items:write"
      },
      "patch": {
        "externalDocs": {
          "description": "Guía: Datos: colecciones e ítems",
          "url": "https://developers.meteor.com.co/guias/colecciones-e-items.html"
        },
        "operationId": "ItemContentController_update",
        "parameters": [
          {
            "description": "ID numérico del ítem (fila de una colección).",
            "in": "path",
            "name": "itemId",
            "required": true,
            "schema": {
              "type": "number"
            }
          },
          {
            "description": "ID del bloque.",
            "in": "path",
            "name": "blockId",
            "required": true,
            "schema": {
              "type": "string"
            }
          }
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/UpdateBlockDto"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "allOf": [
                    {
                      "$ref": "#/components/schemas/ApiEnvelope"
                    },
                    {
                      "properties": {
                        "data": {
                          "$ref": "#/components/schemas/ContentBlockResponseDto"
                        }
                      },
                      "required": [
                        "data"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": ""
          },
          "400": {
            "$ref": "#/components/responses/ApiErrorInvalidRequest"
          },
          "401": {
            "$ref": "#/components/responses/ApiErrorAuth"
          },
          "403": {
            "$ref": "#/components/responses/ApiErrorForbidden"
          },
          "404": {
            "$ref": "#/components/responses/ApiErrorNotFound"
          },
          "409": {
            "$ref": "#/components/responses/ApiErrorConflict"
          },
          "429": {
            "$ref": "#/components/responses/ApiErrorRateLimit"
          },
          "500": {
            "$ref": "#/components/responses/ApiErrorServer"
          }
        },
        "security": [
          {
            "bearer": []
          },
          {
            "api-key": []
          }
        ],
        "summary": "Actualiza los datos de un bloque existente",
        "tags": [
          "Items"
        ],
        "x-scope": "items:write"
      }
    },
    "/items/{itemId}/content/reorder": {
      "post": {
        "externalDocs": {
          "description": "Guía: Datos: colecciones e ítems",
          "url": "https://developers.meteor.com.co/guias/colecciones-e-items.html"
        },
        "operationId": "ItemContentController_reorder",
        "parameters": [
          {
            "description": "ID numérico del ítem (fila de una colección).",
            "in": "path",
            "name": "itemId",
            "required": true,
            "schema": {
              "type": "number"
            }
          }
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/ReorderContentDto"
              }
            }
          },
          "required": true
        },
        "responses": {
          "201": {
            "content": {
              "application/json": {
                "schema": {
                  "allOf": [
                    {
                      "$ref": "#/components/schemas/ApiEnvelope"
                    },
                    {
                      "properties": {
                        "data": {
                          "items": {
                            "$ref": "#/components/schemas/ContentBlockResponseDto"
                          },
                          "type": "array"
                        }
                      },
                      "required": [
                        "data"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": ""
          },
          "400": {
            "$ref": "#/components/responses/ApiErrorInvalidRequest"
          },
          "401": {
            "$ref": "#/components/responses/ApiErrorAuth"
          },
          "403": {
            "$ref": "#/components/responses/ApiErrorForbidden"
          },
          "404": {
            "$ref": "#/components/responses/ApiErrorNotFound"
          },
          "409": {
            "$ref": "#/components/responses/ApiErrorConflict"
          },
          "429": {
            "$ref": "#/components/responses/ApiErrorRateLimit"
          },
          "500": {
            "$ref": "#/components/responses/ApiErrorServer"
          }
        },
        "security": [
          {
            "bearer": []
          },
          {
            "api-key": []
          }
        ],
        "summary": "Reordena los bloques según la lista completa de ids",
        "tags": [
          "Items"
        ],
        "x-scope": "items:write"
      }
    },
    "/items/{itemId}/content/upload-image": {
      "post": {
        "externalDocs": {
          "description": "Guía: Datos: colecciones e ítems",
          "url": "https://developers.meteor.com.co/guias/colecciones-e-items.html"
        },
        "operationId": "ItemContentController_uploadImage",
        "parameters": [
          {
            "description": "ID numérico del ítem (fila de una colección).",
            "in": "path",
            "name": "itemId",
            "required": true,
            "schema": {
              "type": "number"
            }
          }
        ],
        "responses": {
          "201": {
            "content": {
              "application/json": {
                "schema": {
                  "allOf": [
                    {
                      "$ref": "#/components/schemas/ApiEnvelope"
                    },
                    {
                      "properties": {
                        "data": {
                          "$ref": "#/components/schemas/ItemContentUploadResponseDto"
                        }
                      },
                      "required": [
                        "data"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": ""
          },
          "400": {
            "$ref": "#/components/responses/ApiErrorInvalidRequest"
          },
          "401": {
            "$ref": "#/components/responses/ApiErrorAuth"
          },
          "403": {
            "$ref": "#/components/responses/ApiErrorForbidden"
          },
          "404": {
            "$ref": "#/components/responses/ApiErrorNotFound"
          },
          "409": {
            "$ref": "#/components/responses/ApiErrorConflict"
          },
          "429": {
            "$ref": "#/components/responses/ApiErrorRateLimit"
          },
          "500": {
            "$ref": "#/components/responses/ApiErrorServer"
          }
        },
        "security": [
          {
            "bearer": []
          },
          {
            "api-key": []
          }
        ],
        "summary": "Sube una imagen; devuelve `storage_path` para usar en un bloque de imagen",
        "tags": [
          "Items"
        ],
        "x-scope": "items:write"
      }
    },
    "/items/{itemId}/files": {
      "get": {
        "externalDocs": {
          "description": "Guía: Datos: colecciones e ítems",
          "url": "https://developers.meteor.com.co/guias/colecciones-e-items.html"
        },
        "operationId": "FilesController_findByItem",
        "parameters": [
          {
            "description": "ID numérico del ítem (fila de una colección).",
            "in": "path",
            "name": "itemId",
            "required": true,
            "schema": {
              "type": "number"
            }
          }
        ],
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "allOf": [
                    {
                      "$ref": "#/components/schemas/ApiEnvelope"
                    },
                    {
                      "properties": {
                        "data": {
                          "items": {
                            "$ref": "#/components/schemas/ItemFileResponseDto"
                          },
                          "type": "array"
                        }
                      },
                      "required": [
                        "data"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": ""
          },
          "400": {
            "$ref": "#/components/responses/ApiErrorInvalidRequest"
          },
          "401": {
            "$ref": "#/components/responses/ApiErrorAuth"
          },
          "403": {
            "$ref": "#/components/responses/ApiErrorForbidden"
          },
          "404": {
            "$ref": "#/components/responses/ApiErrorNotFound"
          },
          "429": {
            "$ref": "#/components/responses/ApiErrorRateLimit"
          },
          "500": {
            "$ref": "#/components/responses/ApiErrorServer"
          }
        },
        "security": [
          {
            "bearer": []
          },
          {
            "api-key": []
          }
        ],
        "summary": "Lista los archivos del item",
        "tags": [
          "Items"
        ],
        "x-scope": "items:read"
      },
      "post": {
        "externalDocs": {
          "description": "Guía: Datos: colecciones e ítems",
          "url": "https://developers.meteor.com.co/guias/colecciones-e-items.html"
        },
        "operationId": "FilesController_upload",
        "parameters": [
          {
            "description": "ID numérico del ítem (fila de una colección).",
            "in": "path",
            "name": "itemId",
            "required": true,
            "schema": {
              "type": "number"
            }
          }
        ],
        "responses": {
          "201": {
            "content": {
              "application/json": {
                "schema": {
                  "allOf": [
                    {
                      "$ref": "#/components/schemas/ApiEnvelope"
                    },
                    {
                      "properties": {
                        "data": {
                          "$ref": "#/components/schemas/ItemFileUploadResponseDto"
                        }
                      },
                      "required": [
                        "data"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": ""
          },
          "400": {
            "$ref": "#/components/responses/ApiErrorInvalidRequest"
          },
          "401": {
            "$ref": "#/components/responses/ApiErrorAuth"
          },
          "403": {
            "$ref": "#/components/responses/ApiErrorForbidden"
          },
          "404": {
            "$ref": "#/components/responses/ApiErrorNotFound"
          },
          "409": {
            "$ref": "#/components/responses/ApiErrorConflict"
          },
          "429": {
            "$ref": "#/components/responses/ApiErrorRateLimit"
          },
          "500": {
            "$ref": "#/components/responses/ApiErrorServer"
          }
        },
        "security": [
          {
            "bearer": []
          },
          {
            "api-key": []
          }
        ],
        "summary": "Adjunta un archivo a un item (máx. 25MB). Envía multipart `file`, O un body JSON { url, filename } para adjuntar desde una URL pública. La respuesta incluye un `download_url` firmado.",
        "tags": [
          "Items"
        ],
        "x-scope": "items:write"
      }
    },
    "/items/{itemId}/links": {
      "get": {
        "externalDocs": {
          "description": "Guía: Datos: colecciones e ítems",
          "url": "https://developers.meteor.com.co/guias/colecciones-e-items.html"
        },
        "operationId": "ItemLinksController_findByItem",
        "parameters": [
          {
            "description": "ID numérico del ítem (fila de una colección).",
            "in": "path",
            "name": "itemId",
            "required": true,
            "schema": {
              "type": "number"
            }
          }
        ],
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "allOf": [
                    {
                      "$ref": "#/components/schemas/ApiEnvelope"
                    },
                    {
                      "properties": {
                        "data": {
                          "items": {
                            "$ref": "#/components/schemas/ItemLinkResponseDto"
                          },
                          "type": "array"
                        }
                      },
                      "required": [
                        "data"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": ""
          },
          "400": {
            "$ref": "#/components/responses/ApiErrorInvalidRequest"
          },
          "401": {
            "$ref": "#/components/responses/ApiErrorAuth"
          },
          "403": {
            "$ref": "#/components/responses/ApiErrorForbidden"
          },
          "404": {
            "$ref": "#/components/responses/ApiErrorNotFound"
          },
          "429": {
            "$ref": "#/components/responses/ApiErrorRateLimit"
          },
          "500": {
            "$ref": "#/components/responses/ApiErrorServer"
          }
        },
        "security": [
          {
            "bearer": []
          },
          {
            "api-key": []
          }
        ],
        "summary": "Lista los enlaces del item",
        "tags": [
          "Item Links"
        ],
        "x-scope": "items:read"
      },
      "post": {
        "externalDocs": {
          "description": "Guía: Datos: colecciones e ítems",
          "url": "https://developers.meteor.com.co/guias/colecciones-e-items.html"
        },
        "operationId": "ItemLinksController_create",
        "parameters": [
          {
            "description": "ID numérico del ítem (fila de una colección).",
            "in": "path",
            "name": "itemId",
            "required": true,
            "schema": {
              "type": "number"
            }
          }
        ],
        "responses": {
          "201": {
            "content": {
              "application/json": {
                "schema": {
                  "allOf": [
                    {
                      "$ref": "#/components/schemas/ApiEnvelope"
                    },
                    {
                      "properties": {
                        "data": {
                          "$ref": "#/components/schemas/ItemLinkResponseDto"
                        }
                      },
                      "required": [
                        "data"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": ""
          },
          "400": {
            "$ref": "#/components/responses/ApiErrorInvalidRequest"
          },
          "401": {
            "$ref": "#/components/responses/ApiErrorAuth"
          },
          "403": {
            "$ref": "#/components/responses/ApiErrorForbidden"
          },
          "404": {
            "$ref": "#/components/responses/ApiErrorNotFound"
          },
          "409": {
            "$ref": "#/components/responses/ApiErrorConflict"
          },
          "429": {
            "$ref": "#/components/responses/ApiErrorRateLimit"
          },
          "500": {
            "$ref": "#/components/responses/ApiErrorServer"
          }
        },
        "security": [
          {
            "bearer": []
          },
          {
            "api-key": []
          }
        ],
        "summary": "Crea un enlace entre items",
        "tags": [
          "Item Links"
        ],
        "x-scope": "items:write"
      }
    },
    "/items/{itemId}/slug": {
      "put": {
        "externalDocs": {
          "description": "Guía: Datos: colecciones e ítems",
          "url": "https://developers.meteor.com.co/guias/colecciones-e-items.html"
        },
        "operationId": "SlugsController_updateItemSlug",
        "parameters": [
          {
            "description": "ID numérico del ítem (fila de una colección).",
            "in": "path",
            "name": "itemId",
            "required": true,
            "schema": {
              "type": "number"
            }
          }
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/UpdateSlugDto"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "allOf": [
                    {
                      "$ref": "#/components/schemas/ApiEnvelope"
                    },
                    {
                      "properties": {
                        "data": {
                          "$ref": "#/components/schemas/SlugUpdatedResponseDto"
                        }
                      },
                      "required": [
                        "data"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": ""
          },
          "400": {
            "$ref": "#/components/responses/ApiErrorInvalidRequest"
          },
          "401": {
            "$ref": "#/components/responses/ApiErrorAuth"
          },
          "403": {
            "$ref": "#/components/responses/ApiErrorForbidden"
          },
          "404": {
            "$ref": "#/components/responses/ApiErrorNotFound"
          },
          "409": {
            "$ref": "#/components/responses/ApiErrorConflict"
          },
          "429": {
            "$ref": "#/components/responses/ApiErrorRateLimit"
          },
          "500": {
            "$ref": "#/components/responses/ApiErrorServer"
          }
        },
        "security": [
          {
            "bearer": []
          },
          {
            "api-key": []
          }
        ],
        "summary": "Actualiza el slug del item",
        "tags": [
          "Collections"
        ],
        "x-scope": "collections:write"
      }
    },
    "/mcp": {
      "post": {
        "externalDocs": {
          "description": "Guía: Integraciones MCP",
          "url": "https://developers.meteor.com.co/guias/integraciones-mcp.html"
        },
        "operationId": "McpServerController_handle",
        "parameters": [],
        "responses": {
          "201": {
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/McpJsonRpcResponseDto"
                }
              }
            },
            "description": ""
          },
          "400": {
            "$ref": "#/components/responses/ApiErrorInvalidRequest"
          },
          "401": {
            "$ref": "#/components/responses/ApiErrorAuth"
          },
          "403": {
            "$ref": "#/components/responses/ApiErrorForbidden"
          },
          "404": {
            "$ref": "#/components/responses/ApiErrorNotFound"
          },
          "409": {
            "$ref": "#/components/responses/ApiErrorConflict"
          },
          "429": {
            "$ref": "#/components/responses/ApiErrorRateLimit"
          },
          "500": {
            "$ref": "#/components/responses/ApiErrorServer"
          }
        },
        "security": [
          {
            "bearer": []
          },
          {
            "api-key": []
          }
        ],
        "summary": "Servidor MCP — transporte JSON-RPC (Streamable HTTP) sobre la superficie pública",
        "tags": [
          "MCP"
        ],
        "x-scope": "mcp:use",
        "x-sin-sobre": true
      }
    },
    "/mcps/active": {
      "get": {
        "externalDocs": {
          "description": "Guía: Datos: colecciones e ítems",
          "url": "https://developers.meteor.com.co/guias/colecciones-e-items.html"
        },
        "operationId": "ItemLinksController_getActiveMcps",
        "parameters": [],
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "allOf": [
                    {
                      "$ref": "#/components/schemas/ApiEnvelope"
                    },
                    {
                      "properties": {
                        "data": {
                          "items": {
                            "$ref": "#/components/schemas/ActiveMcpResponseDto"
                          },
                          "type": "array"
                        }
                      },
                      "required": [
                        "data"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": ""
          },
          "400": {
            "$ref": "#/components/responses/ApiErrorInvalidRequest"
          },
          "401": {
            "$ref": "#/components/responses/ApiErrorAuth"
          },
          "403": {
            "$ref": "#/components/responses/ApiErrorForbidden"
          },
          "404": {
            "$ref": "#/components/responses/ApiErrorNotFound"
          },
          "429": {
            "$ref": "#/components/responses/ApiErrorRateLimit"
          },
          "500": {
            "$ref": "#/components/responses/ApiErrorServer"
          }
        },
        "security": [
          {
            "bearer": []
          },
          {
            "api-key": []
          }
        ],
        "summary": "Lista los MCP activos",
        "tags": [
          "Item Links"
        ],
        "x-scope": "integrations:read"
      }
    },
    "/me": {
      "get": {
        "externalDocs": {
          "description": "Guía: Autenticación",
          "url": "https://developers.meteor.com.co/guias/autenticacion.html"
        },
        "operationId": "ApiIdentityController_me",
        "parameters": [],
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "allOf": [
                    {
                      "$ref": "#/components/schemas/ApiEnvelope"
                    },
                    {
                      "properties": {
                        "data": {
                          "$ref": "#/components/schemas/IdentityResponseDto"
                        }
                      },
                      "required": [
                        "data"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": ""
          },
          "400": {
            "$ref": "#/components/responses/ApiErrorInvalidRequest"
          },
          "401": {
            "$ref": "#/components/responses/ApiErrorAuth"
          },
          "403": {
            "$ref": "#/components/responses/ApiErrorForbidden"
          },
          "404": {
            "$ref": "#/components/responses/ApiErrorNotFound"
          },
          "429": {
            "$ref": "#/components/responses/ApiErrorRateLimit"
          },
          "500": {
            "$ref": "#/components/responses/ApiErrorServer"
          }
        },
        "security": [
          {
            "bearer": []
          },
          {
            "api-key": []
          }
        ],
        "summary": "Devuelve la identidad de la key que llama: dueño, scopes, entorno y límites",
        "tags": [
          "Identidad"
        ],
        "x-scope": "runs:read"
      }
    },
    "/node-registry": {
      "get": {
        "externalDocs": {
          "description": "Guía: Funciones y flujos",
          "url": "https://developers.meteor.com.co/guias/funciones-y-flujos.html"
        },
        "operationId": "FlowsController_nodeRegistry",
        "parameters": [],
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "allOf": [
                    {
                      "$ref": "#/components/schemas/ApiEnvelope"
                    },
                    {
                      "properties": {
                        "data": {
                          "$ref": "#/components/schemas/NodeRegistryResponseDto"
                        }
                      },
                      "required": [
                        "data"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": ""
          },
          "400": {
            "$ref": "#/components/responses/ApiErrorInvalidRequest"
          },
          "401": {
            "$ref": "#/components/responses/ApiErrorAuth"
          },
          "403": {
            "$ref": "#/components/responses/ApiErrorForbidden"
          },
          "404": {
            "$ref": "#/components/responses/ApiErrorNotFound"
          },
          "429": {
            "$ref": "#/components/responses/ApiErrorRateLimit"
          },
          "500": {
            "$ref": "#/components/responses/ApiErrorServer"
          }
        },
        "security": [
          {
            "bearer": []
          },
          {
            "api-key": []
          }
        ],
        "summary": "Catálogo de tipos de nodo del MVP",
        "tags": [
          "Flows"
        ],
        "x-scope": "automations:read"
      }
    },
    "/partner/payment-method": {
      "get": {
        "externalDocs": {
          "description": "Guía: Aprovisionamiento de cuentas",
          "url": "https://developers.meteor.com.co/guias/aprovisionamiento.html"
        },
        "operationId": "ApiProvisioningController_paymentMethod",
        "parameters": [],
        "responses": {
          "200": {
            "description": ""
          },
          "400": {
            "$ref": "#/components/responses/ApiErrorInvalidRequest"
          },
          "401": {
            "$ref": "#/components/responses/ApiErrorAuth"
          },
          "403": {
            "$ref": "#/components/responses/ApiErrorForbidden"
          },
          "404": {
            "$ref": "#/components/responses/ApiErrorNotFound"
          },
          "429": {
            "$ref": "#/components/responses/ApiErrorRateLimit"
          },
          "500": {
            "$ref": "#/components/responses/ApiErrorServer"
          }
        },
        "security": [
          {
            "bearer": []
          },
          {
            "api-key": []
          }
        ],
        "summary": "El medio de pago con el que el partner paga las cuentas que gestiona.",
        "tags": [
          "Provisioning"
        ],
        "x-scope": "partner:billing:manage"
      }
    },
    "/partner/payment-method/setup": {
      "post": {
        "externalDocs": {
          "description": "Guía: Aprovisionamiento de cuentas",
          "url": "https://developers.meteor.com.co/guias/aprovisionamiento.html"
        },
        "operationId": "ApiProvisioningController_setupPaymentMethod",
        "parameters": [],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/SetupPaymentMethodDto"
              }
            }
          },
          "required": true
        },
        "responses": {
          "201": {
            "description": ""
          },
          "400": {
            "$ref": "#/components/responses/ApiErrorInvalidRequest"
          },
          "401": {
            "$ref": "#/components/responses/ApiErrorAuth"
          },
          "403": {
            "$ref": "#/components/responses/ApiErrorForbidden"
          },
          "404": {
            "$ref": "#/components/responses/ApiErrorNotFound"
          },
          "409": {
            "$ref": "#/components/responses/ApiErrorConflict"
          },
          "429": {
            "$ref": "#/components/responses/ApiErrorRateLimit"
          },
          "500": {
            "$ref": "#/components/responses/ApiErrorServer"
          }
        },
        "security": [
          {
            "bearer": []
          },
          {
            "api-key": []
          }
        ],
        "summary": "Abre un Checkout en modo setup para guardar la tarjeta del partner.",
        "tags": [
          "Provisioning"
        ],
        "x-scope": "partner:billing:manage"
      }
    },
    "/reminders": {
      "get": {
        "description": "Ordenados por `scheduled_for` ascendente y topeados a 100. Incluye los ya enviados, cancelados y fallidos; filtrá con `status=pending` para ver solo los que todavía van a salir.",
        "externalDocs": {
          "description": "Guía: Operación del workspace",
          "url": "https://developers.meteor.com.co/guias/operacion-del-workspace.html"
        },
        "operationId": "RemindersController_list",
        "parameters": [
          {
            "description": "Filtra por contacto del CRM.",
            "in": "query",
            "name": "contact_id",
            "required": true,
            "schema": {
              "type": "string"
            }
          },
          {
            "description": "Filtra por estado.",
            "in": "query",
            "name": "status",
            "required": true,
            "schema": {
              "type": "string"
            }
          }
        ],
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "allOf": [
                    {
                      "$ref": "#/components/schemas/ApiEnvelope"
                    },
                    {
                      "properties": {
                        "data": {
                          "items": {
                            "$ref": "#/components/schemas/ReminderResponseDto"
                          },
                          "type": "array"
                        }
                      },
                      "required": [
                        "data"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": ""
          },
          "400": {
            "$ref": "#/components/responses/ApiErrorInvalidRequest"
          },
          "401": {
            "$ref": "#/components/responses/ApiErrorAuth"
          },
          "403": {
            "$ref": "#/components/responses/ApiErrorForbidden"
          },
          "404": {
            "$ref": "#/components/responses/ApiErrorNotFound"
          },
          "429": {
            "$ref": "#/components/responses/ApiErrorRateLimit"
          },
          "500": {
            "$ref": "#/components/responses/ApiErrorServer"
          }
        },
        "security": [
          {
            "bearer": []
          },
          {
            "api-key": []
          }
        ],
        "summary": "Lista recordatorios del workspace (filtros: contact_id, status)",
        "tags": [
          "Reminders"
        ],
        "x-scope": "reminders:read"
      },
      "post": {
        "description": "A la hora indicada, Meteor **le escribe al contacto por WhatsApp** con una plantilla aprobada. No es una nota interna ni un aviso para el equipo: si lo creas, se envía. El único campo que no viaja al contacto es `note`. `scheduled_for` debe ser futuro; sin offset se interpreta en la zona horaria del workspace. Sin `template_name` se usa la plantilla de recordatorio por defecto del workspace, y si no hay ninguna configurada la creación falla con 400.",
        "externalDocs": {
          "description": "Guía: Operación del workspace",
          "url": "https://developers.meteor.com.co/guias/operacion-del-workspace.html"
        },
        "operationId": "RemindersController_create",
        "parameters": [],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/CreateReminderDto"
              }
            }
          },
          "required": true
        },
        "responses": {
          "201": {
            "content": {
              "application/json": {
                "schema": {
                  "allOf": [
                    {
                      "$ref": "#/components/schemas/ApiEnvelope"
                    },
                    {
                      "properties": {
                        "data": {
                          "$ref": "#/components/schemas/ReminderResponseDto"
                        }
                      },
                      "required": [
                        "data"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": ""
          },
          "400": {
            "$ref": "#/components/responses/ApiErrorInvalidRequest"
          },
          "401": {
            "$ref": "#/components/responses/ApiErrorAuth"
          },
          "403": {
            "$ref": "#/components/responses/ApiErrorForbidden"
          },
          "404": {
            "$ref": "#/components/responses/ApiErrorNotFound"
          },
          "409": {
            "$ref": "#/components/responses/ApiErrorConflict"
          },
          "429": {
            "$ref": "#/components/responses/ApiErrorRateLimit"
          },
          "500": {
            "$ref": "#/components/responses/ApiErrorServer"
          }
        },
        "security": [
          {
            "bearer": []
          },
          {
            "api-key": []
          }
        ],
        "summary": "Crea un recordatorio (envío de plantilla WhatsApp agendado)",
        "tags": [
          "Reminders"
        ],
        "x-scope": "reminders:write"
      }
    },
    "/reminders/{id}": {
      "delete": {
        "description": "Evita que el mensaje le llegue al contacto. Solo funciona mientras siga `pending`: un recordatorio ya enviado responde 404 y no se puede deshacer.",
        "externalDocs": {
          "description": "Guía: Operación del workspace",
          "url": "https://developers.meteor.com.co/guias/operacion-del-workspace.html"
        },
        "operationId": "RemindersController_cancel",
        "parameters": [
          {
            "description": "ID del recurso de esta ruta.",
            "in": "path",
            "name": "id",
            "required": true,
            "schema": {
              "type": "number"
            }
          }
        ],
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "allOf": [
                    {
                      "$ref": "#/components/schemas/ApiEnvelope"
                    },
                    {
                      "properties": {
                        "data": {
                          "$ref": "#/components/schemas/ReminderCancelResponseDto"
                        }
                      },
                      "required": [
                        "data"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": ""
          },
          "400": {
            "$ref": "#/components/responses/ApiErrorInvalidRequest"
          },
          "401": {
            "$ref": "#/components/responses/ApiErrorAuth"
          },
          "403": {
            "$ref": "#/components/responses/ApiErrorForbidden"
          },
          "404": {
            "$ref": "#/components/responses/ApiErrorNotFound"
          },
          "409": {
            "$ref": "#/components/responses/ApiErrorConflict"
          },
          "429": {
            "$ref": "#/components/responses/ApiErrorRateLimit"
          },
          "500": {
            "$ref": "#/components/responses/ApiErrorServer"
          }
        },
        "security": [
          {
            "bearer": []
          },
          {
            "api-key": []
          }
        ],
        "summary": "Cancela un recordatorio pendiente",
        "tags": [
          "Reminders"
        ],
        "x-scope": "reminders:write"
      },
      "patch": {
        "description": "Solo mientras siga `pending`; si ya se envió o se canceló responde 404. Cambiar `message` cambia lo que va a leer el contacto.",
        "externalDocs": {
          "description": "Guía: Operación del workspace",
          "url": "https://developers.meteor.com.co/guias/operacion-del-workspace.html"
        },
        "operationId": "RemindersController_update",
        "parameters": [
          {
            "description": "ID del recurso de esta ruta.",
            "in": "path",
            "name": "id",
            "required": true,
            "schema": {
              "type": "number"
            }
          }
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/UpdateReminderDto"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "allOf": [
                    {
                      "$ref": "#/components/schemas/ApiEnvelope"
                    },
                    {
                      "properties": {
                        "data": {
                          "$ref": "#/components/schemas/ReminderResponseDto"
                        }
                      },
                      "required": [
                        "data"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": ""
          },
          "400": {
            "$ref": "#/components/responses/ApiErrorInvalidRequest"
          },
          "401": {
            "$ref": "#/components/responses/ApiErrorAuth"
          },
          "403": {
            "$ref": "#/components/responses/ApiErrorForbidden"
          },
          "404": {
            "$ref": "#/components/responses/ApiErrorNotFound"
          },
          "409": {
            "$ref": "#/components/responses/ApiErrorConflict"
          },
          "429": {
            "$ref": "#/components/responses/ApiErrorRateLimit"
          },
          "500": {
            "$ref": "#/components/responses/ApiErrorServer"
          }
        },
        "security": [
          {
            "bearer": []
          },
          {
            "api-key": []
          }
        ],
        "summary": "Edita un recordatorio pendiente (fecha/hora, texto, nota)",
        "tags": [
          "Reminders"
        ],
        "x-scope": "reminders:write"
      }
    },
    "/resolve/code/{code}": {
      "get": {
        "externalDocs": {
          "description": "Guía: Datos: colecciones e ítems",
          "url": "https://developers.meteor.com.co/guias/colecciones-e-items.html"
        },
        "operationId": "SlugsController_resolveByCode",
        "parameters": [
          {
            "description": "Código del recurso: identificador corto y estable.",
            "in": "path",
            "name": "code",
            "required": true,
            "schema": {
              "type": "string"
            }
          }
        ],
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "allOf": [
                    {
                      "$ref": "#/components/schemas/ApiEnvelope"
                    },
                    {
                      "properties": {
                        "data": {
                          "oneOf": [
                            {
                              "$ref": "#/components/schemas/ResolvedCodeCollectionDto"
                            },
                            {
                              "$ref": "#/components/schemas/ResolvedCodeItemDto"
                            }
                          ]
                        }
                      },
                      "required": [
                        "data"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Mira `type` para saber qué resolvió el código: una colección o un item."
          },
          "400": {
            "$ref": "#/components/responses/ApiErrorInvalidRequest"
          },
          "401": {
            "$ref": "#/components/responses/ApiErrorAuth"
          },
          "403": {
            "$ref": "#/components/responses/ApiErrorForbidden"
          },
          "404": {
            "$ref": "#/components/responses/ApiErrorNotFound"
          },
          "429": {
            "$ref": "#/components/responses/ApiErrorRateLimit"
          },
          "500": {
            "$ref": "#/components/responses/ApiErrorServer"
          }
        },
        "security": [
          {
            "bearer": []
          },
          {
            "api-key": []
          }
        ],
        "summary": "Resuelve un código corto a su recurso (acotado al workspace que llama)",
        "tags": [
          "Collections"
        ],
        "x-scope": "collections:read"
      }
    },
    "/resolve/folder-slug/{slug}": {
      "get": {
        "externalDocs": {
          "description": "Guía: Datos: colecciones e ítems",
          "url": "https://developers.meteor.com.co/guias/colecciones-e-items.html"
        },
        "operationId": "SlugsController_resolveFolderBySlug",
        "parameters": [
          {
            "description": "Identificador legible del recurso (en minúsculas y con guiones).",
            "in": "path",
            "name": "slug",
            "required": true,
            "schema": {
              "type": "string"
            }
          }
        ],
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "allOf": [
                    {
                      "$ref": "#/components/schemas/ApiEnvelope"
                    },
                    {
                      "properties": {
                        "data": {
                          "$ref": "#/components/schemas/ResolvedFolderDto"
                        }
                      },
                      "required": [
                        "data"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": ""
          },
          "400": {
            "$ref": "#/components/responses/ApiErrorInvalidRequest"
          },
          "401": {
            "$ref": "#/components/responses/ApiErrorAuth"
          },
          "403": {
            "$ref": "#/components/responses/ApiErrorForbidden"
          },
          "404": {
            "$ref": "#/components/responses/ApiErrorNotFound"
          },
          "429": {
            "$ref": "#/components/responses/ApiErrorRateLimit"
          },
          "500": {
            "$ref": "#/components/responses/ApiErrorServer"
          }
        },
        "security": [
          {
            "bearer": []
          },
          {
            "api-key": []
          }
        ],
        "summary": "Resuelve una carpeta por slug (acotado al workspace que llama)",
        "tags": [
          "Collections"
        ],
        "x-scope": "collections:read"
      }
    },
    "/runs/{id}": {
      "get": {
        "externalDocs": {
          "description": "Guía: Ejecutar Mets (Runs)",
          "url": "https://developers.meteor.com.co/guias/ejecutar-agentes.html"
        },
        "operationId": "ApiRunsController_get",
        "parameters": [
          {
            "description": "ID del recurso de esta ruta.",
            "in": "path",
            "name": "id",
            "required": true,
            "schema": {
              "type": "string"
            }
          }
        ],
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "allOf": [
                    {
                      "$ref": "#/components/schemas/ApiEnvelope"
                    },
                    {
                      "properties": {
                        "data": {
                          "$ref": "#/components/schemas/RunResponseDto"
                        }
                      },
                      "required": [
                        "data"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": ""
          },
          "400": {
            "$ref": "#/components/responses/ApiErrorInvalidRequest"
          },
          "401": {
            "$ref": "#/components/responses/ApiErrorAuth"
          },
          "403": {
            "$ref": "#/components/responses/ApiErrorForbidden"
          },
          "404": {
            "$ref": "#/components/responses/ApiErrorNotFound"
          },
          "429": {
            "$ref": "#/components/responses/ApiErrorRateLimit"
          },
          "500": {
            "$ref": "#/components/responses/ApiErrorServer"
          }
        },
        "security": [
          {
            "bearer": []
          },
          {
            "api-key": []
          }
        ],
        "summary": "Estado + salida de un Run",
        "tags": [
          "Runs"
        ],
        "x-scope": "runs:read"
      }
    },
    "/skills/all": {
      "get": {
        "externalDocs": {
          "description": "Guía: Datos: colecciones e ítems",
          "url": "https://developers.meteor.com.co/guias/colecciones-e-items.html"
        },
        "operationId": "ItemLinksController_getAllSkills",
        "parameters": [],
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "allOf": [
                    {
                      "$ref": "#/components/schemas/ApiEnvelope"
                    },
                    {
                      "properties": {
                        "data": {
                          "items": {
                            "$ref": "#/components/schemas/ActiveSkillResponseDto"
                          },
                          "type": "array"
                        }
                      },
                      "required": [
                        "data"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": ""
          },
          "400": {
            "$ref": "#/components/responses/ApiErrorInvalidRequest"
          },
          "401": {
            "$ref": "#/components/responses/ApiErrorAuth"
          },
          "403": {
            "$ref": "#/components/responses/ApiErrorForbidden"
          },
          "404": {
            "$ref": "#/components/responses/ApiErrorNotFound"
          },
          "429": {
            "$ref": "#/components/responses/ApiErrorRateLimit"
          },
          "500": {
            "$ref": "#/components/responses/ApiErrorServer"
          }
        },
        "security": [
          {
            "bearer": []
          },
          {
            "api-key": []
          }
        ],
        "summary": "Lista las habilidades activas del workspace",
        "tags": [
          "Item Links"
        ],
        "x-scope": "skills:read"
      }
    },
    "/task-executions/{executionId}": {
      "get": {
        "description": "Incluye `task_step_executions`: el resultado de cada paso de esa corrida.",
        "externalDocs": {
          "description": "Guía: Tareas",
          "url": "https://developers.meteor.com.co/guias/tareas.html"
        },
        "operationId": "TasksController_getExecution",
        "parameters": [
          {
            "description": "ID de la ejecución (la devuelve el endpoint que la dispara).",
            "in": "path",
            "name": "executionId",
            "required": true,
            "schema": {
              "type": "string"
            }
          }
        ],
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "allOf": [
                    {
                      "$ref": "#/components/schemas/ApiEnvelope"
                    },
                    {
                      "properties": {
                        "data": {
                          "$ref": "#/components/schemas/TaskExecutionResponseDto"
                        }
                      },
                      "required": [
                        "data"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": ""
          },
          "400": {
            "$ref": "#/components/responses/ApiErrorInvalidRequest"
          },
          "401": {
            "$ref": "#/components/responses/ApiErrorAuth"
          },
          "403": {
            "$ref": "#/components/responses/ApiErrorForbidden"
          },
          "404": {
            "$ref": "#/components/responses/ApiErrorNotFound"
          },
          "429": {
            "$ref": "#/components/responses/ApiErrorRateLimit"
          },
          "500": {
            "$ref": "#/components/responses/ApiErrorServer"
          }
        },
        "security": [
          {
            "bearer": []
          },
          {
            "api-key": []
          }
        ],
        "summary": "Obtiene el detalle de la ejecución",
        "tags": [
          "Tasks"
        ],
        "x-scope": "tasks:read"
      }
    },
    "/task-executions/{executionId}/approve-step/{stepId}": {
      "post": {
        "description": "Solo sobre un paso en `waiting_for_approval`; cualquier otro estado responde 404. La ejecución sigue con el paso siguiente en segundo plano, así que la respuesta describe el paso aprobado, no el resultado final de la tarea.",
        "externalDocs": {
          "description": "Guía: Tareas",
          "url": "https://developers.meteor.com.co/guias/tareas.html"
        },
        "operationId": "TasksController_approveStep",
        "parameters": [
          {
            "description": "ID de la ejecución (la devuelve el endpoint que la dispara).",
            "in": "path",
            "name": "executionId",
            "required": true,
            "schema": {
              "type": "string"
            }
          },
          {
            "description": "ID del paso dentro de la tarea.",
            "in": "path",
            "name": "stepId",
            "required": true,
            "schema": {
              "type": "string"
            }
          }
        ],
        "responses": {
          "201": {
            "content": {
              "application/json": {
                "schema": {
                  "allOf": [
                    {
                      "$ref": "#/components/schemas/ApiEnvelope"
                    },
                    {
                      "properties": {
                        "data": {
                          "$ref": "#/components/schemas/TaskStepExecutionResponseDto"
                        }
                      },
                      "required": [
                        "data"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": ""
          },
          "400": {
            "$ref": "#/components/responses/ApiErrorInvalidRequest"
          },
          "401": {
            "$ref": "#/components/responses/ApiErrorAuth"
          },
          "403": {
            "$ref": "#/components/responses/ApiErrorForbidden"
          },
          "404": {
            "$ref": "#/components/responses/ApiErrorNotFound"
          },
          "409": {
            "$ref": "#/components/responses/ApiErrorConflict"
          },
          "429": {
            "$ref": "#/components/responses/ApiErrorRateLimit"
          },
          "500": {
            "$ref": "#/components/responses/ApiErrorServer"
          }
        },
        "security": [
          {
            "bearer": []
          },
          {
            "api-key": []
          }
        ],
        "summary": "Aprueba la ejecución de un paso",
        "tags": [
          "Tasks"
        ],
        "x-scope": "tasks:write"
      }
    },
    "/task-executions/{executionId}/cancel": {
      "post": {
        "description": "Marca la ejecución como `cancelled`. El paso que ya esté corriendo termina; se cortan los siguientes.",
        "externalDocs": {
          "description": "Guía: Tareas",
          "url": "https://developers.meteor.com.co/guias/tareas.html"
        },
        "operationId": "TasksController_cancelExecution",
        "parameters": [
          {
            "description": "ID de la ejecución (la devuelve el endpoint que la dispara).",
            "in": "path",
            "name": "executionId",
            "required": true,
            "schema": {
              "type": "string"
            }
          }
        ],
        "responses": {
          "201": {
            "content": {
              "application/json": {
                "schema": {
                  "allOf": [
                    {
                      "$ref": "#/components/schemas/ApiEnvelope"
                    },
                    {
                      "properties": {
                        "data": {
                          "$ref": "#/components/schemas/TaskExecutionResponseDto"
                        }
                      },
                      "required": [
                        "data"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": ""
          },
          "400": {
            "$ref": "#/components/responses/ApiErrorInvalidRequest"
          },
          "401": {
            "$ref": "#/components/responses/ApiErrorAuth"
          },
          "403": {
            "$ref": "#/components/responses/ApiErrorForbidden"
          },
          "404": {
            "$ref": "#/components/responses/ApiErrorNotFound"
          },
          "409": {
            "$ref": "#/components/responses/ApiErrorConflict"
          },
          "429": {
            "$ref": "#/components/responses/ApiErrorRateLimit"
          },
          "500": {
            "$ref": "#/components/responses/ApiErrorServer"
          }
        },
        "security": [
          {
            "bearer": []
          },
          {
            "api-key": []
          }
        ],
        "summary": "Cancela la ejecución",
        "tags": [
          "Tasks"
        ],
        "x-scope": "tasks:write"
      }
    },
    "/task-executions/{executionId}/complete-human-step/{stepId}": {
      "post": {
        "description": "Solo sobre un paso en `waiting_for_human`. El `comment` queda como salida del paso, así que los pasos siguientes lo pueden leer. La ejecución sigue en segundo plano.",
        "externalDocs": {
          "description": "Guía: Tareas",
          "url": "https://developers.meteor.com.co/guias/tareas.html"
        },
        "operationId": "TasksController_completeHumanStep",
        "parameters": [
          {
            "description": "ID de la ejecución (la devuelve el endpoint que la dispara).",
            "in": "path",
            "name": "executionId",
            "required": true,
            "schema": {
              "type": "string"
            }
          },
          {
            "description": "ID del paso dentro de la tarea.",
            "in": "path",
            "name": "stepId",
            "required": true,
            "schema": {
              "type": "string"
            }
          }
        ],
        "responses": {
          "201": {
            "content": {
              "application/json": {
                "schema": {
                  "allOf": [
                    {
                      "$ref": "#/components/schemas/ApiEnvelope"
                    },
                    {
                      "properties": {
                        "data": {
                          "$ref": "#/components/schemas/TaskStepExecutionResponseDto"
                        }
                      },
                      "required": [
                        "data"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": ""
          },
          "400": {
            "$ref": "#/components/responses/ApiErrorInvalidRequest"
          },
          "401": {
            "$ref": "#/components/responses/ApiErrorAuth"
          },
          "403": {
            "$ref": "#/components/responses/ApiErrorForbidden"
          },
          "404": {
            "$ref": "#/components/responses/ApiErrorNotFound"
          },
          "409": {
            "$ref": "#/components/responses/ApiErrorConflict"
          },
          "429": {
            "$ref": "#/components/responses/ApiErrorRateLimit"
          },
          "500": {
            "$ref": "#/components/responses/ApiErrorServer"
          }
        },
        "security": [
          {
            "bearer": []
          },
          {
            "api-key": []
          }
        ],
        "summary": "Marcar un step type=human_task como completado por el asignee",
        "tags": [
          "Tasks"
        ],
        "x-scope": "tasks:write"
      }
    },
    "/task-executions/{executionId}/reject-step/{stepId}": {
      "post": {
        "description": "Solo sobre un paso en `waiting_for_approval`. A diferencia de aprobar, la ejecución no continúa.",
        "externalDocs": {
          "description": "Guía: Tareas",
          "url": "https://developers.meteor.com.co/guias/tareas.html"
        },
        "operationId": "TasksController_rejectStep",
        "parameters": [
          {
            "description": "ID de la ejecución (la devuelve el endpoint que la dispara).",
            "in": "path",
            "name": "executionId",
            "required": true,
            "schema": {
              "type": "string"
            }
          },
          {
            "description": "ID del paso dentro de la tarea.",
            "in": "path",
            "name": "stepId",
            "required": true,
            "schema": {
              "type": "string"
            }
          }
        ],
        "responses": {
          "201": {
            "content": {
              "application/json": {
                "schema": {
                  "allOf": [
                    {
                      "$ref": "#/components/schemas/ApiEnvelope"
                    },
                    {
                      "properties": {
                        "data": {
                          "$ref": "#/components/schemas/TaskStepExecutionResponseDto"
                        }
                      },
                      "required": [
                        "data"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": ""
          },
          "400": {
            "$ref": "#/components/responses/ApiErrorInvalidRequest"
          },
          "401": {
            "$ref": "#/components/responses/ApiErrorAuth"
          },
          "403": {
            "$ref": "#/components/responses/ApiErrorForbidden"
          },
          "404": {
            "$ref": "#/components/responses/ApiErrorNotFound"
          },
          "409": {
            "$ref": "#/components/responses/ApiErrorConflict"
          },
          "429": {
            "$ref": "#/components/responses/ApiErrorRateLimit"
          },
          "500": {
            "$ref": "#/components/responses/ApiErrorServer"
          }
        },
        "security": [
          {
            "bearer": []
          },
          {
            "api-key": []
          }
        ],
        "summary": "Rechaza la ejecución de un paso",
        "tags": [
          "Tasks"
        ],
        "x-scope": "tasks:write"
      }
    },
    "/task-views/{viewId}": {
      "delete": {
        "description": "Borra la pestaña, no las tareas que mostraba.",
        "externalDocs": {
          "description": "Guía: Tareas",
          "url": "https://developers.meteor.com.co/guias/tareas.html"
        },
        "operationId": "TaskViewsController_remove",
        "parameters": [
          {
            "description": "ID de la vista guardada.",
            "in": "path",
            "name": "viewId",
            "required": true,
            "schema": {
              "type": "number"
            }
          }
        ],
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "allOf": [
                    {
                      "$ref": "#/components/schemas/ApiEnvelope"
                    },
                    {
                      "properties": {
                        "data": {
                          "$ref": "#/components/schemas/TaskMessageResponseDto"
                        }
                      },
                      "required": [
                        "data"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": ""
          },
          "400": {
            "$ref": "#/components/responses/ApiErrorInvalidRequest"
          },
          "401": {
            "$ref": "#/components/responses/ApiErrorAuth"
          },
          "403": {
            "$ref": "#/components/responses/ApiErrorForbidden"
          },
          "404": {
            "$ref": "#/components/responses/ApiErrorNotFound"
          },
          "409": {
            "$ref": "#/components/responses/ApiErrorConflict"
          },
          "429": {
            "$ref": "#/components/responses/ApiErrorRateLimit"
          },
          "500": {
            "$ref": "#/components/responses/ApiErrorServer"
          }
        },
        "security": [
          {
            "bearer": []
          },
          {
            "api-key": []
          }
        ],
        "summary": "Elimina una vista de tareas",
        "tags": [
          "Tasks"
        ],
        "x-scope": "tasks:write"
      },
      "patch": {
        "externalDocs": {
          "description": "Guía: Tareas",
          "url": "https://developers.meteor.com.co/guias/tareas.html"
        },
        "operationId": "TaskViewsController_update",
        "parameters": [
          {
            "description": "ID de la vista guardada.",
            "in": "path",
            "name": "viewId",
            "required": true,
            "schema": {
              "type": "number"
            }
          }
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/UpdateTaskViewDto"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "allOf": [
                    {
                      "$ref": "#/components/schemas/ApiEnvelope"
                    },
                    {
                      "properties": {
                        "data": {
                          "$ref": "#/components/schemas/TaskViewResponseDto"
                        }
                      },
                      "required": [
                        "data"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": ""
          },
          "400": {
            "$ref": "#/components/responses/ApiErrorInvalidRequest"
          },
          "401": {
            "$ref": "#/components/responses/ApiErrorAuth"
          },
          "403": {
            "$ref": "#/components/responses/ApiErrorForbidden"
          },
          "404": {
            "$ref": "#/components/responses/ApiErrorNotFound"
          },
          "409": {
            "$ref": "#/components/responses/ApiErrorConflict"
          },
          "429": {
            "$ref": "#/components/responses/ApiErrorRateLimit"
          },
          "500": {
            "$ref": "#/components/responses/ApiErrorServer"
          }
        },
        "security": [
          {
            "bearer": []
          },
          {
            "api-key": []
          }
        ],
        "summary": "Actualiza una vista de tareas",
        "tags": [
          "Tasks"
        ],
        "x-scope": "tasks:write"
      }
    },
    "/tasks/{taskId}": {
      "delete": {
        "description": "Se lleva sus pasos, disparadores, comentarios y ejecuciones. No se puede deshacer.",
        "externalDocs": {
          "description": "Guía: Tareas",
          "url": "https://developers.meteor.com.co/guias/tareas.html"
        },
        "operationId": "TasksController_remove",
        "parameters": [
          {
            "description": "ID de la tarea.",
            "in": "path",
            "name": "taskId",
            "required": true,
            "schema": {
              "type": "string"
            }
          }
        ],
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "allOf": [
                    {
                      "$ref": "#/components/schemas/ApiEnvelope"
                    },
                    {
                      "properties": {
                        "data": {
                          "$ref": "#/components/schemas/TaskMessageResponseDto"
                        }
                      },
                      "required": [
                        "data"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": ""
          },
          "400": {
            "$ref": "#/components/responses/ApiErrorInvalidRequest"
          },
          "401": {
            "$ref": "#/components/responses/ApiErrorAuth"
          },
          "403": {
            "$ref": "#/components/responses/ApiErrorForbidden"
          },
          "404": {
            "$ref": "#/components/responses/ApiErrorNotFound"
          },
          "409": {
            "$ref": "#/components/responses/ApiErrorConflict"
          },
          "429": {
            "$ref": "#/components/responses/ApiErrorRateLimit"
          },
          "500": {
            "$ref": "#/components/responses/ApiErrorServer"
          }
        },
        "security": [
          {
            "bearer": []
          },
          {
            "api-key": []
          }
        ],
        "summary": "Elimina la tarea",
        "tags": [
          "Tasks"
        ],
        "x-scope": "tasks:write"
      },
      "get": {
        "externalDocs": {
          "description": "Guía: Tareas",
          "url": "https://developers.meteor.com.co/guias/tareas.html"
        },
        "operationId": "TasksController_findOne",
        "parameters": [
          {
            "description": "ID de la tarea.",
            "in": "path",
            "name": "taskId",
            "required": true,
            "schema": {
              "type": "string"
            }
          }
        ],
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "allOf": [
                    {
                      "$ref": "#/components/schemas/ApiEnvelope"
                    },
                    {
                      "properties": {
                        "data": {
                          "$ref": "#/components/schemas/TaskResponseDto"
                        }
                      },
                      "required": [
                        "data"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": ""
          },
          "400": {
            "$ref": "#/components/responses/ApiErrorInvalidRequest"
          },
          "401": {
            "$ref": "#/components/responses/ApiErrorAuth"
          },
          "403": {
            "$ref": "#/components/responses/ApiErrorForbidden"
          },
          "404": {
            "$ref": "#/components/responses/ApiErrorNotFound"
          },
          "429": {
            "$ref": "#/components/responses/ApiErrorRateLimit"
          },
          "500": {
            "$ref": "#/components/responses/ApiErrorServer"
          }
        },
        "security": [
          {
            "bearer": []
          },
          {
            "api-key": []
          }
        ],
        "summary": "Obtiene la tarea por ID",
        "tags": [
          "Tasks"
        ],
        "x-scope": "tasks:read"
      },
      "put": {
        "description": "Devuelve la tarea actualizada. Si el cuerpo solo trae `context_content` o `deliverables_content`, la respuesta viene con los bloques ya hidratados y con `steps` y `triggers`, igual que el detalle de la tarea.",
        "externalDocs": {
          "description": "Guía: Tareas",
          "url": "https://developers.meteor.com.co/guias/tareas.html"
        },
        "operationId": "TasksController_update",
        "parameters": [
          {
            "description": "ID de la tarea.",
            "in": "path",
            "name": "taskId",
            "required": true,
            "schema": {
              "type": "string"
            }
          }
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/UpdateTaskDto"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "allOf": [
                    {
                      "$ref": "#/components/schemas/ApiEnvelope"
                    },
                    {
                      "properties": {
                        "data": {
                          "$ref": "#/components/schemas/TaskResponseDto"
                        }
                      },
                      "required": [
                        "data"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": ""
          },
          "400": {
            "$ref": "#/components/responses/ApiErrorInvalidRequest"
          },
          "401": {
            "$ref": "#/components/responses/ApiErrorAuth"
          },
          "403": {
            "$ref": "#/components/responses/ApiErrorForbidden"
          },
          "404": {
            "$ref": "#/components/responses/ApiErrorNotFound"
          },
          "409": {
            "$ref": "#/components/responses/ApiErrorConflict"
          },
          "429": {
            "$ref": "#/components/responses/ApiErrorRateLimit"
          },
          "500": {
            "$ref": "#/components/responses/ApiErrorServer"
          }
        },
        "security": [
          {
            "bearer": []
          },
          {
            "api-key": []
          }
        ],
        "summary": "Actualiza la tarea (incl. context_content / deliverables_content)",
        "tags": [
          "Tasks"
        ],
        "x-scope": "tasks:write"
      }
    },
    "/tasks/{taskId}/activity": {
      "get": {
        "description": "Las 100 entradas más recientes, de la más nueva a la más vieja.",
        "externalDocs": {
          "description": "Guía: Tareas",
          "url": "https://developers.meteor.com.co/guias/tareas.html"
        },
        "operationId": "TasksController_getTaskActivity",
        "parameters": [
          {
            "description": "ID de la tarea.",
            "in": "path",
            "name": "taskId",
            "required": true,
            "schema": {
              "type": "string"
            }
          }
        ],
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "allOf": [
                    {
                      "$ref": "#/components/schemas/ApiEnvelope"
                    },
                    {
                      "properties": {
                        "data": {
                          "items": {
                            "$ref": "#/components/schemas/TaskActivityResponseDto"
                          },
                          "type": "array"
                        }
                      },
                      "required": [
                        "data"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": ""
          },
          "400": {
            "$ref": "#/components/responses/ApiErrorInvalidRequest"
          },
          "401": {
            "$ref": "#/components/responses/ApiErrorAuth"
          },
          "403": {
            "$ref": "#/components/responses/ApiErrorForbidden"
          },
          "404": {
            "$ref": "#/components/responses/ApiErrorNotFound"
          },
          "429": {
            "$ref": "#/components/responses/ApiErrorRateLimit"
          },
          "500": {
            "$ref": "#/components/responses/ApiErrorServer"
          }
        },
        "security": [
          {
            "bearer": []
          },
          {
            "api-key": []
          }
        ],
        "summary": "Obtiene el registro de actividad de la tarea",
        "tags": [
          "Tasks"
        ],
        "x-scope": "tasks:read"
      }
    },
    "/tasks/{taskId}/comments": {
      "get": {
        "description": "El autor viene resuelto (nombre, avatar) y las URL de los adjuntos se firman en cada lectura: son temporales, no las guardes.",
        "externalDocs": {
          "description": "Guía: Tareas",
          "url": "https://developers.meteor.com.co/guias/tareas.html"
        },
        "operationId": "TaskCommentsController_list",
        "parameters": [
          {
            "description": "ID de la tarea.",
            "in": "path",
            "name": "taskId",
            "required": true,
            "schema": {
              "type": "string"
            }
          }
        ],
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "allOf": [
                    {
                      "$ref": "#/components/schemas/ApiEnvelope"
                    },
                    {
                      "properties": {
                        "data": {
                          "items": {
                            "$ref": "#/components/schemas/TaskCommentResponseDto"
                          },
                          "type": "array"
                        }
                      },
                      "required": [
                        "data"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": ""
          },
          "400": {
            "$ref": "#/components/responses/ApiErrorInvalidRequest"
          },
          "401": {
            "$ref": "#/components/responses/ApiErrorAuth"
          },
          "403": {
            "$ref": "#/components/responses/ApiErrorForbidden"
          },
          "404": {
            "$ref": "#/components/responses/ApiErrorNotFound"
          },
          "429": {
            "$ref": "#/components/responses/ApiErrorRateLimit"
          },
          "500": {
            "$ref": "#/components/responses/ApiErrorServer"
          }
        },
        "security": [
          {
            "bearer": []
          },
          {
            "api-key": []
          }
        ],
        "summary": "Lista comentarios de la tarea (más antiguo primero).",
        "tags": [
          "Tasks"
        ],
        "x-scope": "tasks:read"
      },
      "post": {
        "description": "Necesita `body` o `attachments`; vacío responde 400. La respuesta trae el autor sin resolver (`author_type` + el id que corresponda), a diferencia del listado.",
        "externalDocs": {
          "description": "Guía: Tareas",
          "url": "https://developers.meteor.com.co/guias/tareas.html"
        },
        "operationId": "TaskCommentsController_create",
        "parameters": [
          {
            "description": "ID de la tarea.",
            "in": "path",
            "name": "taskId",
            "required": true,
            "schema": {
              "type": "string"
            }
          }
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/CreateTaskCommentDto"
              }
            }
          },
          "required": true
        },
        "responses": {
          "201": {
            "content": {
              "application/json": {
                "schema": {
                  "allOf": [
                    {
                      "$ref": "#/components/schemas/ApiEnvelope"
                    },
                    {
                      "properties": {
                        "data": {
                          "$ref": "#/components/schemas/TaskCommentCreatedResponseDto"
                        }
                      },
                      "required": [
                        "data"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": ""
          },
          "400": {
            "$ref": "#/components/responses/ApiErrorInvalidRequest"
          },
          "401": {
            "$ref": "#/components/responses/ApiErrorAuth"
          },
          "403": {
            "$ref": "#/components/responses/ApiErrorForbidden"
          },
          "404": {
            "$ref": "#/components/responses/ApiErrorNotFound"
          },
          "409": {
            "$ref": "#/components/responses/ApiErrorConflict"
          },
          "429": {
            "$ref": "#/components/responses/ApiErrorRateLimit"
          },
          "500": {
            "$ref": "#/components/responses/ApiErrorServer"
          }
        },
        "security": [
          {
            "bearer": []
          },
          {
            "api-key": []
          }
        ],
        "summary": "Crear un comentario (autor = user del JWT).",
        "tags": [
          "Tasks"
        ],
        "x-scope": "tasks:write"
      }
    },
    "/tasks/{taskId}/comments/upload": {
      "post": {
        "externalDocs": {
          "description": "Guía: Tareas",
          "url": "https://developers.meteor.com.co/guias/tareas.html"
        },
        "operationId": "TaskCommentsController_upload",
        "parameters": [
          {
            "description": "ID de la tarea.",
            "in": "path",
            "name": "taskId",
            "required": true,
            "schema": {
              "type": "string"
            }
          }
        ],
        "responses": {
          "201": {
            "content": {
              "application/json": {
                "schema": {
                  "allOf": [
                    {
                      "$ref": "#/components/schemas/ApiEnvelope"
                    },
                    {
                      "properties": {
                        "data": {
                          "$ref": "#/components/schemas/FileAttachmentDto"
                        }
                      },
                      "required": [
                        "data"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": ""
          },
          "400": {
            "$ref": "#/components/responses/ApiErrorInvalidRequest"
          },
          "401": {
            "$ref": "#/components/responses/ApiErrorAuth"
          },
          "403": {
            "$ref": "#/components/responses/ApiErrorForbidden"
          },
          "404": {
            "$ref": "#/components/responses/ApiErrorNotFound"
          },
          "409": {
            "$ref": "#/components/responses/ApiErrorConflict"
          },
          "429": {
            "$ref": "#/components/responses/ApiErrorRateLimit"
          },
          "500": {
            "$ref": "#/components/responses/ApiErrorServer"
          }
        },
        "security": [
          {
            "bearer": []
          },
          {
            "api-key": []
          }
        ],
        "summary": "Sube un archivo y devuelve metadata para incluir en attachments.",
        "tags": [
          "Tasks"
        ],
        "x-scope": "tasks:write"
      }
    },
    "/tasks/{taskId}/comments/{commentId}": {
      "delete": {
        "description": "Solo quien lo escribió puede borrarlo; los comentarios de un Met o del sistema no se borran (403).",
        "externalDocs": {
          "description": "Guía: Tareas",
          "url": "https://developers.meteor.com.co/guias/tareas.html"
        },
        "operationId": "TaskCommentsController_remove",
        "parameters": [
          {
            "description": "ID de la tarea.",
            "in": "path",
            "name": "taskId",
            "required": true,
            "schema": {
              "type": "string"
            }
          },
          {
            "description": "ID del comentario.",
            "in": "path",
            "name": "commentId",
            "required": true,
            "schema": {
              "type": "number"
            }
          }
        ],
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "allOf": [
                    {
                      "$ref": "#/components/schemas/ApiEnvelope"
                    },
                    {
                      "properties": {
                        "data": {
                          "$ref": "#/components/schemas/TaskMessageResponseDto"
                        }
                      },
                      "required": [
                        "data"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": ""
          },
          "400": {
            "$ref": "#/components/responses/ApiErrorInvalidRequest"
          },
          "401": {
            "$ref": "#/components/responses/ApiErrorAuth"
          },
          "403": {
            "$ref": "#/components/responses/ApiErrorForbidden"
          },
          "404": {
            "$ref": "#/components/responses/ApiErrorNotFound"
          },
          "409": {
            "$ref": "#/components/responses/ApiErrorConflict"
          },
          "429": {
            "$ref": "#/components/responses/ApiErrorRateLimit"
          },
          "500": {
            "$ref": "#/components/responses/ApiErrorServer"
          }
        },
        "security": [
          {
            "bearer": []
          },
          {
            "api-key": []
          }
        ],
        "summary": "Eliminar comentario (solo el autor humano).",
        "tags": [
          "Tasks"
        ],
        "x-scope": "tasks:write"
      }
    },
    "/tasks/{taskId}/execute": {
      "post": {
        "externalDocs": {
          "description": "Guía: Tareas",
          "url": "https://developers.meteor.com.co/guias/tareas.html"
        },
        "operationId": "TasksController_execute",
        "parameters": [
          {
            "description": "ID de la tarea.",
            "in": "path",
            "name": "taskId",
            "required": true,
            "schema": {
              "type": "string"
            }
          }
        ],
        "responses": {
          "201": {
            "content": {
              "application/json": {
                "schema": {
                  "allOf": [
                    {
                      "$ref": "#/components/schemas/ApiEnvelope"
                    },
                    {
                      "properties": {
                        "data": {
                          "$ref": "#/components/schemas/TaskExecutionResponseDto"
                        }
                      },
                      "required": [
                        "data"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": ""
          },
          "400": {
            "$ref": "#/components/responses/ApiErrorInvalidRequest"
          },
          "401": {
            "$ref": "#/components/responses/ApiErrorAuth"
          },
          "403": {
            "$ref": "#/components/responses/ApiErrorForbidden"
          },
          "404": {
            "$ref": "#/components/responses/ApiErrorNotFound"
          },
          "409": {
            "$ref": "#/components/responses/ApiErrorConflict"
          },
          "429": {
            "$ref": "#/components/responses/ApiErrorRateLimit"
          },
          "500": {
            "$ref": "#/components/responses/ApiErrorServer"
          }
        },
        "security": [
          {
            "bearer": []
          },
          {
            "api-key": []
          }
        ],
        "summary": "Ejecuta la tarea",
        "tags": [
          "Tasks"
        ],
        "x-scope": "tasks:write"
      }
    },
    "/tasks/{taskId}/executions": {
      "get": {
        "externalDocs": {
          "description": "Guía: Tareas",
          "url": "https://developers.meteor.com.co/guias/tareas.html"
        },
        "operationId": "TasksController_getExecutions",
        "parameters": [
          {
            "description": "ID de la tarea.",
            "in": "path",
            "name": "taskId",
            "required": true,
            "schema": {
              "type": "string"
            }
          }
        ],
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "allOf": [
                    {
                      "$ref": "#/components/schemas/ApiEnvelope"
                    },
                    {
                      "properties": {
                        "data": {
                          "items": {
                            "$ref": "#/components/schemas/TaskExecutionResponseDto"
                          },
                          "type": "array"
                        }
                      },
                      "required": [
                        "data"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": ""
          },
          "400": {
            "$ref": "#/components/responses/ApiErrorInvalidRequest"
          },
          "401": {
            "$ref": "#/components/responses/ApiErrorAuth"
          },
          "403": {
            "$ref": "#/components/responses/ApiErrorForbidden"
          },
          "404": {
            "$ref": "#/components/responses/ApiErrorNotFound"
          },
          "429": {
            "$ref": "#/components/responses/ApiErrorRateLimit"
          },
          "500": {
            "$ref": "#/components/responses/ApiErrorServer"
          }
        },
        "security": [
          {
            "bearer": []
          },
          {
            "api-key": []
          }
        ],
        "summary": "Lista las ejecuciones de la tarea",
        "tags": [
          "Tasks"
        ],
        "x-scope": "tasks:read"
      }
    },
    "/tasks/{taskId}/linked-items": {
      "get": {
        "description": "Items cuyo content (JSONB) contiene un bloque { type: task, data: { task_id: <id> } }. Devuelve la lista hidratada con nombre/colección para que la sidebar de TaskDetail muestre dónde está embebida la tarea.",
        "externalDocs": {
          "description": "Guía: Tareas",
          "url": "https://developers.meteor.com.co/guias/tareas.html"
        },
        "operationId": "TasksController_getLinkedItems",
        "parameters": [
          {
            "description": "ID de la tarea.",
            "in": "path",
            "name": "taskId",
            "required": true,
            "schema": {
              "type": "string"
            }
          }
        ],
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "allOf": [
                    {
                      "$ref": "#/components/schemas/ApiEnvelope"
                    },
                    {
                      "properties": {
                        "data": {
                          "items": {
                            "$ref": "#/components/schemas/TaskLinkedItemResponseDto"
                          },
                          "type": "array"
                        }
                      },
                      "required": [
                        "data"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": ""
          },
          "400": {
            "$ref": "#/components/responses/ApiErrorInvalidRequest"
          },
          "401": {
            "$ref": "#/components/responses/ApiErrorAuth"
          },
          "403": {
            "$ref": "#/components/responses/ApiErrorForbidden"
          },
          "404": {
            "$ref": "#/components/responses/ApiErrorNotFound"
          },
          "429": {
            "$ref": "#/components/responses/ApiErrorRateLimit"
          },
          "500": {
            "$ref": "#/components/responses/ApiErrorServer"
          }
        },
        "security": [
          {
            "bearer": []
          },
          {
            "api-key": []
          }
        ],
        "summary": "Items que tienen un bloque task referenciando esta tarea",
        "tags": [
          "Tasks"
        ],
        "x-scope": "tasks:read"
      }
    },
    "/tasks/{taskId}/status": {
      "put": {
        "description": "Los estados válidos los define el tablero del workspace, no la API.",
        "externalDocs": {
          "description": "Guía: Tareas",
          "url": "https://developers.meteor.com.co/guias/tareas.html"
        },
        "operationId": "TasksController_updateStatus",
        "parameters": [
          {
            "description": "ID de la tarea.",
            "in": "path",
            "name": "taskId",
            "required": true,
            "schema": {
              "type": "string"
            }
          }
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/UpdateTaskStatusDto"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "allOf": [
                    {
                      "$ref": "#/components/schemas/ApiEnvelope"
                    },
                    {
                      "properties": {
                        "data": {
                          "$ref": "#/components/schemas/TaskResponseDto"
                        }
                      },
                      "required": [
                        "data"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": ""
          },
          "400": {
            "$ref": "#/components/responses/ApiErrorInvalidRequest"
          },
          "401": {
            "$ref": "#/components/responses/ApiErrorAuth"
          },
          "403": {
            "$ref": "#/components/responses/ApiErrorForbidden"
          },
          "404": {
            "$ref": "#/components/responses/ApiErrorNotFound"
          },
          "409": {
            "$ref": "#/components/responses/ApiErrorConflict"
          },
          "429": {
            "$ref": "#/components/responses/ApiErrorRateLimit"
          },
          "500": {
            "$ref": "#/components/responses/ApiErrorServer"
          }
        },
        "security": [
          {
            "bearer": []
          },
          {
            "api-key": []
          }
        ],
        "summary": "Actualiza el estado de la tarea",
        "tags": [
          "Tasks"
        ],
        "x-scope": "tasks:write"
      }
    },
    "/tasks/{taskId}/steps": {
      "post": {
        "description": "Queda al final del checklist: `step_order` se asigna solo.",
        "externalDocs": {
          "description": "Guía: Tareas",
          "url": "https://developers.meteor.com.co/guias/tareas.html"
        },
        "operationId": "TaskStepsController_create",
        "parameters": [
          {
            "description": "ID de la tarea.",
            "in": "path",
            "name": "taskId",
            "required": true,
            "schema": {
              "type": "string"
            }
          }
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/CreateStepDto"
              }
            }
          },
          "required": true
        },
        "responses": {
          "201": {
            "content": {
              "application/json": {
                "schema": {
                  "allOf": [
                    {
                      "$ref": "#/components/schemas/ApiEnvelope"
                    },
                    {
                      "properties": {
                        "data": {
                          "$ref": "#/components/schemas/TaskStepResponseDto"
                        }
                      },
                      "required": [
                        "data"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": ""
          },
          "400": {
            "$ref": "#/components/responses/ApiErrorInvalidRequest"
          },
          "401": {
            "$ref": "#/components/responses/ApiErrorAuth"
          },
          "403": {
            "$ref": "#/components/responses/ApiErrorForbidden"
          },
          "404": {
            "$ref": "#/components/responses/ApiErrorNotFound"
          },
          "409": {
            "$ref": "#/components/responses/ApiErrorConflict"
          },
          "429": {
            "$ref": "#/components/responses/ApiErrorRateLimit"
          },
          "500": {
            "$ref": "#/components/responses/ApiErrorServer"
          }
        },
        "security": [
          {
            "bearer": []
          },
          {
            "api-key": []
          }
        ],
        "summary": "Crea un paso",
        "tags": [
          "Tasks"
        ],
        "x-scope": "tasks:write"
      }
    },
    "/tasks/{taskId}/steps/reorder": {
      "post": {
        "description": "`order` es la lista de ids de pasos en el orden nuevo; la posición en el arreglo pasa a ser el `step_order` (1-based). No devuelve los pasos: volvé a pedir la tarea.",
        "externalDocs": {
          "description": "Guía: Tareas",
          "url": "https://developers.meteor.com.co/guias/tareas.html"
        },
        "operationId": "TaskStepsController_reorder",
        "parameters": [
          {
            "description": "ID de la tarea.",
            "in": "path",
            "name": "taskId",
            "required": true,
            "schema": {
              "type": "string"
            }
          }
        ],
        "responses": {
          "201": {
            "content": {
              "application/json": {
                "schema": {
                  "allOf": [
                    {
                      "$ref": "#/components/schemas/ApiEnvelope"
                    },
                    {
                      "properties": {
                        "data": {
                          "$ref": "#/components/schemas/TaskMessageResponseDto"
                        }
                      },
                      "required": [
                        "data"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": ""
          },
          "400": {
            "$ref": "#/components/responses/ApiErrorInvalidRequest"
          },
          "401": {
            "$ref": "#/components/responses/ApiErrorAuth"
          },
          "403": {
            "$ref": "#/components/responses/ApiErrorForbidden"
          },
          "404": {
            "$ref": "#/components/responses/ApiErrorNotFound"
          },
          "409": {
            "$ref": "#/components/responses/ApiErrorConflict"
          },
          "429": {
            "$ref": "#/components/responses/ApiErrorRateLimit"
          },
          "500": {
            "$ref": "#/components/responses/ApiErrorServer"
          }
        },
        "security": [
          {
            "bearer": []
          },
          {
            "api-key": []
          }
        ],
        "summary": "Reordena los pasos",
        "tags": [
          "Tasks"
        ],
        "x-scope": "tasks:write"
      }
    },
    "/tasks/{taskId}/steps/{stepId}": {
      "delete": {
        "description": "No renumera los pasos que quedan; para eso está `POST /steps/reorder`.",
        "externalDocs": {
          "description": "Guía: Tareas",
          "url": "https://developers.meteor.com.co/guias/tareas.html"
        },
        "operationId": "TaskStepsController_remove",
        "parameters": [
          {
            "description": "ID de la tarea.",
            "in": "path",
            "name": "taskId",
            "required": true,
            "schema": {
              "type": "string"
            }
          },
          {
            "description": "ID del paso dentro de la tarea.",
            "in": "path",
            "name": "stepId",
            "required": true,
            "schema": {
              "type": "string"
            }
          }
        ],
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "allOf": [
                    {
                      "$ref": "#/components/schemas/ApiEnvelope"
                    },
                    {
                      "properties": {
                        "data": {
                          "$ref": "#/components/schemas/TaskMessageResponseDto"
                        }
                      },
                      "required": [
                        "data"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": ""
          },
          "400": {
            "$ref": "#/components/responses/ApiErrorInvalidRequest"
          },
          "401": {
            "$ref": "#/components/responses/ApiErrorAuth"
          },
          "403": {
            "$ref": "#/components/responses/ApiErrorForbidden"
          },
          "404": {
            "$ref": "#/components/responses/ApiErrorNotFound"
          },
          "409": {
            "$ref": "#/components/responses/ApiErrorConflict"
          },
          "429": {
            "$ref": "#/components/responses/ApiErrorRateLimit"
          },
          "500": {
            "$ref": "#/components/responses/ApiErrorServer"
          }
        },
        "security": [
          {
            "bearer": []
          },
          {
            "api-key": []
          }
        ],
        "summary": "Elimina un paso",
        "tags": [
          "Tasks"
        ],
        "x-scope": "tasks:write"
      },
      "put": {
        "description": "Si el cuerpo trae `result_content`, la respuesta lo devuelve hidratado (las referencias con su `__hydrated` resuelto); si no, tal como está guardado.",
        "externalDocs": {
          "description": "Guía: Tareas",
          "url": "https://developers.meteor.com.co/guias/tareas.html"
        },
        "operationId": "TaskStepsController_update",
        "parameters": [
          {
            "description": "ID de la tarea.",
            "in": "path",
            "name": "taskId",
            "required": true,
            "schema": {
              "type": "string"
            }
          },
          {
            "description": "ID del paso dentro de la tarea.",
            "in": "path",
            "name": "stepId",
            "required": true,
            "schema": {
              "type": "string"
            }
          }
        ],
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "allOf": [
                    {
                      "$ref": "#/components/schemas/ApiEnvelope"
                    },
                    {
                      "properties": {
                        "data": {
                          "$ref": "#/components/schemas/TaskStepResponseDto"
                        }
                      },
                      "required": [
                        "data"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": ""
          },
          "400": {
            "$ref": "#/components/responses/ApiErrorInvalidRequest"
          },
          "401": {
            "$ref": "#/components/responses/ApiErrorAuth"
          },
          "403": {
            "$ref": "#/components/responses/ApiErrorForbidden"
          },
          "404": {
            "$ref": "#/components/responses/ApiErrorNotFound"
          },
          "409": {
            "$ref": "#/components/responses/ApiErrorConflict"
          },
          "429": {
            "$ref": "#/components/responses/ApiErrorRateLimit"
          },
          "500": {
            "$ref": "#/components/responses/ApiErrorServer"
          }
        },
        "security": [
          {
            "bearer": []
          },
          {
            "api-key": []
          }
        ],
        "summary": "Actualiza un paso (incl. result_content)",
        "tags": [
          "Tasks"
        ],
        "x-scope": "tasks:write"
      }
    },
    "/tasks/{taskId}/steps/{stepId}/result": {
      "put": {
        "description": "Reemplaza, no agrega: el arreglo que mandes queda como el resultado completo del paso. Devuelve los bloques ya hidratados, no el paso entero.",
        "externalDocs": {
          "description": "Guía: Tareas",
          "url": "https://developers.meteor.com.co/guias/tareas.html"
        },
        "operationId": "TaskStepsController_updateResult",
        "parameters": [
          {
            "description": "ID de la tarea.",
            "in": "path",
            "name": "taskId",
            "required": true,
            "schema": {
              "type": "string"
            }
          },
          {
            "description": "ID del paso dentro de la tarea.",
            "in": "path",
            "name": "stepId",
            "required": true,
            "schema": {
              "type": "string"
            }
          }
        ],
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "allOf": [
                    {
                      "$ref": "#/components/schemas/ApiEnvelope"
                    },
                    {
                      "properties": {
                        "data": {
                          "items": {
                            "$ref": "#/components/schemas/TaskStepResultBlockDto"
                          },
                          "type": "array"
                        }
                      },
                      "required": [
                        "data"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": ""
          },
          "400": {
            "$ref": "#/components/responses/ApiErrorInvalidRequest"
          },
          "401": {
            "$ref": "#/components/responses/ApiErrorAuth"
          },
          "403": {
            "$ref": "#/components/responses/ApiErrorForbidden"
          },
          "404": {
            "$ref": "#/components/responses/ApiErrorNotFound"
          },
          "409": {
            "$ref": "#/components/responses/ApiErrorConflict"
          },
          "429": {
            "$ref": "#/components/responses/ApiErrorRateLimit"
          },
          "500": {
            "$ref": "#/components/responses/ApiErrorServer"
          }
        },
        "security": [
          {
            "bearer": []
          },
          {
            "api-key": []
          }
        ],
        "summary": "Reemplaza el result_content del paso (bloques)",
        "tags": [
          "Tasks"
        ],
        "x-scope": "tasks:write"
      }
    },
    "/tasks/{taskId}/trigger": {
      "put": {
        "description": "El principal es el disparador más viejo de la tarea. Si la tarea no tiene ninguno, lo crea con lo que mandes en vez de responder 404.",
        "externalDocs": {
          "description": "Guía: Tareas",
          "url": "https://developers.meteor.com.co/guias/tareas.html"
        },
        "operationId": "TaskTriggersController_updatePrimary",
        "parameters": [
          {
            "description": "ID de la tarea.",
            "in": "path",
            "name": "taskId",
            "required": true,
            "schema": {
              "type": "string"
            }
          }
        ],
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "allOf": [
                    {
                      "$ref": "#/components/schemas/ApiEnvelope"
                    },
                    {
                      "properties": {
                        "data": {
                          "$ref": "#/components/schemas/TaskTriggerResponseDto"
                        }
                      },
                      "required": [
                        "data"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": ""
          },
          "400": {
            "$ref": "#/components/responses/ApiErrorInvalidRequest"
          },
          "401": {
            "$ref": "#/components/responses/ApiErrorAuth"
          },
          "403": {
            "$ref": "#/components/responses/ApiErrorForbidden"
          },
          "404": {
            "$ref": "#/components/responses/ApiErrorNotFound"
          },
          "409": {
            "$ref": "#/components/responses/ApiErrorConflict"
          },
          "429": {
            "$ref": "#/components/responses/ApiErrorRateLimit"
          },
          "500": {
            "$ref": "#/components/responses/ApiErrorServer"
          }
        },
        "security": [
          {
            "bearer": []
          },
          {
            "api-key": []
          }
        ],
        "summary": "Actualiza el disparador principal",
        "tags": [
          "Tasks"
        ],
        "x-scope": "tasks:write"
      }
    },
    "/tasks/{taskId}/triggers": {
      "get": {
        "description": "Del más viejo al más nuevo; el primero es el que trata como principal `PUT /trigger`.",
        "externalDocs": {
          "description": "Guía: Tareas",
          "url": "https://developers.meteor.com.co/guias/tareas.html"
        },
        "operationId": "TaskTriggersController_findByTask",
        "parameters": [
          {
            "description": "ID de la tarea.",
            "in": "path",
            "name": "taskId",
            "required": true,
            "schema": {
              "type": "string"
            }
          }
        ],
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "allOf": [
                    {
                      "$ref": "#/components/schemas/ApiEnvelope"
                    },
                    {
                      "properties": {
                        "data": {
                          "items": {
                            "$ref": "#/components/schemas/TaskTriggerResponseDto"
                          },
                          "type": "array"
                        }
                      },
                      "required": [
                        "data"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": ""
          },
          "400": {
            "$ref": "#/components/responses/ApiErrorInvalidRequest"
          },
          "401": {
            "$ref": "#/components/responses/ApiErrorAuth"
          },
          "403": {
            "$ref": "#/components/responses/ApiErrorForbidden"
          },
          "404": {
            "$ref": "#/components/responses/ApiErrorNotFound"
          },
          "429": {
            "$ref": "#/components/responses/ApiErrorRateLimit"
          },
          "500": {
            "$ref": "#/components/responses/ApiErrorServer"
          }
        },
        "security": [
          {
            "bearer": []
          },
          {
            "api-key": []
          }
        ],
        "summary": "Lista los disparadores de la tarea",
        "tags": [
          "Tasks"
        ],
        "x-scope": "tasks:read"
      },
      "post": {
        "description": "Nace habilitado (`enabled: true`).",
        "externalDocs": {
          "description": "Guía: Tareas",
          "url": "https://developers.meteor.com.co/guias/tareas.html"
        },
        "operationId": "TaskTriggersController_create",
        "parameters": [
          {
            "description": "ID de la tarea.",
            "in": "path",
            "name": "taskId",
            "required": true,
            "schema": {
              "type": "string"
            }
          }
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/CreateTriggerDto"
              }
            }
          },
          "required": true
        },
        "responses": {
          "201": {
            "content": {
              "application/json": {
                "schema": {
                  "allOf": [
                    {
                      "$ref": "#/components/schemas/ApiEnvelope"
                    },
                    {
                      "properties": {
                        "data": {
                          "$ref": "#/components/schemas/TaskTriggerResponseDto"
                        }
                      },
                      "required": [
                        "data"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": ""
          },
          "400": {
            "$ref": "#/components/responses/ApiErrorInvalidRequest"
          },
          "401": {
            "$ref": "#/components/responses/ApiErrorAuth"
          },
          "403": {
            "$ref": "#/components/responses/ApiErrorForbidden"
          },
          "404": {
            "$ref": "#/components/responses/ApiErrorNotFound"
          },
          "409": {
            "$ref": "#/components/responses/ApiErrorConflict"
          },
          "429": {
            "$ref": "#/components/responses/ApiErrorRateLimit"
          },
          "500": {
            "$ref": "#/components/responses/ApiErrorServer"
          }
        },
        "security": [
          {
            "bearer": []
          },
          {
            "api-key": []
          }
        ],
        "summary": "Crea un disparador",
        "tags": [
          "Tasks"
        ],
        "x-scope": "tasks:write"
      }
    },
    "/tasks/{taskId}/triggers/{triggerId}": {
      "delete": {
        "description": "Borra el disparador, no la tarea: la tarea queda sin esa forma de dispararse.",
        "externalDocs": {
          "description": "Guía: Tareas",
          "url": "https://developers.meteor.com.co/guias/tareas.html"
        },
        "operationId": "TaskTriggersController_remove",
        "parameters": [
          {
            "description": "ID del disparador de la tarea.",
            "in": "path",
            "name": "triggerId",
            "required": true,
            "schema": {
              "type": "string"
            }
          }
        ],
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "allOf": [
                    {
                      "$ref": "#/components/schemas/ApiEnvelope"
                    },
                    {
                      "properties": {
                        "data": {
                          "$ref": "#/components/schemas/TaskMessageResponseDto"
                        }
                      },
                      "required": [
                        "data"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": ""
          },
          "400": {
            "$ref": "#/components/responses/ApiErrorInvalidRequest"
          },
          "401": {
            "$ref": "#/components/responses/ApiErrorAuth"
          },
          "403": {
            "$ref": "#/components/responses/ApiErrorForbidden"
          },
          "404": {
            "$ref": "#/components/responses/ApiErrorNotFound"
          },
          "409": {
            "$ref": "#/components/responses/ApiErrorConflict"
          },
          "429": {
            "$ref": "#/components/responses/ApiErrorRateLimit"
          },
          "500": {
            "$ref": "#/components/responses/ApiErrorServer"
          }
        },
        "security": [
          {
            "bearer": []
          },
          {
            "api-key": []
          }
        ],
        "summary": "Elimina un disparador",
        "tags": [
          "Tasks"
        ],
        "x-scope": "tasks:write"
      },
      "put": {
        "externalDocs": {
          "description": "Guía: Tareas",
          "url": "https://developers.meteor.com.co/guias/tareas.html"
        },
        "operationId": "TaskTriggersController_update",
        "parameters": [
          {
            "description": "ID del disparador de la tarea.",
            "in": "path",
            "name": "triggerId",
            "required": true,
            "schema": {
              "type": "string"
            }
          }
        ],
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "allOf": [
                    {
                      "$ref": "#/components/schemas/ApiEnvelope"
                    },
                    {
                      "properties": {
                        "data": {
                          "$ref": "#/components/schemas/TaskTriggerResponseDto"
                        }
                      },
                      "required": [
                        "data"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": ""
          },
          "400": {
            "$ref": "#/components/responses/ApiErrorInvalidRequest"
          },
          "401": {
            "$ref": "#/components/responses/ApiErrorAuth"
          },
          "403": {
            "$ref": "#/components/responses/ApiErrorForbidden"
          },
          "404": {
            "$ref": "#/components/responses/ApiErrorNotFound"
          },
          "409": {
            "$ref": "#/components/responses/ApiErrorConflict"
          },
          "429": {
            "$ref": "#/components/responses/ApiErrorRateLimit"
          },
          "500": {
            "$ref": "#/components/responses/ApiErrorServer"
          }
        },
        "security": [
          {
            "bearer": []
          },
          {
            "api-key": []
          }
        ],
        "summary": "Actualiza un disparador específico",
        "tags": [
          "Tasks"
        ],
        "x-scope": "tasks:write"
      }
    },
    "/trigger-catalog": {
      "get": {
        "externalDocs": {
          "description": "Guía: Funciones y flujos",
          "url": "https://developers.meteor.com.co/guias/funciones-y-flujos.html"
        },
        "operationId": "AutomationsController_catalog",
        "parameters": [],
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "allOf": [
                    {
                      "$ref": "#/components/schemas/ApiEnvelope"
                    },
                    {
                      "properties": {
                        "data": {
                          "items": {
                            "$ref": "#/components/schemas/TriggerCatalogEntryDto"
                          },
                          "type": "array"
                        }
                      },
                      "required": [
                        "data"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": ""
          },
          "400": {
            "$ref": "#/components/responses/ApiErrorInvalidRequest"
          },
          "401": {
            "$ref": "#/components/responses/ApiErrorAuth"
          },
          "403": {
            "$ref": "#/components/responses/ApiErrorForbidden"
          },
          "404": {
            "$ref": "#/components/responses/ApiErrorNotFound"
          },
          "429": {
            "$ref": "#/components/responses/ApiErrorRateLimit"
          },
          "500": {
            "$ref": "#/components/responses/ApiErrorServer"
          }
        },
        "security": [
          {
            "bearer": []
          },
          {
            "api-key": []
          }
        ],
        "summary": "Lista el catálogo de disparadores enriquecido",
        "tags": [
          "Automations"
        ],
        "x-scope": "automations:read"
      }
    },
    "/variables": {
      "get": {
        "externalDocs": {
          "description": "Guía: Variables del workspace",
          "url": "https://developers.meteor.com.co/guias/variables.html"
        },
        "operationId": "VariablesController_findAll",
        "parameters": [],
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "allOf": [
                    {
                      "$ref": "#/components/schemas/ApiEnvelope"
                    },
                    {
                      "properties": {
                        "data": {
                          "items": {
                            "$ref": "#/components/schemas/WorkspaceVariableDto"
                          },
                          "type": "array"
                        }
                      },
                      "required": [
                        "data"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": ""
          },
          "400": {
            "$ref": "#/components/responses/ApiErrorInvalidRequest"
          },
          "401": {
            "$ref": "#/components/responses/ApiErrorAuth"
          },
          "403": {
            "$ref": "#/components/responses/ApiErrorForbidden"
          },
          "404": {
            "$ref": "#/components/responses/ApiErrorNotFound"
          },
          "429": {
            "$ref": "#/components/responses/ApiErrorRateLimit"
          },
          "500": {
            "$ref": "#/components/responses/ApiErrorServer"
          }
        },
        "security": [
          {
            "bearer": []
          },
          {
            "api-key": []
          }
        ],
        "summary": "Lista las variables del workspace",
        "tags": [
          "Variables"
        ],
        "x-scope": "variables:read"
      },
      "post": {
        "externalDocs": {
          "description": "Guía: Variables del workspace",
          "url": "https://developers.meteor.com.co/guias/variables.html"
        },
        "operationId": "VariablesController_create",
        "parameters": [],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/CreateVariableDto"
              }
            }
          },
          "required": true
        },
        "responses": {
          "201": {
            "content": {
              "application/json": {
                "schema": {
                  "allOf": [
                    {
                      "$ref": "#/components/schemas/ApiEnvelope"
                    },
                    {
                      "properties": {
                        "data": {
                          "$ref": "#/components/schemas/WorkspaceVariableDto"
                        }
                      },
                      "required": [
                        "data"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": ""
          },
          "400": {
            "$ref": "#/components/responses/ApiErrorInvalidRequest"
          },
          "401": {
            "$ref": "#/components/responses/ApiErrorAuth"
          },
          "403": {
            "$ref": "#/components/responses/ApiErrorForbidden"
          },
          "404": {
            "$ref": "#/components/responses/ApiErrorNotFound"
          },
          "409": {
            "$ref": "#/components/responses/ApiErrorConflict"
          },
          "429": {
            "$ref": "#/components/responses/ApiErrorRateLimit"
          },
          "500": {
            "$ref": "#/components/responses/ApiErrorServer"
          }
        },
        "security": [
          {
            "bearer": []
          },
          {
            "api-key": []
          }
        ],
        "summary": "Crea una variable del workspace",
        "tags": [
          "Variables"
        ],
        "x-scope": "variables:write"
      }
    },
    "/variables/available": {
      "get": {
        "externalDocs": {
          "description": "Guía: Variables del workspace",
          "url": "https://developers.meteor.com.co/guias/variables.html"
        },
        "operationId": "VariablesController_available",
        "parameters": [
          {
            "description": "Filtra por contacto del CRM.",
            "in": "query",
            "name": "contact_id",
            "required": true,
            "schema": {
              "type": "string"
            }
          },
          {
            "description": "Texto a buscar.",
            "in": "query",
            "name": "search",
            "required": true,
            "schema": {
              "type": "string"
            }
          }
        ],
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "allOf": [
                    {
                      "$ref": "#/components/schemas/ApiEnvelope"
                    },
                    {
                      "properties": {
                        "data": {
                          "items": {
                            "$ref": "#/components/schemas/AvailableVariableDto"
                          },
                          "type": "array"
                        }
                      },
                      "required": [
                        "data"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": ""
          },
          "400": {
            "$ref": "#/components/responses/ApiErrorInvalidRequest"
          },
          "401": {
            "$ref": "#/components/responses/ApiErrorAuth"
          },
          "403": {
            "$ref": "#/components/responses/ApiErrorForbidden"
          },
          "404": {
            "$ref": "#/components/responses/ApiErrorNotFound"
          },
          "429": {
            "$ref": "#/components/responses/ApiErrorRateLimit"
          },
          "500": {
            "$ref": "#/components/responses/ApiErrorServer"
          }
        },
        "security": [
          {
            "bearer": []
          },
          {
            "api-key": []
          }
        ],
        "summary": "Lista las variables disponibles para autocompletar",
        "tags": [
          "Variables"
        ],
        "x-scope": "variables:read"
      }
    },
    "/variables/field-definitions": {
      "get": {
        "externalDocs": {
          "description": "Guía: Variables del workspace",
          "url": "https://developers.meteor.com.co/guias/variables.html"
        },
        "operationId": "VariablesController_findFieldDefinitions",
        "parameters": [],
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "allOf": [
                    {
                      "$ref": "#/components/schemas/ApiEnvelope"
                    },
                    {
                      "properties": {
                        "data": {
                          "items": {
                            "$ref": "#/components/schemas/ContactFieldDefinitionDto"
                          },
                          "type": "array"
                        }
                      },
                      "required": [
                        "data"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": ""
          },
          "400": {
            "$ref": "#/components/responses/ApiErrorInvalidRequest"
          },
          "401": {
            "$ref": "#/components/responses/ApiErrorAuth"
          },
          "403": {
            "$ref": "#/components/responses/ApiErrorForbidden"
          },
          "404": {
            "$ref": "#/components/responses/ApiErrorNotFound"
          },
          "429": {
            "$ref": "#/components/responses/ApiErrorRateLimit"
          },
          "500": {
            "$ref": "#/components/responses/ApiErrorServer"
          }
        },
        "security": [
          {
            "bearer": []
          },
          {
            "api-key": []
          }
        ],
        "summary": "Lista las definiciones de campos de contacto",
        "tags": [
          "Variables"
        ],
        "x-scope": "variables:read"
      },
      "post": {
        "externalDocs": {
          "description": "Guía: Variables del workspace",
          "url": "https://developers.meteor.com.co/guias/variables.html"
        },
        "operationId": "VariablesController_createFieldDefinition",
        "parameters": [],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/CreateFieldDefinitionDto"
              }
            }
          },
          "required": true
        },
        "responses": {
          "201": {
            "content": {
              "application/json": {
                "schema": {
                  "allOf": [
                    {
                      "$ref": "#/components/schemas/ApiEnvelope"
                    },
                    {
                      "properties": {
                        "data": {
                          "$ref": "#/components/schemas/ContactFieldDefinitionDto"
                        }
                      },
                      "required": [
                        "data"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": ""
          },
          "400": {
            "$ref": "#/components/responses/ApiErrorInvalidRequest"
          },
          "401": {
            "$ref": "#/components/responses/ApiErrorAuth"
          },
          "403": {
            "$ref": "#/components/responses/ApiErrorForbidden"
          },
          "404": {
            "$ref": "#/components/responses/ApiErrorNotFound"
          },
          "409": {
            "$ref": "#/components/responses/ApiErrorConflict"
          },
          "429": {
            "$ref": "#/components/responses/ApiErrorRateLimit"
          },
          "500": {
            "$ref": "#/components/responses/ApiErrorServer"
          }
        },
        "security": [
          {
            "bearer": []
          },
          {
            "api-key": []
          }
        ],
        "summary": "Crea una definición de campo de contacto",
        "tags": [
          "Variables"
        ],
        "x-scope": "variables:write"
      }
    },
    "/variables/field-definitions/{id}": {
      "delete": {
        "externalDocs": {
          "description": "Guía: Variables del workspace",
          "url": "https://developers.meteor.com.co/guias/variables.html"
        },
        "operationId": "VariablesController_removeFieldDefinition",
        "parameters": [
          {
            "description": "ID del recurso de esta ruta.",
            "in": "path",
            "name": "id",
            "required": true,
            "schema": {
              "type": "number"
            }
          }
        ],
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "allOf": [
                    {
                      "$ref": "#/components/schemas/ApiEnvelope"
                    },
                    {
                      "properties": {
                        "data": {
                          "$ref": "#/components/schemas/FieldDefinitionDeletedResponseDto"
                        }
                      },
                      "required": [
                        "data"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": ""
          },
          "400": {
            "$ref": "#/components/responses/ApiErrorInvalidRequest"
          },
          "401": {
            "$ref": "#/components/responses/ApiErrorAuth"
          },
          "403": {
            "$ref": "#/components/responses/ApiErrorForbidden"
          },
          "404": {
            "$ref": "#/components/responses/ApiErrorNotFound"
          },
          "409": {
            "$ref": "#/components/responses/ApiErrorConflict"
          },
          "429": {
            "$ref": "#/components/responses/ApiErrorRateLimit"
          },
          "500": {
            "$ref": "#/components/responses/ApiErrorServer"
          }
        },
        "security": [
          {
            "bearer": []
          },
          {
            "api-key": []
          }
        ],
        "summary": "Elimina una definición de campo de contacto",
        "tags": [
          "Variables"
        ],
        "x-scope": "variables:write"
      },
      "patch": {
        "externalDocs": {
          "description": "Guía: Variables del workspace",
          "url": "https://developers.meteor.com.co/guias/variables.html"
        },
        "operationId": "VariablesController_updateFieldDefinition",
        "parameters": [
          {
            "description": "ID del recurso de esta ruta.",
            "in": "path",
            "name": "id",
            "required": true,
            "schema": {
              "type": "number"
            }
          }
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/UpdateFieldDefinitionDto"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "allOf": [
                    {
                      "$ref": "#/components/schemas/ApiEnvelope"
                    },
                    {
                      "properties": {
                        "data": {
                          "$ref": "#/components/schemas/ContactFieldDefinitionDto"
                        }
                      },
                      "required": [
                        "data"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": ""
          },
          "400": {
            "$ref": "#/components/responses/ApiErrorInvalidRequest"
          },
          "401": {
            "$ref": "#/components/responses/ApiErrorAuth"
          },
          "403": {
            "$ref": "#/components/responses/ApiErrorForbidden"
          },
          "404": {
            "$ref": "#/components/responses/ApiErrorNotFound"
          },
          "409": {
            "$ref": "#/components/responses/ApiErrorConflict"
          },
          "429": {
            "$ref": "#/components/responses/ApiErrorRateLimit"
          },
          "500": {
            "$ref": "#/components/responses/ApiErrorServer"
          }
        },
        "security": [
          {
            "bearer": []
          },
          {
            "api-key": []
          }
        ],
        "summary": "Actualiza una definición de campo de contacto (label / options)",
        "tags": [
          "Variables"
        ],
        "x-scope": "variables:write"
      }
    },
    "/variables/resolve": {
      "post": {
        "externalDocs": {
          "description": "Guía: Variables del workspace",
          "url": "https://developers.meteor.com.co/guias/variables.html"
        },
        "operationId": "VariablesController_resolve",
        "parameters": [],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/ResolveVariablesDto"
              }
            }
          },
          "required": true
        },
        "responses": {
          "201": {
            "content": {
              "application/json": {
                "schema": {
                  "allOf": [
                    {
                      "$ref": "#/components/schemas/ApiEnvelope"
                    },
                    {
                      "properties": {
                        "data": {
                          "$ref": "#/components/schemas/ResolveVariablesResponseDto"
                        }
                      },
                      "required": [
                        "data"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": ""
          },
          "400": {
            "$ref": "#/components/responses/ApiErrorInvalidRequest"
          },
          "401": {
            "$ref": "#/components/responses/ApiErrorAuth"
          },
          "403": {
            "$ref": "#/components/responses/ApiErrorForbidden"
          },
          "404": {
            "$ref": "#/components/responses/ApiErrorNotFound"
          },
          "409": {
            "$ref": "#/components/responses/ApiErrorConflict"
          },
          "429": {
            "$ref": "#/components/responses/ApiErrorRateLimit"
          },
          "500": {
            "$ref": "#/components/responses/ApiErrorServer"
          }
        },
        "security": [
          {
            "bearer": []
          },
          {
            "api-key": []
          }
        ],
        "summary": "Resuelve los tokens de variable en una plantilla de texto",
        "tags": [
          "Variables"
        ],
        "x-scope": "variables:read"
      }
    },
    "/variables/{id}": {
      "delete": {
        "externalDocs": {
          "description": "Guía: Variables del workspace",
          "url": "https://developers.meteor.com.co/guias/variables.html"
        },
        "operationId": "VariablesController_remove",
        "parameters": [
          {
            "description": "ID del recurso de esta ruta.",
            "in": "path",
            "name": "id",
            "required": true,
            "schema": {
              "type": "number"
            }
          }
        ],
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "allOf": [
                    {
                      "$ref": "#/components/schemas/ApiEnvelope"
                    },
                    {
                      "properties": {
                        "data": {
                          "$ref": "#/components/schemas/VariableDeletedResponseDto"
                        }
                      },
                      "required": [
                        "data"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": ""
          },
          "400": {
            "$ref": "#/components/responses/ApiErrorInvalidRequest"
          },
          "401": {
            "$ref": "#/components/responses/ApiErrorAuth"
          },
          "403": {
            "$ref": "#/components/responses/ApiErrorForbidden"
          },
          "404": {
            "$ref": "#/components/responses/ApiErrorNotFound"
          },
          "409": {
            "$ref": "#/components/responses/ApiErrorConflict"
          },
          "429": {
            "$ref": "#/components/responses/ApiErrorRateLimit"
          },
          "500": {
            "$ref": "#/components/responses/ApiErrorServer"
          }
        },
        "security": [
          {
            "bearer": []
          },
          {
            "api-key": []
          }
        ],
        "summary": "Elimina la variable del workspace",
        "tags": [
          "Variables"
        ],
        "x-scope": "variables:write"
      },
      "get": {
        "externalDocs": {
          "description": "Guía: Variables del workspace",
          "url": "https://developers.meteor.com.co/guias/variables.html"
        },
        "operationId": "VariablesController_findOne",
        "parameters": [
          {
            "description": "ID del recurso de esta ruta.",
            "in": "path",
            "name": "id",
            "required": true,
            "schema": {
              "type": "number"
            }
          }
        ],
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "allOf": [
                    {
                      "$ref": "#/components/schemas/ApiEnvelope"
                    },
                    {
                      "properties": {
                        "data": {
                          "$ref": "#/components/schemas/WorkspaceVariableDto"
                        }
                      },
                      "required": [
                        "data"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": ""
          },
          "400": {
            "$ref": "#/components/responses/ApiErrorInvalidRequest"
          },
          "401": {
            "$ref": "#/components/responses/ApiErrorAuth"
          },
          "403": {
            "$ref": "#/components/responses/ApiErrorForbidden"
          },
          "404": {
            "$ref": "#/components/responses/ApiErrorNotFound"
          },
          "429": {
            "$ref": "#/components/responses/ApiErrorRateLimit"
          },
          "500": {
            "$ref": "#/components/responses/ApiErrorServer"
          }
        },
        "security": [
          {
            "bearer": []
          },
          {
            "api-key": []
          }
        ],
        "summary": "Obtiene la variable del workspace por ID",
        "tags": [
          "Variables"
        ],
        "x-scope": "variables:read"
      },
      "put": {
        "externalDocs": {
          "description": "Guía: Variables del workspace",
          "url": "https://developers.meteor.com.co/guias/variables.html"
        },
        "operationId": "VariablesController_update",
        "parameters": [
          {
            "description": "ID del recurso de esta ruta.",
            "in": "path",
            "name": "id",
            "required": true,
            "schema": {
              "type": "number"
            }
          }
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/UpdateVariableDto"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "allOf": [
                    {
                      "$ref": "#/components/schemas/ApiEnvelope"
                    },
                    {
                      "properties": {
                        "data": {
                          "$ref": "#/components/schemas/WorkspaceVariableDto"
                        }
                      },
                      "required": [
                        "data"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": ""
          },
          "400": {
            "$ref": "#/components/responses/ApiErrorInvalidRequest"
          },
          "401": {
            "$ref": "#/components/responses/ApiErrorAuth"
          },
          "403": {
            "$ref": "#/components/responses/ApiErrorForbidden"
          },
          "404": {
            "$ref": "#/components/responses/ApiErrorNotFound"
          },
          "409": {
            "$ref": "#/components/responses/ApiErrorConflict"
          },
          "429": {
            "$ref": "#/components/responses/ApiErrorRateLimit"
          },
          "500": {
            "$ref": "#/components/responses/ApiErrorServer"
          }
        },
        "security": [
          {
            "bearer": []
          },
          {
            "api-key": []
          }
        ],
        "summary": "Actualiza la variable del workspace",
        "tags": [
          "Variables"
        ],
        "x-scope": "variables:write"
      }
    },
    "/webhook-endpoints": {
      "get": {
        "externalDocs": {
          "description": "Guía: Webhooks entrantes",
          "url": "https://developers.meteor.com.co/guias/webhooks.html"
        },
        "operationId": "OutboundWebhooksController_list",
        "parameters": [],
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "allOf": [
                    {
                      "$ref": "#/components/schemas/ApiEnvelope"
                    },
                    {
                      "properties": {
                        "data": {
                          "items": {
                            "$ref": "#/components/schemas/WebhookEndpointResponseDto"
                          },
                          "type": "array"
                        }
                      },
                      "required": [
                        "data"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": ""
          },
          "400": {
            "$ref": "#/components/responses/ApiErrorInvalidRequest"
          },
          "401": {
            "$ref": "#/components/responses/ApiErrorAuth"
          },
          "403": {
            "$ref": "#/components/responses/ApiErrorForbidden"
          },
          "404": {
            "$ref": "#/components/responses/ApiErrorNotFound"
          },
          "429": {
            "$ref": "#/components/responses/ApiErrorRateLimit"
          },
          "500": {
            "$ref": "#/components/responses/ApiErrorServer"
          }
        },
        "security": [
          {
            "bearer": []
          },
          {
            "api-key": []
          }
        ],
        "summary": "Lista los webhook endpoints del workspace",
        "tags": [
          "Webhooks"
        ],
        "x-scope": "webhooks:manage"
      },
      "post": {
        "externalDocs": {
          "description": "Guía: Webhooks entrantes",
          "url": "https://developers.meteor.com.co/guias/webhooks.html"
        },
        "operationId": "OutboundWebhooksController_create",
        "parameters": [],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/CreateWebhookSubscriptionDto"
              }
            }
          },
          "required": true
        },
        "responses": {
          "201": {
            "content": {
              "application/json": {
                "schema": {
                  "allOf": [
                    {
                      "$ref": "#/components/schemas/ApiEnvelope"
                    },
                    {
                      "properties": {
                        "data": {
                          "$ref": "#/components/schemas/WebhookEndpointCreatedResponseDto"
                        }
                      },
                      "required": [
                        "data"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": ""
          },
          "400": {
            "$ref": "#/components/responses/ApiErrorInvalidRequest"
          },
          "401": {
            "$ref": "#/components/responses/ApiErrorAuth"
          },
          "403": {
            "$ref": "#/components/responses/ApiErrorForbidden"
          },
          "404": {
            "$ref": "#/components/responses/ApiErrorNotFound"
          },
          "409": {
            "$ref": "#/components/responses/ApiErrorConflict"
          },
          "429": {
            "$ref": "#/components/responses/ApiErrorRateLimit"
          },
          "500": {
            "$ref": "#/components/responses/ApiErrorServer"
          }
        },
        "security": [
          {
            "bearer": []
          },
          {
            "api-key": []
          }
        ],
        "summary": "Crea un webhook endpoint (devuelve el secreto una vez)",
        "tags": [
          "Webhooks"
        ],
        "x-scope": "webhooks:manage"
      }
    },
    "/webhook-endpoints/event-types": {
      "get": {
        "externalDocs": {
          "description": "Guía: Webhooks entrantes",
          "url": "https://developers.meteor.com.co/guias/webhooks.html"
        },
        "operationId": "OutboundWebhooksController_eventTypes",
        "parameters": [],
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "allOf": [
                    {
                      "$ref": "#/components/schemas/ApiEnvelope"
                    },
                    {
                      "properties": {
                        "data": {
                          "$ref": "#/components/schemas/WebhookEventTypeListResponseDto"
                        }
                      },
                      "required": [
                        "data"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": ""
          },
          "400": {
            "$ref": "#/components/responses/ApiErrorInvalidRequest"
          },
          "401": {
            "$ref": "#/components/responses/ApiErrorAuth"
          },
          "403": {
            "$ref": "#/components/responses/ApiErrorForbidden"
          },
          "404": {
            "$ref": "#/components/responses/ApiErrorNotFound"
          },
          "429": {
            "$ref": "#/components/responses/ApiErrorRateLimit"
          },
          "500": {
            "$ref": "#/components/responses/ApiErrorServer"
          }
        },
        "security": [
          {
            "bearer": []
          },
          {
            "api-key": []
          }
        ],
        "summary": "Catálogo de eventos salientes disponibles",
        "tags": [
          "Webhooks"
        ],
        "x-scope": "webhooks:manage"
      }
    },
    "/webhook-endpoints/{id}": {
      "delete": {
        "externalDocs": {
          "description": "Guía: Webhooks entrantes",
          "url": "https://developers.meteor.com.co/guias/webhooks.html"
        },
        "operationId": "OutboundWebhooksController_remove",
        "parameters": [
          {
            "description": "ID del recurso de esta ruta.",
            "in": "path",
            "name": "id",
            "required": true,
            "schema": {
              "type": "string"
            }
          }
        ],
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "allOf": [
                    {
                      "$ref": "#/components/schemas/ApiEnvelope"
                    },
                    {
                      "properties": {
                        "data": {
                          "$ref": "#/components/schemas/WebhookEndpointDeletedResponseDto"
                        }
                      },
                      "required": [
                        "data"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": ""
          },
          "400": {
            "$ref": "#/components/responses/ApiErrorInvalidRequest"
          },
          "401": {
            "$ref": "#/components/responses/ApiErrorAuth"
          },
          "403": {
            "$ref": "#/components/responses/ApiErrorForbidden"
          },
          "404": {
            "$ref": "#/components/responses/ApiErrorNotFound"
          },
          "409": {
            "$ref": "#/components/responses/ApiErrorConflict"
          },
          "429": {
            "$ref": "#/components/responses/ApiErrorRateLimit"
          },
          "500": {
            "$ref": "#/components/responses/ApiErrorServer"
          }
        },
        "security": [
          {
            "bearer": []
          },
          {
            "api-key": []
          }
        ],
        "summary": "Elimina un webhook endpoint",
        "tags": [
          "Webhooks"
        ],
        "x-scope": "webhooks:manage"
      }
    },
    "/webhook-endpoints/{id}/deliveries": {
      "get": {
        "externalDocs": {
          "description": "Guía: Webhooks entrantes",
          "url": "https://developers.meteor.com.co/guias/webhooks.html"
        },
        "operationId": "OutboundWebhooksController_deliveries",
        "parameters": [
          {
            "description": "ID del recurso de esta ruta.",
            "in": "path",
            "name": "id",
            "required": true,
            "schema": {
              "type": "string"
            }
          },
          {
            "description": "Cuántos resultados traer por página.",
            "in": "query",
            "name": "limit",
            "required": true,
            "schema": {
              "type": "string"
            }
          }
        ],
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "allOf": [
                    {
                      "$ref": "#/components/schemas/ApiEnvelope"
                    },
                    {
                      "properties": {
                        "data": {
                          "$ref": "#/components/schemas/WebhookDeliveryListResponseDto"
                        }
                      },
                      "required": [
                        "data"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": ""
          },
          "400": {
            "$ref": "#/components/responses/ApiErrorInvalidRequest"
          },
          "401": {
            "$ref": "#/components/responses/ApiErrorAuth"
          },
          "403": {
            "$ref": "#/components/responses/ApiErrorForbidden"
          },
          "404": {
            "$ref": "#/components/responses/ApiErrorNotFound"
          },
          "429": {
            "$ref": "#/components/responses/ApiErrorRateLimit"
          },
          "500": {
            "$ref": "#/components/responses/ApiErrorServer"
          }
        },
        "security": [
          {
            "bearer": []
          },
          {
            "api-key": []
          }
        ],
        "summary": "Log de intentos de entrega de un endpoint (F4.2b)",
        "tags": [
          "Webhooks"
        ],
        "x-scope": "webhooks:manage"
      }
    },
    "/webhook-endpoints/{id}/deliveries/{deliveryId}/retry": {
      "post": {
        "externalDocs": {
          "description": "Guía: Webhooks entrantes",
          "url": "https://developers.meteor.com.co/guias/webhooks.html"
        },
        "operationId": "OutboundWebhooksController_retryDelivery",
        "parameters": [
          {
            "description": "ID del recurso de esta ruta.",
            "in": "path",
            "name": "id",
            "required": true,
            "schema": {
              "type": "string"
            }
          },
          {
            "description": "ID del intento de entrega del webhook.",
            "in": "path",
            "name": "deliveryId",
            "required": true,
            "schema": {
              "type": "string"
            }
          }
        ],
        "responses": {
          "201": {
            "content": {
              "application/json": {
                "schema": {
                  "allOf": [
                    {
                      "$ref": "#/components/schemas/ApiEnvelope"
                    },
                    {
                      "properties": {
                        "data": {
                          "$ref": "#/components/schemas/WebhookDeliveryDto"
                        }
                      },
                      "required": [
                        "data"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": ""
          },
          "400": {
            "$ref": "#/components/responses/ApiErrorInvalidRequest"
          },
          "401": {
            "$ref": "#/components/responses/ApiErrorAuth"
          },
          "403": {
            "$ref": "#/components/responses/ApiErrorForbidden"
          },
          "404": {
            "$ref": "#/components/responses/ApiErrorNotFound"
          },
          "409": {
            "$ref": "#/components/responses/ApiErrorConflict"
          },
          "429": {
            "$ref": "#/components/responses/ApiErrorRateLimit"
          },
          "500": {
            "$ref": "#/components/responses/ApiErrorServer"
          }
        },
        "security": [
          {
            "bearer": []
          },
          {
            "api-key": []
          }
        ],
        "summary": "Reintenta manualmente una entrega puntual (F6.2)",
        "tags": [
          "Webhooks"
        ],
        "x-scope": "webhooks:manage"
      }
    },
    "/webhook-endpoints/{id}/test": {
      "post": {
        "externalDocs": {
          "description": "Guía: Webhooks entrantes",
          "url": "https://developers.meteor.com.co/guias/webhooks.html"
        },
        "operationId": "OutboundWebhooksController_sendTest",
        "parameters": [
          {
            "description": "ID del recurso de esta ruta.",
            "in": "path",
            "name": "id",
            "required": true,
            "schema": {
              "type": "string"
            }
          }
        ],
        "responses": {
          "201": {
            "content": {
              "application/json": {
                "schema": {
                  "allOf": [
                    {
                      "$ref": "#/components/schemas/ApiEnvelope"
                    },
                    {
                      "properties": {
                        "data": {
                          "$ref": "#/components/schemas/WebhookDeliveryDto"
                        }
                      },
                      "required": [
                        "data"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": ""
          },
          "400": {
            "$ref": "#/components/responses/ApiErrorInvalidRequest"
          },
          "401": {
            "$ref": "#/components/responses/ApiErrorAuth"
          },
          "403": {
            "$ref": "#/components/responses/ApiErrorForbidden"
          },
          "404": {
            "$ref": "#/components/responses/ApiErrorNotFound"
          },
          "409": {
            "$ref": "#/components/responses/ApiErrorConflict"
          },
          "429": {
            "$ref": "#/components/responses/ApiErrorRateLimit"
          },
          "500": {
            "$ref": "#/components/responses/ApiErrorServer"
          }
        },
        "security": [
          {
            "bearer": []
          },
          {
            "api-key": []
          }
        ],
        "summary": "Envía una entrega de prueba firmada al endpoint (F6.2)",
        "tags": [
          "Webhooks"
        ],
        "x-scope": "webhooks:manage"
      }
    },
    "/workspaces": {
      "post": {
        "externalDocs": {
          "description": "Guía: Aprovisionamiento de cuentas",
          "url": "https://developers.meteor.com.co/guias/aprovisionamiento.html"
        },
        "operationId": "ApiProvisioningController_create",
        "parameters": [
          {
            "in": "header",
            "name": "idempotency-key",
            "required": true,
            "schema": {
              "type": "string"
            }
          },
          {
            "description": "Reintentar con la misma clave devuelve la cuenta ya creada, no una nueva.",
            "in": "header",
            "name": "Idempotency-Key",
            "required": true,
            "schema": {
              "type": "string"
            }
          }
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/ProvisionWorkspaceDto"
              }
            }
          },
          "required": true
        },
        "responses": {
          "201": {
            "description": ""
          },
          "400": {
            "$ref": "#/components/responses/ApiErrorInvalidRequest"
          },
          "401": {
            "$ref": "#/components/responses/ApiErrorAuth"
          },
          "403": {
            "$ref": "#/components/responses/ApiErrorForbidden"
          },
          "404": {
            "$ref": "#/components/responses/ApiErrorNotFound"
          },
          "409": {
            "$ref": "#/components/responses/ApiErrorConflict"
          },
          "429": {
            "$ref": "#/components/responses/ApiErrorRateLimit"
          },
          "500": {
            "$ref": "#/components/responses/ApiErrorServer"
          }
        },
        "security": [
          {
            "bearer": []
          },
          {
            "api-key": []
          }
        ],
        "summary": "Crea una cuenta de Met con el plan Tech Partner (solo keys de partner).",
        "tags": [
          "Provisioning"
        ],
        "x-scope": "workspaces:provision"
      }
    },
    "/workspaces/{workspaceId}/activity": {
      "get": {
        "externalDocs": {
          "description": "Guía: Eventos en vivo",
          "url": "https://developers.meteor.com.co/guias/eventos.html"
        },
        "operationId": "EventsController_getWorkspaceActivity",
        "parameters": [
          {
            "description": "ID numérico del workspace. Debe ser el mismo workspace de tu API key: pedir otro devuelve 401.",
            "in": "path",
            "name": "workspaceId",
            "required": true,
            "schema": {
              "type": "number"
            }
          },
          {
            "description": "Cuántos resultados traer por página.",
            "in": "query",
            "name": "limit",
            "required": true,
            "schema": {
              "type": "number"
            }
          }
        ],
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "allOf": [
                    {
                      "$ref": "#/components/schemas/ApiEnvelope"
                    },
                    {
                      "properties": {
                        "data": {
                          "items": {
                            "$ref": "#/components/schemas/EventResponseDto"
                          },
                          "type": "array"
                        }
                      },
                      "required": [
                        "data"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": ""
          },
          "400": {
            "$ref": "#/components/responses/ApiErrorInvalidRequest"
          },
          "401": {
            "$ref": "#/components/responses/ApiErrorAuth"
          },
          "403": {
            "$ref": "#/components/responses/ApiErrorForbidden"
          },
          "404": {
            "$ref": "#/components/responses/ApiErrorNotFound"
          },
          "429": {
            "$ref": "#/components/responses/ApiErrorRateLimit"
          },
          "500": {
            "$ref": "#/components/responses/ApiErrorServer"
          }
        },
        "security": [
          {
            "bearer": []
          },
          {
            "api-key": []
          }
        ],
        "summary": "Obtiene la actividad del workspace",
        "tags": [
          "Events"
        ],
        "x-scope": "events:read"
      }
    },
    "/workspaces/{workspaceId}/agents": {
      "get": {
        "externalDocs": {
          "description": "Guía: Mets y sus herramientas",
          "url": "https://developers.meteor.com.co/guias/mets-y-herramientas.html"
        },
        "operationId": "ApiAgentsController_list",
        "parameters": [
          {
            "description": "ID numérico del workspace. Debe ser el mismo workspace de tu API key: pedir otro devuelve 401.",
            "in": "path",
            "name": "workspaceId",
            "required": true,
            "schema": {
              "type": "number"
            }
          }
        ],
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "allOf": [
                    {
                      "$ref": "#/components/schemas/ApiEnvelope"
                    },
                    {
                      "properties": {
                        "data": {
                          "items": {
                            "$ref": "#/components/schemas/AgentResponseDto"
                          },
                          "type": "array"
                        }
                      },
                      "required": [
                        "data"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": ""
          },
          "400": {
            "$ref": "#/components/responses/ApiErrorInvalidRequest"
          },
          "401": {
            "$ref": "#/components/responses/ApiErrorAuth"
          },
          "403": {
            "$ref": "#/components/responses/ApiErrorForbidden"
          },
          "404": {
            "$ref": "#/components/responses/ApiErrorNotFound"
          },
          "429": {
            "$ref": "#/components/responses/ApiErrorRateLimit"
          },
          "500": {
            "$ref": "#/components/responses/ApiErrorServer"
          }
        },
        "security": [
          {
            "bearer": []
          },
          {
            "api-key": []
          }
        ],
        "summary": "Lista los agentes (Mets) del workspace",
        "tags": [
          "Agents"
        ],
        "x-scope": "agents:read"
      },
      "post": {
        "externalDocs": {
          "description": "Guía: Mets y sus herramientas",
          "url": "https://developers.meteor.com.co/guias/mets-y-herramientas.html"
        },
        "operationId": "ApiAgentsController_create",
        "parameters": [
          {
            "description": "ID numérico del workspace. Debe ser el mismo workspace de tu API key: pedir otro devuelve 401.",
            "in": "path",
            "name": "workspaceId",
            "required": true,
            "schema": {
              "type": "number"
            }
          }
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/CreateAgentDto"
              }
            }
          },
          "required": true
        },
        "responses": {
          "201": {
            "content": {
              "application/json": {
                "schema": {
                  "allOf": [
                    {
                      "$ref": "#/components/schemas/ApiEnvelope"
                    },
                    {
                      "properties": {
                        "data": {
                          "$ref": "#/components/schemas/AgentResponseDto"
                        }
                      },
                      "required": [
                        "data"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": ""
          },
          "400": {
            "$ref": "#/components/responses/ApiErrorInvalidRequest"
          },
          "401": {
            "$ref": "#/components/responses/ApiErrorAuth"
          },
          "403": {
            "$ref": "#/components/responses/ApiErrorForbidden"
          },
          "404": {
            "$ref": "#/components/responses/ApiErrorNotFound"
          },
          "409": {
            "$ref": "#/components/responses/ApiErrorConflict"
          },
          "429": {
            "$ref": "#/components/responses/ApiErrorRateLimit"
          },
          "500": {
            "$ref": "#/components/responses/ApiErrorServer"
          }
        },
        "security": [
          {
            "bearer": []
          },
          {
            "api-key": []
          }
        ],
        "summary": "Crea un agente (Met)",
        "tags": [
          "Agents"
        ],
        "x-scope": "agents:write"
      }
    },
    "/workspaces/{workspaceId}/agents/{agentId}/disabled-tools": {
      "put": {
        "externalDocs": {
          "description": "Guía: Skills",
          "url": "https://developers.meteor.com.co/guias/skills.html"
        },
        "operationId": "AgentSkillsController_setDisabledTools",
        "parameters": [
          {
            "description": "ID del Met (agente).",
            "in": "path",
            "name": "agentId",
            "required": true,
            "schema": {
              "type": "string"
            }
          }
        ],
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "allOf": [
                    {
                      "$ref": "#/components/schemas/ApiEnvelope"
                    },
                    {
                      "properties": {
                        "data": {
                          "$ref": "#/components/schemas/AgentDisabledToolsResponseDto"
                        }
                      },
                      "required": [
                        "data"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": ""
          },
          "400": {
            "$ref": "#/components/responses/ApiErrorInvalidRequest"
          },
          "401": {
            "$ref": "#/components/responses/ApiErrorAuth"
          },
          "403": {
            "$ref": "#/components/responses/ApiErrorForbidden"
          },
          "404": {
            "$ref": "#/components/responses/ApiErrorNotFound"
          },
          "409": {
            "$ref": "#/components/responses/ApiErrorConflict"
          },
          "429": {
            "$ref": "#/components/responses/ApiErrorRateLimit"
          },
          "500": {
            "$ref": "#/components/responses/ApiErrorServer"
          }
        },
        "security": [
          {
            "bearer": []
          },
          {
            "api-key": []
          }
        ],
        "summary": "Reemplaza las acciones (tool keys) desactivadas por-Met — override sobre las tools de las skills",
        "tags": [
          "Skills"
        ],
        "x-scope": "skills:manage"
      }
    },
    "/workspaces/{workspaceId}/agents/{agentId}/functions": {
      "get": {
        "externalDocs": {
          "description": "Guía: Funciones y flujos",
          "url": "https://developers.meteor.com.co/guias/funciones-y-flujos.html"
        },
        "operationId": "FunctionsController_listAgentLinks",
        "parameters": [
          {
            "description": "ID del Met (agente).",
            "in": "path",
            "name": "agentId",
            "required": true,
            "schema": {
              "type": "string"
            }
          }
        ],
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "allOf": [
                    {
                      "$ref": "#/components/schemas/ApiEnvelope"
                    },
                    {
                      "properties": {
                        "data": {
                          "$ref": "#/components/schemas/AgentFunctionLinksResponseDto"
                        }
                      },
                      "required": [
                        "data"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": ""
          },
          "400": {
            "$ref": "#/components/responses/ApiErrorInvalidRequest"
          },
          "401": {
            "$ref": "#/components/responses/ApiErrorAuth"
          },
          "403": {
            "$ref": "#/components/responses/ApiErrorForbidden"
          },
          "404": {
            "$ref": "#/components/responses/ApiErrorNotFound"
          },
          "429": {
            "$ref": "#/components/responses/ApiErrorRateLimit"
          },
          "500": {
            "$ref": "#/components/responses/ApiErrorServer"
          }
        },
        "security": [
          {
            "bearer": []
          },
          {
            "api-key": []
          }
        ],
        "summary": "IDs de las funciones vinculadas a un Met.",
        "tags": [
          "Functions"
        ],
        "x-scope": "functions:read"
      }
    },
    "/workspaces/{workspaceId}/agents/{agentId}/functions/{functionId}": {
      "delete": {
        "externalDocs": {
          "description": "Guía: Funciones y flujos",
          "url": "https://developers.meteor.com.co/guias/funciones-y-flujos.html"
        },
        "operationId": "FunctionsController_unlink",
        "parameters": [
          {
            "description": "ID del Met (agente).",
            "in": "path",
            "name": "agentId",
            "required": true,
            "schema": {
              "type": "string"
            }
          },
          {
            "description": "ID de la función.",
            "in": "path",
            "name": "functionId",
            "required": true,
            "schema": {
              "type": "number"
            }
          }
        ],
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "allOf": [
                    {
                      "$ref": "#/components/schemas/ApiEnvelope"
                    },
                    {
                      "properties": {
                        "data": {
                          "$ref": "#/components/schemas/FunctionUnlinkResponseDto"
                        }
                      },
                      "required": [
                        "data"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": ""
          },
          "400": {
            "$ref": "#/components/responses/ApiErrorInvalidRequest"
          },
          "401": {
            "$ref": "#/components/responses/ApiErrorAuth"
          },
          "403": {
            "$ref": "#/components/responses/ApiErrorForbidden"
          },
          "404": {
            "$ref": "#/components/responses/ApiErrorNotFound"
          },
          "409": {
            "$ref": "#/components/responses/ApiErrorConflict"
          },
          "429": {
            "$ref": "#/components/responses/ApiErrorRateLimit"
          },
          "500": {
            "$ref": "#/components/responses/ApiErrorServer"
          }
        },
        "security": [
          {
            "bearer": []
          },
          {
            "api-key": []
          }
        ],
        "summary": "Desvincula una función de un Met.",
        "tags": [
          "Functions"
        ],
        "x-scope": "functions:write"
      }
    },
    "/workspaces/{workspaceId}/agents/{agentId}/functions/{functionId}/link": {
      "post": {
        "externalDocs": {
          "description": "Guía: Funciones y flujos",
          "url": "https://developers.meteor.com.co/guias/funciones-y-flujos.html"
        },
        "operationId": "FunctionsController_link",
        "parameters": [
          {
            "description": "ID del Met (agente).",
            "in": "path",
            "name": "agentId",
            "required": true,
            "schema": {
              "type": "string"
            }
          },
          {
            "description": "ID de la función.",
            "in": "path",
            "name": "functionId",
            "required": true,
            "schema": {
              "type": "number"
            }
          }
        ],
        "responses": {
          "201": {
            "content": {
              "application/json": {
                "schema": {
                  "allOf": [
                    {
                      "$ref": "#/components/schemas/ApiEnvelope"
                    },
                    {
                      "properties": {
                        "data": {
                          "$ref": "#/components/schemas/FunctionLinkResponseDto"
                        }
                      },
                      "required": [
                        "data"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": ""
          },
          "400": {
            "$ref": "#/components/responses/ApiErrorInvalidRequest"
          },
          "401": {
            "$ref": "#/components/responses/ApiErrorAuth"
          },
          "403": {
            "$ref": "#/components/responses/ApiErrorForbidden"
          },
          "404": {
            "$ref": "#/components/responses/ApiErrorNotFound"
          },
          "409": {
            "$ref": "#/components/responses/ApiErrorConflict"
          },
          "429": {
            "$ref": "#/components/responses/ApiErrorRateLimit"
          },
          "500": {
            "$ref": "#/components/responses/ApiErrorServer"
          }
        },
        "security": [
          {
            "bearer": []
          },
          {
            "api-key": []
          }
        ],
        "summary": "Vincula una función a un Met (idempotente).",
        "tags": [
          "Functions"
        ],
        "x-scope": "functions:write"
      }
    },
    "/workspaces/{workspaceId}/agents/{agentId}/mcps": {
      "get": {
        "externalDocs": {
          "description": "Guía: Skills",
          "url": "https://developers.meteor.com.co/guias/skills.html"
        },
        "operationId": "AgentSkillsController_listAgentMcps",
        "parameters": [
          {
            "description": "ID del Met (agente).",
            "in": "path",
            "name": "agentId",
            "required": true,
            "schema": {
              "type": "string"
            }
          }
        ],
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "allOf": [
                    {
                      "$ref": "#/components/schemas/ApiEnvelope"
                    },
                    {
                      "properties": {
                        "data": {
                          "$ref": "#/components/schemas/AgentMcpsResponseDto"
                        }
                      },
                      "required": [
                        "data"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": ""
          },
          "400": {
            "$ref": "#/components/responses/ApiErrorInvalidRequest"
          },
          "401": {
            "$ref": "#/components/responses/ApiErrorAuth"
          },
          "403": {
            "$ref": "#/components/responses/ApiErrorForbidden"
          },
          "404": {
            "$ref": "#/components/responses/ApiErrorNotFound"
          },
          "429": {
            "$ref": "#/components/responses/ApiErrorRateLimit"
          },
          "500": {
            "$ref": "#/components/responses/ApiErrorServer"
          }
        },
        "security": [
          {
            "bearer": []
          },
          {
            "api-key": []
          }
        ],
        "summary": "Lista los MCP únicos disponibles para un agente a través de sus skills vinculadas (para las filas de íconos de la UI) + las claves de herramientas deshabilitadas por Met",
        "tags": [
          "Skills"
        ],
        "x-scope": "skills:read"
      }
    },
    "/workspaces/{workspaceId}/agents/{agentId}/skills": {
      "get": {
        "externalDocs": {
          "description": "Guía: Skills",
          "url": "https://developers.meteor.com.co/guias/skills.html"
        },
        "operationId": "AgentSkillsController_listForAgent",
        "parameters": [
          {
            "description": "ID numérico del workspace. Debe ser el mismo workspace de tu API key: pedir otro devuelve 401.",
            "in": "path",
            "name": "workspaceId",
            "required": true,
            "schema": {
              "type": "number"
            }
          },
          {
            "description": "ID del Met (agente).",
            "in": "path",
            "name": "agentId",
            "required": true,
            "schema": {
              "type": "string"
            }
          }
        ],
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "allOf": [
                    {
                      "$ref": "#/components/schemas/ApiEnvelope"
                    },
                    {
                      "properties": {
                        "data": {
                          "$ref": "#/components/schemas/AgentAvailableSkillsResponseDto"
                        }
                      },
                      "required": [
                        "data"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": ""
          },
          "400": {
            "$ref": "#/components/responses/ApiErrorInvalidRequest"
          },
          "401": {
            "$ref": "#/components/responses/ApiErrorAuth"
          },
          "403": {
            "$ref": "#/components/responses/ApiErrorForbidden"
          },
          "404": {
            "$ref": "#/components/responses/ApiErrorNotFound"
          },
          "429": {
            "$ref": "#/components/responses/ApiErrorRateLimit"
          },
          "500": {
            "$ref": "#/components/responses/ApiErrorServer"
          }
        },
        "security": [
          {
            "bearer": []
          },
          {
            "api-key": []
          }
        ],
        "summary": "Lista skills disponibles para un Met — locales del workspace + globales no contratadas. Incluye estado derivado (active|pending_credentials|inactive), origin, requires_credentials y mcp_handler para que la UI decida si abrir el modal de credenciales tras un toggle ON.",
        "tags": [
          "Skills"
        ],
        "x-scope": "skills:read"
      }
    },
    "/workspaces/{workspaceId}/agents/{agentId}/skills/{skillId}": {
      "delete": {
        "externalDocs": {
          "description": "Guía: Skills",
          "url": "https://developers.meteor.com.co/guias/skills.html"
        },
        "operationId": "AgentSkillsController_unlink",
        "parameters": [
          {
            "description": "ID del Met (agente).",
            "in": "path",
            "name": "agentId",
            "required": true,
            "schema": {
              "type": "string"
            }
          },
          {
            "description": "ID de la skill.",
            "in": "path",
            "name": "skillId",
            "required": true,
            "schema": {
              "type": "number"
            }
          }
        ],
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "allOf": [
                    {
                      "$ref": "#/components/schemas/ApiEnvelope"
                    },
                    {
                      "properties": {
                        "data": {
                          "$ref": "#/components/schemas/SkillOkResponseDto"
                        }
                      },
                      "required": [
                        "data"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": ""
          },
          "400": {
            "$ref": "#/components/responses/ApiErrorInvalidRequest"
          },
          "401": {
            "$ref": "#/components/responses/ApiErrorAuth"
          },
          "403": {
            "$ref": "#/components/responses/ApiErrorForbidden"
          },
          "404": {
            "$ref": "#/components/responses/ApiErrorNotFound"
          },
          "409": {
            "$ref": "#/components/responses/ApiErrorConflict"
          },
          "429": {
            "$ref": "#/components/responses/ApiErrorRateLimit"
          },
          "500": {
            "$ref": "#/components/responses/ApiErrorServer"
          }
        },
        "security": [
          {
            "bearer": []
          },
          {
            "api-key": []
          }
        ],
        "summary": "Desvincula una skill de un agente",
        "tags": [
          "Skills"
        ],
        "x-scope": "skills:manage"
      }
    },
    "/workspaces/{workspaceId}/agents/{agentId}/skills/{skillId}/link": {
      "post": {
        "externalDocs": {
          "description": "Guía: Skills",
          "url": "https://developers.meteor.com.co/guias/skills.html"
        },
        "operationId": "AgentSkillsController_link",
        "parameters": [
          {
            "description": "ID del Met (agente).",
            "in": "path",
            "name": "agentId",
            "required": true,
            "schema": {
              "type": "string"
            }
          },
          {
            "description": "ID de la skill.",
            "in": "path",
            "name": "skillId",
            "required": true,
            "schema": {
              "type": "number"
            }
          }
        ],
        "responses": {
          "201": {
            "content": {
              "application/json": {
                "schema": {
                  "allOf": [
                    {
                      "$ref": "#/components/schemas/ApiEnvelope"
                    },
                    {
                      "properties": {
                        "data": {
                          "$ref": "#/components/schemas/LinkAgentSkillResponseDto"
                        }
                      },
                      "required": [
                        "data"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": ""
          },
          "400": {
            "$ref": "#/components/responses/ApiErrorInvalidRequest"
          },
          "401": {
            "$ref": "#/components/responses/ApiErrorAuth"
          },
          "403": {
            "$ref": "#/components/responses/ApiErrorForbidden"
          },
          "404": {
            "$ref": "#/components/responses/ApiErrorNotFound"
          },
          "409": {
            "$ref": "#/components/responses/ApiErrorConflict"
          },
          "429": {
            "$ref": "#/components/responses/ApiErrorRateLimit"
          },
          "500": {
            "$ref": "#/components/responses/ApiErrorServer"
          }
        },
        "security": [
          {
            "bearer": []
          },
          {
            "api-key": []
          }
        ],
        "summary": "Vincula una skill a un agente (idempotente)",
        "tags": [
          "Skills"
        ],
        "x-scope": "skills:manage"
      }
    },
    "/workspaces/{workspaceId}/agents/{agentId}/tools": {
      "get": {
        "externalDocs": {
          "description": "Guía: Mets y sus herramientas",
          "url": "https://developers.meteor.com.co/guias/mets-y-herramientas.html"
        },
        "operationId": "ApiAgentsController_listTools",
        "parameters": [
          {
            "description": "ID numérico del workspace. Debe ser el mismo workspace de tu API key: pedir otro devuelve 401.",
            "in": "path",
            "name": "workspaceId",
            "required": true,
            "schema": {
              "type": "number"
            }
          },
          {
            "description": "ID del Met (agente).",
            "in": "path",
            "name": "agentId",
            "required": true,
            "schema": {
              "type": "number"
            }
          }
        ],
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "allOf": [
                    {
                      "$ref": "#/components/schemas/ApiEnvelope"
                    },
                    {
                      "properties": {
                        "data": {
                          "$ref": "#/components/schemas/AgentToolsResponseDto"
                        }
                      },
                      "required": [
                        "data"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": ""
          },
          "400": {
            "$ref": "#/components/responses/ApiErrorInvalidRequest"
          },
          "401": {
            "$ref": "#/components/responses/ApiErrorAuth"
          },
          "403": {
            "$ref": "#/components/responses/ApiErrorForbidden"
          },
          "404": {
            "$ref": "#/components/responses/ApiErrorNotFound"
          },
          "429": {
            "$ref": "#/components/responses/ApiErrorRateLimit"
          },
          "500": {
            "$ref": "#/components/responses/ApiErrorServer"
          }
        },
        "security": [
          {
            "bearer": []
          },
          {
            "api-key": []
          }
        ],
        "summary": "Pool de tools que verá este Met (diagnóstico de por qué una Función/skill no aflora)",
        "tags": [
          "Agents"
        ],
        "x-scope": "agents:read"
      }
    },
    "/workspaces/{workspaceId}/asset-folders": {
      "get": {
        "externalDocs": {
          "description": "Guía: Operación del workspace",
          "url": "https://developers.meteor.com.co/guias/operacion-del-workspace.html"
        },
        "operationId": "WorkspaceAssetFoldersController_list",
        "parameters": [
          {
            "description": "ID numérico del workspace. Debe ser el mismo workspace de tu API key: pedir otro devuelve 401.",
            "in": "path",
            "name": "workspaceId",
            "required": true,
            "schema": {
              "type": "number"
            }
          }
        ],
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "allOf": [
                    {
                      "$ref": "#/components/schemas/ApiEnvelope"
                    },
                    {
                      "properties": {
                        "data": {
                          "items": {
                            "$ref": "#/components/schemas/WorkspaceAssetFolderNodeDto"
                          },
                          "type": "array"
                        }
                      },
                      "required": [
                        "data"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": ""
          },
          "400": {
            "$ref": "#/components/responses/ApiErrorInvalidRequest"
          },
          "401": {
            "$ref": "#/components/responses/ApiErrorAuth"
          },
          "403": {
            "$ref": "#/components/responses/ApiErrorForbidden"
          },
          "404": {
            "$ref": "#/components/responses/ApiErrorNotFound"
          },
          "429": {
            "$ref": "#/components/responses/ApiErrorRateLimit"
          },
          "500": {
            "$ref": "#/components/responses/ApiErrorServer"
          }
        },
        "security": [
          {
            "bearer": []
          },
          {
            "api-key": []
          }
        ],
        "summary": "Árbol de carpetas del workspace",
        "tags": [
          "Files"
        ],
        "x-scope": "files:read"
      },
      "post": {
        "externalDocs": {
          "description": "Guía: Operación del workspace",
          "url": "https://developers.meteor.com.co/guias/operacion-del-workspace.html"
        },
        "operationId": "WorkspaceAssetFoldersController_create",
        "parameters": [
          {
            "description": "ID numérico del workspace. Debe ser el mismo workspace de tu API key: pedir otro devuelve 401.",
            "in": "path",
            "name": "workspaceId",
            "required": true,
            "schema": {
              "type": "number"
            }
          }
        ],
        "responses": {
          "201": {
            "content": {
              "application/json": {
                "schema": {
                  "allOf": [
                    {
                      "$ref": "#/components/schemas/ApiEnvelope"
                    },
                    {
                      "properties": {
                        "data": {
                          "$ref": "#/components/schemas/WorkspaceAssetFolderResponseDto"
                        }
                      },
                      "required": [
                        "data"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": ""
          },
          "400": {
            "$ref": "#/components/responses/ApiErrorInvalidRequest"
          },
          "401": {
            "$ref": "#/components/responses/ApiErrorAuth"
          },
          "403": {
            "$ref": "#/components/responses/ApiErrorForbidden"
          },
          "404": {
            "$ref": "#/components/responses/ApiErrorNotFound"
          },
          "409": {
            "$ref": "#/components/responses/ApiErrorConflict"
          },
          "429": {
            "$ref": "#/components/responses/ApiErrorRateLimit"
          },
          "500": {
            "$ref": "#/components/responses/ApiErrorServer"
          }
        },
        "security": [
          {
            "bearer": []
          },
          {
            "api-key": []
          }
        ],
        "summary": "Crear carpeta",
        "tags": [
          "Files"
        ],
        "x-scope": "files:write"
      }
    },
    "/workspaces/{workspaceId}/asset-folders/{folderId}": {
      "delete": {
        "externalDocs": {
          "description": "Guía: Operación del workspace",
          "url": "https://developers.meteor.com.co/guias/operacion-del-workspace.html"
        },
        "operationId": "WorkspaceAssetFoldersController_remove",
        "parameters": [
          {
            "description": "ID numérico del workspace. Debe ser el mismo workspace de tu API key: pedir otro devuelve 401.",
            "in": "path",
            "name": "workspaceId",
            "required": true,
            "schema": {
              "type": "number"
            }
          },
          {
            "description": "ID numérico de la carpeta.",
            "in": "path",
            "name": "folderId",
            "required": true,
            "schema": {
              "type": "string"
            }
          }
        ],
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "allOf": [
                    {
                      "$ref": "#/components/schemas/ApiEnvelope"
                    },
                    {
                      "properties": {
                        "data": {
                          "$ref": "#/components/schemas/WorkspaceAssetDeletedResponseDto"
                        }
                      },
                      "required": [
                        "data"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": ""
          },
          "400": {
            "$ref": "#/components/responses/ApiErrorInvalidRequest"
          },
          "401": {
            "$ref": "#/components/responses/ApiErrorAuth"
          },
          "403": {
            "$ref": "#/components/responses/ApiErrorForbidden"
          },
          "404": {
            "$ref": "#/components/responses/ApiErrorNotFound"
          },
          "409": {
            "$ref": "#/components/responses/ApiErrorConflict"
          },
          "429": {
            "$ref": "#/components/responses/ApiErrorRateLimit"
          },
          "500": {
            "$ref": "#/components/responses/ApiErrorServer"
          }
        },
        "security": [
          {
            "bearer": []
          },
          {
            "api-key": []
          }
        ],
        "summary": "Borrar carpeta (assets quedan sueltos)",
        "tags": [
          "Files"
        ],
        "x-scope": "files:write"
      },
      "patch": {
        "externalDocs": {
          "description": "Guía: Operación del workspace",
          "url": "https://developers.meteor.com.co/guias/operacion-del-workspace.html"
        },
        "operationId": "WorkspaceAssetFoldersController_update",
        "parameters": [
          {
            "description": "ID numérico del workspace. Debe ser el mismo workspace de tu API key: pedir otro devuelve 401.",
            "in": "path",
            "name": "workspaceId",
            "required": true,
            "schema": {
              "type": "number"
            }
          },
          {
            "description": "ID numérico de la carpeta.",
            "in": "path",
            "name": "folderId",
            "required": true,
            "schema": {
              "type": "string"
            }
          }
        ],
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "allOf": [
                    {
                      "$ref": "#/components/schemas/ApiEnvelope"
                    },
                    {
                      "properties": {
                        "data": {
                          "$ref": "#/components/schemas/WorkspaceAssetFolderResponseDto"
                        }
                      },
                      "required": [
                        "data"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": ""
          },
          "400": {
            "$ref": "#/components/responses/ApiErrorInvalidRequest"
          },
          "401": {
            "$ref": "#/components/responses/ApiErrorAuth"
          },
          "403": {
            "$ref": "#/components/responses/ApiErrorForbidden"
          },
          "404": {
            "$ref": "#/components/responses/ApiErrorNotFound"
          },
          "409": {
            "$ref": "#/components/responses/ApiErrorConflict"
          },
          "429": {
            "$ref": "#/components/responses/ApiErrorRateLimit"
          },
          "500": {
            "$ref": "#/components/responses/ApiErrorServer"
          }
        },
        "security": [
          {
            "bearer": []
          },
          {
            "api-key": []
          }
        ],
        "summary": "Renombrar, mover o reordenar",
        "tags": [
          "Files"
        ],
        "x-scope": "files:write"
      }
    },
    "/workspaces/{workspaceId}/assets": {
      "get": {
        "externalDocs": {
          "description": "Guía: Operación del workspace",
          "url": "https://developers.meteor.com.co/guias/operacion-del-workspace.html"
        },
        "operationId": "WorkspaceAssetsController_list",
        "parameters": [
          {
            "description": "ID numérico del workspace. Debe ser el mismo workspace de tu API key: pedir otro devuelve 401.",
            "in": "path",
            "name": "workspaceId",
            "required": true,
            "schema": {
              "type": "number"
            }
          },
          {
            "description": "Filtra por carpeta.",
            "in": "query",
            "name": "folder_id",
            "required": true,
            "schema": {
              "type": "string"
            }
          },
          {
            "description": "Texto a buscar.",
            "in": "query",
            "name": "search",
            "required": true,
            "schema": {
              "type": "string"
            }
          },
          {
            "description": "Filtra por origen del registro.",
            "in": "query",
            "name": "source",
            "required": true,
            "schema": {
              "type": "string"
            }
          },
          {
            "description": "Filtra por tipo de archivo con el prefijo del MIME (por ejemplo `image/`).",
            "in": "query",
            "name": "mime_prefix",
            "required": true,
            "schema": {
              "type": "string"
            }
          },
          {
            "description": "Cuántos resultados traer por página.",
            "in": "query",
            "name": "limit",
            "required": true,
            "schema": {
              "type": "string"
            }
          },
          {
            "description": "Cuántos resultados saltear antes de empezar a devolver.",
            "in": "query",
            "name": "offset",
            "required": true,
            "schema": {
              "type": "string"
            }
          }
        ],
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "allOf": [
                    {
                      "$ref": "#/components/schemas/ApiEnvelope"
                    },
                    {
                      "properties": {
                        "data": {
                          "items": {
                            "$ref": "#/components/schemas/WorkspaceAssetWithUrlDto"
                          },
                          "type": "array"
                        }
                      },
                      "required": [
                        "data"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": ""
          },
          "400": {
            "$ref": "#/components/responses/ApiErrorInvalidRequest"
          },
          "401": {
            "$ref": "#/components/responses/ApiErrorAuth"
          },
          "403": {
            "$ref": "#/components/responses/ApiErrorForbidden"
          },
          "404": {
            "$ref": "#/components/responses/ApiErrorNotFound"
          },
          "429": {
            "$ref": "#/components/responses/ApiErrorRateLimit"
          },
          "500": {
            "$ref": "#/components/responses/ApiErrorServer"
          }
        },
        "security": [
          {
            "bearer": []
          },
          {
            "api-key": []
          }
        ],
        "summary": "Listar assets de la mediateca",
        "tags": [
          "Files"
        ],
        "x-scope": "files:read"
      },
      "post": {
        "externalDocs": {
          "description": "Guía: Operación del workspace",
          "url": "https://developers.meteor.com.co/guias/operacion-del-workspace.html"
        },
        "operationId": "WorkspaceAssetsController_upload",
        "parameters": [
          {
            "description": "ID numérico del workspace. Debe ser el mismo workspace de tu API key: pedir otro devuelve 401.",
            "in": "path",
            "name": "workspaceId",
            "required": true,
            "schema": {
              "type": "number"
            }
          }
        ],
        "responses": {
          "201": {
            "content": {
              "application/json": {
                "schema": {
                  "allOf": [
                    {
                      "$ref": "#/components/schemas/ApiEnvelope"
                    },
                    {
                      "properties": {
                        "data": {
                          "$ref": "#/components/schemas/WorkspaceAssetWithUrlDto"
                        }
                      },
                      "required": [
                        "data"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": ""
          },
          "400": {
            "$ref": "#/components/responses/ApiErrorInvalidRequest"
          },
          "401": {
            "$ref": "#/components/responses/ApiErrorAuth"
          },
          "403": {
            "$ref": "#/components/responses/ApiErrorForbidden"
          },
          "404": {
            "$ref": "#/components/responses/ApiErrorNotFound"
          },
          "409": {
            "$ref": "#/components/responses/ApiErrorConflict"
          },
          "429": {
            "$ref": "#/components/responses/ApiErrorRateLimit"
          },
          "500": {
            "$ref": "#/components/responses/ApiErrorServer"
          }
        },
        "security": [
          {
            "bearer": []
          },
          {
            "api-key": []
          }
        ],
        "summary": "Subir un asset suelto (máx 25MB)",
        "tags": [
          "Files"
        ],
        "x-scope": "files:write"
      }
    },
    "/workspaces/{workspaceId}/assets/provisional-cleanup": {
      "post": {
        "externalDocs": {
          "description": "Guía: Operación del workspace",
          "url": "https://developers.meteor.com.co/guias/operacion-del-workspace.html"
        },
        "operationId": "WorkspaceAssetsController_cleanupProvisional",
        "parameters": [
          {
            "description": "ID numérico del workspace. Debe ser el mismo workspace de tu API key: pedir otro devuelve 401.",
            "in": "path",
            "name": "workspaceId",
            "required": true,
            "schema": {
              "type": "number"
            }
          }
        ],
        "responses": {
          "201": {
            "content": {
              "application/json": {
                "schema": {
                  "allOf": [
                    {
                      "$ref": "#/components/schemas/ApiEnvelope"
                    },
                    {
                      "properties": {
                        "data": {
                          "$ref": "#/components/schemas/WorkspaceAssetCleanupResponseDto"
                        }
                      },
                      "required": [
                        "data"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": ""
          },
          "400": {
            "$ref": "#/components/responses/ApiErrorInvalidRequest"
          },
          "401": {
            "$ref": "#/components/responses/ApiErrorAuth"
          },
          "403": {
            "$ref": "#/components/responses/ApiErrorForbidden"
          },
          "404": {
            "$ref": "#/components/responses/ApiErrorNotFound"
          },
          "409": {
            "$ref": "#/components/responses/ApiErrorConflict"
          },
          "429": {
            "$ref": "#/components/responses/ApiErrorRateLimit"
          },
          "500": {
            "$ref": "#/components/responses/ApiErrorServer"
          }
        },
        "security": [
          {
            "bearer": []
          },
          {
            "api-key": []
          }
        ],
        "summary": "Ordena provisionales de Webi: mueve las usadas a carpeta, borra las huérfanas (apply=false = dry-run)",
        "tags": [
          "Files"
        ],
        "x-scope": "files:write"
      }
    },
    "/workspaces/{workspaceId}/assets/{assetId}": {
      "delete": {
        "externalDocs": {
          "description": "Guía: Operación del workspace",
          "url": "https://developers.meteor.com.co/guias/operacion-del-workspace.html"
        },
        "operationId": "WorkspaceAssetsController_remove",
        "parameters": [
          {
            "description": "ID numérico del workspace. Debe ser el mismo workspace de tu API key: pedir otro devuelve 401.",
            "in": "path",
            "name": "workspaceId",
            "required": true,
            "schema": {
              "type": "number"
            }
          },
          {
            "description": "ID del archivo de la Mediateca.",
            "in": "path",
            "name": "assetId",
            "required": true,
            "schema": {
              "type": "string"
            }
          }
        ],
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "allOf": [
                    {
                      "$ref": "#/components/schemas/ApiEnvelope"
                    },
                    {
                      "properties": {
                        "data": {
                          "$ref": "#/components/schemas/WorkspaceAssetDeletedResponseDto"
                        }
                      },
                      "required": [
                        "data"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": ""
          },
          "400": {
            "$ref": "#/components/responses/ApiErrorInvalidRequest"
          },
          "401": {
            "$ref": "#/components/responses/ApiErrorAuth"
          },
          "403": {
            "$ref": "#/components/responses/ApiErrorForbidden"
          },
          "404": {
            "$ref": "#/components/responses/ApiErrorNotFound"
          },
          "409": {
            "$ref": "#/components/responses/ApiErrorConflict"
          },
          "429": {
            "$ref": "#/components/responses/ApiErrorRateLimit"
          },
          "500": {
            "$ref": "#/components/responses/ApiErrorServer"
          }
        },
        "security": [
          {
            "bearer": []
          },
          {
            "api-key": []
          }
        ],
        "summary": "Borrar asset (también del storage)",
        "tags": [
          "Files"
        ],
        "x-scope": "files:write"
      },
      "patch": {
        "externalDocs": {
          "description": "Guía: Operación del workspace",
          "url": "https://developers.meteor.com.co/guias/operacion-del-workspace.html"
        },
        "operationId": "WorkspaceAssetsController_update",
        "parameters": [
          {
            "description": "ID numérico del workspace. Debe ser el mismo workspace de tu API key: pedir otro devuelve 401.",
            "in": "path",
            "name": "workspaceId",
            "required": true,
            "schema": {
              "type": "number"
            }
          },
          {
            "description": "ID del archivo de la Mediateca.",
            "in": "path",
            "name": "assetId",
            "required": true,
            "schema": {
              "type": "string"
            }
          }
        ],
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "allOf": [
                    {
                      "$ref": "#/components/schemas/ApiEnvelope"
                    },
                    {
                      "properties": {
                        "data": {
                          "$ref": "#/components/schemas/WorkspaceAssetWithUrlDto"
                        }
                      },
                      "required": [
                        "data"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": ""
          },
          "400": {
            "$ref": "#/components/responses/ApiErrorInvalidRequest"
          },
          "401": {
            "$ref": "#/components/responses/ApiErrorAuth"
          },
          "403": {
            "$ref": "#/components/responses/ApiErrorForbidden"
          },
          "404": {
            "$ref": "#/components/responses/ApiErrorNotFound"
          },
          "409": {
            "$ref": "#/components/responses/ApiErrorConflict"
          },
          "429": {
            "$ref": "#/components/responses/ApiErrorRateLimit"
          },
          "500": {
            "$ref": "#/components/responses/ApiErrorServer"
          }
        },
        "security": [
          {
            "bearer": []
          },
          {
            "api-key": []
          }
        ],
        "summary": "Renombrar o mover de carpeta",
        "tags": [
          "Files"
        ],
        "x-scope": "files:write"
      }
    },
    "/workspaces/{workspaceId}/automations": {
      "get": {
        "externalDocs": {
          "description": "Guía: Funciones y flujos",
          "url": "https://developers.meteor.com.co/guias/funciones-y-flujos.html"
        },
        "operationId": "AutomationsController_list",
        "parameters": [
          {
            "description": "ID numérico del workspace. Debe ser el mismo workspace de tu API key: pedir otro devuelve 401.",
            "in": "path",
            "name": "workspaceId",
            "required": true,
            "schema": {
              "type": "number"
            }
          },
          {
            "description": "Filtra por tarea.",
            "in": "query",
            "name": "task_id",
            "required": true,
            "schema": {
              "type": "string"
            }
          }
        ],
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "allOf": [
                    {
                      "$ref": "#/components/schemas/ApiEnvelope"
                    },
                    {
                      "properties": {
                        "data": {
                          "items": {
                            "$ref": "#/components/schemas/AutomationResponseDto"
                          },
                          "type": "array"
                        }
                      },
                      "required": [
                        "data"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": ""
          },
          "400": {
            "$ref": "#/components/responses/ApiErrorInvalidRequest"
          },
          "401": {
            "$ref": "#/components/responses/ApiErrorAuth"
          },
          "403": {
            "$ref": "#/components/responses/ApiErrorForbidden"
          },
          "404": {
            "$ref": "#/components/responses/ApiErrorNotFound"
          },
          "429": {
            "$ref": "#/components/responses/ApiErrorRateLimit"
          },
          "500": {
            "$ref": "#/components/responses/ApiErrorServer"
          }
        },
        "security": [
          {
            "bearer": []
          },
          {
            "api-key": []
          }
        ],
        "summary": "Lista las automatizaciones de disparador de un workspace, con filtro opcional por task_id",
        "tags": [
          "Automations"
        ],
        "x-scope": "automations:read"
      },
      "post": {
        "externalDocs": {
          "description": "Guía: Funciones y flujos",
          "url": "https://developers.meteor.com.co/guias/funciones-y-flujos.html"
        },
        "operationId": "AutomationsController_create",
        "parameters": [
          {
            "description": "ID numérico del workspace. Debe ser el mismo workspace de tu API key: pedir otro devuelve 401.",
            "in": "path",
            "name": "workspaceId",
            "required": true,
            "schema": {
              "type": "number"
            }
          }
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/CreateTriggerAutomationDto"
              }
            }
          },
          "required": true
        },
        "responses": {
          "201": {
            "content": {
              "application/json": {
                "schema": {
                  "allOf": [
                    {
                      "$ref": "#/components/schemas/ApiEnvelope"
                    },
                    {
                      "properties": {
                        "data": {
                          "$ref": "#/components/schemas/AutomationResponseDto"
                        }
                      },
                      "required": [
                        "data"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": ""
          },
          "400": {
            "$ref": "#/components/responses/ApiErrorInvalidRequest"
          },
          "401": {
            "$ref": "#/components/responses/ApiErrorAuth"
          },
          "403": {
            "$ref": "#/components/responses/ApiErrorForbidden"
          },
          "404": {
            "$ref": "#/components/responses/ApiErrorNotFound"
          },
          "409": {
            "$ref": "#/components/responses/ApiErrorConflict"
          },
          "429": {
            "$ref": "#/components/responses/ApiErrorRateLimit"
          },
          "500": {
            "$ref": "#/components/responses/ApiErrorServer"
          }
        },
        "security": [
          {
            "bearer": []
          },
          {
            "api-key": []
          }
        ],
        "summary": "Crea una automatización de disparador",
        "tags": [
          "Automations"
        ],
        "x-scope": "automations:write",
        "x-since": "1.1.0"
      }
    },
    "/workspaces/{workspaceId}/automations/{id}": {
      "delete": {
        "externalDocs": {
          "description": "Guía: Funciones y flujos",
          "url": "https://developers.meteor.com.co/guias/funciones-y-flujos.html"
        },
        "operationId": "AutomationsController_remove",
        "parameters": [
          {
            "description": "ID numérico del workspace. Debe ser el mismo workspace de tu API key: pedir otro devuelve 401.",
            "in": "path",
            "name": "workspaceId",
            "required": true,
            "schema": {
              "type": "number"
            }
          },
          {
            "description": "ID del recurso de esta ruta.",
            "in": "path",
            "name": "id",
            "required": true,
            "schema": {
              "type": "string"
            }
          }
        ],
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "allOf": [
                    {
                      "$ref": "#/components/schemas/ApiEnvelope"
                    },
                    {
                      "properties": {
                        "data": {
                          "$ref": "#/components/schemas/AutomationDeletedResponseDto"
                        }
                      },
                      "required": [
                        "data"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": ""
          },
          "400": {
            "$ref": "#/components/responses/ApiErrorInvalidRequest"
          },
          "401": {
            "$ref": "#/components/responses/ApiErrorAuth"
          },
          "403": {
            "$ref": "#/components/responses/ApiErrorForbidden"
          },
          "404": {
            "$ref": "#/components/responses/ApiErrorNotFound"
          },
          "409": {
            "$ref": "#/components/responses/ApiErrorConflict"
          },
          "429": {
            "$ref": "#/components/responses/ApiErrorRateLimit"
          },
          "500": {
            "$ref": "#/components/responses/ApiErrorServer"
          }
        },
        "security": [
          {
            "bearer": []
          },
          {
            "api-key": []
          }
        ],
        "summary": "Elimina una automatización de disparador",
        "tags": [
          "Automations"
        ],
        "x-scope": "automations:write",
        "x-since": "1.1.0"
      },
      "get": {
        "externalDocs": {
          "description": "Guía: Funciones y flujos",
          "url": "https://developers.meteor.com.co/guias/funciones-y-flujos.html"
        },
        "operationId": "AutomationsController_findOne",
        "parameters": [
          {
            "description": "ID numérico del workspace. Debe ser el mismo workspace de tu API key: pedir otro devuelve 401.",
            "in": "path",
            "name": "workspaceId",
            "required": true,
            "schema": {
              "type": "number"
            }
          },
          {
            "description": "ID del recurso de esta ruta.",
            "in": "path",
            "name": "id",
            "required": true,
            "schema": {
              "type": "string"
            }
          }
        ],
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "allOf": [
                    {
                      "$ref": "#/components/schemas/ApiEnvelope"
                    },
                    {
                      "properties": {
                        "data": {
                          "$ref": "#/components/schemas/AutomationResponseDto"
                        }
                      },
                      "required": [
                        "data"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": ""
          },
          "400": {
            "$ref": "#/components/responses/ApiErrorInvalidRequest"
          },
          "401": {
            "$ref": "#/components/responses/ApiErrorAuth"
          },
          "403": {
            "$ref": "#/components/responses/ApiErrorForbidden"
          },
          "404": {
            "$ref": "#/components/responses/ApiErrorNotFound"
          },
          "429": {
            "$ref": "#/components/responses/ApiErrorRateLimit"
          },
          "500": {
            "$ref": "#/components/responses/ApiErrorServer"
          }
        },
        "security": [
          {
            "bearer": []
          },
          {
            "api-key": []
          }
        ],
        "summary": "Obtiene una automatización de disparador por id",
        "tags": [
          "Automations"
        ],
        "x-scope": "automations:read"
      },
      "patch": {
        "externalDocs": {
          "description": "Guía: Funciones y flujos",
          "url": "https://developers.meteor.com.co/guias/funciones-y-flujos.html"
        },
        "operationId": "AutomationsController_update",
        "parameters": [
          {
            "description": "ID numérico del workspace. Debe ser el mismo workspace de tu API key: pedir otro devuelve 401.",
            "in": "path",
            "name": "workspaceId",
            "required": true,
            "schema": {
              "type": "number"
            }
          },
          {
            "description": "ID del recurso de esta ruta.",
            "in": "path",
            "name": "id",
            "required": true,
            "schema": {
              "type": "string"
            }
          }
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/UpdateTriggerAutomationDto"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "allOf": [
                    {
                      "$ref": "#/components/schemas/ApiEnvelope"
                    },
                    {
                      "properties": {
                        "data": {
                          "$ref": "#/components/schemas/AutomationResponseDto"
                        }
                      },
                      "required": [
                        "data"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": ""
          },
          "400": {
            "$ref": "#/components/responses/ApiErrorInvalidRequest"
          },
          "401": {
            "$ref": "#/components/responses/ApiErrorAuth"
          },
          "403": {
            "$ref": "#/components/responses/ApiErrorForbidden"
          },
          "404": {
            "$ref": "#/components/responses/ApiErrorNotFound"
          },
          "409": {
            "$ref": "#/components/responses/ApiErrorConflict"
          },
          "429": {
            "$ref": "#/components/responses/ApiErrorRateLimit"
          },
          "500": {
            "$ref": "#/components/responses/ApiErrorServer"
          }
        },
        "security": [
          {
            "bearer": []
          },
          {
            "api-key": []
          }
        ],
        "summary": "Actualiza una automatización de disparador",
        "tags": [
          "Automations"
        ],
        "x-scope": "automations:write",
        "x-since": "1.1.0"
      }
    },
    "/workspaces/{workspaceId}/automations/{id}/configuration": {
      "patch": {
        "externalDocs": {
          "description": "Guía: Funciones y flujos",
          "url": "https://developers.meteor.com.co/guias/funciones-y-flujos.html"
        },
        "operationId": "AutomationsController_updateManagedConfiguration",
        "parameters": [
          {
            "description": "ID numérico del workspace. Debe ser el mismo workspace de tu API key: pedir otro devuelve 401.",
            "in": "path",
            "name": "workspaceId",
            "required": true,
            "schema": {
              "type": "number"
            }
          },
          {
            "description": "ID del recurso de esta ruta.",
            "in": "path",
            "name": "id",
            "required": true,
            "schema": {
              "type": "string"
            }
          }
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/UpdateManagedAutomationConfigDto"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "allOf": [
                    {
                      "$ref": "#/components/schemas/ApiEnvelope"
                    },
                    {
                      "properties": {
                        "data": {
                          "$ref": "#/components/schemas/AutomationResponseDto"
                        }
                      },
                      "required": [
                        "data"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": ""
          },
          "400": {
            "$ref": "#/components/responses/ApiErrorInvalidRequest"
          },
          "401": {
            "$ref": "#/components/responses/ApiErrorAuth"
          },
          "403": {
            "$ref": "#/components/responses/ApiErrorForbidden"
          },
          "404": {
            "$ref": "#/components/responses/ApiErrorNotFound"
          },
          "409": {
            "$ref": "#/components/responses/ApiErrorConflict"
          },
          "429": {
            "$ref": "#/components/responses/ApiErrorRateLimit"
          },
          "500": {
            "$ref": "#/components/responses/ApiErrorServer"
          }
        },
        "security": [
          {
            "bearer": []
          },
          {
            "api-key": []
          }
        ],
        "summary": "Actualiza campos permitidos de un proceso administrado, con control de versión",
        "tags": [
          "Automations"
        ],
        "x-scope": "automations:write",
        "x-since": "1.1.0"
      }
    },
    "/workspaces/{workspaceId}/automations/{id}/configuration/history": {
      "get": {
        "externalDocs": {
          "description": "Guía: Funciones y flujos",
          "url": "https://developers.meteor.com.co/guias/funciones-y-flujos.html"
        },
        "operationId": "AutomationsController_listManagedConfigurationHistory",
        "parameters": [
          {
            "description": "ID numérico del workspace. Debe ser el mismo workspace de tu API key: pedir otro devuelve 401.",
            "in": "path",
            "name": "workspaceId",
            "required": true,
            "schema": {
              "type": "number"
            }
          },
          {
            "description": "ID del recurso de esta ruta.",
            "in": "path",
            "name": "id",
            "required": true,
            "schema": {
              "type": "string"
            }
          },
          {
            "description": "Cuántos resultados traer por página.",
            "in": "query",
            "name": "limit",
            "required": true,
            "schema": {
              "type": "string"
            }
          }
        ],
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "allOf": [
                    {
                      "$ref": "#/components/schemas/ApiEnvelope"
                    },
                    {
                      "properties": {
                        "data": {
                          "items": {
                            "$ref": "#/components/schemas/ManagedAutomationHistoryDto"
                          },
                          "type": "array"
                        }
                      },
                      "required": [
                        "data"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": ""
          },
          "400": {
            "$ref": "#/components/responses/ApiErrorInvalidRequest"
          },
          "401": {
            "$ref": "#/components/responses/ApiErrorAuth"
          },
          "403": {
            "$ref": "#/components/responses/ApiErrorForbidden"
          },
          "404": {
            "$ref": "#/components/responses/ApiErrorNotFound"
          },
          "429": {
            "$ref": "#/components/responses/ApiErrorRateLimit"
          },
          "500": {
            "$ref": "#/components/responses/ApiErrorServer"
          }
        },
        "security": [
          {
            "bearer": []
          },
          {
            "api-key": []
          }
        ],
        "summary": "Lista el historial de cambios de configuración administrada",
        "tags": [
          "Automations"
        ],
        "x-scope": "automations:read"
      }
    },
    "/workspaces/{workspaceId}/automations/{id}/configuration/restore": {
      "post": {
        "externalDocs": {
          "description": "Guía: Funciones y flujos",
          "url": "https://developers.meteor.com.co/guias/funciones-y-flujos.html"
        },
        "operationId": "AutomationsController_restoreManagedConfiguration",
        "parameters": [
          {
            "description": "ID numérico del workspace. Debe ser el mismo workspace de tu API key: pedir otro devuelve 401.",
            "in": "path",
            "name": "workspaceId",
            "required": true,
            "schema": {
              "type": "number"
            }
          },
          {
            "description": "ID del recurso de esta ruta.",
            "in": "path",
            "name": "id",
            "required": true,
            "schema": {
              "type": "string"
            }
          }
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/RestoreManagedAutomationConfigDto"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "allOf": [
                    {
                      "$ref": "#/components/schemas/ApiEnvelope"
                    },
                    {
                      "properties": {
                        "data": {
                          "$ref": "#/components/schemas/AutomationResponseDto"
                        }
                      },
                      "required": [
                        "data"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": ""
          },
          "400": {
            "$ref": "#/components/responses/ApiErrorInvalidRequest"
          },
          "401": {
            "$ref": "#/components/responses/ApiErrorAuth"
          },
          "403": {
            "$ref": "#/components/responses/ApiErrorForbidden"
          },
          "404": {
            "$ref": "#/components/responses/ApiErrorNotFound"
          },
          "409": {
            "$ref": "#/components/responses/ApiErrorConflict"
          },
          "429": {
            "$ref": "#/components/responses/ApiErrorRateLimit"
          },
          "500": {
            "$ref": "#/components/responses/ApiErrorServer"
          }
        },
        "security": [
          {
            "bearer": []
          },
          {
            "api-key": []
          }
        ],
        "summary": "Restaura la configuración publicada de un proceso administrado",
        "tags": [
          "Automations"
        ],
        "x-scope": "automations:write",
        "x-since": "1.1.0"
      }
    },
    "/workspaces/{workspaceId}/automations/{id}/run-now": {
      "post": {
        "externalDocs": {
          "description": "Guía: Funciones y flujos",
          "url": "https://developers.meteor.com.co/guias/funciones-y-flujos.html"
        },
        "operationId": "AutomationsController_runNow",
        "parameters": [
          {
            "description": "ID numérico del workspace. Debe ser el mismo workspace de tu API key: pedir otro devuelve 401.",
            "in": "path",
            "name": "workspaceId",
            "required": true,
            "schema": {
              "type": "number"
            }
          },
          {
            "description": "ID del recurso de esta ruta.",
            "in": "path",
            "name": "id",
            "required": true,
            "schema": {
              "type": "string"
            }
          }
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/RunSystemAutomationDto"
              }
            }
          },
          "required": true
        },
        "responses": {
          "201": {
            "description": ""
          },
          "400": {
            "$ref": "#/components/responses/ApiErrorInvalidRequest"
          },
          "401": {
            "$ref": "#/components/responses/ApiErrorAuth"
          },
          "403": {
            "$ref": "#/components/responses/ApiErrorForbidden"
          },
          "404": {
            "$ref": "#/components/responses/ApiErrorNotFound"
          },
          "409": {
            "$ref": "#/components/responses/ApiErrorConflict"
          },
          "429": {
            "$ref": "#/components/responses/ApiErrorRateLimit"
          },
          "500": {
            "$ref": "#/components/responses/ApiErrorServer"
          }
        },
        "security": [
          {
            "bearer": []
          },
          {
            "api-key": []
          }
        ],
        "summary": "Ejecuta inmediatamente un proceso administrado que admite ejecución manual",
        "tags": [
          "Automations"
        ],
        "x-scope": "automations:execute",
        "x-since": "1.1.0"
      }
    },
    "/workspaces/{workspaceId}/automations/{id}/runs": {
      "get": {
        "externalDocs": {
          "description": "Guía: Funciones y flujos",
          "url": "https://developers.meteor.com.co/guias/funciones-y-flujos.html"
        },
        "operationId": "AutomationsController_listRuns",
        "parameters": [
          {
            "description": "ID numérico del workspace. Debe ser el mismo workspace de tu API key: pedir otro devuelve 401.",
            "in": "path",
            "name": "workspaceId",
            "required": true,
            "schema": {
              "type": "number"
            }
          },
          {
            "description": "ID del recurso de esta ruta.",
            "in": "path",
            "name": "id",
            "required": true,
            "schema": {
              "type": "string"
            }
          },
          {
            "description": "Cuántos resultados traer por página.",
            "in": "query",
            "name": "limit",
            "required": true,
            "schema": {
              "type": "string"
            }
          }
        ],
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "allOf": [
                    {
                      "$ref": "#/components/schemas/ApiEnvelope"
                    },
                    {
                      "properties": {
                        "data": {
                          "items": {
                            "$ref": "#/components/schemas/SystemAutomationRunDto"
                          },
                          "type": "array"
                        }
                      },
                      "required": [
                        "data"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": ""
          },
          "400": {
            "$ref": "#/components/responses/ApiErrorInvalidRequest"
          },
          "401": {
            "$ref": "#/components/responses/ApiErrorAuth"
          },
          "403": {
            "$ref": "#/components/responses/ApiErrorForbidden"
          },
          "404": {
            "$ref": "#/components/responses/ApiErrorNotFound"
          },
          "429": {
            "$ref": "#/components/responses/ApiErrorRateLimit"
          },
          "500": {
            "$ref": "#/components/responses/ApiErrorServer"
          }
        },
        "security": [
          {
            "bearer": []
          },
          {
            "api-key": []
          }
        ],
        "summary": "Lista el historial sanitizado de un proceso administrado",
        "tags": [
          "Automations"
        ],
        "x-scope": "automations:read"
      }
    },
    "/workspaces/{workspaceId}/automations/{id}/schedule": {
      "patch": {
        "externalDocs": {
          "description": "Guía: Funciones y flujos",
          "url": "https://developers.meteor.com.co/guias/funciones-y-flujos.html"
        },
        "operationId": "AutomationsController_updateManagedSchedule",
        "parameters": [
          {
            "description": "ID numérico del workspace. Debe ser el mismo workspace de tu API key: pedir otro devuelve 401.",
            "in": "path",
            "name": "workspaceId",
            "required": true,
            "schema": {
              "type": "number"
            }
          },
          {
            "description": "ID del recurso de esta ruta.",
            "in": "path",
            "name": "id",
            "required": true,
            "schema": {
              "type": "string"
            }
          }
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/UpdateManagedScheduleDto"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "allOf": [
                    {
                      "$ref": "#/components/schemas/ApiEnvelope"
                    },
                    {
                      "properties": {
                        "data": {
                          "$ref": "#/components/schemas/AutomationResponseDto"
                        }
                      },
                      "required": [
                        "data"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": ""
          },
          "400": {
            "$ref": "#/components/responses/ApiErrorInvalidRequest"
          },
          "401": {
            "$ref": "#/components/responses/ApiErrorAuth"
          },
          "403": {
            "$ref": "#/components/responses/ApiErrorForbidden"
          },
          "404": {
            "$ref": "#/components/responses/ApiErrorNotFound"
          },
          "409": {
            "$ref": "#/components/responses/ApiErrorConflict"
          },
          "429": {
            "$ref": "#/components/responses/ApiErrorRateLimit"
          },
          "500": {
            "$ref": "#/components/responses/ApiErrorServer"
          }
        },
        "security": [
          {
            "bearer": []
          },
          {
            "api-key": []
          }
        ],
        "summary": "Actualiza el horario seguro de un proceso administrado recurrente",
        "tags": [
          "Automations"
        ],
        "x-scope": "automations:write",
        "x-since": "1.1.0"
      }
    },
    "/workspaces/{workspaceId}/broadcasts": {
      "get": {
        "externalDocs": {
          "description": "Guía: CRM y contactos",
          "url": "https://developers.meteor.com.co/guias/contactos.html"
        },
        "operationId": "BroadcastsController_list",
        "parameters": [
          {
            "description": "ID numérico del workspace. Debe ser el mismo workspace de tu API key: pedir otro devuelve 401.",
            "in": "path",
            "name": "workspaceId",
            "required": true,
            "schema": {
              "type": "number"
            }
          }
        ],
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "allOf": [
                    {
                      "$ref": "#/components/schemas/ApiEnvelope"
                    },
                    {
                      "properties": {
                        "data": {
                          "items": {
                            "$ref": "#/components/schemas/BroadcastListItemDto"
                          },
                          "type": "array"
                        }
                      },
                      "required": [
                        "data"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": ""
          },
          "400": {
            "$ref": "#/components/responses/ApiErrorInvalidRequest"
          },
          "401": {
            "$ref": "#/components/responses/ApiErrorAuth"
          },
          "403": {
            "$ref": "#/components/responses/ApiErrorForbidden"
          },
          "404": {
            "$ref": "#/components/responses/ApiErrorNotFound"
          },
          "429": {
            "$ref": "#/components/responses/ApiErrorRateLimit"
          },
          "500": {
            "$ref": "#/components/responses/ApiErrorServer"
          }
        },
        "security": [
          {
            "bearer": []
          },
          {
            "api-key": []
          }
        ],
        "summary": "Lista las difusiones del workspace",
        "tags": [
          "Broadcasts"
        ],
        "x-scope": "channels:read"
      },
      "post": {
        "externalDocs": {
          "description": "Guía: CRM y contactos",
          "url": "https://developers.meteor.com.co/guias/contactos.html"
        },
        "operationId": "BroadcastsController_create",
        "parameters": [
          {
            "description": "ID numérico del workspace. Debe ser el mismo workspace de tu API key: pedir otro devuelve 401.",
            "in": "path",
            "name": "workspaceId",
            "required": true,
            "schema": {
              "type": "number"
            }
          }
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/CreateBroadcastDto"
              }
            }
          },
          "required": true
        },
        "responses": {
          "201": {
            "content": {
              "application/json": {
                "schema": {
                  "allOf": [
                    {
                      "$ref": "#/components/schemas/ApiEnvelope"
                    },
                    {
                      "properties": {
                        "data": {
                          "$ref": "#/components/schemas/BroadcastResponseDto"
                        }
                      },
                      "required": [
                        "data"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": ""
          },
          "400": {
            "$ref": "#/components/responses/ApiErrorInvalidRequest"
          },
          "401": {
            "$ref": "#/components/responses/ApiErrorAuth"
          },
          "403": {
            "$ref": "#/components/responses/ApiErrorForbidden"
          },
          "404": {
            "$ref": "#/components/responses/ApiErrorNotFound"
          },
          "409": {
            "$ref": "#/components/responses/ApiErrorConflict"
          },
          "429": {
            "$ref": "#/components/responses/ApiErrorRateLimit"
          },
          "500": {
            "$ref": "#/components/responses/ApiErrorServer"
          }
        },
        "security": [
          {
            "bearer": []
          },
          {
            "api-key": []
          }
        ],
        "summary": "Crea una difusión (queda programada / \"ahora\")",
        "tags": [
          "Broadcasts"
        ],
        "x-scope": "channels:send"
      }
    },
    "/workspaces/{workspaceId}/broadcasts/preview-count": {
      "post": {
        "externalDocs": {
          "description": "Guía: CRM y contactos",
          "url": "https://developers.meteor.com.co/guias/contactos.html"
        },
        "operationId": "BroadcastsController_previewCount",
        "parameters": [
          {
            "description": "ID numérico del workspace. Debe ser el mismo workspace de tu API key: pedir otro devuelve 401.",
            "in": "path",
            "name": "workspaceId",
            "required": true,
            "schema": {
              "type": "number"
            }
          }
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/PreviewCountDto"
              }
            }
          },
          "required": true
        },
        "responses": {
          "201": {
            "content": {
              "application/json": {
                "schema": {
                  "allOf": [
                    {
                      "$ref": "#/components/schemas/ApiEnvelope"
                    },
                    {
                      "properties": {
                        "data": {
                          "$ref": "#/components/schemas/BroadcastPreviewCountResponseDto"
                        }
                      },
                      "required": [
                        "data"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": ""
          },
          "400": {
            "$ref": "#/components/responses/ApiErrorInvalidRequest"
          },
          "401": {
            "$ref": "#/components/responses/ApiErrorAuth"
          },
          "403": {
            "$ref": "#/components/responses/ApiErrorForbidden"
          },
          "404": {
            "$ref": "#/components/responses/ApiErrorNotFound"
          },
          "409": {
            "$ref": "#/components/responses/ApiErrorConflict"
          },
          "429": {
            "$ref": "#/components/responses/ApiErrorRateLimit"
          },
          "500": {
            "$ref": "#/components/responses/ApiErrorServer"
          }
        },
        "security": [
          {
            "bearer": []
          },
          {
            "api-key": []
          }
        ],
        "summary": "Cuenta contactos que cumplen el segmento (preview)",
        "tags": [
          "Broadcasts"
        ],
        "x-scope": "channels:read"
      }
    },
    "/workspaces/{workspaceId}/broadcasts/{id}": {
      "delete": {
        "externalDocs": {
          "description": "Guía: CRM y contactos",
          "url": "https://developers.meteor.com.co/guias/contactos.html"
        },
        "operationId": "BroadcastsController_remove",
        "parameters": [
          {
            "description": "ID numérico del workspace. Debe ser el mismo workspace de tu API key: pedir otro devuelve 401.",
            "in": "path",
            "name": "workspaceId",
            "required": true,
            "schema": {
              "type": "number"
            }
          },
          {
            "description": "ID del recurso de esta ruta.",
            "in": "path",
            "name": "id",
            "required": true,
            "schema": {
              "type": "string"
            }
          }
        ],
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "allOf": [
                    {
                      "$ref": "#/components/schemas/ApiEnvelope"
                    },
                    {
                      "properties": {
                        "data": {
                          "$ref": "#/components/schemas/BroadcastDeletedResponseDto"
                        }
                      },
                      "required": [
                        "data"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": ""
          },
          "400": {
            "$ref": "#/components/responses/ApiErrorInvalidRequest"
          },
          "401": {
            "$ref": "#/components/responses/ApiErrorAuth"
          },
          "403": {
            "$ref": "#/components/responses/ApiErrorForbidden"
          },
          "404": {
            "$ref": "#/components/responses/ApiErrorNotFound"
          },
          "409": {
            "$ref": "#/components/responses/ApiErrorConflict"
          },
          "429": {
            "$ref": "#/components/responses/ApiErrorRateLimit"
          },
          "500": {
            "$ref": "#/components/responses/ApiErrorServer"
          }
        },
        "security": [
          {
            "bearer": []
          },
          {
            "api-key": []
          }
        ],
        "summary": "Borra una difusión y sus destinatarios",
        "tags": [
          "Broadcasts"
        ],
        "x-scope": "channels:send"
      },
      "get": {
        "externalDocs": {
          "description": "Guía: CRM y contactos",
          "url": "https://developers.meteor.com.co/guias/contactos.html"
        },
        "operationId": "BroadcastsController_findOne",
        "parameters": [
          {
            "description": "ID numérico del workspace. Debe ser el mismo workspace de tu API key: pedir otro devuelve 401.",
            "in": "path",
            "name": "workspaceId",
            "required": true,
            "schema": {
              "type": "number"
            }
          },
          {
            "description": "ID del recurso de esta ruta.",
            "in": "path",
            "name": "id",
            "required": true,
            "schema": {
              "type": "string"
            }
          }
        ],
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "allOf": [
                    {
                      "$ref": "#/components/schemas/ApiEnvelope"
                    },
                    {
                      "properties": {
                        "data": {
                          "$ref": "#/components/schemas/BroadcastDetailDto"
                        }
                      },
                      "required": [
                        "data"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": ""
          },
          "400": {
            "$ref": "#/components/responses/ApiErrorInvalidRequest"
          },
          "401": {
            "$ref": "#/components/responses/ApiErrorAuth"
          },
          "403": {
            "$ref": "#/components/responses/ApiErrorForbidden"
          },
          "404": {
            "$ref": "#/components/responses/ApiErrorNotFound"
          },
          "429": {
            "$ref": "#/components/responses/ApiErrorRateLimit"
          },
          "500": {
            "$ref": "#/components/responses/ApiErrorServer"
          }
        },
        "security": [
          {
            "bearer": []
          },
          {
            "api-key": []
          }
        ],
        "summary": "Detalle de la difusión con métricas",
        "tags": [
          "Broadcasts"
        ],
        "x-scope": "channels:read"
      },
      "put": {
        "externalDocs": {
          "description": "Guía: CRM y contactos",
          "url": "https://developers.meteor.com.co/guias/contactos.html"
        },
        "operationId": "BroadcastsController_update",
        "parameters": [
          {
            "description": "ID numérico del workspace. Debe ser el mismo workspace de tu API key: pedir otro devuelve 401.",
            "in": "path",
            "name": "workspaceId",
            "required": true,
            "schema": {
              "type": "number"
            }
          },
          {
            "description": "ID del recurso de esta ruta.",
            "in": "path",
            "name": "id",
            "required": true,
            "schema": {
              "type": "string"
            }
          }
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/UpdateBroadcastDto"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "allOf": [
                    {
                      "$ref": "#/components/schemas/ApiEnvelope"
                    },
                    {
                      "properties": {
                        "data": {
                          "$ref": "#/components/schemas/BroadcastResponseDto"
                        }
                      },
                      "required": [
                        "data"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": ""
          },
          "400": {
            "$ref": "#/components/responses/ApiErrorInvalidRequest"
          },
          "401": {
            "$ref": "#/components/responses/ApiErrorAuth"
          },
          "403": {
            "$ref": "#/components/responses/ApiErrorForbidden"
          },
          "404": {
            "$ref": "#/components/responses/ApiErrorNotFound"
          },
          "409": {
            "$ref": "#/components/responses/ApiErrorConflict"
          },
          "429": {
            "$ref": "#/components/responses/ApiErrorRateLimit"
          },
          "500": {
            "$ref": "#/components/responses/ApiErrorServer"
          }
        },
        "security": [
          {
            "bearer": []
          },
          {
            "api-key": []
          }
        ],
        "summary": "Edita una difusión (solo en estado draft/scheduled)",
        "tags": [
          "Broadcasts"
        ],
        "x-scope": "channels:send"
      }
    },
    "/workspaces/{workspaceId}/broadcasts/{id}/cancel": {
      "post": {
        "externalDocs": {
          "description": "Guía: CRM y contactos",
          "url": "https://developers.meteor.com.co/guias/contactos.html"
        },
        "operationId": "BroadcastsController_cancel",
        "parameters": [
          {
            "description": "ID numérico del workspace. Debe ser el mismo workspace de tu API key: pedir otro devuelve 401.",
            "in": "path",
            "name": "workspaceId",
            "required": true,
            "schema": {
              "type": "number"
            }
          },
          {
            "description": "ID del recurso de esta ruta.",
            "in": "path",
            "name": "id",
            "required": true,
            "schema": {
              "type": "string"
            }
          }
        ],
        "responses": {
          "201": {
            "content": {
              "application/json": {
                "schema": {
                  "allOf": [
                    {
                      "$ref": "#/components/schemas/ApiEnvelope"
                    },
                    {
                      "properties": {
                        "data": {
                          "$ref": "#/components/schemas/BroadcastResponseDto"
                        }
                      },
                      "required": [
                        "data"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": ""
          },
          "400": {
            "$ref": "#/components/responses/ApiErrorInvalidRequest"
          },
          "401": {
            "$ref": "#/components/responses/ApiErrorAuth"
          },
          "403": {
            "$ref": "#/components/responses/ApiErrorForbidden"
          },
          "404": {
            "$ref": "#/components/responses/ApiErrorNotFound"
          },
          "409": {
            "$ref": "#/components/responses/ApiErrorConflict"
          },
          "429": {
            "$ref": "#/components/responses/ApiErrorRateLimit"
          },
          "500": {
            "$ref": "#/components/responses/ApiErrorServer"
          }
        },
        "security": [
          {
            "bearer": []
          },
          {
            "api-key": []
          }
        ],
        "summary": "Cancela una difusión programada o en curso",
        "tags": [
          "Broadcasts"
        ],
        "x-scope": "channels:send"
      }
    },
    "/workspaces/{workspaceId}/collections": {
      "get": {
        "externalDocs": {
          "description": "Guía: Datos: colecciones e ítems",
          "url": "https://developers.meteor.com.co/guias/colecciones-e-items.html"
        },
        "operationId": "CollectionsController_findAll",
        "parameters": [
          {
            "description": "ID numérico del workspace. Debe ser el mismo workspace de tu API key: pedir otro devuelve 401.",
            "in": "path",
            "name": "workspaceId",
            "required": true,
            "schema": {
              "type": "number"
            }
          },
          {
            "description": "Filtra por carpeta.",
            "in": "query",
            "name": "folder",
            "required": true,
            "schema": {
              "type": "string"
            }
          }
        ],
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "allOf": [
                    {
                      "$ref": "#/components/schemas/ApiEnvelope"
                    },
                    {
                      "properties": {
                        "data": {
                          "items": {
                            "$ref": "#/components/schemas/CollectionResponseDto"
                          },
                          "type": "array"
                        }
                      },
                      "required": [
                        "data"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": ""
          },
          "400": {
            "$ref": "#/components/responses/ApiErrorInvalidRequest"
          },
          "401": {
            "$ref": "#/components/responses/ApiErrorAuth"
          },
          "403": {
            "$ref": "#/components/responses/ApiErrorForbidden"
          },
          "404": {
            "$ref": "#/components/responses/ApiErrorNotFound"
          },
          "429": {
            "$ref": "#/components/responses/ApiErrorRateLimit"
          },
          "500": {
            "$ref": "#/components/responses/ApiErrorServer"
          }
        },
        "security": [
          {
            "bearer": []
          },
          {
            "api-key": []
          }
        ],
        "summary": "Lista las colecciones del workspace",
        "tags": [
          "Collections"
        ],
        "x-scope": "collections:read"
      }
    },
    "/workspaces/{workspaceId}/collections/by-slug/{slug}": {
      "get": {
        "externalDocs": {
          "description": "Guía: Datos: colecciones e ítems",
          "url": "https://developers.meteor.com.co/guias/colecciones-e-items.html"
        },
        "operationId": "SlugsController_resolveCollectionBySlug",
        "parameters": [
          {
            "description": "ID numérico del workspace. Debe ser el mismo workspace de tu API key: pedir otro devuelve 401.",
            "in": "path",
            "name": "workspaceId",
            "required": true,
            "schema": {
              "type": "number"
            }
          },
          {
            "description": "Identificador legible del recurso (en minúsculas y con guiones).",
            "in": "path",
            "name": "slug",
            "required": true,
            "schema": {
              "type": "string"
            }
          }
        ],
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "allOf": [
                    {
                      "$ref": "#/components/schemas/ApiEnvelope"
                    },
                    {
                      "properties": {
                        "data": {
                          "additionalProperties": true,
                          "allOf": [
                            {
                              "$ref": "#/components/schemas/ResolvedCollectionDto"
                            }
                          ]
                        }
                      },
                      "required": [
                        "data"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "La colección, con sus campos definidos (`collection_fields`). Además de las propiedades declaradas viene la fila completa."
          },
          "400": {
            "$ref": "#/components/responses/ApiErrorInvalidRequest"
          },
          "401": {
            "$ref": "#/components/responses/ApiErrorAuth"
          },
          "403": {
            "$ref": "#/components/responses/ApiErrorForbidden"
          },
          "404": {
            "$ref": "#/components/responses/ApiErrorNotFound"
          },
          "429": {
            "$ref": "#/components/responses/ApiErrorRateLimit"
          },
          "500": {
            "$ref": "#/components/responses/ApiErrorServer"
          }
        },
        "security": [
          {
            "bearer": []
          },
          {
            "api-key": []
          }
        ],
        "summary": "Resuelve una colección por slug",
        "tags": [
          "Collections"
        ],
        "x-scope": "collections:read"
      }
    },
    "/workspaces/{workspaceId}/collections/move-bulk": {
      "post": {
        "externalDocs": {
          "description": "Guía: Datos: colecciones e ítems",
          "url": "https://developers.meteor.com.co/guias/colecciones-e-items.html"
        },
        "operationId": "FoldersController_moveCollectionsBulk",
        "parameters": [
          {
            "description": "ID numérico del workspace. Debe ser el mismo workspace de tu API key: pedir otro devuelve 401.",
            "in": "path",
            "name": "workspaceId",
            "required": true,
            "schema": {
              "type": "number"
            }
          }
        ],
        "responses": {
          "201": {
            "content": {
              "application/json": {
                "schema": {
                  "allOf": [
                    {
                      "$ref": "#/components/schemas/ApiEnvelope"
                    },
                    {
                      "properties": {
                        "data": {
                          "$ref": "#/components/schemas/FolderMessageResponseDto"
                        }
                      },
                      "required": [
                        "data"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": ""
          },
          "400": {
            "$ref": "#/components/responses/ApiErrorInvalidRequest"
          },
          "401": {
            "$ref": "#/components/responses/ApiErrorAuth"
          },
          "403": {
            "$ref": "#/components/responses/ApiErrorForbidden"
          },
          "404": {
            "$ref": "#/components/responses/ApiErrorNotFound"
          },
          "409": {
            "$ref": "#/components/responses/ApiErrorConflict"
          },
          "429": {
            "$ref": "#/components/responses/ApiErrorRateLimit"
          },
          "500": {
            "$ref": "#/components/responses/ApiErrorServer"
          }
        },
        "security": [
          {
            "bearer": []
          },
          {
            "api-key": []
          }
        ],
        "summary": "Mueve varias colecciones a una carpeta",
        "tags": [
          "Collections"
        ],
        "x-scope": "collections:write"
      }
    },
    "/workspaces/{workspaceId}/collections/reorder": {
      "post": {
        "externalDocs": {
          "description": "Guía: Datos: colecciones e ítems",
          "url": "https://developers.meteor.com.co/guias/colecciones-e-items.html"
        },
        "operationId": "FoldersController_reorderRootCollections",
        "parameters": [
          {
            "description": "ID numérico del workspace. Debe ser el mismo workspace de tu API key: pedir otro devuelve 401.",
            "in": "path",
            "name": "workspaceId",
            "required": true,
            "schema": {
              "type": "number"
            }
          }
        ],
        "responses": {
          "201": {
            "content": {
              "application/json": {
                "schema": {
                  "allOf": [
                    {
                      "$ref": "#/components/schemas/ApiEnvelope"
                    },
                    {
                      "properties": {
                        "data": {
                          "$ref": "#/components/schemas/FolderMessageResponseDto"
                        }
                      },
                      "required": [
                        "data"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": ""
          },
          "400": {
            "$ref": "#/components/responses/ApiErrorInvalidRequest"
          },
          "401": {
            "$ref": "#/components/responses/ApiErrorAuth"
          },
          "403": {
            "$ref": "#/components/responses/ApiErrorForbidden"
          },
          "404": {
            "$ref": "#/components/responses/ApiErrorNotFound"
          },
          "409": {
            "$ref": "#/components/responses/ApiErrorConflict"
          },
          "429": {
            "$ref": "#/components/responses/ApiErrorRateLimit"
          },
          "500": {
            "$ref": "#/components/responses/ApiErrorServer"
          }
        },
        "security": [
          {
            "bearer": []
          },
          {
            "api-key": []
          }
        ],
        "summary": "Reordena las colecciones raíz",
        "tags": [
          "Collections"
        ],
        "x-scope": "collections:write"
      }
    },
    "/workspaces/{workspaceId}/collections/search": {
      "get": {
        "externalDocs": {
          "description": "Guía: Datos: colecciones e ítems",
          "url": "https://developers.meteor.com.co/guias/colecciones-e-items.html"
        },
        "operationId": "FoldersController_searchCollections",
        "parameters": [
          {
            "description": "ID numérico del workspace. Debe ser el mismo workspace de tu API key: pedir otro devuelve 401.",
            "in": "path",
            "name": "workspaceId",
            "required": true,
            "schema": {
              "type": "number"
            }
          },
          {
            "description": "Texto a buscar.",
            "in": "query",
            "name": "q",
            "required": true,
            "schema": {
              "type": "string"
            }
          }
        ],
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "allOf": [
                    {
                      "$ref": "#/components/schemas/ApiEnvelope"
                    },
                    {
                      "properties": {
                        "data": {
                          "items": {
                            "$ref": "#/components/schemas/CollectionSearchResultDto"
                          },
                          "type": "array"
                        }
                      },
                      "required": [
                        "data"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": ""
          },
          "400": {
            "$ref": "#/components/responses/ApiErrorInvalidRequest"
          },
          "401": {
            "$ref": "#/components/responses/ApiErrorAuth"
          },
          "403": {
            "$ref": "#/components/responses/ApiErrorForbidden"
          },
          "404": {
            "$ref": "#/components/responses/ApiErrorNotFound"
          },
          "429": {
            "$ref": "#/components/responses/ApiErrorRateLimit"
          },
          "500": {
            "$ref": "#/components/responses/ApiErrorServer"
          }
        },
        "security": [
          {
            "bearer": []
          },
          {
            "api-key": []
          }
        ],
        "summary": "Busca colecciones",
        "tags": [
          "Collections"
        ],
        "x-scope": "collections:read"
      }
    },
    "/workspaces/{workspaceId}/conversations": {
      "get": {
        "description": "Solo las de quien hace la llamada —las conversaciones no se comparten entre personas del workspace—, de la más reciente a la más vieja y topeadas a 50.",
        "externalDocs": {
          "description": "Guía: Operación del workspace",
          "url": "https://developers.meteor.com.co/guias/operacion-del-workspace.html"
        },
        "operationId": "ChatController_findAll",
        "parameters": [
          {
            "description": "ID numérico del workspace. Debe ser el mismo workspace de tu API key: pedir otro devuelve 401.",
            "in": "path",
            "name": "workspaceId",
            "required": true,
            "schema": {
              "type": "number"
            }
          }
        ],
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "allOf": [
                    {
                      "$ref": "#/components/schemas/ApiEnvelope"
                    },
                    {
                      "properties": {
                        "data": {
                          "items": {
                            "$ref": "#/components/schemas/ChatConversationResponseDto"
                          },
                          "type": "array"
                        }
                      },
                      "required": [
                        "data"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": ""
          },
          "400": {
            "$ref": "#/components/responses/ApiErrorInvalidRequest"
          },
          "401": {
            "$ref": "#/components/responses/ApiErrorAuth"
          },
          "403": {
            "$ref": "#/components/responses/ApiErrorForbidden"
          },
          "404": {
            "$ref": "#/components/responses/ApiErrorNotFound"
          },
          "429": {
            "$ref": "#/components/responses/ApiErrorRateLimit"
          },
          "500": {
            "$ref": "#/components/responses/ApiErrorServer"
          }
        },
        "security": [
          {
            "bearer": []
          },
          {
            "api-key": []
          }
        ],
        "summary": "Lista las conversaciones",
        "tags": [
          "Conversations"
        ],
        "x-scope": "conversations:read"
      }
    },
    "/workspaces/{workspaceId}/conversations/main": {
      "get": {
        "description": "Cada persona tiene una sola conversación principal por workspace y no se comparte. La primera llamada la crea, así que nunca responde 404.",
        "externalDocs": {
          "description": "Guía: Operación del workspace",
          "url": "https://developers.meteor.com.co/guias/operacion-del-workspace.html"
        },
        "operationId": "ChatController_getMain",
        "parameters": [
          {
            "description": "ID numérico del workspace. Debe ser el mismo workspace de tu API key: pedir otro devuelve 401.",
            "in": "path",
            "name": "workspaceId",
            "required": true,
            "schema": {
              "type": "number"
            }
          }
        ],
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "allOf": [
                    {
                      "$ref": "#/components/schemas/ApiEnvelope"
                    },
                    {
                      "properties": {
                        "data": {
                          "$ref": "#/components/schemas/ChatConversationResponseDto"
                        }
                      },
                      "required": [
                        "data"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": ""
          },
          "400": {
            "$ref": "#/components/responses/ApiErrorInvalidRequest"
          },
          "401": {
            "$ref": "#/components/responses/ApiErrorAuth"
          },
          "403": {
            "$ref": "#/components/responses/ApiErrorForbidden"
          },
          "404": {
            "$ref": "#/components/responses/ApiErrorNotFound"
          },
          "429": {
            "$ref": "#/components/responses/ApiErrorRateLimit"
          },
          "500": {
            "$ref": "#/components/responses/ApiErrorServer"
          }
        },
        "security": [
          {
            "bearer": []
          },
          {
            "api-key": []
          }
        ],
        "summary": "Obtiene o crea la conversación principal",
        "tags": [
          "Conversations"
        ],
        "x-scope": "conversations:read"
      }
    },
    "/workspaces/{workspaceId}/conversations/{convId}/messages": {
      "get": {
        "description": "Los 50 mensajes más recientes del hilo principal, en orden cronológico, más los hilos abiertos sobre la conversación. No hay cursor para pedir más historial.",
        "externalDocs": {
          "description": "Guía: Operación del workspace",
          "url": "https://developers.meteor.com.co/guias/operacion-del-workspace.html"
        },
        "operationId": "ChatController_getMessages",
        "parameters": [
          {
            "description": "ID numérico del workspace. Debe ser el mismo workspace de tu API key: pedir otro devuelve 401.",
            "in": "path",
            "name": "workspaceId",
            "required": true,
            "schema": {
              "type": "number"
            }
          },
          {
            "description": "ID numérico de la conversación.",
            "in": "path",
            "name": "convId",
            "required": true,
            "schema": {
              "type": "number"
            }
          }
        ],
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "allOf": [
                    {
                      "$ref": "#/components/schemas/ApiEnvelope"
                    },
                    {
                      "properties": {
                        "data": {
                          "$ref": "#/components/schemas/ChatMessagesResponseDto"
                        }
                      },
                      "required": [
                        "data"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": ""
          },
          "400": {
            "$ref": "#/components/responses/ApiErrorInvalidRequest"
          },
          "401": {
            "$ref": "#/components/responses/ApiErrorAuth"
          },
          "403": {
            "$ref": "#/components/responses/ApiErrorForbidden"
          },
          "404": {
            "$ref": "#/components/responses/ApiErrorNotFound"
          },
          "429": {
            "$ref": "#/components/responses/ApiErrorRateLimit"
          },
          "500": {
            "$ref": "#/components/responses/ApiErrorServer"
          }
        },
        "security": [
          {
            "bearer": []
          },
          {
            "api-key": []
          }
        ],
        "summary": "Obtiene los mensajes de la conversación",
        "tags": [
          "Conversations"
        ],
        "x-scope": "conversations:read"
      }
    },
    "/workspaces/{workspaceId}/events": {
      "get": {
        "externalDocs": {
          "description": "Guía: Eventos en vivo",
          "url": "https://developers.meteor.com.co/guias/eventos.html"
        },
        "operationId": "EventsController_getWorkspaceEvents",
        "parameters": [
          {
            "description": "ID numérico del workspace. Debe ser el mismo workspace de tu API key: pedir otro devuelve 401.",
            "in": "path",
            "name": "workspaceId",
            "required": true,
            "schema": {
              "type": "number"
            }
          },
          {
            "description": "Cuántos resultados traer por página.",
            "in": "query",
            "name": "limit",
            "required": true,
            "schema": {
              "type": "number"
            }
          }
        ],
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "allOf": [
                    {
                      "$ref": "#/components/schemas/ApiEnvelope"
                    },
                    {
                      "properties": {
                        "data": {
                          "items": {
                            "$ref": "#/components/schemas/EventResponseDto"
                          },
                          "type": "array"
                        }
                      },
                      "required": [
                        "data"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": ""
          },
          "400": {
            "$ref": "#/components/responses/ApiErrorInvalidRequest"
          },
          "401": {
            "$ref": "#/components/responses/ApiErrorAuth"
          },
          "403": {
            "$ref": "#/components/responses/ApiErrorForbidden"
          },
          "404": {
            "$ref": "#/components/responses/ApiErrorNotFound"
          },
          "429": {
            "$ref": "#/components/responses/ApiErrorRateLimit"
          },
          "500": {
            "$ref": "#/components/responses/ApiErrorServer"
          }
        },
        "security": [
          {
            "bearer": []
          },
          {
            "api-key": []
          }
        ],
        "summary": "Obtiene los eventos del workspace",
        "tags": [
          "Events"
        ],
        "x-scope": "events:read"
      }
    },
    "/workspaces/{workspaceId}/flow-mcps": {
      "get": {
        "externalDocs": {
          "description": "Guía: Funciones y flujos",
          "url": "https://developers.meteor.com.co/guias/funciones-y-flujos.html"
        },
        "operationId": "FlowsController_flowMcps",
        "parameters": [
          {
            "description": "ID numérico del workspace. Debe ser el mismo workspace de tu API key: pedir otro devuelve 401.",
            "in": "path",
            "name": "workspaceId",
            "required": true,
            "schema": {
              "type": "number"
            }
          }
        ],
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "allOf": [
                    {
                      "$ref": "#/components/schemas/ApiEnvelope"
                    },
                    {
                      "properties": {
                        "data": {
                          "$ref": "#/components/schemas/FlowMcpsResponseDto"
                        }
                      },
                      "required": [
                        "data"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": ""
          },
          "400": {
            "$ref": "#/components/responses/ApiErrorInvalidRequest"
          },
          "401": {
            "$ref": "#/components/responses/ApiErrorAuth"
          },
          "403": {
            "$ref": "#/components/responses/ApiErrorForbidden"
          },
          "404": {
            "$ref": "#/components/responses/ApiErrorNotFound"
          },
          "429": {
            "$ref": "#/components/responses/ApiErrorRateLimit"
          },
          "500": {
            "$ref": "#/components/responses/ApiErrorServer"
          }
        },
        "security": [
          {
            "bearer": []
          },
          {
            "api-key": []
          }
        ],
        "summary": "MCPs invocables desde un flujo: configurados (con credenciales) o sin credenciales.",
        "tags": [
          "Flows"
        ],
        "x-scope": "automations:read"
      }
    },
    "/workspaces/{workspaceId}/flow-runs/{runId}": {
      "get": {
        "externalDocs": {
          "description": "Guía: Funciones y flujos",
          "url": "https://developers.meteor.com.co/guias/funciones-y-flujos.html"
        },
        "operationId": "FlowsController_findRun",
        "parameters": [
          {
            "description": "ID numérico del workspace. Debe ser el mismo workspace de tu API key: pedir otro devuelve 401.",
            "in": "path",
            "name": "workspaceId",
            "required": true,
            "schema": {
              "type": "number"
            }
          },
          {
            "description": "ID del run, con prefijo `run_`.",
            "in": "path",
            "name": "runId",
            "required": true,
            "schema": {
              "type": "string"
            }
          }
        ],
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "allOf": [
                    {
                      "$ref": "#/components/schemas/ApiEnvelope"
                    },
                    {
                      "properties": {
                        "data": {
                          "$ref": "#/components/schemas/FlowRunDetailResponseDto"
                        }
                      },
                      "required": [
                        "data"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": ""
          },
          "400": {
            "$ref": "#/components/responses/ApiErrorInvalidRequest"
          },
          "401": {
            "$ref": "#/components/responses/ApiErrorAuth"
          },
          "403": {
            "$ref": "#/components/responses/ApiErrorForbidden"
          },
          "404": {
            "$ref": "#/components/responses/ApiErrorNotFound"
          },
          "429": {
            "$ref": "#/components/responses/ApiErrorRateLimit"
          },
          "500": {
            "$ref": "#/components/responses/ApiErrorServer"
          }
        },
        "security": [
          {
            "bearer": []
          },
          {
            "api-key": []
          }
        ],
        "summary": "Obtiene una ejecución de flujo con sus nodos",
        "tags": [
          "Flows"
        ],
        "x-scope": "automations:read"
      }
    },
    "/workspaces/{workspaceId}/flow-runs/{runId}/cancel": {
      "post": {
        "description": "Detiene el agendado de nodos nuevos y marca el run como cancelado. No aborta una generación que el proveedor ya esté corriendo: esa se termina y se cobra igual.",
        "externalDocs": {
          "description": "Guía: Funciones y flujos",
          "url": "https://developers.meteor.com.co/guias/funciones-y-flujos.html"
        },
        "operationId": "FlowsController_cancelRun",
        "parameters": [
          {
            "description": "ID numérico del workspace. Debe ser el mismo workspace de tu API key: pedir otro devuelve 401.",
            "in": "path",
            "name": "workspaceId",
            "required": true,
            "schema": {
              "type": "number"
            }
          },
          {
            "description": "ID del run, con prefijo `run_`.",
            "in": "path",
            "name": "runId",
            "required": true,
            "schema": {
              "type": "string"
            }
          }
        ],
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "allOf": [
                    {
                      "$ref": "#/components/schemas/ApiEnvelope"
                    },
                    {
                      "properties": {
                        "data": {
                          "$ref": "#/components/schemas/FlowRunResponseDto"
                        }
                      },
                      "required": [
                        "data"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": ""
          },
          "400": {
            "$ref": "#/components/responses/ApiErrorInvalidRequest"
          },
          "401": {
            "$ref": "#/components/responses/ApiErrorAuth"
          },
          "403": {
            "$ref": "#/components/responses/ApiErrorForbidden"
          },
          "404": {
            "$ref": "#/components/responses/ApiErrorNotFound"
          },
          "409": {
            "$ref": "#/components/responses/ApiErrorConflict"
          },
          "429": {
            "$ref": "#/components/responses/ApiErrorRateLimit"
          },
          "500": {
            "$ref": "#/components/responses/ApiErrorServer"
          }
        },
        "security": [
          {
            "bearer": []
          },
          {
            "api-key": []
          }
        ],
        "summary": "Cancela una ejecución en curso",
        "tags": [
          "Flows"
        ],
        "x-scope": "automations:write"
      }
    },
    "/workspaces/{workspaceId}/flows": {
      "get": {
        "externalDocs": {
          "description": "Guía: Funciones y flujos",
          "url": "https://developers.meteor.com.co/guias/funciones-y-flujos.html"
        },
        "operationId": "FlowsController_list",
        "parameters": [
          {
            "description": "ID numérico del workspace. Debe ser el mismo workspace de tu API key: pedir otro devuelve 401.",
            "in": "path",
            "name": "workspaceId",
            "required": true,
            "schema": {
              "type": "number"
            }
          }
        ],
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "allOf": [
                    {
                      "$ref": "#/components/schemas/ApiEnvelope"
                    },
                    {
                      "properties": {
                        "data": {
                          "items": {
                            "$ref": "#/components/schemas/FlowResponseDto"
                          },
                          "type": "array"
                        }
                      },
                      "required": [
                        "data"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": ""
          },
          "400": {
            "$ref": "#/components/responses/ApiErrorInvalidRequest"
          },
          "401": {
            "$ref": "#/components/responses/ApiErrorAuth"
          },
          "403": {
            "$ref": "#/components/responses/ApiErrorForbidden"
          },
          "404": {
            "$ref": "#/components/responses/ApiErrorNotFound"
          },
          "429": {
            "$ref": "#/components/responses/ApiErrorRateLimit"
          },
          "500": {
            "$ref": "#/components/responses/ApiErrorServer"
          }
        },
        "security": [
          {
            "bearer": []
          },
          {
            "api-key": []
          }
        ],
        "summary": "Lista los flujos de un workspace",
        "tags": [
          "Flows"
        ],
        "x-scope": "automations:read"
      },
      "post": {
        "externalDocs": {
          "description": "Guía: Funciones y flujos",
          "url": "https://developers.meteor.com.co/guias/funciones-y-flujos.html"
        },
        "operationId": "FlowsController_create",
        "parameters": [
          {
            "description": "ID numérico del workspace. Debe ser el mismo workspace de tu API key: pedir otro devuelve 401.",
            "in": "path",
            "name": "workspaceId",
            "required": true,
            "schema": {
              "type": "number"
            }
          }
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/CreateFlowDto"
              }
            }
          },
          "required": true
        },
        "responses": {
          "201": {
            "content": {
              "application/json": {
                "schema": {
                  "allOf": [
                    {
                      "$ref": "#/components/schemas/ApiEnvelope"
                    },
                    {
                      "properties": {
                        "data": {
                          "$ref": "#/components/schemas/FlowResponseDto"
                        }
                      },
                      "required": [
                        "data"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": ""
          },
          "400": {
            "$ref": "#/components/responses/ApiErrorInvalidRequest"
          },
          "401": {
            "$ref": "#/components/responses/ApiErrorAuth"
          },
          "403": {
            "$ref": "#/components/responses/ApiErrorForbidden"
          },
          "404": {
            "$ref": "#/components/responses/ApiErrorNotFound"
          },
          "409": {
            "$ref": "#/components/responses/ApiErrorConflict"
          },
          "429": {
            "$ref": "#/components/responses/ApiErrorRateLimit"
          },
          "500": {
            "$ref": "#/components/responses/ApiErrorServer"
          }
        },
        "security": [
          {
            "bearer": []
          },
          {
            "api-key": []
          }
        ],
        "summary": "Crea un flujo nuevo (borrador vacío)",
        "tags": [
          "Flows"
        ],
        "x-scope": "flows:write",
        "x-since": "1.1.0"
      }
    },
    "/workspaces/{workspaceId}/flows/import": {
      "post": {
        "externalDocs": {
          "description": "Guía: Funciones y flujos",
          "url": "https://developers.meteor.com.co/guias/funciones-y-flujos.html"
        },
        "operationId": "FlowsController_importFlow",
        "parameters": [
          {
            "description": "ID numérico del workspace. Debe ser el mismo workspace de tu API key: pedir otro devuelve 401.",
            "in": "path",
            "name": "workspaceId",
            "required": true,
            "schema": {
              "type": "number"
            }
          }
        ],
        "responses": {
          "201": {
            "content": {
              "application/json": {
                "schema": {
                  "allOf": [
                    {
                      "$ref": "#/components/schemas/ApiEnvelope"
                    },
                    {
                      "properties": {
                        "data": {
                          "$ref": "#/components/schemas/FlowImportResultResponseDto"
                        }
                      },
                      "required": [
                        "data"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": ""
          },
          "400": {
            "$ref": "#/components/responses/ApiErrorInvalidRequest"
          },
          "401": {
            "$ref": "#/components/responses/ApiErrorAuth"
          },
          "403": {
            "$ref": "#/components/responses/ApiErrorForbidden"
          },
          "404": {
            "$ref": "#/components/responses/ApiErrorNotFound"
          },
          "409": {
            "$ref": "#/components/responses/ApiErrorConflict"
          },
          "429": {
            "$ref": "#/components/responses/ApiErrorRateLimit"
          },
          "500": {
            "$ref": "#/components/responses/ApiErrorServer"
          }
        },
        "security": [
          {
            "bearer": []
          },
          {
            "api-key": []
          }
        ],
        "summary": "Importa un flujo desde JSON portable. Aterriza como draft. Body: { doc, bindings?, target_flow_id? }. Con target_flow_id actualiza ese flujo en vez de crear uno nuevo (idempotente).",
        "tags": [
          "Flows"
        ],
        "x-scope": "flows:write",
        "x-since": "1.5.0"
      }
    },
    "/workspaces/{workspaceId}/flows/import/preview": {
      "post": {
        "externalDocs": {
          "description": "Guía: Funciones y flujos",
          "url": "https://developers.meteor.com.co/guias/funciones-y-flujos.html"
        },
        "operationId": "FlowsController_importPreview",
        "parameters": [
          {
            "description": "ID numérico del workspace. Debe ser el mismo workspace de tu API key: pedir otro devuelve 401.",
            "in": "path",
            "name": "workspaceId",
            "required": true,
            "schema": {
              "type": "number"
            }
          }
        ],
        "responses": {
          "201": {
            "content": {
              "application/json": {
                "schema": {
                  "allOf": [
                    {
                      "$ref": "#/components/schemas/ApiEnvelope"
                    },
                    {
                      "properties": {
                        "data": {
                          "$ref": "#/components/schemas/FlowImportPreviewResponseDto"
                        }
                      },
                      "required": [
                        "data"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": ""
          },
          "400": {
            "$ref": "#/components/responses/ApiErrorInvalidRequest"
          },
          "401": {
            "$ref": "#/components/responses/ApiErrorAuth"
          },
          "403": {
            "$ref": "#/components/responses/ApiErrorForbidden"
          },
          "404": {
            "$ref": "#/components/responses/ApiErrorNotFound"
          },
          "409": {
            "$ref": "#/components/responses/ApiErrorConflict"
          },
          "429": {
            "$ref": "#/components/responses/ApiErrorRateLimit"
          },
          "500": {
            "$ref": "#/components/responses/ApiErrorServer"
          }
        },
        "security": [
          {
            "bearer": []
          },
          {
            "api-key": []
          }
        ],
        "summary": "Dry-run de import: valida el JSON y resuelve dependencias, sin crear nada. Body: { doc }",
        "tags": [
          "Flows"
        ],
        "x-scope": "automations:read",
        "x-since": "1.5.0"
      }
    },
    "/workspaces/{workspaceId}/flows/{id}": {
      "delete": {
        "externalDocs": {
          "description": "Guía: Funciones y flujos",
          "url": "https://developers.meteor.com.co/guias/funciones-y-flujos.html"
        },
        "operationId": "FlowsController_archive",
        "parameters": [
          {
            "description": "ID numérico del workspace. Debe ser el mismo workspace de tu API key: pedir otro devuelve 401.",
            "in": "path",
            "name": "workspaceId",
            "required": true,
            "schema": {
              "type": "number"
            }
          },
          {
            "description": "ID del recurso de esta ruta.",
            "in": "path",
            "name": "id",
            "required": true,
            "schema": {
              "type": "string"
            }
          }
        ],
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "allOf": [
                    {
                      "$ref": "#/components/schemas/ApiEnvelope"
                    },
                    {
                      "properties": {
                        "data": {
                          "$ref": "#/components/schemas/FlowArchivedResponseDto"
                        }
                      },
                      "required": [
                        "data"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": ""
          },
          "400": {
            "$ref": "#/components/responses/ApiErrorInvalidRequest"
          },
          "401": {
            "$ref": "#/components/responses/ApiErrorAuth"
          },
          "403": {
            "$ref": "#/components/responses/ApiErrorForbidden"
          },
          "404": {
            "$ref": "#/components/responses/ApiErrorNotFound"
          },
          "409": {
            "$ref": "#/components/responses/ApiErrorConflict"
          },
          "429": {
            "$ref": "#/components/responses/ApiErrorRateLimit"
          },
          "500": {
            "$ref": "#/components/responses/ApiErrorServer"
          }
        },
        "security": [
          {
            "bearer": []
          },
          {
            "api-key": []
          }
        ],
        "summary": "Archiva un flujo (borrado lógico)",
        "tags": [
          "Flows"
        ],
        "x-scope": "flows:write",
        "x-since": "1.1.0"
      },
      "get": {
        "externalDocs": {
          "description": "Guía: Funciones y flujos",
          "url": "https://developers.meteor.com.co/guias/funciones-y-flujos.html"
        },
        "operationId": "FlowsController_findOne",
        "parameters": [
          {
            "description": "ID numérico del workspace. Debe ser el mismo workspace de tu API key: pedir otro devuelve 401.",
            "in": "path",
            "name": "workspaceId",
            "required": true,
            "schema": {
              "type": "number"
            }
          },
          {
            "description": "ID del recurso de esta ruta.",
            "in": "path",
            "name": "id",
            "required": true,
            "schema": {
              "type": "string"
            }
          }
        ],
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "allOf": [
                    {
                      "$ref": "#/components/schemas/ApiEnvelope"
                    },
                    {
                      "properties": {
                        "data": {
                          "$ref": "#/components/schemas/FlowDetailResponseDto"
                        }
                      },
                      "required": [
                        "data"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": ""
          },
          "400": {
            "$ref": "#/components/responses/ApiErrorInvalidRequest"
          },
          "401": {
            "$ref": "#/components/responses/ApiErrorAuth"
          },
          "403": {
            "$ref": "#/components/responses/ApiErrorForbidden"
          },
          "404": {
            "$ref": "#/components/responses/ApiErrorNotFound"
          },
          "429": {
            "$ref": "#/components/responses/ApiErrorRateLimit"
          },
          "500": {
            "$ref": "#/components/responses/ApiErrorServer"
          }
        },
        "security": [
          {
            "bearer": []
          },
          {
            "api-key": []
          }
        ],
        "summary": "Obtiene un flujo con sus automatizaciones conectadas",
        "tags": [
          "Flows"
        ],
        "x-scope": "automations:read"
      },
      "patch": {
        "externalDocs": {
          "description": "Guía: Funciones y flujos",
          "url": "https://developers.meteor.com.co/guias/funciones-y-flujos.html"
        },
        "operationId": "FlowsController_update",
        "parameters": [
          {
            "description": "ID numérico del workspace. Debe ser el mismo workspace de tu API key: pedir otro devuelve 401.",
            "in": "path",
            "name": "workspaceId",
            "required": true,
            "schema": {
              "type": "number"
            }
          },
          {
            "description": "ID del recurso de esta ruta.",
            "in": "path",
            "name": "id",
            "required": true,
            "schema": {
              "type": "string"
            }
          }
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/UpdateFlowDto"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "allOf": [
                    {
                      "$ref": "#/components/schemas/ApiEnvelope"
                    },
                    {
                      "properties": {
                        "data": {
                          "$ref": "#/components/schemas/FlowResponseDto"
                        }
                      },
                      "required": [
                        "data"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": ""
          },
          "400": {
            "$ref": "#/components/responses/ApiErrorInvalidRequest"
          },
          "401": {
            "$ref": "#/components/responses/ApiErrorAuth"
          },
          "403": {
            "$ref": "#/components/responses/ApiErrorForbidden"
          },
          "404": {
            "$ref": "#/components/responses/ApiErrorNotFound"
          },
          "409": {
            "$ref": "#/components/responses/ApiErrorConflict"
          },
          "429": {
            "$ref": "#/components/responses/ApiErrorRateLimit"
          },
          "500": {
            "$ref": "#/components/responses/ApiErrorServer"
          }
        },
        "security": [
          {
            "bearer": []
          },
          {
            "api-key": []
          }
        ],
        "summary": "Actualiza un flujo (nombre, descripción, lienzo borrador)",
        "tags": [
          "Flows"
        ],
        "x-scope": "flows:write",
        "x-since": "1.1.0"
      }
    },
    "/workspaces/{workspaceId}/flows/{id}/duplicate": {
      "post": {
        "externalDocs": {
          "description": "Guía: Funciones y flujos",
          "url": "https://developers.meteor.com.co/guias/funciones-y-flujos.html"
        },
        "operationId": "FlowsController_duplicate",
        "parameters": [
          {
            "description": "ID numérico del workspace. Debe ser el mismo workspace de tu API key: pedir otro devuelve 401.",
            "in": "path",
            "name": "workspaceId",
            "required": true,
            "schema": {
              "type": "number"
            }
          },
          {
            "description": "ID del recurso de esta ruta.",
            "in": "path",
            "name": "id",
            "required": true,
            "schema": {
              "type": "string"
            }
          }
        ],
        "responses": {
          "201": {
            "content": {
              "application/json": {
                "schema": {
                  "allOf": [
                    {
                      "$ref": "#/components/schemas/ApiEnvelope"
                    },
                    {
                      "properties": {
                        "data": {
                          "$ref": "#/components/schemas/FlowResponseDto"
                        }
                      },
                      "required": [
                        "data"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": ""
          },
          "400": {
            "$ref": "#/components/responses/ApiErrorInvalidRequest"
          },
          "401": {
            "$ref": "#/components/responses/ApiErrorAuth"
          },
          "403": {
            "$ref": "#/components/responses/ApiErrorForbidden"
          },
          "404": {
            "$ref": "#/components/responses/ApiErrorNotFound"
          },
          "409": {
            "$ref": "#/components/responses/ApiErrorConflict"
          },
          "429": {
            "$ref": "#/components/responses/ApiErrorRateLimit"
          },
          "500": {
            "$ref": "#/components/responses/ApiErrorServer"
          }
        },
        "security": [
          {
            "bearer": []
          },
          {
            "api-key": []
          }
        ],
        "summary": "Duplica un flujo (crea un borrador nuevo)",
        "tags": [
          "Flows"
        ],
        "x-scope": "flows:write",
        "x-since": "1.1.0"
      }
    },
    "/workspaces/{workspaceId}/flows/{id}/export": {
      "get": {
        "externalDocs": {
          "description": "Guía: Funciones y flujos",
          "url": "https://developers.meteor.com.co/guias/funciones-y-flujos.html"
        },
        "operationId": "FlowsController_exportFlow",
        "parameters": [
          {
            "description": "ID numérico del workspace. Debe ser el mismo workspace de tu API key: pedir otro devuelve 401.",
            "in": "path",
            "name": "workspaceId",
            "required": true,
            "schema": {
              "type": "number"
            }
          },
          {
            "description": "ID del recurso de esta ruta.",
            "in": "path",
            "name": "id",
            "required": true,
            "schema": {
              "type": "string"
            }
          }
        ],
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "allOf": [
                    {
                      "$ref": "#/components/schemas/ApiEnvelope"
                    },
                    {
                      "properties": {
                        "data": {
                          "$ref": "#/components/schemas/FlowPortableDocDto"
                        }
                      },
                      "required": [
                        "data"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": ""
          },
          "400": {
            "$ref": "#/components/responses/ApiErrorInvalidRequest"
          },
          "401": {
            "$ref": "#/components/responses/ApiErrorAuth"
          },
          "403": {
            "$ref": "#/components/responses/ApiErrorForbidden"
          },
          "404": {
            "$ref": "#/components/responses/ApiErrorNotFound"
          },
          "429": {
            "$ref": "#/components/responses/ApiErrorRateLimit"
          },
          "500": {
            "$ref": "#/components/responses/ApiErrorServer"
          }
        },
        "security": [
          {
            "bearer": []
          },
          {
            "api-key": []
          }
        ],
        "summary": "Exporta un flujo como JSON portable (definición + dependencias descritas)",
        "tags": [
          "Flows"
        ],
        "x-scope": "automations:read",
        "x-since": "1.5.0"
      }
    },
    "/workspaces/{workspaceId}/flows/{id}/last-node-outputs": {
      "get": {
        "externalDocs": {
          "description": "Guía: Funciones y flujos",
          "url": "https://developers.meteor.com.co/guias/funciones-y-flujos.html"
        },
        "operationId": "FlowsController_lastNodeOutputs",
        "parameters": [
          {
            "description": "ID numérico del workspace. Debe ser el mismo workspace de tu API key: pedir otro devuelve 401.",
            "in": "path",
            "name": "workspaceId",
            "required": true,
            "schema": {
              "type": "number"
            }
          },
          {
            "description": "ID del recurso de esta ruta.",
            "in": "path",
            "name": "id",
            "required": true,
            "schema": {
              "type": "string"
            }
          }
        ],
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "allOf": [
                    {
                      "$ref": "#/components/schemas/ApiEnvelope"
                    },
                    {
                      "properties": {
                        "data": {
                          "$ref": "#/components/schemas/FlowLastNodeOutputsResponseDto"
                        }
                      },
                      "required": [
                        "data"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": ""
          },
          "400": {
            "$ref": "#/components/responses/ApiErrorInvalidRequest"
          },
          "401": {
            "$ref": "#/components/responses/ApiErrorAuth"
          },
          "403": {
            "$ref": "#/components/responses/ApiErrorForbidden"
          },
          "404": {
            "$ref": "#/components/responses/ApiErrorNotFound"
          },
          "429": {
            "$ref": "#/components/responses/ApiErrorRateLimit"
          },
          "500": {
            "$ref": "#/components/responses/ApiErrorServer"
          }
        },
        "security": [
          {
            "bearer": []
          },
          {
            "api-key": []
          }
        ],
        "summary": "Mapa nodeId → último output_artifact exitoso (para visor de inputs en el editor)",
        "tags": [
          "Flows"
        ],
        "x-scope": "automations:read"
      }
    },
    "/workspaces/{workspaceId}/flows/{id}/nodes/{nodeId}/test": {
      "post": {
        "externalDocs": {
          "description": "Guía: Funciones y flujos",
          "url": "https://developers.meteor.com.co/guias/funciones-y-flujos.html"
        },
        "operationId": "FlowsController_testNode",
        "parameters": [
          {
            "description": "ID numérico del workspace. Debe ser el mismo workspace de tu API key: pedir otro devuelve 401.",
            "in": "path",
            "name": "workspaceId",
            "required": true,
            "schema": {
              "type": "number"
            }
          },
          {
            "description": "ID del recurso de esta ruta.",
            "in": "path",
            "name": "id",
            "required": true,
            "schema": {
              "type": "string"
            }
          },
          {
            "description": "ID del nodo dentro del flujo.",
            "in": "path",
            "name": "nodeId",
            "required": true,
            "schema": {
              "type": "string"
            }
          }
        ],
        "responses": {
          "201": {
            "content": {
              "application/json": {
                "schema": {
                  "allOf": [
                    {
                      "$ref": "#/components/schemas/ApiEnvelope"
                    },
                    {
                      "properties": {
                        "data": {
                          "$ref": "#/components/schemas/FlowTestNodeResponseDto"
                        }
                      },
                      "required": [
                        "data"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": ""
          },
          "400": {
            "$ref": "#/components/responses/ApiErrorInvalidRequest"
          },
          "401": {
            "$ref": "#/components/responses/ApiErrorAuth"
          },
          "403": {
            "$ref": "#/components/responses/ApiErrorForbidden"
          },
          "404": {
            "$ref": "#/components/responses/ApiErrorNotFound"
          },
          "409": {
            "$ref": "#/components/responses/ApiErrorConflict"
          },
          "429": {
            "$ref": "#/components/responses/ApiErrorRateLimit"
          },
          "500": {
            "$ref": "#/components/responses/ApiErrorServer"
          }
        },
        "security": [
          {
            "bearer": []
          },
          {
            "api-key": []
          }
        ],
        "summary": "Ejecuta un solo nodo (de petición) con un payload de muestra y devuelve su respuesta — para mapear contra ella.",
        "tags": [
          "Flows"
        ],
        "x-scope": "automations:execute"
      }
    },
    "/workspaces/{workspaceId}/flows/{id}/publish": {
      "post": {
        "externalDocs": {
          "description": "Guía: Funciones y flujos",
          "url": "https://developers.meteor.com.co/guias/funciones-y-flujos.html"
        },
        "operationId": "FlowsController_publish",
        "parameters": [
          {
            "description": "ID numérico del workspace. Debe ser el mismo workspace de tu API key: pedir otro devuelve 401.",
            "in": "path",
            "name": "workspaceId",
            "required": true,
            "schema": {
              "type": "number"
            }
          },
          {
            "description": "ID del recurso de esta ruta.",
            "in": "path",
            "name": "id",
            "required": true,
            "schema": {
              "type": "string"
            }
          }
        ],
        "responses": {
          "201": {
            "content": {
              "application/json": {
                "schema": {
                  "allOf": [
                    {
                      "$ref": "#/components/schemas/ApiEnvelope"
                    },
                    {
                      "properties": {
                        "data": {
                          "$ref": "#/components/schemas/FlowResponseDto"
                        }
                      },
                      "required": [
                        "data"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": ""
          },
          "400": {
            "$ref": "#/components/responses/ApiErrorInvalidRequest"
          },
          "401": {
            "$ref": "#/components/responses/ApiErrorAuth"
          },
          "403": {
            "$ref": "#/components/responses/ApiErrorForbidden"
          },
          "404": {
            "$ref": "#/components/responses/ApiErrorNotFound"
          },
          "409": {
            "$ref": "#/components/responses/ApiErrorConflict"
          },
          "429": {
            "$ref": "#/components/responses/ApiErrorRateLimit"
          },
          "500": {
            "$ref": "#/components/responses/ApiErrorServer"
          }
        },
        "security": [
          {
            "bearer": []
          },
          {
            "api-key": []
          }
        ],
        "summary": "Snapshot draft → published. Triggers automáticos pasan a usarlo.",
        "tags": [
          "Flows"
        ],
        "x-scope": "automations:execute"
      }
    },
    "/workspaces/{workspaceId}/flows/{id}/run": {
      "post": {
        "externalDocs": {
          "description": "Guía: Funciones y flujos",
          "url": "https://developers.meteor.com.co/guias/funciones-y-flujos.html"
        },
        "operationId": "FlowsController_run",
        "parameters": [
          {
            "description": "ID numérico del workspace. Debe ser el mismo workspace de tu API key: pedir otro devuelve 401.",
            "in": "path",
            "name": "workspaceId",
            "required": true,
            "schema": {
              "type": "number"
            }
          },
          {
            "description": "ID del recurso de esta ruta.",
            "in": "path",
            "name": "id",
            "required": true,
            "schema": {
              "type": "string"
            }
          }
        ],
        "responses": {
          "201": {
            "content": {
              "application/json": {
                "schema": {
                  "allOf": [
                    {
                      "$ref": "#/components/schemas/ApiEnvelope"
                    },
                    {
                      "properties": {
                        "data": {
                          "$ref": "#/components/schemas/FlowRunStartedResponseDto"
                        }
                      },
                      "required": [
                        "data"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": ""
          },
          "400": {
            "$ref": "#/components/responses/ApiErrorInvalidRequest"
          },
          "401": {
            "$ref": "#/components/responses/ApiErrorAuth"
          },
          "403": {
            "$ref": "#/components/responses/ApiErrorForbidden"
          },
          "404": {
            "$ref": "#/components/responses/ApiErrorNotFound"
          },
          "409": {
            "$ref": "#/components/responses/ApiErrorConflict"
          },
          "429": {
            "$ref": "#/components/responses/ApiErrorRateLimit"
          },
          "500": {
            "$ref": "#/components/responses/ApiErrorServer"
          }
        },
        "security": [
          {
            "bearer": []
          },
          {
            "api-key": []
          }
        ],
        "summary": "Ejecuta el flow manualmente. Body: { trigger_payload?, use_draft? }",
        "tags": [
          "Flows"
        ],
        "x-scope": "automations:execute"
      }
    },
    "/workspaces/{workspaceId}/flows/{id}/runs": {
      "get": {
        "externalDocs": {
          "description": "Guía: Funciones y flujos",
          "url": "https://developers.meteor.com.co/guias/funciones-y-flujos.html"
        },
        "operationId": "FlowsController_listRuns",
        "parameters": [
          {
            "description": "ID numérico del workspace. Debe ser el mismo workspace de tu API key: pedir otro devuelve 401.",
            "in": "path",
            "name": "workspaceId",
            "required": true,
            "schema": {
              "type": "number"
            }
          },
          {
            "description": "ID del recurso de esta ruta.",
            "in": "path",
            "name": "id",
            "required": true,
            "schema": {
              "type": "string"
            }
          },
          {
            "description": "Cuántos resultados traer por página.",
            "in": "query",
            "name": "limit",
            "required": true,
            "schema": {
              "type": "string"
            }
          },
          {
            "description": "Cuántos resultados saltear antes de empezar a devolver.",
            "in": "query",
            "name": "offset",
            "required": true,
            "schema": {
              "type": "string"
            }
          }
        ],
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "allOf": [
                    {
                      "$ref": "#/components/schemas/ApiEnvelope"
                    },
                    {
                      "properties": {
                        "data": {
                          "items": {
                            "$ref": "#/components/schemas/FlowRunResponseDto"
                          },
                          "type": "array"
                        }
                      },
                      "required": [
                        "data"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": ""
          },
          "400": {
            "$ref": "#/components/responses/ApiErrorInvalidRequest"
          },
          "401": {
            "$ref": "#/components/responses/ApiErrorAuth"
          },
          "403": {
            "$ref": "#/components/responses/ApiErrorForbidden"
          },
          "404": {
            "$ref": "#/components/responses/ApiErrorNotFound"
          },
          "429": {
            "$ref": "#/components/responses/ApiErrorRateLimit"
          },
          "500": {
            "$ref": "#/components/responses/ApiErrorServer"
          }
        },
        "security": [
          {
            "bearer": []
          },
          {
            "api-key": []
          }
        ],
        "summary": "Lista las ejecuciones paginadas de un flujo",
        "tags": [
          "Flows"
        ],
        "x-scope": "automations:read"
      }
    },
    "/workspaces/{workspaceId}/folders": {
      "get": {
        "externalDocs": {
          "description": "Guía: Datos: colecciones e ítems",
          "url": "https://developers.meteor.com.co/guias/colecciones-e-items.html"
        },
        "operationId": "FoldersController_findAll",
        "parameters": [
          {
            "description": "ID numérico del workspace. Debe ser el mismo workspace de tu API key: pedir otro devuelve 401.",
            "in": "path",
            "name": "workspaceId",
            "required": true,
            "schema": {
              "type": "number"
            }
          }
        ],
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "allOf": [
                    {
                      "$ref": "#/components/schemas/ApiEnvelope"
                    },
                    {
                      "properties": {
                        "data": {
                          "items": {
                            "$ref": "#/components/schemas/FolderResponseDto"
                          },
                          "type": "array"
                        }
                      },
                      "required": [
                        "data"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": ""
          },
          "400": {
            "$ref": "#/components/responses/ApiErrorInvalidRequest"
          },
          "401": {
            "$ref": "#/components/responses/ApiErrorAuth"
          },
          "403": {
            "$ref": "#/components/responses/ApiErrorForbidden"
          },
          "404": {
            "$ref": "#/components/responses/ApiErrorNotFound"
          },
          "429": {
            "$ref": "#/components/responses/ApiErrorRateLimit"
          },
          "500": {
            "$ref": "#/components/responses/ApiErrorServer"
          }
        },
        "security": [
          {
            "bearer": []
          },
          {
            "api-key": []
          }
        ],
        "summary": "Lista las carpetas del workspace",
        "tags": [
          "Collections"
        ],
        "x-scope": "collections:read"
      },
      "post": {
        "externalDocs": {
          "description": "Guía: Datos: colecciones e ítems",
          "url": "https://developers.meteor.com.co/guias/colecciones-e-items.html"
        },
        "operationId": "FoldersController_create",
        "parameters": [
          {
            "description": "ID numérico del workspace. Debe ser el mismo workspace de tu API key: pedir otro devuelve 401.",
            "in": "path",
            "name": "workspaceId",
            "required": true,
            "schema": {
              "type": "number"
            }
          }
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/CreateFolderDto"
              }
            }
          },
          "required": true
        },
        "responses": {
          "201": {
            "content": {
              "application/json": {
                "schema": {
                  "allOf": [
                    {
                      "$ref": "#/components/schemas/ApiEnvelope"
                    },
                    {
                      "properties": {
                        "data": {
                          "$ref": "#/components/schemas/FolderResponseDto"
                        }
                      },
                      "required": [
                        "data"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": ""
          },
          "400": {
            "$ref": "#/components/responses/ApiErrorInvalidRequest"
          },
          "401": {
            "$ref": "#/components/responses/ApiErrorAuth"
          },
          "403": {
            "$ref": "#/components/responses/ApiErrorForbidden"
          },
          "404": {
            "$ref": "#/components/responses/ApiErrorNotFound"
          },
          "409": {
            "$ref": "#/components/responses/ApiErrorConflict"
          },
          "429": {
            "$ref": "#/components/responses/ApiErrorRateLimit"
          },
          "500": {
            "$ref": "#/components/responses/ApiErrorServer"
          }
        },
        "security": [
          {
            "bearer": []
          },
          {
            "api-key": []
          }
        ],
        "summary": "Crea una carpeta",
        "tags": [
          "Collections"
        ],
        "x-scope": "collections:write"
      }
    },
    "/workspaces/{workspaceId}/folders/hierarchy": {
      "get": {
        "externalDocs": {
          "description": "Guía: Datos: colecciones e ítems",
          "url": "https://developers.meteor.com.co/guias/colecciones-e-items.html"
        },
        "operationId": "FoldersController_getHierarchy",
        "parameters": [
          {
            "description": "ID numérico del workspace. Debe ser el mismo workspace de tu API key: pedir otro devuelve 401.",
            "in": "path",
            "name": "workspaceId",
            "required": true,
            "schema": {
              "type": "number"
            }
          }
        ],
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "allOf": [
                    {
                      "$ref": "#/components/schemas/ApiEnvelope"
                    },
                    {
                      "properties": {
                        "data": {
                          "$ref": "#/components/schemas/FolderHierarchyResponseDto"
                        }
                      },
                      "required": [
                        "data"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": ""
          },
          "400": {
            "$ref": "#/components/responses/ApiErrorInvalidRequest"
          },
          "401": {
            "$ref": "#/components/responses/ApiErrorAuth"
          },
          "403": {
            "$ref": "#/components/responses/ApiErrorForbidden"
          },
          "404": {
            "$ref": "#/components/responses/ApiErrorNotFound"
          },
          "429": {
            "$ref": "#/components/responses/ApiErrorRateLimit"
          },
          "500": {
            "$ref": "#/components/responses/ApiErrorServer"
          }
        },
        "security": [
          {
            "bearer": []
          },
          {
            "api-key": []
          }
        ],
        "summary": "Obtiene el árbol de jerarquía de carpetas y colecciones",
        "tags": [
          "Collections"
        ],
        "x-scope": "collections:read"
      }
    },
    "/workspaces/{workspaceId}/folders/reorder": {
      "post": {
        "externalDocs": {
          "description": "Guía: Datos: colecciones e ítems",
          "url": "https://developers.meteor.com.co/guias/colecciones-e-items.html"
        },
        "operationId": "FoldersController_reorderFolders",
        "parameters": [
          {
            "description": "ID numérico del workspace. Debe ser el mismo workspace de tu API key: pedir otro devuelve 401.",
            "in": "path",
            "name": "workspaceId",
            "required": true,
            "schema": {
              "type": "number"
            }
          }
        ],
        "responses": {
          "201": {
            "content": {
              "application/json": {
                "schema": {
                  "allOf": [
                    {
                      "$ref": "#/components/schemas/ApiEnvelope"
                    },
                    {
                      "properties": {
                        "data": {
                          "$ref": "#/components/schemas/FolderMessageResponseDto"
                        }
                      },
                      "required": [
                        "data"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": ""
          },
          "400": {
            "$ref": "#/components/responses/ApiErrorInvalidRequest"
          },
          "401": {
            "$ref": "#/components/responses/ApiErrorAuth"
          },
          "403": {
            "$ref": "#/components/responses/ApiErrorForbidden"
          },
          "404": {
            "$ref": "#/components/responses/ApiErrorNotFound"
          },
          "409": {
            "$ref": "#/components/responses/ApiErrorConflict"
          },
          "429": {
            "$ref": "#/components/responses/ApiErrorRateLimit"
          },
          "500": {
            "$ref": "#/components/responses/ApiErrorServer"
          }
        },
        "security": [
          {
            "bearer": []
          },
          {
            "api-key": []
          }
        ],
        "summary": "Reordena las carpetas",
        "tags": [
          "Collections"
        ],
        "x-scope": "collections:write"
      }
    },
    "/workspaces/{workspaceId}/folders/search": {
      "get": {
        "externalDocs": {
          "description": "Guía: Datos: colecciones e ítems",
          "url": "https://developers.meteor.com.co/guias/colecciones-e-items.html"
        },
        "operationId": "FoldersController_searchFolders",
        "parameters": [
          {
            "description": "ID numérico del workspace. Debe ser el mismo workspace de tu API key: pedir otro devuelve 401.",
            "in": "path",
            "name": "workspaceId",
            "required": true,
            "schema": {
              "type": "number"
            }
          },
          {
            "description": "Texto a buscar.",
            "in": "query",
            "name": "q",
            "required": true,
            "schema": {
              "type": "string"
            }
          }
        ],
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "allOf": [
                    {
                      "$ref": "#/components/schemas/ApiEnvelope"
                    },
                    {
                      "properties": {
                        "data": {
                          "items": {
                            "$ref": "#/components/schemas/FolderSearchResultDto"
                          },
                          "type": "array"
                        }
                      },
                      "required": [
                        "data"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": ""
          },
          "400": {
            "$ref": "#/components/responses/ApiErrorInvalidRequest"
          },
          "401": {
            "$ref": "#/components/responses/ApiErrorAuth"
          },
          "403": {
            "$ref": "#/components/responses/ApiErrorForbidden"
          },
          "404": {
            "$ref": "#/components/responses/ApiErrorNotFound"
          },
          "429": {
            "$ref": "#/components/responses/ApiErrorRateLimit"
          },
          "500": {
            "$ref": "#/components/responses/ApiErrorServer"
          }
        },
        "security": [
          {
            "bearer": []
          },
          {
            "api-key": []
          }
        ],
        "summary": "Busca carpetas",
        "tags": [
          "Collections"
        ],
        "x-scope": "collections:read"
      }
    },
    "/workspaces/{workspaceId}/functions": {
      "get": {
        "externalDocs": {
          "description": "Guía: Funciones y flujos",
          "url": "https://developers.meteor.com.co/guias/funciones-y-flujos.html"
        },
        "operationId": "FunctionsController_list",
        "parameters": [
          {
            "description": "ID numérico del workspace. Debe ser el mismo workspace de tu API key: pedir otro devuelve 401.",
            "in": "path",
            "name": "workspaceId",
            "required": true,
            "schema": {
              "type": "number"
            }
          }
        ],
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "allOf": [
                    {
                      "$ref": "#/components/schemas/ApiEnvelope"
                    },
                    {
                      "properties": {
                        "data": {
                          "$ref": "#/components/schemas/FunctionListResponseDto"
                        }
                      },
                      "required": [
                        "data"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": ""
          },
          "400": {
            "$ref": "#/components/responses/ApiErrorInvalidRequest"
          },
          "401": {
            "$ref": "#/components/responses/ApiErrorAuth"
          },
          "403": {
            "$ref": "#/components/responses/ApiErrorForbidden"
          },
          "404": {
            "$ref": "#/components/responses/ApiErrorNotFound"
          },
          "429": {
            "$ref": "#/components/responses/ApiErrorRateLimit"
          },
          "500": {
            "$ref": "#/components/responses/ApiErrorServer"
          }
        },
        "security": [
          {
            "bearer": []
          },
          {
            "api-key": []
          }
        ],
        "summary": "Lista las Funciones IA locales del workspace.",
        "tags": [
          "Functions"
        ],
        "x-scope": "functions:read"
      },
      "post": {
        "externalDocs": {
          "description": "Guía: Funciones y flujos",
          "url": "https://developers.meteor.com.co/guias/funciones-y-flujos.html"
        },
        "operationId": "FunctionsController_create",
        "parameters": [
          {
            "description": "ID numérico del workspace. Debe ser el mismo workspace de tu API key: pedir otro devuelve 401.",
            "in": "path",
            "name": "workspaceId",
            "required": true,
            "schema": {
              "type": "number"
            }
          }
        ],
        "responses": {
          "201": {
            "content": {
              "application/json": {
                "schema": {
                  "allOf": [
                    {
                      "$ref": "#/components/schemas/ApiEnvelope"
                    },
                    {
                      "properties": {
                        "data": {
                          "$ref": "#/components/schemas/FunctionResponseDto"
                        }
                      },
                      "required": [
                        "data"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": ""
          },
          "400": {
            "$ref": "#/components/responses/ApiErrorInvalidRequest"
          },
          "401": {
            "$ref": "#/components/responses/ApiErrorAuth"
          },
          "403": {
            "$ref": "#/components/responses/ApiErrorForbidden"
          },
          "404": {
            "$ref": "#/components/responses/ApiErrorNotFound"
          },
          "409": {
            "$ref": "#/components/responses/ApiErrorConflict"
          },
          "429": {
            "$ref": "#/components/responses/ApiErrorRateLimit"
          },
          "500": {
            "$ref": "#/components/responses/ApiErrorServer"
          }
        },
        "security": [
          {
            "bearer": []
          },
          {
            "api-key": []
          }
        ],
        "summary": "Crea una Función IA.",
        "tags": [
          "Functions"
        ],
        "x-scope": "functions:write"
      }
    },
    "/workspaces/{workspaceId}/functions/{functionId}": {
      "delete": {
        "externalDocs": {
          "description": "Guía: Funciones y flujos",
          "url": "https://developers.meteor.com.co/guias/funciones-y-flujos.html"
        },
        "operationId": "FunctionsController_remove",
        "parameters": [
          {
            "description": "ID de la función.",
            "in": "path",
            "name": "functionId",
            "required": true,
            "schema": {
              "type": "number"
            }
          }
        ],
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "allOf": [
                    {
                      "$ref": "#/components/schemas/ApiEnvelope"
                    },
                    {
                      "properties": {
                        "data": {
                          "$ref": "#/components/schemas/FunctionDeleteResponseDto"
                        }
                      },
                      "required": [
                        "data"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": ""
          },
          "400": {
            "$ref": "#/components/responses/ApiErrorInvalidRequest"
          },
          "401": {
            "$ref": "#/components/responses/ApiErrorAuth"
          },
          "403": {
            "$ref": "#/components/responses/ApiErrorForbidden"
          },
          "404": {
            "$ref": "#/components/responses/ApiErrorNotFound"
          },
          "409": {
            "$ref": "#/components/responses/ApiErrorConflict"
          },
          "429": {
            "$ref": "#/components/responses/ApiErrorRateLimit"
          },
          "500": {
            "$ref": "#/components/responses/ApiErrorServer"
          }
        },
        "security": [
          {
            "bearer": []
          },
          {
            "api-key": []
          }
        ],
        "summary": "Borra una Función IA y la desvincula de todos los Mets.",
        "tags": [
          "Functions"
        ],
        "x-scope": "functions:write"
      },
      "get": {
        "externalDocs": {
          "description": "Guía: Funciones y flujos",
          "url": "https://developers.meteor.com.co/guias/funciones-y-flujos.html"
        },
        "operationId": "FunctionsController_get",
        "parameters": [
          {
            "description": "ID de la función.",
            "in": "path",
            "name": "functionId",
            "required": true,
            "schema": {
              "type": "number"
            }
          }
        ],
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "allOf": [
                    {
                      "$ref": "#/components/schemas/ApiEnvelope"
                    },
                    {
                      "properties": {
                        "data": {
                          "$ref": "#/components/schemas/FunctionResponseDto"
                        }
                      },
                      "required": [
                        "data"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": ""
          },
          "400": {
            "$ref": "#/components/responses/ApiErrorInvalidRequest"
          },
          "401": {
            "$ref": "#/components/responses/ApiErrorAuth"
          },
          "403": {
            "$ref": "#/components/responses/ApiErrorForbidden"
          },
          "404": {
            "$ref": "#/components/responses/ApiErrorNotFound"
          },
          "429": {
            "$ref": "#/components/responses/ApiErrorRateLimit"
          },
          "500": {
            "$ref": "#/components/responses/ApiErrorServer"
          }
        },
        "security": [
          {
            "bearer": []
          },
          {
            "api-key": []
          }
        ],
        "summary": "Detalle de una Función IA.",
        "tags": [
          "Functions"
        ],
        "x-scope": "functions:read"
      },
      "put": {
        "externalDocs": {
          "description": "Guía: Funciones y flujos",
          "url": "https://developers.meteor.com.co/guias/funciones-y-flujos.html"
        },
        "operationId": "FunctionsController_update",
        "parameters": [
          {
            "description": "ID de la función.",
            "in": "path",
            "name": "functionId",
            "required": true,
            "schema": {
              "type": "number"
            }
          }
        ],
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "allOf": [
                    {
                      "$ref": "#/components/schemas/ApiEnvelope"
                    },
                    {
                      "properties": {
                        "data": {
                          "$ref": "#/components/schemas/FunctionResponseDto"
                        }
                      },
                      "required": [
                        "data"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": ""
          },
          "400": {
            "$ref": "#/components/responses/ApiErrorInvalidRequest"
          },
          "401": {
            "$ref": "#/components/responses/ApiErrorAuth"
          },
          "403": {
            "$ref": "#/components/responses/ApiErrorForbidden"
          },
          "404": {
            "$ref": "#/components/responses/ApiErrorNotFound"
          },
          "409": {
            "$ref": "#/components/responses/ApiErrorConflict"
          },
          "429": {
            "$ref": "#/components/responses/ApiErrorRateLimit"
          },
          "500": {
            "$ref": "#/components/responses/ApiErrorServer"
          }
        },
        "security": [
          {
            "bearer": []
          },
          {
            "api-key": []
          }
        ],
        "summary": "Actualiza una Función IA.",
        "tags": [
          "Functions"
        ],
        "x-scope": "functions:write"
      }
    },
    "/workspaces/{workspaceId}/handover": {
      "post": {
        "externalDocs": {
          "description": "Guía: Aprovisionamiento de cuentas",
          "url": "https://developers.meteor.com.co/guias/aprovisionamiento.html"
        },
        "operationId": "ApiProvisioningController_handover",
        "parameters": [
          {
            "description": "ID numérico del workspace. Debe ser el mismo workspace de tu API key: pedir otro devuelve 401.",
            "in": "path",
            "name": "workspaceId",
            "required": true,
            "schema": {
              "type": "number"
            }
          }
        ],
        "responses": {
          "201": {
            "description": ""
          },
          "400": {
            "$ref": "#/components/responses/ApiErrorInvalidRequest"
          },
          "401": {
            "$ref": "#/components/responses/ApiErrorAuth"
          },
          "403": {
            "$ref": "#/components/responses/ApiErrorForbidden"
          },
          "404": {
            "$ref": "#/components/responses/ApiErrorNotFound"
          },
          "409": {
            "$ref": "#/components/responses/ApiErrorConflict"
          },
          "429": {
            "$ref": "#/components/responses/ApiErrorRateLimit"
          },
          "500": {
            "$ref": "#/components/responses/ApiErrorServer"
          }
        },
        "security": [
          {
            "bearer": []
          },
          {
            "api-key": []
          }
        ],
        "summary": "Suelta una cuenta que gestionas: pasa a pagarla el cliente con su propia tarjeta.",
        "tags": [
          "Provisioning"
        ],
        "x-scope": "workspaces:provision"
      }
    },
    "/workspaces/{workspaceId}/images/edit": {
      "post": {
        "externalDocs": {
          "description": "Guía: Imágenes",
          "url": "https://developers.meteor.com.co/guias/imagenes.html"
        },
        "operationId": "ImagesController_edit",
        "parameters": [
          {
            "description": "ID numérico del workspace. Debe ser el mismo workspace de tu API key: pedir otro devuelve 401.",
            "in": "path",
            "name": "workspaceId",
            "required": true,
            "schema": {
              "type": "number"
            }
          }
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/EditImageDto"
              }
            }
          },
          "required": true
        },
        "responses": {
          "201": {
            "content": {
              "application/json": {
                "schema": {
                  "allOf": [
                    {
                      "$ref": "#/components/schemas/ApiEnvelope"
                    },
                    {
                      "properties": {
                        "data": {
                          "$ref": "#/components/schemas/ImageResultDto"
                        }
                      },
                      "required": [
                        "data"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": ""
          },
          "400": {
            "$ref": "#/components/responses/ApiErrorInvalidRequest"
          },
          "401": {
            "$ref": "#/components/responses/ApiErrorAuth"
          },
          "403": {
            "$ref": "#/components/responses/ApiErrorForbidden"
          },
          "404": {
            "$ref": "#/components/responses/ApiErrorNotFound"
          },
          "409": {
            "$ref": "#/components/responses/ApiErrorConflict"
          },
          "429": {
            "$ref": "#/components/responses/ApiErrorRateLimit"
          },
          "500": {
            "$ref": "#/components/responses/ApiErrorServer"
          }
        },
        "security": [
          {
            "bearer": []
          },
          {
            "api-key": []
          }
        ],
        "summary": "Edita/transforma una imagen existente siguiendo el prompt",
        "tags": [
          "Images"
        ],
        "x-scope": "integrations:execute"
      }
    },
    "/workspaces/{workspaceId}/images/generate": {
      "post": {
        "externalDocs": {
          "description": "Guía: Imágenes",
          "url": "https://developers.meteor.com.co/guias/imagenes.html"
        },
        "operationId": "ImagesController_generate",
        "parameters": [
          {
            "description": "ID numérico del workspace. Debe ser el mismo workspace de tu API key: pedir otro devuelve 401.",
            "in": "path",
            "name": "workspaceId",
            "required": true,
            "schema": {
              "type": "number"
            }
          }
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/GenerateImageDto"
              }
            }
          },
          "required": true
        },
        "responses": {
          "201": {
            "content": {
              "application/json": {
                "schema": {
                  "allOf": [
                    {
                      "$ref": "#/components/schemas/ApiEnvelope"
                    },
                    {
                      "properties": {
                        "data": {
                          "$ref": "#/components/schemas/ImageResultDto"
                        }
                      },
                      "required": [
                        "data"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": ""
          },
          "400": {
            "$ref": "#/components/responses/ApiErrorInvalidRequest"
          },
          "401": {
            "$ref": "#/components/responses/ApiErrorAuth"
          },
          "403": {
            "$ref": "#/components/responses/ApiErrorForbidden"
          },
          "404": {
            "$ref": "#/components/responses/ApiErrorNotFound"
          },
          "409": {
            "$ref": "#/components/responses/ApiErrorConflict"
          },
          "429": {
            "$ref": "#/components/responses/ApiErrorRateLimit"
          },
          "500": {
            "$ref": "#/components/responses/ApiErrorServer"
          }
        },
        "security": [
          {
            "bearer": []
          },
          {
            "api-key": []
          }
        ],
        "summary": "Genera una imagen desde un prompt (handler de imágenes activo del workspace)",
        "tags": [
          "Images"
        ],
        "x-scope": "integrations:execute"
      }
    },
    "/workspaces/{workspaceId}/images/video": {
      "post": {
        "externalDocs": {
          "description": "Guía: Imágenes",
          "url": "https://developers.meteor.com.co/guias/imagenes.html"
        },
        "operationId": "ImagesController_video",
        "parameters": [
          {
            "description": "ID numérico del workspace. Debe ser el mismo workspace de tu API key: pedir otro devuelve 401.",
            "in": "path",
            "name": "workspaceId",
            "required": true,
            "schema": {
              "type": "number"
            }
          }
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/GenerateVideoDto"
              }
            }
          },
          "required": true
        },
        "responses": {
          "201": {
            "content": {
              "application/json": {
                "schema": {
                  "allOf": [
                    {
                      "$ref": "#/components/schemas/ApiEnvelope"
                    },
                    {
                      "properties": {
                        "data": {
                          "$ref": "#/components/schemas/VideoResultDto"
                        }
                      },
                      "required": [
                        "data"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": ""
          },
          "400": {
            "$ref": "#/components/responses/ApiErrorInvalidRequest"
          },
          "401": {
            "$ref": "#/components/responses/ApiErrorAuth"
          },
          "403": {
            "$ref": "#/components/responses/ApiErrorForbidden"
          },
          "404": {
            "$ref": "#/components/responses/ApiErrorNotFound"
          },
          "409": {
            "$ref": "#/components/responses/ApiErrorConflict"
          },
          "429": {
            "$ref": "#/components/responses/ApiErrorRateLimit"
          },
          "500": {
            "$ref": "#/components/responses/ApiErrorServer"
          }
        },
        "security": [
          {
            "bearer": []
          },
          {
            "api-key": []
          }
        ],
        "summary": "Genera un video desde un prompt (y opcionalmente un primer frame)",
        "tags": [
          "Images"
        ],
        "x-scope": "integrations:execute"
      }
    },
    "/workspaces/{workspaceId}/integrations": {
      "get": {
        "externalDocs": {
          "description": "Guía: Integraciones MCP",
          "url": "https://developers.meteor.com.co/guias/integraciones-mcp.html"
        },
        "operationId": "ApiIntegrationsController_list",
        "parameters": [
          {
            "description": "ID numérico del workspace. Debe ser el mismo workspace de tu API key: pedir otro devuelve 401.",
            "in": "path",
            "name": "workspaceId",
            "required": true,
            "schema": {
              "type": "number"
            }
          }
        ],
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "allOf": [
                    {
                      "$ref": "#/components/schemas/ApiEnvelope"
                    },
                    {
                      "properties": {
                        "data": {
                          "items": {
                            "$ref": "#/components/schemas/IntegrationResponseDto"
                          },
                          "type": "array"
                        }
                      },
                      "required": [
                        "data"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": ""
          },
          "400": {
            "$ref": "#/components/responses/ApiErrorInvalidRequest"
          },
          "401": {
            "$ref": "#/components/responses/ApiErrorAuth"
          },
          "403": {
            "$ref": "#/components/responses/ApiErrorForbidden"
          },
          "404": {
            "$ref": "#/components/responses/ApiErrorNotFound"
          },
          "429": {
            "$ref": "#/components/responses/ApiErrorRateLimit"
          },
          "500": {
            "$ref": "#/components/responses/ApiErrorServer"
          }
        },
        "security": [
          {
            "bearer": []
          },
          {
            "api-key": []
          }
        ],
        "summary": "Lista integraciones y su estado (sin credenciales)",
        "tags": [
          "Integrations"
        ],
        "x-scope": "integrations:read"
      },
      "post": {
        "externalDocs": {
          "description": "Guía: Integraciones MCP",
          "url": "https://developers.meteor.com.co/guias/integraciones-mcp.html"
        },
        "operationId": "ApiIntegrationsController_register",
        "parameters": [
          {
            "description": "ID numérico del workspace. Debe ser el mismo workspace de tu API key: pedir otro devuelve 401.",
            "in": "path",
            "name": "workspaceId",
            "required": true,
            "schema": {
              "type": "number"
            }
          }
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/RegisterIntegrationDto"
              }
            }
          },
          "required": true
        },
        "responses": {
          "201": {
            "content": {
              "application/json": {
                "schema": {
                  "allOf": [
                    {
                      "$ref": "#/components/schemas/ApiEnvelope"
                    },
                    {
                      "properties": {
                        "data": {
                          "$ref": "#/components/schemas/IntegrationRegisteredResponseDto"
                        }
                      },
                      "required": [
                        "data"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": ""
          },
          "400": {
            "$ref": "#/components/responses/ApiErrorInvalidRequest"
          },
          "401": {
            "$ref": "#/components/responses/ApiErrorAuth"
          },
          "403": {
            "$ref": "#/components/responses/ApiErrorForbidden"
          },
          "404": {
            "$ref": "#/components/responses/ApiErrorNotFound"
          },
          "409": {
            "$ref": "#/components/responses/ApiErrorConflict"
          },
          "429": {
            "$ref": "#/components/responses/ApiErrorRateLimit"
          },
          "500": {
            "$ref": "#/components/responses/ApiErrorServer"
          }
        },
        "security": [
          {
            "bearer": []
          },
          {
            "api-key": []
          }
        ],
        "summary": "Registra un servidor MCP HTTP propio del workspace (self-service)",
        "tags": [
          "Integrations"
        ],
        "x-scope": "integrations:manage"
      }
    },
    "/workspaces/{workspaceId}/integrations/{key}": {
      "delete": {
        "externalDocs": {
          "description": "Guía: Integraciones MCP",
          "url": "https://developers.meteor.com.co/guias/integraciones-mcp.html"
        },
        "operationId": "ApiIntegrationsController_deactivate",
        "parameters": [
          {
            "description": "ID numérico del workspace. Debe ser el mismo workspace de tu API key: pedir otro devuelve 401.",
            "in": "path",
            "name": "workspaceId",
            "required": true,
            "schema": {
              "type": "number"
            }
          },
          {
            "description": "Clave del recurso: identificador estable, no su ID numérico.",
            "in": "path",
            "name": "key",
            "required": true,
            "schema": {
              "type": "string"
            }
          }
        ],
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "allOf": [
                    {
                      "$ref": "#/components/schemas/ApiEnvelope"
                    },
                    {
                      "properties": {
                        "data": {
                          "$ref": "#/components/schemas/IntegrationDeactivatedResponseDto"
                        }
                      },
                      "required": [
                        "data"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": ""
          },
          "400": {
            "$ref": "#/components/responses/ApiErrorInvalidRequest"
          },
          "401": {
            "$ref": "#/components/responses/ApiErrorAuth"
          },
          "403": {
            "$ref": "#/components/responses/ApiErrorForbidden"
          },
          "404": {
            "$ref": "#/components/responses/ApiErrorNotFound"
          },
          "409": {
            "$ref": "#/components/responses/ApiErrorConflict"
          },
          "429": {
            "$ref": "#/components/responses/ApiErrorRateLimit"
          },
          "500": {
            "$ref": "#/components/responses/ApiErrorServer"
          }
        },
        "security": [
          {
            "bearer": []
          },
          {
            "api-key": []
          }
        ],
        "summary": "Desactiva una integración",
        "tags": [
          "Integrations"
        ],
        "x-scope": "integrations:manage"
      }
    },
    "/workspaces/{workspaceId}/integrations/{key}/activate": {
      "post": {
        "externalDocs": {
          "description": "Guía: Integraciones MCP",
          "url": "https://developers.meteor.com.co/guias/integraciones-mcp.html"
        },
        "operationId": "ApiIntegrationsController_activate",
        "parameters": [
          {
            "description": "ID numérico del workspace. Debe ser el mismo workspace de tu API key: pedir otro devuelve 401.",
            "in": "path",
            "name": "workspaceId",
            "required": true,
            "schema": {
              "type": "number"
            }
          },
          {
            "description": "Clave del recurso: identificador estable, no su ID numérico.",
            "in": "path",
            "name": "key",
            "required": true,
            "schema": {
              "type": "string"
            }
          }
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/ActivateIntegrationDto"
              }
            }
          },
          "required": true
        },
        "responses": {
          "201": {
            "content": {
              "application/json": {
                "schema": {
                  "allOf": [
                    {
                      "$ref": "#/components/schemas/ApiEnvelope"
                    },
                    {
                      "properties": {
                        "data": {
                          "$ref": "#/components/schemas/IntegrationActivatedResponseDto"
                        }
                      },
                      "required": [
                        "data"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": ""
          },
          "400": {
            "$ref": "#/components/responses/ApiErrorInvalidRequest"
          },
          "401": {
            "$ref": "#/components/responses/ApiErrorAuth"
          },
          "403": {
            "$ref": "#/components/responses/ApiErrorForbidden"
          },
          "404": {
            "$ref": "#/components/responses/ApiErrorNotFound"
          },
          "409": {
            "$ref": "#/components/responses/ApiErrorConflict"
          },
          "429": {
            "$ref": "#/components/responses/ApiErrorRateLimit"
          },
          "500": {
            "$ref": "#/components/responses/ApiErrorServer"
          }
        },
        "security": [
          {
            "bearer": []
          },
          {
            "api-key": []
          }
        ],
        "summary": "Activa una integración (credenciales write-only)",
        "tags": [
          "Integrations"
        ],
        "x-scope": "integrations:manage"
      }
    },
    "/workspaces/{workspaceId}/integrations/{key}/tools": {
      "get": {
        "externalDocs": {
          "description": "Guía: Integraciones MCP",
          "url": "https://developers.meteor.com.co/guias/integraciones-mcp.html"
        },
        "operationId": "ApiIntegrationsController_tools",
        "parameters": [
          {
            "description": "ID numérico del workspace. Debe ser el mismo workspace de tu API key: pedir otro devuelve 401.",
            "in": "path",
            "name": "workspaceId",
            "required": true,
            "schema": {
              "type": "number"
            }
          },
          {
            "description": "Clave del recurso: identificador estable, no su ID numérico.",
            "in": "path",
            "name": "key",
            "required": true,
            "schema": {
              "type": "string"
            }
          }
        ],
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "allOf": [
                    {
                      "$ref": "#/components/schemas/ApiEnvelope"
                    },
                    {
                      "properties": {
                        "data": {
                          "items": {
                            "$ref": "#/components/schemas/IntegrationToolResponseDto"
                          },
                          "type": "array"
                        }
                      },
                      "required": [
                        "data"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": ""
          },
          "400": {
            "$ref": "#/components/responses/ApiErrorInvalidRequest"
          },
          "401": {
            "$ref": "#/components/responses/ApiErrorAuth"
          },
          "403": {
            "$ref": "#/components/responses/ApiErrorForbidden"
          },
          "404": {
            "$ref": "#/components/responses/ApiErrorNotFound"
          },
          "429": {
            "$ref": "#/components/responses/ApiErrorRateLimit"
          },
          "500": {
            "$ref": "#/components/responses/ApiErrorServer"
          }
        },
        "security": [
          {
            "bearer": []
          },
          {
            "api-key": []
          }
        ],
        "summary": "Lista las tools de una integración",
        "tags": [
          "Integrations"
        ],
        "x-scope": "integrations:read"
      }
    },
    "/workspaces/{workspaceId}/integrations/{key}/tools/{tool}": {
      "post": {
        "externalDocs": {
          "description": "Guía: Integraciones MCP",
          "url": "https://developers.meteor.com.co/guias/integraciones-mcp.html"
        },
        "operationId": "ApiIntegrationsController_execute",
        "parameters": [
          {
            "description": "ID numérico del workspace. Debe ser el mismo workspace de tu API key: pedir otro devuelve 401.",
            "in": "path",
            "name": "workspaceId",
            "required": true,
            "schema": {
              "type": "number"
            }
          },
          {
            "description": "Clave del recurso: identificador estable, no su ID numérico.",
            "in": "path",
            "name": "key",
            "required": true,
            "schema": {
              "type": "string"
            }
          },
          {
            "description": "Nombre de la tool.",
            "in": "path",
            "name": "tool",
            "required": true,
            "schema": {
              "type": "string"
            }
          }
        ],
        "responses": {
          "201": {
            "content": {
              "application/json": {
                "schema": {
                  "allOf": [
                    {
                      "$ref": "#/components/schemas/ApiEnvelope"
                    },
                    {
                      "properties": {
                        "data": {
                          "$ref": "#/components/schemas/IntegrationToolExecutionResponseDto"
                        }
                      },
                      "required": [
                        "data"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": ""
          },
          "400": {
            "$ref": "#/components/responses/ApiErrorInvalidRequest"
          },
          "401": {
            "$ref": "#/components/responses/ApiErrorAuth"
          },
          "403": {
            "$ref": "#/components/responses/ApiErrorForbidden"
          },
          "404": {
            "$ref": "#/components/responses/ApiErrorNotFound"
          },
          "409": {
            "$ref": "#/components/responses/ApiErrorConflict"
          },
          "429": {
            "$ref": "#/components/responses/ApiErrorRateLimit"
          },
          "500": {
            "$ref": "#/components/responses/ApiErrorServer"
          }
        },
        "security": [
          {
            "bearer": []
          },
          {
            "api-key": []
          }
        ],
        "summary": "Ejecuta una tool de la integración",
        "tags": [
          "Integrations"
        ],
        "x-scope": "integrations:execute"
      }
    },
    "/workspaces/{workspaceId}/items": {
      "post": {
        "externalDocs": {
          "description": "Guía: Datos: colecciones e ítems",
          "url": "https://developers.meteor.com.co/guias/colecciones-e-items.html"
        },
        "operationId": "ItemsController_createOrphan",
        "parameters": [
          {
            "description": "ID numérico del workspace. Debe ser el mismo workspace de tu API key: pedir otro devuelve 401.",
            "in": "path",
            "name": "workspaceId",
            "required": true,
            "schema": {
              "type": "number"
            }
          }
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/CreateItemDto"
              }
            }
          },
          "required": true
        },
        "responses": {
          "201": {
            "content": {
              "application/json": {
                "schema": {
                  "allOf": [
                    {
                      "$ref": "#/components/schemas/ApiEnvelope"
                    },
                    {
                      "properties": {
                        "data": {
                          "$ref": "#/components/schemas/ItemResponseDto"
                        }
                      },
                      "required": [
                        "data"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": ""
          },
          "400": {
            "$ref": "#/components/responses/ApiErrorInvalidRequest"
          },
          "401": {
            "$ref": "#/components/responses/ApiErrorAuth"
          },
          "403": {
            "$ref": "#/components/responses/ApiErrorForbidden"
          },
          "404": {
            "$ref": "#/components/responses/ApiErrorNotFound"
          },
          "409": {
            "$ref": "#/components/responses/ApiErrorConflict"
          },
          "429": {
            "$ref": "#/components/responses/ApiErrorRateLimit"
          },
          "500": {
            "$ref": "#/components/responses/ApiErrorServer"
          }
        },
        "security": [
          {
            "bearer": []
          },
          {
            "api-key": []
          }
        ],
        "summary": "Crea un item huérfano en el workspace",
        "tags": [
          "Items"
        ],
        "x-scope": "items:write"
      }
    },
    "/workspaces/{workspaceId}/items/search": {
      "get": {
        "externalDocs": {
          "description": "Guía: Datos: colecciones e ítems",
          "url": "https://developers.meteor.com.co/guias/colecciones-e-items.html"
        },
        "operationId": "ItemsController_searchByWorkspace",
        "parameters": [
          {
            "description": "ID numérico del workspace. Debe ser el mismo workspace de tu API key: pedir otro devuelve 401.",
            "in": "path",
            "name": "workspaceId",
            "required": true,
            "schema": {
              "type": "number"
            }
          },
          {
            "description": "Texto a buscar.",
            "in": "query",
            "name": "q",
            "required": true,
            "schema": {
              "type": "string"
            }
          },
          {
            "description": "Cuántos resultados traer por página.",
            "in": "query",
            "name": "limit",
            "required": true,
            "schema": {
              "type": "number"
            }
          },
          {
            "description": "Número de página, empezando en 1.",
            "in": "query",
            "name": "page",
            "required": true,
            "schema": {
              "type": "number"
            }
          },
          {
            "description": "Excluye los resultados de esta colección.",
            "in": "query",
            "name": "exclude_collection_code",
            "required": true,
            "schema": {
              "type": "string"
            }
          },
          {
            "description": "Filtra por colección.",
            "in": "query",
            "name": "collection_id",
            "required": true,
            "schema": {
              "type": "number"
            }
          }
        ],
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "allOf": [
                    {
                      "$ref": "#/components/schemas/ApiEnvelope"
                    },
                    {
                      "properties": {
                        "data": {
                          "items": {
                            "$ref": "#/components/schemas/ItemSearchResultDto"
                          },
                          "type": "array"
                        },
                        "pagination": {
                          "$ref": "#/components/schemas/ItemPaginationDto"
                        }
                      },
                      "required": [
                        "data"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": ""
          },
          "400": {
            "$ref": "#/components/responses/ApiErrorInvalidRequest"
          },
          "401": {
            "$ref": "#/components/responses/ApiErrorAuth"
          },
          "403": {
            "$ref": "#/components/responses/ApiErrorForbidden"
          },
          "404": {
            "$ref": "#/components/responses/ApiErrorNotFound"
          },
          "429": {
            "$ref": "#/components/responses/ApiErrorRateLimit"
          },
          "500": {
            "$ref": "#/components/responses/ApiErrorServer"
          }
        },
        "security": [
          {
            "bearer": []
          },
          {
            "api-key": []
          }
        ],
        "summary": "Busca items en todas las colecciones de un workspace. Lo usa el selector de referencias de item (bloques de contenido, campos de tipo item).",
        "tags": [
          "Items"
        ],
        "x-scope": "items:read"
      }
    },
    "/workspaces/{workspaceId}/marketplace/skills": {
      "get": {
        "externalDocs": {
          "description": "Guía: Skills",
          "url": "https://developers.meteor.com.co/guias/skills.html"
        },
        "operationId": "WorkspaceSkillsController_getMarketplace",
        "parameters": [
          {
            "description": "ID numérico del workspace. Debe ser el mismo workspace de tu API key: pedir otro devuelve 401.",
            "in": "path",
            "name": "workspaceId",
            "required": true,
            "schema": {
              "type": "number"
            }
          }
        ],
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "allOf": [
                    {
                      "$ref": "#/components/schemas/ApiEnvelope"
                    },
                    {
                      "properties": {
                        "data": {
                          "items": {
                            "$ref": "#/components/schemas/MarketplaceSkillDto"
                          },
                          "type": "array"
                        }
                      },
                      "required": [
                        "data"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": ""
          },
          "400": {
            "$ref": "#/components/responses/ApiErrorInvalidRequest"
          },
          "401": {
            "$ref": "#/components/responses/ApiErrorAuth"
          },
          "403": {
            "$ref": "#/components/responses/ApiErrorForbidden"
          },
          "404": {
            "$ref": "#/components/responses/ApiErrorNotFound"
          },
          "429": {
            "$ref": "#/components/responses/ApiErrorRateLimit"
          },
          "500": {
            "$ref": "#/components/responses/ApiErrorServer"
          }
        },
        "security": [
          {
            "bearer": []
          },
          {
            "api-key": []
          }
        ],
        "summary": "Obtiene el marketplace de skills",
        "tags": [
          "Skills"
        ],
        "x-scope": "skills:read"
      }
    },
    "/workspaces/{workspaceId}/recharge": {
      "post": {
        "externalDocs": {
          "description": "Guía: Aprovisionamiento de cuentas",
          "url": "https://developers.meteor.com.co/guias/aprovisionamiento.html"
        },
        "operationId": "ApiProvisioningController_recharge",
        "parameters": [
          {
            "description": "ID numérico del workspace. Debe ser el mismo workspace de tu API key: pedir otro devuelve 401.",
            "in": "path",
            "name": "workspaceId",
            "required": true,
            "schema": {
              "type": "number"
            }
          }
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/RechargeWorkspaceDto"
              }
            }
          },
          "required": true
        },
        "responses": {
          "201": {
            "description": ""
          },
          "400": {
            "$ref": "#/components/responses/ApiErrorInvalidRequest"
          },
          "401": {
            "$ref": "#/components/responses/ApiErrorAuth"
          },
          "403": {
            "$ref": "#/components/responses/ApiErrorForbidden"
          },
          "404": {
            "$ref": "#/components/responses/ApiErrorNotFound"
          },
          "409": {
            "$ref": "#/components/responses/ApiErrorConflict"
          },
          "429": {
            "$ref": "#/components/responses/ApiErrorRateLimit"
          },
          "500": {
            "$ref": "#/components/responses/ApiErrorServer"
          }
        },
        "security": [
          {
            "bearer": []
          },
          {
            "api-key": []
          }
        ],
        "summary": "Abre un checkout para cargar energía a una cuenta que aprovisionaste.",
        "tags": [
          "Provisioning"
        ],
        "x-scope": "workspaces:recharge"
      }
    },
    "/workspaces/{workspaceId}/resolve/{path}": {
      "get": {
        "externalDocs": {
          "description": "Guía: Datos: colecciones e ítems",
          "url": "https://developers.meteor.com.co/guias/colecciones-e-items.html"
        },
        "operationId": "SlugsController_resolvePath",
        "parameters": [
          {
            "description": "ID numérico del workspace. Debe ser el mismo workspace de tu API key: pedir otro devuelve 401.",
            "in": "path",
            "name": "workspaceId",
            "required": true,
            "schema": {
              "type": "number"
            }
          },
          {
            "description": "Ruta del recurso dentro del sitio (sin la barra inicial).",
            "in": "path",
            "name": "path",
            "required": true,
            "schema": {
              "type": "string"
            }
          }
        ],
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "allOf": [
                    {
                      "$ref": "#/components/schemas/ApiEnvelope"
                    },
                    {
                      "properties": {
                        "data": {
                          "oneOf": [
                            {
                              "$ref": "#/components/schemas/ResolvedCollectionDto"
                            },
                            {
                              "$ref": "#/components/schemas/ResolvedPathDto"
                            }
                          ]
                        }
                      },
                      "required": [
                        "data"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": "Una ruta de un tramo (`coleccion`) devuelve la colección; una de dos (`coleccion/item`) devuelve `{collection, item}`. En ambos casos viene la fila completa, con los campos propios del recurso además de los declarados."
          },
          "400": {
            "$ref": "#/components/responses/ApiErrorInvalidRequest"
          },
          "401": {
            "$ref": "#/components/responses/ApiErrorAuth"
          },
          "403": {
            "$ref": "#/components/responses/ApiErrorForbidden"
          },
          "404": {
            "$ref": "#/components/responses/ApiErrorNotFound"
          },
          "429": {
            "$ref": "#/components/responses/ApiErrorRateLimit"
          },
          "500": {
            "$ref": "#/components/responses/ApiErrorServer"
          }
        },
        "security": [
          {
            "bearer": []
          },
          {
            "api-key": []
          }
        ],
        "summary": "Resuelve una ruta a su recurso",
        "tags": [
          "Collections"
        ],
        "x-scope": "collections:read"
      }
    },
    "/workspaces/{workspaceId}/runs": {
      "get": {
        "externalDocs": {
          "description": "Guía: Ejecutar Mets (Runs)",
          "url": "https://developers.meteor.com.co/guias/ejecutar-agentes.html"
        },
        "operationId": "ApiRunsController_list",
        "parameters": [
          {
            "description": "ID numérico del workspace. Debe ser el mismo workspace de tu API key: pedir otro devuelve 401.",
            "in": "path",
            "name": "workspaceId",
            "required": true,
            "schema": {
              "type": "number"
            }
          },
          {
            "description": "Cuántos resultados traer por página.",
            "in": "query",
            "name": "limit",
            "required": true,
            "schema": {
              "type": "string"
            }
          },
          {
            "description": "Cursor de paginación: el ID del último resultado de la página anterior.",
            "in": "query",
            "name": "starting_after",
            "required": true,
            "schema": {
              "type": "string"
            }
          },
          {
            "description": "Filtra por estado.",
            "in": "query",
            "name": "status",
            "required": true,
            "schema": {
              "type": "string"
            }
          },
          {
            "description": "Filtra por conversación.",
            "in": "query",
            "name": "conversation_id",
            "required": true,
            "schema": {
              "type": "string"
            }
          }
        ],
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "allOf": [
                    {
                      "$ref": "#/components/schemas/ApiEnvelope"
                    },
                    {
                      "properties": {
                        "data": {
                          "$ref": "#/components/schemas/RunListResponseDto"
                        }
                      },
                      "required": [
                        "data"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": ""
          },
          "400": {
            "$ref": "#/components/responses/ApiErrorInvalidRequest"
          },
          "401": {
            "$ref": "#/components/responses/ApiErrorAuth"
          },
          "403": {
            "$ref": "#/components/responses/ApiErrorForbidden"
          },
          "404": {
            "$ref": "#/components/responses/ApiErrorNotFound"
          },
          "429": {
            "$ref": "#/components/responses/ApiErrorRateLimit"
          },
          "500": {
            "$ref": "#/components/responses/ApiErrorServer"
          }
        },
        "security": [
          {
            "bearer": []
          },
          {
            "api-key": []
          }
        ],
        "summary": "Historial de Runs del workspace",
        "tags": [
          "Runs"
        ],
        "x-scope": "runs:read"
      },
      "post": {
        "externalDocs": {
          "description": "Guía: Ejecutar Mets (Runs)",
          "url": "https://developers.meteor.com.co/guias/ejecutar-agentes.html"
        },
        "operationId": "ApiRunsController_create",
        "parameters": [
          {
            "description": "ID numérico del workspace. Debe ser el mismo workspace de tu API key: pedir otro devuelve 401.",
            "in": "path",
            "name": "workspaceId",
            "required": true,
            "schema": {
              "type": "number"
            }
          }
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/CreateRunDto"
              }
            }
          },
          "required": true
        },
        "responses": {
          "201": {
            "content": {
              "application/json": {
                "schema": {
                  "allOf": [
                    {
                      "$ref": "#/components/schemas/ApiEnvelope"
                    },
                    {
                      "properties": {
                        "data": {
                          "$ref": "#/components/schemas/RunResponseDto"
                        }
                      },
                      "required": [
                        "data"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": ""
          },
          "400": {
            "$ref": "#/components/responses/ApiErrorInvalidRequest"
          },
          "401": {
            "$ref": "#/components/responses/ApiErrorAuth"
          },
          "403": {
            "$ref": "#/components/responses/ApiErrorForbidden"
          },
          "404": {
            "$ref": "#/components/responses/ApiErrorNotFound"
          },
          "409": {
            "$ref": "#/components/responses/ApiErrorConflict"
          },
          "429": {
            "$ref": "#/components/responses/ApiErrorRateLimit"
          },
          "500": {
            "$ref": "#/components/responses/ApiErrorServer"
          }
        },
        "security": [
          {
            "bearer": []
          },
          {
            "api-key": []
          }
        ],
        "summary": "Ejecuta un Met (agente) del workspace",
        "tags": [
          "Runs"
        ],
        "x-scope": "runs:execute"
      }
    },
    "/workspaces/{workspaceId}/skills/active": {
      "get": {
        "externalDocs": {
          "description": "Guía: Skills",
          "url": "https://developers.meteor.com.co/guias/skills.html"
        },
        "operationId": "WorkspaceSkillsController_getActive",
        "parameters": [
          {
            "description": "ID numérico del workspace. Debe ser el mismo workspace de tu API key: pedir otro devuelve 401.",
            "in": "path",
            "name": "workspaceId",
            "required": true,
            "schema": {
              "type": "number"
            }
          }
        ],
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "allOf": [
                    {
                      "$ref": "#/components/schemas/ApiEnvelope"
                    },
                    {
                      "properties": {
                        "data": {
                          "items": {
                            "$ref": "#/components/schemas/WorkspaceSkillConfigDto"
                          },
                          "type": "array"
                        }
                      },
                      "required": [
                        "data"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": ""
          },
          "400": {
            "$ref": "#/components/responses/ApiErrorInvalidRequest"
          },
          "401": {
            "$ref": "#/components/responses/ApiErrorAuth"
          },
          "403": {
            "$ref": "#/components/responses/ApiErrorForbidden"
          },
          "404": {
            "$ref": "#/components/responses/ApiErrorNotFound"
          },
          "429": {
            "$ref": "#/components/responses/ApiErrorRateLimit"
          },
          "500": {
            "$ref": "#/components/responses/ApiErrorServer"
          }
        },
        "security": [
          {
            "bearer": []
          },
          {
            "api-key": []
          }
        ],
        "summary": "Obtiene las skills activas del workspace",
        "tags": [
          "Skills"
        ],
        "x-scope": "skills:read"
      }
    },
    "/workspaces/{workspaceId}/skills/status": {
      "get": {
        "externalDocs": {
          "description": "Guía: Skills",
          "url": "https://developers.meteor.com.co/guias/skills.html"
        },
        "operationId": "AgentSkillsController_getWorkspaceSkillsStatus",
        "parameters": [
          {
            "description": "ID numérico del workspace. Debe ser el mismo workspace de tu API key: pedir otro devuelve 401.",
            "in": "path",
            "name": "workspaceId",
            "required": true,
            "schema": {
              "type": "number"
            }
          }
        ],
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "allOf": [
                    {
                      "$ref": "#/components/schemas/ApiEnvelope"
                    },
                    {
                      "properties": {
                        "data": {
                          "$ref": "#/components/schemas/WorkspaceSkillsStatusResponseDto"
                        }
                      },
                      "required": [
                        "data"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": ""
          },
          "400": {
            "$ref": "#/components/responses/ApiErrorInvalidRequest"
          },
          "401": {
            "$ref": "#/components/responses/ApiErrorAuth"
          },
          "403": {
            "$ref": "#/components/responses/ApiErrorForbidden"
          },
          "404": {
            "$ref": "#/components/responses/ApiErrorNotFound"
          },
          "429": {
            "$ref": "#/components/responses/ApiErrorRateLimit"
          },
          "500": {
            "$ref": "#/components/responses/ApiErrorServer"
          }
        },
        "security": [
          {
            "bearer": []
          },
          {
            "api-key": []
          }
        ],
        "summary": "Estado derivado de TODAS las skills locales del workspace en una sola pasada — usado por MetsModule para pintar el badge \"pendiente de configuración\" y para separar habilidades activas (>=1 Met vinculado) de copias huérfanas.",
        "tags": [
          "Skills"
        ],
        "x-scope": "skills:read"
      }
    },
    "/workspaces/{workspaceId}/skills/{skillId}": {
      "delete": {
        "externalDocs": {
          "description": "Guía: Skills",
          "url": "https://developers.meteor.com.co/guias/skills.html"
        },
        "operationId": "AgentSkillsController_removeWorkspaceSkill",
        "parameters": [
          {
            "description": "ID numérico del workspace. Debe ser el mismo workspace de tu API key: pedir otro devuelve 401.",
            "in": "path",
            "name": "workspaceId",
            "required": true,
            "schema": {
              "type": "number"
            }
          },
          {
            "description": "ID de la skill.",
            "in": "path",
            "name": "skillId",
            "required": true,
            "schema": {
              "type": "number"
            }
          }
        ],
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "allOf": [
                    {
                      "$ref": "#/components/schemas/ApiEnvelope"
                    },
                    {
                      "properties": {
                        "data": {
                          "$ref": "#/components/schemas/RemoveWorkspaceSkillResponseDto"
                        }
                      },
                      "required": [
                        "data"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": ""
          },
          "400": {
            "$ref": "#/components/responses/ApiErrorInvalidRequest"
          },
          "401": {
            "$ref": "#/components/responses/ApiErrorAuth"
          },
          "403": {
            "$ref": "#/components/responses/ApiErrorForbidden"
          },
          "404": {
            "$ref": "#/components/responses/ApiErrorNotFound"
          },
          "409": {
            "$ref": "#/components/responses/ApiErrorConflict"
          },
          "429": {
            "$ref": "#/components/responses/ApiErrorRateLimit"
          },
          "500": {
            "$ref": "#/components/responses/ApiErrorServer"
          }
        },
        "security": [
          {
            "bearer": []
          },
          {
            "api-key": []
          }
        ],
        "summary": "Desconecta una habilidad del workspace: elimina los item_links agent_skill que la usen y borra la copia local. Solo aplica a skills locales del workspace (no a templates globales).",
        "tags": [
          "Skills"
        ],
        "x-scope": "skills:manage"
      }
    },
    "/workspaces/{workspaceId}/skills/{skillId}/activate": {
      "post": {
        "externalDocs": {
          "description": "Guía: Skills",
          "url": "https://developers.meteor.com.co/guias/skills.html"
        },
        "operationId": "WorkspaceSkillsController_activate",
        "parameters": [
          {
            "description": "ID numérico del workspace. Debe ser el mismo workspace de tu API key: pedir otro devuelve 401.",
            "in": "path",
            "name": "workspaceId",
            "required": true,
            "schema": {
              "type": "number"
            }
          },
          {
            "description": "ID de la skill.",
            "in": "path",
            "name": "skillId",
            "required": true,
            "schema": {
              "type": "string"
            }
          }
        ],
        "responses": {
          "201": {
            "content": {
              "application/json": {
                "schema": {
                  "allOf": [
                    {
                      "$ref": "#/components/schemas/ApiEnvelope"
                    },
                    {
                      "properties": {
                        "data": {
                          "$ref": "#/components/schemas/WorkspaceSkillConfigDto"
                        }
                      },
                      "required": [
                        "data"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": ""
          },
          "400": {
            "$ref": "#/components/responses/ApiErrorInvalidRequest"
          },
          "401": {
            "$ref": "#/components/responses/ApiErrorAuth"
          },
          "403": {
            "$ref": "#/components/responses/ApiErrorForbidden"
          },
          "404": {
            "$ref": "#/components/responses/ApiErrorNotFound"
          },
          "409": {
            "$ref": "#/components/responses/ApiErrorConflict"
          },
          "429": {
            "$ref": "#/components/responses/ApiErrorRateLimit"
          },
          "500": {
            "$ref": "#/components/responses/ApiErrorServer"
          }
        },
        "security": [
          {
            "bearer": []
          },
          {
            "api-key": []
          }
        ],
        "summary": "Activa una skill del workspace",
        "tags": [
          "Skills"
        ],
        "x-scope": "skills:manage"
      }
    },
    "/workspaces/{workspaceId}/skills/{skillId}/credentials": {
      "put": {
        "externalDocs": {
          "description": "Guía: Skills",
          "url": "https://developers.meteor.com.co/guias/skills.html"
        },
        "operationId": "WorkspaceSkillsController_updateCredentials",
        "parameters": [
          {
            "description": "ID numérico del workspace. Debe ser el mismo workspace de tu API key: pedir otro devuelve 401.",
            "in": "path",
            "name": "workspaceId",
            "required": true,
            "schema": {
              "type": "number"
            }
          },
          {
            "description": "ID de la skill.",
            "in": "path",
            "name": "skillId",
            "required": true,
            "schema": {
              "type": "string"
            }
          }
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/UpdateSkillCredentialsDto"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "allOf": [
                    {
                      "$ref": "#/components/schemas/ApiEnvelope"
                    },
                    {
                      "properties": {
                        "data": {
                          "$ref": "#/components/schemas/WorkspaceSkillConfigDto"
                        }
                      },
                      "required": [
                        "data"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": ""
          },
          "400": {
            "$ref": "#/components/responses/ApiErrorInvalidRequest"
          },
          "401": {
            "$ref": "#/components/responses/ApiErrorAuth"
          },
          "403": {
            "$ref": "#/components/responses/ApiErrorForbidden"
          },
          "404": {
            "$ref": "#/components/responses/ApiErrorNotFound"
          },
          "409": {
            "$ref": "#/components/responses/ApiErrorConflict"
          },
          "429": {
            "$ref": "#/components/responses/ApiErrorRateLimit"
          },
          "500": {
            "$ref": "#/components/responses/ApiErrorServer"
          }
        },
        "security": [
          {
            "bearer": []
          },
          {
            "api-key": []
          }
        ],
        "summary": "Actualiza las credenciales de la skill",
        "tags": [
          "Skills"
        ],
        "x-scope": "skills:manage"
      }
    },
    "/workspaces/{workspaceId}/skills/{skillId}/deactivate": {
      "post": {
        "externalDocs": {
          "description": "Guía: Skills",
          "url": "https://developers.meteor.com.co/guias/skills.html"
        },
        "operationId": "WorkspaceSkillsController_deactivate",
        "parameters": [
          {
            "description": "ID numérico del workspace. Debe ser el mismo workspace de tu API key: pedir otro devuelve 401.",
            "in": "path",
            "name": "workspaceId",
            "required": true,
            "schema": {
              "type": "number"
            }
          },
          {
            "description": "ID de la skill.",
            "in": "path",
            "name": "skillId",
            "required": true,
            "schema": {
              "type": "string"
            }
          }
        ],
        "responses": {
          "201": {
            "content": {
              "application/json": {
                "schema": {
                  "allOf": [
                    {
                      "$ref": "#/components/schemas/ApiEnvelope"
                    },
                    {
                      "properties": {
                        "data": {
                          "$ref": "#/components/schemas/WorkspaceSkillConfigDto"
                        }
                      },
                      "required": [
                        "data"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": ""
          },
          "400": {
            "$ref": "#/components/responses/ApiErrorInvalidRequest"
          },
          "401": {
            "$ref": "#/components/responses/ApiErrorAuth"
          },
          "403": {
            "$ref": "#/components/responses/ApiErrorForbidden"
          },
          "404": {
            "$ref": "#/components/responses/ApiErrorNotFound"
          },
          "409": {
            "$ref": "#/components/responses/ApiErrorConflict"
          },
          "429": {
            "$ref": "#/components/responses/ApiErrorRateLimit"
          },
          "500": {
            "$ref": "#/components/responses/ApiErrorServer"
          }
        },
        "security": [
          {
            "bearer": []
          },
          {
            "api-key": []
          }
        ],
        "summary": "Desactiva una skill del workspace",
        "tags": [
          "Skills"
        ],
        "x-scope": "skills:manage"
      }
    },
    "/workspaces/{workspaceId}/skills/{skillId}/mcps": {
      "get": {
        "externalDocs": {
          "description": "Guía: Skills",
          "url": "https://developers.meteor.com.co/guias/skills.html"
        },
        "operationId": "AgentSkillsController_listSkillMcps",
        "parameters": [
          {
            "description": "ID de la skill.",
            "in": "path",
            "name": "skillId",
            "required": true,
            "schema": {
              "type": "number"
            }
          }
        ],
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "allOf": [
                    {
                      "$ref": "#/components/schemas/ApiEnvelope"
                    },
                    {
                      "properties": {
                        "data": {
                          "$ref": "#/components/schemas/SkillMcpsResponseDto"
                        }
                      },
                      "required": [
                        "data"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": ""
          },
          "400": {
            "$ref": "#/components/responses/ApiErrorInvalidRequest"
          },
          "401": {
            "$ref": "#/components/responses/ApiErrorAuth"
          },
          "403": {
            "$ref": "#/components/responses/ApiErrorForbidden"
          },
          "404": {
            "$ref": "#/components/responses/ApiErrorNotFound"
          },
          "429": {
            "$ref": "#/components/responses/ApiErrorRateLimit"
          },
          "500": {
            "$ref": "#/components/responses/ApiErrorServer"
          }
        },
        "security": [
          {
            "bearer": []
          },
          {
            "api-key": []
          }
        ],
        "summary": "MCPs vinculados a una skill con su config (native_handler, requires_credentials, connected) y las tools que exponen — para el sub-tab \"Tools\" del detalle de habilidad. Resuelve conexión con fallback por native_handler.",
        "tags": [
          "Skills"
        ],
        "x-scope": "skills:read"
      },
      "put": {
        "externalDocs": {
          "description": "Guía: Skills",
          "url": "https://developers.meteor.com.co/guias/skills.html"
        },
        "operationId": "AgentSkillsController_setMcps",
        "parameters": [
          {
            "description": "ID de la skill.",
            "in": "path",
            "name": "skillId",
            "required": true,
            "schema": {
              "type": "number"
            }
          }
        ],
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "allOf": [
                    {
                      "$ref": "#/components/schemas/ApiEnvelope"
                    },
                    {
                      "properties": {
                        "data": {
                          "$ref": "#/components/schemas/SetSkillMcpsResponseDto"
                        }
                      },
                      "required": [
                        "data"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": ""
          },
          "400": {
            "$ref": "#/components/responses/ApiErrorInvalidRequest"
          },
          "401": {
            "$ref": "#/components/responses/ApiErrorAuth"
          },
          "403": {
            "$ref": "#/components/responses/ApiErrorForbidden"
          },
          "404": {
            "$ref": "#/components/responses/ApiErrorNotFound"
          },
          "409": {
            "$ref": "#/components/responses/ApiErrorConflict"
          },
          "429": {
            "$ref": "#/components/responses/ApiErrorRateLimit"
          },
          "500": {
            "$ref": "#/components/responses/ApiErrorServer"
          }
        },
        "security": [
          {
            "bearer": []
          },
          {
            "api-key": []
          }
        ],
        "summary": "Reemplaza la lista de MCPs que usa una skill",
        "tags": [
          "Skills"
        ],
        "x-scope": "skills:manage"
      }
    },
    "/workspaces/{workspaceId}/skills/{skillId}/mcps/{mcpId}": {
      "delete": {
        "externalDocs": {
          "description": "Guía: Skills",
          "url": "https://developers.meteor.com.co/guias/skills.html"
        },
        "operationId": "AgentSkillsController_removeMcp",
        "parameters": [
          {
            "description": "ID de la skill.",
            "in": "path",
            "name": "skillId",
            "required": true,
            "schema": {
              "type": "number"
            }
          },
          {
            "description": "ID de la integración MCP.",
            "in": "path",
            "name": "mcpId",
            "required": true,
            "schema": {
              "type": "string"
            }
          }
        ],
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "allOf": [
                    {
                      "$ref": "#/components/schemas/ApiEnvelope"
                    },
                    {
                      "properties": {
                        "data": {
                          "$ref": "#/components/schemas/SkillOkResponseDto"
                        }
                      },
                      "required": [
                        "data"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": ""
          },
          "400": {
            "$ref": "#/components/responses/ApiErrorInvalidRequest"
          },
          "401": {
            "$ref": "#/components/responses/ApiErrorAuth"
          },
          "403": {
            "$ref": "#/components/responses/ApiErrorForbidden"
          },
          "404": {
            "$ref": "#/components/responses/ApiErrorNotFound"
          },
          "409": {
            "$ref": "#/components/responses/ApiErrorConflict"
          },
          "429": {
            "$ref": "#/components/responses/ApiErrorRateLimit"
          },
          "500": {
            "$ref": "#/components/responses/ApiErrorServer"
          }
        },
        "security": [
          {
            "bearer": []
          },
          {
            "api-key": []
          }
        ],
        "summary": "Elimina un MCP de una skill",
        "tags": [
          "Skills"
        ],
        "x-scope": "skills:manage"
      },
      "put": {
        "externalDocs": {
          "description": "Guía: Skills",
          "url": "https://developers.meteor.com.co/guias/skills.html"
        },
        "operationId": "AgentSkillsController_upsertMcp",
        "parameters": [
          {
            "description": "ID de la skill.",
            "in": "path",
            "name": "skillId",
            "required": true,
            "schema": {
              "type": "number"
            }
          },
          {
            "description": "ID de la integración MCP.",
            "in": "path",
            "name": "mcpId",
            "required": true,
            "schema": {
              "type": "string"
            }
          }
        ],
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "allOf": [
                    {
                      "$ref": "#/components/schemas/ApiEnvelope"
                    },
                    {
                      "properties": {
                        "data": {
                          "$ref": "#/components/schemas/SkillMcpRefDto"
                        }
                      },
                      "required": [
                        "data"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": ""
          },
          "400": {
            "$ref": "#/components/responses/ApiErrorInvalidRequest"
          },
          "401": {
            "$ref": "#/components/responses/ApiErrorAuth"
          },
          "403": {
            "$ref": "#/components/responses/ApiErrorForbidden"
          },
          "404": {
            "$ref": "#/components/responses/ApiErrorNotFound"
          },
          "409": {
            "$ref": "#/components/responses/ApiErrorConflict"
          },
          "429": {
            "$ref": "#/components/responses/ApiErrorRateLimit"
          },
          "500": {
            "$ref": "#/components/responses/ApiErrorServer"
          }
        },
        "security": [
          {
            "bearer": []
          },
          {
            "api-key": []
          }
        ],
        "summary": "Inserta o actualiza un MCP dentro de una skill (con subconjunto opcional de `enabled_tools`)",
        "tags": [
          "Skills"
        ],
        "x-scope": "skills:manage"
      }
    },
    "/workspaces/{workspaceId}/skills/{skillId}/status": {
      "get": {
        "externalDocs": {
          "description": "Guía: Skills",
          "url": "https://developers.meteor.com.co/guias/skills.html"
        },
        "operationId": "AgentSkillsController_getSkillStatus",
        "parameters": [
          {
            "description": "ID de la skill.",
            "in": "path",
            "name": "skillId",
            "required": true,
            "schema": {
              "type": "number"
            }
          }
        ],
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "allOf": [
                    {
                      "$ref": "#/components/schemas/ApiEnvelope"
                    },
                    {
                      "properties": {
                        "data": {
                          "$ref": "#/components/schemas/SkillStatusResponseDto"
                        }
                      },
                      "required": [
                        "data"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": ""
          },
          "400": {
            "$ref": "#/components/responses/ApiErrorInvalidRequest"
          },
          "401": {
            "$ref": "#/components/responses/ApiErrorAuth"
          },
          "403": {
            "$ref": "#/components/responses/ApiErrorForbidden"
          },
          "404": {
            "$ref": "#/components/responses/ApiErrorNotFound"
          },
          "429": {
            "$ref": "#/components/responses/ApiErrorRateLimit"
          },
          "500": {
            "$ref": "#/components/responses/ApiErrorServer"
          }
        },
        "security": [
          {
            "bearer": []
          },
          {
            "api-key": []
          }
        ],
        "summary": "Estado derivado (active | pending_credentials | inactive) de una skill puntual para el workspace actual. Usado por el header del detalle y por el refresh tras guardar credenciales.",
        "tags": [
          "Skills"
        ],
        "x-scope": "skills:read"
      }
    },
    "/workspaces/{workspaceId}/skills/{skillId}/test": {
      "post": {
        "externalDocs": {
          "description": "Guía: Skills",
          "url": "https://developers.meteor.com.co/guias/skills.html"
        },
        "operationId": "WorkspaceSkillsController_test",
        "parameters": [
          {
            "description": "ID numérico del workspace. Debe ser el mismo workspace de tu API key: pedir otro devuelve 401.",
            "in": "path",
            "name": "workspaceId",
            "required": true,
            "schema": {
              "type": "number"
            }
          },
          {
            "description": "ID de la skill.",
            "in": "path",
            "name": "skillId",
            "required": true,
            "schema": {
              "type": "string"
            }
          }
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/TestSkillDto"
              }
            }
          },
          "required": true
        },
        "responses": {
          "201": {
            "content": {
              "application/json": {
                "schema": {
                  "allOf": [
                    {
                      "$ref": "#/components/schemas/ApiEnvelope"
                    },
                    {
                      "properties": {
                        "data": {
                          "$ref": "#/components/schemas/SkillTestResultDto"
                        }
                      },
                      "required": [
                        "data"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": ""
          },
          "400": {
            "$ref": "#/components/responses/ApiErrorInvalidRequest"
          },
          "401": {
            "$ref": "#/components/responses/ApiErrorAuth"
          },
          "403": {
            "$ref": "#/components/responses/ApiErrorForbidden"
          },
          "404": {
            "$ref": "#/components/responses/ApiErrorNotFound"
          },
          "409": {
            "$ref": "#/components/responses/ApiErrorConflict"
          },
          "429": {
            "$ref": "#/components/responses/ApiErrorRateLimit"
          },
          "500": {
            "$ref": "#/components/responses/ApiErrorServer"
          }
        },
        "security": [
          {
            "bearer": []
          },
          {
            "api-key": []
          }
        ],
        "summary": "Prueba una skill del workspace",
        "tags": [
          "Skills"
        ],
        "x-scope": "skills:manage"
      }
    },
    "/workspaces/{workspaceId}/snapshot-catalog": {
      "get": {
        "externalDocs": {
          "description": "Guía: Plantillas (Snapshots)",
          "url": "https://developers.meteor.com.co/guias/snapshots.html"
        },
        "operationId": "SnapshotCatalogController_list",
        "parameters": [
          {
            "description": "Filtra por vertical de negocio (por ejemplo `inmobiliaria`, `retail`).",
            "in": "query",
            "name": "vertical",
            "required": true,
            "schema": {
              "type": "string"
            }
          }
        ],
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "allOf": [
                    {
                      "$ref": "#/components/schemas/ApiEnvelope"
                    },
                    {
                      "properties": {
                        "data": {
                          "items": {
                            "$ref": "#/components/schemas/SnapshotCatalogItemDto"
                          },
                          "type": "array"
                        }
                      },
                      "required": [
                        "data"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": ""
          },
          "400": {
            "$ref": "#/components/responses/ApiErrorInvalidRequest"
          },
          "401": {
            "$ref": "#/components/responses/ApiErrorAuth"
          },
          "403": {
            "$ref": "#/components/responses/ApiErrorForbidden"
          },
          "404": {
            "$ref": "#/components/responses/ApiErrorNotFound"
          },
          "429": {
            "$ref": "#/components/responses/ApiErrorRateLimit"
          },
          "500": {
            "$ref": "#/components/responses/ApiErrorServer"
          }
        },
        "security": [
          {
            "bearer": []
          },
          {
            "api-key": []
          }
        ],
        "summary": "Listar las plantillas publicadas en el marketplace",
        "tags": [
          "Snapshots"
        ],
        "x-scope": "snapshots:read"
      }
    },
    "/workspaces/{workspaceId}/snapshot-catalog/{slug}": {
      "get": {
        "externalDocs": {
          "description": "Guía: Plantillas (Snapshots)",
          "url": "https://developers.meteor.com.co/guias/snapshots.html"
        },
        "operationId": "SnapshotCatalogController_item",
        "parameters": [
          {
            "description": "Identificador legible del recurso (en minúsculas y con guiones).",
            "in": "path",
            "name": "slug",
            "required": true,
            "schema": {
              "type": "string"
            }
          }
        ],
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "allOf": [
                    {
                      "$ref": "#/components/schemas/ApiEnvelope"
                    },
                    {
                      "properties": {
                        "data": {
                          "$ref": "#/components/schemas/SnapshotCatalogDetailDto"
                        }
                      },
                      "required": [
                        "data"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": ""
          },
          "400": {
            "$ref": "#/components/responses/ApiErrorInvalidRequest"
          },
          "401": {
            "$ref": "#/components/responses/ApiErrorAuth"
          },
          "403": {
            "$ref": "#/components/responses/ApiErrorForbidden"
          },
          "404": {
            "$ref": "#/components/responses/ApiErrorNotFound"
          },
          "429": {
            "$ref": "#/components/responses/ApiErrorRateLimit"
          },
          "500": {
            "$ref": "#/components/responses/ApiErrorServer"
          }
        },
        "security": [
          {
            "bearer": []
          },
          {
            "api-key": []
          }
        ],
        "summary": "Ficha de una plantilla (incluye/requiere/guía parcial)",
        "tags": [
          "Snapshots"
        ],
        "x-scope": "snapshots:read"
      }
    },
    "/workspaces/{workspaceId}/snapshot-catalog/{snapshotId}/claim": {
      "post": {
        "externalDocs": {
          "description": "Guía: Plantillas (Snapshots)",
          "url": "https://developers.meteor.com.co/guias/snapshots.html"
        },
        "operationId": "SnapshotCatalogController_claim",
        "parameters": [
          {
            "description": "ID numérico del workspace. Debe ser el mismo workspace de tu API key: pedir otro devuelve 401.",
            "in": "path",
            "name": "workspaceId",
            "required": true,
            "schema": {
              "type": "number"
            }
          },
          {
            "description": "UUID de la plantilla (Snapshot).",
            "in": "path",
            "name": "snapshotId",
            "required": true,
            "schema": {
              "type": "string"
            }
          }
        ],
        "responses": {
          "201": {
            "content": {
              "application/json": {
                "schema": {
                  "allOf": [
                    {
                      "$ref": "#/components/schemas/ApiEnvelope"
                    },
                    {
                      "properties": {
                        "data": {
                          "$ref": "#/components/schemas/SnapshotEntitlementDto"
                        }
                      },
                      "required": [
                        "data"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": ""
          },
          "400": {
            "$ref": "#/components/responses/ApiErrorInvalidRequest"
          },
          "401": {
            "$ref": "#/components/responses/ApiErrorAuth"
          },
          "403": {
            "$ref": "#/components/responses/ApiErrorForbidden"
          },
          "404": {
            "$ref": "#/components/responses/ApiErrorNotFound"
          },
          "409": {
            "$ref": "#/components/responses/ApiErrorConflict"
          },
          "429": {
            "$ref": "#/components/responses/ApiErrorRateLimit"
          },
          "500": {
            "$ref": "#/components/responses/ApiErrorServer"
          }
        },
        "security": [
          {
            "bearer": []
          },
          {
            "api-key": []
          }
        ],
        "summary": "Reclamar acceso gratuito (crea el entitlement)",
        "tags": [
          "Snapshots"
        ],
        "x-scope": "snapshots:install"
      }
    },
    "/workspaces/{workspaceId}/snapshots/{snapshotId}/install": {
      "post": {
        "externalDocs": {
          "description": "Guía: Plantillas (Snapshots)",
          "url": "https://developers.meteor.com.co/guias/snapshots.html"
        },
        "operationId": "SnapshotsController_install",
        "parameters": [
          {
            "description": "ID numérico del workspace. Debe ser el mismo workspace de tu API key: pedir otro devuelve 401.",
            "in": "path",
            "name": "workspaceId",
            "required": true,
            "schema": {
              "type": "number"
            }
          },
          {
            "description": "UUID de la plantilla (Snapshot).",
            "in": "path",
            "name": "snapshotId",
            "required": true,
            "schema": {
              "type": "string"
            }
          }
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/InstallSnapshotDto"
              }
            }
          },
          "required": true
        },
        "responses": {
          "201": {
            "content": {
              "application/json": {
                "schema": {
                  "allOf": [
                    {
                      "$ref": "#/components/schemas/ApiEnvelope"
                    },
                    {
                      "properties": {
                        "data": {
                          "$ref": "#/components/schemas/SnapshotInstallStartedDto"
                        }
                      },
                      "required": [
                        "data"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": ""
          },
          "400": {
            "$ref": "#/components/responses/ApiErrorInvalidRequest"
          },
          "401": {
            "$ref": "#/components/responses/ApiErrorAuth"
          },
          "403": {
            "$ref": "#/components/responses/ApiErrorForbidden"
          },
          "404": {
            "$ref": "#/components/responses/ApiErrorNotFound"
          },
          "409": {
            "$ref": "#/components/responses/ApiErrorConflict"
          },
          "429": {
            "$ref": "#/components/responses/ApiErrorRateLimit"
          },
          "500": {
            "$ref": "#/components/responses/ApiErrorServer"
          }
        },
        "security": [
          {
            "bearer": []
          },
          {
            "api-key": []
          }
        ],
        "summary": "Instalar la última versión del snapshot en este workspace",
        "tags": [
          "Snapshots"
        ],
        "x-scope": "snapshots:install"
      }
    },
    "/workspaces/{workspaceId}/snapshots/{snapshotId}/submit": {
      "post": {
        "externalDocs": {
          "description": "Guía: Plantillas (Snapshots)",
          "url": "https://developers.meteor.com.co/guias/snapshots.html"
        },
        "operationId": "SnapshotsController_submit",
        "parameters": [
          {
            "description": "ID numérico del workspace. Debe ser el mismo workspace de tu API key: pedir otro devuelve 401.",
            "in": "path",
            "name": "workspaceId",
            "required": true,
            "schema": {
              "type": "number"
            }
          },
          {
            "description": "UUID de la plantilla (Snapshot).",
            "in": "path",
            "name": "snapshotId",
            "required": true,
            "schema": {
              "type": "string"
            }
          }
        ],
        "responses": {
          "201": {
            "content": {
              "application/json": {
                "schema": {
                  "allOf": [
                    {
                      "$ref": "#/components/schemas/ApiEnvelope"
                    },
                    {
                      "properties": {
                        "data": {
                          "$ref": "#/components/schemas/SnapshotSubmittedDto"
                        }
                      },
                      "required": [
                        "data"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": ""
          },
          "400": {
            "$ref": "#/components/responses/ApiErrorInvalidRequest"
          },
          "401": {
            "$ref": "#/components/responses/ApiErrorAuth"
          },
          "403": {
            "$ref": "#/components/responses/ApiErrorForbidden"
          },
          "404": {
            "$ref": "#/components/responses/ApiErrorNotFound"
          },
          "409": {
            "$ref": "#/components/responses/ApiErrorConflict"
          },
          "429": {
            "$ref": "#/components/responses/ApiErrorRateLimit"
          },
          "500": {
            "$ref": "#/components/responses/ApiErrorServer"
          }
        },
        "security": [
          {
            "bearer": []
          },
          {
            "api-key": []
          }
        ],
        "summary": "Enviar el snapshot a revisión editorial",
        "tags": [
          "Snapshots"
        ],
        "x-scope": "snapshots:publish"
      }
    },
    "/workspaces/{workspaceId}/subscription": {
      "post": {
        "externalDocs": {
          "description": "Guía: Aprovisionamiento de cuentas",
          "url": "https://developers.meteor.com.co/guias/aprovisionamiento.html"
        },
        "operationId": "ApiProvisioningController_upgrade",
        "parameters": [
          {
            "description": "ID numérico del workspace. Debe ser el mismo workspace de tu API key: pedir otro devuelve 401.",
            "in": "path",
            "name": "workspaceId",
            "required": true,
            "schema": {
              "type": "number"
            }
          }
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/UpgradeWorkspaceDto"
              }
            }
          },
          "required": true
        },
        "responses": {
          "201": {
            "description": ""
          },
          "400": {
            "$ref": "#/components/responses/ApiErrorInvalidRequest"
          },
          "401": {
            "$ref": "#/components/responses/ApiErrorAuth"
          },
          "403": {
            "$ref": "#/components/responses/ApiErrorForbidden"
          },
          "404": {
            "$ref": "#/components/responses/ApiErrorNotFound"
          },
          "409": {
            "$ref": "#/components/responses/ApiErrorConflict"
          },
          "429": {
            "$ref": "#/components/responses/ApiErrorRateLimit"
          },
          "500": {
            "$ref": "#/components/responses/ApiErrorServer"
          }
        },
        "security": [
          {
            "bearer": []
          },
          {
            "api-key": []
          }
        ],
        "summary": "Pasa una cuenta que aprovisionaste a un plan comercial, cobrado a tu medio de pago.",
        "tags": [
          "Provisioning"
        ],
        "x-scope": "workspaces:provision"
      }
    },
    "/workspaces/{workspaceId}/system-skills": {
      "get": {
        "externalDocs": {
          "description": "Guía: Skills",
          "url": "https://developers.meteor.com.co/guias/skills.html"
        },
        "operationId": "WorkspaceSkillsController_getSystemSkills",
        "parameters": [
          {
            "description": "ID numérico del workspace. Debe ser el mismo workspace de tu API key: pedir otro devuelve 401.",
            "in": "path",
            "name": "workspaceId",
            "required": true,
            "schema": {
              "type": "number"
            }
          }
        ],
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "allOf": [
                    {
                      "$ref": "#/components/schemas/ApiEnvelope"
                    },
                    {
                      "properties": {
                        "data": {
                          "items": {
                            "$ref": "#/components/schemas/WorkspaceSkillItemDto"
                          },
                          "type": "array"
                        }
                      },
                      "required": [
                        "data"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": ""
          },
          "400": {
            "$ref": "#/components/responses/ApiErrorInvalidRequest"
          },
          "401": {
            "$ref": "#/components/responses/ApiErrorAuth"
          },
          "403": {
            "$ref": "#/components/responses/ApiErrorForbidden"
          },
          "404": {
            "$ref": "#/components/responses/ApiErrorNotFound"
          },
          "429": {
            "$ref": "#/components/responses/ApiErrorRateLimit"
          },
          "500": {
            "$ref": "#/components/responses/ApiErrorServer"
          }
        },
        "security": [
          {
            "bearer": []
          },
          {
            "api-key": []
          }
        ],
        "summary": "Obtiene las skills del sistema",
        "tags": [
          "Skills"
        ],
        "x-scope": "skills:read"
      }
    },
    "/workspaces/{workspaceId}/task-views": {
      "get": {
        "description": "Solo las vistas que creó el workspace, ordenadas por `position`. Las vistas de fábrica (\"Asignadas a mí\", \"Recurrentes\", …) viven en la aplicación y no salen acá.",
        "externalDocs": {
          "description": "Guía: Tareas",
          "url": "https://developers.meteor.com.co/guias/tareas.html"
        },
        "operationId": "TaskViewsController_list",
        "parameters": [
          {
            "description": "ID numérico del workspace. Debe ser el mismo workspace de tu API key: pedir otro devuelve 401.",
            "in": "path",
            "name": "workspaceId",
            "required": true,
            "schema": {
              "type": "number"
            }
          }
        ],
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "allOf": [
                    {
                      "$ref": "#/components/schemas/ApiEnvelope"
                    },
                    {
                      "properties": {
                        "data": {
                          "items": {
                            "$ref": "#/components/schemas/TaskViewResponseDto"
                          },
                          "type": "array"
                        }
                      },
                      "required": [
                        "data"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": ""
          },
          "400": {
            "$ref": "#/components/responses/ApiErrorInvalidRequest"
          },
          "401": {
            "$ref": "#/components/responses/ApiErrorAuth"
          },
          "403": {
            "$ref": "#/components/responses/ApiErrorForbidden"
          },
          "404": {
            "$ref": "#/components/responses/ApiErrorNotFound"
          },
          "429": {
            "$ref": "#/components/responses/ApiErrorRateLimit"
          },
          "500": {
            "$ref": "#/components/responses/ApiErrorServer"
          }
        },
        "security": [
          {
            "bearer": []
          },
          {
            "api-key": []
          }
        ],
        "summary": "Lista las vistas de tareas personalizadas de un workspace",
        "tags": [
          "Tasks"
        ],
        "x-scope": "tasks:read"
      },
      "post": {
        "description": "Queda al final de las pestañas: `position` se asigna sola.",
        "externalDocs": {
          "description": "Guía: Tareas",
          "url": "https://developers.meteor.com.co/guias/tareas.html"
        },
        "operationId": "TaskViewsController_create",
        "parameters": [
          {
            "description": "ID numérico del workspace. Debe ser el mismo workspace de tu API key: pedir otro devuelve 401.",
            "in": "path",
            "name": "workspaceId",
            "required": true,
            "schema": {
              "type": "number"
            }
          }
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/CreateTaskViewDto"
              }
            }
          },
          "required": true
        },
        "responses": {
          "201": {
            "content": {
              "application/json": {
                "schema": {
                  "allOf": [
                    {
                      "$ref": "#/components/schemas/ApiEnvelope"
                    },
                    {
                      "properties": {
                        "data": {
                          "$ref": "#/components/schemas/TaskViewResponseDto"
                        }
                      },
                      "required": [
                        "data"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": ""
          },
          "400": {
            "$ref": "#/components/responses/ApiErrorInvalidRequest"
          },
          "401": {
            "$ref": "#/components/responses/ApiErrorAuth"
          },
          "403": {
            "$ref": "#/components/responses/ApiErrorForbidden"
          },
          "404": {
            "$ref": "#/components/responses/ApiErrorNotFound"
          },
          "409": {
            "$ref": "#/components/responses/ApiErrorConflict"
          },
          "429": {
            "$ref": "#/components/responses/ApiErrorRateLimit"
          },
          "500": {
            "$ref": "#/components/responses/ApiErrorServer"
          }
        },
        "security": [
          {
            "bearer": []
          },
          {
            "api-key": []
          }
        ],
        "summary": "Crea una vista de tareas personalizada",
        "tags": [
          "Tasks"
        ],
        "x-scope": "tasks:write"
      }
    },
    "/workspaces/{workspaceId}/task-views/reorder": {
      "patch": {
        "description": "Devuelve la lista completa ya reordenada. Todas las vistas del cuerpo tienen que existir y pertenecer al workspace, o no se aplica ninguna.",
        "externalDocs": {
          "description": "Guía: Tareas",
          "url": "https://developers.meteor.com.co/guias/tareas.html"
        },
        "operationId": "TaskViewsController_reorder",
        "parameters": [
          {
            "description": "ID numérico del workspace. Debe ser el mismo workspace de tu API key: pedir otro devuelve 401.",
            "in": "path",
            "name": "workspaceId",
            "required": true,
            "schema": {
              "type": "number"
            }
          }
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/ReorderTaskViewsDto"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "allOf": [
                    {
                      "$ref": "#/components/schemas/ApiEnvelope"
                    },
                    {
                      "properties": {
                        "data": {
                          "items": {
                            "$ref": "#/components/schemas/TaskViewResponseDto"
                          },
                          "type": "array"
                        }
                      },
                      "required": [
                        "data"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": ""
          },
          "400": {
            "$ref": "#/components/responses/ApiErrorInvalidRequest"
          },
          "401": {
            "$ref": "#/components/responses/ApiErrorAuth"
          },
          "403": {
            "$ref": "#/components/responses/ApiErrorForbidden"
          },
          "404": {
            "$ref": "#/components/responses/ApiErrorNotFound"
          },
          "409": {
            "$ref": "#/components/responses/ApiErrorConflict"
          },
          "429": {
            "$ref": "#/components/responses/ApiErrorRateLimit"
          },
          "500": {
            "$ref": "#/components/responses/ApiErrorServer"
          }
        },
        "security": [
          {
            "bearer": []
          },
          {
            "api-key": []
          }
        ],
        "summary": "Reordena las vistas de tareas (pestañas arrastrables)",
        "tags": [
          "Tasks"
        ],
        "x-scope": "tasks:write"
      }
    },
    "/workspaces/{workspaceId}/tasks": {
      "get": {
        "description": "Con `contact_id` devuelve solo las tareas de seguimiento de ese contacto del CRM.",
        "externalDocs": {
          "description": "Guía: Tareas",
          "url": "https://developers.meteor.com.co/guias/tareas.html"
        },
        "operationId": "TasksController_findAll",
        "parameters": [
          {
            "description": "ID numérico del workspace. Debe ser el mismo workspace de tu API key: pedir otro devuelve 401.",
            "in": "path",
            "name": "workspaceId",
            "required": true,
            "schema": {
              "type": "number"
            }
          },
          {
            "description": "Filtra por contacto del CRM.",
            "in": "query",
            "name": "contact_id",
            "required": true,
            "schema": {
              "type": "string"
            }
          }
        ],
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "allOf": [
                    {
                      "$ref": "#/components/schemas/ApiEnvelope"
                    },
                    {
                      "properties": {
                        "data": {
                          "items": {
                            "$ref": "#/components/schemas/TaskResponseDto"
                          },
                          "type": "array"
                        }
                      },
                      "required": [
                        "data"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": ""
          },
          "400": {
            "$ref": "#/components/responses/ApiErrorInvalidRequest"
          },
          "401": {
            "$ref": "#/components/responses/ApiErrorAuth"
          },
          "403": {
            "$ref": "#/components/responses/ApiErrorForbidden"
          },
          "404": {
            "$ref": "#/components/responses/ApiErrorNotFound"
          },
          "429": {
            "$ref": "#/components/responses/ApiErrorRateLimit"
          },
          "500": {
            "$ref": "#/components/responses/ApiErrorServer"
          }
        },
        "security": [
          {
            "bearer": []
          },
          {
            "api-key": []
          }
        ],
        "summary": "Lista las tareas del workspace",
        "tags": [
          "Tasks"
        ],
        "x-scope": "tasks:read"
      },
      "post": {
        "externalDocs": {
          "description": "Guía: Tareas",
          "url": "https://developers.meteor.com.co/guias/tareas.html"
        },
        "operationId": "TasksController_create",
        "parameters": [
          {
            "description": "ID numérico del workspace. Debe ser el mismo workspace de tu API key: pedir otro devuelve 401.",
            "in": "path",
            "name": "workspaceId",
            "required": true,
            "schema": {
              "type": "number"
            }
          }
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/CreateTaskDto"
              }
            }
          },
          "required": true
        },
        "responses": {
          "201": {
            "content": {
              "application/json": {
                "schema": {
                  "allOf": [
                    {
                      "$ref": "#/components/schemas/ApiEnvelope"
                    },
                    {
                      "properties": {
                        "data": {
                          "$ref": "#/components/schemas/TaskResponseDto"
                        }
                      },
                      "required": [
                        "data"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": ""
          },
          "400": {
            "$ref": "#/components/responses/ApiErrorInvalidRequest"
          },
          "401": {
            "$ref": "#/components/responses/ApiErrorAuth"
          },
          "403": {
            "$ref": "#/components/responses/ApiErrorForbidden"
          },
          "404": {
            "$ref": "#/components/responses/ApiErrorNotFound"
          },
          "409": {
            "$ref": "#/components/responses/ApiErrorConflict"
          },
          "429": {
            "$ref": "#/components/responses/ApiErrorRateLimit"
          },
          "500": {
            "$ref": "#/components/responses/ApiErrorServer"
          }
        },
        "security": [
          {
            "bearer": []
          },
          {
            "api-key": []
          }
        ],
        "summary": "Crea una tarea",
        "tags": [
          "Tasks"
        ],
        "x-scope": "tasks:write"
      }
    },
    "/workspaces/{workspaceId}/tasks-activity": {
      "get": {
        "description": "Las 100 entradas más recientes de todas las tareas, de la más nueva a la más vieja.",
        "externalDocs": {
          "description": "Guía: Tareas",
          "url": "https://developers.meteor.com.co/guias/tareas.html"
        },
        "operationId": "TasksController_getWorkspaceTasksActivity",
        "parameters": [
          {
            "description": "ID numérico del workspace. Debe ser el mismo workspace de tu API key: pedir otro devuelve 401.",
            "in": "path",
            "name": "workspaceId",
            "required": true,
            "schema": {
              "type": "number"
            }
          }
        ],
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "allOf": [
                    {
                      "$ref": "#/components/schemas/ApiEnvelope"
                    },
                    {
                      "properties": {
                        "data": {
                          "items": {
                            "$ref": "#/components/schemas/TaskActivityResponseDto"
                          },
                          "type": "array"
                        }
                      },
                      "required": [
                        "data"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": ""
          },
          "400": {
            "$ref": "#/components/responses/ApiErrorInvalidRequest"
          },
          "401": {
            "$ref": "#/components/responses/ApiErrorAuth"
          },
          "403": {
            "$ref": "#/components/responses/ApiErrorForbidden"
          },
          "404": {
            "$ref": "#/components/responses/ApiErrorNotFound"
          },
          "429": {
            "$ref": "#/components/responses/ApiErrorRateLimit"
          },
          "500": {
            "$ref": "#/components/responses/ApiErrorServer"
          }
        },
        "security": [
          {
            "bearer": []
          },
          {
            "api-key": []
          }
        ],
        "summary": "Obtiene la actividad de tareas del workspace",
        "tags": [
          "Tasks"
        ],
        "x-scope": "tasks:read"
      }
    },
    "/workspaces/{workspaceId}/threads/{threadId}/messages": {
      "get": {
        "description": "Los 200 mensajes más recientes del hilo, en orden cronológico, más el hilo mismo.",
        "externalDocs": {
          "description": "Guía: Operación del workspace",
          "url": "https://developers.meteor.com.co/guias/operacion-del-workspace.html"
        },
        "operationId": "ChatController_getThreadMessages",
        "parameters": [
          {
            "description": "ID numérico del workspace. Debe ser el mismo workspace de tu API key: pedir otro devuelve 401.",
            "in": "path",
            "name": "workspaceId",
            "required": true,
            "schema": {
              "type": "number"
            }
          },
          {
            "description": "ID del hilo de conversación.",
            "in": "path",
            "name": "threadId",
            "required": true,
            "schema": {
              "type": "number"
            }
          }
        ],
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "allOf": [
                    {
                      "$ref": "#/components/schemas/ApiEnvelope"
                    },
                    {
                      "properties": {
                        "data": {
                          "$ref": "#/components/schemas/ChatThreadMessagesResponseDto"
                        }
                      },
                      "required": [
                        "data"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": ""
          },
          "400": {
            "$ref": "#/components/responses/ApiErrorInvalidRequest"
          },
          "401": {
            "$ref": "#/components/responses/ApiErrorAuth"
          },
          "403": {
            "$ref": "#/components/responses/ApiErrorForbidden"
          },
          "404": {
            "$ref": "#/components/responses/ApiErrorNotFound"
          },
          "429": {
            "$ref": "#/components/responses/ApiErrorRateLimit"
          },
          "500": {
            "$ref": "#/components/responses/ApiErrorServer"
          }
        },
        "security": [
          {
            "bearer": []
          },
          {
            "api-key": []
          }
        ],
        "summary": "Obtiene los mensajes del hilo (gestionados por el orquestador)",
        "tags": [
          "Conversations"
        ],
        "x-scope": "conversations:read"
      }
    },
    "/workspaces/{workspaceId}/webhooks": {
      "get": {
        "externalDocs": {
          "description": "Guía: Webhooks entrantes",
          "url": "https://developers.meteor.com.co/guias/webhooks.html"
        },
        "operationId": "WebhooksController_list",
        "parameters": [
          {
            "description": "ID numérico del workspace. Debe ser el mismo workspace de tu API key: pedir otro devuelve 401.",
            "in": "path",
            "name": "workspaceId",
            "required": true,
            "schema": {
              "type": "number"
            }
          }
        ],
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "allOf": [
                    {
                      "$ref": "#/components/schemas/ApiEnvelope"
                    },
                    {
                      "properties": {
                        "data": {
                          "items": {
                            "$ref": "#/components/schemas/InboundWebhookListItemDto"
                          },
                          "type": "array"
                        }
                      },
                      "required": [
                        "data"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": ""
          },
          "400": {
            "$ref": "#/components/responses/ApiErrorInvalidRequest"
          },
          "401": {
            "$ref": "#/components/responses/ApiErrorAuth"
          },
          "403": {
            "$ref": "#/components/responses/ApiErrorForbidden"
          },
          "404": {
            "$ref": "#/components/responses/ApiErrorNotFound"
          },
          "429": {
            "$ref": "#/components/responses/ApiErrorRateLimit"
          },
          "500": {
            "$ref": "#/components/responses/ApiErrorServer"
          }
        },
        "security": [
          {
            "bearer": []
          },
          {
            "api-key": []
          }
        ],
        "summary": "Lista webhooks entrantes del workspace",
        "tags": [
          "Webhooks"
        ],
        "x-scope": "webhooks:manage"
      },
      "post": {
        "externalDocs": {
          "description": "Guía: Webhooks entrantes",
          "url": "https://developers.meteor.com.co/guias/webhooks.html"
        },
        "operationId": "WebhooksController_create",
        "parameters": [
          {
            "description": "ID numérico del workspace. Debe ser el mismo workspace de tu API key: pedir otro devuelve 401.",
            "in": "path",
            "name": "workspaceId",
            "required": true,
            "schema": {
              "type": "number"
            }
          }
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/CreateWebhookDto"
              }
            }
          },
          "required": true
        },
        "responses": {
          "201": {
            "content": {
              "application/json": {
                "schema": {
                  "allOf": [
                    {
                      "$ref": "#/components/schemas/ApiEnvelope"
                    },
                    {
                      "properties": {
                        "data": {
                          "$ref": "#/components/schemas/InboundWebhookCreatedDto"
                        }
                      },
                      "required": [
                        "data"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": ""
          },
          "400": {
            "$ref": "#/components/responses/ApiErrorInvalidRequest"
          },
          "401": {
            "$ref": "#/components/responses/ApiErrorAuth"
          },
          "403": {
            "$ref": "#/components/responses/ApiErrorForbidden"
          },
          "404": {
            "$ref": "#/components/responses/ApiErrorNotFound"
          },
          "409": {
            "$ref": "#/components/responses/ApiErrorConflict"
          },
          "429": {
            "$ref": "#/components/responses/ApiErrorRateLimit"
          },
          "500": {
            "$ref": "#/components/responses/ApiErrorServer"
          }
        },
        "security": [
          {
            "bearer": []
          },
          {
            "api-key": []
          }
        ],
        "summary": "Crea un webhook entrante libre (binding task/generic)",
        "tags": [
          "Webhooks"
        ],
        "x-scope": "webhooks:manage"
      }
    },
    "/workspaces/{workspaceId}/webhooks/{id}": {
      "delete": {
        "externalDocs": {
          "description": "Guía: Webhooks entrantes",
          "url": "https://developers.meteor.com.co/guias/webhooks.html"
        },
        "operationId": "WebhooksController_remove",
        "parameters": [
          {
            "description": "ID numérico del workspace. Debe ser el mismo workspace de tu API key: pedir otro devuelve 401.",
            "in": "path",
            "name": "workspaceId",
            "required": true,
            "schema": {
              "type": "number"
            }
          },
          {
            "description": "ID del recurso de esta ruta.",
            "in": "path",
            "name": "id",
            "required": true,
            "schema": {
              "type": "number"
            }
          }
        ],
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "allOf": [
                    {
                      "$ref": "#/components/schemas/ApiEnvelope"
                    },
                    {
                      "properties": {
                        "data": {
                          "$ref": "#/components/schemas/WebhookDeletedResponseDto"
                        }
                      },
                      "required": [
                        "data"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": ""
          },
          "400": {
            "$ref": "#/components/responses/ApiErrorInvalidRequest"
          },
          "401": {
            "$ref": "#/components/responses/ApiErrorAuth"
          },
          "403": {
            "$ref": "#/components/responses/ApiErrorForbidden"
          },
          "404": {
            "$ref": "#/components/responses/ApiErrorNotFound"
          },
          "409": {
            "$ref": "#/components/responses/ApiErrorConflict"
          },
          "429": {
            "$ref": "#/components/responses/ApiErrorRateLimit"
          },
          "500": {
            "$ref": "#/components/responses/ApiErrorServer"
          }
        },
        "security": [
          {
            "bearer": []
          },
          {
            "api-key": []
          }
        ],
        "summary": "Elimina un webhook libre. Los de MCP no se borran por acá.",
        "tags": [
          "Webhooks"
        ],
        "x-scope": "webhooks:manage"
      },
      "get": {
        "externalDocs": {
          "description": "Guía: Webhooks entrantes",
          "url": "https://developers.meteor.com.co/guias/webhooks.html"
        },
        "operationId": "WebhooksController_getOne",
        "parameters": [
          {
            "description": "ID numérico del workspace. Debe ser el mismo workspace de tu API key: pedir otro devuelve 401.",
            "in": "path",
            "name": "workspaceId",
            "required": true,
            "schema": {
              "type": "number"
            }
          },
          {
            "description": "ID del recurso de esta ruta.",
            "in": "path",
            "name": "id",
            "required": true,
            "schema": {
              "type": "number"
            }
          }
        ],
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "allOf": [
                    {
                      "$ref": "#/components/schemas/ApiEnvelope"
                    },
                    {
                      "properties": {
                        "data": {
                          "$ref": "#/components/schemas/InboundWebhookDetailDto"
                        }
                      },
                      "required": [
                        "data"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": ""
          },
          "400": {
            "$ref": "#/components/responses/ApiErrorInvalidRequest"
          },
          "401": {
            "$ref": "#/components/responses/ApiErrorAuth"
          },
          "403": {
            "$ref": "#/components/responses/ApiErrorForbidden"
          },
          "404": {
            "$ref": "#/components/responses/ApiErrorNotFound"
          },
          "429": {
            "$ref": "#/components/responses/ApiErrorRateLimit"
          },
          "500": {
            "$ref": "#/components/responses/ApiErrorServer"
          }
        },
        "security": [
          {
            "bearer": []
          },
          {
            "api-key": []
          }
        ],
        "summary": "Detalle de un webhook entrante",
        "tags": [
          "Webhooks"
        ],
        "x-scope": "webhooks:manage"
      },
      "put": {
        "externalDocs": {
          "description": "Guía: Webhooks entrantes",
          "url": "https://developers.meteor.com.co/guias/webhooks.html"
        },
        "operationId": "WebhooksController_update",
        "parameters": [
          {
            "description": "ID numérico del workspace. Debe ser el mismo workspace de tu API key: pedir otro devuelve 401.",
            "in": "path",
            "name": "workspaceId",
            "required": true,
            "schema": {
              "type": "number"
            }
          },
          {
            "description": "ID del recurso de esta ruta.",
            "in": "path",
            "name": "id",
            "required": true,
            "schema": {
              "type": "number"
            }
          }
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/UpdateWebhookDto"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "allOf": [
                    {
                      "$ref": "#/components/schemas/ApiEnvelope"
                    },
                    {
                      "properties": {
                        "data": {
                          "$ref": "#/components/schemas/InboundWebhookDto"
                        }
                      },
                      "required": [
                        "data"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": ""
          },
          "400": {
            "$ref": "#/components/responses/ApiErrorInvalidRequest"
          },
          "401": {
            "$ref": "#/components/responses/ApiErrorAuth"
          },
          "403": {
            "$ref": "#/components/responses/ApiErrorForbidden"
          },
          "404": {
            "$ref": "#/components/responses/ApiErrorNotFound"
          },
          "409": {
            "$ref": "#/components/responses/ApiErrorConflict"
          },
          "429": {
            "$ref": "#/components/responses/ApiErrorRateLimit"
          },
          "500": {
            "$ref": "#/components/responses/ApiErrorServer"
          }
        },
        "security": [
          {
            "bearer": []
          },
          {
            "api-key": []
          }
        ],
        "summary": "Actualiza name/description/enabled del webhook",
        "tags": [
          "Webhooks"
        ],
        "x-scope": "webhooks:manage"
      }
    },
    "/workspaces/{workspaceId}/webhooks/{id}/events": {
      "get": {
        "externalDocs": {
          "description": "Guía: Webhooks entrantes",
          "url": "https://developers.meteor.com.co/guias/webhooks.html"
        },
        "operationId": "WebhooksController_listEvents",
        "parameters": [
          {
            "description": "ID numérico del workspace. Debe ser el mismo workspace de tu API key: pedir otro devuelve 401.",
            "in": "path",
            "name": "workspaceId",
            "required": true,
            "schema": {
              "type": "number"
            }
          },
          {
            "description": "ID del recurso de esta ruta.",
            "in": "path",
            "name": "id",
            "required": true,
            "schema": {
              "type": "number"
            }
          },
          {
            "description": "Cuántos resultados traer por página.",
            "in": "query",
            "name": "limit",
            "required": true,
            "schema": {
              "type": "string"
            }
          }
        ],
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "allOf": [
                    {
                      "$ref": "#/components/schemas/ApiEnvelope"
                    },
                    {
                      "properties": {
                        "data": {
                          "items": {
                            "$ref": "#/components/schemas/WebhookEventDto"
                          },
                          "type": "array"
                        }
                      },
                      "required": [
                        "data"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": ""
          },
          "400": {
            "$ref": "#/components/responses/ApiErrorInvalidRequest"
          },
          "401": {
            "$ref": "#/components/responses/ApiErrorAuth"
          },
          "403": {
            "$ref": "#/components/responses/ApiErrorForbidden"
          },
          "404": {
            "$ref": "#/components/responses/ApiErrorNotFound"
          },
          "429": {
            "$ref": "#/components/responses/ApiErrorRateLimit"
          },
          "500": {
            "$ref": "#/components/responses/ApiErrorServer"
          }
        },
        "security": [
          {
            "bearer": []
          },
          {
            "api-key": []
          }
        ],
        "summary": "Log de eventos recibidos por este webhook (default 50, máx 200)",
        "tags": [
          "Webhooks"
        ],
        "x-scope": "webhooks:manage"
      }
    },
    "/workspaces/{workspaceId}/webhooks/{id}/flow": {
      "delete": {
        "externalDocs": {
          "description": "Guía: Webhooks entrantes",
          "url": "https://developers.meteor.com.co/guias/webhooks.html"
        },
        "operationId": "WebhooksController_disconnectFlow",
        "parameters": [
          {
            "description": "ID numérico del workspace. Debe ser el mismo workspace de tu API key: pedir otro devuelve 401.",
            "in": "path",
            "name": "workspaceId",
            "required": true,
            "schema": {
              "type": "number"
            }
          },
          {
            "description": "ID del recurso de esta ruta.",
            "in": "path",
            "name": "id",
            "required": true,
            "schema": {
              "type": "number"
            }
          }
        ],
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "allOf": [
                    {
                      "$ref": "#/components/schemas/ApiEnvelope"
                    },
                    {
                      "properties": {
                        "data": {
                          "$ref": "#/components/schemas/WebhookConnectedFlowResponseDto"
                        }
                      },
                      "required": [
                        "data"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": ""
          },
          "400": {
            "$ref": "#/components/responses/ApiErrorInvalidRequest"
          },
          "401": {
            "$ref": "#/components/responses/ApiErrorAuth"
          },
          "403": {
            "$ref": "#/components/responses/ApiErrorForbidden"
          },
          "404": {
            "$ref": "#/components/responses/ApiErrorNotFound"
          },
          "409": {
            "$ref": "#/components/responses/ApiErrorConflict"
          },
          "429": {
            "$ref": "#/components/responses/ApiErrorRateLimit"
          },
          "500": {
            "$ref": "#/components/responses/ApiErrorServer"
          }
        },
        "security": [
          {
            "bearer": []
          },
          {
            "api-key": []
          }
        ],
        "summary": "Desconecta el flujo del webhook",
        "tags": [
          "Webhooks"
        ],
        "x-scope": "webhooks:manage"
      },
      "put": {
        "externalDocs": {
          "description": "Guía: Webhooks entrantes",
          "url": "https://developers.meteor.com.co/guias/webhooks.html"
        },
        "operationId": "WebhooksController_connectFlow",
        "parameters": [
          {
            "description": "ID numérico del workspace. Debe ser el mismo workspace de tu API key: pedir otro devuelve 401.",
            "in": "path",
            "name": "workspaceId",
            "required": true,
            "schema": {
              "type": "number"
            }
          },
          {
            "description": "ID del recurso de esta ruta.",
            "in": "path",
            "name": "id",
            "required": true,
            "schema": {
              "type": "number"
            }
          }
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/ConnectFlowDto"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "allOf": [
                    {
                      "$ref": "#/components/schemas/ApiEnvelope"
                    },
                    {
                      "properties": {
                        "data": {
                          "$ref": "#/components/schemas/WebhookConnectedFlowResponseDto"
                        }
                      },
                      "required": [
                        "data"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": ""
          },
          "400": {
            "$ref": "#/components/responses/ApiErrorInvalidRequest"
          },
          "401": {
            "$ref": "#/components/responses/ApiErrorAuth"
          },
          "403": {
            "$ref": "#/components/responses/ApiErrorForbidden"
          },
          "404": {
            "$ref": "#/components/responses/ApiErrorNotFound"
          },
          "409": {
            "$ref": "#/components/responses/ApiErrorConflict"
          },
          "429": {
            "$ref": "#/components/responses/ApiErrorRateLimit"
          },
          "500": {
            "$ref": "#/components/responses/ApiErrorServer"
          }
        },
        "security": [
          {
            "bearer": []
          },
          {
            "api-key": []
          }
        ],
        "summary": "Conecta un flujo al webhook (se ejecuta al recibir un evento)",
        "tags": [
          "Webhooks"
        ],
        "x-scope": "webhooks:manage"
      }
    },
    "/workspaces/{workspaceId}/webhooks/{id}/mappings": {
      "put": {
        "externalDocs": {
          "description": "Guía: Webhooks entrantes",
          "url": "https://developers.meteor.com.co/guias/webhooks.html"
        },
        "operationId": "WebhooksController_updateMappings",
        "parameters": [
          {
            "description": "ID numérico del workspace. Debe ser el mismo workspace de tu API key: pedir otro devuelve 401.",
            "in": "path",
            "name": "workspaceId",
            "required": true,
            "schema": {
              "type": "number"
            }
          },
          {
            "description": "ID del recurso de esta ruta.",
            "in": "path",
            "name": "id",
            "required": true,
            "schema": {
              "type": "number"
            }
          }
        ],
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/UpdateMappingsDto"
              }
            }
          },
          "required": true
        },
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "allOf": [
                    {
                      "$ref": "#/components/schemas/ApiEnvelope"
                    },
                    {
                      "properties": {
                        "data": {
                          "$ref": "#/components/schemas/InboundWebhookDto"
                        }
                      },
                      "required": [
                        "data"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": ""
          },
          "400": {
            "$ref": "#/components/responses/ApiErrorInvalidRequest"
          },
          "401": {
            "$ref": "#/components/responses/ApiErrorAuth"
          },
          "403": {
            "$ref": "#/components/responses/ApiErrorForbidden"
          },
          "404": {
            "$ref": "#/components/responses/ApiErrorNotFound"
          },
          "409": {
            "$ref": "#/components/responses/ApiErrorConflict"
          },
          "429": {
            "$ref": "#/components/responses/ApiErrorRateLimit"
          },
          "500": {
            "$ref": "#/components/responses/ApiErrorServer"
          }
        },
        "security": [
          {
            "bearer": []
          },
          {
            "api-key": []
          }
        ],
        "summary": "Guarda el mapeo de payload → campos del webhook",
        "tags": [
          "Webhooks"
        ],
        "x-scope": "webhooks:manage"
      }
    },
    "/workspaces/{workspaceId}/webhooks/{id}/rotate-secret": {
      "post": {
        "externalDocs": {
          "description": "Guía: Webhooks entrantes",
          "url": "https://developers.meteor.com.co/guias/webhooks.html"
        },
        "operationId": "WebhooksController_rotateSecret",
        "parameters": [
          {
            "description": "ID numérico del workspace. Debe ser el mismo workspace de tu API key: pedir otro devuelve 401.",
            "in": "path",
            "name": "workspaceId",
            "required": true,
            "schema": {
              "type": "number"
            }
          },
          {
            "description": "ID del recurso de esta ruta.",
            "in": "path",
            "name": "id",
            "required": true,
            "schema": {
              "type": "number"
            }
          }
        ],
        "responses": {
          "201": {
            "content": {
              "application/json": {
                "schema": {
                  "allOf": [
                    {
                      "$ref": "#/components/schemas/ApiEnvelope"
                    },
                    {
                      "properties": {
                        "data": {
                          "$ref": "#/components/schemas/WebhookRotatedSecretDto"
                        }
                      },
                      "required": [
                        "data"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": ""
          },
          "400": {
            "$ref": "#/components/responses/ApiErrorInvalidRequest"
          },
          "401": {
            "$ref": "#/components/responses/ApiErrorAuth"
          },
          "403": {
            "$ref": "#/components/responses/ApiErrorForbidden"
          },
          "404": {
            "$ref": "#/components/responses/ApiErrorNotFound"
          },
          "409": {
            "$ref": "#/components/responses/ApiErrorConflict"
          },
          "429": {
            "$ref": "#/components/responses/ApiErrorRateLimit"
          },
          "500": {
            "$ref": "#/components/responses/ApiErrorServer"
          }
        },
        "security": [
          {
            "bearer": []
          },
          {
            "api-key": []
          }
        ],
        "summary": "Genera un nuevo secret HMAC (invalida el anterior)",
        "tags": [
          "Webhooks"
        ],
        "x-scope": "webhooks:manage"
      }
    },
    "/workspaces/{workspaceId}/webhooks/{id}/sample": {
      "get": {
        "externalDocs": {
          "description": "Guía: Webhooks entrantes",
          "url": "https://developers.meteor.com.co/guias/webhooks.html"
        },
        "operationId": "WebhooksController_getSample",
        "parameters": [
          {
            "description": "ID numérico del workspace. Debe ser el mismo workspace de tu API key: pedir otro devuelve 401.",
            "in": "path",
            "name": "workspaceId",
            "required": true,
            "schema": {
              "type": "number"
            }
          },
          {
            "description": "ID del recurso de esta ruta.",
            "in": "path",
            "name": "id",
            "required": true,
            "schema": {
              "type": "number"
            }
          }
        ],
        "responses": {
          "200": {
            "content": {
              "application/json": {
                "schema": {
                  "allOf": [
                    {
                      "$ref": "#/components/schemas/ApiEnvelope"
                    },
                    {
                      "properties": {
                        "data": {
                          "$ref": "#/components/schemas/WebhookSampleDto"
                        }
                      },
                      "required": [
                        "data"
                      ],
                      "type": "object"
                    }
                  ]
                }
              }
            },
            "description": ""
          },
          "400": {
            "$ref": "#/components/responses/ApiErrorInvalidRequest"
          },
          "401": {
            "$ref": "#/components/responses/ApiErrorAuth"
          },
          "403": {
            "$ref": "#/components/responses/ApiErrorForbidden"
          },
          "404": {
            "$ref": "#/components/responses/ApiErrorNotFound"
          },
          "429": {
            "$ref": "#/components/responses/ApiErrorRateLimit"
          },
          "500": {
            "$ref": "#/components/responses/ApiErrorServer"
          }
        },
        "security": [
          {
            "bearer": []
          },
          {
            "api-key": []
          }
        ],
        "summary": "Último payload recibido (para vista previa del mapeo)",
        "tags": [
          "Webhooks"
        ],
        "x-scope": "webhooks:manage"
      }
    }
  },
  "servers": [
    {
      "url": "https://api.met.meteor.com.co/api/v1"
    }
  ],
  "tags": [
    {
      "description": "Ejecutar un Met y leer el resultado, con o sin streaming.",
      "externalDocs": {
        "description": "Guía: Ejecutar Mets (Runs)",
        "url": "https://developers.meteor.com.co/guias/ejecutar-agentes.html"
      },
      "name": "Runs"
    },
    {
      "description": "Los Mets: crearlos, ajustar su prompt, elegir sus herramientas y armar grupos que se repartan la atención de un canal.",
      "externalDocs": {
        "description": "Guía: Mets y sus herramientas",
        "url": "https://developers.meteor.com.co/guias/mets-y-herramientas.html"
      },
      "name": "Agents"
    },
    {
      "description": "Las skills: el catálogo del workspace (instalar, configurar, credenciales) y cuáles tiene habilitadas cada Met.",
      "externalDocs": {
        "description": "Guía: Skills",
        "url": "https://developers.meteor.com.co/guias/skills.html"
      },
      "name": "Skills"
    },
    {
      "description": "Integraciones y sus tools: activar, listar y ejecutar.",
      "externalDocs": {
        "description": "Guía: Integraciones MCP",
        "url": "https://developers.meteor.com.co/guias/integraciones-mcp.html"
      },
      "name": "Integrations"
    },
    {
      "description": "Servidores MCP propios registrados en el workspace.",
      "externalDocs": {
        "description": "Guía: Integraciones MCP",
        "url": "https://developers.meteor.com.co/guias/integraciones-mcp.html"
      },
      "name": "MCP"
    },
    {
      "description": "Con qué identidad entra tu key: dueño, scopes, entorno y límites vigentes.",
      "externalDocs": {
        "description": "Guía: Autenticación",
        "url": "https://developers.meteor.com.co/guias/autenticacion.html"
      },
      "name": "Identidad"
    },
    {
      "description": "Las tablas del workspace: crear, listar, describir sus campos, organizarlas en carpetas y resolverlas por slug.",
      "externalDocs": {
        "description": "Guía: Datos: colecciones e ítems",
        "url": "https://developers.meteor.com.co/guias/colecciones-e-items.html"
      },
      "name": "Collections"
    },
    {
      "description": "Las filas de una colección: crear, buscar, mover de estado y borrar, con su contenido largo, sus comentarios y sus archivos adjuntos.",
      "externalDocs": {
        "description": "Guía: Datos: colecciones e ítems",
        "url": "https://developers.meteor.com.co/guias/colecciones-e-items.html"
      },
      "name": "Items"
    },
    {
      "description": "Relaciones entre un ítem y otros recursos del workspace.",
      "externalDocs": {
        "description": "Guía: Datos: colecciones e ítems",
        "url": "https://developers.meteor.com.co/guias/colecciones-e-items.html"
      },
      "name": "Item Links"
    },
    {
      "description": "Tareas agénticas: crear, ejecutar y seguir su ejecución, con sus pasos, sus disparadores y sus comentarios.",
      "externalDocs": {
        "description": "Guía: Tareas",
        "url": "https://developers.meteor.com.co/guias/tareas.html"
      },
      "name": "Tasks"
    },
    {
      "description": "El CRM: crear contactos, etiquetarlos, moverlos por el embudo y leer su ficha.",
      "externalDocs": {
        "description": "Guía: CRM y contactos",
        "url": "https://developers.meteor.com.co/guias/contactos.html"
      },
      "name": "Contacts"
    },
    {
      "description": "Las conversaciones del workspace y sus mensajes.",
      "externalDocs": {
        "description": "Guía: Operación del workspace",
        "url": "https://developers.meteor.com.co/guias/operacion-del-workspace.html"
      },
      "name": "Conversations"
    },
    {
      "description": "Los canales conectados (WhatsApp y otros) y el envío de mensajes.",
      "externalDocs": {
        "description": "Guía: CRM y contactos",
        "url": "https://developers.meteor.com.co/guias/contactos.html"
      },
      "name": "Channels"
    },
    {
      "description": "Difusiones: mandar un mensaje a un segmento de contactos.",
      "externalDocs": {
        "description": "Guía: CRM y contactos",
        "url": "https://developers.meteor.com.co/guias/contactos.html"
      },
      "name": "Broadcasts"
    },
    {
      "description": "Reportar conversiones a Meta (CAPI) que nacen de anuncios; una compuerta valida atribución y criterio antes de emitir.",
      "externalDocs": {
        "description": "Guía: CRM y contactos",
        "url": "https://developers.meteor.com.co/guias/contactos.html"
      },
      "name": "Conversions"
    },
    {
      "description": "Flujos visuales: ejecutarlos, versionarlos, exportarlos e importarlos.",
      "externalDocs": {
        "description": "Guía: Funciones y flujos",
        "url": "https://developers.meteor.com.co/guias/funciones-y-flujos.html"
      },
      "name": "Flows"
    },
    {
      "description": "Automatizaciones: qué se dispara y con qué condición.",
      "externalDocs": {
        "description": "Guía: Funciones y flujos",
        "url": "https://developers.meteor.com.co/guias/funciones-y-flujos.html"
      },
      "name": "Automations"
    },
    {
      "description": "Funciones propias que un Met puede llamar como herramienta.",
      "externalDocs": {
        "description": "Guía: Funciones y flujos",
        "url": "https://developers.meteor.com.co/guias/funciones-y-flujos.html"
      },
      "name": "Functions"
    },
    {
      "description": "Webhooks entrantes: recibir eventos de sistemas de afuera.",
      "externalDocs": {
        "description": "Guía: Webhooks entrantes",
        "url": "https://developers.meteor.com.co/guias/webhooks.html"
      },
      "name": "Webhooks"
    },
    {
      "description": "El flujo de eventos del workspace en vivo.",
      "externalDocs": {
        "description": "Guía: Eventos en vivo",
        "url": "https://developers.meteor.com.co/guias/eventos.html"
      },
      "name": "Events"
    },
    {
      "description": "Variables del workspace, incluidas las cifradas.",
      "externalDocs": {
        "description": "Guía: Variables del workspace",
        "url": "https://developers.meteor.com.co/guias/variables.html"
      },
      "name": "Variables"
    },
    {
      "description": "Consumo de Energía, plan y cuotas del workspace.",
      "externalDocs": {
        "description": "Guía: Límites y cuotas",
        "url": "https://developers.meteor.com.co/guias/limites.html"
      },
      "name": "Billing"
    },
    {
      "description": "La mediateca del workspace: subir archivos, listarlos y ordenarlos en carpetas.",
      "externalDocs": {
        "description": "Guía: Operación del workspace",
        "url": "https://developers.meteor.com.co/guias/operacion-del-workspace.html"
      },
      "name": "Files"
    },
    {
      "description": "Recordatorios programados que se envían al contacto.",
      "externalDocs": {
        "description": "Guía: Operación del workspace",
        "url": "https://developers.meteor.com.co/guias/operacion-del-workspace.html"
      },
      "name": "Reminders"
    },
    {
      "description": "Generar, editar y animar imágenes.",
      "externalDocs": {
        "description": "Guía: Imágenes",
        "url": "https://developers.meteor.com.co/guias/imagenes.html"
      },
      "name": "Images"
    },
    {
      "description": "Plantillas de workspace: el catálogo disponible, e instalarlas, aplicarlas y publicarlas.",
      "externalDocs": {
        "description": "Guía: Plantillas (Snapshots)",
        "url": "https://developers.meteor.com.co/guias/snapshots.html"
      },
      "name": "Snapshots"
    },
    {
      "description": "Crear cuentas de Met desde tu producto y cargarles energía. Exclusivo de Tech Partners con key de partner.",
      "externalDocs": {
        "description": "Guía: Aprovisionamiento de cuentas",
        "url": "https://developers.meteor.com.co/guias/aprovisionamiento.html"
      },
      "name": "Provisioning"
    }
  ],
  "x-tagGroups": [
    {
      "name": "Empezar",
      "tags": [
        "Runs",
        "Agents",
        "Skills",
        "Integrations",
        "MCP",
        "Identidad"
      ]
    },
    {
      "name": "Datos",
      "tags": [
        "Collections",
        "Items",
        "Item Links",
        "Tasks"
      ]
    },
    {
      "name": "CRM y canales",
      "tags": [
        "Contacts",
        "Conversations",
        "Channels",
        "Broadcasts",
        "Conversions"
      ]
    },
    {
      "name": "Automatización",
      "tags": [
        "Flows",
        "Automations",
        "Functions",
        "Webhooks",
        "Events"
      ]
    },
    {
      "name": "Workspace",
      "tags": [
        "Variables",
        "Billing",
        "Files",
        "Reminders",
        "Images",
        "Snapshots"
      ]
    },
    {
      "name": "Partners",
      "tags": [
        "Provisioning"
      ]
    }
  ]
}
