Manage company locations
When a Shopify merchant conducts business-to-business (B2B) transactions, they sell their goods and services directly to other companies. You can use the GraphQL Admin API to create companies that represent those business customers and contain information about them.
A company can be associated with one or more company locations. Each company location contains information that can be used to change how orders are calculated and charged for a specific company context. For example, a company might have multinational branches that need to follow different billing and taxation rules.
This tutorial shows you how to add a location to a company and make updates to the location information.
What you'll learnAnchor link to section titled "What you'll learn"
In this tutorial, you'll learn how to do the following tasks:
RequirementsAnchor link to section titled "Requirements"
Step 1: Add a company location to a companyAnchor link to section titled "Step 1: Add a company location to a company"
You can use the
companyLocationCreate mutation to create and add a company location to a company:
Step 2: Set up tax exemptions for a company locationAnchor link to section titled "Step 2: Set up tax exemptions for a company location"
If a company is exempt from sales tax at a location, then you should set up their tax exemption before they process any orders at that location.
companyLocationAssignTaxExemptions mutation to override the relevant taxes on the company's account.
The following example sets multiple tax exemptions on one company location. For details on all possible tax exemptions, reference the
Step 3: Associate payment terms with a company locationAnchor link to section titled "Step 3: Associate payment terms with a company location"
Payment terms determine when a company needs to pay for an order. This could be in advance of the order, at the time of order, or within a given amount of time that the merchant decides upon with the company.
Refer to the
paymentTermsCreate mutation documentation for information on creating payment terms.
The following example assigns payment terms with the ID
gid://shopify/PaymentTermsTemplate/2 to a company location:
- Learn how to associate a price list and publication to a B2B catalog to determine the available products and prices for customers ordering for a specific B2B company location.
- Learn how to manage draft orders for B2B clients by calculating and sending invoices.