Repository navigation
searchapi: derive the 402 resource.url from the committed spec, drop … - #783
Merged
Merged
Conversation
…SEARCH_SERVICE_URL A leftover trial-deploy env value advertised the *.bunny.run origin as the payment scope on the direct routes, making #97600 unattributable to web-agent.fretchen.eu for indexers (cdp-sdk#835). resource.url is the payment scope, not the serving origin, so it now always names the production identity from openapi.search.json's servers[0].url — the same pattern as the llm twin. The stale env var was removed from script 97472 (verified live: search and fetch both quote https://web-agent.fretchen.eu now). Generated by Mistral Vibe. Co-Authored-By: Mistral Vibe <vibe@mistral.ai>
Each origin now serves a generated agent README at GET /, unconditionally (agents send Accept: */*, so the old text/html gate hid it): spec title and description, the well-known contracts (openapi.json, agent-registration, oasf.json, MCP), prices from the spec's x-payment-info / the live price ceiling, the x402 payment flow, a no-wallet curl that returns the honest 402, and the error semantics. The <link rel="icon"> x402scan parses stays the first head element; nothing on the page is hand-restated. - discovery.ts (bunny + scw twins): FAVICON_DISCOVERY_HTML + wantsHtml replaced by buildRootPage(RootPageInput); no callers of wantsHtml remain. - searchapi_routes: page generated from the committed spec (prices per route from x-payment-info); serviceName -> "Fretchen Web Retrieval"; spec title -> "Fretchen Web Retrieval - pay-per-call web access for agents". - llm_routes: page with the live MAX_PRICE_ATOMIC ceiling, the testnet mock note, and the MCP link; serviceName -> "Fretchen LLM Inference"; spec title -> "Fretchen LLM Inference - pay-per-call chat completions for agents". - mcp_routes: hand-composed gateway page (the origin relays, holds no spec of its own): links to both seller origins, its registration document, free initialize/tools/list curl, and the isError/structuredContent 402 shape of an unpaid tools/call. - genimg (scw): same scheme, generated from openapi.genimg.json (title and description unchanged - already capability-first, decided). - tests: root serving is now unconditional and asserted with favicon-first, href, price and curl checks; the llm "non-POST" rejection moved from GET (now the root page) to PUT; pinned serviceNames and titles updated. - READMEs: one entry each describing the root page. Generated by Mistral Vibe. Co-Authored-By: Mistral Vibe <vibe@mistral.ai>
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.
…SEARCH_SERVICE_URL
A leftover trial-deploy env value advertised the *.bunny.run origin as the payment scope on the direct routes, making #97600 unattributable to web-agent.fretchen.eu for indexers (cdp-sdk#835). resource.url is the payment scope, not the serving origin, so it now always names the production identity from openapi.search.json's servers[0].url — the same pattern as the llm twin. The stale env var was removed from script 97472 (verified live: search and fetch both quote https://web-agent.fretchen.eu now).
Generated by Mistral Vibe.