Some checks failed
CI / Lint (pull_request) Has been cancelled
CI / Schema map up to date (pull_request) Has been cancelled
CI / Forbidden patterns (9 checks) (pull_request) Has been cancelled
CI / Migrations apply (node-pg-migrate) (pull_request) Has been cancelled
Visual diff / Should run? (pull_request) Has been cancelled
CI / Unit tests (vitest) (pull_request) Has been cancelled
Convoy metrics gate / Require role-event telemetry on convoy PRs (pull_request) Has been cancelled
PR Health rollup / Aggregate gate status (pull_request) Has been cancelled
Preview smoke / Should run? (pull_request) Has been cancelled
Preview smoke / Playwright smoke (pull_request) Has been cancelled
Visual diff / Screenshot diff (pull_request) Has been cancelled
Add pricing schema, free API integrations (MTG bulk, TCGdex, Foolio), valuation and sort-by-price, card detail pricing UI, and nearby store discovery via home zip and OSM geo clients. Co-authored-by: Cursor <cursoragent@cursor.com>
1.6 KiB
1.6 KiB
| convoy | brief_number | depends_on | recommended_model | model_tier | files | ||
|---|---|---|---|---|---|---|---|
| pricing-online-local | 1 | composer-2.5 | standard |
|
Brief 1: Pricing schema migration
Goal (1 sentence)
Ship the node-pg-migrate migration for pricing timestamps, price history, user home zip, and geo caches.
Files in scope (do not edit anything else)
migrations/1783000000001_add-pricing-schema.jsdocs/SCHEMA_MAP.md
Conventions to follow
- Generate via
npm run migrate create add-pricing-schema -- -j js; apply withnpm run migrate up. down()must hard-stub (throw) — seemigrations/1779853647564_initial-schema.js.- Update
docs/SCHEMA_MAP.mdfor every new column/table (AGENTS.md § Schema changes). - Use
ADD COLUMN IF NOT EXISTS/CREATE TABLE IF NOT EXISTSfor idempotency.
Acceptance criteria
- Migration adds
cards.prices_updated_at TIMESTAMPTZ - Migration creates
card_price_historywith UNIQUE(card_id, source, price_type, currency, recorded_at)and index on(card_id, recorded_at DESC) - Migration adds
users.home_zip VARCHAR(10) - Migration creates
geo_zip_cacheandgeo_stores_cachetables per Architecture §3 docs/SCHEMA_MAP.mdupdatednpm run migrate upsucceeds on fresh + existing DB- No scope expansion (do not edit files outside
files:above)
Rationale (≤3 sentences)
All pricing and geo features depend on these columns/tables. Landing schema first unblocks parallel implementers for bulk ingest, APIs, and settings without merge conflicts on migration files.