> ## Documentation Index
> Fetch the complete documentation index at: https://docs.blinkops.com/llms.txt
> Use this file to discover all available pages before exploring further.

# Create A Run

A run performs a plan and apply, using a configuration version and the workspace’s current variables. You can specify a configuration version when creating a run; if you don’t provide one, the run defaults to the workspace’s most recently used version. (A configuration version is “used” when it is created or used for a run in this workspace).

<Note>
  External Documentation

  To learn more, visit the [Terraform Cloud documentation](https://developer.hashicorp.com/terraform/cloud-docs/api-docs/run#create-a-run).
</Note>

## Parameters

<div className="integrations-table">
  | Parameter                | Description                                                                                                                                                                                                                                         |
  | ------------------------ | --------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
  | Allow Empty Apply        | Specifies whether Terraform can apply the run even when the plan contains no changes. Often used to upgrade state after upgrading a workspace to a new terraform version.                                                                           |
  | Auto Apply               | Whether to automatically apply changes when a Terraform plan is successful.                                                                                                                                                                         |
  | Configuration Version ID | Specifies the configuration version to use for this run. If the configuration-version object is omitted (left empty), the run will be created using the workspace's latest configuration version.                                                   |
  | Message                  | Specifies the message associated with this run.                                                                                                                                                                                                     |
  | Plan-Only                | Specifies if this is a speculative, plan-only run that Terraform cannot apply. Often used in conjunction with terraform-version in order to test whether an upgrade would succeed.                                                                  |
  | Refresh                  | Whether or not to refresh the state before a plan.                                                                                                                                                                                                  |
  | Replace Addresses        | Specifies an optional list of resource addresses to be passed to the -replace flag. Of the form array\[string].                                                                                                                                     |
  | Target Addresses         | Specifies an optional list of resource addresses to be passed to the -target flag. Of the form array\[string].                                                                                                                                      |
  | Terraform Version        | Specifies the Terraform version to use in this run. Only valid for plan-only runs; must be a valid Terraform version available to the organization.                                                                                                 |
  | Type                     | Specifies if this plan is a destroy plan that will destroy all provisioned resources, a refresh-only plan which should refresh the state without modifying any resources or neither.                                                                |
  | Variables                | Specifies an optional list of run-specific variable values. Refer to Run-Specific Variables for details. Of the form array`[{key, value}]` e.g. <pre><code>\[\{"key": "key1", "value": "value1"},\{"key": "key2", "value": "value2"}]</code></pre>. |
  | Workspace ID             | Specifies the workspace ID where the run will be executed.                                                                                                                                                                                          |
</div>

## Workflow Library Example

[Create a Run with Terraform Cloud and Send Results Via Email](https://library.blinkops.com/workflows/create-a-run-with-terraform-cloud-and-send-results-via-email)

<div className="iframe-wrapper">
  <div className="iframe-media">
    <img src="https://mintcdn.com/blinkops-2/ojHYuDeYX5FWuN8a/img/Icons/play-box.svg?fit=max&auto=format&n=ojHYuDeYX5FWuN8a&q=85&s=b8af968e71438a9499c3223c9bd29fb2" alt="Workflow Library" width="16" height="16" data-path="img/Icons/play-box.svg" />

    Preview this Workflow on desktop
  </div>

  <iframe className="iframe" src="https://library.blinkops.com/workflows/create-a-run-with-terraform-cloud-and-send-results-via-email/canvas" />
</div>
