Akeda Settings roles API

Модуль settings (участники, роли, юрлица) — роли, их носители и перенос носителей

Operations 5

GET /api/v1/settings/permission-catalog Получить каталог прав кабинета #
GET /api/v1/settings/role-templates Получить шаблоны ролей по функциям #
GET /api/v1/settings/roles Получить роли кабинета #
GET /api/v1/settings/roles/{id} Получить роль кабинета #
GET /api/v1/settings/roles/{id}/members Получить носителей роли #

Work with this as data

Every API here is available over the APIs.io API and to AI agents over MCP.

MCP server

One button, every client — Claude, Cursor, VS Code and the rest.

https://apis.io/mcp

Tools for apis

7 MCP tools reach this
  • find_apisBrowse and filter every API in the catalog.
  • get_api_artifactsOne API's artifacts, grouped by type.
  • get_openapiThe primary OpenAPI for this API.
  • find_similar_apisAPIs that look like this one.
  • apis_io_searchSTART HERE — APIs, providers and tags for one query, each with its total.
  • resolveTurn a domain, URL or GitHub org into the provider it belongs to.
  • find_cohortsEvery scored population of providers in the catalog.
All 92 tools →

Call it yourself

curl for this page
This API
curl "https://apis.io/api/v1/apis/akeda-ru:akeda-ru-settings-roles-api"
All apis
curl "https://apis.io/api/v1/apis?limit=25"

Discovery needs no key. Ratings and market analysis are Pro.

Get an API key

Free tier, no form to fill in. Signing in shares your email address with us — we store it to create your key and to recognise you if you sign in with another provider. See our Privacy Policy and Terms.

A second provider on the same verified email joins the account you already have.

OpenAPI Specification

akeda-ru-settings-roles-api-openapi.yml Raw ↑
openapi: 3.2.0
info:
  title: Akeda ERP Client Settings roles API
  version: 0.21.0-core-public
  summary: Проверяемый публичный контракт Go API Akeda ERP
  license:
    name: Proprietary
    identifier: LicenseRef-Akeda-Proprietary
  description: 'Этот контракт описывает API Akeda ERP. Полный исходный файл используют

    проверки живых Go-маршрутов, внутренние клиенты и реестр MCP. Скачиваемый

    клиентский контракт в `/docs` содержит только отобранные внешние методы;

    административные методы кабинета показаны отдельно после входа, а

    платформенные операторские методы остаются во внутреннем источнике.

    Стадия `public` означает обещание совместимости; `preview` допускает

    изменение формы. Аудитория, стадия и `security` — разные признаки:

    наличие метода в полном файле само по себе не выдаёт вызывающему право.

    Сервер отдельно проверяет тип токена, кабинет, scope и права на запись.

    Актуальные числа покрытия берите из генерируемой карты маршрутов и

    каталога покрытия, а не из описательного текста.'
servers:
- url: https://erp.akeda.ru
  description: PROD
security:
- erpUserToken: []
- tenantApiKey: []
- mcpOAuth:
  - akeda:delegate
tags:
- name: Settings roles
  description: Модуль settings (участники, роли, юрлица) — роли, их носители и перенос носителей
