⬅️ Contracts

FeiDAO

Mainnet implementations

Name Address
feiDAO 0x0BEF27FEB58e857046d630B2c03dFb7bae567494
tribeRariDAO 0x637deEED4e4deb1D222650bD4B64192abf002c00

FeiDAOTimelock, Tribe, Timelock

Events

ProposalCanceled

event ProposalCanceled(uint256)
Params
Param Type Notes
proposalId uint256

ProposalCreated

event ProposalCreated(uint256,address,address[],uint256[],string[],bytes[],uint256,uint256,string)
Params
Param Type Notes
proposalId uint256
proposer address
targets address[]
values uint256[]
signatures string[]
calldatas bytes[]
startBlock uint256
endBlock uint256
description string

ProposalExecuted

event ProposalExecuted(uint256)
Params
Param Type Notes
proposalId uint256

ProposalQueued

event ProposalQueued(uint256,uint256)
Params
Param Type Notes
proposalId uint256
eta uint256

ProposalThresholdUpdated

event ProposalThresholdUpdated(uint256,uint256)
Params
Param Type Notes
oldProposalThreshold uint256
newProposalThreshold uint256

QuorumUpdated

event QuorumUpdated(uint256,uint256)
Params
Param Type Notes
oldQuorum uint256
newQuorum uint256

Rollback

event Rollback()

RollbackQueued

event RollbackQueued(uint256)
Params
Param Type Notes
eta uint256

TimelockChange

event TimelockChange(address,address)
Params
Param Type Notes
oldTimelock address
newTimelock address

VoteCast

event VoteCast(address,uint256,uint8,uint256,string)
Params
Param Type Notes
voter address indexed
proposalId uint256
support uint8
weight uint256
reason string

VotingDelayUpdated

event VotingDelayUpdated(uint256,uint256)
Params
Param Type Notes
oldVotingDelay uint256
newVotingDelay uint256

VotingPeriodUpdated

event VotingPeriodUpdated(uint256,uint256)
Params
Param Type Notes
oldVotingPeriod uint256
newVotingPeriod uint256

Methods

BACKUP_GOVERNOR

function BACKUP_GOVERNOR() view returns(address)
Returns
Param Type Notes
address

BALLOT_TYPEHASH

function BALLOT_TYPEHASH() view returns(bytes32)
Returns
Param Type Notes
bytes32

COUNTING_MODE

function COUNTING_MODE() pure returns(string)

module:voting

A description of the possible support values for {castVote} and the way these votes are counted, meant to be consumed by UIs to show correct vote options and interpret the results. The string is a URL-encoded sequence of key-value pairs that each describe one aspect, for example support=bravo&quorum=for,abstain. There are 2 standard keys: support and quorum. - support=bravo refers to the vote options 0 = Against, 1 = For, 2 = Abstain, as in GovernorBravo. - quorum=bravo means that only For votes are counted towards quorum. - quorum=for,abstain means that both For and Abstain votes are counted towards quorum. NOTE: The string can be decoded by the standard https://developer.mozilla.org/en-US/docs/Web/API/URLSearchParams[URLSearchParams] JavaScript class.

Returns
Param Type Notes
string

ROLLBACK_DEADLINE

function ROLLBACK_DEADLINE() view returns(uint256)
Returns
Param Type Notes
uint256

__acceptAdmin

function __acceptAdmin() nonpayable

Accept admin right over the timelock.

__executeRollback

function __executeRollback() nonpayable

complete the rollback

__rollback

function __rollback(uint256) nonpayable

one-time option to roll back the DAO to old GovernorAlpha

guardian-only, and expires after the deadline. This function is here as a fallback in case something goes wrong.

Params
Param Type Notes
eta uint256

cancel

function cancel(uint256) nonpayable

Cancels a proposal only if sender is the proposer, or proposer delegates dropped below proposal threshold.

Params
Param Type Notes
proposalId uint256

