Paying Using a Selected Method

How It Works

When you open the payment UI, you can send the payment method ID in the settings.payment_method parameter. In this case, the user will be immediately redirected to the payment form of the selected payment method.

Who Can Use It

Partners who have Pay Station integrated.

How to Get It

Example

curl -v https://api.xsolla.com/merchant/v2/merchants/{merchant_id}/token \
 -X POST \
 -u your_merchant_id:merchant_api_key \
 -H 'Content-Type:application/json' \
 -H 'Accept: application/json' \
 -d '
 {
     "user": {
         "id": {
             "value": "1234567"
         },
     },
     "settings": {
         "project_id": 14004,
         "payment_method": 24
     },
     "purchase": {
             "checkout": {
                 "amount": 9.99,
                 "currency": "USD"
             }
     }
 }'

You can get the list of payment method IDs in Publisher Account or using the Get payment methods API method.