rest

package
v0.13.4 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Feb 2, 2022 License: Apache-2.0 Imports: 17 Imported by: 0

Documentation

Index

Constants

View Source
const (
	QueryParamKeyRole = "key_role"
	QueryParamKeyID   = "key_id"
	QueryParamSymbol  = keeper.BySymbol
	QueryParamAsset   = keeper.ByAsset
)

query parameters

View Source
const (
	TxConfirmChain                = "confirm-chain"
	TxConfirmGatewayDeployment    = "confirm-gateway-deployment"
	TxLink                        = "link"
	TxConfirmTokenDeploy          = "confirm-erc20-deploy"
	TxConfirmDeposit              = "confirm-erc20-deposit"
	TxConfirmTransferOwnership    = "confirm-transfer-ownership"
	TxConfirmTransferOperatorship = "confirm-transfer-operatorship"
	TxCreatePendingTransfers      = "create-pending-transfers"
	TxCreateDeployToken           = "create-deploy-token"
	TxCreateBurnTokens            = "create-burn-token"
	TxCreateTransferOwnership     = "create-transfer-ownership"
	TxCreateTransferOperatorship  = "create-transfer-operatorship"
	TxSignCommands                = "sign-commands"
	TxAddChain                    = "add-chain"

	QueryAddress              = "query-address"
	QueryBatchedCommands      = "batched-commands"
	QueryTokenAddress         = "token-address"
	QueryPendingCommands      = keeper.QPendingCommands
	QueryCommand              = keeper.QCommand
	QueryNextMasterAddress    = keeper.QNextMasterAddress
	QueryAxelarGatewayAddress = keeper.QAxelarGatewayAddress
	QueryBytecode             = keeper.QBytecode
	QueryDepositState         = keeper.QDepositState
	QueryChains               = keeper.QChains
)

rest routes

Variables

This section is empty.

Functions

func GetHandlerAddChain

func GetHandlerAddChain(cliCtx client.Context) http.HandlerFunc

GetHandlerAddChain returns a handler to add a new evm chain command

func GetHandlerConfirmChain

func GetHandlerConfirmChain(cliCtx client.Context) http.HandlerFunc

GetHandlerConfirmChain returns a handler to confirm an EVM chain

func GetHandlerConfirmDeposit

func GetHandlerConfirmDeposit(cliCtx client.Context) http.HandlerFunc

GetHandlerConfirmDeposit returns a handler to confirm a deposit

func GetHandlerConfirmGatewayDeployment

func GetHandlerConfirmGatewayDeployment(cliCtx client.Context) http.HandlerFunc

GetHandlerConfirmGatewayDeployment returns a handler to confirm the gateway deployment

func GetHandlerConfirmTokenDeploy

func GetHandlerConfirmTokenDeploy(cliCtx client.Context) http.HandlerFunc

GetHandlerConfirmTokenDeploy returns a handler to confirm a token deployment

func GetHandlerConfirmTransferKey

func GetHandlerConfirmTransferKey(cliCtx client.Context, transferKeyType types.TransferKeyType) http.HandlerFunc

GetHandlerConfirmTransferKey returns a handler to confirm a transfer ownership

func GetHandlerCreateBurnTokens

func GetHandlerCreateBurnTokens(cliCtx client.Context) http.HandlerFunc

GetHandlerCreateBurnTokens returns a handler to create commands for all outstanding burns

func GetHandlerCreateDeployToken

func GetHandlerCreateDeployToken(cliCtx client.Context) http.HandlerFunc

GetHandlerCreateDeployToken returns a handler to create a deploy token command

func GetHandlerCreatePendingTransfers

func GetHandlerCreatePendingTransfers(cliCtx client.Context) http.HandlerFunc

GetHandlerCreatePendingTransfers returns a handler to create commands for all pending transfers

func GetHandlerCreateTransferOperatorship

func GetHandlerCreateTransferOperatorship(cliCtx client.Context) http.HandlerFunc

GetHandlerCreateTransferOperatorship returns a handler to create transfer operatoship command

