Microsoft Dynamics 365 — ERP Connector Setup
Microsoft Dynamics 365 is a suite of enterprise business applications covering ERP, CRM, Finance, Supply Chain, and more. The BizOSaaS Dynamics 365 connector integrates with Dynamics using OAuth 2.0 and the Dataverse / Web API to sync finance, sales, and operations data with your AI agents.
Prerequisites
- A Microsoft 365 / Dynamics 365 subscription with an active environment
- An Azure Active Directory (AAD) tenant with admin rights
- Access to portal.azure.com to register an app
Step 1: Register an App in Azure Active Directory
- Log in to portal.azure.com
- Go to Azure Active Directory → App Registrations → New Registration
- Fill in the details:
- Name:
BizOSaaS Dynamics Connector - Supported Account Types: Select your organisation's tenant
- Redirect URI:
https://api.bizoholic.com/api/auth/callback/dynamics-365
- Name:
- Click Register
- Save the Application (client) ID and Directory (tenant) ID
Step 2: Create a Client Secret
- In your registered app, go to Certificates & Secrets → New Client Secret
- Set an appropriate expiry (24 months recommended)
- Click Add and immediately copy the Value (it won't be shown again)
Step 3: Configure API Permissions
Add the following API permissions under API Permissions → Add a permission:
| API | Permission | Type |
|---|---|---|
| Dynamics 365 (Dataverse) | user_impersonation | Delegated |
| Microsoft Graph | User.Read | Delegated |
Click Grant Admin Consent after adding the permissions.
Step 4: Add BizOSaaS as an Application User in Dynamics
- In your Dynamics 365 environment, go to Settings → Security → Users
- Switch the view to Application Users
- Click New and set User Type to
Application User - Enter the Application ID from Step 1
- Assign a security role (e.g.,
System Administratoror a custom role with appropriate entity access)
Step 5: Connect to BizOSaaS
- In your BizOSaaS dashboard, go to Settings → Integrations → Microsoft Dynamics 365
- Enter:
- Tenant ID (Directory ID from Step 1)
- Client ID (Application ID from Step 1)
- Client Secret (from Step 2)
- Dynamics Environment URL (e.g.,
https://yourorg.crm.dynamics.com)
- Click Test Connection to verify
- Click Save once the connection shows ✅ Connected
Step 6: Configure Data Sync
| Entity | Frequency | Dynamics Table |
|---|---|---|
| Accounts (Companies) | Every 1 hour | accounts |
| Contacts | Every 1 hour | contacts |
| Sales Orders | Every 30 min | salesorders |
| Invoices | Every 30 min | invoices |
| Products/Catalog | Daily | products |
| Purchase Orders | Every 1 hour | purchaseorders |
| Opportunities | Every 30 min | opportunities |
Available AI Actions
| Action | Description |
|---|---|
| Create Sales Order | Generate a sales order from a CRM deal |
| Update Account | Sync enriched company data back to Dynamics |
| Fetch Invoice Status | Check payment status for outstanding invoices |
| Create Contact | Add new contacts discovered via BizBot leads |
| Get Open Opportunities | Pull pipeline data for AI-powered forecasting |
| Trigger Workflow | Kick off a Dynamics Power Automate flow |
Troubleshooting
| Issue | Solution |
|---|---|
AADSTS50011 — Redirect URI mismatch | Ensure the Redirect URI in Azure exactly matches https://api.bizoholic.com/api/auth/callback/dynamics-365 |
Access Denied in Dynamics | Verify the Application User has the correct Security Role assigned |
403 Forbidden on entity sync | The assigned role may lack read permissions for that Dynamics entity |
| Token expiry | Tokens auto-refresh; if failing, re-save the Client Secret |
| Environment URL incorrect | Use the full URL from Dynamics Settings → Customization → Developer Resources |
Support
For detailed API reference, see the Microsoft Dataverse Web API documentation or contact BizOSaaS support.