-
Notifications
You must be signed in to change notification settings - Fork 66
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
[BUG] #817
Comments
This looks more like the payload format check between notification and google chat. Transfer to notification repo. |
Hi @tomvannostrand , can you give a sample curl request to use the google webhook? For example: curl -H 'Content-Type: application/json' -d '{"text": "Hello World"}' . I want to make sure the json structure is consistent with our custom webhook. |
@tomvannostrand you can choose slack as notification type and input google webhook endpoint, they share same json schema. |
Sure enough! Picking "Slack" instead of "Custom Webhook" allows me to use a google webhook. |
Thank you @Hailong-am and @zhichao-aws. I've closed this but the problem remains that "Slack" should be renamed. |
Describe the bug
Trying to use a Google Webhook for a notification fails. Using other webhooks like Discord and https://webhook.site/ for example work fine.
To Reproduce
Steps to reproduce the behavior:
Expected behavior
A notification pops up in google chat
OpenSearch Version
2.9, 2.11
Dashboards Version
2.9, 2.11
Plugins
None
Error message
[status_exception] {"event_status_list": [{"config_id":"N7QfGosBxj32RX8UNdMY","config_type":"webhook","config_name":"google webhooks are broken but heres mine","email_recipient_status":[],"delivery_status":{"status_code":"500","status_text":"Failed to send webhook message Failed: {\n "error": {\n "code": 400,\n "message": "Invalid JSON payload received. Unexpected token.\nTest message content\n^",\n "status": "INVALID_ARGUMENT"\n }\n}\n"}}]}
If applicable, add screenshots to help explain your problem.
Host/Environment (please complete the following information):
Additional context
I'm using a webhook generated in google chat. For instance my host was: chat.googleapis.com
I've tried fiddling with manual webhook settings to no avail. It seems that whatever format OIpenSearch is sending to google, Google doesn't like it as it doesn't somehow conform to their formatting.
Because OpenSearch can send to other webhooks, just not google's but other things can send to google webhooks just fine, I believe the problem should be fixed within OpenSearch. Perhaps all webhook notifications could be modified to some lowest common denominator formatting, or perhaps in the manual settings, there could be a "and fix formatting to conform to google" button, or at least a way to manually modify whatever is breaking.
The text was updated successfully, but these errors were encountered: