Add webhook trigger condition for automations
Per-automation webhook URL with auto-generated 128-bit hex token.
External services (Home Assistant, IFTTT, curl) can POST to
/api/v1/webhooks/{token} with {"action": "activate"|"deactivate"}
to control automation state — no API key required (token is auth).
Backend: WebhookCondition model, engine state tracking with
immediate evaluation, webhook endpoint, schema/route updates.
Frontend: webhook option in condition editor, URL display with
copy button, card badge, i18n for en/ru/zh.
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
This commit is contained in:
@@ -607,6 +607,12 @@
|
||||
"automations.condition.mqtt.match_mode.contains": "Содержит",
|
||||
"automations.condition.mqtt.match_mode.regex": "Регулярное выражение",
|
||||
"automations.condition.mqtt.hint": "Активировать при получении совпадающего значения по MQTT топику",
|
||||
"automations.condition.webhook": "Вебхук",
|
||||
"automations.condition.webhook.hint": "Активировать через HTTP-запрос от внешних сервисов (Home Assistant, IFTTT, curl и т.д.)",
|
||||
"automations.condition.webhook.url": "URL вебхука:",
|
||||
"automations.condition.webhook.copy": "Скопировать",
|
||||
"automations.condition.webhook.copied": "Скопировано!",
|
||||
"automations.condition.webhook.save_first": "Сначала сохраните автоматизацию для генерации URL вебхука",
|
||||
"automations.scene": "Сцена:",
|
||||
"automations.scene.hint": "Пресет сцены для активации при выполнении условий",
|
||||
"automations.scene.search_placeholder": "Поиск сцен...",
|
||||
|
||||
Reference in New Issue
Block a user