Skip to main content
cancel
Showing results for 
Search instead for 
Did you mean: 

Enhance your career with this limited time 50% discount on Fabric and Power BI exams. Ends August 31st. Request your voucher.

Reply
bsushy
Frequent Visitor

Power BI Embedded API - PostImportWithFile returns "Internal Server Error" - pbix file 1.2gb

Hi,

We are using the API to programatically upload a file. Everything was going well until we tried to upload a 1.2gb file. 

 

I found from the community that you can supply us with a direct URL to our local PowerBI workspace cluster. See below:

 

For anyone with same issue, the problem is in using the base url https://api.powerbi.com. As per Microsoft support, when using this base url and importing large PBIX files, it has a tendency to timeout the file stream, thus throwing the exception. Microsoft support provided a direct URL to our local Power Bi Workspace cluster and the issue was resolved.

 

We are using the EASTUS location. 

 

Than you in advance

1 REPLY 1
v-ljerr-msft
Microsoft Employee
Microsoft Employee

Hi @bsushy,

Absolutely. When the workspace collections are created with the Azure dashboard, there is a choice of location to select (i.e. East US 2, West US 1, etc.). These are their clusters for Power BI workspace collections and they have direct API URLs to these clusters so instead of https://api.powerbi.com, one would use the direct URL to the Azure cluster location where your workspace collections are hosted. For my case scenario, we have all of our workspace collections hosted in the same cluster location so I just had to use the direct URL instead of https://api.powerbi.com and the filestream timeouts (including the vague Internal Server Error exception returned by the PostImportWithFile method) were gone. Just check with your Microsoft support rep for your Power BI cluster's direct URL if you have to import larger PBIX files.

As suggested by @albin-ipmg in this similar thread, you may need to create a support ticket on Power BI Support page for better assistance on this issue. Smiley Happy

 

Regards

Helpful resources

Announcements
July 2025 community update carousel

Fabric Community Update - July 2025

Find out what's new and trending in the Fabric community.

July PBI25 Carousel

Power BI Monthly Update - July 2025

Check out the July 2025 Power BI update to learn about new features.

Join our Fabric User Panel

Join our Fabric User Panel

This is your chance to engage directly with the engineering team behind Fabric and Power BI. Share your experiences and shape the future.