Get charged for what you get and not for what you ask
For every request, we calculate an estimated cost based on the operation requested. The estimation is greatly affected by the relay parameters used in connection fields. When no first
value is defined, we always assume a default of 100
.
Until now, the queries you made directly impacted the cost of your requests. Thus in the number of credits, you were deducted from your quota.
Not anymore!
From now on, you will be charged for what you get. If you asked for a 100 but got 5, we will only charge you those 5. Let’s see it with an example
A common question has been
How do we iterate order line items without asking for too much (thus producing a more expensive query) but not too little (having to make another query to get the remaining line items)
Well, no need to worry about that anymore. Just ask for what you think you should get. If you get less, you won’t be charged. This means you don’t need to worry too much about optimizing the first
parameter. It’s better to ask for 50 and get 30 than asking for 25 and needing to make an extra query to fetch the remaining 5.
What about specific field costs?
Some of our schema fields have a cost associated with them. Now, whenever you request one of those fields, you will see the cost and the impact it has on the overall cost of your request.
User quota info
From now on, you will also get the status of your user quota in every response. This means you won’t have to make extra queries to get it.
GraphQL Operation Aliases
We now support aliases. This means you can make the same operation more than once in the same request, and you will get a clear cost breakdown with the details of each operation.