March 31 - April 2, 2025, in Las Vegas, Nevada. Use code MSCUST for a $150 discount! Early bird discount ends December 31.
Register NowBe one of the first to start using Fabric Databases. View on-demand sessions with database experts and the Microsoft product team to learn just how easy it is to get started. Watch now
Often, we have to link to website data via API, and we use query parameters for parts of its API.
for example, the parameter 'location' is being used in part of its API as below:
How are we able to bring this parameter 'location' to the UI report itself, such that user has a list of locations to choose from?
Solved! Go to Solution.
Hi @Anonymous,
Use & to combine these strings and
First, you need create a parameter named location or something you like and use this M code to do it:
let
yourkey = "PVACBQ6LTCVBR9NBF529V3H8V",
url = "https://weather.visualcrossing.com/VisualCrossingWebServices/rest/services/timeline/"& location &"?key="& yourkey,
data = Json.Document( Web.Contents(url))
in
data
Reault:
Best Regards
Community Support Team _ chenwu zhu
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
Hi @Anonymous,
Use & to combine these strings and
First, you need create a parameter named location or something you like and use this M code to do it:
let
yourkey = "PVACBQ6LTCVBR9NBF529V3H8V",
url = "https://weather.visualcrossing.com/VisualCrossingWebServices/rest/services/timeline/"& location &"?key="& yourkey,
data = Json.Document( Web.Contents(url))
in
data
Reault:
Best Regards
Community Support Team _ chenwu zhu
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
with the code in M code, I have below error:
@Anonymous
It's a long answer 🙂
Check this official doc:
https://docs.microsoft.com/en-us/power-bi/connect-data/desktop-dynamic-m-query-parameters
Thanks for the link and prompt reply, I will give it a try and let you know 🙂
I am not sure if that works for API, hopefully it works.
@Anonymous I'm not sure also 😃
March 31 - April 2, 2025, in Las Vegas, Nevada. Use code MSCUST for a $150 discount!
Arun Ulag shares exciting details about the Microsoft Fabric Conference 2025, which will be held in Las Vegas, NV.
User | Count |
---|---|
127 | |
84 | |
69 | |
53 | |
44 |
User | Count |
---|---|
202 | |
106 | |
100 | |
64 | |
56 |