---
# System prepended metadata

title: Russian rubble (RUB)

---

# Russian rubble (RUB)

## Create Payment

### Available payment methods and integration options
| Method           | Redirect  | Iframe    | H2H     |
|----------------- |-----------|-----------|---------|
| `card`           | `True`    | `True`    | `True`  |
| `card_transfer`  | `True`    | `True`    | `True`  |
| `phone_transfer` | `True`    | `True`    | `True`  |
| `mobile_topup`   | `True`    | `True`    | `True`  |
| `sbp`            | `True`    | `False`   | `False` |


To enable Iframe, if available, please contact support.

### Card
The POST request endpoint is `/rest/paymentgate/simple/`

> Request example:

```http
POST /rest/paymentgate/simple/ HTTP/1.1
Api-sign: *****
Content-Type: application/json

{
    "shop_key": "00112233-4455-6677-8899-aabbccddeeff",
    "amount": 29900,
    "order_currency": "RUB",
    "payment_currency": "RUB",
    "payment_method": "card",
    "order_number": "order-12345",
    "payment_details": "Payment via order 12345",
    "success_url": "https://example.com/success",
    "fail_url": "https://example.com/fail",
    "lang": "en"
}
```

> Response example:

```shell
HTTP/1.1 200 OK
Content-Type: application/json

{
    "redirect_url": "https://example.com/redirect",
    "order_token": "7b0906f6-7c14-45ba-a186-86cc49d701fd",
    "status": "progress",
    "status_description": "None"
}
```

### Card transfer
The POST request endpoint is `/rest/paymentgate/simple/`

| Field                  | Type          | Mandatory | Description                              |
|------------------------|---------------|-----------|------------------------------------------|
| `user_id`              | `string`      | `Y`       | Unique user ID in the merchant system    |

> Request example:
> 
```http
POST /rest/paymentgate/simple/ HTTP/1.1
Api-sign: *****
Content-Type: application/json

{
    "shop_key": "00112233-4455-6677-8899-aabbccddeeff",
    "amount": 29900,
    "order_currency": "RUB",
    "payment_currency": "RUB",
    "payment_method": "card_transfer",
    "order_number": "order-12345",
    "payment_details": "Payment via order 12345",
    "success_url": "https://example.com/success",
    "fail_url": "https://example.com/fail",
    "lang": "en",
    "user_id": "12345"
}
```

> Response example:

```shell
HTTP/1.1 200 OK
Content-Type: application/json

{
    "redirect_url": "https://example.com/redirect",
    "order_token": "7b0906f6-7c14-45ba-a186-86cc49d701fd",
    "status": "progress",
    "status_description": "None"
}
```

#### Card transfer H2H
For this payment method, you need to send an additional field `payment_method_details` with the selected bank code field. 


