pub struct ModelResponse {Show 22 fields
pub id: String,
pub object: String,
pub created_at: i64,
pub model: String,
pub output: Vec<ModelOutput>,
pub parallel_tool_calls: bool,
pub text: ModelResponseConfiguration,
pub tool_choice: ModelToolChoice,
pub tools: Vec<ModelTool>,
pub status: String,
pub store: bool,
pub metadata: Value,
pub usage: Option<ModelUsage>,
pub temperature: Option<f32>,
pub top_p: Option<f32>,
pub max_output_tokens: Option<i32>,
pub previous_response_id: Option<String>,
pub reasoning: Option<ReasoningConfiguration>,
pub user: Option<String>,
pub incomplete_details: Option<IncompleteDetails>,
pub background: Option<bool>,
pub debug_output: Option<DebugOutput>,
}Expand description
The response body for /v1/responses endpoint.
Fields§
§id: StringUnique ID of the response.
object: StringThe object type of this resource. Always set to response.
created_at: i64The Unix timestamp (in seconds) for the response creation time.
model: StringModel name used to generate the response.
output: Vec<ModelOutput>The response generated by the model.
parallel_tool_calls: boolWhether to allow the model to run parallel tool calls.
text: ModelResponseConfigurationSettings for customizing a text response from the model.
tool_choice: ModelToolChoiceControls which (if any) tool is called by the model.
tools: Vec<ModelTool>A list of tools the model may call.
status: StringStatus of the response. One of completed, in_progress or incomplete.
store: boolWhether to store the input message(s) and model response for later retrieval.
metadata: ValueOnly included for compatibility.
usage: Option<ModelUsage>Token usage information.
temperature: Option<f32>What sampling temperature to use, between 0 and 2.
top_p: Option<f32>An alternative to sampling with temperature, called nucleus sampling.
max_output_tokens: Option<i32>Max number of tokens that can be generated in a response.
previous_response_id: Option<String>The ID of the previous response from the model.
reasoning: Option<ReasoningConfiguration>Reasoning configuration. Only for reasoning models.
user: Option<String>A unique identifier representing your end-user.
incomplete_details: Option<IncompleteDetails>Details about why the response is incomplete.
background: Option<bool>Whether to process the response asynchronously in the background.
debug_output: Option<DebugOutput>Debug output. Only available to trusted testers.
Trait Implementations§
Source§impl Clone for ModelResponse
impl Clone for ModelResponse
Source§fn clone(&self) -> ModelResponse
fn clone(&self) -> ModelResponse
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read more