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

# Check DARF

> Check a DARF



## OpenAPI

````yaml v2/api-reference/openapi.json POST /v2/out/darf/check
openapi: 3.0.0
info:
  title: Trio API v2
  version: 2026-10-19.v2
servers:
  - url: https://api.sandbox.trio.com.br
    variables: {}
  - url: https://api.qa.trio.com.br
    variables: {}
  - url: https://api.trio.com.br
    variables: {}
security: []
tags: []
paths:
  /v2/out/darf/check:
    parameters:
      - description: >-
          Version of the v2 contract the client is written against. Each
          breaking change publishes a new version.
        example: 2026-10-19.v2
        in: header
        name: Trio-Version
        required: true
        schema:
          enum:
            - 2026-10-19.v2
          type: string
          x-struct: null
          x-validate: null
      - description: >-
          ID of another org to act on instead of the API key's own org. The
          key's org must have been granted access to it, and the request is
          refused with 403 FORBIDDEN otherwise. When that access or the API key
          is read-only, only GET and HEAD requests may carry it. When the target
          org requires mTLS, so does the request. Leave it out to act on the
          key's own org.
        in: header
        name: Trio-Target-Org-Id
        required: false
        schema:
          format: uuid
          type: string
          x-struct: null
          x-validate: null
    post:
      tags:
        - Payments (out)
        - Darf
      summary: Check DARF
      description: Check a DARF
      operationId: TrioFoundationWeb.V2.Out.DarfController.check
      parameters: []
      requestBody:
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/V2_Check_Darf_Request'
        description: Check DARF payload
        required: true
      responses:
        '200':
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/V2_Check_Darf_Response'
          description: Check
        '400':
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/V2_error'
          description: >-
            Malformed request: a body that is not valid JSON
            (MALFORMED_REQUEST), or a Trio-Version header that is missing or not
            the current one (INVALID_TRIO_VERSION).
        '401':
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/V2_error'
          description: Missing or invalid API key credentials (INVALID_CREDENTIALS).
        '403':
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/V2_error'
          description: >-
            The API key may not do this (FORBIDDEN): for instance
            Trio-Target-Org-Id names an org it has no access to, or writes
            through a read-only access.
        '422':
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/V2_error'
          description: >-
            Invalid input (INVALID_PARAMETER, REQUIRED_PARAMETER, or the code of
            the rule the request breaks). A request outside the operation's
            schema lists the offending fields in `errors`.
        '503':
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/V2_error'
          description: >-
            A service needed to answer is unavailable
            (TRIO_SERVICE_UNAVAILABLE).
      callbacks: {}
      security:
        - authorization: []
