Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
View Source
var (
ErrDepositNotFound = errors.New("external deposit not found")
)
Functions ¶
This section is empty.
Types ¶
type Record ¶
type Record struct { Id uint64 Signature string Destination string Amount uint64 UsdMarketValue float64 Slot uint64 ConfirmationState transaction.Confirmation CreatedAt time.Time }
Note: Only captures external deposits at the transaction level
type Store ¶
type Store interface { // Save saves a deposit record Save(ctx context.Context, record *Record) error // Get gets a deposit record for a signature and account Get(ctx context.Context, signature, account string) (*Record, error) // GetKinAmount gets the total deposited Kin amount in quarks to an account // for finalized transactions GetKinAmount(ctx context.Context, account string) (uint64, error) // GetKinAmountBatch is like GetKinAmount but for a batch of accounts GetKinAmountBatch(ctx context.Context, accounts ...string) (map[string]uint64, error) // GetUsdAmount gets the total deposited USD amount to an account for finalized // transactions GetUsdAmount(ctx context.Context, account string) (float64, error) }
Click to show internal directories.
Click to hide internal directories.