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

# Calculate Conversion Fee

> Quote the fee, rate and expected output for a conversion before you create it

> [!NOTE]
>
> **Auth method: Signed (HMAC)** — this endpoint requires the full set of signed
> headers: `x-access-id`, `x-request-id`, `x-timestamp`, and an HMAC-SHA256
> `authorization` signature. See [Authentication](https://docs.tender.cash/api-reference/authentication.md#signed-hmac-authentication).

All conversion endpoints share a bucket of 10 requests per minute per merchant, on top of the
general limit. See [Rate limits](https://docs.tender.cash/api-reference/rate-limits.md).

The quote is an estimate at current prices. The final figures are fixed when you
[create the conversion](https://docs.tender.cash/api-reference/endpoint/conversions/create.md).

## Headers

**authorization** `string` *required*

Base64-encoded HMAC-SHA256 signature of `{"timeStamp":"<x-timestamp>","requestId":"<x-request-id>","accessId":"<x-access-id>"}`, signed with your access secret. The request body is not part of the signature.

**Example:** `"pV3n0o8kq0lK2mJ8bZ1yq3Yt6hR0cXK9u4mVJ2l9sE0="`

**x-timestamp** `string` *required*

ISO 8601 timestamp; must be within 5 minutes of server time

**Example:** `"2026-10-15T09:45:53.000Z"`

**x-request-id** `string` *required*

A unique UUID v4 per request

**Example:** `"550e8400-e29b-41d4-a716-446655440000"`

**x-access-id** `string` *required*

Your API access ID provided by Tender

**Example:** `"your-access-id-here"`

## Path parameters

**chain** `string` *required*

Source chain ID

**Example:** `"ethereum"`

**coin** `string` *required*

Source coin ID (for example `usdt`, not the symbol `USDT`)

**Example:** `"usdt"`

**amount** `string` *required*

Amount to convert, in the source coin. Must be greater than zero.

**Example:** `"100"`

## Query parameters

**toChain** `string`

Destination chain ID for a crypto swap. Use `fiat` to quote a fiat conversion.

**Example:** `"solana"`

**toCoin** `string`

Destination coin ID for a crypto swap, or a fiat currency ID (for example `ngn`) when `toChain`
is `fiat`. If omitted, the destination is the source coin.

**Example:** `"sol"`

## Response

**status** `string` *required*

`success` on success

**Example:** `"success"`

**message** `string` *required*

Human-readable result message

**Example:** `"success"`

**data** `object` *required*

Conversion quote

**data properties**

**from** `object`

Source side of the quote

**from properties**

**chain** `string`

**Example:** `"ethereum"`

**currency** `string`

**Example:** `"usdt"`

**symbol** `string`

**Example:** `"USDT"`

**amount** `number`

Amount you convert

**Example:** `100`

**amountUSD** `number`

USD value of `amount`

**Example:** `100`

**to** `object`

Destination side of the quote, after fees

**to properties**

**chain** `string`

Destination chain, `fiat` for fiat quotes. Absent when you don't send `toChain`.

**Example:** `"solana"`

**currency** `string`

**Example:** `"sol"`

**symbol** `string`

**Example:** `"SOL"`

**amount** `number`

Estimated amount you receive, in the destination currency

**Example:** `0.6633`

**amountUSD** `number`

USD value after the fee

**Example:** `99.5`

**fee** `object`

Conversion fee

**fee properties**

**fee** `number`

Fee in the source coin

**Example:** `0.5`

**feeUSD** `number`

Fee in USD

**Example:** `0.5`

**rate** `object`

Exchange rate

**rate properties**

**value** `string`

Destination units per USD, after fees. Two decimals for fiat, six for crypto.

**Example:** `"0.006667"`

**perSourceUnit** `string`

Value of one source unit in the destination currency, before fees. Use it to display
"1 `from.symbol` = `perSourceUnit` `rate.symbol`".

**Example:** `"0.006700"`

**symbol** `string`

Destination symbol

**Example:** `"SOL"`

**overridden** `boolean`

`true` if the quote uses a fixed rate instead of the live market rate

**Example:** `false`

## Errors

All return HTTP 400.

| Message | Cause |
| - | - |
| `Amount must be greater than zero` | `amount` is zero, negative or not a number |
| `Invalid chain` | Unknown source chain |
| `Invalid currency` | Unknown source coin |
| `Exchange price not available` | No price for the source coin |
| `Invalid destination chain` | Unknown `toChain` |
| `Invalid destination currency` | Unknown `toCoin` |
| `Exchange price not available for destination currency` | No price for `toCoin` |
| `Invalid destination exchange rate` | The destination price is unusable |

```bash Crypto swap theme={null}
curl "https://sandbox-api.tender.cash/v1/api/conversions/fee/ethereum/usdt/100?toChain=solana&toCoin=sol" \
  -H "x-access-id: your-access-id-here" \
  -H "x-request-id: 550e8400-e29b-41d4-a716-446655440000" \
  -H "x-timestamp: 2026-10-15T09:45:53.000Z" \
  -H "authorization: <signature>"
```

```bash Fiat theme={null}
curl "https://sandbox-api.tender.cash/v1/api/conversions/fee/ethereum/usdt/100?toChain=fiat&toCoin=ngn" \
  -H "x-access-id: your-access-id-here" \
  -H "x-request-id: 550e8400-e29b-41d4-a716-446655440000" \
  -H "x-timestamp: 2026-10-15T09:45:53.000Z" \
  -H "authorization: <signature>"
```

```json 200 theme={null}
{
  "status": "success",
  "message": "success",
  "data": {
    "from": { "chain": "ethereum", "currency": "usdt", "symbol": "USDT", "amount": 100, "amountUSD": 100 },
    "to": { "chain": "solana", "currency": "sol", "symbol": "SOL", "amount": 0.6633, "amountUSD": 99.5 },
    "fee": { "fee": 0.5, "feeUSD": 0.5 },
    "rate": { "value": "0.006667", "perSourceUnit": "0.006700", "symbol": "SOL", "overridden": false }
  }
}
```

```json 400 theme={null}
{
  "status": "error",
  "message": "Invalid destination currency",
  "data": {}
}
```


## OpenAPI

````yaml GET /v1/api/conversions/fee/{chain}/{coin}/{amount}
openapi: 3.1.0
info:
  title: Tender API
  description: Tender Developer API for cryptocurrency payments and agent management
  version: 2.0.0
  contact:
    name: Tender Support
    url: https://tender.cash
servers:
  - url: https://secureapi.tender.cash
    description: Production Server
  - url: https://sandbox-api.tender.cash
    description: Sandbox Server
security:
  - SignedAuth: []
tags:
  - name: Agents
    description: Manage agents and sub-businesses
  - name: Transactions
    description: Payment and transaction operations
  - name: System
    description: System information and configuration
  - name: Webhooks
    description: Webhook management and logs
  - name: On-ramp
    description: Fiat-to-crypto on-ramp operations
  - name: Payouts
    description: Send crypto from merchant balance to a wallet address or payout account
  - name: Subwallets
    description: Provision and manage crypto wallet infrastructure for your end-users
  - name: Conversions
    description: Swap crypto between coins and chains, or convert to a payout account
paths:
  /v1/api/conversions/fee/{chain}/{coin}/{amount}:
    get:
      tags:
        - Conversions
      summary: Calculate Conversion Fee
      description: >-
        Quote the fee, rate and expected output. Use `toChain=fiat` with a fiat
        currency ID as `toCoin` for fiat quotes. Conversion endpoints share a 10
        requests/minute bucket per merchant.
      operationId: calculateConversionFee
      parameters:
        - name: authorization
          in: header
          required: true
          description: >-
            Base64-encoded HMAC-SHA256 signature of
            `{"timeStamp":"<x-timestamp>","requestId":"<x-request-id>","accessId":"<x-access-id>"}`,
            signed with your access secret. The request body is not part of the
            signature.
          schema:
            type: string
          example: pV3n0o8kq0lK2mJ8bZ1yq3Yt6hR0cXK9u4mVJ2l9sE0=
        - name: x-timestamp
          in: header
          required: true
          description: ISO 8601 timestamp; must be within 5 minutes of server time
          schema:
            type: string
            format: date-time
          example: '2026-10-15T09:45:53.000Z'
        - name: x-request-id
          in: header
          required: true
          description: A unique UUID v4 per request
          schema:
            type: string
            format: uuid
          example: 550e8400-e29b-41d4-a716-446655440000
        - name: x-access-id
          in: header
          required: true
          schema:
            type: string
          example: your-access-id-here
        - name: chain
          in: path
          required: true
          description: Source chain ID
          schema:
            type: string
          example: ethereum
        - name: coin
          in: path
          required: true
          description: Source coin ID
          schema:
            type: string
          example: usdt
        - name: amount
          in: path
          required: true
          description: Amount in the source coin; must be greater than zero
          schema:
            type: string
          example: '100'
        - name: toChain
          in: query
          required: false
          description: Destination chain ID, or `fiat`
          schema:
            type: string
          example: solana
        - name: toCoin
          in: query
          required: false
          description: Destination coin ID, or fiat currency ID when toChain is fiat
          schema:
            type: string
          example: sol
      responses:
        '200':
          description: Quote
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ConversionFeeResponse'
              example:
                status: success
                message: success
                data:
                  from:
                    chain: ethereum
                    currency: usdt
                    symbol: USDT
                    amount: 100
                    amountUSD: 100
                  to:
                    chain: solana
                    currency: sol
                    symbol: SOL
                    amount: 0.6633
                    amountUSD: 99.5
                  fee:
                    fee: 0.5
                    feeUSD: 0.5
                  rate:
                    value: '0.006667'
                    perSourceUnit: '0.006700'
                    symbol: SOL
                    overridden: false
        '400':
          description: Invalid amount, unknown chain or coin, or no price available
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ConversionPayoutErrorResponse'
              example:
                status: error
                message: Invalid destination currency
                data: {}
        '429':
          description: Rate limit exceeded
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ConversionPayoutErrorResponse'
              example:
                status: error
                message: Too many requests. Max 10 per 60s.
                data: {}
      security:
        - SignedAuth: []
components:
  schemas:
    ConversionFeeResponse:
      type: object
      required:
        - status
        - message
        - data
      properties:
        status:
          type: string
          example: success
        message:
          type: string
          example: success
        data:
          type: object
          properties:
            from:
              type: object
              properties:
                chain:
                  type: string
                currency:
                  type: string
                symbol:
                  type: string
                amount:
                  type: number
                amountUSD:
                  type: number
            to:
              type: object
              properties:
                chain:
                  type: string
                currency:
                  type: string
                symbol:
                  type: string
                amount:
                  type: number
                amountUSD:
                  type: number
            fee:
              type: object
              properties:
                fee:
                  type: number
                feeUSD:
                  type: number
            rate:
              type: object
              properties:
                value:
                  type: string
                  description: Destination units per USD after fees
                perSourceUnit:
                  type: string
                  description: Value of 1 source unit in the destination, before fees
                symbol:
                  type: string
                overridden:
                  type: boolean
    ConversionPayoutErrorResponse:
      type: object
      properties:
        status:
          type: string
          example: error
        message:
          type: string
        data:
          type: object
          nullable: true
  securitySchemes:
    SignedAuth:
      type: apiKey
      in: header
      name: authorization
      description: >-
        Signed (HMAC) authentication. Required headers: x-access-id,
        x-request-id (UUID v4), x-timestamp (ISO 8601, must be within 5 minutes
        of server time), and authorization: the Base64 HMAC-SHA256 of the JSON
        string
        {"timeStamp":"<x-timestamp>","requestId":"<x-request-id>","accessId":"<x-access-id>"}
        (keys in that order, no whitespace) using your access secret. The
        request body, method and path are not signed. The API key must be linked
        to an outlet.

````

This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.