Skip to main content
Glama
disnet
by disnet

create_note_type

Define custom note types with structured metadata schemas and agent instructions for organized AI-assisted note-taking in Flint Note.

Instructions

Create a new note type with description, agent instructions, and metadata schema

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
type_nameYesName of the note type (filesystem-safe)
descriptionYesDescription of the note type purpose and usage
agent_instructionsNoOptional custom agent instructions for this note type
metadata_schemaNoOptional metadata schema definition for this note type
vault_idNoOptional vault ID to operate on. If not provided, uses the current active vault.

Implementation Reference

  • The primary handler function for the 'create_note_type' MCP tool. Validates input arguments using validateToolArgs('create_note_type', args) and delegates to noteTypeManager.createNoteType to perform the actual creation.
    handleCreateNoteType = async (args: CreateNoteTypeArgs) => {
      // Validate arguments
      validateToolArgs('create_note_type', args);
    
      const { noteTypeManager } = await this.resolveVaultContext(args.vault_id);
    
      await noteTypeManager.createNoteType(
        args.type_name,
        args.description,
        args.agent_instructions,
        args.metadata_schema
      );
      return {
        content: [
          {
            type: 'text',
            text: JSON.stringify(
              {
                success: true,
                message: `Created note type '${args.type_name}' successfully`,
                type_name: args.type_name
              },
              null,
              2
            )
          }
        ]
      };
    };
  • Registration of the tool handler in the MCP server's CallToolRequestSchema request handler switch statement.
    case 'create_note_type':
      return await this.noteTypeHandlers.handleCreateNoteType(
        args as unknown as CreateNoteTypeArgs
      );
  • MCP tool schema definition including inputSchema, properties, and required fields for create_note_type.
    name: 'create_note_type',
    description:
      'Create a new note type with description, agent instructions, and metadata schema',
    inputSchema: {
      type: 'object',
      properties: {
        type_name: {
          type: 'string',
          description: 'Name of the note type (filesystem-safe)'
        },
        description: {
          type: 'string',
          description: 'Description of the note type purpose and usage'
        },
        agent_instructions: {
          type: 'array',
          items: {
            type: 'string'
          },
          description: 'Optional custom agent instructions for this note type'
        },
        metadata_schema: {
          type: 'object',
          properties: {
            fields: {
              type: 'array',
              items: {
                type: 'object',
                properties: {
                  name: {
                    type: 'string',
                    description: 'Name of the metadata field'
                  },
                  type: {
                    type: 'string',
                    enum: ['string', 'number', 'boolean', 'date', 'array', 'select'],
                    description: 'Type of the metadata field'
                  },
                  description: {
                    type: 'string',
                    description: 'Optional description of the field'
                  },
                  required: {
                    type: 'boolean',
                    description: 'Whether this field is required'
                  },
                  constraints: {
                    type: 'object',
                    description: 'Optional field constraints (min, max, options, etc.)'
                  },
                  default: {
                    description: 'Optional default value for the field'
                  }
                },
                required: ['name', 'type']
              }
            },
            version: {
              type: 'string',
              description: 'Optional schema version'
            }
          },
          required: ['fields'],
          description: 'Optional metadata schema definition for this note type'
        },
        vault_id: {
          type: 'string',
          description:
            'Optional vault ID to operate on. If not provided, uses the current active vault.'
        }
      },
      required: ['type_name', 'description']
    }
  • src/server.ts:314-396 (registration)
    Tool metadata and schema registration in the ListToolsRequestSchema handler, which is served to MCP clients.
    {
      name: 'create_note_type',
      description:
        'Create a new note type with description, agent instructions, and metadata schema',
      inputSchema: {
        type: 'object',
        properties: {
          type_name: {
            type: 'string',
            description: 'Name of the note type (filesystem-safe)'
          },
          description: {
            type: 'string',
            description: 'Description of the note type purpose and usage'
          },
          agent_instructions: {
            type: 'array',
            items: {
              type: 'string'
            },
            description: 'Optional custom agent instructions for this note type'
          },
          metadata_schema: {
            type: 'object',
            properties: {
              fields: {
                type: 'array',
                items: {
                  type: 'object',
                  properties: {
                    name: {
                      type: 'string',
                      description: 'Name of the metadata field'
                    },
                    type: {
                      type: 'string',
                      enum: [
                        'string',
                        'number',
                        'boolean',
                        'date',
                        'array',
                        'select'
                      ],
                      description: 'Type of the metadata field'
                    },
                    description: {
                      type: 'string',
                      description: 'Optional description of the field'
                    },
                    required: {
                      type: 'boolean',
                      description: 'Whether this field is required'
                    },
                    constraints: {
                      type: 'object',
                      description:
                        'Optional field constraints (min, max, options, etc.)'
                    },
                    default: {
                      description: 'Optional default value for the field'
                    }
                  },
                  required: ['name', 'type']
                }
              },
              version: {
                type: 'string',
                description: 'Optional schema version'
              }
            },
            required: ['fields'],
            description: 'Optional metadata schema definition for this note type'
          },
          vault_id: {
            type: 'string',
            description:
              'Optional vault ID to operate on. If not provided, uses the current active vault.'
          }
        },
        required: ['type_name', 'description']
      }
    },
  • TypeScript interface defining the expected arguments for the create_note_type tool.
    export interface CreateNoteTypeArgs {
      type_name: string;
      description: string;
      agent_instructions?: string[];
      metadata_schema?: MetadataSchema;
      vault_id?: string;
    }
Behavior2/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

No annotations are provided, so the description carries full burden for behavioral disclosure. It states it 'creates' a new note type, implying a write/mutation operation, but doesn't disclose permissions required, whether the operation is idempotent, what happens on conflicts (e.g., duplicate type_name), or the response format. For a creation tool with zero annotation coverage, this is a significant gap in transparency.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness5/5

Is the description appropriately sized, front-loaded, and free of redundancy?

The description is a single, efficient sentence that front-loads the core action ('Create a new note type') and lists key components. Every word earns its place with zero waste or redundancy, making it easy to parse quickly.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness2/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

Given the tool's complexity (creation operation with nested objects, 5 parameters) and lack of both annotations and output schema, the description is incomplete. It doesn't cover behavioral aspects like permissions, idempotency, or response format, nor does it provide usage guidance. For a tool that creates structured data types, more context is needed for safe and effective use.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters3/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Schema description coverage is 100%, so the schema already documents all 5 parameters thoroughly. The description mentions 'description, agent instructions, and metadata schema', which aligns with parameters but adds no additional meaning beyond what the schema provides (e.g., no examples, format details, or constraints). Baseline 3 is appropriate when schema does the heavy lifting.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose4/5

Does the description clearly state what the tool does and how it differs from similar tools?

The description clearly states the verb 'Create' and resource 'note type', specifying it creates a new note type with description, agent instructions, and metadata schema. It distinguishes from siblings like 'create_note' (creates notes, not note types) and 'update_note_type' (updates existing note types). However, it doesn't explicitly differentiate from all siblings like 'list_note_types' or 'delete_note_type' in the description text itself.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines2/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

The description provides no guidance on when to use this tool versus alternatives. It doesn't mention prerequisites (e.g., needing a vault), when not to use it (e.g., for updating existing note types), or direct alternatives like 'update_note_type' for modifications. The agent must infer usage from the tool name and sibling list alone.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

Install Server

Other Tools

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/disnet/flint-note'

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