BTG Pactual Prepayment API

The Prepayment API from BTG Pactual — 4 operation(s) for prepayment.

Operations 4

POST /fidc-loan/v1/prepayment/{contract_number}/confirm Create fidc loan prepayment by contract number confirm #
GET /fidc-loan/v1/prepayment/{simulation_identification}/bankslip Get fidc loan prepayment by simulation identification bankslip #
GET /fidc-loan/v1/prepayment/{contract_number}/balance Get fidc loan prepayment by contract number balance #
POST /fidc-loan/v1/prepayment/{contract_number}/simulate Create fidc loan prepayment by contract number simulate #

Documentation

📖
Documentation
https://developers.empresas.btgpactual.com/docs/api-specs-target/Acquirers%20-%20PaymentLink/acquirers-paymentlink
📖
Documentation
https://developers.empresas.btgpactual.com/docs/api-specs-target/Acquirers%20-%20Salesprovider/acquirers-salesprovider
📖
Documentation
https://developers.empresas.btgpactual.com/docs/api-specs-target/ANTECRED-Subcredenciadores/antecred-subcredenciadores
📖
Documentation
https://developers.empresas.btgpactual.com/docs/api-specs-target/Banking%20-%20Accounts/banking-accounts
📖
Documentation
https://developers.empresas.btgpactual.com/docs/api-specs-target/Banking%20-%20Cards/banking-cards
📖
Documentation
https://developers.empresas.btgpactual.com/docs/api-specs-target/Banking%20-%20CCReceivables/banking-ccreceivables
📖
Documentation
https://developers.empresas.btgpactual.com/docs/api-specs-target/Banking%20-%20Collections/banking-collections
📖
Documentation
https://developers.empresas.btgpactual.com/docs/api-specs-target/Banking%20-%20DDA/banking-dda
📖
Documentation
https://developers.empresas.btgpactual.com/docs/api-specs-target/Banking%20-%20PaymentLink/banking-paymentlink
📖
Documentation
https://developers.empresas.btgpactual.com/docs/api-specs-target/Banking%20-%20PaymentLinkRec/banking-paymentlinkrec
📖
Documentation
https://developers.empresas.btgpactual.com/docs/api-specs-target/Banking%20-%20Payments/banking-payments
📖
Documentation
https://developers.empresas.btgpactual.com/docs/api-specs-target/Banking%20-%20Payroll/banking-payroll
📖
Documentation
https://developers.empresas.btgpactual.com/docs/api-specs-target/Banking%20-%20Pix%20Autom%5Cxe1tico/banking-pix-automatico
📖
Documentation
https://developers.empresas.btgpactual.com/docs/api-specs-target/Banking%20-%20PixCashin/banking-pixcashin
📖
Documentation
https://developers.empresas.btgpactual.com/docs/api-specs-target/Banking%20-%20Protest/banking-protest
📖
Documentation
https://developers.empresas.btgpactual.com/docs/api-specs-target/Banking%20-%20Split/banking-split
📖
Documentation
https://developers.empresas.btgpactual.com/docs/api-specs-target/BankingHub%20-%20Open%20Finance%20Balance%20Refresh/bankinghub-open-finance-balance-refresh
📖
Documentation
https://developers.empresas.btgpactual.com/docs/api-specs-target/CrediFlow%20-%20Ativos%20e%20Cess%5Cxf5es/crediflow-ativos-e-cessoes
📖
Documentation
https://developers.empresas.btgpactual.com/docs/api-specs-target/FIDC%20-%20Consignado%20Privado/fidc-consignado-privado
📖
Documentation
https://developers.empresas.btgpactual.com/docs/api-specs-target/FIDC%20-%20Credit%20Conciliation/fidc-credit-conciliation
📖
Documentation
https://developers.empresas.btgpactual.com/docs/api-specs-target/FIDC%20-%20Document/fidc-document
📖
Documentation
https://developers.empresas.btgpactual.com/docs/api-specs-target/FIDC%20-%20Eligibility/fidc-eligibility
📖
Documentation
https://developers.empresas.btgpactual.com/docs/api-specs-target/FIDC%20-%20Motor%20de%20Credito/fidc-motor-de-credito
📖
Documentation
https://developers.empresas.btgpactual.com/docs/api-specs-target/FIDC%20-%20Operation/fidc-operation
📖
Documentation
https://developers.empresas.btgpactual.com/docs/api-specs-target/FIDC%20-%20Payment/fidc-payment
📖
Documentation
https://developers.empresas.btgpactual.com/docs/api-specs-target/FIDC%20-%20Portability/fidc-portability
📖
Documentation
https://developers.empresas.btgpactual.com/docs/api-specs-target/FIDC%20-%20Prepayment/fidc-prepayment
📖
Documentation
https://developers.empresas.btgpactual.com/docs/api-specs-target/FIDC%20-%20Renegotiation/fidc-renegotiation
📖
Documentation
https://developers.empresas.btgpactual.com/docs/api-specs-target/FIDC%20-%20Simulation/fidc-simulation
📖
Documentation
https://developers.empresas.btgpactual.com/docs/api-specs-target/FIDC%20-%20Wallet/fidc-wallet
📖
Documentation
https://developers.empresas.btgpactual.com/docs/api-specs-target/FIDC%20-%20Warranty/fidc-warranty
📖
Documentation
https://developers.empresas.btgpactual.com/docs/api-specs-target/Files/files
📖
Documentation
https://developers.empresas.btgpactual.com/docs/api-specs-target/HUBFX%20-%20Cambio/hubfx-cambio
📖
Documentation
https://developers.empresas.btgpactual.com/docs/api-specs-target/KGIRO%20-%20Leads%20de%20Cr%5Cxe9dito/kgiro-leads-de-credito
📖
Documentation
https://developers.empresas.btgpactual.com/docs/api-specs-target/Onboarding/onboarding
📖
Documentation
https://developers.empresas.btgpactual.com/docs/api-specs-target/SCF%20-%20Colombia/scf-colombia
📖
Documentation
https://developers.empresas.btgpactual.com/docs/api-specs-target/SCF%20-%20Risco%20Sacado/scf-risco-sacado
📖
Documentation
https://developers.empresas.btgpactual.com/docs/api-specs-target/SCF-Financiers-Supplier/scf-financiers-supplier
📖
Documentation
https://developers.empresas.btgpactual.com/docs/api-specs-target/Solar-CreditAnalysis/solar-creditanalysis
📖
Documentation
https://developers.empresas.btgpactual.com/docs/api-specs-target/Solar-Workflow/solar-workflow
📖
Documentation
https://developers.empresas.btgpactual.com/docs/api-specs-target/Webhooks/webhooks

