Documentation
¶
Index ¶
- type Account
- type Block
- type BufferedTransaction
- type BufferedTransactionLog
- type BufferedUserActions
- type RpcError
- type Slot
- type SubscriptionError
- type SubscriptionResponse
- type Transaction
- type TransactionAddressTableLookups
- type TransactionInnerInstruction
- type TransactionInnerTxn
- type TransactionInstruction
- type TransactionLog
- type TransactionMessage
- type TransactionMeta
- type TransactionResult
- type TransactionTokenAmount
- type TransactionTokenBalance
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Account ¶
type Account struct { // Number of lamports assigned to this account Lamports uint64 `json:"lamports"` // Pubkey of the program this account has been assigned to Owner string `json:"owner"` // Data associated with the account, hardstuck in its binary form Data []string `json:"data"` // Boolean indicating if the account contains a program (and is strictly read-only) Executable bool `json:"executable"` // The epoch at which this account will next owe rent RentEpoch uint64 `json:"rentEpoch"` }
type Block ¶
type Block struct { Blockhash string `json:"blockhash"` Transactions []TransactionResult `json:"transactions"` }
type BufferedTransaction ¶
type BufferedTransaction struct { Slot uint64 `json:"slot"` Transactions []Transaction `json:"transactions"` // LogsCount of the number of logs previously sent in the buffered logs LogsCount int `json:"logs_count"` SecondsSinceLastSlot uint64 `json:"seconds_since_last_slot"` }
BufferedTransactions that were seen together in the same slot
type BufferedTransactionLog ¶
type BufferedTransactionLog struct { Slot uint64 `json:"slot"` Logs []TransactionLog `json:"logs"` SecondsSinceLastSlot uint64 `json:"seconds_since_last_slot"` }
BufferedTransactionsLogs created by microservice-solana-buffer-logs, including the slot (block number) that could be useful for calculating the number of fluid transfers in a block
type BufferedUserActions ¶
type BufferedUserActions struct { Slot uint64 `json:"slot"` UserActions []user_actions.UserAction `json:"user_actions"` LogCount int `json:"logs_count"` SecondsSinceLastSlot uint64 `json:"seconds_since_last_slot"` }
type Slot ¶
type Slot struct {
Slot uint64 `json:"slot"`
}
Slot is the type that logs the current slot as sent by the solana RPC
type SubscriptionError ¶
type SubscriptionError struct {
Message string `json:"message"`
}
type SubscriptionResponse ¶
type SubscriptionResponse struct { Result int `json:"result"` Id int `json:"id"` Error SubscriptionError `json:"error"` }
SubscriptionResponse is the confirmation or rejection of a subscription on the Solana websocket
type Transaction ¶
type Transaction struct { Result TransactionResult `json:"result"` AdjustedFee *big.Rat `json:"adjusted_fee"` }
Transaction is part of the transaction info type returned from the Solana RPC call
type TransactionInnerInstruction ¶
type TransactionInnerInstruction struct { Index int `json:"index"` Instructions []TransactionInstruction `json:"instructions"` }
type TransactionInnerTxn ¶
type TransactionInnerTxn struct { Message TransactionMessage `json:"message"` Signatures []string `json:"signatures"` }
type TransactionInstruction ¶
type TransactionLog ¶
type TransactionLog struct {
Params params `json:"params"`
}
TransactionLog is a simplified version of the transaction log type returned from Solana websocket subscriptions
type TransactionMessage ¶
type TransactionMessage struct { AccountKeys []string `json:"accountKeys"` Instructions []TransactionInstruction `json:"instructions"` // only present in v0 AddressTableLookups []TransactionAddressTableLookups `json:"addressTableLookups"` }
type TransactionMeta ¶
type TransactionMeta struct { // TODO solana doesn't doccument what this type actually is Err interface{} `json:"err"` Fee uint64 `json:"fee"` PreTokenBalances []TransactionTokenBalance `json:"preTokenBalances"` PostTokenBalances []TransactionTokenBalance `json:"postTokenBalances"` InnerInstructions []TransactionInnerInstruction `json:"innerInstructions"` Logs []string `json:"logMessages"` }
type TransactionResult ¶
type TransactionResult struct { // "legacy" or 0 or sometimes unset Version json.RawMessage `json:"version"` Meta TransactionMeta `json:"meta"` Slot int `json:"slot"` Transaction TransactionInnerTxn `json:"transaction"` }
type TransactionTokenAmount ¶
type TransactionTokenBalance ¶
type TransactionTokenBalance struct { AccountIndex int `json:"accountIndex"` Mint string `json:"mint"` Owner string `json:"owner"` UiTokenAmount TransactionTokenAmount `json:"uiTokenAmount"` }
Click to show internal directories.
Click to hide internal directories.