types.go 840 B

123456789101112131415161718192021222324252627282930313233
  1. package stackdriver
  2. import "time"
  3. type StackDriverResponse struct {
  4. TimeSeries []struct {
  5. Metric struct {
  6. Labels struct {
  7. InstanceName string `json:"instance_name"`
  8. } `json:"labels"`
  9. Type string `json:"type"`
  10. } `json:"metric"`
  11. Resource struct {
  12. Type string `json:"type"`
  13. Labels struct {
  14. InstanceID string `json:"instance_id"`
  15. Zone string `json:"zone"`
  16. ProjectID string `json:"project_id"`
  17. } `json:"labels"`
  18. } `json:"resource"`
  19. MetricKind string `json:"metricKind"`
  20. ValueType string `json:"valueType"`
  21. Points []struct {
  22. Interval struct {
  23. StartTime time.Time `json:"startTime"`
  24. EndTime time.Time `json:"endTime"`
  25. } `json:"interval"`
  26. Value struct {
  27. DoubleValue float64 `json:"doubleValue"`
  28. } `json:"value"`
  29. } `json:"points"`
  30. } `json:"timeSeries"`
  31. }