v1

latestSwagger 2.02026-07-17290378721.8 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'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,
    "role": "Editor",
    "teams": [],
    "updatedAt": "2022-03-21T14:35:33Z"
  }
}