Synchronize orders

When a customer places an order in your webshop, Tinx Connector automatically imports the order details into Business Central. This keeps your order data accurate and up to date without manual entry. The connector can process standard orders from all webshops, and also draft orders from Shopify. Webshop orders are imported into Business Central as sales orders. After creating sales orders, Tinx Connector can also automate the creation of other related documents, such as invoices, warehouse picks, and shipments.

Order processing in Tinx Connector

A webshop order progresses through the following steps before becoming a sales order in Business Central.

  1. Connection: There must be an active connection between your webshop platform and Business Central.
  2. Webshop Orders page: Incoming webshop orders are first saved on the Webshop Orders page (table 11205270).
  3. Item matching: Ordered products must exist in Business Central and be linked on the Webshop Products page (table 11205274).
  4. Customer record: Orders must be assigned to a customer in Business Central. This can be an individual customer card or a default customer card for all webshop orders.
  5. Conversion to sales document: Orders are converted to sales orders based on configurable filter criteria, such as payment status, guest or registered customer, and item matching. The required administrative data, such as posting groups, number series, stock, and prices, must be in place before a sales order can be created.
  6. Optional additional automation: After the sales orders are created, the remaining steps, such as creating invoices or arranging shipments, can be completed manually. Tinx Connector can also automate these steps. For more information, see Order Events page.
  7. Order status updates to the webshop: Tinx Connector can update the order status in the webshop. This is typically triggered when a sales shipment or sales invoice is created in Business Central. Track & Trace information can also be included, but this requires additional configuration in both Business Central and the webshop.

Enable webshop orders import

The procedures in this article require that the appropriate synchronization dashboard and message definitions are running. Activate them depending on what you are going to achieve.

The following tables show the synchronization dashboard and message definition for some of the webshops. The codes for other supported webshops follow the same pattern.

Direction Webshop Synchronization dashboard Message definition
Import WooCommerce WOO-IN-ORDERS WOO-086, WOO-086-1, WOO-087
Magento M2R_IN_ORDERS M2R-086, M2R-0871-1, M2R-087
Shopify GQL_IN_ORDERS GQL-120 to GQL-125

Orders are imported and processed via message definitions on the IN-ORDERS synchronization dashboard, such as WOO-IN-ORDERS for WooCommerce or GQL_IN_ORDERS for Shopify. The synchronization dashboard runs on a schedule, for example, every minute, and checks for new orders in the webshop. When new orders are found, they are imported into the Webshop Orders page. They are then converted to sales orders based on the filter criteria you have configured.

There are typically three message definitions involved in the process. Each message definition serves a specific purpose. In WooCommerce:

  • WOO-086: Checks for new orders submitted in the webshop.
  • WOO-086-1: Downloads additional order data, including order lines, shipping costs, discounts, and metadata.
  • WOO-087: Creates the sales order in Business Central based on the filter settings you have configured.

Setting up webshop orders import

After you install Tinx Connector and establish a sales channel, you need to configure two areas before the connector starts importing webshop orders into Business Central. On the E-commerce Setup page, define the order import parameters, such as which customer receives guest orders or how freight costs are recorded. Within the synchronization dashboards and message definitions for your webshop, you review the filter criteria that control which imported orders become sales orders.

If you run multiple sales channels, you can configure order import settings separately for each channel on the Sales Channel Card page. For more information, see Sales channel.

To set up webshop orders processing

Before you import the webshop orders, check or update the order import settings.

The following steps describe the setup on the E-commerce Setup page. However, for some scenarios, the Sales Channel Card page is the appropriate method to set up the webshop order import.

  1. Select Search (Alt+Q) in the upper-right corner, enter E-Commerce Integration Setup, and then choose the related link.

    If you don’t find E-Commerce Integration Setup in Search, change your role in Business Central to TINX E-Com Admin. Then, on the Role Center, select Setup, then choose E-Commerce Integration Setup.

  2. On the E-commerce Setup page, fill in the fields on the Orders FastTab. Hover over a field to read a short description.

    The following table lists some key fields on the E-commerce Setup page.

    Field Description
    Webshop Guest Customer No. Specifies the customer number to use for orders placed by customers who do not have a registered account in your webshop. For more information, see Guest customers.
    Freight Cost Type Specifies the type used for freight costs during order import. Options include G/L Account, Item, Resource, Fixed Asset, and Charge Item. In most cases, companies use G/L Account and Item.
    Freight Cost No. Specifies the account, item, or charge code to use for freight costs, depending on the Freight Cost Type you selected.
    No. of Order Checks Specifies how many times Tinx Connector checks an order’s status in the webshop.
    No. of Days Order to ‘Processed NAV’ Specifies how many days an unprocessed order can remain on the Webshop Orders page before it is archived.
    Webshop Order Status to Check Specifies which order statuses to skip when checking orders repeatedly in the webshop. This field works together with the No. of Order Checks field. Orders with final statuses, such as canceled or completed, don’t need to be checked repeatedly because their status won’t change. Use a filter expression to exclude these statuses. For example,canceled: completed.
    Sales Person Assigns the webshop order to a specific salesperson. In practice, most businesses leave this field blank.
    Different Table No. Sales Order Applies only if you import webshop orders into a custom order table instead of the default Sales Header (36) table.
    Handle Product Options Specifies how Tinx Connector processes custom product options: Create as new sales line, Link option to field, or Create as dimension.
    Custom Option Element Name Specifies which element name to use for custom options: Value or Title.
    Product Type in Webshop Order Line Specifies the product type used in webshop order lines. Options include Bundle, Configurable, and Configurator.
    Turn Off Check Legacy functionality, no longer used.

Filters for sales order creation

