Change what someone can do
assign_member_role
Puts an existing member on a different role, which changes what they can do across the whole workspace.
It needs the Manage roles permission (roles.manage), and managing roles at all needs the workspace on Pro or Enterprise, otherwise it is refused with You must upgrade to the Pro plan to manage roles! The new role applies straight away.
The owner role cannot be given out and the owner's own role cannot be changed, so ownership never moves this way. A custom role's id comes back from create_workspace_role, and list_workspace_members shows it as the Role of everyone who holds it. See Members and roles.
Request
Call it with a POST to https://api.modulify.ai/v1/assign_member_role, sending the inputs below as a JSON object. The token needs the members:write scope.
It makes changes, so send an Idempotency-Key header whenever you might retry it. A retry with the same key gets the first answer back instead of running again.
curl -X POST https://api.modulify.ai/v1/assign_member_role \
-H "Authorization: Bearer YOUR_TOKEN" \
-H "Content-Type: application/json" \
-d '{"workspaceId":"WORKSPACE_ID","memberId":"MEMBER_ID","role":"ROLE"}'Over MCP, the same method is the assign_member_role tool.
Inputs
| Input | Type | Required | Description |
|---|---|---|---|
workspaceId |
string | Yes | The workspace id. |
memberId |
string | Yes | The member id, from list_workspace_members. |
role |
string | Yes | The role to put them on: a custom role's id, or member for the stock Member role. owner is refused. |
Response
Every call answers with the JSON envelope of success, message, data, code and version. data holds the result described above, and on a method that returns a total, count carries it. The response headers carry the call's X-Request-Id and what is left of your per-minute budget in X-RateLimit-Limit, X-RateLimit-Remaining and X-RateLimit-Reset. Errors explains every status code a call can answer with.