POST
/
browsers
JavaScript
import Kernel from '@onkernel/sdk';

const client = new Kernel({
  apiKey: 'My API Key',
});

const browser = await client.browsers.create();

console.log(browser.session_id);
{
  "cdp_ws_url": "wss://api.onkernel.com/browser/cdp?jwt=eyJ0eXAi...",
  "browser_live_view_url": "https://api.onkernel.com/browser/remote?jwt=eyJ0eXAi...",
  "session_id": "htzv5orfit78e1m2biiifpbv",
  "persistence": {
    "id": "my-awesome-browser-for-user-1234"
  }
}

Authorizations

Authorization
string
header
required

Bearer authentication header of the form Bearer <token>, where <token> is your auth token.

Body

application/json

Response

200
application/json

Successful response

The response is of type object.