Developer Docs

Connect your AI to your knowledge base

REST API for automation. MCP server for AI assistants. Same knowledge base, same security.

MCP Server

Connect Claude Code, Claude Desktop, VS Code, or Cursor directly to your knowledge base. AI assistants can search, query, and review documents natively.

  • 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)
  • Document CRUD + file upload
  • API key scoping + rate limiting

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

RAG answer with citations

puccha_list_docs

Browse the knowledge base

puccha_get_doc

Read full document content

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"}'

Full API reference with request/response schemas coming soon.

In the meantime, explore the API via the Playground in your dashboard.

Rate limits

Plan Queries/day Per key/hour MCP tools/hour
Free1006060
Team1,0006060
Business10,0006060
EnterpriseCustomCustomCustom