Cogneris, inside your code editor.
Cogneris runs a Model Context Protocol server. Connect VS Code, Cursor, Claude Code or any MCP client and the assistant in your editor reads our docs and API reference, creates API keys and webhooks, trains classifiers and runs fill jobs — on your tenant, with the same audit trail as the REST API.
What it is
A Model Context Protocol server in front of the same platform your API keys already reach.
- An MCP endpoint, not a second product — every tool call goes to the same Cogneris services the REST API uses. Same tenant, same metering, same audit trail.
- Built for writing integrations — the assistant searches the docs, reads the exact contract of a route with code in Node, Python, C# and curl, then creates the API key and webhook your code needs.
- 53 tools in eight areas — account, docs and API reference, API keys, webhooks, classifiers, workflows and their runs, Build AI, and PDF fill. 21 read tools carry
mcp.readand 10 write tools carrymcp.write; API key management, webhook management and Build AI have scopes of their own. - Stay connected with a developer token — generate it in the Cogneris platform, paste it once, and your editor keeps it in its own secret storage for up to 90 days.
- Any MCP client — VS Code, Cursor and Claude Code are the three we document below; anything that speaks streamable HTTP works the same way.
Watch it in VS Code
A four-minute walkthrough, recorded in production: set up the server, then ask GitHub Copilot for an API key, Python code that extracts and classifies documents, and a webhook with a verified signature.
- Cogneris in VS Code: MCP, API keys, Python code and webhooks — in English
- Cogneris no VS Code: MCP, chave de API, código Python e webhooks — in Brazilian Portuguese
Server URL
One URL per production region — use the one your tenant lives in. Europe is the default region for new tenants.
Your tenant region is pinned at sign-up and matches the REST host you already use
(api-eu; the US region and api-us are paused since 2026-10-27) — see
Environments.
The MCP page in the platform shows the right URL for your tenant. The JSON-RPC endpoint
is the root path /, not a sub-path.
Generate a developer token
The recommended way in: one token, scoped and expiring, that keeps your editor connected.
- Where — in the Cogneris platform, open Vision → MCP. The page shows your server URL, ready-to-paste configuration for each editor, and the token generator.
- What you choose — a name that says where the token is used, a validity of 30 or 90 days, and its scopes.
mcp.readandmcp.writeare ticked by default; addapikeys.manageorwebhooks.manageonly if the assistant should manage keys or webhooks. - Shown once — copy the token when it appears; it is not shown again. Generate a new one if you lose it.
- Tied to you — every action taken with the token is recorded against your user. Revoke it from the same page when you no longer need it.
Connect your editor
Three editors, one server. Swap the URL for your region.
VS Code
Put this in .vscode/mcp.json. The token is a password input: VS Code asks for it
once, keeps it in its secret storage, and never writes it to the file — so the file is safe
to commit.
{
"inputs": [
{
"id": "cogneris-token",
"type": "promptString",
"password": true,
"description": "Cogneris developer token"
}
],
"servers": {
"cogneris": {
"type": "http",
"url": "https://mcp-eu.cogneris.ai/",
"headers": { "Authorization": "Bearer ${input:cogneris-token}" }
}
}
}
Cursor
Put this in ~/.cursor/mcp.json and replace the placeholder with your token. This
file holds the token in plain text, so keep it out of any repository.
{
"mcpServers": {
"cogneris": {
"url": "https://mcp-eu.cogneris.ai/",
"headers": { "Authorization": "Bearer <YOUR_COGNERIS_TOKEN>" }
}
}
}
Claude Code
One command registers the server; replace the placeholder with your token.
claude mcp add --transport http Cogneris https://mcp-eu.cogneris.ai/ \ --header "Authorization: Bearer <YOUR_COGNERIS_TOKEN>"
A custom MCP client
The server is stateless, so a single POST lists the catalog. Send both content types in
Accept — replies are SSE-framed. Then call cogneris_whoami to confirm
which tenant, user and scopes the connection carries.
curl -sS https://mcp-eu.cogneris.ai/ \
-H "Authorization: Bearer $COGNERIS_MCP_TOKEN" \
-H "Content-Type: application/json" \
-H "Accept: application/json, text/event-stream" \
-d '{"jsonrpc":"2.0","id":1,"method":"tools/list","params":{}}'
Browser sign-in (OAuth)
The alternative to a token: sign in through the browser, for sessions of up to 1 hour.
- Configure the URL without a header — a call without credentials answers
401with aWWW-Authenticateheader pointing at the server's metadata, which is the signal an MCP client uses to start sign-in. - Authorization code with PKCE — the client sends you to the Cogneris sign-in page for your region (
sso-eu.cogneris.aiorsso-us.cogneris.ai) and exchanges the code for a short-lived bearer token. There is no client secret in your configuration. - The session lasts 1 hour — that cap is a security control of the Cogneris sign-in. To stay connected for days, use a developer token instead.
- Covers the two MCP scopes — browser sign-in grants
mcp.readandmcp.write. The API key, webhook management and Build AI tools need a developer token that carries their scopes. - Discover before you configure —
GET /.well-known/oauth-protected-resourceis anonymous and returns the resource identifier (the server's ownhttps://URL), the authorization server and the supported scopes, per RFC 9728. Read it rather than hardcoding.
Scopes
A tool whose scope your credential lacks is not listed, and refuses to run if called.
Tool catalog
53 tools, grouped by area. The names are exactly what tools/list returns; the scope column is what the credential must carry.
cogneris_classifiers_list, never from cogneris_templates_list.
Account and usage
Who the connection acts as, and what the tenant has consumed.
cogneris_whoamimcp.readShows who this connection acts as: tenant, user and e-mail, how you signed in (developer token or browser sign-in), sandbox or production, the granted scopes, and the API base URL your code should call.cogneris_usage_summarymcp.readDocuments, pages and AI tokens per day and per document type over a UTC date range — the same numbers the dashboard shows.Docs and API reference
So the assistant in your editor writes code against the real API instead of guessing it.
cogneris_docs_searchmcp.readSearches the public Cogneris documentation and the server's integration guides, and returns the best-matching sections with their URLs.cogneris_docs_getmcp.readReads one documentation page as plain text, in parts of at most 6000 characters.cogneris_api_operationsmcp.readLists the API's routes — method, path and a one-line summary, grouped by area — with an optional filter.cogneris_api_referencemcp.readEverything needed to call one route: parameters, request and response schemas, error codes, authentication, and ready-to-run Node, Python, C# and curl that read the key from COGNERIS_API_KEY.API keys
Keys for your own code. These tools are listed only when the developer token carries apikeys.manage.
cogneris_apikeys_listapikeys.manageLists the tenant's API keys — name, environment, scopes, last four characters, dates — never their values.cogneris_apikeys_createapikeys.manageCreates an API key with only the scopes your code needs. Sandbox by default; a production key needs an explicit confirmation. The value is returned once.cogneris_apikeys_revokeapikeys.manageRevokes a key by id. Immediate and irreversible: every request made with it fails from then on.Webhooks
Endpoints that receive Cogneris events. The event catalogue needs mcp.read; everything else needs webhooks.manage.
cogneris_webhooks_event_typesmcp.readThe event catalogue: each versioned CloudEvents type with its description, an example payload, and whether it is sent today or only planned.cogneris_webhooks_listwebhooks.manageLists the tenant's webhook endpoints — URL, subscribed events, active flag. Never returns signing secrets.cogneris_webhooks_getwebhooks.manageReads one webhook endpoint by id.cogneris_webhooks_createwebhooks.manageRegisters a public HTTPS endpoint. Returns the signing secret once, with receiver code in Node, Python and C# that verifies the Cogneris-Webhook-Signature header.cogneris_webhooks_updatewebhooks.manageReplaces an endpoint's URL, description and subscribed events. Events left out of the list stop being delivered.cogneris_webhooks_disablewebhooks.manageStops deliveries to an endpoint. Events raised while it is disabled are not delivered to it.cogneris_webhooks_deletewebhooks.manageDeletes an endpoint; deliveries to it stop.cogneris_webhooks_rotate_secretwebhooks.manageReplaces an endpoint's signing secret and returns the new one once. The old secret stops validating new deliveries.cogneris_webhooks_testwebhooks.manageQueues a signed test delivery to an endpoint, so you can check the receiver before a real event arrives.cogneris_webhooks_deliveries_listwebhooks.manageDelivery history, newest first — event type, state, attempts, last error. Payloads and secrets are never included.cogneris_webhooks_deliveries_getwebhooks.manageOne delivery with its attempts: the HTTP status your receiver answered, latency and error code.cogneris_webhooks_deliveries_replaywebhooks.manageSends a failed delivery again. The endpoint must be active, and a delivery gets at most five attempts in total.Classifiers
Your own document types — the ones shown as templates in the Cogneris app.
cogneris_classifiers_listmcp.readLists the tenant's classifiers with their status (Draft, Queued, Processing, Training, Finished, Error) and sample files.cogneris_classifiers_getmcp.readReads one classifier by id: name, status, field metadata and its sample files.cogneris_classifiers_statusmcp.readThe current training status of one classifier.cogneris_classifiers_createmcp.writeCreates a classifier from a name and sample documents. It starts in Draft. Not idempotent.cogneris_classifiers_add_samplesmcp.writeAdds sample documents to a classifier. A Finished classifier is immutable — create a new one to change it. Not idempotent.cogneris_classifiers_trainmcp.writeStarts training from the samples. Training is asynchronous; poll the status until Finished or Error.Workflows
Write a workflow graph from a description: read the schema, validate, save a draft, publish when you confirm. No Build AI credits.
cogneris_workflows_schemamcp.readThe JSON Schema of a workflow graph, in pieces an assistant can read: the graph shape and an index of every phase type, then one phase type's configuration at a time, split into parts when it is large.cogneris_workflows_listmcp.readLists the tenant's workflows — name, status, version — page by page.cogneris_workflows_getmcp.readOne workflow: its published phases and a summary of the draft graph (nodes, phase types, connections). The full graph JSON comes in blocks of 6500 characters.cogneris_workflows_validatemcp.readChecks a graph with the same rules publish applies — schema, one start node, no cycle, reachability, the tenant resources it names — without saving anything. Costs no credits.cogneris_workflows_createmcp.writeCreates a draft workflow from a name, a description and a graph. A draft runs nothing. Retrying the same create returns the same draft.cogneris_workflows_updatemcp.writeReplaces a draft's name, description or graph. The published version keeps running until the next publish.cogneris_workflows_publishmcp.writePublishes the draft as a new immutable version that new runs use. The assistant asks you first; a refusal lists every validation issue.Workflow runs
Try a published workflow on real documents and see what each step decided.
cogneris_workflow_runs_startmcp.writeStarts a run of a published workflow with 1 to 10 documents (base64, 10 MB each). Steps consume credits like the matching document operations. Retrying with the same documents returns the same run.cogneris_workflow_runs_getmcp.readA run's status, documents and steps, with a suggested wait before reading it again while it is in progress.cogneris_workflow_runs_stepmcp.readWhat one step concluded: its outcome, the decisions behind it and the extracted fields per document, with long values cut and personal data masked.Build AI
Let Cogneris draft the whole process — workflow, classifier and templates — from your description. Listed only when the developer token carries builder.run; every step states its cost.
cogneris_builder_startbuilder.runOpens a Build AI session from a description of your process and returns follow-up questions. Costs 2 credits.cogneris_builder_answerbuilder.runSaves your answers to the session's questions. Free.cogneris_builder_planbuilder.runDrafts the plan — document types and fields, form, workflow, templates. Costs 10 to 30 credits: 10 for the plan, 10 more for an automatic market research when none ran yet, and up to 2 automatic revisions of 5.cogneris_builder_revisebuilder.runChanges the latest plan from an instruction in plain words. Costs 5 to 15 credits.cogneris_builder_statusbuilder.runThe session: questions, a summary of the latest plan and its issues, and credits consumed and pending. Free; while a step runs, reading the session is what moves it forward.cogneris_builder_set_samplesbuilder.runChooses Cogneris library examples, or none, for one document type of the plan. Free. Uploading your own samples stays in the Build AI screen.cogneris_builder_approvebuilder.runApproves one plan version and creates the workflow, classifier and templates in your tenant. Only after your explicit yes.cogneris_builder_apply_statusbuilder.runProgress of an approved plan: applying, training, ready or failed.PDF fill: templates, sources, jobs and artifacts
Write-back: stamp extracted data into a PDF template and download the result.
cogneris_templates_listmcp.readLists PDF fill templates (acroform, overlay or HTML), paged, with an optional name filter.cogneris_templates_getmcp.readThe full definition of one fill template — fields, strategy, storage key and version.cogneris_templates_registermcp.writeRegisters a fill template from an uploaded PDF and returns its id and detected field count. Not idempotent.cogneris_sources_uploadmcp.writeUploads a base64 PDF as the source of a fill job or as a template PDF. At most 10 MB decoded. Not idempotent.cogneris_jobs_createmcp.writeStarts a billable fill job: extract the source PDF, map its fields, fill the template. Every call creates a new job and consumes credits.cogneris_jobs_getmcp.readStatus and result metadata of one fill job; a completed job carries the artifact id to download.cogneris_jobs_listmcp.readLists fill jobs with optional status and template filters.cogneris_artifacts_downloadmcp.readA signed URL for the filled PDF, valid for 5 minutes.Transport & discovery
Stateless streamable HTTP. Worth knowing if you are writing the client yourself.
- Stateless by design — there is no
Mcp-Session-Idto carry. Every request stands on its own, which is what lets the service scale to zero between calls. - JSON-RPC at the root — POST to
/. There is no/mcpsub-path; a client configured with one gets a 404. - Responses are SSE-framed — the reply comes back as
text/event-stream, so the request must advertiseAccept: application/json, text/event-stream. - A missing or rejected credential is a 401 — with
WWW-Authenticate: Bearer resource_metadata="…", never an empty tool list. - Two anonymous discovery documents —
/.well-known/mcp.jsonpublishes the protocol version, the server identity and the supported scopes;/.well-known/oauth-protected-resourcepublishes the RFC 9728 metadata. Neither needs a token. - Health is public too —
GET /healthanswers without credentials, which is what the regional status probes read.
Before you wire it up
Behaviours that surprise people once an agent is driving.
- API keys are sandbox by default —
cogneris_apikeys_createmakes a sandbox key unless you explicitly confirm a production one. Keys created from the editor never carryapikeys.manage,mcp.readormcp.write. - Secrets are handed out once — a new API key, webhook signing secret or rotated secret appears in one answer only. The assistant is told to write it to your git-ignored
.envand never repeat it in chat, code or commits. - Fill jobs cost money —
cogneris_jobs_createconsumes credits on your plan. An agent looping over a folder spends real budget, so cap it in the prompt as well as in the tenant cost cap. - Creating is not idempotent — creating a classifier, adding samples, registering a template, uploading a source, starting a fill job, or creating a webhook or an API key each make a new record per call. A retried tool call is a duplicate, not a no-op. Workflow writes, workflow runs and the Build AI steps that cost credits are the exception: a retry with the same input is answered once.
- Publishing asks first — new runs use a published workflow version, so the assistant shows you the graph and publishes only after you say yes. Deleting a workflow and promoting it from sandbox are not available over MCP.
- Build AI spends credits and needs an admin — the plan costs 10 to 30 credits and a revision 5 to 15, including the automatic research and revisions. It runs on production developer tokens that carry
builder.run, owned by a tenant administrator; a sandbox token is refused. - Uploads cap at 10 MB decoded — that is the size after base64 decoding, so budget roughly 7.5 MB of file. Larger sources go through the REST upload path instead.
- Signed URLs expire in 5 minutes — fetch the artifact when you get the URL. Storing it for later is storing a dead link.
- Usage ranges are UTC and half-open —
tomust be strictly greater thanfrom; reversed or equal ranges are rejected rather than silently clamped.
Next: Authentication
How keys, scopes and signatures work across the rest of the platform.