Unkey · Schema

V2PermissionsCreateRoleRequestBody

API KeysRate LimitingAuthenticationDeveloper PlatformAccess ControlIdentityAnalytics

Properties

Name Type Description
name string The unique name for this role. Must be unique within your workspace and clearly indicate the role's purpose. Use descriptive names like 'admin', 'editor', or 'billing_manager'. Examples: 'admin.billin
description string Provides comprehensive documentation of what this role encompasses and what access it grants. Include information about the intended use case, what permissions should be assigned, and any important co
View JSON Schema on GitHub

JSON Schema

unkey-v2permissionscreaterolerequestbody-schema.json Raw ↑
{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "$id": "#/components/schemas/V2PermissionsCreateRoleRequestBody",
  "title": "V2PermissionsCreateRoleRequestBody",
  "type": "object",
  "required": [
    "name"
  ],
  "properties": {
    "name": {
      "type": "string",
      "minLength": 1,
      "maxLength": 512,
      "pattern": "^[a-zA-Z][a-zA-Z0-9._-]*$",
      "description": "The unique name for this role. Must be unique within your workspace and clearly indicate the role's purpose. Use descriptive names like 'admin', 'editor', or 'billing_manager'.\n\nExamples: 'admin.billing', 'support.readonly', 'developer.api', 'manager.analytics'\n",
      "example": "support.readonly"
    },
    "description": {
      "type": "string",
      "maxLength": 512,
      "description": "Provides comprehensive documentation of what this role encompasses and what access it grants.\nInclude information about the intended use case, what permissions should be assigned, and any important considerations.\nThis internal documentation helps team members understand role boundaries and security implications.\nNot visible to end users - designed for administration teams and access control audits.\n\nConsider documenting:\n- The role's intended purpose and scope\n- What types of users should receive this role\n- What permissions are typically associated with it\n- Any security considerations or limitations\n- Related roles that might be used together\n",
      "example": "Provides read-only access for customer support representatives. Includes permissions to view user accounts, support tickets, and basic analytics. Does not include access to billing, admin functions, or data modification capabilities."
    }
  },
  "additionalProperties": false
}