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...
Suggested Answer

API Error when fetching SalesOrder

(0) ShareShare
ReportReport
Posted on by 35

Hi ,

I'm getting error when trying to fetch SalesOrders from Business Central using Odata API

Request:"/api/v2.0/companies(9ec36eeb-f404-eb11-aa61-000d3aab094d)/salesOrders?$filter=lastModifiedDateTime+ge+2021-02-08T08:49:21Z&$orderby=lastModifiedDateTime+asc&$top=1000&$skip=0&$expand=salesOrderLines($filter=lineType eq 'Comment' or lineType eq 'Item' or lineType eq 'Account';$orderby=sequence)"

Response:"{\"error\":{\"code\":\"Application_DialogException\",\"message\":\"The maximum Invoice Discount Amount that you can apply is 4,224.04.  CorrelationId:  6ff97399-ed67-4597-924d-90ef8020bf3c.\"}}"

Can anyone has idea why am i getting this error and how to fix this?

Looking forward to your responses.

Thanks & Regards,

Ankit

  • Suggested answer
    Marco Mels Profile Picture
    Microsoft Employee on at

    Hello,

    Best is probably to raise this as an issue to Microsoft via your CSP or partner.

    Thanks.

  • MadsG Profile Picture
    on at

    Did you manage to find a solution to this? We got same error. Thanks

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

Season of Sharing Community Challenge Winners!

Congratulations to our community stars!

Women in Power Builds Momentum

Expanding mentorship, skilling, and AI innovation

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

#1
OussamaSabbouh Profile Picture

OussamaSabbouh 569 Super User 2026 Season 2

#2
YUN ZHU Profile Picture

YUN ZHU 375 Super User 2026 Season 2

#3
Grigorios Mavrogeorgis Profile Picture

Grigorios Mavrogeorgis 228 Super User 2026 Season 2

Last 30 days Overall leaderboard

Featured topics

Microsoft Training Manuals

Product updates

Dynamics 365 release plans