Skip to content

Add bsv namespace (BSV Blockchain) - #190

Merged
obstropolos merged 5 commits into
ChainAgnostic:mainfrom
sirdeggen:bsv-namespace
Aug 18, 2026
Merged

Add bsv namespace (BSV Blockchain)#190
obstropolos merged 5 commits into
ChainAgnostic:mainfrom
sirdeggen:bsv-namespace

Conversation

@sirdeggen

@sirdeggen sirdeggen commented Jul 16, 2026

Copy link
Copy Markdown
Contributor

Summary

Adds a new namespace, bsv, for the BSV Blockchain, with a complete README.md and CAIP-2 profile. Registers four Chain IDs:

  • bsv:mainnet — BSV main network
  • bsv:testnet — BSV public test network
  • bsv:ttn — Teranode Test Net (public Teranode scaling test network / Teratestnet)
  • bsv:tstn — Teranode Scaling Test Net (private, per-deployment scaling test network)

Approach and rationale

BSV descends from the original Bitcoin protocol and shares Satoshi's genesis block with BTC and BCH. I want to be upfront that bip122 can represent BSV: it disambiguates forks by the first post-fork block hash (as it does for Bitcoin Cash, bip122:000000000000000000651ef99cb9fcbe), and a BSV entry could be built the same way from its fork block.

This namespace uses the human-readable network name as the CAIP-2 reference instead, following the casper precedent (a Chain ID that "should not be confused with the genesis_hash"). The reason is that the BSV application layer — BRC-100 wallets, overlay services, ARC broadcasters, SPV clients — universally identifies a network by name, never by fork-block hash. A BRC-100 wallet self-reports via getNetworkmainnet/testnet (and ttn/tstn on Teranode deployments); SV Node's getblockchaininfo.chain returns main/test. Cross-chain tooling (e.g. the x402 payment protocol, CAIP-10/CAIP-19 references) can then map directly onto identifiers applications already exchange without a full-node round-trip. The two schemes can coexist — a hash-based bip122 BSV entry and this name-based one occupy different namespaces.

ttn and tstn are registered up front so high-throughput payment protocols can target Teranode test environments without overloading bsv:testnet or inventing ad-hoc names that later need client migration. Clients MUST NOT treat a genesis-only bip122 identifier as a BSV network — that reference is ambiguous across the BTC/BCH/BSV split.

Resolution mechanics, syntax (bsv:(mainnet|testnet|ttn|tstn)), and test cases are in bsv/caip2.md.

Context

This registration supports adding BSV as a payment mechanism to the x402 protocol, where the design discussion for these identifiers is ongoing. Happy to adjust the reference scheme (including moving to bip122) based on editor guidance.

Author: @sirdeggen (BSV Association).

Registers bsv:mainnet and bsv:testnet, identifying BSV networks by
human-readable network name (mirroring BRC-100 getNetwork and SV Node
getblockchaininfo.chain), following the casper precedent of a Chain ID
distinct from the genesis hash. Rationale acknowledges that bip122 can
represent BSV via its fork-block hash.
Register Teranode Test Net (ttn) and Teranode Scaling Test Net (tstn)
alongside mainnet and testnet so payment tooling can target Teranode
environments without overloading bsv:testnet. Document that bip122
genesis-only identifiers are ambiguous for BSV and must not be used.
@andyrowe

andyrowe commented Aug 7, 2026

Copy link
Copy Markdown

I maintain a live implementation of the x402 exact scheme for BSV payments (bsv.cx), and this namespace gap is a concrete blocker for it.

Today the only CAIP-2 identifier available for BSV is bip122: — but that's ambiguous: BSV shares Satoshi's genesis block with BTC (and BCH), so a bip122: reference alone can't distinguish the three. My implementation currently works around this by pairing the bip122: network id with a non-standard extra.chain: "bsv" field plus asset: "BSV", and refusing to settle a payment whenever a Bitcoin-family network id arrives without that disambiguator. It works, but it's a workaround for a missing standard identifier.

Registering the bsv namespace here (bsv:mainnet / bsv:testnet) would let conforming implementations reference the chain unambiguously and drop the custom disambiguation. Is there anything currently blocking review, or something I could contribute to help it along — extra CAIP-2 profile detail, an implementer reference, test vectors? Happy to help however's useful.

Comment thread bsv/README.md
Comment thread bsv/README.md Outdated

@bumblefudge bumblefudge left a comment

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This seems fine, but I took a glance at BRC-100 and it looks to me like you should probably wrote at least a CAIP-10 profile as well, it looks like BSV breaks a LOT of assumptions people might smuggle over from BTC and/or BCH unless they're warned!

obstropolos and others added 3 commits August 18, 2026 13:21
Co-authored-by: Bumblefudge <bumblefudge@learningproof.xyz>
Co-authored-by: Bumblefudge <bumblefudge@learningproof.xyz>
@obstropolos
obstropolos merged commit 9bac6ac into ChainAgnostic:main Aug 18, 2026
andyrowe pushed a commit to andyrowe/x402-bsv-p2pkh that referenced this pull request Aug 18, 2026
ChainAgnostic/namespaces#190 merged 2026-08-18, registering `bsv:mainnet`,
`bsv:testnet`, `bsv:ttn`, `bsv:tstn`. This was the "PENDING ALIGNMENT" the spec
deferred to; the reference service was swapped to emit `bsv:mainnet` the same day.

- scheme spec §Network identifier: table + prose now `bsv:mainnet`/`bsv:testnet`;
  drop the genesis-hash rationale (no longer how the id is formed); keep the
  ambiguity warning as the reason `bip122` MUST NOT be emitted; readers MAY still
  accept a legacy `bip122:` value.
- BRC draft §5.2 + banner + submission checklist item 5: same alignment; the
  identifier question is resolved, not pending.
- README status: `bsv:` namespace registered, service emits it.
- JSON examples throughout: `bip122:<genesis>` -> `bsv:mainnet`.

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
@Ruthheasman

Copy link
Copy Markdown

The only checks that have run on this PR are labeler and check-verified-commits — the test workflows haven't been triggered, since PRs from forks need a maintainer to approve workflow runs. Could someone approve the run so we can see actual CI status here? Hard to review a 43-file PR that's never been tested.
Also worth noting the CAIP-2 dependency is now cleared — bsv namespace merged in #190.

sirdeggen added a commit to bsv-blockchain/x402 that referenced this pull request Sep 3, 2026
ChainAgnostic/namespaces#190 merged on 2026-08-18. Point the spec,
package README, and network-constant comments at the registered
bsv/caip2.md instead of describing registration as in progress.

Signed-off-by: Deggen <d.kellenschwiler@bsvassociation.org>
@sirdeggen

Copy link
Copy Markdown
Contributor Author

Follow-up for the CAIP-10 request in #190 (review): opened #202 with a BRC-100 identity-key profile (not Bitcoin addresses), including the BTC/BCH assumptions that do not carry over.

@bumblefudge

Copy link
Copy Markdown
Collaborator

Hard to review a 43-file PR that's never been tested.

@Ruthheasman maybe you intended this comment for a different PR?

@Ruthheasman

Ruthheasman commented Sep 8, 2026 via email

Copy link
Copy Markdown

@bumblefudge

Copy link
Copy Markdown
Collaborator

@Ruthheasman this not a 43-file PR and there is no CI to run or any code to test?!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

5 participants