OutOfBandOperationsMultiAccount
public protocol OutOfBandOperationsMultiAccount
The OutOfBandOperations
protocol specifies the out-of-band (OOB) operations and actions exposed by the SDK.
This protocol also exposes methods to manage dispatch target entities. Dispatch targets allow to involve users in out-of-band operations.
A dispatch target describes a destination to which a NEVIS Mobile Authentication backend can dispatch a token.
For instance it can be the registration token that can be used to send Push notifications to a mobile application.
-
Deletes an existing Dispatch Target.
Errors
In case of failure, the following errors can be returned as part of the result:
NevisError.invalidDispatchTarget
if the Dispatch Target cannot be deleted;NevisError.generic
in case of networking or encoding error.
Declaration
Swift
func deleteDispatchTarget(for username: Username, authorizationProvider: AuthorizationProvider?, onCompletion handler: @escaping (Result<(), Error>) -> ())
Parameters
username
The username whose dispatch target is deleted.
authorizationProvider
An optional
AuthorizationProvider
to provide credentials required to perform authorization, if the delete dispatch target endpoint is protected and requires authorization.handler
A completion handler executed when the deletion is completed.
result
A single argument that represents either a successful result or a failure with an error.