/*
* CrowdStrike API Specification
*
* Use this API specification as a reference for the API endpoints you can use to interact with your Falcon environment. These endpoints support authentication via OAuth2 and interact with detections and network containment. For detailed usage guides and examples, see our [documentation inside the Falcon console](https://falcon.crowdstrike.com/support/documentation). To use the APIs described below, combine the base URL with the path shown for each API endpoint. For commercial cloud customers, your base URL is `https://api.crowdstrike.com`. Each API endpoint requires authorization via an OAuth2 token. Your first API request should retrieve an OAuth2 token using the `oauth2/token` endpoint, such as `https://api.crowdstrike.com/oauth2/token`. For subsequent requests, include the OAuth2 token in an HTTP authorization header. Tokens expire after 30 minutes, after which you should make a new token request to continue making API requests.
*
* The version of the OpenAPI document: rolling
*
* Generated by: https://openapi-generator.tech
*/
use crate::models;
#[derive(Clone, Default, Debug, PartialEq, Serialize, Deserialize)]
pub struct DomainCloudAwsAccountV1 {
#[serde(rename = "CreatedAt")]
pub created_at: String,
#[serde(rename = "DeletedAt")]
pub deleted_at: String,
#[serde(rename = "ID")]
pub id: i32,
#[serde(rename = "UpdatedAt")]
pub updated_at: String,
/// 12 digit AWS provided unique identifier for the account.
#[serde(rename = "account_id", skip_serializing_if = "Option::is_none")]
pub account_id: Option<String>,
/// AWS account name
#[serde(rename = "account_name", skip_serializing_if = "Option::is_none")]
pub account_name: Option<String>,
#[serde(rename = "account_type", skip_serializing_if = "Option::is_none")]
pub account_type: Option<String>,
#[serde(rename = "active_regions", skip_serializing_if = "Option::is_none")]
pub active_regions: Option<Vec<String>>,
#[serde(rename = "cid", skip_serializing_if = "Option::is_none")]
pub cid: Option<String>,
#[serde(
rename = "cloudformation_stack_arn",
skip_serializing_if = "Option::is_none"
)]
pub cloudformation_stack_arn: Option<String>,
#[serde(
rename = "cloudformation_update_url",
skip_serializing_if = "Option::is_none"
)]
pub cloudformation_update_url: Option<String>,
#[serde(rename = "cloudformation_url", skip_serializing_if = "Option::is_none")]
pub cloudformation_url: Option<String>,
#[serde(rename = "conditions", skip_serializing_if = "Option::is_none")]
pub conditions: Option<Vec<models::DomainCloudCondition>>,
/// csp live events are enabled
#[serde(rename = "csp_events", skip_serializing_if = "Option::is_none")]
pub csp_events: Option<bool>,
#[serde(rename = "environment", skip_serializing_if = "Option::is_none")]
pub environment: Option<String>,
#[serde(rename = "falcon_client_id", skip_serializing_if = "Option::is_none")]
pub falcon_client_id: Option<String>,
/// Permissions status for each product returned via API.
#[serde(rename = "iam_service_permissions_status")]
pub iam_service_permissions_status: Vec<models::DomainProductPermission>,
#[serde(rename = "inventory_filter")]
pub inventory_filter: Vec<models::DomainAwsInventoryFilterSetting>,
#[serde(rename = "is_custom_rolename")]
pub is_custom_rolename: bool,
#[serde(rename = "is_delegated_admin", skip_serializing_if = "Option::is_none")]
pub is_delegated_admin: Option<bool>,
#[serde(rename = "is_master", skip_serializing_if = "Option::is_none")]
pub is_master: Option<bool>,
/// Up to 34 character AWS provided unique identifier for the organization.
#[serde(rename = "organization_id", skip_serializing_if = "Option::is_none")]
pub organization_id: Option<String>,
#[serde(rename = "products")]
pub products: Vec<models::DomainProductFeatures>,
#[serde(
rename = "registration_status",
skip_serializing_if = "Option::is_none"
)]
pub registration_status: Option<String>,
#[serde(rename = "resource_metadata")]
pub resource_metadata: Box<models::DomainAwsAccountResourceMetadata>,
#[serde(
rename = "resource_name_prefix",
skip_serializing_if = "Option::is_none"
)]
pub resource_name_prefix: Option<String>,
#[serde(
rename = "resource_name_suffix",
skip_serializing_if = "Option::is_none"
)]
pub resource_name_suffix: Option<String>,
/// 12 digit AWS provided unique identifier for the root account (of the organization this account belongs to).
#[serde(rename = "root_account_id", skip_serializing_if = "Option::is_none")]
pub root_account_id: Option<String>,
#[serde(rename = "root_iam_role", skip_serializing_if = "Option::is_none")]
pub root_iam_role: Option<bool>,
#[serde(rename = "s3_url", skip_serializing_if = "Option::is_none")]
pub s3_url: Option<String>,
/// Account registration status for each product and feature
#[serde(rename = "status", skip_serializing_if = "Option::is_none")]
pub status: Option<Vec<models::DomainProductFeaturesStatus>>,
#[serde(rename = "target_ous", skip_serializing_if = "Option::is_none")]
pub target_ous: Option<Vec<String>>,
#[serde(
rename = "template_source_region",
skip_serializing_if = "Option::is_none"
)]
pub template_source_region: Option<String>,
#[serde(
rename = "use_existing_cloudtrail",
skip_serializing_if = "Option::is_none"
)]
pub use_existing_cloudtrail: Option<bool>,
}
impl DomainCloudAwsAccountV1 {
pub fn new(
created_at: String,
deleted_at: String,
id: i32,
updated_at: String,
iam_service_permissions_status: Vec<models::DomainProductPermission>,
inventory_filter: Vec<models::DomainAwsInventoryFilterSetting>,
is_custom_rolename: bool,
products: Vec<models::DomainProductFeatures>,
resource_metadata: models::DomainAwsAccountResourceMetadata,
) -> DomainCloudAwsAccountV1 {
DomainCloudAwsAccountV1 {
created_at,
deleted_at,
id,
updated_at,
account_id: None,
account_name: None,
account_type: None,
active_regions: None,
cid: None,
cloudformation_stack_arn: None,
cloudformation_update_url: None,
cloudformation_url: None,
conditions: None,
csp_events: None,
environment: None,
falcon_client_id: None,
iam_service_permissions_status,
inventory_filter,
is_custom_rolename,
is_delegated_admin: None,
is_master: None,
organization_id: None,
products,
registration_status: None,
resource_metadata: Box::new(resource_metadata),
resource_name_prefix: None,
resource_name_suffix: None,
root_account_id: None,
root_iam_role: None,
s3_url: None,
status: None,
target_ous: None,
template_source_region: None,
use_existing_cloudtrail: None,
}
}
}