ndex_network_get_permission: Get All Permissions on a Network

Description Usage Arguments Value REST query Note Examples

View source: R/ndex_networks_ndex_properties.r

Description

This function retrieves the user or group permissions for a network

Usage

1
2
ndex_network_get_permission(ndexcon, networkId, type, permission, start,
  size)

Arguments

ndexcon

object of class NDExConnection linkndex_connect

networkId

unique ID of the network

type

character ("user"|"group"); specifies whether user or group permissions should be returned

permission

character (optional)("READ"|"WRITE"|"ADMIN"); constrains the type of the returned membership. If not set (or NULL), all permission types will be returned.

start

integer (optional); specifies that the result is the nth page of the requested data.

size

integer (optional); specifies the number of data items in each page.

Value

data.frame containing user or group UUIDs and the highest permission assigned to that user or group

REST query

GET: ndex_config$api$network$permission$get

Note

Compatible to NDEx server version 1.3 and 2.0

In version 1.3 the function only returns user permissions and differs in the returned data (more columns)!

Requires an authorized user! (ndex_connect with credentials)

Examples

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
18
## Establish a server connection with credentials 
# ndexcon = ndex_connect('MyAccountName', 'MyPassword')
## Find one of your networks and get its UUID
# networks = ndex_find_networks(ndexcon, accountName='MyAccountName')
# networkId = networks[1,"externalId"]
## Get the permissions
# permissions = ndex_network_get_permission(ndexcon, networkId, 'user')
## Version 2.0:
## names(permission)
## [1] "memberUUID" "permission"
## Version 1.3:
## names(permission)
## [1] "membershipType"    "memberUUID"  "resourceUUID"      
## [4] "memberAccountName" "permissions" "resourceName" 
# permissions = ndex_network_get_permission(ndexcon, networkId, 'user', NULL)    # same as previous
# permissions = ndex_network_get_permission(ndexcon, networkId, 'user', 'READ', 0, 10)
# permissions = ndex_network_get_permission(ndexcon, networkId, 'group')
NULL

ndexr documentation built on April 29, 2020, 5:20 a.m.