Auth API reference

Auth API · Permissions

get/v1/apps/{app_id}/permissions/enforcementAuth

List permissions that at least one Consumer-API route enforces

Returns the deduplicated set of permission strings that any handler in this users-api build gates via `@RequireAppPermission`. Drives the console "Enforced" badge — a customer who binds `user.delete` to a role can see whether any route in this deploy actually checks for it. App-agnostic in shape; the path parameter is included for URN symmetry with the rest of the per-app surface, not to narrow the response.

Path parameters

app_id*string

Id of the app.

Response · 200

data*array

Deduplicated set of `<resource>.<action>` permission strings that at least one Consumer-API route gates via `@RequireAppPermission`. App-agnostic — the same users-api binary serves every app, so the set does not vary by `:appId`. Lets the console surface an "Enforced" badge so customers can tell which catalog entries do real work.

Example: ["session.revoke","user.list"]

Example

Request

GET https://api.auth.productcraft.co/v1/apps/{app_id}/permissions/enforcement
Authorization: Bearer YOUR_TOKEN

Response

{
  "data": [
    "session.revoke",
    "user.list"
  ]
}