1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
/*
* Vapi API
*
* Voice AI for developers.
*
* The version of the OpenAPI document: 1.0
*
* Generated by: https://openapi-generator.tech
*/
use crate::models;
use serde::{Deserialize, Serialize};
#[derive(Clone, Default, Debug, PartialEq, Serialize, Deserialize)]
pub struct ClientInboundMessageControl {
/// This is the type of the message. Send \"control\" message to control the assistant. `control` options are: - \"mute-assistant\" - mute the assistant - \"unmute-assistant\" - unmute the assistant - \"say-first-message\" - say the first message (this is used when video recording is enabled and the conversation is only started once the client side kicks off the recording)
#[serde(rename = "type")]
pub r#type: TypeTrue,
/// This is the control action
#[serde(rename = "control")]
pub control: ControlTrue,
}
impl ClientInboundMessageControl {
pub fn new(r#type: TypeTrue, control: ControlTrue) -> ClientInboundMessageControl {
ClientInboundMessageControl { r#type, control }
}
}
/// This is the type of the message. Send \"control\" message to control the assistant. `control` options are: - \"mute-assistant\" - mute the assistant - \"unmute-assistant\" - unmute the assistant - \"say-first-message\" - say the first message (this is used when video recording is enabled and the conversation is only started once the client side kicks off the recording)
#[derive(Clone, Copy, Debug, Eq, PartialEq, Ord, PartialOrd, Hash, Serialize, Deserialize)]
pub enum TypeTrue {
#[serde(rename = "control")]
Control,
}
impl Default for TypeTrue {
fn default() -> TypeTrue {
Self::Control
}
}
/// This is the control action
#[derive(Clone, Copy, Debug, Eq, PartialEq, Ord, PartialOrd, Hash, Serialize, Deserialize)]
pub enum ControlTrue {
#[serde(rename = "mute-assistant")]
MuteAssistant,
#[serde(rename = "unmute-assistant")]
UnmuteAssistant,
#[serde(rename = "say-first-message")]
SayFirstMessage,
}
impl Default for ControlTrue {
fn default() -> ControlTrue {
Self::MuteAssistant
}
}