Grafana · Capability

Grafana — Users

Grafana — Users. 49 operations. Lead operation: Grafana List Users Roles. Self-contained Naftiko capability covering one Grafana business surface.

Run with Naftiko GrafanaUsers

What You Can Do

POST
Listusersroles — Grafana List Users Roles
/v1/access-control/users/roles/search
GET
Listuserroles — Grafana List User Roles
/v1/access-control/users/{userid}/roles
PUT
Setuserroles — Grafana Set User Roles
/v1/access-control/users/{userid}/roles
POST
Adduserrole — Grafana Add User Role
/v1/access-control/users/{userid}/roles
DELETE
Removeuserrole — Grafana Remove User Role
/v1/access-control/users/{userid}/roles/{roleuid}
POST
Setresourcepermissionsforuser — Grafana Set Resource Permissions For User
/v1/access-control/{resource}/{resourceid}/users/{userid}
POST
Postsyncuserwithldap — Grafana Post Sync User With LDAP
/v1/admin/ldap/sync/{user-id}
GET
Getuserfromldap — Grafana Get User From LDAP
/v1/admin/ldap/{user-name}
POST
Admincreateuser — Grafana Admin Create User
/v1/admin/users
DELETE
Admindeleteuser — Grafana Admin Delete User
/v1/admin/users/{user-id}
GET
Admingetuserauthtokens — Grafana Admin Get User Auth Tokens
/v1/admin/users/{user-id}/auth-tokens
POST
Admindisableuser — Grafana Admin Disable User
/v1/admin/users/{user-id}/disable
POST
Adminenableuser — Grafana Admin Enable User
/v1/admin/users/{user-id}/enable
POST
Adminlogoutuser — Grafana Admin Logout User
/v1/admin/users/{user-id}/logout
PUT
Adminupdateuserpassword — Grafana Admin Update User Password
/v1/admin/users/{user-id}/password
PUT
Adminupdateuserpermissions — Grafana Admin Update User Permissions
/v1/admin/users/{user-id}/permissions
GET
Getuserquota — Grafana Get User Quota
/v1/admin/users/{user-id}/quotas
PUT
Updateuserquota — Grafana Update User Quota
/v1/admin/users/{user-id}/quotas/{quota-target}
POST
Adminrevokeuserauthtoken — Grafana Admin Revoke User Auth Token
/v1/admin/users/{user-id}/revoke-auth-token
GET
Getorgusersforcurrentorg — Grafana Get Org Users For Current Org
/v1/org/users
POST
Addorgusertocurrentorg — Grafana Add Org User To Current Org
/v1/org/users
GET
Getorgusersforcurrentorglookup — Grafana Get Org Users For Current Org Lookup
/v1/org/users/lookup
DELETE
Removeorguserforcurrentorg — Grafana Remove Org User For Current Org
/v1/org/users/{user-id}
PATCH
Updateorguserforcurrentorg — Grafana Update Org User For Current Org
/v1/org/users/{user-id}
GET
Getorgusers — Grafana Get Org Users
/v1/orgs/{org-id}/users
POST
Addorguser — Grafana Add Org User
/v1/orgs/{org-id}/users
GET
Searchorgusers — Grafana Search Org Users
/v1/orgs/{org-id}/users/search
DELETE
Removeorguser — Grafana Remove Org User
/v1/orgs/{org-id}/users/{user-id}
PATCH
Updateorguser — Grafana Update Org User
/v1/orgs/{org-id}/users/{user-id}
GET
Getsignedinuser — Grafana Get Signed In User
/v1/user
PUT
Updatesignedinuser — Grafana Update Signed In User
/v1/user
GET
Getuserauthtokens — Grafana Get User Auth Tokens
/v1/user/auth-tokens
GET
Updateuseremail — Grafana Update User Email
/v1/user/email/update
GET
Getsignedinuserorglist — Grafana Get Signed In User Org List
/v1/user/orgs
PUT
Changeuserpassword — Grafana Change User Password
/v1/user/password
GET
Getuserpreferences — Grafana Get User Preferences
/v1/user/preferences
PUT
Updateuserpreferences — Grafana Update User Preferences
/v1/user/preferences
PATCH
Patchuserpreferences — Grafana Patch User Preferences
/v1/user/preferences
GET
Getuserquotas — Grafana Get User Quotas
/v1/user/quotas
POST
Revokeuserauthtoken — Grafana Revoke User Auth Token
/v1/user/revoke-auth-token
GET
Getsignedinuserteamlist — Grafana Get Signed In User Team List
/v1/user/teams
POST
Usersetusingorg — Grafana User Set Using Org
/v1/user/using/{org-id}
GET
Searchusers — Grafana Search Users
/v1/users
GET
Getuserbyloginoremail — Grafana Get User By Login Or Email
/v1/users/lookup
GET
Searchuserswithpaging — Grafana Search Users With Paging
/v1/users/search
GET
Getuserbyid — Grafana Get User By ID
/v1/users/{user-id}
PUT
Updateuser — Grafana Update User
/v1/users/{user-id}
GET
Getuserorglist — Grafana Get User Org List
/v1/users/{user-id}/orgs
GET
Getuserteams — Grafana Get User Teams
/v1/users/{user-id}/teams

