From a4be20b2c8b7c490cfb56532b1604d11283b8634 Mon Sep 17 00:00:00 2001 From: Yoshi Automation Date: Mon, 27 Nov 2023 01:32:42 +0000 Subject: [PATCH] feat(analyticsdata): update the API #### analyticsdata:v1beta The following keys were added: - schemas.ResponseMetaData.properties.samplingMetadatas.description - schemas.ResponseMetaData.properties.samplingMetadatas.items.$ref - schemas.ResponseMetaData.properties.samplingMetadatas.type - schemas.SamplingMetadata.description - schemas.SamplingMetadata.id - schemas.SamplingMetadata.properties.samplesReadCount.description - schemas.SamplingMetadata.properties.samplesReadCount.format - schemas.SamplingMetadata.properties.samplesReadCount.type - schemas.SamplingMetadata.properties.samplingSpaceSize.description - schemas.SamplingMetadata.properties.samplingSpaceSize.format - schemas.SamplingMetadata.properties.samplingSpaceSize.type - schemas.SamplingMetadata.type The following keys were changed: - schemas.ResponseMetaData.properties.subjectToThresholding.description --- discovery/analyticsdata-v1beta.json | 28 ++++++++++++++++++++++++++-- src/apis/analyticsdata/v1beta.ts | 19 ++++++++++++++++++- 2 files changed, 44 insertions(+), 3 deletions(-) diff --git a/discovery/analyticsdata-v1beta.json b/discovery/analyticsdata-v1beta.json index 07b3a651547..dce95797810 100644 --- a/discovery/analyticsdata-v1beta.json +++ b/discovery/analyticsdata-v1beta.json @@ -313,7 +313,7 @@ } } }, - "revision": "20230920", + "revision": "20231114", "rootUrl": "https://analyticsdata.googleapis.com/", "schemas": { "ActiveMetricRestriction": { @@ -1349,12 +1349,19 @@ "description": "If empty reason is specified, the report is empty for this reason.", "type": "string" }, + "samplingMetadatas": { + "description": "If this report results is [sampled](https://support.google.com/analytics/answer/13331292), this describes the percentage of events used in this report. One `samplingMetadatas` is populated for each date range. Each `samplingMetadatas` corresponds to a date range in order that date ranges were specified in the request. However if the results are not sampled, this field will not be defined.", + "items": { + "$ref": "SamplingMetadata" + }, + "type": "array" + }, "schemaRestrictionResponse": { "$ref": "SchemaRestrictionResponse", "description": "Describes the schema restrictions actively enforced in creating this report. To learn more, see [Access and data-restriction management](https://support.google.com/analytics/answer/10851388)." }, "subjectToThresholding": { - "description": "If `subjectToThresholding` is true, this report is subject to thresholding and only returns data that meets the minimum aggregation thresholds. It is possible for a request to be subject to thresholding thresholding and no data is absent from the report, and this happens when all data is above the thresholds. To learn more, see [Data thresholds](https://support.google.com/analytics/answer/9383630) and [About Demographics and Interests](https://support.google.com/analytics/answer/2799357).", + "description": "If `subjectToThresholding` is true, this report is subject to thresholding and only returns data that meets the minimum aggregation thresholds. It is possible for a request to be subject to thresholding thresholding and no data is absent from the report, and this happens when all data is above the thresholds. To learn more, see [Data thresholds](https://support.google.com/analytics/answer/9383630).", "type": "boolean" }, "timeZone": { @@ -1797,6 +1804,23 @@ }, "type": "object" }, + "SamplingMetadata": { + "description": "If this report results is [sampled](https://support.google.com/analytics/answer/13331292), this describes the percentage of events used in this report. Sampling is the practice of analyzing a subset of all data in order to uncover the meaningful information in the larger data set.", + "id": "SamplingMetadata", + "properties": { + "samplesReadCount": { + "description": "The total number of events read in this sampled report for a date range. This is the size of the subset this property's data that was analyzed in this report.", + "format": "int64", + "type": "string" + }, + "samplingSpaceSize": { + "description": "The total number of events present in this property's data that could have been analyzed in this report for a date range. Sampling uncovers the meaningful information about the larger data set, and this is the size of the larger data set. To calculate the percentage of available data that was used in this report, compute `samplesReadCount/samplingSpaceSize`.", + "format": "int64", + "type": "string" + } + }, + "type": "object" + }, "SchemaRestrictionResponse": { "description": "The schema restrictions actively enforced in creating this report. To learn more, see [Access and data-restriction management](https://support.google.com/analytics/answer/10851388).", "id": "SchemaRestrictionResponse", diff --git a/src/apis/analyticsdata/v1beta.ts b/src/apis/analyticsdata/v1beta.ts index d95d9a29d9a..809650d71cc 100644 --- a/src/apis/analyticsdata/v1beta.ts +++ b/src/apis/analyticsdata/v1beta.ts @@ -820,12 +820,16 @@ export namespace analyticsdata_v1beta { * If empty reason is specified, the report is empty for this reason. */ emptyReason?: string | null; + /** + * If this report results is [sampled](https://support.google.com/analytics/answer/13331292), this describes the percentage of events used in this report. One `samplingMetadatas` is populated for each date range. Each `samplingMetadatas` corresponds to a date range in order that date ranges were specified in the request. However if the results are not sampled, this field will not be defined. + */ + samplingMetadatas?: Schema$SamplingMetadata[]; /** * Describes the schema restrictions actively enforced in creating this report. To learn more, see [Access and data-restriction management](https://support.google.com/analytics/answer/10851388). */ schemaRestrictionResponse?: Schema$SchemaRestrictionResponse; /** - * If `subjectToThresholding` is true, this report is subject to thresholding and only returns data that meets the minimum aggregation thresholds. It is possible for a request to be subject to thresholding thresholding and no data is absent from the report, and this happens when all data is above the thresholds. To learn more, see [Data thresholds](https://support.google.com/analytics/answer/9383630) and [About Demographics and Interests](https://support.google.com/analytics/answer/2799357). + * If `subjectToThresholding` is true, this report is subject to thresholding and only returns data that meets the minimum aggregation thresholds. It is possible for a request to be subject to thresholding thresholding and no data is absent from the report, and this happens when all data is above the thresholds. To learn more, see [Data thresholds](https://support.google.com/analytics/answer/9383630). */ subjectToThresholding?: boolean | null; /** @@ -1120,6 +1124,19 @@ export namespace analyticsdata_v1beta { */ totals?: Schema$Row[]; } + /** + * If this report results is [sampled](https://support.google.com/analytics/answer/13331292), this describes the percentage of events used in this report. Sampling is the practice of analyzing a subset of all data in order to uncover the meaningful information in the larger data set. + */ + export interface Schema$SamplingMetadata { + /** + * The total number of events read in this sampled report for a date range. This is the size of the subset this property's data that was analyzed in this report. + */ + samplesReadCount?: string | null; + /** + * The total number of events present in this property's data that could have been analyzed in this report for a date range. Sampling uncovers the meaningful information about the larger data set, and this is the size of the larger data set. To calculate the percentage of available data that was used in this report, compute `samplesReadCount/samplingSpaceSize`. + */ + samplingSpaceSize?: string | null; + } /** * The schema restrictions actively enforced in creating this report. To learn more, see [Access and data-restriction management](https://support.google.com/analytics/answer/10851388). */