---
metadata:
  - name: generator
    content: Diplodoc Platform v5.70.0
alternate:
  - https://yandex.ru/support/wiki/en/api-ref/pages_access/pagesaccess__create_page_access.md
  - https://yandex.ru/support/wiki/ru/api-ref/pages_access/pagesaccess__create_page_access.md
  - href: https://yandex.ru/support/wiki/en/api-ref/pages_access/pagesaccess__create_page_access.md
    type: text/markdown
    title: Markdown version
  - href: https://yandex.ru/support/wiki/en/llms.txt?revision=r22094953
    rel: describedby
---
> **Documentation Index:** Fetch the complete configuration index at https://yandex.ru/support/wiki/en/llms.txt?revision=r22094953

<div class="openapi">

# Add User/Group Access to a Page

<!-- markdownlint-disable-file -->

Grants personal access to the page to the specified user or group.

You can grant one of the following roles:
- `reader`: Read.
- `editor`: Edit.
- `extra_editor`: Extended editing.
- `author`: Author (full access).

The available roles depend on the organization's access mode.
Legacy mode supports `editor` and `author`. The `author` role can be assigned only to a user.

For common headers and authentication methods, see [Access to the API](https://yandex.ru/support/wiki/en/api-ref/access.md#headers). For sample scenarios, see [API usage examples](https://yandex.ru/support/wiki/en/api-ref/examples.md).

## Request

<div class="openapi__requests">

<div class="openapi__request__wrapper" style="--method: var(--dc-openapi-methods-post);margin-bottom: 12px">

<div class="openapi__request">

POST {.openapi__method}
```text translate=no
https://api.wiki.yandex.net/v1/pages/{idx}/access
```

</div>

</div>

</div>

### Path parameters

#|
|| **Name** | **Description** ||
||

_idx_{.json-schema-reset .json-schema-property .json-schema-required}
{.table-cell}|
**Type**: integer

Page ID. The value of `idx` is the same as the `id` field value in the response to `GET /v1/pages?slug=…` or `POST /v1/pages`.
{.table-cell}
||
|#{.json-schema-properties}

<div class="openapi-entity">

### Body

{% cut "application/json" %}

```json translate=no
{
  "user": {
    "uid": "example",
    "cloud_uid": "example"
  },
  "group": {
    "src": "dir",
    "id": "example"
  },
  "role": "reader",
  "inheritance": "inherited"
}
```

{% endcut %}

#|
|| **Name** | **Description** ||
||

_role_{.json-schema-reset .json-schema-property .json-schema-required}
{.table-cell}|
{% cut "**All of 1 type**" %}{.json-schema-combinators data-marker=and}

- **RoleAPI**

  **Type**: [RoleAPI](#entity-RoleAPI)

  Page access role:
  - `reader`: Read.
  - `editor`: Edit.
  - `extra_editor`: Extended editing.
  - `author`: Author (full access).

  _Enum:_{.json-schema-reset .json-schema-value} `reader`, `editor`, `extra_editor`, `author`

{% endcut %}

Access role: `reader` (read), `editor` (edit), `extra_editor` (extended edit), `author` (author)

_Example:_{.json-schema-reset .json-schema-example} `reader`
{.table-cell}
||
||

_group_{.json-schema-reset .json-schema-property}
{.table-cell}|
{% cut "**All of 1 type**" %}{.json-schema-combinators data-marker=and}

- **ComIdentitySchema**

  **Type**: [ComIdentitySchema](#entity-ComIdentitySchema)

  Group identifier

  {% cut "**Example**" %}{.json-schema-example}

  ```json translate=no
  {
    "src": "dir",
    "id": "example"
  }
  ```

  {% endcut %}

{% endcut %}

ID of the group to grant access to. Specify either `user` or `group`

{% cut "**Example**" %}{.json-schema-example}

```json translate=no
{
  "src": "dir",
  "id": "example"
}
```

{% endcut %}
{.table-cell}
||
||

_inheritance_{.json-schema-reset .json-schema-property}
{.table-cell}|
{% cut "**All of 1 type**" %}{.json-schema-combinators data-marker=and}

- **InheritanceAPI**

  **Type**: [InheritanceAPI](#entity-InheritanceAPI)

  Access inheritance for subpages:
  - `inherited`: Subpages inherit the access permission.
  - `not_inherited`: Subpages do not inherit the access permission.

  _Enum:_{.json-schema-reset .json-schema-value} `inherited`, `not_inherited`

{% endcut %}

Access inheritance for subpages: `inherited` (inherited), `not_inherited` (not inherited)

_Example:_{.json-schema-reset .json-schema-example} `inherited`
{.table-cell}
||
||

_user_{.json-schema-reset .json-schema-property}
{.table-cell}|
{% cut "**All of 1 type**" %}{.json-schema-combinators data-marker=and}

- **UserIdentity**

  **Type**: [UserIdentity](#entity-UserIdentity)

  User identifier

  {% cut "**Example**" %}{.json-schema-example}

  ```json translate=no
  {
    "uid": "example",
    "cloud_uid": "example"
  }
  ```

  {% endcut %}

{% endcut %}

ID of the user to grant access to. Specify either `user` or `group`

{% cut "**Example**" %}{.json-schema-example}

```json translate=no
{
  "uid": "example",
  "cloud_uid": "example"
}
```

{% endcut %}
{.table-cell}
||
|#{.json-schema-properties}

</div>

<div class="openapi-entity">

### UserIdentity {#entity-UserIdentity}

User identifier

#|
|| **Name** | **Description** ||
||

_cloud_uid_{.json-schema-reset .json-schema-property}
{.table-cell}|
**Type**: string

User identifier in the cloud

_Example:_{.json-schema-reset .json-schema-example} `example`
{.table-cell}
||
||

_uid_{.json-schema-reset .json-schema-property}
{.table-cell}|
**Type**: string

Yandex user ID

_Example:_{.json-schema-reset .json-schema-example} `example`
{.table-cell}
||
|#{.json-schema-properties}

{% cut "**Example**" %}{.json-schema-example}

```json translate=no
{
  "uid": "example",
  "cloud_uid": "example"
}
```

{% endcut %}

</div>

<div class="openapi-entity">

### ComSource {#entity-ComSource}

Source of the group ID:
- `dir`: IAM.
- `cloud`: Yandex Cloud.
- `com`: Local database.
- `staff`: Internal employee directory.

**Type**: string

_Enum:_{.json-schema-reset .json-schema-value} `dir`, `cloud`, `com`, `staff`

</div>

<div class="openapi-entity">

### ComIdentitySchema {#entity-ComIdentitySchema}

Group identifier

#|
|| **Name** | **Description** ||
||

_id_{.json-schema-reset .json-schema-property .json-schema-required}
{.table-cell}|
**Type**: string

Group identifier in the specified source

_Example:_{.json-schema-reset .json-schema-example} `example`
{.table-cell}
||
||

_src_{.json-schema-reset .json-schema-property .json-schema-required}
{.table-cell}|
{% cut "**All of 1 type**" %}{.json-schema-combinators data-marker=and}

- **ComSource**

  **Type**: [ComSource](#entity-ComSource)

  Source of the group ID:
  - `dir`: IAM.
  - `cloud`: Yandex Cloud.
  - `com`: Local database.
  - `staff`: Internal employee directory.

  _Enum:_{.json-schema-reset .json-schema-value} `dir`, `cloud`, `com`, `staff`

{% endcut %}

Identifier source

_Example:_{.json-schema-reset .json-schema-example} `dir`
{.table-cell}
||
|#{.json-schema-properties}

{% cut "**Example**" %}{.json-schema-example}

```json translate=no
{
  "src": "dir",
  "id": "example"
}
```

{% endcut %}

</div>

<div class="openapi-entity">

### RoleAPI {#entity-RoleAPI}

Page access role:
- `reader`: Read.
- `editor`: Edit.
- `extra_editor`: Extended editing.
- `author`: Author (full access).

**Type**: string

_Enum:_{.json-schema-reset .json-schema-value} `reader`, `editor`, `extra_editor`, `author`

</div>

<div class="openapi-entity">

### InheritanceAPI {#entity-InheritanceAPI}

Access inheritance for subpages:
- `inherited`: Subpages inherit the access permission.
- `not_inherited`: Subpages do not inherit the access permission.

**Type**: string

_Enum:_{.json-schema-reset .json-schema-value} `inherited`, `not_inherited`

</div>

## Responses

<div class="openapi__response__code__200">

## 200 OK

OK

<div class="openapi-entity">

### Body

{% cut "application/json" %}

```json translate=no
{
  "id": "example",
  "created_at": "2025-01-01T00:00:00Z",
  "user": {
    "id": 0,
    "identity": {
      "uid": "example",
      "cloud_uid": "example"
    },
    "username": "example",
    "display_name": "example",
    "is_dismissed": true,
    "affiliation": "example"
  },
  "group": {
    "id": "example",
    "identity": {
      "src": null,
      "id": "example"
    },
    "name": "example",
    "type": "wiki",
    "metadata": {
      "url": "example",
      "externals_count": 0
    },
    "members_count": 0
  },
  "role": "reader",
  "inheritance": "inherited"
}
```

{% endcut %}

#|
|| **Name** | **Description** ||
||

_id_{.json-schema-reset .json-schema-property .json-schema-required}
{.table-cell}|
**Type**: string

Unique access identifier

_Example:_{.json-schema-reset .json-schema-example} `example`
{.table-cell}
||
||

_role_{.json-schema-reset .json-schema-property .json-schema-required}
{.table-cell}|
{% cut "**All of 1 type**" %}{.json-schema-combinators data-marker=and}

- **RoleAPI**

  **Type**: [RoleAPI](#entity-RoleAPI)

  Page access role:
  - `reader`: Read.
  - `editor`: Edit.
  - `extra_editor`: Extended editing.
  - `author`: Author (full access).

  _Enum:_{.json-schema-reset .json-schema-value} `reader`, `editor`, `extra_editor`, `author`

{% endcut %}

Access role

_Example:_{.json-schema-reset .json-schema-example} `reader`
{.table-cell}
||
||

_created_at_{.json-schema-reset .json-schema-property}
{.table-cell}|
**Type**: string&lt;date-time&gt;

Date and time the access was created

_Example:_{.json-schema-reset .json-schema-example} `2025-01-01T00:00:00Z`
{.table-cell}
||
||

_group_{.json-schema-reset .json-schema-property}
{.table-cell}|
{% cut "**All of 1 type**" %}{.json-schema-combinators data-marker=and}

- **GroupSchema**

  **Type**: [GroupSchema](#entity-GroupSchema)

  Group information

  {% cut "**Example**" %}{.json-schema-example}

  ```json translate=no
  {
    "id": "example",
    "identity": {
      "src": "dir",
      "id": "example"
    },
    "name": "example",
    "type": "wiki",
    "metadata": {
      "url": "example",
      "externals_count": 0
    },
    "members_count": 0
  }
  ```

  {% endcut %}

{% endcut %}

Group granted access (populated if access was granted to a group)

{% cut "**Example**" %}{.json-schema-example}

```json translate=no
{
  "id": "example",
  "identity": {
    "src": "dir",
    "id": "example"
  },
  "name": "example",
  "type": "wiki",
  "metadata": {
    "url": "example",
    "externals_count": 0
  },
  "members_count": 0
}
```

{% endcut %}
{.table-cell}
||
||

_inheritance_{.json-schema-reset .json-schema-property}
{.table-cell}|
{% cut "**All of 1 type**" %}{.json-schema-combinators data-marker=and}

- **InheritanceAPI**

  **Type**: [InheritanceAPI](#entity-InheritanceAPI)

  Access inheritance for subpages:
  - `inherited`: Subpages inherit the access permission.
  - `not_inherited`: Subpages do not inherit the access permission.

  _Enum:_{.json-schema-reset .json-schema-value} `inherited`, `not_inherited`

{% endcut %}

Access inheritance setting for subpages

_Example:_{.json-schema-reset .json-schema-example} `inherited`
{.table-cell}
||
||

_user_{.json-schema-reset .json-schema-property}
{.table-cell}|
{% cut "**All of 1 type**" %}{.json-schema-combinators data-marker=and}

- **UserSchema**

  **Type**: [UserSchema](#entity-UserSchema)

  User information

  {% cut "**Example**" %}{.json-schema-example}

  ```json translate=no
  {
    "id": 0,
    "identity": {
      "uid": "example",
      "cloud_uid": "example"
    },
    "username": "example",
    "display_name": "example",
    "is_dismissed": true,
    "affiliation": "example"
  }
  ```

  {% endcut %}

{% endcut %}

User granted access (populated if access was granted to a user)

{% cut "**Example**" %}{.json-schema-example}

```json translate=no
{
  "id": 0,
  "identity": {
    "uid": "example",
    "cloud_uid": "example"
  },
  "username": "example",
  "display_name": "example",
  "is_dismissed": true,
  "affiliation": "example"
}
```

{% endcut %}
{.table-cell}
||
|#{.json-schema-properties}

</div>

<div class="openapi-entity">

### UserSchema {#entity-UserSchema}

User information

#|
|| **Name** | **Description** ||
||

_affiliation_{.json-schema-reset .json-schema-property .json-schema-required}
{.table-cell}|
**Type**: string

User affiliation

_Example:_{.json-schema-reset .json-schema-example} `example`
{.table-cell}
||
||

_display_name_{.json-schema-reset .json-schema-property .json-schema-required}
{.table-cell}|
**Type**: string

User display name

_Example:_{.json-schema-reset .json-schema-example} `example`
{.table-cell}
||
||

_id_{.json-schema-reset .json-schema-property .json-schema-required}
{.table-cell}|
**Type**: integer

Internal user identifier
{.table-cell}
||
||

_is_dismissed_{.json-schema-reset .json-schema-property .json-schema-required}
{.table-cell}|
**Type**: boolean

The user is dismissed
{.table-cell}
||
||

_username_{.json-schema-reset .json-schema-property .json-schema-required}
{.table-cell}|
**Type**: string

User login

_Example:_{.json-schema-reset .json-schema-example} `example`
{.table-cell}
||
||

_identity_{.json-schema-reset .json-schema-property}
{.table-cell}|
{% cut "**All of 1 type**" %}{.json-schema-combinators data-marker=and}

- **UserIdentity**

  **Type**: [UserIdentity](#entity-UserIdentity)

  User identifier

  {% cut "**Example**" %}{.json-schema-example}

  ```json translate=no
  {
    "uid": "example",
    "cloud_uid": "example"
  }
  ```

  {% endcut %}

{% endcut %}

User identifier in the system

{% cut "**Example**" %}{.json-schema-example}

```json translate=no
{
  "uid": "example",
  "cloud_uid": "example"
}
```

{% endcut %}
{.table-cell}
||
|#{.json-schema-properties}

{% cut "**Example**" %}{.json-schema-example}

```json translate=no
{
  "id": 0,
  "identity": {
    "uid": "example",
    "cloud_uid": "example"
  },
  "username": "example",
  "display_name": "example",
  "is_dismissed": true,
  "affiliation": "example"
}
```

{% endcut %}

</div>

<div class="openapi-entity">

### GroupType {#entity-GroupType}

Group type:
- `wiki`: Wiki group.
- `service`: Service group.
- `servicerole`: Service role.
- `group`: Regular group.
- `department`: Department.

**Type**: string

_Enum:_{.json-schema-reset .json-schema-value} `wiki`, `service`, `servicerole`, `group`, `department`

</div>

<div class="openapi-entity">

### IntranetGroupMetadata {#entity-IntranetGroupMetadata}

Group metadata from the internal directory

#|
|| **Name** | **Description** ||
||

_externals_count_{.json-schema-reset .json-schema-property}
{.table-cell}|
**Type**: integer

Number of external consultants in the group
{.table-cell}
||
||

_url_{.json-schema-reset .json-schema-property}
{.table-cell}|
**Type**: string

Group URL in the directory

_Example:_{.json-schema-reset .json-schema-example} `example`
{.table-cell}
||
|#{.json-schema-properties}

{% cut "**Example**" %}{.json-schema-example}

```json translate=no
{
  "url": "example",
  "externals_count": 0
}
```

{% endcut %}

</div>

<div class="openapi-entity">

### IamGroupMetadata {#entity-IamGroupMetadata}

Group metadata from IAM (Identity and Access Management)

#|
|| **Name** | **Description** ||
||

_dir_id_{.json-schema-reset .json-schema-property .json-schema-required}
{.table-cell}|
**Type**: string

Directory identifier

_Example:_{.json-schema-reset .json-schema-example} `example`
{.table-cell}
||
|#{.json-schema-properties}

{% cut "**Example**" %}{.json-schema-example}

```json translate=no
{
  "dir_id": "example"
}
```

{% endcut %}

</div>

<div class="openapi-entity">

### GroupSchema {#entity-GroupSchema}

Group information

#|
|| **Name** | **Description** ||
||

_identity_{.json-schema-reset .json-schema-property .json-schema-required}
{.table-cell}|
{% cut "**All of 1 type**" %}{.json-schema-combinators data-marker=and}

- **ComIdentitySchema**

  **Type**: [ComIdentitySchema](#entity-ComIdentitySchema)

  Group identifier

  {% cut "**Example**" %}{.json-schema-example}

  ```json translate=no
  {
    "src": "dir",
    "id": "example"
  }
  ```

  {% endcut %}

{% endcut %}

Group identifier in the system

{% cut "**Example**" %}{.json-schema-example}

```json translate=no
{
  "src": "dir",
  "id": "example"
}
```

{% endcut %}
{.table-cell}
||
||

_name_{.json-schema-reset .json-schema-property .json-schema-required}
{.table-cell}|
**Type**: string

Group name

_Example:_{.json-schema-reset .json-schema-example} `example`
{.table-cell}
||
||

_type_{.json-schema-reset .json-schema-property .json-schema-required}
{.table-cell}|
{% cut "**All of 1 type**" %}{.json-schema-combinators data-marker=and}

- **GroupType**

  **Type**: [GroupType](#entity-GroupType)

  Group type:
  - `wiki`: Wiki group.
  - `service`: Service group.
  - `servicerole`: Service role.
  - `group`: Regular group.
  - `department`: Department.

  _Enum:_{.json-schema-reset .json-schema-value} `wiki`, `service`, `servicerole`, `group`, `department`

{% endcut %}

Group type

_Example:_{.json-schema-reset .json-schema-example} `wiki`
{.table-cell}
||
||

_id_{.json-schema-reset .json-schema-property}
{.table-cell}|
**Type**: string

Group ID. Uses dir_id in the external version and staff_id in the internal version.

_Example:_{.json-schema-reset .json-schema-example} `example`
{.table-cell}
||
||

_members_count_{.json-schema-reset .json-schema-property}
{.table-cell}|
**Type**: integer

Number of group members

_Default:_{.json-schema-reset .json-schema-value} `0`
{.table-cell}
||
||

_metadata_{.json-schema-reset .json-schema-property}
{.table-cell}|
{% cut "**Any of 2 types**" %}{.json-schema-combinators data-marker=or}

- **IntranetGroupMetadata**

  **Type**: [IntranetGroupMetadata](#entity-IntranetGroupMetadata)

  Group metadata from the internal directory

  {% cut "**Example**" %}{.json-schema-example}

  ```json translate=no
  {
    "url": "example",
    "externals_count": 0
  }
  ```

  {% endcut %}

- **IamGroupMetadata**

  **Type**: [IamGroupMetadata](#entity-IamGroupMetadata)

  Group metadata from IAM (Identity and Access Management)

  {% cut "**Example**" %}{.json-schema-example}

  ```json translate=no
  {
    "dir_id": "example"
  }
  ```

  {% endcut %}

{% endcut %}

Additional group metadata

{% cut "**Example**" %}{.json-schema-example}

```json translate=no
{
  "url": "example",
  "externals_count": 0
}
```

{% endcut %}
{.table-cell}
||
|#{.json-schema-properties}

{% cut "**Example**" %}{.json-schema-example}

```json translate=no
{
  "id": "example",
  "identity": {
    "src": "dir",
    "id": "example"
  },
  "name": "example",
  "type": "wiki",
  "metadata": {
    "url": "example",
    "externals_count": 0
  },
  "members_count": 0
}
```

{% endcut %}

</div>

</div>

</div>

[*Deprecated]: No longer supported, please use an alternative and newer version.