func GetHandlerCreateTransferOwnership

func GetHandlerCreateTransferOwnership(cliCtx client.Context) http.HandlerFunc

GetHandlerCreateTransferOwnership returns a handler to create transfer ownership command

func GetHandlerLink(cliCtx client.Context) http.HandlerFunc

GetHandlerLink returns the handler to link addresses

func GetHandlerQueryAddress

func GetHandlerQueryAddress(cliCtx client.Context) http.HandlerFunc

GetHandlerQueryAddress returns a handler to query an EVM chain address

func GetHandlerQueryAxelarGatewayAddress

func GetHandlerQueryAxelarGatewayAddress(cliCtx client.Context) http.HandlerFunc

GetHandlerQueryAxelarGatewayAddress returns a handler to query an EVM chain gateway contract address

func GetHandlerQueryBatchedCommands

func GetHandlerQueryBatchedCommands(cliCtx client.Context) http.HandlerFunc

GetHandlerQueryBatchedCommands returns a handler to query batched commands by ID

func GetHandlerQueryBytecode

func GetHandlerQueryBytecode(cliCtx client.Context) http.HandlerFunc

GetHandlerQueryBytecode returns a handler to fetch the bytecodes of an EVM contract

func GetHandlerQueryChains added in v0.10.0

func GetHandlerQueryChains(cliCtx client.Context) http.HandlerFunc

GetHandlerQueryChains returns a handler to query EVM chains

func GetHandlerQueryCommand added in v0.10.0

func GetHandlerQueryCommand(cliCtx client.Context) http.HandlerFunc

GetHandlerQueryCommand returns a handler to get the command with the given ID on the specified chain

func GetHandlerQueryDepositState

func GetHandlerQueryDepositState(cliCtx client.Context) http.HandlerFunc

GetHandlerQueryDepositState returns a handler to query the state of an ERC20 deposit confirmation

func GetHandlerQueryLatestBatchedCommands

func GetHandlerQueryLatestBatchedCommands(cliCtx client.Context) http.HandlerFunc

GetHandlerQueryLatestBatchedCommands returns a handler to query batched commands by ID

func GetHandlerQueryNextMasterAddress

func GetHandlerQueryNextMasterAddress(cliCtx client.Context) http.HandlerFunc

GetHandlerQueryNextMasterAddress returns a handler to query an EVM chain next master address

func GetHandlerQueryPendingCommands added in v0.10.0

func GetHandlerQueryPendingCommands(cliCtx client.Context) http.HandlerFunc

GetHandlerQueryPendingCommands returns a handler to get the list of commands not yet added to a batch

func GetHandlerQueryTokenAddress

func GetHandlerQueryTokenAddress(cliCtx client.Context) http.HandlerFunc

GetHandlerQueryTokenAddress returns a handler to query an EVM chain address

func GetHandlerSignCommands

func GetHandlerSignCommands(cliCtx client.Context) http.HandlerFunc

GetHandlerSignCommands returns a handler to sign pending commands

func RegisterRoutes

func RegisterRoutes(cliCtx client.Context, r *mux.Router)

RegisterRoutes registers this module's REST routes with the given router

Types

type ReqAddChain

type ReqAddChain struct {
	BaseReq     rest.BaseReq `json:"base_req" yaml:"base_req"`
	Name        string       `json:"name" yaml:"name"`
	NativeAsset string       `json:"native_asset" yaml:"native_asset"`
	KeyType     string       `json:"key_type" yaml:"key_type"`
	Params      types.Params `json:"params" yaml:"params"`
}

ReqAddChain represents a request to add a new evm chain command

type ReqConfirmChain

type ReqConfirmChain struct {
	BaseReq rest.BaseReq `json:"base_req" yaml:"base_req"`
	Chain   string       `json:"chain" yaml:"chain"`
}

ReqConfirmChain represents a request to confirm a new chain

type ReqConfirmDeposit

