Skip to main content
Glama

code_beautify

Beautify source code by applying proper indentation and formatting. Supports multiple programming languages.

Instructions

Beautify/format source code with proper indentation.

Parameters:
    code — Source code to beautify.
    language — Programming language (default: 'javascript').

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
codeYes
languageNojavascript

Output Schema

TableJSON Schema
NameRequiredDescriptionDefault
resultYes
Behavior2/5

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

With no annotations, the description must disclose behavioral traits. It only says 'beautify/format', but does not specify if the tool mutates input, returns a new string, or requires authentication. It lacks detail on side effects, rate limits, or error conditions. The output schema is not referenced, leaving return value ambiguous.

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 very concise: two sentences with bulleted parameters. No extra words or fluff. Information is front-loaded with the purpose, then parameter details in a structured list. Every sentence earns its keep.

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 an output schema (so return format need not be detailed), the description is adequate for a simple formatting task. However, it lacks mention of output behavior (e.g., returns formatted string), error handling, or size limits. The implicit assumption that it works for multiple languages is not confirmed. Completeness is moderate.

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 description adds meaning beyond the schema by explaining each parameter: 'code — Source code to beautify' and 'language — Programming language (default: javascript)'. However, it does not enumerate supported languages or provide constraints, leaving ambiguity about valid inputs. Since schema coverage is 0%, the description partially compensates but could be more precise.

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 tool's purpose: 'Beautify/format source code with proper indentation.' It uses specific verbs (beautify/format) and resource (source code). It distinguishes from siblings like code_minify_js (minification vs beautification) and code_indent_check (checking vs fixing).

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 vs alternatives (e.g., code_minify_js, sql_format). It does not mention prerequisites, limitations, or scenarios where other tools are more appropriate. Usage context is entirely implied.

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/scotia1973-bot/api-hub'

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