Forum Discussion

SWhiteMKL's avatar
SWhiteMKL
Frequent Visitor
2 years ago
Solved

Dataset Refresh using a trigger

Hi all,

 

We currently have a set up automated report and cube builds that are migrating from Cognos to PowerBI.  As part of the update cycle we have automation that triggers the rebuild of these Cognos objects by calling a batch file to initiate the process.  The batch is part of a larger in place orchestrator so I was wondering if there was a way to use a batch file but trigger the PowerBI execution.  This keeps the existing pipeline intact and allows us to trigger the PowerBI refresh on the same schedule.  We are just tying to minimize the pipeline rewrite if possible.

 

Thanks,

Steve

  • Yes, you can initiate a refresh request for a Semantic model via API calls.  In fact, you can even request refresh of a single table or even a partition (if you use incremental refresh).

     

    These API calls can be done from PowerShell or from PowerAutomate or from any otther tool that allow (automatic) OAUTh2/AAD authentification.

     

    Note that these calls only refresh a request.  For refresh monitoring you need to create additional processes.

  • Thanks so much for the help.  We were able to get the triggers working and the refreshes are executing based on a database event now.

3 Replies

  • Yes, you can initiate a refresh request for a Semantic model via API calls.  In fact, you can even request refresh of a single table or even a partition (if you use incremental refresh).

     

    These API calls can be done from PowerShell or from PowerAutomate or from any otther tool that allow (automatic) OAUTh2/AAD authentification.

     

    Note that these calls only refresh a request.  For refresh monitoring you need to create additional processes.

    • SWhiteMKL's avatar
      SWhiteMKL
      Frequent Visitor

      Thanks so much for the help.  We were able to get the triggers working and the refreshes are executing based on a database event now.

  • Anonymous's avatar
    Anonymous
    Not applicable

    Thanks for the reply from lbendlin , please allow me to provide another insight:

     

    Hi SWhiteMKL ,

     

    As a supplement, to trigger a Power BI dataset refresh using a batch file, you can use the Power BI REST API, specifically the Refresh Dataset API.This API allows you to programmatically trigger a dataset refresh in Power BI, which is a great fit for integrating into your existing batch file-driven processes.

     

    For more details, you can read below document:

    Datasets - Refresh Dataset - REST API (Power BI Power BI REST APIs) | Microsoft Learn

     

    Best Regards,
    Adamk Kong

     

    If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.