Interactive choice cards for user decisions. Always use instead of numbered option lists. One survey replaces 3-4 back-and-forth messages.
Collect structured input from the user via an interactive survey card. The survey tool is a direct tool — call it by name, not via bash.
Don't use when: simple yes/no (ask in text), or the user already gave all details.
The questions parameter uses pipe format: each line is Question | Option A | Option B | ....
{
"title": "What to analyze?",
"questions": "Analysis type | Revenue by region | Trends over time | Customer segmentation | All of the above"
}
{
"title": "Export Setup",
"questions": "Format? | PDF | CSV | Markdown\nDetail level? | Summary | Detailed | Full data"
}
Separate multiple questions with \n (newline).
survey ask "Output format?" --options "PDF|Markdown|HTML" --title "Export"
Question | Option1 | Option2 (at least 2 options)