WhatsApp Ordering

How WhatsApp Order Automation and ERP Integration Work for Wholesalers

By Arezoo Mohammadzadegan November 8, 2026 9 min read
How WhatsApp Order Automation and ERP Integration Work for Wholesalers

WhatsApp order automation and ERP integration work best when the chat never touches the ERP. A middle layer receives each WhatsApp order, matches the sender to a customer account, maps every line to the ERP’s item code and unit, takes prices from the ERP, gets the customer’s confirmation, and posts the order once with a reference that blocks duplicates.

This guide is for wholesalers and distributors in the UAE who already take orders on WhatsApp and want them to reach the ERP or accounting system without anyone typing them in again. It covers the parts of the connection, which system should own which data, the path an order takes, how to stop duplicates, what to do when the ERP refuses an order and what to ask before choosing a method. The WhatsApp details come from Meta’s developer documentation and the ERP examples from Microsoft, Zoho and Tally documentation, all checked on 8 November 2026.

What sits between WhatsApp and the ERP

There are always three parts, even when one product hides them. The first is the WhatsApp Business Platform, Meta’s API for businesses, which is what any automated ordering runs on, as the guide to what a WhatsApp ordering system for wholesalers must do explains. When a customer sends a message or an order, the platform sends your server a notification called a webhook.

The second is the middle layer. It can be custom code, an ordering product or a workflow tool. n8n is an example of the last kind, a tool that connects the apps a business already runs so that work moves between them without someone copying it by hand. This layer is where the matching, checking and confirming happens, and it is the part you design.

The third is the ERP or accounting system, reached through its own API. Microsoft Dynamics 365 Business Central, for example, documents one request that creates a sales order and another that adds lines to it. Zoho Inventory has an endpoint to create a sales order. TallyPrime’s integration guide says that for incoming data Tally acts as a server, accepting XML or JSON requests over HTTP.

Data moves both ways. Orders go from WhatsApp into the ERP, and the ERP’s answer, whether that is an order number, a missing item or a credit hold, goes back to the customer in the same chat.

Decide which system owns each piece of data

Most integration problems start with two systems that both think they are right. Settle who owns what before anyone builds anything.

  • Customers, branches, credit limits and payment terms belong to the ERP. The WhatsApp side only stores which phone number belongs to which customer account.
  • Items, units and pack sizes belong to the ERP. Every product a customer can order on WhatsApp needs a matching ERP item code and unit.
  • Prices belong to the ERP. Meta’s order webhook does carry an item_price on each line, but that is the catalogue price, and if customers pay different prices, the ERP price for that account is the one that counts.
  • Stock and the invoice belong to the ERP.
  • The conversation, the WhatsApp message ID and the customer’s confirmation belong to the WhatsApp side and are copied onto the ERP order as a reference.

The price point catches many wholesalers out, because a WhatsApp catalogue shows one price per product to everyone who opens it. The guide on how to send a price list and catalogue on WhatsApp covers what to do when your prices differ by customer. The comparison of a B2B ordering portal and WhatsApp ordering makes the same ownership point from another side. Whichever channel takes the order, it has to end up in the same ERP record.

How an order travels from the chat to the ERP

The path below runs in this order. Each step has one job and can fail on its own, which is why they are kept apart.

  1. Receive and store the webhook. Save the notification first and reply to Meta quickly, then do the work. Meta’s webhooks overview says that when a notification does not get an HTTP 200 response, delivery is retried with decreasing frequency for up to 7 days, and that this can result in duplicate notifications.
  2. Identify the customer. The webhook gives the sender’s phone number in the from field and a WhatsApp user ID in wa_id, and Meta’s order webhook reference notes that the two may not always match. Match on the phone number your team registered for that account. An unknown number, or one number shared by several accounts or branches, goes to a person instead of a guess.
  3. Turn the message into order lines. A catalogue order arrives already structured, with product_retailer_id, quantity, item_price and currency for each line. Meta’s multi-product messages guide uses the product’s SKU as the retailer ID in its example, so if each catalogue product carries the ERP item code as its ID, no lookup table is needed. A free-text or voice-note order has to be turned into lines first, and the checks in how to reduce order errors in WhatsApp orders apply at this step.
  4. Check the lines against the ERP. Look up each item, unit, price and stock level for that customer, and the customer’s credit status. Anything that does not match goes back to the customer as a question or to a person.
  5. Read the order back and get a clear yes. Send the summary with the ERP prices and wait for the confirmation. Because the customer has just messaged you, the reply falls inside the 24-hour customer service window, which Meta’s send messages guide says starts when a user messages or calls you. Once it closes, only pre-approved template messages can be sent.
  6. Post the order once. Create the sales order with the ERP customer number and the lines, and put the WhatsApp reference on it. In Business Central the sales order has an externalDocumentNumber field for this, and the line request takes an item, a unitOfMeasureCode, a quantity and a unitPrice. Zoho Inventory marks customer_id, salesorder_number and line_items as required when creating a sales order, and also accepts a reference_number.
  7. Send the result back. Reply with the ERP order number, or with the problem if the ERP refused the order.
