Content Permissions

Set database restriction state

Changed on

Sets the restriction state of a database.

Permissions required: Permission to edit the database or administer the space.

put/databases/{id}/restriction-state

Request

  • Base URL
    https://no-default/wiki/api/v2
  • URL
    https://no-default/wiki/api/v2/databases/{id}/restriction-state
  • Auth
    • HTTP basic
    • or OAuth 2
      Authorization code: https://auth.atlassian.com/authorize
      Token URL: https://auth.atlassian.com/oauth/token scopes: write:database:confluence

Path parameters

idinteger required

The ID of the database.

Query parameters

allow-self-lockoutboolean

If false (default), the request is rejected when it would remove the calling user's own edit access. Set to true to allow the operation even when it locks out the caller.

Request body

state'OPEN' | 'EDIT_RESTRICTED' | 'VIEW_RESTRICTED' required

The direct restriction state of a content item. Inherited restrictions are not represented by this REST enum.

  • OPEN – No direct restrictions. Effective access may still be restricted by a parent.
  • EDIT_RESTRICTED – Direct viewing is open but editing is restricted to explicitly granted users/groups.
  • VIEW_RESTRICTED – Direct viewing and editing are restricted to explicitly granted users/groups.

Response

Returned if the state was successfully updated.

state'OPEN' | 'EDIT_RESTRICTED' | 'VIEW_RESTRICTED' required

The direct restriction state of a content item. Inherited restrictions are not represented by this REST enum.

  • OPEN – No direct restrictions. Effective access may still be restricted by a parent.
  • EDIT_RESTRICTED – Direct viewing is open but editing is restricted to explicitly granted users/groups.
  • VIEW_RESTRICTED – Direct viewing and editing are restricted to explicitly granted users/groups.
createdAtstring date-time

ISO-8601 timestamp of when the restriction was set. Absent when the state is OPEN.

createdBystring

Atlassian Account ID of the user who set the restriction. Absent when the state is OPEN.

createdByAaidstring

Deprecated alias for createdBy. Use createdBy instead. Absent when the state is OPEN.

Changes