Identity
P0 · Foundation
Federated Auth & User Management
Authenticate users, connect external identity providers, and manage application identities.
Auth is the block most callers will touch from React. The SDK owns redirects, refresh, and session state. Application code does not integrate each provider by hand.
Paths in the tables are relative to https://api.ultrahost.com/v1/projects/{projectId}. Pagination, idempotency, and errors are described in Conventions.
Create
Registration and invitations create identities. Provider configuration creates the federated path those identities can use.
Authentication
| SDK | REST | Description |
|---|---|---|
auth.signUp(data) | POST /auth/signup | Register a user |
auth.signIn(credentials) | POST /auth/signin | Sign in with credentials |
auth.signInWithProvider(provider) | GET /auth/oauth/{provider}/authorize | Start federated sign-in |
auth.resetPassword(email) | POST /auth/password/reset | Request a password reset |
auth.verifyEmail(token) | POST /auth/email/verify | Verify an email address |
Users
These methods are administrative. They belong on the admin client, not in a public browser bundle.
| SDK | REST | Description |
|---|---|---|
auth.users.list() | GET /auth/users | List users |
auth.users.get(id) | GET /auth/users/{id} | Retrieve a user |
auth.users.create(data) | POST /auth/users | Create a user |
auth.users.update(id, data) | PATCH /auth/users/{id} | Update a user |
auth.users.disable(id) | POST /auth/users/{id}/disable | Disable an account |
auth.users.delete(id) | DELETE /auth/users/{id} | Delete an account |
auth.users.invite(email, options?) | POST /auth/invitations | Invite a user |
Providers
| SDK | REST | Description |
|---|---|---|
auth.providers.list() | GET /auth/providers | List identity providers |
auth.providers.configure(name, config) | PUT /auth/providers/{name} | Configure a provider |
auth.providers.disable(name) | POST /auth/providers/{name}/disable | Disable a provider |
Configure
auth.providers.configure() stores the provider connection. Provider client secrets stay on the server. The browser only starts signInWithProvider() and receives a session.
Multifactor authentication is enabled per user with auth.enableMFA(config) (POST /auth/mfa/enable).
Password changes for the signed-in user use auth.updatePassword(data) (POST /auth/password/update).
Use
| SDK | REST | Description |
|---|---|---|
auth.signOut() | POST /auth/signout | End the session |
auth.refreshSession() | POST /auth/refresh | Refresh the session |
auth.getSession() | GET /auth/session | Current session |
auth.getUser() | GET /auth/me | Authenticated user |
const { user, loading, signIn, signOut } = useAuth();Wrap the tree in UltrahostProvider. The companion hooks are useAuth(), useUser(), useSession(), and usePermissions(). Details are on the React page.