---
ai:
  exclude: true
search:
  tags:
    - Space Permissions
    - PUT
seo:
  description: >-
    Grant permissions to a user in… Reference for the PUT
    /rest/api/space/{spaceKey}/permissions/user/{userKey}/grant endpoint in the
    Confluence Data Center API.
sidebar:
  label: Grants space permissions to a user
  badge: PUT
title: Grants space permissions to a user
type: openapi-operation
---
Grant permissions to a user in the given space.
Operation doesn't override existing permissions, will only add those one that weren't granted before.
Multiple permissions could be passed in one request. Supported targetType and operationKey pairs:
* space read
* space administer
* space export
* space restrict
* space delete_own
* space delete_mail
* page create
* page delete
* blogpost create
* blogpost delete
* comment create
* comment delete
* attachment create
* attachment delete

See &lt;a href="https://confluence.atlassian.com/display/DOC/Space+Permissions+Overview">Space Permissions documentation&lt;/a> for additional information about supported permissions.

Example request URI's:
`https://example.com/confluence/rest/api/space/TESTSPACE/permissions/user/4028ae289154667d0191546bd5840000/grant`

`PUT /rest/api/space/{spaceKey}/permissions/user/{userKey}/grant`

**Request body** (`application/json`)

Request body example:

```json
[
  {
    "targetType": "space",
    "operationKey": "read"
  },
  {
    "targetType": "page",
    "operationKey": "create"
  }
]
```

**Responses**

- `204` — Space permissions successfully granted to a user.
- `400` — Returned if incorrect permissions are passed in request (for e.g. non existing operation or global permission).
- `401` — Returned if the calling User is not authenticated.
- `403` — Returned if the calling User does not have necessary permission.
- `404` — Returned if user with specified key not found.
