Documentation
¶
Overview ¶
Package timeparse holds the lookback / timestamp parsers shared between `bacio history` (CLI) and the HTTP history endpoints. Day (d) and week (w) suffixes are not understood by time.ParseDuration, so we wrap it.
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func Lookback ¶
Lookback extends time.ParseDuration with day (d) and week (w) units. Examples: 30m, 1h, 6h, 1d, 7d, 2w. Single-unit only for d/w; multi-unit composites use Go's native parser.
func Timestamp ¶
Timestamp accepts several common shapes and returns a UTC time. Date-only and bare datetimes are interpreted in the user's local timezone; RFC 3339 inputs honour the offset they specify.
Accepted: 2006-01-02 | 2006-01-02 15:04 | 2006-01-02 15:04:05 |
2006-01-02T15:04:05 | RFC3339 (e.g. 2026-05-03T07:27:14Z).
Types ¶
This section is empty.