MCP Tools

grafana-list-users-roles

Grafana List Users Roles

read-only
grafana-list-user-roles

Grafana List User Roles

read-only idempotent
grafana-set-user-roles

Grafana Set User Roles

idempotent
grafana-add-user-role

Grafana Add User Role

grafana-remove-user-role

Grafana Remove User Role

idempotent
grafana-set-resource-permissions-user

Grafana Set Resource Permissions For User

grafana-post-sync-user-ldap

Grafana Post Sync User With LDAP

grafana-get-user-ldap

Grafana Get User From LDAP

read-only idempotent
grafana-admin-create-user

Grafana Admin Create User

grafana-admin-delete-user

Grafana Admin Delete User

idempotent
grafana-admin-get-user-auth

Grafana Admin Get User Auth Tokens

read-only idempotent
grafana-admin-disable-user

Grafana Admin Disable User

grafana-admin-enable-user

Grafana Admin Enable User

grafana-admin-logout-user

Grafana Admin Logout User

grafana-admin-update-user-password

Grafana Admin Update User Password

idempotent
grafana-admin-update-user-permissions

Grafana Admin Update User Permissions

idempotent
grafana-get-user-quota

Grafana Get User Quota

read-only idempotent
grafana-update-user-quota

Grafana Update User Quota

idempotent
grafana-admin-revoke-user-auth

Grafana Admin Revoke User Auth Token

grafana-get-org-users-current

Grafana Get Org Users For Current Org

read-only idempotent
grafana-add-org-user-current

Grafana Add Org User To Current Org

grafana-get-org-users-current-2

Grafana Get Org Users For Current Org Lookup

read-only idempotent
grafana-remove-org-user-current

Grafana Remove Org User For Current Org

idempotent
grafana-update-org-user-current

Grafana Update Org User For Current Org

idempotent
grafana-get-org-users

Grafana Get Org Users

read-only idempotent
grafana-add-org-user

Grafana Add Org User

grafana-search-org-users

Grafana Search Org Users

read-only idempotent
grafana-remove-org-user

Grafana Remove Org User

idempotent
grafana-update-org-user

Grafana Update Org User

idempotent
grafana-get-signed-user

Grafana Get Signed In User

read-only idempotent
grafana-update-signed-user

Grafana Update Signed In User

idempotent
grafana-get-user-auth-tokens

Grafana Get User Auth Tokens

read-only idempotent
grafana-update-user-email

Grafana Update User Email

read-only idempotent
grafana-get-signed-user-org

Grafana Get Signed In User Org List

read-only idempotent
grafana-change-user-password

Grafana Change User Password

idempotent
grafana-get-user-preferences

Grafana Get User Preferences

read-only idempotent
grafana-update-user-preferences

Grafana Update User Preferences

idempotent
grafana-patch-user-preferences

Grafana Patch User Preferences

idempotent
grafana-get-user-quotas

Grafana Get User Quotas

read-only idempotent
grafana-revoke-user-auth-token

Grafana Revoke User Auth Token

grafana-get-signed-user-team

Grafana Get Signed In User Team List

read-only idempotent
grafana-user-set-using-org

Grafana User Set Using Org

grafana-search-users

Grafana Search Users

read-only idempotent
grafana-get-user-login-email

Grafana Get User By Login Or Email

read-only idempotent
grafana-search-users-paging

Grafana Search Users With Paging

read-only idempotent
grafana-get-user-id

Grafana Get User By ID

read-only idempotent
grafana-update-user

Grafana Update User

idempotent
grafana-get-user-org-list

Grafana Get User Org List

read-only idempotent
grafana-get-user-teams

Grafana Get User Teams

read-only idempotent

Capability Spec

