Skip to main content
Glama
context.ts783 B
import type { ServerContext } from "../types"; import { SKILLS, type Skill } from "../skills"; /** * Create a test context with default values for testing tools */ export function createTestContext( overrides: Partial<ServerContext> = {}, ): ServerContext { // Default to all skills for testing const allSkills = Object.keys(SKILLS) as Skill[]; return { accessToken: "test-access-token", constraints: {}, grantedSkills: new Set<Skill>(allSkills), ...overrides, }; } /** * Create a test context with specific constraints */ export function createTestContextWithConstraints( constraints: ServerContext["constraints"], overrides: Partial<ServerContext> = {}, ): ServerContext { return createTestContext({ constraints, ...overrides, }); }

Latest Blog Posts

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/getsentry/sentry-mcp'

If you have feedback or need assistance with the MCP directory API, please join our Discord server