Documentation ¶
Index ¶
- Variables
- type AddStakeRequest
- type Apy
- type BalanceChanges
- type Base64Data
- type BatchTransactionRequest
- type BatchTransactionResponse
- type Bytes
- type CheckpointResponse
- type ChildObjectsResponse
- type CoinAllBalanceResponse
- type CoinBalanceResponse
- type CoinData
- type CoinLockedBalance
- type CoinMetadataResponse
- type DelegatedStakeInfo
- type DelegatedStakesResponse
- type Digest
- type DisplayFieldsResponse
- type DynamicFieldInfo
- type DynamicFieldName
- type EndOfEpochInfo
- type EpochInfo
- type EpochRollingGasCostSummary
- type EventFilterByMoveEventField
- type EventFilterByMoveEventType
- type EventFilterByMoveModule
- type EventFilterByPackage
- type EventFilterBySuiAddress
- type EventFilterByTimeRange
- type EventFilterByTransaction
- type EventId
- type ExecutionStatus
- type GasCostSummary
- type GetEventsResponse
- type GetMoveFunctionArgTypesRequest
- type GetMoveFunctionArgTypesResponse
- type GetNormalizedMoveFunctionRequest
- type GetNormalizedMoveFunctionResponse
- type GetNormalizedMoveModuleRequest
- type GetNormalizedMoveModuleResponse
- type GetNormalizedMoveModulesByPackageRequest
- type GetNormalizedMoveModulesByPackageResponse
- type GetNormalizedMoveStructRequest
- type GetNormalizedMoveStructResponse
- type GetTransactionMetaData
- type HexData
- type InputObjectKind
- type JsonRPCMessage
- type JsonRPCRequest
- type MergeCoinsRequest
- type ModifiedAtVersions
- type MoveCallRequest
- type MoveCallResponse
- type MoveCallSuiTransaction
- type MoveEventField
- type MoveFunction
- type MoveModule
- type ObjectChange
- type ObjectFilterByAddressOwner
- type ObjectFilterByObjectId
- type ObjectFilterByObjectIds
- type ObjectFilterByObjectOwner
- type ObjectFilterByPackage
- type ObjectFilterByStructType
- type ObjectFilterByVersion
- type ObjectId
- type ObjectOwner
- type ObjectRef
- type ObjectShare
- type OwnedObjectRef
- type PaginatedCheckpointsResponse
- type PaginatedCoinsResponse
- type PaginatedDynamicFieldInfoResponse
- type PaginatedEpochInfoResponse
- type PaginatedEventsResponse
- type PaginatedObjectsResponse
- type PastObjectResponse
- type PayAllSuiRequest
- type PayRequest
- type PaySuiRequest
- type ProgrammableTransaction
- type PublishRequest
- type RPCTransactionRequestParams
- type SigFlag
- type SigScheme
- type SignAndExecuteTransactionBlockRequest
- type SignAndExecuteTransactionBlockRequestWithKMS
- type SignedTransaction
- type SignedTransactionSerializedSig
- type SplitCoinEqualRequest
- type SplitCoinRequest
- type SuiAddress
- type SuiArgument
- type SuiCallArg
- type SuiDevInspectTransactionBlockRequest
- type SuiDryRunTransactionBlockRequest
- type SuiEffects
- type SuiEventFilter
- type SuiEventResponse
- type SuiExecuteTransactionBlockRequest
- type SuiGasData
- type SuiGetCheckpointRequest
- type SuiGetCheckpointsRequest
- type SuiGetEventsRequest
- type SuiGetLoadedChildObjectsRequest
- type SuiGetObjectRequest
- type SuiGetTransactionBlockRequest
- type SuiKeyPair
- type SuiLoadedChildObject
- type SuiMoveModuleId
- type SuiMoveNormalizedModule
- type SuiMoveObject
- type SuiMovePackage
- type SuiMultiGetObjectsRequest
- type SuiMultiGetTransactionBlocksRequest
- type SuiMultiGetTransactionBlocksResponse
- type SuiObjectChangeCreated
- type SuiObjectChangeDeleted
- type SuiObjectChangeMutated
- type SuiObjectChangePublished
- type SuiObjectChangeTransferred
- type SuiObjectChangeWrapped
- type SuiObjectData
- type SuiObjectDataFilter
- type SuiObjectDataOptions
- type SuiObjectInfo
- type SuiObjectRef
- type SuiObjectResponse
- type SuiObjectResponseError
- type SuiObjectResponseQuery
- type SuiParsedData
- type SuiRawData
- type SuiRawMoveObject
- type SuiRawMovePackage
- type SuiSystemStateSummary
- type SuiTransaction
- type SuiTransactionBlock
- type SuiTransactionBlockData
- type SuiTransactionBlockKind
- type SuiTransactionBlockOptions
- type SuiTransactionBlockResponse
- type SuiTransactionBlockResponseQuery
- type SuiTryGetPastObjectRequest
- type SuiValidatorSummary
- type SuiXGetAllBalanceRequest
- type SuiXGetAllCoinsRequest
- type SuiXGetBalanceRequest
- type SuiXGetCoinMetadataRequest
- type SuiXGetCoinsRequest
- type SuiXGetCommitteeInfoRequest
- type SuiXGetCommitteeInfoResponse
- type SuiXGetDynamicFieldObjectRequest
- type SuiXGetDynamicFieldRequest
- type SuiXGetEpochsRequest
- type SuiXGetOwnedObjectsRequest
- type SuiXGetStakesByIdsRequest
- type SuiXGetStakesRequest
- type SuiXGetTotalSupplyRequest
- type SuiXQueryEventsRequest
- type SuiXQueryTransactionBlocksRequest
- type SuiXQueryTransactionBlocksResponse
- type SuiXResolveNameServiceAddressRequest
- type SuiXResolveNameServiceNamesRequest
- type SuiXResolveNameServiceNamesResponse
- type SuiXSubscribeEventsRequest
- type SuiXSubscribeTransactionsRequest
- type TimeRange
- type TotalSupplyResponse
- type TransactionDigest
- type TransactionFilter
- type TransactionFilterByChangedObjectFilter
- type TransactionFilterByFromAddress
- type TransactionFilterByInputObject
- type TransactionFilterByMoveFunction
- type TransactionFilterByToAddress
- type TransferObjectRequest
- type TransferSuiRequest
- type TxnMetaData
- type ValidatorsApy
- type WithdrawStakeRequest
Constants ¶
This section is empty.
Variables ¶
var IntentBytes = []byte{0, 0, 0}
Functions ¶
This section is empty.
Types ¶
type AddStakeRequest ¶
type AddStakeRequest struct { // the transaction signer's Sui address Signer string `json:"signer"` // Coin<SUI> object to stake Coins []string `json:"coins"` // stake amount Amount string `json:"amount"` // the validator's Sui address Validator string `json:"validator"` // gas object to be used in this transaction, node will pick one from the signer's possession if not provided Gas string `json:"gas"` // the gas budget, the transaction will fail if the gas cost exceed the budget GasBudget string `json:"gasBudget"` }
type BalanceChanges ¶
type BalanceChanges struct { Owner ObjectOwner `json:"owner"` CoinType string `json:"coinType"` Amount string `json:"amount"` }
type Base64Data ¶
type Base64Data struct {
// contains filtered or unexported fields
}
func NewBase64Data ¶
func NewBase64Data(str string) (*Base64Data, error)
func (Base64Data) Data ¶
func (h Base64Data) Data() []byte
type BatchTransactionRequest ¶
type BatchTransactionRequest struct { // the transaction signer's Sui address Signer string `json:"signer"` // list of transaction request parameters RPCTransactionRequestParams []RPCTransactionRequestParams `json:"RPCTransactionRequestParams"` // gas object to be used in this transaction, node will pick one from the signer's possession if not provided Gas string `json:"gas"` // the gas budget, the transaction will fail if the gas cost exceed the budget GasBudget string `json:"gasBudget"` // Whether this is a regular transaction or a Dev Inspect Transaction // The optional enumeration values are: `DevInspect`, or `Commit` SuiTransactionBlockBuilderMode string `json:"suiTransactionBlockBuilderMode"` }
type BatchTransactionResponse ¶
type BatchTransactionResponse struct { Gas []sui_types.SuiObjectRef `json:"gas"` InputObjects []interface{} `json:"inputObjects"` TxBytes string `json:"txBytes"` }
type Bytes ¶
type Bytes []byte
func (Bytes) GetBase64Data ¶
func (b Bytes) GetBase64Data() Base64Data
func (Bytes) GetHexData ¶
type CheckpointResponse ¶
type CheckpointResponse struct { Epoch string `json:"epoch"` SequenceNumber string `json:"sequenceNumber"` Digest string `json:"digest"` NetworkTotalTransactions string `json:"networkTotalTransactions"` PreviousDigest string `json:"previousDigest"` EpochRollingGasCostSummary EpochRollingGasCostSummary `json:"epochRollingGasCostSummary"` TimestampMs string `json:"timestampMs"` Transactions []string `json:"transactions"` CheckpointCommitments []interface{} `json:"checkpointCommitments"` ValidatorSignature string `json:"validatorSignature"` }
type ChildObjectsResponse ¶
type ChildObjectsResponse struct {
LoadedChildObjects []*SuiLoadedChildObject `json:"loadedChildObjects"`
}
type CoinAllBalanceResponse ¶
type CoinAllBalanceResponse []CoinBalanceResponse
type CoinBalanceResponse ¶
type CoinBalanceResponse struct { CoinType string `json:"coinType"` CoinObjectCount int `json:"coinObjectCount"` TotalBalance string `json:"totalBalance"` LockedBalance CoinLockedBalance `json:"lockedBalance"` }
type CoinData ¶
type CoinData struct { CoinType string `json:"coinType"` CoinObjectId string `json:"coinObjectId"` Version string `json:"version"` Digest string `json:"digest"` Balance string `json:"balance"` LockedUntilEpoch uint64 `json:"lockedUntilEpoch"` PreviousTransaction string `json:"previousTransaction"` }
type CoinLockedBalance ¶
type CoinMetadataResponse ¶
type DelegatedStakeInfo ¶
type DelegatedStakesResponse ¶
type DelegatedStakesResponse struct { ValidatorAddress string `json:"validatorAddress"` StakingPool string `json:"stakingPool"` Stakes []DelegatedStakeInfo `json:"stakes"` }
type Digest ¶
type Digest = Base64Data
type DisplayFieldsResponse ¶
type DisplayFieldsResponse struct { Data interface{} `json:"data,omitempty"` Error SuiObjectResponseError `json:"error,omitempty"` }
type DynamicFieldInfo ¶
type DynamicFieldName ¶
type DynamicFieldName struct { Type string `json:"type"` Value interface{} `json:"value"` }
type EndOfEpochInfo ¶
type EndOfEpochInfo struct { LastCheckpointId string `json:"lastCheckpointId"` EpochEndTimestamp string `json:"epochEndTimestamp"` ProtocolVersion string `json:"protocolVersion"` ReferenceGasPrice string `json:"referenceGasPrice"` TotalStake string `json:"totalStake"` StorageFundReinvestment string `json:"storageFundReinvestment"` StorageCharge string `json:"storageCharge"` StorageRebate string `json:"storageRebate"` StorageFundBalance string `json:"storageFundBalance"` StakeSubsidyAmount string `json:"stakeSubsidyAmount"` TotalGasFees string `json:"totalGasFees"` TotalStakeRewardsDistributed string `json:"totalStakeRewardsDistributed"` LeftoverStorageFundInflow string `json:"leftoverStorageFundInflow"` }
type EpochInfo ¶
type EpochInfo struct { Epoch string `json:"epoch"` Validators []SuiValidatorSummary `json:"validators"` EpochTotalTransactions string `json:"epochTotalTransactions"` FirstCheckpointId string `json:"firstCheckpointId"` EpochStartTimestamp string `json:"epochStartTimestamp"` EndOfEpochInfo EndOfEpochInfo `json:"endOfEpochInfo"` }
type EventFilterByMoveEventField ¶
type EventFilterByMoveEventField struct {
MoveEventField MoveEventField `json:"MoveEventField"`
}
the event query by `MoveEventField`
type EventFilterByMoveEventType ¶
type EventFilterByMoveEventType struct {
MoveEventType string `json:"MoveEventType"`
}
the event query by `MoveEventType`
type EventFilterByMoveModule ¶
type EventFilterByMoveModule struct {
MoveModule MoveModule `json:"MoveModule"`
}
the event query by `MoveModule`
type EventFilterByPackage ¶
type EventFilterByPackage struct {
Package string `json:"Package"`
}
the event query by `Package`
type EventFilterBySuiAddress ¶
type EventFilterBySuiAddress struct {
Sender string `json:"Sender"`
}
the event query by `Sender`
type EventFilterByTimeRange ¶
type EventFilterByTimeRange struct {
TimeRange TimeRange `json:"TimeRange"`
}
the event query by `TimeRange`
type EventFilterByTransaction ¶
type EventFilterByTransaction struct {
Transaction string `json:"Transaction"`
}
the event query by `Transaction`
type ExecutionStatus ¶
type GasCostSummary ¶
type GetEventsResponse ¶
type GetEventsResponse []*SuiEventResponse
type GetMoveFunctionArgTypesResponse ¶
type GetMoveFunctionArgTypesResponse []interface{}
type GetNormalizedMoveFunctionResponse ¶
type GetNormalizedMoveFunctionResponse sui_json_rpc_types.SuiMoveNormalizedFunction
type GetNormalizedMoveModuleResponse ¶
type GetNormalizedMoveModuleResponse sui_json_rpc_types.SuiMoveNormalizedModule
type GetNormalizedMoveModulesByPackageRequest ¶
type GetNormalizedMoveModulesByPackageRequest struct {
Package string `json:"package"`
}
type GetNormalizedMoveModulesByPackageResponse ¶
type GetNormalizedMoveModulesByPackageResponse map[string]sui_json_rpc_types.SuiMoveNormalizedModule
type GetNormalizedMoveStructResponse ¶
type GetNormalizedMoveStructResponse sui_json_rpc_types.SuiMoveNormalizedStruct
type GetTransactionMetaData ¶
type InputObjectKind ¶
type InputObjectKind map[string]interface{}
type JsonRPCMessage ¶
type JsonRPCMessage struct { Version string `json:"jsonrpc,omitempty"` ID json.RawMessage `json:"id,omitempty"` Method string `json:"method,omitempty"` Params json.RawMessage `json:"params,omitempty"` Error *jsonError `json:"error,omitempty"` Result json.RawMessage `json:"result,omitempty"` }
JsonRPCMessage value of this type can a JSON-RPC request, notification, successful response or error response. Which one it is depends on the fields.
type JsonRPCRequest ¶
type MergeCoinsRequest ¶
type MergeCoinsRequest struct { // the transaction signer's Sui address Signer string `json:"signer"` PrimaryCoin string `json:"primaryCoin"` CoinToMerge string `json:"coinToMerge"` // gas object to be used in this transaction, node will pick one from the signer's possession if not provided Gas string `json:"gas"` // the gas budget, the transaction will fail if the gas cost exceed the budget GasBudget string `json:"gasBudget"` }
type ModifiedAtVersions ¶
type MoveCallRequest ¶
type MoveCallRequest struct { // the transaction signer's Sui address Signer string `json:"signer"` // the package containing the module and function PackageObjectId string `json:"packageObjectId"` // the specific module in the package containing the function Module string `json:"module"` // the function to be called Function string `json:"function"` // the type arguments to the function TypeArguments []interface{} `json:"typeArguments"` // the arguments to the function Arguments []interface{} `json:"arguments"` // gas object to be used in this transaction, node will pick one from the signer's possession if not provided Gas string `json:"gas"` // the gas budget, the transaction will fail if the gas cost exceed the budget GasBudget string `json:"gasBudget"` }
type MoveCallResponse ¶
type MoveCallResponse struct { Gas []sui_types.SuiObjectRef `json:"gas"` InputObjects interface{} `json:"inputObjects"` TxBytes string `json:"txBytes"` }
type MoveCallSuiTransaction ¶
type MoveEventField ¶
type MoveFunction ¶
type MoveModule ¶
type ObjectChange ¶
type ObjectChange struct { Type string `json:"type"` Sender string `json:"sender"` Owner ObjectOwner `json:"owner"` ObjectType string `json:"objectType"` ObjectId string `json:"objectId"` PackageId string `json:"packageId"` Modules []string `json:"modules"` Version string `json:"version"` PreviousVersion string `json:"previousVersion,omitempty"` Digest string `json:"digest"` }
type ObjectFilterByAddressOwner ¶
type ObjectFilterByAddressOwner struct {
AddressOwner string `json:"AddressOwner"`
}
type ObjectFilterByObjectId ¶
type ObjectFilterByObjectId struct {
ObjectId string `json:"ObjectId"`
}
type ObjectFilterByObjectIds ¶
type ObjectFilterByObjectIds struct {
ObjectIds []string `json:"ObjectIds"`
}
type ObjectFilterByObjectOwner ¶
type ObjectFilterByObjectOwner struct {
ObjectOwner string `json:"ObjectOwner"`
}
type ObjectFilterByPackage ¶
type ObjectFilterByPackage struct {
Package string `json:"Package"`
}
type ObjectFilterByStructType ¶
type ObjectFilterByStructType struct {
StructType string `json:"StructType"`
}
type ObjectFilterByVersion ¶
type ObjectFilterByVersion struct {
Version string `json:"Version"`
}
type ObjectOwner ¶
type ObjectShare ¶
type ObjectShare struct {
}type OwnedObjectRef ¶
type OwnedObjectRef struct { Owner interface{} `json:"owner"` Reference SuiObjectRef `json:"reference"` }
type PaginatedCheckpointsResponse ¶
type PaginatedCheckpointsResponse struct { Data []CheckpointResponse `json:"data"` NextCursor string `json:"nextCursor"` HasNextPage bool `json:"hasNextPage"` }
type PaginatedCoinsResponse ¶
type PaginatedDynamicFieldInfoResponse ¶
type PaginatedDynamicFieldInfoResponse struct { Data []DynamicFieldInfo `json:"data"` NextCursor string `json:"nextCursor"` HasNextPage bool `json:"hasNextPage"` }
type PaginatedEventsResponse ¶
type PaginatedEventsResponse struct { Data []SuiEventResponse `json:"data"` NextCursor EventId `json:"nextCursor"` HasNextPage bool `json:"hasNextPage"` }
type PaginatedObjectsResponse ¶
type PaginatedObjectsResponse struct { Data []SuiObjectResponse `json:"data"` NextCursor string `json:"nextCursor"` HasNextPage bool `json:"hasNextPage"` }
type PastObjectResponse ¶
type PastObjectResponse struct { Status string `json:"status"` Details SuiObjectData `json:"details"` }
type PayAllSuiRequest ¶
type PayRequest ¶
type PayRequest struct { // the transaction signer's Sui address Signer string `json:"signer"` SuiObjectId []string `json:"suiObjectId"` Recipient []string `json:"recipient"` Amount []string `json:"amount"` // gas object to be used in this transaction, node will pick one from the signer's possession if not provided Gas string `json:"gas"` // the gas budget, the transaction will fail if the gas cost exceed the budget GasBudget string `json:"gasBudget"` }
type PaySuiRequest ¶
type PaySuiRequest struct { // the transaction signer's Sui address Signer string `json:"signer"` SuiObjectId []string `json:"suiObjectId"` Recipient []string `json:"recipient"` Amount []string `json:"amount"` // the gas budget, the transaction will fail if the gas cost exceed the budget GasBudget string `json:"gasBudget"` }
type ProgrammableTransaction ¶
type ProgrammableTransaction struct { Transactions []SuiTransaction `json:"transactions"` Inputs []SuiCallArg `json:"inputs"` }
type PublishRequest ¶
type PublishRequest struct { // the transaction signer's Sui address Sender string `json:"sender"` CompiledModules []string `json:"compiled_modules"` Dependencies []string `json:"dependencies"` // gas object to be used in this transaction, node will pick one from the signer's possession if not provided Gas string `json:"gas"` // the gas budget, the transaction will fail if the gas cost exceed the budget GasBudget string `json:"gasBudget"` }
type RPCTransactionRequestParams ¶
type RPCTransactionRequestParams struct { MoveCallRequestParams *MoveCallRequest `json:"moveCallRequestParams,omitempty"` TransferObjectRequestParams *TransferObjectRequest `json:"transferObjectRequestParams,omitempty"` }
type SignAndExecuteTransactionBlockRequest ¶
type SignAndExecuteTransactionBlockRequest struct { TxnMetaData TxnMetaData // the address private key to sign the transaction PriKey ed25519.PrivateKey Options SuiTransactionBlockOptions `json:"options"` // The optional enumeration values are: `WaitForEffectsCert`, or `WaitForLocalExecution` RequestType string `json:"requestType"` }
type SignAndExecuteTransactionBlockRequestWithKMS ¶
type SignAndExecuteTransactionBlockRequestWithKMS struct { TxnMetaData TxnMetaData KeyId string Kms *kms.KMS PublicKey []byte Options SuiTransactionBlockOptions `json:"options"` // The optional enumeration values are: `WaitForEffectsCert`, or `WaitForLocalExecution` RequestType string `json:"requestType"` }
type SignedTransaction ¶
type SignedTransaction struct { // transaction data bytes TxBytes string `json:"tx_bytes"` // Flag of the signature scheme that is used. SigScheme SigScheme `json:"sig_scheme"` // transaction signature Signature *Base64Data `json:"signature"` // signer's public key PublicKey *Base64Data `json:"pub_key"` }
type SplitCoinEqualRequest ¶
type SplitCoinEqualRequest struct { // the transaction signer's Sui address Signer string `json:"signer"` CoinObjectId string `json:"coinObjectId"` SplitCount string `json:"splitCount"` // gas object to be used in this transaction, node will pick one from the signer's possession if not provided Gas string `json:"gas"` // the gas budget, the transaction will fail if the gas cost exceed the budget GasBudget string `json:"gasBudget"` }
type SplitCoinRequest ¶
type SplitCoinRequest struct { // the transaction signer's Sui address Signer string `json:"signer"` CoinObjectId string `json:"coinObjectId"` SplitAmounts []string `json:"splitAmounts"` // gas object to be used in this transaction, node will pick one from the signer's possession if not provided Gas string `json:"gas"` // the gas budget, the transaction will fail if the gas cost exceed the budget GasBudget string `json:"gasBudget"` }
type SuiAddress ¶
type SuiAddress string
type SuiArgument ¶
type SuiArgument map[string]interface{}
type SuiCallArg ¶
type SuiCallArg map[string]interface{}
type SuiDevInspectTransactionBlockRequest ¶
type SuiDevInspectTransactionBlockRequest struct { // the transaction signer's Sui address Sender string `json:"sender"` // BCS encoded TransactionKind(as opposed to TransactionData, which include gasBudget and gasPrice) TxBytes string `json:"txBytes"` // Gas is not charged, but gas usage is still calculated. Default to use reference gas price GasPrice string `json:"gasPrice"` // The epoch to perform the call. Will be set from the system state object if not provided Epoch string `json:"epoch"` }
type SuiDryRunTransactionBlockRequest ¶
type SuiDryRunTransactionBlockRequest struct {
TxBytes string `json:"txBytes"`
}
type SuiEffects ¶
type SuiEffects struct { MessageVersion string `json:"messageVersion"` Status ExecutionStatus `json:"status"` ExecutedEpoch string `json:"executedEpoch"` GasUsed GasCostSummary `json:"gasUsed"` ModifiedAtVersions []ModifiedAtVersions `json:"modifiedAtVersions"` TransactionDigest string `json:"transactionDigest"` Created []OwnedObjectRef `json:"created"` Mutated []OwnedObjectRef `json:"mutated"` Deleted []SuiObjectRef `json:"deleted"` GasObject OwnedObjectRef `json:"gasObject"` EventsDigest string `json:"eventsDigest"` Dependencies []string `json:"dependencies"` }
type SuiEventFilter ¶
type SuiEventFilter map[string]interface{}
type SuiEventResponse ¶
type SuiEventResponse struct { Id EventId `json:"id"` PackageId string `json:"packageId"` TransactionModule string `json:"transactionModule"` Sender string `json:"sender"` Type string `json:"type"` ParsedJson map[string]interface{} `json:"parsedJson"` Bcs string `json:"bcs"` TimestampMs string `json:"timestampMs"` }
type SuiExecuteTransactionBlockRequest ¶
type SuiExecuteTransactionBlockRequest struct { // BCS serialized transaction data bytes without its type tag, as base-64 encoded string. TxBytes string `json:"txBytes"` // A list of signatures (`flag || signature || pubkey` bytes, as base-64 encoded string). // Signature is committed to the intent message of the transaction data, as base-64 encoded string. Signature []string `json:"signature"` // Options for specifying the content to be returned Options SuiTransactionBlockOptions `json:"options"` // The request type, derived from `SuiTransactionBlockResponseOptions` if None. // The optional enumeration values are: `WaitForEffectsCert`, or `WaitForLocalExecution` RequestType string `json:"requestType"` }
type SuiGasData ¶
type SuiGasData struct { Payment []SuiObjectRef `json:"payment"` // the owner's Sui address Owner string `json:"owner"` Price string `json:"price"` Budget string `json:"budget"` }
type SuiGetCheckpointRequest ¶
type SuiGetCheckpointRequest struct {
CheckpointID string `json:"id"`
}
type SuiGetCheckpointsRequest ¶
type SuiGetCheckpointsRequest struct { // optional paging cursor Cursor interface{} `json:"cursor"` // maximum number of items per page Limit uint64 `json:"limit" validate:"lte=50"` // query result ordering, default to false (ascending order), oldest record first DescendingOrder bool `json:"descendingOrder"` }
type SuiGetEventsRequest ¶
type SuiGetEventsRequest struct {
Digest string `json:"digest"`
}
type SuiGetLoadedChildObjectsRequest ¶
type SuiGetLoadedChildObjectsRequest struct {
Digest string `json:"digest"`
}
type SuiGetObjectRequest ¶
type SuiGetObjectRequest struct { // the ID of the queried object ObjectId string `json:"ObjectId"` // config which fields to include in the response, by default only digest is included Options SuiObjectDataOptions `json:"options"` }
type SuiGetTransactionBlockRequest ¶
type SuiGetTransactionBlockRequest struct { Digest string `json:"digest"` Options SuiTransactionBlockOptions `json:"options"` }
type SuiKeyPair ¶
type SuiLoadedChildObject ¶
type SuiMoveModuleId ¶
type SuiMoveNormalizedModule ¶
type SuiMoveNormalizedModule struct { FileFormatVersion uint64 Address string Name string Friends []SuiMoveModuleId }
type SuiMoveObject ¶
type SuiMovePackage ¶
type SuiMovePackage struct {
Disassembled string `json:"disassembled"`
}
type SuiMultiGetObjectsRequest ¶
type SuiMultiGetObjectsRequest struct { ObjectIds []string `json:"objectIds"` Options SuiObjectDataOptions `json:"options"` }
type SuiMultiGetTransactionBlocksRequest ¶
type SuiMultiGetTransactionBlocksRequest struct { Digests []string `json:"digests"` Options SuiTransactionBlockOptions `json:"options"` }
type SuiMultiGetTransactionBlocksResponse ¶
type SuiMultiGetTransactionBlocksResponse []*SuiTransactionBlockResponse
type SuiObjectChangeCreated ¶
type SuiObjectChangeDeleted ¶
type SuiObjectChangeMutated ¶
type SuiObjectChangeMutated struct { Type string `json:"type"` Sender string `json:"sender"` Owner ObjectOwner `json:"owner"` ObjectType string `json:"objectType"` ObjectId string `json:"objectId"` Version int `json:"version"` PreviousVersion int `json:"previousVersion"` Digest string `json:"digest"` }
type SuiObjectChangeWrapped ¶
type SuiObjectData ¶
type SuiObjectData struct { ObjectId string `json:"objectId"` Version string `json:"version"` Digest string `json:"digest"` Type string `json:"type"` Owner interface{} `json:"owner"` PreviousTransaction string `json:"previousTransaction"` Display DisplayFieldsResponse `json:"display"` Content SuiParsedData `json:"content"` Bcs SuiRawData `json:"bcs"` }
type SuiObjectDataFilter ¶
type SuiObjectDataFilter map[string]interface{}
type SuiObjectDataOptions ¶
type SuiObjectDataOptions struct { ShowType bool `json:"showType"` ShowContent bool `json:"showContent"` ShowBcs bool `json:"showBcs"` ShowOwner bool `json:"showOwner"` ShowPreviousTransaction bool `json:"showPreviousTransaction"` ShowStorageRebate bool `json:"showStorageRebate"` ShowDisplay bool `json:"showDisplay"` }
type SuiObjectInfo ¶
type SuiObjectRef ¶
type SuiObjectResponse ¶
type SuiObjectResponse struct { Data SuiObjectData `json:"data"` Error SuiObjectResponseError `json:"error"` }
type SuiObjectResponseError ¶
type SuiObjectResponseQuery ¶
type SuiObjectResponseQuery struct { // If None, no filter will be applied Filter interface{} `json:"filter"` // config which fields to include in the response, by default only digest is included Options SuiObjectDataOptions `json:"options"` }
type SuiParsedData ¶
type SuiParsedData struct { DataType string `json:"dataType"` SuiMoveObject SuiMovePackage }
type SuiRawData ¶
type SuiRawData struct { DataType string `json:"dataType"` SuiRawMoveObject SuiRawMovePackage }
type SuiRawMoveObject ¶
type SuiRawMovePackage ¶
type SuiSystemStateSummary ¶
type SuiSystemStateSummary struct { Epoch string `json:"epoch"` ProtocolVersion string `json:"protocolVersion"` SystemStateVersion string `json:"systemStateVersion"` StorageFundTotalObjectStorageRebates string `json:"storageFundTotalObjectStorageRebates"` StorageFundNonRefundableBalance string `json:"storageFundNonRefundableBalance"` ReferenceGasPrice string `json:"referenceGasPrice"` SafeMode bool `json:"safeMode"` SafeModeStorageRewards string `json:"safeModeStorageRewards"` SafeModeComputationRewards string `json:"safeModeComputationRewards"` SafeModeStorageRebates string `json:"safeModeStorageRebates"` SafeModeNonRefundableStorageFee string `json:"safeModeNonRefundableStorageFee"` EpochStartTimestampMs string `json:"epochStartTimestampMs"` EpochDurationMs string `json:"epochDurationMs"` StakeSubsidyStartEpoch string `json:"stakeSubsidyStartEpoch"` MaxValidatorCount string `json:"maxValidatorCount"` MinValidatorJoiningStake string `json:"minValidatorJoiningStake"` ValidatorLowStakeThreshold string `json:"validatorLowStakeThreshold"` ValidatorVeryLowStakeThreshold string `json:"validatorVeryLowStakeThreshold"` ValidatorLowStakeGracePeriod string `json:"validatorLowStakeGracePeriod"` StakeSubsidyBalance string `json:"stakeSubsidyBalance"` StakeSubsidyDistributionCounter string `json:"stakeSubsidyDistributionCounter"` StakeSubsidyCurrentDistributionAmount string `json:"stakeSubsidyCurrentDistributionAmount"` StakeSubsidyPeriodLength string `json:"stakeSubsidyPeriodLength"` StakeSubsidyDecreaseRate int `json:"stakeSubsidyDecreaseRate"` TotalStake string `json:"totalStake"` ActiveValidators []SuiValidatorSummary `json:"activeValidators"` PendingActiveValidatorsId string `json:"pendingActiveValidatorsId"` PendingActiveValidatorsSize string `json:"pendingActiveValidatorsSize"` PendingRemovals []string `json:"pendingRemovals"` StakingPoolMappingsId string `json:"stakingPoolMappingsId"` StakingPoolMappingsSize string `json:"stakingPoolMappingsSize"` InactivePoolsId string `json:"inactivePoolsId"` InactivePoolsSize string `json:"inactivePoolsSize"` ValidatorCandidatesId string `json:"validatorCandidatesId"` ValidatorCandidatesSize string `json:"validatorCandidatesSize"` AtRiskValidators []string `json:"atRiskValidators"` ValidatorReportRecords [][]interface{} `json:"validatorReportRecords"` }
type SuiTransaction ¶
type SuiTransaction struct { MakeMoveVec []interface{} `json:"MakeMoveVec,omitempty"` MergeCoins []interface{} `json:"MergeCoins,omitempty"` SplitCoins []interface{} `json:"SplitCoins,omitempty"` TransferObjects []interface{} `json:"TransferObjects,omitempty"` Publish []interface{} `json:"Publish,omitempty"` Upgrade []interface{} `json:"Upgrade,omitempty"` MoveCall MoveCallSuiTransaction `json:"MoveCall,omitempty"` }
type SuiTransactionBlock ¶
type SuiTransactionBlock struct { Data SuiTransactionBlockData `json:"data"` TxSignatures []string `json:"txSignatures"` }
type SuiTransactionBlockData ¶
type SuiTransactionBlockData struct { MessageVersion string `json:"messageVersion"` Transaction SuiTransactionBlockKind `json:"transaction"` Sender string `json:"sender"` GasData SuiGasData `json:"gasData"` }
type SuiTransactionBlockKind ¶
type SuiTransactionBlockKind struct { Kind string `json:"kind"` Inputs []SuiCallArg `json:"inputs"` Transactions []SuiTransaction `json:"transactions"` }
type SuiTransactionBlockOptions ¶
type SuiTransactionBlockOptions struct { ShowInput bool `json:"showInput,omitempty"` ShowRawInput bool `json:"showRawInput,omitempty"` ShowEffects bool `json:"showEffects,omitempty"` ShowEvents bool `json:"showEvents,omitempty"` ShowObjectChanges bool `json:"showObjectChanges,omitempty"` ShowBalanceChanges bool `json:"showBalanceChanges,omitempty"` }
type SuiTransactionBlockResponse ¶
type SuiTransactionBlockResponse struct { Digest string `json:"digest"` Transaction SuiTransactionBlock `json:"transaction,omitempty"` RawTransaction string `json:"rawTransaction,omitempty"` Effects SuiEffects `json:"effects,omitempty"` Events []SuiEventResponse `json:"events,omitempty"` ObjectChanges []ObjectChange `json:"objectChanges,omitempty"` BalanceChanges []BalanceChanges `json:"balanceChanges,omitempty"` TimestampMs string `json:"timestampMs,omitempty"` Checkpoint string `json:"checkpoint,omitempty"` ConfirmedLocalExecution bool `json:"confirmedLocalExecution,omitempty"` }
type SuiTransactionBlockResponseQuery ¶
type SuiTransactionBlockResponseQuery struct { TransactionFilter TransactionFilter `json:"filter"` Options SuiTransactionBlockOptions `json:"options"` }
type SuiTryGetPastObjectRequest ¶
type SuiTryGetPastObjectRequest struct { ObjectId string `json:"objectId"` Version uint64 `json:"version"` Options SuiObjectDataOptions `json:"options"` }
type SuiValidatorSummary ¶
type SuiValidatorSummary struct { SuiAddress SuiAddress `json:"suiAddress"` ProtocolPubkeyBytes string `json:"protocolPubkeyBytes"` NetworkPubkeyBytes string `json:"networkPubkeyBytes"` WorkerPubkeyBytes string `json:"workerPubkeyBytes"` ProofOfPossessionBytes string `json:"proofOfPossessionBytes"` OperationCapId string `json:"operationCapId"` Name string `json:"name"` Description string `json:"description"` ImageUrl string `json:"imageUrl"` ProjectUrl string `json:"projectUrl"` P2pAddress string `json:"p2pAddress"` NetAddress string `json:"netAddress"` PrimaryAddress string `json:"primaryAddress"` WorkerAddress string `json:"workerAddress"` NextEpochProtocolPubkeyBytes string `json:"nextEpochProtocolPubkeyBytes"` NextEpochProofOfPossession string `json:"nextEpochProofOfPossession"` NextEpochNetworkPubkeyBytes string `json:"nextEpochNetworkPubkeyBytes"` NextEpochWorkerPubkeyBytes string `json:"nextEpochWorkerPubkeyBytes"` NextEpochNetAddress string `json:"nextEpochNetAddress"` NextEpochP2pAddress string `json:"nextEpochP2pAddress"` NextEpochPrimaryAddress string `json:"nextEpochPrimaryAddress"` NextEpochWorkerAddress string `json:"nextEpochWorkerAddress"` VotingPower string `json:"votingPower"` GasPrice string `json:"gasPrice"` CommissionRate string `json:"commissionRate"` NextEpochStake string `json:"nextEpochStake"` NextEpochGasPrice string `json:"nextEpochGasPrice"` NextEpochCommissionRate string `json:"nextEpochCommissionRate"` StakingPoolId string `json:"stakingPoolId"` StakingPoolActivationEpoch string `json:"stakingPoolActivationEpoch"` StakingPoolDeactivationEpoch string `json:"stakingPoolDeactivationEpoch"` StakingPoolSuiBalance string `json:"stakingPoolSuiBalance"` RewardsPool string `json:"rewardsPool"` PoolTokenBalance string `json:"poolTokenBalance"` PendingStake string `json:"pendingStake"` PendingPoolTokenWithdraw string `json:"pendingPoolTokenWithdraw"` PendingTotalSuiWithdraw string `json:"pendingTotalSuiWithdraw"` ExchangeRatesId string `json:"exchangeRatesId"` ExchangeRatesSize string `json:"exchangeRatesSize"` }
type SuiXGetAllBalanceRequest ¶
type SuiXGetAllBalanceRequest struct { // the owner's Sui address Owner string `json:"owner"` }
type SuiXGetAllCoinsRequest ¶
type SuiXGetBalanceRequest ¶
type SuiXGetCoinMetadataRequest ¶
type SuiXGetCoinMetadataRequest struct { // type name for the coin (e.g., 0x168da5bf1f48dafc111b0a488fa454aca95e0b5e::usdc::USDC) CoinType string `json:"coinType"` }
type SuiXGetCoinsRequest ¶
type SuiXGetCoinsRequest struct { // the owner's Sui address Owner string `json:"owner"` // optional type name for the coin (e.g., 0x168da5bf1f48dafc111b0a488fa454aca95e0b5e::usdc::USDC), default to 0x2::sui::SUI if not specified. CoinType string `json:"coin_type"` // optional paging cursor Cursor interface{} `json:"cursor"` // maximum number of items per page Limit uint64 `json:"limit" validate:"lte=50"` }
type SuiXGetCommitteeInfoRequest ¶
type SuiXGetCommitteeInfoRequest struct {
Epoch string `json:"epoch"`
}
type SuiXGetDynamicFieldObjectRequest ¶
type SuiXGetDynamicFieldObjectRequest struct { ObjectId string `json:"objectId"` DynamicFieldName DynamicFieldName `json:"dynamicFieldName"` }
type SuiXGetEpochsRequest ¶
type SuiXGetEpochsRequest struct { // optional paging cursor Cursor interface{} `json:"cursor"` // maximum number of items per page Limit uint64 `json:"limit" validate:"lte=50"` // query result ordering, default to false (ascending order), oldest record first DescendingOrder bool `json:"descendingOrder"` }
type SuiXGetOwnedObjectsRequest ¶
type SuiXGetOwnedObjectsRequest struct { // the owner's Sui address Address string `json:"address" validate:"checkAddress"` // the objects query criteria Query SuiObjectResponseQuery // optional paging cursor Cursor interface{} `json:"cursor"` // maximum number of items per page Limit uint64 `json:"limit" validate:"lte=50"` }
type SuiXGetStakesByIdsRequest ¶
type SuiXGetStakesByIdsRequest struct {
StakedSuiIds []string `json:"stakedSuiIds"`
}
type SuiXGetStakesRequest ¶
type SuiXGetStakesRequest struct {
Owner string `json:"owner"`
}
type SuiXGetTotalSupplyRequest ¶
type SuiXGetTotalSupplyRequest struct { // type name for the coin (e.g., 0x168da5bf1f48dafc111b0a488fa454aca95e0b5e::usdc::USDC) CoinType string `json:"coinType"` }
type SuiXQueryEventsRequest ¶
type SuiXQueryEventsRequest struct { // the event query criteria. SuiEventFilter interface{} `json:"suiEventFilter"` // optional paging cursor Cursor interface{} `json:"cursor"` // maximum number of items per page Limit uint64 `json:"limit" validate:"lte=50"` // query result ordering, default to false (ascending order), oldest record first DescendingOrder bool `json:"descendingOrder"` }
type SuiXQueryTransactionBlocksRequest ¶
type SuiXQueryTransactionBlocksRequest struct { SuiTransactionBlockResponseQuery SuiTransactionBlockResponseQuery // optional paging cursor Cursor interface{} `json:"cursor"` // maximum number of items per page Limit uint64 `json:"limit" validate:"lte=50"` // query result ordering, default to false (ascending order), oldest record first DescendingOrder bool `json:"descendingOrder"` }
type SuiXQueryTransactionBlocksResponse ¶
type SuiXQueryTransactionBlocksResponse struct { Data []SuiTransactionBlockResponse `json:"data"` NextCursor string `json:"nextCursor"` HasNextPage bool `json:"hasNextPage"` }
type SuiXResolveNameServiceAddressRequest ¶
type SuiXResolveNameServiceAddressRequest struct {
Name string `json:"name"`
}
type SuiXSubscribeEventsRequest ¶
type SuiXSubscribeEventsRequest struct {
// the event query criteria.
SuiEventFilter interface{} `json:"suiEventFilter"`
}
type SuiXSubscribeTransactionsRequest ¶
type SuiXSubscribeTransactionsRequest struct {
// the transaction query criteria.
TransactionFilter interface{} `json:"filter"`
}
type TotalSupplyResponse ¶
type TotalSupplyResponse struct {
Value string `json:"value"`
}
type TransactionDigest ¶
type TransactionDigest string
type TransactionFilter ¶
type TransactionFilter map[string]interface{}
type TransactionFilterByChangedObjectFilter ¶
type TransactionFilterByChangedObjectFilter struct { // ChangedObject is a filter for changed objects ChangedObject string `json:"ChangedObject"` }
TransactionFilterByChangedObjectFilter is a filter for changed objects
type TransactionFilterByFromAddress ¶
type TransactionFilterByFromAddress struct {
FromAddress string `json:"FromAddress"`
}
TransactionFilterByFromAddress is a filter for from address
type TransactionFilterByInputObject ¶
type TransactionFilterByInputObject struct { // InputObject is the id of the object InputObject string `json:"InputObject"` }
TransactionFilterByInputObject is a filter for input objects
type TransactionFilterByMoveFunction ¶
type TransactionFilterByMoveFunction struct {
MoveFunction MoveFunction `json:"MoveFunction"`
}
TransactionFilterByMoveFunction is a filter for move functions
type TransactionFilterByToAddress ¶
type TransactionFilterByToAddress struct {
ToAddress string `json:"ToAddress"`
}
TransactionFilterByToAddress is a filter for to address
type TransferObjectRequest ¶
type TransferObjectRequest struct { // the transaction signer's Sui address Signer string `json:"signer"` ObjectId string `json:"objectId"` // gas object to be used in this transaction, node will pick one from the signer's possession if not provided Gas string `json:"gas"` // the gas budget, the transaction will fail if the gas cost exceed the budget GasBudget string `json:"gasBudget"` Recipient string `json:"recipient"` }
type TransferSuiRequest ¶
type TransferSuiRequest struct { // the transaction signer's Sui address Signer string `json:"signer"` SuiObjectId string `json:"suiObjectId"` // the gas budget, the transaction will fail if the gas cost exceed the budget GasBudget string `json:"gasBudget"` Recipient string `json:"recipient"` Amount string `json:"amount"` }
type TxnMetaData ¶
type TxnMetaData struct { Gas []sui_types.SuiObjectRef `json:"gas"` InputObjects []interface{} `json:"inputObjects"` TxBytes string `json:"txBytes"` }
func (*TxnMetaData) SignSerializedSigWith ¶
func (txn *TxnMetaData) SignSerializedSigWith(privateKey ed25519.PrivateKey) *SignedTransactionSerializedSig
func (*TxnMetaData) SignSerializedSigWithKMS ¶
type ValidatorsApy ¶
type WithdrawStakeRequest ¶
type WithdrawStakeRequest struct { // the transaction signer's Sui address Signer string `json:"signer"` // StakedSui object ID StakedObjectId string `json:"stakedObjectId"` // gas object to be used in this transaction, node will pick one from the signer's possession if not provided Gas string `json:"gas"` // the gas budget, the transaction will fail if the gas cost exceed the budget GasBudget string `json:"gasBudget"` }