# Governance

# Proposals

Terra.gov.proposals()

Returns all current proposals.

terra.gov.proposals()

# Returns

Proposal[]

List of all proposals.

Terra.gov.proposal(proposal_id)

Get a single proposal by ID.

terra.gov.proposal(3)

# Parameters

int
proposal_id

ID of proposal to look up.


# Returns

Proposal

Proposal information of ID queried.

# Proposal Proposer

Terra.gov.proposer_for(proposal_id)

Get the proposal's proposer.

terra.gov.proposer_for(5) # -> AccAddress

# Parameters

int
proposal_id

ID of proposal to look up.


# Returns

AccAddress

Proposal's proposer.

# Proposal Deposits

Terra.gov.deposits_for(proposal_id)

Get the proposal's deposits.

terra.gov.deposits_for(5)

# Parameters

int
proposal_id

ID of proposal to look up.


# Returns

Coins

Proposal's current deposits.

# Proposal Votes

Terra.gov.votes_for(proposal_id)

Get the proposal's votes.

terra.gov.votes_for(5)

# Parameters

int
proposal_id

ID of proposal to look up.


# Returns

JiguBox[AccAddress, str] with keys the account addresses of voters, and values "Yes", "Abstain", "No", or "NoWithVeto".

# Proposal Tally

Terra.gov.tally_for(proposal_id)

Get the proposal's tally.

terra.gov.tally_for(5)

# Parameters

int
proposal_id

ID of proposal to look up.


# Returns

JiguBox[str, Coin] with keys "Yes", "Abstain", "No", or "NoWithVeto" and values the Luna amount of votes each category has received.

# Module Params

Terra.gov.params(key=None)

Gets the current governance module params.

terra.gov.params()

# Parameters

str
key
optional

One of "deposit_params", "voting_params", or "tally_params".


# Returns

JiguBox with the following keys:

JiguBox
deposit_params

with the following keys:

Coins
min_deposit

Minimum deposit to enter voting.

int
max_deposit_period

Amount of time (in seconds) a proposal can take to acquire the necessary deposits to enter voting stage, after being submitted.

JiguBox
voting_params

with the following keys:

int
voting_period

Amount of time (in seconds) a proposal can take to get votes once voting has begun.

JiguBox
tally_params

with the following keys:

Dec
quorum

Ratio of total staked tokens that need to have participated in the vote.

Dec
threshold

Ratio of participating tokens that have voted in favor of the proposal.

Dec
veto

Ratio of participating votes with NoWithVeto (after excluding Abstain votes) to veto the proposal.

Updated on: 3/10/2020, 9:45:12 AM