[{"data":1,"prerenderedAt":-1},["ShallowReactive",2],{"skill:01M7BVM81FWB5PETMPFRRB0MBK":3,"skill-same:01M7BVM81FWB5PETMPFRRB0MBK":44},{"skillNo":4,"name":5,"nameZh":6,"description":7,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":16,"categories":17,"keywords":18,"publishedAt":19,"linkOnly":20,"markdownContent":21,"markdownBody":22,"frontMatter":23,"refName":24,"commitSha":25,"skillDirectory":26,"forksCount":14,"repositoryHtmlUrl":27,"repositoryHomepageUrl":6,"ownerHtmlUrl":28,"ownerBlogUrl":6,"ownerDescription":6,"updatedAt":29,"install":30,"resources":43},"01M7BVM81FWB5PETMPFRRB0MBK","principle-enforce-where-it-is-stored",null,"Apply when more than one client (a web app, an API caller, an agent or MCP tool, an import job) can write the same data, or when a client fills in or corrects a field before sending it. The system that stores the data enforces its rules for every writer; a client that covers for a missing server rule hides the gap.","quotegoat-ux\u002Fbleat","quotegoat-ux","https:\u002F\u002Favatars.githubusercontent.com\u002Fu\u002F279744457?v=4","01M7BVHCY3V27VFM64ZVC9RRKG","Justin Alvarado","01M7BVHCYQ0A0KV5BE406H99D7",0,"MIT","https:\u002F\u002Fgithub.com\u002Fquotegoat-ux\u002Fbleat\u002Fblob\u002Fmain\u002Fplugins\u002Fbleat\u002Fskills\u002Fprinciple-enforce-where-it-is-stored\u002FSKILL.md",[],[],"2026-11-15 14:19:17",false,"---\nname: principle-enforce-where-it-is-stored\ndescription: \"Apply when more than one client (a web app, an API caller, an agent or MCP tool, an import job) can write the same data, or when a client fills in or corrects a field before sending it. The system that stores the data enforces its rules for every writer; a client that covers for a missing server rule hides the gap.\"\nuser-invocable: false\n---\n\n# Enforce Where It Is Stored\n\nThe rule for what a record may hold lives where the record is stored: the API that writes it, and the database constraint beneath it. Every writer passes through that rule. The web app, an agent's tool, a script, and an import job are all just clients.\n\n**Why:** when each client carries its own copy of the rule, the copies drift, and the next client to arrive (an agent, an integration, another environment) writes rows the others never would. A client that pads a field (\"send `0` so the server doesn't break\") makes the missing server rule invisible until a client that does not pad it shows up.\n\n**The pattern:**\n- **Validate every write body on the server**, against the same schema whichever client sent it. Reject what breaks a rule; do not store it and hope a reader copes.\n- **Back the invariants that matter with database constraints**, so a path that skips the API still cannot store a broken row.\n- **Treat client-side checks as feedback, not enforcement.** Instant feedback in the browser can share the server's code, but the server decides.\n- **When a client works around a server gap, fix the server**, then delete the workaround.\n- **The server makes identity and entitlement.** A row's id, its owner (user id, `sub`, organization), a billing or payment-provider id, a storage key, and what the customer paid for come from the server or from the provider's own record, never from a request body. Refuse a body that names one. A client that may choose an id may choose another row's id.\n\n**The tests:**\n- \"If a new client sent the minimal body the API accepts, would the stored row still be valid?\"\n- \"Is this client changing data to suit the server? If so, the rule belongs on the server.\"\n- Send each create once with every required field left out in turn. Each answer is a 400 that names the field, never a 500 from a database constraint.\n\nBuilds on [Boundary Discipline](..\u002Fprinciple-boundary-discipline\u002FSKILL.md): this names which boundary owns a rule when several clients share one store.\n","# Enforce Where It Is Stored\n\nThe rule for what a record may hold lives where the record is stored: the API that writes it, and the database constraint beneath it. Every writer passes through that rule. The web app, an agent's tool, a script, and an import job are all just clients.\n\n**Why:** when each client carries its own copy of the rule, the copies drift, and the next client to arrive (an agent, an integration, another environment) writes rows the others never would. A client that pads a field (\"send `0` so the server doesn't break\") makes the missing server rule invisible until a client that does not pad it shows up.\n\n**The pattern:**\n- **Validate every write body on the server**, against the same schema whichever client sent it. Reject what breaks a rule; do not store it and hope a reader copes.\n- **Back the invariants that matter with database constraints**, so a path that skips the API still cannot store a broken row.\n- **Treat client-side checks as feedback, not enforcement.** Instant feedback in the browser can share the server's code, but the server decides.\n- **When a client works around a server gap, fix the server**, then delete the workaround.\n- **The server makes identity and entitlement.** A row's id, its owner (user id, `sub`, organization), a billing or payment-provider id, a storage key, and what the customer paid for come from the server or from the provider's own record, never from a request body. Refuse a body that names one. A client that may choose an id may choose another row's id.\n\n**The tests:**\n- \"If a new client sent the minimal body the API accepts, would the stored row still be valid?\"\n- \"Is this client changing data to suit the server? If so, the rule belongs on the server.\"\n- Send each create once with every required field left out in turn. Each answer is a 400 that names the field, never a 500 from a database constraint.\n\nBuilds on [Boundary Discipline](..\u002Fprinciple-boundary-discipline\u002FSKILL.md): this names which boundary owns a rule when several clients share one store.\n",{"name":5,"description":7,"user-invocable":20},"main","f499b102d6b17c905e2c9e27992b2670bf2a2ee0","plugins\u002Fbleat\u002Fskills\u002Fprinciple-enforce-where-it-is-stored","https:\u002F\u002Fgithub.com\u002Fquotegoat-ux\u002Fbleat","https:\u002F\u002Fgithub.com\u002Fquotegoat-ux","2026-11-11 05:16:43",{"source":8,"skillName":5,"commands":31,"prompt":41,"zipAvailable":42},[32,35,38],{"tool":33,"command":34},"npx","npx skills add quotegoat-ux\u002Fbleat --skill principle-enforce-where-it-is-stored",{"tool":36,"command":37},"bunx","bunx skills add quotegoat-ux\u002Fbleat --skill principle-enforce-where-it-is-stored",{"tool":39,"command":40},"pnpm","pnpm dlx skills add quotegoat-ux\u002Fbleat --skill principle-enforce-where-it-is-stored","安装技能，技能地址：https:\u002F\u002Fgithub.com\u002Fquotegoat-ux\u002Fbleat\u002Fblob\u002Fmain\u002Fplugins\u002Fbleat\u002Fskills\u002Fprinciple-enforce-where-it-is-stored\u002FSKILL.md",true,[],[45,52,59,66,73,80],{"skillNo":46,"name":47,"nameZh":6,"description":48,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":49,"categories":50,"keywords":51,"publishedAt":19},"01M7BVQ7YDABHNMZJXDTPEASX5","why","Use for 'why does X work this way', 'why we picked Y', design rationale, regressions, postmortems, or data-backed thresholds. Discovers available MCPs and queries each evidence category (source control, issue tracker, long-form docs, real-time chat, infrastructure observability, error tracking, product analytics warehouse) in parallel, then returns a cited read on decisions and tradeoffs. Use how for runtime behavior.","https:\u002F\u002Fgithub.com\u002Fquotegoat-ux\u002Fbleat\u002Fblob\u002Fmain\u002Fplugins\u002Fbleat\u002Fskills\u002Fwhy\u002FSKILL.md",[],[],{"skillNo":53,"name":54,"nameZh":6,"description":55,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":56,"categories":57,"keywords":58,"publishedAt":19},"01M7BVQ652PNKM7P3GJNNGAGZT","what-did-i-get-done","Summarize authored commits over a user-specified time period into a concise update","https:\u002F\u002Fgithub.com\u002Fquotegoat-ux\u002Fbleat\u002Fblob\u002Fmain\u002Fplugins\u002Fbleat\u002Fskills\u002Fwhat-did-i-get-done\u002FSKILL.md",[],[],{"skillNo":60,"name":61,"nameZh":6,"description":62,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":63,"categories":64,"keywords":65,"publishedAt":19},"01M7BVQ4T0C5BVKRFD8KFKQMEY","unslop","Cut AI tells from any writing.","https:\u002F\u002Fgithub.com\u002Fquotegoat-ux\u002Fbleat\u002Fblob\u002Fmain\u002Fplugins\u002Fbleat\u002Fskills\u002Funslop\u002FSKILL.md",[],[],{"skillNo":67,"name":68,"nameZh":6,"description":69,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":70,"categories":71,"keywords":72,"publishedAt":19},"01M7BVQ324D14NMF7K9H9WAVXF","typescript-best-practices","TypeScript best practices. Use when reading or editing any .ts or .tsx file.","https:\u002F\u002Fgithub.com\u002Fquotegoat-ux\u002Fbleat\u002Fblob\u002Fmain\u002Fplugins\u002Fbleat\u002Fskills\u002Ftypescript-best-practices\u002FSKILL.md",[],[],{"skillNo":74,"name":75,"nameZh":6,"description":76,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":77,"categories":78,"keywords":79,"publishedAt":19},"01M7BVQ0041D0YMD9DBCRAW18C","thermo-nuclear-code-quality-review","Run an extremely strict maintainability review for abstraction quality, giant files, and spaghetti-condition growth. Use for a thermo-nuclear code quality review, thermonuclear review, deep code quality audit, or especially harsh maintainability review.","https:\u002F\u002Fgithub.com\u002Fquotegoat-ux\u002Fbleat\u002Fblob\u002Fmain\u002Fplugins\u002Fbleat\u002Fskills\u002Fthermo-nuclear-code-quality-review\u002FSKILL.md",[],[],{"skillNo":81,"name":82,"nameZh":6,"description":83,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":84,"categories":85,"keywords":86,"publishedAt":19},"01M7BVPWB83H4QB9DDBE3NJKKH","technical-writing","Layered technical-writing standard: Diátaxis structure, Google developer style sentences, STE instruction rules, Global English syntax. Use for \u002Ftechnical-writing or when writing or reviewing docs, RFCs, readmes, PR descriptions, or commit messages.","https:\u002F\u002Fgithub.com\u002Fquotegoat-ux\u002Fbleat\u002Fblob\u002Fmain\u002Fplugins\u002Fbleat\u002Fskills\u002Ftechnical-writing\u002FSKILL.md",[],[]]