Integration Steps
Prerequisite
Create the User: Ensure the user is initialised in the Saber system with proper phone, email, and has completed basic KYC verification.Step 1: Generate the HMAC Signature
A unique signature must be generated dynamically on your secure server backend for each user session:Step 2: Generate Redirect URL
Once the signature is created for the user, compile the redirect link with the following query parameters:
Base URLs:
Example URLs:
With redirect URL (user will be redirected after completion):
Step 3: Redirect User to the Widget
Once the URL is generated, redirect your user to the link. The user will see the EDD form interface. Post-Completion Behaviour:- With
redirect_url: After successful EDD completion, the user will be automatically redirected to the specified URL after 10 seconds. - Without
redirect_url: After completion, the user will remain in the widget and see the EDD status screen showing their verification status.
Integration Options
Option 1: Direct Redirect
Redirect the user directly to the EDD Widget URL in the same browser tab:Option 2: Iframe Integration (Recommended)
Embed the EDD Widget as an iframe inside your page for a seamless user experience:
📘 For iframe integration, it is recommended to omit the redirect_url parameter so users see the status screen inside the iframe rather than being redirected away from your application.
Option 3: WebView Integration (Mobile Apps)
For React Native or native mobile apps, use a standard WebView component:EDD Status Flow
The EDD Widget supports the following status states:Security Considerations
URL Expiration
⚠️ Warning: The URL validity is 10 minutes from the creation of the signature. Always generate URLs dynamically in real-time just before redirecting users.
CORS and Origin Validation
The widget validates the origin of incoming requests. Ensure your web domain is correctly registered and whitelisted with Saber Money for iframe integrations.HTTPS Required
All integrations must use HTTPS securely in production environments.Error Handling
Common Error Scenarios
- Invalid Signature: Check timestamp validity and signature generation logic.
- Expired URL: Generate a fresh signature.
- User Not Found: Ensure user is created and exists in the Saber system.
- Insufficient Permissions: Verify user has completed basic KYC.
Event Timing
close: Fired when the user clicks the close button or navigates away from the widget.completed: Fired when the user successfully submits all required EDD information.error: Fired when validation fails, API errors occur, or other issues prevent EDD completion.token_expired: Fired when the HMAC signature expires (10-minute validity window).
Event Handling Best Practices
- Always Verify Origin: Check that events come from the correct Saber Money domain.
- Handle All Events: Implement handlers for all four event types to provide a smooth user experience.
- Token Expiration: For
token_expired, automatically generate a new signature and reload the widget. - Error Recovery: For
errorevents, provide clear messaging and retry options when appropriate. - User Feedback: Show appropriate loading states, success messages, and error notifications.
- Graceful Closure: Handle
closeevents by returning users to a logical point in your application flow.