Skip to content

Commit 061a9fb

Browse files
Google APIscopybara-github
authored andcommitted
feat: add account-level binding for theRunAccessReport method (example: /v1alpha/accounts/1234567:runAccessReport)
feat: add `GetEnhancedMeasurementSettings`, `UpdateEnhancedMeasurementSettings` methods to the Admin API v1alpha feat: add `CreateConnectedSiteTag`, `DeleteConnectedSiteTag`, `ListConnectedSiteTags` methods to the Admin API v1alpha feat: add `EnhancedMeasurementSettings`, `ConnectedSiteTag` resource types to the Admin API v1alpha feat: add `GetEnhancedMeasurementSettingsRequest`, `UpdateEnhancedMeasurementSettingsRequest`,`CreateConnectedSiteTagRequest`, `CreateConnectedSiteTagResponse`, `DeleteConnectedSiteTagRequest`, `ListConnectedSiteTagsRequest`, `ListConnectedSiteTagsResponse` feat: add `ENHANCED_MEASUREMENT_SETTINGS` option to the `ChangeHistoryResourceType` enum feat: add `enhanced_measurement_settings` option to the `ChangeHistoryResource.resource` oneof field feat: add `intraday_export_enabled` field to the `BigQueryLink` resource PiperOrigin-RevId: 518088512
1 parent e354eef commit 061a9fb

6 files changed

Lines changed: 251 additions & 21 deletions

File tree

google/analytics/admin/v1alpha/access_report.proto

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
// Copyright 2022 Google LLC
1+
// Copyright 2023 Google LLC
22
//
33
// Licensed under the Apache License, Version 2.0 (the "License");
44
// you may not use this file except in compliance with the License.

google/analytics/admin/v1alpha/analytics_admin.proto

Lines changed: 154 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
// Copyright 2022 Google LLC
1+
// Copyright 2023 Google LLC
22
//
33
// Licensed under the Apache License, Version 2.0 (the "License");
44
// you may not use this file except in compliance with the License.
@@ -918,6 +918,10 @@ service AnalyticsAdminService {
918918
option (google.api.http) = {
919919
post: "/v1alpha/{entity=properties/*}:runAccessReport"
920920
body: "*"
921+
additional_bindings {
922+
post: "/v1alpha/{entity=accounts/*}:runAccessReport"
923+
body: "*"
924+
}
921925
};
922926
}
923927

@@ -1123,13 +1127,75 @@ service AnalyticsAdminService {
11231127
};
11241128
option (google.api.method_signature) = "parent";
11251129
}
1130+
1131+
// Returns the enhanced measurement settings for this data stream.
1132+
// Note that the stream must enable enhanced measurement for these settings to
1133+
// take effect.
1134+
rpc GetEnhancedMeasurementSettings(GetEnhancedMeasurementSettingsRequest)
1135+
returns (EnhancedMeasurementSettings) {
1136+
option (google.api.http) = {
1137+
get: "/v1alpha/{name=properties/*/dataStreams/*/enhancedMeasurementSettings}"
1138+
};
1139+
option (google.api.method_signature) = "name";
1140+
}
1141+
1142+
// Updates the enhanced measurement settings for this data stream.
1143+
// Note that the stream must enable enhanced measurement for these settings to
1144+
// take effect.
1145+
rpc UpdateEnhancedMeasurementSettings(
1146+
UpdateEnhancedMeasurementSettingsRequest)
1147+
returns (EnhancedMeasurementSettings) {
1148+
option (google.api.http) = {
1149+
patch: "/v1alpha/{enhanced_measurement_settings.name=properties/*/dataStreams/*/enhancedMeasurementSettings}"
1150+
body: "enhanced_measurement_settings"
1151+
};
1152+
option (google.api.method_signature) =
1153+
"enhanced_measurement_settings,update_mask";
1154+
}
1155+
1156+
// Creates a connected site tag for a Universal Analytics property. You can
1157+
// create a maximum of 20 connected site tags per property.
1158+
// Note: This API cannot be used on GA4 properties.
1159+
rpc CreateConnectedSiteTag(CreateConnectedSiteTagRequest)
1160+
returns (CreateConnectedSiteTagResponse) {
1161+
option (google.api.http) = {
1162+
post: "/v1alpha/properties:createConnectedSiteTag"
1163+
body: "*"
1164+
};
1165+
}
1166+
1167+
// Deletes a connected site tag for a Universal Analytics property.
1168+
// Note: this has no effect on GA4 properties.
1169+
rpc DeleteConnectedSiteTag(DeleteConnectedSiteTagRequest)
1170+
returns (google.protobuf.Empty) {
1171+
option (google.api.http) = {
1172+
post: "/v1alpha/properties:deleteConnectedSiteTag"
1173+
body: "*"
1174+
};
1175+
}
1176+
1177+
// Lists the connected site tags for a Universal Analytics property. A maximum
1178+
// of 20 connected site tags will be returned. Note: this has no effect on GA4
1179+
// property.
1180+
rpc ListConnectedSiteTags(ListConnectedSiteTagsRequest)
1181+
returns (ListConnectedSiteTagsResponse) {
1182+
option (google.api.http) = {
1183+
post: "/v1alpha/properties:listConnectedSiteTags"
1184+
body: "*"
1185+
};
1186+
}
11261187
}
11271188

