Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
Functions ¶
This section is empty.
Types ¶
type Distribution ¶
type Distribution struct {
DestinationOwnerAccount string
DestinationTokenAccount string
Quantity uint64
}
func (*Distribution) Clone ¶
func (m *Distribution) Clone() Distribution
func (*Distribution) CopyTo ¶
func (m *Distribution) CopyTo(dst *Distribution)
func (*Distribution) Validate ¶
func (m *Distribution) Validate() error
type ExternalDepositMetadata ¶
type ExternalDepositMetadata struct {
DestinationTokenAccount string
Quantity uint64
UsdMarketValue float64
}
func (*ExternalDepositMetadata) Clone ¶
func (m *ExternalDepositMetadata) Clone() ExternalDepositMetadata
func (*ExternalDepositMetadata) CopyTo ¶
func (m *ExternalDepositMetadata) CopyTo(dst *ExternalDepositMetadata)
func (*ExternalDepositMetadata) Validate ¶
func (m *ExternalDepositMetadata) Validate() error
type OpenAccountsMetadata ¶
type OpenAccountsMetadata struct {
}
func (*OpenAccountsMetadata) Clone ¶
func (m *OpenAccountsMetadata) Clone() OpenAccountsMetadata
func (*OpenAccountsMetadata) CopyTo ¶
func (m *OpenAccountsMetadata) CopyTo(dst *OpenAccountsMetadata)
func (*OpenAccountsMetadata) Validate ¶
func (m *OpenAccountsMetadata) Validate() error
type PublicDistributionMetadata ¶
type PublicDistributionMetadata struct {
Source string
Distributions []*Distribution
Quantity uint64
UsdMarketValue float64
}
func (*PublicDistributionMetadata) Clone ¶
func (m *PublicDistributionMetadata) Clone() PublicDistributionMetadata
func (*PublicDistributionMetadata) CopyTo ¶
func (m *PublicDistributionMetadata) CopyTo(dst *PublicDistributionMetadata)
func (*PublicDistributionMetadata) Validate ¶
func (m *PublicDistributionMetadata) Validate() error
type ReceivePaymentsPubliclyMetadata ¶
type ReceivePaymentsPubliclyMetadata struct {
Source string
Quantity uint64
IsRemoteSend bool
IsReturned bool
IsIssuerVoidingGiftCard bool
OriginalExchangeCurrency currency.Code
OriginalExchangeRate float64
OriginalNativeAmount float64
UsdMarketValue float64
}
func (*ReceivePaymentsPubliclyMetadata) Clone ¶
func (m *ReceivePaymentsPubliclyMetadata) Clone() ReceivePaymentsPubliclyMetadata
func (*ReceivePaymentsPubliclyMetadata) CopyTo ¶
func (m *ReceivePaymentsPubliclyMetadata) CopyTo(dst *ReceivePaymentsPubliclyMetadata)
func (*ReceivePaymentsPubliclyMetadata) Validate ¶
func (m *ReceivePaymentsPubliclyMetadata) Validate() error
type Record ¶
type Record struct {
Id uint64
IntentId string
IntentType Type
MintAccount string
InitiatorOwnerAccount string
OpenAccountsMetadata *OpenAccountsMetadata
ExternalDepositMetadata *ExternalDepositMetadata
SendPublicPaymentMetadata *SendPublicPaymentMetadata
ReceivePaymentsPubliclyMetadata *ReceivePaymentsPubliclyMetadata
PublicDistributionMetadata *PublicDistributionMetadata
State State
Version uint64
CreatedAt time.Time
}
func (*Record) IsCompleted ¶
type SendPublicPaymentMetadata ¶
type SendPublicPaymentMetadata struct {
DestinationOwnerAccount string
DestinationTokenAccount string
Quantity uint64
ExchangeCurrency currency.Code
ExchangeRate float64
NativeAmount float64
UsdMarketValue float64
IsWithdrawal bool
IsRemoteSend bool
}
func (*SendPublicPaymentMetadata) Clone ¶
func (m *SendPublicPaymentMetadata) Clone() SendPublicPaymentMetadata
func (*SendPublicPaymentMetadata) CopyTo ¶
func (m *SendPublicPaymentMetadata) CopyTo(dst *SendPublicPaymentMetadata)
func (*SendPublicPaymentMetadata) Validate ¶
func (m *SendPublicPaymentMetadata) Validate() error
type Store ¶
type Store interface {
// Save creates or updates an intent on the store.
Save(ctx context.Context, record *Record) error
// Get finds the intent record for a given intent ID.
//
// Returns ErrNotFound if no record is found.
Get(ctx context.Context, intentID string) (*Record, error)
// GetAllByOwner returns all records for a given owner (as both a source and destination).
//
// Returns ErrNotFound if no records are found.
GetAllByOwner(ctx context.Context, owner string, cursor query.Cursor, limit uint64, direction query.Ordering) ([]*Record, error)
// GetOriginalGiftCardIssuedIntent gets the original intent where a gift card
// was issued by its vault address.
GetOriginalGiftCardIssuedIntent(ctx context.Context, giftCardVault string) (*Record, error)
// GetGiftCardClaimedIntent gets the intent where a gift card was claimed by its
// vault address.
GetGiftCardClaimedIntent(ctx context.Context, giftCardVault string) (*Record, error)
// GetTransactedAmountForAntiMoneyLaundering gets the total transacted core mint quarks and the
// corresponding USD market value for an owner since a timestamp.
GetTransactedAmountForAntiMoneyLaundering(ctx context.Context, owner string, since time.Time) (uint64, float64, error)
}
type Type ¶
type Type uint8
const ( UnknownType Type = iota LegacyPayment // Deprecated pre-2022 privacy flow LegacyCreateAccount // Deprecated pre-2022 privacy flow OpenAccounts SendPrivatePayment // Deprecated privacy flow ReceivePaymentsPrivately // Deprecated privacy flow SaveRecentRoot // Deprecated privacy flow MigrateToPrivacy2022 // Deprecated privacy flow ExternalDeposit SendPublicPayment ReceivePaymentsPublicly EstablishRelationship // Deprecated privacy flow Login // Deprecated login flow PublicDistribution )
Click to show internal directories.
Click to hide internal directories.