Skip to content

Instantly share code, notes, and snippets.

@dale3h
Created May 15, 2019 04:45
Show Gist options
  • Star 9 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save dale3h/62cc5a9a359c75d4efc8d1b2df777b10 to your computer and use it in GitHub Desktop.
Save dale3h/62cc5a9a359c75d4efc8d1b2df777b10 to your computer and use it in GitHub Desktop.
[Home Assistant] Webhook Debugger
# Webhook URL: https://[your-hass-domain]/api/webhook/2qDFuSEBA7jU2sNjaK6JD5ac3FxnGfVTSF
- id: webhook_debugger
alias: "Webhook Debugger"
trigger:
- platform: webhook
webhook_id: 2qDFuSEBA7jU2sNjaK6JD5ac3FxnGfVTSF
action:
- service: persistent_notification.create
data_template:
message: >-
{% if 'data' in trigger %}
Data: {{ dict(trigger.data)|tojson }}
{% elif 'json' in trigger %}
JSON: {{ dict(trigger.json)|tojson }}
{% endif %}
{% if 'query' in trigger and trigger.query|length > 0 %}
Query: {{ dict(trigger.query)|tojson }}
{% endif %}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment