Developer Docs

Connect your AI to your knowledge base

REST API for automation. MCP server for any AI assistant — Claude, Codex, Gemini, Cursor, VS Code, Windsurf. Same knowledge base, same access rules.

MCP Server

Connect any MCP-compatible assistant — Claude Code, Claude Desktop, Cursor, VS Code, Windsurf, Codex CLI or Gemini CLI — directly to your knowledge base. It can search, answer and review documents natively, under the same per-document access rules as your team.

  • 4 tools: search, answer, list docs, get doc
  • 2 prompts: compliance check, document review
  • Same auth + rate limits as REST API

REST API

Build custom integrations, automate workflows, or embed knowledge search into your own applications. JSON in, JSON out.

  • Search, answer, chat (SSE streaming)
  • Documents, conversations and tickets
  • Help-centre content as JSON (GET /api/content)
  • Per-endpoint key scopes, IP allowlist, rate limits

MCP Setup

Connect your AI assistant in 3 steps.

1

Create an API key

Go to Settings → API Keys in your Puccha dashboard. Create a key with mcp.

2

Connect your AI tool

Pick your tool and replace puccha_live_YOUR_KEY with the key from step 1. The same snippets, pre-filled with your key, appear in the dashboard the moment a key is created.

Claude Code

Run in your terminal

claude mcp add --transport http puccha https://app.puccha.ai/api/mcp \
  --header "Authorization: Bearer puccha_live_YOUR_KEY"

Add to .mcp.json — alternative

{
  "mcpServers": {
    "puccha": {
      "type": "http",
      "url": "https://app.puccha.ai/api/mcp",
      "headers": {
        "Authorization": "Bearer puccha_live_YOUR_KEY"
      }
    }
  }
}

Add --scope user to make it available in every project.

Restart Claude Code. puccha_search, puccha_answer and the document tools appear in its tool list.

Claude Desktop

Add to claude_desktop_config.json

{
  "mcpServers": {
    "puccha": {
      "command": "npx",
      "args": [
        "-y",
        "mcp-remote",
        "https://app.puccha.ai/api/mcp",
        "--transport",
        "http-only",
        "--header",
        "Authorization:${AUTH_HEADER}"
      ],
      "env": {
        "AUTH_HEADER": "Bearer puccha_live_YOUR_KEY"
      }
    }
  }
}

Needs Node.js (runs the mcp-remote bridge). Open the file from Settings → Developer → Edit Config.

Restart Claude Desktop. puccha_search, puccha_answer and the document tools appear in its tool list.

Cursor

Add to .cursor/mcp.json

{
  "mcpServers": {
    "puccha": {
      "url": "https://app.puccha.ai/api/mcp",
      "headers": {
        "Authorization": "Bearer puccha_live_YOUR_KEY"
      }
    }
  }
}

Project file shown — use ~/.cursor/mcp.json to enable it everywhere.

Restart Cursor. puccha_search, puccha_answer and the document tools appear in its tool list.

VS Code

Add to .vscode/mcp.json

{
  "servers": {
    "puccha": {
      "type": "http",
      "url": "https://app.puccha.ai/api/mcp",
      "headers": {
        "Authorization": "Bearer puccha_live_YOUR_KEY"
      }
    }
  }
}

Workspace file shown — for every project run "MCP: Open User Configuration" from the Command Palette.

Restart VS Code. puccha_search, puccha_answer and the document tools appear in its tool list.

Windsurf

Add to ~/.codeium/windsurf/mcp_config.json

{
  "mcpServers": {
    "puccha": {
      "serverUrl": "https://app.puccha.ai/api/mcp",
      "headers": {
        "Authorization": "Bearer puccha_live_YOUR_KEY"
      }
    }
  }
}

Restart Windsurf. puccha_search, puccha_answer and the document tools appear in its tool list.

Codex CLI

Add to ~/.codex/config.toml

[mcp_servers.puccha]
url = "https://app.puccha.ai/api/mcp"
http_headers = { "Authorization" = "Bearer puccha_live_YOUR_KEY" }

Restart Codex CLI. puccha_search, puccha_answer and the document tools appear in its tool list.

Gemini CLI

Run in your terminal

gemini mcp add --transport http \
  --header "Authorization: Bearer puccha_live_YOUR_KEY" \
  puccha https://app.puccha.ai/api/mcp

Add to ~/.gemini/settings.json — alternative

{
  "mcpServers": {
    "puccha": {
      "httpUrl": "https://app.puccha.ai/api/mcp",
      "headers": {
        "Authorization": "Bearer puccha_live_YOUR_KEY"
      }
    }
  }
}

Restart Gemini CLI. puccha_search, puccha_answer and the document tools appear in its tool list.

3

Start using

Your AI assistant now has access to these tools:

puccha_search

Hybrid search — returns document chunks

puccha_answer

Cited context for your assistant to answer from

puccha_list_docs

Browse the knowledge base

puccha_get_doc

Read full document content

puccha_persona_* · puccha_publish

With a key holding the Personas scopes: build personas and playbooks, import skills, add knowledge, evaluate and publish (drafts first; your publish rule applies)

Agent Skill

Using Agent Skills (Claude, ChatGPT/Codex, Cursor, Gemini CLI)? Add the Puccha skill. It tells the assistant to answer from Puccha with citations, follow your organisation’s playbooks, and say so when Puccha has no answer. It carries no knowledge itself.

Download SKILL.md

REST API

All endpoints require an API key via Authorization: Bearer puccha_live_...

POST

/api/search

Hybrid search (semantic + lexical). Returns ranked document chunks without LLM generation.

curl -X POST https://app.puccha.ai/api/search \
  -H "Authorization: Bearer puccha_live_..." \
  -H "Content-Type: application/json" \
  -d '{"query": "PDPA requirements", "topK": 5}'
POST

/api/answer

RAG answer with citations. Retrieves relevant docs, generates an answer grounded in your knowledge base.

curl -X POST https://app.puccha.ai/api/answer \
  -H "Authorization: Bearer puccha_live_..." \
  -H "Content-Type: application/json" \
  -d '{"query": "วิธีขอความยินยอมตาม PDPA", "locale": "th"}'
POST

/api/chat

Streaming chat with multi-turn context. Returns an SSE stream with text chunks and citations.

curl -N -X POST https://app.puccha.ai/api/chat \
  -H "Authorization: Bearer puccha_live_..." \
  -H "Content-Type: application/json" \
  -d '{"query": "What is PDPA?", "locale": "en"}'

Try each endpoint against your own knowledge base in the Playground in your dashboard. app.puccha.ai →

Rate limits

Plan API + MCP queries included / month Requests per key / hour Chat turns / day (abuse cap)
FreeCounts toward the 100-resolution cap6030
Team5,00060500
Business25,000605,000
Enterprise125,000+6050,000