Works with the AI Agents you already use

    Claude CodeClaude CodeCursorCursorCodex CLICodex CLIMuseMuseDotsDots+21 more

    API Contract Doc Builder

    1

    Turn routes, schemas, and middleware into trusted API references plus a validated OpenAPI, GraphQL, or Postman contract — errors, auth, and examples included.

    Free

    6 usesSecurity scanned
    API Contract Doc Builder

    API Contract Doc Builder

    Example session with this skill installed

    We just shipped the v1 payments API — Express routes live in src/routes/payments, request bodies are validated with class-validator schemas, and auth is scoped API keys via middleware. There is zero documentation and partners keep emailing us integration questions. Please read the route handlers, validation schemas, and error mappings, then produce a developer reference for each endpoint covering parameters, auth scopes, and a full error catalog, plus copyable cURL, JavaScript, and Python examples, and finally a machine-readable OpenAPI 3 document. Mark anything you cannot verify in the code as an assumption instead of guessing.

    • Read your context and instructions
    • Compiled the api contract doc

    Summary

    Drafted the full contract for the payments API from src/routes and the class-validator schemas: 8 endpoints documented, plus a validated OpenAPI 3.1 file. Undocumented behavior (webhook retries, Idempotency-Key reuse windows) is flagged as assumption for your review.

    ArtifactCoverageNeeds review
    Endpoint reference (docs/api/)8/8 routes3 flagged fields
    Error catalog11 codes, 6 status classesrate-limit envelope
    openapi.yamlSchemas, security, examplesbeta endpoints
    Runnable cURL/JS/Python examplesHappy + failure pathsandbox base URL

    Next steps

    • Confirm the 3 assumption-marked fields against handler behavior
    • Point a partner at the Quick Start and paste-test the first cURL example
    • Diff openapi.yaml against a live sandbox request before publishing
    • Label @deprecated routes in the inventory so they render as deprecated

    Connects securely to your tools. The creator never sees your data.

    About this skill

    The problem

    API documentation often drifts from reality, leaving developers to guess request shapes, auth requirements, and error codes. Stale docs or missing contracts slow down integration and increase support tickets for internal and partner-facing APIs.

    What it does

    • Analyzes routes, controllers, and schemas to build precise developer references.
    • Generates machine-readable contracts in OpenAPI, GraphQL SDL, or AsyncAPI formats.
    • Produces copy-pasteable code snippets in Shell, JavaScript, and Python.
    • Maps failure modes and HTTP status codes to specific implementation behaviors.
    • Structures onboarding materials including auth guides, pagination logic, and error catalogs.

    Frameworks & tools

    Supports REST, GraphQL, and event-based architectures. Compatible with OpenAPI 3.x, GraphQL SDL, and Postman Collection formats.

    Why this beats prompting it yourself

    Generic prompts often hallucinate field types or omit critical failure modes. This skill enforces a strict verification workflow that treats documentation as a technical contract, ensuring every example is self-contained and every schema field is explicitly typed and validated.

    Use cases

    • Generating a validated OpenAPI YAML from legacy Express or FastAPI routes.
    • Documenting GraphQL resolvers including field-level auth and complexity caps.
    • Preparing partner-facing integration guides with realistic request-response pairs.
    • Auditing implementation code to identify undocumented fields or missing error handles.

    Known limitations

    Requires access to source code or detailed requirements to avoid assumptions. Does not perform live network testing of endpoints.

    Output quality depends on how much of the implementation is readable in the repo; live traffic is not inspected, so unverifiable runtime behavior is marked as assumptions and examples are validated against the documented schema rather than executed against a running server.

    How to use

    1. 1

      Connect your agent to the Agensi MCP

      Copy the prompt and paste it into Claude, ChatGPT, Cursor or any agent that supports MCP. It sets up the connection for you. Manual setup

    2. 2

      Sign in to Agensi

      Your agent shows a sign-in link. Sign in and click Allow.

    3. 3

      Ask for what you need

      Your agent loads this skill and uses it on your task. It always asks before any payment.

    Reviews

    No reviews yet

    Be one of the first to try it. Every listed skill goes through the trust checks below.

    Security scanned

    Checked by our 8-point scan before listing

    6 uses

    Times used to date

    Free forever

    No account required to browse

    Trust & safety

    Security scan

    Security scan passed 1 month ago

    • Free with an Agensi account

    Requires

    Acme

    Permissions

    Network Access
    Environment Variables
    Read Files
    Write Files

    Allowed Hosts

    api.acme.example

    File Scopes

    src/routes/**
    src/**
    docs/api/**
    openapi.yaml
    *.md

    Reads source routes, schemas, and middleware to extract contracts and writes documentation and OpenAPI artifacts back into the repo; no network access is required.

    Listed1 month ago

    What's inside

    Frequently Asked Questions

    This skill bridges the gap between your source code and your documentation by automatically generating precise OpenAPI, GraphQL, or Postman contracts while ensuring every error code and auth requirement is accurately reflected.

    It is compatible with any AI agent capable of file analysis or code reading, specifically designed to support REST, GraphQL, and event-based architectures.

    The skill requires read access to your route definitions, schemas, and controller logic to ensure the generated documentation is a technical contract rather than a guess.

    You receive the complete API Contract Doc Builder skill, including pre-configured workflows for generating schema-validated contracts, multi-language code snippets, and structured onboarding guides.

    Unlike generic prompts, this skill uses a strict verification workflow that cross-references implementation details to prevent hallucinations in field types and ensures all examples are self-contained and valid.

    The Doc Builder is designed for static analysis of your code and requirements; it does not perform live network requests or active security penetration testing.

    New in APIs & Backend