Articles in this section

Shopify B2B - NetSuite integration template

The Shopify B2B - NetSuite template automates and synchronizes the company, location, customer (contact), catalog, pricing, orders, fulfillment, shipment, and refunds between the Shopify B2B Plus store and NetSuite.

Note

This template is compatible with the Shopify – NetSuite integration app flows. If you are using both the IA and this template, you will need to set a filter to exclude Shopify B2B orders from syncing through IA. 

If you are only using the template and installing it for the first time, as a prerequisite (before installing the template), make sure you install the Celigo Shopify Connector bundle (ID: 81289) in your NetSuite account. For detailed information, see the Install the Shopify B2B – NetSuite template section.

Shopify is a leading e-commerce platform designed for businesses of all sizes. B2B on Shopify is a suite with built-in features that enable merchants to sell business-to-business directly through their online store, without relying on third-party apps or complex workarounds. Merchants can set customer-specific price lists, payment terms, and currencies, and manage multiple buyers and locations under a single company profile. NetSuite is a comprehensive cloud-based ERP system that streamlines business operations such as financials, inventory, orders, and customer management.

Celigo already offers a pre-built Shopify-NetSuite Integration App for D2C (B2C) businesses. To address the distinct requirements of B2B commerce, Celigo now provides a separate, dedicated template for integrating Shopify’s B2B offering with NetSuite. By setting up a Shopify B2B to NetSuite integration using this template, businesses can harness the capabilities of both platforms to efficiently synchronize key data such as companies, locations, customers (contacts), catalogs, pricing, orders, fulfillments, shipments, and refunds - ensuring a seamless experience across sales operations and backend systems. The Shopify B2B – NetSuite template flow includes a filter that processes only those orders created by B2B customers associated with a specific company, allowing merchants to focus on scaling their B2B operations and managing workflows in real-time, without the need for manual data transfers between Shopify and NetSuite.

All_flows.png

In this template:

  • The company, contact, location, and payment details are bidirectional

  • The order, product item ID map, and refund details are from Shopify to NetSuite

  • The shipment, catalog, and pricing details are from NetSuite to Shopify

Shopifyb2bf.png

The following video explains the Shopify B2B - NetSuite integration template

Supported integration flows

The following built-in flows sync from the specified source data to the corresponding destination.

Companies

When a merchant creates a company in Shopify B2B, it is not just a placeholder; it’s the center of operations. Every company can have multiple locations, and each of these locations, along with the company, can serve different customer segments with unique catalogs.

When a company is created in Shopify, it syncs to NetSuite as a customer. For the Shopify B2B Company, the customer’s type is set as Company. These companies can have dedicated contacts and sub-customers.

c_and_SCu.png

Important

To run the NetSuite Company to Shopify Company (create or update) flow, a Shopify Plus account is required, as specified by Shopify. For more information, see API reference.

  • NetSuite company to Shopify company (create or update): Syncs companies and main contact from NetSuite to Shopify. This flow creates or updates any company records that are added. 

  • Shopify company and location to NetSuite company (create or update): Syncs companies and locations from Shopify to NetSuite. This flow creates or updates any company or location records that are added.

Sub-customers (NetSuite) aka Locations (Shopify)

In Shopify, a location defined under a company is represented in NetSuite as a sub-customer under the parent company record. A single company can have multiple sub-customers, each corresponding to a specific location defined within the Shopify company structure.

The company and sub-customers (locations) are also used to link the catalogs.

Each location can have:

  • One or more contacts (customers) assigned.

  • One or more catalogs can be linked to one location or company.

Each location can have one or more contacts (customers) assigned to it. Additionally, one or more catalogs can be linked to a location or the company itself. As a result, when a customer associated with a particular location or company logs into the Shopify store, they will only see the items included in the catalog assigned to that specific location or company. This ensures that even if the merchant has thousands of products in total, each customer sees only the relevant subset based on their assigned company or location that holds the catalog.

The Celigo Shopify B2B NetSuite template defines the location in NetSuite as sub-customers of a company. While NetSuite also allows locations to be represented through addresses, this approach has limitations, specifically, catalogs and contacts cannot be directly assigned to an address. Hence, sub-customers are preferred, since they support:

  • Catalog assignment (via price levels).

  • Contact assignments.

