Keep tokens server-side
KarFlows API tokens must live on your backend. Bad:OTP verification
Your backend should:- Call send OTP.
- Store
pinIdagainst the user/session. - Ask the customer for the code.
- Call verify OTP.
- Mark the phone as verified only when KarFlows returns success.
Sender names
Never let users type arbitrary sender names in your public UI. Store approved sender names server-side and send only those values to KarFlows.Webhook signatures
VerifyX-KarFlows-Signature against the raw request body before parsing JSON. Reject stale timestamps and store the delivery ID to prevent duplicate processing.
