Skip to main content
Glama

pylon_get_issue_body

Retrieve the full body content of an issue, including large email threads, with a configurable maximum length up to 10,000 characters.

Instructions

Get the full body content of an issue. Warning: can be very large for email threads.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
idYesThe issue ID or issue number
max_lengthNoMaximum body length to return (default 2000, max 10000)

Implementation Reference

  • The handler function for pylon_get_issue_body. It calls client.getIssue(id), extracts body_html from the raw response, strips HTML tags, truncates to max_length (default 2000, max 10000), and returns the body text.
    async ({ id, max_length }) => {
    	const result = await client.getIssue(id);
    	const raw = result.data as unknown as Record<string, unknown>;
    	const bodyHtml = raw['body_html'] as string | null | undefined;
    
    	if (!bodyHtml) {
    		return {
    			content: [{ type: 'text', text: 'No body content available.' }],
    		};
    	}
    
    	// Strip HTML and truncate
    	const maxLen = max_length ?? 2000;
    	const text = bodyHtml.replace(/<[^>]*>/g, ' ').replace(/\s+/g, ' ').trim();
    	const truncated =
    		text.length > maxLen ? `${text.slice(0, maxLen - 3)}...` : text;
    
    	return {
    		content: [
    			{
    				type: 'text',
    				text: `Issue #${raw['number']} body (${text.length} chars total, showing ${truncated.length}):\n\n${truncated}`,
    			},
    		],
    	};
    },
  • src/index.ts:642-680 (registration)
    The registration of the pylon_get_issue_body tool via server.tool(), including its description 'Get the full body content of an issue. Warning: can be very large for email threads.' and Zod schema for parameters (id: string, max_length: optional number 100-10000).
    server.tool(
    	'pylon_get_issue_body',
    	'Get the full body content of an issue. Warning: can be very large for email threads.',
    	{
    		id: z.string().describe('The issue ID or issue number'),
    		max_length: z
    			.number()
    			.min(100)
    			.max(10000)
    			.optional()
    			.describe('Maximum body length to return (default 2000, max 10000)'),
    	},
    	async ({ id, max_length }) => {
    		const result = await client.getIssue(id);
    		const raw = result.data as unknown as Record<string, unknown>;
    		const bodyHtml = raw['body_html'] as string | null | undefined;
    
    		if (!bodyHtml) {
    			return {
    				content: [{ type: 'text', text: 'No body content available.' }],
    			};
    		}
    
    		// Strip HTML and truncate
    		const maxLen = max_length ?? 2000;
    		const text = bodyHtml.replace(/<[^>]*>/g, ' ').replace(/\s+/g, ' ').trim();
    		const truncated =
    			text.length > maxLen ? `${text.slice(0, maxLen - 3)}...` : text;
    
    		return {
    			content: [
    				{
    					type: 'text',
    					text: `Issue #${raw['number']} body (${text.length} chars total, showing ${truncated.length}):\n\n${truncated}`,
    				},
    			],
    		};
    	},
    );
  • Input validation schema for pylon_get_issue_body: id is a required string, max_length is an optional number with min=100 and max=10000.
    {
    	id: z.string().describe('The issue ID or issue number'),
    	max_length: z
    		.number()
    		.min(100)
    		.max(10000)
    		.optional()
    		.describe('Maximum body length to return (default 2000, max 10000)'),
    },
  • The PylonClient.getIssue() method called by the handler. Makes a GET request to /issues/{id} and returns the issue data.
    async getIssue(id: string): Promise<SingleResponse<Issue>> {
    	return this.request<SingleResponse<Issue>>('GET', `/issues/${id}`);
    }
Behavior3/5

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

No annotations are provided, so the description must convey behavioral traits. It discloses the potential for large content, but does not mention idempotency, authentication, or read-only nature. The warning adds value but more detail is needed for full 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 extremely concise with two sentences: one for purpose and one for a critical warning. No unnecessary words, and the information is front-loaded.

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?

The description warns about size but does not explain the format of the returned body (e.g., plain text, HTML) or the behavior when max_length is exceeded. Given no output schema, this missing detail reduces completeness. However, the input schema is well-documented.

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% with descriptions for both parameters. The description adds value by warning about large bodies, which reinforces the purpose of the max_length parameter to limit output. This helps agents choose appropriate values.

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 tool retrieves the full body content of an issue, which is specific and distinct from the sibling pylon_get_issue that likely returns metadata. However, it could explicitly differentiate the use case.

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 warning about size provides contextual caution but no explicit guidance on when to use this tool over alternatives like pylon_get_issue or when to avoid it. No criteria for appropriate usage are given.

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/JustinBeckwith/pylon-mcp'

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