1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
/*
* public
*
* No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator)
*
* The version of the OpenAPI document: 1.105.3
*
* Generated by: https://openapi-generator.tech
*/
use crate::models;
use serde::{Deserialize, Serialize};
/// FulfillLicenseKeyRequest : Request body for manually fulfilling a pending license-key grant.
#[derive(Clone, Default, Debug, PartialEq, Serialize, Deserialize)]
pub struct FulfillLicenseKeyRequest {
/// Per-key activation limit. Defaults to the entitlement's license-key configuration.
#[serde(
rename = "activations_limit",
default,
with = "::serde_with::rust::double_option",
skip_serializing_if = "Option::is_none"
)]
pub activations_limit: Option<Option<i32>>,
/// When the key expires. Defaults to the duration in the entitlement's license-key configuration.
#[serde(
rename = "expires_at",
default,
with = "::serde_with::rust::double_option",
skip_serializing_if = "Option::is_none"
)]
pub expires_at: Option<Option<chrono::DateTime<chrono::FixedOffset>>>,
/// The license key value to deliver to the customer.
#[serde(rename = "key")]
pub key: String,
}
impl FulfillLicenseKeyRequest {
/// Request body for manually fulfilling a pending license-key grant.
pub fn new(key: String) -> FulfillLicenseKeyRequest {
FulfillLicenseKeyRequest {
activations_limit: None,
expires_at: None,
key,
}
}
}