← Tips

OWASPA06Insecure Design

I Gave My AI Database Access. The Price Was Still Wrong.

Same prompt, but this time the AI could read the database. It changed how cleaners get matched without asking me, and the booking was still $15 short. Having access isn't the same as checking.

Watch on YouTube

The mistake

My AI missed a $15 pet fee because the fee lived in the database and it couldn't see the database. So I gave it read-only database access and asked the exact same thing, in a fresh session.

This time it went further. Without asking, it changed the cleaner matching so that "unknown" now means "might have pets". The cats booking went to the cleaner without the allergy. Better.

But the price was still $150. It had access to the database. It didn't look at what used the column.
It also made a decision for me

The new matching means the cleaner with the allergy gets no new jobs until staff confirm the pets answer by hand. That's a reasonable call. It's also a business decision about your staff's work, and the AI made it without asking. In another run with the same access, it asked first. You can't count on which one you'll get.

The fix

What to do instead

  • Don't treat access as checking. Ask the AI what it looked at, and what it couldn't check.
  • Run the check yourself. The full post has a read-only query for the Supabase SQL editor that lists every view, function, policy and trigger that touches a column.
  • Make the business decisions yourself before you hand over the change: what "unknown" should mean for fees, matching and staff.

The query and the full order of changes are in the full post: My AI Removed One Form Field. It Never Mentioned the Price

The app in this tip is my own demo, built with fake data. Behaviour varied between runs; this is what happened when I tried it with Claude Code 2.1.326 in November 2026.

Full post: My AI Removed One Form Field. It Never Mentioned the Price →