Skip to main content
Glama

Attach to JVM Process

intercept_jvm

Intercept HTTP(S) traffic from running Java, Kotlin, or Clojure applications by attaching to their JVM processes for debugging and inspection.

Instructions

Attach to a running JVM process (Java, Kotlin, Clojure, etc.) to intercept all its HTTP(S) traffic. Uses Java agent attachment.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
proxyPortYesProxy port to route traffic through
targetPidYesPID of the JVM process. Use get_interceptor_metadata with id "attach-jvm" to list available JVM processes.

Implementation Reference

  • src/index.ts:297-309 (registration)
    The 'intercept_jvm' tool is registered in src/index.ts, where it takes proxyPort and targetPid as inputs and invokes client.activateInterceptor to perform the actual work.
    server.registerTool(
      'intercept_jvm',
      {
        title: 'Attach to JVM Process',
        description: 'Attach to a running JVM process (Java, Kotlin, Clojure, etc.) to intercept all its HTTP(S) traffic. Uses Java agent attachment.',
        inputSchema: z.object({
          proxyPort: z.number().describe('Proxy port to route traffic through'),
          targetPid: z.string().describe('PID of the JVM process. Use get_interceptor_metadata with id "attach-jvm" to list available JVM processes.'),
        }),
      },
      async ({ proxyPort, targetPid }) =>
        jsonResult(await client.activateInterceptor('attach-jvm', proxyPort, { targetPid }))
    );
Behavior2/5

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

No annotations are provided, so the description carries the full burden of behavioral disclosure. It mentions the action ('intercept all its HTTP(S) traffic') and mechanism ('Java agent attachment'), but lacks details on permissions needed, side effects (e.g., process disruption), rate limits, or output behavior. For a tool that attaches to processes, this is a significant gap in transparency.

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 front-loaded with the core purpose in the first sentence and adds a brief technical detail in the second. Both sentences are essential, with no wasted words, making it highly concise and well-structured for quick understanding.

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 complexity of attaching to a JVM process, no annotations, and no output schema, the description is incomplete. It lacks information on success/failure outcomes, error handling, prerequisites (e.g., agent availability), or security implications. For a tool with potential side effects, this leaves significant gaps in context.

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 schema already documents both parameters (proxyPort and targetPid). The description does not add any parameter-specific details beyond what the schema provides, such as format examples or constraints. Baseline 3 is appropriate when the schema handles parameter documentation adequately.

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 the specific action ('Attach to a running JVM process') and resource ('HTTP(S) traffic'), distinguishing it from siblings like intercept_android_adb or intercept_chrome by specifying JVM-based languages (Java, Kotlin, Clojure). It explicitly mentions the mechanism ('Uses Java agent attachment'), making the purpose unambiguous.

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

Usage Guidelines4/5

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

The description implies usage context by specifying it's for JVM processes and HTTP(S) traffic interception, but does not explicitly state when to use this tool versus alternatives like frida_android_intercept or intercept_docker_container. However, it provides a clear target scope (JVM processes), which offers some guidance without naming exclusions or direct alternatives.

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/fdciabdul/httptoolkit-mcp'

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