⚓️ Portcall

Querying metered feature usage

How to query usage for metered features using Portcall API

To query metered feature usage via the Portcall API, you can use the user entitlements endpoint:

curl -X GET https://api.portcall.com/v1/users/{{user_id}}/entitlements/{{entitlement_id}} \
  -H "X-API-Key YOUR_SECRET_API_KEY" \
  -H "Content-Type: application/json"

You can review the current usage and quota in the response:

{
  "id": "ENTITLEMENT_ID",
  "usage": 50,
  "quota": 100
}