Tinx Connector creates sales orders in Business Central based on the orders imported into the Webshop Orders page. Order import is controlled by the message definition, such as WOO-086 for WooCommerce. In most cases, the message imports all new webshop orders. The next message in the flow, such as WOO-087 in WooCommerce, is responsible for creating sales orders in Business Central. One of the goals of this message is to apply filters to create the sales orders based on the webshop orders that meet filter criteria.

To review filters for sales order creation

  1. Select Search (Alt+Q) in the upper-right corner, enter Synchronisation Dashboard List, and then choose the related link.

  2. Select the synchronization dashboard related to importing webshop orders, such as WOO-IN-ORDERS for WooCommerce, and choose the View action.

  3. On the Synchronisation Dashboard page, select the message definition related to creating sales orders, such as WOO-087 in WooCommerce, and choose the Filters action.

    The following table lists the most common filters applied during order processing.

    Filter Description
    Processed NAV = 0 The order has not yet been converted to a sales order in Business Central. This prevents duplicate sales orders from being created for the same webshop order.
    No. Of Order Lines <> 0 The order must have at least one order line. This prevents empty orders from being converted to sales orders.
    Default Customer No. <> '' The customer in the imported webshop order must have a matching customer in Business Central, which is identified on the Default Customer No. field on the Webshop Orders page. Orders without a matched customer are not converted to a sales order. For more information, see Customer matching.
    Blocked = 0 The product in the imported webshop order must have a matching item in Business Central. Otherwise, the order is blocked. Blocked orders with unmatched items are excluded from processing. For more information, see Items matching.
    Blocked Customer = 0 The customer assigned to the order is not blocked in Business Central. Orders where the customer is blocked are excluded from processing until the block is resolved. For more information, see Blocked customers.
    Status = processing:pending Only orders with the status processing or pending are converted to a sales order. Orders with other statuses, such as canceled, are excluded.
    Fulfillment Channel = AFN Filters orders by fulfillment method. You can filter by AFN or MFN to process the orders you want.

    For more information about the filters, see.

Review imported webshop orders

When your webshop is connected, and orders meet the import criteria, they appear on the Webshop Orders page (TINX Sales Order table 11205270). This is a buffer table that stores the webshop orders. It is used to filter the orders before they are converted into sales orders in Business Central. For example, many businesses decide not to convert orders with the pending payment status.

The following table describes some of the key fields on the Webshop Orders page.

Field Description
Processed ERP Indicates whether the webshop order has been successfully converted to a sales order in Business Central. This prevents duplicate sales orders from being created.
Failed to Import Indicates that an error occurred when Tinx Connector tried to create a Business Central sales order based on the webshop order. Prevents a continuous loop of failed attempts.
Fault Reason Provides details about why the order failed to import. You can also find the error message in the Process Message part of the FactBox. Use this message to troubleshoot and resolve the issue. For more information, see Error messages.
Order Record ID Shows the ID of the sales order created in Business Central.
Status Shows the payment status of the order in the webshop, for example, pending, processing, or canceled. This status determines whether the order should be converted to a sales order.
Default Customer No. Specifies the customer number used for the order, as defined by templates or default settings.
Webshop Customer ID Shows the customer ID from the webshop. This field is used to match the order to a customer in Business Central. For more information, see Customer and item matching.
Blocked Customer Indicates that the customer is blocked in Business Central. The order is not processed until the block is resolved.
Blocked Order Indicates that one or more items in the order could not be matched on the Webshop Products page.

To review the webshop order lines

  1. Select Search (Alt+Q) in the upper-right corner, enter Webshop Orders, and then choose the related link.

  2. On the Webshop Orders page, select the order you want to review.

  3. On the action bar, in the Order group, choose the Order Lines action. This opens the Webshop Sales Order Lines page.

    You can also add new webshop order lines manually on the Webshop Sales Order Lines page.

Webshop order processing status

The Processed ERP and Failed to Import fields work together to indicate the current state of a webshop order. The following diagram shows the three scenarios for webshop order processing right after the order is imported into the Webshop Orders page. A sales order cannot be created from the first webshop order due to the filters. The second one has passed the filters, but has been blocked by the validation in Business Central. Only the third one has been successfully converted to a sales order in Business Central. The status of the webshop orders is reflected in the Processed ERP and Failed to Import fields on the Webshop Orders page.

Webshop order processing status

The following table describes all possible combinations in more detail.

Processed ERP Failed to Import Description
There are two possible reasons for this status.
- Recently imported orders might be waiting for the next job queue run to be processed.
- If the webshop order remains in that status for a longer period of time, the sales order has not been created because of the filters. For example, the message definition related to sales order creation, such as WOO-087 for WooCommerce, M2R-087 for Magento, GQL-124 for Shopify, and the equivalent for other supported webshops, can include filters that require that the status of the order must be either processing or pending. The webshop order with the status canceled is blocked by the filters.
The order passed the filter criteria, and Tinx Connector attempted to create a sales order. However, the attempt failed because Business Central raised a validation error. For example, the customer does not exist in Business Central, so the sales order could not be created. Check the Process Message part of the FactBox to see the error message. After resolving the issue, clear the Failed to Import checkbox to allow the next job queue run to process the order.
The order was successfully converted to a sales order in Business Central. To open the sales order, on the action bar, in the Order group, choose the Quote/Order action.
The order initially failed to import but was later successfully converted to a sales order in Business Central.

The most common fault reasons of webshop orders

Webshop orders are the most common area where users encounter synchronization issues. You can find the reason for the failure on the Webshop Orders page in the Process Message part in the FactBox. Select an error to see the details and how to resolve it.

Related information

Customer and item matching
Synchronize customers
Synchronize products
Automate order processing after import
Troubleshooting checklist
Error messages
E-commerce Setup and Sales Channel: Where to set up the webshop
Key concepts in Tinx Connector