Forum Discussion

BH22One's avatar
BH22One
Helper I
4 years ago
Solved

JSON API Call Script Help

Good Afternoon PBI Community,   I am fairly new to JSON language as it pertains to APIs. Currently, I have an M script in Power Query that returns a binary list as seen below (FYI I have a Bearer T...
  • Anonymous's avatar
    Anonymous
    4 years ago

    Hi BH22One , does the following work:

     

    let
        Source = 
        Csv.Document( 
            Web.Contents(
                "https://US.api.blackline.com/api/completedqueryrun/",
                [
                    RelativePath = GetReportId() &"/CSV",
                    Timeout=#duration(0, 0, 30, 0),
                    Headers=[Authorization="Bearer "& GetAccessToken(), #"Content-Type"="application/octet-stream"]
                ]
        ), 
        [
            Delimiter=",",
            Columns=13, 
            Encoding=65001, 
            QuoteStyle=QuoteStyle.None
        ]
    )