Skip to content

Conversation

@rohitsaw115
Copy link
Contributor

@rohitsaw115 rohitsaw115 commented Dec 8, 2025

ticket: win-8154

Changes:-

  • Optimization for erc721 token standard.
  • With new changes, only feature flag is required to support erc721 standard for new coins.
  • erc721 token test token.

@rohitsaw115 rohitsaw115 force-pushed the erc721 branch 2 times, most recently from 7dbdff9 to 3b2cdbc Compare December 8, 2025 07:16
ArunBala-Bitgo
ArunBala-Bitgo previously approved these changes Dec 8, 2025
Copy link
Contributor

@ArunBala-Bitgo ArunBala-Bitgo left a comment

Choose a reason for hiding this comment

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

Could we add test cov for the new changes

Copy link

Copilot AI left a comment

Choose a reason for hiding this comment

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

Pull request overview

This PR adds ERC721 (NFT) token support for EVM-compatible coins, specifically enabling it for Hedera EVM (both mainnet and testnet). The implementation follows the existing ERC20 token pattern and introduces the necessary infrastructure to support NFTs across EVM chains.

Key Changes:

  • Added SUPPORTS_ERC721 coin feature and ERC721 underlying asset type
  • Implemented EthLikeERC721Token class and factory function with non-divisible token support (0 decimal places)
  • Registered ERC721 token constructors and configured token mappings for supported chains
  • Fixed Hedera EVM base unit from HBAR (tinybar) to ETH (wei) to align with EVM standards

Reviewed changes

Copilot reviewed 11 out of 11 changed files in this pull request and generated 3 comments.

Show a summary per file
File Description
modules/statics/src/base.ts Added SUPPORTS_ERC721 coin feature enum value
modules/statics/src/account.ts Added EthLikeERC721Token class, Erc721ConstructorOptions interface, and erc721Token factory function with proper documentation
modules/statics/src/tokenConfig.ts Added ERC721 token configuration functions and integration into token map structure
modules/statics/src/coins.ts Added ERC721 chain-to-name mapping and token creation logic in createToken function
modules/statics/src/allCoinsAndTokens.ts Enabled SUPPORTS_ERC721 feature for Hedera EVM (mainnet and testnet) and corrected base unit from HBAR to ETH
modules/sdk-coin-evm/src/ethLikeErc721Token.ts Implemented EthLikeErc721Token class extending EthLikeToken with ERC721-specific functionality
modules/sdk-coin-evm/src/register.ts Added ERC721 token constructor registration for EVM SDK
modules/sdk-coin-evm/src/index.ts Exported EthLikeErc721Token class
modules/bitgo/src/v2/coinFactory.ts Added ERC721 token registration, testnet/mainnet mapping, and token constructor logic
modules/bitgo/src/v2/coins/index.ts Exported EthLikeErc721Token for use in BitGo SDK
modules/bitgo/test/browser/browser.spec.ts Updated test exclusions to include EthLikeErc721Token

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Copy link

Copilot AI left a comment

Choose a reason for hiding this comment

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

Copilot encountered an error and was unable to review this pull request. You can try again by re-requesting a review.

@rohitsaw115 rohitsaw115 force-pushed the erc721 branch 10 times, most recently from 7f71c74 to c58e5ee Compare December 9, 2025 08:08
@rohitsaw115 rohitsaw115 force-pushed the erc721 branch 4 times, most recently from eaebcde to 86f67bc Compare December 10, 2025 07:04
Copy link
Contributor

@ArunBala-Bitgo ArunBala-Bitgo left a comment

Choose a reason for hiding this comment

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

Looks good to me, Please make sure that the test token onboarded works in lower environments before releasing in prod

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.

3 participants