Skip to Content
Open Beta — managed Kubernetes, DNS & more are live.
🎫

Single sign-on (SSO)

Updated 2026-11-20
On this page

Single sign-on (SSO)

Patrii Cloud can act as an OpenID Connect (OIDC) and OAuth2 identity provider, so you can sign in to other applications with your Patrii Cloud account and connect integrations securely.

When Patrii Cloud is your identity provider, your users authenticate once against Patrii Cloud and your application receives standard tokens describing who they are. There is no separate password to manage in each app.

The implementation follows the OpenID Connect and OAuth2 standards, so it works with common identity libraries out of the box. Your app reads the discovery document to learn the authorize, token, userinfo and key endpoints, and validates tokens against the published keys.

Screenshot — The consent screen a user sees when a third-party application requests access to their Patrii Cloud identity
The consent screen a user sees when a third-party application requests access to their Patrii Cloud identity

Key concepts

Identity provider (IdP) — The service that authenticates users and issues tokens; here, Patrii Cloud.

OpenID Connect — An identity layer on top of OAuth2 that returns a verifiable ID token about the user.

Discovery document — A well-known URL that lists all the OIDC endpoints and settings for automatic configuration.

Consent screen — The page where a user approves an application's request to use their identity.

JWKS — The published set of public keys your app uses to verify the signature on issued tokens.

Before you start

  • An application that supports OpenID Connect or OAuth2.
  • The client credentials Patrii Cloud issues for your application.
  • A redirect URL in your application to receive the sign-in result.

Step by step

  1. Read the discovery document

    Point your app at the OIDC discovery URL to auto-configure the authorize, token, userinfo and JWKS endpoints.

  2. Configure your application
    • Set your client credentials and redirect URL.
    • Request the scopes your app needs (for example openid, profile, email).
  3. Send users to sign in

    Redirect users to the authorization endpoint; they authenticate with Patrii Cloud and approve the consent screen.

    Screenshot — A user approving the consent screen
    A user approving the consent screen
  4. Exchange the code for tokens

    Your app exchanges the returned authorization code at the token endpoint for an ID token and access token.

  5. Read the user and verify tokens

    Call the userinfo endpoint for profile details, and validate token signatures against the JWKS keys.

Examples

Fetch the OIDC discovery document
curl https://api.patrii.cloud/oauth2/.well-known/openid-configuration
Fetch the signing keys (JWKS)
curl https://api.patrii.cloud/oauth2/jwks
Get the signed-in user's profile
curl -H "Authorization: Bearer $ACCESS_TOKEN" \
  https://api.patrii.cloud/oauth2/userinfo

Limits & specifications

Standard OIDC / OAuth2 endpoints:

EndpointPurpose
/oauth2/.well-known/openid-configurationDiscovery document listing all endpoints.
/oauth2/authorizeWhere users sign in and grant consent.
/oauth2/tokenExchange the authorization code for tokens.
/oauth2/userinfoReturn the authenticated user's profile.
/oauth2/jwksPublic keys used to verify token signatures.

Best practices

  • Use the discovery document instead of hard-coding endpoints so your app keeps working if they change.
  • Request only the scopes your application actually needs.
  • Always validate token signatures against the JWKS keys before trusting a token.
  • Keep your client secret confidential and out of source control.

FAQ

Which standards does Patrii Cloud support?
Patrii Cloud implements OpenID Connect and OAuth2, with standard discovery, authorization, token, userinfo and JWKS endpoints.
How does my app learn the endpoints?
Read the discovery document at the well-known URL; it lists every endpoint so most libraries configure themselves automatically.
Can I automate the API without a browser sign-in?
Yes. For scripts and services, use application credentials to authenticate directly instead of the interactive sign-in flow.

Learn more

Everything you can do here in the console is also available through the Patrii Cloud API for automation and scripting.

Was this article helpful?
Thank you for your feedback. Still stuck? Contact us