Webhook verification not working

374 views
Skip to first unread message

and...@nimblr.ai

unread,
Sep 8, 2017, 3:20:14 PM9/8/17
to drchrono Medical Healthcare API SDK
I am trying to verify a webhook without success. The URL is never submitted to my server, and the validation fails. I am not sure if it is a client problem as I can see some JS errors in the console (see image). Can you help me?




Denis Malinovskiy

unread,
Sep 8, 2017, 3:21:31 PM9/8/17
to drchrono Medical Healthcare API SDK
Try saving the settings on the page first and then clicking Verify Webhook.

On Fri, Sep 8, 2017 at 12:20 PM <and...@nimblr.ai> wrote:
I am trying to verify a webhook without success. The URL is never submitted to my server, and the validation fails. I am not sure if it is a client problem as I can see some JS errors in the console (see image). Can you help me?




--
You received this message because you are subscribed to the Google Groups "drchrono Medical Healthcare API SDK" group.
To unsubscribe from this group and stop receiving emails from it, send an email to drchrono-api...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.
--
Denis Malinovskiy
Software Engineer, drchrono

and...@nimblr.ai

unread,
Sep 12, 2017, 6:38:04 PM9/12/17
to drchrono Medical Healthcare API SDK
That worked, thanks.

Andres Rodriguez

unread,
Sep 12, 2017, 9:07:04 PM9/12/17
to drchro...@googlegroups.com

Or I should say, "almost" worked. I get a payload that looks like this:

object=profile&object=status&object=patient&object=office&object=base_recurring_appointment&object=color&object=scheduled_time&object=doctor&object=exam_room&object=updated_at&object=id&object=created_at&object=is_walk_in&object=reason&object=icd10_codes&object=deleted_flag&object=notes&object=duration&object=recurring_appointment&object=appt_is_break&object=allow_overlapping&receiver=verified&receiver=name&receiver=secret_token&receiver=created_at&receiver=api_app&receiver=updated_at&receiver=owning_doctor_id&receiver=events&receiver=active&receiver=callback_url&receiver=id

With no data. Can you help?



Andres C. Rodriguez
Chief Technology Officer



You received this message because you are subscribed to a topic in the Google Groups "drchrono Medical Healthcare API SDK" group.
To unsubscribe from this topic, visit https://groups.google.com/d/topic/drchrono-api/xpjvM2PL7Z4/unsubscribe.
To unsubscribe from this group and all its topics, send an email to drchrono-api...@googlegroups.com.

Denis Malinovskiy

unread,
Sep 13, 2017, 11:49:59 AM9/13/17
to drchro...@googlegroups.com
This is the expected payload for a test webhook.  You need to verify it now responding as described in the docs: https://app.drchrono.com/api-docs/v2016_06/documentation#webhooks-verification

and...@nimblr.ai

unread,
Sep 13, 2017, 2:09:21 PM9/13/17
to drchrono Medical Healthcare API SDK

I did verify it (see screenshot below). I am getting this payload for an appointment modification.

HEADERS:  { host: 'andres-ngrok-api.nimblr.ai',

  connection: 'keep-alive',

  'accept-encoding': 'gzip, deflate',

  accept: '*/*',

  'user-agent': 'python-requests/2.10.0',

  'x-drchrono-delivery': 'd3060bcc-2009-48fc-8c31-2fdcd3c2ba14',

  'x-drchrono-signature': 'c660ff3b7b055bd28bfb88e9fe49ea693b5cd355',

  'content-type': 'application/json',

  'x-drchrono-event': 'APPOINTMENT_MODIFY',

  'content-length': '581' }

BODY:  object=profile&object=status&object=patient&object=office&object=base_recurring_appointment&object=color&object=scheduled_time&object=doctor&object=exam_room&object=updated_at&object=id&object=created_at&object=is_walk_in&object=reason&object=icd10_codes&object=deleted_flag&object=notes&object=duration&object=recurring_appointment&object=appt_is_break&object=allow_overlapping&receiver=verified&receiver=name&receiver=secret_token&receiver=created_at&receiver=api_app&receiver=updated_at&receiver=owning_doctor_id&receiver=events&receiver=active&receiver=callback_url&receiver=id



Verified:

Denis Malinovskiy

unread,
Sep 13, 2017, 2:32:24 PM9/13/17
to drchrono Medical Healthcare API SDK
I checked your account (searched by your first and last name), and your webhook is not verified.

and...@nimblr.ai

unread,
Sep 13, 2017, 2:36:47 PM9/13/17
to drchrono Medical Healthcare API SDK

Denis, I am using a test account under the name "Howard Roark".

I have attached  screenshot that shows the web hook is verified.

Thanks for your help.

Andres
Screen Shot 2017-09-13 at 11.34.59.png

Denis Malinovskiy

unread,
Sep 13, 2017, 2:40:11 PM9/13/17
to drchrono Medical Healthcare API SDK
You need to click "Active" checkbox.  I'm sorry for the UI, it was done by the developer. :)

and...@nimblr.ai

unread,
Sep 13, 2017, 2:45:31 PM9/13/17
to drchrono Medical Healthcare API SDK

Denis,

No worries about the UI :) I have coded my fair share of quickly done GUIs.

I have it un-active right now because I am not getting JSON from the web hook (as described below).

When I activate it to test the web hook, then I get the following payload (with headers printed):

HEADERS:  { host: 'andres-ngrok-api.nimblr.ai',
  connection: 'keep-alive',
  'accept-encoding': 'gzip, deflate',
  accept: '*/*',
  'user-agent': 'python-requests/2.10.0',
  'x-drchrono-delivery': 'd3060bcc-2009-48fc-8c31-2fdcd3c2ba14',
  'x-drchrono-signature': 'c660ff3b7b055bd28bfb88e9fe49ea693b5cd355',
  'content-type': 'application/json',
  'x-drchrono-event': 'APPOINTMENT_MODIFY',
  'content-length': '581' }
