What an identity contains
An identity is more than a username and password. After a successful login, Anchor persists everything needed to stay signed in:
What Anchor can do on the next run depends on what was saved. An identity with credentials and a valid browser profile starts signed in immediately. An identity with only a browser profile (for example after manual login) works until the site expires the session — then someone must sign in again.
Quick start: create an identity
Create an identity with credentials for the target application. If the application uses a preset auth flow, passauthOptionId with the flow ID.
Use an identity in browser sessions
Pass the identity ID in theidentities array when creating a session. Anchor authenticates before your agent or automation starts.
Use an identity in tasks
Passidentity_id when running an Automation Task. Anchor creates a browser session, authenticates with the identity, then executes the task.
session_id to run a task inside an existing authenticated session. By default (identity_skip_validation: true), active identities reuse their saved profile. Pass identity_skip_validation: false, or call POST /v1/identities/{identityId}/reauthenticate, to validate the profile and re-authenticate if it is stale.
When Anchor re-authenticates
Each time a session or task starts with an identity attached, Anchor decides whether a full login is needed:- Browser profile is still valid — Anchor loads the saved profile and the session starts signed in. No login steps run.
- Browser profile expired / re-auth requested, credentials available — Anchor runs the application’s auth flow using stored credentials (including MFA methods like email OTP or authenticator). The profile is refreshed for next time.
- Browser profile expired, no credentials — Common for manual-login identities. Anchor cannot re-authenticate automatically. Sign in again via the dashboard or generate a re-authenticate link (see below).
Re-authentication requires the identity to have the credentials or auth flow needed for the site’s login steps. If the site adds a new MFA requirement that wasn’t saved on the identity, update the identity or re-authenticate manually.
Generate re-authenticate links
When an identity needs a fresh login, create a token or ready-to-share URL:
Both accept an optional request body:
Send the user to
https://app.anchorbrowser.io/identity/re-authenticate?token={token} (or use reauth_url from reauth-links).
Identity metadata
Add custom metadata to identities for filtering and organization. Metadata is a flexible key-value store.Creating an identity with metadata
Filtering identities by metadata
Related
Managed Authentication Overview
Profiles vs identities and how everything connects
Applications
Configure target sites and auth flows
Run a Task
Execute automation tasks with an identity
Embedding End-User Auth UI
Let end users connect accounts from your product
Email MFA
Email OTP via forwarded inbox
API Reference
Identity endpoints

