Skip to main content
Glama

remove_tests_from_test_plan

Remove specific tests from an existing test plan by providing test issue IDs, streamlining test management and maintaining accurate test coverage.

Instructions

Remove tests from an existing test plan

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
testPlanIssueIdYesThe test plan issue ID (not key)
testIssueIdsYesArray of test issue IDs to remove

Implementation Reference

  • Core handler implementing the tool logic: executes GraphQL mutation to remove specified test issue IDs from a test plan using Xray Cloud API.
    async removeTestsFromTestPlan(testPlanIssueId: string, testIssueIds: string[]): Promise<any> {
      const mutation = `
        mutation RemoveTestsFromTestPlan($issueId: String!, $testIssueIds: [String]!) {
          removeTestsFromTestPlan(issueId: $issueId, testIssueIds: $testIssueIds) {
            removedTests
            warning
          }
        }
      `;
    
      const variables = {
        issueId: testPlanIssueId,
        testIssueIds
      };
    
      const result = await this.graphqlRequest<{ removeTestsFromTestPlan: any }>(mutation, variables);
      return result.removeTestsFromTestPlan;
    }
  • Input schema defining parameters for the tool: testPlanIssueId (string) and testIssueIds (array of strings).
    inputSchema: {
      type: 'object',
      properties: {
        testPlanIssueId: {
          type: 'string',
          description: 'The test plan issue ID (not key)',
        },
        testIssueIds: {
          type: 'array',
          items: { type: 'string' },
          description: 'Array of test issue IDs to remove',
        },
      },
      required: ['testPlanIssueId', 'testIssueIds'],
    },
  • src/index.ts:366-384 (registration)
    Tool registration in the MCP tools list, including name, description, and schema.
    {
      name: 'remove_tests_from_test_plan',
      description: 'Remove tests from an existing test plan',
      inputSchema: {
        type: 'object',
        properties: {
          testPlanIssueId: {
            type: 'string',
            description: 'The test plan issue ID (not key)',
          },
          testIssueIds: {
            type: 'array',
            items: { type: 'string' },
            description: 'Array of test issue IDs to remove',
          },
        },
        required: ['testPlanIssueId', 'testIssueIds'],
      },
    },
  • src/index.ts:780-793 (registration)
    Dispatch handler in the MCP CallToolRequest that invokes the XrayClient method and formats the response.
    case 'remove_tests_from_test_plan': {
      const result = await xrayClient.removeTestsFromTestPlan(
        args.testPlanIssueId as string,
        args.testIssueIds as string[]
      );
      return {
        content: [
          {
            type: 'text',
            text: JSON.stringify(result, null, 2),
          },
        ],
      };
    }
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. It states the tool removes tests from a test plan, implying a destructive mutation, but doesn't address critical aspects like whether this requires specific permissions, if the removal is reversible, what happens to the removed tests (e.g., deletion vs. disassociation), or any rate limits. For a mutation tool with zero annotation coverage, this is a significant gap.

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 directly states the tool's purpose without any unnecessary words. It's appropriately sized and front-loaded, with every word earning its place. No structural issues or redundancy are present.

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 as a destructive mutation operation, the absence of annotations, and no output schema, the description is incomplete. It doesn't address behavioral traits (e.g., permissions, reversibility), output expectations, or error conditions. The agent lacks sufficient context to use this tool safely and effectively beyond basic parameter passing.

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?

The schema description coverage is 100%, with both parameters clearly documented in the input schema. The description doesn't add any semantic information beyond what's already in the schema (e.g., it doesn't clarify format examples, constraints, or relationships between parameters). According to the rules, when schema coverage is high (>80%), the baseline score is 3 even without parameter details in the description.

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 ('Remove tests') and target resource ('from an existing test plan'), providing a specific verb+resource combination. It distinguishes from sibling tools like 'remove_tests_from_test_set' by specifying the target is a test plan rather than a test set. However, it doesn't fully differentiate from other removal operations like 'delete_test_case' beyond the resource type.

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 an existing test plan), exclusions, or compare with similar tools like 'remove_tests_from_test_set' or 'delete_test_case'. The agent must infer usage solely from the tool name and 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

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/c4m3lblue-star/xray-mcp'

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