veSEILOR is escrowed SEILOR. It has the same value as SEILOR and is subject to the total supply of SEILOR. veSEILOR cannot be traded or transferred but has voting rights and can share in protocol earnings. Mining rewards are the primary source of veSEILOR. veSEILOR holders can convert their veSEILOR to SEILOR through a vesting process. Once the process is started, veSEILOR will be linearly converted to SEILOR over a period of 30 days.
Config
Copy #[derive( Serialize , Deserialize , Clone , Debug , PartialEq , JsonSchema )]
pub struct VoteConfig {
pub max_supply : u128 ,
pub fund : Addr ,
pub gov : Addr ,
pub max_minted : Uint128 ,
pub total_minted : Uint128 ,
pub new_gov : Option < Addr >,
}
InitMsg
Copy #[cw_serde]
pub struct InstantiateMsg {
pub cw20_init_msg : Cw20InstantiateMsg ,
pub max_supply : u128 ,
// default msg.sender
pub gov : Option < Addr >,
pub max_minted : u128 ,
}
Copy {
"cw20_init_msg" : {
"name" : "seilor dev" ,
"symbol" : "seilor" ,
"decimals" : 6 ,
"initial_balances" : []
} ,
"max_supply" : "650000000000000"
}
* = optional
ExecuteMsg
UpdateConfig
Updates the configuration of the contract. Can only be issued by the gov address.
Copy #[cw_serde]
pub enum ExecuteMsg {
UpdateConfig {
max_minted : Option < Uint128 >,
fund : Option < Addr >,
gov : Option < Addr >,
}
}
Copy {
"update_config" : {
"max_minted" : "650000000000000" ,
"fund" : "sei1..." ,
"gov" : "sei1..."
}
}
SetMinters
Updates the minters of the contract. Can only be issued by the gov address.
Copy #[cw_serde]
pub enum ExecuteMsg {
SetMinters {
contracts : Vec < Addr >,
is_minter : Vec < bool >
}
}
Copy {
"set_minters" : {
"contracts" : [
"sei1..."
] ,
"is_minter" : [
true
]
}
}
Mint
Mints veSEILOR. Can only be issued by the mint permissions.
Copy #[cw_serde]
pub enum ExecuteMsg {
Mint {
recipient : String ,
amount : Uint128 ,
}
}
Copy {
"mint" : {
"recipient" : "sei1..." ,
"amount" : "650000000000000"
}
}
Burn
Burns veSEILOR. Can only be issued by the mint permissions.
Copy #[cw_serde]
pub enum ExecuteMsg {
Burn {
user : String ,
amount : Uint128 ,
}
}
Copy {
"burn" : {
"user" : "sei1..." ,
"amount" : "650000000000000"
}
}
UpdateMarketing
Only with the "marketing" extension. If authorized, updates marketing metadata. Setting None/null for any of these will leave it unchanged. Setting Some("") will clear this field on the contract storage
Copy #[cw_serde]
pub enum ExecuteMsg {
UpdateMarketing {
project : Option < String >,
description : Option < String >,
marketing : Option < String >,
}
}
Copy {
"update_marketing" : {
"project" : null ,
"description" : null ,
"marketing" : null
}
}
UploadLogo
If set as the "marketing" role on the contract, upload a new URL, SVG, or PNG for the token
Copy #[cw_serde]
pub enum ExecuteMsg {
UploadLogo {
logo : String
}
}
Copy {
"upload_logo" : {
"logo" : "https://..."
}
}
QueryMsg
VoteConfig
Returns the current configuration of the contract.
Copy #[cw_serde]
#[derive( QueryResponses )]
pub enum QueryMsg {
#[returns( VoteConfigResponse )]
VoteConfig {},
}
Copy {
"vote_config": {}
}
VoteConfigResponse
Copy #[cw_serde]
pub struct VoteConfigResponse {
pub max_supply : u128 ,
pub fund : Addr ,
pub gov : Addr ,
pub max_minted : Uint128 ,
pub total_minted : Uint128 ,
pub new_gov : Option < Addr >,
}
Copy {
"max_supply" : "650000000000000" ,
"fund" : "sei1..." ,
"gov" : "sei1..." ,
"max_minted" : "650000000000000" ,
"total_minted" : "650000000000000"
}
* = optional
IsMinter
Returns whether the given address is a minter.
Copy #[cw_serde]
#[derive( QueryResponses )]
pub enum QueryMsg {
#[returns( IsMinterResponse )]
IsMinter { address : String },
}
Copy {
"is_minter" : {
"address" : "sei1..."
}
}
IsMinterResponse
Copy #[cw_serde]
pub struct IsMinterResponse {
pub is_minter : bool ,
}
Copy {
"is_minter" : true
}
Checkpoints
Returns the checkpoints of the given address and points.
Copy #[cw_serde]
#[derive( QueryResponses )]
pub enum QueryMsg {
#[returns( CheckpointResponse )]
Checkpoints { account : Addr , pos : u32 },
}
Copy {
"checkpoints" : {
"account" : "sei1..." ,
"pos" : 0
}
}
CheckpointResponse
Copy #[cw_serde]
pub struct CheckpointResponse {
pub from_block : u64 ,
pub votes : u128 ,
}
Copy {
"from_block": 0,
"votes": "650000000000000"
}
NumCheckpoints
Returns the number of checkpoints for the given address.
Copy #[cw_serde]
#[derive( QueryResponses )]
pub enum QueryMsg {
#[returns( NumCheckpointsResponse )]
NumCheckpoints { account : Addr },
}
Copy {
"num_checkpoints": {
"account": "sei1..."
}
}
NumCheckpointsResponse
Copy #[cw_serde]
pub struct NumCheckpointsResponse {
pub num : usize ,
}
GetVotes
Returns the amount of votes the given address has.
Copy #[cw_serde]
#[derive( QueryResponses )]
pub enum QueryMsg {
#[returns( GetVotesResponse )]
GetVotes { account : Addr },
}
Copy {
"get_votes" : {
"account" : "sei1..."
}
}
GetVotesResponse
Copy #[cw_serde]
pub struct GetVotesResponse {
pub votes : u128 ,
}
Copy {
"votes": "650000000000000"
}
GetPastVotes
Returns the amount of votes the given address had at the given block.
Copy #[cw_serde]
#[derive( QueryResponses )]
pub enum QueryMsg {
#[returns( GetPastVotesResponse )]
GetPastVotes { account : Addr , block_number : u64 },
}
Copy {
"get_past_votes" : {
"account" : "sei1..." ,
"block_number" : 0
}
}
GetPastVotesResponse
Copy #[cw_serde]
pub struct GetPastVotesResponse {
pub votes : u128 ,
}
Copy {
"votes": "650000000000000"
}
GetPastTotalSupply
Returns the amount of total supply at the given block.
Copy #[cw_serde]
#[derive( QueryResponses )]
pub enum QueryMsg {
#[returns( GetPastTotalSupplyResponse )]
GetPastTotalSupply { block_number : u64 },
}
Copy {
"get_past_total_supply" : {
"block_number" : 0
}
}
GetPastTotalSupplyResponse
Copy #[cw_serde]
pub struct GetPastTotalSupplyResponse {
pub total_supply : u128 ,
}
Copy {
"total_supply": "650000000000000"
}
Balance
Returns the current balance of the given address, 0 if unset. Return type: BalanceResponse.
Copy #[cw_serde]
pub enum QueryMsg {
Balance {
address : String
}
}
Copy {
"balance" : {
"address" : "sei..."
}
}
BalanceResponse
Copy #[cw_serde]
pub struct BalanceResponse {
pub balance : Uint128 ,
}
Copy {
"balance" : "100000000000000000000000000"
}
TokenInfo
Returns metadata on the contract - name, decimals, supply, etc. Return type: TokenInfoResponse
Copy #[cw_serde]
pub enum QueryMsg {
TokenInfo {}
}
TokenInfoResponse
Copy #[cw_serde]
pub struct TokenInfoResponse {
pub name: String,
pub symbol: String,
pub decimals: u8,
pub total_supply: Uint128,
}
Copy {
"name": "SEILOR",
"symbol": "SEILOR",
"decimals": 18,
"total_supply": "100000000000000000000000000"
}
Minter
Only with "mintable" extension. Returns who can mint and the hard cap on maximum tokens after minting. Return type: MinterResponse.
Copy #[cw_serde]
pub enum QueryMsg {
Minter {}
}
MinterResponse
Copy #[cw_serde]
pub struct MinterResponse {
pub minter: Addr,
pub cap: Option<Uint128>,
}
Copy {
"minter": "sei...",
"cap": "100000000000000000000000000"
}
AllAccounts
Only with "enumerable" extension Returns all accounts that have balances. Supports pagination. Return type: AllAccountsResponse.
Copy #[cw_serde]
pub enum QueryMsg {
AllAccounts {
start_after: Option<String>,
limit: Option<u32>,
}
}
Copy {
"all_accounts": {
"start_after": "sei...",
"limit": 10
}
}
* = optional
MarketingInfo
Only with "marketing" extension Returns more metadata on the contract to display in the client:
description, logo, project url, etc. Return type: MarketingInfoResponse.
Copy #[cw_serde]
pub enum QueryMsg {
MarketingInfo {}
}
Copy {
"marketing_info": {}
}
MarketingInfoResponse
Copy #[cw_serde]
pub struct MarketingInfoResponse {
/// A URL pointing to the project behind this token.
pub project: Option<String>,
/// A longer description of the token and it's utility. Designed for tooltips or such
pub description: Option<String>,
/// A link to the logo, or a comment there is an on-chain logo stored
pub logo: Option<LogoInfo>,
/// The address (if any) who can update this data structure
pub marketing: Option<Addr>,
}
Copy {
"project": "https://...",
"description": "Ku...",
"logo": {
"url": "logo",
"embedded": "iVBORw0KGgoAAAANSUhEUgAA..."
},
"marketing": "sei..."
}
DownLoadLogo
Only with "marketing" extension Downloads the embedded logo data (if stored on chain). Errors if no logo data stored for this contract. Return type: DownloadLogoResponse.
Copy #[cw_serde]
pub enum QueryMsg {
DownloadLogo {}
}
Copy {
"download_logo": {}
}
DownloadLogoResponse
When we download an embedded logo, we get this response type. We expect a SPA to be able to accept this info and display it.
Copy #[cw_serde]
pub struct DownloadLogoResponse {
/// The mime type of the image
pub mime_type: String,
/// The raw bytes of the image
pub data: Binary,
}
Copy {
"mime_type": "image/png",
"data": "iVBORw0KGgoAAAANSUhEUgAA..."
}