LogoLogo
  • Envelop (NIFTSY) documentation
  • Documents
    • Key terms
    • F.A.Q.
    • White paper
      • Disclaimers
      • Introduction
      • Key terms
      • Industry (market) analysis and NIFTSY's place in it
        • Figures and facts
        • Possible implementations of Envelop
      • Protocol. Oracle. Index
        • Protocol
          • NFT as a new order ETF and a brief history of NIFTSY
        • Oracle
        • Index
      • The architecture of the Project and the role of the Token
        • DAO. Token. IDO
        • The token as a linking element in the project
        • IDO (Initial DAO offering)
      • Roadmap. Part. #01
      • Roadmap. Part #02
      • Conclusion
      • List of references
    • Lite paper
      • Abstract
      • Disclaimers
      • Market challenges - our solutions
      • The main hypostases and parts of the Project
      • Development strategy and market coverage
      • Additions
    • White paper (Spanish)
      • Descargo de responsabilidad
      • Introducción
      • Términos clave
      • Análisis de la industria (mercado) y el lugar de NIFTSY en el
        • Figuras y hechos
        • Posibles implementaciones de NIFTSY
      • Protocolo. Oráculo. Índice
        • Protocolo
        • NFTs como un nuevo de EFT y una breve historia de NIFTS
        • Oraculo
        • Índice
        • Untitled
      • La arquitectura del proyecto y el rol del token
        • DAO. Token. IDO
        • El token como un elemento vinculante en el proyecto
        • IDO
      • Mapa de ruta
      • Conclusiones
      • Lista de referencias
    • Lite paper (Spanish)
      • Abstracto
      • Descargo de responsabilidad
      • Los desafíos del mercado y nuestras soluciones
      • La hipótesis principal y partes del proyecto
      • Estrategia de desarrollo y cobertura de mercado
      • Adiciones
    • White paper (BAHASA INDONESIA)
      • PENAFIAN
      • PENGANTAR
      • ​KATA KUNCI
      • ANALISIS INDUSTRI (PASAR)) DAN KEDUDUKAN niftsy DI DALAMNYA
      • Angka dan Fakta
      • Kemungkinan implementasi NIFTSY
      • PROTOKOL. ORACLE. INDEKS
        • Protokol
        • Oracle
        • Indeks
      • ARSITEKTUR PROYEK DAN PERAN TOKEN
      • DAO. Token. IDO
      • Token sebagai elemen penghubung dalam proyek
      • IDO
      • ROADMAP
      • KESIMPULAN
      • DAFTAR REFERENSI
    • LITE PAPER (BAHASA INDONESIA)
      • Abstrak
      • Penafian
      • Tantangan pasar - solusi kami
      • Hipotesis utama dan bagian dari Proyek
      • Strategi pengembangan dan cakupan pasar
      • Tambahan
    • Tokenomics
      • General provisions
      • Links
  • Technical documentation
    • URLs of dAPPs
    • Technical paper
      • Introduction
      • Protocol
      • Oracle
      • Index
      • Stack
      • Conclusion
    • Smart-contracts
      • Deployment addresses v2
      • Deployment addresses v1
      • Deployment addresses v0
      • Security and smart contracts
      • Contract NiftsyERC20.sol
      • Protocol
        • V0
          • Audit
          • Contracts
            • WrapperWithERC20Collateral (V.0)
            • WrapperDistributor721.sol
            • WrapperFarming.sol
        • V1
          • Audit
          • Contracts
            • WrapperV1
            • AdvancedWhiteList.sol
            • EnvelopwNFT721
            • EnvelopwNFT1155
            • Saft
            • SBT smart-contract Factory
          • Gas measurements for Protocol version 1
      • Launchpad
        • V0
          • Launchpad.sol
        • V1
          • NFTKiosk.sol
          • DefaultPriceModel.sol
      • Subscription service
      • Factory (smart-contracts) minting
      • P2P NFT/wNFT trading service
    • Envelop dApps Troubleshooting
  • Tutorials
    • Introduction to tutorials
    • dApps
      • Minting
        • Version 0
          • Release notes
          • Instruction
          • Video
        • Version 1.1
          • Release notes
          • Instruction
          • Video
      • Main app
        • Version 0
          • Release notes
          • Instruction
          • Aptos instruction
          • Video
        • Version 1.0
          • Release notes
          • Instruction
        • Version 1.1
          • Release notes
          • Instruction
          • Video
      • Cross-NFT
        • Version 0
          • Release notes
          • Instruction
          • Video
      • Launchpad (wINO)
        • Version 0
          • Release notes
          • Instruction
          • Video
        • Version 1
          • Release notes
          • Instruction
            • NFT trading
            • ERC20 tokens trading
          • Video
      • Farming
        • Version 0
          • Release notes
          • Instruction
      • SAFT wNFT
        • Version 0
          • Release notices
          • Instruction
          • Video
        • Version 1.0
          • Release notices
          • Insctruction
          • Video
        • Version 1.1
          • Release notices
          • Insctruction
          • Video
    • Oracle
      • Version 0
        • Release notices
      • Version 1
        • Release notices
    • Subscription service
      • Version 0
        • Release notes
      • Version 1
        • Release notes
    • Metamask settings for different networks
    • How to wrap your NFT
    • How to make SAFT wNFT
    • How to unwrap your wNFT
    • How to mint Soulbound tokens with Envelop
    • How to use Wrapper from Safe Gnosis
    • Video tutorials
  • Bounty
    • Bounty FAQ
    • General conditions
    • Bounty rules
    • Approximate (maximum) activity estimates
    • Bug Bounty
  • Legal
    • Privacy-policy
    • Legal FAQ
    • DAO
    • Archive
      • Licence
  • ARHIVE
    • Archive tutorials
      • Wrap NFT
    • Others
      • Marketplace (Scotch.sale)
      • How do I buy on DEXs?
        • Uniswap
        • PancakeSwap
        • QuickSwap
