How to automate inbound email into Dynamics 365 Business Central
Short answer
Read shared mailboxes with Microsoft Graph, extract order and quote data with a language model, and create draft sales orders, quotes or purchase confirmations through Business Central API v2.0, with a review queue before anything posts. Business Central's own email features handle outbound mail well, but not inbound understanding.
Many manufacturers receive customer purchase orders as PDFs and free-text emails to a shared inbox, and an order desk retypes them into Business Central. Supplier acknowledgements and shipping notices arrive the same way. The work is slow and error-prone, but the variety of formats defeats rigid templates.
Business Central's email module sends documents and tracks the outbox, and it can attach files to records, but it is not designed to read arbitrary inbound mail and decide what it means. That job sits outside the ERP, in a pipeline that reads mail, classifies it, extracts fields, matches them to master data and drafts a transaction.
The right ambition is a draft with evidence, not an auto-posted order. Done that way, the order desk shifts from typing to reviewing exceptions.
What teams use it for
Customer PO to draft sales order
Match the sender to a customer, map customer part numbers to items using item references, and create a draft Sales Order with the PO number in the external document number.
RFQ intake to sales quote
Extract requested items, quantities and dates from RFQ emails and create sales quotes, flagging unknown parts for engineering.
Vendor order acknowledgements
Compare confirmed quantities and dates against the purchase order and propose date updates on lines, routed to the buyer.
Shipping and ASN emails
Parse carrier or supplier shipment notices and attach tracking numbers or expected receipt dates to the relevant purchase order.
Customer service triage
Classify inbound questions as order status, returns, invoices or complaints and route them, answering status questions from read-only data.
Microsoft Dynamics 365 Business Central integration surface
- Microsoft Graph API for reading shared mailboxes with application permissions, change notifications for new mail, and moving messages between folders to show state.
- Business Central REST API v2.0 for salesQuotes, salesOrders, purchaseOrders and their lines, plus customers, items and itemReferences for matching.
- Document attachments and Incoming Documents so the original email or PDF stays linked to the draft record for audit.
- The email module and email scenarios for outbound replies and confirmations, with the outbox as the sending record.
- Custom API pages in AL for staging tables where drafts, confidence scores and extracted evidence wait for review.
How it works
- 1
Scope one mailbox and one document type
Start with a single shared inbox and one flow, such as customer POs. Mixed mailboxes multiply classification errors.
- 2
Ingest through Graph
Use change notifications or polling to fetch new messages and attachments, storing the original with a stable message ID for traceability.
- 3
Classify and extract
A model identifies the message type and pulls structured fields: PO number, ship-to, lines, part numbers, quantities, dates. Run it on a local open-weight model if the content is sensitive.
- 4
Match to master data
Resolve customer by sender or tax ID, items by item reference, unit of measure and currency. Unmatched values go to review rather than guesses.
- 5
Create a draft and attach evidence
Create the document via API v2.0 in an open or draft state, attach the source email, and store confidence per field in a staging table.
- 6
Review queue
Present extracted fields beside the source with low-confidence fields highlighted. The user accepts, edits or rejects, then releases the document through the normal process.
Example flows
PO email becomes a draft order
Trigger: A PDF purchase order arrives in orders@ mailbox.
- Graph notification delivers the message and attachment.
- Extraction yields PO number, lines and requested dates.
- Item references map customer part numbers to item numbers.
- A draft sales order is created and the email attached.
- The order desk reviews flagged lines and releases.
Result: Retyping is replaced by a short review, with the original email one click away from the order.
Supplier date change
Trigger: A vendor emails revised delivery dates.
- The message is matched to the vendor and PO number.
- Proposed new dates are compared to current promised dates.
- A task with the change and impact is sent to the buyer.
Result: Buyers see schedule risks the day they are announced, but dates are updated only on approval.
Keeping data on-prem
Inbound mail often contains drawings, pricing and customer names, so many regulated shops keep extraction local. Run the classification and extraction models on your own GPU servers using vLLM or Ollama, keep the pipeline inside your network, and connect to on-premises Exchange or Exchange Online with the appropriate permissions. For on-premises Business Central, enable web services and call the APIs from the pipeline host. Nothing about extraction requires a cloud model, though accuracy on messy scans depends on the model and tuning you choose.
Security checklist
- Use application access policies so the Graph app can only read the intended mailbox.
- Treat email content as untrusted input: strip instructions embedded in messages and never let the model call write endpoints directly.
- Keep draft creation separate from release and posting, with permission sets that stop the service account from posting.
- Retain the source message for audit and set retention aligned with your records policy.
- Block auto-replies to external senders until the flow has been validated, to avoid leaking data.
Ways to get it done
Power Automate with Office 365 and Business Central connectors
Effort: One to two weeks
Structured emails and attachments from a small set of known senders.
Third-party EDI or order capture product
Effort: Weeks to months including trading partner onboarding
High-volume customers who can move to EDI or a portal, where structured data beats email parsing.
Custom pipeline with a local model, via Netray or in-house
Effort: Typically four to eight weeks for a first mailbox
Messy free-text and PDFs, sensitive content and a review queue tailored to your item references.
Pitfalls
- !Customer part numbers that are not in item references cause silent mismatches; clean this up before automating.
- !Auto-creating customers from unknown senders pollutes master data. Send them to review.
- !Replies and forwarded threads duplicate the same PO, so deduplicate on PO number plus customer.
- !Prompt injection through email text can try to steer the pipeline, so keep extraction output schema-bound and validated.
- !Units of measure and currency assumptions are a frequent source of wrong quantities and prices.
Frequently asked questions
Can Business Central read incoming emails by itself?
Its email module is mainly for sending and for attaching messages to records. Reading arbitrary inbound mail and interpreting it is typically done outside the ERP, using Microsoft Graph or Power Automate, then creating records through the APIs. Check your version for newer built-in capabilities.
Is it safe to create orders automatically?
Create drafts automatically, release manually. Auto-posting from free-text email is risky because a misread quantity or customer becomes a real commitment. After months of measured accuracy, you may auto-release narrow, low-risk cases such as repeat orders from one customer.
How accurate is extraction?
It varies with document quality and how consistent your customers' formats are. Clean digital PDFs can do well, scans and handwritten notes less so. Measure field-level accuracy on your own samples and set confidence thresholds that route doubtful fields to a person.
Should we move customers to EDI instead?
For high-volume customers, yes, structured data is more reliable than parsing. Email automation covers the long tail of customers who will never adopt EDI. Many companies run both, with EDI for the top accounts and email extraction for the rest.
Can this work with on-premises Exchange and Business Central?
Yes. Use the mail API available for your Exchange deployment, enable Business Central web services with a supported authentication method, and host the pipeline internally. Local models mean message content does not need to leave your network.
Want Email automation working on your Microsoft Dynamics 365 Business Central?
A free 30 minute assessment: we map the integration path for your version and setup, and where it should run.
Get a free assessmentTry it here, free
Business Central On-Prem Private AI Layer Blueprint Generator
Describe your Business Central on-prem setup and get an architecture plan for a private AI assistant built on API v2.0 and a local model.
New to Microsoft Dynamics NAV and Business Central on-prem? Start with the Microsoft Dynamics NAV and Business Central on-prem guide and toolkit.
Keep exploring
Free tools
- Business Central On-Prem Private AI Layer Blueprint GeneratorDescribe your Business Central on-prem setup and get an architecture plan for a private AI assistant built on API v2.0 and a local model.
- Business Central Setup Checklist (Finance and Manufacturing)A step-by-step checklist for the first setup of a Business Central company, covering finance, inventory, manufacturing, users and go-live basics.
- Business Central License Cost CalculatorEstimate Business Central monthly and annual subscription cost from your user mix and your own price per user, with a chart of cost growth.
ERP fixes and how-tos
- Business Central Manufacturing Setup: Items, BOMs, Routings and Production OrdersSet up Business Central manufacturing: Manufacturing Setup, work centers, production BOMs, routings, item settings, manufacturing policy and demo data.
- Adding a Private AI Layer to Business Central On-PremisesAdd AI to Business Central on-prem without cloud: API v2.0, custom API pages, SQL replica, retrieval, local LLM, BC permission sets, approved write-back.
- Business Central Item Templates and Customer TemplatesCreate and use item templates and customer templates in Business Central to default posting groups, costing method and dimensions on every new record.
AI on your ERP
- AI for Business Central manufacturing operations, beyond CopilotAI for Business Central manufacturing beyond Copilot: grounded answers on production orders, routings, and capacity via APIs v2.0, on-prem capable.
- AI for Business Central Purchasing: Questions, Exceptions and Draft Orders on Your Own DataAI for Business Central purchasing: ask plain-English questions on purchase orders, vendor lateness and invoice matching, with read-only access and approvals.
Integrations
- How to automate email into Dynamics 365 Finance and Supply ChainTurn inbound emails into Dynamics 365 Finance and Supply Chain transactions: shared mailboxes, Graph, PO acknowledgements, RFQs and review queues.
- How to automate email to orders in Dynamics NAVAutomate inbound POs, RFQs and supplier emails into Dynamics NAV drafts: parse shared inboxes, create sales orders or purchase documents, with review.
Software
- Microsoft Dynamics 365 Business CentralDynamics 365 Business Central explained for manufacturers: modules, APIs, AL extensions, deployment, strengths, limits and alternatives for small and mid-size firms.
- Microsoft Dynamics 365 Finance and Supply ChainDynamics 365 Finance and Supply Chain Management explained for manufacturers: modules, data entities, OData, deployment, strengths, limits and alternatives.