Skip to main content

Notifications

Announcements

No record found.

Small and medium business | Business Central, N...
Answered

AL Integration issue

(1) ShareShare
ReportReport
Posted on by 68
Hi all,
I've a code unit with procedures that accept data through parameters and send it to business central. I can send a header information using POSTMAN but when it comes to lines, I am wondering how I will send the whole thing i.e. a combined header and lines. Is this possible and if so how will the json data look like? How will I connect the header and line procedures to be one procedure? If not possible should I send lines as a separately ? and if so how will I connect the lines to the header bearing in mind field No on the header is similar to field Document No in the lines.
 
kindly assist
  • Ramesh Kumar Profile Picture
    Ramesh Kumar 233 on at
    AL Integration issue
    Yeah. As these are 2 separate tables you need to have custom call Line and header.
     
    1. You can create a custom codeunit or API that accepts a JSON payload containing both the header and lines as part of the same object.
    2. Also you can send the header first, receive the Document No., and then send the lines in a separate request referencing the Document No..
  • Verified answer
    YUN ZHU Profile Picture
    YUN ZHU 74,115 Super User 2024 Season 2 on at

Under review

Thank you for your reply! To ensure a great experience for everyone, your content is awaiting approval by our Community Managers. Please check back later.

Helpful resources

Quick Links

December Spotlight Star - Muhammad Affan

Congratulations to a top community star!

Top 10 leaders for November!

Congratulations to our November super stars!

Tips for Writing Effective Verified Answers

Best practices for providing successful forum answers ✍️

Leaderboard

#1
André Arnaud de Calavon Profile Picture

André Arnaud de Cal... 291,391 Super User 2024 Season 2

#2
Martin Dráb Profile Picture

Martin Dráb 230,445 Most Valuable Professional

#3
nmaenpaa Profile Picture

nmaenpaa 101,156

Leaderboard

Featured topics

Product updates

Dynamics 365 release plans