Creating a payment URL


πŸ‡ΈπŸ‡¦ In The Kingdom of Saudi Arabia, Payments are not yet supported in the KSAs Open Banking Standard.

In order to start initiating open banking single domestic payments from your application you need to first create a Payment URL by making a call to the following end point /payment-services/v2/payments .

curl --location --request POST '' \
--header 'Authorization: Bearer <your_access_token>' \
--header 'Content-Type: application/json' \
--data-raw '{
  "endToEndId": "{{321423413}}",
  "intent": {
    "type": "SINGLE_DOMESTIC",
    "reference": "payment to my favourite store",
    "payment": {
      "currency": "BHD",
      "value": "800.231"

Once you make the above API call, you will receive a redirectUrl, status and endToEndId in response.

  "endToEndId": "31d7ab6f6e4049ed84c00b7f7fc6fd4c",
  "createdAtDateTime": "2023-02-09T07:39:16.278337175Z",
  "redirectUrl": "",
  "status": "INITIATED",
  "payment": {
    "currency": "BHD",
    "value": "54.662"

The redirect url has information about the transaction, user information, info like currency, unique transaction identifier and more.

In the above request and response payloads you will also notice that there is a field called as the "endToEndId". This is parameter that can be used to pass the unique identifier that is attached to each API request. For every API request whether it is successful or failed, the endToEndId passed should be unique. This helps merchants and TG internal teams to troubleshoot any problems that may occur on a technical level.

The redirect url should be integrated in such a way that the URL is generated with the right values in it when the end user is on the merchant payment page and the end user clicks on "Pay with Bank". This way the merchant does not create redirect urls that do not get invoked and the payment journey on the merchant app is also seamless.


Good to know : -

Our service can be used to initiate a Single Domestic Payment via Fawri+. Fawri+ settles transactions in near real-time, up to 30 seconds and are limited to 1000.000 BHD. Other payment types of payment rails, like Fawri, a slower delayed settlement payment method, are currently not supported. TG does not support other payment types, like future-dated and international payments.