clerk-rs 0.4.2

The official community Rust SDK for the Clerk API
Documentation
/*
 * Clerk Backend API
 *
 * The Clerk REST Backend API, meant to be accessed by backend servers. Please see https://clerk.com/docs for more information.
 *
 * The version of the OpenAPI document: v1
 * Contact: support@clerk.com
 * Generated by: https://openapi-generator.tech
 */

#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)]
pub struct UpsertTemplateRequest {
	/// The user-friendly name of the template
	#[serde(rename = "name", skip_serializing_if = "Option::is_none")]
	pub name: Option<String>,
	/// The email subject. Applicable only to email templates.
	#[serde(rename = "subject", skip_serializing_if = "Option::is_none")]
	pub subject: Option<String>,
	/// The editor markup used to generate the body of the template
	#[serde(rename = "markup", skip_serializing_if = "Option::is_none")]
	pub markup: Option<String>,
	/// The template body before variable interpolation
	#[serde(rename = "body", skip_serializing_if = "Option::is_none")]
	pub body: Option<String>,
	/// Whether Clerk should deliver emails or SMS messages based on the current template
	#[serde(rename = "delivered_by_clerk", skip_serializing_if = "Option::is_none")]
	pub delivered_by_clerk: Option<bool>,
	/// The local part of the From email address that will be used for emails. For example, in the address 'hello@example.com', the local part is 'hello'. Applicable only to email templates.
	#[serde(rename = "from_email_name", skip_serializing_if = "Option::is_none")]
	pub from_email_name: Option<String>,
}

impl UpsertTemplateRequest {
	pub fn new() -> UpsertTemplateRequest {
		UpsertTemplateRequest {
			name: None,
			subject: None,
			markup: None,
			body: None,
			delivered_by_clerk: None,
			from_email_name: None,
		}
	}
}