Powered by GitBook
LogoLogo

Links:

  • envelop.is
  • daoenvelop.eth

dApps:

  • app.envelop.is
  • crossing

Soc. nets:

  • blog
  • youtube
On this page
  • Method wnftInfo
  • Method URI
  • Method safeTransferFrom

Was this helpful?

  1. Technical documentation
  2. Smart-contracts
  3. Protocol
  4. V1
  5. Contracts

EnvelopwNFT1155

PreviousEnvelopwNFT721NextSaft

Last updated 1 year ago

Was this helpful?

This contract is based on the classic ERC-1155 standard token contract. A detailed description of the methods of the standard can be found in the documentation (). The contract is used for minting, burning and wNFT ERC-1155 transfers that the WrapperBaseV1 protocol contract creates for users.

The mint, burn methods are defined in the EnvelopwNFT1155 contract, taking into account the logic of the protocol.

The mint, burn method can only call the WrapperBaseV1 contract. No other address can call these methods.

Method wnftInfo

function wnftInfo(uint256 tokenId) external view returns (ETypes.WNFT memory)

The method returns all data about wNFT.

Input method call parameters:

Name
Type
Description

_tokenId

uint256

tokenId wrap NFT

A description of the returned data types can be found in the LibEnvelopTypes.sol contact, ETypes library.

Returned values:

Name
Type
Description

value

ETypes.WNFT

wNFT data

ETypes.WNFT

Name
Type
Description

inAsset

ETypes.AssetItem

Data on the original NFT

collateral

ETypes.AssetItem[]

Data on collateral

unWrapDestination

address

Recipient address of the original NFT and collateral after unwrap of wNFT - filled by default with a null address

fees

ETypes.Fee[]

Array of information on transfer fees

locks

ETypes.Lock[]

Array of information on unwrap conditions (blocking by time, by amount of commission collected, etc...)

royalties

ETypes.Royalty[]

An array of information on royalty beneficiaries

rules

bytes2

wNFT rules of conduct (e.g. 1111, where right to left:

pos1 - prohibition to unwrap

pos2 - prohibition to wrap wNFT

pos3 - prohibition to transfer (send) wNFT

pos4 - prohibition to add something to collateral)

ETypes.AssetItem

Name
Type
Description

asset

ETypes.Asset

Data on the type and contract of tokens transferred to the WrapperBaseV1 contract for wrapped NFT or added to collateral of wrapped NFT

tokenId

uint256

Token number

(if a empty was wrapped

it will return 0;

if the collateral was topped up with ERC-20 tokens, it will return 0;

if the collateral was topped up with native tokens, it will return 0).

amount

amount

Number of NFT copies or number of tokens( for ERC-1155 - a value other than 0, for ERC-20 - value other than 0

for native tokens - value other than 0

for ERC-721 - 0)

ETypes.Asset

Name
Type
Description

assetType

contractAddress

Value from the token type dictionary

contractAddress

address

Address of token contract transferred to WrapperBaseV1 protocol contract as security or original NFT

ETypes.AssetType:

  • 0 - empty;

  • 1 - native token (coin);

  • 2 - ERC-20;

  • 3 - ERC-1155;

  • 4 - ERC-1155.

ETypes.Fee

Name
Type
Description

feeType

bytes1

Fee type - 0

param

uint256

Fee amount

token

address

Transfer fee token contract address

ETypes.Lock

Name
Type
Description

lockType

bytes1

Blocking type:

0x00 - blocking by time

0x01 - blocking by volume of accumulated transfer fee for wNFT 0x02 - count of max collateral slots for wNFT

param

uint256

Value

ETypes.Royalty

Name
Type
Description

beneficiary

address

Royalty beneficiary address

percent

uint16

Value - no more than 10000 (100%)

Method URI

function uri(uint256 _tokenID) public view override 
        returns (string memory _uri) 

Method returns reference to metadata of original NFT for wNFT. If empty, the metadata generated by the EnvelopwNFT1155 contract will be returned.

Input method call parameters:

Name
Type
Description

_tokenId

uint256

tokenId wNFT

Returned values:

Name
Type
Description

uri_

string

Link to metadata

Method safeTransferFrom

When a transfer is made, the transfer fee is calculated if the creator of wNFT has made the appropriate settings for it. The fee is held in ERC-20 tokens whose smart-contract address the wNFT creator has specified when he wrapped. The fee can be allocated to royalty beneficiaries, or part or all of the fee can be added to wNFT's Collateral.

The method does not return anything.

Input method call parameters:

Name
Type
Description

from

address

Address from which wNFT is being transferred

to

address

The address to which the wNFT is transferred

id

uint256

tokenId wNFT

amount

uint256

Number of copies-amount to be transferred from address to

data

bytes

Data

The method works based is based on the ERC-1155 method. Link to documentation ().

https://docs.openzeppelin.com/contracts/4.x/api/token/erc1155
https://docs.openzeppelin.com/contracts/4.x/api/token/erc1155#IERC1155-safeTransferFrom-address-address-uint256-uint256-bytes-