Survey
The survey server lets agents collect structured input from the user during a workflow: confirmations, choices, text fields, numbers, booleans, and more.
It uses MCP elicitation, so the client renders a form and returns structured JSON instead of relying on free-form chat.
Configuration
Section titled “Configuration”{ "servers": { "survey": { "type": "in-memory" } }}The built-in survey server does not read any args.
| Tool | Description |
|---|---|
ask_user | Present a JSON Schema-backed form and collect the response. |
| Field | Type | Description |
|---|---|---|
message | string | Prompt shown to the user. |
schema | object or JSON string | JSON Schema for the form. Must describe an object schema with properties. |
Output
Section titled “Output”| Field | Type | Description |
|---|---|---|
accepted | boolean | true when the user accepted/submitted the form. |
data | object | null | Structured response data when accepted. |
Examples
Section titled “Examples”Confirm a destructive operation:
{ "message": "This will delete 3 generated files. Continue?", "schema": { "type": "object", "properties": { "confirm": { "type": "boolean", "description": "Confirm deletion" } } }}Collect multiple fields:
{ "message": "Configure the new service:", "schema": { "type": "object", "properties": { "name": { "type": "string", "description": "Service name" }, "port": { "type": "number", "description": "Port number" }, "public": { "type": "boolean", "description": "Expose publicly" } } }}Use survey when an agent needs a precise decision or value before it can safely continue.