Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add a webhook automation trigger #17246

Merged
merged 1 commit into from
Oct 8, 2018
Merged

Add a webhook automation trigger #17246

merged 1 commit into from
Oct 8, 2018

Conversation

balloob
Copy link
Member

@balloob balloob commented Oct 8, 2018

Description:

This adds a webhook automation trigger. Supports both JSON and POST requests. Allows users to register webhooks and have that data be routed to their automations.

Allows users to easily send data in their local network to Home Assistant in a secure way without dealing with all the auth stuff.

Example entry for configuration.yaml (if applicable):

automation:
  trigger:
    platform: webhook
    webhook_id: hello-super-webhook
  action:
    service: light.turn_on
    data_template:
      entity_id: '{{ trigger.json.entity_id }}'

And then from your external scripts send JSON or POST data to http://hassio.local:8123/api/webhook/hello-super-webhook

Checklist:

  • The code change is tested and works locally.
  • Local tests pass with tox. Your PR cannot be merged unless tests pass

If the code does not interact with devices:

  • Tests have been added to verify that the new code works.

@balloob balloob merged commit 68472b8 into dev Oct 8, 2018
@ghost ghost removed the in progress label Oct 8, 2018
@balloob balloob deleted the automation-webhook branch October 8, 2018 18:16
@balloob balloob added this to the 0.80 milestone Oct 8, 2018
balloob added a commit that referenced this pull request Oct 9, 2018
@balloob balloob mentioned this pull request Oct 12, 2018
@home-assistant home-assistant locked and limited conversation to collaborators Feb 5, 2019
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants