@schibsted/account-sdk-browser
    Preparing search index...

    Type Alias AccountConfig

    AccountConfig: Omit<AccountBaseConfig, "env"> & {
        callbackBeforeRedirect?: IdentityBeforeRedirectCallback;
        defaultProductIds?: readonly string[];
        env?: AccountBaseConfig["env"];
        generateState: StateGenerator;
        getConsents?: ConsentReader;
        log?: LogFunction;
        refreshLoginLinks?: boolean;
        varnish?: VarnishCookieOptions;
    }

    Configuration used to create an Account instance.

    Type Declaration

    • OptionalcallbackBeforeRedirect?: IdentityBeforeRedirectCallback

      Callback triggered before a session refresh redirect happens.

    • OptionaldefaultProductIds?: readonly string[]

      Product or feature ids used by hasAccess() when no ids are passed to the method.

    • Optionalenv?: AccountBaseConfig["env"]

      Schibsted account environment. Defaults to PRE.

    • generateState: StateGenerator

      Generates the OAuth state value used by login(), loginUrl(), and the simplified login widget when no explicit state is passed.

    • OptionalgetConsents?: ConsentReader

      Reads consents forwarded in login URLs. Defaults to the Schibsted Sourcepoint integration.

    • Optionallog?: LogFunction

      Receives debug logs and consent reader errors. Without it, consent reader errors are reported through console.warn.

    • OptionalrefreshLoginLinks?: boolean

      Refresh consents of rendered login links when clicked. Defaults to true.

    • Optionalvarnish?: VarnishCookieOptions

      Optional Varnish cookie setup applied during Account initialization.