Skip to main content
Glama

container_stop

Stop and remove the Kali Linux Docker container to halt security testing sessions and free system resources.

Instructions

Stop and remove the Kali Linux Docker container.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault

No arguments

Implementation Reference

  • Tool definition and handler registration for 'container_stop' in the MCP server. It calls docker.stopContainer().
    server.tool(
      "container_stop",
      "Stop and remove the Kali Linux Docker container.",
      {},
      async () => {
        try {
          const message = await docker.stopContainer();
          return { content: [{ type: "text", text: message }] };
        } catch (err) {
          return {
            content: [
              {
                type: "text",
                text: `Failed to stop container: ${err instanceof Error ? err.message : String(err)}`,
              },
            ],
            isError: true,
          };
        }
      }
    );
  • The actual implementation of stopping and removing the Docker container, used by the 'container_stop' tool.
    async stopContainer(): Promise<string> {
      const container = await this.getContainer();
      if (!container) {
        return "No Kali container found.";
      }
    
      const info = await container.inspect();
      if (info.State.Running) {
        await container.stop();
      }
      await container.remove();
      return "Kali container stopped and removed.";
    }
Behavior3/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 indicates the tool performs a destructive action ('Stop and remove'), which implies mutation and potential data loss, but lacks details on permissions needed, whether the action is reversible, or error conditions. It adds some context but is incomplete for a destructive operation.

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 key action ('Stop and remove') and target. There is zero waste—every word contributes directly to understanding the tool's purpose without unnecessary elaboration.

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

Completeness3/5

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

Given the tool has no parameters, no annotations, and no output schema, the description is minimally complete for a simple destructive operation. However, it lacks details on behavioral aspects like what 'remove' entails (e.g., deletion of container data) or expected outcomes, which would be helpful for an AI agent to use it correctly.

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?

The input schema has 0 parameters with 100% coverage, so no parameter documentation is needed. The description doesn't add parameter details, which is appropriate, but it could have mentioned any implicit assumptions (e.g., targeting a specific default container). Since there are no parameters, a baseline of 4 is applied as it adequately handles the empty schema.

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 ('Stop and remove') and the target ('the Kali Linux Docker container'), making the purpose immediately understandable. However, it doesn't explicitly differentiate from sibling tools like 'container_status' or 'container_start', which would require mentioning this is specifically for termination rather than checking status or starting.

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., that a container must be running first), exclusions (e.g., not for other container types), or direct comparisons to siblings like 'container_start' for starting containers. Usage is implied but not explicitly stated.

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/Hannes221/kali-mcp'

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