/*
* 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.522.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 GetAutomationCatalog200Response {
/// JSON Schema of the body of `POST /v1/automations`.
#[serde(rename = "schema")]
pub schema: serde_json::Value,
#[serde(rename = "triggers")]
pub triggers: Vec<models::GetAutomationCatalog200ResponseTriggersInner>,
/// Ad rule subjects.
#[serde(rename = "subjects")]
pub subjects: Vec<models::GetAutomationCatalog200ResponseSubjectsInner>,
/// The fields and operators `subjects.filters` takes, and which fields each subject accepts.
#[serde(rename = "filters")]
pub filters: serde_json::Value,
/// What `subjects.groups` takes.
#[serde(rename = "groups")]
pub groups: serde_json::Value,
/// The most checks `alert.confirmChecks` can ask for.
#[serde(rename = "alert")]
pub alert: serde_json::Value,
/// Condition operators, windows, `compareTo` options and size limits.
#[serde(rename = "conditions")]
pub conditions: serde_json::Value,
#[serde(rename = "limits")]
pub limits: Vec<String>,
/// Where `approval.request` goes, how many approvers and how long it can wait.
#[serde(rename = "approval")]
pub approval: serde_json::Value,
}
impl GetAutomationCatalog200Response {
pub fn new(
schema: serde_json::Value,
triggers: Vec<models::GetAutomationCatalog200ResponseTriggersInner>,
subjects: Vec<models::GetAutomationCatalog200ResponseSubjectsInner>,
filters: serde_json::Value,
groups: serde_json::Value,
alert: serde_json::Value,
conditions: serde_json::Value,
limits: Vec<String>,
approval: serde_json::Value,
) -> GetAutomationCatalog200Response {
GetAutomationCatalog200Response {
schema,
triggers,
subjects,
filters,
groups,
alert,
conditions,
limits,
approval,
}
}
}