Prerequisites: Your API key (
zupy_pk_*) and familiarity with the Authentication page. OTP is an additional verification layer on top of API key auth.OTP Policy Per Integration
Each integration has its own OTP policy, configured by Zupy during onboarding. The policy determines which customer-facing actions require identity verification.Policy Settings
Trust Levels
Zupy defines three trust level presets:Trust level examples by partner type
Trust level examples by partner type
Your trust level is assigned during onboarding based on your integration type and how you verify customer identity.
When OTP Is Required vs. Not
The OTP Flow
When your integration requires OTP for an action, follow this 3-step flow:1
Request OTP
Send the customer’s identifier (phone, email, or CPF) to request a verification code.Zupy sends a 6-digit code to the customer via WhatsApp (primary) or email (fallback). The code expires in 5 minutes.
2
Verify OTP
The customer provides the code. Send it back to Zupy for verification.On success, you receive an
otp_session token along with the customer’s profile.3
Use OTP Session
Include the session token in subsequent requests that require OTP.The session is valid for 30 minutes. After expiry, request a new OTP.
Step 1: Request OTP
X-API-Key)
Request Body
Response — 200 OK
Step 2: Verify OTP
X-API-Key)
Request Body
Response — 200 OK
Verify OTP — Errors
Step 3: Use the OTP Session
Include theX-OTP-Session header in requests that require OTP verification:
Session Expiry
The OTP session token is valid for 30 minutes (cache-backed). After expiry:- Requests with the expired token return
403with typeotp-required - Request a new OTP to get a fresh session
What Happens Without OTP
If your integration’s OTP policy requires verification for an action and you don’t provide a validX-OTP-Session header, you receive a 403 error:
This error only occurs when your specific integration’s policy requires OTP for the attempted action. If your policy doesn’t require OTP (e.g., trusted partners), you won’t see this error.
Full OTP Example
Complete end-to-end flow: request OTP, verify, then redeem a reward.Next Steps
Webhook Setup
Configure webhooks for automatic order processing
Partner Onboarding
Complete the onboarding checklist for production deployment
API Reference
Browse all endpoints with request/response schemas