How can we improve Power BI?

oauth

Add oauth(2) as an option to authenticate for e.g. web.contents.

577 votes
Sign in
Check!
(thinking…)
Reset
or sign in with
  • facebook
  • google
    Password icon
    Signed in as (Sign out)

    We’ll send you updates on this idea

    Bjoern Sjut shared this idea  ·   ·  Flag idea as inappropriate…  ·  Admin →

    90 comments

    Sign in
    Check!
    (thinking…)
    Reset
    or sign in with
    • facebook
    • google
      Password icon
      Signed in as (Sign out)
      Submitting...
      • Andreas Bosch commented  ·   ·  Flag as inappropriate

        So sad Microsoft is not willing to help us here.

        Maybe this code helps some of you to get it done...

        Copied from

        let
        BaseURL = "https://<domain>.leanix.net", // This is evaluated by Power BI Online to check if auto-refresh is possible without authentication

        AuthKey = "APITOKEN_ENCODED", // Base64 Encoded "apitoken:API Token" string
        AuthHeader = "Basic " & AuthKey, // Concatenate two strings for "Authorization:" Header in POST Request to get OAuth access token
        AuthRelativePath = "services/mtm/v1/oauth2/token", // Here we get our access token from with our AuthKey
        grant_type = "grant_type=client_credentials", // Indicates the type of grant presented in exchange for an authentication token

        Endpoint = "graphql", // The endpoint we are interested in
        EndpointRelativePath = "services/pathfinder/v1/" & Endpoint, // We can call this HTTP REST Endpoint via GET to get all applications as JSON once we have the OAuth acccess Token

        gqlQuery = "{ ""query"": ""{allFactSheets(factSheetType:Application){edges{node{id name description ... on Application{lifecycle{asString} technicalSuitability technicalSuitabilityDescription businessCriticality businessCriticalityDescription functionalSuitability functionalSuitabilityDescription }}}}}}}}""}",

        // We do a HTTP POST Request to BaseURL + AuthRelativePath with our AuthenticationKey in the Header and some extra data to get the access token in JWT format
        JWT = Json.Document(Web.Contents(BaseURL, [RelativePath=AuthRelativePath, Headers=[#"Authorization"=AuthHeader, #"Content-Type"="application/x-www-form-urlencoded"], Content=Text.ToBinary(grant_type)])),

        // OAuth 2.0 authentication is done and we use the access token to construct the Authorization Header for our HTTP GET Requests against the REST API Endpoint
        BearerToken = "Bearer " & JWT[access_token],
        Applications = Json.Document(Web.Contents(BaseURL, [RelativePath=EndpointRelativePath, Headers=[#"Authorization"=BearerToken, #"Content-Type"="application/json"], Content=Text.ToBinary(gqlQuery)]))
        //... (now create your own specific tables)
        in Applications

      • Phil Baker commented  ·   ·  Flag as inappropriate

        Ha ha ha, This is a laughable response. So now I am to either carry on using Basic Auth on my APIs or start telling my customers: "Here download and follow these installation instructions to install this weird file before you can use Power BI for what it was intended to do". That's even worse than asking a client to follow instructions on how to generate an API key and I've never seen that work out well.

        We considered Custom Connectors but didn't want to wear the cost of providing application support to 5000 customers.

        I mean, I had to roll my own Basic Auth provider when we started working onto dotNET Core just to support Power BI and Excel. Did you hear me?! I rolled my own Auth provider to a data API to support your product; that's insane!

        Please reopen this idea, please implement OAuth as a connector. I fail to understand how this can be hard for you to do or what Microsoft's strategic value is in not providing it.

      • Mike commented  ·   ·  Flag as inappropriate

        Daniel there is a link posted in their response on how create custom connections.

      • Daniel (Australia) commented  ·   ·  Flag as inappropriate

        Hi Miguel. I can understand you saying 'not planned', but you have not given us any alternative to connect to API's? Please provide a solution.

      • Pasquale commented  ·   ·  Flag as inappropriate

        Very disappointing. The people was waiting for another kind of response. 581 votes can mean 581 Customers/Leads that potentially it could involve thousand times more users. A better explanation was the minimum.

      • Ionut N commented  ·   ·  Flag as inappropriate

        An unexpected short answer after all that time. How about Power BI Online? What is the story around that ?

      • Anonymous commented  ·   ·  Flag as inappropriate

        The article referenced states : "Data Connectors are currently only supported in Power BI Desktop", so how does this help Power BI Report Server ?

      • Anonymous commented  ·   ·  Flag as inappropriate

        killing the whole idea of self-service bi, making many APIs as data sources out of reach for the common user...

      • Anonymous commented  ·   ·  Flag as inappropriate

        so Microsoft is not going to support a standard that is widely used that customers are asking for and force us to make our own possibly flawed version of the standard ??
        what the heck is going on at HQ ? are you guys in some other world all your own ?

      • Callum commented  ·   ·  Flag as inappropriate

        It's crazy to me that this is still outstanding after over 2 years, especially since there are On-Premise Microsoft products that rely on both OData and OAuth (CRM).

      ← Previous 1 3 4 5

      Feedback and Knowledge Base

      Ready to get started?

      Try new features of Power BI today by signing up and learn more about our powerful suite of apps.