Skip to main content
Glama

get_package_readme

Fetch the README of a Swift package from GitHub to understand its functionality, usage, and documentation before integration.

Instructions

Fetch the README of a Swift package from GitHub.

This is a QUERY tool — read-only, safe to call multiple times.

Use this after search_swift_packages to get details about a specific package. The owner and repo values come from search results (e.g. "apple" and "swift-nio").

Args: owner: GitHub repository owner (user or org). Example: "Alamofire". repo: GitHub repository name. Example: "Alamofire". max_length: Maximum characters to return (default 4000). Set to 0 for full content. Larger values use more tokens.

Returns the README content as markdown. If the README is longer than max_length, it is truncated with a note about the full length.

After reading the README, you can suggest the package to the user with its Swift Package Index URL: https://swiftpackageindex.com/{owner}/{repo}

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
ownerYes
repoYes
max_lengthNo

Output Schema

TableJSON Schema
NameRequiredDescriptionDefault
resultYes
Behavior4/5

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

With no annotations provided, the description carries full behavioral disclosure burden. It successfully states 'read-only, safe to call multiple times,' output format ('markdown'), truncation behavior ('truncated with a note'), and cost implications ('Larger values use more tokens'). Missing only error handling details (e.g., 404 behavior) for a perfect score.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness4/5

Is the description appropriately sized, front-loaded, and free of redundancy?

The description is front-loaded with the core purpose, followed by safety notes, usage guidelines, Args section, and return value details. While comprehensive, the final sentence suggesting post-call actions ('After reading the README, you can suggest...') slightly exceeds strict tool description scope, though it provides workflow context.

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

Completeness5/5

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

For a simple read operation with 3 parameters and an output schema, the description is complete. It explains the input parameters, output behavior (markdown, truncation), workflow relationship to siblings, and even post-call URL construction, leaving no significant gaps for agent operation.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters5/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Schema description coverage is 0%, requiring the description to compensate fully. It provides an 'Args' section documenting all three parameters: owner/repo include examples ('Alamofire'), and max_length explains the default (4000), special case (0 for full), and cost implications—substantially exceeding baseline requirements.

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 opens with 'Fetch the README of a Swift package from GitHub,' providing a specific verb (Fetch), resource (README), and scope (Swift package from GitHub). It distinguishes itself from sibling search_swift_packages by explicitly stating 'Use this after search_swift_packages,' clarifying this is for detail retrieval, not discovery.

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

Usage Guidelines5/5

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

Explicitly states when to use the tool: 'Use this after search_swift_packages to get details about a specific package.' It also clarifies the parameter workflow: 'The owner and repo values come from search results,' directly referencing the sibling tool's output and establishing a clear sequential relationship between the tools.

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/detailobsessed/spm-search'

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