Documentation ¶
Index ¶
- Constants
- Variables
- func KeyNameCurveType(newKeyMatch []string) (keyName, curveType string)
- type Account
- type Assert
- type Bond
- type BondArg
- type Build
- type Call
- type CallArg
- type Client
- func (c *Client) Bond(arg *BondArg, logger *logging.Logger) (*payload.BondTx, error)
- func (c *Client) Broadcast(tx payload.Payload, logger *logging.Logger) (*exec.TxExecution, error)
- func (c *Client) BroadcastEnvelope(txEnv *txs.Envelope, logger *logging.Logger) (*exec.TxExecution, error)
- func (c *Client) Call(arg *CallArg, logger *logging.Logger) (*payload.CallTx, error)
- func (c *Client) CreateKey(keyName, curveTypeString string, logger *logging.Logger) (crypto.PublicKey, error)
- func (c *Client) Events(logger *logging.Logger) (rpcevents.ExecutionEventsClient, error)
- func (c *Client) GetAccount(address crypto.Address) (*acm.Account, error)
- func (c *Client) GetMetadata(metahash acmstate.MetadataHash) (string, error)
- func (c *Client) GetMetadataForAccount(address crypto.Address) (string, error)
- func (c *Client) GetName(name string, logger *logging.Logger) (*names.Entry, error)
- func (c *Client) GetProposal(hash []byte, logger *logging.Logger) (*payload.Ballot, error)
- func (c *Client) GetStorage(address crypto.Address, key binary.Word256) ([]byte, error)
- func (c *Client) GetValidatorSet(logger *logging.Logger) (*rpcquery.ValidatorSet, error)
- func (c *Client) Identify(arg *IdentifyArg, logger *logging.Logger) (*payload.IdentifyTx, error)
- func (c *Client) ListProposals(proposed bool, logger *logging.Logger) ([]*rpcquery.ProposalResult, error)
- func (c *Client) Name(arg *NameArg, logger *logging.Logger) (*payload.NameTx, error)
- func (c *Client) ParseAddress(key string, logger *logging.Logger) (crypto.Address, error)
- func (c *Client) ParseUint64(amount string) (uint64, error)
- func (c *Client) Permissions(arg *PermArg, logger *logging.Logger) (*payload.PermsTx, error)
- func (c *Client) PublicKeyFromAddress(address *crypto.Address) (*crypto.PublicKey, error)
- func (c *Client) Query(logger *logging.Logger) (rpcquery.QueryClient, error)
- func (c *Client) QueryContract(arg *QueryArg, logger *logging.Logger) (*exec.TxExecution, error)
- func (c *Client) Send(arg *SendArg, logger *logging.Logger) (*payload.SendTx, error)
- func (c *Client) SignAndBroadcast(tx payload.Payload, logger *logging.Logger) (*exec.TxExecution, error)
- func (c *Client) SignTx(tx payload.Payload, logger *logging.Logger) (*txs.Envelope, error)
- func (c *Client) Status(logger *logging.Logger) (*rpc.ResultStatus, error)
- func (c *Client) Transact(logger *logging.Logger) (rpctransact.TransactClient, error)
- func (c *Client) TxInput(inputString, amountString, sequenceString string, allowMempoolSigning bool, ...) (*payload.TxInput, error)
- func (c *Client) Unbond(arg *UnbondArg, logger *logging.Logger) (*payload.UnbondTx, error)
- func (c *Client) UpdateAccount(arg *GovArg, logger *logging.Logger) (*payload.GovTx, error)
- type Deploy
- type DeployArgs
- type DumpState
- type GovArg
- type Identify
- type IdentifyArg
- type Job
- type Meta
- type NameArg
- type PackageDeploy
- type Payload
- type PermArg
- type Permission
- type PermissionString
- type Playbook
- type Proposal
- type QueryAccount
- type QueryArg
- type QueryContract
- type QueryName
- type QueryVals
- type RegisterName
- type RestoreState
- type Send
- type SendArg
- type Set
- type Unbond
- type UnbondArg
- type UpdateAccount
Constants ¶
View Source
const DefaultOutputFile = "deploy.output.json"
Variables ¶
View Source
var NewKeyRegex = regexp.MustCompile(`new\((?P<keyName>[[:alnum:]]+)?(,(?P<curveType>[[:alnum:]]+))?\)`)
Used in the Target of UpdateAccount to determine whether to create a new account, e.g. new() or new(key1,ed25519)
Functions ¶
func KeyNameCurveType ¶
Types ¶
type Account ¶
type Account struct { // (Required) address of the account which should be used as the default (if source) is // not given for future transactions. Will make sure the burrow keys has the public key // for the account. Generally account should be the first job called unless it is used // via a flag or environment variables to establish what default to use. Address string `mapstructure:"address" json:"address" yaml:"address" toml:"address"` }
type Assert ¶
type Assert struct { // (Required) key which should be used for the assertion. This is usually known as the "expected" // value in most testing suites Key string `mapstructure:"key" json:"key" yaml:"key" toml:"key"` // (Required) must be of the set ["eq", "ne", "ge", "gt", "le", "lt", "==", "!=", ">=", ">", "<=", "<"] // establishes the relation to be tested by the assertion. If a strings key:value pair is being used // only the equals or not-equals relations may be used as the key:value will try to be converted to // ints for the remainder of the relations. if strings are passed to them then `monax pkgs do` will return an // error Relation string `mapstructure:"relation" json:"relation" yaml:"relation" toml:"relation"` // (Required) value which should be used for the assertion. This is usually known as the "given" // value in most testing suites. Generally it will be a variable expansion from one of the query // jobs. Value string `mapstructure:"val" json:"val" yaml:"val" toml:"val"` }
type Bond ¶ added in v0.28.0
type Bond struct { // (Optional, if account job or global account set) address of the account from which to bond (the // public key for the account must be available to burrow keys) Source string `mapstructure:"source" json:"source" yaml:"source" toml:"source"` // (Required) the Tendermint validator power to claim Amount string `mapstructure:"amount" json:"amount" yaml:"amount" toml:"amount"` // (Optional, advanced only) sequence to use when burrow keys signs the transaction // (do not use unless you know what you're doing) Sequence string `mapstructure:"sequence" json:"sequence" yaml:"sequence" toml:"sequence"` }
type Build ¶
type Build struct { // (Required) the filepath to the contract file. this should be relative to the current path **or** // relative to the contracts path established via the --dir. // If contract has a "bin" file extension then it will not be sent to the // compilers but rather will just be sent to the chain. Note, if you use a "call" job after deploying // a binary contract then you will be **required** to utilize an abi field in the call job. Contract string `mapstructure:"contract" json:"contract" yaml:"contract" toml:"contract"` // (Optional) where to save the result of the compilation BinPath string `mapstructure:"binpath" json:"binpath" yaml:"binpath" toml:"binpath"` // (Optional) the name of contract to instantiate (it has to be one of the contracts present) // in the file defined in Contract above. // When none is provided, the system will choose the contract with the same name as that file. // use "all" to override and deploy all contracts in order. if "all" is selected the result // of the job will default to the address of the contract which was deployed that matches // the name of the file (or the last one deployed if there are no matching names; not the "last" // one deployed" strategy is non-deterministic and should not be used). Instance string `mapstructure:"instance" json:"instance" yaml:"instance" toml:"instance"` // (Optional) Path to store an extra copy of the bin file Store string `mapstructure:"store" json:"store" yaml:"store" toml:"store"` }
type Call ¶
type Call struct { // (Optional, if account job or global account set) address of the account from which to send (the // public key for the account must be available to burrow keys) Source string `mapstructure:"source" json:"source" yaml:"source" toml:"source"` // (Required) address of the contract which should be called Destination string `mapstructure:"destination" json:"destination" yaml:"destination" toml:"destination"` // (Required unless testing fallback function) function inside the contract to be called Function string `mapstructure:"function" json:"function" yaml:"function" toml:"function"` // (Optional) data which should be called. will use the monax-abi tooling under the hood to formalize the // transaction Data interface{} `mapstructure:"data" json:"data" yaml:"data" toml:"data"` // (Optional) amount of tokens to send to the contract Amount string `mapstructure:"amount" json:"amount" yaml:"amount" toml:"amount"` // (Optional) validators' fee Fee string `mapstructure:"fee" json:"fee" yaml:"fee" toml:"fee"` // (Optional) amount of gas which should be sent along with the call transaction Gas string `mapstructure:"gas" json:"gas" yaml:"gas" toml:"gas"` // (Optional, advanced only) sequence to use when burrow keys signs the transaction (do not use unless you // know what you're doing) Sequence string `mapstructure:"sequence" json:"sequence" yaml:"sequence" toml:"sequence"` // (Optional) location of the bin file to use (can be relative path or in bin path) // deployed contracts save ABI artifacts in the bin folder as *both* the name of the contract // and the address where the contract was deployed to Bin string `mapstructure:"bin" json:"bin" yaml:"bin" toml:"bin"` // (Optional) by default the call job will "store" the return from the contract as the // result of the job. If you would like to store the transaction hash instead of the // return from the call job as the result of the call job then select "tx" on the save // variable. Anything other than "tx" in this field will use the default. Save string `mapstructure:"save" json:"save" yaml:"save" toml:"save"` // (Optional) the call job's returned variables Variables []*abi.Variable }
type Client ¶
type Client struct { MempoolSigning bool ChainAddress string KeysClientAddress string AllSpecs *abi.Spec // contains filtered or unexported fields }
func (*Client) BroadcastEnvelope ¶
func (c *Client) BroadcastEnvelope(txEnv *txs.Envelope, logger *logging.Logger) (*exec.TxExecution, error)
Broadcast envelope - can be locally signed or remote signing will be attempted
func (*Client) CreateKey ¶
func (c *Client) CreateKey(keyName, curveTypeString string, logger *logging.Logger) (crypto.PublicKey, error)
Creates a keypair using attached keys service
func (*Client) GetAccount ¶
func (*Client) GetMetadata ¶ added in v0.28.0
func (c *Client) GetMetadata(metahash acmstate.MetadataHash) (string, error)
func (*Client) GetMetadataForAccount ¶ added in v0.28.0
func (*Client) GetProposal ¶ added in v0.24.0
func (*Client) GetStorage ¶ added in v0.24.0
func (*Client) GetValidatorSet ¶
func (*Client) Identify ¶ added in v0.29.0
func (c *Client) Identify(arg *IdentifyArg, logger *logging.Logger) (*payload.IdentifyTx, error)
func (*Client) ListProposals ¶ added in v0.24.0
func (*Client) ParseAddress ¶ added in v0.28.0
func (*Client) Permissions ¶
func (*Client) PublicKeyFromAddress ¶ added in v0.28.0
func (*Client) QueryContract ¶
func (*Client) SignAndBroadcast ¶
func (*Client) Transact ¶
func (c *Client) Transact(logger *logging.Logger) (rpctransact.TransactClient, error)
type Deploy ¶
type Deploy struct { // (Optional, if account job or global account set) address of the account from which to send (the // public key for the account must be available to burrow keys) Source string `mapstructure:"source" json:"source" yaml:"source" toml:"source"` // (Required) the filepath to the contract file. this should be relative to the current path **or** // relative to the contracts path established via the --dir. // If contract has a "bin" file extension then it will not be sent to the // compilers but rather will just be sent to the chain. Note, if you use a "call" job after deploying // a binary contract then you will be **required** to utilize an abi field in the call job. Contract string `mapstructure:"contract" json:"contract" yaml:"contract" toml:"contract"` // (Optional) the name of contract to instantiate (it has to be one of the contracts present) // in the file defined in Contract above. // When none is provided, the system will choose the contract with the same name as that file. // use "all" to override and deploy all contracts in order. if "all" is selected the result // of the job will default to the address of the contract which was deployed that matches // the name of the file (or the last one deployed if there are no matching names; not the "last" // one deployed" strategy is non-deterministic and should not be used). Instance string `mapstructure:"instance" json:"instance" yaml:"instance" toml:"instance"` // (Optional) the file path for the linkReferences for contract Libraries string `mapstructure:"libraries" json:"libraries" yaml:"libraries" toml:"libraries"` // (Optional) TODO: additional arguments to send along with the contract code Data interface{} `mapstructure:"data" json:"data" yaml:"data" toml:"data"` // (Optional) amount of tokens to send to the contract which will (after deployment) reside in the // contract's account Amount string `mapstructure:"amount" json:"amount" yaml:"amount" toml:"amount"` // (Optional) validators' fee Fee string `mapstructure:"fee" json:"fee" yaml:"fee" toml:"fee"` // (Optional) amount of gas which should be sent along with the contract deployment transaction Gas string `mapstructure:"gas" json:"gas" yaml:"gas" toml:"gas"` // (Optional, advanced only) sequence to use when burrow keys signs the transaction (do not use unless you // know what you're doing) Sequence string `mapstructure:"sequence" json:"sequence" yaml:"sequence" toml:"sequence"` // (Optional) todo Variables []*abi.Variable // (Optional) Path to store an extra copy of the bin file Store string `mapstructure:"store" json:"store" yaml:"store" toml:"store"` }
type DeployArgs ¶ added in v0.23.0
type DeployArgs struct { Chain string `mapstructure:"," json:"," yaml:"," toml:","` KeysService string `mapstructure:"," json:"," yaml:"," toml:","` MempoolSign bool `mapstructure:"," json:"," yaml:"," toml:","` LocalABI bool `mapstructure:"," json:"," yaml:"," toml:","` Wasm bool `mapstructure:"," json:"," yaml:"," toml:","` Timeout int `mapstructure:"," json:"," yaml:"," toml:","` Address string `mapstructure:"," json:"," yaml:"," toml:","` BinPath string `mapstructure:"," json:"," yaml:"," toml:","` CurrentOutput string `mapstructure:"," json:"," yaml:"," toml:","` Debug bool `mapstructure:"," json:"," yaml:"," toml:","` DefaultAmount string `mapstructure:"," json:"," yaml:"," toml:","` DefaultFee string `mapstructure:"," json:"," yaml:"," toml:","` DefaultGas string `mapstructure:"," json:"," yaml:"," toml:","` DefaultOutput string `mapstructure:"," json:"," yaml:"," toml:","` DefaultSets []string `mapstructure:"," json:"," yaml:"," toml:","` Path string `mapstructure:"," json:"," yaml:"," toml:","` Verbose bool `mapstructure:"," json:"," yaml:"," toml:","` Jobs int `mapstructure:"," json:"," yaml:"," toml:","` ProposeVerify bool `mapstructure:"," json:"," yaml:"," toml:","` ProposeVote bool `mapstructure:"," json:"," yaml:"," toml:","` ProposeCreate bool `mapstructure:"," json:"," yaml:"," toml:","` }
func (*DeployArgs) Validate ¶ added in v0.23.0
func (args *DeployArgs) Validate() error
type DumpState ¶
type DumpState struct { WithValidators bool `mapstructure:"include-validators" json:"include-validators" yaml:"include-validators" toml:"include-validators"` ToIPFS bool `mapstructure:"to-ipfs" json:"to-ipfs" yaml:"to-ipfs" toml:"to-ipfs"` ToFile bool `mapstructure:"to-file" json:"to-file" yaml:"to-file" toml:"to-file"` IPFSHost string `mapstructure:"ipfs-host" json:"ipfs-host" yaml:"ipfs-host" toml:"ipfs-host"` FilePath string `mapstructure:"file" json:"file" yaml:"file" toml:"file"` }
type Identify ¶ added in v0.29.0
type Identify struct { // (Optional, if account job or global account set) address of the account from which to identify (the // public key for the account must be available to burrow keys) Source string `mapstructure:"source" json:"source" yaml:"source" toml:"source"` // (Required) file containing the tendermint node to identify as NodeKey string `mapstructure:"nodekey" json:"nodekey" yaml:"nodekey" toml:"nodekey"` // (Required) publically available network address NetAddress string `mapstructure:"netaddress" json:"netaddress" yaml:"netaddress" toml:"netaddress"` // (Optional) publically available network moniker Moniker string `mapstructure:"moniker" json:"moniker" yaml:"moniker" toml:"moniker"` // (Optional, advanced only) sequence to use when burrow keys signs the transaction (do not use unless you // know what you're doing) Sequence string `mapstructure:"sequence" json:"sequence" yaml:"sequence" toml:"sequence"` }
type IdentifyArg ¶ added in v0.29.0
type Job ¶
type Job struct { // Name of the job Name string `mapstructure:"name,omitempty" json:"name,omitempty" yaml:"name,omitempty" toml:"name"` // Not marshalled Intermediate interface{} `json:"-" yaml:"-" toml:"-"` // Not marshalled Result interface{} `json:"-" yaml:"-" toml:"-"` // For multiple values Variables []*abi.Variable `json:"-" yaml:"-" toml:"-"` // Create proposal or vote for one Proposal *Proposal `mapstructure:"proposal,omitempty" json:"proposal,omitempty" yaml:"proposal,omitempty" toml:"proposal"` // Sets/Resets the primary account to use Account *Account `mapstructure:"account,omitempty" json:"account,omitempty" yaml:"account,omitempty" toml:"account"` // Set an arbitrary value Set *Set `mapstructure:"set,omitempty" json:"set,omitempty" yaml:"set,omitempty" toml:"set"` // Run a sequence of other deploy.yamls Meta *Meta `mapstructure:"meta,omitempty" json:"meta,omitempty" yaml:"meta,omitempty" toml:"meta"` // Issue a governance transaction UpdateAccount *UpdateAccount `mapstructure:"update-account,omitempty" json:"update-account,omitempty" yaml:"update-account,omitempty" toml:"update-account"` // Contract compile and send to the chain functions Deploy *Deploy `mapstructure:"deploy,omitempty" json:"deploy,omitempty" yaml:"deploy,omitempty" toml:"deploy"` // Contract compile/build Build *Build `mapstructure:"build,omitempty" json:"build,omitempty" yaml:"build,omitempty" toml:"build"` // Send tokens from one account to another Send *Send `mapstructure:"send,omitempty" json:"send,omitempty" yaml:"send,omitempty" toml:"send"` // Bond tokens from an account Bond *Bond `mapstructure:"bond,omitempty" json:"bond,omitempty" yaml:"bond,omitempty" toml:"bond"` // Unbond tokens from an account Unbond *Unbond `mapstructure:"unbond,omitempty" json:"unbond,omitempty" yaml:"unbond,omitempty" toml:"unbond"` // Utilize monax:db's native name registry to register a name RegisterName *RegisterName `mapstructure:"register,omitempty" json:"register,omitempty" yaml:"register,omitempty" toml:"register"` // Validator identify as node key Identify *Identify `mapstructure:"identify,omitempty" json:"identify,omitempty" yaml:"identify,omitempty" toml:"identify"` // Sends a transaction which will update the permissions of an account. Must be sent from an account which // has root permissions on the blockchain (as set by either the genesis.json or in a subsequence transaction) Permission *Permission `mapstructure:"permission,omitempty" json:"permission,omitempty" yaml:"permission,omitempty" toml:"permission"` // Sends a transaction to a contract. Will utilize monax-abi under the hood to perform all of the heavy lifting Call *Call `mapstructure:"call,omitempty" json:"call,omitempty" yaml:"call,omitempty" toml:"call"` // Wrapper for mintdump dump. WIP DumpState *DumpState `mapstructure:"dump-state,omitempty" json:"dump-state,omitempty" yaml:"dump-state,omitempty" toml:"dump-state"` // Wrapper for mintdum restore. WIP RestoreState *RestoreState `mapstructure:"restore-state,omitempty" json:"restore-state,omitempty" yaml:"restore-state,omitempty" toml:"restore-state"` // Sends a "simulated call,omitempty" to a contract. Predominantly used for accessor functions ("Getters,omitempty" within contracts) QueryContract *QueryContract `mapstructure:"query-contract,omitempty" json:"query-contract,omitempty" yaml:"query-contract,omitempty" toml:"query-contract"` // Queries information from an account. QueryAccount *QueryAccount `mapstructure:"query-account,omitempty" json:"query-account,omitempty" yaml:"query-account,omitempty" toml:"query-account"` // Queries information about a name registered with monax:db's native name registry QueryName *QueryName `mapstructure:"query-name,omitempty" json:"query-name,omitempty" yaml:"query-name,omitempty" toml:"query-name"` // Queries information about the validator set QueryVals *QueryVals `mapstructure:"query-vals,omitempty" json:"query-vals,omitempty" yaml:"query-vals,omitempty" toml:"query-vals"` // Makes and assertion (useful for testing purposes) Assert *Assert `mapstructure:"assert,omitempty" json:"assert,omitempty" yaml:"assert,omitempty" toml:"assert"` }
func (*Job) PayloadField ¶
Ensures only one Job payload is set and returns a pointer to that field or an error if none or multiple job payload fields are set
type Meta ¶
type PackageDeploy ¶
type PackageDeploy struct { }
type Payload ¶
type Payload interface { validation.Validatable }
type Permission ¶
type Permission struct { // (Optional, if account job or global account set) address of the account from which to send (the // public key for the account must be available to burrow keys) Source string `mapstructure:"source" json:"source" yaml:"source" toml:"source"` // (Required) actions must be in the set ["set_base", "unset_base", "set_global", "add_role" "rm_role"] Action string `mapstructure:"action" json:"action" yaml:"action" toml:"action"` // (Required, unless add_role or rm_role action selected) the name of the permission flag which is to // be updated Permission string `mapstructure:"permission" json:"permission" yaml:"permission" toml:"permission"` // (Required) the value of the permission or role which is to be updated Value string `mapstructure:"value" json:"value" yaml:"value" toml:"value"` // (Required) the target account which is to be updated Target string `mapstructure:"target" json:"target" yaml:"target" toml:"target"` // (Required, if add_role or rm_role action selected) the role which should be given to the account Role string `mapstructure:"role" json:"role" yaml:"role" toml:"role"` // (Optional, advanced only) sequence to use when burrow keys signs the transaction (do not use unless you // know what you're doing) Sequence string `mapstructure:"sequence" json:"sequence" yaml:"sequence" toml:"sequence"` }
func (*Permission) Validate ¶
func (job *Permission) Validate() error
type PermissionString ¶
type PermissionString string
func (PermissionString) Validate ¶
func (ps PermissionString) Validate() error
type Playbook ¶ added in v0.24.0
type Playbook struct { Filename string Account string Jobs []*Job Path string `mapstructure:"-" json:"-" yaml:"-" toml:"-"` BinPath string `mapstructure:"-" json:"-" yaml:"-" toml:"-"` // If we're in a proposal or meta job, reference our parent script Parent *Playbook `mapstructure:"-" json:"-" yaml:"-" toml:"-"` }
type Proposal ¶ added in v0.23.0
type Proposal struct { // (Optional), address of the account that signs the proposal or votes for the proposal Source string `mapstructure:"source" json:"source" yaml:"source" toml:"source"` // (Optional, advanced only) sequence to use when burrow keys signs the transaction (do not use unless you // know what you're doing) Sequence string `mapstructure:"sequence" json:"sequence" yaml:"sequence" toml:"sequence"` // (Required), address of the account used for serialising proposals, the proposals system account ProposalAddress string `mapstructure:"proposaladdress" json:"proposaladdress" yaml:"proposaladdress" toml:"proposaladdress"` // (Optional), sequence of the ProposalAddress ProposalSequence string `mapstructure:"proposalsequence" json:"proposalsequence" yaml:"proposalsequence" toml:"proposalsequence"` // (Optional) VotingPower string `mapstructure:"votingpower" json:"votingpower" yaml:"votingpower" toml:"votingpower"` // (Required) the name of the proposal Name string `mapstructure:"name" json:"name" yaml:"name" toml:"name"` // (Required) the description of the proposal Description string `mapstructure:"description" json:"description" yaml:"description" toml:"description"` // (Required) the file path of the sub yaml to run Jobs []*Job `mapstructure:"jobs" json:"jobs" yaml:"jobs" toml:"jobs"` }
type QueryAccount ¶
type QueryAccount struct { // (Required) address of the account which should be queried Account string `mapstructure:"account" json:"account" yaml:"account" toml:"account"` // (Required) field which should be queried. If users are trying to query the permissions of the // account one can get either the `permissions.base` which will return the base permission of the // account, or one can get the `permissions.set` which will return the setBit of the account. Field string `mapstructure:"field" json:"field" yaml:"field" toml:"field"` }
func (*QueryAccount) Validate ¶
func (job *QueryAccount) Validate() error
type QueryContract ¶
type QueryContract struct { // (Optional, if account job or global account set) address of the account from which to send (the // public key for the account must be available to burrow keys) Source string `mapstructure:"source" json:"source" yaml:"source" toml:"source"` // (Required) address of the contract which should be called Destination string `mapstructure:"destination" json:"destination" yaml:"destination" toml:"destination"` // (Required) data which should be called. will use the monax-abi tooling under the hood to formalize the // transaction. QueryContract will usually be used with "accessor" functions in contracts Function string `mapstructure:"function" json:"function" yaml:"function" toml:"function"` // (Optional) data to be used in the function arguments. Will use the monax-abi tooling under the hood to formalize the // transaction. Data interface{} `mapstructure:"data" json:"data" yaml:"data" toml:"data"` // (Optional) location of the bin file to use (can be relative path or in abi path) // deployed contracts save ABI artifacts in the abi folder as *both* the name of the contract // and the address where the contract was deployed to Bin string `mapstructure:"bin" json:"bin" yaml:"bin" toml:"bin"` Variables []*abi.Variable }
aka. Simulated Call.
func (*QueryContract) Validate ¶
func (job *QueryContract) Validate() error
type QueryName ¶
type QueryName struct { // (Required) name which should be queried Name string `mapstructure:"name" json:"name" yaml:"name" toml:"name"` // (Required) field which should be quiried (generally will be "data" to get the registered "name") Field string `mapstructure:"field" json:"field" yaml:"field" toml:"field"` }
type QueryVals ¶
type QueryVals struct { // (Required) should be of the set ["bonded_validators" or "unbonding_validators"] and it will // return a comma separated listing of the addresses which fall into one of those categories Query string `mapstructure:"field" json:"field" yaml:"field" toml:"field"` }
type RegisterName ¶
type RegisterName struct { // (Optional, if account job or global account set) address of the account from which to send (the // public key for the account must be available to burrow keys) Source string `mapstructure:"source" json:"source" yaml:"source" toml:"source"` // (Required - unless providing data file) name which will be registered Name string `mapstructure:"name" json:"name" yaml:"name" toml:"name"` // (Optional, if data_file is used; otherwise required) data which will be stored at the `name` key Data string `mapstructure:"data" json:"data" yaml:"data" toml:"data"` // (Optional) csv file in the form (name,data[,amount]) which can be used to bulk register names DataFile string `mapstructure:"data_file" json:"data_file" yaml:"data_file" toml:"data_file"` // (Optional) amount of blocks which the name entry will be reserved for the registering user Amount string `mapstructure:"amount" json:"amount" yaml:"amount" toml:"amount"` // (Optional) validators' fee Fee string `mapstructure:"fee" json:"fee" yaml:"fee" toml:"fee"` // (Optional, advanced only) sequence to use when burrow keys signs the transaction (do not use unless you // know what you're doing) Sequence string `mapstructure:"sequence" json:"sequence" yaml:"sequence" toml:"sequence"` }
func (*RegisterName) Validate ¶
func (job *RegisterName) Validate() error
type RestoreState ¶
type RestoreState struct { FromIPFS bool `mapstructure:"from-ipfs" json:"from-ipfs" yaml:"from-ipfs" toml:"from-ipfs"` FromFile bool `mapstructure:"from-file" json:"from-file" yaml:"from-file" toml:"from-file"` IPFSHost string `mapstructure:"ipfs-host" json:"ipfs-host" yaml:"ipfs-host" toml:"ipfs-host"` FilePath string `mapstructure:"file" json:"file" yaml:"file" toml:"file"` }
func (*RestoreState) Validate ¶
func (job *RestoreState) Validate() error
type Send ¶
type Send struct { // (Optional, if account job or global account set) address of the account from which to send (the // public key for the account must be available to burrow keys) Source string `mapstructure:"source" json:"source" yaml:"source" toml:"source"` // (Required) address of the account to send the tokens Destination string `mapstructure:"destination" json:"destination" yaml:"destination" toml:"destination"` // (Required) amount of tokens to send from the `source` to the `destination` Amount string `mapstructure:"amount" json:"amount" yaml:"amount" toml:"amount"` // (Optional, advanced only) sequence to use when burrow keys signs the transaction (do not use unless you // know what you're doing) Sequence string `mapstructure:"sequence" json:"sequence" yaml:"sequence" toml:"sequence"` }
type Set ¶
type Set struct { // (Required) value which should be saved along with the jobName (which will be the key) // this is useful to set variables which can be used throughout the jobs definition file (deploy.yaml). // It should be noted that arrays and bools must be defined using strings as such "[1,2,3]" // if they are intended to be used further in a assert job. Value string `mapstructure:"val" json:"val" yaml:"val" toml:"val"` }
type Unbond ¶ added in v0.28.0
type Unbond struct { // (Optional, if account job or global account set) address of the validator to unbond (the // public key for the validator must be available to burrow keys) Source string `mapstructure:"source" json:"source" yaml:"source" toml:"source"` // (Required) the Tendermint validator power to unclaim Amount string `mapstructure:"amount" json:"amount" yaml:"amount" toml:"amount"` // (Optional, advanced only) sequence to use when burrow keys signs the transaction (do not use unless you // know what you're doing) Sequence string `mapstructure:"sequence" json:"sequence" yaml:"sequence" toml:"sequence"` }
type UpdateAccount ¶
type UpdateAccount struct { // (Optional, if account job or global account set) address of the account from which to send (the // public key for the account must be available to burrow keys) Source string `mapstructure:"source" json:"source" yaml:"source" toml:"source"` // (Required) The target account that will be governed - either an address or public key (its type will be determined by it's length) // if altering power then either a public key must be provided or the requisite public key associated with the address // must be available in an connected keys Signer Target string `mapstructure:"target" json:"target" yaml:"target" toml:"target"` // (Optional) the Tendermint validator power to set for this account Power string `mapstructure:"power" json:"power" yaml:"power" toml:"power"` // (Optional) The Burrow native token balance to set for this account Native string `mapstructure:"native" json:"native" yaml:"native" toml:"native"` // (Optional) the permissions to set for this account Permissions []PermissionString `mapstructure:"permissions" json:"permissions" yaml:"permissions" toml:"permissions"` // (Optional) the account permission roles to set for this account Roles []string `mapstructure:"roles" json:"roles" yaml:"roles" toml:"roles"` // (Optional, advanced only) sequence to use when burrow keys signs the transaction (do not use unless you // know what you're doing) Sequence string `mapstructure:"sequence" json:"sequence" yaml:"sequence" toml:"sequence"` }
UpdateAccount updates an account by overwriting the given values, where values are omitted the existing values are preserved. Currently requires Root permission on Source account
func (*UpdateAccount) Validate ¶
func (job *UpdateAccount) Validate() error
Click to show internal directories.
Click to hide internal directories.