google-analytics-admin-v1alpha 0.33.0 → 0.34.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -524,6 +524,23 @@ module Google
524
524
  "properties/#{property}"
525
525
  end
526
526
 
527
+ ##
528
+ # Create a fully-qualified ReportingDataAnnotation resource string.
529
+ #
530
+ # The resource will be in the following format:
531
+ #
532
+ # `properties/{property}/reportingDataAnnotations/{reporting_data_annotation}`
533
+ #
534
+ # @param property [String]
535
+ # @param reporting_data_annotation [String]
536
+ #
537
+ # @return [::String]
538
+ def reporting_data_annotation_path property:, reporting_data_annotation:
539
+ raise ::ArgumentError, "property cannot contain /" if property.to_s.include? "/"
540
+
541
+ "properties/#{property}/reportingDataAnnotations/#{reporting_data_annotation}"
542
+ end
543
+
527
544
  ##
528
545
  # Create a fully-qualified RollupPropertySourceLink resource string.
529
546
  #
@@ -12988,6 +12988,573 @@ module Google
12988
12988
  raise ::Google::Cloud::Error.from_error(e)
12989
12989
  end
12990
12990
 
12991
+ ##
12992
+ # Creates a Reporting Data Annotation.
12993
+ #
12994
+ # @overload create_reporting_data_annotation(request, options = nil)
12995
+ # Pass arguments to `create_reporting_data_annotation` via a request object, either of type
12996
+ # {::Google::Analytics::Admin::V1alpha::CreateReportingDataAnnotationRequest} or an equivalent Hash.
12997
+ #
12998
+ # @param request [::Google::Analytics::Admin::V1alpha::CreateReportingDataAnnotationRequest, ::Hash]
12999
+ # A request object representing the call parameters. Required. To specify no
13000
+ # parameters, or to keep all the default parameter values, pass an empty Hash.
13001
+ # @param options [::Gapic::CallOptions, ::Hash]
13002
+ # Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
13003
+ #
13004
+ # @overload create_reporting_data_annotation(parent: nil, reporting_data_annotation: nil)
13005
+ # Pass arguments to `create_reporting_data_annotation` via keyword arguments. Note that at
13006
+ # least one keyword argument is required. To specify no parameters, or to keep all
13007
+ # the default parameter values, pass an empty Hash as a request object (see above).
13008
+ #
13009
+ # @param parent [::String]
13010
+ # Required. The property for which to create a Reporting Data Annotation.
13011
+ # Format: properties/property_id
13012
+ # Example: properties/123
13013
+ # @param reporting_data_annotation [::Google::Analytics::Admin::V1alpha::ReportingDataAnnotation, ::Hash]
13014
+ # Required. The Reporting Data Annotation to create.
13015
+ # @yield [result, operation] Access the result along with the TransportOperation object
13016
+ # @yieldparam result [::Google::Analytics::Admin::V1alpha::ReportingDataAnnotation]
13017
+ # @yieldparam operation [::Gapic::Rest::TransportOperation]
13018
+ #
13019
+ # @return [::Google::Analytics::Admin::V1alpha::ReportingDataAnnotation]
13020
+ #
13021
+ # @raise [::Google::Cloud::Error] if the REST call is aborted.
13022
+ #
13023
+ # @example Basic example
13024
+ # require "google/analytics/admin/v1alpha"
13025
+ #
13026
+ # # Create a client object. The client can be reused for multiple calls.
13027
+ # client = Google::Analytics::Admin::V1alpha::AnalyticsAdminService::Rest::Client.new
13028
+ #
13029
+ # # Create a request. To set request fields, pass in keyword arguments.
13030
+ # request = Google::Analytics::Admin::V1alpha::CreateReportingDataAnnotationRequest.new
13031
+ #
13032
+ # # Call the create_reporting_data_annotation method.
13033
+ # result = client.create_reporting_data_annotation request
13034
+ #
13035
+ # # The returned object is of type Google::Analytics::Admin::V1alpha::ReportingDataAnnotation.
13036
+ # p result
13037
+ #
13038
+ def create_reporting_data_annotation request, options = nil
13039
+ raise ::ArgumentError, "request must be provided" if request.nil?
13040
+
13041
+ request = ::Gapic::Protobuf.coerce request, to: ::Google::Analytics::Admin::V1alpha::CreateReportingDataAnnotationRequest
13042
+
13043
+ # Converts hash and nil to an options object
13044
+ options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h
13045
+
13046
+ # Customize the options with defaults
13047
+ call_metadata = @config.rpcs.create_reporting_data_annotation.metadata.to_h
13048
+
13049
+ # Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers
13050
+ call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
13051
+ lib_name: @config.lib_name, lib_version: @config.lib_version,
13052
+ gapic_version: ::Google::Analytics::Admin::V1alpha::VERSION,
13053
+ transports_version_send: [:rest]
13054
+
13055
+ call_metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty?
13056
+ call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
13057
+
13058
+ options.apply_defaults timeout: @config.rpcs.create_reporting_data_annotation.timeout,
13059
+ metadata: call_metadata,
13060
+ retry_policy: @config.rpcs.create_reporting_data_annotation.retry_policy
13061
+
13062
+ options.apply_defaults timeout: @config.timeout,
13063
+ metadata: @config.metadata,
13064
+ retry_policy: @config.retry_policy
13065
+
13066
+ @analytics_admin_service_stub.create_reporting_data_annotation request, options do |result, operation|
13067
+ yield result, operation if block_given?
13068
+ end
13069
+ rescue ::Gapic::Rest::Error => e
13070
+ raise ::Google::Cloud::Error.from_error(e)
13071
+ end
13072
+
13073
+ ##
13074
+ # Lookup a single Reporting Data Annotation.
13075
+ #
13076
+ # @overload get_reporting_data_annotation(request, options = nil)
13077
+ # Pass arguments to `get_reporting_data_annotation` via a request object, either of type
13078
+ # {::Google::Analytics::Admin::V1alpha::GetReportingDataAnnotationRequest} or an equivalent Hash.
13079
+ #
13080
+ # @param request [::Google::Analytics::Admin::V1alpha::GetReportingDataAnnotationRequest, ::Hash]
13081
+ # A request object representing the call parameters. Required. To specify no
13082
+ # parameters, or to keep all the default parameter values, pass an empty Hash.
13083
+ # @param options [::Gapic::CallOptions, ::Hash]
13084
+ # Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
13085
+ #
13086
+ # @overload get_reporting_data_annotation(name: nil)
13087
+ # Pass arguments to `get_reporting_data_annotation` via keyword arguments. Note that at
13088
+ # least one keyword argument is required. To specify no parameters, or to keep all
13089
+ # the default parameter values, pass an empty Hash as a request object (see above).
13090
+ #
13091
+ # @param name [::String]
13092
+ # Required. Resource name of the Reporting Data Annotation to lookup.
13093
+ # Format:
13094
+ # properties/property_id/reportingDataAnnotations/reportingDataAnnotation
13095
+ # Example: properties/123/reportingDataAnnotations/456
13096
+ # @yield [result, operation] Access the result along with the TransportOperation object
13097
+ # @yieldparam result [::Google::Analytics::Admin::V1alpha::ReportingDataAnnotation]
13098
+ # @yieldparam operation [::Gapic::Rest::TransportOperation]
13099
+ #
13100
+ # @return [::Google::Analytics::Admin::V1alpha::ReportingDataAnnotation]
13101
+ #
13102
+ # @raise [::Google::Cloud::Error] if the REST call is aborted.
13103
+ #
13104
+ # @example Basic example
13105
+ # require "google/analytics/admin/v1alpha"
13106
+ #
13107
+ # # Create a client object. The client can be reused for multiple calls.
13108
+ # client = Google::Analytics::Admin::V1alpha::AnalyticsAdminService::Rest::Client.new
13109
+ #
13110
+ # # Create a request. To set request fields, pass in keyword arguments.
13111
+ # request = Google::Analytics::Admin::V1alpha::GetReportingDataAnnotationRequest.new
13112
+ #
13113
+ # # Call the get_reporting_data_annotation method.
13114
+ # result = client.get_reporting_data_annotation request
13115
+ #
13116
+ # # The returned object is of type Google::Analytics::Admin::V1alpha::ReportingDataAnnotation.
13117
+ # p result
13118
+ #
13119
+ def get_reporting_data_annotation request, options = nil
13120
+ raise ::ArgumentError, "request must be provided" if request.nil?
13121
+
13122
+ request = ::Gapic::Protobuf.coerce request, to: ::Google::Analytics::Admin::V1alpha::GetReportingDataAnnotationRequest
13123
+
13124
+ # Converts hash and nil to an options object
13125
+ options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h
13126
+
13127
+ # Customize the options with defaults
13128
+ call_metadata = @config.rpcs.get_reporting_data_annotation.metadata.to_h
13129
+
13130
+ # Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers
13131
+ call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
13132
+ lib_name: @config.lib_name, lib_version: @config.lib_version,
13133
+ gapic_version: ::Google::Analytics::Admin::V1alpha::VERSION,
13134
+ transports_version_send: [:rest]
13135
+
13136
+ call_metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty?
13137
+ call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
13138
+
13139
+ options.apply_defaults timeout: @config.rpcs.get_reporting_data_annotation.timeout,
13140
+ metadata: call_metadata,
13141
+ retry_policy: @config.rpcs.get_reporting_data_annotation.retry_policy
13142
+
13143
+ options.apply_defaults timeout: @config.timeout,
13144
+ metadata: @config.metadata,
13145
+ retry_policy: @config.retry_policy
13146
+
13147
+ @analytics_admin_service_stub.get_reporting_data_annotation request, options do |result, operation|
13148
+ yield result, operation if block_given?
13149
+ end
13150
+ rescue ::Gapic::Rest::Error => e
13151
+ raise ::Google::Cloud::Error.from_error(e)
13152
+ end
13153
+
13154
+ ##
13155
+ # List all Reporting Data Annotations on a property.
13156
+ #
13157
+ # @overload list_reporting_data_annotations(request, options = nil)
13158
+ # Pass arguments to `list_reporting_data_annotations` via a request object, either of type
13159
+ # {::Google::Analytics::Admin::V1alpha::ListReportingDataAnnotationsRequest} or an equivalent Hash.
13160
+ #
13161
+ # @param request [::Google::Analytics::Admin::V1alpha::ListReportingDataAnnotationsRequest, ::Hash]
13162
+ # A request object representing the call parameters. Required. To specify no
13163
+ # parameters, or to keep all the default parameter values, pass an empty Hash.
13164
+ # @param options [::Gapic::CallOptions, ::Hash]
13165
+ # Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
13166
+ #
13167
+ # @overload list_reporting_data_annotations(parent: nil, filter: nil, page_size: nil, page_token: nil)
13168
+ # Pass arguments to `list_reporting_data_annotations` via keyword arguments. Note that at
13169
+ # least one keyword argument is required. To specify no parameters, or to keep all
13170
+ # the default parameter values, pass an empty Hash as a request object (see above).
13171
+ #
13172
+ # @param parent [::String]
13173
+ # Required. Resource name of the property.
13174
+ # Format: properties/property_id
13175
+ # Example: properties/123
13176
+ # @param filter [::String]
13177
+ # Optional. Filter that restricts which reporting data annotations under the
13178
+ # parent property are listed.
13179
+ #
13180
+ # Supported fields are:
13181
+ #
13182
+ # * 'name'
13183
+ # * `title`
13184
+ # * `description`
13185
+ # * `annotation_date`
13186
+ # * `annotation_date_range`
13187
+ # * `color`
13188
+ #
13189
+ # Additionally, this API provides the following helper functions:
13190
+ #
13191
+ # * annotation_duration() : the duration that this annotation marks,
13192
+ # [durations](https://github.com/protocolbuffers/protobuf/blob/main/src/google/protobuf/duration.proto).
13193
+ # expect a numeric representation of seconds followed by an `s` suffix.
13194
+ # * is_annotation_in_range(start_date, end_date) : if the annotation is in
13195
+ # the range specified by the `start_date` and `end_date`. The dates are in
13196
+ # ISO-8601 format, for example `2031-06-28`.
13197
+ #
13198
+ # Supported operations:
13199
+ #
13200
+ # * `=` : equals
13201
+ # * `!=` : not equals
13202
+ # * `<` : less than
13203
+ # * `>` : greater than
13204
+ # * `<=` : less than or equals
13205
+ # * `>=` : greater than or equals
13206
+ # * `:` : has operator
13207
+ # * `=~` : [regular expression](https://github.com/google/re2/wiki/Syntax)
13208
+ # match
13209
+ # * `!~` : [regular expression](https://github.com/google/re2/wiki/Syntax)
13210
+ # does not match
13211
+ # * `NOT` : Logical not
13212
+ # * `AND` : Logical and
13213
+ # * `OR` : Logical or
13214
+ #
13215
+ # Examples:
13216
+ #
13217
+ # 1. `title="Holiday Sale"`
13218
+ # 2. `description=~"[Bb]ig [Gg]ame.*[Ss]ale"`
13219
+ # 3. `is_annotation_in_range("2025-12-25", "2026-01-16") = true`
13220
+ # 4. `annotation_duration() >= 172800s AND title:BOGO`
13221
+ # @param page_size [::Integer]
13222
+ # Optional. The maximum number of resources to return. The service may return
13223
+ # fewer than this value, even if there are additional pages. If unspecified,
13224
+ # at most 50 resources will be returned. The maximum value is 200; (higher
13225
+ # values will be coerced to the maximum)
13226
+ # @param page_token [::String]
13227
+ # Optional. A page token, received from a previous
13228
+ # `ListReportingDataAnnotations` call. Provide this to retrieve the
13229
+ # subsequent page. When paginating, all other parameters provided to
13230
+ # `ListReportingDataAnnotations` must match the call that provided the page
13231
+ # token.
13232
+ # @yield [result, operation] Access the result along with the TransportOperation object
13233
+ # @yieldparam result [::Gapic::Rest::PagedEnumerable<::Google::Analytics::Admin::V1alpha::ReportingDataAnnotation>]
13234
+ # @yieldparam operation [::Gapic::Rest::TransportOperation]
13235
+ #
13236
+ # @return [::Gapic::Rest::PagedEnumerable<::Google::Analytics::Admin::V1alpha::ReportingDataAnnotation>]
13237
+ #
13238
+ # @raise [::Google::Cloud::Error] if the REST call is aborted.
13239
+ #
13240
+ # @example Basic example
13241
+ # require "google/analytics/admin/v1alpha"
13242
+ #
13243
+ # # Create a client object. The client can be reused for multiple calls.
13244
+ # client = Google::Analytics::Admin::V1alpha::AnalyticsAdminService::Rest::Client.new
13245
+ #
13246
+ # # Create a request. To set request fields, pass in keyword arguments.
13247
+ # request = Google::Analytics::Admin::V1alpha::ListReportingDataAnnotationsRequest.new
13248
+ #
13249
+ # # Call the list_reporting_data_annotations method.
13250
+ # result = client.list_reporting_data_annotations request
13251
+ #
13252
+ # # The returned object is of type Gapic::PagedEnumerable. You can iterate
13253
+ # # over elements, and API calls will be issued to fetch pages as needed.
13254
+ # result.each do |item|
13255
+ # # Each element is of type ::Google::Analytics::Admin::V1alpha::ReportingDataAnnotation.
13256
+ # p item
13257
+ # end
13258
+ #
13259
+ def list_reporting_data_annotations request, options = nil
13260
+ raise ::ArgumentError, "request must be provided" if request.nil?
13261
+
13262
+ request = ::Gapic::Protobuf.coerce request, to: ::Google::Analytics::Admin::V1alpha::ListReportingDataAnnotationsRequest
13263
+
13264
+ # Converts hash and nil to an options object
13265
+ options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h
13266
+
13267
+ # Customize the options with defaults
13268
+ call_metadata = @config.rpcs.list_reporting_data_annotations.metadata.to_h
13269
+
13270
+ # Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers
13271
+ call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
13272
+ lib_name: @config.lib_name, lib_version: @config.lib_version,
13273
+ gapic_version: ::Google::Analytics::Admin::V1alpha::VERSION,
13274
+ transports_version_send: [:rest]
13275
+
13276
+ call_metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty?
13277
+ call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
13278
+
13279
+ options.apply_defaults timeout: @config.rpcs.list_reporting_data_annotations.timeout,
13280
+ metadata: call_metadata,
13281
+ retry_policy: @config.rpcs.list_reporting_data_annotations.retry_policy
13282
+
13283
+ options.apply_defaults timeout: @config.timeout,
13284
+ metadata: @config.metadata,
13285
+ retry_policy: @config.retry_policy
13286
+
13287
+ @analytics_admin_service_stub.list_reporting_data_annotations request, options do |result, operation|
13288
+ result = ::Gapic::Rest::PagedEnumerable.new @analytics_admin_service_stub, :list_reporting_data_annotations, "reporting_data_annotations", request, result, options
13289
+ yield result, operation if block_given?
13290
+ throw :response, result
13291
+ end
13292
+ rescue ::Gapic::Rest::Error => e
13293
+ raise ::Google::Cloud::Error.from_error(e)
13294
+ end
13295
+
13296
+ ##
13297
+ # Updates a Reporting Data Annotation.
13298
+ #
13299
+ # @overload update_reporting_data_annotation(request, options = nil)
13300
+ # Pass arguments to `update_reporting_data_annotation` via a request object, either of type
13301
+ # {::Google::Analytics::Admin::V1alpha::UpdateReportingDataAnnotationRequest} or an equivalent Hash.
13302
+ #
13303
+ # @param request [::Google::Analytics::Admin::V1alpha::UpdateReportingDataAnnotationRequest, ::Hash]
13304
+ # A request object representing the call parameters. Required. To specify no
13305
+ # parameters, or to keep all the default parameter values, pass an empty Hash.
13306
+ # @param options [::Gapic::CallOptions, ::Hash]
13307
+ # Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
13308
+ #
13309
+ # @overload update_reporting_data_annotation(reporting_data_annotation: nil, update_mask: nil)
13310
+ # Pass arguments to `update_reporting_data_annotation` via keyword arguments. Note that at
13311
+ # least one keyword argument is required. To specify no parameters, or to keep all
13312
+ # the default parameter values, pass an empty Hash as a request object (see above).
13313
+ #
13314
+ # @param reporting_data_annotation [::Google::Analytics::Admin::V1alpha::ReportingDataAnnotation, ::Hash]
13315
+ # Required. The Reporting Data Annotation to update.
13316
+ # @param update_mask [::Google::Protobuf::FieldMask, ::Hash]
13317
+ # Optional. The list of fields to update. Field names must be in snake case
13318
+ # (for example, "field_to_update"). Omitted fields will not be updated. To
13319
+ # replace the entire entity, use one path with the string "*" to match all
13320
+ # fields.
13321
+ # @yield [result, operation] Access the result along with the TransportOperation object
13322
+ # @yieldparam result [::Google::Analytics::Admin::V1alpha::ReportingDataAnnotation]
13323
+ # @yieldparam operation [::Gapic::Rest::TransportOperation]
13324
+ #
13325
+ # @return [::Google::Analytics::Admin::V1alpha::ReportingDataAnnotation]
13326
+ #
13327
+ # @raise [::Google::Cloud::Error] if the REST call is aborted.
13328
+ #
13329
+ # @example Basic example
13330
+ # require "google/analytics/admin/v1alpha"
13331
+ #
13332
+ # # Create a client object. The client can be reused for multiple calls.
13333
+ # client = Google::Analytics::Admin::V1alpha::AnalyticsAdminService::Rest::Client.new
13334
+ #
13335
+ # # Create a request. To set request fields, pass in keyword arguments.
13336
+ # request = Google::Analytics::Admin::V1alpha::UpdateReportingDataAnnotationRequest.new
13337
+ #
13338
+ # # Call the update_reporting_data_annotation method.
13339
+ # result = client.update_reporting_data_annotation request
13340
+ #
13341
+ # # The returned object is of type Google::Analytics::Admin::V1alpha::ReportingDataAnnotation.
13342
+ # p result
13343
+ #
13344
+ def update_reporting_data_annotation request, options = nil
13345
+ raise ::ArgumentError, "request must be provided" if request.nil?
13346
+
13347
+ request = ::Gapic::Protobuf.coerce request, to: ::Google::Analytics::Admin::V1alpha::UpdateReportingDataAnnotationRequest
13348
+
13349
+ # Converts hash and nil to an options object
13350
+ options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h
13351
+
13352
+ # Customize the options with defaults
13353
+ call_metadata = @config.rpcs.update_reporting_data_annotation.metadata.to_h
13354
+
13355
+ # Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers
13356
+ call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
13357
+ lib_name: @config.lib_name, lib_version: @config.lib_version,
13358
+ gapic_version: ::Google::Analytics::Admin::V1alpha::VERSION,
13359
+ transports_version_send: [:rest]
13360
+
13361
+ call_metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty?
13362
+ call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
13363
+
13364
+ options.apply_defaults timeout: @config.rpcs.update_reporting_data_annotation.timeout,
13365
+ metadata: call_metadata,
13366
+ retry_policy: @config.rpcs.update_reporting_data_annotation.retry_policy
13367
+
13368
+ options.apply_defaults timeout: @config.timeout,
13369
+ metadata: @config.metadata,
13370
+ retry_policy: @config.retry_policy
13371
+
13372
+ @analytics_admin_service_stub.update_reporting_data_annotation request, options do |result, operation|
13373
+ yield result, operation if block_given?
13374
+ end
13375
+ rescue ::Gapic::Rest::Error => e
13376
+ raise ::Google::Cloud::Error.from_error(e)
13377
+ end
13378
+
13379
+ ##
13380
+ # Deletes a Reporting Data Annotation.
13381
+ #
13382
+ # @overload delete_reporting_data_annotation(request, options = nil)
13383
+ # Pass arguments to `delete_reporting_data_annotation` via a request object, either of type
13384
+ # {::Google::Analytics::Admin::V1alpha::DeleteReportingDataAnnotationRequest} or an equivalent Hash.
13385
+ #
13386
+ # @param request [::Google::Analytics::Admin::V1alpha::DeleteReportingDataAnnotationRequest, ::Hash]
13387
+ # A request object representing the call parameters. Required. To specify no
13388
+ # parameters, or to keep all the default parameter values, pass an empty Hash.
13389
+ # @param options [::Gapic::CallOptions, ::Hash]
13390
+ # Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
13391
+ #
13392
+ # @overload delete_reporting_data_annotation(name: nil)
13393
+ # Pass arguments to `delete_reporting_data_annotation` via keyword arguments. Note that at
13394
+ # least one keyword argument is required. To specify no parameters, or to keep all
13395
+ # the default parameter values, pass an empty Hash as a request object (see above).
13396
+ #
13397
+ # @param name [::String]
13398
+ # Required. Resource name of the Reporting Data Annotation to delete.
13399
+ # Format:
13400
+ # properties/property_id/reportingDataAnnotations/reporting_data_annotation
13401
+ # Example: properties/123/reportingDataAnnotations/456
13402
+ # @yield [result, operation] Access the result along with the TransportOperation object
13403
+ # @yieldparam result [::Google::Protobuf::Empty]
13404
+ # @yieldparam operation [::Gapic::Rest::TransportOperation]
13405
+ #
13406
+ # @return [::Google::Protobuf::Empty]
13407
+ #
13408
+ # @raise [::Google::Cloud::Error] if the REST call is aborted.
13409
+ #
13410
+ # @example Basic example
13411
+ # require "google/analytics/admin/v1alpha"
13412
+ #
13413
+ # # Create a client object. The client can be reused for multiple calls.
13414
+ # client = Google::Analytics::Admin::V1alpha::AnalyticsAdminService::Rest::Client.new
13415
+ #
13416
+ # # Create a request. To set request fields, pass in keyword arguments.
13417
+ # request = Google::Analytics::Admin::V1alpha::DeleteReportingDataAnnotationRequest.new
13418
+ #
13419
+ # # Call the delete_reporting_data_annotation method.
13420
+ # result = client.delete_reporting_data_annotation request
13421
+ #
13422
+ # # The returned object is of type Google::Protobuf::Empty.
13423
+ # p result
13424
+ #
13425
+ def delete_reporting_data_annotation request, options = nil
13426
+ raise ::ArgumentError, "request must be provided" if request.nil?
13427
+
13428
+ request = ::Gapic::Protobuf.coerce request, to: ::Google::Analytics::Admin::V1alpha::DeleteReportingDataAnnotationRequest
13429
+
13430
+ # Converts hash and nil to an options object
13431
+ options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h
13432
+
13433
+ # Customize the options with defaults
13434
+ call_metadata = @config.rpcs.delete_reporting_data_annotation.metadata.to_h
13435
+
13436
+ # Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers
13437
+ call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
13438
+ lib_name: @config.lib_name, lib_version: @config.lib_version,
13439
+ gapic_version: ::Google::Analytics::Admin::V1alpha::VERSION,
13440
+ transports_version_send: [:rest]
13441
+
13442
+ call_metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty?
13443
+ call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
13444
+
13445
+ options.apply_defaults timeout: @config.rpcs.delete_reporting_data_annotation.timeout,
13446
+ metadata: call_metadata,
13447
+ retry_policy: @config.rpcs.delete_reporting_data_annotation.retry_policy
13448
+
13449
+ options.apply_defaults timeout: @config.timeout,
13450
+ metadata: @config.metadata,
13451
+ retry_policy: @config.retry_policy
13452
+
13453
+ @analytics_admin_service_stub.delete_reporting_data_annotation request, options do |result, operation|
13454
+ yield result, operation if block_given?
13455
+ end
13456
+ rescue ::Gapic::Rest::Error => e
13457
+ raise ::Google::Cloud::Error.from_error(e)
13458
+ end
13459
+
13460
+ ##
13461
+ # Submits a request for user deletion for a property.
13462
+ #
13463
+ # @overload submit_user_deletion(request, options = nil)
13464
+ # Pass arguments to `submit_user_deletion` via a request object, either of type
13465
+ # {::Google::Analytics::Admin::V1alpha::SubmitUserDeletionRequest} or an equivalent Hash.
13466
+ #
13467
+ # @param request [::Google::Analytics::Admin::V1alpha::SubmitUserDeletionRequest, ::Hash]
13468
+ # A request object representing the call parameters. Required. To specify no
13469
+ # parameters, or to keep all the default parameter values, pass an empty Hash.
13470
+ # @param options [::Gapic::CallOptions, ::Hash]
13471
+ # Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
13472
+ #
13473
+ # @overload submit_user_deletion(user_id: nil, client_id: nil, app_instance_id: nil, user_provided_data: nil, name: nil)
13474
+ # Pass arguments to `submit_user_deletion` via keyword arguments. Note that at
13475
+ # least one keyword argument is required. To specify no parameters, or to keep all
13476
+ # the default parameter values, pass an empty Hash as a request object (see above).
13477
+ #
13478
+ # @param user_id [::String]
13479
+ # Google Analytics [user
13480
+ # ID](https://firebase.google.com/docs/analytics/userid).
13481
+ #
13482
+ # Note: The following fields are mutually exclusive: `user_id`, `client_id`, `app_instance_id`, `user_provided_data`. If a field in that set is populated, all other fields in the set will automatically be cleared.
13483
+ # @param client_id [::String]
13484
+ # Google Analytics [client
13485
+ # ID](https://support.google.com/analytics/answer/11593727).
13486
+ #
13487
+ # Note: The following fields are mutually exclusive: `client_id`, `user_id`, `app_instance_id`, `user_provided_data`. If a field in that set is populated, all other fields in the set will automatically be cleared.
13488
+ # @param app_instance_id [::String]
13489
+ # Firebase [application instance
13490
+ # ID](https://firebase.google.com/docs/reference/android/com/google/firebase/analytics/FirebaseAnalytics.html#getAppInstanceId).
13491
+ #
13492
+ # Note: The following fields are mutually exclusive: `app_instance_id`, `user_id`, `client_id`, `user_provided_data`. If a field in that set is populated, all other fields in the set will automatically be cleared.
13493
+ # @param user_provided_data [::String]
13494
+ # The un-hashed, unencrypted, [user-provided
13495
+ # data](https://support.google.com/analytics/answer/14077171).
13496
+ #
13497
+ # Note: The following fields are mutually exclusive: `user_provided_data`, `user_id`, `client_id`, `app_instance_id`. If a field in that set is populated, all other fields in the set will automatically be cleared.
13498
+ # @param name [::String]
13499
+ # Required. The name of the property to submit user deletion for.
13500
+ # @yield [result, operation] Access the result along with the TransportOperation object
13501
+ # @yieldparam result [::Google::Analytics::Admin::V1alpha::SubmitUserDeletionResponse]
13502
+ # @yieldparam operation [::Gapic::Rest::TransportOperation]
13503
+ #
13504
+ # @return [::Google::Analytics::Admin::V1alpha::SubmitUserDeletionResponse]
13505
+ #
13506
+ # @raise [::Google::Cloud::Error] if the REST call is aborted.
13507
+ #
13508
+ # @example Basic example
13509
+ # require "google/analytics/admin/v1alpha"
13510
+ #
13511
+ # # Create a client object. The client can be reused for multiple calls.
13512
+ # client = Google::Analytics::Admin::V1alpha::AnalyticsAdminService::Rest::Client.new
13513
+ #
13514
+ # # Create a request. To set request fields, pass in keyword arguments.
13515
+ # request = Google::Analytics::Admin::V1alpha::SubmitUserDeletionRequest.new
13516
+ #
13517
+ # # Call the submit_user_deletion method.
13518
+ # result = client.submit_user_deletion request
13519
+ #
13520
+ # # The returned object is of type Google::Analytics::Admin::V1alpha::SubmitUserDeletionResponse.
13521
+ # p result
13522
+ #
13523
+ def submit_user_deletion request, options = nil
13524
+ raise ::ArgumentError, "request must be provided" if request.nil?
13525
+
13526
+ request = ::Gapic::Protobuf.coerce request, to: ::Google::Analytics::Admin::V1alpha::SubmitUserDeletionRequest
13527
+
13528
+ # Converts hash and nil to an options object
13529
+ options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h
13530
+
13531
+ # Customize the options with defaults
13532
+ call_metadata = @config.rpcs.submit_user_deletion.metadata.to_h
13533
+
13534
+ # Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers
13535
+ call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
13536
+ lib_name: @config.lib_name, lib_version: @config.lib_version,
13537
+ gapic_version: ::Google::Analytics::Admin::V1alpha::VERSION,
13538
+ transports_version_send: [:rest]
13539
+
13540
+ call_metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty?
13541
+ call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
13542
+
13543
+ options.apply_defaults timeout: @config.rpcs.submit_user_deletion.timeout,
13544
+ metadata: call_metadata,
13545
+ retry_policy: @config.rpcs.submit_user_deletion.retry_policy
13546
+
13547
+ options.apply_defaults timeout: @config.timeout,
13548
+ metadata: @config.metadata,
13549
+ retry_policy: @config.retry_policy
13550
+
13551
+ @analytics_admin_service_stub.submit_user_deletion request, options do |result, operation|
13552
+ yield result, operation if block_given?
13553
+ end
13554
+ rescue ::Gapic::Rest::Error => e
13555
+ raise ::Google::Cloud::Error.from_error(e)
13556
+ end
13557
+
12991
13558
  ##
