Token Based Auth
@JsonClass(generateAdapter = true )
Content copied to clipboard
This class provides the authentication data by using user and password.
Constructors
Link copied to clipboard
fun TokenBasedAuth( @Json(name = "session" ) session: String? = null, @Json(name = "token" ) token: String? = null, @Json(name = "txn_id" ) transactionId: String? = null, @Json(name = "type" ) type: String? = LoginFlowTypes.TOKEN)
Content copied to clipboard
Functions
Properties
Link copied to clipboard
The txn_id should be a random string generated by the client for the request. The same txn_id should be used if retrying the request. The txn_id may be used by the server to disallow other devices from using the token, thus providing "single use" tokens while still allowing the device to retry the request. This would be done by tying the token to the txn_id server side, as well as potentially invalidating the token completely once the device has successfully logged in (e.g. when we receive a request from the newly provisioned access_token).