Skip to main content

windmill_api/models/
edit_variable_expiration_handler.rs

1/*
2 * Windmill API
3 *
4 * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator)
5 *
6 * The version of the OpenAPI document: 1.848.2
7 * Contact: contact@windmill.dev
8 * Generated by: https://openapi-generator.tech
9 */
10
11use crate::models;
12use serde::{Deserialize, Serialize};
13
14/// EditVariableExpirationHandler : Request body for editing the workspace variable expiration handler. Omit `path` (or send null) to unset the handler. 
15#[derive(Clone, Default, Debug, PartialEq, Serialize, Deserialize)]
16pub struct EditVariableExpirationHandler {
17    /// Path to the variable expiration handler script or flow
18    #[serde(rename = "path", default, with = "::serde_with::rust::double_option", skip_serializing_if = "Option::is_none")]
19    pub path: Option<Option<String>>,
20    /// The arguments to pass to the script or flow
21    #[serde(rename = "extra_args", skip_serializing_if = "Option::is_none")]
22    pub extra_args: Option<std::collections::HashMap<String, serde_json::Value>>,
23    /// Do not run the handler for variables on a personal (u/) path
24    #[serde(rename = "muted_on_user_path", skip_serializing_if = "Option::is_none")]
25    pub muted_on_user_path: Option<bool>,
26    /// How long before a variable's value expires the handler runs. 1 day when omitted.
27    #[serde(rename = "notify_before_secs", skip_serializing_if = "Option::is_none")]
28    pub notify_before_secs: Option<i32>,
29    /// Run the handler again at this interval until the value expires. No reminders when omitted or 0.
30    #[serde(rename = "remind_every_secs", skip_serializing_if = "Option::is_none")]
31    pub remind_every_secs: Option<i32>,
32}
33
34impl EditVariableExpirationHandler {
35    /// Request body for editing the workspace variable expiration handler. Omit `path` (or send null) to unset the handler. 
36    pub fn new() -> EditVariableExpirationHandler {
37        EditVariableExpirationHandler {
38            path: None,
39            extra_args: None,
40            muted_on_user_path: None,
41            notify_before_secs: None,
42            remind_every_secs: None,
43        }
44    }
45}
46