create_checkbox_node
Add a checkbox node to Tana workspaces to track tasks or mark items as complete. Specify name, checked status, description, and supertags for organization.
Input Schema
TableJSON Schema
| Name | Required | Description | Default |
|---|---|---|---|
| targetNodeId | No | ||
| name | Yes | ||
| checked | Yes | ||
| description | No | ||
| supertags | No |
Implementation Reference
- src/server/tana-mcp-server.ts:258-299 (handler)Complete registration and handler implementation for the 'create_checkbox_node' MCP tool. Includes inline Zod input schema validation and the async executor that builds a TanaBooleanNode and invokes the TanaClient to create the node.this.server.tool( 'create_checkbox_node', { targetNodeId: z.string().optional(), name: z.string(), checked: z.boolean(), description: z.string().optional(), supertags: z.array(SupertagSchema).optional() }, async ({ targetNodeId, name, checked, description, supertags }) => { try { const node: TanaBooleanNode = { dataType: 'boolean', name, value: checked, description, supertags }; const result = await this.tanaClient.createNode(targetNodeId, node); return { content: [ { type: 'text', text: JSON.stringify(result, null, 2) } ], isError: false }; } catch (error) { return { content: [ { type: 'text', text: `Error creating checkbox node: ${error instanceof Error ? error.message : String(error)}` } ], isError: true }; } }
- src/types/tana-api.ts:40-44 (schema)TypeScript interface defining the TanaBooleanNode structure used by the create_checkbox_node handler, specifying dataType 'boolean', required name and value (checked state), extending base node properties.export interface TanaBooleanNode extends TanaBaseNode { dataType: 'boolean'; name: string; value: boolean; }
- src/types/tana-api.ts:14-18 (schema)Base interface for Tana nodes, providing optional common properties (name, description, supertags, children) extended by TanaBooleanNode.export interface TanaBaseNode { name?: string; description?: string; supertags?: TanaSupertag[]; children?: TanaNode[];
- src/types/tana-api.ts:9-12 (schema)Type definition for TanaSupertag used in node supertags, including id and optional fields.export interface TanaSupertag { id: string; fields?: Record<string, string>; }