Authdog

Quickstarts

Last updated Jul 11, 2026
View as Markdown

A quickstart takes you from an empty project to a working sign-in in about five minutes. You create an environment, grab its public key, install the SDK for your stack, and drop in a hosted flow or a set of components — Authdog handles the credentials, you validate the session it issues.

What a quickstart gives you

Every Authdog integration is built on the same session model. A user signs in against your environment, and Authdog issues a session: a signed JWT delivered as the authdog-session cookie (also usable as an Authorization: Bearer <token> header). Your app never touches raw credentials — it only validates the issued session against the identity provider's userinfo endpoint using your environment's public key (pk_...).

The three primitives

No matter the framework, an integration is just three pieces:

  • A session resolver — reads the authdog-session cookie (or Bearer token), verifies it, and exposes the current user to your code.
  • A protected-route gate — the server-side enforcement point that rejects unauthenticated requests with a 401 and lets authenticated ones through.
  • A sign-out handler — clears the session cookie and redirects back to your app.

Frontend SDKs wrap these in hooks and route guards; backend SDKs wrap them in middleware. Learn the model in depth in Sessions & tokens.

The five-minute path

  1. In the console, create a tenant, a project, and an environment (e.g. dev).
  2. Copy the environment's public key (pk_...) — this is all your app needs to validate sessions.
  3. Install the SDK for your stack (below) and configure it with the public key and your API base URL (NEXT_PUBLIC_API_ENDPOINT).
  4. Add authentication UI: the hosted Account portal for zero-config sign-in, or drop-in components for full control.
  5. Protect a route with the gate and confirm the session resolves.

Pick your stack

Frontend — sign users in and manage the session in the browser:

  • Next.js, React, Remix, SvelteKit, TanStack Start
  • Vue / Nuxt, Angular, Astro, Gatsby, RedwoodJS
  • React Native / Expo

Backend — validate sessions and call the REST API from your server:

  • Node (Express, Fastify)
  • Python (FastAPI, Django, Flask)
  • Go, Rust, Java, .NET (C#)

Each SDK exposes the same three primitives with idiomatic bindings for the framework.

Next steps

  • Guides — task-oriented recipes for multi-tenant apps, SSO, and provisioning.
  • Backend requests — verify sessions and protect APIs on the server.
  • Components — the drop-in UI reference.

Learn more