Skip to content

fix: remove api prefix#612

Open
vladimirvolek wants to merge 1 commit into
mainfrom
remove-api-prefix
Open

fix: remove api prefix#612
vladimirvolek wants to merge 1 commit into
mainfrom
remove-api-prefix

Conversation

@vladimirvolek

@vladimirvolek vladimirvolek commented Jul 15, 2026

Copy link
Copy Markdown
Member

resolves: #259

@vercel

vercel Bot commented Jul 15, 2026

Copy link
Copy Markdown

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

Project Deployment Actions Updated (UTC)
blockfrost-platform-docs Ready Ready Preview, Comment Jul 15, 2026 9:00pm
blockfrost-platform-docs-next Ready Ready Preview, Comment Jul 15, 2026 9:00pm

Request Review

@cloudflare-workers-and-pages

Copy link
Copy Markdown

Deploying blockfrost-platform with  Cloudflare Pages  Cloudflare Pages

Latest commit: 3e7a038
Status: ✅  Deploy successful!
Preview URL: https://dd5c8919.blockfrost-platform.pages.dev
Branch Preview URL: https://remove-api-prefix.blockfrost-platform.pages.dev

View logs

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

This PR removes the random UUID path prefix from the Platform’s own HTTP API surface, so the Platform now serves all HTTP routes directly at / while still using a UUID for Icebreakers/gateway routing and registration.

Changes:

  • Flattened/centralized Platform HTTP routing so all API endpoints are mounted directly at / (no UUID prefix nesting).
  • Simplified Icebreakers/relay wiring by removing ApiPrefix plumbing from server construction and load balancer request reconstruction; the UUID is now generated and held by IcebreakersAPI.
  • Updated docs, integration tests, and root changelog to reflect the new routing behavior and registration log message.

Reviewed changes

Copilot reviewed 21 out of 21 changed files in this pull request and generated no comments.

Show a summary per file
File Description
docs/src/content/ja/verification.md Documents that the Platform API is served at / and updates the UUID-related log example.
docs/src/content/ja/faq.mdx Updates FAQ guidance to reflect removal of UUID path prefix for the Platform API.
docs/src/content/en/verification.md Documents that the Platform API is served at / and updates the UUID-related log example.
docs/src/content/en/faq.mdx Updates FAQ guidance to reflect removal of UUID path prefix for the Platform API.
crates/platform/src/server/state.rs Removes the ApiPrefix type and its Display behavior.
crates/platform/src/server/routes/regular.rs Removes the old “regular routes” module (routes are now centralized).
crates/platform/src/server/routes/hidden.rs Removes the old “hidden routes under UUID prefix” module (routes are now centralized).
crates/platform/src/server/routes.rs Introduces a single get_api_routes router containing all API endpoints mounted at / (and optional /metrics).
crates/platform/src/server.rs Removes UUID prefix generation/nesting; uses get_api_routes and simplifies the build return tuple.
crates/platform/src/main.rs Adjusts server startup logging and removes api_prefix propagation into Icebreakers manager.
crates/platform/src/load_balancer.rs Removes prefix injection into reconstructed requests; requests now target json.path directly.
crates/platform/src/icebreakers/manager.rs Removes api_prefix from manager state and load balancer startup parameters.
crates/platform/src/icebreakers/api.rs Generates/stores a UUID for registration, exposes it via api_prefix(), and logs the returned route.
crates/integration_tests/tests/platform_submit.rs Updates build tuple destructuring after removing api_prefix.
crates/integration_tests/tests/platform_root.rs Updates build tuple destructuring after removing api_prefix.
crates/integration_tests/tests/platform_metrics.rs Updates build tuple destructuring after removing api_prefix.
crates/integration_tests/tests/platform_data_node.rs Updates build tuple destructuring after removing api_prefix.
crates/integration_tests/tests/e2e_websocket.rs Updates build tuple destructuring and removes api_prefix threading into manager.
crates/integration_tests/src/platform/mod.rs Updates return types after removing api_prefix from Platform build helpers.
crates/integration_tests/src/gateway/mod.rs Uses icebreakers_api.api_prefix() to construct prefixed gateway base URL for tests.
CHANGELOG.md Adds an Unreleased entry noting removal of UUID path prefix for the Platform API.

@vladimirvolek vladimirvolek self-assigned this Jul 15, 2026
@vladimirvolek vladimirvolek changed the title fix: remove api prefix fix: Remove api prefix Jul 15, 2026
@vladimirvolek vladimirvolek changed the title fix: Remove api prefix fix: remove api prefix Jul 15, 2026

@michalrus michalrus left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Without reading the code yet -- is it backwards compatible? I.e. the old crates/platform (1.0.0) still works with this crates/gateway?

@michalrus
michalrus self-requested a review July 16, 2026 07:29
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Hide GET /metrics and GET / before we have WebSockets

3 participants