Documentation
¶
Index ¶
- Variables
- func NewEthereumEndpoints() []*api.Endpoint
- func RegisterEthereumHandler(s server.Server, hdlr EthereumHandler, opts ...server.HandlerOption) error
- type BalanceRequest
- type BalanceResponse
- type BroadcastRequest
- type BroadcastResponse
- type EthereumHandler
- type EthereumService
- type TransactionRequest
- func (*TransactionRequest) Descriptor() ([]byte, []int)deprecated
- func (x *TransactionRequest) GetHash() string
- func (*TransactionRequest) ProtoMessage()
- func (x *TransactionRequest) ProtoReflect() protoreflect.Message
- func (x *TransactionRequest) Reset()
- func (x *TransactionRequest) String() string
- type TransactionResponse
- func (*TransactionResponse) Descriptor() ([]byte, []int)deprecated
- func (x *TransactionResponse) GetBlockHash() string
- func (x *TransactionResponse) GetBlockNumber() string
- func (x *TransactionResponse) GetChainId() string
- func (x *TransactionResponse) GetFromAddress() string
- func (x *TransactionResponse) GetGas() string
- func (x *TransactionResponse) GetGasPrice() string
- func (x *TransactionResponse) GetHash() string
- func (x *TransactionResponse) GetInput() string
- func (x *TransactionResponse) GetMaxFeePerGas() string
- func (x *TransactionResponse) GetMaxPriorityFeePerGas() string
- func (x *TransactionResponse) GetNonce() string
- func (x *TransactionResponse) GetR() string
- func (x *TransactionResponse) GetS() string
- func (x *TransactionResponse) GetToAddress() string
- func (x *TransactionResponse) GetTxIndex() string
- func (x *TransactionResponse) GetType() string
- func (x *TransactionResponse) GetV() string
- func (x *TransactionResponse) GetValue() string
- func (*TransactionResponse) ProtoMessage()
- func (x *TransactionResponse) ProtoReflect() protoreflect.Message
- func (x *TransactionResponse) Reset()
- func (x *TransactionResponse) String() string
Constants ¶
This section is empty.
Variables ¶
View Source
var File_proto_ethereum_proto protoreflect.FileDescriptor
Functions ¶
func NewEthereumEndpoints ¶
func RegisterEthereumHandler ¶
func RegisterEthereumHandler(s server.Server, hdlr EthereumHandler, opts ...server.HandlerOption) error
Types ¶
type BalanceRequest ¶
type BalanceRequest struct {
// address of wallet
Address string `protobuf:"bytes,1,opt,name=address,proto3" json:"address,omitempty"`
// contains filtered or unexported fields
}
Get the balance of an ethereum wallet
func (*BalanceRequest) Descriptor
deprecated
func (*BalanceRequest) Descriptor() ([]byte, []int)
Deprecated: Use BalanceRequest.ProtoReflect.Descriptor instead.
func (*BalanceRequest) GetAddress ¶
func (x *BalanceRequest) GetAddress() string
func (*BalanceRequest) ProtoMessage ¶
func (*BalanceRequest) ProtoMessage()
func (*BalanceRequest) ProtoReflect ¶
func (x *BalanceRequest) ProtoReflect() protoreflect.Message
func (*BalanceRequest) Reset ¶
func (x *BalanceRequest) Reset()
func (*BalanceRequest) String ¶
func (x *BalanceRequest) String() string
type BalanceResponse ¶
type BalanceResponse struct {
// the account balance (in wei)
Balance int64 `protobuf:"varint,1,opt,name=balance,proto3" json:"balance,omitempty"`
// contains filtered or unexported fields
}
func (*BalanceResponse) Descriptor
deprecated
func (*BalanceResponse) Descriptor() ([]byte, []int)
Deprecated: Use BalanceResponse.ProtoReflect.Descriptor instead.
func (*BalanceResponse) GetBalance ¶
func (x *BalanceResponse) GetBalance() int64
func (*BalanceResponse) ProtoMessage ¶
func (*BalanceResponse) ProtoMessage()
func (*BalanceResponse) ProtoReflect ¶
func (x *BalanceResponse) ProtoReflect() protoreflect.Message
func (*BalanceResponse) Reset ¶
func (x *BalanceResponse) Reset()
func (*BalanceResponse) String ¶
func (x *BalanceResponse) String() string
type BroadcastRequest ¶
type BroadcastRequest struct {
// raw transaction data to broadcast
Hex string `protobuf:"bytes,1,opt,name=hex,proto3" json:"hex,omitempty"`
// contains filtered or unexported fields
}
Broadcast presigned transaction to ethereum network
func (*BroadcastRequest) Descriptor
deprecated
func (*BroadcastRequest) Descriptor() ([]byte, []int)
Deprecated: Use BroadcastRequest.ProtoReflect.Descriptor instead.
func (*BroadcastRequest) GetHex ¶
func (x *BroadcastRequest) GetHex() string
func (*BroadcastRequest) ProtoMessage ¶
func (*BroadcastRequest) ProtoMessage()
func (*BroadcastRequest) ProtoReflect ¶
func (x *BroadcastRequest) ProtoReflect() protoreflect.Message
func (*BroadcastRequest) Reset ¶
func (x *BroadcastRequest) Reset()
func (*BroadcastRequest) String ¶
func (x *BroadcastRequest) String() string
type BroadcastResponse ¶
type BroadcastResponse struct {
// the transaction hash
Hash string `protobuf:"bytes,1,opt,name=hash,proto3" json:"hash,omitempty"`
// contains filtered or unexported fields
}
func (*BroadcastResponse) Descriptor
deprecated
func (*BroadcastResponse) Descriptor() ([]byte, []int)
Deprecated: Use BroadcastResponse.ProtoReflect.Descriptor instead.
func (*BroadcastResponse) GetHash ¶
func (x *BroadcastResponse) GetHash() string
func (*BroadcastResponse) ProtoMessage ¶
func (*BroadcastResponse) ProtoMessage()
func (*BroadcastResponse) ProtoReflect ¶
func (x *BroadcastResponse) ProtoReflect() protoreflect.Message
func (*BroadcastResponse) Reset ¶
func (x *BroadcastResponse) Reset()
func (*BroadcastResponse) String ¶
func (x *BroadcastResponse) String() string
type EthereumHandler ¶
type EthereumHandler interface {
Balance(context.Context, *BalanceRequest, *BalanceResponse) error
Broadcast(context.Context, *BroadcastRequest, *BroadcastResponse) error
Transaction(context.Context, *TransactionRequest, *TransactionResponse) error
}
type EthereumService ¶
type EthereumService interface {
Balance(ctx context.Context, in *BalanceRequest, opts ...client.CallOption) (*BalanceResponse, error)
Broadcast(ctx context.Context, in *BroadcastRequest, opts ...client.CallOption) (*BroadcastResponse, error)
Transaction(ctx context.Context, in *TransactionRequest, opts ...client.CallOption) (*TransactionResponse, error)
}
func NewEthereumService ¶
func NewEthereumService(name string, c client.Client) EthereumService
type TransactionRequest ¶
type TransactionRequest struct {
// tx hash
Hash string `protobuf:"bytes,1,opt,name=hash,proto3" json:"hash,omitempty"`
// contains filtered or unexported fields
}
Get transaction details by hash
func (*TransactionRequest) Descriptor
deprecated
func (*TransactionRequest) Descriptor() ([]byte, []int)
Deprecated: Use TransactionRequest.ProtoReflect.Descriptor instead.
func (*TransactionRequest) GetHash ¶
func (x *TransactionRequest) GetHash() string
func (*TransactionRequest) ProtoMessage ¶
func (*TransactionRequest) ProtoMessage()
func (*TransactionRequest) ProtoReflect ¶
func (x *TransactionRequest) ProtoReflect() protoreflect.Message
func (*TransactionRequest) Reset ¶
func (x *TransactionRequest) Reset()
func (*TransactionRequest) String ¶
func (x *TransactionRequest) String() string
type TransactionResponse ¶
type TransactionResponse struct {
// tx hash
Hash string `protobuf:"bytes,1,opt,name=hash,proto3" json:"hash,omitempty"`
// the block hash
BlockHash string `protobuf:"bytes,2,opt,name=block_hash,json=blockHash,proto3" json:"block_hash,omitempty"`
// the block number
BlockNumber string `protobuf:"bytes,3,opt,name=block_number,json=blockNumber,proto3" json:"block_number,omitempty"`
// sent from
FromAddress string `protobuf:"bytes,4,opt,name=from_address,json=fromAddress,proto3" json:"from_address,omitempty"`
// gas
Gas string `protobuf:"bytes,5,opt,name=gas,proto3" json:"gas,omitempty"`
// gas price
GasPrice string `protobuf:"bytes,6,opt,name=gas_price,json=gasPrice,proto3" json:"gas_price,omitempty"`
// max fee per gas
MaxFeePerGas string `protobuf:"bytes,7,opt,name=max_fee_per_gas,json=maxFeePerGas,proto3" json:"max_fee_per_gas,omitempty"`
// max priority fee per gas
MaxPriorityFeePerGas string `` /* 127-byte string literal not displayed */
// input
Input string `protobuf:"bytes,9,opt,name=input,proto3" json:"input,omitempty"`
// the nonce
Nonce string `protobuf:"bytes,10,opt,name=nonce,proto3" json:"nonce,omitempty"`
// to address
ToAddress string `protobuf:"bytes,11,opt,name=to_address,json=toAddress,proto3" json:"to_address,omitempty"`
// transaction index
TxIndex string `protobuf:"bytes,12,opt,name=tx_index,json=txIndex,proto3" json:"tx_index,omitempty"`
// value of transaction
Value string `protobuf:"bytes,13,opt,name=value,proto3" json:"value,omitempty"`
// type of transaction
Type string `protobuf:"bytes,14,opt,name=type,proto3" json:"type,omitempty"`
// chain id
ChainId string `protobuf:"bytes,15,opt,name=chain_id,json=chainId,proto3" json:"chain_id,omitempty"`
V string `protobuf:"bytes,16,opt,name=v,proto3" json:"v,omitempty"`
R string `protobuf:"bytes,17,opt,name=r,proto3" json:"r,omitempty"`
S string `protobuf:"bytes,18,opt,name=s,proto3" json:"s,omitempty"`
// contains filtered or unexported fields
}
func (*TransactionResponse) Descriptor
deprecated
func (*TransactionResponse) Descriptor() ([]byte, []int)
Deprecated: Use TransactionResponse.ProtoReflect.Descriptor instead.
func (*TransactionResponse) GetBlockHash ¶
func (x *TransactionResponse) GetBlockHash() string
func (*TransactionResponse) GetBlockNumber ¶
func (x *TransactionResponse) GetBlockNumber() string
func (*TransactionResponse) GetChainId ¶
func (x *TransactionResponse) GetChainId() string
func (*TransactionResponse) GetFromAddress ¶
func (x *TransactionResponse) GetFromAddress() string
func (*TransactionResponse) GetGas ¶
func (x *TransactionResponse) GetGas() string
func (*TransactionResponse) GetGasPrice ¶
func (x *TransactionResponse) GetGasPrice() string
func (*TransactionResponse) GetHash ¶
func (x *TransactionResponse) GetHash() string
func (*TransactionResponse) GetInput ¶
func (x *TransactionResponse) GetInput() string
func (*TransactionResponse) GetMaxFeePerGas ¶
func (x *TransactionResponse) GetMaxFeePerGas() string
func (*TransactionResponse) GetMaxPriorityFeePerGas ¶
func (x *TransactionResponse) GetMaxPriorityFeePerGas() string
func (*TransactionResponse) GetNonce ¶
func (x *TransactionResponse) GetNonce() string
func (*TransactionResponse) GetR ¶
func (x *TransactionResponse) GetR() string
func (*TransactionResponse) GetS ¶
func (x *TransactionResponse) GetS() string
func (*TransactionResponse) GetToAddress ¶
func (x *TransactionResponse) GetToAddress() string
func (*TransactionResponse) GetTxIndex ¶
func (x *TransactionResponse) GetTxIndex() string
func (*TransactionResponse) GetType ¶
func (x *TransactionResponse) GetType() string
func (*TransactionResponse) GetV ¶
func (x *TransactionResponse) GetV() string
func (*TransactionResponse) GetValue ¶
func (x *TransactionResponse) GetValue() string
func (*TransactionResponse) ProtoMessage ¶
func (*TransactionResponse) ProtoMessage()
func (*TransactionResponse) ProtoReflect ¶
func (x *TransactionResponse) ProtoReflect() protoreflect.Message
func (*TransactionResponse) Reset ¶
func (x *TransactionResponse) Reset()
func (*TransactionResponse) String ¶
func (x *TransactionResponse) String() string
Click to show internal directories.
Click to hide internal directories.