Skip to content

Feat/add stellar bridge controller#8625

Open
Julink-eth wants to merge 9 commits into
mainfrom
feat/add-stellar-bridge-controller
Open

Feat/add stellar bridge controller#8625
Julink-eth wants to merge 9 commits into
mainfrom
feat/add-stellar-bridge-controller

Conversation

@Julink-eth
Copy link
Copy Markdown
Contributor

@Julink-eth Julink-eth commented Apr 29, 2026

Explanation

Adds Stellar support to @metamask/bridge-controller, following the existing non-EVM patterns for Solana, Bitcoin, and Tron. This includes Stellar chain/native asset constants, CAIP formatting, default token metadata, quote validation, non-EVM fee handling via snap computeFee, and targeted test coverage.
Also aligns Stellar asset formatting with the Bridge API contract:

  • Native XLM: stellar:pubnet/slip44:148
  • Classic assets: stellar:pubnet/asset:CODE-ISSUER
  • Soroban contracts: stellar:pubnet/sep41:C...

References

Checklist

  • I've updated the test suite for new or updated code as appropriate
  • I've updated documentation (JSDoc, Markdown, etc.) for new or updated code as appropriate
  • I've communicated my changes to consumers by updating changelogs for packages I've changed
  • I've introduced breaking changes in this PR and have prepared draft pull requests for clients and consumer packages to resolve them

Note

Medium Risk
Adds a new non-EVM chain path (Stellar) across chain-id/asset formatting, validation, and snap-based fee computation; regressions could impact quote requests or fee display for non-EVM chains. Changes are mostly additive with tests, limiting blast radius but touching shared chain-id utilities.

Overview
Adds Stellar network support to @metamask/bridge-controller, including a new ChainId.STELLAR, XlmScope.Pubnet being treated as an allowed bridge chain, and default native token metadata for XLM (decimals/slip44 mapping).

Extends shared utilities to recognize Stellar via isStellarChainId, treat it as non-EVM in isNonEvmChainId, and format Stellar chain IDs/asset IDs in caip-formatters (native stellar:pubnet/slip44:148, classic asset:CODE-ISSUER, and Soroban sep41:C…).

Updates quote request validation to require destWalletAddress when bridging to/from Stellar, exports isStellarChainId, and adds targeted tests (including verifying Stellar quotes get nonEvmFeesInNative via snap computeFee calls).

Reviewed by Cursor Bugbot for commit d8f0ece. Bugbot is set up for automated code reviews on this repo. Configure here.

@Julink-eth Julink-eth requested review from a team as code owners April 29, 2026 07:00
Copy link
Copy Markdown

@cursor cursor Bot left a comment

Choose a reason for hiding this comment

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

Cursor Bugbot has reviewed your changes and found 1 potential issue.

Fix All in Cursor

❌ Bugbot Autofix is OFF. To automatically fix reported issues with cloud agents, have a team admin enable autofix in the Cursor dashboard.

Reviewed by Cursor Bugbot for commit 0b037a5. Configure here.

Comment thread packages/bridge-controller/CHANGELOG.md Outdated
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.

1 participant