cyverse-de/permissions-client

Name: permissions-client

Owner: CyVerse Discovery Environment

Description: null

Created: 2016-08-29 19:29:37.0

Updated: 2016-08-29 23:24:10.0

Pushed: 2017-07-20 23:17:35.0

Homepage: null

Size: 38

Language: Clojure

GitHub Committers

UserMost Recent Commit# Commits

Other Committers

UserEmailMost Recent Commit# Commits

README

permissions-client

A client library for the CyVerse Discovery Environment permissions service.

Usage
uire '[permissions-client.core :as pc])

 client (pc/new-permissions-client base-uri))

et service status information.
get-status client)

ubject operations.
 subjects (pc/list-subjects client))
 subject (pc/add-subject client subject-id subject-type))
 updated-subject (pc/update-subject client (:id subject) new-subject-id new-subject-type))
delete-subject client (:id updated-subject))

esource operations.
 resources (pc/list-resources client))
 resource (pc/add-resource client resource-name resource-type-name))
 updated-resource (pc/update-resource client (:id resource) new-resource-name))
delete-resource client (:id updated-resource))

esource type operations.
 resource-types (pc/list-resource-types client))
 resource-type (pc/add-resource-type client name description))
 updated-resource-type (pc/update-resource-type client (:id resource-type) new-name new-description)
delete-resource-type client (:id updated-resource-type))

ermissions operations.
 permissions (pc/list-permissions client))
copy-permissions client subject-type subject-id [{:subject_type dest-type :subject_id dest-id}])
 permission (pc/grant-permission client resource-type resource-name subject-type subject-id permission-level))
revoke-permission client resource-type resource-name subject-type subject-id)
 permissions (pc/list-resource-permissions client resource-type resource-name))

ist permissions by subject.
 permissions (pc/get-subject-permissions client subject-type subject-id false))

ookup the highest permission levels available to a subject. If the subject is a user then the listing may
lso include permissions that are assigned to groups that the user belongs to.
 permissions (pc/get-subject-permissions client subject-type subject-id true))

ist permissions by subject and resource type.
 permissions (pc/get-subject-permissions-for-resource-type client subject-type subject-id resource-type false))

ookup the highest permission levels available to a subject for a resource type. If the subject is a user then the
isting may also include permissions that are assigned to groups that the user belongs to.
 permissions (pc/get-subject-permissions-for-resource-type client subject-type subject-id resource-type true)

ist permissions by subject and resource.
 permissions (pc/get-subject-permissions-for-resource client subject-type subject-id resource-type resource-name
                                                      false))

ookup the highest permission levels available to a subject for a resource. If the subject is a user then the
isting may also include permissions that are assigned to groups that the user belongs to.
 permissions (pc/get-subject-permissions-for-resource client subject-type subject-id resource-type resource-name
                                                      true))
License

http://www.cyverse.org/sites/default/files/iPLANT-LICENSE.txt


This work is supported by the National Institutes of Health's National Center for Advancing Translational Sciences, Grant Number U24TR002306. This work is solely the responsibility of the creators and does not necessarily represent the official views of the National Institutes of Health.