Hord Congress

Represents multi-sig wallet for HORD app.

Code

HordCongress.sol

Address

HordCongress is deployed at 0x086A6d9FD61758096CF4F394AE7C1F9B6b4EEC14 on the Ethereum mainnet.

Overview

Standard implementation of the multisignature wallet. This contract contains the initial total supply of HORD tokens.

Events

ProposalCreated

event ProposalCreated(uint id, address proposer, address[] targets, uint[] values, string[] signatures, bytes[] calldatas, string description);
  • Emitted each time when a new proposal is created.

VoteCast

event VoteCast(address voter, uint proposalId, bool support);
  • Emitted each time when a vote has been cast on a proposal.

ProposalCanceled

event ProposalCanceled(uint id);
  • Emitted each time when a proposal has been canceled.

ProposalExecuted

event ProposalExecuted(uint id);
  • Emitted each time when a proposal has been executed.

ReceivedEther

event ReceivedEther(address sender, uint amount);
  • Emitted each time when ether is received.

ExecuteTransaction

event ExecuteTransaction(address indexed target, uint value, string signature,  bytes data);
  • Emitted each time when transaction is executed.

Read-Only Functions

name

function name() external view returns (string memory);
  • Returns the name of the contract. [HordCongress]

proposalCount

function proposalCount() external view returns (uint);
  • Returns the total number of proposals.

proposals

function proposals(uint256 proposalId) external view returns (Proposal memory);
  • Returns official record of all proposals ever proposed.

getActions

function getActions(uint proposalId) external view returns (address[] memory targets, uint[] memory values, string[] memory signatures, bytes[] memory calldatas);
  • Returns all actions from exact proposal.

getMembersRegistry

function getMembersRegistry()external view returns (address);
  • Returns the address of HordCongressMembersRegistry contract.

State-Changing Functions

setMembersRegistry

function setMembersRegistry(address _membersRegistry) external;
  • One time call function to set address of HordCongressMembersRegistry contract.

propose

function propose(address[] memory targets, uint[] memory values, string[] memory signatures, bytes[] memory calldatas, string memory description) external onlyMember returns (uint);
  • Only a member of HordCongress can call this function in order to create a proposal for which members will vote and based on the votes the proposal will be executed or rejected.

  • Returns id of new proposal.

  • Emits a ProposalCreated event.

castVote

function castVote(uint proposalId, bool support) external onlyMember;
  • Only a member of HordCongress can call this function in order to vote on a specific proposal.

  • Emits a VoteCast event.

execute

function execute(uint proposalId) external onlyMember payable;
  • Only a member of HordCongress can call this function in order to execute a specific proposal which reached the minimal quorum (50% or more of the votes are in favor).

  • Emits a ExecuteTransaction and ProposalExecuted events.

cancel

function cancel(uint proposalId) external onlyMember;
  • Only a member of HordCongress can call this function in order to cancel a specific proposal which didn`t reach the minimal quorum (less than 50% of votes are in favor).

  • Emits a ProposalCanceled event .

Last updated