πŸ“ˆGet Current Price

Need help with your integration? Click here to chat with our custom GPT for instant answers.

All pricing information can be retrieved with a POST request.

URL: https://widget.swapped.com/api/v1/merchant/pricing

Request Data:

{
    "api_key": "",
    "payment_method": "creditcard",
    "fiat_currency": "USD",
    "fiat_amount": 500,
    "crypto_currency": "ETH",
    "crypto_amount": 1,
    "region": "BE"
}

Note: The crypto_amount and fiat_amount fields are optional. If you only provide one of them, the other will be calculated based on the current exchange rate.

Note: You must supply the group as payment_method and also include the region for it to work as intended.

Request Definition:

  • api_key: The merchant's public key. Identifies the requesting merchant.

  • payment_method: Payment method to use (e.g., creditcard).

  • fiat_currency: The fiat currency you want to query. For the full list of supported currencies, see here.

  • fiat_amount: The fiat amount you want to convert.

  • crypto_currency: The cryptocurrency you want to convert to. For the full list of supported currencies, see here.

  • crypto_amount: The cryptocurrency amount you want to convert to.

  • region: The 2-letter ISO-3166 code of the country the method is available in.

Response data:

{
    "success": true,
    "data": {
        "crypto_amount": 0.11031,
        "crypto_currency": "ETH",
        "crypto_unit_price": 4532.7,
        "network_fee": 0.25,
        "network_fee_local": 0.29,
        "fiat_amount_incl_fees": 442.16,
        "fiat_amount_excl_fees": 425.83,
        "fiat_amount_incl_fees_local": 519.17,
        "fiat_amount_excl_fees_local": 500,
        "fiat_currency": "USD",
        "markup_fiat_value": 0,
        "processing_fee": 19.17,
        "payment_method": "creditcard",
        "payment_group": "creditcard"
    }
}

Response Definition:

  • crypto_amount: Amount of crypto the user will receive (e.g., 0.14137 ETH).

  • crypto_currency: The crypto token used (e.g., "ETH").

  • crypto_unit_price: Price per 1 unit of crypto in the given fiat (e.g., 3536.82 EUR per ETH).

  • network_fee: Network fee in EUR.

  • network_fee_local: Provides the network fee amount converted to the user's local fiat currency.

  • fiat_amount_incl_fees: Fiat value the user is paying, including fees, in EUR.

  • fiat_amount_excl_fees: Fiat value the user is paying, excluding fees, in EUR.

  • fiat_amount_incl_fees_local: Total fiat paid, including fees, in user’s fiat currency (e.g., USD).

  • fiat_amount_excl_fees_local: Total fiat paid, excluding fees, in user’s fiat currency (e.g., USD).

  • fiat_currency: The local fiat currency (e.g., "USD").

  • markup_fiat_value: Additional markup displayed in fiat.

    • Merchants can add a markup via dashboard.swapped.com > Settings > Affiliate Fee.

    • Only the workspace owner can configure this.

  • processing_fee: Total processing fee in local fiat (e.g., 19.21 EUR).

  • payment_method: The payment method used for the order.

  • payment_group: The payment group the method belongs to.

Last updated