async function fundAccount (deployer, accounts) {
  const master = deployer.accountsByName.get('master-account');
  const params = [];
  if (!(accounts instanceof Array)) {
    accounts = [accounts];
  }
  for (const a of accounts) {
    console.log(`* Funding Account: ${a.name} *`);
    params.push({
      type: types.TransactionType.TransferAlgo,
      sign: types.SignType.SecretKey,
      fromAccount: master,
      toAccountAddr: a.addr,
      amountMicroAlgos: 20e6,
      payFlags: { totalFee: 1000, note: 'funding account' }
    });
  }

  try {
    await executeTransaction(deployer, params);
  } catch (e) {
    console.error('Transaction Failed', e.response ? e.response.error.text : e);
  }
}
/**
 * Fund accounts from master with 20 Algos
 * @param {*} deployer algobDeployer
 * @param {*} accounts account or list of accounts to fund
 */
Fund accounts from master with 20 Algos
@param {*} deployer algobDeployer
@param {*} accounts account or list of accounts to fund
Fund accounts from master with 20 Algos @param { * } deployer algobDeployer @param { * } accounts account or list of accounts to fund
async function fundAccount (deployer, accounts) {
  const master = deployer.accountsByName.get('master-account');
  const params = [];
  if (!(accounts instanceof Array)) {
    accounts = [accounts];
  }
  for (const a of accounts) {
    console.log(`* Funding Account: ${a.name} *`);
    params.push({
      type: types.TransactionType.TransferAlgo,
      sign: types.SignType.SecretKey,
      fromAccount: master,
      toAccountAddr: a.addr,
      amountMicroAlgos: 20e6,
      payFlags: { totalFee: 1000, note: 'funding account' }
    });
  }
  try {
    await executeTransaction(deployer, params);
  } catch (e) {
    console.error('Transaction Failed', e.response ? e.response.error.text : e);
  }
}
async function fundAccount ( deployer , accounts ) { const master = deployer . accountsByName . get ( 'master-account' ) ; const params = [ ] ; if ( ! ( accounts instanceof Array ) ) { accounts = [ accounts ] ; } for ( const a of accounts ) { console . log ( ` ${ a . name } ` ) ; params . push ( { type : types . TransactionType . TransferAlgo , sign : types . SignType . SecretKey , fromAccount : master , toAccountAddr : a . addr , amountMicroAlgos : 20e6 , payFlags : { totalFee : 1000 , note : 'funding account' } } ) ; } try { await executeTransaction ( deployer , params ) ; } catch ( e ) { console . error ( 'Transaction Failed' , e . response ? e . response . error . text : e ) ; } }
Fund accounts from master with 20 Algos
 @param {*} deployer algobDeployer
 @param {*} accounts account or list of accounts to fund
Fund accounts from master with 20 Algos @param { * } deployer algobDeployer @param { * } accounts account or list of accounts to fund