paths:
  /api/v1/settings/permission-catalog:
    get:
      tags:
      - Settings roles
      operationId: settingsPermissionCatalog
      summary: Получить каталог прав кабинета
      description: 'Модули, их разделы и ресурсы и действия со строками прав и подписями на языке запроса. Источник тот же, что у политик движка прав, поэтому строка из каталога что-то открывает, а строку вне каталога сохранение роли отклоняет с кодом 422. Выключенные в кабинете модули тоже показаны — роль можно подготовить заранее. Разметка под шкалу роли: у действия — ступень «Смотрит» или «Работает» (`level`) либо группа дополнительных прав (`extra`), у раздела — до какой ступени его покрывает право модуля (`inherit`) и подзаголовок (`heading`).'
      x-akeda-module: settings
      x-akeda-release-stage: preview
      x-akeda-audience: external
      x-akeda-permission: settings:read
      parameters:
      - $ref: '#/components/parameters/TenantHeader'
      responses:
        '200':
          description: Каталог прав
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/SettingsPermissionCatalog'
        '401':
          $ref: '#/components/responses/Unauthorized'
        '403':
          $ref: '#/components/responses/Forbidden'
  /api/v1/settings/role-templates:
    get:
      tags:
      - Settings roles
      operationId: settingsListRoleTemplates
      summary: Получить шаблоны ролей по функциям
      description: Готовые наборы прав для кладовщика, логиста, менеджера маркетплейсов, бухгалтера и других функций. Права выключенных в кабинете модулей не входят в состав и перечислены в missing_modules.
      x-akeda-module: settings
      x-akeda-release-stage: preview
      x-akeda-audience: external
      x-akeda-permission: settings:read
      parameters:
      - $ref: '#/components/parameters/TenantHeader'
      responses:
        '200':
          description: Шаблоны ролей
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/SettingsRoleTemplatePage'
        '401':
          $ref: '#/components/responses/Unauthorized'
        '403':
          $ref: '#/components/responses/Forbidden'
  /api/v1/settings/roles:
    get:
      tags:
      - Settings roles
      operationId: settingsListRoles
      summary: Получить роли кабинета
      description: Отдаёт роли кабинета без страниц. Без параметра status в выдачу попадают только действующие роли.
      x-akeda-module: settings
      x-akeda-release-stage: preview
      x-akeda-audience: external
      x-akeda-permission: settings:read
      parameters:
      - $ref: '#/components/parameters/TenantHeader'
      - name: status
        in: query
        schema:
          type: string
          enum:
          - active
          - disabled
          - all
        description: Умолчание — active; disabled отдаёт только отключённые роли
      responses:
        '200':
          description: Роли кабинета
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/SettingsRolePage'
        '401':
          $ref: '#/components/responses/Unauthorized'
        '403':
          $ref: '#/components/responses/Forbidden'
  /api/v1/settings/roles/{id}:
    get:
      tags:
      - Settings roles
      operationId: settingsGetRole
      summary: Получить роль кабинета
      description: 'Отдаёт одну роль целиком: права и правила видимости записей, в том числе у отключённой роли. Присланный в правке список permissions заменяет прежний целиком; чтобы выдать или снять несколько прав, правка шлёт add_permissions и remove_permissions.'
      x-akeda-module: settings
      x-akeda-release-stage: preview
      x-akeda-audience: external
      x-akeda-permission: settings:read
      parameters:
      - $ref: '#/components/parameters/TenantHeader'
      - name: id
        in: path
        required: true
        schema:
          $ref: '#/components/schemas/UUID'
      responses:
        '200':
          description: Роль кабинета
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/SettingsRole'
        '400':
          $ref: '#/components/responses/BadRequest'
        '401':
          $ref: '#/components/responses/Unauthorized'
        '403':
          $ref: '#/components/responses/Forbidden'
        '404':
          $ref: '#/components/responses/NotFound'
  /api/v1/settings/roles/{id}/members:
    get:
      tags:
      - Settings roles
      operationId: settingsListRoleMembers
      summary: Получить носителей роли
      description: 'Показывает всех участников кабинета с этой ролью, включая отключённых: перед отключением роли перевести нужно и их. Форма ответа совпадает со списком участников кабинета.'
      x-akeda-module: settings
      x-akeda-release-stage: preview
      x-akeda-audience: external
      x-akeda-permission: settings:read
      parameters:
      - $ref: '#/components/parameters/TenantHeader'
      - name: id
        in: path
        required: true
        schema:
          $ref: '#/components/schemas/UUID'
      responses:
        '200':
          description: Носители роли
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/SettingsMemberPage'
        '400':
          $ref: '#/components/responses/BadRequest'
        '401':
          $ref: '#/components/responses/Unauthorized'
        '403':
          $ref: '#/components/responses/Forbidden'
        '404':
          $ref: '#/components/responses/NotFound'
