C2A-03 Checkout
Hands a fully resolved order to Azotte. Submission returns immediately with 202 Accepted and a trackingNumber — actual payment authorization, 3DS, capture, and entitlement delivery happen asynchronously through Kafka workers.
You then poll the status endpoint until the order reaches a terminal state.
Concepts
- Async — HTTP request enqueues the order on Kafka. The response is not a payment confirmation.
- Tracking — every checkout returns a
trackingNumber— the only identifier needed to poll status. - Webhook-first — a payment is
Capturedonly after PSP webhook confirmation. The status endpoint surfaces this. - 3DS-aware — when the PSP requires a 3DS challenge, the status response carries
redirectInstructions(HTML or URL) to forward to the end-user.
Base Route
/api/c2a/offer
The Checkout controller shares the /c2a/offer route prefix with the Offer controller. Separate controllers, separate endpoints. Standard C2A headers (x-api-key, x-tn, Content-Type: application/json) apply.
Endpoints
| # | Method | Path | Purpose |
|---|---|---|---|
| C2A-03-01 | POST | /api/c2a/offer/checkout | Submit Checkout |
| C2A-03-02 | GET | /api/c2a/offer/checkout/{trackingId}/status | Get Checkout Status |
Behaviour & Guarantees
- Idempotency — submit the same
correlationIdtwice and Azotte will not double-charge. Use a stablecorrelationIdper business order. - Webhook-first capture —
CHECK_OUT_DONEis published only once the PSP webhook is verified and the payment is captured. Don't deliver entitlements on the client side; Azotte's subscription provider has already done it before this status is reported. - Amounts — all amounts in offer / response are in milpieces (1/1000 minor-unit). Display values are
milpieces / 100. - Tenant isolation — a
trackingNumberis scoped to the tenant inx-tn. Cross-tenant lookup returns 404.
Error Statuses
messageCode | Meaning |
|---|---|
CHECK_OUT_PROCESSING | Async worker still running. |
CHECK_OUT_3DS_REQUIRED | 3DS challenge required. |
CHECK_OUT_DONE | Terminal success. |
CHECK_OUT_FAILED | Terminal failure. |
OFFER_EXPIRED | Offer past expiresAt. |
OFFER_NOT_PURCHASABLE | Showcase offer submitted to checkout. |
ORDERED_ITEM_NOT_FOUND | trackingId unknown for this tenant. |
Source
- Controller:
Azotte.Api.Gateway.Controllers.C2A.C2A_03_CheckoutController - Service:
Azotte.Business.Checkout.CheckOutService - DTOs:
Azotte.Business.Checkout.Dto/* - Background processing:
Azotte.Services.CheckOutCenter(worker),OrderHandler,OrderItemProcessorFactory - Postman:
documents/PostmanSamples/C2A API.postman_collection.json