Système U

Ready

Tap "Request Auth Token" to start the auth flow

Request Auth Token

Auto-triggered on load · calls GET_TOKEN via Flutter bridge

Flow (RFC 8693 Token Exchange)

1. Webview calls window.MMU.auth.getToken() from the MMU Bridge SDK

2. SDK calls flutter_inappwebview.callHandler('GET_TOKEN')

3. Flutter exchanges AT1 → AT2 with ForgeRock CIAM (scope: espaceclient.partenaire.jeux, 5 min lifetime)

4. Flutter resolves the Promise with AT2 — webview decodes JWT claims and fetches account data automatically

Diagnostic log

Initialising…

Fetch Account Data

Auto-called after token arrives · GET /compte

API Documentation

Method: GET  Scope: espaceclient.partenaire.jeux

GET https://ext-api.systeme-u.com/espaceclient-comptes-process-api/v1/compte
Authorization: Bearer <AT2>

// 401 → window.MMU.auth.getToken() → Flutter re-exchanges → retry

Returns: nom, prenom, email, numeroCarteU, idIndividu, adresses…

Cache-busted with ?t=<timestamp> on every call

Request log

Communication Preferences

PUT /allowsCommunication

API Documentation

Method: PUT  Scope: espaceclient.partenaire.jeux

PUT https://ext-api.systeme-u.com/espaceclient-comptes-process-api/v1/allowsCommunication
Authorization: Bearer <AT2>
Content-Type: application/json

{ "allowEmail": true, "allowSms": true }

Returns: 204 No Content on success

Copy Code

Copies DEMO2025 to clipboard

API Documentation

navigator.clipboard.writeText('DEMO2025')

Open External URL

Opens www.google.com in the same tab

API Documentation

window.open('https://google.com', '_self')

Camera Access

Accesses device camera via getUserMedia

API Documentation

navigator.mediaDevices.getUserMedia({
  video: { facingMode: 'environment' }
})

Download — URL only

Campaign image PARTNER_DOWNLOAD_FILE with URL only

API Documentation

Handler: PARTNER_DOWNLOAD_FILE

getFlutterHandler('PARTNER_DOWNLOAD_FILE', {
  url: 'https://jeu.magasins-u.com/image/campaign.jpg'
})

Download — URL + Metadata

Campaign image PARTNER_DOWNLOAD_FILE with title, description, folder

API Documentation

Handler: PARTNER_DOWNLOAD_FILE

getFlutterHandler('PARTNER_DOWNLOAD_FILE', {
  url: 'https://jeu.magasins-u.com/image/campaign.jpg',
  title: 'Campagne Système U',
  description: 'Participez à la campagne et gagnez des lots',
  folder: 'systeme-u'
})

Save Image to Phone

Campaign image Saves image directly to device gallery

API Documentation

Handler: PARTNER_DOWNLOAD_FILE

getFlutterHandler('PARTNER_DOWNLOAD_FILE', {
  url: 'https://jeu.magasins-u.com/image/campaign.jpg',
  title: 'Campagne Système U',
  description: 'Participez à la campagne',
  folder: 'systeme-u'
})

Native Share

Campaign image Shares image + text via SHARE_CONTENT handler

API Documentation

Handler: SHARE_CONTENT

getFlutterHandler('SHARE_CONTENT', {
  file_url: 'https://jeu.magasins-u.com/image/campaign.jpg',
  text: 'Participez à la campagne Système U !',
  title: 'Système U — Campagne',
  folder: 'systeme-u'
})