Sanity Library Reference Docs
    Preparing search index...

    Interface OAuthAuthConfigBeta

    Authentication options for signing in with OAuth.

    interface OAuthAuthConfig {
        apiHost?: string;
        experimental_oauth: OAuthConfig;
        loginMethod?: never;
        providers?: never;
        redirectOnSingle?: never;
    }
    Index

    Properties

    apiHost?: string

    The API hostname for requests. Should usually be left undefined, but can be set if using custom cname for API domain.

    experimental_oauth: OAuthConfig

    Sign in with OAuth 2.1 (authorization code with PKCE), using an OAuth application registered for this Studio in Manage, instead of the login providers. Users get short-lived access tokens that the Studio renews in the background, and refresh tokens that rotate on every use.

    loginMethod?: never

    Not used with OAuth: the OAuth application decides how users sign in.

    providers?: never

    Not used with OAuth: the OAuth application decides how users sign in.

    redirectOnSingle?: never

    Not used with OAuth: the OAuth application decides how users sign in.