pub struct SaveQueryParams {
pub name: String,
pub sql: String,
pub description: Option<String>,
}Expand description
Parameters for the save_query tool.
Persists a named read-only SQL query. After saving, the query is available as two MCP resources:
hyper://queries/{name}/definition— JSON metadata (sql, description,created_at).hyper://queries/{name}/result— re-runs the SQL on every read and returns the rows + query stats.
In ephemeral workspaces (no --workspace) saved queries live only for
the life of the server process; in persistent workspaces they are
stored in the _hyperdb_saved_queries meta-table and survive restarts.
Fields§
§name: StringUnique name identifying the query. Becomes the path component of the resource URIs — pick something URL-safe and human-readable.
sql: StringThe SQL to store. Must be a read-only statement (SELECT / WITH
/ EXPLAIN / SHOW / VALUES); destructive statements are
rejected at save time.
description: Option<String>Optional free-form description — what does this query answer?
Trait Implementations§
Source§impl Debug for SaveQueryParams
impl Debug for SaveQueryParams
Source§impl<'de> Deserialize<'de> for SaveQueryParams
impl<'de> Deserialize<'de> for SaveQueryParams
Source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
Source§impl JsonSchema for SaveQueryParams
impl JsonSchema for SaveQueryParams
Source§fn schema_id() -> Cow<'static, str>
fn schema_id() -> Cow<'static, str>
Returns a string that uniquely identifies the schema produced by this type. Read more
Source§fn json_schema(generator: &mut SchemaGenerator) -> Schema
fn json_schema(generator: &mut SchemaGenerator) -> Schema
Generates a JSON Schema for this type. Read more
Source§fn inline_schema() -> bool
fn inline_schema() -> bool
Whether JSON Schemas generated for this type should be included directly in parent schemas,
rather than being re-used where possible using the
$ref keyword. Read moreAuto Trait Implementations§
impl Freeze for SaveQueryParams
impl RefUnwindSafe for SaveQueryParams
impl Send for SaveQueryParams
impl Sync for SaveQueryParams
impl Unpin for SaveQueryParams
impl UnsafeUnpin for SaveQueryParams
impl UnwindSafe for SaveQueryParams
Blanket Implementations§
impl<T> Allocation for T
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more
impl<T> DeserializeOwned for Twhere
T: for<'de> Deserialize<'de>,
Source§impl<T> Instrument for T
impl<T> Instrument for T
Source§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
Source§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
Source§impl<T> IntoRequest<T> for T
impl<T> IntoRequest<T> for T
Source§fn into_request(self) -> Request<T>
fn into_request(self) -> Request<T>
Wrap the input message
T in a tonic::Request