alert service

This commit is contained in:
yash 2026-02-25 23:52:21 +03:00
parent 0e73841b3e
commit 608561ab38
8 changed files with 283 additions and 8 deletions

View file

@ -4,9 +4,17 @@ 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
}