vapi_client/models/
make_tool_provider_details.rs

1/*
2 * Vapi API
3 *
4 * API for building voice assistants
5 *
6 * The version of the OpenAPI document: 1.0
7 *
8 * Generated by: https://openapi-generator.tech
9 */
10
11use serde::{Deserialize, Serialize};
12
13use crate::models;
14
15#[derive(Clone, Default, Debug, PartialEq, Serialize, Deserialize)]
16pub struct MakeToolProviderDetails {
17    /// This is the Template URL or the Snapshot URL corresponding to the Template.
18    #[serde(rename = "templateUrl", skip_serializing_if = "Option::is_none")]
19    pub template_url: Option<String>,
20    #[serde(rename = "setupInstructions", skip_serializing_if = "Option::is_none")]
21    pub setup_instructions: Option<Vec<models::ToolTemplateSetup>>,
22    /// The type of tool. \"make\" for Make tool.
23    #[serde(rename = "type")]
24    pub r#type: Type,
25    #[serde(rename = "scenarioId", skip_serializing_if = "Option::is_none")]
26    pub scenario_id: Option<f64>,
27    #[serde(rename = "scenarioName", skip_serializing_if = "Option::is_none")]
28    pub scenario_name: Option<String>,
29    #[serde(rename = "triggerHookId", skip_serializing_if = "Option::is_none")]
30    pub trigger_hook_id: Option<f64>,
31    #[serde(rename = "triggerHookName", skip_serializing_if = "Option::is_none")]
32    pub trigger_hook_name: Option<String>,
33}
34
35impl MakeToolProviderDetails {
36    pub fn new(r#type: Type) -> MakeToolProviderDetails {
37        MakeToolProviderDetails {
38            template_url: None,
39            setup_instructions: None,
40            r#type,
41            scenario_id: None,
42            scenario_name: None,
43            trigger_hook_id: None,
44            trigger_hook_name: None,
45        }
46    }
47}
48/// The type of tool. \"make\" for Make tool.
49#[derive(Clone, Copy, Debug, Eq, PartialEq, Ord, PartialOrd, Hash, Serialize, Deserialize)]
50pub enum Type {
51    #[serde(rename = "make")]
52    Make,
53}
54
55impl Default for Type {
56    fn default() -> Type {
57        Self::Make
58    }
59}