/*
* 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).
*
* The version of the OpenAPI document: 1.71.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 ValidatePhoneNumberKycAddressRequest {
/// ISO 3166-1 alpha-2 country code.
#[serde(rename = "country")]
pub country: String,
#[serde(rename = "street_address")]
pub street_address: String,
/// Address complement: apartment, suite, unit, or the quadra/lote used in some countries. Optional. Does not substitute for a building number on street_address.
#[serde(rename = "extended_address", skip_serializing_if = "Option::is_none")]
pub extended_address: Option<String>,
/// City / town.
#[serde(rename = "locality")]
pub locality: String,
/// State / province / region. When omitted, the pre-check is skipped (the final submit still validates).
#[serde(
rename = "administrative_area",
skip_serializing_if = "Option::is_none"
)]
pub administrative_area: Option<String>,
#[serde(rename = "postal_code")]
pub postal_code: String,
}
impl ValidatePhoneNumberKycAddressRequest {
pub fn new(
country: String,
street_address: String,
locality: String,
postal_code: String,
) -> ValidatePhoneNumberKycAddressRequest {
ValidatePhoneNumberKycAddressRequest {
country,
street_address,
extended_address: None,
locality,
administrative_area: None,
postal_code,
}
}
}