
Security News
OpenCode User Hit with Hostile Backlash After Reporting Free AI Loophole
An OpenCode user faced harassment after reporting a free AI usage loophole, drawing a bitter backlash in a GitHub thread that has since been deleted.
@weavetab/sdk
Advanced tools
Official Enterprise TypeScript SDK and Developer Toolkit for building plugins, tools, isolated configurations, and visual extensions for Weavetab.
@weavetab/sdk is the official developer SDK for building modular, enterprise-grade plugins that extend the Weavetab Model Context Protocol (MCP) runtime.
With @weavetab/sdk, you can:
defineTool, z). Zero manual JSON schema writing — automatically exported to weavetab.json.onBeforeAction (ad-blocking, auth injection), onAfterAction (PII redaction, DLP), and onDOMMutation (live change streams).~/.weavetab/plugins/<name>/config.json without modifying core settings.~/.weavetab/plugins/<name>/.showThought), update HUD status badges (setHudState), inject custom CSS (injectStyles), and execute scripts.browser_eval, browser_click, browser_navigate).PluginBuilder API: Write clean, enterprise-grade plugin definitions with fluent chaining.@weavetab/sdk shares identical version numbering with @weavetab/mcp:
@weavetab/sdk@2.5.x matches @weavetab/mcp@2.5.x."engines": { "weavetab": "^2.5.1" } in your weavetab.json, install @weavetab/sdk@^2.5.1.Choose from 5 enterprise starter templates:
# Standard versatile plugin (Tools + Storage + HUD)
npx -y @weavetab/sdk init my-custom-plugin
# Visual feedback & UI overlay plugin
npx -y @weavetab/sdk init my-visual-plugin --template visual
# Web scraper & data extraction plugin
npx -y @weavetab/sdk init my-scraper-plugin --template scraper
# Security tool interceptor & hook plugin
npx -y @weavetab/sdk init my-guard-plugin --template override
| Template | Focus Area | Highlights |
|---|---|---|
standard | General purpose | Tool registration, isolated storage, HUD thought bubble |
visual | UI & Visual Feedback | setHudState, showThought, injectStyles |
scraper | Data Extraction | CDP evaluation, DOM extraction, storage.setJSON |
automation | Browser Automations | Multi-step workflows, forms, navigations |
override | Security & Interception | overrideTool("browser_navigate"), beforeToolCall |
my-custom-plugin/
├── src/
│ └── index.ts # Plugin implementation (tools, hooks, visuals)
├── weavetab.json # Security manifest & permissions (auto-synced)
├── package.json # Dependencies & build scripts
├── tsconfig.json # TypeScript configuration
└── README.md # Documentation
defineTool)Plugin authors do not have to hand-craft JSON Schema draft-07 objects. Define tools using pure TypeScript + Zod with full auto-completion and compile-time type inference:
import { defineTool, z } from "@weavetab/sdk";
export const auditTool = defineTool({
name: "audit_page",
description: "Audits target page components and reports issues",
schema: z.object({
selector: z.string().describe("Root CSS selector to inspect"),
maxDepth: z.number().default(5).describe("Maximum DOM depth to traverse"),
strictMode: z.boolean().optional().describe("Fail on minor accessibility warnings"),
}),
// args is inferred as: { selector: string; maxDepth: number; strictMode?: boolean }
handler: async (args, session) => {
return {
content: [{ type: "text", text: `Inspected ${args.selector} up to depth ${args.maxDepth}` }],
};
},
});
PluginBuilder Pattern (Enterprise)import { PluginBuilder, z } from "@weavetab/sdk";
export default new PluginBuilder("weavetab-plugin-analytics")
.version("1.0.0")
.description("Enterprise real-time web analytics and visual HUD plugin")
.defaultConfig({
enableHud: true,
themeColor: "#3b82f6",
sampleRate: 100,
})
.addTool({
name: "record_metric",
description: "Records custom telemetry event in isolated plugin storage",
schema: z.object({
metric: z.string().describe("Metric name"),
value: z.number().describe("Numerical value"),
}),
handler: async (args, session) => {
return { content: [{ type: "text", text: `Recorded ${args.metric}: ${args.value}` }] };
},
})
// Intercept every tool call before it runs
.onBeforeAction(async (tool, args, session) => {
if (tool === "browser_navigate" && args.url?.includes("tracking-ads.com")) {
return { __blocked: true, reason: "Blocked navigation to tracking domain" };
}
})
// Inspect or transform results after execution
.onAfterAction(async (tool, result) => {
return result;
})
// Stream live DOM mutations
.onDOMMutation(async (delta) => {
console.log(`[Analytics] DOM change detected: ${delta.type}`);
})
.onLoad(async (ctx) => {
ctx.logger.info("Analytics plugin active with config:", ctx.config);
})
.build();
definePlugin Patternimport { definePlugin, type PluginContext } from "@weavetab/sdk";
import { auditTool } from "./tools.js";
export default definePlugin({
name: "weavetab-plugin-example",
version: "1.0.0",
defaultConfig: {
enableHud: true,
maxRetries: 3,
themeColor: "#3b82f6",
},
tools: [auditTool],
// Enterprise Middleware Hooks
onBeforeAction: async (tool, args) => {
// Modify args or block unauthorized tool calls
},
onAfterAction: async (tool, result) => {
// Redact sensitive data before returning to agent
return result;
},
onDOMMutation: async (delta) => {
// Process live element mutations
},
async onLoad(ctx: PluginContext) {
ctx.logger.info("Plugin loaded! Config:", ctx.config);
// Dynamic tool registrations also support Zod schemas
ctx.mcp.registerTool({
name: "example_ping",
description: "Health check probe",
handler: async () => ({ content: [{ type: "text", text: "pong" }] }),
});
},
async onUnload(ctx: PluginContext) {
ctx.logger.info("Plugin unloaded.");
},
});
Enterprise plugins can intercept every MCP tool call across the runtime beneath the agent:
onBeforeAction (Ad-Blocking & Security Guards)onBeforeAction: async (tool, args) => {
// Block destructive actions
if (tool === "browser_click" && args.selector?.includes(".delete-all")) {
return { __blocked: true, reason: "Destructive bulk deletion forbidden by security policy" };
}
// Inject corporate auth headers
if (tool === "browser_navigate" && args.url?.startsWith("https://corp.internal/")) {
return {
...args,
headers: { ...args.headers, Authorization: "Bearer token-xyz" },
};
}
}
onAfterAction (DLP & PII Redaction)onAfterAction: async (tool, result) => {
if (tool === "browser_map" || tool === "browser_scrape") {
// Scrub sensitive identifiers from the DOM text returned to LLMs
return JSON.parse(
JSON.stringify(result).replace(/\b\d{3}-\d{2}-\d{4}\b/g, "[SSN REDACTED]")
);
}
return result;
}
onDOMMutation (Real-Time DOM Diff Stream)onDOMMutation: async (delta) => {
if (delta.significantChange) {
console.log(`DOM mutated on ${delta.url}: ${delta.added?.length || 0} elements added.`);
}
}
Unlike legacy tools that pollute a single global file, Weavetab gives each plugin its own isolated sandbox directory:
~/.weavetab/plugins/<plugin-name>/
├── config.json <-- User editable configuration
├── storage.json <-- Sandboxed key-value store
└── data/ <-- Custom assets / cache files
ctx.storage)// Key-Value Store (~/.weavetab/plugins/<plugin-name>/storage.json)
await ctx.storage.set("token", "secret-xyz");
const token = await ctx.storage.get<string>("token");
await ctx.storage.delete("token");
// Structured JSON files (~/.weavetab/plugins/<plugin-name>/data/report.json)
await ctx.storage.setJSON("data/report.json", { items: [1, 2, 3] });
const report = await ctx.storage.getJSON("data/report.json");
// Sandbox path resolver with path-traversal protection
const filePath = ctx.storage.getPath("cache.db");
const files = await ctx.storage.list("data");
ctx.extension)// 1. Show an animated floating thought bubble
await ctx.extension.showThought(
session,
"✨ Automation step complete!",
{ durationMs: 3500 }
);
// 2. Update HUD badge and status
await ctx.extension.setHudState(session, {
action: "Extracting Tables",
badge: "Running",
badgeColor: "#10b981",
});
// 3. Inject custom CSS stylesheets into the DOM
await ctx.extension.injectStyles(
session,
`
.weavetab-highlight {
outline: 2px solid #3b82f6 !important;
background: rgba(59, 130, 246, 0.1) !important;
}
`
);
// 4. Temporarily hide HUD for clean screenshots or PDF prints
await ctx.extension.hideOverlay(session);
// ... take screenshot ...
await ctx.extension.restoreOverlay(session);
ctx.mcp.overrideTool("browser_eval", async (args, session, config, originalHandler) => {
console.log("Auditing script before evaluation:", args.code);
// Execute original built-in handler if desired
const res = originalHandler ? await originalHandler(args, session, config) : null;
return {
...res,
auditedByPlugin: true,
};
});
The @weavetab/sdk exposes the weavetab, weavetab-sdk, and weavetab-plugin binaries:
| Command | Description |
|---|---|
weavetab init [name] [--template <type>] | Scaffolds a new TypeScript plugin (5 templates: standard, visual, scraper, automation, override) |
weavetab templates | Lists all 5 available plugin templates |
weavetab build | Compiles TypeScript and synchronizes weavetab.json |
weavetab manifest / schema | Auto-generates weavetab.json manifest from Zod tool definitions & middleware hooks |
weavetab dev | Starts live TypeScript watch mode (tsc --watch) |
weavetab validate [--offline] | Audits and validates weavetab.json schema and permissions (--offline skips the remote schema check) |
weavetab doctor | Runs complete developer environment diagnostics and health checks |
weavetab publish [--dry-run] | npm publish + sync to the weavetab.dev registry |
weavetab version | Displays the current SDK version |
Both
@weavetab/mcpand@weavetab/sdkship aweavetabbinary. In docs, bareweavetab <sdk-cmd>means the SDK one — run it vianpx @weavetab/sdk <cmd>(or the localnpm runscript) to remove ambiguity.
npm run build
npx @weavetab/sdk validate
npx @weavetab/sdk doctor
npx @weavetab/sdk publish
# preview first:
npx @weavetab/sdk publish --dry-run
weavetab plugin add your-published-package-name
MIT © fy2ne
FAQs
Official TypeScript SDK for developing Weavetab plugins and tools.
The npm package @weavetab/sdk receives a total of 3 weekly downloads. As such, @weavetab/sdk popularity was classified as not popular.
We found that @weavetab/sdk demonstrated a healthy version release cadence and project activity because the last version was released less than a year ago. It has 1 open source maintainer collaborating on the project.

Security News
An OpenCode user faced harassment after reporting a free AI usage loophole, drawing a bitter backlash in a GitHub thread that has since been deleted.

Threat Research
/Security News
319 browser extensions installed by 13.4 million users hijack searches, capture queries, and collect referral payments from Yahoo and Bing.

Threat Research
Malicious Firefox extensions mimic Phantom, Jupiter, and Bitget wallets to steal recovery phrases and private keys, with one fetching its payload remotely.