The user prompt tool allows agents to ask questions and collect input from users during execution. This enables interactive workflows where the agent needs clarification, confirmation, or additional information before proceeding.Documentation Index
Fetch the complete documentation index at: https://mintlify.com/docker/docker-agent/llms.txt
Use this file to discover all available pages before exploring further.
Configuration
When to use it
- When the agent needs clarification before proceeding with a destructive or irreversible action
- Collecting credentials, tokens, or configuration values at runtime
- Presenting choices and getting the user’s decision
- Confirming important actions before executing them
Tool parameters
When the agent callsuser_prompt, it passes:
| Parameter | Type | Required | Description |
|---|---|---|---|
message | string | Yes | The question or prompt text to display to the user. |
schema | object | No | JSON Schema defining the expected shape of the response. |
Response format
The tool returns a JSON object:| Action | Meaning |
|---|---|
accept | The user provided a response. Check content for the value. |
decline | The user declined to answer. |
cancel | The user cancelled the prompt. |
Schema examples
Example agent
agent.yaml
UI presentation
How the prompt appears depends on the interface:| Interface | Behavior |
|---|---|
| TUI | Displays an interactive dialog with appropriate input controls. |
| CLI (exec mode) | Prints the prompt and reads a response from stdin. |
| API / MCP | Returns an elicitation request to the client. |
Related
Shell
Execute commands after collecting user input.
Think
Reason about the user’s response before acting.
Permissions
Require confirmation for specific tool calls.
Features: TUI
Learn about the interactive terminal UI.