---
title: "Round-robin command"
method: POST
path: "/pool/command"
---

# Round-robin command

`POST /pool/command`

## Request

- Base URL: `https://oyabrowser.com`
- URL: `https://oyabrowser.com/pool/command`
- Auth: HTTP bearer

Send a command to the next browser in the pool via round-robin. Response includes _browser field showing which browser handled it.

## Request body

- object
  - `action` string, required: Command action (navigate, analyze, click, type, etc.)
  - `params` object: Action parameters

## Response `200`

Command result

- object
  - `ok` boolean: Whether the command succeeded
  - `code` string: For ok:false, a stable reason: command_failed for a refusal the page answered, or one named per action.
  - `data` object: Action-specific result data
    - `url` string
    - `title` string
    - `screenshot` string: Base64 PNG data URL (for screenshot action)
    - `format` 'markdown' | 'toon' | 'jsonl': The format page is written in (for analyze action)
    - `page` string: The page, written in format (for analyze action)
    - `markdown` string: Page content as markdown, when format is markdown (for analyze action)
    - `blocks` object[]: The page as data: one block per heading, paragraph, list item, table row, image and element, in reading order (for analyze action)
    - `elements` object[]: Interactive elements (for analyze/read_page actions)
      - `id` integer
      - `type` string
      - `text` string
      - `href` string
      - `visible` boolean
    - `tabs` object[]: Open tabs (for list_tabs action)
      - `id` integer
      - `title` string
      - `url` string
      - `active` boolean
    - `tab_id` integer: New tab ID (for open_tab action)
    - `selector` string
    - `direction` string
    - `amount` number
    - `key` string
    - `found` boolean
    - `closed` boolean
    - `needs_capture` boolean
    - `scroll` object
      - `top` number
      - `height` number
      - `scrollHeight` number
    - `viewport` object
      - `width` number
      - `height` number
    - `truncated` boolean
  - `error` string, nullable: Error message if ok is false
  - `_browser` string: Browser ID that handled the command

## Other responses

- `503`: No browsers available in pool

---

[API](https://skmtc.dev/oyabrowser/apis/oya-browser-api.md) · [All operations](https://skmtc.dev/oyabrowser/apis/oya-browser-api/llms.txt) · [OpenAPI document](https://skmtc.dev/oyabrowser/apis/oya-browser-api/revisions/748c4b34f8e4?raw)
