rest

package
v1.9.0 Latest Latest
Warning

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

Go to latest
Published: Apr 25, 2022 License: Apache-2.0 Imports: 12 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func NewBindNameRequestHandlerFn

func NewBindNameRequestHandlerFn(clientCtx client.Context) http.HandlerFunc

NewBindNameRequestHandlerFn returns an HTTP handler for binding names to addresses.

func RegisterHandlers

func RegisterHandlers(clientCtx client.Context, rtr *mux.Router)

RegisterHandlers registers the rest query and tx handlers

func RootNameProposalHandler added in v1.8.0

func RootNameProposalHandler(clientCtx client.Context) govrest.ProposalRESTHandler

RootNameProposalHandler returns a ProposalRESTHandler that exposes the create root name REST handler with a given sub-route.

Types

type BindNameRequest

type BindNameRequest struct {
	BaseReq    rest.BaseReq `json:"base_req"`
	Name       string       `json:"name"`
	Address    string       `json:"address"`
	RootName   string       `json:"root"`
	Restricted bool         `json:"restricted"`
}

BindNameRequest type for binding names to addresses.

type CreateRootNameProposalReq added in v1.8.0

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

	Title       string         `json:"title" yaml:"title"`
	Description string         `json:"description" yaml:"description"`
	Owner       sdk.AccAddress `json:"owner" yaml:"owner"`
	Name        string         `json:"name" yaml:"name"`
	Restricted  bool           `json:"restricted" yaml:"restricted"`
	Proposer    sdk.AccAddress `json:"proposer" yaml:"proposer"`
	Deposit     sdk.Coins      `json:"deposit" yaml:"deposit"`
}

CreateRootNameProposalReq defines a create root name proposal request body.

Jump to

Keyboard shortcuts

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