12992
13559
  # Configuration class for the AnalyticsAdminService REST API.
12993
13560
  #
@@ -13884,6 +14451,36 @@ module Google
13884
14451
  # @return [::Gapic::Config::Method]
13885
14452
  #
13886
14453
  attr_reader :delete_subproperty_event_filter
14454
+ ##
14455
+ # RPC-specific configuration for `create_reporting_data_annotation`
14456
+ # @return [::Gapic::Config::Method]
14457
+ #
14458
+ attr_reader :create_reporting_data_annotation
14459
+ ##
14460
+ # RPC-specific configuration for `get_reporting_data_annotation`
14461
+ # @return [::Gapic::Config::Method]
14462
+ #
14463
+ attr_reader :get_reporting_data_annotation
14464
+ ##
14465
+ # RPC-specific configuration for `list_reporting_data_annotations`
14466
+ # @return [::Gapic::Config::Method]
14467
+ #
14468
+ attr_reader :list_reporting_data_annotations
14469
+ ##
14470
+ # RPC-specific configuration for `update_reporting_data_annotation`
14471
+ # @return [::Gapic::Config::Method]
14472
+ #
14473
+ attr_reader :update_reporting_data_annotation
14474
+ ##
14475
+ # RPC-specific configuration for `delete_reporting_data_annotation`
14476
+ # @return [::Gapic::Config::Method]
14477
+ #
14478
+ attr_reader :delete_reporting_data_annotation
14479
+ ##
14480
+ # RPC-specific configuration for `submit_user_deletion`
14481
+ # @return [::Gapic::Config::Method]
14482
+ #
14483
+ attr_reader :submit_user_deletion
13887
14484
 
