Deploy NFT
Construct a transfer to Layer 2 broker and trigger deployment of tokenAddress in Layer 1
Congratulations! You have successfully deployed your Counterfactual NFT!
Last updated
Was this helpful?
Construct a transfer to Layer 2 broker and trigger deployment of tokenAddress in Layer 1
Congratulations! You have successfully deployed your Counterfactual NFT!
Last updated
Was this helpful?
Was this helpful?
const transfer = {
exchange: LOOPRING_EXPORTED_ACCOUNT.exchangeAddress,
payerAddr: LOOPRING_EXPORTED_ACCOUNT.address,
payerId: LOOPRING_EXPORTED_ACCOUNT.accountId,
payeeAddr: broker,
// payeeAddr: LOOPRING_EXPORTED_ACCOUNT.address2,
storageId: storageId.offchainId,
token: {
tokenId: TOKEN_INFO.tokenMap["LRC"].tokenId,
volume: fee.fees["LRC"].fee ?? "9400000000000000000",
},
validUntil: LOOPRING_EXPORTED_ACCOUNT.validUntil,
};
const response = await LoopringAPI.userAPI.submitDeployNFT({
request: {
transfer,
tokenAddress: LOOPRING_EXPORTED_ACCOUNT.nftTokenAddress,
nftData: LOOPRING_EXPORTED_ACCOUNT.nftData,
},
web3,
chainId: sdk.ChainId.GOERLI,
walletType: sdk.ConnectorNames.Unknown,
eddsaKey: eddsaKey.sk,
apiKey: apiKey,
});
console.log(response);