While both addresses and sub-customers can be used to represent locations, sub-customers are the preferred approach and are implemented in this template due to their ability to support catalog and contact assignments. However, if needed, you can opt to sync the company’s address as a location by selecting the Create location for company checkbox under Settings > General > Locations.

  • NetSuite locations to Shopify (Delete): Synchronizes deletions of company locations from NetSuite to Shopify, ensuring that removed locations are also cleared from Shopify. 

  • NetSuite locations to Shopify locations (Create/Update): Sync companies' sub-customers from NetSuite to Shopify companies' locations.

Contacts

In Shopify, each company is required to have a primary contact. Additionally, companies can have multiple contacts associated with them. These contacts represent individuals who act on behalf of the company, such as customer service representatives (CSRs). They are the actual users interacting with the store, for example, by browsing catalogs or placing orders.

In NetSuite, these contacts are linked to a parent customer record with the type set as Company or to the Sub-Customer (location) record.

  • NetSuite contacts to Shopify contacts: Syncs NetSuite contacts to Shopify contacts. This flow creates or updates contacts that are added.

  • Shopify contacts to NetSuite contacts: Syncs Shopify contacts to NetSuite contacts. This flow creates or updates contacts that are added.

Orders

When a contact places an order in Shopify B2B, the order is made on behalf of the company, through a specific location, and by a particular contact.

  • Shopify orders to NetSuite orders: Syncs orders from Shopify as sales orders to NetSuite. In NetSuite, a Shopify B2B order is mapped according to the following structure that ensures accurate company and catalog enforcement:

    • Customer: Represents the parent company (Applies when the contact placing the order is assigned directly to the company, or when the Assign order to location setting is disabled).

    • Sub-customer: Represents the location under the company (Applies when the contact placing the order is assigned directly to the location, and the Assign order to location setting is enabled).

    • Contact: Captured within the order details, identifying the individual who placed the order.

Shipments

After an order is synced to NetSuite, it uses the location’s shipping address to initiate the shipment and creates an item fulfillment record linked to the original sales order.

  • NetSuite shipments to Shopify: Syncs sales order fulfillment from NetSuite to Shopify when the status of the fulfillment is changed to Shipped in NetSuite.

Shipment records are tied to the company or the sub-customer (location), making it easy to track:

  • Which location received the goods.

  • Fulfillment status and tracking numbers.

Refunds
  • Shopify refunds to NetSuite refunds: Syncs item refund orders from Shopify to NetSuite refund. The flow helps you to create a customer refund from an invoice.

Catalogs and pricing

Once locations (sub-customers) are defined, the next step is assigning a catalog and pricing.

In Shopify B2B, each location can have a dedicated multiple catalog assigned, and this catalog determines the products visible to customers at that location.

In NetSuite, a price level can be assigned to each company and its corresponding sub-customer (location). This price level represents the corresponding catalog and ultimately defines the set of available items and the applicable price for each item in the specific catalog.

When a contact logs in:

  • They only see products and prices associated with their companies'/location's catalog.

  • Each contact under a company can have visibility into different catalogs, along with their related items and prices, depending on the location they are created under. 

Important

Since the flows below leverage the ShopifypublicationCreate mutation, the authenticated Shopify user must have the write_publications access scope. This permission allows the user to create and edit catalogs within Shopify. Failure to grant this access scope will result in the following error when running the flows: Access denied for publicationCreate field.Required access: `write_publications` access scope.

  • NetSuite price level catalogs to Shopify catalogs (Create/Update): Syncs eTail Shopify price lists (a custom catalog record) from NetSuite into the Shopify catalog. Price lists are assigned to the catalog through an eTail Shopify Price Lists custom table in NetSuite. The rows created using this table are synced as the catalog in Shopify. This flow creates or updates catalogs that are added.

  • NetSuite price level catalogs to Shopify companies and locations: Syncs catalog assignments from NetSuite to Shopify companies and locations. You can assign multiple price levels to a company or sub-customer in NetSuite by navigating to the Customer > eTail tab and selecting the desired values from the eTail price level multi-select setting. This dropdown displays all available price levels configured in your NetSuite account.

  • NetSuite price level to Shopify catalog product price: Syncs product-level pricing from NetSuite price levels to Shopify catalogs.

    Use case: When a merchant wants to override the default percentage-based discount in a Shopify catalog with a specific price for a given item, this flow allows custom product-level pricing per item within a catalog.

    For example, assume that each catalog in NetSuite is associated with a price level (10% discount). If the merchant wants to set a custom price for a specific item, instead of the assigned 10% discount, they can update the price manually under the 10% discount price level in NetSuite.

  • Remove locations from catalogs: Removes catalog-location assignments in Shopify based on changes in NetSuite.

Payment

