pub fn failure(request_id: String, error: impl Into<String>) -> WidgetResponse
Builds an error response.