Configure the On-Ramp user journey

The following parameters can be used to customize the user journey in the widget.

ParameterDescription
apiKey requiredYour publishable API key. This is used to assign customers and transactions to your MoonPay account.
currencyCodeThe code of the cryptocurrency (e.g., btc, eth, matic) you want the customer to purchase. The customer will not be able to select another currency. To differentiate between networks, use the currency codes listed in the MoonPay Dashboard.
defaultCurrencyCodeThe code of the cryptocurrency you would prefer the customer to purchase. The customer can still select another currency.
If both currencyCode and defaultCurrencyCode are passed, currencyCode will take precedence.
walletAddressThe cryptocurrency wallet address the purchased funds will be sent to. If you pass a valid wallet address the customer won't be prompted to enter one.

When pre-filling wallet addresses, you must pass currencyCode and sign the URL. Values need to be URL encoded in order to generate a valid signature.
walletAddressTagThe secondary cryptocurrency wallet address identifier/memo for coins such as EOS, XLM, XRP and XMR. This parameter will be skipped if walletAddress or currencyCode is not passed.
walletAddressesA JSON string representing the wallet addresses you want to use for multiple cryptocurrencies. If the customer selects a cryptocurrency for which you have passed a valid wallet address, the customer won't be prompted to enter one. The currency code must be lowercase.

An example for BTC and EOS: {"btc":"tb1qst9rvjnhym6kwmdkwgfs4h5dtp7cau5346jp9x","eos":"eosmoonpay23"}

If you use this parameter, only the cryptocurrencies for which you pass a wallet address will be shown to the customer, unless you also pass the showAllCurrencies parameter.
If both walletAddresses and walletAddress are passed, walletAddresses takes precedence.

For the following token types, you only need to provide a single wallet address:
BEP-2, bnb
BEP-20, bnb_bsc
ERC-20, eth
EOS, eos
Polygon, matic_polygon
TRC-20, trx

When using this parameter, you must sign URLs. Learn more about signing URLs.
walletAddressTagsA JSON string representing the wallet address tags you want to use for various cryptocurrencies. An example with EOS and XRP wallet address tags: {"eos":"myeostag","xrp":"0123456789"}.

If the customer selects a cryptocurrency for which you have passed a valid wallet address tag, the customer won't be prompted to enter one. This parameter will be skipped if walletAddresses is not passed.

If both walletAddressTags and walletAddressTag are passed, walletAddressTags takes precedence.
colorCodeThe color code for the widget main color. It is used for buttons, links and highlighted text. Only hexadecimal codes are accepted, for example #FF2B8F. You can also apply a different color for dark mode by adding a comma separated color code.
themeEnable dark mode or light mode as the default appearance for the widget. Possible values are dark, light.
themeIdID of the theme created for your application or website. See Themes page.
languageThe ISO 639-1 standard language code representing the language the widget should use.

If you pass a code for a language we do not support, the widget will remain in the current default language. This is usually the language of the customer's browser; if we do not offer that language, the widget will use English (en).
baseCurrencyCodeThe code of the fiat currency (e.g. usd, aud, gbp) you want the customer to purchase with.

Refer to our Currencies API to get a full list of supported currencies.
baseCurrencyAmountA positive integer representing how much fiat the customer wants to spend. Best used together with the baseCurrencyCode & currencyCode parameters.

Refer to our Currencies API to get the minimum and maximum values for each currency.
quoteCurrencyAmountA positive integer representing how much crypto the customer wants to buy. Best used together with the currencyCode & baseCurrencyCode parameters.

Refer to our Currencies API to get the minimum and maximum values for each currency.

Note that if you pass both baseCurrencyAmount and quoteCurrencyAmount, the quote currency amount will take precedence.
lockAmountSet this parameter to true to lock the baseCurrencyAmount set for the customer and prevent them from modifying it. This parameter will be skipped if baseCurrencyAmount is not passed.
emailThe customer's email address. If you pass a valid email address, the customer won't be prompted to enter one.

If a customer is already logged in and their e-mail address doesn't match with the URL address, the customer will be logged out automatically.
externalTransactionIdAn identifier you would like to associate with the transaction. This identifier will be present whenever we pass you transaction data.
externalCustomerIdAn identifier you would like to associate with the customer. This identifier will be present whenever we pass you customer data, allowing you to match our data with your own existing customer data.
paymentMethodPre-select the payment method you want the customer to use. Possible values are ach_bank_transfer, credit_debit_card, gbp_bank_transfer, gbp_open_banking_payment, mobile_wallet, sepa_bank_transfer, sepa_open_banking_payment, pix_instant_payment and paypal.

If payment method is unavailable users will default to our payment selection screen.
redirectURLA URL you'd like to redirect the customer to after they complete the buy flow in the widget. We will append the transaction's ID and status as query parameters to your URL.

MoonPay will add transactionId={{transactionId}}&transactionStatus=pending to the redirectURL.

You may also pass deeplinks and your own custom parameters.
showAllCurrenciesSet this parameter true to show all cryptocurrencies enabled on your account, including those for which you did not pass any wallet address via the walletAddresses parameter. You don't need to set this if you did not use the walletAddresses parameter.
showOnlyCurrenciesA comma-separated list of currency codes. Set this parameter if you want to show only some of the cryptocurrencies enabled on your account, without having to pass wallet addresses for those currencies. If both the walletAddresses and showOnlyCurrencies parameters are passed we will only show matching currencies present in both fields. All other currencies will not be included.
showWalletAddressFormSet this parameter true to show the wallet address form, even though you've already passed a valid wallet address via the walletAddress or walletAddresses parameters. The customer will be able to see the valid wallet address, but will not be able to change it.
unsupportedRegionRedirectUrlA URL you'd like to redirect the customer upon coming from unsupported region. After the user lands on an unsupported region screen, they will be redirected to provided URL after 3 seconds.
skipUnsupportedRegionScreenSet this parameter to true if you want to skip the widget's unsupported region screen and immediately redirect the customer. If you set this parameter, you also need to set unsupportedRegionRedirectUrl.