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

Announcements

News and Announcements icon
Community site session details

Community site session details

Session Id :
Power Platform Community / Forums / Power Automate / How to access Power BI...
Power Automate
Unanswered

How to access Power BI REST API token in Power Automate

(1) ShareShare
ReportReport
Posted on by 5

Hello,

 

I'm trying to get all the user event activities in Power BI via rest api in automate, the problem is the rest api token i got directly from microsoft user account expires every 1h, so I'm trying to call this token directly from Power Automate using tenant id, client id and other credential info. but it seems that 1) it didnt match with my token that i got from microsoft account  2) i would like to use enviroment variables to hide my personal data but i didnt find this setting in power automate.

Anyone has similar experience about this? thanks 

 

see my workflow below, now i just manually input my token every hour

Penn_0-1720023323202.png

 

Best 

Penn 

Categories:
  • SudeepGhatakNZ Profile Picture
    14,396 Most Valuable Professional on at

    Can you expand your HTTP action?

     

  • Penn Profile Picture
    5 on at

    Hi Sudeep,

     

    My http code is as below:

    {
      "type": "Http",
      "inputs": {
        "method": "GET",
        "queries": {
          "startDateTime": "'@{variables('startTime')}'",
          "endDateTime": "'@{variables('endTime')}'",
          "$filter\n": "Activity eq 'ViewReport'"
        },
        "authentication": {
          "type": "Raw",
          "value": "@variables('Token')"
        }
      },
      "runAfter": {
        "IsMoreData": [
          "Succeeded"
        ]
      },
     
     
    Best 
    Penn
  • SudeepGhatakNZ Profile Picture
    14,396 Most Valuable Professional on at

    @Penn 

    I think you should register an Azure AD App for authentication. Check this out for detailed steps.

    This will let you leverage AD OAuth authentication.

    Call Power BI Rest APIs with Power Automate (vahiddm.com)

     

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!

Kudos to our 2025 Community Spotlight Honorees

Expanding mentorship, skilling, and AI innovation

Leaderboard > Power Automate

#1
11manish Profile Picture

11manish 307 Super User 2026 Season 2

#2
Mohsin Ali Profile Picture

Mohsin Ali 289

#3
Henil Profile Picture

Henil 127

Last 30 days Overall leaderboard