google-cloud-security_center_management-v1 0.1.0 → 0.2.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.
- checksums.yaml +4 -4
- data/lib/google/cloud/security_center_management/v1/security_center_management/client.rb +415 -68
- data/lib/google/cloud/security_center_management/v1/security_center_management/paths.rb +58 -0
- data/lib/google/cloud/security_center_management/v1/security_center_management/rest/client.rb +394 -68
- data/lib/google/cloud/security_center_management/v1/security_center_management/rest/service_stub.rb +222 -0
- data/lib/google/cloud/security_center_management/v1/version.rb +1 -1
- data/lib/google/cloud/securitycentermanagement/v1/security_center_management_pb.rb +9 -2
- data/lib/google/cloud/securitycentermanagement/v1/security_center_management_services_pb.rb +7 -0
- data/proto_docs/google/cloud/securitycentermanagement/v1/security_center_management.rb +252 -77
- metadata +2 -2
data/lib/google/cloud/security_center_management/v1/security_center_management/rest/client.rb
CHANGED
@@ -33,6 +33,9 @@ module Google
|
|
33
33
|
# Service describing handlers for resources
|
34
34
|
#
|
35
35
|
class Client
|
36
|
+
# @private
|
37
|
+
API_VERSION = ""
|
38
|
+
|
36
39
|
# @private
|
37
40
|
DEFAULT_ENDPOINT_TEMPLATE = "securitycentermanagement.$UNIVERSE_DOMAIN$"
|
38
41
|
|
@@ -263,11 +266,12 @@ module Google
|
|
263
266
|
# the default parameter values, pass an empty Hash as a request object (see above).
|
264
267
|
#
|
265
268
|
# @param parent [::String]
|
266
|
-
# Required. Name of parent to list effective custom modules.
|
267
|
-
#
|
268
|
-
#
|
269
|
+
# Required. Name of parent to list effective custom modules. specified in one
|
270
|
+
# of the following formats:
|
271
|
+
# * `organizations/{organization}/locations/{location}`
|
272
|
+
# * `folders/{folder}/locations/{location}`
|
269
273
|
# or
|
270
|
-
#
|
274
|
+
# `projects/{project}/locations/{location}`
|
271
275
|
# @param page_size [::Integer]
|
272
276
|
# Optional. The maximum number of results to return in a single response.
|
273
277
|
# Default is 10, minimum is 1, maximum is 1000.
|
@@ -311,12 +315,13 @@ module Google
|
|
311
315
|
# Customize the options with defaults
|
312
316
|
call_metadata = @config.rpcs.list_effective_security_health_analytics_custom_modules.metadata.to_h
|
313
317
|
|
314
|
-
# Set x-goog-api-client
|
318
|
+
# Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers
|
315
319
|
call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
|
316
320
|
lib_name: @config.lib_name, lib_version: @config.lib_version,
|
317
321
|
gapic_version: ::Google::Cloud::SecurityCenterManagement::V1::VERSION,
|
318
322
|
transports_version_send: [:rest]
|
319
323
|
|
324
|
+
call_metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty?
|
320
325
|
call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
|
321
326
|
|
322
327
|
options.apply_defaults timeout: @config.rpcs.list_effective_security_health_analytics_custom_modules.timeout,
|
@@ -355,13 +360,12 @@ module Google
|
|
355
360
|
# the default parameter values, pass an empty Hash as a request object (see above).
|
356
361
|
#
|
357
362
|
# @param name [::String]
|
358
|
-
# Required. The resource name of the
|
363
|
+
# Required. The full resource name of the custom module, specified in one of
|
364
|
+
# the following formats:
|
359
365
|
#
|
360
|
-
#
|
361
|
-
#
|
362
|
-
#
|
363
|
-
# * "folders/\\{folder}/locations/\\{location}/effectiveSecurityHealthAnalyticsCustomModules/\\{module_id}".
|
364
|
-
# * "projects/\\{project}/locations/\\{location}/effectiveSecurityHealthAnalyticsCustomModules/\\{module_id}".
|
366
|
+
# * `organizations/organization/{location}/effectiveSecurityHealthAnalyticsCustomModules/{effective_security_health_analytics_custom_module}`
|
367
|
+
# * `folders/folder/{location}/effectiveSecurityHealthAnalyticsCustomModules/{effective_security_health_analytics_custom_module}`
|
368
|
+
# * `projects/project/{location}/effectiveSecurityHealthAnalyticsCustomModules/{effective_security_health_analytics_custom_module}`
|
365
369
|
# @yield [result, operation] Access the result along with the TransportOperation object
|
366
370
|
# @yieldparam result [::Google::Cloud::SecurityCenterManagement::V1::EffectiveSecurityHealthAnalyticsCustomModule]
|
367
371
|
# @yieldparam operation [::Gapic::Rest::TransportOperation]
|
@@ -396,12 +400,13 @@ module Google
|
|
396
400
|
# Customize the options with defaults
|
397
401
|
call_metadata = @config.rpcs.get_effective_security_health_analytics_custom_module.metadata.to_h
|
398
402
|
|
399
|
-
# Set x-goog-api-client
|
403
|
+
# Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers
|
400
404
|
call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
|
401
405
|
lib_name: @config.lib_name, lib_version: @config.lib_version,
|
402
406
|
gapic_version: ::Google::Cloud::SecurityCenterManagement::V1::VERSION,
|
403
407
|
transports_version_send: [:rest]
|
404
408
|
|
409
|
+
call_metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty?
|
405
410
|
call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
|
406
411
|
|
407
412
|
options.apply_defaults timeout: @config.rpcs.get_effective_security_health_analytics_custom_module.timeout,
|
@@ -441,11 +446,12 @@ module Google
|
|
441
446
|
# the default parameter values, pass an empty Hash as a request object (see above).
|
442
447
|
#
|
443
448
|
# @param parent [::String]
|
444
|
-
# Required. Name of parent
|
445
|
-
#
|
446
|
-
#
|
447
|
-
#
|
448
|
-
#
|
449
|
+
# Required. Name of parent organization, folder, or project in which to list
|
450
|
+
# custom modules, specified in one of the following formats:
|
451
|
+
#
|
452
|
+
# * `organizations/{organization}/locations/{location}`
|
453
|
+
# * `folders/{folder}/locations/{location}`
|
454
|
+
# * `projects/{project}/locations/{location}`
|
449
455
|
# @param page_size [::Integer]
|
450
456
|
# Optional. The maximum number of results to return in a single response.
|
451
457
|
# Default is 10, minimum is 1, maximum is 1000.
|
@@ -489,12 +495,13 @@ module Google
|
|
489
495
|
# Customize the options with defaults
|
490
496
|
call_metadata = @config.rpcs.list_security_health_analytics_custom_modules.metadata.to_h
|
491
497
|
|
492
|
-
# Set x-goog-api-client
|
498
|
+
# Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers
|
493
499
|
call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
|
494
500
|
lib_name: @config.lib_name, lib_version: @config.lib_version,
|
495
501
|
gapic_version: ::Google::Cloud::SecurityCenterManagement::V1::VERSION,
|
496
502
|
transports_version_send: [:rest]
|
497
503
|
|
504
|
+
call_metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty?
|
498
505
|
call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
|
499
506
|
|
500
507
|
options.apply_defaults timeout: @config.rpcs.list_security_health_analytics_custom_modules.timeout,
|
@@ -534,11 +541,12 @@ module Google
|
|
534
541
|
# the default parameter values, pass an empty Hash as a request object (see above).
|
535
542
|
#
|
536
543
|
# @param parent [::String]
|
537
|
-
# Required. Name of parent
|
538
|
-
#
|
539
|
-
#
|
540
|
-
#
|
541
|
-
#
|
544
|
+
# Required. Name of the parent organization, folder, or project in which to
|
545
|
+
# list custom modules, specified in one of the following formats:
|
546
|
+
#
|
547
|
+
# * `organizations/{organization}/locations/{location}`
|
548
|
+
# * `folders/{folder}/locations/{location}`
|
549
|
+
# * `projects/{project}/locations/{location}`
|
542
550
|
# @param page_size [::Integer]
|
543
551
|
# Optional. The maximum number of results to return in a single response.
|
544
552
|
# Default is 10, minimum is 1, maximum is 1000.
|
@@ -582,12 +590,13 @@ module Google
|
|
582
590
|
# Customize the options with defaults
|
583
591
|
call_metadata = @config.rpcs.list_descendant_security_health_analytics_custom_modules.metadata.to_h
|
584
592
|
|
585
|
-
# Set x-goog-api-client
|
593
|
+
# Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers
|
586
594
|
call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
|
587
595
|
lib_name: @config.lib_name, lib_version: @config.lib_version,
|
588
596
|
gapic_version: ::Google::Cloud::SecurityCenterManagement::V1::VERSION,
|
589
597
|
transports_version_send: [:rest]
|
590
598
|
|
599
|
+
call_metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty?
|
591
600
|
call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
|
592
601
|
|
593
602
|
options.apply_defaults timeout: @config.rpcs.list_descendant_security_health_analytics_custom_modules.timeout,
|
@@ -661,12 +670,13 @@ module Google
|
|
661
670
|
# Customize the options with defaults
|
662
671
|
call_metadata = @config.rpcs.get_security_health_analytics_custom_module.metadata.to_h
|
663
672
|
|
664
|
-
# Set x-goog-api-client
|
673
|
+
# Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers
|
665
674
|
call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
|
666
675
|
lib_name: @config.lib_name, lib_version: @config.lib_version,
|
667
676
|
gapic_version: ::Google::Cloud::SecurityCenterManagement::V1::VERSION,
|
668
677
|
transports_version_send: [:rest]
|
669
678
|
|
679
|
+
call_metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty?
|
670
680
|
call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
|
671
681
|
|
672
682
|
options.apply_defaults timeout: @config.rpcs.get_security_health_analytics_custom_module.timeout,
|
@@ -707,11 +717,12 @@ module Google
|
|
707
717
|
# the default parameter values, pass an empty Hash as a request object (see above).
|
708
718
|
#
|
709
719
|
# @param parent [::String]
|
710
|
-
# Required. Name of the parent
|
711
|
-
#
|
712
|
-
#
|
713
|
-
#
|
714
|
-
#
|
720
|
+
# Required. Name of the parent organization, folder, or project of the
|
721
|
+
# module, specified in one of the following formats:
|
722
|
+
#
|
723
|
+
# * `organizations/{organization}/locations/{location}`
|
724
|
+
# * `folders/{folder}/locations/{location}`
|
725
|
+
# * `projects/{project}/locations/{location}`
|
715
726
|
# @param security_health_analytics_custom_module [::Google::Cloud::SecurityCenterManagement::V1::SecurityHealthAnalyticsCustomModule, ::Hash]
|
716
727
|
# Required. The resource being created
|
717
728
|
# @param validate_only [::Boolean]
|
@@ -757,12 +768,13 @@ module Google
|
|
757
768
|
# Customize the options with defaults
|
758
769
|
call_metadata = @config.rpcs.create_security_health_analytics_custom_module.metadata.to_h
|
759
770
|
|
760
|
-
# Set x-goog-api-client
|
771
|
+
# Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers
|
761
772
|
call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
|
762
773
|
lib_name: @config.lib_name, lib_version: @config.lib_version,
|
763
774
|
gapic_version: ::Google::Cloud::SecurityCenterManagement::V1::VERSION,
|
764
775
|
transports_version_send: [:rest]
|
765
776
|
|
777
|
+
call_metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty?
|
766
778
|
call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
|
767
779
|
|
768
780
|
options.apply_defaults timeout: @config.rpcs.create_security_health_analytics_custom_module.timeout,
|
@@ -852,12 +864,13 @@ module Google
|
|
852
864
|
# Customize the options with defaults
|
853
865
|
call_metadata = @config.rpcs.update_security_health_analytics_custom_module.metadata.to_h
|
854
866
|
|
855
|
-
# Set x-goog-api-client
|
867
|
+
# Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers
|
856
868
|
call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
|
857
869
|
lib_name: @config.lib_name, lib_version: @config.lib_version,
|
858
870
|
gapic_version: ::Google::Cloud::SecurityCenterManagement::V1::VERSION,
|
859
871
|
transports_version_send: [:rest]
|
860
872
|
|
873
|
+
call_metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty?
|
861
874
|
call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
|
862
875
|
|
863
876
|
options.apply_defaults timeout: @config.rpcs.update_security_health_analytics_custom_module.timeout,
|
@@ -901,9 +914,9 @@ module Google
|
|
901
914
|
#
|
902
915
|
# Its format is:
|
903
916
|
#
|
904
|
-
# *
|
905
|
-
# *
|
906
|
-
# *
|
917
|
+
# * `organizations/{organization}/locations/{location}/securityHealthAnalyticsCustomModules/{security_health_analytics_custom_module}`.
|
918
|
+
# * `folders/{folder}/locations/{location}/securityHealthAnalyticsCustomModules/{security_health_analytics_custom_module}`.
|
919
|
+
# * `projects/{project}/locations/{location}/securityHealthAnalyticsCustomModules/{security_health_analytics_custom_module}`.
|
907
920
|
# @param validate_only [::Boolean]
|
908
921
|
# Optional. When set to true, only validations (including IAM checks) will
|
909
922
|
# done for the request (module will not be deleted). An OK response indicates
|
@@ -946,12 +959,13 @@ module Google
|
|
946
959
|
# Customize the options with defaults
|
947
960
|
call_metadata = @config.rpcs.delete_security_health_analytics_custom_module.metadata.to_h
|
948
961
|
|
949
|
-
# Set x-goog-api-client
|
962
|
+
# Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers
|
950
963
|
call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
|
951
964
|
lib_name: @config.lib_name, lib_version: @config.lib_version,
|
952
965
|
gapic_version: ::Google::Cloud::SecurityCenterManagement::V1::VERSION,
|
953
966
|
transports_version_send: [:rest]
|
954
967
|
|
968
|
+
call_metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty?
|
955
969
|
call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
|
956
970
|
|
957
971
|
options.apply_defaults timeout: @config.rpcs.delete_security_health_analytics_custom_module.timeout,
|
@@ -1032,12 +1046,13 @@ module Google
|
|
1032
1046
|
# Customize the options with defaults
|
1033
1047
|
call_metadata = @config.rpcs.simulate_security_health_analytics_custom_module.metadata.to_h
|
1034
1048
|
|
1035
|
-
# Set x-goog-api-client
|
1049
|
+
# Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers
|
1036
1050
|
call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
|
1037
1051
|
lib_name: @config.lib_name, lib_version: @config.lib_version,
|
1038
1052
|
gapic_version: ::Google::Cloud::SecurityCenterManagement::V1::VERSION,
|
1039
1053
|
transports_version_send: [:rest]
|
1040
1054
|
|
1055
|
+
call_metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty?
|
1041
1056
|
call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
|
1042
1057
|
|
1043
1058
|
options.apply_defaults timeout: @config.rpcs.simulate_security_health_analytics_custom_module.timeout,
|
@@ -1078,10 +1093,10 @@ module Google
|
|
1078
1093
|
#
|
1079
1094
|
# @param parent [::String]
|
1080
1095
|
# Required. Name of parent to list effective custom modules. Its format is
|
1081
|
-
#
|
1082
|
-
#
|
1096
|
+
# `organizations/{organization}/locations/{location}`,
|
1097
|
+
# `folders/{folder}/locations/{location}`,
|
1083
1098
|
# or
|
1084
|
-
#
|
1099
|
+
# `projects/{project}/locations/{location}`
|
1085
1100
|
# @param page_size [::Integer]
|
1086
1101
|
# Optional. The maximum number of results to return in a single response.
|
1087
1102
|
# Default is 10, minimum is 1, maximum is 1000.
|
@@ -1125,12 +1140,13 @@ module Google
|
|
1125
1140
|
# Customize the options with defaults
|
1126
1141
|
call_metadata = @config.rpcs.list_effective_event_threat_detection_custom_modules.metadata.to_h
|
1127
1142
|
|
1128
|
-
# Set x-goog-api-client
|
1143
|
+
# Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers
|
1129
1144
|
call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
|
1130
1145
|
lib_name: @config.lib_name, lib_version: @config.lib_version,
|
1131
1146
|
gapic_version: ::Google::Cloud::SecurityCenterManagement::V1::VERSION,
|
1132
1147
|
transports_version_send: [:rest]
|
1133
1148
|
|
1149
|
+
call_metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty?
|
1134
1150
|
call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
|
1135
1151
|
|
1136
1152
|
options.apply_defaults timeout: @config.rpcs.list_effective_event_threat_detection_custom_modules.timeout,
|
@@ -1179,9 +1195,9 @@ module Google
|
|
1179
1195
|
#
|
1180
1196
|
# Its format is:
|
1181
1197
|
#
|
1182
|
-
# *
|
1183
|
-
# *
|
1184
|
-
# *
|
1198
|
+
# * `organizations/{organization}/locations/{location}/effectiveEventThreatDetectionCustomModules/{effective_event_threat_detection_custom_module}`.
|
1199
|
+
# * `folders/{folder}/locations/{location}/effectiveEventThreatDetectionCustomModules/{effective_event_threat_detection_custom_module}`.
|
1200
|
+
# * `projects/{project}/locations/{location}/effectiveEventThreatDetectionCustomModules/{effective_event_threat_detection_custom_module}`.
|
1185
1201
|
# @yield [result, operation] Access the result along with the TransportOperation object
|
1186
1202
|
# @yieldparam result [::Google::Cloud::SecurityCenterManagement::V1::EffectiveEventThreatDetectionCustomModule]
|
1187
1203
|
# @yieldparam operation [::Gapic::Rest::TransportOperation]
|
@@ -1216,12 +1232,13 @@ module Google
|
|
1216
1232
|
# Customize the options with defaults
|
1217
1233
|
call_metadata = @config.rpcs.get_effective_event_threat_detection_custom_module.metadata.to_h
|
1218
1234
|
|
1219
|
-
# Set x-goog-api-client
|
1235
|
+
# Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers
|
1220
1236
|
call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
|
1221
1237
|
lib_name: @config.lib_name, lib_version: @config.lib_version,
|
1222
1238
|
gapic_version: ::Google::Cloud::SecurityCenterManagement::V1::VERSION,
|
1223
1239
|
transports_version_send: [:rest]
|
1224
1240
|
|
1241
|
+
call_metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty?
|
1225
1242
|
call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
|
1226
1243
|
|
1227
1244
|
options.apply_defaults timeout: @config.rpcs.get_effective_event_threat_detection_custom_module.timeout,
|
@@ -1262,10 +1279,10 @@ module Google
|
|
1262
1279
|
#
|
1263
1280
|
# @param parent [::String]
|
1264
1281
|
# Required. Name of parent to list custom modules. Its format is
|
1265
|
-
#
|
1266
|
-
#
|
1282
|
+
# `organizations/{organization}/locations/{location}`,
|
1283
|
+
# `folders/{folder}/locations/{location}`,
|
1267
1284
|
# or
|
1268
|
-
#
|
1285
|
+
# `projects/{project}/locations/{location}`
|
1269
1286
|
# @param page_size [::Integer]
|
1270
1287
|
# Optional. The maximum number of modules to return. The service may return
|
1271
1288
|
# fewer than this value. If unspecified, at most 10 configs will be returned.
|
@@ -1316,12 +1333,13 @@ module Google
|
|
1316
1333
|
# Customize the options with defaults
|
1317
1334
|
call_metadata = @config.rpcs.list_event_threat_detection_custom_modules.metadata.to_h
|
1318
1335
|
|
1319
|
-
# Set x-goog-api-client
|
1336
|
+
# Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers
|
1320
1337
|
call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
|
1321
1338
|
lib_name: @config.lib_name, lib_version: @config.lib_version,
|
1322
1339
|
gapic_version: ::Google::Cloud::SecurityCenterManagement::V1::VERSION,
|
1323
1340
|
transports_version_send: [:rest]
|
1324
1341
|
|
1342
|
+
call_metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty?
|
1325
1343
|
call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
|
1326
1344
|
|
1327
1345
|
options.apply_defaults timeout: @config.rpcs.list_event_threat_detection_custom_modules.timeout,
|
@@ -1362,10 +1380,10 @@ module Google
|
|
1362
1380
|
#
|
1363
1381
|
# @param parent [::String]
|
1364
1382
|
# Required. Name of parent to list custom modules. Its format is
|
1365
|
-
#
|
1366
|
-
#
|
1383
|
+
# `organizations/{organization}/locations/{location}`,
|
1384
|
+
# `folders/{folder}/locations/{location}`,
|
1367
1385
|
# or
|
1368
|
-
#
|
1386
|
+
# `projects/{project}/locations/{location}`
|
1369
1387
|
# @param page_size [::Integer]
|
1370
1388
|
# Optional. The maximum number of modules to return. The service may return
|
1371
1389
|
# fewer than this value. If unspecified, at most 10 configs will be returned.
|
@@ -1410,12 +1428,13 @@ module Google
|
|
1410
1428
|
# Customize the options with defaults
|
1411
1429
|
call_metadata = @config.rpcs.list_descendant_event_threat_detection_custom_modules.metadata.to_h
|
1412
1430
|
|
1413
|
-
# Set x-goog-api-client
|
1431
|
+
# Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers
|
1414
1432
|
call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
|
1415
1433
|
lib_name: @config.lib_name, lib_version: @config.lib_version,
|
1416
1434
|
gapic_version: ::Google::Cloud::SecurityCenterManagement::V1::VERSION,
|
1417
1435
|
transports_version_send: [:rest]
|
1418
1436
|
|
1437
|
+
call_metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty?
|
1419
1438
|
call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
|
1420
1439
|
|
1421
1440
|
options.apply_defaults timeout: @config.rpcs.list_descendant_event_threat_detection_custom_modules.timeout,
|
@@ -1458,9 +1477,9 @@ module Google
|
|
1458
1477
|
#
|
1459
1478
|
# Its format is:
|
1460
1479
|
#
|
1461
|
-
# *
|
1462
|
-
# *
|
1463
|
-
# *
|
1480
|
+
# * `organizations/{organization}/locations/{location}/eventThreatDetectionCustomModules/{event_threat_detection_custom_module}`.
|
1481
|
+
# * `folders/{folder}/locations/{location}/eventThreatDetectionCustomModules/{event_threat_detection_custom_module}`.
|
1482
|
+
# * `projects/{project}/locations/{location}/eventThreatDetectionCustomModules/{event_threat_detection_custom_module}`.
|
1464
1483
|
# @yield [result, operation] Access the result along with the TransportOperation object
|
1465
1484
|
# @yieldparam result [::Google::Cloud::SecurityCenterManagement::V1::EventThreatDetectionCustomModule]
|
1466
1485
|
# @yieldparam operation [::Gapic::Rest::TransportOperation]
|
@@ -1495,12 +1514,13 @@ module Google
|
|
1495
1514
|
# Customize the options with defaults
|
1496
1515
|
call_metadata = @config.rpcs.get_event_threat_detection_custom_module.metadata.to_h
|
1497
1516
|
|
1498
|
-
# Set x-goog-api-client
|
1517
|
+
# Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers
|
1499
1518
|
call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
|
1500
1519
|
lib_name: @config.lib_name, lib_version: @config.lib_version,
|
1501
1520
|
gapic_version: ::Google::Cloud::SecurityCenterManagement::V1::VERSION,
|
1502
1521
|
transports_version_send: [:rest]
|
1503
1522
|
|
1523
|
+
call_metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty?
|
1504
1524
|
call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
|
1505
1525
|
|
1506
1526
|
options.apply_defaults timeout: @config.rpcs.get_event_threat_detection_custom_module.timeout,
|
@@ -1542,10 +1562,10 @@ module Google
|
|
1542
1562
|
#
|
1543
1563
|
# @param parent [::String]
|
1544
1564
|
# Required. Name of parent for the module. Its format is
|
1545
|
-
#
|
1546
|
-
#
|
1565
|
+
# `organizations/{organization}/locations/{location}`,
|
1566
|
+
# `folders/{folder}/locations/{location}`,
|
1547
1567
|
# or
|
1548
|
-
#
|
1568
|
+
# `projects/{project}/locations/{location}`
|
1549
1569
|
# @param event_threat_detection_custom_module [::Google::Cloud::SecurityCenterManagement::V1::EventThreatDetectionCustomModule, ::Hash]
|
1550
1570
|
# Required. The module to create. The
|
1551
1571
|
# event_threat_detection_custom_module.name will be ignored and server
|
@@ -1592,12 +1612,13 @@ module Google
|
|
1592
1612
|
# Customize the options with defaults
|
1593
1613
|
call_metadata = @config.rpcs.create_event_threat_detection_custom_module.metadata.to_h
|
1594
1614
|
|
1595
|
-
# Set x-goog-api-client
|
1615
|
+
# Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers
|
1596
1616
|
call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
|
1597
1617
|
lib_name: @config.lib_name, lib_version: @config.lib_version,
|
1598
1618
|
gapic_version: ::Google::Cloud::SecurityCenterManagement::V1::VERSION,
|
1599
1619
|
transports_version_send: [:rest]
|
1600
1620
|
|
1621
|
+
call_metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty?
|
1601
1622
|
call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
|
1602
1623
|
|
1603
1624
|
options.apply_defaults timeout: @config.rpcs.create_event_threat_detection_custom_module.timeout,
|
@@ -1689,12 +1710,13 @@ module Google
|
|
1689
1710
|
# Customize the options with defaults
|
1690
1711
|
call_metadata = @config.rpcs.update_event_threat_detection_custom_module.metadata.to_h
|
1691
1712
|
|
1692
|
-
# Set x-goog-api-client
|
1713
|
+
# Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers
|
1693
1714
|
call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
|
1694
1715
|
lib_name: @config.lib_name, lib_version: @config.lib_version,
|
1695
1716
|
gapic_version: ::Google::Cloud::SecurityCenterManagement::V1::VERSION,
|
1696
1717
|
transports_version_send: [:rest]
|
1697
1718
|
|
1719
|
+
call_metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty?
|
1698
1720
|
call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
|
1699
1721
|
|
1700
1722
|
options.apply_defaults timeout: @config.rpcs.update_event_threat_detection_custom_module.timeout,
|
@@ -1738,9 +1760,9 @@ module Google
|
|
1738
1760
|
#
|
1739
1761
|
# Its format is:
|
1740
1762
|
#
|
1741
|
-
# *
|
1742
|
-
# *
|
1743
|
-
# *
|
1763
|
+
# * `organizations/{organization}/locations/{location}/eventThreatDetectionCustomModules/{event_threat_detection_custom_module}`.
|
1764
|
+
# * `folders/{folder}/locations/{location}/eventThreatDetectionCustomModules/{event_threat_detection_custom_module}`.
|
1765
|
+
# * `projects/{project}/locations/{location}/eventThreatDetectionCustomModules/{event_threat_detection_custom_module}`.
|
1744
1766
|
# @param validate_only [::Boolean]
|
1745
1767
|
# Optional. When set to true, only validations (including IAM checks) will
|
1746
1768
|
# done for the request (module will not be deleted). An OK response indicates
|
@@ -1783,12 +1805,13 @@ module Google
|
|
1783
1805
|
# Customize the options with defaults
|
1784
1806
|
call_metadata = @config.rpcs.delete_event_threat_detection_custom_module.metadata.to_h
|
1785
1807
|
|
1786
|
-
# Set x-goog-api-client
|
1808
|
+
# Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers
|
1787
1809
|
call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
|
1788
1810
|
lib_name: @config.lib_name, lib_version: @config.lib_version,
|
1789
1811
|
gapic_version: ::Google::Cloud::SecurityCenterManagement::V1::VERSION,
|
1790
1812
|
transports_version_send: [:rest]
|
1791
1813
|
|
1814
|
+
call_metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty?
|
1792
1815
|
call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
|
1793
1816
|
|
1794
1817
|
options.apply_defaults timeout: @config.rpcs.delete_event_threat_detection_custom_module.timeout,
|
@@ -1830,7 +1853,7 @@ module Google
|
|
1830
1853
|
#
|
1831
1854
|
# Its format is:
|
1832
1855
|
#
|
1833
|
-
# *
|
1856
|
+
# * `organizations/{organization}/locations/{location}`.
|
1834
1857
|
# @param raw_text [::String]
|
1835
1858
|
# Required. The raw text of the module's contents. Used to generate error
|
1836
1859
|
# messages.
|
@@ -1870,12 +1893,13 @@ module Google
|
|
1870
1893
|
# Customize the options with defaults
|
1871
1894
|
call_metadata = @config.rpcs.validate_event_threat_detection_custom_module.metadata.to_h
|
1872
1895
|
|
1873
|
-
# Set x-goog-api-client
|
1896
|
+
# Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers
|
1874
1897
|
call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
|
1875
1898
|
lib_name: @config.lib_name, lib_version: @config.lib_version,
|
1876
1899
|
gapic_version: ::Google::Cloud::SecurityCenterManagement::V1::VERSION,
|
1877
1900
|
transports_version_send: [:rest]
|
1878
1901
|
|
1902
|
+
call_metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty?
|
1879
1903
|
call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
|
1880
1904
|
|
1881
1905
|
options.apply_defaults timeout: @config.rpcs.validate_event_threat_detection_custom_module.timeout,
|
@@ -1894,6 +1918,287 @@ module Google
|
|
1894
1918
|
raise ::Google::Cloud::Error.from_error(e)
|
1895
1919
|
end
|
1896
1920
|
|
1921
|
+
##
|
1922
|
+
# Gets service settings for the specified Security Command Center service.
|
1923
|
+
#
|
1924
|
+
# @overload get_security_center_service(request, options = nil)
|
1925
|
+
# Pass arguments to `get_security_center_service` via a request object, either of type
|
1926
|
+
# {::Google::Cloud::SecurityCenterManagement::V1::GetSecurityCenterServiceRequest} or an equivalent Hash.
|
1927
|
+
#
|
1928
|
+
# @param request [::Google::Cloud::SecurityCenterManagement::V1::GetSecurityCenterServiceRequest, ::Hash]
|
1929
|
+
# A request object representing the call parameters. Required. To specify no
|
1930
|
+
# parameters, or to keep all the default parameter values, pass an empty Hash.
|
1931
|
+
# @param options [::Gapic::CallOptions, ::Hash]
|
1932
|
+
# Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
|
1933
|
+
#
|
1934
|
+
# @overload get_security_center_service(name: nil)
|
1935
|
+
# Pass arguments to `get_security_center_service` via keyword arguments. Note that at
|
1936
|
+
# least one keyword argument is required. To specify no parameters, or to keep all
|
1937
|
+
# the default parameter values, pass an empty Hash as a request object (see above).
|
1938
|
+
#
|
1939
|
+
# @param name [::String]
|
1940
|
+
# Required. The Security Command Center service to retrieve.
|
1941
|
+
#
|
1942
|
+
# Formats:
|
1943
|
+
#
|
1944
|
+
# * organizations/\\{organization}/locations/\\{location}/securityCenterServices/\\{service}
|
1945
|
+
# * folders/\\{folder}/locations/\\{location}/securityCenterServices/\\{service}
|
1946
|
+
# * projects/\\{project}/locations/\\{location}/securityCenterServices/\\{service}
|
1947
|
+
#
|
1948
|
+
# The possible values for id \\{service} are:
|
1949
|
+
#
|
1950
|
+
# * container-threat-detection
|
1951
|
+
# * event-threat-detection
|
1952
|
+
# * security-health-analytics
|
1953
|
+
# * vm-threat-detection
|
1954
|
+
# * web-security-scanner
|
1955
|
+
# @yield [result, operation] Access the result along with the TransportOperation object
|
1956
|
+
# @yieldparam result [::Google::Cloud::SecurityCenterManagement::V1::SecurityCenterService]
|
1957
|
+
# @yieldparam operation [::Gapic::Rest::TransportOperation]
|
1958
|
+
#
|
1959
|
+
# @return [::Google::Cloud::SecurityCenterManagement::V1::SecurityCenterService]
|
1960
|
+
#
|
1961
|
+
# @raise [::Google::Cloud::Error] if the REST call is aborted.
|
1962
|
+
#
|
1963
|
+
# @example Basic example
|
1964
|
+
# require "google/cloud/security_center_management/v1"
|
1965
|
+
#
|
1966
|
+
# # Create a client object. The client can be reused for multiple calls.
|
1967
|
+
# client = Google::Cloud::SecurityCenterManagement::V1::SecurityCenterManagement::Rest::Client.new
|
1968
|
+
#
|
1969
|
+
# # Create a request. To set request fields, pass in keyword arguments.
|
1970
|
+
# request = Google::Cloud::SecurityCenterManagement::V1::GetSecurityCenterServiceRequest.new
|
1971
|
+
#
|
1972
|
+
# # Call the get_security_center_service method.
|
1973
|
+
# result = client.get_security_center_service request
|
1974
|
+
#
|
1975
|
+
# # The returned object is of type Google::Cloud::SecurityCenterManagement::V1::SecurityCenterService.
|
1976
|
+
# p result
|
1977
|
+
#
|
1978
|
+
def get_security_center_service request, options = nil
|
1979
|
+
raise ::ArgumentError, "request must be provided" if request.nil?
|
1980
|
+
|
1981
|
+
request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::SecurityCenterManagement::V1::GetSecurityCenterServiceRequest
|
1982
|
+
|
1983
|
+
# Converts hash and nil to an options object
|
1984
|
+
options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h
|
1985
|
+
|
1986
|
+
# Customize the options with defaults
|
1987
|
+
call_metadata = @config.rpcs.get_security_center_service.metadata.to_h
|
1988
|
+
|
1989
|
+
# Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers
|
1990
|
+
call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
|
1991
|
+
lib_name: @config.lib_name, lib_version: @config.lib_version,
|
1992
|
+
gapic_version: ::Google::Cloud::SecurityCenterManagement::V1::VERSION,
|
1993
|
+
transports_version_send: [:rest]
|
1994
|
+
|
1995
|
+
call_metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty?
|
1996
|
+
call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
|
1997
|
+
|
1998
|
+
options.apply_defaults timeout: @config.rpcs.get_security_center_service.timeout,
|
1999
|
+
metadata: call_metadata,
|
2000
|
+
retry_policy: @config.rpcs.get_security_center_service.retry_policy
|
2001
|
+
|
2002
|
+
options.apply_defaults timeout: @config.timeout,
|
2003
|
+
metadata: @config.metadata,
|
2004
|
+
retry_policy: @config.retry_policy
|
2005
|
+
|
2006
|
+
@security_center_management_stub.get_security_center_service request, options do |result, operation|
|
2007
|
+
yield result, operation if block_given?
|
2008
|
+
return result
|
2009
|
+
end
|
2010
|
+
rescue ::Gapic::Rest::Error => e
|
2011
|
+
raise ::Google::Cloud::Error.from_error(e)
|
2012
|
+
end
|
2013
|
+
|
2014
|
+
##
|
2015
|
+
# Returns a list of all Security Command Center services for the given
|
2016
|
+
# parent.
|
2017
|
+
#
|
2018
|
+
# @overload list_security_center_services(request, options = nil)
|
2019
|
+
# Pass arguments to `list_security_center_services` via a request object, either of type
|
2020
|
+
# {::Google::Cloud::SecurityCenterManagement::V1::ListSecurityCenterServicesRequest} or an equivalent Hash.
|
2021
|
+
#
|
2022
|
+
# @param request [::Google::Cloud::SecurityCenterManagement::V1::ListSecurityCenterServicesRequest, ::Hash]
|
2023
|
+
# A request object representing the call parameters. Required. To specify no
|
2024
|
+
# parameters, or to keep all the default parameter values, pass an empty Hash.
|
2025
|
+
# @param options [::Gapic::CallOptions, ::Hash]
|
2026
|
+
# Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
|
2027
|
+
#
|
2028
|
+
# @overload list_security_center_services(parent: nil, page_size: nil, page_token: nil)
|
2029
|
+
# Pass arguments to `list_security_center_services` via keyword arguments. Note that at
|
2030
|
+
# least one keyword argument is required. To specify no parameters, or to keep all
|
2031
|
+
# the default parameter values, pass an empty Hash as a request object (see above).
|
2032
|
+
#
|
2033
|
+
# @param parent [::String]
|
2034
|
+
# Required. The name of the parent to list Security Command Center services.
|
2035
|
+
#
|
2036
|
+
# Formats:
|
2037
|
+
#
|
2038
|
+
# * organizations/\\{organization}/locations/\\{location}
|
2039
|
+
# * folders/\\{folder}/locations/\\{location}
|
2040
|
+
# * projects/\\{project}/locations/\\{location}
|
2041
|
+
# @param page_size [::Integer]
|
2042
|
+
# Optional. The maximum number of results to return in a single response.
|
2043
|
+
# Default is 10, minimum is 1, maximum is 1000.
|
2044
|
+
# @param page_token [::String]
|
2045
|
+
# Optional. The value returned by the last call indicating a continuation.
|
2046
|
+
# @yield [result, operation] Access the result along with the TransportOperation object
|
2047
|
+
# @yieldparam result [::Gapic::Rest::PagedEnumerable<::Google::Cloud::SecurityCenterManagement::V1::SecurityCenterService>]
|
2048
|
+
# @yieldparam operation [::Gapic::Rest::TransportOperation]
|
2049
|
+
#
|
2050
|
+
# @return [::Gapic::Rest::PagedEnumerable<::Google::Cloud::SecurityCenterManagement::V1::SecurityCenterService>]
|
2051
|
+
#
|
2052
|
+
# @raise [::Google::Cloud::Error] if the REST call is aborted.
|
2053
|
+
#
|
2054
|
+
# @example Basic example
|
2055
|
+
# require "google/cloud/security_center_management/v1"
|
2056
|
+
#
|
2057
|
+
# # Create a client object. The client can be reused for multiple calls.
|
2058
|
+
# client = Google::Cloud::SecurityCenterManagement::V1::SecurityCenterManagement::Rest::Client.new
|
2059
|
+
#
|
2060
|
+
# # Create a request. To set request fields, pass in keyword arguments.
|
2061
|
+
# request = Google::Cloud::SecurityCenterManagement::V1::ListSecurityCenterServicesRequest.new
|
2062
|
+
#
|
2063
|
+
# # Call the list_security_center_services method.
|
2064
|
+
# result = client.list_security_center_services request
|
2065
|
+
#
|
2066
|
+
# # The returned object is of type Gapic::PagedEnumerable. You can iterate
|
2067
|
+
# # over elements, and API calls will be issued to fetch pages as needed.
|
2068
|
+
# result.each do |item|
|
2069
|
+
# # Each element is of type ::Google::Cloud::SecurityCenterManagement::V1::SecurityCenterService.
|
2070
|
+
# p item
|
2071
|
+
# end
|
2072
|
+
#
|
2073
|
+
def list_security_center_services request, options = nil
|
2074
|
+
raise ::ArgumentError, "request must be provided" if request.nil?
|
2075
|
+
|
2076
|
+
request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::SecurityCenterManagement::V1::ListSecurityCenterServicesRequest
|
2077
|
+
|
2078
|
+
# Converts hash and nil to an options object
|
2079
|
+
options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h
|
2080
|
+
|
2081
|
+
# Customize the options with defaults
|
2082
|
+
call_metadata = @config.rpcs.list_security_center_services.metadata.to_h
|
2083
|
+
|
2084
|
+
# Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers
|
2085
|
+
call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
|
2086
|
+
lib_name: @config.lib_name, lib_version: @config.lib_version,
|
2087
|
+
gapic_version: ::Google::Cloud::SecurityCenterManagement::V1::VERSION,
|
2088
|
+
transports_version_send: [:rest]
|
2089
|
+
|
2090
|
+
call_metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty?
|
2091
|
+
call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
|
2092
|
+
|
2093
|
+
options.apply_defaults timeout: @config.rpcs.list_security_center_services.timeout,
|
2094
|
+
metadata: call_metadata,
|
2095
|
+
retry_policy: @config.rpcs.list_security_center_services.retry_policy
|
2096
|
+
|
2097
|
+
options.apply_defaults timeout: @config.timeout,
|
2098
|
+
metadata: @config.metadata,
|
2099
|
+
retry_policy: @config.retry_policy
|
2100
|
+
|
2101
|
+
@security_center_management_stub.list_security_center_services request, options do |result, operation|
|
2102
|
+
result = ::Gapic::Rest::PagedEnumerable.new @security_center_management_stub, :list_security_center_services, "security_center_services", request, result, options
|
2103
|
+
yield result, operation if block_given?
|
2104
|
+
return result
|
2105
|
+
end
|
2106
|
+
rescue ::Gapic::Rest::Error => e
|
2107
|
+
raise ::Google::Cloud::Error.from_error(e)
|
2108
|
+
end
|
2109
|
+
|
2110
|
+
##
|
2111
|
+
# Updates a Security Command Center service using the given update mask.
|
2112
|
+
#
|
2113
|
+
# @overload update_security_center_service(request, options = nil)
|
2114
|
+
# Pass arguments to `update_security_center_service` via a request object, either of type
|
2115
|
+
# {::Google::Cloud::SecurityCenterManagement::V1::UpdateSecurityCenterServiceRequest} or an equivalent Hash.
|
2116
|
+
#
|
2117
|
+
# @param request [::Google::Cloud::SecurityCenterManagement::V1::UpdateSecurityCenterServiceRequest, ::Hash]
|
2118
|
+
# A request object representing the call parameters. Required. To specify no
|
2119
|
+
# parameters, or to keep all the default parameter values, pass an empty Hash.
|
2120
|
+
# @param options [::Gapic::CallOptions, ::Hash]
|
2121
|
+
# Overrides the default settings for this call, e.g, timeout, retries etc. Optional.
|
2122
|
+
#
|
2123
|
+
# @overload update_security_center_service(security_center_service: nil, update_mask: nil, validate_only: nil)
|
2124
|
+
# Pass arguments to `update_security_center_service` via keyword arguments. Note that at
|
2125
|
+
# least one keyword argument is required. To specify no parameters, or to keep all
|
2126
|
+
# the default parameter values, pass an empty Hash as a request object (see above).
|
2127
|
+
#
|
2128
|
+
# @param security_center_service [::Google::Cloud::SecurityCenterManagement::V1::SecurityCenterService, ::Hash]
|
2129
|
+
# Required. The updated service.
|
2130
|
+
# @param update_mask [::Google::Protobuf::FieldMask, ::Hash]
|
2131
|
+
# Required. The list of fields to be updated. Possible values:
|
2132
|
+
#
|
2133
|
+
# * "intended_enablement_state"
|
2134
|
+
# * "modules"
|
2135
|
+
# @param validate_only [::Boolean]
|
2136
|
+
# Optional. When set to true, only validations (including IAM checks) will
|
2137
|
+
# done for the request (service will not be updated). An OK response
|
2138
|
+
# indicates the request is valid while an error response indicates the
|
2139
|
+
# request is invalid. Note that a subsequent request to actually update the
|
2140
|
+
# service could still fail because 1. the state could have changed (e.g. IAM
|
2141
|
+
# permission lost) or
|
2142
|
+
# 2. A failure occurred while trying to delete the module.
|
2143
|
+
# @yield [result, operation] Access the result along with the TransportOperation object
|
2144
|
+
# @yieldparam result [::Google::Cloud::SecurityCenterManagement::V1::SecurityCenterService]
|
2145
|
+
# @yieldparam operation [::Gapic::Rest::TransportOperation]
|
2146
|
+
#
|
2147
|
+
# @return [::Google::Cloud::SecurityCenterManagement::V1::SecurityCenterService]
|
2148
|
+
#
|
2149
|
+
# @raise [::Google::Cloud::Error] if the REST call is aborted.
|
2150
|
+
#
|
2151
|
+
# @example Basic example
|
2152
|
+
# require "google/cloud/security_center_management/v1"
|
2153
|
+
#
|
2154
|
+
# # Create a client object. The client can be reused for multiple calls.
|
2155
|
+
# client = Google::Cloud::SecurityCenterManagement::V1::SecurityCenterManagement::Rest::Client.new
|
2156
|
+
#
|
2157
|
+
# # Create a request. To set request fields, pass in keyword arguments.
|
2158
|
+
# request = Google::Cloud::SecurityCenterManagement::V1::UpdateSecurityCenterServiceRequest.new
|
2159
|
+
#
|
2160
|
+
# # Call the update_security_center_service method.
|
2161
|
+
# result = client.update_security_center_service request
|
2162
|
+
#
|
2163
|
+
# # The returned object is of type Google::Cloud::SecurityCenterManagement::V1::SecurityCenterService.
|
2164
|
+
# p result
|
2165
|
+
#
|
2166
|
+
def update_security_center_service request, options = nil
|
2167
|
+
raise ::ArgumentError, "request must be provided" if request.nil?
|
2168
|
+
|
2169
|
+
request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::SecurityCenterManagement::V1::UpdateSecurityCenterServiceRequest
|
2170
|
+
|
2171
|
+
# Converts hash and nil to an options object
|
2172
|
+
options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h
|
2173
|
+
|
2174
|
+
# Customize the options with defaults
|
2175
|
+
call_metadata = @config.rpcs.update_security_center_service.metadata.to_h
|
2176
|
+
|
2177
|
+
# Set x-goog-api-client, x-goog-user-project and x-goog-api-version headers
|
2178
|
+
call_metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
|
2179
|
+
lib_name: @config.lib_name, lib_version: @config.lib_version,
|
2180
|
+
gapic_version: ::Google::Cloud::SecurityCenterManagement::V1::VERSION,
|
2181
|
+
transports_version_send: [:rest]
|
2182
|
+
|
2183
|
+
call_metadata[:"x-goog-api-version"] = API_VERSION unless API_VERSION.empty?
|
2184
|
+
call_metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
|
2185
|
+
|
2186
|
+
options.apply_defaults timeout: @config.rpcs.update_security_center_service.timeout,
|
2187
|
+
metadata: call_metadata,
|
2188
|
+
retry_policy: @config.rpcs.update_security_center_service.retry_policy
|
2189
|
+
|
2190
|
+
options.apply_defaults timeout: @config.timeout,
|
2191
|
+
metadata: @config.metadata,
|
2192
|
+
retry_policy: @config.retry_policy
|
2193
|
+
|
2194
|
+
@security_center_management_stub.update_security_center_service request, options do |result, operation|
|
2195
|
+
yield result, operation if block_given?
|
2196
|
+
return result
|
2197
|
+
end
|
2198
|
+
rescue ::Gapic::Rest::Error => e
|
2199
|
+
raise ::Google::Cloud::Error.from_error(e)
|
2200
|
+
end
|
2201
|
+
|
1897
2202
|
##
|
1898
2203
|
# Configuration class for the SecurityCenterManagement REST API.
|
1899
2204
|
#
|
@@ -2124,6 +2429,21 @@ module Google
|
|
2124
2429
|
# @return [::Gapic::Config::Method]
|
2125
2430
|
#
|
2126
2431
|
attr_reader :validate_event_threat_detection_custom_module
|
2432
|
+
##
|
2433
|
+
# RPC-specific configuration for `get_security_center_service`
|
2434
|
+
# @return [::Gapic::Config::Method]
|
2435
|
+
#
|
2436
|
+
attr_reader :get_security_center_service
|
2437
|
+
##
|
2438
|
+
# RPC-specific configuration for `list_security_center_services`
|
2439
|
+
# @return [::Gapic::Config::Method]
|
2440
|
+
#
|
2441
|
+
attr_reader :list_security_center_services
|
2442
|
+
##
|
2443
|
+
# RPC-specific configuration for `update_security_center_service`
|
2444
|
+
# @return [::Gapic::Config::Method]
|
2445
|
+
#
|
2446
|
+
attr_reader :update_security_center_service
|
2127
2447
|
|
2128
2448
|
# @private
|
2129
2449
|
def initialize parent_rpcs = nil
|
@@ -2163,6 +2483,12 @@ module Google
|
|
2163
2483
|
@delete_event_threat_detection_custom_module = ::Gapic::Config::Method.new delete_event_threat_detection_custom_module_config
|
2164
2484
|
validate_event_threat_detection_custom_module_config = parent_rpcs.validate_event_threat_detection_custom_module if parent_rpcs.respond_to? :validate_event_threat_detection_custom_module
|
2165
2485
|
@validate_event_threat_detection_custom_module = ::Gapic::Config::Method.new validate_event_threat_detection_custom_module_config
|
2486
|
+
get_security_center_service_config = parent_rpcs.get_security_center_service if parent_rpcs.respond_to? :get_security_center_service
|
2487
|
+
@get_security_center_service = ::Gapic::Config::Method.new get_security_center_service_config
|
2488
|
+
list_security_center_services_config = parent_rpcs.list_security_center_services if parent_rpcs.respond_to? :list_security_center_services
|
2489
|
+
@list_security_center_services = ::Gapic::Config::Method.new list_security_center_services_config
|
2490
|
+
update_security_center_service_config = parent_rpcs.update_security_center_service if parent_rpcs.respond_to? :update_security_center_service
|
2491
|
+
@update_security_center_service = ::Gapic::Config::Method.new update_security_center_service_config
|
2166
2492
|
|
2167
2493
|
yield self if block_given?
|
2168
2494
|
end
|