Skip to content
PUT /automation/{id}/webhook/{triggerKey}/secret

hmac endpoints only; the secret is the sender’s own. Never echoed back. The previous secret keeps verifying for `grace_seconds` (0 to 86400, default 86400); 0 cuts it off immediately. 503 `automation_unavailable` means the new secret could not be applied to the live endpoint yet: retry.

Path Parameters

idstring
required·

Resource id

triggerKeystring
required·

Webhook trigger key within the workflow

Request Body

grace_secondsinteger
secretstring

Response Body

can_manageboolean
created_atstring
endpoint_idstring
presetstring,null
previous_secret_expires_atstring,null
rotated_atstring,null
schemestring
Possible values:
standardhmactoken
secret_statestring
Possible values:
unrevealedrevealedprovidedmissing
statusstring
Possible values:
activeneeds_secretdraft_only
trigger_keystring
urlstring
curl -X PUT 'https://api.elaichi.ai/automation/<id>/webhook/<triggerKey>/secret' \
  -H 'Authorization: Bearer $ELAICHI_API_TOKEN' \
  -H 'Content-Type: application/json' \
  -d '{"secret":"your_secret","grace_seconds":0}'
const body = {
  "secret": "your_secret",
  "grace_seconds": 0
};

const response = await fetch('https://api.elaichi.ai/automation/<id>/webhook/<triggerKey>/secret', {
  method: 'PUT',
  headers: {
    'Authorization': 'Bearer ' + process.env.ELAICHI_API_TOKEN,
    'Content-Type': 'application/json',
  },
  body: JSON.stringify(body),
});

const data = await response.json();
console.log(data);
import os
import requests

url = "https://api.elaichi.ai/automation/<id>/webhook/<triggerKey>/secret"
headers = {
    "Authorization": f"Bearer {os.environ['ELAICHI_API_TOKEN']}",
    "Content-Type": "application/json",
}
payload = {
    "secret": "your_secret",
    "grace_seconds": 0
}

response = requests.put(url, headers=headers, json=payload)
print(response.json())