13888
14485
  # @private
13889
14486
  def initialize parent_rpcs = nil
@@ -14187,6 +14784,18 @@ module Google
14187
14784
  @update_subproperty_event_filter = ::Gapic::Config::Method.new update_subproperty_event_filter_config
14188
14785
  delete_subproperty_event_filter_config = parent_rpcs.delete_subproperty_event_filter if parent_rpcs.respond_to? :delete_subproperty_event_filter
14189
14786
  @delete_subproperty_event_filter = ::Gapic::Config::Method.new delete_subproperty_event_filter_config
14787
+ create_reporting_data_annotation_config = parent_rpcs.create_reporting_data_annotation if parent_rpcs.respond_to? :create_reporting_data_annotation
14788
+ @create_reporting_data_annotation = ::Gapic::Config::Method.new create_reporting_data_annotation_config
14789
+ get_reporting_data_annotation_config = parent_rpcs.get_reporting_data_annotation if parent_rpcs.respond_to? :get_reporting_data_annotation
14790
+ @get_reporting_data_annotation = ::Gapic::Config::Method.new get_reporting_data_annotation_config
14791
+ list_reporting_data_annotations_config = parent_rpcs.list_reporting_data_annotations if parent_rpcs.respond_to? :list_reporting_data_annotations
14792
+ @list_reporting_data_annotations = ::Gapic::Config::Method.new list_reporting_data_annotations_config
14793
+ update_reporting_data_annotation_config = parent_rpcs.update_reporting_data_annotation if parent_rpcs.respond_to? :update_reporting_data_annotation
14794
+ @update_reporting_data_annotation = ::Gapic::Config::Method.new update_reporting_data_annotation_config
14795
+ delete_reporting_data_annotation_config = parent_rpcs.delete_reporting_data_annotation if parent_rpcs.respond_to? :delete_reporting_data_annotation
14796
+ @delete_reporting_data_annotation = ::Gapic::Config::Method.new delete_reporting_data_annotation_config
14797
+ submit_user_deletion_config = parent_rpcs.submit_user_deletion if parent_rpcs.respond_to? :submit_user_deletion
14798
+ @submit_user_deletion = ::Gapic::Config::Method.new submit_user_deletion_config
14190
14799
 
14191
14800
  yield self if block_given?
14192
14801
  end