components:
  schemas:
    V2_Check_Darf_Request:
      description: >-
        The DARF to check, as the check response publishes it. A DARF is always
        paid to Receita Federal, so it has a taxpayer and no beneficiary.
      example:
        accumulated_revenue_amount:
          amount: 0
          currency: BRL
        amount:
          amount: 13208
          currency: BRL
        assessment_date: '2026-01-01'
        authentication_date: '2026-01-30'
        due_date: '2026-01-30'
        federal_revenue_id: '473'
        fine_amount:
          amount: 1001
          currency: BRL
        interest_amount:
          amount: 1001
          currency: BRL
        percentage: 0
        phone: '+5541999381724'
        reference_number: null
        taxpayer:
          name: John Doe
          tax_number: '52998224725'
      properties:
        accumulated_revenue_amount:
          $ref: '#/components/schemas/V2_DARF_money'
        amount:
          $ref: '#/components/schemas/V2_DARF_money'
        assessment_date:
          description: Assessment period (período de apuração)
          format: date
          type: string
          x-struct: null
          x-validate: null
        authentication_date:
          description: Authentication date
          format: date
          type: string
          x-struct: null
          x-validate: null
        due_date:
          description: Due date
          format: date
          type: string
          x-struct: null
          x-validate: null
        federal_revenue_id:
          description: Revenue code (código da receita)
          type: string
          x-struct: null
          x-validate: null
        fine_amount:
          $ref: '#/components/schemas/V2_DARF_money'
        interest_amount:
          $ref: '#/components/schemas/V2_DARF_money'
        percentage:
          description: Percentage
          type: integer
          x-struct: null
          x-validate: null
        phone:
          description: Taxpayer phone number
          type: string
          x-struct: null
          x-validate: null
        reference_number:
          description: Reference number
          nullable: true
          type: integer
          x-struct: null
          x-validate: null
        taxpayer:
          description: Taxpayer the DARF belongs to
          properties:
            name:
              description: Name
              type: string
              x-struct: null
              x-validate: null
            tax_number:
              description: CPF or CNPJ
              type: string
              x-struct: null
              x-validate: null
          required:
            - name
            - tax_number
          type: object
          x-struct: null
          x-validate: null
      required:
        - taxpayer
        - federal_revenue_id
        - amount
        - fine_amount
        - interest_amount
        - accumulated_revenue_amount
        - percentage
        - assessment_date
        - due_date
        - authentication_date
        - phone
      title: V2 Check_Darf_Request
      type: object
      x-struct: >-
        Elixir.TrioFoundationWeb.Schemas.Banking.V2.Cashout.Darf.DarfSchema.CheckRequest
      x-validate: null
    V2_Check_Darf_Response:
      description: >-
        A DARF checked before it is paid. A DARF is always paid to Receita
        Federal, so it has a taxpayer and no beneficiary.
      example:
        data:
          accumulated_revenue_amount:
            amount: 0
            currency: BRL
          amount:
            amount: 13208
            currency: BRL
          assessment_date: '2022-11-04'
          authentication_date: '2022-11-04'
          due_date: '2022-11-04'
          federal_revenue_id: '473'
          fine_amount:
            amount: 1001
            currency: BRL
          id: 019cdabf-5a3e-7c21-9f10-2b6d8e4c1a77
          inserted_at: '2026-03-11T02:34:58.120000Z'
          interest_amount:
            amount: 1001
            currency: BRL
          percentage: 0
          reference_number: null
          taxpayer:
            name: John Doe
            tax_number: '***982247**'
          type: darf
          updated_at: '2026-03-11T02:34:58.120000Z'
      properties:
        data:
          properties:
            accumulated_revenue_amount:
              description: Accumulated revenue amount
              nullable: true
              properties:
                amount:
                  description: Amount in cents
                  type: integer
                  x-struct: null
                  x-validate: null
                currency:
                  description: Currency
                  type: string
                  x-struct: null
                  x-validate: null
              type: object
              x-struct: null
              x-validate: null
            amount:
              description: DARF principal amount
              nullable: true
              properties:
                amount:
                  description: Amount in cents
                  type: integer
                  x-struct: null
                  x-validate: null
                currency:
                  description: Currency
                  type: string
                  x-struct: null
                  x-validate: null
              type: object
              x-struct: null
              x-validate: null
            assessment_date:
              description: Assessment period (período de apuração)
              format: date
              type: string
              x-struct: null
              x-validate: null
            authentication_date:
              description: Authentication date
              format: date
              nullable: true
              type: string
              x-struct: null
              x-validate: null
            due_date:
              description: Due date
              format: date
              type: string
              x-struct: null
              x-validate: null
            federal_revenue_id:
              description: Revenue code (código da receita)
              type: string
              x-struct: null
              x-validate: null
            fine_amount:
              description: Fine amount
              nullable: true
              properties:
                amount:
                  description: Amount in cents
                  type: integer
                  x-struct: null
                  x-validate: null
                currency:
                  description: Currency
                  type: string
                  x-struct: null
                  x-validate: null
              type: object
              x-struct: null
              x-validate: null
            id:
              description: Check ID
              format: uuid
              type: string
              x-struct: null
              x-validate: null
            inserted_at:
              description: When the check was made
              format: date-time
              type: string
              x-struct: null
              x-validate: null
            interest_amount:
              description: Interest amount
              nullable: true
              properties:
                amount:
                  description: Amount in cents
                  type: integer
                  x-struct: null
                  x-validate: null
                currency:
                  description: Currency
                  type: string
                  x-struct: null
                  x-validate: null
              type: object
              x-struct: null
              x-validate: null
            percentage:
              description: Percentage
              nullable: true
              type: integer
              x-struct: null
              x-validate: null
            reference_number:
              description: Reference number
              nullable: true
              type: integer
              x-struct: null
              x-validate: null
            taxpayer:
              description: Taxpayer the DARF belongs to
              properties:
                name:
                  description: Name
                  nullable: true
                  type: string
                  x-struct: null
                  x-validate: null
                tax_number:
                  description: >-
                    Tax number. A CPF is masked (e.g. ***982247**); a CNPJ is
                    published as is
                  nullable: true
                  type: string
                  x-struct: null
                  x-validate: null
              type: object
              x-struct: null
              x-validate: null
            type:
              description: Payment type
              enum:
                - darf
              type: string
              x-struct: null
              x-validate: null
            updated_at:
              description: When the check was last updated
              format: date-time
              type: string
              x-struct: null
              x-validate: null
          type: object
          x-struct: null
          x-validate: null
      title: V2 Check_Darf_Response
      type: object
      x-struct: >-
        Elixir.TrioFoundationWeb.Schemas.Banking.V2.Cashout.Darf.DarfSchema.CheckResponse
      x-validate: null
    V2_error:
      example:
        error:
          error_code: INVALID_PARAMETER
          error_message: 'Invalid parameters: /amount: Invalid integer. Got: string'
          errors:
            - field: /amount
              message: 'Invalid integer. Got: string'
      properties:
        error:
          properties:
            error_code:
              description: >-
                Stable UPPER_SNAKE identifier of the error, for programs and
                logs. Branch on this, not on the message.
              type: string
              x-struct: null
              x-validate: null
            error_message:
              description: Human readable explanation of the error.
              type: string
              x-struct: null
              x-validate: null
            errors:
              description: >-
                Only on INVALID_PARAMETER for a request outside the operation's
                schema: one entry per offending field.
              items:
                properties:
                  field:
                    description: JSON pointer to the field, e.g. /amount.
                    type: string
                    x-struct: null
                    x-validate: null
                  message:
                    description: What is wrong with it.
                    type: string
                    x-struct: null
                    x-validate: null
                required:
                  - field
                  - message
                type: object
                x-struct: null
                x-validate: null
              type: array
              x-struct: null
              x-validate: null
          required:
            - error_code
            - error_message
          type: object
          x-struct: null
          x-validate: null
      required:
        - error
      title: V2 error
      type: object
      x-struct: Elixir.TrioFoundationWeb.Schemas.HTTP.V2Error
      x-validate: null
    V2_DARF_money:
      description: An amount of a DARF
      example:
        amount: 1001
        currency: BRL
      properties:
        amount:
          description: Amount in cents
          minimum: 0
          type: integer
          x-struct: null
          x-validate: null
        currency:
          description: Currency
          enum:
            - BRL
          type: string
          x-struct: null
          x-validate: null
      required:
        - amount
        - currency
      title: V2 DARF money
      type: object
      x-struct: >-
        Elixir.TrioFoundationWeb.Schemas.Banking.V2.Cashout.Darf.DarfSchema.Money
      x-validate: null
  securitySchemes:
    authorization:
      scheme: basic
      type: http

````

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