v1

latestOpenAPI 3.0.32026-07-14314472448.6 KB
service_accounts

Update service account

Required permissions (See note in the introduction for an explanation): action: serviceaccounts:write scope: serviceaccounts:id:1 (single service account)

patch/serviceaccounts/{serviceAccountId}

Path parameters

serviceAccountIdinteger required

Request body

isDisabledboolean
namestring
role'None' | 'Viewer' | 'Editor' | 'Admin'
serviceAccountIdinteger

Response

(empty)

idinteger
messagestring
namestring

Example response

{
  "serviceaccount": {
    "avatarUrl": "/avatar/8ea890a677d6a223c591a1beea6ea9d2",
    "createdAt": "2022-03-21T14:35:33Z",
    "id": 2,
    "login": "sa-grafana",
    "name": "test",
    "orgId": 1,
    "requiredBy": "grafana-app",
    "role": "Editor",
    "teams": [],
    "uid": "fe1xejlha91xce",
    "updatedAt": "2022-03-21T14:35:33Z"
  }
}