Best Practices for Optimizing Usage
Data 360 Developer Guide, mirrored from developer.salesforce.com: To stay within your consumption credits, follow best practices to optimize your service and data usage.
markdownreferencev1Q6YQ-TZZFguide: data-cloud-devstage: referencetrust: officialsource: developer.salesforce.comservice: data360interface: restinterface: sqlBest Practices for Optimizing UsageData 360Data CloudData 360 Developer Guide
Mirror of <https://developer.salesforce.com/docs/data/data-cloud-dev/guide/best-practices-usage.html> (Salesforce, Data 360 Developer Guide), read 2026-10-23. Salesforce's own page is the authority; this copy exists because that site refuses non-browser readers.
Best Practices for Optimizing Usage
To stay within your consumption credits, follow best practices to optimize your service and data usage.
Customer and Salesforce partners can follow these tips.
Write optimized code that’s inexpensive, such as queries. You can write SQL queries to fetch only the data that you need. Queries are preferable over GET API requests because they offer more flexibility in choosing the data that you want to retrieve. To write efficient queries, add a WHERE clause to filter the returned results and retrieve the smallest set of required records. Also, specify only the fields that you need in the SELECT statement.
For example, this query is efficient because it gets one Individual record for a specific Individual ID value.
Connect REST API resource:
SQL query:
You can query data via Connect REST API. See the Query Library section in Data Cloud Resources in the _Data Cloud Connect REST API Guide_. Or see Query Data using Query API and Query Customer Profile Information with Profile API in the _Data Cloud Query Guide_. Alternatively, you can use SOQL to query data. For more information, see Data Cloud Query Profile Parameters in the _REST API Developer Guide_.
As part of your data ingestion strategy, ensure that you import relevant data records into Data 360 and that you don’t import more data than what’s needed. Sometimes it’s better to aggregate data before ingesting it rather than ingesting every data point, especially if not all attributes are relevant.
When testing a custom app, limit the amount of testing data in the test org. Use a sample of records that’s sufficient to meet your functional testing needs.