use serde::{Deserialize, Serialize}; /*
                                      * Service Control API
                                      *
                                      * Provides admission control and telemetry reporting for services integrated with Service Infrastructure.
                                      *
                                      * The version of the OpenAPI document: v1
                                      *
                                      * Generated by: https://openapi-generator.tech
                                      */

use crate::google_rest_apis::servicecontrol_v1::models;

/// CheckRequest : Request message for the Check method.
#[derive(Clone, Default, Debug, PartialEq, Serialize, Deserialize)]
pub struct CheckRequest {
    #[serde(rename = "operation", skip_serializing_if = "Option::is_none")]
    pub operation: Option<Box<models::Operation>>,
    /// Requests the project settings to be returned as part of the check response.
    #[serde(
        rename = "requestProjectSettings",
        skip_serializing_if = "Option::is_none"
    )]
    pub request_project_settings: Option<bool>,
    /// Specifies which version of service configuration should be used to process the request. If unspecified or no matching version can be found, the latest one will be used.
    #[serde(rename = "serviceConfigId", skip_serializing_if = "Option::is_none")]
    pub service_config_id: Option<String>,
    /// Indicates if service activation check should be skipped for this request. Default behavior is to perform the check and apply relevant quota. WARNING: Setting this flag to \"true\" will disable quota enforcement.
    #[serde(
        rename = "skipActivationCheck",
        skip_serializing_if = "Option::is_none"
    )]
    pub skip_activation_check: Option<bool>,
}

impl CheckRequest {
    /// Request message for the Check method.
    pub fn new() -> CheckRequest {
        CheckRequest {
            operation: None,
            request_project_settings: None,
            service_config_id: None,
            skip_activation_check: None,
        }
    }
}
