UrlFactory
class UrlFactory : IUrlFactory
Creates basic OAuth 2.0 endpoints URLs
-
object provides basic endpoints
Declaration
Swift
private let endpoints: IEndpoints -
Creates authorization url for the specified domain.
Declaration
Swift
init(_ endpoints: IEndpoints = Endpoints())Parameters
endpointsobject provides basic endpoints
-
Creates authorization url for the specified domain.
Declaration
Swift
public func getAuthServerHost(for domain: String) -> URL?Parameters
domaindomain, auth url should be created with.
Return Value
auth url
-
Creates logout url for the specified domain with or without https prefix.
Declaration
Swift
public func getLogoutUrl(for domain: String, shouldAddHttpsPrefix: Bool) -> URL?Parameters
domaindomain, logout url should be created with.
shouldAddHttpsPrefixspecifies should the https prefix be used.
Return Value
logout url
-
Creates token request url for the specified domain.
Declaration
Swift
public func getTokenRequestUrl(for domain: String) -> URL?Parameters
domaindomain, token request url should be created with.
Return Value
token request url
UrlFactory Class Reference