Opening Payment Page by using a Command

You can open Payment Page by using the following JavaScript command:, method);
  • configObj is a JavaScript object which contains all the required payment parameters. For the list of all the parameters you can include in the object see Parameters for opening payment form.
  • method is HTTP request method. This is optional parameter. Supported values are GET (default) and POST.
Here is an example of opening Payment Page by using the JavaScript command:
          { payment_id: 'X03936', // Payment ID
          payment_amount: 2035, // Amount
          payment_currency: 'USD', // Currency
          project_id: 123, // project ID
          signature: 'YWb6Z20ByxpQ30hfTI.....' }, // Signature

In this example, the configObj object code is highlighted in bold and contains payment ID, payment amount, payment currency, project ID, and signature. For more information about signing payments, see Signature generation and verification

To set up the size of the page inserted in the iframe, pass the width and height values in the redirect_window_height and redirect_window_width parameters included in the payment_methods_options string in the request or Payment Page opening:

payment_methods_options={"redirect_window_height": 1200, "redirect_window_width": 1200}

To set up the size of the page for the specific payment method selected by a customer, also specify the payment method code:

payment_methods_options={"card": {"redirect_window_height": 1200, "redirect_window_width": 1200}}

If you need to select several methods – codes are separated by commas. The full list of payment method codes see in Payment method codes.

Related links