BODY:  object=profile&object=status&object=patient&object=office&object=base_recurring_appointment&object=color&object=scheduled_time&object=doctor&object=exam_room&object=updated_at&object=id&object=created_at&object=is_walk_in&object=reason&object=icd10_codes&object=deleted_flag&object=notes&object=duration&object=recurring_appointment&object=appt_is_break&object=allow_overlapping&receiver=verified&receiver=name&receiver=secret_token&receiver=created_at&receiver=api_app&receiver=updated_at&receiver=owning_doctor_id&receiver=events&receiver=active&receiver=callback_url&receiver=id




Denis Malinovskiy

unread,
Sep 13, 2017, 2:48:18 PM9/13/17
to drchrono Medical Healthcare API SDK
It's interesting—when I'm clicking Recent Deliveries in your drchrono API page, I see the last successful webhook and its body is looking correctly.  Can you check things on your end?

and...@nimblr.ai

unread,
Sep 13, 2017, 2:54:50 PM9/13/17
to drchrono Medical Healthcare API SDK

That is indeed true, I had tried to see what the recent deliveries said was delivered, and it does appear to be JSON. So I tried clicking on "Redeliver" to see if I could observe the payload a second time around and I get "Invalid Delivery Object". (see attached image) with NO request/post delivered on my server.

Does that provide any clues as to what may be happening?

Thanks much!

ACR
Screen Shot 2017-09-13 at 11.49.17.png

Denis Malinovskiy

unread,
Sep 13, 2017, 2:56:41 PM9/13/17
to drchrono Medical Healthcare API SDK
Looks like redelivery functionality is broken.  Can you try to modify an appointment instead to trigger a new webhook?

and...@nimblr.ai

unread,
Sep 13, 2017, 3:20:07 PM9/13/17
to drchrono Medical Healthcare API SDK
To make sure my server is not the problem I created a Mockbin and sent the traffic over there to verify the payload (see screenshot).


And see what the DrChrono server is delivering. 


ACR
Screen Shot 2017-09-13 at 12.16.57.png

Denis Malinovskiy

unread,
Sep 13, 2017, 3:32:27 PM9/13/17
to drchrono Medical Healthcare API SDK
I think I found the bug, we'll deploy the fix today or tomorrow, I'll follow up when it'll be live.

Thanks for catching it.

Denis Malinovskiy

unread,
Sep 14, 2017, 12:02:44 PM9/14/17
to drchrono Medical Healthcare API SDK
Please try again in 30 mins, the fix will be deployed by that time.

Andres Rodriguez

unread,
Sep 15, 2017, 11:44:44 AM9/15/17
to drchro...@googlegroups.com

Denis, 

Hmm, it's already verified as described in the docs (see screenshot below).

What else could I be doing wrong?

Thanks,


Andres





Andres C. Rodriguez
Chief Technology Officer



Andres Rodriguez

unread,
Sep 15, 2017, 11:44:44 AM9/15/17
to drchro...@googlegroups.com

I printed the headers as well of what I get for an appointment creation:

/providers/drchrono/callback
PARAMS { name: 'drchrono' }
QUERY:  {}
BODY:  object=profile&object=status&object=patient&object=office&object=base_recurring_appointment&object=color&object=scheduled_time&object=doctor&object=exam_room&object=updated_at&object=id&object=created_at&object=is_walk_in&object=reason&object=icd10_codes&object=deleted_flag&object=notes&object=duration&object=recurring_appointment&object=appt_is_break&object=allow_overlapping&receiver=verified&receiver=name&receiver=secret_token&receiver=created_at&receiver=api_app&receiver=updated_at&receiver=owning_doctor_id&receiver=events&receiver=active&receiver=callback_url&receiver=id
HEADERS:  { host: 'andres-ngrok-api.nimblr.ai',
  connection: 'keep-alive',
  'accept-encoding': 'gzip, deflate',
  accept: '*/*',
  'user-agent': 'python-requests/2.10.0',
  'x-drchrono-delivery': '2d7404fb-72b6-42ef-a136-714338f9a837',
  'x-drchrono-signature': 'c660ff3b7b055bd28bfb88e9fe49ea693b5cd355',
  'content-type': 'application/json',
  'x-drchrono-event': 'APPOINTMENT_CREATE',
  'content-length': '581' }



Andres C. Rodriguez
Chief Technology Officer



Denis Malinovskiy

unread,
Sep 15, 2017, 11:49:16 AM9/15/17
to drchro...@googlegroups.com
Andres, for some reason your messages were delayed in the spam filter.  Do you still have this issue with the webhooks?

and...@nimblr.ai

unread,
Sep 15, 2017, 12:08:25 PM9/15/17
to drchrono Medical Healthcare API SDK
I am about to try again. I will let you know as soon as I finish the tests.

and...@nimblr.ai

unread,
Sep 15, 2017, 12:31:47 PM9/15/17
to drchrono Medical Healthcare API SDK

Yes! I am not getting JSON at the very least. I will start debugging my app. Thanks for your help. Can you share the nature of the issue faced at your end?

and...@nimblr.ai

unread,
Sep 15, 2017, 12:32:50 PM9/15/17
to drchrono Medical Healthcare API SDK

Sorry, typo: it should read "I am NOW getting JSON".

Denis Malinovskiy

unread,
Sep 15, 2017, 12:41:20 PM9/15/17
to drchrono Medical Healthcare API SDK
The issue was we were passing the original object to the library we're using to make the requests.  Instead, we should be passing the JSON string representation of the object, which we do now.
Reply all
Reply to author
Forward
0 new messages