Business Central Integration
Go to the Dynamics 365 Business Central portal at https://businesscentral.dynamics.com/ .
Sign In to Business Central
Sign in using your admin account.
- Search for Microsoft Entra Applications.

Configure Microsoft Entra Applications
- Select Microsoft Entra Applications. Click New and enter the Client ID.

-
In the AP Automation screen under General, set the State as Enabled.
-
Set the D365 BUS PREMIUM under User Permission Sets.

Testing With Postman
Check that you can retrieve the company id. You will need the Postman API platform, to send a request to an API URL. It must be installed on your computer (download from https://www.postman.com ). Follow the Postman documentation for installation instructions.
Open Postman to get started.
Get Access Token
We will first need the access token.
Follow these steps:
-
From Postman, select the GET request.
-
Type this URL (Substitute
{{TenantID}}
with your Tenant ID): https://login.microsoftonline.com/{{TenantID}}/oauth2/v2.0/token -
Under the Body tab, select x-www-form-urlencoded. Fill out the keys with their corresponding values for:
-
grant_type : Specifies the type of OAuth 2.0 flow or grant that the application is using to obtain an access token.
-
client_secret : The client_secret is a confidential string credential that the application uses to prove its identity to Microsoft Entra ID.
-
client_id : Also known as Application ID or App ID, this is a unique identifier (GUID) assigned to your application when you register it in Microsoft Entra ID.
-
scope : This parameter defines the permissions and resources that the application is requesting access to on behalf of a user (delegated permission) or as itself (application permission).
Set the body to x-www-form-urlencoded:
Key | Value |
---|---|
grant_type | client_credentials |
client_secret | Your Client secret |
client_id | Your Client ID |
scope | https://api.businesscentral.dynamics.com/.default |
- Click the Send button. You will see the response in JSON format with the value of the access token (see image). You can find it in the response to the request sent. The response contains a key “access_token” with the value that you will need to get the company id.

You can save this in your Postman workspace (optional). Click the Save button at the top right-hand corner (you can also Share it if you prefer).
Get Company ID
We can now get the company id by using Postman.
-
Select the GET request.
-
Type the following URL (substitute
{{Environment}}
with the name of your environment e.g. production):
https://api.businesscentral.dynamics.com/v2.0/{{Enviroment}}/api/v2.0/Companies
Make sure that you also fill out the Body tab like in the previous step. Follow this guideline:
Set the body to x-www-form-urlencoded:
Key | Value |
---|---|
grant_type | client_credentials |
client_secret | From step 3 |
client_id | From step 3 |
scope | https://api.businesscentral.dynamics.com/.default |
-
Under the Authorization tab, set the Token value with your access token value we retrieved from the earlier request.
-
Click the Send button. You will see the response with the value of the company id (see image).