> You can get the list of available banks from the request [Get Avaible Banks](https://hackmd.io/6aGUyzRlSuuLATeb6QIUvw?view#Available-Banks)
> If you do not receive available banks, adjust the amount. It is advisable to adjust by a random number within 100-2000 minor units to the account amount.
> 
> You can also skip requesting the list of available banks by specifying the code `any` when creating a transaction — in this case, the transaction will be created with one of the available banks. To ensure successful transaction creation, use a random, non-round payment amount.

The POST request endpoint is `/rest/paymentgate/simple/`

| Field                  | Type          | Mandatory | Description                              |
|------------------------|---------------|-----------|------------------------------------------|
| `user_id`              | `string`      | `Y`       | Unique user ID in the merchant system    |

> Request example:
> 
```http
POST /rest/paymentgate/simple/ HTTP/1.1
Api-sign: *****
Content-Type: application/json

{
    "shop_key": "00112233-4455-6677-8899-aabbccddeeff",
    "amount": 29900,
    "order_currency": "RUB",
    "payment_currency": "RUB",
    "payment_method": "card_transfer",
    "order_number": "order-12345",
    "payment_details": "Payment via order 12345",
    "payment_method_details": {
        "code": "Available bank"
    },
    "success_url": "https://example.com/success",
    "fail_url": "https://example.com/fail",
    "lang": "en",
    "user_id": "12345"
}
```

> Response example:

```shell
HTTP/1.1 200 OK
Content-Type: application/json

{
    "redirect_url": "https://example.com/redirect",
    "order_token": "7b0906f6-7c14-45ba-a186-86cc49d701fd",
    "billing_details": {
        "type": "card",
        "bank_name": "Example Bank",
        "cardholder": "John Doe",
        "card_number": "1234567890123456"
    }
}
```
In the `Card transfer` method, the `type` field will have the value `card` in it

When a cross-border transfer type is used, the response to the creation request will be returned as follows. For cross border type method response example:

```shell
HTTP/1.1 200 OK
Content-Type: application/json

{
    "redirect_url": "https://example.com/redirect",
    "order_token": "7b0906f6-7c14-45ba-a186-86cc49d701fd",
    "billing_details": {
        "type": "card",
        "country": "Таджикистан",
        "user_id": "12345_user",
        "bank_name": "Спитамен банк",
        "cardholder": "Spitamen P.",
        "card_number": "1234567890123456",
    }
}
```


### Phone transfer
The POST request endpoint is `/rest/paymentgate/simple/`

> Request example:
> 
```http
POST /rest/paymentgate/simple/ HTTP/1.1
Api-sign: *****
Content-Type: application/json

{
    "shop_key": "00112233-4455-6677-8899-aabbccddeeff",
    "amount": 29900,
    "order_currency": "RUB",
    "payment_currency": "RUB",
    "payment_method": "phone_transfer",
    "order_number": "order-12345",
    "payment_details": "Payment via order 12345",
    "success_url": "https://example.com/success",
    "fail_url": "https://example.com/fail",
    "lang": "en",
    "user_id": "12345"
}
```

> Response example:

```shell
HTTP/1.1 200 OK
Content-Type: application/json

{
    "redirect_url": "https://example.com/redirect",
    "order_token": "7b0906f6-7c14-45ba-a186-86cc49d701fd",
    "status": "progress",
    "status_description": "None"
}
```

#### Phone transfer H2H
For this payment method, you need to send an additional field `payment_method_details` with the selected bank `code` field. 

> You can get the list of available banks from the request [Get Avaible Banks](https://hackmd.io/6aGUyzRlSuuLATeb6QIUvw?view#Available-Banks)
> If you do not receive available banks, adjust the amount. It is advisable to adjust by a random number within 100-2000 minor units to the account amount.
> 
> You can also skip requesting the list of available banks by specifying the code `any` when creating a transaction — in this case, the transaction will be created with one of the available banks. To ensure successful transaction creation, use a random, non-round payment amount.

The POST request endpoint is `/rest/paymentgate/simple/`


> Request example:
> 
```http
POST /rest/paymentgate/simple/ HTTP/1.1
Api-sign: *****
Content-Type: application/json

{
    "shop_key": "00112233-4455-6677-8899-aabbccddeeff",
    "amount": 29900,
    "order_currency": "RUB",
    "payment_currency": "RUB",
    "payment_method": "phone_transfer",
    "order_number": "order-12345",
    "payment_details": "Payment via order 12345",
    "payment_method_details": {
        "code": "Available bank"
    },
    "success_url": "https://example.com/success",
    "fail_url": "https://example.com/fail",
    "lang": "en",
    "user_id": "12345"
}
```

> Response example:

```shell
HTTP/1.1 200 OK
Content-Type: application/json

{
    "redirect_url": "https://example.com/redirect",
    "order_token": "7b0906f6-7c14-45ba-a186-86cc49d701fd",
    "billing_details": {
        "type": "sbp",
        "bank_name": "Example Bank",
        "cardholder": "John Doe",
        "phone_number": "89991234987"
    },
    "status": "progress",
    "status_description": "None"
}
```
When a cross-border transfer type is used, the response to the creation request will be returned as follows. For cross border type method response example:

```shell
HTTP/1.1 200 OK
Content-Type: application/json

{
    "redirect_url": "https://example.com/redirect",
    "order_token": "7b0906f6-7c14-45ba-a186-86cc49d701fd",
    "billing_details": {
        "type": "sbp_spec",
        "country": "Таджикистан",
        "user_id": "12345_user",
        "bank_name": "Спитамен банк",
        "cardholder": "Spitamen P.",
        "phone_number": "89991234987"
    }
}
```
In the `Phone transfer` method, the `type` field will have the value `sbp` in it

### Deeplinks (Deep Link Payments)

#### Overview

Deeplinks are supported **only for `card_transfer` and `phone_transfer` payment methods** and **only if available for the selected bank and channel**.

A payment with deeplinks is created **exactly the same way as a regular transaction** — no additional request parameters are required.

If deeplinks are available, they are returned in the response inside `billing_details.deep_link`.

> If deeplinks are not available for the transaction, the `deep_link` field will be absent in the response.

---

#### Automatic redirect on mobile devices

When the payment `redirect_url` is opened **from a mobile device**, the system will **automatically redirect the user to the corresponding bank application** using the available deeplink.

If automatic redirection is not possible (for example, the bank app is not installed), the standard payment page will be shown.

---

#### Supported payment methods

| Payment method   | Deeplinks |
|------------------|-----------|
| `card_transfer`  | Yes (if available) |
| `phone_transfer` | Yes (if available) |
| Other methods    | No |

---

#### Request

The request format **does not differ** from a standard `card_transfer` or `phone_transfer` payment.

Example (`card_transfer`):

```http
POST /rest/paymentgate/simple/ HTTP/1.1
Api-sign: *****
Content-Type: application/json

{
  "shop_key": "00112233-4455-6677-8899-aabbccddeeff",
  "amount": 510400,
  "order_currency": "RUB",
  "payment_currency": "RUB",
  "payment_method": "card_transfer",
  "order_number": "order-12345",
  "payment_details": "Payment via order 12345",
  "success_url": "https://example.com/success",
  "fail_url": "https://example.com/fail",
  "lang": "en",
  "user_id": "12345"
}
```

#### Response (with deeplinks)

If deeplinks are available for the selected bank and payment method (`card_transfer` or `phone_transfer`), they are returned in the response inside `billing_details.deep_link`.

When the `redirect_url` is opened **from a mobile device**, the system will **automatically attempt to redirect the user to the corresponding bank application** using one of the available deeplinks.

If automatic redirection is not possible (for example, the bank application is not installed), the user will remain on the standard payment page.

#### Example response

```json
{
  "redirect_url": "https://decard.me/frontage/payment/9976p24f-5aca-4a3a-9e68-2502c864862c/",
  "order_token": "9976c24f-5aca-4a3a-9e68-2502c864852c",
  "status": "pending",
  "status_description": "None",
  "billing_details": {
    "type": "card",
    "country": "",
    "user_id": "",
    "bank_name": "Some bank",
    "deep_link": {
      "ios": {
        "vtb": [],
        "sber": [],
        "tbank": [
          "tbank://qr.nspk.ru?invoiceId=f6e57957-f255-40fa-8403-11c93c6bf5e0&invoiceHash=c56p533f5e24e35aa59edebf288722d41f0d1c93d485949aaf1833595a153afb8eb68581226264fa2338339cbaf9990a4878685c9d2ed1bd6025c7079aede35db"
        ]
      },
      "android": {
        "vtb": [],
        "sber": [],
        "tbank": [
          "tbank://qr.nspk.ru?invoiceId=f6e57957-f255-40fa-8403-11c93c6bf5e0&invoiceHash=c56c63f5e24e3535aa59edebf288722d41f0d1c93d485949aaf1833595a153adb8eb68581226264fa2338339cbaf9990a4878685c9d2ed1bd6025c7079aede35db"
        ]
      }
    },
    "cardholder": "James Dean",
    "card_number": "1234567890987654",
  }
}
```


`deep_link` object:
| Field         | Type            | Description                                 |
| ------------- | --------------- | ------------------------------------------- |
| `ios`         | `object`        | Deeplinks for iOS banking applications      |
| `android`     | `object`        | Deeplinks for Android banking applications  |
| `<bank_code>` | `array[string]` | List of deeplink URLs for the specific bank |

### Mobiletopup
The POST request endpoint is `/rest/paymentgate/simple/`

> Request example:
> 
```http
POST /rest/paymentgate/simple/ HTTP/1.1
Api-sign: *****
Content-Type: application/json

{
    "shop_key": "00112233-4455-6677-8899-aabbccddeeff",
    "amount": 29900,
    "order_currency": "RUB",
    "payment_currency": "RUB",
    "payment_method": "mobile_topup",
    "order_number": "order-12345",
    "payment_details": "Payment via order 12345",
    "success_url": "https://example.com/success",
    "fail_url": "https://example.com/fail",
    "lang": "en",
    "user_id": "12345"
}
```

> Response example:

```shell
HTTP/1.1 200 OK
Content-Type: application/json

{
    "redirect_url": "https://example.com/redirect",
    "order_token": "7b0906f6-7c14-45ba-a186-86cc49d701fd",
    "billing_details": {
        "type": "mobile_topup",
        "bank_name": "Example Bank",
        "cardholder": "John Doe",
        "phone_number": "89991234987"
    },
    "status": "progress",
    "status_description": "None"
}
```

### SBP
The POST request endpoint is `/rest/paymentgate/simple/`

> Request example:
> 
```http
POST /rest/paymentgate/simple/ HTTP/1.1
Api-sign: *****
Content-Type: application/json

{
    "shop_key": "00112233-4455-6677-8899-aabbccddeeff",
    "amount": 29900,
    "order_currency": "RUB",
    "payment_currency": "RUB",
    "payment_method": "sbp",
    "order_number": "order-12345",
    "payment_details": "Payment via order 12345",
    "success_url": "https://example.com/success",
    "fail_url": "https://example.com/fail",
    "lang": "en"
}
```

> Response example:

```shell
HTTP/1.1 200 OK
Content-Type: application/json

{
    "redirect_url": "https://example.com/redirect",
    "order_token": "7b0906f6-7c14-45ba-a186-86cc49d701fd",
    "status": "progress",
    "status_description": "None"
}
```

### P2P: The actual payment does not match the declared amount 


If the payer transferred more or less money to the P2P order, the order goes to the status - **AMOUNT_MISMATCH**. 
This requires coordination with the merchant's system. 
To agree with the paid amount (field **approved_amount**), you need to send a confirmation request.

The POST Request endpoint is `/rest/paymentgate/order/amount-agree/`

> Alternatively, if the merchant is ready to automatically accept any paid amounts (without manual confirmation), they can contact support to enable automatic approval of mismatched payments.  
> Once enabled, orders with mismatched amounts will be confirmed automatically without the need to send a /amount-agree/ request.

\
**POST QUERY Request parameters**

| Field          | Type             | Mandatory | Description                     |
|----------------|------------------|-----------|---------------------------------|
| `shop_key`     | `string(uuid)`   | `Y`       | Shop Key                        |
| `order_token`  | `string(uuid)`   | `Y`       | Order token in system           |
| `order_number` | `string`         | `N`       | Order number in merchant system |

> Request examples:

```http
POST /rest/paymentgate/order/amount-agree/ HTTP/1.1
Api-sign: 66207dcc1a1d8596bedbe93728e128c110931c9e12be372aec48f557ba15e787
Content-Type: application/json
 {
 "shop_key": "00112233-4455-6677-8899-aabbccddeeff",
 "order_token": "7b0906f6-7c14-45ba-a186-86cc49d701fd"
 }
```

```python
import requests
import json

params = {
    "shop_key": "00112233-4455-6677-8899-aabbccddeeff",
    "order_token": "7b0906f6-7c14-45ba-a186-86cc49d701fd"
}

response = requests.request(
    "POST",
    url=f"{base_url}/rest/paymentgate/order/amount-agree/",
    data=json.dumps(params),
    headers={
        "Content-Type": "application/json",
        "Api-sign": get_api_sign(params)
    }
)
```
> Response example:
> 
```shell
HTTP/1.1 200 OK
Content-Type: application/json
{
  "payment_currency":"INR",
  "amount":110000,
  "approved_amount":110000,
  "shop":"Shop_title",
  "card_token":"",
  "card_brand":"",
  "pan_bin":"",
  "pan_mask_short":"",
  "wallet":"",
  "token":"7b0906f6-7c14-45ba-a186-86cc49d701fd",
  "number":"order-12345",
  "status":"success",
  "created_date":"06.04.2023 08:16",
  "expires_at":"06.04.2023 18:16",
  "pan_mask":"",
  "payment_type":"upi",
  "payment_account":null,
  "payment_account_detail":{},
  "billing_details":{
    "link":"upi://upi",
    "name":"beneficiary_name",
    "account":"account_info",
    "ifsc_code":"ifsc_code"
    },
  "error_code":"",
  "error_message":""
}
```

## Payment Information
The GET request endpoint is `/rest/paymentgate/order/info/`

> Request example:
> 
```http
GET /rest/paymentgate/order/info/ HTTP/1.1
Api-sign: *****
Content-Type: application/json

{
    "shop_key": "00112233-4455-6677-8899-aabbccddeeff",
    "order_token": "7b0906f6-7c14-45ba-a186-86cc49d701fd"
}
```
> Response example:

```shell
HTTP/1.1 200 OK
Content-Type: application/json

{
    "payment_currency": "RUB",
    "amount": 1000000,
    "approved_amount": 0,
    "shop": "System-Fl-RUB-12345",
    "card_token": "",
    "card_brand": "",
    "pan_bin": "",
    "pan_mask_short": "",
    "wallet": "",
    "token": "123542-9876-49dg-bacc-1234098765",
    "number": "13143adsa-d1443-413a-829s-a123444f8766d",
    "status": "pending",
    "created_date": "01.04.2025 17:12",
    "expires_at": "01.04.2025 17:27",
    "pan_mask": "",
    "payment_type": "card_transfer",
    "payment_account": null,
    "payment_account_detail": {},
    "billing_details": {
      "type": "card",
      "bank_name": "Example Bank",
      "cardholder": "John Doe",
      "card_number": "1234567890123456"
    },
    "error_code": "",
    "error_message": "",
    "settlement": {
      "currency": "RUB",
      "fee": 0,
      "fee_rate": "0.0% + 0.0 fix (min. 0.0, max. 0.0)"
    },
    "status_description": null
}
```
`billing_details` contains information for H2H

## Available Banks
The GET request endpoint is `/rest/paymentgate/methods/`

> Request example:

```http
GET /rest/paymentgate/methods/ HTTP/1.1
Api-sign: *****

GET query params:

{
    "shop_key": "00112233-4455-6677-8899-aabbccddeeff",
    "amount": 29900,
    "currency": "RUB"
}
```

> Response example:

```shell
HTTP/1.1 200 OK
Content-Type: application/json

{
  "currency": "RUB",
  "methods": [
    {
      "method": "card_transfer",
      "detail": {
        "banks": [
          {
            "name": "Example Bank 1",
            "code": "eb1"
          },
          {
            "name": "Example Bank 2",
            "code": "eb2"
          }
        ],
        "min_payment": 0,
        "max_payment": 9223372036854775807,
        "prove_methods": [
          "-"
        ],
        "required_prove_methods": [
          "-"
        ],
        "mock_default_page": false
      }
    },
    {
      "method": "phone_transfer",
      "detail": {
        "banks": [
          {
            "name": "Example Bank 3",
            "code": "eb3"
          }
        ],
        "min_payment": 0,
        "max_payment": 9223372036854775807,
        "prove_methods": [
          "-"
        ],
        "required_prove_methods": [
          "-"
        ],
        "mock_default_page": false
      }
    }
  ]
}

```

## Create Payout

### Available payout methods

| Method                  | 
|-------------------------|
| `card`                  |
| `phone-transfer` |


### Card

The POST request endpoint is `/rest/payoutgate/card/`

After the creation (initialization) of the payout, for its execution it is necessary send a request to payout confirmation

> Request example:

```http
POST /rest/payoutgate/card/ HTTP/1.1
Api-sign: *****
Content-Type: application/json

{
    "shop_key": "00112233-4455-6677-8899-aabbccddeeff",
    "amount": 9900,
    "currency": "RUB",
    "card_pan": "4000000000000002",
    "card_holder": "Jason Statham"
}
```


> Response example:

```shell
HTTP/1.1 200 OK
Content-Type: application/json

{
    "order_token": "b844d36e-af79-4fd5-81c1-ec186d999a81",
}
```


### Phone transfer
<!-- #### Available payout types: -->
<!-- - SBP
- Sberbank -->

### 1 step - get a list of banks to where we can do payout transactions *

The GET request endpoint is  `/rest/payoutgate/methods/`

#### * Check with support to see if this step is necessary for your channel.

**Request format**
| Field                    | Type             | Mandatory | Description          |
|--------------------------|------------------|-----------|----------------------|
| `shop_key`               | `string(uuid)`   | `Y`       | Shop Key             |
| `currency`               | `string(3)`      | `Y`       | Currency of payout   |
| `amount`                 | `integer`        | `Y`       | Amount in minor units|

> Request example:

```http
GET /rest/payoutgate/methods/?shop_key=00112233-4455-6677-8899-aabbccddeeff&currency=RUB&amount=500000 HTTP/1.1
Api-sign: *****
Content-Type: application/json

```
> Respons example:

```shell
HTTP/1.1 200 OK
Content-Type: application/json

[
   {
      "method": "phone_transfer",
      "detail": {
         "banks": [
            {
                "code": "b_8610",
                "name": "Другой банк РФ'"
            },
            {
                "code": "b_8607",
                "name": "Sberbank"
            },
            {
                "code": "b_10867",
                "name": "Raiffeisen"
            },
            {
                "code": "b_11190",
                "name": "Tinkoff Bank'"
            }
            ...
         ],
         "min_payout": 0,
         "max_payout": 10000000
      }
   }
]
```

### 2 step - payout initialization
The POST request endpoint is `/rest/payoutgate/phone-transfer/`

**Request format**

| Field                  | Type          | Mandatory | Description                              |
|------------------------|---------------|-----------|------------------------------------------|
| `bank_code`  			 | `string`      | `N` *       | Bank code from previus step				|
| `bank_name`  			 | `string`      | `N` *     | Human readable bank name    				|
| `recipient_phone`      | `string`      | `Y`       | Recipient phone    					    |
| `recipient_full_name`  | `string`      | `Y`       | Recipient full name    					|

#### * One of the fields is required: bank_code or bank_name

**bank_code** - if it was received in the first step
**bank_name** - if the first step is not needed for this channel

After the creation (initialization) of the payout, for its execution it is necessary send a request to payout confirmation

> Request example:

```http
POST /rest/payoutgate/phone-transfer/ HTTP/1.1
Api-sign: *****
Content-Type: application/json

{
    "shop_key": "00112233-4455-6677-8899-aabbccddeeff",
    "amount": 500000,
    "currency": "RUB",
    "recipient_phone": "+79621308251",
    "recipient_full_name": "Иванов Иван Иванович",
    "bank_name": "Сбер"
}
```
> Response example:

```shell
HTTP/1.1 200 OK
Content-Type: application/json

{
    "order_token": "b844d36e-af79-4fd5-81c1-ec186d999a81",
}
```