castVote

function castVote(uint256,uint8) nonpayable returns(uint256)

See {IGovernor-castVote}.

Params
Param Type Notes
proposalId uint256
support uint8
Returns
Param Type Notes
uint256

castVoteBySig

function castVoteBySig(uint256,uint8,uint8,bytes32,bytes32) nonpayable returns(uint256)

See {IGovernor-castVoteBySig}.

Params
Param Type Notes
proposalId uint256
support uint8
v uint8
r bytes32
s bytes32
Returns
Param Type Notes
uint256

castVoteWithReason

function castVoteWithReason(uint256,uint8,string) nonpayable returns(uint256)

See {IGovernor-castVoteWithReason}.

Params
Param Type Notes
proposalId uint256
support uint8
reason string
Returns
Param Type Notes
uint256

execute

function execute(address[],uint256[],bytes[],bytes32) payable returns(uint256)

See {IGovernor-execute}.

Params
Param Type Notes
targets address[]
values uint256[]
calldatas bytes[]
descriptionHash bytes32
Returns
Param Type Notes
uint256

execute

function execute(uint256) payable

See {IGovernorCompatibilityBravo-execute}.

Params
Param Type Notes
proposalId uint256

getActions

function getActions(uint256) view returns(address[],uint256[],string[],bytes[])

See {IGovernorCompatibilityBravo-getActions}.

Params
Param Type Notes
proposalId uint256
Returns
Param Type Notes
targets address[]
values uint256[]
signatures string[]
calldatas bytes[]

getReceipt

function getReceipt(uint256,address) view returns(tuple)

See {IGovernorCompatibilityBravo-getReceipt}.

Params
Param Type Notes
proposalId uint256
voter address
Returns
Param Type Notes
tuple

getVotes

function getVotes(address,uint256) view returns(uint256)
Params
Param Type Notes
account address
blockNumber uint256
Returns
Param Type Notes
uint256

hasVoted

function hasVoted(uint256,address) view returns(bool)

See {IGovernor-hasVoted}.

Params
Param Type Notes
proposalId uint256
account address
Returns
Param Type Notes
bool

hashProposal

function hashProposal(address[],uint256[],bytes[],bytes32) pure returns(uint256)

See {IGovernor-hashProposal}. The proposal id is produced by hashing the RLC encoded targets array, the values array, the calldatas array and the descriptionHash (bytes32 which itself is the keccak256 hash of the description string). This proposal id can be produced from the proposal data which is part of the {ProposalCreated} event. It can even be computed in advance, before the proposal is submitted. Note that the chainId and the governor address are not part of the proposal id computation. Consequently, the same proposal (with same operation and same description) will have the same id if submitted on multiple governors accross multiple networks. This also means that in order to execute the same operation twice (on the same governor) the proposer will have to change the description in order to avoid proposal id conflicts.

Params
Param Type Notes
targets address[]
values uint256[]
calldatas bytes[]
descriptionHash bytes32
Returns
Param Type Notes
uint256

name

function name() view returns(string)

See {IGovernor-name}.

Returns
Param Type Notes
string

proposalDeadline

function proposalDeadline(uint256) view returns(uint256)

See {IGovernor-proposalDeadline}.

Params
Param Type Notes
proposalId uint256
Returns
Param Type Notes
uint256

proposalEta

function proposalEta(uint256) view returns(uint256)

Public accessor to check the eta of a queued proposal

Params
Param Type Notes
proposalId uint256
Returns
Param Type Notes
uint256

proposalSnapshot

function proposalSnapshot(uint256) view returns(uint256)

See {IGovernor-proposalSnapshot}.

Params
Param Type Notes
proposalId uint256
Returns
Param Type Notes
uint256

proposalThreshold

function proposalThreshold() view returns(uint256)

Part of the Governor Bravo's interface: "The number of votes required in order for a voter to become a proposer".

Returns
Param Type Notes
uint256

