Prepaid Ordering
Prepaid ordering inside OpenApp uses the POS integration capability when the POS remains responsible for item acceptance, kitchen operations, payment recording, and order closure.
OpenApp executes the customer payment before submitting the order to the POS. The completed payment is included directly in OrderSubmissionRequested.payment. If the POS rejects the paid order, OpenApp refunds the customer payment.
The fulfillment context is independent from payment timing. orderContext.type can be TABLE, PICKUP, or DELIVERY; the presence of payment on OrderSubmissionRequested is what makes the submission prepaid.
This diagram is logical. It omits delivery-mode details; see Architecture for the delivery model.
Message types:
| Message type | Direction | Purpose |
|---|---|---|
| OrderSubmissionRequested | OpenApp -> POS | Submit prepaid products and the completed OpenApp payment to the POS. |
| OrderSubmissionResult | POS -> OpenApp | Confirm accepted products or reject products with business reasons. |