Webhook error

I have tried setting up a webhook to be triggered through a flic button. I created the weebhook through Nabu Casa.

My HASS instans is receiving something, but an error occure during the process of the webhook. I am not able to decifer the log, though. Can anyone help me?

log:

Error processing webhook flic
Traceback (most recent call last):
File “/usr/local/lib/python3.7/site-packages/homeassistant/components/webhook/init.py”, line 85, in async_handle_webhook
response = await webhook[‘handler’](hass, webhook_id, request)
File “/usr/local/lib/python3.7/site-packages/homeassistant/components/automation/webhook.py”, line 32, in _handle_webhook
result[‘json’] = await request.json()
File “/usr/local/lib/python3.7/site-packages/homeassistant/util/aiohttp.py”, line 35, in json
return json.loads(self._text)
File “/usr/local/lib/python3.7/json/init.py”, line 348, in loads
return _default_decoder.decode(s)
File “/usr/local/lib/python3.7/json/decoder.py”, line 337, in decode
obj, end = self.raw_decode(s, idx=_w(s, 0).end())
File “/usr/local/lib/python3.7/json/decoder.py”, line 355, in raw_decode
raise JSONDecodeError(“Expecting value”, s, err.value) from None
json.decoder.JSONDecodeError: Expecting value: line 1 column 1 (char 0)

Looks like whatever you’re sending isn’t properly formatted as JSON.

You are right. I send an empty body, since I only use the webhook ID to trigger an automation.

I added {} to the body, and now it works.
Thanks a lot =)

2 Likes

Great! :slight_smile:

Now can you check one of these boxes so others know you no longer require help? Thanks!

image

Never saw those buttons before. Think I have some of my older threads to go through :sweat_smile:

1 Like

arghhh this is why i love the community, ive been struggling with this for ages, thanks to all. glad you took the time to update you resolution