# ⚠️ multiMint(contract, sender, receivers, uri, hash, currency, creator)

<table data-header-hidden><thead><tr><th width="148.5"></th><th></th></tr></thead><tbody><tr><td>Feature</td><td>Mint multiple NFTs at once.<br><mark style="color:red;"><strong>Notes: Sender must be the owner of the contract or a white-listed account. The creator address must be deployed on the Mitum network.</strong></mark></td></tr><tr><td>Parameters</td><td><p><code>string</code> | <code>string[]</code> contract address, // If given a string, it is automatically converted to an array filled with the same values. </p><p><code>string</code> sender, </p><p><code>string[]</code> receivers, // Address to which each nft will be sent </p><p><code>string[]</code> uri, </p><p><code>string[]</code> hash, </p><p><code>string</code> currencyID, </p><p><code>string</code> creator,</p></td></tr><tr><td>Return Value</td><td><code>object</code>mint operation with multiple item</td></tr></tbody></table>

* uri: The array of path where the NFT file is physically stored, or where the metadata is stored.
* hash: The array of hash value of the NFT file.
* creator: The address of a creator or copyright holder of the NFT.

example1. mint 2 nfts on one CA(`0x41…`) and sent each nfts to account(`0xB8…`) and account(`0x07…`)

```javascript
const contractAddress = "0x41EFb6902ADcb1214a7123b01af66b1D13b89864fca";
const sender = "0x4874C17C354c498cf44D2946612DBe47fBcE7E87fca";
const recievers = ["0xB8dE7113DE470Ab89304A954939126FA97a812dcfca", "0x07469989b2562afF5E5C3B116CD3AA5Ef814e5a1fca"]
const uri = "www.abcd_efgh.com";
const hash = "381yXYxtWCavzPxeUXRewT412gbLt2hx7VanKazkBrsnyfPPBdXfoG52Yb2wkF8vC3KJyoWgETpsN6k97mQ8tUXr1CmTedcj";
const currencyID = "MCC";
const creator = "0x78f707a5CB15924b5edf7E45cD8df06b577984F7fca";

const mintOperation = mitum.nft.multiMint(contractAddress, sender, recievers, [uri, uri], [hash, hash], currencyID, creator);
console.log(mintOperation);

// output
Operation {
  id: 'mitum',
  fact: MintFact {
    hint: Hint { s: 'mitum-nft-mint-operation-fact' },
    token: Token { s: '2024-07-31 04:27:04.814 +0000 UTC' },
    _hash: <Buffer ca 18 74 55 7f e0 9b 7c 01 b2 4f be 8b 90 7e 3e c0 34 e5 bd 6d 64 17 28 75 c7 94 f3 6d 0b 4a 0c>,
    sender: Address {
      s: '0x4874C17C354c498cf44D2946612DBe47fBcE7E87fca',
      type: 'mitum'
    },
    items: [ [MintItem], [MintItem] ]
  },
  hint: Hint { s: 'mitum-nft-mint-operation' },
  _factSigns: [],
  _hash: <Buffer >
}
```

example2. mint 1 nft on the each CAs (`0x41…`, `0x2F…`) sent each nfts to account(`0xB8…`) and account(`0x07…`)

```javascript
const contract_array = ["0x41EFb6902ADcb1214a7123b01af66b1D13b89864fca", "0x2F45f1AD55E809629F36BDb0677C61c82539D258fca"];
const sender = "0x4874C17C354c498cf44D2946612DBe47fBcE7E87fca";
const recievers = ["0xB8dE7113DE470Ab89304A954939126FA97a812dcfca", "0x07469989b2562afF5E5C3B116CD3AA5Ef814e5a1fca"]
const uri = "www.abcd_efgh.com";
const hash = "381yXYxtWCavzPxeUXRewT412gbLt2hx7VanKazkBrsnyfPPBdXfoG52Yb2wkF8vC3KJyoWgETpsN6k97mQ8tUXr1CmTedcj";
const currencyID = "MCC";
const creator = "0x78f707a5CB15924b5edf7E45cD8df06b577984F7fca";

const mintOperation = mitum.nft.multiMint(contract_array, sender, recievers, [uri, uri], [hash, hash], currencyID, creator);
console.log(mintOperation);

// output
Operation {
  id: 'mitum',
  fact: MintFact {
    hint: Hint { s: 'mitum-nft-mint-operation-fact' },
    token: Token { s: '2025-01-14 02:38:02.737 +0000 UTC' },
    _hash: <Buffer d1 9e 61 d5 02 7e b3 a1 51 9e 93 c1 cf 6b d8 74 c3 d8 18 20 07 82 d2 02 50 4f ba a1 a8 13 40 e1>,
    sender: Address {
      s: '0x4874C17C354c498cf44D2946612DBe47fBcE7E87fca',
      type: 'mitum'
    },
    items: [ [MintItem], [MintItem] ]
  },
  hint: Hint { s: 'mitum-nft-mint-operation' },
  _factSigns: [],
  _hash: <Buffer >
}
```
