Роли и доступы

Список ролей get

https://userID.aircrm.pro/api/roles

Headers

Content-TypeRequired string application/json
AuthenticationRequired string {token}

Получить роль get

https://userID.aircrm.pro/api/roles/{id}

Headers

Content-TypeRequired string application/json
AuthenticationRequired string {token}

Path Parameters

idRequired integer ID-записи

Создать роль post

https://userID.aircrm.pro/api/roles

Headers

Content-TypeRequired string application/json
AuthenticationRequired string {token}

Body Parameters

nameRequired string
permissionsOptional array Массив разрешений роли

Пример:
[
  "view own activities",
  "delete own activities",
  "view own companies",
  "edit own companies",
]

Редактировать роль put

https://userID.aircrm.pro/api/roles/{id}

Headers

Content-TypeRequired string application/json
AuthenticationRequired string {token}

Path Parameters

idRequired integer ID-записи

Body Parameters

nameRequired string
permissionsOptional array Массив разрешений роли

Пример:
[
  "view own activities",
  "delete own activities",
  "view own companies",
  "edit own companies",
]

Удалить роль delete

https://userID.aircrm.pro/api/roles/{id}

Headers

Content-TypeRequired string application/json
AuthenticationRequired string {token}

Path Parameters

idRequired integer ID-записи

Получение разрешений get

https://userID.aircrm.pro/api/permissions

Headers

Content-TypeRequired string application/json
AuthenticationRequired string {token}