[#1277] API Callback with empty request

Migrated from Redmine #1277 | Author: Guilherme Bueno
Status: New | Priority: Immediate, there is BUG! | Created: 2024-09-10


Today at around 9:15 EST we stopped receiving any data with the callback requests from the SB API.
This results in our database being out of sync with the current bookings being made on the platform as well as us not being able to send any confirmation emails for the appointments we make, since this is handled on our side.

Please revert whatever changes or advise on how to proceed

Dmytro Bondarev wrote:

Hi, we didn’t make any changes, could you please provide http request from SB side?

Guilherme Bueno wrote:

Dmytro Bondarev wrote:

Hi, we didn’t make any changes, could you please provide http request from SB side?

How can I get the http request from SB side? When I log the request params on the endpoint on our side receiving the request, I get just an empty array.

Guilherme Bueno wrote:

On our side there were no deployments as well, last deployment was 4 days ago, where this problem was not present

Dmytro Bondarev wrote:

please provide raw body and all headers that you receive from sb server.
also please provide your public site url, so we can check issue.

Redmine Admin wrote:

you can use some service like https://webhook.site/ to provide a mock API endpoint and then share results with us if it still be empty

Guilherme Bueno wrote:

Dmytro Bondarev wrote:

please provide raw body and all headers that you receive from sb server.
also please provide your public site url, so we can check issue.

Sorry for the formatting but I had to grab it from the server logs:

The header is here:
[connection] => Array
(
[0] => Keep-Alive
)
[cf-ipcountry] => Array
(
[0] => CA
)

[cf-visitor] => Array
(
[0] => {“scheme”:“https”}
)

[cdn-loop] => Array
(
[0] => cloudflare; loops=1
)

[content-type] => Array
(
[0] => application/json
)

[x-forwarded-proto] => Array
(
[0] => https
)

[user-agent] => Array
(
[0] => simplybook.me API
)

[accept-encoding] => Array
(
[0] => gzip, br
)

[cf-connecting-ip] => Array
(
[0] => 35.203.18.191
)

[host] => Array
(
[0] => santemedic.com
)

[x-forwarded-for] => Array
(
[0] => 35.203.18.191
)

[cf-ray] => Array
(
[0] => 8c102c04cf9c38e1
)

)

But trying to get the body of the request returns an empty array. The full request was to large for me to print on the server logs, it exceeded the memory

Guilherme Bueno wrote:

The url for the endpoint would be

https://santemedic.com/api/sb/5

Dmytro Bondarev wrote:

please try to use check with https://webhook.site/ and please provide link to view the callback.

Guilherme Bueno wrote:

Here, i changed the callback url to be the one of this service you mentioned

You can see the request details on the link above
I went ahead and canceled a booking to be able to send this request, as you can see it seems to be empty

Guilherme Bueno wrote:

The most recent one I created a booking instead of cancelling one so we can have a more realistic scenario but it’s still the same thing, no body

Dmytro Bondarev wrote:

Could you please try again and let us know?

Guilherme Bueno wrote:

Yeah i just cancelled a booking and it seems to be fixed. Out of curiosity, what was then issue?

Redmine Admin wrote:

We sincerely apologize for the inconvenience. This issue is due to an infrastructure problem, it is resolved now and we are taking all necessary steps to prevent future occurrences

Guilherme Bueno wrote:

Sounds good. Thank you for the swift response guys!
Have a great rest of your day