Connect to Microsoft Dynamics 365 Business Central using a “Custom API”
Peliqan has 2 connectors to work with a Custom API in Business Central:- MS Business Central Custom API
- MS Business Central Custom API (Private app)
Add connection
In Peliqan, go to Connections, click on “Add Connection” and search for Business Central Custom API. Choose one of the connectors:Prerequisites
- Access to your Microsoft Business Central environment with admin privileges
- Valid API permissions set up in Business Central
Configuration Steps
1. Connection Setup
Connection Name Enter a descriptive name for this connection2. Business Central Credentials
Tenant ID To find your Tenant ID:- Log in to Business Central and navigate to the Dashboard
- Click the Settings icon (⚙) in the top toolbar
- Select “Admin Center”
- Copy the Tenant ID from the URL (it appears as
https://businesscentral.dynamics.com/{TENANT_ID}/admin)
- In the Admin Center, select “Environments”
- Choose your environment from the list (or create one if needed)
- Enter the exact environment name as shown
- On the Business Central Dashboard
- Click the Building icon in the top toolbar
- Select the company you want to connect to from the list
- Enter the exact company name as shown
3. API Configuration
API Category Route Enter the API route in the format:publisher/group/version
Example: zy/zygroup/v2.0
4. Entity Selection
List of Entities- Enter a comma-separated list of custom tables you want to access
- By default, the primary key is assumed to be “id”
- To specify a different primary key:
entityName|primaryKey(e.g.,customer|systemId) - For composite primary keys:
entityName|key1+key2(e.g.,order|orderId+lineNumber)
5. Replication Settings
Replication Key (Optional) Specify which field should be used for incremental refreshes:- Enter the field name that tracks record changes (typically a timestamp or version field)
- Leave blank if you don’t need incremental refresh
- Provided primary key works for all the Entities provided in connect form.
- Select “Incremental” if all your selected entities have the replication key available
- Select “Non-incremental” for full refreshes each time
MS Business Central data sync to your data warehouse
Once the connection is added, the ETL/ELT pipeline will start running and the data will be added to new tables in your data warehouse. Peliqan offers an out of the box data warehouse. Optionally you can choose to sync MS Business Central data to your own data warehouse such as Snowflake, Google BigQuery, MS SQL etc. Data will be synced to the chosen data warehouse and made available through the Peliqan UI for exploration:Support
If you encounter issues or don’t see the tables you need:- Contact support at support@peliqan.io
- Include your Business Central version and any error messages received
How to add custom API endpoints in Business Central
This guide explains how to create custom API endpoints in Business Central, e.g. in order to fetch data that is not available in standard API endpoints.How to create a custom API endpoint in Business Central (extension)
In Business Central click on Search (magnifier icon in top right corner), search for “Extension management” —> click on “Develop in VS Code” —> click on “Generate launch configurations”.COMMAND+SHIFT+P —> Select “AL: Download Symbols”
VendorApi.Page.al
Example content to list vendors with 3 selected fields id, number and displayName:
COMMAND+SHIFT+P —> Select “AL: Publish”
Add a connection in Peliqan for the newly created API endpoints
In Peliqan, add a connection of type “MS Business Central Custom API”:- For Environment name: see Business Central Admin:
https://businesscentral.dynamics.com/{tenant_id}/admin
- For Apicategoryroute, use this format:
publisher/group/version. See the above created file for details, in our example:
peliqan/peliqangroup/v1.0
Troubleshooting
User in BC has no access to Extension Management: make sure the user has Permission setEXTEN. MGT. - ADMIN. Example:
"application": "27.5.46862.46929". This should be same version as the extension “Application”, in BC go to Extension Management, find this extension and copy its version. Example:
