vapi_client/models/
google_sheets_o_auth2_authorization_credential.rs1use crate::models;
12use serde::{Deserialize, Serialize};
13
14#[derive(Clone, Default, Debug, PartialEq, Serialize, Deserialize)]
15pub struct GoogleSheetsOAuth2AuthorizationCredential {
16 #[serde(rename = "provider")]
17 pub provider: Provider,
18 #[serde(rename = "authorizationId")]
20 pub authorization_id: String,
21 #[serde(rename = "id")]
23 pub id: String,
24 #[serde(rename = "orgId")]
26 pub org_id: String,
27 #[serde(rename = "createdAt")]
29 pub created_at: String,
30 #[serde(rename = "updatedAt")]
32 pub updated_at: String,
33 #[serde(rename = "name", skip_serializing_if = "Option::is_none")]
35 pub name: Option<String>,
36}
37
38impl GoogleSheetsOAuth2AuthorizationCredential {
39 pub fn new(provider: Provider, authorization_id: String, id: String, org_id: String, created_at: String, updated_at: String) -> GoogleSheetsOAuth2AuthorizationCredential {
40 GoogleSheetsOAuth2AuthorizationCredential {
41 provider,
42 authorization_id,
43 id,
44 org_id,
45 created_at,
46 updated_at,
47 name: None,
48 }
49 }
50}
51#[derive(Clone, Copy, Debug, Eq, PartialEq, Ord, PartialOrd, Hash, Serialize, Deserialize)]
53pub enum Provider {
54 #[serde(rename = "google.sheets.oauth2-authorization")]
55 GooglePeriodSheetsPeriodOauth2Authorization,
56}
57
58impl Default for Provider {
59 fn default() -> Provider {
60 Self::GooglePeriodSheetsPeriodOauth2Authorization
61 }
62}
63