How to add Slack to Dynamics NAV
Short answer
Build a Slack app that talks to Dynamics NAV through published web services. Use Socket Mode so the app connects outbound from your network, post Block Kit messages for alerts and approvals, and add slash commands for read-only lookups. NAV logic stays in codeunits, Slack is just the front end.
Engineering, planning and sales teams that run Slack still depend on NAV for the answers: what is on hand, when does the part arrive, which orders are blocked. They end up pinging the one person who knows the NAV client.
NAV has no Slack connector, but Slack apps are easy to build and NAV web services are stable. The interesting design choice is network posture: a NAV server on a private LAN can still serve Slack if the app uses Socket Mode and connects outward.
Keep the first version small: three slash commands and one alert channel. Prove the trust model before adding writes.
What teams use it for
Slash command stock check
/nav stock 4510 returns on-hand and available quantity by location from Item Ledger Entry sums via a published query.
Order status for sales
/nav order SO-1042 returns status, ship date and any credit block on the Sales Header.
Stockout alerts
A scheduled job posts items falling under Reorder Point or Safety Stock Quantity to the planning channel.
Interactive PO approvals
Approvers see a Block Kit message with vendor, amount and Approve or Reject buttons.
Production disruption thread
When a production order is flagged late, a thread is opened with the component shortage list so planners can discuss in context.
Receiving notifications
Posted Purchase Receipts for critical items notify the production channel that material has arrived.
Microsoft Dynamics NAV integration surface
- Web services from the Web Services page: SOAP on all versions, OData from NAV 2013 and OData v4 from NAV 2016, with page, query and codeunit objects.
- Queries are efficient for read-only slash commands because they can join Item, Item Ledger Entry and Location, and they publish as OData endpoints.
- Codeunits as web services for decisions and any controlled write, giving Slack a single, validated action to call.
- Job Queue Entries and the NAV Application Server for scheduled alert scans; on very old builds a Windows scheduled task calls a codeunit service instead.
- Authentication choices include Windows credentials and web service access keys; a service account with narrowly scoped permission sets suits an app.
How it works
- 1
Create the Slack app
Define slash commands, interactivity and bot scopes. Enable Socket Mode so you avoid exposing a public request URL.
- 2
Define the NAV contract
List the exact questions and actions. Publish one query or codeunit per question rather than a generic query endpoint.
- 3
Write the app service
Run a small service inside your network that holds the Slack app token, receives events over the socket and calls NAV web services.
- 4
Map Slack users to NAV users
Look up Slack email, match to NAV user and permission set. Unknown users get a polite refusal.
- 5
Format with Block Kit
Return compact tables and buttons. Add a link to the document in the NAV web client when available.
- 6
Implement approvals safely
On button click, verify the clicker, check the Approval Entry is still open and call the decision codeunit.
- 7
Rate limit and log
Throttle alert posts, log every command and response, and alert on service failures.
Example flows
Lookup in a channel
Trigger: Someone types /nav stock 4510.
- Slack sends the command over the socket.
- The app resolves the user and checks permission.
- It calls a stock query for item 4510.
- It replies ephemerally with by-location quantities.
Result: The answer arrives in seconds and only the requester sees it.
Late PO alert
Trigger: An hourly job finds a purchase line past Expected Receipt Date for an A-class item.
- Codeunit writes an alert row.
- The app posts to the buyer channel with the vendor and days late.
- A button lets the buyer log a call outcome.
- The outcome is stored in a note on the line through a codeunit.
Result: Chasing is tracked instead of lost in chat.
Approve from Slack
Trigger: A purchase order enters approval.
- The app posts the summary to the approver by direct message.
- The approver clicks Approve.
- The app verifies and calls the decision codeunit.
- The message is updated to show who approved and when.
Result: Order released without opening NAV.
Keeping data on-prem
A NAV server on a private network can work with Slack if the integration service sits inside that network and opens only outbound HTTPS and WebSocket connections to Slack. Socket Mode removes the need to publish a callback URL. If your Slack plan or policy does not allow Socket Mode, place a minimal reverse proxy in your DMZ that forwards only the Slack paths and checks the request signature. Any AI that interprets free-text requests can run on a local model on the same host, so only the final answer text goes to Slack.
Security checklist
- Verify Slack request signatures or use Socket Mode tokens kept in a secret store.
- Make slash commands read-only by default and require explicit button clicks for writes.
- Use ephemeral replies for sensitive numbers so they do not remain in channel history.
- Restrict the service account in NAV to the published objects only.
- Record Slack user ID, NAV user and document in an audit table.
Ways to get it done
Off-the-shelf iPaaS (Zapier-style or workflow tools) with a NAV connector
Effort: Hours to days, with per-task fees.
Simple notifications where a connector for your exact version exists.
Custom Slack app plus NAV web services
Effort: 2 to 5 weeks for a first release.
Slash commands, approvals and tailored alerts.
Partner delivery with Netray
Effort: Scoped; pilot in a few weeks.
A conversational assistant over NAV with local models and human-approved writes.
Pitfalls
- !Slash commands must respond in about three seconds; acknowledge first and answer asynchronously for slow queries.
- !Channel posts persist; avoid putting prices or customer-confidential details in public channels.
- !SOAP session limits on the service tier can throttle bursts; cache common lookups.
- !Matching users by display name rather than email causes wrong-person approvals.
- !Forgetting that NAV company names appear in the service URL when you run multiple companies.
Frequently asked questions
Is there a Slack app for Dynamics NAV?
There is no official one. Third-party tools may exist for specific versions, but most teams build a small app on top of NAV web services. Check your version and whether the vendor still supports it before depending on a connector.
Can Slack reach an on-prem NAV server?
Not directly, and it should not. A service inside your network connects outward to Slack using Socket Mode and calls NAV locally. That keeps the NAV endpoint private and avoids opening inbound firewall ports.
Can we approve orders from Slack?
Yes, using interactive buttons that call a NAV codeunit as the mapped user. Verify the approval is still open and record who clicked. Start with low-risk approvals, then widen.
What NAV versions work?
Any version with web services and a scheduling option. NAV 2013 R2 and later add the Job Queue, which simplifies alerts. Older releases can still work with an external scheduler.
Can we ask free-text questions?
Yes, with an LLM that maps text to your fixed set of published queries. Run it on a local model if data must stay on-prem. Keep the model out of direct SQL and limit it to approved tools.
More for Microsoft Dynamics NAV
Want Slack working on your Microsoft Dynamics NAV?
A free 30 minute assessment: we map the integration path for your version and setup, and where it should run.
Get a free assessment