Payment method
INFO
Har bir javob umumiy konvertda qaytadi — code, message, messages, status_code, time — foydali yuk esa data ichida. Quyidagi jadvallar faqat data ichini tavsiflaydi.
POST /payment-method/create
This method allows adding payment-method into the account.
So‘rov tanasi
| Maydon | Tur | Majburiy | Tavsif |
|---|---|---|---|
name | string | Ha | |
shortcut | string | Yo‘q | Keyboard shortcut on the POS, F1–F12. |
type | string | Yo‘q | Only cashless can be created. Every account has exactly one cash method, created by the system; sending cash returns a validation error.. Mumkin qiymatlar: cashless. Standart: "cashless" |
subtype | string | Yo‘q | Finer classification of a cashless method: terminal, online, bank or bnpl. cash takes no subtype. Omit or send null to leave the method unclassified.. Mumkin qiymatlar: terminal, online, bank, bnpl |
{
"name": "string",
"shortcut": "F8",
"type": "cashless",
"subtype": "terminal"
}Javob
| Maydon | Tur | Tavsif |
|---|---|---|
_id | string | |
name | string | |
shortcut | string | |
type | string | cash (exactly one per account, created by the system) or cashless. Earlier versions of the API also returned card, terminal, transfer, gift, integration — these are now cashless, described by subtype and is_integration.. Mumkin qiymatlar: cash, cashless |
subtype | string | Classification of a cashless method. null when the method is cash or has not been classified yet.. Mumkin qiymatlar: terminal, online, bank, bnpl |
is_integration | boolean | The method was created by a payment integration (Payme, Click, …) rather than by a person. Replaces the old integration type.. Standart: false |
is_enabled | boolean | Standart: true |
is_default | boolean | Standart: false |
is_visible | boolean | Standart: false |
created_at | string (date-time) | |
updated_at | string (date-time) |
{
"code": 0,
"message": "Success",
"status_code": 200,
"data": {
"_id": "string",
"name": "string",
"shortcut": "string",
"type": "cash",
"subtype": "terminal",
"is_integration": false,
"is_enabled": true,
"is_default": false,
"is_visible": false,
"created_at": "2025-05-01T12:00:00Z",
"updated_at": "2025-05-01T12:00:00Z"
},
"time": "2025-05-01T12:00:00Z"
}PUT /payment-method/update
This method allows updating payment-method in the account.
So‘rov tanasi
| Maydon | Tur | Majburiy | Tavsif |
|---|---|---|---|
name | string | Ha | |
shortcut | string | Yo‘q | Keyboard shortcut on the POS, F1–F12. |
type | string | Yo‘q | Optional; omit it to keep the current type. A method cannot be changed to or from cash: a type that would do so is ignored and the rest of the update is applied.. Mumkin qiymatlar: cash, cashless |
subtype | string | Yo‘q | Finer classification of a cashless method: terminal, online, bank or bnpl. cash takes no subtype. Omit or send null to leave the method unclassified.. Mumkin qiymatlar: terminal, online, bank, bnpl |
_id | string | Ha |
{
"name": "string",
"shortcut": "F8",
"type": "cash",
"subtype": "terminal",
"_id": "67b486d242ed76693cd2cc59"
}Javob
Javob tuzilishi quyidagi bilan bir xil: POST /payment-method/create.
DELETE /payment-method/delete/{id}
Delete a payment-method
Yo‘l parametrlari
| Parametr | Tur | Majburiy | Tavsif |
|---|---|---|---|
id | string | Ha |
So‘rov tanasi
So‘rov tanasi talab qilinmaydi.
Javob
{
"code": 0,
"message": "Success",
"status_code": 200,
"data": "ok",
"time": "2025-05-01T12:00:00Z"
}GET /payment-method/get-all
Get all payment-methods
So‘rov parametrlari
| Parametr | Tur | Majburiy | Tavsif |
|---|---|---|---|
is_enabled | boolean | Yo‘q | Filter payment-methods by enabled status |
So‘rov tanasi
So‘rov tanasi talab qilinmaydi.
Javob
{
"code": 0,
"message": "Success",
"status_code": 200,
"data": [
{
"_id": "string",
"name": "string",
"shortcut": "string",
"type": "cash",
"subtype": "terminal",
"is_integration": false,
"is_enabled": true,
"is_default": false,
"is_visible": false,
"created_at": "2025-05-01T12:00:00Z",
"updated_at": "2025-05-01T12:00:00Z"
}
],
"time": "2025-05-01T12:00:00Z"
}GET /payment-method/get-by-id/{id}
Get payment-method using its _id
Yo‘l parametrlari
| Parametr | Tur | Majburiy | Tavsif |
|---|---|---|---|
id | string | Ha |
So‘rov tanasi
So‘rov tanasi talab qilinmaydi.
Javob
Javob tuzilishi quyidagi bilan bir xil: POST /payment-method/create.
GET /payment-method/get-deleted
Get deleted payment-method ids
So‘rov parametrlari
| Parametr | Tur | Majburiy | Tavsif |
|---|---|---|---|
deleted_at | string | Ha |
So‘rov tanasi
So‘rov tanasi talab qilinmaydi.
Javob
{
"code": 0,
"message": "Success",
"status_code": 200,
"data": [
"string"
],
"time": "2025-05-01T12:00:00Z"
}PUT /payment-method/set-active
This method allows setActive payment-method in the account.
So‘rov tanasi
| Maydon | Tur | Majburiy | Tavsif |
|---|---|---|---|
is_enabled | boolean | Ha | Standart: true |
_id | string | Ha |
{
"is_enabled": true,
"_id": "67b486d242ed76693cd2cc59"
}Javob
Javob tuzilishi quyidagi bilan bir xil: POST /payment-method/create.
Bu sahifa OpenAPI spetsifikatsiyasidan yaratilgan.