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

# Get exchange rate for payment

> Retrieve the converted amount and current exchange rate for a currency pair given an amount



## OpenAPI

````yaml openapi.json get /v1/payments/exchange-rate
openapi: 3.0.0
info:
  title: Inflow API
  version: 1.0.0
  description: API service for managing customer cards
  contact:
    name: API Support
servers:
  - url: https://sandbox.inflowafrica.com/api
    description: Sandbox
  - url: https://app.inflowpay.net/api
    description: Production
  - url: http://localhost:3000/api
    description: Local
security:
  - bearerAuth: []
tags: []
paths:
  /v1/payments/exchange-rate:
    get:
      tags:
        - External API - Payments
      summary: Get exchange rate for payment
      description: >-
        Retrieve the converted amount and current exchange rate for a currency
        pair given an amount
      parameters:
        - in: query
          name: amount
          required: true
          schema:
            type: number
          description: Target amount to convert
        - in: query
          name: sourceCurrency
          required: true
          schema:
            type: string
          description: Source currency code
        - in: query
          name: targetCurrency
          required: true
          schema:
            type: string
          description: Target currency code
      responses:
        '200':
          description: Exchange rate and computed source amount
        '400':
          description: Validation error
        '404':
          description: Exchange rate not found
        '500':
          description: Failed to retrieve exchange rate
      security:
        - apiKeyAuth: []
components:
  securitySchemes:
    bearerAuth:
      type: http
      scheme: bearer
      bearerFormat: JWT
      description: Enter JWT token
    apiKeyAuth:
      type: http
      scheme: bearer
      description: Enter your API key starting with gtw_sk_

````