vapi_client/models/
create_chat_stream_response.rs

1/*
2 * Vapi API
3 *
4 * Voice AI for developers.
5 *
6 * The version of the OpenAPI document: 1.0
7 *
8 * Generated by: https://openapi-generator.tech
9 */
10
11use crate::models;
12use serde::{Deserialize, Serialize};
13
14#[derive(Clone, Default, Debug, PartialEq, Serialize, Deserialize)]
15pub struct CreateChatStreamResponse {
16    /// This is the unique identifier for the streaming response.
17    #[serde(rename = "id")]
18    pub id: String,
19    /// This is the path to the content being updated. Format: `chat.output[{contentIndex}].content` where contentIndex identifies the specific content item.
20    #[serde(rename = "path")]
21    pub path: String,
22    /// This is the incremental content chunk being streamed.
23    #[serde(rename = "delta")]
24    pub delta: String,
25}
26
27impl CreateChatStreamResponse {
28    pub fn new(id: String, path: String, delta: String) -> CreateChatStreamResponse {
29        CreateChatStreamResponse { id, path, delta }
30    }
31}