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

Notifications

Announcements

No record found.

Community site session details

Community site session details

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

Import files XML into Business Central from OneDrive

(3) ShareShare
ReportReport
Posted on by 104
Hello,
I am importing XML files into Business Central Cloud from a OneDrive folder. I have already configured everything in Microsoft Entra using the Microsoft Graph API. Previously, it was working in one environment, but after switching to another environment, I get the following message when executing httpclient.Send():
Error: 400 - The request was blocked by the runtime to prevent accidental use of production services.
I appreciate any help.
I have the same question (0)
  • Ramesh Kumar Profile Picture
    7,527 Super User 2025 Season 2 on at
    Double-check your API environment settings in Microsoft Entra (Azure AD) to ensure that the environment you're switching to is properly configured for the new environment.
     
    Ensure that the environment variables (like client ID, secret, and tenant ID) are updated to match the new environment.
     
     
    Thanks
    Ramesh
     
    If this was helpful, please check the "Does this answer your question?" box and mark it as verified.
     
  • Michel Chacaliaza Profile Picture
    104 on at
    If all of that is already configured and working, I even tested it from Postman, and it connects to OneDrive, returning the XML file information.
    The problem is that Business Central does not allow the connection to OneDrive and still returns Error 400.
    I appreciate any help.
  • Verified answer
    YUN ZHU Profile Picture
    95,681 Super User 2025 Season 2 on at
    Hi, hope the following can give you some hints.
    Dynamics 365 Business Central: How to import/read files from OneDrive to Business Central via AL (Graph API)
     
    Thanks.
    ZHU
  • Suggested answer
    Michel Chacaliaza Profile Picture
    104 on at

    Thank you, Zhu! I have already found the solution.

    Many thanks.

  • Verified answer
    Khushbu Rajvi. Profile Picture
    20,441 Super User 2025 Season 2 on at
  • Verified answer
    Gerardo Rentería García Profile Picture
    25,225 Most Valuable Professional on at

    Hi, good day
    I hope this can help you, and give you some hints.

    The request was blocked by the runtime to prevent accidental use of production services. - TharangaC

    Best Regards
    Gerardo

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

Responsible AI policies

As AI tools become more common, we’re introducing a Responsible AI Use…

Neeraj Kumar – Community Spotlight

We are honored to recognize Neeraj Kumar as our Community Spotlight honoree for…

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

#1
OussamaSabbouh Profile Picture

OussamaSabbouh 2,606

#2
YUN ZHU Profile Picture

YUN ZHU 931 Super User 2025 Season 2

#3
Jainam M. Kothari Profile Picture

Jainam M. Kothari 773 Super User 2025 Season 2

Last 30 days Overall leaderboard

Featured topics

Product updates

Dynamics 365 release plans