> For the complete documentation index, see [llms.txt](https://doc.wearepatchworks.com/product-documentation/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://doc.wearepatchworks.com/product-documentation/process-flows/managing-process-flows/initialising-a-process-flow-manually-with-a-payload.md).

# Initialising a process flow manually with a payload

## Introduction

The `initialise flow (advanced)` option can be used if you want to run a process flow immediately with a given payload in a single operation - it's particularly useful if you are sending data into Patchworks via the [Patchworks API](broken://pages/EVn1AesQJtjyoIw7p0HZ) or a [webhook](/product-documentation/process-flows/building-process-flows/process-flow-shapes/standard-shapes/trigger-shape/trigger-shape-webhook.md) and need to test a process flow with specific data.

{% hint style="warning" %}
Before initialising a process flow manually, make sure that you won't be duplicating data, or causing duplication next time the process flow runs according to trigger settings.
{% endhint %}

{% hint style="info" %}
If the virtual environments feature is enabled, you can also use the `initialise flow (advanced)` option to run the process flow against a given virtual environment - for more information, please refer to [Testing a process flow against a virtual environment](/product-documentation/virtual-environments/implementing-virtual-environments/testing-a-process-flow-against-a-virtual-environment.md).
{% endhint %}

## Need to know

* The maximum number of characters for a single payload is 100k. Anything larger than this may cause the process flow to fail.
* Your subscription tier determines the number of process flow runs that can be started per minute - please see [Core subscription tiers](/product-documentation/getting-started/subscription-tier-limits.md) for information.
* When working with `draft` process flows, you cannot edit shapes while the flow is being run manually.

## The steps

To initialise a process flow manually with a payload, follow the steps below.

## Using the initialise flow (advanced) option

{% stepper %}
{% step %}
[Access the first process flow](/product-documentation/process-flows/accessing-your-process-flows.md) that you want to run, so it's displayed on the canvas. If necessary, use the [versions panel in process flow settings](/product-documentation/process-flows/building-process-flows/process-flow-versioning.md#accessing-process-flow-versions) to switch to the required flow version.
{% endstep %}

{% step %}
**Select the initialise flow (advanced)**

Select the `initialise flow (advanced)` option from the actions bar - for example:

<div align="left"><figure><img src="/files/QVVYwImsapIIFRNax9QK" alt=""><figcaption></figcaption></figure></div>

The `initialise flow (advanced)` page is displayed:

<figure><img src="/files/WBpzRIDG8mjdSZcfRGuy" alt=""><figcaption></figcaption></figure>

Here, the left panel can be used to pass in a specific payload, and the right panel shows whether [flow](/product-documentation/process-flows/building-process-flows/dynamic-variables/flow-variables.md) and/or [environment values](/product-documentation/virtual-environments/implementing-virtual-environments/configuring-a-virtual-environment-version/configuring-virtual-environment-replacements/replacement-variables.md) are present.
{% endstep %}

{% step %}
**Apply payload**

Paste your required payload into the `payload` panel - for example:

<figure><img src="/files/LyPFyWTeWGTjcXtIhwsv" alt=""><figcaption></figcaption></figure>
{% endstep %}

{% step %}
**Review flow variables (if applicable)**

If flow variables are present in the current flow version, a `flow variables` section is displayed -click the associated arrow to display any [flow variables](/product-documentation/process-flows/building-process-flows/dynamic-variables/flow-variables.md) defined for the current version - for example:

<figure><img src="/files/p7mg0jrd5BjL1gGCDQZ7" alt=""><figcaption></figcaption></figure>

If required, you can use the associated toggle option to override the current variable value - for example:

<figure><img src="/files/nun4VjrR1w1Kohne6AzU" alt=""><figcaption></figcaption></figure>

{% hint style="info" %}
Any value specified here is applied for this run only.
{% endhint %}
{% endstep %}

{% step %}
**Review virtual environment variables (if applicable)**

If a `virtual environment variables` section is displayed, it means that at least one virtual environment is deployed for your company profile. Click in the `virtual environment` field and select the environment that the current flow should run against - for example:

<figure><img src="/files/Z8VJrXRpHgw3xMnByqA8" alt=""><figcaption></figcaption></figure>

Any replacement environment variables configured for the selected virtual environment are listed below - for example:

<figure><img src="/files/P55sBM3WHOjdascvTqk8" alt=""><figcaption></figcaption></figure>

If required, you can use the associated toggle option to override the current variable value - for example:

<figure><img src="/files/vdU2gbB0XOcRi3qYZqw7" alt=""><figcaption></figcaption></figure>

{% hint style="info" %}
Any value specified here is applied for this run only. For more information, please see [Testing a process flow against a virtual environment](/product-documentation/virtual-environments/implementing-virtual-environments/testing-a-process-flow-against-a-virtual-environment.md).
{% endhint %}
{% endstep %}

{% step %}
**Run the process flow**

Click the `initialise flow` button at the bottom of this page:

<figure><img src="/files/6BIEb4qCdona49yomxMG" alt=""><figcaption></figcaption></figure>
{% endstep %}

{% step %}
Check the logs and generated payloads to ensure that results are as expected. When you're satisfied that the process flow is running correctly, you can [deploy it to the virtual environment](/product-documentation/virtual-environments/implementing-virtual-environments/deploying-a-single-process-flow-to-a-virtual-environment.md).
{% endstep %}
{% endstepper %}

## Related pages

* [Initialising a process flow manually with a payload](/product-documentation/process-flows/managing-process-flows/initialising-a-process-flow-manually-with-a-payload.md)
