- In your web browser, log in to your AL development sandbox.
- Using the icon, search for Users and click on the link to open the page.
- Select the user that you are logged in as to open the User Card.
- Expand the Web Service Access group.
- Let's create a new web service key:
- In the Web Service Access Key field, click the ... button.
- Click Yes on the prompt.
- Select a Key Expiration Date or enable the Key Never Expires field.
- Click OK.
- Now, double-click on the generated key to select the whole value, and copy/paste it to Notepad for later use.
The Web Service Access Key will be used in place of the user's password when we authenticate to the API.
- Open a new tab in your web browser. In the address bar, enter the following URL:
https://api.businesscentral.dynamics.com/v1.0/<tenant name>/sandbox/api/v1.0
Replace <tenant name> with the name of your Azure domain in which you created the Business Central sandbox. For example, if your Azure domain is myazuresub.onmicrosoft.com, then you would use the following URL:
https://api.businesscentral.dynamics.com/v1.0/myazuresub.onmicrosoft.com/sandbox/api/v1.0
At the time of writing this book, the current version of the Business Central API is 1.0. You may need to adjust the previous URL in the event that there is a newer version.
- When prompted, enter the following authentication information:
Username: |
The User Name of the user you created the web services key for in Step 3 |
Password: |
The Web Services Access Key value you generated in step 5 |
Once authenticated, you should see the raw JSON output that lists the entities that are available in the Business Central API.