Skip to end of metadata
Go to start of metadata

You are viewing an old version of this page. View the current version.

Compare with Current View Page History

« Previous Version 4 Next »

What is an API call?

An API call is a request or query to the Salesforce database. Third-party applications, like Pulsar, use API calls to get data from Salesforce. For more information about API calls, refer to API Call Basics.

Why does the number of API Calls matter?

Depending on your Salesforce licensing agreement, you may have a limited number of API calls to use per day. While this number may seem large, the API calls can get used quickly when you multiply the number of daily requests by the number of users in your org. Hitting your API call limit can disrupt business processes. For more information about how Salesforce allocates resources, refer to Salesforce Features and Edition Allocations.

Why does Salesforce limit API calls?

Salesforce data servers are shared resources. Salesforce limits API calls to improve the performance of the database servers, so everyone gets the data they request in a timely manner. If you make a large number of simultaneous requests or request a large amount of data, Salesforce will throttle your request by sending a lower number of records with that request. Throttling results in increased API calls. For more details about the API limits, refer to API Request Limits and Allocations.

How does Pulsar use API calls?

Pulsar is a client application for Salesforce. Since Pulsar works offline, it must download data from Salesforce to store on the user’s device. API calls are used during the request for data from Salesforce. The data may include both record data and metadata.

When does Pulsar use API calls?

In Pulsar, each time you request data or metadata from Salesforce, API calls are used.

Pulsar uses API calls under the following circumstances:

  1. Initial Sync - The initial sync process is a request for all of the Salesforce data that you want to access in Pulsar, plus the metadata that defines how Pulsar will display the data. Many API calls are used in this large request for data.

  2. Catch Up Sync - The catch up sync requests only the data that has changed since the last successful sync. Typically, this does not include metadata. Some API calls are used during the catch up sync, but not as many as an initial sync.

  3. Local Data Push - Local data pushes occur when new or updated data is sent to the Salesforce servers from the user’s device. Metadata is not transferred in this process. This process consumes some API calls.

  4. Refresh Settings - When Refresh Settings is pushed or forced via an automatic process, metadata is updated and requires API calls.

  5. Other processes - Other processes, such as the Salesforce license check, may also use a small number of API calls.

Can you calculate the number of API Calls that Pulsar will use?

Salesforce sends between 200 and 2000 records in each API Call. The number of records depends on the amount of data in each record. For instance, you may request 10,000 records which each contain a short text phrase, and only use 5 API Calls (10,000 records / 2000 records per API Call). Alternatively, you may request 10,000 records containing images, documents, or long text blocks and use 50 API calls (10,000 records / 200 records per API call). This is because short text fields contain small amounts of data, while images, documents, and large text fields contain larger amounts of data. To complicate matters further, requesting records from narrow tables with only a few fields versus large tables with many fields may cause Salesforce to throttle the request, and send back a smaller number of records in each API call. Throttling can happen for other reasons, too, determined by Salesforce.

For these reasons, it is difficult to calculate the actual number of API calls which will be used by Pulsar.

How can I see the number of API calls used in Pulsar?

We recommend that you test your settings in the sandbox, and then look at the system overview to see the number of API Calls that were used during your test. To learn how to view your API limits, refer to this video https://youtu.be/4owr6JhTNjs.

How to reduce the number of API calls in Pulsar

Now that you understand how Pulsar uses API calls, you can make adjustments to reduce the number of API calls you use.

Reducing the amount of data that is synced will reduce the number of API calls used by Pulsar. You should only request the minimum amount of data needed by each user.

Use Salesforce settings to reduce the sync data

You can use Salesforce permissions and sharing settings to filter the data available to each user. This will reduce the overall amount of data that can be synced in Pulsar. An example is limiting the user to accessing only records for accounts contained in the user’s territory. We recommend that you use the tools in Salesforce to filter data prior to adjusting the Pulsar settings.

Use Pulsar Settings to reduce the sync data

Another way to reduce your API call usage is to reduce the number of records maintained on your user’s device. You can use the data sync settings in Pulsar Settings to filter the data by job role, region, account, or other criteria. You can also use Pulsar Settings to reduce the number of times the sync process occurs, or the amount of data included in a sync. For more information, see Data Sync Settings. Here are some examples of Pulsar settings you could use:

  • Pulsar Sync Object List - pulsar.sync.objects - Limit the objects you want to sync to Pulsar.

  • Pulsar Sync Objects - Relationship Directives - pulsar.sync.relationship.directives - Limit the objects you want to sync by their data relationships.

  • Object Filter Limit - pulsar.sync.initialFilterLimit - Limit the number of records fetched by each object.

  • Auto Sync Time Interval - pulsar.sync.autoSyncIntervalMinutes - Limit the number of times Auto Sync runs.

  • Sync Data Filter using a “Where” Clause - pulsar.<sobject type>.syncFilter - Limit the records which are synced for each object using a SOQL format where clause.

  • Disable syncing listviews for certain object types - pulsar.sync.listViews.disabledObjects - Allows Pulsar to skip syncing listviews for certain objects. Useful when there are many listviews in an object.

  • Enable Composite Graph API - pulsar.sync.enableCompositeGraphAPI - Sends as many local changes as possible in a single request to the server. Otherwise, each change is processed in a separate request.

  • No labels