Requesting a sign-on/activation token (registering device)
Request
Once the user has requested companion device sign-on and received a success response from DSRA, the registering device should request a sign-on/activation token from DSRA. To do this, it should send a PUT request to:
https://<host>:<port>/dsra/v1/user/signOnActivationToken
If it receives a 204 response, it should wait for the pollingPeriod that it received in the response to its device registration code request.
If it receives a successful (200) response, it can then sign on.
Headers
x-correlation-id– identifier for logging, to correlate messages across a call flowAuthorization– the DSRA token provided in the response to a device registration code request. Must be preceded byBearer(note the space).
Mandatory arguments
One of the following:
clientId– if the device has previously signed in, it will already have been assigned a client ID and should use it here.deviceInformation– if the device has never signed in before, it must provide its device information. See the Device SignOn and Registration Assistant (DSRA) API documentation for details.
managedDeviceInformation– if the device is a managed device, it must provide itscaSNwithin amanagedDeviceInformationblock.
Signing on managed devices using a companion app is only supported in hybrid applications where CRM Gateway is configured.
Other arguments
None
Response
A successful response returns an HTTP 202 status. The response body contains:
clientId– the client ID assigned to the devicesignOnActivationToken– the sign-on/activation token that can be used to sign on via IAS.
Note that the sign-on/activation token expires after a (configurable) period.
If the request has not yet been approved, the service returns an HTTP 204 status.
A bad request returns an HTTP 400 status.
If the DSRA token is invalid or missing, the service returns an HTTP 401 status.
If the DSRA token has expired (that is, the expiration period returned in the response to a device registration code request (expiresAfterMillis) has been exceeded), the service returns an HTTP 403 status.
See also
Device SignOn and Registration Assistant (DSRA) API documentation