Any OpenID Connect library

Configure a standard OpenID Connect client library to sign users in with onefold, with the settings to use and the options to turn off.

onefold is a standard OpenID Connect provider, so a conforming OpenID Connect client library in any language can sign users in. onefold publishes no SDK of its own; you do not need one.

Prerequisites

  • An application with a redirect URI registered
  • Its client ID, and its client secret unless it is a public client

Settings

Give the library the issuer. It reads the rest from the discovery document.

SettingValue
Issuerhttps://onefold.eitozx.com
Discovery documenthttps://onefold.eitozx.com/.well-known/openid-configuration
Response typecode
PKCEOn, with S256
Scopesopenid, plus identity and profile as you need
Client authenticationclient_secret_basic or client_secret_post; none for a public client
ID token signing algorithmRS256

If the library asks for endpoints one by one, they are listed in OAuth and OIDC endpoints.

Options to check

Libraries have defaults that suit other providers. Check these.

OptionWhat onefold needs
PKCEOn, with S256. Some libraries enable PKCE only for public clients; onefold requires it of every client by default. See PKCE.
FlowAuthorization code only. Implicit and hybrid flows are not supported.
Extra callback parametersThe callback carries iss. Use a library version that accepts it, or allow it explicitly.
Sign-outonefold has no end_session_endpoint. Turn off any option that expects RP-initiated logout.
Dynamic client registrationNot supported. Register the application in the developer portal.
Userinfo/o/userinfo/ needs the openid scope

What the library gives you

After the callback, the library has verified the ID token and exposes its claims. Use sub as the user's identifier. See Scopes and claims for what each scope returns.

The library does not manage your application's session. Start your own once the callback succeeds.

When something fails

  • An error page on onefold before the user signs in is almost always PKCE or the redirect URI. See Troubleshooting.
  • invalid_client at the token endpoint means the client ID or secret is wrong, or a public client sent a secret.

On this page