|
cxxmcp 1.1.6
C++ MCP SDK
|
Result object for tools/call.
More...
#include <tool.hpp>
Public Member Functions | |
| bool | is_error_result () const noexcept |
| Convenience predicate treating a missing signal as success. | |
Static Public Member Functions | |
| static ToolResult | text (std::string value) |
| Creates a successful text-only tool result. | |
| static ToolResult | error_text (std::string value) |
| Creates an error text-only tool result. | |
Public Attributes | |
| std::vector< ContentBlock > | content |
| Ordered user/model-visible content returned by the tool. | |
| std::optional< Json > | structured_content |
| Optional machine-readable result matching the tool output schema. | |
| std::optional< bool > | is_error |
| Optional domain-level error signal. | |
| std::optional< Json > | meta |
Optional _meta extension object preserved on the wire. | |
| std::optional< std::string > | result_type |
| Result type discriminator. | |
| std::optional< Json > | input_requests |
| Server input requests for MRTR (SEP-2322). | |
| std::optional< std::string > | request_state |
| Opaque request state for MRTR retries (SEP-2322). | |
| Json | extensions = Json::object() |
| Unknown JSON members preserved for forward-compatible round trips. | |
Result object for tools/call.
| std::optional<bool> mcp::protocol::ToolResult::is_error |
Optional domain-level error signal.
Missing means the peer did not state whether the tool call produced an error; explicit false is preserved.
| std::optional<std::string> mcp::protocol::ToolResult::result_type |
Result type discriminator.
"input_required" for MRTR (SEP-2322). Missing means the result is complete.