bitwarden-api-api 3.0.0

Api bindings for the Bitwarden API.
Documentation
/*
 * Bitwarden Internal API
 *
 * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator)
 *
 * The version of the OpenAPI document: latest
 *
 * Generated by: https://openapi-generator.tech
 */

use serde::{Deserialize, Serialize};

use crate::models;

#[derive(Clone, Default, Debug, PartialEq, Serialize, Deserialize)]
pub struct RotateUserKeysRequestModel {
    #[serde(
        rename = "wrappedAccountCryptographicState",
        alias = "WrappedAccountCryptographicState"
    )]
    pub wrapped_account_cryptographic_state:
        Box<models::WrappedAccountCryptographicStateRequestModel>,
    #[serde(rename = "unlockData", alias = "UnlockData")]
    pub unlock_data: Box<models::CommonUnlockDataRequestModel>,
    #[serde(rename = "accountData", alias = "AccountData")]
    pub account_data: Box<models::AccountDataRequestModel>,
    #[serde(rename = "unlockMethodData", alias = "UnlockMethodData")]
    pub unlock_method_data: Box<models::UnlockMethodRequestModel>,
}

impl RotateUserKeysRequestModel {
    pub fn new(
        wrapped_account_cryptographic_state: models::WrappedAccountCryptographicStateRequestModel,
        unlock_data: models::CommonUnlockDataRequestModel,
        account_data: models::AccountDataRequestModel,
        unlock_method_data: models::UnlockMethodRequestModel,
    ) -> RotateUserKeysRequestModel {
        RotateUserKeysRequestModel {
            wrapped_account_cryptographic_state: Box::new(wrapped_account_cryptographic_state),
            unlock_data: Box::new(unlock_data),
            account_data: Box::new(account_data),
            unlock_method_data: Box::new(unlock_method_data),
        }
    }
}