Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type CoinHistoricalPrice ¶
type CoinHistoricalPrice struct {
CoinID string `gorm:"type:varchar(255);notNull" json:"coin_id"` // coin id
Date int64 `gorm:"type:bigint;notNull" json:"date"` // unix date
DayDate string `gorm:"type:varchar(255);notNull" json:"day_date"` // day date
Price string `gorm:"type:varchar(255);notNull" json:"price"` // price
Source string `gorm:"type:varchar(255);notNull;default:''" json:"source"` // data source
QueryInfo *string `gorm:"type:json" json:"query_info"` // query info
Base
}
type Coins ¶
type Coins struct {
ID string `gorm:"type:varchar(255);primaryKey" json:"id"` // chain_id + address
Address string `gorm:"type:varchar(255);notNull" json:"address"` // token or pool address
ChainID string `gorm:"type:varchar(255);notNull" json:"chain_id"` // chain id
Symbol *string `gorm:"type:varchar(255);notNull" json:"symbol"` // symbol
Name *string `gorm:"type:varchar(255);notNull" json:"name"` // name
CoingeckoCoinID *string `gorm:"type:varchar(255)" json:"coingecko_coin_id"` // coingecko coin id
CoingeckoPlatforms JSONMap `gorm:"type:json" json:"coingecko_platforms"` // coingecko platforms
GeckoterminalNetwork *string `gorm:"type:varchar(255)" json:"geckoterminal_network"` // geckoterminal network
Extra *string `gorm:"type:json" json:"extra"` // json扩展信息
Decimals *int `gorm:"type:int" json:"decimals"` // decimals
TotalSupply *string `gorm:"type:varchar(255)" json:"total_supply"` // total supply
Label string `gorm:"type:varchar(255);notNull;default:''" json:"label"` // label
PoolName *string `gorm:"type:varchar(255);default:''" json:"pool_name"` // pool name
BaseTokenAddress *string `gorm:"type:varchar(255);default:''" json:"base_token_address"` // base token address
QuoteTokenAddress *string `gorm:"type:varchar(255);default:''" json:"quote_token_address"` // quote token address
PoolCreatedAt *time.Time `gorm:"" json:"pool_created_at"` // pool created at
PoolAttributes *string `gorm:"type:json" json:"pool_attributes"` // pool attributes
LastPriceSource *string `gorm:"type:varchar(255)" json:"last_price_source"` // 上次价格查询结果来源
PriceSource *string `gorm:"type:varchar(255)" json:"price_source"` // 价格查询来源
ReturnCoinsId *string `gorm:"type:varchar(255)" json:"return_coins_id"` // 返回的coins ID
Base
}
type JSONMap ¶
JSONMap is a custom type for handling map[string]string JSON fields in GORM
type RequestLog ¶
type RequestLog struct {
IPAddress string `gorm:"size:45"`
Endpoint string `gorm:"size:255"`
RequestParams string `gorm:"type:text"`
Response string `gorm:"type:text"`
ExecutionTime int64
CreatedAt time.Time `gorm:"autoCreateTime" json:"created_at"`
UpdatedAt time.Time `gorm:"autoUpdateTime" json:"updated_at"`
DeletedAt gorm.DeletedAt `json:"deleted_at"`
}
type SlackNotifications ¶
type SlackNotifications struct {
Source string `gorm:"not null"`
CoinID string `gorm:"not null"`
DayDate string `gorm:"not null"`
Date int64 `gorm:"not null"`
Counter int `gorm:"default:1"`
CreatedAt time.Time `gorm:"autoCreateTime" json:"created_at"`
UpdatedAt time.Time `gorm:"autoUpdateTime" json:"updated_at"`
DeletedAt gorm.DeletedAt `json:"deleted_at"`
}
Click to show internal directories.
Click to hide internal directories.