Skip to Content

whatsapp-mcp


whatsapp-mcp / tools/_registry / ToolContext

Interface: ToolContext

Defined in: src/tools/_registry.ts:30 

The opaque context passed to every tool handler.

Remarks

Phase 4 will populate auth from the API-key middleware (stdio mode synthesises a clientId = LOCAL_OWNER_CLIENT_ID, scopes = ['*'] value). Tools must treat auth as the ground truth for tenancy: never trust clientId from tool input.

Properties

auth

readonly auth: | { apiKeyId: string | null; clientId: string; dailyMsgLimit: number; rpmLimit: number; scopes: readonly string[]; } | null;

Defined in: src/tools/_registry.ts:37 

Populated by the auth middleware in Phase 4. null in Phase 1 because the skeleton has no auth — only the local owner runs it.


requestId

readonly requestId: string;

Defined in: src/tools/_registry.ts:31 


transport

readonly transport: "http" | "stdio";

Defined in: src/tools/_registry.ts:32