Skip to main content
Use 21st through Corsair: one client, typed API calls. Create a 21st API key at 21st.dev/mcp. Search with scope public to browse the public registry, team for your team library or mine for your own components. Installing someone else’s component (components.getInstallPackage) needs a paid 21st plan; your own components install on any plan. Publishing sends the component source as componentCode, demos as demoFiles (metadata.demos[].file_index points into them) and optional covers as previewImages. Give source files as { filename, content } and images as { filename, base64, contentType }. The draft flow is drafts.create (21st starts the cover capture itself; drafts.requestReview with action ensure_media queues it again), then drafts.getReview until media.<demo>.cover.state is ready, then drafts.publish with the same source. A published component can’t be deleted: components.unpublish makes it private. Team invite links need a team API key. What you get:
  • 33 typed API operations

Setup

1

Install

2

Add the plugin

corsair.ts
With multiTenancy: true, scope calls with corsair.withTenant(id). See Quick start for KEK + Hub keys, and Multi-tenancy for account isolation.
3

Choose authentication

4

Connect a tenant

Mint a connect link and send the tenant to it. Hub hosts the page and delivers the result to your app — see Connect / OAuth.

Example API calls

Search the public registry
components.publish
See the full list on the API page.

What’s next

API reference

Every twentyfirst.api.* operation with input and output types.

Connect / OAuth

createLink, Hub delivery, and tenant connect flows.

Use with agents

Expose this plugin’s operations as MCP tools.