Single Session with Pre-Authorization

In this Pre-Authorization flow, the payment authorization is completed immediately after the card is presented, before the product selection. This ensures the transaction is pre-approved, reducing the risk of payment failure after the user has chosen a product. The rest of the process follows product selection, vending, and settlement, similar to the pre-selection flow.

Single Session Flow

See the diagram below:

Where:

  1. Card Holder presents the card to the Nayax Device.
  2. Nayax Device sends an authorization request to the Nayax Server.
  3. Nayax Server forwards the authorization request to the Billing Provider.
  4. The billing Provider sends an authorization response (approved) to the Nayax Server.
  5. Nayax Server sends the authorization response (approved) back to the Nayax Device.
  6. Vending machine SDK begins the session and triggers the session begin event handler (vmc_vend_event_handler_cb(vm_vend_event_on_session_begin)).
  7. Message to Card Holder: "Please Select a Product."
  8. The cardholder selects a product.
  9. Vending machine SDK sends a vend request vmc_vend_vend_request(vend_session_t *session) to the Nayax Device.
  10. Vending machine SDK transfers data internally and triggers the transaction info event handler vmc_vend_event_handler_cb(vm_vend_event_on_transaction_info).
  11. SDK triggers the vend approved event handler vmc_vend_event_handler_cb(vm_vend_event_on_vend_approved).
  12. The vending machine dispenses the product.
  13. SDK reports vend success vmc_vend_vend_status(&session, __true) and completes the vend session vmc_vend_vend_session_complete_lowlevel().
  14. Message to Card Holder: "Please Take Product."
  15. Nayax Device sends a settlement request to the Nayax Server.
  16. Nayax Server forwards the settlement request to the Billing Provider.
  17. The billing Provider sends a settlement response (OK) to the Nayax Server.
  18. Nayax Server sends the settlement response (OK) back to the Nayax Device.
  19. The vending session ends.
  20. Message to Card Holder: "Thank you & Goodbye."