clerk_rs/models/
update_instance_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 UpdateInstanceRequest {
13	/// Toggles test mode for this instance, allowing the use of test email addresses and phone numbers. Defaults to true for development instances.
14	#[serde(
15		rename = "test_mode",
16		default,
17		with = "::serde_with::rust::double_option",
18		skip_serializing_if = "Option::is_none"
19	)]
20	pub test_mode: Option<Option<bool>>,
21	/// Whether the instance should be using the HIBP service to check passwords for breaches
22	#[serde(
23		rename = "hibp",
24		default,
25		with = "::serde_with::rust::double_option",
26		skip_serializing_if = "Option::is_none"
27	)]
28	pub hibp: Option<Option<bool>>,
29	/// The \"enhanced_email_deliverability\" feature will send emails from \"verifications@clerk.dev\" instead of your domain. This can be helpful if you do not have a high domain reputation.
30	#[serde(
31		rename = "enhanced_email_deliverability",
32		default,
33		with = "::serde_with::rust::double_option",
34		skip_serializing_if = "Option::is_none"
35	)]
36	pub enhanced_email_deliverability: Option<Option<bool>>,
37	#[serde(
38		rename = "support_email",
39		default,
40		with = "::serde_with::rust::double_option",
41		skip_serializing_if = "Option::is_none"
42	)]
43	pub support_email: Option<Option<String>>,
44	#[serde(
45		rename = "clerk_js_version",
46		default,
47		with = "::serde_with::rust::double_option",
48		skip_serializing_if = "Option::is_none"
49	)]
50	pub clerk_js_version: Option<Option<String>>,
51	#[serde(
52		rename = "development_origin",
53		default,
54		with = "::serde_with::rust::double_option",
55		skip_serializing_if = "Option::is_none"
56	)]
57	pub development_origin: Option<Option<String>>,
58	/// For browser-like stacks such as browser extensions, Electron, or Capacitor.js the instance allowed origins need to be updated with the request origin value. For Chrome extensions popup, background, or service worker pages the origin is chrome-extension://extension_uiid. For Electron apps the default origin is http://localhost:3000. For Capacitor, the origin is capacitor://localhost.
59	#[serde(rename = "allowed_origins", skip_serializing_if = "Option::is_none")]
60	pub allowed_origins: Option<Vec<String>>,
61	/// Whether the instance should operate in cookieless development mode (i.e. without third-party cookies). Deprecated: Please use `url_based_session_syncing` instead.
62	#[serde(rename = "cookieless_dev", skip_serializing_if = "Option::is_none")]
63	pub cookieless_dev: Option<bool>,
64	/// Whether the instance should use URL-based session syncing in development mode (i.e. without third-party cookies).
65	#[serde(rename = "url_based_session_syncing", skip_serializing_if = "Option::is_none")]
66	pub url_based_session_syncing: Option<bool>,
67}
68
69impl UpdateInstanceRequest {
70	pub fn new() -> UpdateInstanceRequest {
71		UpdateInstanceRequest {
72			test_mode: None,
73			hibp: None,
74			enhanced_email_deliverability: None,
75			support_email: None,
76			clerk_js_version: None,
77			development_origin: None,
78			allowed_origins: None,
79			cookieless_dev: None,
80			url_based_session_syncing: None,
81		}
82	}
83}