Getting Started
Add Nukta SSO to your application in a few steps.
Getting Started
This guide walks you through connecting an application to Nukta SSO so your users can sign in with their Nukta identity.
1. Register an application
From the Admin console create a new OAuth client. You will receive a
client_id and client_secret. Add your redirect URI (for local development,
http://localhost:3000/api/auth/callback).
2. Redirect users to the authorize endpoint
const url = new URL('https://sso.nukta.app/oauth/authorize');
url.searchParams.set('client_id', process.env.NUKTA_CLIENT_ID!);
url.searchParams.set('redirect_uri', 'http://localhost:3000/api/auth/callback');
url.searchParams.set('response_type', 'code');
url.searchParams.set('scope', 'openid profile email');
// Send the user here to sign in.
redirect(url.toString());3. Exchange the code for tokens
After the user signs in, Nukta redirects back with a code. Exchange it for an
access token and ID token at the token endpoint.
Full request and response shapes live in the API reference.
Next steps
- Explore the API reference for every endpoint.
- Learn how organizations and roles work from the Admin docs.