Usage Limits
Rate limits
Request limits are assigned by workspace, environment, and plan. The active
limit is available in your workspace settings. BoxNCase returns HTTP 429
when a request limit is exceeded; honor Retry-After when present and use
exponential backoff with jitter.
If an integration needs sustained throughput above its assigned limit, contact support with the operation mix, peak request rate, and expected business volume.
Query cost
The GraphQL API calculates the number of requested objects to determine the cost of a query. The cost is calculated based on the number of objects requested, not the number of objects returned. For example, a query that requests 10 products will cost the same even if there are only 5 products in the database.
Certain fields may impose an additional cost. For example, fields that return unfiltered lists of objects and fields that can return large JSON structures.
BoxNCase will refuse to execute queries that exceed the maximum cost allowed by the server.
You can find the cost of each query and the maximum cost allowed by the server in the extensions.cost field of the response.
{
"data": {
// ...
},
"extensions": {
"cost": {
"requestedQueryCost": 5,
"maximumAvailable": 50000
}
}
}
Example: Query cost calculation
The cost breakdown for the following GraphQL query is as follows:
- Number of products fetched (
products.first): 10 - Attributes cost: 10 (
products.first) × 100 (complexity factor) = 1,000 - Variants cost: 10 (
products.first) × 100 (complexity factor) = 1,000
Total cost:
10 (base cost for 10 products)
+ 10 (attributes): 10 (`products.first`) × 1
+ 10 (variants): 10 (`products.first`) × 1
= 30
{
products(first:10, channel:"default-channel"){
edges{
node{
attributes{
__typename
}
variants {
id
}
}
}
}
}
Individual field limits
Fields that use pagination (first/last/before/after) are limited to 100 items per page. See pagination for details on how to paginate through results.