Create a Session

Call the following API to create a session:

$ curl -v \
-H 'Authorization: Bearer <token>' \
-H 'Content-Type: application/json' \
-d '{"data":"your data"}' \
https://idws.uqudo.io/api/v1/session

Response:
{
  "sessionId": "",
  "qrCodeText": "",
  "qrCodeTextWithDynamicLink": "",
}

Request:

PropertyTypeOptionalDescription

<token>

string

No

This is the authorization token needed to authorize the request. Is beyond the scope of this example on how to get the token. See Authorisation token for more details

data

string

No

This property can be used to pass the information to the mobile application in order to instruct the application what the onboarding process should be, e.g. what type of document to scan, enable the reading etc.

Note: If you are using the qr code reader mobile application provided by uqudo, data must be a Base64 encoded json string. Please see below for the structure of the JSON object.

Below you can find the JSON object structure that represents the value for the property data described above when using the qr code reader mobile application provided by uqudo. The definition of every field and possible values are explained in the SDK API described in the Enrollment Flow:

{
  "documents": [
      {
  	    "documentType": "PASSPORT",
  	    "reading": {
    	        "enabled": false,
    	        "isForceReading": false,
    	        "isForceReadingIfSupported": false,
    	        "timeoutInSeconds": -1
  	    },
  	    "isExpiredDocumentAllowed": false,
  	    "isFrontSideReviewEnabled": false,
  	    "isBackSideReviewEnabled": false,
  	    "isUploadEnabled": false,
  	    "isHelpPageDisabled": false,
  	    "faceScanMinimumMatchLevel": 2,
  	    "faceReadMinimumMatchLevel": 3
	}
  ],
  "generalConfig": {
	"secureWindowsEnabled": true,
	"userIdentifier": null,
	"returnDataForIncompleteSession": false
  },
  "backgroundCheck": {
	"enabled": false,
	"checkType": "RDC",
	"disableConsent": false,
	"enableMonitoring": false,
	"skipView": false
  },
  "facialRecognition": {
	"enabled": false,
	"isEnrollFace": false,
	"scanMinimumMatchLevel": 2,
	"readMinimumMatchLevel": 3,
      "maxAttempts": 3
  }
}

Response:

PropertyTypeOptionalDescription

sessionId

string

No

The sessionId should be stored in your backend and should match the one returned by your frontend once the onboarding process is done. It should be matched even with the jti attribute value in the JWS result returned by the uqudo info API

qrCodeText

string

No

This text must be returned to your frontend in order to create the QR code and in order to authenticate the web socket channel with the uqudo web socket server. See JavaScript Component for details

qrCodeTextWithDynamicLink

string

No

If you use the QR code reader mobile application provided by uqudo use this value to create the QR code instead of qrCodeText. Please note that qrCodeText is still needed to authenticate the web socket channel with the uqudo web socket server as described above.

If a user opens a Dynamic Link on iOS or Android, they can be taken directly to the linked content in the uqudo QR code reader mobile app. If the app is not installed the user is taken to the store and the session can continue after installation and opening the app.

Last updated