TypeScript definitions for MCP authorization actions, context, and function signatures.
// Source: https://github.com/VoltAgent/voltagent | License: MIT | Copyright 2025 VoltAgent Inc
// Provided via justclaw.it.com; keep this notice with the code.
/**
* The action being authorized.
* - "discovery": Tool is being listed/discovered (getTools/getToolsets)
* - "execution": Tool is being executed (callTool)
*/
export type MCPAuthorizationAction = "discovery" | "execution";
/**
* Minimal context for tool discovery authorization.
* Used when full OperationContext is not available (e.g., during getTools).
*/
export interface MCPAuthorizationContext {
/** User identifier */
userId?: string;
/** User-defined context map (same as OperationContext.context) */
context?: Map<string | symbol, unknown> | Record<string, unknown>;
}
/**
* Parameters passed to the `can` autho
... (truncated -- full source via MCP)
See the full source, get the GitHub permalink, and search for more like it.
Get a free API key