> For the complete documentation index, see [llms.txt](https://developers.mtpelerin.com/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://developers.mtpelerin.com/integration-guides/parameters-and-customization/merchant-parameters.md).

# Merchant parameters

{% hint style="info" %}
To enable merchant payments, please contact us at <hello@mtpelerin.com>
{% endhint %}

Our merchant widget allows you to accept payments for selling a good or service online. The end user has the choice to pay with crypto, by card or by bank transfer. You receive the funds converted into the pre-defined fiat or crypto currency of your choice.

Here are the mandatory parameters to use our merchant payment service:

| Parameter | Value                  | Description                                                                     |
| --------- | ---------------------- | ------------------------------------------------------------------------------- |
| \_ctkn    | string                 | Your activation key                                                             |
| tabs      | merchant               | Must be passed to display the dedicated merchant UI                             |
| bdc       | *fiat or crypto codes* | Settlement currency                                                             |
| bda       | number                 | The amount of the payment denominated in the settlement currency defined by bdc |
| oid       | string                 | Your internal order ID for the payment                                          |

{% hint style="info" %}
bda and oid must be dynamically passed for each payment, bdc can be dynamically passed but not mandatory.
{% endhint %}

{% hint style="info" %}
The customization parameters from [General parameters](/integration-guides/parameters-and-customization/general-parameters.md) and [Branding parameters](/integration-guides/parameters-and-customization/branding-parameters.md) can be used with the merchant parameters.
{% endhint %}

**Fiat codes:** AUD, CAD, CHF, CZK, DKK, EUR, GBP, HKD, HUF, JPY, MXN, NOK, NZD, PLN, SEK, SGD, USD, ZAR

**Crypto codes:** AVAX, BNB, BTC, BTC.b, BTCB, cbBTC, CELO, DAI, ETH, EURC, frxUSD, fxUSD, GHO, PAXG, POL, RBTC, RIF, S, sat, tzBTC, USDC, USDC.e, USDRIF, USDT, WBTC, WETH, XAUt, XDAI, XTZ, ZCHF

#### Payment confirmation <a href="#id-2.-payment-confirmation" id="id-2.-payment-confirmation"></a>

Once a payment has been successfully processed, we call a webhook on your side to let you know that the transaction is complete.

The webhook contains the following info:

```
{
    "id": "664369c938b3ca001a3cd44f" // our own transaction id,
    "amount": 123.45,
    "currency": "USDC",
    "external_id": "123456789", // The order id that you passed in the widget parameters (oid)
}
```

**Webhook setup**

For us to setup the webhook, we need your webhook URL that we must call, as well as 2 keys (authentication and signature) that we will exchange.

The authentication key will be used in the "Authentication" header.

The signature key will allow to compute a HMAC on your side. This HMAC will have to be the same as the "Mtp-Signature" header parameters. The HMAC has to be computed on the full request body. JS example:

```
const computedSignature = crypto.createHmac('sha256', SIGNATURE_KEY).update(JSON.stringify(body)).digest('hex')
```
