Merchant Web SDKs
The payments object
doc

The payments object

Compared to the Instance type of RevolutCheckout, the RevolutCheckout.payments module does not require initialization with an order token (public_id), i.e., you do not need to create an order before checkout. Instead, you will be able to pass a createOrder callback to asynchronously create an order when the user is ready to pay.

See an example with the revolutPay method:

const { revolutPay } = await RevolutCheckout.payments({
locale: 'auto', // optional, defaults to 'auto'
mode: 'sandbox', // optional, defaults to 'prod'
publicToken: '<yourPublicApiKey>', // merchant public API key
})
FieldDescriptionFormatRequired
localeControls the language of the text in the widget.

Possible values are:
  • auto (default) - Detect using browser locale,
  • en (English)
  • en-US (English - US),
  • es (Spanish),
  • de (German),
  • fr (French),
  • it (Italian),
  • nl (Dutch),
  • pl (Polish),
  • pt (Portuguese),
  • cs (Czech),
  • hu (Hungarian),
  • sk (Slovak),
  • ja (Japanese),
  • sv (Swedish),
  • bg (Bulgarian),
  • el (Greek),
  • ro (Romanian),
  • lt (Lithuanian),
  • hr (Croatian)
StringNo
modeDefault value: prod. Controls which API environment handles requests.

Possible values are:
  • sandbox
  • prod
EnumNo
publicTokenThe merchant's public token used for authorization.StringYes
Was this page helpful?