clerk_rs/models/
create_jwt_template_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 CreateJwtTemplateRequest {
13	/// JWT template name
14	#[serde(rename = "name", skip_serializing_if = "Option::is_none")]
15	pub name: Option<String>,
16	/// JWT template claims in JSON format
17	#[serde(rename = "claims", skip_serializing_if = "Option::is_none")]
18	pub claims: Option<serde_json::Value>,
19	/// JWT token lifetime
20	#[serde(rename = "lifetime", skip_serializing_if = "Option::is_none")]
21	pub lifetime: Option<f32>,
22	/// JWT token allowed clock skew
23	#[serde(rename = "allowed_clock_skew", skip_serializing_if = "Option::is_none")]
24	pub allowed_clock_skew: Option<f32>,
25	/// Whether a custom signing key/algorithm is also provided for this template
26	#[serde(rename = "custom_signing_key", skip_serializing_if = "Option::is_none")]
27	pub custom_signing_key: Option<bool>,
28	/// The custom signing algorithm to use when minting JWTs
29	#[serde(rename = "signing_algorithm", skip_serializing_if = "Option::is_none")]
30	pub signing_algorithm: Option<String>,
31	/// The custom signing private key to use when minting JWTs
32	#[serde(rename = "signing_key", skip_serializing_if = "Option::is_none")]
33	pub signing_key: Option<String>,
34}
35
36impl CreateJwtTemplateRequest {
37	pub fn new() -> CreateJwtTemplateRequest {
38		CreateJwtTemplateRequest {
39			name: None,
40			claims: None,
41			lifetime: None,
42			allowed_clock_skew: None,
43			custom_signing_key: None,
44			signing_algorithm: None,
45			signing_key: None,
46		}
47	}
48}