Quota Policy

Not applicable

I'm trying to implement two quota policies: one on preflow and one specific to a method.

The preflow one works fine applying the api product quota limit:

<Allow count="10" countRef="verifyapikey.Verify-API-Key-1.apiproduct.developer.quota.limit"/>

For the one specific to one method, I wanted to apply a fraction of the overall api quota limit:

<Allow count="10" countRef="(verifyapikey.Verify-API-Key-1.apiproduct.developer.quota

.limit)/10"/>

The countref for my second policy is not working so the value of 10 in my fall back count is being applied.

Can I do operations in the countref (like /10)? Is this the reason why this is not working?

0 2 197
2 REPLIES 2

@Patricia Bonisson Caldeira I am not following your flow for the second piece so maybe you can show the flow ? have you checked out these videos on using the quota policy flow variables : http://docs.apigee.com/api-services/reference/quota-policy

HI @Patricia Bonisson Caldeira

Welcome to the community !!!

Your assumption is right - you cannot use (verifyapikey.Verify-API-Key-1.apiproduct.developer.quota

.limit)/10

You should be using MessageWeight for this. Check out this video in our docs. In the video the weight is set to 2 in case of a POST call. In your case, you will need to set it to 0.1

See if it works and reach out if you still need any help