# createRole

## Overview

Creates a new role with the given name, description, and permissions. Auto-assigned permissions (user-management:profile) are always included.

## Modules Commands Used

- [user-management] CreateRole

## Exception Handling

| Error Code | Description |
| --- | --- |
| USER_MANAGEMENT_ROLE_ALREADY_EXISTS | A role with the same name already exists |
| USER_MANAGEMENT_MISSING_REQUIRED_FIELD | Role name is required |
| USER_MANAGEMENT_INVALID_PERMISSION | Invalid permission format |
| INSUFFICIENT_PERMISSION | The caller does not have permission to perform this operation |
