Skip to main content
Dotset CLI API Documentation / tollgate / SessionScope

Type Alias: SessionScope

type SessionScope = "exact" | "tool" | "server" | "pattern";
Defined in: src/tollgate/session/types.ts:38 Scope determines what future tool calls a session grant covers.

Examples

// 'exact' - Only this exact tool with these exact arguments
// User approves: postgres:query with args { sql: "SELECT * FROM users" }
// Matches: postgres:query with args { sql: "SELECT * FROM users" }
// Does NOT match: postgres:query with args { sql: "SELECT * FROM orders" }
// 'tool' - Any call to this tool on this server
// User approves: postgres:query
// Matches: postgres:query with ANY args
// 'server' - Any tool call on this server
// User approves: postgres
// Matches: postgres:query, postgres:execute, postgres:list_tables, etc.
// 'pattern' - Tools matching a glob pattern on this server
// User approves: postgres with pattern "read_*"
// Matches: postgres:read_file, postgres:read_config
// Does NOT match: postgres:write_file