Forum Discussion
Connect to a Web Service sending parameters
- Anonymous9 years ago
got my query working.
Thanks everyone.
I think you need to check the API-documentation for that.
Check out this post with a sample for a Dropbox-connector: https://community.powerbi.com/t5/Integrations-with-Files-and/Connecting-to-data-source-hosted-on-Dropbox/td-p/67946
- MAS423 years agoFrequent Visitor
Hi ImkeF.
I'm afraid I have yet Another API question.
I am new to API’s and have been trying to do a POST request to get some timesheet data. However, whatever code I try to use fails (it seems like the body/query is the main issue). My latest attempt is below and it’s giving me an error on “StartDate”. Are you able to help before I consider changing careers!
let
url = "myurl ",
auth_key = GetAccessToken,
header= [#"Authorization" = auth_key,
#"Content-Type" = "application/json; charset=utf-8"],
query = [
""StartDate"":""2022-10-31T00:00:00"",
""EndDate"":""2022-11-10T00:00:00"",
""fields"":""[Date, Status, CompanyName, CompanyReference, ApproverName, EntryQuantity]"",
""TimesheetStatusFilters"":""[Approved, Exported]""
],
webdata = Web.Contents(url, [Headers=header,Query = query]),
response = Json.Document(webdata)
in
response
Many thanks