You need to sign in to do that
Don't have an account?
scott.e
Data in Streaming notification.
I've set up some streaming push topics, and it works great, but i don't know how to control what data is sent in the "sobject" of the notification.
e.g. My query looks like "SELECT Id, Name, Company, Title, Website, Region__c, Product_Type__c From Lead"
and the payload on the notification looks like this
Message received from: /topic/LeadStream3
{
"channel": "/topic/LeadStream3",
"clientId": "ce31duyktzb0vcqe1fscj7cxstbra",
"data": {
"event": {
"type": "updated",
"createdDate": "2014-01-17T06:45:38.000+0000"
},
"sobject": {
"Name": "Lou Jones",
"Id": "00Q9000000NC6v7EAD",
"Company": "Springfield Police"
}
}
}
no matter how i change the query, i cant seem to pull more than Name, Id, Company...
Any way to specify which fields should be sent as part of notification? Or should I just be using the Id, and making a separate REST request, then pulling everything down?
e.g. My query looks like "SELECT Id, Name, Company, Title, Website, Region__c, Product_Type__c From Lead"
and the payload on the notification looks like this
Message received from: /topic/LeadStream3
{
"channel": "/topic/LeadStream3",
"clientId": "ce31duyktzb0vcqe1fscj7cxstbra",
"data": {
"event": {
"type": "updated",
"createdDate": "2014-01-17T06:45:38.000+0000"
},
"sobject": {
"Name": "Lou Jones",
"Id": "00Q9000000NC6v7EAD",
"Company": "Springfield Police"
}
}
}
no matter how i change the query, i cant seem to pull more than Name, Id, Company...
Any way to specify which fields should be sent as part of notification? Or should I just be using the Id, and making a separate REST request, then pulling everything down?
How is the notification Set, is it an email template that is sending this information?
See the documentation on pg# 32 with examples,
http://www.salesforce.com/us/developer/docs/api_streaming/api_streaming.pdf
See the blogs for more information ,
http://www.tgerm.com/2012/02/forcecom-streaming-api-notifications.html
http://forceguru.blogspot.in/2012/12/streaming-apis-easy-code.html
http://forcesecret.wordpress.com/2013/06/18/streaming-api-for-real-time-notification/
Regards,
Ashish