Méthode POST permettant de publier une météo en construction.
Peut être appelé sur une météo déjà publiée.
Le paramètre ID reçu dans l'URL identifie la vue météo à publier.
| Codes de retour | Explications |
|---|---|
| 200 | OK |
| 401 | L'accès nécessite une authentification ou un Token valide. |
| 403 | Authentification de l'utilisateur OK, mais droits non suffisants. |
| 404 | La vue météo n'existe pas. |
| 500 | L'appel est valide, mais un problème d'exécution est rencontré. |
curl -s -S -U 'username:password' -X POST \ "http://webui:7767/external-api/service-weather/v1/publish/WEATHER_UUID" |
Exemple de sortie attendue :
{
"output": {
"view_info": {
"name": "Bordeaux",
"state": "published",
"type": "service_weather",
"weather_uuid": "ab512c70e84a4c7a9b0e23b46eec5355",
"weather_version": 3,
"weather_format_version": 5,
"weather_shared_group": "service_weather",
"weather_creation_time": 1787666586.1508853
}
}
} |
curl -s -S -U 'username:password' -X POST \ "http://webui:7767/external-api/service-weather/v1/publish/unknown_uuid" |
{
"output": "Weather with uuid [ unknown_uuid ] was not found"
} |