Skip to main content
Glama

create-tag

Generate new tags within your instance using client ID and tag name to organize and categorize data efficiently in the MCP-N8N server.

Instructions

Create a new tag in your instance.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
clientIdYes
nameYes

Implementation Reference

  • MCP tool handler for 'create-tag'. Validates clientId, retrieves N8nClient instance, calls client.createTag(name), and returns the created tag or error.
    case "create-tag": {
      const { clientId, name } = args as { clientId: string; name: string };
      const client = clients.get(clientId);
      if (!client) {
        return {
          content: [{
            type: "text",
            text: "Client not initialized. Please run init-n8n first.",
          }],
          isError: true
        };
      }
    
      try {
        const tag = await client.createTag(name);
        return {
          content: [{
            type: "text",
            text: `Successfully created tag:\n${JSON.stringify(tag, null, 2)}`,
          }]
        };
      } catch (error) {
        return {
          content: [{
            type: "text",
            text: error instanceof Error ? error.message : "Unknown error occurred",
          }],
          isError: true
        };
      }
    }
  • Tool specification including name, description, and input schema definition for 'create-tag' in the ListTools response.
      name: "create-tag",
      description: "Create a new tag in your instance.",
      inputSchema: {
        type: "object",
        properties: {
          clientId: { type: "string" },
          name: { type: "string" }
        },
        required: ["clientId", "name"]
      }
    },
  • N8nClient method that performs the actual API call to create a tag via POST /tags with the tag name.
    async createTag(name: string): Promise<N8nTag> {
      return this.makeRequest<N8nTag>('/tags', {
        method: 'POST',
        body: JSON.stringify({ name }),
      });
    }
  • Type definition for N8nTag returned by the createTag API call.
    interface N8nTag {
      id: string;
      name: string;
      createdAt?: string;
      updatedAt?: string;
    }
Behavior2/5

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

With no annotations provided, the description carries the full burden of behavioral disclosure. While 'Create' implies a write/mutation operation, the description doesn't address permissions needed, whether the operation is idempotent, what happens on duplicate names, or what the response contains. For a mutation tool with zero annotation coverage, this leaves significant behavioral questions unanswered.

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 extremely concise at just 6 words, with zero wasted language. It's front-loaded with the core action and resource, making it immediately understandable despite its brevity.

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?

For a mutation tool with no annotations, no output schema, and two undocumented parameters, the description is insufficiently complete. It doesn't explain what a 'tag' represents in this system, what the parameters do, what happens after creation, or how this operation fits within the broader context of tag management (alongside get-tag, update-tag, delete-tag).

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

Parameters2/5

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

With 0% schema description coverage and two required parameters (clientId and name), the description provides no information about what these parameters mean, their format, or their purpose. The description doesn't compensate for the complete lack of parameter documentation in the schema, leaving both parameters completely unexplained.

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 action ('Create') and resource ('new tag'), making the purpose immediately understandable. However, it doesn't differentiate this tool from its sibling 'update-tag' or explain what distinguishes tag creation from other creation operations like 'create-project' or 'create-workflow'.

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 (like needing a specific instance context), when not to use it, or how it differs from similar tools like 'update-tag' or other creation operations in the sibling list.

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

Related 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/fellipesaraiva88/n8n-mcp-server'

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