...
Note: The "id" fields returned from /user and /userGroup are used in the "userGroupId" fields in the ACLs shown below.
Create Access Control List for a Resource
Note: This is only used when the resource 'rid' currently inherits its access control list from an ancestor. This request causes 'rid' to cease ACL inheritance and instead use the ACL passed in with the request.
Code Block |
---|
POST http://repositoryservice.sagebase.org/repo/v1/resource/{rid}/acl
{
"createdBy":"admin",
"modifiedBy":"admin",
"modifiedOn":1307141851483,
"resourceId":{rid},
"resourceAccess":[
{"userGroupId":"4",
"accessType":["READ","CHANGE_PERMISSIONS","DELETE","UPDATE","CREATE"]
}
]
}
|
Get Access Control List for a Resource
...
Code Block |
---|
{"id":"1",
"creationDate":1307141851484,
"uri":null,
"etag":"0",
"createdBy":"admin",
"resourceId":"1",
"resourceAccess":[
{"id":"1",
"userGroupId":"4",
"accessType":["READ","CHANGE_PERMISSIONS","DELETE","UPDATE","CREATE"]
}
],
"modifiedBy":"admin",
"modifiedOn":1307141851483
}
|
Create Access Control List for a Resource
Note: This is only used when the resource 'rid' currently inherits its access control list from an ancestor. This request causes 'rid' to cease ACL inheritance and instead use the ACL passed in with the request.
Code Block |
---|
POST http://repositoryservice.sagebase.org/repo/v1/resource/{rid}/acl { "createdBy":"admin", "modifiedBy":"admin", "modifiedOn":1307141851483, "resourceId":{rid}, "resourceAccess":[ {"userGroupId":"4", "accessType":["READ","CHANGE_PERMISSIONS","DELETE","UPDATE","CREATE"] } ] } |
Update Access Control List for a Resource
...