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

> ## Agent Instructions
> Test in the sandbox first: base URL https://api-sandbox.y.uno (Test Mode in the Dashboard). Production is https://api.y.uno (Live Mode).
> Every API request needs the public-api-key and private-secret-key headers. Get them in the Dashboard at https://dashboard.y.uno/developers (Developers > Credentials); sandbox and production keys are different.
> Send an X-Idempotency-Key (a UUID) when creating payments, refunds and cancels, so retries do not create duplicates.
> Start with the Quickstart (https://docs.y.uno/docs/quickstart.md) and the agent guide (https://docs.y.uno/agents.md). To search these docs from a coding agent, connect the docs MCP server at https://docs.y.uno/mcp.

# Baixar um relatório

> Consulta o link de download de um relatório gerado usando o ID do relatório.

> [!WARNING]
>
> **Atualização recente do endpoint**
>
> Este endpoint foi atualizado recentemente para a versão 2 (veja "V2" na URL). A versão 1 foi descontinuada; recomendamos migrar para a V2 o quanto antes.

Para obter o conteúdo do arquivo, use as suas credenciais de API para acessar o arquivo indicado pelo `id` do objeto de relatório.

> [!NOTE]
>
> **Download de relatórios**
>
> A resposta da API inclui um link para baixar o relatório. Abra o link no navegador para acessar os dados.

Veja os links a seguir para acessar exemplos de vários relatórios:

> [card] [Pagamentos](https://github.com/yuno-payments/yuno-docs/raw/refs/heads/main/raw-files/report-examples/example-payments-csv.zip)

> [card] [Liquidações e tarifas](https://github.com/yuno-payments/yuno-docs/raw/refs/heads/main/raw-files/report-examples/example-settlement-fees-report.csv.zip)

> [card] [Payouts de liquidação](https://github.com/yuno-payments/yuno-docs/raw/refs/heads/main/raw-files/report-examples/example-settlement-payouts-report.csv.zip)

> [card] [Relatório de transações](https://github.com/yuno-payments/yuno-docs/raw/refs/heads/main/raw-files/report-examples/example-transaction-report-csv.zip)

> [card] [Visão geral da conciliação](https://github.com/yuno-payments/yuno-docs/raw/refs/heads/main/raw-files/report-examples/example-reconciliation-overview-report.csv.zip)

> [card] [Comunicações](https://github.com/yuno-payments/yuno-docs/raw/refs/heads/main/raw-files/report-examples/example-communications-csv.zip)


## OpenAPI

````yaml openapi/pt-br/reports/download-a-report.json GET /reports/{report_id}/download 
openapi: 3.1.0
info:
  title: reports-download-a-report-v2
  version: 1.0.2
servers:
  - url: https://api-sandbox.y.uno/v2
  - url: https://api.y.uno/v2
security:
  - sec0: []
    sec1: []
paths:
  /reports/{report_id}/download:
    get:
      summary: Baixar um relatório
      operationId: download-a-report
      parameters:
        - name: X-Organization-Code
          in: header
          required: true
          schema:
            type: string
          description: Código da organização associado à requisição.
        - name: report_id
          in: path
          required: true
          description: O identificador único do relatório.
          schema:
            type: string
      responses:
        '200':
          description: '200'
          content:
            application/json:
              examples:
                Result:
                  value:
                    type: TRANSACTIONS
                    download_link: https://s3.amazonaws.com/.../report.csv
                    status: AVAILABLE
              schema:
                type: object
                properties:
                  type:
                    type: string
                    example: TRANSACTIONS
                  download_link:
                    type: string
                    example: https://s3.amazonaws.com/.../report.csv
                  status:
                    type: string
                    example: AVAILABLE
        '400':
          description: '400'
          content:
            application/json:
              examples:
                Bad Request:
                  value:
                    code: INVALID_REQUEST
                    messages:
                      - Invalid request
              schema:
                type: object
                properties:
                  code:
                    type: string
                    example: INVALID_REQUEST
                  messages:
                    type: array
                    items:
                      type: string
                      example: Invalid request
        '401':
          description: '401'
          content:
            application/json:
              examples:
                Unauthorized:
                  value:
                    code: INVALID_CREDENTIALS
                    messages:
                      - Invalid credentials
              schema:
                type: object
                properties:
                  code:
                    type: string
                    example: INVALID_CREDENTIALS
                  messages:
                    type: array
                    items:
                      type: string
                      example: Invalid credentials
        '403':
          description: '403'
          content:
            application/json:
              examples:
                Forbidden:
                  value:
                    code: AUTHORIZATION_REQUIRED
                    messages:
                      - The merchant has no authorization to use this API.
              schema:
                type: object
                properties:
                  code:
                    type: string
                    example: AUTHORIZATION_REQUIRED
                  messages:
                    type: array
                    items:
                      type: string
                      example: The merchant has no authorization to use this API.
      deprecated: false
components:
  securitySchemes:
    sec0:
      type: apiKey
      in: header
      name: public-api-key
      x-default: <Your public-api-key>
    sec1:
      type: apiKey
      in: header
      name: private-secret-key
      x-default: <Your private-secret-key>

````

This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.