pub struct CreateFlexInput {
pub request_id: Uuid,
pub body: String,
pub model: String,
pub endpoint: String,
pub method: String,
pub path: String,
pub api_key: String,
pub created_by: String,
pub metadata: Option<Value>,
}Expand description
Input for creating a flex (async) response that the daemon will process.
Inserts a request template (no parent file) and a request row in pending
state with batch_id = NULL. The daemon claims and processes it like any
other pending request.
Fields§
§request_id: UuidPre-generated request ID. Becomes the request’s primary key.
body: StringThe request body as a JSON string.
model: StringModel identifier.
endpoint: StringBase URL of the target endpoint (e.g., “http://localhost:3001/ai”).
method: StringHTTP method (e.g., “POST”).
path: StringAPI path (e.g., “/v1/responses”).
api_key: StringAPI key for the request.
created_by: StringUser/org ID that owns this request.
metadata: Option<Value>Provenance for the dispatched request, stored on the template.
The batchless equivalent of BatchInput::metadata: keys named in the
daemon’s batch_metadata_fields are replayed onto the dispatched request
as x-fusillade-batch-<key> headers. A flex request is dispatched long
after the caller submitted it, over a client that sends no User-Agent, so
this is the only way anything about the submitter reaches the far side.
Trait Implementations§
Source§impl Clone for CreateFlexInput
impl Clone for CreateFlexInput
Source§fn clone(&self) -> CreateFlexInput
fn clone(&self) -> CreateFlexInput
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read more