components:
  responses:
    Forbidden:
      description: Текущая роль не имеет требуемого права
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/Error'
    BadRequest:
      description: Некорректный запрос или нарушение бизнес-правила
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/Error'
    Unauthorized:
      description: Сессия, ключ или кабинет не подтверждены
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/Error'
    NotFound:
      description: Запись не найдена или не видима текущему пользователю
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/Error'
  schemas:
    SettingsPermissionModule:
      type: object
      additionalProperties: false
      required:
      - key
      - label
      - enabled
      - actions
      - units
      - record_rules
      properties:
        key:
          type: string
        label:
          type: string
        label_key:
          type: string
        enabled:
          type: boolean
          description: Модуль включён в кабинете
        actions:
          type: array
          items:
            $ref: '#/components/schemas/SettingsPermissionAction'
        units:
          type: array
          items:
            $ref: '#/components/schemas/SettingsPermissionUnit'
        record_rules:
          type: array
          items:
            $ref: '#/components/schemas/SettingsPermissionRecordRule'
    SettingsPermissionRecordRule:
      type: object
      additionalProperties: false
      required:
      - resource
      - label
      - rules
      properties:
        resource:
          type: string
        label:
          type: string
        rules:
          type: array
          items:
            type: string
            enum:
            - own
            - projects
            - team
            - department
            - department_tree
            - all
        unit:
          type: string
          description: Строка карточки, у которой редактор показывает «Чьи»; пусто — шапка модуля
        units:
          type: array
          items:
            type: string
          description: Строки карточки, совместно использующие область записей этого ресурса; unit остаётся совместимым основным значением.
        action:
          type: string
          description: Дополнительное право, к которому относится «Чьи»
    SettingsMemberPage:
      type: object
      additionalProperties: false
      required:
      - count
      - results
      properties:
        count:
          type: integer
          minimum: 0
          description: Число строк в results, а не общее число участников кабинета
        results:
          type: array
          items:
            $ref: '#/components/schemas/SettingsMember'
    SettingsPermissionAction:
      type: object
      additionalProperties: false
      required:
      - permission
      - verb
      - label
      - implies
      properties:
        permission:
          type: string
          description: Строка права для поля permissions роли
        verb:
          type: string
        label:
          type: string
        hint:
          type: string
        implies:
          type: array
          items:
            type: string
          description: 'Строки, которые ставятся вместе с этой: изменение без просмотра не откроет экран'
        level:
          type: integer
          enum:
          - 1
          - 2
          description: 'Ступень шкалы своей строки (у действия модуля — шкалы модуля): 1 — «Смотрит», 2 — «Работает». Ступень из нескольких строк ставится и снимается целиком'
        extra:
          type: string
          enum:
          - money
          - outside
          - others
          - people
          - admin
          description: 'Группа блока «Дополнительные права»: money — деньги и цены, outside — подпись и отправка наружу, others — решения по чужому, people — данные людей, admin — администрирование модулей. Действие без level и extra редактор не показывает, строка остаётся допустимой'
        includes:
          type: array
          items:
            type: string
          description: 'Строки, которые сервер даёт вместе с этим правом. Только для показа: в роль не пишутся'
    SettingsMemberBusinessScope:
      type: object
      additionalProperties: false
      required:
      - business
      properties:
        business:
          $ref: '#/components/schemas/UUID'
        company:
          $ref: '#/components/schemas/UUID'
          description: Сужает доступ до юрлица этого бизнеса; без поля — бизнес целиком
    SettingsMember:
      type: object
      additionalProperties: false
      required:
      - id
      - user_id
      - username
      - full_name
      - birth_date
      - avatar_url
      - role
      - role_name
      - company_scope
      - companies
      - is_active
      - all_businesses
      - businesses
      - access_until
      - access_closed
      - is_guest
      properties:
        id:
          $ref: '#/components/schemas/UUID'
          description: Идентификатор членства в кабинете, а не человека
        user_id:
          type: integer
          format: int64
          description: Идентификатор человека в общем реестре платформы
        username:
          type: string
        full_name:
          type: string
        birth_date:
          oneOf:
          - type: string
            format: date
          - type: 'null'
        avatar_url:
          type: string
        role:
          oneOf:
          - $ref: '#/components/schemas/UUID'
          - type: 'null'
        role_name:
          oneOf:
          - type: string
          - type: 'null'
        company_scope:
          type: string
          enum:
          - all
          - selected
        companies:
          type: array
          items:
            $ref: '#/components/schemas/UUID'
          description: Заполнен при company_scope selected
        is_active:
          type: boolean
        all_businesses:
          type: boolean
          description: Роль действует во всех бизнесах кабинета, включая заведённые позже. У администратора всегда true
        businesses:
          type: array
          items:
            $ref: '#/components/schemas/SettingsMemberBusinessScope'
          description: Бизнесы сотрудника; пуст при all_businesses
        access_until:
          oneOf:
          - type: string
            format: date
          - type: 'null'
          description: 'Последний день доступа в этом кабинете: после конца этого дня в поясе кабинета вход закрыт. null — доступ бессрочный'
        access_closed:
          type: boolean
          description: 'Последний день доступа уже прошёл: участник числится активным, но войти не может и места тарифа не занимает'
        is_guest:
          type: boolean
          description: 'Гость-подрядчик (карточка «Команды» с affiliation guest): права роли сужены до задач, чата и файлов «только где участник», места тарифа не занимает'
    Error:
      type: object
      additionalProperties: false
      required:
      - detail
      properties:
        detail:
          type: string
          description: One human sentence in the request language (Accept-Language, echoed as Content-Language)
        code:
          type: string
          description: Stable module error code when the endpoint defines one
        field:
          type: string
          description: Request body path of the field the refusal is about, e.g. content.commercial.amount or due_date; present when the endpoint names the field
        reason:
          type: string
          description: Machine code of the field refusal reason, e.g. required, format, total_mismatch; present together with field when the endpoint defines reasons
        request_id:
          type: string
          format: uuid
          description: Case id. Always present on 5xx and on any error produced by the server itself; the same value is returned in the X-Request-ID header and recorded in the access log and the incident. Quote it to support instead of the cause, which the response never carries.
    SettingsRolePage:
      type: object
      additionalProperties: false
      required:
      - count
      - results
      properties:
        count:
          type: integer
          minimum: 0
          description: Число строк в results, а не общее число ролей кабинета
        results:
          type: array
          items:
            $ref: '#/components/schemas/SettingsRole'
    SettingsRole:
      type: object
      additionalProperties: false
      required:
      - id
      - name
      - is_admin
      - is_active
      - permissions
      - record_rules
      properties:
        id:
          $ref: '#/components/schemas/UUID'
        name:
          type: string
        is_admin:
          type: boolean
          description: У административной роли permissions всегда равны ["*:*"]
        is_active:
          type: boolean
        permissions:
          type: array
          items:
            type: string
          description: Право записывается как «модуль:действие», например settings:read
        unknown_permissions:
          type: array
          readOnly: true
          items:
            type: string
          description: Stored permission strings that the current authorization engine no longer recognizes. Returned when reading roles; omit these inactive strings when copying a role. Existing permissions and valid aliases remain unchanged.
        record_rules:
          type: object
          additionalProperties:
            type: string
            enum:
            - own
            - projects
            - team
            - department
            - department_tree
            - all
          description: 'Ключ — ресурс модуля: tasks.task, crm.lead, crm.deal, crm.customer, crm.conversation, core.order, docflow.payment_request и ресурсы клиентских модулей. Значение — own (свои), projects (свои и проекты участия, у задач), team (свои и подчинённых), department (своего подразделения), department_tree (подразделения с подотделами) или all (все записи области). Пустая карта означает видимость только своих записей'
    SettingsRoleTemplate:
      type: object
      additionalProperties: false
      required:
      - key
      - name
      - description
      - permissions
      - record_rules
      - missing_modules
      properties:
        key:
          type: string
        name:
          type: string
        description:
          type: string
        permissions:
          type: array
          items:
            type: string
        record_rules:
          type: object
          additionalProperties:
            type: string
            enum:
            - own
            - projects
            - team
            - department
            - department_tree
            - all
        missing_modules:
          type: array
          items:
            type: string
          description: 'Модули шаблона, выключенные в кабинете: их права в роль не попадут'
    UUID:
      type: string
      format: uuid
    SettingsPermissionUnit:
      type: object
      additionalProperties: false
      required:
      - key
      - kind
      - label
      - exclusive
      - technical
      - actions
      - inherit
      properties:
        key:
          type: string
          description: 'Полный ключ раздела или ресурса: модуль.единица'
        kind:
          type: string
          enum:
          - section
          - resource
        label:
          type: string
        label_key:
          type: string
        hint:
          type: string
        exclusive:
          type: boolean
          description: 'Право на модуль единицу не покрывает: выдаётся только своей строкой'
        technical:
          type: boolean
          description: Ресурс выдаётся разделом; своей галочки в редакторе нет, но строка допустима
        actions:
          type: array
          items:
            $ref: '#/components/schemas/SettingsPermissionAction'
        heading:
          type: string
          description: 'Ключ подзаголовка внутри карточки модуля: группа меню финансов, настройки CRM или склада'
        heading_label:
          type: string
          description: Подзаголовок на языке запроса
        card:
          type: string
          enum:
          - trade
          description: 'Виртуальная карточка редактора вместо карточки модуля: trade — «Продажи и закупки»'
        inherit:
          type: integer
          enum:
          - 0
          - 1
          - 2
          description: 'До какой ступени строку покрывает право модуля: 2 — целиком, 1 — только «Смотрит», 0 — не покрывает'
    SettingsRoleTemplatePage:
      type: object
      additionalProperties: false
      required:
      - count
      - results
      properties:
        count:
          type: integer
          minimum: 0
        results:
          type: array
          items:
            $ref: '#/components/schemas/SettingsRoleTemplate'
    SettingsPermissionCatalog:
      type: object
      additionalProperties: false
      required:
      - modules
      - wildcards
      properties:
        modules:
          type: array
          items:
            $ref: '#/components/schemas/SettingsPermissionModule'
        wildcards:
          type: array
          items:
            type: string
          description: 'Строки полного доступа: их выдаёт только администратор кабинета'
  parameters:
    TenantHeader:
      name: X-Tenant
      in: header
      required: true
      description: Slug выбранного кабинета; кабинет не является юрлицом
      schema:
        type: string
        minLength: 1
  securitySchemes:
    erpUserToken:
      type: http
      scheme: bearer
      bearerFormat: go_session
      description: Пользовательский ERP token, полученный через ORY Kratos session bridge
    tenantApiKey:
      type: apiKey
      in: header
      name: X-Api-Key
      description: Tenant-scoped сервисный API-ключ Akeda
    installationToken:
      type: http
      scheme: bearer
      bearerFormat: akeda_installation_token
      description: 'Краткосрочный токен установки приложения (`ai_…`). Выдаёт его человек: публичной двери обмена учётных данных на токен нет и не будет, пока нет брокера долгой половины секрета, асимметричного подтверждения и ограничителя с аудитом неудачных попыток. Токен принимается и в заголовке X-Api-Key, и живёт минуты — вместо показа его ротируют'
    developerSessionToken:
      type: http
      scheme: bearer
      bearerFormat: akeda_developer_session
      description: 'Сессия аккаунта разработчика (`ad_…`). Своя схема, а не пользовательский токен ERP: у разработчика нет кабинета, роли и прав, а хеш этого токена лежит в отдельном хранилище — на кабинетных маршрутах он не находится ничем. Выдаёт его обмен одноразовой ссылки из письма; пароля в этом контуре нет вовсе'
    developerAppKey:
      type: http
      scheme: bearer
      bearerFormat: akeda_developer_app_key
      description: 'Учётные данные приложения (`adk_…`) — это машина конвейера издателя, а не человек. Ключ привязан к ОДНОМУ приложению внешним ключом, и достижимая им поверхность — маршруты `/api/v1/developer` этого приложения. Обменять его на токен установки нельзя: такой двери нет, и ни одного маршрута к данным кабинета за ним не существует. Выпуск, ротацию и отзыв учётных данных этот ключ не выполняет: ключ, умеющий выпустить следующий ключ, не отзывается никогда. Значение показывается один раз, при выдаче; в хранилище лежит хеш'
    mcpOAuth:
      type: oauth2
      description: OAuth 2.1 delegation для MCP; кабинетные права проверяются на каждом вызове
      flows:
        authorizationCode:
          authorizationUrl: https://erp.akeda.ru/oauth2/authorize
          tokenUrl: https://erp.akeda.ru/oauth2/token
          scopes:
            akeda:delegate: Делегировать текущие пользовательские права MCP-подключению
