{
  "openapi": "3.1.0",
  "info": {
    "title": "Ucotron Cortex — SBOX",
    "version": "doc4-sbox-product-surface-v1",
    "description": "Superficie pública del sandbox. TODO lo que responde es fixture determinista: no hay datos de clientes, no se llama a ningún proveedor externo y el estado vuelve a cero con POST /v1/sbox/reset."
  },
  "servers": [
    {
      "url": "https://sbox.ucotron.com",
      "description": "SBOX — fixture-only, no producción"
    }
  ],
  "x-ucotron-source-status": {
    "mode": "sbox_mocked",
    "generatedFrom": "packages/schemas/src/sbox-product-contracts.ts",
    "generator": "tools/sbox-openapi-generator.ts",
    "fixtureOnly": true,
    "externalProviderCalls": false,
    "realCustomerData": false,
    "driftFailureMode": "pnpm openapi:sbox:check falla cuando docs/sbox-openapi.local.json no se regeneró desde el catálogo de rutas."
  },
  "paths": {
    "/v1/sbox/fixtures": {
      "get": {
        "operationId": "getSboxFixtures",
        "summary": "Dataset sembrado completo del sandbox.",
        "tags": [
          "sbox"
        ],
        "security": [
          {
            "bearerFixtureToken": []
          }
        ],
        "x-ucotron-permission": "portfolio:read",
        "x-ucotron-idempotency-required": false,
        "x-ucotron-mode": "sbox_mocked",
        "parameters": [
          {
            "$ref": "#/components/parameters/TenantId"
          }
        ],
        "responses": {
          "200": {
            "description": "El recurso.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "data": {
                      "type": "object"
                    }
                  },
                  "required": [
                    "data"
                  ]
                }
              }
            }
          },
          "400": {
            "$ref": "#/components/responses/BadRequest"
          },
          "401": {
            "$ref": "#/components/responses/Unauthorized"
          },
          "403": {
            "$ref": "#/components/responses/Forbidden"
          },
          "404": {
            "$ref": "#/components/responses/NotFound"
          }
        }
      }
    },
    "/v1/sbox/reset": {
      "post": {
        "operationId": "postSboxReset",
        "summary": "Vuelve el sandbox al dataset sembrado.",
        "tags": [
          "sbox"
        ],
        "security": [
          {
            "bearerFixtureToken": []
          }
        ],
        "x-ucotron-permission": null,
        "x-ucotron-idempotency-required": true,
        "x-ucotron-mode": "sbox_mocked",
        "parameters": [
          {
            "$ref": "#/components/parameters/TenantId"
          },
          {
            "$ref": "#/components/parameters/IdempotencyKey"
          }
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object"
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Aplicado."
          },
          "201": {
            "description": "Creado. `Location` apunta al recurso."
          },
          "202": {
            "description": "Aceptado. La respuesta describe el trabajo o la decisión."
          },
          "401": {
            "$ref": "#/components/responses/Unauthorized"
          },
          "404": {
            "$ref": "#/components/responses/NotFound"
          },
          "409": {
            "$ref": "#/components/responses/Conflict"
          },
          "422": {
            "$ref": "#/components/responses/Unprocessable"
          }
        }
      }
    },
    "/v1/portfolios": {
      "get": {
        "operationId": "getPortfolios",
        "summary": "Carteras del tenant.",
        "tags": [
          "portfolios"
        ],
        "security": [
          {
            "bearerFixtureToken": []
          }
        ],
        "x-ucotron-permission": "portfolio:read",
        "x-ucotron-idempotency-required": false,
        "x-ucotron-mode": "sbox_mocked",
        "parameters": [
          {
            "$ref": "#/components/parameters/Cursor"
          },
          {
            "$ref": "#/components/parameters/Limit"
          },
          {
            "$ref": "#/components/parameters/TenantId"
          }
        ],
        "responses": {
          "200": {
            "description": "Página de resultados.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CursorPage"
                },
                "examples": {
                  "page": {
                    "$ref": "#/components/examples/listPortfoliosResponse"
                  }
                }
              }
            }
          },
          "400": {
            "$ref": "#/components/responses/BadRequest"
          },
          "401": {
            "$ref": "#/components/responses/Unauthorized"
          },
          "403": {
            "$ref": "#/components/responses/Forbidden"
          },
          "404": {
            "$ref": "#/components/responses/NotFound"
          }
        }
      },
      "post": {
        "operationId": "postPortfolios",
        "summary": "Carteras del tenant.",
        "tags": [
          "portfolios"
        ],
        "security": [
          {
            "bearerFixtureToken": []
          }
        ],
        "x-ucotron-permission": "portfolio:write",
        "x-ucotron-idempotency-required": true,
        "x-ucotron-mode": "sbox_mocked",
        "parameters": [
          {
            "$ref": "#/components/parameters/TenantId"
          },
          {
            "$ref": "#/components/parameters/IdempotencyKey"
          }
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object"
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Aplicado."
          },
          "201": {
            "description": "Creado. `Location` apunta al recurso."
          },
          "202": {
            "description": "Aceptado. La respuesta describe el trabajo o la decisión."
          },
          "401": {
            "$ref": "#/components/responses/Unauthorized"
          },
          "403": {
            "$ref": "#/components/responses/Forbidden"
          },
          "404": {
            "$ref": "#/components/responses/NotFound"
          },
          "409": {
            "$ref": "#/components/responses/Conflict"
          },
          "422": {
            "$ref": "#/components/responses/Unprocessable"
          }
        }
      }
    },
    "/v1/portfolios/{id}": {
      "get": {
        "operationId": "getPortfoliosId",
        "summary": "Una cartera por id.",
        "tags": [
          "portfolios"
        ],
        "security": [
          {
            "bearerFixtureToken": []
          }
        ],
        "x-ucotron-permission": "portfolio:read",
        "x-ucotron-idempotency-required": false,
        "x-ucotron-mode": "sbox_mocked",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "description": "Identificador del recurso dentro de la organización."
          },
          {
            "$ref": "#/components/parameters/TenantId"
          }
        ],
        "responses": {
          "200": {
            "description": "El recurso.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "data": {
                      "type": "object"
                    }
                  },
                  "required": [
                    "data"
                  ]
                }
              }
            }
          },
          "400": {
            "$ref": "#/components/responses/BadRequest"
          },
          "401": {
            "$ref": "#/components/responses/Unauthorized"
          },
          "403": {
            "$ref": "#/components/responses/Forbidden"
          },
          "404": {
            "$ref": "#/components/responses/NotFound"
          }
        }
      }
    },
    "/v1/aois": {
      "get": {
        "operationId": "getAois",
        "summary": "Lotes / AOIs del tenant.",
        "tags": [
          "aois"
        ],
        "security": [
          {
            "bearerFixtureToken": []
          }
        ],
        "x-ucotron-permission": "portfolio:read",
        "x-ucotron-idempotency-required": false,
        "x-ucotron-mode": "sbox_mocked",
        "parameters": [
          {
            "$ref": "#/components/parameters/Cursor"
          },
          {
            "$ref": "#/components/parameters/Limit"
          },
          {
            "$ref": "#/components/parameters/TenantId"
          }
        ],
        "responses": {
          "200": {
            "description": "Página de resultados.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CursorPage"
                },
                "examples": {
                  "page": {
                    "$ref": "#/components/examples/listAoisResponse"
                  }
                }
              }
            }
          },
          "400": {
            "$ref": "#/components/responses/BadRequest"
          },
          "401": {
            "$ref": "#/components/responses/Unauthorized"
          },
          "403": {
            "$ref": "#/components/responses/Forbidden"
          },
          "404": {
            "$ref": "#/components/responses/NotFound"
          }
        }
      },
      "post": {
        "operationId": "postAois",
        "summary": "Lotes / AOIs del tenant.",
        "tags": [
          "aois"
        ],
        "security": [
          {
            "bearerFixtureToken": []
          }
        ],
        "x-ucotron-permission": "portfolio:write",
        "x-ucotron-idempotency-required": true,
        "x-ucotron-mode": "sbox_mocked",
        "parameters": [
          {
            "$ref": "#/components/parameters/TenantId"
          },
          {
            "$ref": "#/components/parameters/IdempotencyKey"
          }
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object"
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Aplicado."
          },
          "201": {
            "description": "Creado. `Location` apunta al recurso."
          },
          "202": {
            "description": "Aceptado. La respuesta describe el trabajo o la decisión."
          },
          "401": {
            "$ref": "#/components/responses/Unauthorized"
          },
          "403": {
            "$ref": "#/components/responses/Forbidden"
          },
          "404": {
            "$ref": "#/components/responses/NotFound"
          },
          "409": {
            "$ref": "#/components/responses/Conflict"
          },
          "422": {
            "$ref": "#/components/responses/Unprocessable"
          }
        }
      }
    },
    "/v1/aois/{id}": {
      "get": {
        "operationId": "getAoisId",
        "summary": "Un AOI por id, con su geometría vigente.",
        "tags": [
          "aois"
        ],
        "security": [
          {
            "bearerFixtureToken": []
          }
        ],
        "x-ucotron-permission": "portfolio:read",
        "x-ucotron-idempotency-required": false,
        "x-ucotron-mode": "sbox_mocked",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "description": "Identificador del recurso dentro de la organización."
          },
          {
            "$ref": "#/components/parameters/TenantId"
          }
        ],
        "responses": {
          "200": {
            "description": "El recurso.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "data": {
                      "type": "object"
                    }
                  },
                  "required": [
                    "data"
                  ]
                }
              }
            }
          },
          "400": {
            "$ref": "#/components/responses/BadRequest"
          },
          "401": {
            "$ref": "#/components/responses/Unauthorized"
          },
          "403": {
            "$ref": "#/components/responses/Forbidden"
          },
          "404": {
            "$ref": "#/components/responses/NotFound"
          }
        }
      }
    },
    "/v1/clients": {
      "get": {
        "operationId": "getClients",
        "summary": "Clientes del tenant.",
        "tags": [
          "clients"
        ],
        "security": [
          {
            "bearerFixtureToken": []
          }
        ],
        "x-ucotron-permission": "clients:read",
        "x-ucotron-idempotency-required": false,
        "x-ucotron-mode": "sbox_mocked",
        "parameters": [
          {
            "$ref": "#/components/parameters/Cursor"
          },
          {
            "$ref": "#/components/parameters/Limit"
          },
          {
            "$ref": "#/components/parameters/TenantId"
          }
        ],
        "responses": {
          "200": {
            "description": "Página de resultados.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CursorPage"
                },
                "examples": {
                  "page": {
                    "$ref": "#/components/examples/listClientsResponse"
                  }
                }
              }
            }
          },
          "400": {
            "$ref": "#/components/responses/BadRequest"
          },
          "401": {
            "$ref": "#/components/responses/Unauthorized"
          },
          "403": {
            "$ref": "#/components/responses/Forbidden"
          },
          "404": {
            "$ref": "#/components/responses/NotFound"
          }
        }
      },
      "post": {
        "operationId": "postClients",
        "summary": "Clientes del tenant.",
        "tags": [
          "clients"
        ],
        "security": [
          {
            "bearerFixtureToken": []
          }
        ],
        "x-ucotron-permission": "clients:write",
        "x-ucotron-idempotency-required": true,
        "x-ucotron-mode": "sbox_mocked",
        "parameters": [
          {
            "$ref": "#/components/parameters/TenantId"
          },
          {
            "$ref": "#/components/parameters/IdempotencyKey"
          }
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object"
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Aplicado."
          },
          "201": {
            "description": "Creado. `Location` apunta al recurso."
          },
          "202": {
            "description": "Aceptado. La respuesta describe el trabajo o la decisión."
          },
          "401": {
            "$ref": "#/components/responses/Unauthorized"
          },
          "403": {
            "$ref": "#/components/responses/Forbidden"
          },
          "404": {
            "$ref": "#/components/responses/NotFound"
          },
          "409": {
            "$ref": "#/components/responses/Conflict"
          },
          "422": {
            "$ref": "#/components/responses/Unprocessable"
          }
        }
      }
    },
    "/v1/policies": {
      "get": {
        "operationId": "getPolicies",
        "summary": "Pólizas del tenant.",
        "tags": [
          "policies"
        ],
        "security": [
          {
            "bearerFixtureToken": []
          }
        ],
        "x-ucotron-permission": "underwriting:read",
        "x-ucotron-idempotency-required": false,
        "x-ucotron-mode": "sbox_mocked",
        "parameters": [
          {
            "$ref": "#/components/parameters/Cursor"
          },
          {
            "$ref": "#/components/parameters/Limit"
          },
          {
            "$ref": "#/components/parameters/TenantId"
          }
        ],
        "responses": {
          "200": {
            "description": "Página de resultados.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CursorPage"
                },
                "examples": {
                  "page": {
                    "$ref": "#/components/examples/listPoliciesResponse"
                  }
                }
              }
            }
          },
          "400": {
            "$ref": "#/components/responses/BadRequest"
          },
          "401": {
            "$ref": "#/components/responses/Unauthorized"
          },
          "403": {
            "$ref": "#/components/responses/Forbidden"
          },
          "404": {
            "$ref": "#/components/responses/NotFound"
          }
        }
      },
      "post": {
        "operationId": "postPolicies",
        "summary": "Pólizas del tenant.",
        "tags": [
          "policies"
        ],
        "security": [
          {
            "bearerFixtureToken": []
          }
        ],
        "x-ucotron-permission": "underwriting:write",
        "x-ucotron-idempotency-required": true,
        "x-ucotron-mode": "sbox_mocked",
        "parameters": [
          {
            "$ref": "#/components/parameters/TenantId"
          },
          {
            "$ref": "#/components/parameters/IdempotencyKey"
          }
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object"
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Aplicado."
          },
          "201": {
            "description": "Creado. `Location` apunta al recurso."
          },
          "202": {
            "description": "Aceptado. La respuesta describe el trabajo o la decisión."
          },
          "401": {
            "$ref": "#/components/responses/Unauthorized"
          },
          "403": {
            "$ref": "#/components/responses/Forbidden"
          },
          "404": {
            "$ref": "#/components/responses/NotFound"
          },
          "409": {
            "$ref": "#/components/responses/Conflict"
          },
          "422": {
            "$ref": "#/components/responses/Unprocessable"
          }
        }
      }
    },
    "/v1/events": {
      "get": {
        "operationId": "getEvents",
        "summary": "Eventos meteorológicos que tocaron la cartera.",
        "tags": [
          "events"
        ],
        "security": [
          {
            "bearerFixtureToken": []
          }
        ],
        "x-ucotron-permission": "events:read",
        "x-ucotron-idempotency-required": false,
        "x-ucotron-mode": "sbox_mocked",
        "parameters": [
          {
            "$ref": "#/components/parameters/Cursor"
          },
          {
            "$ref": "#/components/parameters/Limit"
          },
          {
            "$ref": "#/components/parameters/TenantId"
          }
        ],
        "responses": {
          "200": {
            "description": "Página de resultados.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CursorPage"
                },
                "examples": {
                  "page": {
                    "$ref": "#/components/examples/listEventsResponse"
                  }
                }
              }
            }
          },
          "400": {
            "$ref": "#/components/responses/BadRequest"
          },
          "401": {
            "$ref": "#/components/responses/Unauthorized"
          },
          "403": {
            "$ref": "#/components/responses/Forbidden"
          },
          "404": {
            "$ref": "#/components/responses/NotFound"
          }
        }
      }
    },
    "/v1/detections": {
      "get": {
        "operationId": "getDetections",
        "summary": "Detecciones de daño por evento y AOI.",
        "tags": [
          "detections"
        ],
        "security": [
          {
            "bearerFixtureToken": []
          }
        ],
        "x-ucotron-permission": "events:read",
        "x-ucotron-idempotency-required": false,
        "x-ucotron-mode": "sbox_mocked",
        "parameters": [
          {
            "$ref": "#/components/parameters/Cursor"
          },
          {
            "$ref": "#/components/parameters/Limit"
          },
          {
            "$ref": "#/components/parameters/TenantId"
          }
        ],
        "responses": {
          "200": {
            "description": "Página de resultados.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CursorPage"
                },
                "examples": {
                  "page": {
                    "$ref": "#/components/examples/listDetectionsResponse"
                  }
                }
              }
            }
          },
          "400": {
            "$ref": "#/components/responses/BadRequest"
          },
          "401": {
            "$ref": "#/components/responses/Unauthorized"
          },
          "403": {
            "$ref": "#/components/responses/Forbidden"
          },
          "404": {
            "$ref": "#/components/responses/NotFound"
          }
        }
      },
      "post": {
        "operationId": "postDetections",
        "summary": "Detecciones de daño por evento y AOI.",
        "tags": [
          "detections"
        ],
        "security": [
          {
            "bearerFixtureToken": []
          }
        ],
        "x-ucotron-permission": "events:write",
        "x-ucotron-idempotency-required": true,
        "x-ucotron-mode": "sbox_mocked",
        "parameters": [
          {
            "$ref": "#/components/parameters/TenantId"
          },
          {
            "$ref": "#/components/parameters/IdempotencyKey"
          }
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object"
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Aplicado."
          },
          "201": {
            "description": "Creado. `Location` apunta al recurso."
          },
          "202": {
            "description": "Aceptado. La respuesta describe el trabajo o la decisión."
          },
          "401": {
            "$ref": "#/components/responses/Unauthorized"
          },
          "403": {
            "$ref": "#/components/responses/Forbidden"
          },
          "404": {
            "$ref": "#/components/responses/NotFound"
          },
          "409": {
            "$ref": "#/components/responses/Conflict"
          },
          "422": {
            "$ref": "#/components/responses/Unprocessable"
          }
        }
      }
    },
    "/v1/weather": {
      "get": {
        "operationId": "getWeather",
        "summary": "Observaciones meteorológicas por AOI.",
        "tags": [
          "weather"
        ],
        "security": [
          {
            "bearerFixtureToken": []
          }
        ],
        "x-ucotron-permission": "events:read",
        "x-ucotron-idempotency-required": false,
        "x-ucotron-mode": "sbox_mocked",
        "parameters": [
          {
            "$ref": "#/components/parameters/Cursor"
          },
          {
            "$ref": "#/components/parameters/Limit"
          },
          {
            "$ref": "#/components/parameters/TenantId"
          }
        ],
        "responses": {
          "200": {
            "description": "Página de resultados.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CursorPage"
                },
                "examples": {
                  "page": {
                    "$ref": "#/components/examples/listWeatherResponse"
                  }
                }
              }
            }
          },
          "400": {
            "$ref": "#/components/responses/BadRequest"
          },
          "401": {
            "$ref": "#/components/responses/Unauthorized"
          },
          "403": {
            "$ref": "#/components/responses/Forbidden"
          },
          "404": {
            "$ref": "#/components/responses/NotFound"
          }
        }
      }
    },
    "/v1/claims": {
      "get": {
        "operationId": "getClaims",
        "summary": "Siniestros del tenant.",
        "tags": [
          "claims"
        ],
        "security": [
          {
            "bearerFixtureToken": []
          }
        ],
        "x-ucotron-permission": "claims:read",
        "x-ucotron-idempotency-required": false,
        "x-ucotron-mode": "sbox_mocked",
        "parameters": [
          {
            "$ref": "#/components/parameters/Cursor"
          },
          {
            "$ref": "#/components/parameters/Limit"
          },
          {
            "$ref": "#/components/parameters/TenantId"
          }
        ],
        "responses": {
          "200": {
            "description": "Página de resultados.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CursorPage"
                },
                "examples": {
                  "page": {
                    "$ref": "#/components/examples/listClaimsResponse"
                  }
                }
              }
            }
          },
          "400": {
            "$ref": "#/components/responses/BadRequest"
          },
          "401": {
            "$ref": "#/components/responses/Unauthorized"
          },
          "403": {
            "$ref": "#/components/responses/Forbidden"
          },
          "404": {
            "$ref": "#/components/responses/NotFound"
          }
        }
      },
      "post": {
        "operationId": "postClaims",
        "summary": "Siniestros del tenant.",
        "tags": [
          "claims"
        ],
        "security": [
          {
            "bearerFixtureToken": []
          }
        ],
        "x-ucotron-permission": "claims:write",
        "x-ucotron-idempotency-required": true,
        "x-ucotron-mode": "sbox_mocked",
        "parameters": [
          {
            "$ref": "#/components/parameters/TenantId"
          },
          {
            "$ref": "#/components/parameters/IdempotencyKey"
          }
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object"
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Aplicado."
          },
          "201": {
            "description": "Creado. `Location` apunta al recurso."
          },
          "202": {
            "description": "Aceptado. La respuesta describe el trabajo o la decisión."
          },
          "401": {
            "$ref": "#/components/responses/Unauthorized"
          },
          "403": {
            "$ref": "#/components/responses/Forbidden"
          },
          "404": {
            "$ref": "#/components/responses/NotFound"
          },
          "409": {
            "$ref": "#/components/responses/Conflict"
          },
          "422": {
            "$ref": "#/components/responses/Unprocessable"
          }
        }
      }
    },
    "/v1/claims/{id}": {
      "get": {
        "operationId": "getClaimsId",
        "summary": "Un siniestro por id.",
        "tags": [
          "claims"
        ],
        "security": [
          {
            "bearerFixtureToken": []
          }
        ],
        "x-ucotron-permission": "claims:read",
        "x-ucotron-idempotency-required": false,
        "x-ucotron-mode": "sbox_mocked",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "description": "Identificador del recurso dentro de la organización."
          },
          {
            "$ref": "#/components/parameters/TenantId"
          }
        ],
        "responses": {
          "200": {
            "description": "El recurso.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "data": {
                      "type": "object"
                    }
                  },
                  "required": [
                    "data"
                  ]
                }
              }
            }
          },
          "400": {
            "$ref": "#/components/responses/BadRequest"
          },
          "401": {
            "$ref": "#/components/responses/Unauthorized"
          },
          "403": {
            "$ref": "#/components/responses/Forbidden"
          },
          "404": {
            "$ref": "#/components/responses/NotFound"
          }
        }
      }
    },
    "/v1/peritajes": {
      "get": {
        "operationId": "getPeritajes",
        "summary": "Peritajes ligados a un siniestro y a su detección.",
        "tags": [
          "peritajes"
        ],
        "security": [
          {
            "bearerFixtureToken": []
          }
        ],
        "x-ucotron-permission": "claims:read",
        "x-ucotron-idempotency-required": false,
        "x-ucotron-mode": "sbox_mocked",
        "parameters": [
          {
            "$ref": "#/components/parameters/Cursor"
          },
          {
            "$ref": "#/components/parameters/Limit"
          },
          {
            "$ref": "#/components/parameters/TenantId"
          }
        ],
        "responses": {
          "200": {
            "description": "Página de resultados.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CursorPage"
                },
                "examples": {
                  "page": {
                    "$ref": "#/components/examples/listPeritajesResponse"
                  }
                }
              }
            }
          },
          "400": {
            "$ref": "#/components/responses/BadRequest"
          },
          "401": {
            "$ref": "#/components/responses/Unauthorized"
          },
          "403": {
            "$ref": "#/components/responses/Forbidden"
          },
          "404": {
            "$ref": "#/components/responses/NotFound"
          }
        }
      },
      "post": {
        "operationId": "postPeritajes",
        "summary": "Peritajes ligados a un siniestro y a su detección.",
        "tags": [
          "peritajes"
        ],
        "security": [
          {
            "bearerFixtureToken": []
          }
        ],
        "x-ucotron-permission": "claims:write",
        "x-ucotron-idempotency-required": true,
        "x-ucotron-mode": "sbox_mocked",
        "parameters": [
          {
            "$ref": "#/components/parameters/TenantId"
          },
          {
            "$ref": "#/components/parameters/IdempotencyKey"
          }
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object"
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Aplicado."
          },
          "201": {
            "description": "Creado. `Location` apunta al recurso."
          },
          "202": {
            "description": "Aceptado. La respuesta describe el trabajo o la decisión."
          },
          "401": {
            "$ref": "#/components/responses/Unauthorized"
          },
          "403": {
            "$ref": "#/components/responses/Forbidden"
          },
          "404": {
            "$ref": "#/components/responses/NotFound"
          },
          "409": {
            "$ref": "#/components/responses/Conflict"
          },
          "422": {
            "$ref": "#/components/responses/Unprocessable"
          }
        }
      }
    },
    "/v1/reports": {
      "get": {
        "operationId": "getReports",
        "summary": "Reportes, firmados o en borrador.",
        "tags": [
          "reports"
        ],
        "security": [
          {
            "bearerFixtureToken": []
          }
        ],
        "x-ucotron-permission": "reports:read",
        "x-ucotron-idempotency-required": false,
        "x-ucotron-mode": "sbox_mocked",
        "parameters": [
          {
            "$ref": "#/components/parameters/Cursor"
          },
          {
            "$ref": "#/components/parameters/Limit"
          },
          {
            "$ref": "#/components/parameters/TenantId"
          }
        ],
        "responses": {
          "200": {
            "description": "Página de resultados.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CursorPage"
                },
                "examples": {
                  "page": {
                    "$ref": "#/components/examples/listReportsResponse"
                  }
                }
              }
            }
          },
          "400": {
            "$ref": "#/components/responses/BadRequest"
          },
          "401": {
            "$ref": "#/components/responses/Unauthorized"
          },
          "403": {
            "$ref": "#/components/responses/Forbidden"
          },
          "404": {
            "$ref": "#/components/responses/NotFound"
          }
        }
      },
      "post": {
        "operationId": "postReports",
        "summary": "Reportes, firmados o en borrador.",
        "tags": [
          "reports"
        ],
        "security": [
          {
            "bearerFixtureToken": []
          }
        ],
        "x-ucotron-permission": "reports:write",
        "x-ucotron-idempotency-required": true,
        "x-ucotron-mode": "sbox_mocked",
        "parameters": [
          {
            "$ref": "#/components/parameters/TenantId"
          },
          {
            "$ref": "#/components/parameters/IdempotencyKey"
          }
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object"
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Aplicado."
          },
          "201": {
            "description": "Creado. `Location` apunta al recurso."
          },
          "202": {
            "description": "Aceptado. La respuesta describe el trabajo o la decisión."
          },
          "401": {
            "$ref": "#/components/responses/Unauthorized"
          },
          "403": {
            "$ref": "#/components/responses/Forbidden"
          },
          "404": {
            "$ref": "#/components/responses/NotFound"
          },
          "409": {
            "$ref": "#/components/responses/Conflict"
          },
          "422": {
            "$ref": "#/components/responses/Unprocessable"
          }
        }
      }
    },
    "/v1/reports/{id}": {
      "get": {
        "operationId": "getReportsId",
        "summary": "Un reporte por id, con su manifiesto firmado.",
        "tags": [
          "reports"
        ],
        "security": [
          {
            "bearerFixtureToken": []
          }
        ],
        "x-ucotron-permission": "reports:read",
        "x-ucotron-idempotency-required": false,
        "x-ucotron-mode": "sbox_mocked",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "description": "Identificador del recurso dentro de la organización."
          },
          {
            "$ref": "#/components/parameters/TenantId"
          }
        ],
        "responses": {
          "200": {
            "description": "El recurso.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "data": {
                      "type": "object"
                    }
                  },
                  "required": [
                    "data"
                  ]
                }
              }
            }
          },
          "400": {
            "$ref": "#/components/responses/BadRequest"
          },
          "401": {
            "$ref": "#/components/responses/Unauthorized"
          },
          "403": {
            "$ref": "#/components/responses/Forbidden"
          },
          "404": {
            "$ref": "#/components/responses/NotFound"
          }
        }
      }
    },
    "/v1/watch/subscriptions": {
      "get": {
        "operationId": "getWatchSubscriptions",
        "summary": "Suscripciones de vigilancia por AOI y peligro.",
        "tags": [
          "watch"
        ],
        "security": [
          {
            "bearerFixtureToken": []
          }
        ],
        "x-ucotron-permission": "alerting:read",
        "x-ucotron-idempotency-required": false,
        "x-ucotron-mode": "sbox_mocked",
        "parameters": [
          {
            "$ref": "#/components/parameters/Cursor"
          },
          {
            "$ref": "#/components/parameters/Limit"
          },
          {
            "$ref": "#/components/parameters/TenantId"
          }
        ],
        "responses": {
          "200": {
            "description": "Página de resultados.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CursorPage"
                },
                "examples": {
                  "page": {
                    "$ref": "#/components/examples/listWatchSubscriptionsResponse"
                  }
                }
              }
            }
          },
          "400": {
            "$ref": "#/components/responses/BadRequest"
          },
          "401": {
            "$ref": "#/components/responses/Unauthorized"
          },
          "403": {
            "$ref": "#/components/responses/Forbidden"
          },
          "404": {
            "$ref": "#/components/responses/NotFound"
          }
        }
      },
      "post": {
        "operationId": "postWatchSubscriptions",
        "summary": "Suscripciones de vigilancia por AOI y peligro.",
        "tags": [
          "watch"
        ],
        "security": [
          {
            "bearerFixtureToken": []
          }
        ],
        "x-ucotron-permission": "alerting:write",
        "x-ucotron-idempotency-required": true,
        "x-ucotron-mode": "sbox_mocked",
        "parameters": [
          {
            "$ref": "#/components/parameters/TenantId"
          },
          {
            "$ref": "#/components/parameters/IdempotencyKey"
          }
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object"
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Aplicado."
          },
          "201": {
            "description": "Creado. `Location` apunta al recurso."
          },
          "202": {
            "description": "Aceptado. La respuesta describe el trabajo o la decisión."
          },
          "401": {
            "$ref": "#/components/responses/Unauthorized"
          },
          "403": {
            "$ref": "#/components/responses/Forbidden"
          },
          "404": {
            "$ref": "#/components/responses/NotFound"
          },
          "409": {
            "$ref": "#/components/responses/Conflict"
          },
          "422": {
            "$ref": "#/components/responses/Unprocessable"
          }
        }
      }
    },
    "/v1/alerts": {
      "get": {
        "operationId": "getAlerts",
        "summary": "Alertas emitidas por las suscripciones.",
        "tags": [
          "alerts"
        ],
        "security": [
          {
            "bearerFixtureToken": []
          }
        ],
        "x-ucotron-permission": "alerting:read",
        "x-ucotron-idempotency-required": false,
        "x-ucotron-mode": "sbox_mocked",
        "parameters": [
          {
            "$ref": "#/components/parameters/Cursor"
          },
          {
            "$ref": "#/components/parameters/Limit"
          },
          {
            "$ref": "#/components/parameters/TenantId"
          }
        ],
        "responses": {
          "200": {
            "description": "Página de resultados.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CursorPage"
                },
                "examples": {
                  "page": {
                    "$ref": "#/components/examples/listAlertsResponse"
                  }
                }
              }
            }
          },
          "400": {
            "$ref": "#/components/responses/BadRequest"
          },
          "401": {
            "$ref": "#/components/responses/Unauthorized"
          },
          "403": {
            "$ref": "#/components/responses/Forbidden"
          },
          "404": {
            "$ref": "#/components/responses/NotFound"
          }
        }
      }
    },
    "/v1/webhooks/subscriptions": {
      "get": {
        "operationId": "getWebhooksSubscriptions",
        "summary": "Endpoints suscritos a eventos.",
        "tags": [
          "webhooks"
        ],
        "security": [
          {
            "bearerFixtureToken": []
          }
        ],
        "x-ucotron-permission": "notifications:read",
        "x-ucotron-idempotency-required": false,
        "x-ucotron-mode": "sbox_mocked",
        "parameters": [
          {
            "$ref": "#/components/parameters/Cursor"
          },
          {
            "$ref": "#/components/parameters/Limit"
          },
          {
            "$ref": "#/components/parameters/TenantId"
          }
        ],
        "responses": {
          "200": {
            "description": "Página de resultados.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CursorPage"
                },
                "examples": {
                  "page": {
                    "$ref": "#/components/examples/listWebhookSubscriptionsResponse"
                  }
                }
              }
            }
          },
          "400": {
            "$ref": "#/components/responses/BadRequest"
          },
          "401": {
            "$ref": "#/components/responses/Unauthorized"
          },
          "403": {
            "$ref": "#/components/responses/Forbidden"
          },
          "404": {
            "$ref": "#/components/responses/NotFound"
          }
        }
      },
      "post": {
        "operationId": "postWebhooksSubscriptions",
        "summary": "Endpoints suscritos a eventos.",
        "tags": [
          "webhooks"
        ],
        "security": [
          {
            "bearerFixtureToken": []
          }
        ],
        "x-ucotron-permission": "notifications:write",
        "x-ucotron-idempotency-required": true,
        "x-ucotron-mode": "sbox_mocked",
        "parameters": [
          {
            "$ref": "#/components/parameters/TenantId"
          },
          {
            "$ref": "#/components/parameters/IdempotencyKey"
          }
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object"
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Aplicado."
          },
          "201": {
            "description": "Creado. `Location` apunta al recurso."
          },
          "202": {
            "description": "Aceptado. La respuesta describe el trabajo o la decisión."
          },
          "401": {
            "$ref": "#/components/responses/Unauthorized"
          },
          "403": {
            "$ref": "#/components/responses/Forbidden"
          },
          "404": {
            "$ref": "#/components/responses/NotFound"
          },
          "409": {
            "$ref": "#/components/responses/Conflict"
          },
          "422": {
            "$ref": "#/components/responses/Unprocessable"
          }
        }
      }
    },
    "/v1/webhooks/deliveries": {
      "get": {
        "operationId": "getWebhooksDeliveries",
        "summary": "Entregas simuladas, con sus reintentos y su DLQ.",
        "tags": [
          "webhooks"
        ],
        "security": [
          {
            "bearerFixtureToken": []
          }
        ],
        "x-ucotron-permission": "notifications:read",
        "x-ucotron-idempotency-required": false,
        "x-ucotron-mode": "sbox_mocked",
        "parameters": [
          {
            "$ref": "#/components/parameters/TenantId"
          }
        ],
        "responses": {
          "200": {
            "description": "El recurso.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "data": {
                      "type": "object"
                    }
                  },
                  "required": [
                    "data"
                  ]
                }
              }
            }
          },
          "400": {
            "$ref": "#/components/responses/BadRequest"
          },
          "401": {
            "$ref": "#/components/responses/Unauthorized"
          },
          "403": {
            "$ref": "#/components/responses/Forbidden"
          },
          "404": {
            "$ref": "#/components/responses/NotFound"
          }
        }
      }
    },
    "/v1/webhooks/deliveries/{id}/replay": {
      "post": {
        "operationId": "postWebhooksDeliveriesIdReplay",
        "summary": "Reintenta una entrega desde la DLQ.",
        "tags": [
          "webhooks"
        ],
        "security": [
          {
            "bearerFixtureToken": []
          }
        ],
        "x-ucotron-permission": "notifications:write",
        "x-ucotron-idempotency-required": true,
        "x-ucotron-mode": "sbox_mocked",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "description": "Identificador del recurso dentro de la organización."
          },
          {
            "$ref": "#/components/parameters/TenantId"
          },
          {
            "$ref": "#/components/parameters/IdempotencyKey"
          }
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object"
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Aplicado."
          },
          "201": {
            "description": "Creado. `Location` apunta al recurso."
          },
          "202": {
            "description": "Aceptado. La respuesta describe el trabajo o la decisión."
          },
          "401": {
            "$ref": "#/components/responses/Unauthorized"
          },
          "403": {
            "$ref": "#/components/responses/Forbidden"
          },
          "404": {
            "$ref": "#/components/responses/NotFound"
          },
          "409": {
            "$ref": "#/components/responses/Conflict"
          },
          "422": {
            "$ref": "#/components/responses/Unprocessable"
          }
        }
      }
    },
    "/v1/org/branding": {
      "get": {
        "operationId": "getOrgBranding",
        "summary": "Branding del tenant.",
        "tags": [
          "org"
        ],
        "security": [
          {
            "bearerFixtureToken": []
          }
        ],
        "x-ucotron-permission": "admin:read",
        "x-ucotron-idempotency-required": false,
        "x-ucotron-mode": "sbox_mocked",
        "parameters": [
          {
            "$ref": "#/components/parameters/TenantId"
          }
        ],
        "responses": {
          "200": {
            "description": "El recurso.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "data": {
                      "type": "object"
                    }
                  },
                  "required": [
                    "data"
                  ]
                }
              }
            }
          },
          "400": {
            "$ref": "#/components/responses/BadRequest"
          },
          "401": {
            "$ref": "#/components/responses/Unauthorized"
          },
          "403": {
            "$ref": "#/components/responses/Forbidden"
          },
          "404": {
            "$ref": "#/components/responses/NotFound"
          }
        }
      },
      "put": {
        "operationId": "putOrgBranding",
        "summary": "Branding del tenant.",
        "tags": [
          "org"
        ],
        "security": [
          {
            "bearerFixtureToken": []
          }
        ],
        "x-ucotron-permission": "admin:write",
        "x-ucotron-idempotency-required": true,
        "x-ucotron-mode": "sbox_mocked",
        "parameters": [
          {
            "$ref": "#/components/parameters/TenantId"
          },
          {
            "$ref": "#/components/parameters/IdempotencyKey"
          }
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object"
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Aplicado."
          },
          "201": {
            "description": "Creado. `Location` apunta al recurso."
          },
          "202": {
            "description": "Aceptado. La respuesta describe el trabajo o la decisión."
          },
          "401": {
            "$ref": "#/components/responses/Unauthorized"
          },
          "403": {
            "$ref": "#/components/responses/Forbidden"
          },
          "404": {
            "$ref": "#/components/responses/NotFound"
          },
          "409": {
            "$ref": "#/components/responses/Conflict"
          },
          "422": {
            "$ref": "#/components/responses/Unprocessable"
          }
        }
      }
    },
    "/v1/org/branding/logo": {
      "post": {
        "operationId": "postOrgBrandingLogo",
        "summary": "Sube el logo del tenant.",
        "tags": [
          "org"
        ],
        "security": [
          {
            "bearerFixtureToken": []
          }
        ],
        "x-ucotron-permission": "admin:write",
        "x-ucotron-idempotency-required": true,
        "x-ucotron-mode": "sbox_mocked",
        "parameters": [
          {
            "$ref": "#/components/parameters/TenantId"
          },
          {
            "$ref": "#/components/parameters/IdempotencyKey"
          }
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object"
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Aplicado."
          },
          "201": {
            "description": "Creado. `Location` apunta al recurso."
          },
          "202": {
            "description": "Aceptado. La respuesta describe el trabajo o la decisión."
          },
          "401": {
            "$ref": "#/components/responses/Unauthorized"
          },
          "403": {
            "$ref": "#/components/responses/Forbidden"
          },
          "404": {
            "$ref": "#/components/responses/NotFound"
          },
          "409": {
            "$ref": "#/components/responses/Conflict"
          },
          "422": {
            "$ref": "#/components/responses/Unprocessable"
          }
        }
      }
    },
    "/v1/import/{kind}": {
      "post": {
        "operationId": "postImportKind",
        "summary": "Encola un import en lote sobre /v1/jobs.",
        "tags": [
          "import"
        ],
        "security": [
          {
            "bearerFixtureToken": []
          }
        ],
        "x-ucotron-permission": null,
        "x-ucotron-idempotency-required": true,
        "x-ucotron-mode": "sbox_mocked",
        "parameters": [
          {
            "name": "kind",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "description": "Uno de: aois, policies, clients, claims."
          },
          {
            "$ref": "#/components/parameters/TenantId"
          },
          {
            "$ref": "#/components/parameters/IdempotencyKey"
          }
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object"
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Aplicado."
          },
          "201": {
            "description": "Creado. `Location` apunta al recurso."
          },
          "202": {
            "description": "Aceptado. La respuesta describe el trabajo o la decisión."
          },
          "401": {
            "$ref": "#/components/responses/Unauthorized"
          },
          "404": {
            "$ref": "#/components/responses/NotFound"
          },
          "409": {
            "$ref": "#/components/responses/Conflict"
          },
          "422": {
            "$ref": "#/components/responses/Unprocessable"
          }
        }
      }
    },
    "/v1/jobs": {
      "post": {
        "operationId": "postJobs",
        "summary": "Encola un trabajo asíncrono.",
        "tags": [
          "jobs"
        ],
        "security": [
          {
            "bearerFixtureToken": []
          }
        ],
        "x-ucotron-permission": "events:read",
        "x-ucotron-idempotency-required": true,
        "x-ucotron-mode": "sbox_mocked",
        "parameters": [
          {
            "$ref": "#/components/parameters/TenantId"
          },
          {
            "$ref": "#/components/parameters/IdempotencyKey"
          }
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object"
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Aplicado."
          },
          "201": {
            "description": "Creado. `Location` apunta al recurso."
          },
          "202": {
            "description": "Aceptado. La respuesta describe el trabajo o la decisión."
          },
          "401": {
            "$ref": "#/components/responses/Unauthorized"
          },
          "403": {
            "$ref": "#/components/responses/Forbidden"
          },
          "404": {
            "$ref": "#/components/responses/NotFound"
          },
          "409": {
            "$ref": "#/components/responses/Conflict"
          },
          "422": {
            "$ref": "#/components/responses/Unprocessable"
          }
        }
      }
    },
    "/v1/jobs/{id}": {
      "get": {
        "operationId": "getJobsId",
        "summary": "Estado del trabajo, o su cancelación.",
        "tags": [
          "jobs"
        ],
        "security": [
          {
            "bearerFixtureToken": []
          }
        ],
        "x-ucotron-permission": "events:read",
        "x-ucotron-idempotency-required": false,
        "x-ucotron-mode": "sbox_mocked",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "description": "Identificador del recurso dentro de la organización."
          },
          {
            "$ref": "#/components/parameters/TenantId"
          }
        ],
        "responses": {
          "200": {
            "description": "El recurso.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "data": {
                      "type": "object"
                    }
                  },
                  "required": [
                    "data"
                  ]
                }
              }
            }
          },
          "400": {
            "$ref": "#/components/responses/BadRequest"
          },
          "401": {
            "$ref": "#/components/responses/Unauthorized"
          },
          "403": {
            "$ref": "#/components/responses/Forbidden"
          },
          "404": {
            "$ref": "#/components/responses/NotFound"
          }
        }
      },
      "delete": {
        "operationId": "deleteJobsId",
        "summary": "Estado del trabajo, o su cancelación.",
        "tags": [
          "jobs"
        ],
        "security": [
          {
            "bearerFixtureToken": []
          }
        ],
        "x-ucotron-permission": "events:write",
        "x-ucotron-idempotency-required": false,
        "x-ucotron-mode": "sbox_mocked",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "description": "Identificador del recurso dentro de la organización."
          },
          {
            "$ref": "#/components/parameters/TenantId"
          }
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object"
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Aplicado."
          },
          "201": {
            "description": "Creado. `Location` apunta al recurso."
          },
          "202": {
            "description": "Aceptado. La respuesta describe el trabajo o la decisión."
          },
          "401": {
            "$ref": "#/components/responses/Unauthorized"
          },
          "403": {
            "$ref": "#/components/responses/Forbidden"
          },
          "404": {
            "$ref": "#/components/responses/NotFound"
          },
          "409": {
            "$ref": "#/components/responses/Conflict"
          },
          "422": {
            "$ref": "#/components/responses/Unprocessable"
          }
        }
      }
    },
    "/v1/jobs/{id}/result": {
      "get": {
        "operationId": "getJobsIdResult",
        "summary": "Resultado del trabajo, sólo cuando terminó bien.",
        "tags": [
          "jobs"
        ],
        "security": [
          {
            "bearerFixtureToken": []
          }
        ],
        "x-ucotron-permission": "events:read",
        "x-ucotron-idempotency-required": false,
        "x-ucotron-mode": "sbox_mocked",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string"
            },
            "description": "Identificador del recurso dentro de la organización."
          },
          {
            "$ref": "#/components/parameters/TenantId"
          }
        ],
        "responses": {
          "200": {
            "description": "El recurso.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "data": {
                      "type": "object"
                    }
                  },
                  "required": [
                    "data"
                  ]
                }
              }
            }
          },
          "400": {
            "$ref": "#/components/responses/BadRequest"
          },
          "401": {
            "$ref": "#/components/responses/Unauthorized"
          },
          "403": {
            "$ref": "#/components/responses/Forbidden"
          },
          "404": {
            "$ref": "#/components/responses/NotFound"
          }
        }
      }
    },
    "/v1/verify": {
      "post": {
        "operationId": "postVerify",
        "summary": "Verifica una firma Ed25519 sin red, base de datos ni runtime.",
        "tags": [
          "verify"
        ],
        "security": [
          {
            "bearerFixtureToken": []
          }
        ],
        "x-ucotron-permission": "reports:read",
        "x-ucotron-idempotency-required": false,
        "x-ucotron-mode": "sbox_mocked",
        "parameters": [
          {
            "$ref": "#/components/parameters/TenantId"
          }
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object"
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Aplicado."
          },
          "201": {
            "description": "Creado. `Location` apunta al recurso."
          },
          "202": {
            "description": "Aceptado. La respuesta describe el trabajo o la decisión."
          },
          "401": {
            "$ref": "#/components/responses/Unauthorized"
          },
          "403": {
            "$ref": "#/components/responses/Forbidden"
          },
          "404": {
            "$ref": "#/components/responses/NotFound"
          },
          "409": {
            "$ref": "#/components/responses/Conflict"
          },
          "422": {
            "$ref": "#/components/responses/Unprocessable"
          }
        }
      }
    },
    "/v1/search": {
      "get": {
        "operationId": "getSearch",
        "summary": "Buscador unificado tenant-scoped.",
        "tags": [
          "search"
        ],
        "security": [
          {
            "bearerFixtureToken": []
          }
        ],
        "x-ucotron-permission": "portfolio:read",
        "x-ucotron-idempotency-required": false,
        "x-ucotron-mode": "sbox_mocked",
        "parameters": [
          {
            "$ref": "#/components/parameters/TenantId"
          }
        ],
        "responses": {
          "200": {
            "description": "El recurso.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "data": {
                      "type": "object"
                    }
                  },
                  "required": [
                    "data"
                  ]
                }
              }
            }
          },
          "400": {
            "$ref": "#/components/responses/BadRequest"
          },
          "401": {
            "$ref": "#/components/responses/Unauthorized"
          },
          "403": {
            "$ref": "#/components/responses/Forbidden"
          },
          "404": {
            "$ref": "#/components/responses/NotFound"
          }
        }
      }
    },
    "/v1/cortex/geocode": {
      "get": {
        "operationId": "getCortexGeocode",
        "summary": "Geocoding de lugares y jurisdicciones.",
        "tags": [
          "cortex"
        ],
        "security": [
          {
            "bearerFixtureToken": []
          }
        ],
        "x-ucotron-permission": "portfolio:read",
        "x-ucotron-idempotency-required": false,
        "x-ucotron-mode": "sbox_mocked",
        "parameters": [
          {
            "$ref": "#/components/parameters/TenantId"
          }
        ],
        "responses": {
          "200": {
            "description": "El recurso.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "data": {
                      "type": "object"
                    }
                  },
                  "required": [
                    "data"
                  ]
                }
              }
            }
          },
          "400": {
            "$ref": "#/components/responses/BadRequest"
          },
          "401": {
            "$ref": "#/components/responses/Unauthorized"
          },
          "403": {
            "$ref": "#/components/responses/Forbidden"
          },
          "404": {
            "$ref": "#/components/responses/NotFound"
          }
        }
      }
    },
    "/v1/score": {
      "post": {
        "operationId": "postScore",
        "summary": "Score de riesgo del AOI (fixture determinista).",
        "tags": [
          "score"
        ],
        "security": [
          {
            "bearerFixtureToken": []
          }
        ],
        "x-ucotron-permission": "events:read",
        "x-ucotron-idempotency-required": true,
        "x-ucotron-mode": "sbox_mocked",
        "parameters": [
          {
            "$ref": "#/components/parameters/TenantId"
          },
          {
            "$ref": "#/components/parameters/IdempotencyKey"
          }
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object"
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Aplicado."
          },
          "201": {
            "description": "Creado. `Location` apunta al recurso."
          },
          "202": {
            "description": "Aceptado. La respuesta describe el trabajo o la decisión."
          },
          "401": {
            "$ref": "#/components/responses/Unauthorized"
          },
          "403": {
            "$ref": "#/components/responses/Forbidden"
          },
          "404": {
            "$ref": "#/components/responses/NotFound"
          },
          "409": {
            "$ref": "#/components/responses/Conflict"
          },
          "422": {
            "$ref": "#/components/responses/Unprocessable"
          }
        }
      }
    },
    "/v1/detect": {
      "post": {
        "operationId": "postDetect",
        "summary": "Detección de daño post-evento (fixture determinista).",
        "tags": [
          "detect"
        ],
        "security": [
          {
            "bearerFixtureToken": []
          }
        ],
        "x-ucotron-permission": "events:read",
        "x-ucotron-idempotency-required": true,
        "x-ucotron-mode": "sbox_mocked",
        "parameters": [
          {
            "$ref": "#/components/parameters/TenantId"
          },
          {
            "$ref": "#/components/parameters/IdempotencyKey"
          }
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object"
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Aplicado."
          },
          "201": {
            "description": "Creado. `Location` apunta al recurso."
          },
          "202": {
            "description": "Aceptado. La respuesta describe el trabajo o la decisión."
          },
          "401": {
            "$ref": "#/components/responses/Unauthorized"
          },
          "403": {
            "$ref": "#/components/responses/Forbidden"
          },
          "404": {
            "$ref": "#/components/responses/NotFound"
          },
          "409": {
            "$ref": "#/components/responses/Conflict"
          },
          "422": {
            "$ref": "#/components/responses/Unprocessable"
          }
        }
      }
    },
    "/v1/ai/query": {
      "post": {
        "operationId": "postAiQuery",
        "summary": "Copiloto sobre los datos del tenant, con trace y citations.",
        "tags": [
          "ai"
        ],
        "security": [
          {
            "bearerFixtureToken": []
          }
        ],
        "x-ucotron-permission": "portfolio:read",
        "x-ucotron-idempotency-required": true,
        "x-ucotron-mode": "sbox_mocked",
        "parameters": [
          {
            "$ref": "#/components/parameters/TenantId"
          },
          {
            "$ref": "#/components/parameters/IdempotencyKey"
          }
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object"
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Aplicado."
          },
          "201": {
            "description": "Creado. `Location` apunta al recurso."
          },
          "202": {
            "description": "Aceptado. La respuesta describe el trabajo o la decisión."
          },
          "401": {
            "$ref": "#/components/responses/Unauthorized"
          },
          "403": {
            "$ref": "#/components/responses/Forbidden"
          },
          "404": {
            "$ref": "#/components/responses/NotFound"
          },
          "409": {
            "$ref": "#/components/responses/Conflict"
          },
          "422": {
            "$ref": "#/components/responses/Unprocessable"
          }
        }
      }
    }
  },
  "components": {
    "securitySchemes": {
      "bearerFixtureToken": {
        "type": "http",
        "scheme": "bearer",
        "description": "Token fixture del sandbox. Hay tres: acceso completo, sólo lectura y otra organización — para poder ejercitar 200, 403 y 404 cross-tenant. Ninguno es un secreto."
      }
    },
    "parameters": {
      "TenantId": {
        "name": "x-ucotron-tenant-id",
        "in": "header",
        "required": false,
        "schema": {
          "type": "string"
        },
        "description": "Organización. Si viene, tiene que coincidir con la de la credencial: un header que la sobreescribiera sería el propio bypass."
      },
      "IdempotencyKey": {
        "name": "idempotency-key",
        "in": "header",
        "required": true,
        "schema": {
          "type": "string",
          "minLength": 16,
          "maxLength": 128
        },
        "description": "Sin ella un reintento crearía un segundo recurso por la misma intención."
      },
      "Cursor": {
        "name": "cursor",
        "in": "query",
        "required": false,
        "schema": {
          "type": "string"
        },
        "description": "Opaco. Usá el `nextCursor` de la página anterior; construirlo a mano se rompe cuando cambie la paginación."
      },
      "Limit": {
        "name": "limit",
        "in": "query",
        "required": false,
        "schema": {
          "type": "integer",
          "minimum": 1,
          "maximum": 250,
          "default": 25
        }
      }
    },
    "schemas": {
      "ProblemDetails": {
        "type": "object",
        "properties": {
          "type": {
            "type": "string"
          },
          "title": {
            "type": "string"
          },
          "titleKey": {
            "type": "string"
          },
          "status": {
            "type": "integer"
          },
          "detail": {
            "type": "string"
          },
          "detailKey": {
            "type": "string"
          },
          "instance": {
            "type": "string"
          },
          "code": {
            "type": "string"
          },
          "messageKey": {
            "type": "string"
          },
          "requestId": {
            "type": "string"
          },
          "orgId": {
            "type": "string"
          },
          "retryable": {
            "type": "boolean"
          },
          "errors": {
            "type": "string"
          },
          "job": {
            "type": "string"
          }
        },
        "required": [
          "code",
          "detail",
          "detailKey",
          "instance",
          "messageKey",
          "requestId",
          "retryable",
          "status",
          "title",
          "titleKey",
          "type"
        ]
      },
      "CursorPage": {
        "type": "object",
        "required": [
          "data",
          "page"
        ],
        "properties": {
          "data": {
            "type": "array",
            "items": {
              "type": "object"
            }
          },
          "page": {
            "type": "object",
            "required": [
              "nextCursor",
              "previousCursor",
              "limit",
              "hasMore"
            ],
            "properties": {
              "nextCursor": {
                "type": [
                  "string",
                  "null"
                ]
              },
              "previousCursor": {
                "type": [
                  "string",
                  "null"
                ]
              },
              "limit": {
                "type": "integer"
              },
              "hasMore": {
                "type": "boolean"
              }
            }
          }
        }
      }
    },
    "responses": {
      "Unauthorized": {
        "description": "Sin credencial o con una que no verifica.",
        "content": {
          "application/problem+json": {
            "schema": {
              "$ref": "#/components/schemas/ProblemDetails"
            }
          }
        }
      },
      "Forbidden": {
        "description": "La credencial no tiene el permiso que la operación pide.",
        "content": {
          "application/problem+json": {
            "schema": {
              "$ref": "#/components/schemas/ProblemDetails"
            }
          }
        }
      },
      "NotFound": {
        "description": "No hay ese recurso en esta organización. Un recurso de OTRA organización también responde 404, nunca 403: un 403 confirmaría que existe en algún lado.",
        "content": {
          "application/problem+json": {
            "schema": {
              "$ref": "#/components/schemas/ProblemDetails"
            }
          }
        }
      },
      "BadRequest": {
        "description": "Cursor o `limit` inválidos.",
        "content": {
          "application/problem+json": {
            "schema": {
              "$ref": "#/components/schemas/ProblemDetails"
            }
          }
        }
      },
      "Conflict": {
        "description": "`Idempotency-Key` faltante, o reusada con otro cuerpo.",
        "content": {
          "application/problem+json": {
            "schema": {
              "$ref": "#/components/schemas/ProblemDetails"
            }
          }
        }
      },
      "Unprocessable": {
        "description": "El cuerpo no cumple el contrato del recurso.",
        "content": {
          "application/problem+json": {
            "schema": {
              "$ref": "#/components/schemas/ProblemDetails"
            }
          }
        }
      }
    },
    "examples": {
      "listPortfoliosResponse": {
        "summary": "Página determinista de portfolios (un elemento; la lista completa está en GET /v1/sbox/fixtures)",
        "value": {
          "data": [
            {
              "portfolioId": "portfolio_sbox_58159f1a",
              "org_id": "org_sbox_demo",
              "name": "SBOX Synthetic Agro Portfolio",
              "vertical": "agro",
              "currency": "USD",
              "insuredValue": 1250000,
              "aoiIds": [
                "aoi_sbox_f0c86d81",
                "aoi_sbox_d3a304ba"
              ]
            }
          ],
          "page": {
            "nextCursor": null,
            "previousCursor": null,
            "limit": 25,
            "hasMore": false
          }
        }
      },
      "listAoisResponse": {
        "summary": "Página determinista de aois (un elemento; la lista completa está en GET /v1/sbox/fixtures)",
        "value": {
          "data": [
            {
              "aoiId": "aoi_sbox_f0c86d81",
              "portfolioId": "portfolio_sbox_58159f1a",
              "name": "Synthetic Pergamino North AOI",
              "centroid": {
                "lat": -33.8921,
                "lon": -60.5736
              },
              "areaHectares": 182.4,
              "perilProfile": [
                "hail",
                "frost",
                "drought"
              ],
              "ring": [
                [
                  -60.580894,
                  -33.898178
                ],
                [
                  -60.566306,
                  -33.898178
                ],
                [
                  -60.566306,
                  -33.886022
                ],
                [
                  -60.580894,
                  -33.886022
                ]
              ],
              "aoiVersion": 1
            }
          ],
          "page": {
            "nextCursor": null,
            "previousCursor": null,
            "limit": 25,
            "hasMore": true
          }
        }
      },
      "listClientsResponse": {
        "summary": "Página determinista de clients (un elemento; la lista completa está en GET /v1/sbox/fixtures)",
        "value": {
          "data": [
            {
              "clientId": "client_sbox_e7d43e17",
              "displayName": "Cooperativa Sintética Pergamino",
              "taxIdRef": "synthetic-tax-id-sbox-001",
              "contactEmail": "cooperativa@sbox.invalid",
              "segment": "cooperativa",
              "createdAt": "2025-11-03T14:00:00.000Z"
            }
          ],
          "page": {
            "nextCursor": null,
            "previousCursor": null,
            "limit": 25,
            "hasMore": true
          }
        }
      },
      "listPoliciesResponse": {
        "summary": "Página determinista de policies (un elemento; la lista completa está en GET /v1/sbox/fixtures)",
        "value": {
          "data": [
            {
              "policyId": "policy_sbox_ac91ce43",
              "clientId": "client_sbox_e7d43e17",
              "portfolioId": "portfolio_sbox_58159f1a",
              "aoiIds": [
                "aoi_sbox_f0c86d81"
              ],
              "peril": "hail",
              "sumInsuredUsd": 780000,
              "deductiblePct": 10,
              "coverage": {
                "start": "2025-11-15T00:00:00.000Z",
                "end": "2026-04-30T00:00:00.000Z"
              },
              "status": "active"
            }
          ],
          "page": {
            "nextCursor": null,
            "previousCursor": null,
            "limit": 25,
            "hasMore": true
          }
        }
      },
      "listEventsResponse": {
        "summary": "Página determinista de events (un elemento; la lista completa está en GET /v1/sbox/fixtures)",
        "value": {
          "data": [
            {
              "eventId": "event_sbox_de4368bd",
              "peril": "hail",
              "occurredAt": "2026-01-14T21:00:00.000Z",
              "severity": "high",
              "centroid": {
                "lat": -33.8921,
                "lon": -60.5736
              },
              "affectedAoiIds": [
                "aoi_sbox_f0c86d81"
              ],
              "source": "synthetic_openapi_example"
            }
          ],
          "page": {
            "nextCursor": null,
            "previousCursor": null,
            "limit": 25,
            "hasMore": true
          }
        }
      },
      "listDetectionsResponse": {
        "summary": "Página determinista de detections (un elemento; la lista completa está en GET /v1/sbox/fixtures)",
        "value": {
          "data": [
            {
              "detectionId": "detection_sbox_b9b5cdb6",
              "eventId": "event_sbox_de4368bd",
              "aoiId": "aoi_sbox_f0c86d81",
              "computedAt": "2026-01-15T02:00:00.000Z",
              "affectedPct": 38,
              "damagedHectares": 69.3,
              "severity": "high",
              "method": "hail_ndvi_delta_fixture_v1",
              "provenance": {
                "provider": "fixture",
                "licenceTier": "noncommercial",
                "externalProviderCalls": false
              }
            }
          ],
          "page": {
            "nextCursor": null,
            "previousCursor": null,
            "limit": 25,
            "hasMore": true
          }
        }
      },
      "listClaimsResponse": {
        "summary": "Página determinista de claims (un elemento; la lista completa está en GET /v1/sbox/fixtures)",
        "value": {
          "data": [
            {
              "claimId": "claim_sbox_83d381c9",
              "aoiId": "aoi_sbox_f0c86d81",
              "peril": "hail",
              "status": "under_review",
              "eventWindow": {
                "start": "2026-01-14T20:00:00.000Z",
                "end": "2026-01-14T23:00:00.000Z"
              },
              "claimedLossUsd": 42000,
              "syntheticReporterRef": "synthetic_adjuster_sbox_001"
            }
          ],
          "page": {
            "nextCursor": null,
            "previousCursor": null,
            "limit": 25,
            "hasMore": false
          }
        }
      },
      "listPeritajesResponse": {
        "summary": "Página determinista de peritajes (un elemento; la lista completa está en GET /v1/sbox/fixtures)",
        "value": {
          "data": [
            {
              "peritajeId": "peritaje_sbox_e74f00de",
              "claimId": "claim_sbox_83d381c9",
              "detectionId": "detection_sbox_b9b5cdb6",
              "status": "signed",
              "assessedLossUsd": 38700,
              "dossierRef": "packages/ingestion/src/fixtures/claims-dossier-local.fixture.json",
              "signedManifestId": "verify_manifest_fixture_ucx_sec_002_claims_dossier_001"
            }
          ],
          "page": {
            "nextCursor": null,
            "previousCursor": null,
            "limit": 25,
            "hasMore": false
          }
        }
      },
      "listReportsResponse": {
        "summary": "Página determinista de reports (un elemento; la lista completa está en GET /v1/sbox/fixtures)",
        "value": {
          "data": [
            {
              "reportId": "report_sbox_5e7cfce9",
              "claimId": "claim_sbox_83d381c9",
              "status": "draft",
              "templateId": "template_sbox_hail_claims_public_example_v1",
              "version": 1,
              "evidenceRefs": [
                "fixture://sbox/weather/weather_sbox_hail_001",
                "fixture://sbox/aoi/synthetic_pergamino_north"
              ],
              "signature": null
            }
          ],
          "page": {
            "nextCursor": null,
            "previousCursor": null,
            "limit": 25,
            "hasMore": true
          }
        }
      },
      "listWeatherResponse": {
        "summary": "Página determinista de weather (un elemento; la lista completa está en GET /v1/sbox/fixtures)",
        "value": {
          "data": [
            {
              "weatherId": "weather_sbox_hail_001",
              "aoiId": "aoi_sbox_f0c86d81",
              "observedAt": "2026-01-14T21:00:00.000Z",
              "source": "synthetic_openapi_example",
              "hailProbability": 0.82,
              "windKph": 64,
              "precipitationMm": 28.6
            }
          ],
          "page": {
            "nextCursor": null,
            "previousCursor": null,
            "limit": 25,
            "hasMore": false
          }
        }
      },
      "listWatchSubscriptionsResponse": {
        "summary": "Página determinista de subscriptions (un elemento; la lista completa está en GET /v1/sbox/fixtures)",
        "value": {
          "data": [
            {
              "subscriptionId": "watch_sbox_535b0a61",
              "aoiIds": [
                "aoi_sbox_f0c86d81",
                "aoi_sbox_d3a304ba"
              ],
              "perils": [
                "hail",
                "flood"
              ],
              "minSeverity": "medium",
              "status": "active",
              "createdAt": "2025-11-20T12:00:00.000Z"
            }
          ],
          "page": {
            "nextCursor": null,
            "previousCursor": null,
            "limit": 25,
            "hasMore": false
          }
        }
      },
      "listAlertsResponse": {
        "summary": "Página determinista de alerts (un elemento; la lista completa está en GET /v1/sbox/fixtures)",
        "value": {
          "data": [
            {
              "alertId": "alert_sbox_3469dc1c",
              "subscriptionId": "watch_sbox_535b0a61",
              "eventId": "event_sbox_de4368bd",
              "aoiId": "aoi_sbox_f0c86d81",
              "level": "high",
              "raisedAt": "2026-01-14T21:05:00.000Z",
              "acknowledgedAt": null
            }
          ],
          "page": {
            "nextCursor": null,
            "previousCursor": null,
            "limit": 25,
            "hasMore": false
          }
        }
      },
      "listWebhookSubscriptionsResponse": {
        "summary": "Página determinista de subscriptions (un elemento; la lista completa está en GET /v1/sbox/fixtures)",
        "value": {
          "data": [
            {
              "subscriptionId": "whsub_sbox_ec8b444b",
              "endpointUrl": "https://webhooks.sbox.invalid/ucotron",
              "eventTypes": [
                "claim.created",
                "report.approved",
                "weather.alert"
              ],
              "signingKeyRef": "fixture-key:sbox-webhook-non-secret",
              "status": "active",
              "createdAt": "2025-11-20T12:05:00.000Z"
            }
          ],
          "page": {
            "nextCursor": null,
            "previousCursor": null,
            "limit": 25,
            "hasMore": false
          }
        }
      }
    }
  }
}