clerk_rs/models/
create_email_request.rs

1/*
2 * Clerk Backend API
3 *
4 * The Clerk REST Backend API, meant to be accessed by backend servers. Please see https://clerk.com/docs for more information.
5 *
6 * The version of the OpenAPI document: v1
7 * Contact: support@clerk.com
8 * Generated by: https://openapi-generator.tech
9 */
10
11#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)]
12pub struct CreateEmailRequest {
13	/// The email name portion of the sending email address. <br/>e.g.: `from_email_name=info` will send from info@example.com
14	#[serde(rename = "from_email_name", skip_serializing_if = "Option::is_none")]
15	pub from_email_name: Option<String>,
16	/// The subject of the email.
17	#[serde(rename = "subject", skip_serializing_if = "Option::is_none")]
18	pub subject: Option<String>,
19	/// The body of the email.
20	#[serde(rename = "body", skip_serializing_if = "Option::is_none")]
21	pub body: Option<String>,
22	/// The ID of the email address to send to.
23	#[serde(
24		rename = "email_address_id",
25		default,
26		with = "::serde_with::rust::double_option",
27		skip_serializing_if = "Option::is_none"
28	)]
29	pub email_address_id: Option<Option<String>>,
30}
31
32impl CreateEmailRequest {
33	pub fn new() -> CreateEmailRequest {
34		CreateEmailRequest {
35			from_email_name: None,
36			subject: None,
37			body: None,
38			email_address_id: None,
39		}
40	}
41}