AGENT
Use when designing a new HTTP/GraphQL API or changing an existing one — modeling resources, defining endpoint contracts, choosing status codes, pagination,…
The same PR, summarized two ways. The weak version is what you get from skimming the title and the last commit. The strong version comes from reading the full `base...HEAD` diff and applying the risk taxonomy. The contrast shows the specific habits that separate a useful summary
$ npx -y skills add vanara-agents/skills --agent claude-codeHow it fires
How this agent gets triggered: by you, by Claude, or both.
Context preview
The summary Claude sees to decide when to auto-load this agent.
The same PR, summarized two ways. The weak version is what you get from skimming the title and the last commit. The strong version comes from reading the full `base...HEAD` diff and applying the risk taxonomy. The contrast shows the specific habits that separate a useful summary
The same PR, summarized two ways. The weak version is what you get from skimming the title and the last commit. The strong version comes from reading the full `base...HEAD` diff and applying the risk taxonomy. The contrast shows the specific habits that separate a useful summary from a useless one.
The PR: a branch titled **"fix: handle empty cart"** with four commits.
---
## PR Summary — fix: handle empty cart **Summary** This PR fixes a bug where the cart didn't handle the empty case. It updates the checkout code to be more robust. Looks good overall. **Risk areas** - Some changes to the checkout flow. **Test plan** - [ ] Test the cart. - [ ] Make sure checkout works.
**Why it fails:**
but commit 2 on the branch also changed the discount calculation — invisible here.
---
## PR Summary — fix: handle empty cart
**Summary**
Fixes a crash when checking out an empty cart (`checkout/total.js:18` now returns 0 instead of
dereferencing `items[0]`). Beyond the stated fix, commit 2 also changes discount rounding in
`checkout/discount.js:33` from `Math.round` to `Math.floor` — a real pricing behavior change the PR
title doesn't mention, and the first thing a reviewer should scrutinize. Net +47/-12 across 3 files;
no new tests were added.
**Risk areas**
- `checkout/discount.js:33` — discount now rounds *down* instead of to-nearest; every discounted
order's total shifts by up to a cent. Money math change, unrelated to the empty-cart fix — confirm
it's intentional and expected by finance/accounting.
- `checkout/total.js:18` — the empty-cart guard returns `0`; verify downstream code treats a `0`
total as valid (not as "unpriced") so it doesn't skip payment or tax steps.
- No test file touched — neither the crash fix nor the rounding change has a regression test.
**Test plan**
- [ ] Checkout an empty cart → returns total 0, no crash (regression test for the reported bug).
- [ ] Discounted order → total uses floor rounding as intended; compare against a known expected
value (covers the unannounced pricing change).
- [ ] A `0` total order flows through payment/tax steps correctly and isn't dropped as "unpriced."**Why it works:** it read the whole branch (caught the commit-2 pricing change the title hid), anchored every claim to a `file:line`, led with the highest-consequence change (money math), stayed neutral (no "looks good"), and turned each risk into a concrete, input-specific test — including the missing regression tests it flagged.
🐒 Free agents, skills & packs for Claude Code One subscription. An army of Claude Code agents. 30 production-grade agents, skills, and packs for Claude Code — free, Apache-2.0, install with one command.
Repo: vanara-agents/skills
Use when designing a new HTTP/GraphQL API or changing an existing one — modeling resources, defining endpoint contracts, choosing status codes, pagination,…
This shows how the api-designer agent reviews a flawed draft. Findings are severity-ranked so the implementer fixes the contract-breakers first. Severity…
The contract is the deliverable. Express it as an **OpenAPI 3.1** document so it is human-readable *and* machine-checkable. This reference covers how to…
Run through this before declaring an API contract done. It is ordered the way you should *design*: resources first, cross-cutting rules last. Every box is a…
APIs are forever once published: a consumer you've never met may depend on any field you expose. Design so you can **add without breaking**, and version…
Copy-paste templates for leaving review comments. Keep each comment to one finding: an anchor, the problem, and the fix.