fix(rpc): show the real base endpoint in RPC response URL, not a fabr…#31
Merged
Conversation
…icated path The LIVE RESPONSE header and the expanded-response modal on RPC operation pages displayed a synthetic URL like `https://rpc.mainnet.fastnear.com/account/view_account`. NEAR JSON-RPC does not route by path — every method is a POST to the base endpoint with the method in the JSON body — so that `/account/view_account` slug never matched the actual request that the page fires. Drop the buildRpcEndpointUrl helper (which derived the slug from the canonical docs path) and report the real endpoint the request POSTs to (selectedNetworkDetails.url), which also correctly tracks mainnet/testnet. The change is runtime-display only; REST/HTTP pages, which have genuine paths, are untouched. Update the two playwright assertions that had codified the old behavior. Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01H8DjaLbA7Ed63XuSAENrJ7
mikedotexe
added a commit
that referenced
this pull request
Jul 21, 2026
…an older build) No content change. Four PRs merged within ~3 minutes (#32, #33, #30, #31) and their Cloudflare Pages deployments finished out of order: #33 fe452e4 14:01:28 #31 f914d2f 14:02:13 <- newest commit (contains the RPC endpoint-URL fix) #30 99a2520 14:02:56 <- finished LAST CF Pages points the production alias at the last deployment to *finish*, not the newest commit, so docs.fastnear.com got pinned to #30's build (main.6e03125c.js), which predates the RPC fix. Result: the live docs still rendered a fabricated `https://rpc.mainnet.fastnear.com/account/view_account` instead of the real base endpoint. This empty commit forces a fresh production deployment of current main, which already contains the fix. Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01H8DjaLbA7Ed63XuSAENrJ7
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
…icated path
The LIVE RESPONSE header and the expanded-response modal on RPC operation pages displayed a synthetic URL like
https://rpc.mainnet.fastnear.com/account/view_account. NEAR JSON-RPC does not route by path — every method is a POST to the base endpoint with the method in the JSON body — so that/account/view_accountslug never matched the actual request that the page fires.Drop the buildRpcEndpointUrl helper (which derived the slug from the canonical docs path) and report the real endpoint the request POSTs to (selectedNetworkDetails.url), which also correctly tracks mainnet/testnet. The change is runtime-display only; REST/HTTP pages, which have genuine paths, are untouched.
Update the two playwright assertions that had codified the old behavior.
Claude-Session: https://claude.ai/code/session_01H8DjaLbA7Ed63XuSAENrJ7