Skip to main content
Glama
cosmix

JIRA MCP Server

by cosmix

create_issue

Create a new JIRA issue by specifying project key, issue type, summary, description, and additional fields to track work items.

Instructions

Create a new JIRA issue

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
projectKeyYesThe project key where the issue will be created
issueTypeYesThe type of issue to create (e.g., "Bug", "Story", "Task")
summaryYesThe issue summary/title
descriptionNoThe issue description
fieldsNoAdditional fields to set on the issue

Implementation Reference

  • MCP CallToolRequest handler case for 'create_issue': validates input parameters and delegates to JiraApiService.createIssue method, returning the created issue as JSON text content.
    case "create_issue": {
      // Basic validation
      if (
        !args.projectKey ||
        typeof args.projectKey !== "string" ||
        !args.issueType ||
        typeof args.issueType !== "string" ||
        !args.summary ||
        typeof args.summary !== "string"
      ) {
        throw new McpError(
          ErrorCode.InvalidParams,
          "projectKey, issueType, and summary are required",
        );
      }
      const response = await this.jiraApi.createIssue(
        args.projectKey,
        args.issueType,
        args.summary,
        args.description as string | undefined,
        args.fields as Record<string, any> | undefined,
      );
      return {
        content: [
          { type: "text", text: JSON.stringify(response, null, 2) },
        ],
      };
    }
  • Input schema definition for the 'create_issue' tool, specifying required fields (projectKey, issueType, summary) and optional fields (description, fields).
    inputSchema: {
      type: "object",
      properties: {
        projectKey: {
          type: "string",
          description: "The project key where the issue will be created",
        },
        issueType: {
          type: "string",
          description:
            'The type of issue to create (e.g., "Bug", "Story", "Task")',
        },
        summary: {
          type: "string",
          description: "The issue summary/title",
        },
        description: {
          type: "string",
          description: "The issue description",
        },
        fields: {
          type: "object",
          description: "Additional fields to set on the issue",
          additionalProperties: true,
        },
      },
      required: ["projectKey", "issueType", "summary"],
      additionalProperties: false,
    },
  • src/index.ts:131-163 (registration)
    Tool registration in ListTools response: defines name, description, and inputSchema for 'create_issue'.
    {
      name: "create_issue",
      description: "Create a new JIRA issue",
      inputSchema: {
        type: "object",
        properties: {
          projectKey: {
            type: "string",
            description: "The project key where the issue will be created",
          },
          issueType: {
            type: "string",
            description:
              'The type of issue to create (e.g., "Bug", "Story", "Task")',
          },
          summary: {
            type: "string",
            description: "The issue summary/title",
          },
          description: {
            type: "string",
            description: "The issue description",
          },
          fields: {
            type: "object",
            description: "Additional fields to set on the issue",
            additionalProperties: true,
          },
        },
        required: ["projectKey", "issueType", "summary"],
        additionalProperties: false,
      },
    },
  • Core implementation of issue creation: constructs payload with project, summary, issue type, optional description/fields, and performs POST request to JIRA REST API /rest/api/3/issue.
    async createIssue(
      projectKey: string,
      issueType: string,
      summary: string,
      description?: string,
      fields?: Record<string, any>
    ): Promise<{ id: string; key: string }> {
      const payload = {
        fields: {
          project: {
            key: projectKey,
          },
          summary,
          issuetype: {
            name: issueType,
          },
          ...(description && { description }),
          ...fields,
        },
      };
    
      return this.fetchJson<{ id: string; key: string }>("/rest/api/3/issue", {
        method: "POST",
        body: JSON.stringify(payload),
      });
    }

Schema Changelog

Changes observed during successful MCP inspections.

  1. Addedv1.0.0

TDQS

B3.3/5.0
Behavior2/5

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

No annotations are provided, and the description lacks behavioral details beyond the fact that it creates. It does not mention permissions, side effects, return value, or any constraints, leaving the agent underinformed.

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

Conciseness4/5

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

The description is extremely concise, which is generally positive. However, given the tool's complexity (5 parameters, nested objects), it may benefit from slightly more detail without losing 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?

The description is too sparse for a creation tool with no output schema. It fails to mention what the tool returns, any required permissions, or potential side effects, leaving significant gaps for the agent.

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 baseline is 3. The description adds no additional parameter information beyond what the schema already provides, so no increase is warranted.

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 clearly states 'Create a new JIRA issue', specifying a concrete action and resource. It distinguishes itself from sibling tools like update_issue, add_attachment, and search_issues.

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 usage for creating issues but provides no guidance on when not to use it or alternatives. The context of sibling tools is present but not explicitly addressed.

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