Documentation
¶
Index ¶
- func AddrEvmToTron(address string) string
- func AddrTronToEvm(address string) string
- func CreateTRONAddress() (string, string, error)
- type Client
- func (c *Client) Balance(addr string) (*big.Int, error)
- func (c *Client) CheckBalance(addr string, fee *big.Int) error
- func (c *Client) Conn()
- func (c *Client) GetTRC20Transfers(addr string) (*TRC20TransfersResp, error)
- func (c *Client) SignTx(prk *ecdsa.PrivateKey, tx *core.Transaction) (*core.Transaction, error)
- func (c *Client) SunpumpLaunchpadCreateAndInitPurchase(contractAddr string, prkHex string, symbol string, name string) (string, error)
- func (c *Client) SystemPromptManagerMint(contractAddr string, prkHex string, to common.Address, uri string, data []byte, ...) (string, error)
- func (c *Client) TRC20ApproveMax(contractAddr string, prkHex string, toAddr string) (string, error)
- func (c *Client) TRC20Call(from, contractAddress, data string, constant bool, value, feeLimit int64) (*api.TransactionExtention, error)
- func (c *Client) Trc20Balance(erc20Addr string, addr string) (*big.Int, error)
- type TRC20TransfersResp
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func AddrEvmToTron ¶
func AddrTronToEvm ¶
func CreateTRONAddress ¶
Types ¶
type Client ¶
type Client struct { ApiURL string RpcURL string GrpcURL string APIKey string // contains filtered or unexported fields }
func (*Client) GetTRC20Transfers ¶
func (c *Client) GetTRC20Transfers(addr string) (*TRC20TransfersResp, error)
func (*Client) SignTx ¶
func (c *Client) SignTx(prk *ecdsa.PrivateKey, tx *core.Transaction) (*core.Transaction, error)
func (*Client) SunpumpLaunchpadCreateAndInitPurchase ¶
func (*Client) SystemPromptManagerMint ¶
func (*Client) TRC20ApproveMax ¶
type TRC20TransfersResp ¶
type TRC20TransfersResp struct { Data []struct { BlockNumber int `json:"block_number"` BlockTimestamp int64 `json:"block_timestamp"` CallerContractAddress string `json:"caller_contract_address"` ContractAddress string `json:"contract_address"` EventIndex int `json:"event_index"` EventName string `json:"event_name"` Result struct { Num0 string `json:"0"` Num1 string `json:"1"` Num2 string `json:"2"` From string `json:"from"` To string `json:"to"` Value numeric.BigInt `json:"value"` } `json:"result"` ResultType struct { From string `json:"from"` To string `json:"to"` Value string `json:"value"` } `json:"result_type"` Event string `json:"event"` TransactionID string `json:"transaction_id"` } `json:"data"` Success bool `json:"success"` Meta struct { At int64 `json:"at"` PageSize int `json:"page_size"` } `json:"meta"` }
Click to show internal directories.
Click to hide internal directories.