proposals

function proposals(uint256) view returns(uint256,address,uint256,uint256,uint256,uint256,uint256,uint256,bool,bool)

See {IGovernorCompatibilityBravo-proposals}.

Params
Param Type Notes
proposalId uint256
Returns
Param Type Notes
id uint256
proposer address
eta uint256
startBlock uint256
endBlock uint256
forVotes uint256
againstVotes uint256
abstainVotes uint256
canceled bool
executed bool

propose

function propose(address[],uint256[],bytes[],string) nonpayable returns(uint256)
Params
Param Type Notes
targets address[]
values uint256[]
calldatas bytes[]
description string
Returns
Param Type Notes
uint256

propose

function propose(address[],uint256[],string[],bytes[],string) nonpayable returns(uint256)

See {IGovernorCompatibilityBravo-propose}.

Params
Param Type Notes
targets address[]
values uint256[]
signatures string[]
calldatas bytes[]
description string
Returns
Param Type Notes
uint256

queue

function queue(address[],uint256[],bytes[],bytes32) nonpayable returns(uint256)

Function to queue a proposal to the timelock.

Params
Param Type Notes
targets address[]
values uint256[]
calldatas bytes[]
descriptionHash bytes32
Returns
Param Type Notes
uint256

queue

function queue(uint256) nonpayable

See {IGovernorCompatibilityBravo-queue}.

Params
Param Type Notes
proposalId uint256

quorum

function quorum(uint256) view returns(uint256)
Params
Param Type Notes
uint256
Returns
Param Type Notes
uint256

quorumVotes

function quorumVotes() view returns(uint256)

See {IGovernorCompatibilityBravo-quorumVotes}.

Returns
Param Type Notes
uint256

setProposalThreshold

function setProposalThreshold(uint256) nonpayable
Params
Param Type Notes
newProposalThreshold uint256

setQuorum

function setQuorum(uint256) nonpayable
Params
Param Type Notes
newQuorum uint256

setVotingDelay

function setVotingDelay(uint256) nonpayable
Params
Param Type Notes
newVotingDelay uint256

setVotingPeriod

function setVotingPeriod(uint256) nonpayable
Params
Param Type Notes
newVotingPeriod uint256

state

function state(uint256) view returns(uint8)
Params
Param Type Notes
proposalId uint256
Returns
Param Type Notes
uint8

supportsInterface

function supportsInterface(bytes4) view returns(bool)
Params
Param Type Notes
interfaceId bytes4
Returns
Param Type Notes
bool

timelock

function timelock() view returns(address)

Public accessor to check the address of the timelock

Returns
Param Type Notes
address

token

function token() view returns(address)
Returns
Param Type Notes
address

updateTimelock

function updateTimelock(address) nonpayable

Public endpoint to update the underlying timelock instance. Restricted to the timelock itself, so updates must be proposed, scheduled and executed using the {Governor} workflow. For security reason, the timelock must be handed over to another admin before setting up a new one. The two operations (hand over the timelock) and do the update can be batched in a single proposal. Note that if the timelock admin has been handed over in a previous operation, we refuse updates made through the timelock if admin of the timelock has already been accepted and the operation is executed outside the scope of governance.

Params
Param Type Notes
newTimelock address

version

function version() view returns(string)

See {IGovernor-version}.

Returns
Param Type Notes
string

votingDelay

function votingDelay() view returns(uint256)

module:user-config

Delay, in number of block, between the proposal is created and the vote starts. This can be increassed to leave time for users to buy voting power, of delegate it, before the voting of a proposal starts.

Returns
Param Type Notes
uint256

votingPeriod

function votingPeriod() view returns(uint256)

module:user-config

Delay, in number of blocks, between the vote start and vote ends. NOTE: The {votingDelay} can delay the start of the vote. This must be considered when setting the voting duration compared to the voting delay.

Returns
Param Type Notes
uint256

⬅️ Contracts