I updated the weather pipe, if you install it again you’ll see a new API call to get weather by zip code.
- You can use any name for the parameters and they most certainly can be loaded from record value.
Just so we’re on the same page:
There are several parts to the URL:
- Parameter Name
- Parameter Value
The parameter name is determined by the API you’re using and must be followed strictly. For example, the Weather API requires a parameter of “appid” Passing a different value will return an error. However, the parameter value (in this case appid value) is dynamic.
appid is the parameter name
123456 is the parameter value.
The parameter value is a value you pass along with your request. Since parameter values are generally dynamic and not hardcoded, you can create custom parameters that will change these values on the fly. This is where the parameters tab comes in. You can create a parameter name which can be any text of your choosing, and the slug can also be anything you choose. The key here is to ensure that the slug you choose matches the slug you put in the URL.
From this example, the Parameter Name of “zip” is not something we can tweak, since this is how the API will utilize this API call.
If the request parameter name (not value) requires a space (for example if it required it to be as follows:
http://api.openweathermap.org/data/2.5/forecast/daily?zip code= the “zip code” part (which contains a space) will get auto URL encoded and it will still work.