Verified HTTP routes enforced by the Bundata API server.
API reference
Authentication, collections, and search
| Method | Path | Result |
|---|---|---|
| POST | /auth/login | Cookie session, or JWT when the client is non-browser |
| GET | /auth/me | User, workspaces, active workspace |
| POST | /auth/workspace | Binds a browser session to workspaceId |
| POST | /auth/logout | Revokes the browser session |
| GET | /api/w/:workspaceId/collections | Collections for that workspace |
| POST | /api/collections/:id/documents/upload-url | Presigned upload instructions (documentUploadRejection checked) |
| POST | /api/collections/:id/documents/confirm | 201 and queued processing |
| POST | /api/collections/:id/retrieve | Hybrid Retrieval v2 over a collection (includeTableFacts optional) |
| POST | /api/collections/:id/answer | Structured answer brief (answer-brief/v1), verified answer, or studied field answer (/answer/stream for SSE) |
| POST | /api/w/:workspaceId/connections/:id/source-ingest | Queued ingest for S3 or PostgreSQL |
| POST | /api/w/:workspaceId/search | Workspace search; semantic mode needs agent:run |
| POST | /api/w/:workspaceId/search/answer | Grounded answer or an explicit non-answer status |
AI providers, models, and chunking
| Method | Path | Result |
|---|---|---|
| GET | /api/account/org/llm/providers | Connected providers (openai, anthropic, google), default provider, and dependent workspace choices |
| PUT | /api/account/org/llm/providers/:provider | Connect or replace an encrypted organization provider key |
| DELETE | /api/account/org/llm/providers/:provider | Remove an organization provider key |
| PUT | /api/account/org/llm/default-provider | Set a connected openai or anthropic key as the default provider |
| GET | /api/w/:wsId/ai-models | Workspace AI model map, catalog models, and chat backend |
| PUT / DELETE | /api/w/:wsId/ai-models/choices/:step | Set or clear a workspace model choice for one step |
| POST | /api/w/:wsId/ai-models/fill-gemini | Fill unchosen steps with suggested Gemini models for Google-only orgs |
| GET / PUT | /api/collections/:id/chunk-sizes | Read or update a collection’s multi-size chunking strategy (single, three_sizes, custom) |
Context Engine, Context Studio, Lineage, and Table Facts
| Method | Path | Result |
|---|---|---|
| GET | /api/w/:wsId/context-engine/status | Coverage and reason codes across all 9 derived layers (?collectionId= optional) |
| POST | /api/w/:wsId/context-engine/builds/dry-run | Estimate document counts, model calls, and USD cost before building a layer |
| POST | /api/w/:wsId/context-engine/builds | Start, :buildId/resume, or :buildId/cancel a Context Engine layer build |
| GET / PUT | /api/w/:wsId/context-engine/switches[/:key] | Read or toggle answer-path switches (graphrag.*, whole_document, field_answers) with evaluation evidence |
| PUT | /api/w/:wsId/context-engine/strictness | Set claim verification strictness (remove, caveat, abstain) |
| GET / PUT / DELETE | /api/w/:wsId/context-engine/ranking[/assignment|/shadow] | Inspect ranking profile, hold deployment default, or opt into shadow comparisons |
| GET / POST | /api/w/:wsId/context-library/* | Business context library entries, versions, re-anchoring, approvals, stewards, /memory, and /asked-before |
| GET / POST / PUT | /api/w/:wsId/context-sets/* | Context sets, versions, proposals, rollback, preview, and access rows |
| GET / POST | /api/w/:wsId/context-explore/* | Context Studio Explore capabilities, turns, and private saved chats |
| GET / POST / PUT | /api/w/:wsId/context-enrichment/* | Enrichment settings, runs, proposals inbox, and member /suggestions |
| GET / POST / PUT / DELETE | /api/w/:wsId/learning/* | Answer feedback, kept questions, learning settings, and Gaps list |
| GET / POST / PUT | /api/w/:wsId/graph-review/* | Quality review queues, items, bitemporal decisions, undo, dataset promotion, and /gate |
| GET / POST / PUT / DELETE | /api/w/:wsId/structured-context/* | PostgreSQL/MySQL schema reads, dbt metadata reads, annotations, joins, and query template test/run |
| GET / POST / PUT / DELETE | /api/w/:wsId/ask-history/* | Private Ask conversations, notes, owner retention settings, and member /agent-memories |
| GET / POST | /api/w/:wsId/documents/:documentId/tables/* | Logical tables, typed cell facts, reconciliation findings, finance rules, and /api/w/:wsId/table-facts |
| POST | /api/w/:wsId/lineage/* | Lineage catalog-map, investigation reads, and time-travel reads (entity-profile, value-series, history, diff, activity, themes) |
Agent credentials, Agent Context API, and MCP
| Method | Path | Result |
|---|---|---|
| GET / POST | /api/w/:wsId/agent-credentials | List or create scoped bdk_… agent credentials (plus /:id/rotate, /:id/revoke, /:id/context-sets) |
| POST | /api/agent/v1/context-packs | Ranked, deduplicated, cited evidence pack within token budget (/context-packs/stream for NDJSON) |
| POST | /api/agent/v1/replays/:replayId | Verify or recompute a recorded context pack |
| POST | /api/agent/v1/context-sets/list | List usable context sets (plus /context-sets/get, /definitions/lookup, /verified-answers/match) |
| POST | /api/agent/v1/fields/list | List studied fields for a collection (plus /fields/query for structured filter/sort/aggregate plans) |
| POST | /api/agent/v1/query-templates/run | Execute an approved read-only PostgreSQL query template from an active context set |
| POST | /api/agent/v1/memories/* | Governed agent memory (remember, recall, list, forget) |
| POST | /api/agent/v1/mcp | Stateless Streamable HTTP MCP server (bundata-workspace-context) |
Paths that older pages marked conceptual, including /extraction/runs and unprefixed /v1, are not this contract.