- Home
- Learn
- SpiceDB Schema Examples
- SaaS entitlements
SaaS entitlements
Per-tier feature flags for a SaaS application. Free and paid plans grant access to different features.
SaaSView on GitHub
SaaS entitlements
Per-tier feature flags for a SaaS application. Free and paid plans grant access to different features.
An entity that can be granted permissions
definition user {}Organizations contain users
definition organization {
relation member: user
}An entitlement is a grant given to an organization
definition entitlement {
relation org: organization
permission subscribed_member = org->member
}Features are given to entitlements
definition feature {
relation associated_entitlement: entitlement
permission access = associated_entitlement->subscribed_member
}schema.zedSection 1 / 4
definition user {}
definition organization {
relation member: user
}
definition entitlement {
relation org: organization
permission subscribed_member = org->member
}
definition feature {
relation associated_entitlement: entitlement
permission access = associated_entitlement->subscribed_member
}Schemas come from the authzed/examples repository (Apache 2.0). Comments shown alongside the code are the authors' original docstrings.