You are viewing a plain text version of this content. The canonical link for it is here.
Posted to notifications@apisix.apache.org by GitBox <gi...@apache.org> on 2022/08/02 01:22:35 UTC

[GitHub] [apisix] tzssangglass commented on issue #7587: help request: limit-count plugin

tzssangglass commented on issue #7587:
URL: https://github.com/apache/apisix/issues/7587#issuecomment-1201909168

   > Does it make this distinction per customer?
   
   We can set the `key` to be `$consumer_name` to distinguish the customer, e.g.:
   
   ```
       "plugins": {
           "limit-count": {
               "count": 2,
               "time_window": 60,
               "rejected_code": 503,
               "key": "$consumer_name"
           }
       },
   ```
   
   for more details, ref: https://github.com/apache/apisix/blob/master/docs/en/latest/plugins/limit-count.md#attributes
   
   `X-API-Key` is used for the admin API of APISIX. It is not related to customs and should not be used to count requests generated by customs.
   
   > Is there a way that we can expose the usage count for the client via a GET call so they can assess and budget their usage?
   
   None. But you can add this functionality based on open source plugins.


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: notifications-unsubscribe@apisix.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org