TokenProvider
@objc
public protocol TokenProvider
TokenProvider protocol.
Conform to the TokenProvider protocol in order to generate the token for the user that you want to authenticate.
-
Method
fetchTokenwill return the token on success or error on failure.Precondition
userIdshould not be nil.Declaration
Swift
func fetchToken(userId: String, completionHandler completion: @escaping (String, Error?) -> Void) throwsParameters
userIdId of the user that you want to generate the token for.
completionThe block to execute when operation succeeds or fails.
View on GitHub
TokenProvider Protocol Reference