Merchant API
Pay for an order
api
post
/api/orders/{order_id}/payments

Pay for an order

Initiate a payment to pay full amount for an order using a customer's saved payment method.

note

The /orders/{order_id}/confirm endpoint has been deprecated. It will be only supported for already existing implementations.

caution

This endpoint is part of a new API, pay attention to the different endpoint URL.

For more information about how to save and charge payment methods, see: Charge a customer's saved payment method.

The following table shows who can initiate payments on saved payment methods (initiator parameter), depending on if the payment method was saved for the customer or the merchant (savedPaymentMethodFor parameter):

savePaymentMethodFor: customersavePaymentMethodFor: merchant
initiator: customerAllowedAllowed
initiator: merchantNot allowedAllowed
note

Using this endpoint, only merchant initiated payments are supported with Revolut Pay.

For more information about customers' payment methods, see the Retrieve all payment methods of a customer operation.

Request

Path Parameters
Path Parameters
Header Parameters
Header Parameters
Request body
Body object 

Response

Payment initiated

Response body
Body object 
Was this page helpful?
POST
/api . /orders . /{order_id} . /payments . 
Parameters
curl -L -g -X POST 'https://merchant.revolut.com/api/orders/{order_id}/payments' \
-H 'Content-Type: application/json' \
-H 'Accept: application/json' \
-H 'Authorization: Bearer <yourSecretApiKey>' \
--data-raw '{
"saved_payment_method": {
"type": "card",
"id": "2b83c23a-650e-40c3-8989-00ee24478738",
"initiator": "customer",
"environment": {
"type": "browser",
"time_zone_utc_offset": 180,
"color_depth": 48,
"screen_width": 1920,
"screen_height": 1080,
"java_enabled": true,
"challenge_window_width": 640,
"browser_url": "https://business.revolut.com"
}
}
}'
Request body samples
{
"saved_payment_method": {
"type": "card",
"id": "2b83c23a-650e-40c3-8989-00ee24478738",
"initiator": "customer",
"environment": {
"type": "browser",
"time_zone_utc_offset": 180,
"color_depth": 48,
"screen_width": 1920,
"screen_height": 1080,
"java_enabled": true,
"challenge_window_width": 640,
"browser_url": "https://business.revolut.com"
}
}
}
Response body samples
{
"id": "63c55e04-4208-a43d-9c96-eaee848ffbaf",
"order_id": "63c55df6-1461-a886-b90f-f49d3c370253",
"payment_method": {
"type": "card",
"id": "2b83c23a-650e-40c3-8989-00ee24478738",
"brand": "mastercard_credit",
"last_four": 1234
},
"state": "authorisation_passed"
}