Specifications

Work with this as data

Every API here is available over the APIs.io API and to AI agents over MCP.

MCP server

One button, every client — Claude, Cursor, VS Code and the rest.

https://apis.io/mcp

Tools for apis

7 MCP tools reach this
  • find_apisBrowse and filter every API in the catalog.
  • get_api_artifactsOne API's artifacts, grouped by type.
  • get_openapiThe primary OpenAPI for this API.
  • find_similar_apisAPIs that look like this one.
  • apis_io_searchSTART HERE — APIs, providers and tags for one query, each with its total.
  • resolveTurn a domain, URL or GitHub org into the provider it belongs to.
  • find_cohortsEvery scored population of providers in the catalog.
All 92 tools →

Call it yourself

curl for this page
This API
curl "https://apis.io/api/v1/apis/btg-pactual:btg-pactual-prepayment-api"
All apis
curl "https://apis.io/api/v1/apis?limit=25"

Discovery needs no key. Ratings and market analysis are Pro.

Get an API key

Free tier, no form to fill in. Signing in shares your email address with us — we store it to create your key and to recognise you if you sign in with another provider. See our Privacy Policy and Terms.

A second provider on the same verified email joins the account you already have.

OpenAPI Specification

btg-pactual-prepayment-api-openapi.yml Raw ↑
openapi: 3.2.0
info:
  title: FIDC Prepayment API
  version: '1.0'
  description: Esta documentação tem a finalidade de instruir parceiros a utilização das APIs de credit as a service. Para autenticação é necessário a utilização do fluxo de client credentials de acordo com o menu `Authentication -> Fluxos de Autenticação -> Client Credentials`
  termsOfService: https://www.btgpactual.com/empresas/termos-e-politicas/
servers:
- url: https://api.sandbox.empresas.btgpactual.com
  description: Sandbox
- url: https://api.empresas.btgpactual.com
  description: Produção
