pub trait ExtensionError:
Error
+ Send
+ Sync
+ 'static {
// Required method
fn code(&self) -> &'static str;
// Provided methods
fn status(&self) -> StatusCode { ... }
fn is_retryable(&self) -> bool { ... }
fn user_message(&self) -> String { ... }
fn to_mcp_error(&self) -> McpErrorData { ... }
fn to_api_error(&self) -> ApiError { ... }
}Available on crate feature
core only.