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

# Recuperar uma chave

> Use este endpoint para recuperar os detalhes de uma chave Pix para fins
de pagamento. Esta operação consulta o sistema DICT para obter as
informações da conta associadas a uma chave Pix, permitindo validar e
preparar os destinos de pagamento.



## OpenAPI

````yaml pt/openapi/v3-current/indirect-pix.yaml GET /v1/dict/keys/{key}
openapi: 3.0.3
info:
  title: Plugin BR Pix Indireto - API Completa
  description: |
    API completa para o sistema brasileiro de pagamentos instantâneos Pix,
    incluindo operações de dicionário de chaves Pix, geração/decodificação de
    QR Code, transações e limites de transações.
  version: 1.0.0
servers:
  - url: https://plugin-pix-indirect.api.lerian.net
security:
  - bearerAuth: []
paths:
  /v1/dict/keys/{key}:
    get:
      tags:
        - DICT API
      summary: Recuperar uma chave
      description: |-
        Use este endpoint para recuperar os detalhes de uma chave Pix para fins
        de pagamento. Esta operação consulta o sistema DICT para obter as
        informações da conta associadas a uma chave Pix, permitindo validar e
        preparar os destinos de pagamento.
      parameters:
        - $ref: '#/components/parameters/KeyPath'
        - $ref: '#/components/parameters/XAccountId'
        - $ref: '#/components/parameters/XEndToEndId'
      responses:
        '200':
          description: Detalhes da chave Pix recuperados com sucesso.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/GetKeyOutput'
        '400':
          description: ''
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ErrorFormat'
              examples:
                ErrorPIX0001:
                  $ref: '#/components/examples/ErrorPIX0001'
                ErrorPIX0002:
                  $ref: '#/components/examples/ErrorPIX0002'
                ErrorPIX0008:
                  $ref: '#/components/examples/ErrorPIX0008'
        '404':
          description: ''
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ErrorFormat'
              examples:
                ErrorPIX1005:
                  $ref: '#/components/examples/ErrorPIX1005'
        '422':
          description: Unprocessable Entity
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ErrorFormat'
              examples:
                ErrorPIX0114:
                  $ref: '#/components/examples/ErrorPIX0114'
        '500':
          description: Internal Server Error
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ErrorFormat'
              examples:
                ErrorPIX0000:
                  $ref: '#/components/examples/ErrorPIX0000'
        '502':
          description: Bad Gateway
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ErrorFormat'
              examples:
                ErrorPIX1000:
                  $ref: '#/components/examples/ErrorPIX1000'
                ErrorPIX1007:
                  $ref: '#/components/examples/ErrorPIX1007'
                ErrorPIX1099:
                  $ref: '#/components/examples/ErrorPIX1099'
      deprecated: false
      security:
        - bearerAuth: []
components:
  parameters:
    KeyPath:
      name: key
      in: path
      description: Valor da chave Pix (CPF, CNPJ, E-mail, Telefone ou EVP).
      required: true
      example: john.doe@example.com
      schema:
        type: string
    XAccountId:
      name: X-Account-Id
      in: header
      description: Identificador único da Conta do Ledger Midaz (formato UUID).
      required: true
      example: 019c96a0-0a98-7287-9a31-786e0809c769
      schema:
        type: string
    XEndToEndId:
      name: X-EndToEnd-Id
      in: header
      description: >-
        Identificador end-to-end opcional do SPI usado em propostas de
        pagamento.
      required: false
      example: E123456789BR1234567890123456789
      schema:
        type: string
  schemas:
    GetKeyOutput:
      type: object
      properties:
        key:
          type: string
          description: Valor da chave Pix.
          example: john.doe@example.com
        keyType:
          type: string
          description: Tipo de chave Pix.
          example: EMAIL
        account:
          $ref: '#/components/schemas/AccountDetails'
        owner:
          $ref: '#/components/schemas/OwnerDetails'
    ErrorFormat:
      type: object
      description: A mensagem de erro da resposta.
      required:
        - code
        - title
        - message
      properties:
        code:
          type: string
          description: Um identificador único e estável para o erro.
        title:
          type: string
          description: Um breve resumo do problema.
        message:
          type: string
          description: Orientação detalhada para resolver o erro.
    AccountDetails:
      type: object
      properties:
        branch:
          type: string
          description: Código da agência bancária.
          example: '0001'
        number:
          type: string
          description: Número da conta.
          example: '123456789'
        participant:
          type: string
          description: ISPB da instituição participante.
          example: '12345678'
        type:
          type: string
          description: Tipo de conta.
          example: TRAN
    OwnerDetails:
      type: object
      properties:
        name:
          type: string
          description: Nome do proprietário.
          example: John Doe
        taxIdNumber:
          type: string
          description: CPF ou CNPJ.
          example: '12345678901'
        type:
          type: string
          enum:
            - NATURAL_PERSON
            - LEGAL_PERSON
          description: Tipo de proprietário.
          example: NATURAL_PERSON
  examples:
    ErrorPIX0001:
      summary: Missing Headers in Request
      value:
        code: PIX-0001
        title: Missing Headers in Request
        message: >-
          Your request is missing one or more required header params. Please
          refer to the documentation to ensure all necessary header params are
          included in your request.
    ErrorPIX0002:
      summary: Invalid Header Value
      value:
        code: PIX-0002
        title: Invalid Header Value
        message: >-
          One or more header values are invalid. Please refer to the
          documentation to verify the expected format and allowed values for
          each header.
    ErrorPIX0008:
      summary: Invalid Path Parameter in Request
      value:
        code: PIX-0008
        title: Invalid Path Parameter in Request
        message: >-
          One or more path parameters are invalid. Please refer to the
          documentation to verify the expected format and allowed values for
          each path parameter.
    ErrorPIX1005:
      summary: Key Not Found
      value:
        code: PIX-1005
        title: Key Not Found
        message: The Pix key was not found.
    ErrorPIX0114:
      summary: Key In Custody Account
      value:
        code: PIX-0114
        title: Key In Custody Account
        message: The entry queried is in custody of the participant making the query.
    ErrorPIX0000:
      summary: Internal Server Error
      value:
        code: PIX-0000
        title: Internal Server Error
        message: The server encountered an unexpected error. Please try again later.
    ErrorPIX1000:
      summary: Provider Connection Error
      value:
        code: PIX-1000
        title: Provider Connection Error
        message: Failed to connect to provider.
    ErrorPIX1007:
      summary: Provider Internal Error
      value:
        code: PIX-1007
        title: Provider Internal Error
        message: Provider returned an internal error.
    ErrorPIX1099:
      summary: Provider Unmapped Error
      value:
        code: PIX-1099
        title: Provider Unmapped Error
        message: Provider returned an unmapped error.
  securitySchemes:
    bearerAuth:
      type: http
      scheme: bearer
      bearerFormat: JWT

````