create_environment_role
Create a unique role inside a Scalekit environment, setting display name, description, and default assignment. Confirm existing roles first; this does not create permission scopes.
Instructions
Create one role in an environment. Use list_environment_roles to see roles that already exist. This tool does not create a permission scope. Use create_environment_scope for that. Requires the caller OAuth token. A duplicate role name is rejected.
Tool call template
Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.
{
"id": 1,
"jsonrpc": "2.0",
"method": "tools/call",
"params": {
"arguments": {
"environmentId": "<environmentId>",
"roleName": "<roleName>",
"roleDisplayName": "<roleDisplayName>"
},
"name": "create_environment_role"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| roleName | Yes | Role name stored on the environment. Must be unique in that environment. | |
| isDefault | No | When true, new organization users get this role unless another role is chosen. Default false. | |
| description | No | Human-readable explanation of the role. Empty when omitted. | |
| environmentId | Yes | Scalekit environment id. Format: env_<id>. | |
| roleDisplayName | Yes | Name shown for this role in the Scalekit dashboard. |