> ## 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.

# Authorize payment

> Authorizes a payment using a FIDO assertion.



## OpenAPI

````yaml api-reference/banking-api/receivables/biometrics/openapi.json POST /biometrics/enrollments/{enrollment_id}/payments/{payment_id}/authorize
openapi: 3.0.0
info:
  title: Trio Biometrics API
  version: 0.1.0
servers:
  - url: http://api.trio.com.br
    variables: {}
security: []
tags: []
paths:
  /biometrics/enrollments/{enrollment_id}/payments/{payment_id}/authorize:
    post:
      tags:
        - biometrics
      summary: Authorize payment with biometrics
      description: Authorizes a payment using a FIDO assertion.
      operationId: TrioInitiationWeb.Biometrics.PaymentController.authorize
      parameters:
        - description: Enrollment ID
          in: path
          name: enrollment_id
          required: true
          schema:
            type: string
        - description: ITP Document ID (payment)
          in: path
          name: payment_id
          required: true
          schema:
            type: string
      requestBody:
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/FIDO_assertion_parameters'
        description: FIDO assertion
        required: true
      responses:
        '200':
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Payment_response'
          description: Payment
        '401':
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/JsonErrorResponse'
          description: Unprocessable Entity
        '422':
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/JsonErrorResponse'
          description: Unprocessable Entity
        '500':
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/JsonErrorResponse'
          description: Unprocessable Entity
      callbacks: {}
components:
  schemas:
    FIDO_assertion_parameters:
      description: FIDO assertion for authorizing a payment
      example:
        fido_assertion:
          id: credential_id_example
          raw_id: raw_credential_id_example
          response:
            authenticator_data: authenticator_data_example
            client_data_JSON: client_data_json_example
            signature: signature_example
            user_handle: user_handle_example
          type: public-key
        riskSignals: null
      properties:
        fido_assertion:
          $ref: '#/components/schemas/FIDO_assertion'
        riskSignals:
          description: Risk signals
          nullable: true
          type: object
      required:
        - fido_assertion
      title: FIDO_assertion_parameters
      type: object
    Payment_response:
      description: Response schema for a biometric payment
      example:
        data:
          amount:
            amount: 1000
            currency: BRL
          description: Payment description example
          end_to_end_id: E12345678202607252301s6AO2vwTrlD
          external_id: external_id_example
          id: 019f9fbf-2cd7-160a-b0ae-3b02f310bcc8
          inserted_at: '2026-07-26T00:00:00Z'
          status: pending
          transaction_date: '2026-07-26'
          updated_at: '2026-07-26T00:00:00Z'
          virtual_account_id: 019f9fbf-2cd7-ae17-3015-a65b66719fc0
      properties:
        data:
          $ref: '#/components/schemas/Payment'
      title: Payment_response
      type: object
    JsonErrorResponse:
      properties:
        errors:
          items:
            properties:
              detail:
                example: null value where string expected
                type: string
              source:
                properties:
                  pointer:
                    example: /data/attributes/petName
                    type: string
                required:
                  - pointer
                type: object
              title:
                example: Invalid value
                type: string
            required:
              - title
              - source
              - detail
            type: object
          type: array
      required:
        - errors
      title: JsonErrorResponse
      type: object
    FIDO_assertion:
      description: FIDO assertion credential object
      type: object
      required:
        - id
        - raw_id
        - response
        - type
      properties:
        id:
          description: Credential ID
          type: string
        raw_id:
          description: Raw credential ID
          type: string
        response:
          $ref: '#/components/schemas/FIDO_assertion_response'
        type:
          description: Credential type
          type: string
    Payment:
      description: A biometric payment initiation
      example:
        amount:
          amount: 1000
          currency: BRL
        description: Payment description example
        end_to_end_id: null
        external_id: external_id_example
        id: 019f9fbf-2cb3-a8d4-9ebe-0c7781f37117
        inserted_at: '2026-07-26T00:00:00Z'
        status: pending
        transaction_date: null
        updated_at: '2026-07-26T00:00:00Z'
        virtual_account_id: 019f9fbf-2cb4-4e0d-1e20-2d6b9b27dbf0
      properties:
        amount:
          description: Amount
          type: object
          properties:
            amount:
              description: Amount in cents
              type: integer
            currency:
              description: Currency code
              type: string
        description:
          description: Payment description
          type: string
        end_to_end_id:
          description: End to end ID
          nullable: true
          type: string
        external_id:
          description: External ID
          nullable: true
          type: string
        id:
          description: Payment ID
          format: uuid
          type: string
        inserted_at:
          description: Created at
          format: date-time
          type: string
        status:
          description: Payment status
          type: string
        transaction_date:
          description: Transaction date
          format: date
          nullable: true
          type: string
        updated_at:
          description: Updated at
          format: date-time
          type: string
        virtual_account_id:
          description: Virtual account ID
          format: uuid
          nullable: true
          type: string
      title: Payment
      type: object
    FIDO_assertion_response:
      description: FIDO assertion response data
      type: object
      required:
        - authenticator_data
        - client_data_JSON
        - signature
        - user_handle
      properties:
        authenticator_data:
          description: Authenticator data
          type: string
        client_data_JSON:
          description: Client data JSON
          type: string
        signature:
          description: Signature
          type: string
        user_handle:
          description: User handle
          type: string

````