Skip to content

CLI network browse should distinguish peer/operator from on-chain seller #596

@kc-zero-lab

Description

@kc-zero-lab

Summary

antseed network browse currently displays peer.peerId as the visible peer/seller identity. For delegated/proxy sellers, that value is the operator EOA / node identity, while the actual on-chain seller is carried separately in peer.metadata.sellerContract.

This makes Venice-style delegated sellers look visually wrong in the CLI: the browse table appears to show the operator wallet as the seller, even though discovery/enrichment and channel accounting are already using the seller contract address correctly.

Current behavior

  • antseed network browse shows peer.peerId
  • peer.peerId is the operator EOA / node identity
  • delegated/proxy sellers announce the actual on-chain seller in peer.metadata.sellerContract
  • the browse table does not surface sellerContract, so users can mistake the operator for the seller

Expected behavior

Keep Peer as the pin/connect identity, but explicitly show the on-chain seller when it differs or when metadata.sellerContract exists.

Suggested CLI UX:

antseed network browse

  • keep existing Peer column for peer.peerId
    • this is still needed for antseed buyer connection set --peer <peerId>
    • also matches x-antseed-pin-peer
  • add a Seller / On-chain seller column when metadata.sellerContract exists
  • if no seller contract exists, the column can show the peer address or be omitted depending on table width

antseed network peer <id>

Show both identities explicitly:

Peer / operator: <peerId>
On-chain seller: 0x<sellerContract>   # or same as peer when not delegated

Also add a short note:

Channel stats/payments are attributed to the seller address.

Why this matters

The underlying data model appears correct:

  • sellers announce sellerContract
  • buyer discovery/enrichment resolves sellerContract.isOperator(peerAddress)
  • on-chain stats/payments use the seller contract address, not the operator wallet

But the CLI presentation hides that distinction. This can make delegated/proxy sellers look misconfigured even when channel resolution is doing the right thing.

Likely files

The change should be small, mostly around CLI presentation:

  • apps/cli/src/cli/commands/network/browse.ts
  • apps/cli/src/cli/commands/network/peer.ts

Proposed fix

  1. In browse output, derive something like:
    • peerId / operator from peer.peerId
    • sellerAddress from peer.metadata?.sellerContract ?? peer.peerId
  2. Render both where appropriate.
  3. Preserve all pin/connect semantics around peer.peerId.
  4. In peer detail view, clearly label operator vs on-chain seller and explain payment attribution.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions