Overview
Two ways to reach the same documents, with the same permissions and the same credits:
REST API
For your application or scripts: HTTP routes that return JSON. You decide when to search, when to ask a question, and what to do with the answer.
MCP connector
For an AI assistant (Claude, Cursor, an agent): it discovers the tools on its own and decides when to dig into your documents to answer you.
Either way, you read your workspace: the documents uploaded or imported in the app. Questions asked through the API or MCP show up in your chat, with their sources.
Create an API key
- 1
Create an account and upload at least one document in Documents.
- 2
Open Integrations → API and MCP, name the key after its use (“Claude Code”, “Reporting script”…), then Create a key.
- 3
Copy it right away: it starts with
ags_and won't be shown again. Keep it in an environment variable rather than in your code:Terminalexport AGENTIC_SEARCH_API_KEY="ags_your_key" - 4
A key can be revoked at any time from the same page; clients using it lose access immediately. Use one key per tool: you can revoke one without cutting off the others.
Pricing and limits
- Asking a question (
ask): €0.10, same as in the app: taken from your free credit, then billed at the end of the month with pay as you go. Nothing is charged if no answer could be produced. - Searching, listing documents, reading a page: free. Search is limited to 60 calls per hour per key.
- Questions of up to 2,000 characters; 1 to 20 passages per search.
- Up to 10 keys per account. An invited member has their own keys, on the owner's workspace.
Call the API from your code
HTTP routes under https://agentic-search.cc/api/v1 that accept and return JSON.
Authentication
Every request carries the key in the Authorization header. Without a valid key, the API answers 401. The app's session (cookie) is never accepted on these routes.
Authorization: Bearer ags_your_keyThe key gives access to the whole workspace: call the API from a server, never from code running in the browser.
List documents
GET/api/v1/documents
The workspace's documents. Only those with the ready status can be queried; the others are still being read.
curl https://agentic-search.cc/api/v1/documents \
-H "Authorization: Bearer $AGENTIC_SEARCH_API_KEY"{
"documents": [
{
"id": "5f0c2a8e-1b7d-4c3e-9a51-0e6d2f4b8c19",
"name": "Annual report 2023.pdf",
"pages": 148,
"status": "ready"
},
{
"id": "a91d…",
"name": "Master agreement.docx",
"pages": 22,
"status": "processing"
}
]
}Search passages
POST/api/v1/search
Hybrid search (exact words and meaning) across all documents, reranked by relevance. Returns raw passages without writing an answer: handy to feed your own model. Free.
query | What you're looking for, in natural language or keywords. |
limit | Number of passages, from 1 to 20 (8 by default). |
curl https://agentic-search.cc/api/v1/search \
-H "Authorization: Bearer $AGENTIC_SEARCH_API_KEY" \
-H "Content-Type: application/json" \
-d '{"query": "chiffre d affaires 2023", "limit": 5}'{
"results": [
{
"document": "Annual report 2023.pdf",
"document_id": "5f0c2a8e-1b7d-4c3e-9a51-0e6d2f4b8c19",
"page": 12,
"text": "Consolidated revenue reached €1,284M, up 6.1%…"
}
]
}Ask a question
POST/api/v1/ask
The app's full pipeline: search, reasoning, a written answer with [n] citations and their sources (document, page). Allow 15 to 60 seconds and set your client's timeout accordingly. Costs €0.10.
question | The question, up to 2,000 characters. |
conversation_id | Continues a conversation: the identifier returned by a previous question. |
curl https://agentic-search.cc/api/v1/ask \
-H "Authorization: Bearer $AGENTIC_SEARCH_API_KEY" \
-H "Content-Type: application/json" \
--max-time 180 \
-d '{"question": "What was 2023 revenue?"}'{
"answer": "2023 revenue was **€1,284M** [1], up 6.1% [1].",
"sources": [
{
"n": 1,
"document": "Annual report 2023",
"page": 12,
"document_id": "5f0c2a8e-1b7d-4c3e-9a51-0e6d2f4b8c19",
"excerpt": "Consolidated revenue reached €1,284M, up 6.1%…"
}
],
"conversation_id": "0b6f…",
"conversation_url": "https://…/dashboard/chat?c=0b6f…",
"credits_used": 10,
"balance": 410
}Read a page
GET/api/v1/documents/{document_id}/pages/{page}
The full text of a page, numbered from 1, to check a source. The identifier comes from the document list or from a source's document_id field.
curl https://agentic-search.cc/api/v1/documents/<id>/pages/12 \
-H "Authorization: Bearer $AGENTIC_SEARCH_API_KEY"{
"document": "Annual report 2023.pdf",
"page": 12,
"text": "…full text of the page…"
}Balance and billing
GET/api/v1/credits
The remaining free credit, in cents (balance), and whether pay as you go is on. Without pay as you go, a question refused for lack of credit returns 402.
curl https://agentic-search.cc/api/v1/credits \
-H "Authorization: Bearer $AGENTIC_SEARCH_API_KEY"{
"balance": 410,
"pay_as_you_go": false
}Errors
An error returns an HTTP status and a message to show the user as is, in French by default, in English if the request sends the Accept-Language: en header:
{
"error": "Insufficient balance: this action costs €0.10 and €0.00 is left. Turn on pay as you go in Billing to continue."
}400 | Invalid request, or no document ready in the workspace. |
401 | Missing, invalid or revoked key. |
402 | Free credit used up without pay as you go, or a failed payment. |
404 | Document, page or conversation not found in your workspace. |
429 | More than 60 searches in an hour with this key. |
500 | No answer could be produced; nothing was charged. |
Plug your documents into an assistant (MCP)
MCP (Model Context Protocol) is the open standard that lets an AI assistant use external tools. Connected to Agentic Search, your assistant searches your documents by itself when a question calls for it, and cites its sources.
How it works
The Agentic Search MCP server is a remote (HTTP) server. To connect it, you need two things:
https://<MCP server address>/mcpand an API key (ags_…), sent in the Authorization header. Each tool has its own way of setting them: follow the section for yours below. Once connected, just ask: “In my Agentic Search documents, what was 2023 revenue? Cite the pages.”
Exposed tools
list_documents | What your workspace contains: identifier, name, pages, status. Free. |
search | The most relevant raw passages. Free, 60 per hour. The assistant reasons over them itself. |
ask | An answer written and cited by the Agentic Search pipeline. €0.10 per question. |
read_page | Full text of a page, to check a citation. Free. |
Assistants often prefer search: they get the passages and write the answer themselves. Ask explicitly “ask Agentic Search” to get the verified answer from ask.
Claude Code
One command, in the terminal. The --scope user option makes the server available in all your projects.
claude mcp add --transport http --scope user agentic-search https://<MCP server address>/mcp \
--header "Authorization: Bearer $AGENTIC_SEARCH_API_KEY"Check with /mcp in Claude Code: agentic-search should show as connected, with its four tools.
Claude Desktop
The desktop app launches the servers declared in its configuration file. The small mcp-remote program (Node.js 18 or later) bridges to our remote server and adds your key.
- 1
Open Settings → Developer → Edit Config, or directly
~/Library/Application Support/Claude/claude_desktop_config.json(macOS),%APPDATA%\Claude\claude_desktop_config.json(Windows). - 2
Add the server, with your key:
claude_desktop_config.json{ "mcpServers": { "agentic-search": { "command": "npx", "args": [ "-y", "mcp-remote", "https://<MCP server address>/mcp", "--header", "Authorization:${AUTH_HEADER}" ], "env": { "AUTH_HEADER": "Bearer ags_your_key" } } } } - 3
Quit and restart Claude Desktop: the Agentic Search tools appear in the conversation's tools menu.
Cursor and VS Code
Both editors accept a remote server with a header. In VS Code, the inputs variable asks for the key on first launch instead of writing it in the file.
{
"mcpServers": {
"agentic-search": {
"url": "https://<MCP server address>/mcp",
"headers": {
"Authorization": "Bearer ags_your_key"
}
}
}
}Any other MCP client that supports “Streamable HTTP” is configured the same way: the server address and the Authorization header.
Claude.ai, Cowork, ChatGPT
SoonThese assistants add a remote server as a custom connector: you paste the server address, click Connect, then authorize access from your Agentic Search account (OAuth). They can't send an API key.
OAuth sign-in is coming soon; this section will then walk you through it. Until then, use Claude Desktop or Claude Code, or go through the REST API.
Agents in code
The Claude and OpenAI APIs connect to the MCP server themselves: declare it in the request and the model calls the tools while it answers. The server must be reachable from the Internet (no localhost address). With LangGraph, the MCP adapter turns the tools into LangChain tools.
import os
import anthropic
client = anthropic.Anthropic()
response = client.beta.messages.create(
model="claude-opus-5-5",
max_tokens=16000,
betas=["mcp-client-2025-11-20"],
mcp_servers=[{
"type": "url",
"url": "https://<MCP server address>/mcp",
"name": "agentic-search",
"authorization_token": os.environ["AGENTIC_SEARCH_API_KEY"],
}],
tools=[{"type": "mcp_toolset", "mcp_server_name": "agentic-search"}],
messages=[{"role": "user", "content": "In my documents, what was 2023 revenue? Cite the pages."}],
)
for block in response.content:
if block.type == "text":
print(block.text)Security
- A key reads the whole workspace and spends its credits (
ask): never commit it to a Git repository, don't share it, revoke it at the slightest doubt. - The workspace queried is determined by the key, never by what the assistant sends: an assistant can't read another account's workspace.
- Passages returned to the assistant are sent to that assistant's provider (Anthropic, OpenAI, your software's vendor), under its own terms.
- A document can contain text that looks like instructions. If your agent can also act (send an email, edit files), keep a human approval step on those actions.