Forum Discussion

VendettaBob's avatar
VendettaBob
Helper II
5 years ago
Solved

PowerBI Rest API to export report as PNG file

Hi,   We are using PowerBI Pro.    We want to utilise the PowerBI rest API to export reports as PNG files and  to email these out to customers.   Is this possible to do using the REST API:   ...
  • v-luwang-msft's avatar
    5 years ago

    Hi VendettaBob ,

    Official article announced on March 6, 2020  that allowed you to export a Power BI report by using a REST call, to the following file formats: PDF, PPTX (PowerPoint) and PNG.

    Send to print button – In your application, create a button that when clicked on triggers an export job. The job can export the viewed report as a PDF or a PPTX, and when it’s complete, the user can receive the file as a download. As the API is asynchronous, it may take some time for the file to be available.

    Email attachment – Send an automated email at set intervals, with an attached PDF report. This scenario can be useful if you want to automate sending a weekly report to executives.

    When the Export-To-File API is called, it triggers an export job. After triggering the export job, you can use the Polling API to track the job until it is complete. When the export job is complete, the Polling API call returns a Power BI URL for getting the file (The URL is available for 24 hours). The API supports concurrent export job requests. The number of jobs you can run at the same time, depends on the SKU your report resides on, as detailed in this table.

     

    Wish it is helpful for you!

     

    Best Regards

    Lucien