tags:
- name: Prepayment
paths:
  /fidc-loan/v1/prepayment/{contract_number}/confirm:
    post:
      tags:
      - Prepayment
      description: Essa rota é responsável pela confirmação de uma simulação de pré-pagamento retornando o código de barras do boleto
      parameters:
      - in: path
        name: contract_number
        description: Identificação do contrato
        required: true
        schema:
          type: string
          description: Identificador do contrato
          example: 6764459321/EP
          title: ContractIdentificationSchema
      requestBody:
        description: Informações de confirmação de renegociação
        content:
          application/json:
            schema:
              type: object
              properties:
                simulation_identification:
                  type: string
                  description: Identificador da simulação de pré-pagamento
                  example: FDA4162DA3999EB0570307A7356110F5-638101491065224458
      responses:
        '200':
          description: Sucesso
          content:
            application/json:
              schema:
                type: object
                properties:
                  barcode_number:
                    type: string
                    description: Código de barras para pagamento
                    example: 2.0890001091e+46
                title: PrepaymentConfirmationSchema
        '400':
          description: Erro
          content:
            application/json:
              schema:
                type: object
                properties:
                  code:
                    type: string
                    description: Código de erro
                    example: Unexpected error
                  message:
                    type: string
                    description: Descrição do erro
                    example: Erro no inesperado no processamento
                title: ContractPositionErrorSchema
        '401':
          description: Não autorizado
      security:
      - oauth2:
        - empresas.btgpactual.com/prepayments
      x-docs-url: https://developers.empresas.btgpactual.com/docs/api-specs-target/FIDC%20-%20Prepayment/confirmar-uma-simulacao-de-pre-pagamento
      summary: Create fidc loan prepayment by contract number confirm
      x-summary-source: derived
      operationId: postFidcLoanV1PrepaymentByContractNumberConfirm
      x-operation-id-source: derived
  /fidc-loan/v1/prepayment/{simulation_identification}/bankslip:
    get:
      tags:
      - Prepayment
      description: O objetivo dessa rota é retornar o boleto de pré pagamento
      parameters:
      - in: path
        name: simulation_identification
        description: Identificador da simulação de pré pagamento
        required: true
        schema:
          type: string
          example: FDA4162DA3999EB0570307A7356110F5-638101491065224458
          description: Identificador da simulação do pré pagamento
          title: SimulationIdentificationSchema
      responses:
        '200':
          description: Sucesso
          content:
            application/json:
              schema:
                type: string
                format: base64
                description: Boleto
                title: PrepaymentBankslipSchema
        '400':
          description: Erro
          content:
            text/plain:
              schema:
                type: string
                description: Mensagem de Erro
                example: Erro ao baixar o boleto
                title: PrepaymentBankslipErrorSchema
        '401':
          description: Não autorizado
        '404':
          description: Erro
          headers:
            X-Retry-After:
              description: Indica quanto tempo em segundos é aconselhável que o cliente aguarde para fazer uma nova tentativa
              schema:
                type: number
                example: 180
          content:
            text/plain:
              schema:
                type: string
                description: Mensagem de Erro
                example: Boleto não encontrado
                title: PrepaymentBankslipNotFoundSchema
      security:
      - oauth2:
        - empresas.btgpactual.com/prepayments
      x-docs-url: https://developers.empresas.btgpactual.com/docs/api-specs-target/FIDC%20-%20Prepayment/consultar-o-boleto-de-pre-pagamento
      summary: Get fidc loan prepayment by simulation identification bankslip
      x-summary-source: derived
      operationId: getFidcLoanV1PrepaymentBySimulationIdentificationBankslip
      x-operation-id-source: derived
  /fidc-loan/v1/prepayment/{contract_number}/balance:
    get:
      tags:
      - Prepayment
      description: O objetivo dessa rota é exibir a posição do contrato.
      parameters:
      - in: path
        name: contract_number
        description: Identificação do contrato
        required: true
        schema:
          type: string
          description: Identificador do contrato
          example: 6764459321/EP
          title: ContractIdentificationSchema
      - in: query
        name: fund_tax_id
        description: Identificação do fundo
        required: true
        schema:
          type: string
          example: '15996430000182'
          description: CNPJ/CPF
          title: TaxIdSchema
      - in: query
        name: position_date
        description: Data da posição (default dia atual)
        required: false
        schema:
          type: string
          example: '2023-09-14T00:00:00'
          description: Data de vencimento
          title: PositionDateSchema
      responses:
        '200':
          description: Sucesso
          content:
            application/json:
              schema:
                type: array
                items:
                  type: object
                  properties:
                    amortization_type:
                      type: string
                      description: Tipo de amortização
                      example: InstallmentFlow
                    balance_date:
                      type: string
                      description: Data da posição
                      example: '2023-08-02 00:00:00'
                    contract_number:
                      type: string
                      description: Identificação do contrato da operação
                      example: 1247244/HYD
                    currency:
                      type: string
                      description: Moeda
                      example: BRL
                    installments:
                      type: array
                      items:
                        type: object
                        properties:
                          amount_at_maturity:
                            type: number
                            description: Valor de vencimento da parcela
                            example: 136.1
                          curve_value:
                            type: number
                            description: Valor da parcela na curva
                            example: 140.62
                          discount:
                            type: number
                            description: Valor de desconto da parcela
                            example: 0
                          installment_number:
                            type: number
                            description: Número da parcela
                            example: 1
                          principal:
                            type: number
                            description: Valor de principal da parcela
                            example: 117.28
                          status_description:
                            type: string
                            description: Status da parcela
                            example: Opened
                    is_vnp:
                      type: boolean
                      description: Indicador se o contrato está inadimplente
                      example: true
                    position_date:
                      type: string
                      description: Data da posição
                      example: '2023-08-02 00:00:00'
                    trade_id:
                      type: string
                      description: Identificador do trade
                      example: 11266246
                  title: BalanceSchema
        '400':
          description: Erro
          content:
            application/json:
              schema:
                type: object
                properties:
                  code:
                    type: string
                    description: Código de erro
                    example: Unexpected error
                  message:
                    type: string
                    description: Descrição do erro
                    example: Erro no inesperado no processamento
                title: ContractPositionErrorSchema
        '401':
          description: Não autorizado
      security:
      - oauth2:
        - empresas.btgpactual.com/prepayments
      x-docs-url: https://developers.empresas.btgpactual.com/docs/api-specs-target/FIDC%20-%20Prepayment/consultar-posicao-do-credito-por-contrato
      summary: Get fidc loan prepayment by contract number balance
      x-summary-source: derived
      operationId: getFidcLoanV1PrepaymentByContractNumberBalance
      x-operation-id-source: derived
  /fidc-loan/v1/prepayment/{contract_number}/simulate:
    post:
      tags:
      - Prepayment
      description: Essa rota é responsável pela simulação de pré-pagamento, aplicando as regras do fundo para pré-pagamento e retornando o status
      parameters:
      - in: path
        name: contract_number
        description: Identificação do contrato
        required: true
        schema:
          type: string
          description: Identificador do contrato
          example: 6764459321/EP
          title: ContractIdentificationSchema
      requestBody:
        description: Informações da simulação de pré pagamento
        content:
          application/json:
            schema:
              type: object
              properties:
                fund_tax_id:
                  description: Identificador do fundo
                  type: string
                  example: 15996430000182
                installments:
                  type: array
                  items:
                    type: number
                    description: Número da parcela
                    example: 1
                position_date:
                  description: Data da posição
                  type: string
                  example: '2023-08-02 00:00:00'
        required: true
      responses:
        '200':
          description: Sucesso
          content:
            application/json:
              schema:
                type: object
                properties:
                  simulation_identification:
                    type: string
                    description: Identificador da simulação de pré-pagamento
                    example: FDA4162DA3999EB0570307A7356110F5-638101491065224458
                  value_to_pay:
                    type: number
                    description: Valor a ser pago
                    example: 244.18
                title: PrepaymentSimulateSchema
        '400':
          description: Erro
          content:
            application/json:
              schema:
                type: object
                properties:
                  code:
                    type: string
                    description: Código de erro
                    example: Unexpected error
                  message:
                    type: string
                    description: Descrição do erro
                    example: Erro no inesperado no processamento
                title: ContractPositionErrorSchema
        '401':
          description: Não autorizado
      security:
      - oauth2:
        - empresas.btgpactual.com/prepayments
      x-docs-url: https://developers.empresas.btgpactual.com/docs/api-specs-target/FIDC%20-%20Prepayment/simular-uma-solicitacao-de-pre-pagamento
      summary: Create fidc loan prepayment by contract number simulate
      x-summary-source: derived
      operationId: postFidcLoanV1PrepaymentByContractNumberSimulate
      x-operation-id-source: derived
components:
  securitySchemes:
    oauth2:
      type: oauth2
      flows:
        clientCredentials:
          tokenUrl: https://id.sandbox.btgpactual.com/oauth2/token
          scopes:
            empresas.btgpactual.com/prepayments: Scope to pre payment
x-reassembled-from:
  source: https://developers.empresas.btgpactual.com/docs/api-specs-target/
  method: Operation objects decoded verbatim from the "api" payload that the provider's Docusaurus OpenAPI docs embed in each reference page chunk (/assets/js/*.js); grouped by info.title; jsonRequestBodyExample and postman keys dropped.
  chunks:
  - https://developers.empresas.btgpactual.com/assets/js/1f7f005a.c294a601.js
  - https://developers.empresas.btgpactual.com/assets/js/3a8ade50.1978c077.js
  - https://developers.empresas.btgpactual.com/assets/js/71f00634.7e06677e.js
  - https://developers.empresas.btgpactual.com/assets/js/7315c5a6.8a6a83eb.js