x-akeda-contract-coverage:
- dashboard-metrics
- tasks-lifecycle
- tasks-collaboration
- tasks-workflow
- tasks-organization
- tasks-automation
- tasks-planning
- tasks-project-hub
- tasks-files
- calendar-events
- calendar-availability
- calendar-booking
- calendar-notifications
- calendar-connectors
- chat-conversations
- chat-messages
- chat-receipts
- chat-mentions
- chat-realtime
- core-directories
- core-folders
- core-contacts
- core-products
- core-documents
- core-orders
- core-registers
- core-accounting
- core-ledger
- core-items
- core-employees
- core-employee-operations
- core-currency-rates
- core-preferences
- core-ui-state
- core-external-refs
- core-product-imports
- core-product-exports
- core-gl-opening-imports
- core-reference
- core-change-feed
- finance-accounts
- finance-statements
- finance-transactions
- finance-connectors
- finance-connector-sync
- finance-requisites
- finance-counterparty-terms
- finance-operations
- finance-settlements
- finance-trade
- finance-exchange
- finance-imports
- finance-payment-calendar
- finance-pnl-layouts
- finance-registers
- finance-reports
- crm-pipelines
- crm-deals
- crm-leads
- crm-customers
- crm-links
- crm-inbox
- crm-automation
- crm-analytics
- knowledge-spaces
- knowledge-pages
- knowledge-access
- knowledge-files
- knowledge-search
- files-drives
- files-content
- files-access
- files-uploads
- files-shares
- stock-documents
- stock-inventory
- stock-warehouses
- stock-handling-units
- stock-batches
- stock-product-units
- stock-references
- stock-imports
- stock-exports
- stock-reports
- stock-valuation
- stock-reorder-rules
- stock-settings
- stock-purchasing
- marking-settings
- marking-connections
- marking-products
- marking-codes
- marking-labels
- marking-stock-codes
- marking-orders
- marking-gismt-documents
- marking-boxes
- marketplace-stores
- marketplace-ozon
- marketplace-wildberries
- marketplace-yandex
- marketplace-product-groups
- marketplace-accounting
- marketplace-catalog
- settings-companies
- settings-roles
- settings-members
- settings-fields
- settings-api-keys
- finance-payroll
- finance-report-details
- knowledge-tags
- knowledge-revisions
- knowledge-approval
- chat-attachments
- chat-reactions
- chat-folders
- platform-apps
- platform-app-installations
- platform-app-tokens
- platform-app-deliveries
- platform-app-publishers
- platform-app-publication
- platform-app-rollouts
- platform-app-runtime
- platform-app-access
- platform-app-blocks
- platform-demo-data
- billing-usage
- platform-analytics
- finance-staffing
- platform-tenants
- platform-users
- platform-access
- platform-mcp-publication
- platform-incidents
- platform-health
- settings-apps
- docflow-connections
- docflow-mirror
- docflow-signing
- docflow-actions
- docflow-outgoing
- docflow-intake
- docflow-flow
- docflow-approvals
- docflow-flow-accounting
- mail-accounts
- mail-folders
- mail-messages
- mail-rules
- mail-outbound
- mail-attachments
- billing-plans
- billing-subscriptions
- billing-invoices
- billing-analytics
- settings-subscription
- billing-payments
- billing-public
x-akeda-docs-path: /docs
x-akeda-default-release-stage: internal
x-akeda-default-audience: operator