- 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}}}
Try it out!
Request Body
| media type |
data type |
description |
| application/json |
HdcVectorLayerTO
(JSON) |
The specification of layer that has to be added. |
Response Body
| media type |
data type |
description |
| application/json |
HdcBasicObjectIdOnlyTO
(JSON) |
JSON Response with id of added layer
Example of response:
{"objectId":"1"}
|
DELETE /admin/layer/{layerId}
Delete layer.
Try it out!
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 |
HdcSuccessTO
(JSON) |
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"}]}
Try it out!
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 |
| application/json |
string
(JSON) |
Response Body
| media type |
data type |
description |
| application/json |
HdcSuccessTO
(JSON) |
JSON response with information if assignment was successful or not |
GET /admin/layer/global/json
Get list of global layers
Try it out!
Response Body
| media type |
data type |
description |
| application/json |
array of HdcVectorLayerTO
(JSON) |
JSON with list of layers |
GET /admin/layer/members/{layerId}
Get list of users or groups, which are restricted for editing layer
Try it out!
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) |
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"}]}
Try it out!
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 |
| application/json |
string
(JSON) |
Response Body
| media type |
data type |
description |
| application/json |
HdcSuccessTO
(JSON) |
JSON response with information if assignment was successful or not |