Changedatacapture

Change Data Capture with Nodejs

by Patrick Connelly posted on January 23, 2019

There’s a new feature in Salesforce called Change Data Capture that allows you to subscribe to a Cometd endpoint and stream changes to most or some of your objects. I’ve talked in a previous post about how to get data out of Salesforce and this seems like it might be the front-runner for one of the best ways. I would still plan on ways to get data if it exceeds the three day replay period and you’ll also need a way to do your initial data import.

What data can I get with Change Data Capture?

In a perfect world, everything you’d need would always live in Salesforce and you’d never have to worry about backing up data. Well, we don’t live in a perfect world. Lot’s of times you need to get data out of Salesforce and get it into an external system. You could do this for data backup, for populating a search index, for sending messages to an external system. With Change Data Capture, you can do this type of data flow in real-time.

Change Data Capture supports the following standard object (at time of writing):

  • Account
  • AccountContactRole
  • Asset
  • Campaign
  • Case
  • Contact
  • Event
  • EventRelation
  • Lead
  • ListEmail
  • Opportunity
  • OpportunityContactRole
  • Order
  • OrderItem
  • Product2
  • Task
  • User

In addition to the standard items above, Change Data Capture supports all custom objects.