Forum Discussion
Anonymous
5 years agoNot applicable
Call Rest API from Advanced Editor
I'm new to PowerBI and have a simple web API i typically call in python. I used the Advanced Editor in PowerBI. It it telling the syntax is good, but then i get the error: "Expression.Error: We ca...
Anonymous
5 years agoNot applicable
I've tried to use Web.Contents() like this:
let
apiUrl = "http://someserver:7979/v1/completed_detail",
body = "{""submission_id"" :""01-25-2021-15-47-25""}",
result = Json.Document(Web.Contents(apiUrl, [Headers = [#"Content-Type"="application/json"], Content = Text.ToBinary(body)]))
in
#"result"But getting error:
DataSource.Error: Web.Contents failed to get contents from 'http://someserver:7979/v1/completed_detail' (405): METHOD NOT ALLOWED
Details:
DataSourceKind=Web
DataSourcePath=http://someserver:7979/v1/completed_detail
Url=http://someserver:7979/v1/completed_detail