Skip to main content
Glama

authenticate

Establish a session with The Game Crafter's print-on-demand platform to access manufacturing tools for tabletop games. Required before using catalog browsing, project creation, artwork upload, and pricing features.

Instructions

Create a TGC session using stored credentials. Must be called before any tool that requires authentication.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault

No arguments

Implementation Reference

  • The handler function that executes the "authenticate" tool logic.
    export function handleAuthenticate(client: TgcClient) {
      return async (): Promise<CallToolResult> => {
        const session = await client.authenticate();
        return {
          content: [
            {
              type: "text",
              text: `Authenticated successfully as user ${session.user_id}. You can now use tools that require authentication.`,
            },
          ],
        };
      };
    }
  • src/index.ts:76-80 (registration)
    The registration of the "authenticate" tool in the MCP server.
    server.registerTool("authenticate", {
      description:
        "Create a TGC session using stored credentials. Must be called before any tool that requires authentication.",
      annotations: { readOnlyHint: false },
    }, withErrorHandling(handleAuthenticate(client)));

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/alex-gon/thegamecrafter-mcp-server'

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