diff --git a/v2/types.go b/v2/types.go index 761cbe715..1aa02f902 100644 --- a/v2/types.go +++ b/v2/types.go @@ -586,6 +586,7 @@ type Trade struct { Amount float64 Price float64 Side OrderSide + Period float64 // Period (Funding only) } func NewTradeFromRaw(pair string, raw []interface{}) (o *Trade, err error) { @@ -610,6 +611,10 @@ func NewTradeFromRaw(pair string, raw []interface{}) (o *Trade, err error) { Side: side, } + if len(raw) == 5 { + o.Period = f64ValOrZero(raw[4]) + } + return }