grafana-users-2.yaml Raw ↑
naftiko: 1.0.0-alpha2
info:
  label: Grafana — Users
  description: 'Grafana — Users. 49 operations. Lead operation: Grafana List Users Roles. Self-contained Naftiko capability
    covering one Grafana business surface.'
  tags:
  - Grafana
  - Users
  created: '2026-05-19'
  modified: '2026-05-19'
binds:
- namespace: env
  keys:
    GRAFANA_API_KEY: GRAFANA_API_KEY
capability:
  consumes:
  - type: http
    namespace: grafana-users-2
    baseUri: http://{defaultHost}
    description: Grafana — Users business capability. Self-contained, no shared references.
    resources:
    - name: access-control-users-roles-search
      path: /access-control/users/roles/search
      operations:
      - name: listusersroles
        method: POST
        description: Grafana List Users Roles
        outputRawFormat: json
        outputParameters:
        - name: result
          type: object
          value: $.
        inputParameters:
        - name: body
          in: body
          type: object
          description: Request body (JSON).
          required: true
    - name: access-control-users-userId-roles
      path: /access-control/users/{userId}/roles
      operations:
      - name: listuserroles
        method: GET
        description: Grafana List User Roles
        outputRawFormat: json
        outputParameters:
        - name: result
          type: object
          value: $.
        inputParameters:
        - name: userId
          in: path
          type: integer
          required: true
      - name: setuserroles
        method: PUT
        description: Grafana Set User Roles
        outputRawFormat: json
        outputParameters:
        - name: result
          type: object
          value: $.
        inputParameters:
        - name: userId
          in: path
          type: integer
          required: true
        - name: body
          in: body
          type: object
          description: Request body (JSON).
          required: true
      - name: adduserrole
        method: POST
        description: Grafana Add User Role
        outputRawFormat: json
        outputParameters:
        - name: result
          type: object
          value: $.
        inputParameters:
        - name: userId
          in: path
          type: integer
          required: true
        - name: body
          in: body
          type: object
          description: Request body (JSON).
          required: true
    - name: access-control-users-userId-roles-roleUID
      path: /access-control/users/{userId}/roles/{roleUID}
      operations:
      - name: removeuserrole
        method: DELETE
        description: Grafana Remove User Role
        outputRawFormat: json
        outputParameters:
        - name: result
          type: object
          value: $.
        inputParameters:
        - name: global
          in: query
          type: boolean
          description: A flag indicating if the assignment is global or not. If set to false, the default org ID of the authenticated
            user will be used from the request to remove assi
        - name: roleUID
          in: path
          type: string
          required: true
        - name: userId
          in: path
          type: integer
          required: true
    - name: access-control-resource-resourceID-users-userID
      path: /access-control/{resource}/{resourceID}/users/{userID}
      operations:
      - name: setresourcepermissionsforuser
        method: POST
        description: Grafana Set Resource Permissions For User
        outputRawFormat: json
        outputParameters:
        - name: result
          type: object
          value: $.
        inputParameters:
        - name: resource
          in: path
          type: string
          required: true
        - name: resourceID
          in: path
          type: string
          required: true
        - name: userID
          in: path
          type: integer
          required: true
        - name: body
          in: body
          type: object
          description: Request body (JSON).
          required: true
    - name: admin-ldap-sync-user_id
      path: /admin/ldap/sync/{user_id}
      operations:
      - name: postsyncuserwithldap
        method: POST
        description: Grafana Post Sync User With LDAP
        outputRawFormat: json
        outputParameters:
        - name: result
          type: object
          value: $.
        inputParameters:
        - name: user_id
          in: path
          type: integer
          required: true
    - name: admin-ldap-user_name
      path: /admin/ldap/{user_name}
      operations:
      - name: getuserfromldap
        method: GET
        description: Grafana Get User From LDAP
        outputRawFormat: json
        outputParameters:
        - name: result
          type: object
          value: $.
        inputParameters:
        - name: user_name
          in: path
          type: string
          required: true
    - name: admin-users
      path: /admin/users
      operations:
      - name: admincreateuser
        method: POST
        description: Grafana Admin Create User
        outputRawFormat: json
        outputParameters:
        - name: result
          type: object
          value: $.
        inputParameters:
        - name: body
          in: body
          type: object
          description: Request body (JSON).
          required: true
    - name: admin-users-user_id
      path: /admin/users/{user_id}
      operations:
      - name: admindeleteuser
        method: DELETE
        description: Grafana Admin Delete User
        outputRawFormat: json
        outputParameters:
        - name: result
          type: object
          value: $.
        inputParameters:
        - name: user_id
          in: path
          type: integer
          required: true
    - name: admin-users-user_id-auth-tokens
      path: /admin/users/{user_id}/auth-tokens
      operations:
      - name: admingetuserauthtokens
        method: GET
        description: Grafana Admin Get User Auth Tokens
        outputRawFormat: json
        outputParameters:
        - name: result
          type: object
          value: $.
        inputParameters:
        - name: user_id
          in: path
          type: integer
          required: true
    - name: admin-users-user_id-disable
      path: /admin/users/{user_id}/disable
      operations:
      - name: admindisableuser
        method: POST
        description: Grafana Admin Disable User
        outputRawFormat: json
        outputParameters:
        - name: result
          type: object
          value: $.
        inputParameters:
        - name: user_id
          in: path
          type: integer
          required: true
    - name: admin-users-user_id-enable
      path: /admin/users/{user_id}/enable
      operations:
      - name: adminenableuser
        method: POST
        description: Grafana Admin Enable User
        outputRawFormat: json
        outputParameters:
        - name: result
          type: object
          value: $.
        inputParameters:
        - name: user_id
          in: path
          type: integer
          required: true
    - name: admin-users-user_id-logout
      path: /admin/users/{user_id}/logout
      operations:
      - name: adminlogoutuser
        method: POST
        description: Grafana Admin Logout User
        outputRawFormat: json
        outputParameters:
        - name: result
          type: object
          value: $.
        inputParameters:
        - name: user_id
          in: path
          type: integer
          required: true
    - name: admin-users-user_id-password
      path: /admin/users/{user_id}/password
      operations:
      - name: adminupdateuserpassword
        method: PUT
        description: Grafana Admin Update User Password
        outputRawFormat: json
        outputParameters:
        - name: result
          type: object
          value: $.
        inputParameters:
        - name: user_id
          in: path
          type: integer
          required: true
        - name: body
          in: body
          type: object
          description: Request body (JSON).
          required: true
    - name: admin-users-user_id-permissions
      path: /admin/users/{user_id}/permissions
      operations:
      - name: adminupdateuserpermissions
        method: PUT
        description: Grafana Admin Update User Permissions
        outputRawFormat: json
        outputParameters:
        - name: result
          type: object
          value: $.
        inputParameters:
        - name: user_id
          in: path
          type: integer
          required: true
        - name: body
          in: body
          type: object
          description: Request body (JSON).
          required: true
    - name: admin-users-user_id-quotas
      path: /admin/users/{user_id}/quotas
      operations:
      - name: getuserquota
        method: GET
        description: Grafana Get User Quota
        outputRawFormat: json
        outputParameters:
        - name: result
          type: object
          value: $.
        inputParameters:
        - name: user_id
          in: path
          type: integer
          required: true
    - name: admin-users-user_id-quotas-quota_target
      path: /admin/users/{user_id}/quotas/{quota_target}
      operations:
      - name: updateuserquota
        method: PUT
        description: Grafana Update User Quota
        outputRawFormat: json
        outputParameters:
        - name: result
          type: object
          value: $.
        inputParameters:
        - name: quota_target
          in: path
          type: string
          required: true
        - name: user_id
          in: path
          type: integer
          required: true
        - name: body
          in: body
          type: object
          description: Request body (JSON).
          required: true
    - name: admin-users-user_id-revoke-auth-token
      path: /admin/users/{user_id}/revoke-auth-token
      operations:
      - name: adminrevokeuserauthtoken
        method: POST
        description: Grafana Admin Revoke User Auth Token
        outputRawFormat: json
        outputParameters:
        - name: result
          type: object
          value: $.
        inputParameters:
        - name: user_id
          in: path
          type: integer
          required: true
        - name: body
          in: body
          type: object
          description: Request body (JSON).
          required: true
    - name: org-users
      path: /org/users
      operations:
      - name: getorgusersforcurrentorg
        method: GET
        description: Grafana Get Org Users For Current Org
        outputRawFormat: json
        outputParameters:
        - name: result
          type: object
          value: $.
        inputParameters:
        - name: query
          in: query
          type: string
        - name: limit
          in: query
          type: integer
      - name: addorgusertocurrentorg
        method: POST
        description: Grafana Add Org User To Current Org
        outputRawFormat: json
        outputParameters:
        - name: result
          type: object
          value: $.
        inputParameters:
        - name: body
          in: body
          type: object
          description: Request body (JSON).
          required: true
    - name: org-users-lookup
      path: /org/users/lookup
      operations:
      - name: getorgusersforcurrentorglookup
        method: GET
        description: Grafana Get Org Users For Current Org Lookup
        outputRawFormat: json
        outputParameters:
        - name: result
          type: object
          value: $.
        inputParameters:
        - name: query
          in: query
          type: string
        - name: limit
          in: query
          type: integer
    - name: org-users-user_id
      path: /org/users/{user_id}
      operations:
      - name: removeorguserforcurrentorg
        method: DELETE
        description: Grafana Remove Org User For Current Org
        outputRawFormat: json
        outputParameters:
        - name: result
          type: object
          value: $.
        inputParameters:
        - name: user_id
          in: path
          type: integer
          required: true
      - name: updateorguserforcurrentorg
        method: PATCH
        description: Grafana Update Org User For Current Org
        outputRawFormat: json
        outputParameters:
        - name: result
          type: object
          value: $.
        inputParameters:
        - name: user_id
          in: path
          type: integer
          required: true
        - name: body
          in: body
          type: object
          description: Request body (JSON).
          required: true
    - name: orgs-org_id-users
      path: /orgs/{org_id}/users
      operations:
      - name: getorgusers
        method: GET
        description: Grafana Get Org Users
        outputRawFormat: json
        outputParameters:
        - name: result
          type: object
          value: $.
        inputParameters:
        - name: org_id
          in: path
          type: integer
          required: true
      - name: addorguser
        method: POST
        description: Grafana Add Org User
        outputRawFormat: json
        outputParameters:
        - name: result
          type: object
          value: $.
        inputParameters:
        - name: org_id
          in: path
          type: integer
          required: true
        - name: body
          in: body
          type: object
          description: Request body (JSON).
          required: true
    - name: orgs-org_id-users-search
      path: /orgs/{org_id}/users/search
      operations:
      - name: searchorgusers
        method: GET
        description: Grafana Search Org Users
        outputRawFormat: json
        outputParameters:
        - name: result
          type: object
          value: $.
        inputParameters:
        - name: org_id
          in: path
          type: integer
          required: true
    - name: orgs-org_id-users-user_id
      path: /orgs/{org_id}/users/{user_id}
      operations:
      - name: removeorguser
        method: DELETE
        description: Grafana Remove Org User
        outputRawFormat: json
        outputParameters:
        - name: result
          type: object
          value: $.
        inputParameters:
        - name: org_id
          in: path
          type: integer
          required: true
        - name: user_id
          in: path
          type: integer
          required: true
      - name: updateorguser
        method: PATCH
        description: Grafana Update Org User
        outputRawFormat: json
        outputParameters:
        - name: result
          type: object
          value: $.
        inputParameters:
        - name: org_id
          in: path
          type: integer
          required: true
        - name: user_id
          in: path
          type: integer
          required: true
        - name: body
          in: body
          type: object
          description: Request body (JSON).
          required: true
    - name: user
      path: /user
      operations:
      - name: getsignedinuser
        method: GET
        description: Grafana Get Signed In User
        outputRawFormat: json
        outputParameters:
        - name: result
          type: object
          value: $.
      - name: updatesignedinuser
        method: PUT
        description: Grafana Update Signed In User
        outputRawFormat: json
        outputParameters:
        - name: result
          type: object
          value: $.
        inputParameters:
        - name: body
          in: body
          type: object
          description: Request body (JSON).
          required: true
    - name: user-auth-tokens
      path: /user/auth-tokens
      operations:
      - name: getuserauthtokens
        method: GET
        description: Grafana Get User Auth Tokens
        outputRawFormat: json
        outputParameters:
        - name: result
          type: object
          value: $.
    - name: user-email-update
      path: /user/email/update
      operations:
      - name: updateuseremail
        method: GET
        description: Grafana Update User Email
        outputRawFormat: json
        outputParameters:
        - name: result
          type: object
          value: $.
    - name: user-orgs
      path: /user/orgs
      operations:
      - name: getsignedinuserorglist
        method: GET
        description: Grafana Get Signed In User Org List
        outputRawFormat: json
        outputParameters:
        - name: result
          type: object
          value: $.
    - name: user-password
      path: /user/password
      operations:
      - name: changeuserpassword
        method: PUT
        description: Grafana Change User Password
        outputRawFormat: json
        outputParameters:
        - name: result
          type: object
          value: $.
        inputParameters:
        - name: body
          in: body
          type: object
          description: Request body (JSON).
          required: true
    - name: user-preferences
      path: /user/preferences
      operations:
      - name: getuserpreferences
        method: GET
        description: Grafana Get User Preferences
        outputRawFormat: json
        outputParameters:
        - name: result
          type: object
          value: $.
      - name: updateuserpreferences
        method: PUT
        description: Grafana Update User Preferences
        outputRawFormat: json
        outputParameters:
        - name: result
          type: object
          value: $.
        inputParameters:
        - name: body
          in: body
          type: object
          description: Request body (JSON).
          required: true
      - name: patchuserpreferences
        method: PATCH
        description: Grafana Patch User Preferences
        outputRawFormat: json
        outputParameters:
        - name: result
          type: object
          value: $.
        inputParameters:
        - name: body
          in: body
          type: object
          description: Request body (JSON).
          required: true
    - name: user-quotas
      path: /user/quotas
      operations:
      - name: getuserquotas
        method: GET
        description: Grafana Get User Quotas
        outputRawFormat: json
        outputParameters:
        - name: result
          type: object
          value: $.
    - name: user-revoke-auth-token
      path: /user/revoke-auth-token
      operations:
      - name: revokeuserauthtoken
        method: POST
        description: Grafana Revoke User Auth Token
        outputRawFormat: json
        outputParameters:
        - name: result
          type: object
          value: $.
        inputParameters:
        - name: body
          in: body
          type: object
          description: Request body (JSON).
          required: true
    - name: user-teams
      path: /user/teams
      operations:
      - name: getsignedinuserteamlist
        method: GET
        description: Grafana Get Signed In User Team List
        outputRawFormat: json
        outputParameters:
        - name: result
          type: object
          value: $.
    - name: user-using-org_id
      path: /user/using/{org_id}
      operations:
      - name: usersetusingorg
        method: POST
        description: Grafana User Set Using Org
        outputRawFormat: json
        outputParameters:
        - name: result
          type: object
          value: $.
        inputParameters:
        - name: org_id
          in: path
          type: integer
          required: true
    - name: users
      path: /users
      operations:
      - name: searchusers
        method: GET
        description: Grafana Search Users
        outputRawFormat: json
        outputParameters:
        - name: result
          type: object
          value: $.
        inputParameters:
        - name: perpage
          in: query
          type: integer
          description: Limit the maximum number of users to return per page
        - name: page
          in: query
          type: integer
          description: Page index for starting fetching users
    - name: users-lookup
      path: /users/lookup
      operations:
      - name: getuserbyloginoremail
        method: GET
        description: Grafana Get User By Login Or Email
        outputRawFormat: json
        outputParameters:
        - name: result
          type: object
          value: $.
        inputParameters:
        - name: loginOrEmail
          in: query
          type: string
          description: loginOrEmail of the user
          required: true
    - name: users-search
      path: /users/search
      operations:
      - name: searchuserswithpaging
        method: GET
        description: Grafana Search Users With Paging
        outputRawFormat: json
        outputParameters:
        - name: result
          type: object
          value: $.
    - name: users-user_id
      path: /users/{user_id}
      operations:
      - name: getuserbyid
        method: GET
        description: Grafana Get User By ID
        outputRawFormat: json
        outputParameters:
        - name: result
          type: object
          value: $.
        inputParameters:
        - name: user_id
          in: path
          type: integer
          required: true
      - name: updateuser
        method: PUT
        description: Grafana Update User
        outputRawFormat: json
        outputParameters:
        - name: result
          type: object
          value: $.
        inputParameters:
        - name: user_id
          in: path
          type: integer
          required: true
        - name: body
          in: body
          type: object
          description: Request body (JSON).
          required: true
    - name: users-user_id-orgs
      path: /users/{user_id}/orgs
      operations:
      - name: getuserorglist
        method: GET
        description: Grafana Get User Org List
        outputRawFormat: json
        outputParameters:
        - name: result
          type: object
          value: $.
        inputParameters:
        - name: user_id
          in: path
          type: integer
          required: true
    - name: users-user_id-teams
      path: /users/{user_id}/teams
      operations:
      - name: getuserteams
        method: GET
        description: Grafana Get User Teams
        outputRawFormat: json
        outputParameters:
        - name: result
          type: object
          value: $.
        inputParameters:
        - name: user_id
          in: path
          type: integer
          required: true
    authentication:
      type: apikey
      key: Authorization
      value: '{{env.GRAFANA_API_KEY}}'
      placement: header
  exposes:
  - type: rest
    namespace: grafana-users-2-rest
    port: 8080
    description: REST adapter for Grafana — Users. One Spectral-compliant resource per consumed operation, prefixed with /v1.
    resources:
    - path: /v1/access-control/users/roles/search
      name: access-control-users-roles-search
      description: REST surface for access-control-users-roles-search.
      operations:
      - method: POST
        name: listusersroles
        description: Grafana List Users Roles
        call: grafana-users-2.listusersroles
        with:
          body: rest.body
        outputParameters:
        - type: object
          mapping: $.
    - path: /v1/access-control/users/{userid}/roles
      name: access-control-users-userid-roles
      description: REST surface for access-control-users-userId-roles.
      operations:
      - method: GET
        name: listuserroles
        description: Grafana List User Roles
        call: grafana-users-2.listuserroles
        with:
          userId: rest.userId
        outputParameters:
        - type: object
          mapping: $.
      - method: PUT
        name: setuserroles
        description: Grafana Set User Roles
        call: grafana-users-2.setuserroles
        with:
          userId: rest.userId
          body: rest.body
        outputParameters:
        - type: object
          mapping: $.
      - method: POST
        name: adduserrole
        description: Grafana Add User Role
        call: grafana-users-2.adduserrole
        with:
          userId: rest.userId
          body: rest.body
        outputParameters:
        - type: object
          mapping: $.
    - path: /v1/access-control/users/{userid}/roles/{roleuid}
      name: access-control-users-userid-roles-roleuid
      description: REST surface for access-control-users-userId-roles-roleUID.
      operations:
      - method: DELETE
        name: removeuserrole
        description: Grafana Remove User Role
        call: grafana-users-2.removeuserrole
        with:
          global: rest.global
          roleUID: rest.roleUID
          userId: rest.userId
        outputParameters:
        - type: object
          mapping: $.
    - path: /v1/access-control/{resource}/{resourceid}/users/{userid}
      name: access-control-resource-resourceid-users-userid
      description: REST surface for access-control-resource-resourceID-users-userID.
      operations:
      - method: POST
        name: setresourcepermissionsforuser
        description: Grafana Set Resource Permissions For User
        call: grafana-users-2.setresourcepermissionsforuser
        with:
          resource: rest.resource
          resourceID: rest.resourceID
          userID: rest.userID
          body: rest.body
        outputParameters:
        - type: object
          mapping: $.
    - path: /v1/admin/ldap/sync/{user-id}
      name: admin-ldap-sync-user-id
      description: REST surface for admin-ldap-sync-user_id.
      operations:
      - method: POST
        name: postsyncuserwithldap
        description: Grafana Post Sync User With LDAP
        call: grafana-users-2.postsyncuserwithldap
        with:
          user_id: rest.user_id
        outputParameters:
        - type: object
          mapping: $.
    - path: /v1/admin/ldap/{user-name}
      name: admin-ldap-user-name
      description: REST surface for admin-ldap-user_name.
      operations:
      - method: GET
        name: getuserfromldap
        description: Grafana Get User From LDAP
        call: grafana-users-2.getuserfromldap
        with:
          user_name: rest.user_name
        outputParameters:
        - type: object
          mapping: $.
    - path: /v1/admin/users
      name: admin-users
      description: REST surface for admin-users.
      operations:
      - method: POST
        name: admincreateuser
        description: Grafana Admin Create User
        call: grafana-users-2.admincreateuser
        with:
          body: rest.body
        outputParameters:
        - type: object
          mapping: $.
    - path: /v1/admin/users/{user-id}
      name: admin-users-user-id
      description: REST surface for admin-users-user_id.
      operations:
      - method: DELETE
        name: admindeleteuser
        description: Grafana Admin Delete User
        call: grafana-users-2.admindeleteuser
        with:
          user_id: rest.user_id
        outputParameters:
        - type: object
          mapping: $.
    - path: /v1/admin/users/{user-id}/auth-tokens
      name: admin-users-user-id-auth-tokens
      description: REST surface for admin-users-user_id-auth-tokens.
      operations:
      - method: GET
        name: admingetuserauthtokens
        description: Grafana Admin Get User Auth Tokens
        call: grafana-users-2.admingetuserauthtokens
        with:
          user_id: rest.user_id
        outputParameters:
        - type: object
          mapping: $.
    - path: /v1/admin/users/{user-id}/disable
      name: admin-users-user-id-disable
      description: REST surface for admin-users-user_id-disable.
      operations:
      - method: POST
        name: admindisableuser
        description: Grafana Admin Disable User
        call: grafana-users-2.admindisableuser
        with:
          user_id: rest.user_id
        outputParameters:
        - type: object
          mapping: $.
    - path: /v1/admin/users/{user-id}/enable
      name: admin-users-user-id-enable
      description: REST surface for admin-users-user_id-enable.
      operations:
      - method: POST
        name: adminenableuser
        description: Grafana Admin Enable User
        call: grafana-users-2.adminenableuser
        with:
          user_id: rest.user_id
        outputParameters:
        - type: object
          mapping: $.
    - path: /v1/admin/users/{user-id}/logout
      name: admin-users-user-id-logout
      description: REST surface for admin-users-user_id-logout.
      operations:
      - method: POST
        name: adminlogoutuser
        description: Grafana Admin Logout User
        call: grafana-users-2.adminlogoutuser
        with:
          user_id: rest.user_id
        outputParameters:
        - type: object
          mapping: $.
    - path: /v1/admin/users/{user-id}/password
      name: admin-users-user-id-password
      description: REST surface for admin-users-user_id-password.
      operations:
      - method: PUT
        name: adminupdateuserpassword
        description: Grafana Admin Update User Password
        call: grafana-users-2.adminupdateuserpassword
        with:
          user_id: rest.user_id
          body: rest.body
        outputParameters:
        - type: object
          mapping: $.
    - path: /v1/admin/users/{user-id}/permissions
      name: admin-users-user-id-permissions
      description: REST surface for admin-users-user_id-permissions.
      operations:
      - method: PUT
        name: adminupdateuserpermissions
        description: Grafana Admin Update User Permissions
        call: grafana-users-2.adminupdateuserpermissions
        with:
          user_id: rest.user_id
          body: rest.body
        outputParameters:
        - type: object
          mapping: $.
    - path: /v1/admin/users/{user-id}/quotas
      name: admin-users-user-id-quotas
      description: REST surface for admin-users-user_id-quotas.
      operations:
      - method: GET
        name: getuserquota
        description: Grafana Get User Quota
        call: grafana-users-2.getuserquota
        with:
          user_id: rest.user_id
        outputParameters:
        - type: object
          mapping: $.
    - path: /v1/admin/users/{user-id}/quotas/{quota-target}
      name: admin-users-user-id-quotas-quota-target
      description: REST surface for admin-users-user_id-quotas-quota_target.
      operations:
      - method: PUT
        name: updateuserquota
        description: Grafana Update User Quota
        call: grafana-users-2.updateuserquota
        with:
          quota_target: rest.quota_target
          user_id: rest.user_id
          body: rest.body
        outputParameters:
        - type: object
          mapping: $.
    - path: /v1/admin/users/{user-id}/revoke-auth-token
      name: admin-users-user-id-revoke-auth-token
      description: REST surface for admin-users-user_id-revoke-auth-token.
      operations:
      - method: POST
        name: adminrevokeuserauthtoken
        description: Grafana Admin Revoke User Auth Token
        call: grafana-users-2.adminrevokeuserauthtoken
        with:
          user_id: rest.user_id
          body: rest.body
        outputParameters:
        - type: object
          mapping: $.
    - path: /v1/org/users
      name: org-users
      description: REST surface for org-users.
      operations:
      - method: GET
        name: getorgusersforcurrentorg
        description: Grafana Get Org Users For Current Org
        call: grafana-users-2.getorgusersforcurrentorg
        with:
          query: rest.query
          limit: rest.limit
        outputParameters:
        - type: object
          mapping: $.
      - method: POST
        name: addorgusertocurrentorg
        description: Grafana Add Org User To Current Org
        call: grafana-users-2.addorgusertocurrentorg
        with:
          body: rest.body
        outputParameters:
        - type: object
          mapping: $.
    - path: /v1/org/users/lookup
      name: org-users-lookup
      description: REST surface for org-users-lookup.
      operations:
      - method: GET
        name: getorgusersforcurrentorglookup
        description: Grafana Get Org Users For Current Org Lookup
        call: grafana-users-2.getorgusersforcurrentorglookup
        with:
          query: rest.query
          limit: rest.limit
        outputParameters:
        - type: object
          mapping: $.
    - path: /v1/org/users/{user-id}
      name: org-users-user-id
 

# --- truncated at 32 KB (57 KB total) ---
# Full source: https://raw.githubusercontent.com/api-evangelist/grafana/refs/heads/main/capabilities/grafana-users-2.yaml