dLocal · Arazzo Workflow

dLocal FX Preview and Pay

Version 1.0.0

Preview the exchange rate for a corridor, then create a payment in the local currency.

1 workflow 2 source APIs 1 provider
View Spec View on GitHub PaymentsEmerging MarketsPayinsPayoutsFintechLatin AmericaAfricaAsiaLocal Payment MethodsPayment ProcessingArazzoWorkflows

Provider

dlocal

Workflows

fx-preview-and-pay
Preview an FX rate and create a payment in the local currency.
Retrieves the exchange rate for the settlement-to-local corridor and then creates a payment denominated in the local currency for the target country.
2 steps inputs: amount, country, fromCurrency, orderId, payerDocument, payerEmail, payerName, paymentMethodId, toCurrency outputs: paymentId, rate, status
1
getExchangeRate
getExchangeRate
Retrieve the real-time exchange rate for the settlement-to-local currency corridor so the rate can be shown before charging.
2
createLocalPayment
Create a payment denominated in the local currency now that the live FX rate has been previewed.

Source API Descriptions

Arazzo Workflow Specification

Raw ↑
arazzo: 1.0.1
info:
  title: dLocal FX Preview and Pay
  summary: Preview the exchange rate for a corridor, then create a payment in the local currency.
  description: >-
    Previews the conversion rate before charging. The workflow retrieves the
    real-time exchange rate between the settlement currency and the local
    currency, then creates a payment in the local currency for the target
    country. This lets a merchant show the customer the live FX rate before the
    charge is placed. Every step spells out its request inline so the flow can
    be read and executed without opening the underlying OpenAPI description.
  version: 1.0.0
sourceDescriptions:
- name: exchangeratesApi
  url: ../openapi/d-local-exchangerates-api-openapi.yml
  type: openapi
- name: paymentsApi
  url: ../openapi/_superseded/d-local-payments-api-openapi.yml
  type: openapi
workflows:
- workflowId: fx-preview-and-pay
  summary: Preview an FX rate and create a payment in the local currency.
  description: >-
    Retrieves the exchange rate for the settlement-to-local corridor and then
    creates a payment denominated in the local currency for the target country.
  inputs:
    type: object
    required:
    - fromCurrency
    - toCurrency
    - country
    - amount
    - orderId
    - paymentMethodId
    - payerName
    - payerEmail
    - payerDocument
    properties:
      fromCurrency:
        type: string
        description: Settlement currency to convert from (e.g. USD).
      toCurrency:
        type: string
        description: Local currency to convert to (e.g. BRL).
      country:
        type: string
        description: ISO 3166-1 alpha-2 country code (e.g. BR).
      amount:
        type: number
        description: Amount in the local currency to charge.
      orderId:
        type: string
        description: Merchant-provided order identifier.
      paymentMethodId:
        type: string
        description: Local payment method code (e.g. PIX, CARD).
      payerName:
        type: string
        description: Full name of the payer.
      payerEmail:
        type: string
        description: Email address of the payer.
      payerDocument:
        type: string
        description: National identification document of the payer.
  steps:
  - stepId: getExchangeRate
    description: >-
      Retrieve the real-time exchange rate for the settlement-to-local currency
      corridor so the rate can be shown before charging.
    operationId: getExchangeRate
    parameters:
    - name: from_currency
      in: query
      value: $inputs.fromCurrency
    - name: to_currency
      in: query
      value: $inputs.toCurrency
    - name: country
      in: query
      value: $inputs.country
    successCriteria:
    - condition: $statusCode == 200
    outputs:
      rate: $response.body#/rate
      inverseRate: $response.body#/inverse_rate
  - stepId: createLocalPayment
    description: >-
      Create a payment denominated in the local currency now that the live FX
      rate has been previewed.
    operationId: createPayment
    requestBody:
      contentType: application/json
      payload:
        amount: $inputs.amount
        currency: $inputs.toCurrency
        country: $inputs.country
        payment_method_id: $inputs.paymentMethodId
        payment_method_flow: DIRECT
        order_id: $inputs.orderId
        payer:
          name: $inputs.payerName
          email: $inputs.payerEmail
          document: $inputs.payerDocument
    successCriteria:
    - condition: $statusCode == 200
    outputs:
      paymentId: $response.body#/id
      status: $response.body#/status
  outputs:
    rate: $steps.getExchangeRate.outputs.rate
    paymentId: $steps.createLocalPayment.outputs.paymentId
    status: $steps.createLocalPayment.outputs.status

Work with this as data

Every workflow 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 arazzo workflows

4 MCP tools reach this
  • find_arazzoBrowse and filter every workflow in the catalog.
  • 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 workflow
curl "https://apis.io/api/v1/arazzo/dlocal-fx-preview-and-pay-workflow"
All arazzo workflows
curl "https://apis.io/api/v1/arazzo?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.