submitdraft
to create a draft proposal- send 100 EOS from
proposer
account activate
proposal, deducts min deposit & can no longer be modified
submitdraft
draft proposalcanceldraft
cancel draft
submitdraft
draft proposal- send 100 EOS
refund
action to return 100 EOS
- Create
eosio.wps
account with 2MB worth of RAM
- Transfer
eosio.wps
account with50,000 EOS
fromeosio.names
account
- Deploy EOS WPS smart contract https://github.com/EOS-Nation/eos-wps
- Initialize EOS WPS (start will be 00:00UTC the day
init
is executed)
Submit a draft WPS proposal (create/modify)
- authority:
proposer
- ram_payer:
proposer
{name} proposer
- proposer of proposal{name} proposal_name
- proposal name{string} title
- proposal title{asset} monthly_budget
- monthly budget payment request{uin8_t} duration
- monthly budget duration (maximum of 6 months){map<name, string>} proposal_json
- a sorted container of <key, value>
cleos push action eosio.wps submitdraft '["myaccount", "mywps", "My WPS", "500.0000 EOS", 1, [{"key":"category", "value":"other"}, {"key":"region", "value":"global"}]]' -p myaccount
Vote for a WPS proposal
- authority:
voter
- ram_payer:
get_self()
{name} voter
- voter{name} proposal_name
- proposal name{name} vote
- vote (yes/no/abstain)
cleos push action eosio.wps vote '["myaccount", "mywps", "yes"]' -p myaccount
Activate WPS proposal at a specified voting period
- authority:
proposer
- ram_payer:
get_self()
{name} proposer
- proposer{name} proposal_name
- proposal name{bool} [activate_next=false]
- (optional) activate proposal at next voting period (default to current voting period)
cleos push action eosio.wps activate '["myaccount", "mywps", false]' -p myaccount
Claim remaining proposal amount, transfer amount to proposer
- authority:
any
{name} proposal_name
- proposal name to claim
cleos push action eosio.wps claim '["mywps"]' -p myaccount
Refund any remaining deposit amount from requesting account
- authority:
account
{name} account
- account requesting refund
cleos push action eosio.wps refund '["myaccount"]' -p myaccount
Cancel draft WPS proposal
- authority:
proposer
{name} proposer
- proposer{name} proposal_name
- proposal name
cleos push action eosio.wps canceldraft '["myaccount", "mywps"]' -p myaccount
Modify draft WPS proposal
- authority:
proposer
- ram_payer:
proposer
{name} proposer
- proposer of proposal{name} proposal_name
- proposal name{string} title
- proposal title{map<name, string>} proposal_json
- a sorted container of <key, value>
cleos push action eosio.wps modifydraft '["myaccount", "mywps", "My WPS", [{"key":"region", value":"global"}]]' -p myaccount
Modify draft WPS proposal budget
- authority:
proposer
- ram_payer:
proposer
{name} proposer
- proposer of proposal{name} proposal_name
- proposal name{asset} monthly_budget
- monthly budget payment request{uin8_t} duration
- monthly budget duration (maximum of 6 months)
cleos push action eosio.wps modifybudget '["myaccount", "mywps", "500.0000 EOS", 2]' -p myaccount
Set proposer's json metadata
- authority:
proposer
- ram_payer:
proposer
{name} proposer
- proposer of proposal{map<name, string>} proposer_json
- a sorted container of <key, value>
cleos push action eosio.wps setproposer '["myaccount", [{"key":"region", value":"global"}]]' -p myaccount
Initialize WPS contract
- authority:
get_self()
- ram_payer:
get_self()
{wps_parameters} params
- EOSIO WPS parameters
cleos push action eosio.wps init '[{"vote_margin": 20, "deposit_required": "100.0000 EOS", "voting_interval": 2592000, "max_monthly_budget": "25000.0000 EOS", "min_time_voting_end": 432000 }]' -p eosio.wps
Complete WPS voting period
- authority:
any
N/A
cleos push action eosio.wps complete '[]' -p eosio.wps
Set paramaters for WPS contract
- authority:
get_self()
- ram_payer:
get_self()
{wps_parameters} params
- EOSIO WPS parameters
cleos push action eosio.wps setparams '[{"vote_margin": 20, "deposit_required": "100.0000 EOS", "voting_interval": 2592000, "max_monthly_budget": "25000.0000 EOS", "min_time_voting_end": 432000 }]' -p eosio.wps
Update votes
from eligible voters
Any existing votes with voters with less than 100 EOS vpay will be removed
- authority:
any
cleos push action eosio.wps refresh '[]' -p myaccount
- authority:
account
- ram_payer:
account
{name} account
- account name{name} proposal_name
- proposal name{map<name, string>} comment_json
- a sorted container of <key, value>
# create/modify comment
cleos push action eosio.wps comment '["myaccount", "myproposal", [{ "key": "text", "value": "my comment" }]]' -p myaccount
# delete comment
cleos push action eosio.wps comment '["myaccount", "myproposal", []]' -p myaccount
{int16_t} [vote_margin=20]
- minimum BP vote margin threshold to reach for proposals{asset} [deposit_required="100.0000 EOS"]
- deposit required to active proposal{uint64_t} [voting_interval=2592000]
- voting interval in seconds{asset} [max_monthly_budget="25000.0000 EOS"]
- maximum monthly budget{uint64_t} [min_time_voting_end=432000]
- minimum time required to activate at the end of the currentoting period
{
"vote_margin": 20,
"deposit_required": "100.0000 EOS",
"voting_interval": 2592000,
"max_monthly_budget": "25000.0000 EOS",
"min_time_voting_end": 432000
}
- scope:
proposer
- ram_payer:
proposer
{name} proposer
- proposer of proposal{name} proposal_name
- proposal name{string} title
- proposal title{asset} monthly_budget
- monthly budget payment request{uint8_t} duration
- monthly budget duration (maximum of 6 months){asset} total_budget
- total budget payment request{map<name, string>} proposal_json
- a sorted container of <key, value>
{
"proposer": "myaccount",
"proposal_name": "mywps",
"title": "My WPS",
"monthly_budget": "500.0000 EOS",
"duration": 2,
"total_budget": "1000.0000 EOS",
"proposal_json": [
{ "key": "category", "value": "other" },
{ "key": "region", "value": "global" }
]
}
{name} proposer
- proposer of proposal{map<name, string>} proposer_json
- a sorted container of <key, value>
{
"proposer": "myaccount",
"proposer_json": [
{ "key": "region", "value": "global" }
]
}
param |
index_position |
key_type |
---|---|---|
status |
2 | i64 |
proposer |
3 | i64 |
param |
value |
---|---|
active |
available for current voting period |
completed |
proposal completed and payout in full |
partial |
proposal completed and partial payout |
expired |
proposal expired without any payout |
{name} proposer
- proposer of proposal{name} proposal_name
- proposal name{string} title
- proposal title{asset} monthly_budget
- monthly budget payment request{uint8_t} duration
- monthly budget duration (maximum of 6 months){asset} total_budget
- total budget payment request{map<name, string>} proposal_json
- a sorted container of <key, value>{name} status
- status of proposal (active/expired/completed){int16_t} total_net_votes
- total net votes{bool} eligible
- (true/false) eligible for current voting period payout{asset} payouts
- total payouts amount received{asset} claimed
- total claimed amount{time_point_sec} created
- time proposal was created (UTC){time_point_sec} start_voting_period
- start of voting period (UTC){time_point_sec} end
- end of proposal (UTC)
{
"proposer": "myaccount",
"proposal_name": "mywps",
"title": "My WPS",
"monthly_budget": "500.0000 EOS",
"duration": 2,
"total_budget": "1000.0000 EOS",
"proposal_json": [
{ "key": "category", "value": "other" },
{ "key": "region", "value": "global" }
],
"status": "active",
"total_net_votes": 2,
"eligible": false,
"payouts": "0.0000 EOS",
"claimed": "0.0000 EOS",
"created": "2019-11-05T12:10:00",
"start_voting_period": "2019-11-01T00:00:00",
"end": "2019-12-01T00:00:00"
}
{name} proposal_name
- The proposal's name, its ID among all proposals{map<name, name>} votes
- a sorted container of <voter, vote>
{
"proposal_name": "mywps",
"votes": [
{ "key": "mybp1", "value": "yes" },
{ "key": "mybp2", "value": "no" },
{ "key": "mybp3", "value": "yes" },
{ "key": "mybp4", "value": "abstain" },
{ "key": "mybp5", "value": "yes" }
]
}
{time_point_sec} current_voting_period
- current voting period{time_point_sec} next_voting_period
- next voting period{asset} [liquid_deposits="0.0000 EOS"]
- liquid deposits{asset} [locked_deposits="0.0000 EOS"]
- locked deposits{asset} [available_funding="0.0000 EOS"]
- available funding
{
"current_voting_period": "2019-12-12T00:00:00",
"next_voting_period": "2020-01-11T00:00:00",
"liquid_deposits": "100.0000 EOS",
"locked_deposits": "200.0000 EOS",
"available_funding": "50000.0000 EOS",
}
{name} account
- account balance owner{asset} balance
- token balance amount
{
"account": "myaccount",
"balance": "100.0000 EOS"
}
{time_point_sec} voting_period
- voting period{set<name>} proposals
- set of proposal names
{
"voting_period": "2019-11-01T00:00:00",
"proposals": ["mywps"],
}
{uint64_t} id
- claim identifier{name} proposer
- proposer{name} proposal_name
- proposal name{asset} quantity
- claim quantity amount{time_point_sec} timestamp
- timestamp of claim transfer{checksum256} tx_id
- transaction ID
{
"id": 0,
"proposer": "myaccount",
"proposal_name": "mywps",
"quantity": "100.0000 EOS",
"timestamp": "2019-12-01T00:00:00",
"tx_id": "<TRANSACTION ID>"
}
- scope:
proposal_name
- ram_payer:
account
param |
index_position |
key_type |
---|---|---|
timestamp |
2 | i64 |
{name} account
- account name{time_point_sec} timestamp
- last time created/modified{uint16_t} version
- version number{map<name, string>} comment_json
- a sorted container of <key, value>
{
"account": "myaccount",
"timestamp": "2020-03-26T12:00:00",
"version": 0,
"comment_json": [
{ "key": "text", "value": "my comment" }
]
}