mirror of
https://github.com/grafana/grafana.git
synced 2025-07-28 03:42:12 +08:00
API: Add service account routes to the swagger (#52398)
* API: Add service account routes to the swagger
This commit is contained in:

committed by
GitHub

parent
a0f96ed4e1
commit
e6b9ded949
@ -115,7 +115,7 @@ Requires basic authentication and that the authenticated user is a Grafana Admin
|
||||
`PATCH /api/serviceaccounts/:id`
|
||||
|
||||
**Required permissions**
|
||||
|
||||
|
||||
See note in the [introduction]({{< ref "#service-account-api" >}}) for an explanation.
|
||||
|
||||
| Action | Scope |
|
||||
@ -140,9 +140,9 @@ Content-Type: application/json
|
||||
HTTP/1.1 200
|
||||
Content-Type: application/json
|
||||
|
||||
```
|
||||
|
||||
---
|
||||
```
|
||||
|
||||
---
|
||||
|
||||
## Service account tokens
|
||||
|
||||
@ -183,14 +183,14 @@ Content-Type: application/json
|
||||
|
||||
**Required permissions**
|
||||
|
||||
See note in the [introduction]({{< ref "#service-account-api" >}}) for an explanation.
|
||||
|
||||
| Action | Scope |
|
||||
See note in the [introduction]({{< ref "#service-account-api" >}}) for an explanation.
|
||||
|
||||
| Action | Scope |
|
||||
| --------------------- | -------------------- |
|
||||
| serviceaccounts:write | serviceaccounts:id:1 |
|
||||
|
||||
**Example Request**:
|
||||
|
||||
|
||||
```http
|
||||
POST /api/serviceaccounts/2/tokens HTTP/1.1
|
||||
Accept: application/json
|
||||
@ -235,9 +235,9 @@ Content-Type: application/json
|
||||
**Example Response**:
|
||||
|
||||
```http
|
||||
HTTP/1.1 200
|
||||
Content-Type: application/json
|
||||
|
||||
HTTP/1.1 200
|
||||
Content-Type: application/json
|
||||
|
||||
```
|
||||
**Example Request**:
|
||||
|
||||
@ -277,9 +277,9 @@ Content-Type: application/json
|
||||
|
||||
See note in the [introduction]({{< ref "#service-account-api" >}}) for an explanation.
|
||||
|
||||
| Action | Scope |
|
||||
| --------------------- | ------------------ |
|
||||
| serviceaccounts:write | serviceaccounts:\* |
|
||||
| Action | Scope |
|
||||
| --------------------- | -------------------- |
|
||||
| serviceaccounts:write | serviceaccounts:id:1 |
|
||||
|
||||
**Example Request**:
|
||||
|
||||
@ -318,9 +318,9 @@ Content-Type: application/json
|
||||
|
||||
See note in the [introduction]({{< ref "#service-account-api" >}}) for an explanation.
|
||||
|
||||
| Action | Scope |
|
||||
| --------------------- | ------------------ |
|
||||
| serviceaccounts:write | serviceaccounts:\* |
|
||||
| Action | Scope |
|
||||
| --------------------- | -------------------- |
|
||||
| serviceaccounts:write | serviceaccounts:id:1 |
|
||||
|
||||
**Example Request**:
|
||||
|
||||
|
Reference in New Issue
Block a user