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

# Start a Chromium session



## OpenAPI

````yaml /openapi.json post /browsers
openapi: 3.1.0
info:
  title: Styne sandbox API
  version: 0.1.0
  description: >-
    Isolated Linux sandboxes for AI agents: create from a template, run
    commands, files, fork, snapshots, pause and resume. The wire contract is the
    E2B API, so an unmodified E2B SDK works.
servers:
  - url: https://api.styne.ai
security:
  - bearerAuth: []
tags:
  - name: Sandboxes
    externalDocs:
      url: https://docs.styne.ai/quickstart
  - name: Templates
    externalDocs:
      url: https://docs.styne.ai/guide-templates
  - name: Run commands
    externalDocs:
      url: https://docs.styne.ai/exec
  - name: Files
    externalDocs:
      url: https://docs.styne.ai/files
  - name: Fork
    externalDocs:
      url: https://docs.styne.ai/fork
  - name: Snapshots
    externalDocs:
      url: https://docs.styne.ai/snapshots
  - name: Volumes
    externalDocs:
      url: https://docs.styne.ai/volumes
  - name: Logs and metrics
    externalDocs:
      url: https://docs.styne.ai/observability
  - name: Timeouts, pause and resume
    externalDocs:
      url: https://docs.styne.ai/pause-tiers
  - name: Plans and billing
    externalDocs:
      url: https://docs.styne.ai/billing
  - name: Agent sign-up
    externalDocs:
      url: https://docs.styne.ai/agent-signup
  - name: Browsers
    externalDocs:
      url: https://docs.styne.ai/browsers
  - name: Browser profiles
    externalDocs:
      url: https://docs.styne.ai/profiles
  - name: Login vault
    externalDocs:
      url: https://docs.styne.ai/vault
  - name: Ports and preview URLs
    externalDocs:
      url: https://docs.styne.ai/ports
  - name: SSH and port forwarding
    externalDocs:
      url: https://docs.styne.ai/ssh
  - name: CI runners
    externalDocs:
      url: https://docs.styne.ai/ci
  - name: Run a coding agent in a sandbox
    externalDocs:
      url: https://docs.styne.ai/agents
  - name: State store
    externalDocs:
      url: https://docs.styne.ai/state
  - name: Calls between sandboxes
    externalDocs:
      url: https://docs.styne.ai/calls
  - name: Wake triggers and schedules
    externalDocs:
      url: https://docs.styne.ai/wake-triggers
  - name: Checkpoints and rewind
    externalDocs:
      url: https://docs.styne.ai/checkpoints
  - name: Container images
    externalDocs:
      url: https://docs.styne.ai/images
paths:
  /browsers:
    post:
      tags:
        - Browsers
      summary: Start a Chromium session
      operationId: browsers.create
      requestBody:
        required: true
        content:
          application/json:
            schema:
              type: object
              description: Start a browser session. Every field is optional.
              properties:
                region:
                  type: string
                  description: >-
                    Region to start in: ash (default). ams is accepted and
                    served in ash for now; aliases eu, us-east.
                timeout:
                  type: integer
                  description: Seconds the session lives.
                idle_timeout_seconds:
                  type: integer
                  description: >-
                    Seconds without a connected CDP client before the session
                    sleeps; 0 never sleeps on its own.
                secure:
                  type: boolean
                  description: >-
                    Refused with a 422: a browser session is reached only with
                    the signed token in its cdp_url.
                metadata:
                  type: object
                  description: >-
                    Your own keys and JSON values (also accepted as
                    user_metadata), kept with the session and answered on
                    create, GET /browsers/{id} and GET /browsers: at most 50
                    keys of 1 to 64 letters, digits, _ - . :, each value at most
                    512 bytes as JSON.
                unblock:
                  type: string
                  description: >-
                    What happens on a block or captcha page: off, auto (default)
                    or always.
                captcha:
                  type: string
                  description: >-
                    What the session does with a CAPTCHA: off, click (default:
                    the widget's checkbox is clicked) or solve (a challenge the
                    click does not pass is solved, metered per solve, at most 10
                    per session).
                egress:
                  type: string
                  description: >-
                    Where the session's traffic leaves from, from its first
                    request: direct (default), residential or mullvad.
                    Residential traffic is metered per GB; static and image
                    CDNs, ad hosts and the browser's own background fetches
                    leave directly.
                country:
                  type: string
                  description: >-
                    Two-letter country of the residential or mullvad address,
                    for example it. Needs egress residential or mullvad.
                proxy:
                  description: >-
                    Refused with a 422 that names egress and country, which pick
                    where the session's traffic leaves.
                timezone:
                  type: string
                  description: >-
                    IANA timezone the session reports, for example
                    Europe/Berlin.
                locale:
                  type: string
                  description: BCP 47 language tag, for example de-DE.
                profile:
                  type: string
                  description: >-
                    Start the saved browser of this profile, signed in as it was
                    left.
                fork:
                  type: boolean
                  description: 'With profile: an unbound copy for runs in parallel.'
                persist:
                  type: boolean
                  description: >-
                    With profile: true (the default without fork) saves the
                    browser into the profile on the server whenever the session
                    ends (a delete, its timeout, a stop of its machine); false
                    writes the profile only on POST /profiles/{id}/save. true
                    without profile or with fork is a 422.
                viewport:
                  type: object
                  properties:
                    width:
                      type: integer
                    height:
                      type: integer
                  required:
                    - width
                    - height
                  description: >-
                    Page size in CSS pixels (window.innerWidth x innerHeight),
                    320x240 to 3840x2160, set before the start answers; pages
                    opened later get it too. Default 1280x633.
                recording:
                  type: boolean
                  description: >-
                    false: the edge keeps no recording of the session (console,
                    network, trace and replay answer empty). Default true.
                downloads:
                  type: boolean
                  description: >-
                    true: the browser saves every download into
                    /home/browser/Downloads for the whole session; read the
                    files with GET /sandboxes/{id}/files. Default false.
                stealth:
                  type: boolean
                  description: >-
                    false: unblock and captcha default to off (a value you name
                    still wins). true or absent keeps the defaults.
                extensions:
                  type: array
                  description: >-
                    Ids of uploaded extensions (POST /extensions) loaded into
                    the browser before the start answers, at most 10; an id the
                    account does not have is a 422 that names it.
      responses:
        2XX:
          description: Success. The answer is described on https://docs.styne.ai/browsers.
        default:
          description: An error.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Error'
      externalDocs:
        description: Browsers
        url: https://docs.styne.ai/browsers
components:
  schemas:
    Error:
      type: object
      description: >-
        Every error answer has this shape; the codes are listed on the errors
        page.
      properties:
        code:
          type: integer
          description: The HTTP status.
        error_code:
          type: string
          description: A stable machine-readable code, for example free_tier_limit.
        message:
          type: string
          description: What happened and what to do, in plain words.
        origin:
          type: string
          description: >-
            Where the fault came from, for example client, customer_limit or
            infrastructure.
        request_id:
          type: string
          description: Quote it to support; the same value is in the x-request-id header.
      required:
        - code
        - message
  securitySchemes:
    bearerAuth:
      type: http
      scheme: bearer
      description: 'Your Styne API key: Authorization: Bearer $STYNE_API_KEY.'

````

This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.