title: how can make throttling per user per api and per resource of the api in wso2 api management 2.6?
body: <p>I am using wso2 API management 2.6. I have 15 API in my store and every API has 5-10 resources (many 'get'-'post'-'delete'-'put'). I have 3 users (consumers) that every one has his own tiers for calling APIs. for example 'user1' can call just  one 'get' resource of 'API1' ,all 'post' resources of API2 and can not call other resources in API1 , API2 and API3. This situation is same for user2 and user3. I don't know how can I make throttling tiers for this store?</p>
  
  <p>I found this <a href="https://medium.com/@lahirugmg/resource-level-rate-limiting-for-each-user-with-wso2-api-manager-3a743bffe846" rel="nofollow noreferrer">this</a> example and change it to my own one like this :</p>
  
  <blockquote>
    <p>key Template:
    $userId:$resourceKey</p>
    
    <p>siddhi query :
    FROM RequestStream
    SELECT userId, ( userId == 'userId@carbon.super'  and resourceKey== '/api/1.0.0/resourceKey:GET') AS isEligible ,
    str:concat('userId@carbon.super' , ':' , '/api/1.0.0/resourceKey:GET') as throttleKey</p>
    
    <p>INSERT INTO EligibilityStream;
    FROM EligibilityStream[isEligible==true]#throttler:timeBatch(1 min)
    SELECT throttleKey, (count(userId) >= 1) as isThrottled, expiryTimeStamp group by throttleKey
    INSERT ALL EVENTS into ResultStream;</p>
  </blockquote>
  
  <p>I have this siddhi query but it doesn't work!
  I don't know this info helps or not but my api request Url is : <a href="https://[APIAdress]/api/1.0.0/resourceKey" rel="nofollow noreferrer">https://[APIAdress]/api/1.0.0/resourceKey</a></p>