Shopify Companies
Applies toShopify
How it works
Shopify Companies is part of Shopify's native B2B features, now on every Shopify plan. You find it at Customers,Companies (opens in your Shopify admin in a new tab). A Shopify company has a profile, locations (offices, branches or warehouses, each with its own addresses) and customers (the contacts who buy for it).
SparkLayer works with those records. It links its draft orders to the buyer's Shopify company, contact and location, so orders show under the company in your Shopify admin.
With the Shopify B2B companies setting on at
SparkLayer Wholesale,Integrations,Platform (in your Shopify admin), each Shopify company is a company in SparkLayer, and its contacts are the people at that company. The sync runs one way, from Shopify to SparkLayer. Manage the company, its locations and its contacts in Shopify. Set its terms, such as its Customer group, Price list, pay later, sales reps and address settings, on its page in SparkLayer, or with company metafields in Shopify. While a company metafield has a value, it decides that setting, and the setting is locked on the company's page in SparkLayer, so you change it in Shopify. A change in SparkLayer never updates the metafield. See How it works.
Company in Shopify
Synced to SparkLayer
Terms set
Orders linked
With the sync off, you can build companies in SparkLayer instead.
SparkLayer still identifies B2B customers by their b2b customer tag and puts them in customer groups by their group tag (such as b2b-trade). A company's customer group sets the terms for the people at that company.
Do you need Shopify Companies?
Companies are optional. Use this table to decide before you set them up.
| If you want to… | Then |
|---|---|
| Give a business its own prices, payment terms or sales reps | Use companies. Build them in SparkLayer with the sync off, where you set the terms on each company. |
| Let several people buy for one business, or split a business into stores or regions | Use companies and company locations. |
| See B2B orders grouped by company in your Shopify admin | Use companies. SparkLayer links their orders automatically. |
| Sell to individual B2B customers on the same terms | You don't need companies. Customer groups handle everything. |
Set up your companies
First choose where you'll manage them:
- In Shopify: turn on the Shopify B2B companies setting, then create your companies, their locations and their contacts at Customers,Companies (opens in your Shopify admin in a new tab). They show in SparkLayer. Set each company's terms there, or with company metafields. Change its name, locations and contacts in Shopify.
- In SparkLayer: leave the sync off and click Create company at
SparkLayer Wholesale,Companies (in your Shopify admin). Set each company's Customer group, Price list, Let them pay later, people and locations there. See Companies.
Set a company's terms with metafields
With the Shopify B2B companies setting on, you can set a company's terms in either of 2 places:
- In SparkLayer, on the company's page.
- In Shopify, with a SparkLayer metafield on the company.
Metafields are optional. Use them if you'd rather keep a company's terms in Shopify with the rest of the company. Shopify companies don't have tags, so a metafield is the only way to set a company's customer group from Shopify.
You can mix the 2. For example, set the Customer group in Shopify and Pay later in SparkLayer. Each field follows the rule below on its own.
How it works
There's one rule: if a metafield has a value, Shopify decides. If it's empty, SparkLayer decides.
Fill it in on Shopify
It syncs across
The field locks
| What you do in Shopify | What happens in SparkLayer |
|---|---|
| Leave a metafield empty | Nothing. You set that field in SparkLayer as usual. |
| Add a value | The value replaces what SparkLayer had. The field locks on the company's page, with the hint "Set by the B2B - Customer Group metafield in Shopify. Remove it there to set it here." |
| Change the value | SparkLayer updates to the new value. The field stays locked. |
| Remove the value | The field unlocks and keeps its last value. It doesn't reset. Change it in SparkLayer if you want something else. |
| Enter a value SparkLayer can't read | That company or location stops updating in SparkLayer until you fix the value. This includes its name and its other terms. |
Removing a value doesn't undo it
To take a company off a price list, removing the metafield isn't enough: the company keeps the price list. Remove the metafield in Shopify, then remove the price list on the company's page in SparkLayer. To turn off an address setting, set its metafield to false instead of leaving it empty.
The 6 company metafields
Each one shows in Shopify with a name starting B2B -.
| Metafield in Shopify | What it sets | Where you can use it |
|---|---|---|
| B2B - Customer Group | The company's customer group, which sets its pricing and rules | Company or location |
| B2B - Price Lists | The price lists its buyers get | Company or location |
| B2B - Payment on Account | Whether it can pay later, with its credit limit, balance and net terms | Company only |
| B2B - Sales Agent Groups | The sales rep groups that look after it | Company only |
| B2B - Allow Personal Addresses | Whether buyers can use their own saved addresses as well as the company's | Company or location |
| B2B - Allow One-time Addresses | Whether buyers can enter a one-off address at checkout | Company or location |
What to enter in each:
| Metafield in Shopify | What to enter | Example |
|---|---|---|
| B2B - Customer Group | The group's tag. For the Base group, enter base, not b2b. | b2b-trade |
| B2B - Price Lists | A list of price list handles. Use the form below. | ["trade-25","clearance"] |
| B2B - Payment on Account | Its account details. Use the form below. | {"credit_limit":1000} |
| B2B - Sales Agent Groups | One group per entry, using letters, numbers and dashes. | uk-north |
| B2B - Allow Personal Addresses | true or false | true |
| B2B - Allow One-time Addresses | true or false | false |
For a customer group, b2b-trade and trade both mean the Trade group: SparkLayer ignores the b2b- at the start.
To write a B2B - Price Lists value, add each price list's handle here, then copy the result:
sparklayer.price_listsTo write a B2B - Payment on Account value, fill this in and copy the result. Leave out anything you don't use, and enter amounts without a currency symbol.
sparklayer.payment_on_accountNamespaces, keys and types, for developers and imports
All 6 use the sparklayer namespace.
| Metafield in Shopify | Key | Type | Owner |
|---|---|---|---|
| B2B - Customer Group | customer_group | single_line_text_field | Company, company location |
| B2B - Price Lists | price_lists | json | Company, company location |
| B2B - Payment on Account | payment_on_account | json | Company |
| B2B - Sales Agent Groups | sales_agent_groups | list.single_line_text_field | Company |
| B2B - Allow Personal Addresses | allow_personal_addresses | boolean | Company, company location |
| B2B - Allow One-time Addresses | allow_one_time_addresses | boolean | Company, company location |
Check the metafields are set up
You don't need to create these metafields. SparkLayer creates all 6 in Shopify when you turn on the Shopify B2B companies setting. If you've already made one by hand, SparkLayer keeps it and doesn't add a duplicate.
To check they're there:
- Go to
SparkLayer Wholesale,Integrations,Platform,Configurations (in your Shopify admin) and click Configure next to Metafields. - Find Company metafields. Each one should show Enabled.
- If one doesn't, click the button beside it: Retry or Enable.
The list has Customer metafields too, and some share a name, such as Sales rep groups. Those are for customers. Only the ones under Company metafields work on a company.
Fill in a metafield
- In your Shopify admin, go to Customers,Companies (opens in your Shopify admin in a new tab) and click the company. For a location, click the location on the company's page.
- Find the metafields with names starting
B2B -. - Enter the value, using the list above. Leave any you don't need empty.
- Click Save.
- In SparkLayer, go to
SparkLayer Wholesale,Companies (in your Shopify admin) and open the company. The field shows your value, with the hint that it's set by the metafield.
If the field hasn't changed, see the FAQs.
Companies and locations
A location uses its company's terms until it has its own. See Company locations.
| To do this | Do this |
|---|---|
| Give the whole company a customer group, price list or address setting | Fill in the metafield on the company. |
| Give one location something different | Fill in the same metafield on that location. That location's value applies there, and the other locations aren't affected. |
| Give one location its own pay later or sales reps | Use SparkLayer. B2B - Payment on Account and B2B - Sales Agent Groups only work on the company, so set these on the location's page. |
Example
A wholesale company buys at your Trade prices, with a 5,000 credit limit and Net 30 terms. Its Berlin location should use your Europe group instead. In Shopify, you'd enter:
| Where | Metafield | Value |
|---|---|---|
| The company | B2B - Customer Group | b2b-trade |
| The company | B2B - Payment on Account | {"credit_limit":5000,"net_terms":"30_days"} |
| The Berlin location | B2B - Customer Group | b2b-europe |
In SparkLayer, the company is then in the Trade group, and its Customer group and pay later settings are locked. Berlin is in the Europe group, and every other location stays on Trade. The other metafields are empty, so you set the company's price lists, sales reps and address settings in SparkLayer.
FAQs about company metafields
A metafield in Shopify is setting it. The hint under the field names the metafield. Change the value in Shopify, or remove it to set the field in SparkLayer.
Check these in order:
- The setting is on. SparkLayer only reads company metafields while the Shopify B2B companies setting is on.
- It's on the company. A metafield on the company's contact, under Customers, doesn't set the company's terms.
- It's the SparkLayer metafield. Its namespace must be
sparklayer. A metafield Shopify suggests undercustomisn't read. - The value is valid. Check it against the list of metafields. One bad value stops that company or location updating.
- The customer group exists. The value must match a group at
SparkLayer Wholesale,Companies,Customer groups (in your Shopify admin).
That's expected. Removing a value unlocks the field and leaves it as it was. Change it on the company's page in SparkLayer.
The metafield, if it has a value. SparkLayer takes it from Shopify and locks the field, so the 2 can't stay different. If the metafield is empty, SparkLayer's value stands.
No. With the setting off, SparkLayer doesn't read company metafields, and you set everything on the company's page. If you turn it off later, the metafields and their values stay in Shopify.
Companies built in SparkLayer
With the Shopify B2B companies setting off, you can build companies in SparkLayer without using Shopify Companies. Click Create company at
SparkLayer Wholesale,Companies (in your Shopify admin), then add its locations and people there.
Turning on the integration replaces companies built in SparkLayer
If you turn on the Shopify B2B companies setting later, your Shopify companies replace the companies you built in SparkLayer, along with their locations, people and settings. From then on, companies are managed in Shopify, and you set their terms in SparkLayer or with company metafields.
So if there's a chance you'll use Shopify Companies, create your companies in Shopify from the start.
How draft orders are linked to companies
When SparkLayer creates a draft order for a buyer at a company, it links the order to their Shopify company, contact and location. This keeps your Shopify orders and reports accurate.
Buyer orders
Draft order created
Company linked
Shown in Shopify
What the order is linked to depends on how the customer is linked to companies in Shopify. This applies to every order SparkLayer creates, including a quote converted to an order.
| The customer is | The order is placed against |
|---|---|
| Not linked to a company | The customer only. |
| A contact at one location of one company | The customer, the company and the location. |
| A contact at several locations or several companies | The customer, and the company and location they chose to order for. |
The delivery address the customer chooses at checkout becomes the Shopify order's shipping address. It doesn't decide which company location the order is linked to.
This means:
- Orders from SparkLayer appear under the company in your Shopify admin. On the orders list, you see the company name under the customer's name.
- Shopify's reports recognise them as B2B orders from that company.
- It resolves Shopify's warning that "Some apps may not attribute B2B orders correctly on your current plan. Check that B2B orders are assigned to a company, not just an individual customer."
Use vaulted credit cards
Because SparkLayer links draft orders to the customer's company and location, your B2B customers can use Shopify's vaulted credit cards (opens in a new tab). They save a card once and reuse it on later orders.
Vaulted cards belong to a company location. When a customer saves a card, at checkout or in their customer account, it's available to every customer linked to the same company location. With SparkLayer, they work in 2 ways:
- Pay Online by Card: when a customer chooses Pay Online by Card in the SparkLayer checkout, the cards saved for their company location appear under Credit card in the Shopify checkout. They can choose one, or click Use a different card.
- Draft orders and invoices: when a customer uses another payment method (for example Pay by Invoice), you can charge a vaulted card on the resulting draft order from your Shopify admin. On the draft order, click Collect payment and choose the saved card.
Before you start
- Shopify Payments turned on. Vaulted cards need Shopify Payments as your payment provider.
- Customers linked to a Shopify company. The customer must be a contact of a company in your Shopify admin.
- A saved card. Someone at the company location must have saved a card during a checkout or in their customer account. Once it's saved, every customer at that location can use it.
There's nothing to set up in SparkLayer. Vaulted cards work in the SparkLayer checkout as long as customers are linked to Shopify companies and Shopify Payments is active. They're available on every Shopify plan that has the Companies feature. Check any transaction fees with Shopify Support.
Control who can use vaulted cards
To stop some of a customer's team from using vaulted cards, use SparkLayer's company users feature. Give those team members the Limited role. They can browse and build an order, but they can't check out: their order goes to the main company user for approval instead. Because limited users never reach the Shopify checkout, they can't charge a card saved for the company location.
Limitations
- Shopify catalogs still control which products a company sees: SparkLayer's price lists replace the prices in a Shopify catalog, but not the catalog's product list. If a customer is a contact at a Shopify company whose catalog leaves a product out, Shopify hides it from them: it's missing from your theme's search and its page shows a 404, even when SparkLayer gives them a price. Add the products to the catalog, remove the catalog from the company, or don't use Shopify companies for these customers.
- Shopify payment terms aren't used: payment rules come from SparkLayer's customer groups, set on the company or location in SparkLayer. The payment terms on Shopify company records are ignored.
- Shopify's locations don't nest : in Shopify, a company's locations sit side by side. Grouping them into regions, with locations inside other locations, is a SparkLayer feature.
- Customers not in a company: their orders are linked to the customer only.
FAQs
No. Customers who aren't in a company buy at their customer group's settings, and you add them to a group with a tag. Use companies to see B2B orders grouped by company in Shopify, or to let colleagues share vaulted cards, or when a business needs its own terms, several people buy for it, or it has several locations.
Yes, with the Shopify B2B companies setting on. Companies, locations and contacts sync from Shopify to SparkLayer. It doesn't work the other way, so change the company, its locations and its contacts in Shopify. In SparkLayer, you choose its Customer group and Price list.
Not for the same customer session: the ordering experience is either SparkLayer or Shopify's native B2B checkout. Your Shopify companies still hold the business, its locations and its contacts, and SparkLayer uses them for ordering.
Both work together. Tags make someone a B2B customer and put them in a customer group. Companies group the people who buy for the same business, and let you give that business its own terms and locations.
Not for SparkLayer pricing. Companies and Markets are separate features, but on plans other than Plus they're closely linked.
You can create company records without Markets. They work as structured customer profiles with locations, contacts and payment terms. But to give those companies their own Shopify pricing catalogs, you need Markets: on the Basic, Grow and Advanced plans, catalogs are assigned through Markets (customer groupings), not directly to companies. On Shopify Plus, you can assign catalogs directly to company locations without Markets.
SparkLayer doesn't use either for pricing. Your price lists and customer groups, and each company's terms, are managed in SparkLayer, whether or not you use Markets.
SparkLayer handles it. It links draft orders to the right Shopify company and location, so B2B orders are attributed correctly in your Shopify admin.
No. The address the customer chooses at checkout becomes the order's shipping address in Shopify, but it doesn't change which company or location the order is linked to. See How draft orders are linked to companies.
Not in the SparkLayer checkout. SparkLayer uses its own address settings for each company: Personal addresses and One-time addresses on the company or location, or the matching company metafields. Shopify's Ship to any address setting doesn't carry over. Both are Not allowed on a new company, and they apply to sales reps ordering for the company too.
Shopify's setting matters when a customer pays by card. Pay Online by Card takes them to Shopify's checkout, which follows Shopify's company settings. For customers to use their own addresses everywhere, allow them in SparkLayer and turn on Ship to any address in Shopify.
No. Customers can request a quote whether or not they're linked to a Shopify company. When you convert the quote to an order, it's linked in the same way as any other order: see How draft orders are linked to companies.
Next steps
Last updated