Support

Widget configuration

In order to configure the widget on your custom website, follow the steps below.


Settings

AttributeDefault valueDescription
merchant-tokenThis field is mandatory. You will find it in the "Developer" section on your Scalapay Partner Portal.
amount-selectors[".price-container .price"]Array of string selectors to use to find the amount in the DOM. Use css selectors (like .class-name or #id or div.classname). Required if amount is not set.
amountThe amount used as fallback if amount-selectors prop is not defined.
min5Minimum amount to display the widget. Make sure to modify it accordingly to your contract.
max1500Maximum amount to display the widget. Make sure to modify it accordingly to your contract.
currency-positionbeforePosition of the currency. Change the position of the currency before or after the amount. The value can be: 'before' or 'after'.
currency-displaysymbolThe value can be: 'symbol' or 'code'.
localeenLanguage of the labels. The Scalapay widget supports English, Italian, Portuguese, German, French and Spanish languages.
The valid values are: 'en', 'it', 'pt', 'de', 'fr', 'es'.
typeproductThe widget type. The value can be: 'product' or 'cart' or 'checkout'.
environmentproductionIn accordance with the merchant token entered, the environment value can be: integration or production.
amount-separatorWhen the format is not standard, you can specify the separator. The available values are: , ..


Amount selectors

Add the selector of the product price component to allow the widget to change dynamically: in this way, if the product price changes, the value of the instalments changes.

amount-selectors='["#price-container"]'

For pages that can have multiple prices such as a regular price and a special price, add multiple price selectors separated by a comma ',' and the widget will take as reference the price of the first selector.

amount-selectors='["#price-container .default-price", "#price-container .secondary-price"]'

Amount value

The amount prop is used as fallback ifamount-selectorsprop is not defined.
The value could be the price with or without the currency (e.g.100,00€ , 100.00).

amount='300,64'