/*
* Zernio API
*
* API reference for Zernio. Authenticate with a Bearer API key. Base URL: https://zernio.com/api Versioning and deprecation: all endpoints are versioned in the URL path (current version: /v1). Breaking changes only ship in a new path version; existing versions keep working. Deprecated operations are marked 'deprecated: true' in this spec and announced in the changelog (https://zernio.com/changelog) before removal. Errors: every 4xx/5xx response is application/json with a machine-readable 'code' and a human-readable 'error' message (see the ErrorResponse schema). Request ids: responses carry an X-Request-Id header with the id we log the request under. Quote it when reporting a problem. A valid x-request-id you send is reused as that id.
*
* The version of the OpenAPI document: 1.605.0
* Contact: support@zernio.com
* Generated by: https://openapi-generator.tech
*/
use crate::models;
use serde::{Deserialize, Serialize};
#[derive(Clone, Default, Debug, PartialEq, Serialize, Deserialize)]
pub struct UpdateOAuthAppRequest {
#[serde(rename = "label", skip_serializing_if = "Option::is_none")]
pub label: Option<String>,
#[serde(rename = "clientSecret", skip_serializing_if = "Option::is_none")]
pub client_secret: Option<String>,
/// Instagram only: the numeric ID of the Meta app your Instagram app lives in. Zernio uses it with `metaAppSecret` to register the webhook. Send both or neither.
#[serde(rename = "metaAppId", skip_serializing_if = "Option::is_none")]
pub meta_app_id: Option<String>,
/// Instagram only: the secret of that Meta app. Never returned.
#[serde(rename = "metaAppSecret", skip_serializing_if = "Option::is_none")]
pub meta_app_secret: Option<String>,
/// Slack only: saves or replaces the signing secret from the app's Basic Information page; any other platform is a 400.
#[serde(rename = "slackSigningSecret", skip_serializing_if = "Option::is_none")]
pub slack_signing_secret: Option<String>,
/// Replaces the areas new connects request. Accounts already connected keep what they were granted until they reconnect.
#[serde(rename = "scopeAreas", skip_serializing_if = "Option::is_none")]
pub scope_areas: Option<Vec<ScopeAreas>>,
}
impl UpdateOAuthAppRequest {
pub fn new() -> UpdateOAuthAppRequest {
UpdateOAuthAppRequest {
label: None,
client_secret: None,
meta_app_id: None,
meta_app_secret: None,
slack_signing_secret: None,
scope_areas: None,
}
}
}
/// Replaces the areas new connects request. Accounts already connected keep what they were granted until they reconnect.
#[derive(Clone, Copy, Debug, Eq, PartialEq, Ord, PartialOrd, Hash, Serialize, Deserialize)]
pub enum ScopeAreas {
#[serde(rename = "posting")]
Posting,
#[serde(rename = "analytics")]
Analytics,
#[serde(rename = "comments")]
Comments,
#[serde(rename = "messaging")]
Messaging,
}
impl Default for ScopeAreas {
fn default() -> ScopeAreas {
Self::Posting
}
}