Redirect Back to Enterprise Portal

🔄Redirect Back to Enterprise Portal

🧾 Description

After the user completes the identity verification steps on IdvWebServer—including document scan, selfie capture, and Opt-In—the user is automatically redirected back to the enterprise portal.

The redirection URL is the same redirectUrl provided by the enterprise during IDVWebToken generation.


🔁 What Happens on Redirect?

Once the user is redirected back, the enterprise portal is expected to:

  1. 🔍 Fetch the final identity verification result.
  2. 🔄 Update the user’s status based on the verification outcome.
  3. 📲 Continue with login/session handling based on the result.

🔗 API 1: Verify IDVWebToken

This API allows the enterprise to fetch the results of the IDV process.

📘 Purpose

  • Get final IDV result
  • Get KYC reference number (if KYC was enabled)
  • Retrieve user’s verification status

🧪 Request

GET https://<GM-API-SERVER-IP>:9442/v1/idvWebTokens/{web_session_id}
  • Path Parameter: web_session_id (received during token generation)
  • Authorization: Bearer Token required

✅ Sample Response

{
  "userId": "john.doe",
  "status": "VERIFIED",
  "kycReferenceId": "KYC123456789",
  "timestamp": "2025-05-26T14:22:00Z"
}

🔗 API 2: Update Status of User

This API updates the user’s status in REL-ID after successful identity verification.

📘 Purpose

Mark the user as fully onboarded (from status ONBOARDING to CREATED).

🧪 Request

PUT https://<GM-API-SERVER-IP>:9442/v1/users/{userId}/status

🔐 Headers

  • Authorization: Bearer <access_token>
  • Content-Type: application/json

📦 Request Body

{
  "status": "CREATED"
}

🧭 Recommended Sequence on Redirect

sequenceDiagram
    participant User
    participant IdvWebServer
    participant EnterprisePortal
    participant GM-API-Server

    User ->> IdvWebServer: Completes IDV Flow
    IdvWebServer ->> User: Redirect to Enterprise (with redirectUrl)
    User ->> EnterprisePortal: Lands on redirectUrl
    EnterprisePortal ->> GM-API-Server: Verify IDVWebToken
    GM-API-Server -->> EnterprisePortal: Verification Result
    EnterprisePortal ->> GM-API-Server: Update user status (to CREATED)
    EnterprisePortal -->> User: Show onboarding success / login

📌 Notes

  • The redirectUrl must be a valid HTTPS endpoint.
  • Session management (login, tokens, etc.) should be handled by the enterprise portal after status update.
  • Verification results may include failure scenarios (e.g., document mismatch or selfie failure).

✅ Completion

At this point, the user has returned to the enterprise system with verified identity and can proceed with onboarding or access to services.