---
title: "Búsqueda federada"
method: GET
path: "/v1/buscar"
tags: ["Búsqueda"]
---

# Búsqueda federada

`GET /v1/buscar`

## Request

- Base URL: `https://api.alfil.co`
- URL: `https://api.alfil.co/v1/buscar`
- Auth: OAuth 2 (authorization code, authorization URL `https://api.alfil.co/oauth/authorize`, token URL `https://api.alfil.co/oauth/token`, scopes: `buscar:read`)

Descubre y desambigua sobre políticos, partidos, contratos e investigaciones.

## Query parameters

- `cursor` string
- `limit` integer
- `q` string, required
- `tipos` string[]
- `response_format` 'concise' | 'detailed'

## Response `200`

Resultados de búsqueda

- BuscarResponse
  - `data` ResultadoBusqueda[], required
    - `tipo` 'politico' | 'partido' | 'contrato' | 'investigacion', required
    - `id` string, required: Conector tipado a la tool de detalle
    - `titulo` string, required
    - `resumen` string, required
    - `destacado` object: Campos de desambiguación por tipo
    - `url` string, required
    - `referencias` Referencia[], required
      - `tipo` 'pagina_alfil' | 'registro_oficial' | 'documento_oficial' | 'coleccion_oficial', required
      - `titulo` string, required
      - `url` string, uri, required
      - `proveedor` string, required
      - `id_externo` string
    - `acciones` AccionSugerida[]: Solo en response_format=detailed
      - `tool` string, required: Tool MCP para profundizar
      - `args` object, required: Argumentos ya armados
  - `page` Page, required: Paginación por cursor opaco (no offset)
    - `cursor` string, nullable, required: Cursor opaco de la siguiente página; null si no hay más
    - `has_more` boolean, required: Indica si existen más resultados
  - `fuente` Fuente, required: Proveniencia: fuente oficial y fecha de corte (atribución Ley 1712)
    - `nombre` string, required: Fuente oficial del dato
    - `url` string: URL de la fuente oficial
    - `corte` string, required: Fecha de corte del dato (ISO 8601)
    - `licencia` string: Licencia de la fuente

## Other responses

- `401`: Token faltante, expirado o de emisor inesperado
- `403`: Scope insuficiente
- `429`: Cuota agotada o rate limit

---

[API](https://skmtc.dev/alfil/apis/alfil-api.md) · [All operations](https://skmtc.dev/alfil/apis/alfil-api/llms.txt) · [OpenAPI document](https://skmtc.dev/alfil/apis/alfil-api/revisions/e2545a4c45a5?raw)
