Economics approved; rewards, caps, expiration, and pending policy reviewed.
Launch, observe, reconcile, and recover.
Use production gates, retry rules, signed webhooks, reconciliation checks, and incident runbooks built for loyalty liabilities.
Production is a controlled change.
Customer mapping, consent status, duplicates, and deletion process tested.
Earn, retry, full return, partial return, and out-of-order behavior proven.
Opening balances and liability control totals reconciled with signed approval.
Least-privilege production keys stored, rotated, and monitored server-side.
Alerts, owners, webhook replay, rollback, and customer support scripts ready.
Verify the bytes before trusting the event.
Loyumi deliveries use x-loyumi-event-id, x-loyumi-timestamp, and x-loyumi-signature: v1=<hex>. Existing integrations may continue reading the legacy x-loyaltyos-* aliases during the compatibility window.
- 1
Read the raw body
Do not parse and re-serialize before verification.
- 2
Reject stale timestamps
Apply a short replay window that matches your risk policy and tolerate normal clock skew.
- 3
Compute the expected signature
HMAC-SHA256 the UTF-8 string
timestamp.raw_bodywith the endpoint secret. - 4
Compare in constant time
Only enqueue trusted events. Deduplicate by event ID and respond quickly.
expected = HMAC_SHA256(
endpoint_secret,
x_loyumi_timestamp + "." + raw_request_body
)
constant_time_compare("v1=" + hex(expected), x_loyumi_signature)Retry transport failures, not business decisions.
Retry-After; keep the same key and body.requestId.Compare three independent views.
Completed and returned order value by source reference.
Issued, clawed back, expired, redeemed, pending, and available points.
Opening, movement, closing liability, and documented adjustments.
Contain first. Preserve evidence. Recover deliberately.
Disable the affected key, endpoint, campaign, or production path without deleting evidence.
Bound environments, programs, members, source references, point value, and customer impact.
Assign incident, finance, risk, engineering, support, and communications owners.
Use replay-safe requests or authorized ledger adjustments; reconcile before reopening.
Document cause, detection gap, control improvement, and evidence that the fix works.