#[non_exhaustive]pub struct MutationResponse {Show 13 fields
pub succeeded: bool,
pub state_changed: bool,
pub error_class: Option<MutationErrorClass>,
pub status_detail: Option<String>,
pub http_status: Option<i16>,
pub message: Option<String>,
pub entity_id: Option<Uuid>,
pub entity_type: Option<String>,
pub entity: Value,
pub updated_fields: Vec<String>,
pub cascade: Value,
pub error_detail: Value,
pub metadata: Value,
}Expand description
Typed app.mutation_response row.
Field types map 1:1 to the PostgreSQL composite columns. See
docs/architecture/mutation-response.md.
Fields (Non-exhaustive)§
This struct is marked as non-exhaustive
Struct { .. } syntax; cannot be matched against without a wildcard ..; and struct update syntax will not work.succeeded: boolTerminal outcome. true means the operation completed (including noops).
state_changed: boolDid the database actually change? Independent of succeeded.
error_class: Option<MutationErrorClass>NULL iff succeeded. Drives the cascade error code 1:1.
status_detail: Option<String>Human-readable subtype (e.g. "duplicate_email"); not parsed.
http_status: Option<i16>HTTP status, first-class. Validated to 100..=599 on ingest.
message: Option<String>Human-readable summary safe to show to end users.
entity_id: Option<Uuid>Primary key of the affected entity. Present for updates/deletes.
entity_type: Option<String>GraphQL type name (e.g. "User"). Used for cache invalidation.
entity: ValueFull entity payload. Populated even for noops.
updated_fields: Vec<String>GraphQL field names that changed. Empty on noop.
cascade: ValueCascade operations (see the graphql-cascade specification).
error_detail: ValueStructured error payload only (field / constraint / severity).
metadata: ValueObservability only (trace IDs, timings, audit extras).
Trait Implementations§
Source§impl Clone for MutationResponse
impl Clone for MutationResponse
Source§fn clone(&self) -> MutationResponse
fn clone(&self) -> MutationResponse
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read more