Skip to content

Keep app-facing API contracts deployable and verifiable - #308

Merged
OziinG merged 2 commits into
mainfrom
fix/openapi-contract-parity
Aug 19, 2026
Merged

Keep app-facing API contracts deployable and verifiable#308
OziinG merged 2 commits into
mainfrom
fix/openapi-contract-parity

Conversation

@OziinG

@OziinG OziinG commented Aug 19, 2026

Copy link
Copy Markdown
Contributor

What changed

  • expand OpenAPI parity across app-facing Orders, Route Plans, Drivers, Inventory, Route Groups, and customer-email routes
  • align Shopify API runtime, schema, migration, examples, and docs to 2026-07
  • add sanitized shopify_admin_api_surface_request correlation records
  • add a guarded disposable PostgreSQL integration runner for otherwise skipped suites
  • repair stale DB fixtures revealed by the guarded lane
  • fix the single-order assignment optimistic-lock race exposed by those integration tests
  • keep deployment migration monitoring aligned with the new migration tail

Why

The full API audit found documented/runtime route drift, duplicated Shopify API defaults, incomplete cross-service request evidence, and DB integration suites that were safe but difficult to run. Enabling the guarded tests also exposed a real single-order assignment concurrency defect.

Impact

The Shopify compatibility path remains query-only for upstream Orders and Customers. Existing app-facing routes remain backward-compatible. Runtime logs contain only sanitized route, status, timing, app/request identifiers, and no raw request or response bodies.

Verification

  • Prisma validate and client generation passed
  • ESLint, typecheck, and production build passed
  • default suite: 1,881 passed; 56 guarded tests intentionally skipped
  • targeted OpenAPI/version/logging suite: 22 passed
  • disposable PostgreSQL lane: 59 passed across G003, G004/G009, and G005
  • OpenAPI parsed as 3.1.0 with 138 paths, 190 operations, and 2026-07 header example
  • disposable containers were removed after completion
  • manual full GitHub Actions CI passed

Cross-repository tracking

OziinG added 2 commits August 19, 2026 14:02
Constraint: Shopify compatibility remains query-only and existing app routes stay backward-compatible.
Rejected: Raw payload logging | Protected customer data must not enter retained runtime evidence.
Confidence: high
Scope-risk: moderate
Directive: Keep OpenAPI parity, Shopify API defaults, and disposable DB guards synchronized with runtime changes.
Tested: prisma validate/generate; lint; typecheck; build; 1,881 default tests; 59 disposable DB tests; OpenAPI parse/parity checks.
Not-tested: Production cross-service smoke pending after both PRs merge.
Constraint: Production monitoring treats the repository migration tail as an exact deployment contract.
Confidence: high
Scope-risk: narrow
Directive: Update the monitor migration count and latest-name assertion whenever a checked-in migration is added.
Tested: tests/deploy/monitor-route-ops-production.test.sh
@OziinG
OziinG marked this pull request as ready for review August 19, 2026 05:08
@OziinG
OziinG merged commit f2eb7cf into main Aug 19, 2026
4 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant