Cerbos Playground - Prototype, test and share policies
Files
Export
_schemas
derived_roles
- store_roles.yaml
principal_policies
resource_policies
- inventory_resource.yaml
order_resource.yaml
README.md
README
These policies are in use in our Go REST API demo. https://github.com/cerbos/demo-rest
Examples
Choose one of the sample application policies above to see the Cerbos engine in action.
If you make any changes to policy files, click on Apply & Run to validate the new policies
Policy files
You can add new resource, derived role, or principal policies on the left.
For syntax of the policy files, please see: https://docs.cerbos.dev/cerbos/policies/index.html
Testing Actions for Principals and Resources
You can add multiple principals and resource definitions on the right.
At any point you can see whether the listed actions are allowed or disallowed on the right. Alternatively, Check all buttons allow bulk checks for all the principals or resources.
README
OutputsProblemsTests
No policy outputs defined. Policies can return context along with the decisions - read more in the documentation..
Principal
Who is performing the action(s)?
Try the API
{
"id":"adam",
"roles":[
"customer"
],
"attr":{}
}
Resource
What is being accessed?
order 1 - only 12 eggs, Pending
{
"id":"1",
"kind":"order",
"policyVersion":"default",
"attr":{
"eggs":12,
"milk":1,
"status":"PENDING"
}
}
Actions
List of actions the principal is attempting to do with the resource
order Actions |
Result |
|---|---|
| Denied | |
| Denied | |
| Denied | |
| Denied | |
| Denied | |
| Denied | |
| Denied |
Check AllQuery Plan
Aux Data
Additional request context
Request
The HTTP request payload to Cerbos PDP
Try the API
Response
The HTTP response from Cerbos PDP
Welcome to the Cerbos Playground
This environment allows you to build, test and debug authorization policies in real-time and share examples with your team.
Full documentation can be found at docs.cerbos.dev