IUrlFactory

protocol IUrlFactory

Protocol specifies methods which create basic OAuth 2.0 endpoint URLs.

  • Creates authorization url for the specified domain.

    Declaration

    Swift

    func getAuthServerHost(for domain: String) -> URL?

    Parameters

    domain

    domain, auth url should be created with.

    Return Value

    auth url

  • Creates logout url for the specified domain with or without https prefix.

    Declaration

    Swift

    func getLogoutUrl(for domain: String, shouldAddHttpsPrefix: Bool) -> URL?

    Parameters

    domain

    domain, logout url should be created with.

    shouldAddHttpsPrefix

    specifies should the https prefix be used.

    Return Value

    logout url

  • Creates token request url for the specified domain.

    Declaration

    Swift

    func getTokenRequestUrl(for domain: String) -> URL?

    Parameters

    domain

    domain, token request url should be created with.

    Return Value

    token request url