Skip to main content

Documentation Index

Fetch the complete documentation index at: https://docs.driver.dev/llms.txt

Use this file to discover all available pages before exploring further.

Control which nodes serve your browser sessions using node IDs and session types.

Session Types

Specify the type of infrastructure for your session:
TypeDescriptionBest For
consumer_distributedRuns on real consumer devicesMaximum stealth, anti-detection
hostedRuns in our data centersConsistent performance, reliability
const session = await client.browser.session.create({
  type: "hosted",
});

Targeting Specific Nodes

Every session response includes a servedBy field with the node ID. Reuse this to target the same node:
// Create first session
const session1 = await client.browser.session.create();
console.log("Node:", session1.servedBy); // "node-us-east-abc123"

// Stop when done
await client.browser.session.stop({ sessionId: session1.sessionId });

// Later — target the same node
const session2 = await client.browser.session.create({
  nodeId: session1.servedBy,
});

Combining Filters

Use multiple parameters together:
const session = await client.browser.session.create({
  country: "US", // Geographic filter
  type: "hosted", // Infrastructure type
  nodeId: "node-123", // Specific node (overrides country)
});
If you specify a nodeId, that takes precedence over country. If the node is offline or unavailable, the request will fail rather than fall back to another node.

Node Availability

  • Nodes may go offline temporarily
  • Distributed nodes have variable availability
  • Hosted nodes offer high uptime guarantees