> ## Documentation Index
> Fetch the complete documentation index at: https://docs.docta.com.ar/llms.txt
> Use this file to discover all available pages before exploring further.

# Buscar instrumentos

> Buscar instrumentos de bonos

<Note>
  Busca instrumentos de bonos por texto.
</Note>

## Parámetros de consulta

<ParamField query="query" type="string" required>
  Ticker del bono (ej., "AL30").
</ParamField>

<ParamField query="limit" type="integer">
  Límite de resultados (predeterminado 10).
</ParamField>

<ParamField query="cursor" type="string">
  Cursor de paginación.
</ParamField>

## Ejemplo de Solicitud

<RequestExample>
  ```bash cURL theme={null}
  curl -X GET "https://api.doctacapital.com.ar/api/v1/bonds/instruments/search?query=AL30&limit=10" \
    -H "Authorization: Bearer YOUR_ACCESS_TOKEN"
  ```
</RequestExample>

## Respuesta Exitosa

<ResponseField name="data" type="array">
  Lista de instrumentos encontrados.
</ResponseField>

<ResponseField name="data[].ticker" type="string">
  Ticker del bono (ej., "AL30").
</ResponseField>

<ResponseField name="data[].asset_class" type="string">
  Clase de activo del bono.
</ResponseField>

<ResponseField name="data[].sub_asset_class" type="string">
  Subclase de activo del bono.
</ResponseField>

<ResponseField name="query" type="string">
  Consulta de búsqueda utilizada.
</ResponseField>

<ResponseField name="pagination" type="object">
  Información de paginación.
</ResponseField>

<ResponseField name="pagination.next_cursor" type="string | null">
  Cursor para obtener la siguiente página. Es null si no hay más páginas.
</ResponseField>

<ResponseField name="pagination.has_next" type="boolean">
  Indica si hay más páginas disponibles.
</ResponseField>

<ResponseField name="metadata" type="object">
  Metadatos de la respuesta.
</ResponseField>

<ResponseField name="metadata.total_records" type="integer">
  Número total de registros encontrados.
</ResponseField>

## Ejemplo de Respuesta Exitosa

<ResponseExample>
  ```json Success theme={null}
  {
    "data": [
      {
        "ticker": "AL30",
        "asset_class": "BONO AL30",
        "sub_asset_class": "HARD_DOLLAR",
      }
    ],
    "pagination": {
      "next_cursor": null,
      "has_next": false
    },
    "metadata": {
      "total_records": 1
    }
  }
  ```
</ResponseExample>


## OpenAPI

````yaml GET /api/v1/bonds/instruments/search
openapi: 3.1.0
info:
  title: API de Docta
  description: >-
    API de mercado argentino: bonos (instrumentos, cashflows, curvas/yields) y
    FCI (screener, series, performance, comparaciones y analytics de industria).
  license:
    name: MIT
  version: 1.0.0
servers:
  - url: https://api.doctacapital.com.ar
security: []
paths:
  /api/v1/bonds/instruments/search:
    get:
      tags:
        - Bonds
      description: Buscar instrumentos de bonos
      parameters:
        - name: query
          in: query
          required: true
          schema:
            type: string
        - name: limit
          in: query
          required: false
          schema:
            type: integer
            default: 10
        - name: cursor
          in: query
          required: false
          schema:
            type: string
            nullable: true
      responses:
        '200':
          description: Resultados de búsqueda
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/InstrumentsSearchResponse'
        '400':
          description: Solicitud incorrecta - parámetros inválidos
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Error'
        '401':
          description: No autorizado - token de acceso inválido o faltante
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Error'
              example:
                type: /errors/authentication-required
                title: Authorization header missing
                status: 401
                detail: Authorization header missing
                correlation_id: d6e20e07-0580-4e2d-9480-00a68c1ae493
        '500':
          description: Error interno del servidor
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Error'
              example:
                type: /errors/internal-server-error
                title: Internal server error
                status: 500
                detail: Internal server error
                correlation_id: 6cd1fd05-63e9-4863-832f-d873e58e9d67
      security:
        - bearerAuth: []
components:
  schemas:
    InstrumentsSearchResponse:
      type: object
      properties:
        data:
          type: array
          items: d35ef57d-a499-40c2-9722-d26082682982
        query:
          type: string
          description: Consulta de búsqueda utilizada
        pagination: 4da7bdb3-a9d9-4c04-94ab-4c6ef4706dc3
        metadata: 23993667-9975-47f1-aa49-6dda87fcf7b9
      required:
        - data
        - query
        - pagination
        - metadata
    Error:
      required:
        - type
        - title
        - status
        - detail
        - correlation_id
      type: object
      properties:
        type:
          description: El identificador del tipo de error
          type: string
          example: /errors/authentication-required
        title:
          description: Una breve descripción del error
          type: string
          example: Invalid client credentials
        status:
          description: El código de estado HTTP
          type: integer
          example: 401
        detail:
          description: Una descripción detallada del error
          type: string
          example: Invalid client credentials
        correlation_id:
          description: Un identificador único para rastrear esta solicitud de error
          type: string
          format: uuid
          example: 2eb07802-94de-468a-b70f-75a49f3e9516
  securitySchemes:
    bearerAuth:
      type: http
      scheme: bearer

````