API Notifications
Maintenu par : Aether365 Team Public : Développeurs Périmètre : Endpoints de l'API pour les paramètres de notification
Gérez les paramètres de notification par e-mail et Teams pour le tenant authentifié.
Obtenir les paramètres de notification
GET /tenants/me/notificationsExemple de requête
bash
curl https://api.aether365.io/tenants/me/notifications \
-H "Authorization: Bearer <token>"Exemple de réponse
json
{
"success": true,
"data": {
"emailOnComplete": true,
"emailOnFail": true,
"teamsWebhookUrl": "https://outlook.office.com/webhook/...",
"teamsOnComplete": true,
"teamsOnFail": true
}
}Champs de la réponse
| Champ | Type | Description |
|---|---|---|
emailOnComplete | boolean | Envoyer un e-mail quand une analyse se termine avec succès |
emailOnFail | boolean | Envoyer un e-mail quand une analyse échoue |
teamsWebhookUrl | string ou null | URL du webhook entrant Microsoft Teams |
teamsOnComplete | boolean | Publier dans Teams quand une analyse se termine |
teamsOnFail | boolean | Publier dans Teams quand une analyse échoue |
Mettre à jour les paramètres de notification
Met à jour les paramètres de notification. Seuls les champs inclus sont modifiés.
PATCH /tenants/me/notificationsCorps de la requête
Tous les champs sont optionnels. N'incluez que les champs que vous souhaitez modifier.
json
{
"emailOnComplete": true,
"emailOnFail": true,
"teamsWebhookUrl": "https://outlook.office.com/webhook/...",
"teamsOnComplete": true,
"teamsOnFail": false
}Exemple : Activer les notifications Teams
bash
curl -X PATCH https://api.aether365.io/tenants/me/notifications \
-H "Authorization: Bearer <token>" \
-H "Content-Type: application/json" \
-d '{
"teamsWebhookUrl": "https://outlook.office.com/webhook/your-webhook-url",
"teamsOnComplete": true,
"teamsOnFail": true
}'Exemple : Désactiver toutes les notifications par e-mail
bash
curl -X PATCH https://api.aether365.io/tenants/me/notifications \
-H "Authorization: Bearer <token>" \
-H "Content-Type: application/json" \
-d '{
"emailOnComplete": false,
"emailOnFail": false
}'Exemple de réponse
json
{
"success": true,
"data": {
"emailOnComplete": false,
"emailOnFail": false,
"teamsWebhookUrl": "https://outlook.office.com/webhook/...",
"teamsOnComplete": true,
"teamsOnFail": true
}
}Erreurs
| Code | HTTP | Description |
|---|---|---|
AUTH_INSUFFICIENT_SCOPE | 403 | Permissions insuffisantes pour cette action |
VALIDATION_ERROR | 400 | Format d'URL de webhook invalide |