Skip to main content
Glama

get_script_public_api

Parse a C# script without Unity to extract its class name, base type, and public methods and fields for API inspection.

Instructions

Parse a C# script and return class name, base type, public methods and fields (no Unity required).

Tool call template

Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.

{
  "id": 1,
  "jsonrpc": "2.0",
  "method": "tools/call",
  "params": {
    "arguments": {
      "script_path": "<script_path>"
    },
    "name": "get_script_public_api"
  }
}

Input Schema

NameRequiredDescriptionDefault
script_pathYese.g. Assets/Scripts/PlayerController.cs

Schema Changelog

Changes observed during successful MCP inspections.

  1. Addedv1.5.2

TDQS

B3.4/5.0
Behavior2/5

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

With no annotations supplied, the description carries the full behavioral burden. It discloses the output shape and the no-Unity constraint, which is genuinely useful, but says nothing about error handling on an invalid or missing path, whether partially parseable scripts return partial results, or whether the call is read-only/side-effect free. For a tool with zero annotation coverage, that leaves real gaps.

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?

A single front-loaded sentence with zero filler; the output contract is stated immediately and the no-Unity caveat is appended compactly. Nothing to cut.

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

Completeness4/5

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

For a one-parameter read tool with no output schema, the description usefully enumerates the returned fields so the agent need not guess the response shape. The remaining omission is failure/partial-parse behavior, a minor gap given the tool's simplicity.

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?

Only one parameter, and the schema already documents script_path at 100% coverage with an inline example ("Assets/Scripts/PlayerController.cs"). The description adds no further meaning such as path format constraints, project-relative vs absolute paths, or behavior on non-C# files. Baseline 3 applies since the schema does the work.

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?

Specific verb ("Parse") plus resource ("a C# script") and an explicit enumeration of the returned data: class name, base type, public methods and fields. An agent knows exactly what it gets back. It does not differentiate itself from siblings like get_accessibility_stack or find_script_references, so it stops short of a 5.

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

Usage Guidelines3/5

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

There is no explicit when-to-use or when-not-to-use guidance and no named alternative. The parenthetical "(no Unity required)" implies the relevant context — this is a static parse usable outside a running editor — but the agent must infer that itself. Usage is implied rather than stated.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

Deploy Server

Other Tools