> 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/building-process-flows/process-flow-shapes/standard-shapes/split-shape.md).

# Split shape

## Introduction

The `split` shape is used to split out a given payload element. When data is split, the specified element (including any nested elements) is extracted for onward processing.

For example, your process flow might receive customer data from a source connection, but you need to send address details to a different endpoint. In this case, you'd use the [route shape](/product-documentation/process-flows/building-process-flows/process-flow-shapes/standard-shapes/route-shape.md) to create two different routes, mapping just customer data down one, and splitting out addresses for the other.

{% hint style="info" %}
A single incoming payload for [any process flow shape](https://open.gitbook.com/~site/site_dIV1g/~/revisions/9dTvdvRJIRVZQXuBMMnJ/process-flows/building-process-flows/process-flow-shapes) should not exceed 500MB.

We recommend processing multiple, smaller payloads rather than one single payload (1000 x 0.5MB payloads are more efficient than 1 x 500MB payload!).

For payloads up to 500MB, consider adding a[ flow control shape](https://open.gitbook.com/~site/site_dIV1g/~/revisions/9dTvdvRJIRVZQXuBMMnJ/process-flows/building-process-flows/process-flow-shapes/standard-shapes/flow-control-shape) to batch data into multiple, smaller payloads. Payloads exceeding 500MB should be batched at source.
{% endhint %}

## Adding & configuring a split shape

<details>

<summary><img src="/files/JOYoP4EdSu7WJ3CMdAAS" alt="" data-size="line"> Show me</summary>

![](/files/hsVQNPKhUSJ3nXg0VxMB)

</details>

{% stepper %}
{% step %}
**Add a split shape**

In your process flow, add the `split` shape in the usual way:

<div align="left"><figure><img src="/files/ZNF9uv6L5AFDOTQiXW3t" alt="" width="375"><figcaption></figcaption></figure></div>
{% endstep %}

{% step %}
**Access settings**

Click the `settings` icon for the `split` shape:

<div align="left"><figure><img src="/files/QyrIhhPisrvlXjCLu07v" alt="" width="326"><figcaption></figcaption></figure></div>
{% endstep %}

{% step %}
**Select source details (optional)**

If appropriate, enter a `source integration` and a `source endpoint` - for example:

<div align="left"><figure><img src="/files/14O1mPlF9C1n83HCYg5c" alt="" width="375"><figcaption></figcaption></figure></div>

{% hint style="info" %}
Adding this information allows you to navigate the associated schema to determine where data is split. This is easier than entering a path manually, but it's not essential.
{% endhint %}
{% endstep %}

{% step %}
**Define where incoming data is split**

Move down to the `level to split` section. If you added source details in the previous step, you can use the dropdown data path to select the required data element to split - for example:

<div align="left"><figure><img src="/files/fU0G3NhJnSXM0kN4Oio5" alt="" width="375"><figcaption></figcaption></figure></div>

Alternatively, you can enter the required data path manually. For example:

<div align="left"><figure><img src="/files/ZRKDfFpcwrsxo5ydC7FA" alt="" width="375"><figcaption></figcaption></figure></div>

Here, `customer.addresses` targets the `addresses` array within a `customer` object.&#x20;

{% hint style="info" %}
Remember - any data (including nested data) within the selected element will be split out into a new payload.
{% endhint %}
{% endstep %}

{% step %}
**Add a wrapper key (optional)**

If required, you can add a `wrapper key`. This wraps the entire payload in an element of the given name - for example:

<div align="left"><figure><img src="/files/ewLszUiBM8cNo81lSOXt" alt="" width="375"><figcaption></figcaption></figure></div>

Here, defining `ADDRESSES` as the wrapper key would wrap the payload as shown below:

<div align="left"><figure><img src="/files/7khwJluqOthl7IZsYqp6" alt="" width="327"><figcaption></figcaption></figure></div>
{% endstep %}

{% step %}
**Save changes**

Save shape settings to exit back to the canvas.
{% endstep %}
{% endstepper %}
