POST
/
sessions
/
create
curl --request POST \
  --url https://api.raccoonai.tech/sessions/create \
  --header 'Content-Type: application/json' \
  --header 'raccoon-secret-key: <api-key>' \
  --data '{
  "raccoon_passcode": "<end-user-raccoon-passcode>",
  "url": "https://www.google.com",
  "browser_type": "chromium",
  "settings": {
    "locales": [
      "en-US",
      "fr-FR"
    ],
    "user_agent": "Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/91.0.4472.124 Safari/537.36",
    "viewport": {
      "height": 720,
      "width": 1280
    }
  },
  "advanced": {
    "block_ads": true,
    "proxy": {
      "city": "sanfrancisco",
      "country": "us",
      "state": "ca",
      "zip": 94102
    },
    "solve_captchas": true
  },
  "headless": true,
  "session_timeout": 600
}'
{
  "session_id": "session_12345",
  "websocket_url": "wss://connect.raccoonai.tech/ws/6000?sessionId=session_12345",
  "livestream_url": "https://api.raccoonai.tech/sessions/session_12345/stream?enable_actions=true&theme=dark",
  "status": "running"
}

The following features are currently experimental:

  • Proxies
  • CAPTCHA Solving

If you run into any issues, please report back to us through mail or use support center on the bottom right.

Use the websocket_url field of the response from this endpoint to connect to the browser session using frameworks like playwright.

Connect to browser using websocket url
from playwright.async_api import async_playwright

async with async_playwright() as playwright:
    browser = await playwright.chromium.connect_over_cdp(websocket_url)

Authorizations

raccoon-secret-key
string
header
required

Body

application/json

Response

200
application/json

Successful Response

The response is of type object.