Skip to main content

windmill_api/models/
path_flow.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.881.0
7 * Contact: contact@windmill.dev
8 * Generated by: https://openapi-generator.tech
9 */
10
11use crate::models;
12use serde::{Deserialize, Serialize};
13
14/// PathFlow : Reference to an existing flow by path. Use this to call another flow as a subflow
15#[derive(Clone, Default, Debug, PartialEq, Serialize, Deserialize)]
16pub struct PathFlow {
17    /// Map of parameter names to their values (static or JavaScript expressions). These become the subflow's input arguments
18    #[serde(rename = "input_transforms")]
19    pub input_transforms: std::collections::HashMap<String, models::InputTransform>,
20    /// Path to the flow in the workspace (e.g., 'f/flows/process_user')
21    #[serde(rename = "path")]
22    pub path: String,
23    /// Override the subflow's worker group tag. Its steps run on this tag unless the subflow sets preserve_step_tags
24    #[serde(rename = "tag_override", skip_serializing_if = "Option::is_none")]
25    pub tag_override: Option<String>,
26    #[serde(rename = "type")]
27    pub r#type: Type,
28}
29
30impl PathFlow {
31    /// Reference to an existing flow by path. Use this to call another flow as a subflow
32    pub fn new(input_transforms: std::collections::HashMap<String, models::InputTransform>, path: String, r#type: Type) -> PathFlow {
33        PathFlow {
34            input_transforms,
35            path,
36            tag_override: None,
37            r#type,
38        }
39    }
40}
41/// 
42#[derive(Clone, Copy, Debug, Eq, PartialEq, Ord, PartialOrd, Hash, Serialize, Deserialize)]
43pub enum Type {
44    #[serde(rename = "flow")]
45    Flow,
46}
47
48impl Default for Type {
49    fn default() -> Type {
50        Self::Flow
51    }
52}
53