# Give a person on this workspace a custom role, or none

`PUT /workspace/people/{pid}/role-definition` · Rivier · workspace

Give a person on this workspace a custom role, or none.

- Scope: workspace:admin
- Graphql: Mutation.workspaceRoleAssignmentSet
- Sdk: workspace.roleAssignment.set
- Cli: workspace role assignment set

## Parameters

- `pid` (path, required), string

## Request body

`application/json`

```json
{
  "type": "object",
  "properties": {
    "role_definition_id": {
      "anyOf": [
        {
          "type": "string",
          "format": "uuid"
        },
        {
          "type": "null"
        }
      ]
    }
  },
  "required": [
    "role_definition_id"
  ],
  "additionalProperties": false
}
```

## Responses

- `200`: Success
- `400`: The request was malformed
- `401`: No valid credential
- `403`: The credential lacks the scope, origin or address
- `429`: Over the key's rate limit; see Retry-After

## Example

```sh
curl -X PUT 'https://api.rivier.ai/workspace/people/{pid}/role-definition' \
  -H 'Authorization: Bearer $KEY' \
  -H 'Content-Type: application/json' \
  -d '{
  "role_definition_id": "string"
}'
```
