You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: docs/docs/api/appkit/index.md
+1-1Lines changed: 1 addition & 1 deletion
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -112,7 +112,7 @@ surface with `@databricks/appkit/beta`. Not meant for application imports.
112
112
113
113
| Variable | Description |
114
114
| ------ | ------ |
115
-
|[agents](Variable.agents.md)| Plugin factory for the agents plugin. Reads `config/agents/*.md` by default, resolves toolkits/tools from registered plugins, exposes `appkit.agents.*` runtime API and mounts `/invocations`. |
115
+
|[agents](Variable.agents.md)| Plugin factory for the agents plugin. Reads `config/agents/*.md` by default, resolves toolkits/tools from registered plugins, exposes `appkit.agents.*` runtime API and mounts `POST /invocations` and `POST /responses` (aliased non-streaming invoke endpoints) plus `POST /chat` (streaming, HITL-capable). |
116
116
|[READ\_ACTIONS](Variable.READ_ACTIONS.md)| Actions that only read data. |
117
117
|[sql](Variable.sql.md)| SQL helper namespace |
118
118
|[WRITE\_ACTIONS](Variable.WRITE_ACTIONS.md)| Actions that mutate data. |
Copy file name to clipboardExpand all lines: docs/docs/plugins/agents.md
+8-4Lines changed: 8 additions & 4 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -6,7 +6,7 @@ This plugin is currently **beta**. APIs may change between minor releases. Impor
6
6
:::
7
7
<!-- AUTO-GENERATED: stability-banner-end -->
8
8
9
-
The `agents` plugin turns a Databricks AppKit app into an AI-agent host. It loads agent definitions from markdown on disk (one folder per agent: `config/agents/<id>/agent.md`), from TypeScript (`createAgent(def)`), or both, and exposes them at `POST /invocations` alongside routes for chat, thread management, and cancellation.
9
+
The `agents` plugin turns a Databricks AppKit app into an AI-agent host. It loads agent definitions from markdown on disk (one folder per agent: `config/agents/<id>/agent.md`), from TypeScript (`createAgent(def)`), or both, and exposes them at `POST /invocations`and `POST /responses` (non-streaming, aliases) alongside `POST /chat` (streaming) and routes for thread management, cancellation, and HITL approval.
10
10
11
11
This page covers the full lifecycle. For the hand-written primitives (`tool()`, `mcpServer()`), see [tools](./server.md).
12
12
@@ -31,7 +31,7 @@ await createApp({
31
31
});
32
32
```
33
33
34
-
That alone gives you a live HTTP server with `POST /invocations` wired to a markdown-driven agent.
34
+
That alone gives you a live HTTP server with `POST /invocations`(and its alias `POST /responses`) wired to a markdown-driven agent. Use `POST /chat` instead when you want the streaming, HITL-capable surface.
35
35
36
36
## Level 1: drop a markdown agent package
37
37
@@ -65,7 +65,11 @@ On startup the plugin:
65
65
66
66
The agent starts with **no tools**. Tools are opt-in — declare them in frontmatter (Level 2 below) or opt into auto-inherit explicitly with `agents({ autoInheritTools: { file: true } })`. See "Auto-inherit posture" further down for what that costs and why it's off by default.
67
67
68
-
Requests land at `POST /invocations` with an OpenAI Responses-compatible body. Every tool call runs through `asUser(req)` so SQL executes as the requesting user, file access respects Unity Catalog ACLs, and telemetry spans are created automatically.
68
+
Requests land at `POST /invocations` (or its alias `POST /responses`) with an OpenAI Responses-compatible body. These endpoints run the agent to completion and return a single JSON response — no SSE. Streaming clients should use `POST /chat`. Every tool call runs through `asUser(req)` so SQL executes as the requesting user, file access respects Unity Catalog ACLs, and telemetry spans are created automatically.
69
+
70
+
:::warning No HITL on `/invocations` and `/responses`
71
+
The non-streaming invoke surface has no way to surface a mid-call approval prompt back to the caller. When `approval.requireForDestructive` is enabled (default) and the resolved agent has any tool annotated with a mutating effect (`effect: "write" | "update" | "destructive"`, or the legacy `destructive: true`), `POST /invocations` and `POST /responses` reject the request with HTTP 400 before the adapter runs. Move HITL-capable agents to `POST /chat`, or disable approval via `agents({ approval: { requireForDestructive: false } })` for autonomous back-office agents.
72
+
:::
69
73
70
74
## Level 2: scope tools in frontmatter
71
75
@@ -370,7 +374,7 @@ The route enforces that the decider is the stream owner: an approve from a diffe
370
374
371
375
The plugin enforces a handful of caps to protect a single-instance deployment from runaway prompts, misbehaving clients, or prompt-injected delegation cycles. Some are static (enforced by the request schema) and some are configurable via `agents({ limits: { ... } })`.
372
376
373
-
**Static caps** (applied at `POST /chat`and `POST /invocations` request parsing):
377
+
**Static caps** (applied at `POST /chat`, `POST /invocations`, and `POST /responses` request parsing):
0 commit comments