# Shopify B2B Data

When you set up a new Shopify Plus integration in Daasity, we'll automatically pull in your B2B orders, draft orders, and metadata about companies, company locations, and contacts.&#x20;

{% hint style="info" %}
**Shopify integrations set up before September 2024**

If you have a Shopify Plus integration that was set up before September 2024, you need to re-authorize your integration and run history to pick up additional B2B data. You can do this in the edit menu of the integration screen in the Daasity app.
{% endhint %}

## Segmenting by Sales Rep and Sales Region

We also have additional tools to help you segment your B2B performance by sales rep and region. But to use these, you must set up some custom fields in Shopify.

### Set up the Sales Rep field

Here's how you would set up the custom company sales rep field:

{% hint style="info" %}
You can set up the **Sales Rep** field under either **Companies** or **Company Locations** — you should choose whichever makes sense for your business. If you assign sales reps to entire companies, choose **Companies**. If you assign a sales reps to individual company locations, choose **Company Locations**.
{% endhint %}

{% embed url="<https://youtu.be/zQ95YYCZHdE>" fullWidth="true" %}

1. In your Shopify admin, navigate to **Settings** in the lower right-hand corner of your screen.
2. Click into the **Custom Data** tab on the left.
3. In the **Metafield definitions** section, click on **Companies** or **Company Locations** — You should choose based on whether your organization assigns sales reps to a specific company or a specific company location.
4. Click **Add Definition**.
5. In the **Name** field, enter `Sales Rep`.
6. Click the **Select Type** button and choose **Single Line Text**.
7. If you want to create a preset list of choices (we recommend choosing this so that there aren't inconsistencies), check the **Limit to preset choices** option under the **Validations** section. Then enter the names of the sales reps currently active in your organization.
8. Under the **Options** section, click the **Filter in company index** toggle so that you'll be able to filter companies by sales rep in your Shopify admin.
9. Click **Save**.

### Set up the Sales Region field

Here's how you would set up the custom company location sales region field:

{% hint style="info" %}
You can set up the **Sales Region** field under either **Companies** or **Company Locations** — you should choose whichever makes sense for your business. If you assign sales regions to entire companies, choose **Companies**. If you assign a sales regions to individual company locations, choose **Company Locations**.
{% endhint %}

{% embed url="<https://youtu.be/fLg-0c8NbIc>" fullWidth="true" %}

1. In your Shopify admin, navigate to **Settings** in the lower right-hand corner of your screen.
2. Click into the **Custom Data** tab on the left.
3. In the **Metafield definitions** section, click on **Companies** or **Company Locations** — You should choose based on whether your organization assigns sales regions to a specific company or a specific company location.
4. Click **Add Definition**.
5. In the **Name** field, enter `Sales Region`.
6. Click the **Select Type** button and choose **Single Line Text**.
7. If you want to create a preset list of choices (we recommend choosing this so that there aren't inconsistencies), check the **Limit to preset choices** option under the **Validations** section. Then enter the names of the sales regions used by your organization to classify B2B customers.
8. Under the **Options** section, click the **Filter in company index** toggle so that you'll be able to filter companies by sales rep in your Shopify admin.
9. Click **Save**.

### Add metadata info

Now that you have set up your Sales Rep and Sales Region fields, you must populate those fields for the companies and company locations in your Shopify admin.


---

# Agent Instructions: Querying This Documentation

If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://help.daasity.com/core-concepts/data-integrations/setup-guides/digital-integrations/shopify/shopify-b2b-data.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
