B2BSSOClient

interface B2BSSOClient

B2B SSO (Single Sign-On) authentication methods via SAML, OIDC, and external connections.

Properties

Link copied to clipboard

External SSO connection management methods.

Link copied to clipboard
abstract val oidc: B2BSSOOIDCClient

OIDC SSO connection management methods.

Link copied to clipboard
abstract val saml: B2BSSOSAMLClient

SAML SSO connection management methods.

Functions

Link copied to clipboard
abstract suspend fun authenticate(request: IB2BSSOAuthEnticateParameters): B2BSSOAuthenticateResponse

Authenticates an SSO token received via deeplink after the browser-based SSO flow completes, establishing a member session. Calls the POST /sdk/v1/b2b/sso/authenticate endpoint. Retrieves the PKCE code verifier stored during the start call, and automatically includes the intermediate session token if one is present.

Link copied to clipboard
abstract suspend fun deleteConnection(connectionId: String): B2BDeleteSSOConnectionResponse

Deletes the specified SSO connection from the organization. Calls the DELETE /sdk/v1/b2b/sso/{connection_id} endpoint. Requires an active session.

Link copied to clipboard
abstract suspend fun getConnections(): B2BGetSSOConnectionsResponse

Returns all SSO connections (SAML, OIDC, and external) configured for the organization. Calls the GET /sdk/v1/b2b/sso endpoint. Requires an active session.

Link copied to clipboard
abstract suspend fun start(parameters: B2BSSOStartParameters): AuthenticatedResponse

Initiates an SSO authentication flow by opening a browser to the SSO provider. Opens a browser session at https://{domain}/b2b/public/sso/start, then automatically exchanges the resulting token by calling POST /sdk/v1/b2b/sso/authenticate, establishing a member session on success.