OutOfBandPayloadDecode class abstract

The object that decodes an OutOfBandPayload from a string in JSON format or a Base64 URL encoded string representing the JSON.

The OutOfBandPayload can be used to trigger an out-of-band operation (see OutOfBandOperation).

Usage example:

  [...]
  Future<void> decodeOutOfBandPayload({
    required MobileAuthenticationClient client,
    required String json,
  }) async {
    await client.operations.outOfBandPayloadDecode
      .json(json)
      .onSuccess((outOfBandPayload) {
        // handle the OutOfBandPayload
      })
      .onError((error) {
        // handle error
      })
      .execute();
  }
  [...]

The JSON is obtained from a push notification, or as a Base64 URL encoded JSON in QR codes generated by the server. JSON example:

{
  "nma_data" : {
    "token" : "b4b07559-f934-4597-a1c5-44d89f691e8f",
    "redeem_url" : "https://fido.siven.ch/nevisfido/token/redeem/authentication",
    "attributeName" : "some additional data to be included in the QR code"
  },
  "nma_data_content_type" : "application/json",
  "nma_data_version" : "1"
}

Constructors

OutOfBandPayloadDecode()

Properties

hashCode int
The hash code for this object.
no setterinherited
runtimeType Type
A representation of the runtime type of the object.
no setterinherited

Methods

base64UrlEncoded(String base64UrlEncoded) OutOfBandPayloadDecode
Specifies the JSON as Base64 URL encoded string to be decoded.
execute() Future<void>
Executes the operation asynchronously.
inherited
json(String json) OutOfBandPayloadDecode
Specifies the JSON to be decoded.
noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
onError(dynamic onError(OutOfBandPayloadError)) OutOfBandPayloadDecode
Specifies the object that will be invoked if the OutOfBandPayload could not be decoded.
onSuccess(dynamic onSuccess(OutOfBandPayload?)) OutOfBandPayloadDecode
Specifies the object that will be invoked if the OutOfBandPayload was decoded.
toString() String
A string representation of this object.
inherited

Operators

operator ==(Object other) bool
The equality operator.
inherited