#[cfg(feature = "builders")]
use bon::Builder;
use serde::{Deserialize, Serialize};
use serde_json::Value;
#[non_exhaustive]
#[cfg_attr(feature = "builders", derive(Builder))]
#[derive(Clone, Debug, Default, Deserialize, Eq, PartialEq, Serialize)]
#[serde(rename_all = "camelCase")]
pub struct SignIn {
pub event_version: String,
pub user_identity: UserIdentity,
pub event_time: String,
pub event_source: String,
pub event_name: String,
pub aws_region: String,
#[serde(rename = "sourceIPAddress")]
pub source_ipaddress: String,
pub user_agent: String,
pub request_parameters: Value,
pub response_elements: ResponseElements,
pub additional_event_data: AdditionalEventData,
#[serde(rename = "eventID")]
pub event_id: String,
pub event_type: String,
#[cfg(feature = "catch-all-fields")]
#[cfg_attr(docsrs, doc(cfg(feature = "catch-all-fields")))]
#[serde(flatten)]
#[cfg_attr(feature = "builders", builder(default))]
pub other: serde_json::Map<String, Value>,
}
#[non_exhaustive]
#[cfg_attr(feature = "builders", derive(Builder))]
#[derive(Clone, Debug, Default, Deserialize, Eq, PartialEq, Serialize)]
#[serde(rename_all = "camelCase")]
pub struct UserIdentity {
pub r#type: String,
pub principal_id: String,
pub arn: String,
pub account_id: String,
#[cfg(feature = "catch-all-fields")]
#[cfg_attr(docsrs, doc(cfg(feature = "catch-all-fields")))]
#[serde(flatten)]
#[cfg_attr(feature = "builders", builder(default))]
pub other: serde_json::Map<String, Value>,
}
#[non_exhaustive]
#[cfg_attr(feature = "builders", derive(Builder))]
#[derive(Clone, Debug, Default, Deserialize, Eq, PartialEq, Serialize)]
#[serde(rename_all = "camelCase")]
pub struct ResponseElements {
#[serde(rename = "ConsoleLogin")]
pub console_login: String,
#[cfg(feature = "catch-all-fields")]
#[cfg_attr(docsrs, doc(cfg(feature = "catch-all-fields")))]
#[serde(flatten)]
#[cfg_attr(feature = "builders", builder(default))]
pub other: serde_json::Map<String, Value>,
}
#[non_exhaustive]
#[cfg_attr(feature = "builders", derive(Builder))]
#[derive(Clone, Debug, Default, Deserialize, Eq, PartialEq, Serialize)]
#[serde(rename_all = "camelCase")]
pub struct AdditionalEventData {
#[serde(rename = "LoginTo")]
pub login_to: String,
#[serde(rename = "MobileVersion")]
pub mobile_version: String,
#[serde(rename = "MFAUsed")]
pub mfaused: String,
#[cfg(feature = "catch-all-fields")]
#[cfg_attr(docsrs, doc(cfg(feature = "catch-all-fields")))]
#[serde(flatten)]
#[cfg_attr(feature = "builders", builder(default))]
pub other: serde_json::Map<String, Value>,
}