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

Webhook test successful but nothing posts to Discord through webhook #21

Open
deterministicj opened this issue Mar 22, 2022 · 3 comments
Assignees
Labels

Comments

@deterministicj
Copy link

deterministicj commented Mar 22, 2022

Describe the bug
500 Internal Server Error when testing Discord webhook with http post request

I have the following types of Webhooks registered
Discord webhook with game subtype

Expected behavior
A test post

Additional context
Response for reference:

{
"id": "3183150c-91f1-45e7-84ff-085cf3c02ba4",
"requestId": "8104c28f-b9db-4479-a14b-300c7b1f118a",
"statusCode": 500,
"errorCode": 0,
"message": "An error has occurred. For more information, please check the logs for error ID 3183150c-91f1-45e7-84ff-085cf3c02ba4"
}

EDIT: I fixed this by using Insomnia instead for the POST. Webhook still not sending anything in Discord though even after successful POST.

@deterministicj
Copy link
Author

deterministicj commented Mar 22, 2022

I also manually tested sending a POST to the webhook to make sure it wasn't permissions on the Discord end. No issues with that. Seems to be something on the server end.

@deterministicj deterministicj changed the title Possibly not working anymore? Webhook test receives 500 error Webhook test successful but nothing posts to Discord through webhook Mar 22, 2022
@Bucketsmith
Copy link

I could not get it to work, either.

@Casper-O
Copy link

Casper-O commented Oct 31, 2022

Did a test request with postman and Insomnia, with postman i get the response "1" and with Insomnia it is empty - if i send wrong type or webhook it gives an error. but i see nothing posted to Discord

* Preparing request to https://humblebundlenotifications.azurewebsites.net/api/TestWebhook/
* Current time is 2022-10-31T18:48:43.053Z
* Enable automatic URL encoding
* Using default HTTP version
* Enable SSL validation
* Found bundle for host humblebundlenotifications.azurewebsites.net: 0x2b69e8655a0 [serially]
* Can not multiplex, even if we wanted to!
* Re-using existing connection! (#4) with host humblebundlenotifications.azurewebsites.net
* Connected to humblebundlenotifications.azurewebsites.net (52.252.160.21) port 443 (#4)
* TLSv1.2 (OUT), TLS header, Supplemental data (23):

> POST /api/TestWebhook/ HTTP/1.1
> Host: humblebundlenotifications.azurewebsites.net
> User-Agent: insomnia/2022.6.0
> Content-Type: application/json
> Accept: */*
> Content-Length: 179

| {
|     "type": 0,
|     "webhook": "https://discord.com/api/webhooks/*************",
|     "webhookType": 0
| }

* TLSv1.2 (IN), TLS header, Supplemental data (23):
* Mark bundle as not supporting multiuse

< HTTP/1.1 200 OK
< Content-Length: 0
< Date: Mon, 31 Oct 2022 18:48:42 GMT
< Server: Microsoft-IIS/10.0
< Cache-Control: no-cache
< Expires: -1
< Pragma: no-cache
< X-Powered-By: ASP.NET

JSON request works fine

* Preparing request to https://humblebundlenotifications.azurewebsites.net/api/TestWebhook/
* Current time is 2022-10-31T18:46:19.860Z
* Enable automatic URL encoding
* Using default HTTP version
* Enable SSL validation
* Too old connection (490 seconds), disconnect it
* Connection 2 seems to be dead!
* Closing connection 2
* TLSv1.2 (OUT), TLS header, Unknown (21):
* TLSv1.2 (OUT), TLS alert, decode error (562):
* Too old connection (490 seconds), disconnect it
* Connection 3 seems to be dead!
* Closing connection 3
* TLSv1.2 (OUT), TLS header, Unknown (21):
* TLSv1.2 (OUT), TLS alert, decode error (562):
* Hostname in DNS cache was stale, zapped
*   Trying 52.252.160.21:443...
* Connected to humblebundlenotifications.azurewebsites.net (52.252.160.21) port 443 (#4)
* ALPN, offering h2
* ALPN, offering http/1.1
* TLSv1.0 (OUT), TLS header, Certificate Status (22):
* TLSv1.3 (OUT), TLS handshake, Client hello (1):
* TLSv1.2 (IN), TLS header, Certificate Status (22):
* TLSv1.3 (IN), TLS handshake, Server hello (2):
* TLSv1.2 (IN), TLS handshake, Certificate (11):
* TLSv1.2 (IN), TLS handshake, Server key exchange (12):
* TLSv1.2 (IN), TLS handshake, Server finished (14):
* TLSv1.2 (OUT), TLS header, Certificate Status (22):
* TLSv1.2 (OUT), TLS handshake, Client key exchange (16):
* TLSv1.2 (OUT), TLS header, Finished (20):
* TLSv1.2 (OUT), TLS change cipher, Change cipher spec (1):
* TLSv1.2 (OUT), TLS header, Certificate Status (22):
* TLSv1.2 (OUT), TLS handshake, Finished (20):
* TLSv1.2 (IN), TLS header, Finished (20):
* TLSv1.2 (IN), TLS header, Certificate Status (22):
* TLSv1.2 (IN), TLS handshake, Finished (20):
* SSL connection using TLSv1.2 / ECDHE-RSA-AES256-GCM-SHA384
* ALPN, server accepted to use http/1.1
* Server certificate:
*  subject: C=US; ST=WA; L=Redmond; O=Microsoft Corporation; CN=*.azurewebsites.net
*  start date: Mar 14 18:39:55 2022 GMT
*  expire date: Mar  9 18:39:55 2023 GMT
*  subjectAltName: host "humblebundlenotifications.azurewebsites.net" matched cert's "*.azurewebsites.net"
*  issuer: C=US; O=Microsoft Corporation; CN=Microsoft Azure TLS Issuing CA 01
*  SSL certificate verify ok.
* TLSv1.2 (OUT), TLS header, Supplemental data (23):

> POST /api/TestWebhook/ HTTP/1.1
> Host: humblebundlenotifications.azurewebsites.net
> User-Agent: insomnia/2022.6.0
> Content-Type: application/json
> Accept: */*
> Content-Length: 115

| {
|     "type": 0,
|     "webhook": "https://webhook.site/******",
|     "webhookType": 1
| }

* TLSv1.2 (IN), TLS header, Supplemental data (23):
* Mark bundle as not supporting multiuse

< HTTP/1.1 200 OK
< Content-Length: 0
< Date: Mon, 31 Oct 2022 18:46:20 GMT
< Server: Microsoft-IIS/10.0
< Cache-Control: no-cache
< Expires: -1
< Pragma: no-cache
< X-Powered-By: ASP.NET


* Connection #4 to host humblebundlenotifications.azurewebsites.net left intact

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

4 participants