Skip to main content

Optimizing API calls

Learn how to use APIs efficiently and ensure you are not reaching our rate limits

Making as few calls to Proactis as possible allows you to reduce your costs and your system's computational times, and decreases internet traffic between you and Proactis. It also allows you to process less data and access that data faster, delivering reduced waiting time and an improved experience for your users.

Use our querying and ordering systems and optimize how you access Proactis with the methods below.

Querying by the last modified date

You can query data by using the dateTimeFrom. This is the date the records have been last updated in Proactis database. This gives you only new or updated data since the specified date/time. If you also store the last queried date per data type, you are able to call our API the minimum number of times to return only new or changed data.

When using the API for the first time, there may be a need to pull all data, for all time. Make sure this is truly required, and if so, perform this pull only once. Afterwards, only query and access data since the last pull.

Pagination

We also recommend using a page size of 25 to return the results faster. The maximum page size is 50 results, which means fewer API calls, but slower responses.

Querying by the last modified date

You can query our Supplier endpoint with dateTimeFrom as follows:

/suppliers/v1/{domainId}?dateTimeFrom=2023-01-30T00:00&pageNumber=0&pageSize=25

This returns any supplier that were added or updated in Proactis since midnight UTC on January 30th. Results are paged with a size of 25.

Querying for a use case

Where possible, use query parameters to filter down the number of results when calling to our API. This allows you to minimize the number of API calls and the volume of data returned. As a result, this speeds up your system, returns the data faster, and improves your user experience.

Querying for a use case

You can query our Supplier endpoint for a supplier name starting with Pro as follows:

/suppliers/v1/{domainId}?pageNumber=0&pageSize=25&name=Pro

This returns all suppliers where the name starts with Pro.