CommunicationTokenCredentialProviding
public protocol CommunicationTokenCredentialProviding : Cancellable
Protocol defining the shape of credentials used with Azure Communication Services.
-
Retrieve an access token from the credential.
Declaration
Swift
func token(completionHandler: @escaping CommunicationTokenCompletionHandler)
Parameters
completionHandler
Closure that accepts an optional
AccessToken
or optionalError
as parameters.AccessToken
returns a token and an expiry date if applicable.Error
returnsnil
if the current token can be returned.