Malfonction API meteo france

Bonjour à tous,
Comme beaucoup j’attendais avec impatience l’ouverture en opendata des données de météofrance mais je bute sur un problème avec l’API des données d’observations sur la route « /station/horaire ».
En effet cette requête permet normalement de pouvoir récupérer les données en fonction de l’id_station (ce qui fonctionne très bien) mais aussi de la date, le problème étant que peut importe la date que j’envoi à l’API je me retrouve avec les même valeurs pour tout les champs.
L’API étant très peu documenté il est même compliqué de comprendre à quoi correspondent les valeurs que l’on recupère notamment les dates.
Est-ce que quelqu’un qui aurait un petit peu de temps pourrait tester de son côté pour voir si il a le même probleme :slight_smile: ?

PS: voici quelques log pour mieux comprendre

01/02/24 14:48:14 - [INFO] - Getting token
01/02/24 14:48:14 - [INFO] - Token received, duration time: 3600 seconds
01/02/24 14:48:15 - [INFO] - Calling: https://public-api.meteofrance.fr/public/DPObs/v1/station/horaire?id_station=31011001&date=2023-01-01T12:00:00Z&format=json
01/02/24 14:48:15 - [INFO] - Temperature received for the 01/1/2023 at 12:00 , Tmin: 15.7, Tmax: 16.4, T: 16.3
01/02/24 14:48:15 - [INFO] - Calling: https://public-api.meteofrance.fr/public/DPObs/v1/station/horaire?id_station=31011001&date=2023-02-01T12:00:00Z&format=json
01/02/24 14:48:15 - [INFO] - Temperature received for the 01/2/2023 at 12:00 , Tmin: 15.7, Tmax: 16.4, T: 16.3
01/02/24 14:48:15 - [INFO] - Calling: https://public-api.meteofrance.fr/public/DPObs/v1/station/horaire?id_station=31011001&date=2023-03-01T12:00:00Z&format=json
01/02/24 14:48:15 - [INFO] - Temperature received for the 01/3/2023 at 12:00 , Tmin: 15.7, Tmax: 16.4, T: 16.3
01/02/24 14:48:15 - [INFO] - Calling: https://public-api.meteofrance.fr/public/DPObs/v1/station/horaire?id_station=31011001&date=2023-04-01T12:00:00Z&format=json
01/02/24 14:48:15 - [INFO] - Temperature received for the 01/4/2023 at 12:00 , Tmin: 15.7, Tmax: 16.4, T: 16.3
01/02/24 14:48:15 - [INFO] - Calling: https://public-api.meteofrance.fr/public/DPObs/v1/station/horaire?id_station=31011001&date=2023-05-01T12:00:00Z&format=json
01/02/24 14:48:15 - [INFO] - Temperature received for the 01/5/2023 at 12:00 , Tmin: 15.7, Tmax: 16.4, T: 16.3
01/02/24 14:48:15 - [INFO] - Calling: https://public-api.meteofrance.fr/public/DPObs/v1/station/horaire?id_station=31011001&date=2023-06-01T12:00:00Z&format=json
01/02/24 14:48:15 - [INFO] - Temperature received for the 01/6/2023 at 12:00 , Tmin: 15.7, Tmax: 16.4, T: 16.3
01/02/24 14:48:16 - [INFO] - Calling: https://public-api.meteofrance.fr/public/DPObs/v1/station/horaire?id_station=31011001&date=2023-07-01T12:00:00Z&format=json
01/02/24 14:48:16 - [INFO] - Temperature received for the 01/7/2023 at 12:00 , Tmin: 15.7, Tmax: 16.4, T: 16.3
01/02/24 14:48:16 - [INFO] - Calling: https://public-api.meteofrance.fr/public/DPObs/v1/station/horaire?id_station=31011001&date=2023-08-01T12:00:00Z&format=json
01/02/24 14:48:16 - [INFO] - Temperature received for the 01/8/2023 at 12:00 , Tmin: 15.7, Tmax: 16.4, T: 16.3
01/02/24 14:48:16 - [INFO] - Calling: https://public-api.meteofrance.fr/public/DPObs/v1/station/horaire?id_station=31011001&date=2023-09-01T12:00:00Z&format=json
01/02/24 14:48:16 - [INFO] - Temperature received for the 01/9/2023 at 12:00 , Tmin: 15.7, Tmax: 16.4, T: 16.3
01/02/24 14:48:16 - [INFO] - Calling: https://public-api.meteofrance.fr/public/DPObs/v1/station/horaire?id_station=31011001&date=2023-10-01T12:00:00Z&format=json
01/02/24 14:48:16 - [INFO] - Temperature received for the 01/10/2023 at 12:00 , Tmin: 15.7, Tmax: 16.4, T: 16.3
01/02/24 14:48:16 - [INFO] - Calling: https://public-api.meteofrance.fr/public/DPObs/v1/station/horaire?id_station=31011001&date=2023-11-01T12:00:00Z&format=json
01/02/24 14:48:16 - [INFO] - Temperature received for the 01/11/2023 at 12:00 , Tmin: 15.7, Tmax: 16.4, T: 16.3
01/02/24 14:48:16 - [INFO] - Calling: https://public-api.meteofrance.fr/public/DPObs/v1/station/horaire?id_station=31011001&date=2023-12-01T12:00:00Z&format=json
01/02/24 14:48:16 - [INFO] - Temperature received for the 01/12/2023 at 12:00 , Tmin: 15.7, Tmax: 16.4, T: 16.3

Je m’excuse, j’ai recu la reponse du support de meteofrance et je n’utilisé simplement pas la bonne API :sweat_smile:.

1 « J'aime »

Bonjour @I3UX;
J’ai le même problème. J’ai vu qu’il y a une autre route qui pourrait le faire ( /paquet/stations/horaire ) mais j’obtiens un csv avec seulement le header (pas de données). Quelle a été ta solution ?
Merci

Bonjour @pierreloicq ,
J’ai finalement utilisé cette API METEO FRANCE – L’API DonneesPubliquesClimatologie. Elle fonctionne avec un systeme de commande qu’il faut demander au serveur de preparer puis à récuperer. Attention ta commande ne peux pas depasser une période de plus de 1ans :confused: . En plus l’API à quelque mal fonction au niveau de sa gateway et peut te renvoyer des erreur http 502 sans raison (La meme requete peut aboutir ou non :man_shrugging:).
J’espere avoir répondu à ta question.
Bonne journée,
IEUX!

Merci beaucoup, ça marche ! :heart_eyes: