20 lines
425 B
Go
20 lines
425 B
Go
package entities
|
|
|
|
import "github.com/shopspring/decimal"
|
|
|
|
type AlertID string
|
|
|
|
type AlertCondition string
|
|
|
|
const (
|
|
AlertConditionAbove AlertCondition = "above" // trigger when price rises to target
|
|
AlertConditionBelow AlertCondition = "below" // trigger when price drops to target
|
|
)
|
|
|
|
type Alert struct {
|
|
ID AlertID
|
|
UserID UserID
|
|
Price decimal.Decimal
|
|
Condition AlertCondition
|
|
Instrument Instrument
|
|
}
|