Integration GuideAPI Reference
Integration Guide

Webhooks: Example

Overview

  • Webhooks allow clients to receive real-time notifications about the status and progression of their transactions.
  • Once a transaction created, the platform will send webhook callbacks to the URLs provided by the client on every status change.

Note: We do not modify, transform, or alter in any way the webhook URLs received from clients. The exact URL provided in the intent creation request is the one used for all webhook callbacks.


Example

  • Sent when a payment status changes (e.g., ACCEPTED, DECLINED, ERROR). Not only terminal statuses, but all.
  • Triggered By: Internal processing events after payment intent creation.
  • Client must provide URL in: webhookUrl inside the request

{
    "transactionType": "PAYMENT",
    "transactionId": "111111",
    "status": "CAPTURED",
    "errorCode": null,
    "errorMessage": null,
    "intentId": "11111",
    "intentStatus": "FINALIZED",
    "createdAt": "2024-01-15T10:30:45.123456Z",
    "updatedAt": "2024-01-15T10:30:45.123456Z",
    "clientReferenceId": "test1",
    "paymentMethodName": "SBP",
    "submittedAmount": {
        "value": 1.00,
        "currency": "RUB"
    },
    "authAmount": {
        "value": 1.00,
        "currency": "RUB"
    },
    "rate": null,
    "declineCode": null,
    "declineCodeMessage": null,
    "additionalParams": {
        "rrn": "111",
        "approvalCode": "ABC123"
    },
    "clientData": {
        "key1": "val1",
        "key2": "val2"
    }
}
{
    "transactionType": "PAYMENT",
    "transactionId": "111111",
    "status": "DECLINED",
    "errorCode": "TESTERRORCODE",
    "errorMessage": "error message",
    "createdAt": 1705315845.123456
}

Fields Description

FieldTypeDescription
intentIdstringUnique identifier of the payment intent created by the client.
intentStatusstringCurrent status of the intent. Example: CREATED, FINALIZED.
createdAttimestampTime when the record was created, in Unix timestamp format (seconds, fractional allowed).
updatedAttimestampTime when the record was last updated.
clientReferenceIdstringClient-side identifier used to correlate this transaction with internal systems
paymentMethodNamestringPayment method used for the transaction (e.g. BankCard).
submittedAmountobjectAmount provided by the client in the original (submitted) currency.
submittedAmount.valuenumberMonetary value of the submitted amount
submittedAmount.currencystringISO currency code of the submitted amount (e.g. RUB).
authAmountobjectAmount authorised by the payment system (settlement currency).
authAmount.valuenumberMonetary value of the authorised amount.
authAmount.currencystringSuccessful flow
ISO currency code of the authorised amount.
ratenumberFX rate applied between submitted and authorised currencies. null if no conversion was applied.
transactionTypestringIdentifies the transaction type.
Enum: PAYMENT, DISBURSEMENT, REFUND
transactionIdstringUnique identifier of the transaction generated by the platform.
statusstringCurrent transaction status. Examples: CAPTURED, DECLINED, ACCEPTED
declineCodestringPlatform or bank decline code. null if the transaction was not declined
declineMessagestringHuman-readable explanation of the decline reason
errorCodestringTechnical or business error code explaining why the transaction failed.
errorMessagestringHuman-readable error message describing the failure.
additionalParamsobjectAdditional parameters returned by the payment provider or bank.
Payment Method-specific.
clientDatastringArbitrary client-provided metadata stored and returned unchanged

Some webhooks may contain additional parameters. The inclusion of this additional data depends on the payment method and may or may not be present in the request.

{
  "additionalParams": {
    "PaymentMethodAdditionalField": "string",
    "PaymentMethodAdditionalField": "string",
    "PaymentMethodAdditionalField": "string"
  }
}

Did this page help you?