11281189
// The request for a Data Access Record Report.
11291190
message RunAccessReportRequest {
1130-
// The Data Access Report is requested for this property.
1131-
// For example if "123" is your GA4 property ID, then entity should be
1132-
// "properties/123".
1191+
// The Data Access Report supports requesting at the property level or account
1192+
// level. If requested at the account level, Data Access Reports include all
1193+
// access for all properties under that account.
1194+
//
1195+
// To request at the property level, entity should be for example
1196+
// 'properties/123' if "123" is your GA4 property ID. To request at the
1197+
// account level, entity should be for example 'accounts/1234' if "1234" is
1198+
// your GA4 Account ID.
11331199
string entity = 1;
11341200

11351201
// The dimensions requested and displayed in the response. Requests are
@@ -1195,7 +1261,8 @@ message RunAccessReportRequest {
11951261
repeated AccessOrderBy order_bys = 10;
11961262

11971263
// Toggles whether to return the current state of this Analytics Property's
1198-
// quota. Quota is returned in [AccessQuota](#AccessQuota).
1264+
// quota. Quota is returned in [AccessQuota](#AccessQuota). For account-level
1265+
// requests, this field must be false.
11991266
bool return_entity_quota = 11;
12001267
}
12011268

@@ -1224,7 +1291,8 @@ message RunAccessReportResponse {
12241291
// [Pagination](https://developers.google.com/analytics/devguides/reporting/data/v1/basics#pagination).
12251292
int32 row_count = 4;
12261293

1227-
// The quota state for this Analytics property including this request.
1294+
// The quota state for this Analytics property including this request. This
1295+
// field doesn't work with account-level requests.
12281296
AccessQuota quota = 5;
12291297
}
12301298

@@ -1304,7 +1372,7 @@ message ProvisionAccountTicketRequest {
13041372
Account account = 1;
13051373

13061374
// Redirect URI where the user will be sent after accepting Terms of Service.
1307-
// Must be configured in Developers Console as a Redirect URI.
1375+
// Must be configured in Cloud Console as a Redirect URI.
13081376
string redirect_uri = 2;
13091377
}
13101378

@@ -2896,8 +2964,9 @@ message UpdateAccessBindingRequest {
28962964
// Request message for BatchUpdateAccessBindings RPC.
28972965
message BatchUpdateAccessBindingsRequest {
28982966
// Required. The account or property that owns the access bindings. The parent
2899-
// field in the UpdateAccessBindingRequest messages must either be empty or
2900-
// match this field. Formats:
2967+
// of all provided AccessBinding in UpdateAccessBindingRequest messages must
2968+
// match this field.
2969+
// Formats:
29012970
// - accounts/{account}
29022971
// - properties/{property}
29032972
string parent = 1 [
@@ -2935,8 +3004,8 @@ message DeleteAccessBindingRequest {
29353004
// Request message for BatchDeleteAccessBindings RPC.
29363005
message BatchDeleteAccessBindingsRequest {
29373006
// Required. The account or property that owns the access bindings. The parent
2938-
// field in the DeleteAccessBindingRequest messages must either be empty or
2939-
// match this field. Formats:
3007+
// of all provided values for the 'names' field in DeleteAccessBindingRequest
3008+
// messages must match this field. Formats:
29403009
// - accounts/{account}
29413010
// - properties/{property}
29423011
string parent = 1 [
@@ -3119,3 +3188,77 @@ message ListBigQueryLinksResponse {
31193188
// If this field is omitted, there are no subsequent pages.
31203189
string next_page_token = 2;
31213190
}
3191+
3192+
// Request message for GetEnhancedMeasurementSettings RPC.
3193+
message GetEnhancedMeasurementSettingsRequest {
3194+
// Required. The name of the settings to lookup.
3195+
// Format:
3196+
// properties/{property}/dataStreams/{data_stream}/enhancedMeasurementSettings
3197+
// Example: "properties/1000/dataStreams/2000/enhancedMeasurementSettings"
3198+
string name = 1 [
3199+
(google.api.field_behavior) = REQUIRED,
3200+
(google.api.resource_reference) = {
3201+
type: "analyticsadmin.googleapis.com/EnhancedMeasurementSettings"
3202+
}
3203+
];
3204+
}
3205+
3206+
// Request message for UpdateEnhancedMeasurementSettings RPC.
3207+
message UpdateEnhancedMeasurementSettingsRequest {
3208+
// Required. The settings to update.
3209+
// The `name` field is used to identify the settings to be updated.
3210+
EnhancedMeasurementSettings enhanced_measurement_settings = 1
3211+
[(google.api.field_behavior) = REQUIRED];
3212+
3213+
// Required. The list of fields to be updated. Field names must be in snake
3214+
// case (e.g., "field_to_update"). Omitted fields will not be updated. To
3215+
// replace the entire entity, use one path with the string "*" to match all
3216+
// fields.
3217+
google.protobuf.FieldMask update_mask = 2
3218+
[(google.api.field_behavior) = REQUIRED];
3219+
}
3220+
3221+
// Request message for CreateConnectedSiteTag RPC.
3222+
message CreateConnectedSiteTagRequest {
3223+
// The Universal Analytics property to create connected site tags for.
3224+
// This API does not support GA4 properties.
3225+
// Format: properties/{universalAnalyticsPropertyId}
3226+
// Example: properties/1234
3227+
string property = 1;
3228+
3229+
// Required. The tag to add to the Universal Analytics property
3230+
ConnectedSiteTag connected_site_tag = 2
3231+
[(google.api.field_behavior) = REQUIRED];
3232+
}
3233+
3234+
// Response message for CreateConnectedSiteTag RPC.
3235+
message CreateConnectedSiteTagResponse {}
3236+
3237+
// Request message for DeleteConnectedSiteTag RPC.
3238+
message DeleteConnectedSiteTagRequest {
3239+
// The Universal Analytics property to delete connected site tags for.
3240+
// This API does not support GA4 properties.
3241+
// Format: properties/{universalAnalyticsPropertyId}
3242+
// Example: properties/1234
3243+
string property = 1;
3244+
3245+
// Tag ID to forward events to. Also known as the Measurement ID, or the
3246+
// "G-ID" (For example: G-12345).
3247+
string tag_id = 2;
3248+
}
3249+
3250+
// Request message for ListConnectedSiteTags RPC.
3251+
message ListConnectedSiteTagsRequest {
3252+
// The Universal Analytics property to fetch connected site tags for.
3253+
// This does not work on GA4 properties. A maximum of 20 connected site tags
3254+
// will be returned.
3255+
// Example Format: `properties/1234`
3256+
string property = 1;
3257+
}
3258+
3259+
// Response message for ListConnectedSiteTags RPC.
3260+
message ListConnectedSiteTagsResponse {
3261+
// The site tags for the Universal Analytics property. A maximum of 20
3262+
// connected site tags will be returned.
3263+
repeated ConnectedSiteTag connected_site_tags = 1;
3264+
}

google/analytics/admin/v1alpha/analyticsadmin_v1alpha.yaml

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -137,6 +137,11 @@ authentication:
137137
canonical_scopes: |-
138138
https://www.googleapis.com/auth/analytics.edit,
139139
https://www.googleapis.com/auth/analytics.readonly
140+
- selector: google.analytics.admin.v1alpha.AnalyticsAdminService.GetEnhancedMeasurementSettings
141+
oauth:
142+
canonical_scopes: |-
143+
https://www.googleapis.com/auth/analytics.edit,
144+
https://www.googleapis.com/auth/analytics.readonly
140145
- selector: google.analytics.admin.v1alpha.AnalyticsAdminService.GetExpandedDataSet
141146
oauth:
142147
canonical_scopes: |-
@@ -197,6 +202,11 @@ authentication:
197202
canonical_scopes: |-
198203
https://www.googleapis.com/auth/analytics.edit,
199204
https://www.googleapis.com/auth/analytics.readonly
205+
- selector: google.analytics.admin.v1alpha.AnalyticsAdminService.ListConnectedSiteTags
206+
oauth:
207+
canonical_scopes: |-
208+
https://www.googleapis.com/auth/analytics.edit,
209+
https://www.googleapis.com/auth/analytics.readonly
200210
- selector: google.analytics.admin.v1alpha.AnalyticsAdminService.ListConversionEvents
201211
oauth:
202212
canonical_scopes: |-

google/analytics/admin/v1alpha/audience.proto

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
// Copyright 2022 Google LLC
1+
// Copyright 2023 Google LLC
22
//
33
// Licensed under the Apache License, Version 2.0 (the "License");
44
// you may not use this file except in compliance with the License.

google/analytics/admin/v1alpha/expanded_data_set.proto

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
// Copyright 2022 Google LLC
1+
// Copyright 2023 Google LLC
22
//
33
// Licensed under the Apache License, Version 2.0 (the "License");
44
// you may not use this file except in compliance with the License.

0 commit comments

Comments
 (0)