API call to obtain table with hourly forecast only #1052
-
|
API doc shows how to get the API call and a preview of the trends you will get. However, when using the URL, a JSON with three elements appear.
Is there an option to modify the API call so only only the hourly data table is obtained? It will be even better to get location as additional columns that don't change over time in this second table. |
Beta Was this translation helpful? Give feedback.
Replies: 2 comments 2 replies
-
|
Do you mean CSV? JSON has no tables |
Beta Was this translation helpful? Give feedback.
-
|
You can easily parse the |
Beta Was this translation helpful? Give feedback.
If you add
&format=csvto the API URL, it will return data in CSV. It will directly prompt you to download a file, because the HTTP content disposition headers are set. E.g. https://api.open-meteo.com/v1/forecast?latitude=52.52&longitude=13.41&hourly=temperature_2m&format=csvOtherwise as @guidocioni wrote, use Python to format the data however you like to :)