changes.mady.by.user Ivan Pavlovcik
Saved on Aug 01, 2018
...
URL: https://api-stage.bimplus.net/v2/<team_slug>/roles
Example: https://api-stage.bimplus.net/v2/bimplus/roles
JSON Structure:
Name
Mandatory / Optional
Type
Description
id
optional
string (guid)
Id of the role
name
mandatory
string
The name of the role
parent
The Id of the parent role
customRole
boolean
When this flag is true the role is custom role otherwise will role is 'built in' role
resources
JSON Array
Array of the right resource type definition objects for which the role is valid
JSON Structure of the right resource type definition object:
resource
Describe kind of right resource type e.g. Global" or "Layer", etc.
rights
Array of the strings with right names e.g.: "FreeAttributeView", "RoomModel"
Array of the objects with properties id, name, access :
Authorization: BimPlus 9c1874a62c974dcfa75e0132c423a088 Content-Type: application/json
{ "name":"Test", "customRole":true, "resources":[{ "id":"4e587ea1-5098-45cd-9655-15f90c16dc58", "resource":"Layer", "rights":["RoomModelRoom" ], "rightsAccess":[{ "id":"52bbc329-dab3-a81c-b548-09c715786a81", "name":"RoomModel", "access":"Edit" } ] } ], "projectRightsRolesTemplate":{ "id":"894072db-e1cb-48f1-a672-999356d66311" } }
Status: 201 Created
{ "name":"Test", "customRole":true, "resources":[{ "id":"4e587ea1-5098-45cd-9655-15f90c16dc58", "resource":"Layer", "rights":["RoomModelRoom" ], "rightsAccess":[{ "id":"52bbc329-dab3-a81c-b548-09c715786a81", "name":"RoomModel", "access":"Edit" } ] } ], "projectRightsRolesTemplate":{ "id":"894072db-e1cb-48f1-a672-999356d66311", "name":"CustomProjectRightsRolesTemplate", "description":"Custom template for rights and roles" } }