/*
* 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.104.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 WebhookPayloadCommentCommentAuthor {
/// Author's platform ID
#[serde(rename = "id")]
pub id: String,
#[serde(rename = "username", skip_serializing_if = "Option::is_none")]
pub username: Option<String>,
#[serde(rename = "name", skip_serializing_if = "Option::is_none")]
pub name: Option<String>,
#[serde(
rename = "picture",
default,
with = "::serde_with::rust::double_option",
skip_serializing_if = "Option::is_none"
)]
pub picture: Option<Option<String>>,
/// True when this comment was authored by the connected account itself. Populated on the Instagram and Facebook realtime webhooks (Meta re-delivers the account's own replies as comments events) and on TikTok, where it is inferred: comments created through this API are always flagged, and once the account's own author identifier is known (from one of those or from a comments listing) every author is compared against it. Absent means not evaluated, never \"not the account\".
#[serde(rename = "isOwnAccount", skip_serializing_if = "Option::is_none")]
pub is_own_account: Option<bool>,
#[serde(rename = "instagramProfile", skip_serializing_if = "Option::is_none")]
pub instagram_profile: Option<Box<models::WebhookPayloadCommentCommentAuthorInstagramProfile>>,
}
impl WebhookPayloadCommentCommentAuthor {
pub fn new(id: String) -> WebhookPayloadCommentCommentAuthor {
WebhookPayloadCommentCommentAuthor {
id,
username: None,
name: None,
picture: None,
is_own_account: None,
instagram_profile: None,
}
}
}