Wednesday, December 05, 2012 9:06 PM
I am developing a Django app (python) that needs to receive event notifications from HV.
My app is configured on https://config.healthvault-ppe.com
My app id: 2ecad30f-d7aa-4be1-bb3e-b00b27828631
My app is authorized for offline access to my account on HV.
My app is configured to use eventing methods.
My app is configured to access Weight measurements (all access rights)
I have set up a ssl proxy (NGINX) for my app's domain, action url and event notification handler url. The urls are accessible from a browser.
I can update HV account from my app with PutThings.
I create event subscriptions using SubscribeToEvent and can get my subscriptions using GetEventSubscriptions.
Yet, when I add Weight measurements to my HV account from HV Browser client, I receive no event notifications in my app.
Thanks for your help
Wednesday, December 05, 2012 10:24 PM
Your application will only receive notifications for changes by users that have authorized the app, and only to the data types the app is authorized to. Make sure that the user that's adding/deleting the Weight measurement item has authorized the app.
Also, I am seeing an SSL error hitting the ActionURL registered for your PPE subscription. You should see the same certificate error (The security certificate presented by this website was issued for a different website's address) if you open the URL in a browser. There are two options to fix this:
- Get a valid SSL cert for your URL domain and provision it on your webserver. OR
- In PPE only we allow you to use non-HTTPS URLs for your notification endpoint. You can change HTTPS to HTTP in your subscription and this should work. Be aware however that for production we require HTTPS and you will need to get a valid SSL certificate if you go-live to PROD.
Hope this helps,
- Marked As Answer by Eytan Ben Meir Friday, December 07, 2012 2:44 AM
Thursday, December 06, 2012 9:37 AM
Thank you for your attention.
1) I changed the self signed certificate to a valid one and now ssl access works from the browser (no errors)
2) There is only one user that can access the account and it is the same user that I used to authorize the app and that creates the new weight measurements.
Still I get no event notifications.
Thursday, December 06, 2012 10:37 PMHi Eytan,
Please note that notification URL should be on the same domain as the ActionURL that is registered with the application. What is your notification URL configured as? Machines that are not directly reachable from the internet cannot be used in a subscription. Look at this article to understand how you can test notification handlers.
Let me know if this helps,
Friday, December 07, 2012 2:44 AM
It actually works now. Last issue had to do with request headers handling on my side.