public sealed class TimeSeries : IMessage<TimeSeries>, IEquatable<TimeSeries>, IDeepCloneable<TimeSeries>, IBufferMessage, IMessage
Reference documentation and code samples for the Google Cloud Monitoring v3 API class TimeSeries.
A collection of data points that describes the time-varying values
of a metric. A time series is identified by a combination of a
fully-specified monitored resource and a fully-specified metric.
This type is used for both listing and creating time series.
Input only. A detailed description of the time series that will be
associated with the
[google.api.MetricDescriptor][google.api.MetricDescriptor] for the metric.
Once set, this field cannot be changed through CreateTimeSeries.
public MonitoredResourceMetadata Metadata { get; set; }
Output only. The associated monitored resource metadata. When reading a
time series, this field will include metadata labels that are explicitly
named in the reduction. When creating a time series, this field is ignored.
public MetricDescriptor.Types.MetricKind MetricKind { get; set; }
The metric kind of the time series. When listing time series, this metric
kind might be different from the metric kind of the associated metric if
this time series is an alignment or reduction of other time series.
When creating a time series, this field is optional. If present, it must be
the same as the metric kind of the associated metric. If the associated
metric's descriptor must be auto-created, then this field specifies the
metric kind of the new descriptor and must be either GAUGE (the default)
or CUMULATIVE.
The data points of this time series. When listing time series, points are
returned in reverse time order.
When creating a time series, this field must contain exactly one point and
the point's type must be the same as the value type of the associated
metric. If the associated metric's descriptor must be auto-created, then
the value type of the descriptor is determined by the point's type, which
must be BOOL, INT64, DOUBLE, or DISTRIBUTION.
The associated monitored resource. Custom metrics can use only certain
monitored resource types in their time series data. For more information,
see Monitored resources for custom
metrics.
The units in which the metric value is reported. It is only applicable
if the value_type is INT64, DOUBLE, or DISTRIBUTION. The unit
defines the representation of the stored metric values. This field can only
be changed through CreateTimeSeries when it is empty.
public MetricDescriptor.Types.ValueType ValueType { get; set; }
The value type of the time series. When listing time series, this value
type might be different from the value type of the associated metric if
this time series is an alignment or reduction of other time series.
When creating a time series, this field is optional. If present, it must be
the same as the type of the data in the points field.
[[["Easy to understand","easyToUnderstand","thumb-up"],["Solved my problem","solvedMyProblem","thumb-up"],["Other","otherUp","thumb-up"]],[["Missing the information I need","missingTheInformationINeed","thumb-down"],["Too complicated / too many steps","tooComplicatedTooManySteps","thumb-down"],["Out of date","outOfDate","thumb-down"],["Samples / code issue","samplesCodeIssue","thumb-down"],["Other","otherDown","thumb-down"]],["Last updated 2025-08-07 UTC."],[[["\u003cp\u003eThis document provides reference documentation for the \u003ccode\u003eTimeSeries\u003c/code\u003e class within the Google Cloud Monitoring v3 API, used to represent a collection of time-varying data points.\u003c/p\u003e\n"],["\u003cp\u003eThe latest version of the \u003ccode\u003eTimeSeries\u003c/code\u003e API is 3.15.0, with documentation available for multiple previous versions dating back to 2.3.0.\u003c/p\u003e\n"],["\u003cp\u003eA \u003ccode\u003eTimeSeries\u003c/code\u003e object includes properties like \u003ccode\u003eMetric\u003c/code\u003e, \u003ccode\u003eResource\u003c/code\u003e, \u003ccode\u003ePoints\u003c/code\u003e, and \u003ccode\u003eUnit\u003c/code\u003e, describing the data, its source, the specific values, and their units of measure.\u003c/p\u003e\n"],["\u003cp\u003eWhen listing time series data, the \u003ccode\u003eMetricKind\u003c/code\u003e and \u003ccode\u003eValueType\u003c/code\u003e might differ from the associated metric's properties if the time series is the result of an alignment or reduction process.\u003c/p\u003e\n"],["\u003cp\u003eThe \u003ccode\u003eTimeSeries\u003c/code\u003e class implements interfaces such as \u003ccode\u003eIMessage\u003c/code\u003e, \u003ccode\u003eIEquatable\u003c/code\u003e, \u003ccode\u003eIDeepCloneable\u003c/code\u003e, and \u003ccode\u003eIBufferMessage\u003c/code\u003e, and inherits from \u003ccode\u003eobject\u003c/code\u003e.\u003c/p\u003e\n"]]],[],null,["# Google Cloud Monitoring v3 API - Class TimeSeries (3.15.0)\n\nVersion latestkeyboard_arrow_down\n\n- [3.15.0 (latest)](/dotnet/docs/reference/Google.Cloud.Monitoring.V3/latest/Google.Cloud.Monitoring.V3.TimeSeries)\n- [3.14.0](/dotnet/docs/reference/Google.Cloud.Monitoring.V3/3.14.0/Google.Cloud.Monitoring.V3.TimeSeries)\n- [3.13.0](/dotnet/docs/reference/Google.Cloud.Monitoring.V3/3.13.0/Google.Cloud.Monitoring.V3.TimeSeries)\n- [3.12.0](/dotnet/docs/reference/Google.Cloud.Monitoring.V3/3.12.0/Google.Cloud.Monitoring.V3.TimeSeries)\n- [3.11.0](/dotnet/docs/reference/Google.Cloud.Monitoring.V3/3.11.0/Google.Cloud.Monitoring.V3.TimeSeries)\n- [3.10.0](/dotnet/docs/reference/Google.Cloud.Monitoring.V3/3.10.0/Google.Cloud.Monitoring.V3.TimeSeries)\n- [3.9.0](/dotnet/docs/reference/Google.Cloud.Monitoring.V3/3.9.0/Google.Cloud.Monitoring.V3.TimeSeries)\n- [3.8.0](/dotnet/docs/reference/Google.Cloud.Monitoring.V3/3.8.0/Google.Cloud.Monitoring.V3.TimeSeries)\n- [3.7.0](/dotnet/docs/reference/Google.Cloud.Monitoring.V3/3.7.0/Google.Cloud.Monitoring.V3.TimeSeries)\n- [3.6.0](/dotnet/docs/reference/Google.Cloud.Monitoring.V3/3.6.0/Google.Cloud.Monitoring.V3.TimeSeries)\n- [3.5.0](/dotnet/docs/reference/Google.Cloud.Monitoring.V3/3.5.0/Google.Cloud.Monitoring.V3.TimeSeries)\n- [3.4.0](/dotnet/docs/reference/Google.Cloud.Monitoring.V3/3.4.0/Google.Cloud.Monitoring.V3.TimeSeries)\n- [3.3.0](/dotnet/docs/reference/Google.Cloud.Monitoring.V3/3.3.0/Google.Cloud.Monitoring.V3.TimeSeries)\n- [3.2.0](/dotnet/docs/reference/Google.Cloud.Monitoring.V3/3.2.0/Google.Cloud.Monitoring.V3.TimeSeries)\n- [3.1.0](/dotnet/docs/reference/Google.Cloud.Monitoring.V3/3.1.0/Google.Cloud.Monitoring.V3.TimeSeries)\n- [3.0.0](/dotnet/docs/reference/Google.Cloud.Monitoring.V3/3.0.0/Google.Cloud.Monitoring.V3.TimeSeries)\n- [2.6.0](/dotnet/docs/reference/Google.Cloud.Monitoring.V3/2.6.0/Google.Cloud.Monitoring.V3.TimeSeries)\n- [2.5.0](/dotnet/docs/reference/Google.Cloud.Monitoring.V3/2.5.0/Google.Cloud.Monitoring.V3.TimeSeries)\n- [2.4.0](/dotnet/docs/reference/Google.Cloud.Monitoring.V3/2.4.0/Google.Cloud.Monitoring.V3.TimeSeries)\n- [2.3.0](/dotnet/docs/reference/Google.Cloud.Monitoring.V3/2.3.0/Google.Cloud.Monitoring.V3.TimeSeries) \n\n public sealed class TimeSeries : IMessage\u003cTimeSeries\u003e, IEquatable\u003cTimeSeries\u003e, IDeepCloneable\u003cTimeSeries\u003e, IBufferMessage, IMessage\n\nReference documentation and code samples for the Google Cloud Monitoring v3 API class TimeSeries.\n\nA collection of data points that describes the time-varying values\nof a metric. A time series is identified by a combination of a\nfully-specified monitored resource and a fully-specified metric.\nThis type is used for both listing and creating time series. \n\nInheritance\n-----------\n\n[object](https://learn.microsoft.com/dotnet/api/system.object) \\\u003e TimeSeries \n\nImplements\n----------\n\n[IMessage](https://cloud.google.com/dotnet/docs/reference/Google.Protobuf/latest/Google.Protobuf.IMessage-1.html)[TimeSeries](/dotnet/docs/reference/Google.Cloud.Monitoring.V3/latest/Google.Cloud.Monitoring.V3.TimeSeries), [IEquatable](https://learn.microsoft.com/dotnet/api/system.iequatable-1)[TimeSeries](/dotnet/docs/reference/Google.Cloud.Monitoring.V3/latest/Google.Cloud.Monitoring.V3.TimeSeries), [IDeepCloneable](https://cloud.google.com/dotnet/docs/reference/Google.Protobuf/latest/Google.Protobuf.IDeepCloneable-1.html)[TimeSeries](/dotnet/docs/reference/Google.Cloud.Monitoring.V3/latest/Google.Cloud.Monitoring.V3.TimeSeries), [IBufferMessage](https://cloud.google.com/dotnet/docs/reference/Google.Protobuf/latest/Google.Protobuf.IBufferMessage.html), [IMessage](https://cloud.google.com/dotnet/docs/reference/Google.Protobuf/latest/Google.Protobuf.IMessage.html) \n\nInherited Members\n-----------------\n\n[object.GetHashCode()](https://learn.microsoft.com/dotnet/api/system.object.gethashcode) \n[object.GetType()](https://learn.microsoft.com/dotnet/api/system.object.gettype) \n[object.ToString()](https://learn.microsoft.com/dotnet/api/system.object.tostring)\n\nNamespace\n---------\n\n[Google.Cloud.Monitoring.V3](/dotnet/docs/reference/Google.Cloud.Monitoring.V3/latest/Google.Cloud.Monitoring.V3)\n\nAssembly\n--------\n\nGoogle.Cloud.Monitoring.V3.dll\n\nConstructors\n------------\n\n### TimeSeries()\n\n public TimeSeries()\n\n### TimeSeries(TimeSeries)\n\n public TimeSeries(TimeSeries other)\n\nProperties\n----------\n\n### Description\n\n public string Description { get; set; }\n\nInput only. A detailed description of the time series that will be\nassociated with the\n\\[google.api.MetricDescriptor\\]\\[google.api.MetricDescriptor\\] for the metric.\nOnce set, this field cannot be changed through CreateTimeSeries.\n\n### Metadata\n\n public MonitoredResourceMetadata Metadata { get; set; }\n\nOutput only. The associated monitored resource metadata. When reading a\ntime series, this field will include metadata labels that are explicitly\nnamed in the reduction. When creating a time series, this field is ignored.\n\n### Metric\n\n public Metric Metric { get; set; }\n\nThe associated metric. A fully-specified metric used to identify the time\nseries.\n\n### MetricKind\n\n public MetricDescriptor.Types.MetricKind MetricKind { get; set; }\n\nThe metric kind of the time series. When listing time series, this metric\nkind might be different from the metric kind of the associated metric if\nthis time series is an alignment or reduction of other time series.\n\nWhen creating a time series, this field is optional. If present, it must be\nthe same as the metric kind of the associated metric. If the associated\nmetric's descriptor must be auto-created, then this field specifies the\nmetric kind of the new descriptor and must be either `GAUGE` (the default)\nor `CUMULATIVE`.\n\n### Points\n\n public RepeatedField\u003cPoint\u003e Points { get; }\n\nThe data points of this time series. When listing time series, points are\nreturned in reverse time order.\n\nWhen creating a time series, this field must contain exactly one point and\nthe point's type must be the same as the value type of the associated\nmetric. If the associated metric's descriptor must be auto-created, then\nthe value type of the descriptor is determined by the point's type, which\nmust be `BOOL`, `INT64`, `DOUBLE`, or `DISTRIBUTION`.\n\n### Resource\n\n public MonitoredResource Resource { get; set; }\n\nThe associated monitored resource. Custom metrics can use only certain\nmonitored resource types in their time series data. For more information,\nsee [Monitored resources for custom\nmetrics](https://cloud.google.com/monitoring/custom-metrics/creating-metrics#custom-metric-resources).\n\n### Unit\n\n public string Unit { get; set; }\n\nThe units in which the metric value is reported. It is only applicable\nif the `value_type` is `INT64`, `DOUBLE`, or `DISTRIBUTION`. The `unit`\ndefines the representation of the stored metric values. This field can only\nbe changed through CreateTimeSeries when it is empty.\n\n### ValueType\n\n public MetricDescriptor.Types.ValueType ValueType { get; set; }\n\nThe value type of the time series. When listing time series, this value\ntype might be different from the value type of the associated metric if\nthis time series is an alignment or reduction of other time series.\n\nWhen creating a time series, this field is optional. If present, it must be\nthe same as the type of the data in the `points` field."]]