GetPromptResponse extension type
A response to a prompts/get request, which is either a GetPromptResult
or an InputRequiredResult.
Check isInputRequired and then cast to one of those.
This type is not intended to be constructed directly and thus has no public constructor.
- on
- Implemented types
- Implementers
Properties
- isInputRequired → bool
-
Whether the server asked for more input before it can answer, which makes
this an InputRequiredResult.
no setterinherited
- meta → Meta?
-
The
_metaproperty/parameter is reserved by MCP to allow clients and servers to attach additional metadata to their interactions.no setterinherited - resultType → String
-
The type of this result, which determines how to parse it.
no setterinherited
Constants
-
getPromptResult
→ const GetPromptResult Function({String? description, required List<
PromptMessage> messages, Meta? meta}) - A complete result with no input required.
-
inputRequiredResult
→ const InputRequiredResult Function({Map<
String, InputRequest> ? inputRequests, Meta? meta, String? requestState}) - A result that requires further input from the client.