web
You’re offline. This is a read only version of the page.
close
Skip to main content

Announcements

No record found.

News and Announcements icon
Community site session details

Community site session details

Session Id :
Small and medium business | Business Central, N...
Unanswered

Delete Assembly BOM records using API, web service, or AL code

(0) ShareShare
ReportReport
Posted on by 15

I would like to delete the Assembly BOM records for a given Parent_Item_No. I looked at using OData services with a DELETE request and receive a message "'DELETE' requests for 'AssemblyBOM' of EdmType 'Collection' are not allowed within Dynamics 365 Business Central OData web services.

So it appears the AssemblyBOM OData web service does not allow delete requests. Is there any way around this?

I also looked for an API for the Assembly BOM table but that does not seem to exist. Could someone please confirm this?

I have started looking at creating a custom API with AL code to perform the delete. I believe I have found a guide to create a custom codeunit API, however, I can't figure out the AL code required to actually delete the BOM records based on a Parent_Item_No parameter. Any guidance?

I have the same question (0)
  • JAngle Profile Picture
    152 on at

    Even though it’s a few years old now it’s still a handy guide for using each command: community.dynamics.com/.../how-to-create-custom-apis-for-business-central-even-from-macos

    I usually ensure deletion by adding the property for that in the api page. When testing make sure you set the If-Match property for the http call. A wild card is fine in your case. The ondelete trigger of the page will need extra logic to find the extra records. If this is troublesome I would try this method instead: joshanglesea.wordpress.com/.../

    It’s more stand alone as the codeunit will take regular logic like check the item has a BOM if it does then delete all the lines

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

Introducing the 2026 Season 1 community Super Users

Congratulations to our 2026 Super Stars!

Congratulations to our 2025 Community Spotlights

Thanks to all of our 2025 Community Spotlight stars!

Leaderboard > Small and medium business | Business Central, NAV, RMS

#1
OussamaSabbouh Profile Picture

OussamaSabbouh 1,926 Super User 2026 Season 1

#2
YUN ZHU Profile Picture

YUN ZHU 1,158 Super User 2026 Season 1

#3
Khushbu Rajvi. Profile Picture

Khushbu Rajvi. 533 Super User 2026 Season 1

Last 30 days Overall leaderboard

Featured topics

Product updates

Dynamics 365 release plans