Skip to content
Connect an agent

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}/approvals

TL;DR

QuestionAnswer
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

FieldTypeRequiredDescription
orgstringyesThe organisation's id or its slug.

Query parameters

FieldTypeRequiredDescription
status"pending" | "decided"nopending (the default) for the queue, decided for the requests decided or ended in the last 30 days.

Responses

StatusMeaningBody
200The requests.ApprovalRequestList
401Not signed in.ErrorResponse
403The caller does not approve (orgs.forbidden).ErrorResponse
404No such organisation, or the caller is not a member of it.ErrorResponse
429Too many requests.ErrorResponse
503Organisations are not set up on this server.ErrorResponse

Response body

A 200 answer has the type ApprovalRequestList.

FieldTypeRequiredDescription
itemsApprovalRequest[]yes
items[].idstringyes
items[].kind"publish" | "change" | "share"yes
items[].status"pending" | "approved" | "rejected" | "expired"yes
items[].diagramobject | nullyesThe diagram as the library has it now, or null once it is gone (a rejected new diagram).
items[].diagram.idstringyes
items[].diagram.namestring | nullyes
items[].diagram.folderstring | nullyes
items[].diagram.classificationClassificationyesA 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[].requestedByobject | nullyesWho asked, or null for an organisation key and once the account is gone.
items[].requestedBy.userIdstringyes
items[].requestedBy.emailstringyes
items[].requestedAtintegeryes
items[].expiresAtintegeryes
items[].secretFindingsintegeryesHow many things that look like a secret the scan found when the request was made, under the organisation's scanning options. minimum 0.
items[].reviewedByobject | nullyes
items[].reviewedBy.userIdstringyes
items[].reviewedBy.emailstringyes
items[].reviewedAtinteger | nullyes
items[].commentstring | nullyesThe approver's comment, when they gave one.
totalintegeryesHow many requests wait, even when the list is shorter. minimum 0.

See also

DocWhy
API referenceEvery endpoint, and the error envelope
SchemasEvery request and response type
Tool referenceThe operations as callable tools