question

camilo-silva10357 avatar image
camilo-silva10357 asked ·

SUB-525 - Sandbox Webhook Subscription Failure

HI Everyone,

I'm facing a cumbersome issue when trying to create my WebHook Subscription via POSTMAN to my sandbox account. I have deployed a service on AWS that can be accessed:
https://jumpserver.lbpengine.com/webhook
Furthermore, it passes all TLS/SSL checks as shown here:
https://www.sslshopper.com/ssl-checker.html#hostname=jumpserver.lbpengine.com

I have implemented also the Validation-Token check and return as explained in the docs and as showcased in all the NodeJS code samples.

Whenever I call the API

POST    https://platform.devtest.ringcentral.com/restapi/v1.0/subscription
{
    "eventFilters": [
        "/restapi/v1.0/account/241847004/extension/241847004/message-store"
    ],
    "deliveryMode": {
        "transportType": "WebHook",
        "encryption":true,
        "address": " https://jumpserver.lbpengine.com/webhook/";
    }
}

I always keep getting the SUB-525 Webhook server response is invalid

What is puzzling to me is that my server is never logging such requests made by the RingCentral servers. And I have logs on every entry point of such webservice.

This is very puzzling...

Please could you please guide/help me address this issue since as you can tell, if you test using POSTMAN or cURL, you will notice that all my requirements have been met to register my webhook.

Any advice is welcomed.
Many thanks,

Camilo
aaa
1 |1000 characters needed characters left characters exceeded

Up to 8 attachments (including images) can be used with a maximum of 1.0 MiB each and 10.0 MiB total.

John Wang avatar image
John Wang answered ·
Hi Camilo,

I've been able to verify your experience using cURL (Validation-Token) and a Create Subscription API call (error). I've also replicated all your response headers on my own test server which doesn't have the issue.

If you create a support ticket, the team should be able to look into our request logs to analyze what's happening with your endpoint. Can you create a support ticket using the links at the bottom of the following page or by sending an email to devsupport@ringcentral.com.

https://developer.ringcentral.com/support.html

Thanks,
John
Share
1 |1000 characters needed characters left characters exceeded

Up to 8 attachments (including images) can be used with a maximum of 1.0 MiB each and 10.0 MiB total.

Tyler Liu avatar image
Tyler Liu answered ·

6 comments Share
1 |1000 characters needed characters left characters exceeded

Up to 8 attachments (including images) can be used with a maximum of 1.0 MiB each and 10.0 MiB total.

Hello Tyler:

Just deployed my solution and now it works correctly.
I think the documentation should be modified to let dev know that Ring Central request sends a header along with an empty body with content-type application-json. This will save additional time of unnecessary debugging.

Many thanks for the help!

1 Like 1 · ·
For JSON, "Content-Type: application/json" the body needs to be minimally "{}" or "[]", but I don't think this is the issue here. When I add the body with the JSON Content-Type header, I get a 200 OK with the Validation-Token returned from the jumpserver webhook URL.
0 Likes 0 · ·
That's right John. I'll be testing per Tyler's recommendation and allow a blank body when the application/json content type is provided. Since I am not sure what the poll headers are from RingCentral confirmation, I will be adding that just to make sure that it is not the issue. I will comment back again tomorrow with my findings. Thanks for the help.
0 Likes 0 · ·
I just tested and when the webhook was being created, the request body IS empty.  So please let the webhook handler allow an empty body and try again.
0 Likes 0 · ·
You are welcome! I have created an issue to track the documentation change:  https://github.com/ringcentral/ringcentral-api-docs/issues/37
0 Likes 0 · ·
Show more comments

Write an Answer

Hint: Notify or tag a user in this post by typing @username.

Up to 10 attachments (including images) can be used with a maximum of 1.0 MiB each and 10.0 MiB total.