Skip to content

feat: convert 52 API endpoints from POST to GET for edge caching#468

Merged
koala73 merged 3 commits intomainfrom
caching_endpoints_get_verb
Feb 27, 2026
Merged

feat: convert 52 API endpoints from POST to GET for edge caching#468
koala73 merged 3 commits intomainfrom
caching_endpoints_get_verb

Conversation

@SebastienMelki
Copy link
Collaborator

Summary

  • 52 endpoints converted from POST to GET across all 21 sebuf services, enabling CDN/edge caching
  • Flattened nested request types (TimeRange, PaginationRequest, BoundingBox) into scalar query params
  • Added path params for resource lookups: GetFredSeries/{series_id}, GetHumanitarianSummary/{country_code}, GetCountryStockIndex/{country_code}, GetCountryIntelBrief/{country_code}, GetAircraftDetails/{icao24}
  • Rewritten router with hybrid static O(1) + dynamic path-param matching
  • Generated with sebuf v0.9.0 (fixes enum/repeated field/path param codegen for GET endpoints)

Kept as POST

  • SummarizeArticle — AI generation
  • ClassifyEvent — AI classification
  • RecordBaselineSnapshot — write operation
  • GetAircraftDetailsBatch — repeated string payload (up to 20 IDs)
  • RegisterInterest — non-sebuf, already POST

Test plan

  • test:sidecar — 53/53 pass
  • test:data — 168/173 pass (5 failures are pre-existing: 4 missing fallbackVideoIds, 1 theater posture race condition)
  • tsc --noEmit — only 3 pre-existing rateLimited errors remain, zero generated code errors
  • E2E smoke test on staging

🤖 Generated with Claude Code

@vercel
Copy link

vercel bot commented Feb 27, 2026

The latest updates on your projects. Learn more about Vercel for GitHub.

Project Deployment Actions Updated (UTC)
worldmonitor Ready Ready Preview, Comment Feb 27, 2026 3:27pm
worldmonitor-finance Ready Ready Preview, Comment Feb 27, 2026 3:27pm
worldmonitor-happy Ready Ready Preview, Comment Feb 27, 2026 3:27pm
worldmonitor-startup Ready Ready Preview, Comment Feb 27, 2026 3:27pm

Request Review

Convert all cacheable sebuf RPC endpoints to HTTP GET with query/path
parameters, enabling CDN edge caching to reduce costs. Flatten nested
request types (TimeRange, PaginationRequest, BoundingBox) into scalar
query params. Add path params for resource lookups (GetFredSeries,
GetHumanitarianSummary, GetCountryStockIndex, GetCountryIntelBrief,
GetAircraftDetails). Rewrite router with hybrid static/dynamic matching
for path param support.

Kept as POST: SummarizeArticle, ClassifyEvent, RecordBaselineSnapshot,
GetAircraftDetailsBatch, RegisterInterest.

Generated with sebuf v0.9.0 (protoc-gen-ts-client, protoc-gen-ts-server).

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
SebastienMelki and others added 2 commits February 27, 2026 17:25
The rateLimited field was hand-patched into generated files on main but
never declared in the proto definitions. Regenerating wiped it out,
breaking the build. Now properly defined in both ListEtfFlowsResponse
and ListMarketQuotesResponse protos.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
@koala73 koala73 merged commit 7c40542 into main Feb 27, 2026
6 checks passed
koala73 added a commit that referenced this pull request Feb 27, 2026
Stale cached client bundles still send POST to endpoints converted to
GET in PR #468, causing 404s. The gateway now parses the POST JSON body
into query params and retries the match as GET.
koala73 added a commit that referenced this pull request Feb 27, 2026
…#477)

Stale cached client bundles still send POST to endpoints converted to
GET in PR #468, causing 404s. The gateway now parses the POST JSON body
into query params and retries the match as GET.
@koala73 koala73 deleted the caching_endpoints_get_verb branch February 27, 2026 20:49
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.

2 participants