SuperTokens
public class SuperTokens
Undocumented
-
initialize(apiDomain:
apiBasePath: sessionExpiredStatusCode: sessionTokenBackendDomain: maxRetryAttemptsForSessionRefresh: tokenTransferMethod: userDefaultsSuiteName: eventHandler: preAPIHook: postAPIHook: ) Undocumented
Declaration
Swift
public static func initialize(apiDomain: String, apiBasePath: String? = nil, sessionExpiredStatusCode: Int? = nil, sessionTokenBackendDomain: String? = nil, maxRetryAttemptsForSessionRefresh: Int? = nil, tokenTransferMethod: SuperTokensTokenTransferMethod? = nil, userDefaultsSuiteName: String? = nil, eventHandler: ((EventType) -> Void)? = nil, preAPIHook: ((APIAction, URLRequest) -> URLRequest)? = nil, postAPIHook: ((APIAction, URLRequest, URLResponse?) -> Void)? = nil) throws
-
Undocumented
Declaration
Swift
public static func doesSessionExist() -> Bool
-
Undocumented
Declaration
Swift
public static func signOut(completionHandler: @escaping (Error?) -> Void)
-
Undocumented
Declaration
Swift
public static func attemptRefreshingSession() throws -> Bool
-
Undocumented
Declaration
Swift
public static func getUserId() throws -> String
-
Undocumented
Declaration
Swift
public static func getAccessTokenPayloadSecurely() throws -> [String : Any]
-
Undocumented
Declaration
Swift
public static func getAccessToken() -> String?