# Brightpearl - add warehouses to cache

## Introduction

This flow retrieves all existing warehouses from Brightpearl and adds them to a `company` cache, ready for use in a subsequent sales order flow. The details below are stored for each warehouse:

* name
* warehouse ID

## Process flow snapshot

<details>

<summary><img src="https://2440044887-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FLYNcUBVQwSkOMG6KjZfz%2Fuploads%2FSUvxsp8XwrC9qsafJMIe%2Ficon%20process%20flow.svg?alt=media&#x26;token=ad1dc886-4a4e-4cad-9ad0-3d755e0f3b5a" alt="" data-size="line"> Click to view process flow snapshot</summary>

<div align="left"><figure><img src="https://2440044887-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FLYNcUBVQwSkOMG6KjZfz%2Fuploads%2FGhQ0N4rdVb1NN6Vrbgdu%2FBrightpearl%20-%20add%20warehouses%20to%20cache%20-%20full%20flow.png?alt=media&#x26;token=169d0106-9ac5-4937-801c-16f635215045" alt="" width="342"><figcaption></figcaption></figure></div>

</details>

## Limitations

No limitations to note.

## Assumptions

No assumptions to note.

## Customisation

To ensure that this process flow runs as required, some customisation options are available. These are documented in the following sections:

* [Flow variables](#flow-variables)
* [Process shape shapes](#process-flow-shapes)

### Flow variables

This process flow does not use flow variables.

### Process flow shapes

This process flow includes some shapes that can be configured with your own settings. Please see guidelines in the table below.

{% hint style="warning" %}
Shape settings determine the outcome of process flows. Do not change shape settings unless they are listed below.&#x20;
{% endhint %}

<table data-full-width="false"><thead><tr><th width="220.09375">Shape</th><th>Notes</th></tr></thead><tbody><tr><td>Trigger</td><td>The default schedule for this flow is to run <code>every hour</code>. This is the recommended run frequency but the schedule can be changed if necessary. Note that the cache updated in this flow is required for the <a href="shopify-greater-than-brightpearl-sales-orders">Shopify > Brightpearl - sales orders</a> process flow.</td></tr><tr><td>Connector (Brightpearl)</td><td>If you did not add or select a Brightpearl instance during the blueprint <a href="../installation-guide-shopify-and-brightpearl">installation process</a>, the following settings must be configured:<br><br><code>Source instance</code> : Set to your required <code>Brightpearl</code> instance<br><code>Source endpoint</code> :  Set to <code>GET Get all warehouses</code></td></tr></tbody></table>

## Reference

Reference information for this process flow is documented in the following sections:

* [Scripts used in this process flow](#scripts-in-this-process-flow)
* [Cross-reference lookups used in this process flow](#cross-reference-lookups-in-this-process-flow)

### Scripts in this process flow

This process flow does not use scripts.

### Cross-reference lookups in this process flow

This process flow does not use cross-reference lookups.
