# Set an organisation's classification settings

> Page: https://docs.plotwork.dev/api/put-orgs-org-classification. Index of every page: https://docs.plotwork.dev/llms.txt

Replaces the default label, the folders' defaults and, for the owner, "Share only diagrams labelled Public", which ends the links of shared diagrams not labelled public when it goes on.

`PUT /orgs/{org}/classification`

## TL;DR

| Question | Answer |
|---|---|
| What does it do? | Set an organisation's classification settings. |
| What does it take? | A JSON body of type [`SetOrganisationClassificationBody`](https://docs.plotwork.dev/api/schemas.md#setorganisationclassificationbody). |
| What does it return? | Status 200 with a body of type [`OrganisationClassificationChanged`](https://docs.plotwork.dev/api/schemas.md#organisationclassificationchanged). |
| What can go wrong? | `400` the body is not valid; `401` not signed in; `403` only the owner or an admin may change them, and only the owner "share only diagrams labelled public" (orgs.forbidden), or the request came from an origin that may not make changes; `404` no such organisation, or the caller is not a member of it; `422` a folder or a label cannot be used (validation.failed); `429` too many requests; `503` organisations are not set up on this server. Every failure uses the one error envelope. |

## What it does

Replaces the default label, the folders' defaults and, for the owner, "Share only diagrams labelled Public", which ends the links of shared diagrams not labelled public when it goes on. The owner or an admin.

## Path parameters

| Field | Type | Required | Description |
|---|---|---|---|
| `org` | `string` | yes | The organisation's id or its slug. |

## Request body

The body has the type [`SetOrganisationClassificationBody`](https://docs.plotwork.dev/api/schemas.md#setorganisationclassificationbody).

| Field | Type | Required | Description |
|---|---|---|---|
| `default` | `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. |
| `sharePublicOnly` | `boolean` | no | Only the owner may change it; left out, it stays as it is. |
| `folders` | `object[]` | yes | At most 50 folders, each a folder path. |
| `folders[].folder` | `string` | yes | at least 1 character; at most 300 characters. |
| `folders[].classification` | `string` | yes | at least 1 character; at most 20 characters. |

## Responses

| Status | Meaning | Body |
|---|---|---|
| 200 | The settings now, and how many public links ended. | [`OrganisationClassificationChanged`](https://docs.plotwork.dev/api/schemas.md#organisationclassificationchanged) |
| 400 | The body is not valid. | [`ErrorResponse`](https://docs.plotwork.dev/api/schemas.md#errorresponse) |
| 401 | Not signed in. | [`ErrorResponse`](https://docs.plotwork.dev/api/schemas.md#errorresponse) |
| 403 | Only the owner or an admin may change them, and only the owner "Share only diagrams labelled Public" (orgs.forbidden), or the request came from an origin that may not make changes. | [`ErrorResponse`](https://docs.plotwork.dev/api/schemas.md#errorresponse) |
| 404 | No such organisation, or the caller is not a member of it. | [`ErrorResponse`](https://docs.plotwork.dev/api/schemas.md#errorresponse) |
| 422 | A folder or a label cannot be used (validation.failed). | [`ErrorResponse`](https://docs.plotwork.dev/api/schemas.md#errorresponse) |
| 429 | Too many requests. | [`ErrorResponse`](https://docs.plotwork.dev/api/schemas.md#errorresponse) |
| 503 | Organisations are not set up on this server. | [`ErrorResponse`](https://docs.plotwork.dev/api/schemas.md#errorresponse) |

## Response body

A 200 answer has the type [`OrganisationClassificationChanged`](https://docs.plotwork.dev/api/schemas.md#organisationclassificationchanged).

| Field | Type | Required | Description |
|---|---|---|---|
| `default` | `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. |
| `sharePublicOnly` | `boolean` | yes | "Share only diagrams labelled Public": while true, only a diagram labelled public may have a public link. The owner's setting. |
| `folders` | `object[]` | yes | The folders with a default label of their own. A new diagram filed in one, or in a folder inside it, gets it; the deepest wins. |
| `folders[].folder` | `string` | yes | at least 1 character; at most 300 characters. |
| `folders[].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. |
| `linksEnded` | `integer` | yes | How many public links ended because "Share only diagrams labelled Public" was turned on and their diagram is not labelled public. minimum 0. |

## See also

| Doc | Why |
|---|---|
| [API reference](https://docs.plotwork.dev/api/reference.md) | Every endpoint, and the error envelope |
| [Schemas](https://docs.plotwork.dev/api/schemas.md) | Every request and response type |
| [Tool reference](https://docs.plotwork.dev/mcp/tools.md) | The operations as callable tools |
