vapi_client/models/
function_tool_provider_details.rs1use serde::{Deserialize, Serialize};
12use utoipa::ToSchema;
13
14
15use crate::models;
16
17#[derive(Clone, Default, Debug, PartialEq, Serialize, Deserialize, ToSchema)]
18pub struct FunctionToolProviderDetails {
19 #[serde(rename = "templateUrl", skip_serializing_if = "Option::is_none")]
21 pub template_url: Option<String>,
22 #[serde(rename = "setupInstructions", skip_serializing_if = "Option::is_none")]
23 pub setup_instructions: Option<Vec<models::ToolTemplateSetup>>,
24 #[serde(rename = "type")]
26 pub r#type: Type,
27}
28
29impl FunctionToolProviderDetails {
30 pub fn new(r#type: Type) -> FunctionToolProviderDetails {
31 FunctionToolProviderDetails {
32 template_url: None,
33 setup_instructions: None,
34 r#type,
35 }
36 }
37}
38#[derive(Clone, Copy, Debug, Eq, PartialEq, Ord, PartialOrd, Hash, Serialize, Deserialize, ToSchema)]
40pub enum Type {
41 #[serde(rename = "function")]
42 Function,
43}
44
45impl Default for Type {
46 fn default() -> Type {
47 Self::Function
48 }
49}