Payments in this template are handled through a bi-directional flow between NetSuite and Shopify. 

In the NetSuite payments to Shopify payments, the flow retrieves payment records from NetSuite, performs a lookup for related orders in Shopify, and creates payments against those orders, provided they are not already marked as paid in Shopify. 

  • NetSuite payments to Shopify payments: Syncs payment records from NetSuite to Shopify order details and payment. This flow retrieves payment records from NetSuite, performs a lookup for related orders in Shopify, and creates payments against those orders, provided they are not already marked as paid in Shopify.

  • Shopify payment to NetSuite payments: Syncs order payment details from NetSuite to Shopify customer payment records. Payments are managed through a real-time flow that requires a webhook to be set up in Shopify. When an order payment event occurs, the webhook triggers the flow, which then retrieves the transaction details from Shopify, looks up the related invoices in NetSuite, and creates a customer payment against the corresponding invoice.

    Create your webhook in Shopify
    1. Sign in to your Shopify admin account.

    2. Navigate to Settings > Notifications and scroll down to Webhooks.

    3. Click Create webhook. The Add webhook window opens.

    4. From Event, select Order payment.

    5. From Format, select JSON.

    6. In URL, add the Public URL generated in your integrator.io Shopify webhook (automatically generated, required): Use the + button to generate a public URL for this webhook listener.

    7. From Webhook API version, select the desired version.

    8. Click Save.

      WEbhook.png
Product
  • Shopify products to NetSuite item map: Syncs the Shopify product IDs, variant IDs, and inventory item IDs to the corresponding NetSuite item ID map record.

    The product flow maps the Shopify Product ID, Variant ID, and Inventory Item ID from the Shopify product to the corresponding item in NetSuite and stores this information in a custom field located under the eTail tab > Celigo Shopify Item ID Map.

Note

If you're using the Shopify–NetSuite Integration Application, it is recommended to continue using the IA-provided flows for both product synchronization and item ID mapping.

Install the Shopify B2B – NetSuite template

Keep your Shopify B2B and NetSuite account credentials ready:

  1. Install the Celigo Shopify Connector bundle (ID: 81289).

    Note

    This bundle will already be available in your NetSuite account if you are using the Shopify-NetSuite Integration Application.

    1. Sign in to your NetSuite account as an administrator.

    2. Navigate to Setup > Customization > SuiteBundler > Search and install bundles.

    3. Enter and search the Bundle ID (81289).

    4. Click Install and wait for the installation to complete successfully.

  2. Navigate to integrator.io > Marketplace.

  3. Search and select the Shopify B2B - NetSuite template and click Install.

  4. Review the template’s contents and ReadMe, and click Install now to begin.

  5. Set up a connection to NetSuite.

  6. Set up a connection to Shopify B2B store (API type: HTTP).

  7. Set up a connection to Shopify B2B store (API type: GraphQL).

  8. Install the Integrator SuiteApp.

  9. Install the resources from the template zip.

  10. Install the template.

Mandatory configurations in NetSuite

To sync catalogs (price lists) from NetSuite to Shopify, you have to configure the following settings in NetSuite. These settings control how catalogs are created, priced, and assigned to Shopify locations.

Create a catalog and set the price adjustment type in NetSuite

To create a new catalog:

  1. Sign in to your NetSuite account.

  2. Open the eTail Shopify price lists custom record page.

  3. Click New eTail Shopify price lists.

    New_eTail_Shopify_price_lists.png
  4. Enter a Name.

  5. Select Related NetSuite price level (predefined price tier).

  6. Select Currency.

    Related_NetSuite_price_level.png
  7. In Price adjustment type, click New.

  8. In Name,

    1. Enter Percentage Increase, and in ID, enter PERCENTAGE_INCREASE.

    2. Enter Percentage Decrease, and in ID, enter PERCENTAGE_DECREASE.

    3. Click Save.

      Percentage_Increase.png
  9. Enter Percentage.

  10. In Compare at mode, click New. (Note that the Compare at mode is an optional field.)

  11. In Name

    1. Enter Nullify in ID, enter NULLIFY , and in the Use case enter Compare at price is set to null unless explicitly defined with a fixed price value.

    2. Enter Adjusted in ID, enter ADJUSTED, and in the Use case enter Compare at price is adjusted based on the percentage specified in the price list.

    3. Click Save.

      Nullify.png
  12. Click Save.

Assign a price level to a specific company or sub-customer in NetSuite

