We have an external website that is integrated with Salesforce via REST API. On the website, when a user registers, a contact record is created and also a welcome email is sent right away. Users also make purchases on the website which are recorded in Salesforce in real-time as well. We do expect heavy traffic when we launch and we are worried about the API limit. Is there a way to batch real-time transactions? We have read about bulk-api but not sure if it is applicable for real-time transactions. Our website is built on Node JS with a vue.js frontend.
-
3You can buy more API calls... If you can have a Middleware in between, it can group them together nd make a single call with bulk data. Bulk api is for bulk data loading. It's not exactly real-time stuff. I would recommend buying more api calls tbh.– Pranay JaiswalCommented Jan 22, 2019 at 23:44
-
1If you want to just record the Contact and Purchase history, and if you can delay that to a later point of time, you can then utilize batch here. Say at the end of the day, you consolidated all contacts and their purchases made until that point of time, then send those to be recorded in Salesforce. It however depends on what is your use case for real time integration. In all other cases you’ll need to get additional licenses as @PranayJaiswal has mentioned.– Jayant DasCommented Jan 23, 2019 at 0:08
1 Answer
Salesforce’s enterprise messaging platform provides the delivery of secure and scalable custom notifications within Salesforce and from external sources.
Platform events are part of Salesforce’s enterprise messaging platform. So using this you can hav 2.4 million events delivered to Salesforce in 24 hours.
Here are platform Event limits per additions which are on higher side from API limit.
You can go through platform events trailhead module and understand event architecture, how to create event and how to process those events in Salesforce.
At high level this will be your flow:
- Create platform event object in Salesforce
- Push event to this platform event object
- Write a process in Salesforce to process event and create Contact record or write after insert trigger on platform event object and insert contact record.