- Home
- Resources
- Layer admin API
Abstract class for REST webservices
POST /admin/layer
Add global layer.
Example of request:
{"layerName":"layerName","toolset":{"style":{"stroke":"#339966","stroke-width":"1","vector-effect":"none","stroke-opacity":1,"fill":"#008000","fill-opacity":1}}}
Request Body
media type |
data type |
description |
application/json |
object
|
The specification of layer that has to be added. |
Response Body
media type |
data type |
description |
application/json |
object
|
JSON Response with id of added layer
Example of response:
{"objectId":"1"}
|
DELETE /admin/layer/{layerId}
Delete layer.
Request Parameters
name |
type |
description |
default |
constraints |
layerId |
path |
ID of layer to be deleted |
|
long |
Response Body
media type |
data type |
description |
application/json |
object
|
JSON Response with information, whether the deletion has or has not
been succeeded. |
POST /admin/layer/assign/{layerId}
Assign restrictions for users or/and groups
Example of request:
{"list":[{"id":"userId"}]}
or
{"list":[{"id":"groupId"}]}
Request Parameters
name |
type |
description |
default |
constraints |
layerId |
path |
layer to be set with restrictions |
|
long |
restriction |
query |
restriction type |
|
|
Request Body
media type |
data type |
*/* |
string
|
Response Body
media type |
data type |
description |
application/json |
object
|
JSON response with information if assignment was successful or not |
GET /admin/layer/global/json
Get list of global layers
Response Body
media type |
data type |
description |
*/* |
object
|
JSON with list of layers |
GET /admin/layer/members/{layerId}
Get list of users or groups, which are restricted for editing layer
Request Parameters
name |
type |
description |
default |
constraints |
layerId |
path |
id of layer |
|
long |
mode |
query |
Could be users - get list of users or groups -
get list of groups |
|
|
restriction |
query |
restriction type |
|
|
Response Body
media type |
data type |
description |
application/json |
object
|
JSON Response with list of users
Example of response:
{"list":[{"id":2,"name":"user1","userFullName":"User 1","enabled":false,"email":""}]}
or {"list":[{"id":22,"name":"Group
C5","description":"Description of group C1","enabled":false}]} |
POST /admin/layer/unassign/{layerId}
Unassign view restrictions for users or/and groups
Example of request:
{"list":[{"id":"userId"}]}
or
{"list":[{"id":"groupId"}]}
Request Parameters
name |
type |
description |
default |
constraints |
layerId |
path |
layer to be set with restrictions |
|
long |
restriction |
query |
restriction type |
|
|
Request Body
media type |
data type |
*/* |
string
|
Response Body
media type |
data type |
description |
application/json |
object
|
JSON response with information if assignment was successful or not |