Flow illustration from a phone chat to a checking layer to an ERP database, with a reply arrow back
The middle layer matches, checks and confirms before the ERP gets the order.

How to stop one chat becoming two orders

Duplicates come from three places. Meta can deliver the same webhook more than once, as its documentation says. The customer can send the order again when no reply comes. And your own middle layer can retry a request that timed out after the ERP had already created the order.

The fix is to give every order one key and check for it before anything is created. For a catalogue order the WhatsApp message ID works as the key, because the order webhook carries it. For a free-text order spread over several messages, use your own order number from the moment the request is recognised as an order. Store the key on the ERP order, in Business Central’s external document number for example, and before creating an order, look for an existing one with the same key. If it exists, return that order instead of making a new one.

💬

Need to generate WhatsApp QR Codes for your sales team?

Create instant click-to-chat QR codes with our free Business Generator.

Create WhatsApp QR
100% Free Tool by ArtinWebs

API designers call this idempotency. Stripe’s documentation on idempotent requests describes it as safely retrying requests without accidentally performing the same operation twice, using a key the client generates. Not every ERP API offers a key like this, so the check often lives in the middle layer. The same risk applies to any workflow step that creates records, and the guide to n8n error handling explains why a retry on such a step can do the job a second time.

A customer who sends the same order again is a different case, because the new message has a new ID. Here the read-back helps. If the same account already has an open order with the same lines from earlier that day, ask whether this is a second order or the same one before posting it.

What to do when the ERP refuses an order

An ERP can refuse an order for good reasons. The item is blocked, the unit does not exist for that item, the customer is over the credit limit, or the ERP is not reachable at that moment. Plan for each case before go-live, because the customer has already been told the order was received.

  • Keep a queue. A confirmed order that cannot be posted stays in a list with its reason and is not lost when the chat moves on.
  • Tell someone who can fix it. Each failure goes to a named person with the customer, the lines and the ERP’s error message.
  • Tell the customer the truth. A message saying the order is received and waiting for your team is better than a confirmation that later turns out to be wrong.
  • Reconcile every day. Count the confirmed WhatsApp orders and the ERP orders carrying a WhatsApp reference for the same day. The two numbers should match, and every gap is an order to chase.

Should WhatsApp orders post to the ERP automatically?

Not every order needs to post straight through on day one. Business Central’s sales order resource lists Draft, In Review and Open as the statuses an order can have. One way to start is to have a person check every WhatsApp order while it is still a draft in the ERP, before it moves on, and later let known customers with clean lines and no credit issue go straight through once those checks show few corrections.

Whatever you decide, an AI model that reads free-text orders should only draft the lines. The ERP checks and the customer’s confirmation decide what is posted.

Questions to answer before choosing a connection method

  • Does your ERP or accounting system have an API for creating sales orders, and is it included in your version or plan? Check this with your ERP provider rather than assuming it.
  • Is the system in the cloud or on a server in your office? A system on a local server has to be reachable by the middle layer, which usually means your IT provider sets up a secure connection to it.
  • Should a WhatsApp order create a sales order, a draft invoice or something else? If your team goes straight to invoices today, decide this first, because each choice changes what the ERP does next.
  • Who keeps the mapping between phone numbers and customer accounts, and between catalogue IDs and item codes, up to date when products or staff change?
  • Which ERP answers go back to the customer automatically, and which go to a person first?
  • Who gets the alert when a post fails, and how quickly do they need to act?

What the integration does not fix

The connection moves data, it does not clean it. Duplicate customer records or wrong pack sizes in the ERP will flow into every WhatsApp order, so fix the master data first.

Invoicing stays in the ERP. For UAE wholesalers that matters more with e-invoicing on the way, and the ordering system guide linked above has a section on planning the order-to-invoice step for it.

The WhatsApp rules still apply. Order updates follow the 24-hour window and the template rules, and Meta’s sending guide reminds businesses that they can only message users who have opted in to receiving messages from them.

Read next

The next guide in this series looks at the order record itself, the fields a WhatsApp order has to carry into the ERP, from customer codes and delivery branch to prices and approvals. A later one covers what UAE e-invoicing means for orders taken on WhatsApp. If you are not sure the ERP connection should be your first project, which process to automate first shows how to compare it with your other candidates.

To see how WhatsApp ordering would work with your own catalogue and ERP, Artin WholesaleOS lists WhatsApp order automation and ERP and accounting integration among its features. To talk through your own setup first, book a free strategy call.

Arezoo Mohammadzadegan
About the Author

Arezoo Mohammadzadegan

AI Programmer & Digital Marketing Strategist at ArtinWebs (A M H R MARKETING MANAGEMENT L.L.C). Specialist in Artificial Intelligence development, AI agent programming, n8n automation workflows, and digital transformation. Based in Dubai, UAE.