1.7. Preauth Form, Capture and Cancel

Introduction

Preauthorization is a transaction type in which bank blocks the specified amount in the Payer’s card account and does not allow the cardholder to use this blocked money. It is important to know that the block remains for a definite period of time depending on whether this is a debit or a credit card (usually the maximum block period is 7 days for debit cards and 28 days for credit cards). Preauth Form integration allows Connecting Party to exclude itself from storing, processing, or transmitting Payer’s cardholder data or other sensitive payment details. Such data is submitted by Payer on Payneteasy hosted payment form in PCI DSS certified environment.
Capture is a transaction followed after preauth which deducts the locked amount from Payer’s card.
Cancel is opposite of Capture which cancels the deduction and returns locked amount back to Payer’s card.
All forms can be customized. Follow the Forms Customization reference to see examples and macros of Payment Page Customization, Prefilled Cardholder Data in Payment Page, Wait Page Customization and Finish Page Customization.

See terms definitions in Glossary.

Preauth Form Flow

  skinparam roundcorner 20
  skinparam sequenceArrowThickness 2
  skinparam ParticipantPadding 30
  actor Плательщик as Customer
  participant "Веб-сайт\nПрисоединяющейся Стороны" as Merchant
  participant "Платёжный Шлюз" as g
  autonumber
  Customer -> Merchant: Инициализация
  activate Merchant
  == Запрос проведения оплаты ==
  Merchant -> g: api/v2/preauth-form
  activate g
  g --> Merchant: Redirect-url, orderId
  deactivate g
  Merchant -> Customer: Предоставление redirect-url \nбраузеру Плательщика
  deactivate Merchant
  activate Customer
  Customer -> g: GET redirect-url
  deactivate Customer
  activate g
  g --> Customer: Форма оплаты
  deactivate g
  activate Customer
  Customer -> g: Подтверждение формы
  deactivate Customer
  activate g
  g --> g: Обработка платежа
  == Финальное перенаправление клиента ==
  g -> Customer: redirect_url веб-сайта \nПрисоединяющейся Стороны
  activate Customer
  Customer -> Merchant: POST redirect_url\nstatus, orderid
  deactivate Customer
  activate Merchant
  group Get Final Status
  == Получение обратного вызова \nПрисоединяющейся Стороны ==
  Merchant <- g: Обратный Вызов \nс финальным статусом
  g <-- Merchant: HTTP 200
  deactivate g
  == Запрос статуса ==
  Merchant -> g: api/v2/status
  activate g
  g --> Merchant: Ответ \nstatus, order-stage
  deactivate g
  end
  Merchant -> Customer: Показ результата
  deactivate Merchant

(2) To implement preauth-form request see /api/v2/preauth-form/.
(9) To implement final redirect see Final Redirect.
(11,12) To implement order status request see /api/v2/status/. Status should be requested multiple times with 3-5 seconds interval until final status will be received in response.
(13) To implement callback with final status handling see Connecting Party.

Capture Flow

  skinparam roundcorner 20
  skinparam sequenceArrowThickness 1
  skinparam maxmessagesize 100
  skinparam sequenceParticipant underline
  actor Плательщик
  participant "Присоединяющаяся Сторона" as A
  participant "Платёжный Шлюз" as B
  hnote over A,B : Успешная транзакция преавторизации
  autonumber
  group Опционально
  Плательщик -> A: Инициация списания
  activate A
  end
  == Списание ==
  A -> B: api/v2/capture
  activate B
  B --> A: ИД транзакции
  B -> B: Обработка списания
  group Получение финального статуса
  == Получение обратного вызова \nПрисоединяющейся Стороны ==
  A <- B: Обратный вызов с финальным статусом
  A --> B: HTTP 200
  deactivate B
  == Запрос статуса ==
  A -> B: Получение статуса по ИД транзакции api/v2/status
  activate B
  B --> A: Ответ со статусом, Order-stage
  deactivate B
  end
  group Опционально
  A --> Плательщик: Конечный статус
  deactivate A
  end

(1) Capture can be initiated by Connecting Party based on internal business model or Payer’s request.
(2) To implement capture request see /api/v2/capture/.
(5) Callback for Capture will be sent only if notify_url was provided in initial transaction request or additional callback URL for Capture transactions is specified on the endpoint level. If server_callback_url was provided in initial transaction request, callback for Capture will not be sent. To implement callback with final status handling see Connecting Party Callbacks.
(7) To implement order status request see /api/v2/status/. Status should be requested multiple times with 3-5 seconds interval until final status will be received in response.
(9) Final Status can be sent by Connecting Party based on internal business model or by Payer’s request.

Cancel Flow

  skinparam roundcorner 20
  skinparam sequenceArrowThickness 1
  skinparam maxmessagesize 100
  skinparam sequenceParticipant underline
  actor Плательщик
  participant "Присоединяющаяся Сторона" as A
  participant "Платёжный Шлюз" as B
  hnote over A,B : Успешная транзакция преавторизации
  autonumber
  group Опционально
  Плательщик -> A: Инициация отмены
  activate A
  end
  == Отмена ==
  A -> B: api/v2/return
  activate B
  B --> A: ИД транзакции
  B -> B: Обработка отмены
  group Получение финального статуса
  == Получение обратного вызова \nПрисоединяющейся Стороны ==
  A <- B: Обратный вызов с финальным статусом
  A --> B: HTTP 200
  deactivate B
  == Запрос статуса ==
  A -> B: Получение статуса по ИД транзакции api/v2/status
  activate B
  B --> A: Ответ со статусом, Order-stage
  deactivate B
  end
  group Опционально
  A --> Плательщик: Конечный статус
  deactivate A
  end

(1) Cancel can be initiated by Connecting Party based on internal business model or Payer’s request.
(2) To implement cancel request see /api/v2/return/.
(5) Callback for Cancel will be sent only if notify_url was provided in initial transaction request or additional callback URL for Cancel transactions is specified on the endpoint level. If server_callback_url was provided in initial transaction request, callback for Cancel will not be sent. To implement callback with final status handling see Connecting Party Callbacks.
(7) To implement order status request see /api/v2/status/. Status should be requested multiple times with 3-5 seconds interval until final status will be received in response.
(9) Final Status can be sent by Connecting Party based on internal business model or by Payer’s request.