Fence Risky Commands
Block risky commands with permission rules and limited logins, then say in the prompt what needs your OK.
Where you'll practice this
4 Promptles scenarios teach this principle directly. Each one drops you into a real engineering ticket and asks you to write the prompt you'd send to Claude Code.
Share Sentry with the Team
Engineers on `billbird/app` keep pasting Sentry error reports into Claude Code by hand. You want all of them to have Sentry's hosted MCP server, set up the same way. It signs each person in with OAuth (a browser login, so nobody handles a token). It offers read tools and one…
Undo It Safely
Two things went wrong this morning. PR #212, the booking discounts change, was merged into the shared `main` yesterday as merge commit `a1b2c3d`, and it broke booking checkout in staging. Five teammates have pulled `main` since. Separately, while tidying your local…
Rebase Before Review
Esther asked you to rebase `feature/csv-export`, which exports bookings to a spreadsheet, so her review shows only your changes. The branch is 14 commits behind `main` and already pushed, so after the rebase it can only be updated with a force push (replacing the branch on…
Allow Only What's Needed
Approving every Gmail search by hand got tedious, so a teammate added the whole Gmail server to the project's Claude Code allow list (the permission rules that let tools run without asking). Searches and reads now run straight through, as hoped. So does sending: yesterday a…
Other principles in Constraints
Define Component Boundaries
When splitting a component, give the decisions already made and say nothing on screen should change.
Define Inputs and Outputs
Say what goes in, what comes out, and what happens with bad input. Leave the inside to Claude.
Define the Business Logic
Turn business words into exact rules: the fields, the thresholds, and how they combine.
Deprecate Before Removing
Keep the old name working for a release, point to the replacement, and announce when it goes away.
Describe Edge Cases
Name the unusual cases you know about and what should happen in each.
Describe Type Contracts
Tell Claude the rules the code doesn't show, like allowed values and optional fields. It can work out the rest.