Documentation
¶
Index ¶
Constants ¶
View Source
const ALLBRIDGE = "ALLBRIDGE"
View Source
const AllProtocolStats24HrAgo = `` /* 1071-byte string literal not displayed */
View Source
const AllProtocolsDeltaLastDay = `` /* 1071-byte string literal not displayed */
View Source
const AllProtocolsDeltaSinceStartOfDay = `` /* 1060-byte string literal not displayed */
View Source
const CCTP = "CCTP_WORMHOLE_INTEGRATION"
View Source
const GenericRelayer = "GENERIC_RELAYER"
View Source
const MAYAN = "MAYAN"
View Source
const NTT = "NATIVE_TOKEN_TRANSFER"
View Source
const PortalTokenBridge = "PORTAL_TOKEN_BRIDGE"
View Source
const QueryLast24HrActivity = `` /* 238-byte string literal not displayed */
View Source
const QueryTemplateProtocolActivity = `` /* 447-byte string literal not displayed */
View Source
const QueryTemplateProtocolStats24HrAgo = `` /* 211-byte string literal not displayed */
View Source
const QueryTemplateProtocolStatsNow = `` /* 210-byte string literal not displayed */
View Source
const UNKNOWN = "UNKNOWN"
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type ProtocolStats ¶
type ProtocolStats struct { Protocol string `json:"protocol"` TotalMessages uint64 `json:"total_messages"` TotalValueLocked float64 `json:"total_value_locked,omitempty"` TotalValueSecured float64 `json:"total_value_secured,omitempty"` TotalValueTransferred float64 `json:"total_value_transferred"` LastDayMessages uint64 `json:"last_day_messages"` LastDayDiffPercentage string `json:"last_day_diff_percentage"` LastDayVolumeDiffPercentage string `json:"last_day_diff_volume_percentage"` Last24HourVolume float64 `json:"last_24_hour_volume"` }
type ProtocolTotalValuesDTO ¶
type ProtocolTotalValuesDTO struct { ProtocolStats Error string `json:"error,omitempty"` }
type QueryDoer ¶
type QueryDoer interface {
Query(ctx context.Context, query string) (QueryResult, error)
}
func WrapQueryAPI ¶
type QueryResult ¶
type QueryResult interface { Next() bool Record() *query.FluxRecord Err() error Close() error }
type Repository ¶
type Repository struct {
// contains filtered or unexported fields
}
func NewRepository ¶
func NewRepository(qApi QueryDoer, bucketInfinite, bucket30d, bucket24Hrs string, logger *zap.Logger) *Repository
type Service ¶
type Service struct {
// contains filtered or unexported fields
}
func NewService ¶
func (*Service) GetProtocolsTotalValues ¶
func (s *Service) GetProtocolsTotalValues(ctx context.Context) []ProtocolTotalValuesDTO
Click to show internal directories.
Click to hide internal directories.