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

# Get crypto exchange

> The Crypto Exchange Endpoint allows you to convert any amount in USD or Local Currency to the specified Cryptocurrency.



## OpenAPI

````yaml open-api-yaml/deposits-api/currency-exchange/get-crypto-exchange.json GET /v3/exchange_rates/crypto
openapi: 3.0.0
info:
  title: Crypto Exchange API
  version: v3
servers:
  - url: https://api-stg.pandablue.com
    description: Staging environment
security:
  - BearerAuth: []
paths:
  /v3/exchange_rates/crypto:
    get:
      tags:
        - Exchange Rates
      summary: Get Cryptocurrency Exchange Rate
      description: >-
        The Crypto Exchange Endpoint allows you to convert any amount in USD or
        Local Currency to the specified Cryptocurrency.
      parameters:
        - name: currency
          in: query
          required: true
          description: USD or the country's local currency that will be used by the payer.
          schema:
            type: string
        - name: amount
          in: query
          required: false
          description: >-
            Amount in the previously specified currency. Used to calculate the
            exchange in the cryptocurrency specified below. Default 1.
          schema:
            type: number
            format: float
            default: 1
        - name: crypto
          in: query
          required: true
          description: Cryptocurrency symbol in which the amount will be converted to.
          schema:
            type: string
      responses:
        '200':
          description: Currency exchange correctly returned.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/CryptoExchangeResponse'
        '401':
          description: Invalid credentials error.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ErrorResponse'
components:
  schemas:
    CryptoExchangeResponse:
      type: object
      properties:
        fx_rate:
          type: number
          format: float
          description: Exchange rate of the cryptocurrency against the base currency.
        converted_amount:
          type: number
          format: float
          description: Amount in the cryptocurrency specified.
        fee:
          type: number
          format: float
          description: Fee for converting the specified amount to the cryptocurrency.
    ErrorResponse:
      type: object
      properties:
        code:
          type: integer
          description: Error code.
        description:
          type: string
          description: Error description.
  securitySchemes:
    BearerAuth:
      type: http
      scheme: bearer
      description: >-
        Your Read-Only API Key prefixed with 'Bearer '. Example: 'Bearer
        your_read_only_key_here'

````

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