1. Packages
  2. Formal Provider
  3. API Docs
  4. Workflow
Formal v1.1.0 published on Sunday, Mar 1, 2026 by Formal
formal logo
Formal v1.1.0 published on Sunday, Mar 1, 2026 by Formal

    Workflows enable automation of actions based on triggers. A workflow is defined using YAML code that specifies a trigger (what starts the workflow) and actions (what the workflow does).

    Create Workflow Resource

    Resources are created with functions called constructors. To learn more about declaring and configuring resources, see Resources.

    Constructor syntax

    new Workflow(name: string, args: WorkflowArgs, opts?: CustomResourceOptions);
    @overload
    def Workflow(resource_name: str,
                 args: WorkflowArgs,
                 opts: Optional[ResourceOptions] = None)
    
    @overload
    def Workflow(resource_name: str,
                 opts: Optional[ResourceOptions] = None,
                 code: Optional[str] = None,
                 name: Optional[str] = None,
                 status: Optional[str] = None)
    func NewWorkflow(ctx *Context, name string, args WorkflowArgs, opts ...ResourceOption) (*Workflow, error)
    public Workflow(string name, WorkflowArgs args, CustomResourceOptions? opts = null)
    public Workflow(String name, WorkflowArgs args)
    public Workflow(String name, WorkflowArgs args, CustomResourceOptions options)
    
    type: formal:Workflow
    properties: # The arguments to resource properties.
    options: # Bag of options to control resource's behavior.
    
    

    Parameters

    name string
    The unique name of the resource.
    args WorkflowArgs
    The arguments to resource properties.
    opts CustomResourceOptions
    Bag of options to control resource's behavior.
    resource_name str
    The unique name of the resource.
    args WorkflowArgs
    The arguments to resource properties.
    opts ResourceOptions
    Bag of options to control resource's behavior.
    ctx Context
    Context object for the current deployment.
    name string
    The unique name of the resource.
    args WorkflowArgs
    The arguments to resource properties.
    opts ResourceOption
    Bag of options to control resource's behavior.
    name string
    The unique name of the resource.
    args WorkflowArgs
    The arguments to resource properties.
    opts CustomResourceOptions
    Bag of options to control resource's behavior.
    name String
    The unique name of the resource.
    args WorkflowArgs
    The arguments to resource properties.
    options CustomResourceOptions
    Bag of options to control resource's behavior.

    Constructor example

    The following reference example uses placeholder values for all input properties.

    var workflowResource = new Pulumi.Workflow("workflowResource", new()
    {
        Code = "string",
        Name = "string",
        Status = "string",
    });
    
    example, err := formal.NewWorkflow(ctx, "workflowResource", &formal.WorkflowArgs{
    	Code:   pulumi.String("string"),
    	Name:   pulumi.String("string"),
    	Status: pulumi.String("string"),
    })
    
    var workflowResource = new Workflow("workflowResource", WorkflowArgs.builder()
        .code("string")
        .name("string")
        .status("string")
        .build());
    
    workflow_resource = formal.Workflow("workflowResource",
        code="string",
        name="string",
        status="string")
    
    const workflowResource = new formal.Workflow("workflowResource", {
        code: "string",
        name: "string",
        status: "string",
    });
    
    type: formal:Workflow
    properties:
        code: string
        name: string
        status: string
    

    Workflow Resource Properties

    To learn more about resource properties and how to use them, see Inputs and Outputs in the Architecture and Concepts docs.

    Inputs

    In Python, inputs that are objects can be passed either as argument classes or as dictionary literals.

    The Workflow resource accepts the following input properties:

    Code string
    The workflow definition in YAML format. Defines the trigger and actions for the workflow.
    Name string
    The name of the workflow. Must be unique within the organization.
    Status string
    The workflow status. Accepted values are active and draft.
    Code string
    The workflow definition in YAML format. Defines the trigger and actions for the workflow.
    Name string
    The name of the workflow. Must be unique within the organization.
    Status string
    The workflow status. Accepted values are active and draft.
    code String
    The workflow definition in YAML format. Defines the trigger and actions for the workflow.
    name String
    The name of the workflow. Must be unique within the organization.
    status String
    The workflow status. Accepted values are active and draft.
    code string
    The workflow definition in YAML format. Defines the trigger and actions for the workflow.
    name string
    The name of the workflow. Must be unique within the organization.
    status string
    The workflow status. Accepted values are active and draft.
    code str
    The workflow definition in YAML format. Defines the trigger and actions for the workflow.
    name str
    The name of the workflow. Must be unique within the organization.
    status str
    The workflow status. Accepted values are active and draft.
    code String
    The workflow definition in YAML format. Defines the trigger and actions for the workflow.
    name String
    The name of the workflow. Must be unique within the organization.
    status String
    The workflow status. Accepted values are active and draft.

    Outputs

    All input properties are implicitly available as output properties. Additionally, the Workflow resource produces the following output properties:

    Id string
    The provider-assigned unique ID for this managed resource.
    Id string
    The provider-assigned unique ID for this managed resource.
    id String
    The provider-assigned unique ID for this managed resource.
    id string
    The provider-assigned unique ID for this managed resource.
    id str
    The provider-assigned unique ID for this managed resource.
    id String
    The provider-assigned unique ID for this managed resource.

    Look up Existing Workflow Resource

    Get an existing Workflow resource’s state with the given name, ID, and optional extra properties used to qualify the lookup.

    public static get(name: string, id: Input<ID>, state?: WorkflowState, opts?: CustomResourceOptions): Workflow
    @staticmethod
    def get(resource_name: str,
            id: str,
            opts: Optional[ResourceOptions] = None,
            code: Optional[str] = None,
            name: Optional[str] = None,
            status: Optional[str] = None) -> Workflow
    func GetWorkflow(ctx *Context, name string, id IDInput, state *WorkflowState, opts ...ResourceOption) (*Workflow, error)
    public static Workflow Get(string name, Input<string> id, WorkflowState? state, CustomResourceOptions? opts = null)
    public static Workflow get(String name, Output<String> id, WorkflowState state, CustomResourceOptions options)
    resources:  _:    type: formal:Workflow    get:      id: ${id}
    name
    The unique name of the resulting resource.
    id
    The unique provider ID of the resource to lookup.
    state
    Any extra arguments used during the lookup.
    opts
    A bag of options that control this resource's behavior.
    resource_name
    The unique name of the resulting resource.
    id
    The unique provider ID of the resource to lookup.
    name
    The unique name of the resulting resource.
    id
    The unique provider ID of the resource to lookup.
    state
    Any extra arguments used during the lookup.
    opts
    A bag of options that control this resource's behavior.
    name
    The unique name of the resulting resource.
    id
    The unique provider ID of the resource to lookup.
    state
    Any extra arguments used during the lookup.
    opts
    A bag of options that control this resource's behavior.
    name
    The unique name of the resulting resource.
    id
    The unique provider ID of the resource to lookup.
    state
    Any extra arguments used during the lookup.
    opts
    A bag of options that control this resource's behavior.
    The following state arguments are supported:
    Code string
    The workflow definition in YAML format. Defines the trigger and actions for the workflow.
    Name string
    The name of the workflow. Must be unique within the organization.
    Status string
    The workflow status. Accepted values are active and draft.
    Code string
    The workflow definition in YAML format. Defines the trigger and actions for the workflow.
    Name string
    The name of the workflow. Must be unique within the organization.
    Status string
    The workflow status. Accepted values are active and draft.
    code String
    The workflow definition in YAML format. Defines the trigger and actions for the workflow.
    name String
    The name of the workflow. Must be unique within the organization.
    status String
    The workflow status. Accepted values are active and draft.
    code string
    The workflow definition in YAML format. Defines the trigger and actions for the workflow.
    name string
    The name of the workflow. Must be unique within the organization.
    status string
    The workflow status. Accepted values are active and draft.
    code str
    The workflow definition in YAML format. Defines the trigger and actions for the workflow.
    name str
    The name of the workflow. Must be unique within the organization.
    status str
    The workflow status. Accepted values are active and draft.
    code String
    The workflow definition in YAML format. Defines the trigger and actions for the workflow.
    name String
    The name of the workflow. Must be unique within the organization.
    status String
    The workflow status. Accepted values are active and draft.

    Package Details

    Repository
    formal formalco/pulumi-formal
    License
    MPL-2.0
    Notes
    This Pulumi package is based on the formal Terraform Provider.
    formal logo
    Formal v1.1.0 published on Sunday, Mar 1, 2026 by Formal
      Meet Neo: Your AI Platform Teammate