Перейти к основному содержанию
POST
/
payment
/
click
Click Pass payment
curl --request POST \
  --url https://fbox.ngrok.io/payment/click \
  --header 'Content-Type: application/json' \
  --data '
{
  "amount": 1000,
  "qr_code": "test"
}
'
{
  "data": {
    "status_code": 0,
    "status": "successfully",
    "message": "",
    "amount": 0,
    "payment_id": "4710103925",
    "transaction_id": "3dbec60e-df7d-4c14-929a-8d79b499f7cb",
    "qr_code": null,
    "client_phone_number": "998712565009"
  },
  "error": null,
  "is_success": true
}

Обзор

Click Payment API используется для инициации платежа через Click. Эндпоинт создает платежную транзакцию и возвращает payment_id that must be used later for fiscalization.

Поля запроса

ПолеТипОбяз.Описание
amountintegerPayment amount in sums
qr_codestringUnique Click transaction identifier

Поля ответа

✅ Успешный ответ 200

ПолеТипОписание
dataobjectДанные ответа
data.status_codeintegerStatus code of payment (0 = success)
data.statusstringPayment status (successfully, failed, etc.)
data.messagestring | nullOptional message from provider
data.amountintegerPayment amount in sums
data.payment_idstringUnique payment identifier
data.transaction_idstringTransaction UUID
data.qr_codestring | nullQR code if provided
data.client_phone_numberstringClient phone number
errornullError object (always null on success)
is_successbooleanAlways true

🚫 Ответ с ошибкой 400

Примечание: Даже при ошибке валидации сервер возвращает HTTP 200.
ПолеТипОписание
datanullNo data returned
errorobjectError details
error.codeintegerInternal error code
error.messagestringПонятное описание ошибки
error.dataany | nullAdditional error details
is_successbooleanAlways false

Тело

application/json
amount
integer
обязательно

Payment amount in sums

Пример:

1000

qr_code
string
обязательно

Unique transaction identifier

Ответ

Payment successful

data
object
error
string | null
is_success
boolean
Пример:

true