post_orgs_by_id_approve
Calls POST /api/orgs/{id}/approve as the signed-in person · REST reference
Approve an organization
Platform staff only (there is no dedicated org-approve command permission). Sets status to 'APPROVED' and saves. There is no per-organization check, so a platform operator can approve an org they do not belong to. 'APPROVED' is a ROUTE-LAYER status: the DAL's OrgStatus enum is ACTIVE | INACTIVE | SUSPENDED, so an approved org is not counted by activeCount on /api/orgs/summary and is not returned by GET /api/orgs?status=ACTIVE. The request body is read by nothing — send it empty.
Arguments
| Argument | Type | Description | |
|---|---|---|---|
idpath | string (uuid) | required |
Example call
A client sends this over the MCP session; Claude and other agents build it for you. The values are placeholders — the shape is real.
{
"jsonrpc": "2.0",
"id": 1,
"method": "tools/call",
"params": {
"name": "post_orgs_by_id_approve",
"arguments": {
"id": "11111111-1111-4111-8111-111111111111"
}
}
}Result
On success (HTTP 200) the tool returns one text item holding the API's JSON, pretty-printed.
The organization after the status change, as the DAL answered the write — epoch millisecond timestamps, createdAt included, as on PATCH /api/orgs/{id}.
{
"id": "11111111-1111-4111-8111-111111111111",
"name": "string",
"status": "APPROVED",
"createdAt": 1
}Fields
| Field | Type | Description |
|---|---|---|
createdAt | integer | Epoch milliseconds, straight off the DAL entity. |
id | string (uuid) | |
name | string | |
status | "APPROVED" |
When it fails
A failed call returns isError: true with the API's message as text. A change the person declines, or lets time out, also comes back this way and nothing changes.
403Authenticated, but the caller holds none of the required permissions.
404No such resource — or none this caller may see.
What the model is shown
This is the tool exactly as the server lists it in tools/list. The description starts with the REST call it makes.
{
"name": "post_orgs_by_id_approve",
"description": "POST /api/orgs/{id}/approve — Platform staff only (there is no dedicated org-approve command permission). Sets `status` to 'APPROVED' and saves. There is no per-organization check, so a platform operator can approve an org they do not belong to. 'APPROVED' is a ROUTE-LAYER status: the DAL's `OrgStatus` enum is ACTIVE | INACTIVE | SUSPENDED, so an approved org is not counted by `activeCount` on `/api/orgs/summary` and is not returned by `GET /api/orgs?status=ACTIVE`. The request body is read by nothing — send it empty.\n\nThis changes data. The person is asked to confirm it before it runs, and nothing happens if they decline.",
"inputSchema": {
"type": "object",
"properties": {
"id": {
"type": "string"
}
},
"required": [
"id"
]
},
"annotations": {
"readOnlyHint": false,
"destructiveHint": true,
"idempotentHint": false,
"openWorldHint": false
}
}