Skip to main content
POST
Add custom WebMCP tools

Authorizations

Authorization
string
header
required

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

Path Parameters

id_or_name
string
required

Browser session ID or name

Body

application/json

Source is limited to 8000000 UTF-8 bytes; the raw JSON body is limited to 8000000 bytes plus 4 KiB before decoding.

namespace
string
required
Pattern: ^[A-Za-z0-9_.-]{1,128}$
source
string
required

JavaScript expression that evaluates to a non-empty array of custom tool definitions. Limited to 8,000,000 bytes when UTF-8 encoded, so multi-byte characters reduce the allowed character count.

Maximum string length: 8000000
force_overwrite_namespace
boolean
default:false

Atomically replace all existing tools in this namespace with this batch when true.

Response

Custom tools added. Contains only the newly added tools.

tools
object[]
required