Skip to content
Console
Menu

Queues

Workflows

Getting Started

Authentication

KV Store

Check an entitlement grant

Answers whether a subject holds a feature now, and how much of it.

Answers whether a subject holds a feature now, and how much of it.

  • Path POST https://api.sylphx.com/v1/orgs/acme/projects/shop/envs/production/entitlement_grants:check
  • Scope billing:read
  • Effect read — nothing is written.
  • Collection entitlement_grants

#Request

FieldTypeWhat it is
parentstringThe environment to check in. Required.
subjectSubjectWho. Required.
featurestringThe feature key. Required.

#Subject

FieldTypeWhat it is
end_userstringAn end user's id (Sylphx Auth, or the app's own OIDC issuer). One of the kind group.
customer_organizationstringA customer organization's id. One of the kind group.

#Response

FieldTypeWhat it is
entitledboolWhether the subject holds the feature now.
limitstringFor a limit feature, the largest allowance the subject holds.
entitlement_grantstringThe grant that answers, when entitled.
expire_timetimestampWhen the answering grant ends; unset for no end. A caller may cache the answer until then.

#Errors

Every error arrives in the body Errors describes.

#Examples

curl -X POST "https://api.sylphx.com/v1/orgs/acme/projects/shop/envs/production/entitlement_grants:check" \
  -H "Authorization: Bearer $SYLPHX_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{"feature":"…","subject":{}}'