KamoCRM

GET/PATCH the org's default legal text

FeatureDocsService
Shipped
14 ஆகஸ்ட், 2026 அன்று 7:35 PM UTC
Author
Kamo
Commit
c7e84df

/api/docs/legal/settings, behind the same guarded() funnel as every other mapping on this controller. The read NEVER creates a row: it resolves to LegalDefaults when the org has none. That keeps the package editor's seed fetch side-effect free and is what covers organizations created after the KamoInitializer seed ran — the row is materialized on the first save, where a write belongs. The right set is deliberately wider than the package endpoints'. This endpoint is reached from the Legal & Compliance settings tab (MANAGE_HRS_SETTINGS) and from the package editor (MANAGE_LEGAL_AND_COMPLIANCE); either right alone 403s a screen on a field it owns. Safe to widen because it is one org-level string of boilerplate — no roster, no assignment, no evidence — and a regression test pins that the widening does not reach list/create/audience-preview. PATCH semantics: an absent field is untouched, an empty string is a deliberate clear. Publish already refuses a blank attestation, so a cleared default only makes the author write their own.

All changes

Like what you see shipping?

All of it arrives in your workspace on its own. Start on the free plan and read this page again in a month.

Start Free ForeverView Pricing