post
https://api.sandbox.1money.com/v1/customers/onboarding/grants
Create a one-time-use onboarding grant token for a customer and return a hosted onboarding URL.
This is Step 2 of the hosted onboarding integration. The returned onboarding_url should be used to redirect the end user's browser to the 1money-hosted KYB onboarding page.
How It Works
- Call this endpoint with a valid
customer_id(fromPOST /v1/customers/hosted) - Receive an
onboarding_urlcontaining the grant token - Redirect the end user's browser to
onboarding_url - The grant token is exchanged for a secure session cookie (transparent to the user)
- The user lands on the hosted onboarding page and completes the KYB form
Grant Token Behavior
- Single-use: Each grant token can only be exchanged once. After use, it cannot be reused.
- Time-limited: Grant tokens expire after 30 minutes. If expired, create a new grant.
- Re-creatable: You can create multiple grants for the same customer (e.g., for re-entry after session expiry or
PENDING_RESPONSEstatus). - Session duration: After exchange, the browser session is valid for 24 hours.
Redirect URL
The optional redirect_url parameter specifies where the user is sent after completing or leaving the onboarding flow. It must be a valid URL and should be under your control. If not provided, users will be redirected to a default 1money page after onboarding.
When to Create a New Grant
| Scenario | Action |
|---|---|
| First-time onboarding | Create grant, redirect user |
| User abandoned the form | Create new grant, redirect again (progress is preserved) |
| Grant token expired | Create new grant |
Status is PENDING_RESPONSE | Create new grant to let user fix flagged items |
Constraints
- The
customer_idmust belong to a customer created viaPOST /v1/customers/hostedunder your entity. - The customer's KYB status must allow editing (
INIT,PENDING_RESPONSE, orREJECTED). Customers withAPPROVED,PENDING_REVIEW, orUNDER_REVIEWstatus cannot start a new onboarding session.
