vapi_client/models/
client_inbound_message_say.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 ClientInboundMessageSay {
16    /// This is the type of the message. Send \"say\" message to make the assistant say something.
17    #[serde(rename = "type", skip_serializing_if = "Option::is_none")]
18    pub r#type: Option<Type>,
19    /// This is the content to say.
20    #[serde(rename = "content", skip_serializing_if = "Option::is_none")]
21    pub content: Option<String>,
22    /// This is the flag to end call after content is spoken.
23    #[serde(rename = "endCallAfterSpoken", skip_serializing_if = "Option::is_none")]
24    pub end_call_after_spoken: Option<bool>,
25    /// This is the flag for whether the message is interruptible.
26    #[serde(rename = "interruptionsEnabled", skip_serializing_if = "Option::is_none")]
27    pub interruptions_enabled: Option<bool>,
28}
29
30impl ClientInboundMessageSay {
31    pub fn new() -> ClientInboundMessageSay {
32        ClientInboundMessageSay {
33            r#type: None,
34            content: None,
35            end_call_after_spoken: None,
36            interruptions_enabled: None,
37        }
38    }
39}
40/// This is the type of the message. Send \"say\" message to make the assistant say something.
41#[derive(Clone, Copy, Debug, Eq, PartialEq, Ord, PartialOrd, Hash, Serialize, Deserialize)]
42pub enum Type {
43    #[serde(rename = "say")]
44    Say,
45}
46
47impl Default for Type {
48    fn default() -> Type {
49        Self::Say
50    }
51}
52