Setup API Connection D365 F&O
Microsoft Azure
App Registration
Open URL: https://portal.azure.com/#home.
- Click on App registrations
- Click on "New registration".

Name
This should be a common name, e.g. "DeDeSales API Access"
Supported account types
Usually, "Accounts in this organisational directory only - ..." with your client name should be selected here. If access to multiple clients is required, you must configure this accordingly.
Set redirect URIs
Two URIs are required for your test and production systems respectively. Always select "Web" as the platform.
The following URLs were used in the screenshot:
- https://usnconeboxax1aos.cloud.onebox.dynamics.com/
- https://usnconeboxax1aos.cloud.onebox.dynamics.com/oauth/
You may not need to enter any URLs here, depending on your environment.
If you do enter any, you must enter your URLs. The example URLs shown here will not work for you.
Now click on "Register"
Create client secret
Under "Manage", click on "Certificates & secrets". Select "New client secret" there.
Name the secret "Secret" and select a duration of 24 Months. Then click "Add".
The secret key will now be displayed in the "Value" column.
Attention! This is only visible once and must be copied now, as we will need it.
API permissions
Now add the permissions shown here.
- Click on "Add a permission"
- Select the permissions shown below in Dynamics ERP.
- The Microsoft Graph "User.Read" permission is also required.
- Click on "Grant admin consent"

Application ID (Client)
You can find the Application ID by clicking on Summary. Copy the Application ID that appears, as we will need it.
D365 Finance & Operation
Microsoft Entra ID applications
Open D365 F&O and search for "Microsoft Entra ID applications".
For example accessible under:
Modules -> System administration -> +Expand All -> under the Category "Settings-> Microsoft Entra ID applications
Create a new entry and enter the following:
- Application ID
- Name as specified above: "DeDeSales API Access"
- Select a user under whose context the API call will be made by us.
- Use a strong password
- Do not select that a password change is required on first login.
- Disable MFA for the user
- Assign the user the correct role and rights. Your Project manager will provide an overview of access to the required entities.
- The role "System user" is Mandatory and must be assigned to the user.

Security configuration
The permissions described here cover the standard Connector of DeDeSales. For individual customisations, the permissions must be extended accordingly.
Do not forget to publish the Privileges and Roles after creation!
Privileges
Please create a new entry: DeDeSales API
Entities
Assign the following entities and grant the corresponding rights.
| Entity | Read | Update | Create | Delete |
| CustCustomerV3Entity | Grant | Unset | Unset | Unset |
| CustomerPaymentMethodEntity | Grant | Unset | Unset | Unset |
| DeliveryTermsEntity | Grant | Unset | Unset | Unset |
| EcoResProductBarcodeV3Entity | Grant | Unset | Unset | Unset |
| EcoResProductV2Entity | Grant | Unset | Unset | Unset |
| EcoResReleasedProductV2Entity | Grant | Unset | Unset | Unset |
| InventProductSpecificOrderSettingsV3Entity | Grant | Unset | Unset | Unset |
| PaymentTermEntity | Grant | Unset | Unset | Unset |
| SalesOrderHeaderV2Entity | Grant | Grant | Grant | Grant |
| SalesOrderLineV2Entity | Grant | Grant | Grant | Grant |
| smmContactPersonV2Entity | Grant | Grant | Grant | Grant |
| smmEmploymentJobFunctionEntity | Grant | Unset | Unset | Unset |
| InventWarehouseInventoryStatusOnHandEntity | Grant | Unset | Unset | Unset |
| EcoResProductLifecycleStateEntity | Grant | Unset | Unset | Unset |
Roles
Create a role named "DeDeSales API Role".
Duties
Add the following:
- Maintain Contacts
Privileges
Add the following:
- DeDeSales API
- DeDeSalesPriceDiscountsView
Completion
Test the API
The API must be accessible under the URL given above with /metadata and return the following result. Example: https://usnconeboxax1aos.cloud.onebox.dynamics.com/metadata/DataEntities
From your setup we need
- Application ID
- Secret
- TenantId
- URL




