Hi all,
Am new in using API in business central, can any one please help me with link or materials to go through on
-Inserting data in to custom table using API example given the link https://jsonplaceholder.typicode.com/users I want to utilize that list and fill my custom table
am using OnPrem BC
There's an error in the code or a mistake.. when you are parsing json.. you should try to add a debugger and see where your code is breaking..
Regards
That was wonderful video thank you, though I stacked on final stage
Error
Unable to convert from Microsoft.Dynamics.Nav.Runtime.NavJsonValue to System.Int32.
Thank you ZHU
Hi, I recommend the two videos of Erik below, I hope they can also help you.
How to make a simple API call with a json reply in Business Central
https://www.youtube.com/watch?v=D5jzrgl1EP0
JSON in AL for beginners - Essential development knowledge for Business Central
https://www.youtube.com/watch?v=so7_bOxp9V4
Thanks.
ZHU
Hi Maroh Kimaro,
I have found a video that explains how to insert data into a custom table using API in Business Central, and it uses the same example provided in the link you shared. Here is the link to the video
I hope this information is helpful.
Regards.
For this you will need to use the http client that you have available in the AL.
learn.microsoft.com/.../httpclient-data-type
Take the respons you get there and load it into a json object
learn.microsoft.com/.../jsonobject-data-type
Parse the json object and then insert records into your desired table
Stay up to date on forum activity by subscribing. You can also customize your in-app and email Notification settings across all subscriptions.
André Arnaud de Cal... 291,253 Super User 2024 Season 2
Martin Dráb 230,188 Most Valuable Professional
nmaenpaa 101,156