Forum Discussion
AI14
3 years agoHelper III
Dynamically Change date range of web source (api link)
Im new to powerquery and have made a connection to a site using APi key. im trying to avoid going into the source every day to look at yesterdays data or any previous day. how can i do this dynamic...
- 3 years ago
AI14You need to include to and from in double quotes .... & "from=" & DateParameter & "to=" & DateParameter & ....
AI14
3 years agoHelper III
ammazing and would this work for both from & to dates?
AntrikshSharma
3 years agoCommunity Champion
AI14 Did you try it?
- AI143 years agoHelper III
Date Parameter works but how do i incoporate it in code.
i tried to put it in like below and i tried how i usually had it "from=dateparameter&" etc.
none worked so far
= Json.Document(Web.Contents("https://www.findmyshift.co.uk/api/1.4/reports/hours?" & "apiKey=xxxxxx&" & "teamId=y22t0l5t4i&" & DateParameter & DateParameter & "timesheetData=yes&" & "additional-columns=staff.jobtitle&" & "additional-columns=staff.department"))
- AntrikshSharma3 years agoCommunity Champion
AI14 You are missing "from" and "to" in your code! Check your question.