add rbacs
All checks were successful
Build and Publish / build-release (push) Successful in 2m4s

This commit is contained in:
2026-05-07 14:01:18 -05:00
parent 9439c62507
commit 07a232c131
3 changed files with 17 additions and 11 deletions

View File

@@ -28,10 +28,12 @@ defmodule PolicyServiceWeb.Router do
scope "/v1" do
pipe_through [:authenticated, :authorized]
get "/policies", PolicyController, :index
get "/policies/:application_id", PolicyController, :show
post "/policies", PolicyController, :create
post "/policies/:application_id/accept", PolicyController, :accept
get "/policies", PolicyController, :index, required_permission: "policy:read"
get "/policies/:application_id", PolicyController, :show, required_permission: "policy:read"
post "/policies", PolicyController, :create, required_permission: "policy:create_request"
post "/policies/:application_id/accept", PolicyController, :accept,
required_permission: "policy:submit_solicitation"
end
end