Overview
Use CL-SDK tools and documentation directly from AI coding assistants via MCP
The CL-SDK MCP server exposes SDK functions and documentation search as Model Context Protocol tools. This lets AI coding assistants like Claude Code, Cursor, and Windsurf call CL-SDK functions and search these docs without leaving your editor.
What it provides
- Documentation search — full-text search across all doc pages, read individual pages, list the doc tree
- Prompt builders — generate system prompts, extraction prompts, and application field prompts
- Extraction pipeline — classify documents, extract policies and quotes from PDFs
- PDF operations — list form fields, fill AcroForms, overlay text on flat PDFs
Quick start
Install the MCP server package:
npm install -g @claritylabs-inc/cl-sdk-mcp
Then add it to your MCP client. See Client setup below.
Published to GitHub Packages. You need a .npmrc pointing @claritylabs-inc to https://npm.pkg.github.com with a valid token.
Architecture
The server is a standalone package (@claritylabs-inc/cl-sdk-mcp) that bundles the documentation content and depends on @claritylabs-inc/cl-sdk for SDK functionality.
┌──────────────────┐ ┌──────────────────────────────────────┐
│ │ stdio │ @claritylabs-inc/cl-sdk-mcp │
│ AI Assistant │◄────────►│ │
│ │ │ ┌───────────────┐ ┌───────────────┐ │
│ Claude Code │ │ │ Doc tools │ │ SDK tools │ │
│ Cursor │ │ │ │ │ │ │
│ Windsurf │ │ │ search_docs │ │ Prompt │ │
│ ... │ │ │ read_doc_page │ │ builders │ │
│ │ │ │ list_sections │ │ Extraction │ │
└──────────────────┘ │ │ │ │ PDF ops │ │
│ └───────┬───────┘ └───────┬───────┘ │
│ │ │ │
│ ▼ ▼ │
│ ┌───────────────┐ ┌───────────────┐ │
│ │ docs-bundle │ │ @claritylabs │ │
│ │ .json │ │ -inc/cl-sdk │ │
│ └───────────────┘ └───────────────┘ │
└──────────────────────────────────────┘
- Documentation is bundled as
docs-bundle.jsonat publish time — no filesystem access needed - SDK functions are imported from
@claritylabs-inc/cl-sdk(installed as a dependency) - Model config is read from
mcp-config.jsonor environment variables - Communicates via
StdioServerTransport
Client setup
Claude Code
Add to your project's .claude/mcp.json or global ~/.claude/mcp.json:
{
"mcpServers": {
"cl-sdk": {
"command": "npx",
"args": ["@claritylabs-inc/cl-sdk-mcp"]
}
}
}
If you're working in the cl-sdk-docs repo directly, the .claude/mcp.json in the repo auto-registers it.
Cursor / Windsurf
Add to your MCP settings (usually ~/.cursor/mcp.json or equivalent):
{
"mcpServers": {
"cl-sdk": {
"command": "npx",
"args": ["@claritylabs-inc/cl-sdk-mcp"]
}
}
}
Other MCP clients
Any client that supports stdio servers:
npx @claritylabs-inc/cl-sdk-mcp