Page tree

Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

...

原生的Confluence没有对页面直接进行查看和编辑的限制授权

接口

接口地址方法参数返回值说明
/rest/gearsapi/1.0/permission/page/addPOST

{
    "pageId"65552,
    "usernameListView": ["admin","user01"],
    "usernameListEdit": ["admin","user01"],
    "groupListView": ["group1""group2"],
    "groupListEdit": ["group1""group2"]
}

{
    "result": true,
    "cannext"true,
    "success": true
}
增加指定用户及用户组的查看或者编辑权限
/rest/gearsapi/1.0/permission/page/removePOST

{
    "pageId"65552,
    "usernameListView": ["admin","user01"],
    "usernameListEdit": ["admin","user01"],
    "groupListView": ["group1""group2"],
    "groupListEdit": ["group1""group2"]
}

{
    "result": true,
    "cannext"true,
    "success": true
}
删除指定用户及用户组的查看或者编辑权限
/rest/gearsapi/1.0/permission/page/nonePOST{
    "pageId"65552
}
{
    "result": true,
    "cannext"true,
    "success": true
}
设定页面不设定权限
/rest/gearsapi/1.0/permission/page/{pageId}GET
{
    "pageId"65552,
    "usernameListView": ["admin","user01"],
    "usernameListEdit": ["admin","user01"],
    "groupListView": ["group1""group2"],
    "groupListEdit": ["group1""group2"]
}

pageId:填写pageId的值










参数说明

参数说明
 pageId数值需要授权的页面ID
usernameListView用户账户对列["admin","user01"],具有查看权限;可以为空
usernameListEdit用户组名称对列["group1","group2"],具有编辑权限;可以为空
groupListView用户账户对列["admin","user01"],具有查看权限;可以为空
groupListEdit用户组名称对列["group1","group2"],具有编辑权限;可以为空

...