Skip to main content
Glama

Create a label

labels_create

Create a label in a connected mailbox and answer the id it is applied by. In a Gmail mailbox, and as a folder in one whose provider is imap or in an Outlook mailbox, a / nests it under the label before it, made first where missing. An Outlook mailbox makes a folder where the name holds a / or folder is true, and a category otherwise.

Input Schema

NameRequiredDescriptionDefault
nameYesWhat the label is called.
folderNoIn an Outlook mailbox, true makes a folder rather than a category.
mailboxYesThe mailbox's name or its email address.

Output Schema

NameRequiredDescriptionDefault
idYes
nameYes
typeNo
messagesTotalNo
messagesUnreadNo

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed3 schema fields changed
    • addedInput schema / properties / folder
      Added value: +{
      +  "description": "In an Outlook mailbox, true makes a folder rather than a category.",
      +  "type": "boolean"
      +}
    • addedOutput schema / properties / messagesTotal
      Added value: +{
      +  "type": "number"
      +}
    • addedOutput schema / properties / messagesUnread
      Added value: +{
      +  "type": "number"
      +}
  2. Changed2 schema fields changed
    • changedInput schema / $schema
      Previous value: -"http://json-schema.org/draft-07/schema#"New value: +"https://json-schema.org/draft/2020-12/schema"
    • changedOutput schema / $schema
      Previous value: -"http://json-schema.org/draft-07/schema#"New value: +"https://json-schema.org/draft/2020-12/schema"
  3. Changed2 schema fields changed
    • removedOutput schema / properties / type / anyOf
      Removed value: -[
      -  {
      -    "type": "string"
      -  },
      -  {
      -    "type": "null"
      -  }
      -]
    • addedOutput schema / properties / type / type
      Added value: +[
      +  "string",
      +  "null"
      +]
  4. First observed

TDQS

A4/5.0
Behavior4/5

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

The annotations already establish that this is a non-read-only, non-destructive mutation. The description adds important behavioral context beyond the annotations, especially that a slash nests labels and that missing parent labels are created first, and it distinguishes Outlook folders from categories. It does not cover duplicate-name behavior or failure modes, so it falls short of a 5.

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

Conciseness3/5

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

The first sentence is front-loaded and clear, but the second sentence is grammatically tangled and difficult to parse: 'In a Gmail mailbox, and as a folder in one whose provider is imap or in an Outlook mailbox, a / nests it...' The content is useful, but the structure could be cleaner.

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

Completeness4/5

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

With an output schema and annotations present, the description does not need to explain return values or safety hints. It covers the key mailbox-provider semantics and the parent-label creation side effect, though it omits duplicate handling and error behavior, leaving a small completeness gap.

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

Parameters4/5

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

Schema coverage is 100%, so the baseline is 3. The description adds real meaning beyond the schema by explaining that slash characters create nested labels and that in Outlook a name containing a slash or folder=true creates a folder rather than a category.

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

Purpose5/5

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

The description uses a specific verb and resource: 'Create a label in a connected mailbox.' It also states that the tool returns the label id, and its create semantics clearly distinguish it from sibling tools such as labels_update, labels_delete, and labels_list.

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

Usage Guidelines3/5

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

The description implies that this tool is for creating labels and explains provider-specific behavior, but it does not explicitly say when to use it instead of labels_update or labels_list, nor does it state when not to use it. Usage is inferable but not directly guided.

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

Try in Browser

Glama MCP Gateway

Add one secure layer between your agents and this server.