vapi_client/models/
create_azure_credential_dto.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 CreateAzureCredentialDto {
16    #[serde(rename = "provider")]
17    pub provider: Provider,
18    /// This is the service being used in Azure.
19    #[serde(rename = "service")]
20    pub service: Service,
21    /// This is the region of the Azure resource.
22    #[serde(rename = "region", skip_serializing_if = "Option::is_none")]
23    pub region: Option<Region>,
24    /// This is not returned in the API.
25    #[serde(rename = "apiKey", skip_serializing_if = "Option::is_none")]
26    pub api_key: Option<String>,
27    /// This is the bucket plan that can be provided to store call artifacts in Azure Blob Storage.
28    #[serde(rename = "bucketPlan", skip_serializing_if = "Option::is_none")]
29    pub bucket_plan: Option<Box<models::AzureBlobStorageBucketPlan>>,
30    /// This is the name of credential. This is just for your reference.
31    #[serde(rename = "name", skip_serializing_if = "Option::is_none")]
32    pub name: Option<String>,
33}
34
35impl CreateAzureCredentialDto {
36    pub fn new(provider: Provider, service: Service) -> CreateAzureCredentialDto {
37        CreateAzureCredentialDto {
38            provider,
39            service,
40            region: None,
41            api_key: None,
42            bucket_plan: None,
43            name: None,
44        }
45    }
46}
47/// 
48#[derive(Clone, Copy, Debug, Eq, PartialEq, Ord, PartialOrd, Hash, Serialize, Deserialize)]
49pub enum Provider {
50    #[serde(rename = "azure")]
51    Azure,
52}
53
54impl Default for Provider {
55    fn default() -> Provider {
56        Self::Azure
57    }
58}
59/// This is the service being used in Azure.
60#[derive(Clone, Copy, Debug, Eq, PartialEq, Ord, PartialOrd, Hash, Serialize, Deserialize)]
61pub enum Service {
62    #[serde(rename = "speech")]
63    Speech,
64    #[serde(rename = "blob_storage")]
65    BlobStorage,
66}
67
68impl Default for Service {
69    fn default() -> Service {
70        Self::Speech
71    }
72}
73/// This is the region of the Azure resource.
74#[derive(Clone, Copy, Debug, Eq, PartialEq, Ord, PartialOrd, Hash, Serialize, Deserialize)]
75pub enum Region {
76    #[serde(rename = "australia")]
77    Australia,
78    #[serde(rename = "canadaeast")]
79    Canadaeast,
80    #[serde(rename = "canadacentral")]
81    Canadacentral,
82    #[serde(rename = "eastus2")]
83    Eastus2,
84    #[serde(rename = "eastus")]
85    Eastus,
86    #[serde(rename = "france")]
87    France,
88    #[serde(rename = "india")]
89    India,
90    #[serde(rename = "japaneast")]
91    Japaneast,
92    #[serde(rename = "japanwest")]
93    Japanwest,
94    #[serde(rename = "uaenorth")]
95    Uaenorth,
96    #[serde(rename = "northcentralus")]
97    Northcentralus,
98    #[serde(rename = "norway")]
99    Norway,
100    #[serde(rename = "southcentralus")]
101    Southcentralus,
102    #[serde(rename = "swedencentral")]
103    Swedencentral,
104    #[serde(rename = "switzerland")]
105    Switzerland,
106    #[serde(rename = "uk")]
107    Uk,
108    #[serde(rename = "westus")]
109    Westus,
110    #[serde(rename = "westus3")]
111    Westus3,
112}
113
114impl Default for Region {
115    fn default() -> Region {
116        Self::Australia
117    }
118}
119