func (d *Duration) Duration() time.Duration {
	if d == nil {
		return time.Duration(0)
	}
	return time.Duration(d.Value) * time.Second
}
Duration returns the time.Duration for this internal Duration.
package internal
import "time"
type DateTime struct {
	Text string `json:"text"`
	TimeZone string `json:"time_zone"`
	Value int64 `json:"value"`
}
func (dt *DateTime) Time() time.Time {
	if dt == nil {
		return time.Time{}
	}
	loc, err := time.LoadLocation(dt.TimeZone)
	t := time.Unix(dt.Value, 0)
	if err == nil && loc != nil {
		t = t.In(loc)
	}
	return t
}
func NewDateTime(t time.Time) *DateTime {
	if t.IsZero() {
		return nil
	}
	loc := t.Location()
	return &DateTime{
		Text:     t.Format(time.RFC1123),  
		TimeZone: loc.String(),
		Value:    t.UnixNano() / int64(time.Second),
	}
}
type Duration struct {
	Value int64 `json:"value"`
	Text string `json:"text"`
}