Repository navigation
Closed
Labels
Description
Summary
adcontextprotocol/adcp#7848 adds "Account references before provisioning" to the spec:
- A buyer-declared natural key resolves only after the seller provisions it.
- Only provisioning tasks (ones that commit spend or create account-owned resources) provision. Discovery and negotiation tasks (
get_products,list_products,get_signals,request_proposals,refine_proposals,decline_proposals) never do. - An unresolved
accountreturnsACCOUNT_NOT_FOUND, including on optional-account tasks. - Buyers omit
accountuntil it's provisioned. - Account errors are not seller-health signals.
- "Buyer SDKs SHOULD track, per seller agent, which natural keys the seller has provisioned and apply these rules by default."
The SDK currently leaves all of this to implementers, and one seller-side default breaks public discovery. The behaviour should match the JS SDK; see adcontextprotocol/adcp-client#3093.
Seller side
At 1fa2b06b:
- Bug:
ExplicitAccountsrejects requests with no account.get_productsalways callsAccountStore.resolve(src/adcp/decisioning/handler.py:2307→_resolve_account,:1543).ExplicitAccounts.resolveraisesACCOUNT_NOT_FOUNDwheneveraccount_idis missing, including whenrefisNone(src/adcp/decisioning/accounts.py:576-597). So a seller using it can't serve account-less public discovery whenrequired_for_productsis false. Absentaccounton an optional-account task should resolve to "no account" (public view). Absentaccountwithrequired_for_products: trueshould getACCOUNT_REQUIRED. - Add a bundled natural-key resolver for buyer-declared sellers. It matches the complete natural key against accounts provisioned by
sync_accountsand returnsACCOUNT_NOT_FOUNDon a miss. - Tell
AccountStore.resolvewhether the task is a provisioning task, and document that lazy provisioning MUST be gated on it. - Add tests for an unknown natural key on
get_products(expectACCOUNT_NOT_FOUND, not public products) and for no account created by a discovery task.
Buyer side
- Account registry per seller agent.
client.accounts.ensure(key, billing=..., payment_terms=...)returnsstatusandaccount_id, persisted through a storage adapter. Todaysync_accountsandget_productsare pass-through (src/adcp/client.py:3209-3251,:2237-2315), andrequired_for_productsandrequire_operator_authare never read. -
account_policy="auto" | "strict"on account-carrying calls.autoomits an unprovisionedaccountand passesbrand.strictraises. - Typed exceptions
AccountNotFoundError,AccountSetupRequiredError, andAccountPaymentRequiredError, carryingfault="buyer_setup". -
FeedMirrorfixes. A missingcache_scopeis currently read as"public"(src/adcp/feed_mirror.py:77-84); this should fail closed. Add public/account layering instead of one mirror per account. Confirm that a failed refresh keeps the last good mirror (the JS SDK has this bug: WholesaleFeedSync wipes the product mirror when a refresh fails adcp-client#3092).
Activity
bokelley commentedon Oct 1, 2026
Triage
Classification: Bug + Feature request (mixed)
Bucket(s): client, handlers (labels not present in repo — gap noted)
Status: ready-for-human
Cross-repo: refs adcontextprotocol/adcp#7848
What the experts said:
allow_absentopt-in for the bug fix and a parallelresolve_for_taskmethod instead of changing the AccountStore.resolve signature.feed_mirror.py:81carries an inline comment stating "spec requirescache_scope: 'public'for unscoped reads," directly contradicting the fail-closed proposal — adcp#7848 text must be verified before changing_scope_str.My take: Experts agree on the diagnosis but disagree on fix strategy for
ExplicitAccounts(spec-mandated direct change vs. breaking-change opt-in guard), and the FeedMirror item has an open spec question that blocks it. @bokelley recommend converting this to an epic with a task list; the seller-sideExplicitAccountsfix is the clearest first PR candidate once the opt-in vs. direct-change question is resolved.Triaged by Claude Code. Session: https://claude.ai/code/session_01Dd8edJgtPwJnPavcUAw6ND
Generated by Claude Code