Skip to content
innovorder
⌘K

Integration path

Integration Guide: E-Wallet SSO

System map · E-Wallet SSO
Guest identity
SSO token
E-Wallet

This guide describes how to integrate the Innovorder E-Wallet (e-rechargement) interface into an external guest application (e.g., via a WebView) using a Single Sign-On (SSO) mechanism.

Prerequisites

You will need the following information provided by Innovorder Support:
  • Brand ID: Unique identifier for your brand.
  • JWT Secret: A private key shared between your backend and Innovorder.

1. Generate the JWT

First, your backend must generate a signed JWT containing the user's identity. This token serves as a proof of authentication.

Payload Structure

JWT Payload
{
  "email": "user@example.com",
  "brandId": 12345,
  "date": "2023-10-27T10:00:00.000Z" // ISO 8601 String
}

Example (Node.js)

Sign JWT
const jwt = require('jsonwebtoken');

const payload = {
  email: "user@example.com",
  brandId: 691,
  date: new Date().toISOString()
};

const jwtSecret = "YOUR_SHARED_SECRET_KEY";
const signedJwt = jwt.sign(payload, jwtSecret);

console.log(signedJwt); 
// Output: eyJhbGciOiJIUzI1NiIsIn...

2. Exchange for Access Token

Unlike the Web Ordering SSO, the E-Wallet requires a valid API accessToken to perform the auto-login. You must exchange your signed JWT for an Innovorder accessToken via the API.

POST/oauth/loginExchange JWT

Send the generated JWT to receive an accessToken. The access token is valid for 24 hours; when it expires the API responds with a 401 error (token_expired) and you must exchange a fresh JWT again.

Request Body

json
{
  "autoLoginJWT": "eyJhbGciOiJIUzI1NiIsIn..."
}
Request Body Properties

Every field in the example is listed below. Explicit requiredness is shown when the endpoint contract defines it.

PropertyTypeExampleDescription
autoLoginJWTstring"eyJhbGciOiJIUzI1NiIsIn..."The auto login jwt value.

Response

json
{
  "access_token": "VALID_ACCESS_TOKEN_XYZ...",
  "token_type": "Bearer"
}
Response Properties

Every field in the example is listed below. Explicit requiredness is shown when the endpoint contract defines it.

PropertyTypeExampleDescription
access_tokenstring"VALID_ACCESS_TOKEN_XYZ..."The access token value.
token_typestring"Bearer"The token type value.

3. Redirect the User

Construct the final URL by appending the received accessToken to the autoLoginByAccessToken query parameter. Open this URL in your WebView or iframe.

https://ewallet.innovorder.fr/<brandId>/home?autoLoginByAccessToken=<accessToken>