Organisations
List the requests waiting for approval
The Approvals queue, newest first, with the diagram, who asked, its label and the secret scan; or the requests decided in the last 30 days.
GET
/orgs/{org}/approvalsTL;DR
| Question | Answer |
|---|---|
| What does it do? | List the requests waiting for approval. |
| What does it take? | org in the path, and status in the query string. |
| What does it return? | Status 200 with a body of type ApprovalRequestList. |
| What can go wrong? | 401 not signed in; 403 the caller does not approve (orgs.forbidden); 404 no such organisation, or the caller is not a member of it; 429 too many requests; 503 organisations are not set up on this server. Every failure uses the one error envelope. |
What it does
The Approvals queue, newest first, with the diagram, who asked, its label and the secret scan; or the requests decided in the last 30 days. Approvers only.
Path parameters
| Field | Type | Required | Description |
|---|---|---|---|
org | string | yes | The organisation's id or its slug. |
Query parameters
| Field | Type | Required | Description |
|---|---|---|---|
status | "pending" | "decided" | no | pending (the default) for the queue, decided for the requests decided or ended in the last 30 days. |
Responses
| Status | Meaning | Body |
|---|---|---|
| 200 | The requests. | ApprovalRequestList |
| 401 | Not signed in. | ErrorResponse |
| 403 | The caller does not approve (orgs.forbidden). | ErrorResponse |
| 404 | No such organisation, or the caller is not a member of it. | ErrorResponse |
| 429 | Too many requests. | ErrorResponse |
| 503 | Organisations are not set up on this server. | ErrorResponse |
Response body
A 200 answer has the type ApprovalRequestList.
| Field | Type | Required | Description |
|---|---|---|---|
items | ApprovalRequest[] | yes | |
items[].id | string | yes | |
items[].kind | "publish" | "change" | "share" | yes | |
items[].status | "pending" | "approved" | "rejected" | "expired" | yes | |
items[].diagram | object | null | yes | The diagram as the library has it now, or null once it is gone (a rejected new diagram). |
items[].diagram.id | string | yes | |
items[].diagram.name | string | null | yes | |
items[].diagram.folder | string | null | yes | |
items[].diagram.classification | Classification | yes | A diagram's classification label: public, internal (the default, and what a diagram published before labels reads as) or confidential. Confidential is never shared publicly; under "Share only diagrams labelled Public" only public is. |
items[].diagram.theme | "light" | "dark" | "auto" | yes | |
items[].requestedBy | object | null | yes | Who asked, or null for an organisation key and once the account is gone. |
items[].requestedBy.userId | string | yes | |
items[].requestedBy.email | string | yes | |
items[].requestedAt | integer | yes | |
items[].expiresAt | integer | yes | |
items[].secretFindings | integer | yes | How many things that look like a secret the scan found when the request was made, under the organisation's scanning options. minimum 0. |
items[].reviewedBy | object | null | yes | |
items[].reviewedBy.userId | string | yes | |
items[].reviewedBy.email | string | yes | |
items[].reviewedAt | integer | null | yes | |
items[].comment | string | null | yes | The approver's comment, when they gave one. |
total | integer | yes | How many requests wait, even when the list is shorter. minimum 0. |
See also
| Doc | Why |
|---|---|
| API reference | Every endpoint, and the error envelope |
| Schemas | Every request and response type |
| Tool reference | The operations as callable tools |