Documentation ¶
Index ¶
- Constants
- func Path(ant MethodType) (rawpath string, method string)
- type ABIInfo
- type AccountInfo
- type AccountModuleInfo
- type AccountModuleReq
- type AccountModuleWithNameReq
- type AccountReq
- type AccountResourceInfo
- type AccountResourceReq
- type AccountResourceWithTypeReq
- type BlockByHeightReq
- type BlockByVersionReq
- type BlockInfo
- type ErrorMsg
- type EstimateGasPrice
- type EventByCreationNumberReq
- type EventByEventHandlerReq
- type EventInfo
- type ExposedFunction
- type GUIDInfo
- type GenericTypeParam
- type HealthyReq
- type HealthyRsp
- type LedgerInfo
- type LedgerRsp
- type MethodType
- type ModuleStruct
- type ModuleStructField
- type TransactionByHashReq
- type TransactionByVersionReq
- type TransactionChangeData
- type TransactionChangeDataEvent
- type TransactionChangeDataInfo
- type TransactionChangeInfo
- type TransactionGUID
- type TransactionID
- type TransactionInfo
- type TransactionOfAccountReq
- type TransactionPayload
- type TransactionReq
- type TransactionSignature
Constants ¶
View Source
const ( AccountPath = "GET@accounts/{address}" AccountResourcePath = "GET@accounts/{address}/resources" AccountModulePath = "GET@accounts/{address}/modules" AccountModuleWithNamePath = "GET@accounts/{address}/module/{module_name}" AccountResourceWithTypePath = "GET@accounts/{address}/resource/{resource_type}" )
View Source
const ( BlockByHeightPath = "GET@blocks/by_height/{height}" BlockByVersionPath = "GET@blocks/by_version/{version}" )
View Source
const ( EventByCreationNumberPath = "GET@accounts/{address}/events/{creation_number}" EventByEventHandlerPath = "GET@accounts/{address}/events/{event_handle}/{field_name}" )
View Source
const ( HealthyPath = "GET@-/healthy" LedgerPath = "GET@" )
View Source
const ( TransactionPath = "GET@transactions" TransactionByHashPath = "GET@transactions/by_hash/{txn_hash}" TransactionByVersionPath = "GET@transactions/by_version/{txn_version}" TransactionOfAccountPath = "GET@accounts/{address}/transactions" TransactionEncodingPath = "POST@transactions/encode_submission" TransactionSimulatePath = "POST@transactions/simulate" TransactionSubmitPath = "POST@transactions" EstimateGasPricePath = "GET@estimate_gas_price" )
Variables ¶
This section is empty.
Functions ¶
func Path ¶
func Path(ant MethodType) (rawpath string, method string)
Types ¶
type ABIInfo ¶
type ABIInfo struct { Address string `json:"address"` Name string `json:"name"` Friends []string `json:"friends"` ExposedFunctions []ExposedFunction `json:"exposed_functions"` Structs []ModuleStruct `json:"structs"` }
type AccountInfo ¶
type AccountModuleInfo ¶
type AccountModuleReq ¶
type AccountReq ¶
type AccountResourceInfo ¶
type AccountResourceInfo struct { Type string `json:"type"` Data json.RawMessage `json:"data"` }
type AccountResourceReq ¶
type BlockByHeightReq ¶
type BlockByVersionReq ¶
type ErrorMsg ¶
type EstimateGasPrice ¶
type EventByEventHandlerReq ¶
type ExposedFunction ¶
type GenericTypeParam ¶
type GenericTypeParam struct {
Constraints []string `json:"constraints"`
}
type HealthyReq ¶
type HealthyReq struct {
Duration uint32 `param:"duration_secs,omitempty"`
}
type HealthyRsp ¶
type HealthyRsp struct {
Message string `json:"message"`
}
type LedgerInfo ¶
type LedgerInfo struct { ChainID int `json:"chain_id"` Epoch string `json:"epoch"` LedgerVersion string `json:"ledger_version"` OldestLedgerVersion string `json:"oldest_ledger_version"` LedgerTimestamp string `json:"ledger_timestamp"` NodeRole string `json:"node_role"` OldestBlockHeight string `json:"oldest_block_height"` BlockHeight string `json:"block_height"` GitHash string `json:"git_hash"` }
type LedgerRsp ¶
type LedgerRsp struct {
LedgerInfo
}
type MethodType ¶
type MethodType uint16
const ( MTHealthy MethodType = 0x1 MTLedger MethodType = 0x2 MTAccount MethodType = 0x3 MTAccountResource MethodType = 0x4 MTAccountModule MethodType = 0x5 MTAccountResourceWithType MethodType = 0x6 MTAccountModuleWithName MethodType = 0x7 MTTransaction MethodType = 0xb MTTransactionByHash MethodType = 0xc MTTransactionByVersion MethodType = 0xd MTTransactionOfAccount MethodType = 0xe MTTransactionEncoding MethodType = 0x11 MTTransactionSimulate MethodType = 0x12 MTTransactionSubmit MethodType = 0x13 MTBlockByHeight MethodType = 0x14 MTBlockByVersion MethodType = 0x15 MTEventByCreationNumber MethodType = 0x16 MTEventByEventHandler MethodType = 0x17 MTEstimateGasPrice MethodType = 0x18 )
type ModuleStruct ¶
type ModuleStruct struct { Name string `json:"name"` IsNative bool `json:"is_native"` Abilities []string `json:"abilities"` GenericTypeParams []GenericTypeParam `json:"generic_type_params"` Fields []ModuleStructField `json:"fields"` }
type ModuleStructField ¶
type TransactionByHashReq ¶
type TransactionByHashReq struct {
Hash string `path:"txn_hash"`
}
type TransactionByVersionReq ¶
type TransactionByVersionReq struct {
Version uint64 `path:"txn_version"`
}
type TransactionChangeData ¶
type TransactionChangeData struct { Address string `json:"address"` StateKeyHash string `json:"state_key_hash"` Type string `json:"type"` Data TransactionChangeDataInfo `json:"data"` }
type TransactionChangeDataEvent ¶
type TransactionChangeDataEvent struct { Counter string `json:"counter"` GUID TransactionGUID `json:"guid"` }
type TransactionChangeDataInfo ¶
type TransactionChangeDataInfo struct { EpochInterval string `json:"epoch_interval"` Height string `json:"height"` NewBlockEvents TransactionChangeDataEvent `json:"new_block_events"` }
type TransactionChangeInfo ¶
type TransactionChangeInfo struct { Address string `json:"address"` StateKeyHash string `json:"state_key_hash"` Data TransactionChangeData `json:"data"` Type string `json:"type"` }
type TransactionGUID ¶
type TransactionGUID struct {
ID TransactionID `json:"id"`
}
type TransactionID ¶
type TransactionInfo ¶
type TransactionInfo struct { Version string `json:"version"` Hash string `json:"hash"` StateChangeHash string `json:"state_change_hash"` EventRootHash string `json:"event_root_hash"` StateCheckpointHash string `json:"state_checkpoint_hash"` GasUsed string `json:"gas_used"` Success bool `json:"success"` VMStatus string `json:"vm_status"` AccumulatorRootHash string `json:"accumulator_root_hash"` Changes []json.RawMessage `json:"changes"` ID string `json:"id,omitempty"` Epoch string `json:"epoch,omitempty"` Round string `json:"round,omitempty"` Events []EventInfo `json:"events,omitempty"` PreviousBlockVotesBitvec []bool `json:"previous_block_votes_bitvec,omitempty"` Proposer string `json:"proposer,omitempty"` FailedProposerIndices []json.RawMessage `json:"failed_proposer_indices,omitempty"` Timestamp string `json:"timestamp"` Type string `json:"type"` Sender string `json:"sender,omitempty"` SequenceNumber string `json:"sequence_number,omitempty"` MaxGasAmount string `json:"max_gas_amount,omitempty"` GasUnitPrice string `json:"gas_unit_price,omitempty"` ExpirationTimestampSecs string `json:"expiration_timestamp_secs,omitempty"` Payload TransactionPayload `json:"payload,omitempty"` Signature TransactionSignature `json:"signature,omitempty"` }
type TransactionOfAccountReq ¶
type TransactionPayload ¶
type TransactionPayload struct { Function string `json:"function"` TypeArguments []string `json:"type_arguments"` Arguments []json.RawMessage `json:"arguments"` Type string `json:"type"` }
type TransactionReq ¶
type TransactionSignature ¶
Click to show internal directories.
Click to hide internal directories.