I integrated jawbone with my app and everything was working fine. I implemented authentication for pub sub notification according to the documentation mentioned in jawbone development portal (https://jawbone.com/up/developer/pubsub) I followed the pub sub json payload structure given in jawbone development portal But now I am getting different pub sub json payload structure. So my pub sub is not working. Is there any change in pub sub json payload structure?
payload structure mentioned on development portal is like this:
{
"notification_timestamp": "1372787949",
"events": [
{
"user_xid": "RGaCBFg9CsB83FsEcMY44A",
"event_xid": "EJpCkyAtwoO0XTdkYyuTNw",
"type": "move",
"action": "creation" ,
"timestamp": "1372787849",
"secret_hash":"e570b3071a0964f9e2e69d13nd9ba19535392aaa"
},
{
"user_xid": "RGaCBFg9CsB83FsEcMY44A",
"event_xid": "blaHyAtwoO0XTdkYyuTNw",
"type": "sleep",
"action": "updation" ,
"timestamp": "1372787859",
"secret_hash":"e570b3071a0964f9e2e69d13nd9ba19535392aaa"
}]
}
Actual payload that i am getting in server is like:
{
"secret_hash": "34ba79b1512cb1bxxxxxxx",
"events":[
{
"user_xid": "6HGK86qWtLJIoXXXX",
"event_xid": "akA6KuLaNsJv8XXXXX ",
"type": "move",
"action": "updation",
"timestamp": "1473145183"
}],
"notification_timestamp": "1473145183"
}
This was an error in the documentation on the developer portal. Thank you for pointing it out!
The examples have been updated to reflect that there is only one secret_hash
per notification:
{
"notification_timestamp": "1372787949",
"events": [
{
"user_xid": "RGaCBFg9CsB83FsEcMY44A",
"event_xid": "EJpCkyAtwoO0XTdkYyuTNw",
"type": "move",
"action": "creation" ,
"timestamp": "1372787849"
},
{
"user_xid": "RGaCBFg9CsB83FsEcMY44A",
"event_xid": "blaHyAtwoO0XTdkYyuTNw",
"type": "sleep",
"action": "updation" ,
"timestamp": "1372787859"
}
],
"secret_hash": "e570b3071a0964f9e2e69d13nd9ba19535392aaa",
}