Install
openclaw skills install @sjungwon03/api-to-typemcpUse when a user wants to turn an API URL, OpenAPI/Swagger file or link, Swagger UI, or Markdown/HTML API documentation into a standalone TypeMCP MCP project through the type-mcp-api-cli.
openclaw skills install @sjungwon03/api-to-typemcpThis skill orchestrates the independently versioned packages/type-mcp-api-cli package in this workspace (or a future trusted npm release of that same package). It does not parse specifications, extract endpoints, create TypeScript templates, or substitute its own generator. The CLI is the deterministic engine; this skill is the approval, safety, verification, and publication layer.
The target is a normal standalone TypeScript MCP repository whose runtime dependency is npm type-mcp.
Use this skill when the user provides or asks to use:
Do not use it for a bare base URL with no supplied API documentation. Do not use it to guess endpoints, execute mutating calls by default, or publish a repository without final confirmation.
Collect or infer only what is needed for the requested stage:
| Stage | Required inputs |
|---|---|
| Inspect/manifest | API source URL/file and optionally desired CLI version/path |
| Generate | An approved manifest plus an empty local output directory |
| Publish | Confirmed GitHub owner/org, repository name, visibility, and source branch |
For Markdown/HTML documents, manifest approval is mandatory. Do not proceed from candidate manifest to generation based on an implied or stale approval.
docs/guides/cli-compatibility.md. Until that policy enables a release, stop and report that no CLI is supported.Completion criterion: the selected CLI provenance (when a release is enabled) and sanitized source descriptor are recorded without any secret value; otherwise the workflow stops with the documented no-supported-CLI outcome.
manifestDigest, and a valid approval requirement/challenge.Completion criterion: there is one schema-valid manifest whose JCS-recomputed canonical digest, approval challenge requirement, CLI version, and schema/protocol versions are known.
manifestDigest and explicit challengeId, then request user confirmation.approve in the isolated state directory. Retain the CLI-issued receipt separately; never edit the manifest to simulate approval.generate; require successful MAC/challenge/expiry/digest/version/protocol verification. A receipt is single-use.GET/HEAD/OPTIONS as read; POST/PUT/PATCH/DELETE as protected-write; and unknown methods as deny. A parser may not change that mapping.approved-override manifest edit; then recompute digest and obtain a new receipt if document-derived. Never override unknown methods from deny.Completion criterion: every operation to generate is explicitly approved and write behavior is policy-gated.
package.json declares npm type-mcp, not a path/file/git copy of its source.Completion criterion: the CLI reports generation metadata and all generated paths are under the approved output directory.
Run generated-project checks only through the contained-verification policy in docs/guides/security-and-publication.md:
package.json and the lockfile, then run npm ci --ignore-scripts;Within that boundary, run the generated project’s applicable checks:
npm run lint
npm run typecheck
npm test
npm run build
npm run verify:package
npm audit --omit=dev --audit-level=high
git diff --check
Verify a denied write-policy operation sends no upstream request. Treat failures as generator/manifest defects; do not patch generated source invisibly.
Completion criterion: fresh tool output demonstrates the generated project uses installed npm type-mcp and passes its applicable checks.
Immediately before GitHub creation/push, ask for and record confirmation of owner/org, repository name, visibility, and source branch. Before staging, committing, or pushing, resolve the actual checked-out/ref-to-publish branch and stop unless it exactly equals the recorded source branch. Only after this ref verification, create, commit, push that verified ref, and read back the remote URL/default branch. Scan staged/tracked files for secrets before reporting success.
Completion criterion: the user-confirmed repository exists remotely and contains the verified generated project with no credential-bearing artifact.
type-mcp-api-cli; do not add parser/template logic here.type-mcp and runs through an official MCP transport.TYPE_MCP_ALLOW_PROTECTED_OPERATIONS exact-ID gate and deny-before-request-construction behavior are verifiedtype-mcp and passes applicable checks