Set the organization's notification layer
Code Mode: praxis.organization.notifications.organizationDefault.create
HTTP: POST /organization/v1/notifications/organization_default
Change the organization’s notification layer. Requires an organization owner or admin role; a member answers 403. Refused with INVALID_PARAMS for an unknown or non-configurable category, a channel the category does not declare, or a hidden critical category. Blocking a channel silences it for every member, and a critical category’s mandatory channel still reaches people (ADR-193 §4 layer 1); setting member_may_change false makes these defaults final for members.
Signature
praxis.organization.notifications.organizationDefault.create(args:{body:{/** Category key → channel → on/off, applied where a member said nothing. */ defaults?:{[key:string]:unknown};/** Channels nobody in this organization receives on. */ blocked_channels?:Array<"in_app"|"email"|"sms">;/** Non-critical categories kept off members' settings pages. */ hidden_categories?:Array<string>;/** false makes these defaults final for members; true (the default) lets each member change their own switches. */ member_may_change?:boolean}}):Promise<{[key:string]:unknown}>;Request body
| Required | Content types | Description |
|---|---|---|
| yes | application/json |
Responses
| Status | Content types | Description |
|---|---|---|
| 200 | application/json | The stored organization layer. |
| 400 | Invalid default, unknown category or hidden critical category (RFC 9457 problem, `INVALID_PARAMS`). | |
| 401 | Missing or invalid credential (RFC 9457 problem). | |
| 403 | The caller is not an owner or admin of this organization — `PERMISSION_DENIED` from the service (RFC 9457 problem). | |
| 502 | The notification service did not answer, or failed in a way it did not classify (RFC 9457 problem, `UNAVAILABLE`). A refusal the service classifies is never a 502 — it reaches the caller in its own class (400, 403, 404), so a client may act on it. |