Company 

  1. Open the Customer record page that you want to assign a price level to.

  2. Navigate to eTail > ShopifyB2B.

  3. From eTail price levels, select Price levels.

  4. Click Save.

    NetSuite_price_level_catalogs_to_Shopify_companies_and_locations.png

Sub-customer 

  1. Open the Customer record page.

  2. Navigate to Information > Sub-customers.

  3. Open the required sub-customer.

  4. Navigate to eTail > ShopifyB2B.

  5. Click Edit.

  6. From eTail price levels, select Price levels.

  7. Click Save.

    Customer.png

This flow will sync the price level to the Companies/locations in Shopify.

Shopify_CAt.png
Shopify_CAt_2.png

    Configure the settings

    In the installed template, navigate to Settings:

    General:
    • Default payment terms: This allows you to predefine payment terms that can auto-populate in template flows for locations and companies. Even though it is not currently used in the active flow, it helps standardize payment terms when syncing data from NetSuite to Shopify.

    • Default contact role: This defines the default role assigned to a customer contact within a location. By default, the system assigns Ordering Only, and you can also select Location admin. This setting ensures that the selected role is automatically applied when creating or updating the company or company locations.

      GEneral.png
    Locations:
    • Create location for company: This enables automatic creation of locations in Shopify based on company addresses in NetSuite. 

    • Billing same as shipping: This enables the billing address to be automatically set to be the same as the shipping address for the location. This simplifies address handling during customer sync or order placement.

    • Editable shipping address: This enables customers to edit their shipping address during the Shopify checkout process. This is helpful for businesses that want to give end users flexibility at checkout.

    • Checkout to draft: This enables checking whether a location is allowed to create a draft order in Shopify during the checkout process. If checked, orders from this location will be saved as drafts instead of being placed directly.

      Location.png
    Main contact for companies:
    • Main Contact for Companies: This determines how the primary contact is selected when syncing company data from NetSuite to Shopify. In NetSuite, each company can have multiple contacts listed under the Relationships. This setting allows you to choose whether the main contact should be selected based on the contact marked as the primary role or based on the oldest internal ID. 

      • If the Primary role is selected, the contact explicitly set as the primary in NetSuite will be used.

      • If the Oldest internal ID is selected, the first contact created for that company will be assigned as the main contact during the sync.

        Main_c.png
    Transactions:
    • NetSuite tax code: This can be used when syncing orders from Shopify to NetSuite. If an order contains taxable line items, the flow adds a new line to the NetSuite sales order representing the tax amount. 

      Trans.png
    Orders:
    • NetSuite discount Item: This is used when syncing Shopify orders that include discounts. The discount is added to the NetSuite order as a separate line using the selected non-inventory item. This ensures that discounts are properly recorded in NetSuite.

    • Assign orders to the location: This determines whether the order in NetSuite is assigned to a specific location (sub-customer) or the main company.

      • If selected, the order created by a contact assigned to a location is assigned to the corresponding location or sub-customer.

      • If not selected, the order is assigned to the parent company, even when it is created by a contact assigned to a location.

        Order_setting.png
    Refunds:
    • Create return for refund: This controls whether a return authorization is created before processing a refund in NetSuite.

      • If selected, the flow will first create a return authorization, followed by a credit memo and refund.

      • If not selected, the return step is skipped entirely, and the refund is processed without a return record.

    • NetSuite adjustment item: This refers to a non-inventory item in NetSuite used to represent refund adjustments. The item name should contain the keyword refund to be considered valid. The criteria for identifying such items can be customized in the saved search eTail Shopify refund adjustment items.

      Net_adjust.png
    Catalogs and pricing
    • Default state: In ShopifyMarketsCatalog, each catalog can be configured with a Default state. This setting determines whether the catalog starts pre-populated with all products or is empty by default.

      • All products: The catalog will initially include all existing products.

      • Empty: The catalog starts with no products. Products must be added manually or through the Automatically include new products option

        Cat_settings.png
    • Auto publish: Any new product created in Shopify will be automatically added to the catalog when the user checks the Automatically include new products checkbox in Shopify. This ensures that merchants don’t need to manually update catalogs with each new product. When the user checks the Auto publish checkbox in Celigo, all the products that are synced from NetSuite to Shopify will be automatically published and made visible in the assigned catalog.

      Last.png

    Configure the Shopify B2B – NetSuite flows

    Additional record mapping is required to integrate the template’s exports and imports with your Shopify B2B and NetSuite apps.

    Note that all of your flows are disabled when first installed. After configuring the flows, you may enable them in your Flows dashboard or in Flow Builder with the Off/On toggle button. Then run the each flow.