Search Results for

    Show / Hide Table of Contents

    TSphinxLogin Class

    Component to authenticate a native application to a Sphinx server.

    Remarks

    Use TSphinxLogin component to perform authentication and authorization to a Sphinx server from a native application. It abstracts the OAuth 2 authentication code with PKCE flow required by Sphinx, by discovering the authorization and token endpoints, performing the HTTP requests passing the proper parameters, processing the response provided to the redirect URLs and saving the identity and access tokens in memory. Usage is simple, just properly set some key properties like Authority, ClientId and Scope and then use available methods like Login to effectively login to the server.

    Syntax

    Unit: Sphinx.Login

    TSphinxLogin = class(TComponent);

    Methods

    Name Description
    Login Starts the process to login to the application.
    Logout Logs out the user from the application.
    IsLoggedIn Indicates if a user is logged in the application.
    AuthResult Provides information about the logged user.
    RequestToken Retrieves access token using client credentials flow.

    Properties

    Name Description
    Authority The base URL of the Sphinx server to authenticate to.
    ClientId The client id used to identity the native application in the Sphinx server.
    Scope The scope to be required to the Sphinx server.

    Events

    Name Description
    OnUserLoggedIn Event fired whenever a user is logged in.
    OnGetBrowser Fires before the browser is launched to show the login page.
    In This Article
    Back to top TMS Sphinx v1.16
    © 2021 - 2025 tmssoftware.com