Cerbos JavaScript SDK
    Preparing search index...

    Interface RolePolicyBody

    A policy defining rules for actions that can be performed by a given role.

    interface RolePolicyBody {
        parentRoles?: string[];
        role: string;
        rules: RoleRule[];
        scope?: string;
        version?: string;
    }
    Index

    Properties

    parentRoles?: string[]

    The list of parent roles that a custom role inherits.

    role: string

    The role to which this policy applies.

    rules: RoleRule[]

    Rules defining the actions that can be performed by the role.

    scope?: string

    Scope of the policy.

    version?: string

    The version of the policy.

    Requires the Cerbos policy decision point server to be at least v0.51.

    Policies are uniquely identified by the role name and version pair. You can have multiple policy versions for the same role (e.g. production vs. staging). The version value default is special as it is the default fallback when no version is specified in the request.

    "default"