René's URL Explorer Experiment


Title: feat(a2a): per-request agent-card URL resolution (follow-up to #616) · Issue #647 · adcontextprotocol/adcp-client-python · GitHub

Open Graph Title: feat(a2a): per-request agent-card URL resolution (follow-up to #616) · Issue #647 · adcontextprotocol/adcp-client-python

X Title: feat(a2a): per-request agent-card URL resolution (follow-up to #616) · Issue #647 · adcontextprotocol/adcp-client-python

Description: Problem (follow-up to closed #616) PR for #616 shipped Option A — the static serve(public_url=...) kwarg — and the issue closed COMPLETED. Option B (trust_forwarded_headers for per-request resolution) was explicitly deferred per the dx-e...

Open Graph Description: Problem (follow-up to closed #616) PR for #616 shipped Option A — the static serve(public_url=...) kwarg — and the issue closed COMPLETED. Option B (trust_forwarded_headers for per-request resoluti...

X Description: Problem (follow-up to closed #616) PR for #616 shipped Option A — the static serve(public_url=...) kwarg — and the issue closed COMPLETED. Option B (trust_forwarded_headers for per-request resoluti...

Opengraph URL: https://github.com/adcontextprotocol/adcp-client-python/issues/647

X: @github

direct link

Domain: github.com


Hey, it has json ld scripts:
{"@context":"https://schema.org","@type":"DiscussionForumPosting","headline":"feat(a2a): per-request agent-card URL resolution (follow-up to #616)","articleBody":"## Problem (follow-up to closed #616)\n\nPR for #616 shipped Option A — the static `serve(public_url=...)` kwarg — and the issue closed COMPLETED. Option B (`trust_forwarded_headers` for per-request resolution) was [explicitly deferred](https://github.com/adcontextprotocol/adcp-client-python/issues/616) per the dx-expert review.\n\nThis is fine for single-host deployments. **For multi-tenant subdomain deployments, where every tenant has its own public host, the static kwarg can only advertise one URL.** Adopters still need a per-request rewrite to surface the correct tenant host in `/.well-known/agent-card.json`.\n\n## Concrete adopter scenario\n\n[bokelley/salesagent](https://github.com/bokelley/salesagent) runs multi-tenant on subdomains: `acme.scope3.com`, `beta.scope3.com`, etc. Each tenant's buyer agent fetches the agent card from its own host. A static `public_url=https://scope3.com/` would advertise the wrong host to every non-apex tenant.\n\nToday we work around this with a 190-LOC ASGI middleware ([core/middleware/agent_card_public_url.py](https://github.com/bokelley/salesagent/blob/main/core/middleware/agent_card_public_url.py)) that buffers the `/.well-known/agent-card.json` response and rewrites localhost URLs from `X-Forwarded-Host` per request. It composes cleanly with the new static kwarg (only rewrites loopback, so it no-ops when `public_url` is set) but it's adopter-side code maintaining an SDK-shaped behaviour.\n\n## Proposed shape\n\nTwo options, both addressing the per-request case the deferral explicitly called out:\n\n**A) `serve(trust_forwarded_headers=True)`** — when set, the agent-card route honours `X-Forwarded-Host` and `X-Forwarded-Proto` at response-build time. Defaults to `False` so unconfigured behaviour is unchanged. Concerns from the original deferral:\n\n- *Trust boundary*: gate via the kwarg — adopters explicitly opt in only when they know they're behind a trusted proxy. Matches how Flask / FastAPI / starlette handle the same headers.\n- *Thread-safety on shared `pb.AgentCard`*: build the response card per-request rather than once at server-init. The card payload is small, the marginal CPU is negligible vs. the network IO.\n\n**B) `serve(public_url=Callable[[Request], str])`** — accept a callable in addition to a static string. Adopters provide the resolution logic themselves. More general, less opinionated about trust boundaries.\n\nEither closes the multi-tenant subdomain gap. **A** is the cleaner zero-config option for the common case (most multi-tenant adopters have a reverse proxy that sends `X-Forwarded-Host`); **B** keeps the SDK out of the trust-policy business at the cost of every adopter writing the resolver.\n\n## Why a new issue vs reopening #616\n\n#616 closed COMPLETED — fine, the static kwarg is real and useful. Re-opening it would muddy the changelog. This is a separate ask that depends on the closed work landing first.\n\n## Source\n\nOur deferral entry in [bokelley/salesagent core/SDK_FEEDBACK.md](https://github.com/bokelley/salesagent/blob/main/core/SDK_FEEDBACK.md): \"make the agent-card URL `X-Forwarded-Host`-aware when no static `public_url` is configured, OR accept a `Callable[[Request], str]` for per-request resolution.\"\n\nLocal tracker: bokelley/salesagent#103.\n\n## Related\n\n- #616 (closed; Option A shipped)\n- #621 (PR that shipped Option A)\n","author":{"url":"https://github.com/bokelley","@type":"Person","name":"bokelley"},"datePublished":"2026-05-11T06:22:55Z","url":"https://github.com/adcontextprotocol/adcp-client-python/issues/647"}

react-profiling0
react-import-mapreact,react-dom,react-dom/client,react-dom/profiling,react-is,react/compiler-runtime,react/jsx-dev-runtime,react/jsx-runtime,scheduler@b8488ee2c322
route-pattern/_view_fragments/issues/show/:user_id/:repository/:id/issue_layout(.:format)
route-controllervoltron_issues_fragments
route-actionissue_layout
fetch-noncev2:ce9227c3-c03e-79e0-652b-a60f6d0a0529
current-catalog-service-hash81bb79d38c15960b92d99bca9288a9108c7a47b18f2423d0f6438c5b7bcd2114
request-idE42E:34DB8F:1B3986D:245A263:6B016527
html-safe-noncea5af35fd050032925072f7fbab01a4eaa4293a50378b6ea8c6d51f5648e0e083
visitor-payloadeyJyZWZlcnJlciI6IiIsInJlcXVlc3RfaWQiOiJFNDJFOjM0REI4RjoxQjM5ODZEOjI0NUEyNjM6NkIwMTY1MjciLCJ2aXNpdG9yX2lkIjoiMzA4ODUxMjE5OTgyNDU5ODMxMSIsInJlZ2lvbl9lZGdlIjoiaWFkIiwicmVnaW9uX3JlbmRlciI6ImlhZCJ9
visitor-hmac9584d2ca94961ecdc89e77b1186edf051874e927c5481c304f6e66f5c35059ea
hovercard-subject-tagissue:4418528290
github-keyboard-shortcutsrepository,issues,copilot
google-site-verificationApib7-x98H0j5cPqHWwSMm6dNU4GmODRoqxLiDzdx9I
octolytics-urlhttps://collector.github.com/github/collect
analytics-location///voltron/issues_fragments/issue_layout
fb:app_id1401488693436528
apple-itunes-appapp-id=1477376905, app-argument=https://github.com/_view_fragments/issues/show/adcontextprotocol/adcp-client-python/647/issue_layout
twitter:imagehttps://opengraph.githubassets.com/77b6c78cc4bca2cd84daa297e06f83e7ae682257d364e95b1e392779df9a1126/adcontextprotocol/adcp-client-python/issues/647
twitter:cardsummary_large_image
og:imagehttps://opengraph.githubassets.com/77b6c78cc4bca2cd84daa297e06f83e7ae682257d364e95b1e392779df9a1126/adcontextprotocol/adcp-client-python/issues/647
og:image:altProblem (follow-up to closed #616) PR for #616 shipped Option A — the static serve(public_url=...) kwarg — and the issue closed COMPLETED. Option B (trust_forwarded_headers for per-request resoluti...
og:image:width1200
og:image:height600
og:site_nameGitHub
og:typeobject
og:author:usernamebokelley
hostnamegithub.com
expected-hostnamegithub.com
Nonecc5dfdd32f62ebd3223cab3af3aa2b268d3605218237326a48a99d1efd89495c
turbo-cache-controlno-preview
go-importgithub.com/adcontextprotocol/adcp-client-python git https://github.com/adcontextprotocol/adcp-client-python.git
octolytics-dimension-user_id221690821
octolytics-dimension-user_loginadcontextprotocol
octolytics-dimension-repository_id1090305973
octolytics-dimension-repository_nwoadcontextprotocol/adcp-client-python
octolytics-dimension-repository_publictrue
octolytics-dimension-repository_is_forkfalse
octolytics-dimension-repository_network_root_id1090305973
octolytics-dimension-repository_network_root_nwoadcontextprotocol/adcp-client-python
turbo-body-classeslogged-out env-production page-responsive
disable-turbofalse
browser-stats-urlhttps://api.github.com/_private/browser/stats
browser-errors-urlhttps://api.github.com/_private/browser/errors
release8c77c9e8439031ad54c75a250694842892f693e1
ui-targetfull
theme-color#1e2327
color-schemelight dark
react-app-nameissues

Links:

Skip to contenthttps://github.com/adcontextprotocol/adcp-client-python/issues/647#start-of-content
https://github.com/
Sign inhttps://github.com/login?return_to=https%3A%2F%2Fgithub.com%2Fadcontextprotocol%2Fadcp-client-python%2Fissues%2F647
GitHubRepository hosting, code review, and collaborationhttps://github.com/platform
CopilotAI coding agent for tasks, projects, and automated workhttps://github.com/features/copilot
ActionsCI/CD and automationhttps://github.com/features/actions
Code QualityQuality analysis, fixes, and enforcementhttps://github.com/features/code-quality
CodespacesCloud development environmentshttps://github.com/features/codespaces
Code SecurityVulnerability detection and remediationhttps://github.com/security/advanced-security/code-security
Secret ProtectionSecret scanning and leak preventionhttps://github.com/security/advanced-security/secret-protection
All Featureshttps://github.com/features
Documentationhttps://docs.github.com/en
Traininghttps://learn.github.com/skills
Certificationshttps://learn.github.com/credentials
Build with Copilothttps://github.com/features/ai
Customize Copilothttps://docs.github.com/en/copilot/how-tos/copilot-on-github/customize-copilot/customize-copilot-overview
Integrationshttps://github.com/marketplace
Trending reposhttps://github.com/trending
GitHub Sponsorshttps://github.com/open-source/sponsors
Developer articleshttps://github.com/resources/articles
ChangelogYour source for the latest features, improvements, and fixes across GitHub products, all in one place.https://github.blog/changelog/
Enterpriseshttps://github.com/enterprise
Teamhttps://github.com/team
Startupshttps://github.com/enterprise/startups
Nonprofitshttps://github.com/solutions/industry/nonprofits
Healthcarehttps://github.com/solutions/industry/healthcare
Financial serviceshttps://github.com/solutions/industry/financial-services
Manufacturinghttps://github.com/solutions/industry/manufacturing
Governmenthttps://github.com/solutions/industry/government
See all industrieshttps://github.com/solutions/industry
Why GitHubhttps://github.com/why-github
Customer Storieshttps://github.com/customer-stories
Business insightshttps://github.com/solutions/executive-insights
Trust Centerhttps://github.com/trust-center
GitHub Advanced SecurityEnterprise-grade code securityhttps://github.com/security/advanced-security
Copilot for businessEnterprise-grade AI featureshttps://github.com/features/copilot/copilot-business
Premium SupportEnterprise-grade 24/7 supporthttps://github.com/enterprise/premium-support
Documentationhttps://docs.github.com/en
Resource centerhttps://github.com/resources
Bloghttps://github.blog/
Events & webinarshttps://github.com/resources/events
Community Forumhttps://github.com/orgs/community/discussions
Customer Storieshttps://github.com/customer-stories
Integrationshttps://github.com/marketplace
Customer supporthttps://help.github.com/
Traininghttps://learn.github.com/skills
GitHub Statushttps://www.githubstatus.com/
Abouthttps://github.com/about
Partnershttps://github.com/partners
Changeloghttps://github.blog/changelog/
GitHub UniverseThe event for developers, by developers — talks, workshops, and what’s next for GitHub.https://githubuniverse.com/
Pricinghttps://github.com/pricing
Sign inhttps://github.com/login?return_to=https%3A%2F%2Fgithub.com%2Fadcontextprotocol%2Fadcp-client-python%2Fissues%2F647
Sign uphttps://github.com/signup?ref_cta=Sign+up&ref_loc=header+logged+out&ref_page=%2F%3Cuser-name%3E%2F%3Crepo-name%3E%2Fvoltron%2Fissues_fragments%2Fissue_layout&source=header-repo&source_repo=adcontextprotocol%2Fadcp-client-python
Reloadhttps://github.com/adcontextprotocol/adcp-client-python/issues/647
Reloadhttps://github.com/adcontextprotocol/adcp-client-python/issues/647
Reloadhttps://github.com/adcontextprotocol/adcp-client-python/issues/647
adcontextprotocolhttps://github.com/adcontextprotocol
adcp-client-pythonhttps://github.com/adcontextprotocol/adcp-client-python
Codehttps://github.com/adcontextprotocol/adcp-client-python
Issues44 (44)https://github.com/adcontextprotocol/adcp-client-python/issues
Pull requests13 (13)https://github.com/adcontextprotocol/adcp-client-python/pulls
Actionshttps://github.com/adcontextprotocol/adcp-client-python/actions
Projectshttps://github.com/adcontextprotocol/adcp-client-python/projects
Security and qualityhttps://github.com/adcontextprotocol/adcp-client-python/security
Insightshttps://github.com/adcontextprotocol/adcp-client-python/insights
https://github.com/adcontextprotocol/adcp-client-python
New issuehttps://github.com/login?return_to=https://github.com/adcontextprotocol/adcp-client-python/issues/647
New issuehttps://github.com/login?return_to=https://github.com/adcontextprotocol/adcp-client-python/issues/647
#650https://github.com/adcontextprotocol/adcp-client-python/pull/650
feat(a2a): per-request agent-card URL resolution (follow-up to #616)https://github.com/adcontextprotocol/adcp-client-python/issues/647#top
#650https://github.com/adcontextprotocol/adcp-client-python/pull/650
claude-triagedhttps://github.com/adcontextprotocol/adcp-client-python/issues?q=state%3Aopen%20label%3A%22claude-triaged%22
https://github.com/bokelley
bokelleyhttps://github.com/bokelley
on May 11, 2026https://github.com/adcontextprotocol/adcp-client-python/issues/647#issue-4418528290
#616https://github.com/adcontextprotocol/adcp-client-python/issues/616
#616https://github.com/adcontextprotocol/adcp-client-python/issues/616
explicitly deferredhttps://github.com/adcontextprotocol/adcp-client-python/issues/616
bokelley/salesagenthttps://github.com/bokelley/salesagent
core/middleware/agent_card_public_url.pyhttps://github.com/bokelley/salesagent/blob/main/core/middleware/agent_card_public_url.py
#616https://github.com/adcontextprotocol/adcp-client-python/issues/616
#616https://github.com/adcontextprotocol/adcp-client-python/issues/616
bokelley/salesagent core/SDK_FEEDBACK.mdhttps://github.com/bokelley/salesagent/blob/main/core/SDK_FEEDBACK.md
bokelley/salesagent#103https://github.com/bokelley/salesagent/issues/103
feat(a2a): agent-card public URL injection (X-Forwarded-Host aware) #616https://github.com/adcontextprotocol/adcp-client-python/issues/616
feat(a2a): add public_url param to agent card for production deployments #621https://github.com/adcontextprotocol/adcp-client-python/pull/621
bokelleyhttps://github.com/bokelley
claude-triagingTriage routine is actively working on this issue (1-3 min)https://github.com/adcontextprotocol/adcp-client-python/issues?q=state%3Aopen%20label%3A%22claude-triaging%22
claude-triagedhttps://github.com/adcontextprotocol/adcp-client-python/issues?q=state%3Aopen%20label%3A%22claude-triaged%22
claude-triagingTriage routine is actively working on this issue (1-3 min)https://github.com/adcontextprotocol/adcp-client-python/issues?q=state%3Aopen%20label%3A%22claude-triaging%22
on May 11, 2026https://github.com/adcontextprotocol/adcp-client-python/issues/647#event-25368334345
https://github.com/bokelley
bokelleyhttps://github.com/bokelley
on May 11, 2026https://github.com/adcontextprotocol/adcp-client-python/issues/647#issuecomment-4418211021
#650https://github.com/adcontextprotocol/adcp-client-python/pull/650
Claude Codehttps://claude.ai/code
bokelleyhttps://github.com/bokelley
completedhttps://github.com/adcontextprotocol/adcp-client-python/issues?q=is%3Aissue%20state%3Aclosed%20archived%3Afalse%20reason%3Acompleted
#650https://github.com/adcontextprotocol/adcp-client-python/pull/650
on May 11, 2026https://github.com/adcontextprotocol/adcp-client-python/issues/647#event-25370166566
bokelleyhttps://github.com/bokelley
on May 11, 2026https://github.com/adcontextprotocol/adcp-client-python/issues/647#event-25370166668
feat(a2a): per-request agent-card URL resolution via callable public_…https://github.com/adcontextprotocol/adcp-client-python/commit/1b4f3e05bd075b65b334a289fa05403008918796
https://docs.github.com/articles/closing-issues-via-commit-messages
1b4f3e0https://github.com/adcontextprotocol/adcp-client-python/commit/1b4f3e05bd075b65b334a289fa05403008918796
feat: adopt adcp 5.0 — delete obsolete middleware + migrate to public…https://github.com/bokelley/salesagent/commit/e6ecd0de8b0464ae31a5855b201ade30590070aa
https://docs.github.com/articles/closing-issues-via-commit-messages
e6ecd0dhttps://github.com/bokelley/salesagent/commit/e6ecd0de8b0464ae31a5855b201ade30590070aa
Sign up for freehttps://github.com/signup?return_to=https://github.com/adcontextprotocol/adcp-client-python/issues/647
Sign in to commenthttps://github.com/login?return_to=https://github.com/adcontextprotocol/adcp-client-python/issues/647
claude-triagedhttps://github.com/adcontextprotocol/adcp-client-python/issues?q=state%3Aopen%20label%3A%22claude-triaged%22
https://github.com
Termshttps://docs.github.com/site-policy/github-terms/github-terms-of-service
Privacyhttps://docs.github.com/site-policy/privacy-policies/github-privacy-statement
Securityhttps://github.com/security
Statushttps://www.githubstatus.com/
Communityhttps://github.community/
Docshttps://docs.github.com/
Contacthttps://support.github.com?tags=dotcom-footer

Viewport: width=device-width


URLs of crawlers that visited me.