create_game
Create a new tabletop game project under a designer on The Game Crafter's print-on-demand platform. Set up game name, designer ID, and optional description to begin manufacturing.
Instructions
Create a new game project under a designer. Requires authentication.
Input Schema
TableJSON Schema
| Name | Required | Description | Default |
|---|---|---|---|
| name | Yes | Name for the new game project (max 255 chars). | |
| designer_id | Yes | The designer ID to create the game under. Get this from the get_my_designers tool. | |
| description | No | Optional description for the game (max 5000 chars). |
Implementation Reference
- src/tools/games.ts:35-55 (handler)The handler function that executes the "create_game" tool logic by calling the client's createGame method.
export function handleCreateGame(client: TgcClient) { return async (args: { name: string; designer_id: string; description?: string; }): Promise<CallToolResult> => { const game = await client.createGame( args.name, args.designer_id, args.description, ); return { content: [ { type: "text", text: `Game "${game.name}" created successfully.\n\n${JSON.stringify(game, null, 2)}`, }, ], }; }; } - src/schemas/tool-inputs.ts:45-56 (schema)Input validation schema for the "create_game" tool.
// Tool 7: create_game — create a new game project export const createGameInput = { name: z.string().trim().min(1).max(255).describe("Name for the new game project (max 255 chars)."), designer_id: safeId.describe( "The designer ID to create the game under. Get this from the get_my_designers tool.", ), description: z .string() .max(5000) .optional() .describe("Optional description for the game (max 5000 chars)."), }; - src/index.ts:107-113 (registration)Tool registration for "create_game" in the main server entry point.
server.registerTool("create_game", { description: "Create a new game project under a designer. Requires authentication.", inputSchema: schemas.createGameInput, annotations: { readOnlyHint: false }, }, withErrorHandling(handleCreateGame(client))); server.registerTool("add_component_to_game", {