Ask the user to confirm (OK/Cancel)
elicit_confirmAsk the user an OK/Cancel confirmation via elicitation (convenience wrapper over elicit_form), modeled on JavaScript's confirm(). Use this for a single yes/no question; use elicit_form to collect arbitrary fields. Returns three-state {confirmed}: true = proceed, false = a human explicitly said no, null = no answer was obtained (reason: "dismissed" | "error") — ask again later.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| labels | No | Relabel or localize the OK/Cancel buttons. Each label is trimmed, 1-40 characters; unknown keys are rejected. Button placement and styling stay fixed. | |
| message | Yes | The yes/no question shown to the user in the host's elicitation dialog. | |
| timeoutSeconds | No | How long to wait for the answer, in seconds (default 300, clamped 60-3600). |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
| reason | No | Present only when confirmed is null: "dismissed" = the elicitation was closed unanswered (including timeout), "error" = it failed. | |
| confirmed | Yes | true = the user chose OK; false = an explicit no (Cancel choice or declined elicitation); null = no answer was obtained. |