Change a member's role
set_member_roleChange an existing member's role in an organization. Requires owner permissions; prevents demoting the last owner, and resets the member's live sessions to apply the new role.
Instructions
Change an existing member's role in an organisation. Requires the OWNER role. Demoting the last remaining owner is refused (409) — promote someone else first. The member's live collaboration sessions are dropped so they reconnect with the new role.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| org | No | Organisation to target: an org id (org_…), slug, or name. Defaults to RAILYARD_ORG, or to your first (personal) org if that is unset. Use list_orgs to see the options. | |
| role | Yes | viewer = read-only, editor = can create and change projects, owner = full control including members and billing. | |
| userId | Yes | The member's user id (usr_…) — from list_members. |