Socket
Socket
Sign inDemoInstall

wearable-contracts

Package Overview
Dependencies
0
Maintainers
1
Versions
7
Alerts
File Explorer

Advanced tools

Install Socket

Detect and block malicious and high-risk dependencies

Install

    wearable-contracts

Decentraland wereable contracts


Version published
Weekly downloads
7
increased by16.67%
Maintainers
1
Install size
872 kB
Created
Weekly downloads
 

Readme

Source

Set Up a Factory

A factory contract is used to sell wearables at OpenSea. The interface is defined here.

Every optionId is the index of a wearableId in the wearables array of an ERC721Collection

ERC721CollectionFactory.sol

function _wearableByOptionId(uint256 _optionId) internal view returns (string memory){
    /* solium-disable-next-line */
    (bool success, bytes memory data) = address(erc721Collection).staticcall(
        abi.encodeWithSelector(
            erc721Collection.wearables.selector,
            _optionId
        )
    );

    require(success, "Invalid wearable");
    return abi.decode(data, (string));
}

OpenSea uses the Wyvern Protocol https://docs.opensea.io/docs/opensea-partners-program. Only one address will be allowed to create option orders. A proxy to this address will be created once the address first interacts with OpenSea.

The contracts for the ProxyRegistry can be seen here. Calling proxies on the Mainnet contract, the user can check if a proxy address was created for her address.

FAQs

Last updated on 07 Apr 2020

Did you know?

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc