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
|`url`| string | - | The URL that the user should navigate to. |
342
+
|`elicitationId`| string | - | A unique identifier for the elicitation. |
343
+
|`notifiesOnCompletion`| boolean | false | Whether the server commits to sending a `notifications/elicitation/complete` notification. |
343
344
344
345
The `url` parameter **MUST** contain a valid URL. The `message` parameter **MUST NOT** contain a URL.
345
346
347
+
The `notifiesOnCompletion` parameter indicates whether the server commits to sending a `notifications/elicitation/complete` notification:
348
+
349
+
- When `notifiesOnCompletion` is `true`: The server **MUST** send the notification once it determines the out-of-band interaction has completed (whether successfully or not).
350
+
- When `notifiesOnCompletion` is `false` or absent: Servers **SHOULD NOT** send the notification, and clients **MUST NOT** rely on receiving it.
351
+
346
352
#### Example: Request Sensitive Data
347
353
348
354
This example shows a URL mode elicitation request directing the user to a secure URL where they can provide sensitive information (an API key, for example).
@@ -359,7 +365,8 @@ The same request could direct the user into an OAuth authorization flow, or a pa
"message": "Please provide your API key to continue."
368
+
"message": "Please provide your API key to continue.",
369
+
"notifiesOnCompletion": true
363
370
}
364
371
}
365
372
```
@@ -382,18 +389,32 @@ of band and the client is not aware of the outcome until and unless the server s
382
389
383
390
### Completion Notifications for URL Mode Elicitation
384
391
385
-
Servers **SHOULD** send a `notifications/elicitation/complete` notification when an
392
+
Servers can send a `notifications/elicitation/complete` notification when an
386
393
out-of-band interaction started by URL mode elicitation is completed. This allows clients to react programmatically if appropriate.
387
394
388
-
- The notification **MUST** only be sent to the client that initiated the elicitation request.
389
-
- The notification **MUST** include the `elicitationId` established in the original
390
-
`elicitation/create` request.
391
-
- Clients **MUST** ignore notifications referencing unknown or already-completed IDs.
392
-
- If a completion notification never arrives, clients **SHOULD** provide a manual
393
-
way for the user to continue the interaction.
395
+
Servers sending notifications:
396
+
397
+
-**MUST** only send the notification to the client that initiated the elicitation request.
398
+
-**MUST** include the `elicitationId` established in the original `elicitation/create` request.
399
+
400
+
Clients receiving notifications:
401
+
402
+
-**MUST** ignore notifications referencing unknown or already-completed IDs.
403
+
404
+
The `notifiesOnCompletion` parameter in the `elicitation/create` request indicates whether the server commits to sending a `notifications/elicitation/complete` notification,
405
+
and whether the client can expect to receive it.
406
+
407
+
When a server includes `notifiesOnCompletion: true` in an `elicitation/create` request:
408
+
409
+
- The server **MUST** send a `notifications/elicitation/complete` notification once it determines the out-of-band interaction has completed (whether successfully or not).
410
+
- Clients **MAY** wait for this notification to automatically retry requests that received a [URLElicitationRequiredError](#error-handling), update the user interface, or otherwise continue an interaction.
411
+
- Clients **SHOULD** still provide manual controls that let the user retry or cancel the original request (or otherwise resume interacting with the client) if the notification never arrives.
412
+
413
+
When a server includes `notifiesOnCompletion: false` in an `elicitation/create` request:
394
414
395
-
Clients **MAY** use the notification to automatically retry requests that received a [URLElicitationRequiredError](#error-handling), update the user interface, or otherwise continue an interaction.
396
-
However, because delivery of the notification is not guaranteed, clients must not wait indefinitely for a notification from the server.
415
+
- The server **SHOULD NOT** send a `notifications/elicitation/complete` notification.
416
+
- Clients **MUST NOT** rely on receiving a notification.
417
+
- Clients **SHOULD** provide a manual way for the user to continue the interaction.
397
418
398
419
#### Example
399
420
@@ -430,7 +451,8 @@ Any elicitations returned in the error **MUST** be URL mode elicitations and hav
0 commit comments