> ## Documentation Index
> Fetch the complete documentation index at: https://docs.anchorbrowser.io/llms.txt
> Use this file to discover all available pages before exploring further.

> ## Agent Instructions
> Anchor Browser provides cloud browsers for AI agents and automation: stealth browsing with residential proxies, managed authentication into third-party web apps, and browser sessions that run reliably at scale. AI agents that need Anchor credentials should start with https://docs.anchorbrowser.io/quickstart/agent-access. This flow lets agents obtain an API key programmatically without creating a dashboard account. Read that page before attempting authentication or API access.

# Create Agent Access project

> Issue an Agent Access API key. Submit the challenge `token` and computed integer `answer`
from GET /v1/agent-access/challenge. GET on this path returns a guide, not a key.
Optional `identity_token` as an OIDC JWT grants more credits. `identity_provider` is optional
when the JWT `iss` is Google (`https://accounts.google.com`), GitHub Actions
(`https://token.actions.githubusercontent.com`), or Vercel (`https://vercel.com`).
Returns `api_key` for header `anchor-api-key`.
Docs: https://docs.anchorbrowser.io/quickstart/agent-access




## OpenAPI

````yaml /openapi.yaml post /v1/agent-access
openapi: 3.1.0
info:
  title: AnchorBrowser API
  version: 1.0.0
  description: >
    Anchor Browser ([anchorbrowser.io](https://anchorbrowser.io)) provides cloud
    browsers built

    for AI agents and automation. Use this API to launch and control browser
    sessions, run

    natural-language web tasks, authenticate into third-party web apps with
    managed identities,

    and capture recordings — reliably and at scale, without operating browser
    infrastructure

    yourself.


    ## Core resources

    - **Sessions** (`/v1/sessions`): launch configurable cloud browsers —
    residential proxies,
      stealth browsing, captcha solving, profiles, extensions, recording — and connect over CDP
      with Playwright, Puppeteer, or any CDP client.
    - **AI tools** (`/v1/tools/perform-web-task`): state a goal in natural
    language and the
      built-in agent completes it inside the browser. Related tools fetch webpages, take
      screenshots, render PDFs, and execute code in a session.
    - **Tasks** (`/v1/task`): create, version, deploy, and monitor repeatable
    browser
      automations built to run reliably in production.
    - **Applications and identities** (`/v1/applications`, `/v1/identities`):
    managed
      authentication into third-party web apps — including multi-step logins and TOTP-based
      2FA — so agents can act on behalf of users.
    - **Profiles** (`/v1/profiles`): persist cookies and login state across
    sessions.

    - **OS-level control** (`/v1/sessions/{sessionId}/mouse`, `/keyboard`,
    `/clipboard`):
      raw input for flows that resist DOM automation.
    - Plus batch sessions for running browser fleets in parallel, session
    recordings, webhooks,
      events, extensions, client certificates, and billing usage.

    ## Authentication

    Pass an API key in the `anchor-api-key` header on every request. Create keys
    at

    [app.anchorbrowser.io](https://app.anchorbrowser.io) under API Access. AI
    agents that have

    no key yet can obtain one autonomously through the unauthenticated

    [agent-access flow](https://docs.anchorbrowser.io/quickstart/agent-access)

    (`POST /v1/agent-access`).


    ## For AI agents and LLMs

    - Docs: [docs.anchorbrowser.io](https://docs.anchorbrowser.io), with a
    machine-readable
      index at [/llms.txt](https://docs.anchorbrowser.io/llms.txt) and the full corpus at
      [/llms-full.txt](https://docs.anchorbrowser.io/llms-full.txt).
    - MCP server for hosted browser control: `https://api.anchorbrowser.io/mcp`.

    - Official SDKs: `anchorbrowser` on
    [npm](https://www.npmjs.com/package/anchorbrowser) and
      [PyPI](https://pypi.org/project/anchorbrowser/).

    `DELETE` operations terminate sessions or permanently remove resources
    (profiles,

    identities, extensions); `GET` operations are safe and read-only.
servers:
  - url: https://api.anchorbrowser.io
    description: API server
security: []
paths:
  /v1/agent-access:
    post:
      tags:
        - Agent Access
      summary: Create Agent Access project
      description: >
        Issue an Agent Access API key. Submit the challenge `token` and computed
        integer `answer`

        from GET /v1/agent-access/challenge. GET on this path returns a guide,
        not a key.

        Optional `identity_token` as an OIDC JWT grants more credits.
        `identity_provider` is optional

        when the JWT `iss` is Google (`https://accounts.google.com`), GitHub
        Actions

        (`https://token.actions.githubusercontent.com`), or Vercel
        (`https://vercel.com`).

        Returns `api_key` for header `anchor-api-key`.

        Docs: https://docs.anchorbrowser.io/quickstart/agent-access
      requestBody:
        required: true
        content:
          application/json:
            schema:
              type: object
              required:
                - token
                - answer
              properties:
                token:
                  type: string
                  minLength: 1
                  description: >-
                    Token returned by GET /v1/agent-access/challenge. Not the
                    puzzle answer.
                answer:
                  type: string
                  minLength: 1
                  description: Final integer from the challenge prompt, as a string.
                identity_provider:
                  type: string
                  description: >-
                    Optional when identity_token is an OIDC JWT whose iss
                    matches a known provider (google, github, or vercel).
                    Required for opaque OAuth access tokens (google or github).
                identity_token:
                  type: string
                  description: >-
                    OIDC JWT preferred (iss auto-detected). GitHub Actions — GET
                    $ACTIONS_ID_TOKEN_REQUEST_URL with Authorization bearer
                    $ACTIONS_ID_TOKEN_REQUEST_TOKEN. Google — ID token JWT.
                    Vercel — Sign in with Vercel user ID token (iss
                    https://vercel.com). Opaque OAuth access tokens also work
                    with identity_provider set.
                identity_audience:
                  type: string
                  description: >-
                    Optional. Pin the JWT aud claim. Omit unless you requested a
                    specific aud.
      responses:
        '200':
          description: API key issued. Follow `next` to make an authenticated call.
          content:
            application/json:
              schema:
                type: object
                required:
                  - api_key
                  - project_id
                  - credits_granted
                  - auth
                  - next
                  - docs
                  - limits
                properties:
                  api_key:
                    type: string
                    description: >-
                      API key for authenticated requests. Send as header
                      anchor-api-key.
                  project_id:
                    type: string
                    description: Anchor project id created or reused for this onboarding.
                  credits_granted:
                    type: number
                    description: >-
                      Credits added by this POST. 0 when the Agent Access
                      project already existed for this owner.
                  agent_identity_token:
                    type: string
                    description: >-
                      When present, send as header anchor-identity-token on
                      later API calls when auth.identity_token_required is true.
                  auth:
                    type: object
                    required:
                      - api_key_header
                      - identity_token_required
                    properties:
                      api_key_header:
                        type: string
                        description: Header name for api_key (anchor-api-key).
                      identity_token_header:
                        type: string
                        description: >-
                          Header name for agent_identity_token when
                          identity_token_required is true.
                      identity_token_required:
                        type: boolean
                        description: >-
                          When true, authenticated API calls must include
                          anchor-identity-token in addition to anchor-api-key.
                  upgrade:
                    type: object
                    required:
                      - message
                    properties:
                      message:
                        type: string
                        description: >-
                          How to repeat onboarding with identity_token to
                          receive more credits.
                  next:
                    $ref: '#/components/schemas/AgentAccessNextStep'
                  docs:
                    type: string
                    description: Human-readable guide URL for Agent Access.
                  limits:
                    type: object
                    required:
                      - session_max_duration_minutes
                    properties:
                      session_max_duration_minutes:
                        type: number
                        description: >-
                          Maximum session duration in minutes for keys issued
                          through Agent Access.
        '400':
          description: >-
            Missing token/answer, expired token, or incomplete identity fields.
            Follow `next`.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/AgentAccessError'
        '401':
          description: Incorrect answer or invalid identity token. Follow `next`.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/AgentAccessError'
        '429':
          description: Too many onboarding attempts from this source.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/AgentAccessError'
        '500':
          description: Failed to create project.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/AgentAccessError'
      security: []
components:
  schemas:
    AgentAccessNextStep:
      type: object
      required:
        - method
        - path
        - description
      properties:
        method:
          type: string
          enum:
            - GET
            - POST
          description: HTTP method for the next call in the Agent Access onboarding flow.
        path:
          type: string
          description: >-
            Path on https://api.anchorbrowser.io for the next call. Prepend the
            method to execute it.
        description:
          type: string
          description: >-
            Plain-language instruction for what to do on the next call and what
            you receive afterward.
    AgentAccessError:
      type: object
      required:
        - error
        - next
        - docs
      properties:
        error:
          type: string
          description: Why the request failed.
        next:
          $ref: '#/components/schemas/AgentAccessNextStep'
        docs:
          type: string
          description: Human-readable guide URL for Agent Access.
          example: https://docs.anchorbrowser.io/quickstart/agent-access

````