Skip to content

Commit

Permalink
[gms-1505] readme for erc1155 preset
Browse files Browse the repository at this point in the history
  • Loading branch information
jasonzwli committed Mar 7, 2024
1 parent 9d34bf4 commit 15f8dba
Showing 1 changed file with 22 additions and 0 deletions.
22 changes: 22 additions & 0 deletions contracts/token/erc1155/README.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,22 @@
# ERC1155 contracts

The ImmutableERC1155 contracts allows clients to mint multiple different tokens with different token ids within the same collection. The contract features methods to allow for minting multiples of multiple token ids to simplify the minting flow and reduce gas costs. This contract is built on top of the [Openzeppelin implemention of EIP-1155](https://github.com/OpenZeppelin/openzeppelin-contracts/blob/master/contracts/token/ERC1155/ERC1155.sol).

[Read more On the Threat Model](../../../audits/202312-threat-model-preset-erc1155.md)
[Read more On the EIP](https://eips.ethereum.org/EIPS/eip-1155)

## preset/draft-ImmutableERC1155

The draft-ImmutableERC1155 contract is the pre-release version of the Immutable's preset 1155 contract. It has been internally audited and is ready to be tested. Please note it is not yet supported by the rest of the Immutable ecosystem. The contract contains all external facing interfaces that are needed to interact(read and write) with deployed ERC1155 collections.

## abstract/ERC1155Permit

This is an abstract contract that is used as an ancestor to the preset 1155. It contains the permit feature for the preset, allowing token owners to give approval and permission to a secure and trusted actor. This action is gasless for the token owner but will require gas from the approved operator. Please note that using permits in an ERC1155 collections exposes all the tokens owned by an address to the approved operator. Please double check to make sure the operator is secure and trusted.

## abstract/IERC1155Permit

Provides the required interface for ERC1155Permit.

## abstract/ImmutableERC1155Base

This is another abstract contract used as an ancestor to the preset 1155. It implements many of the internal methods for the preset that are not directly public facing for everyday uses. It contains functionalities to update royalties, set URIs and manage collection roles.

0 comments on commit 15f8dba

Please sign in to comment.