Create a transaction to delegate Onyx Governance voting rights to an address.

  • _address (string) The address in which to delegate voting rights to.

  • [options] (CallOptions) Options to set for eth_call, optional ABI (as JSON object), and Ethers.js method overrides. The ABI can be a string of the single intended method, an array of many methods, or a JSON object of the ABI generated by a Solidity compiler.

  • RETURN (object) Returns an Ethers.js transaction object of the vote transaction.

const onyx = new Onyx(window.ethereum);

(async function() {
  const delegateTx = await onyx.delegate('0xa0df350d2637096571F7A701CBc1C5fdE30dF76A');
  console.log('Ethers.js transaction object', delegateTx);

Last updated