type ReqConfirmDeposit struct {
	BaseReq       rest.BaseReq `json:"base_req" yaml:"base_req"`
	TxID          string       `json:"tx_id" yaml:"tx_id"`
	Amount        string       `json:"amount" yaml:"amount"`
	BurnerAddress string       `json:"burner_address" yaml:"burner_address"`
}

ReqConfirmDeposit represents a request to confirm a deposit

type ReqConfirmGatewayDeployment

type ReqConfirmGatewayDeployment struct {
	BaseReq rest.BaseReq `json:"base_req" yaml:"base_req"`
	Chain   string       `json:"chain" yaml:"chain"`
	TxID    string       `json:"tx_id" yaml:"tx_id"`
	Address string       `json:"address" yaml:"address"`
}

ReqConfirmGatewayDeployment represents a request to confirm the gateway deployment

type ReqConfirmTokenDeploy

type ReqConfirmTokenDeploy struct {
	BaseReq     rest.BaseReq `json:"base_req" yaml:"base_req"`
	OriginChain string       `json:"origin_chain" yaml:"origin_chain"`
	OriginAsset string       `json:"origin_asset" yaml:"origin_asset"`
	TxID        string       `json:"tx_id" yaml:"tx_id"`
}

ReqConfirmTokenDeploy represents a request to confirm a token deployment

type ReqConfirmTransferKey

type ReqConfirmTransferKey struct {
	BaseReq rest.BaseReq `json:"base_req" yaml:"base_req"`
	TxID    string       `json:"tx_id" yaml:"tx_id"`
	KeyID   string       `json:"key_id" yaml:"key_id"`
}

ReqConfirmTransferKey represents a request to confirm a transfer ownership

type ReqCreateBurnTokens

type ReqCreateBurnTokens struct {
	BaseReq rest.BaseReq `json:"base_req" yaml:"base_req"`
}

ReqCreateBurnTokens represents a request to create commands for all outstanding burns

type ReqCreateDeployToken

type ReqCreateDeployToken struct {
	BaseReq     rest.BaseReq `json:"base_req" yaml:"base_req"`
	OriginChain string       `json:"origin_chain" yaml:"origin_chain"`
	OriginAsset string       `json:"origin_asset" yaml:"origin_asset"`
	Symbol      string       `json:"symbol" yaml:"symbol"`
	TokenName   string       `json:"token_name" yaml:"token_name"`
	Decimals    string       `json:"decimals" yaml:"decimals"`
	Capacity    string       `json:"capacity" yaml:"capacity"`
	MinDeposit  string       `json:"min_deposit" yaml:"min_deposit"`
}

ReqCreateDeployToken represents a request to create a deploy token command

type ReqCreatePendingTransfers

type ReqCreatePendingTransfers struct {
	BaseReq rest.BaseReq `json:"base_req" yaml:"base_req"`
}

ReqCreatePendingTransfers represents a request to create commands for all pending transfers

type ReqCreateTransferOperatorship

type ReqCreateTransferOperatorship struct {
	BaseReq rest.BaseReq `json:"base_req" yaml:"base_req"`
	KeyID   string       `json:"key_id" yaml:"key_id"`
}

ReqCreateTransferOperatorship represents a request to create transfer operatorship command

type ReqCreateTransferOwnership

type ReqCreateTransferOwnership struct {
	BaseReq rest.BaseReq `json:"base_req" yaml:"base_req"`
	KeyID   string       `json:"key_id" yaml:"key_id"`
}

ReqCreateTransferOwnership represents a request to create transfer ownership command

type ReqLink struct {
	BaseReq        rest.BaseReq `json:"base_req" yaml:"base_req"`
	RecipientChain string       `json:"chain" yaml:"chain"`
	RecipientAddr  string       `json:"recipient" yaml:"recipient"`
	Asset          string       `json:"asset" yaml:"asset"`
}

ReqLink represents a request to link a cross-chain address to an EVM chain address

type ReqSignCommands

type ReqSignCommands struct {
	BaseReq rest.BaseReq `json:"base_req" yaml:"base_req"`
}

ReqSignCommands represents a request to sign pending commands

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL