corestack_ team_ member_ role_ attach
Give a team member a role.
When to use it
Give a team member one more role, one you may give them (corestack_team_roles_list, assignable). This is
POST /api/roles/attach. An agent never raises the permissions of the person it acts for: giving that person a role
that adds a permission or an owner role they do not hold now is refused own_permissions_upward.
Ask for it
Using the Corefinity MCP server, call corestack_team_member_role_attach with user_id 1042, role client-member-full. (Give a team member a role.) Tell me what it returned.Inputs
rolestringRequired
The role's slug. Up to 255 characters.
user_idintegerRequired
The team member's id (corestack_team_members_list). At least 1.
Example call
{
"name": "corestack_team_member_role_attach",
"arguments": {
"user_id": 1042,
"role": "client-member-full"
}
}If it is refused
| Reason | What to do |
|---|---|
privileged_target | The account's roles are not yours to change. Only a super administrator may change a super administrator's roles. A company owner's roles are changed only by themself, another owner of the same company or Corefinity staff, and the company's primary user's only by themself or staff. |
forbidden | Only an owner may give roles. |
owner_grant | Only an owner of the company, or Corefinity staff, may make someone an owner (agency-owner or client-owner); holding the edit users or invite users permission is not enough. Message: "Only an owner or Corefinity staff can make someone an owner." |
permission_grant | The role carries a permission you do not hold (a custom role always; a standard role unless you are an owner of the company or Corefinity staff). Message: "You can only give someone a role if you hold all of its permissions yourself." |
own_permissions_upward | The role would give the person you act for more access; ask them to make the change in the Control Panel. |
invalid_arguments | On user_id (nobody you may see: another company's user answers like a missing one), on message (a role you may not give this member), user (they already hold it) or role (no such role). |
tenant_mismatch | The object does not exist or the token may not see it. Check the id. |
scope_required | The token lacks a scope this call needs. Open the link in the answer to add it, then call again. |
pin_refused | The grant is limited to chosen clusters, sites or environments, and this call is outside them. Open the link in the answer to widen it. |
rate_limited | Too many calls. Wait for the number of seconds the answer names. |
temporarily_unavailable | The Control Panel could not answer just now. Nothing was started; try again shortly. |
internal_error | Something went wrong on our side. Quote the trace id to support. |
The same task elsewhere
Was this helpful?