1

How to get Access Right Template list

Тема: How to get Access Right Template list

Dear Partners

We want to get Access Right Template list (http://docs.wialon.com/en/hosting/cms/r … _templates) using Remote API but we don't know which command we should use in post/get. Would you please help us?

2

How to get Access Right Template list

Re: How to get Access Right Template list

hhamedk, access templates are stored in user's  custom property "access_templates".
After login with token https://hst-api.wialon.com/wialon/ajax.html?svc=token/login&params={"token":<your token>}
You'll get user's json. In section user->prp->access_templates there is json-string for access templates.
The structure of json:

{
    "avl_unit":
    [
        {"id":0,"name":"No access","color":"#ffd9bf","acl":0},
        {"id":1,"name":"Full access","color":"#d3bfe5","acl":4503599627370495},
        {"id":2,"name":"Read only","acl":305,"color":"#cae5bf"}
    ],
    "avl_unit_group":[...],
    "avl_resource":[...],
    "avl_route":[...],
    "user":[...]
}

where:
    id - internal identifier
    name - access template name
    acl - template's access flags
    color - color of template

Head of Wialon Local Department
Gurtam