Skip to content

@gala-chain/testAPI


API > mintTokensToUsers

Function: mintTokensToUsers()

mintTokensToUsers(client, nftClassKey, users): Promise\<void>

Complete workflow to mint tokens to multiple users.

Performs the full token minting process: creates token class, grants minting allowances, and mints tokens to each specified user.

Parameters

client: ChainClient & ChainUserAPI

Chain client with user API capabilities

nftClassKey: TokenClassKey

Token class identifier

users: object[]

Array of users and quantities to mint

Returns

Example

await mintTokensToUsers(client, nftClassKey, [
  { user: user1, quantity: new BigNumber(1) },
  { user: user2, quantity: new BigNumber(2) }
]);

Source

chain-test/src/e2e/tokenOps.ts:75