Rotate the webhook's signing secret
https://platform.casafari.com/v1/alerts/webhooks/rotate-secretEnvoyez Authorization: Bearer $CASAFARI_API_KEY : une clé API de plateforme (cf_sk_...) disponible dans la console, ou un jeton d'accès OAuth ; X-API-Key permet également de transmettre la clé. Consultez les clés API de plateforme. Gratuit : 0 jeton.
The platform's OpenAPI file leaves the shape open; what is shown comes from the same definitions the platform publishes elsewhere: request: the description of the same backend; response 200: the hub's fragment from the platform's contract.
Via MCP : aucun ; ce produit est réservé à l'API REST.
Description
Gratuit (n'utilise aucun jeton).
Corps de la requête
Type de contenu application/json. Facultatif. Type : object.
immediatebooléenExemple de requête
Espaces réservés uniquement : remplacez le jeton et les valeurs par les vôtres.
curl -X POST "https://platform.casafari.com/v1/alerts/webhooks/rotate-secret" \
-H "Authorization: Bearer $CASAFARI_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"immediate": false
}'Réponses
200 Success.
Type : object.
Afficher la structure de la réponse (1 champ)
secretchaîne de caractèresrequiswhsec_…).Exemple avec des valeurs types (les identifiants et les chiffres sont fournis à titre d'illustration)
{
"secret": "whsec_Q2nV8xR4tY6uI1oP3aS5dF7gH9jK0lZc"
}Erreurs
Chaque erreur renvoie un corps application/problem+json (RFC 9457) incluant type (une page explicative), title, status, detail (la marche à suivre), instance, code et request_id (à citer lors d'une demande au support). Un code 402 comporte une upgrade_url, et un 429 un en-tête Retry-After. Les codes associés à chaque statut :
- 400
invalid_request,key_in_query(https://platform.casafari.com/errors/invalid-request, https://platform.casafari.com/errors/key-in-query) - 401
unauthorized,invalid_credential,credential_revoked,token_expired(https://platform.casafari.com/errors/unauthorized, https://platform.casafari.com/errors/invalid-credential, https://platform.casafari.com/errors/credential-revoked, https://platform.casafari.com/errors/token-expired) - 403
insufficient_scope,not_entitled,account_suspended(https://platform.casafari.com/errors/insufficient-scope, https://platform.casafari.com/errors/not-entitled, https://platform.casafari.com/errors/account-suspended) - 404
not_found(https://platform.casafari.com/errors/not-found) - 405
method_not_allowed(https://platform.casafari.com/errors/method-not-allowed) - 409
conflict(https://platform.casafari.com/errors/conflict) - 413
payload_too_large(https://platform.casafari.com/errors/payload-too-large) - 415
unsupported_media_type(https://platform.casafari.com/errors/unsupported-media-type) - 422
validation_failed(https://platform.casafari.com/errors/validation-failed) - 429
rate_limited,request_limit_reached(https://platform.casafari.com/errors/rate-limited, https://platform.casafari.com/errors/request-limit-reached) - 500
internal_error(https://platform.casafari.com/errors/internal-error) - 502
upstream_error(https://platform.casafari.com/errors/upstream-error) - 503
unavailable(https://platform.casafari.com/errors/unavailable) - 504
upstream_timeout(https://platform.casafari.com/errors/upstream-timeout)