Recurring charged based on usage: Create app usage records to bill merchants based on their usage of the app. The total value of all usage records cannot exceed the cappedAmount.
The usage charge API however allows to use an amount that exceeds the cappedAmount.
Can you please help me confirm if this is applicable even if the test flag is false. (In test environment, that is with test flag set to true, api returns 200 OK with negative balance amount. What will be the behaviour in prod environment, that is test flag set to false)
Will the remaining amount that does not exceed the cappedAmount be deducted from the merchant in this scenario? For example, if cappedAmount is 100 and usage charge is called with an amount of 110, will the amount of 100 be deducted or the entire request is not completed?
There is another similar question that was asked in the community but we could not conclude our queries from this: link
Thanks for your post. When the test flag is not true the system will reject any [REST API UsageCharge creation call] that would cause the cappedAmount to be exceeded.
The current behaviour of the UsageCharges creation call going through when the test flag is true and the cappedAmount would be exceeded is considered to be a bug which has now been flagged for repair, and a dev doc update request has been submitted to add some more notes about this to the REST API documentation.
“If you create an app usage charge that causes the total usage charges in a billing interval to exceed the capped amount, then a Total price exceeds balance remaining error is returned.”