Overview
Concrete tool registry exporting 34 browser automation tools and a registration helper for populating agent tool lists.
Description
The allBrowserTools export is a `FunctionTool[]` array containing 34 tools organized into categories: tab management (7), UI operations (8), page content (4), screenshots (3), downloads (2), interventions (4), and skills (6). Each tool is created with the `@aipexstudio/aipex-core` `tool()` function, which wraps a name, description, Zod input schema, and async execute handler. The registerDefaultBrowserTools function iterates this array and calls `registry.register(tool)` for each, populating any registry-like object. Several tools are disabled by default (clipboard, wait, organize_tabs) and noted in comments.
Usage
- Pass to AIPex.create: `AIPex.create({ tools: allBrowserTools, ... })`
- Register with a registry: `registerDefaultBrowserTools(myRegistry)`
- Access specific tools: import individual tools from their respective files (e.g., `captureScreenshotTool` from `./screenshot`)
Code Reference
Source Location
- Repository: AIPex
- File: packages/browser-runtime/src/tools/index.ts
- Lines: L64-132
Signature
export const allBrowserTools: FunctionTool[]
export function registerDefaultBrowserTools<T extends ToolRegistryLike>(
registry: T
): T
interface ToolRegistryLike {
register(tool: (typeof allBrowserTools)[number]): unknown
}
Import
import { allBrowserTools, registerDefaultBrowserTools } from "@aipexstudio/browser-runtime";
I/O Contract
Inputs
| Name |
Type |
Required |
Description
|
| registry |
ToolRegistryLike |
Yes |
Registry with a register() method (for registerDefaultBrowserTools)
|
Outputs
| Name |
Type |
Description
|
| allBrowserTools |
FunctionTool[] |
34 browser tools ready for agent registration
|
Usage Examples
Register with Agent
import { AIPex } from "@aipexstudio/aipex-core";
import { allBrowserTools } from "@aipexstudio/browser-runtime";
const agent = AIPex.create({
instructions: "You are a browser automation assistant.",
model: aisdk(openai("gpt-4o")),
tools: allBrowserTools,
});
Register with Custom Registry
import { registerDefaultBrowserTools } from "@aipexstudio/browser-runtime";
const myRegistry = {
tools: [],
register(tool) { this.tools.push(tool); },
};
registerDefaultBrowserTools(myRegistry);
console.log(myRegistry.tools.length); // 34
Related Pages
Implements Principle
Requires Environment
Page Connections
Double-click a node to navigate. Hold to expand connections.