aboutsummaryrefslogtreecommitdiffstats
path: root/test/policies/example/policy.rego
blob: cc192851f30ec71edd135517fbbc93255a2deb57 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
package example

import rego.v1

allow if {
        input.path == ["users"]
        input.method == "POST"
}

allow if {
        input.path == ["users", input.user_id]
        input.method == "GET"
}