---
title: "Get Current Admin"
method: GET
path: "/api/admin"
tags: ["Admin"]
---

# Get Current Admin

`GET /api/admin`

Retrieve the current authenticated admin.

## Response `200`

Successful Response

- AdminDetails — Complete admin model with all fields for database representation and API responses.
  - `id` integer, nullable
  - `username` string, required
  - `telegram_id` integer, nullable
  - `discord_webhook` string, nullable
  - `sub_domain` string, nullable
  - `profile_title` string, nullable
  - `support_url` string, nullable
  - `custom_variables` CustomVariable[]
    - `key` string, required
    - `value` string
  - `notification_enable` UserNotificationEnable
    - `create` boolean
    - `modify` boolean
    - `delete` boolean
    - `status_change` boolean
    - `reset_data_usage` boolean
    - `data_reset_by_next` boolean
    - `subscription_revoked` boolean
  - `total_users` integer
  - `used_traffic` integer
  - `data_limit` integer, nullable
  - `status` 'active' | 'disabled' | 'limited'
  - `sub_template` string, nullable
  - `lifetime_used_traffic` integer, nullable
  - `note` string, nullable
  - `role` AdminRoleData — Runtime role data carried on AdminDetails — only the fields needed for permission checks.
    - `id` integer, nullable
    - `name` string
    - `is_owner` boolean
    - `permissions` RolePermissions — Typed permission map. Missing resource or action = denied. Each action value is True (allowed), {"scope": N} (scoped), or None (denied).
      - `users` UsersPermissions
        - `create` union
          - boolean
          - object
        - `read` union
          - boolean
          - object
        - `read_simple` union
          - boolean
          - object
        - `update` union
          - boolean
          - object
        - `delete` union
          - boolean
          - object
        - `reset_usage` union
          - boolean
          - object
        - `revoke_sub` union
          - boolean
          - object
        - `set_owner` union
          - boolean
          - object
        - `activate_next_plan` union
          - boolean
          - object
      - `admins` AdminsPermissions
        - `create` union
          - boolean
          - object
        - `read` union
          - boolean
          - object
        - `read_simple` union
          - boolean
          - object
        - `update` union
          - boolean
          - object
        - `delete` union
          - boolean
          - object
        - `reset_usage` union
          - boolean
          - object
      - `nodes` NodesPermissions
        - `create` union
          - boolean
          - object
        - `read` union
          - boolean
          - object
        - `read_simple` union
          - boolean
          - object
        - `update` union
          - boolean
          - object
        - `delete` union
          - boolean
          - object
        - `reconnect` union
          - boolean
          - object
        - `update_core` union
          - boolean
          - object
        - `logs` union
          - boolean
          - object
        - `stats` union
          - boolean
          - object
      - `groups` CRUDPermissions — Standard create/read/read_simple/update/delete permissions. Used directly by: groups, templates, client_templates, cores, admin_roles. Also serves as base for resources with additional actions.
        - `create` union
          - boolean
          - object
        - `read` union
          - boolean
          - object
        - `read_simple` union
          - boolean
          - object
        - `update` union
          - boolean
          - object
        - `delete` union
          - boolean
          - object
      - `hosts` HostsPermissions
        - `create` union
          - boolean
          - object
        - `read` union
          - boolean
          - object
        - `update` union
          - boolean
          - object
      - `templates` CRUDPermissions — Standard create/read/read_simple/update/delete permissions. Used directly by: groups, templates, client_templates, cores, admin_roles. Also serves as base for resources with additional actions.
        - `create` union
          - boolean
          - object
        - `read` union
          - boolean
          - object
        - `read_simple` union
          - boolean
          - object
        - `update` union
          - boolean
          - object
        - `delete` union
          - boolean
          - object
      - `client_templates` CRUDPermissions — Standard create/read/read_simple/update/delete permissions. Used directly by: groups, templates, client_templates, cores, admin_roles. Also serves as base for resources with additional actions.
        - `create` union
          - boolean
          - object
        - `read` union
          - boolean
          - object
        - `read_simple` union
          - boolean
          - object
        - `update` union
          - boolean
          - object
        - `delete` union
          - boolean
          - object
      - `cores` CRUDPermissions — Standard create/read/read_simple/update/delete permissions. Used directly by: groups, templates, client_templates, cores, admin_roles. Also serves as base for resources with additional actions.
        - `create` union
          - boolean
          - object
        - `read` union
          - boolean
          - object
        - `read_simple` union
          - boolean
          - object
        - `update` union
          - boolean
          - object
        - `delete` union
          - boolean
          - object
      - `settings` SettingsPermissions
        - `read` union
          - boolean
          - object
        - `read_general` union
          - boolean
          - object
        - `update` union
          - boolean
          - object
      - `system` SystemPermissions
        - `read` union
          - boolean
          - object
      - `hwids` HwidsPermissions
        - `read` union
          - boolean
          - object
        - `delete` union
          - boolean
          - object
      - `admin_roles` CRUDPermissions — Standard create/read/read_simple/update/delete permissions. Used directly by: groups, templates, client_templates, cores, admin_roles. Also serves as base for resources with additional actions.
        - `create` union
          - boolean
          - object
        - `read` union
          - boolean
          - object
        - `read_simple` union
          - boolean
          - object
        - `update` union
          - boolean
          - object
        - `delete` union
          - boolean
          - object
      - `api_keys` APIKeysPermissions
        - `create` boolean, nullable
        - `read` union
          - boolean
          - object
        - `read_simple` union
          - boolean
          - object
        - `update` union
          - boolean
          - object
        - `delete` union
          - boolean
          - object
    - `limits` RoleLimits
      - `max_users` integer, nullable
      - `data_limit_min` integer, nullable
      - `data_limit_max` integer, nullable
      - `expire_min` integer, nullable
      - `expire_max` integer, nullable
      - `min_hwid_per_user` integer, nullable
      - `max_hwid_per_user` integer, nullable
      - `on_hold_timeout_min` integer, nullable
      - `on_hold_timeout_max` integer, nullable
    - `features` RoleFeatures
      - `can_use_reset_strategy` boolean
      - `can_use_next_plan` boolean
    - `access` RoleAccess
      - `require_template` boolean
      - `allowed_template_ids` integer[], nullable
      - `allowed_group_ids` integer[], nullable
    - `hwid` RoleHWIDSettings
      - `enabled` boolean
      - `forced` boolean
      - `require_hwid_for_manual_sub` boolean
      - `fallback_limit` integer, nullable
      - `min_limit` integer, nullable
      - `max_limit` integer, nullable
      - `mode` 'disabled' | 'use_global' | 'override'
    - `disabled_when_limited` boolean
    - `disconnect_users_when_limited` boolean
    - `disconnect_users_when_disabled` boolean
  - `permission_overrides` RoleLimits
    - `max_users` integer, nullable
    - `data_limit_min` integer, nullable
    - `data_limit_max` integer, nullable
    - `expire_min` integer, nullable
    - `expire_max` integer, nullable
    - `min_hwid_per_user` integer, nullable
    - `max_hwid_per_user` integer, nullable
    - `on_hold_timeout_min` integer, nullable
    - `on_hold_timeout_max` integer, nullable
  - `is_disabled` boolean, required
  - `is_limited` boolean, required

## Other responses

- `401` — Unauthorized Error
- `403` — Forbidden Error

---

[API](https://skmtc.dev/socialser/apis/pasarguardapi.md) · [All operations](https://skmtc.dev/socialser/apis/pasarguardapi/llms.txt) · [OpenAPI document](https://skmtc-service-production.skmtc.workers.dev/v1/apis/socialser/pasarguardapi/revisions/4b082bbcb6c3/schema)
