Class: Google::Apis::DlpV2beta1::DLPService

Inherits:
Core::BaseService show all
Defined in:
generated/google/apis/dlp_v2beta1/service.rb

Overview

Cloud Data Loss Prevention (DLP) API

Provides methods for detection, risk analysis, and de-identification of privacy-sensitive fragments in text, images, and Google Cloud Platform storage repositories.

Examples:

require 'google/apis/dlp_v2beta1'

Dlp = Google::Apis::DlpV2beta1 # Alias the module
service = Dlp::DLPService.new

See Also:

Instance Attribute Summary collapse

Attributes inherited from Core::BaseService

#authorization, #base_path, #batch_path, #client, #client_options, #request_options, #root_url, #upload_path

Instance Method Summary collapse

Methods inherited from Core::BaseService

#batch, #batch_upload, #fetch_all, #http

Methods included from Core::Logging

#logger

Constructor Details

#initializeDLPService

Returns a new instance of DLPService



47
48
49
50
# File 'generated/google/apis/dlp_v2beta1/service.rb', line 47

def initialize
  super('https://dlp.googleapis.com/', '')
  @batch_path = 'batch'
end

Instance Attribute Details

#keyString

Returns API key. Your API key identifies your project and provides you with API access, quota, and reports. Required unless you provide an OAuth 2.0 token.

Returns:

  • (String)

    API key. Your API key identifies your project and provides you with API access, quota, and reports. Required unless you provide an OAuth 2.0 token.



40
41
42
# File 'generated/google/apis/dlp_v2beta1/service.rb', line 40

def key
  @key
end

#quota_userString

Returns Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters.

Returns:

  • (String)

    Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters.



45
46
47
# File 'generated/google/apis/dlp_v2beta1/service.rb', line 45

def quota_user
  @quota_user
end

Instance Method Details

#analyze_data_source(google_privacy_dlp_v2beta1_analyze_data_source_risk_request_object = nil, fields: nil, quota_user: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::DlpV2beta1::GoogleLongrunningOperation

Schedules a job to compute risk analysis metrics over content in a Google Cloud Platform repository.

Parameters:

Yields:

  • (result, err)

    Result & error if block supplied

Yield Parameters:

Returns:

Raises:



165
166
167
168
169
170
171
172
173
174
# File 'generated/google/apis/dlp_v2beta1/service.rb', line 165

def analyze_data_source(google_privacy_dlp_v2beta1_analyze_data_source_risk_request_object = nil, fields: nil, quota_user: nil, options: nil, &block)
  command =  make_simple_command(:post, 'v2beta1/dataSource:analyze', options)
  command.request_representation = Google::Apis::DlpV2beta1::GooglePrivacyDlpV2beta1AnalyzeDataSourceRiskRequest::Representation
  command.request_object = google_privacy_dlp_v2beta1_analyze_data_source_risk_request_object
  command.response_representation = Google::Apis::DlpV2beta1::GoogleLongrunningOperation::Representation
  command.response_class = Google::Apis::DlpV2beta1::GoogleLongrunningOperation
  command.query['fields'] = fields unless fields.nil?
  command.query['quotaUser'] = quota_user unless quota_user.nil?
  execute_or_queue_command(command, &block)
end

#cancel_inspect_operation(name, google_longrunning_cancel_operation_request_object = nil, fields: nil, quota_user: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::DlpV2beta1::GoogleProtobufEmpty

Cancels an operation. Use the inspect.operations.get to check whether the cancellation succeeded or the operation completed despite cancellation.

Parameters:

  • name (String)

    The name of the operation resource to be cancelled.

  • google_longrunning_cancel_operation_request_object (Google::Apis::DlpV2beta1::GoogleLongrunningCancelOperationRequest) (defaults to: nil)
  • fields (String)

    Selector specifying which fields to include in a partial response.

  • quota_user (String)

    Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters.

  • options (Google::Apis::RequestOptions)

    Request-specific options

Yields:

  • (result, err)

    Result & error if block supplied

Yield Parameters:

Returns:

Raises:



198
199
200
201
202
203
204
205
206
207
208
# File 'generated/google/apis/dlp_v2beta1/service.rb', line 198

def cancel_inspect_operation(name, google_longrunning_cancel_operation_request_object = nil, fields: nil, quota_user: nil, options: nil, &block)
  command =  make_simple_command(:post, 'v2beta1/{+name}:cancel', options)
  command.request_representation = Google::Apis::DlpV2beta1::GoogleLongrunningCancelOperationRequest::Representation
  command.request_object = google_longrunning_cancel_operation_request_object
  command.response_representation = Google::Apis::DlpV2beta1::GoogleProtobufEmpty::Representation
  command.response_class = Google::Apis::DlpV2beta1::GoogleProtobufEmpty
  command.params['name'] = name unless name.nil?
  command.query['fields'] = fields unless fields.nil?
  command.query['quotaUser'] = quota_user unless quota_user.nil?
  execute_or_queue_command(command, &block)
end

#cancel_risk_analysis_operation(name, google_longrunning_cancel_operation_request_object = nil, fields: nil, quota_user: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::DlpV2beta1::GoogleProtobufEmpty

Cancels an operation. Use the inspect.operations.get to check whether the cancellation succeeded or the operation completed despite cancellation.

Parameters:

  • name (String)

    The name of the operation resource to be cancelled.

  • google_longrunning_cancel_operation_request_object (Google::Apis::DlpV2beta1::GoogleLongrunningCancelOperationRequest) (defaults to: nil)
  • fields (String)

    Selector specifying which fields to include in a partial response.

  • quota_user (String)

    Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters.

  • options (Google::Apis::RequestOptions)

    Request-specific options

Yields:

  • (result, err)

    Result & error if block supplied

Yield Parameters:

Returns:

Raises:



414
415
416
417
418
419
420
421
422
423
424
# File 'generated/google/apis/dlp_v2beta1/service.rb', line 414

def cancel_risk_analysis_operation(name, google_longrunning_cancel_operation_request_object = nil, fields: nil, quota_user: nil, options: nil, &block)
  command =  make_simple_command(:post, 'v2beta1/{+name}:cancel', options)
  command.request_representation = Google::Apis::DlpV2beta1::GoogleLongrunningCancelOperationRequest::Representation
  command.request_object = google_longrunning_cancel_operation_request_object
  command.response_representation = Google::Apis::DlpV2beta1::GoogleProtobufEmpty::Representation
  command.response_class = Google::Apis::DlpV2beta1::GoogleProtobufEmpty
  command.params['name'] = name unless name.nil?
  command.query['fields'] = fields unless fields.nil?
  command.query['quotaUser'] = quota_user unless quota_user.nil?
  execute_or_queue_command(command, &block)
end

#create_inspect_operation(google_privacy_dlp_v2beta1_create_inspect_operation_request_object = nil, fields: nil, quota_user: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::DlpV2beta1::GoogleLongrunningOperation

Schedules a job scanning content in a Google Cloud Platform data repository.

Parameters:

Yields:

  • (result, err)

    Result & error if block supplied

Yield Parameters:

Returns:

Raises:



230
231
232
233
234
235
236
237
238
239
# File 'generated/google/apis/dlp_v2beta1/service.rb', line 230

def create_inspect_operation(google_privacy_dlp_v2beta1_create_inspect_operation_request_object = nil, fields: nil, quota_user: nil, options: nil, &block)
  command =  make_simple_command(:post, 'v2beta1/inspect/operations', options)
  command.request_representation = Google::Apis::DlpV2beta1::GooglePrivacyDlpV2beta1CreateInspectOperationRequest::Representation
  command.request_object = google_privacy_dlp_v2beta1_create_inspect_operation_request_object
  command.response_representation = Google::Apis::DlpV2beta1::GoogleLongrunningOperation::Representation
  command.response_class = Google::Apis::DlpV2beta1::GoogleLongrunningOperation
  command.query['fields'] = fields unless fields.nil?
  command.query['quotaUser'] = quota_user unless quota_user.nil?
  execute_or_queue_command(command, &block)
end

#deidentify_content(google_privacy_dlp_v2beta1_deidentify_content_request_object = nil, fields: nil, quota_user: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::DlpV2beta1::GooglePrivacyDlpV2beta1DeidentifyContentResponse

De-identifies potentially sensitive info from a list of strings. This method has limits on input size and output size.

Parameters:

Yields:

  • (result, err)

    Result & error if block supplied

Yield Parameters:

Returns:

Raises:



72
73
74
75
76
77
78
79
80
81
# File 'generated/google/apis/dlp_v2beta1/service.rb', line 72

def deidentify_content(google_privacy_dlp_v2beta1_deidentify_content_request_object = nil, fields: nil, quota_user: nil, options: nil, &block)
  command =  make_simple_command(:post, 'v2beta1/content:deidentify', options)
  command.request_representation = Google::Apis::DlpV2beta1::GooglePrivacyDlpV2beta1DeidentifyContentRequest::Representation
  command.request_object = google_privacy_dlp_v2beta1_deidentify_content_request_object
  command.response_representation = Google::Apis::DlpV2beta1::GooglePrivacyDlpV2beta1DeidentifyContentResponse::Representation
  command.response_class = Google::Apis::DlpV2beta1::GooglePrivacyDlpV2beta1DeidentifyContentResponse
  command.query['fields'] = fields unless fields.nil?
  command.query['quotaUser'] = quota_user unless quota_user.nil?
  execute_or_queue_command(command, &block)
end

#delete_inspect_operation(name, fields: nil, quota_user: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::DlpV2beta1::GoogleProtobufEmpty

This method is not supported and the server returns UNIMPLEMENTED.

Parameters:

  • name (String)

    The name of the operation resource to be deleted.

  • fields (String)

    Selector specifying which fields to include in a partial response.

  • quota_user (String)

    Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters.

  • options (Google::Apis::RequestOptions)

    Request-specific options

Yields:

  • (result, err)

    Result & error if block supplied

Yield Parameters:

Returns:

Raises:



261
262
263
264
265
266
267
268
269
# File 'generated/google/apis/dlp_v2beta1/service.rb', line 261

def delete_inspect_operation(name, fields: nil, quota_user: nil, options: nil, &block)
  command =  make_simple_command(:delete, 'v2beta1/{+name}', options)
  command.response_representation = Google::Apis::DlpV2beta1::GoogleProtobufEmpty::Representation
  command.response_class = Google::Apis::DlpV2beta1::GoogleProtobufEmpty
  command.params['name'] = name unless name.nil?
  command.query['fields'] = fields unless fields.nil?
  command.query['quotaUser'] = quota_user unless quota_user.nil?
  execute_or_queue_command(command, &block)
end

#delete_risk_analysis_operation(name, fields: nil, quota_user: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::DlpV2beta1::GoogleProtobufEmpty

This method is not supported and the server returns UNIMPLEMENTED.

Parameters:

  • name (String)

    The name of the operation resource to be deleted.

  • fields (String)

    Selector specifying which fields to include in a partial response.

  • quota_user (String)

    Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters.

  • options (Google::Apis::RequestOptions)

    Request-specific options

Yields:

  • (result, err)

    Result & error if block supplied

Yield Parameters:

Returns:

Raises:



446
447
448
449
450
451
452
453
454
# File 'generated/google/apis/dlp_v2beta1/service.rb', line 446

def delete_risk_analysis_operation(name, fields: nil, quota_user: nil, options: nil, &block)
  command =  make_simple_command(:delete, 'v2beta1/{+name}', options)
  command.response_representation = Google::Apis::DlpV2beta1::GoogleProtobufEmpty::Representation
  command.response_class = Google::Apis::DlpV2beta1::GoogleProtobufEmpty
  command.params['name'] = name unless name.nil?
  command.query['fields'] = fields unless fields.nil?
  command.query['quotaUser'] = quota_user unless quota_user.nil?
  execute_or_queue_command(command, &block)
end

#get_inspect_operation(name, fields: nil, quota_user: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::DlpV2beta1::GoogleLongrunningOperation

Gets the latest state of a long-running operation. Clients can use this method to poll the operation result at intervals as recommended by the API service.

Parameters:

  • name (String)

    The name of the operation resource.

  • fields (String)

    Selector specifying which fields to include in a partial response.

  • quota_user (String)

    Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters.

  • options (Google::Apis::RequestOptions)

    Request-specific options

Yields:

  • (result, err)

    Result & error if block supplied

Yield Parameters:

Returns:

Raises:



293
294
295
296
297
298
299
300
301
# File 'generated/google/apis/dlp_v2beta1/service.rb', line 293

def get_inspect_operation(name, fields: nil, quota_user: nil, options: nil, &block)
  command =  make_simple_command(:get, 'v2beta1/{+name}', options)
  command.response_representation = Google::Apis::DlpV2beta1::GoogleLongrunningOperation::Representation
  command.response_class = Google::Apis::DlpV2beta1::GoogleLongrunningOperation
  command.params['name'] = name unless name.nil?
  command.query['fields'] = fields unless fields.nil?
  command.query['quotaUser'] = quota_user unless quota_user.nil?
  execute_or_queue_command(command, &block)
end

#get_risk_analysis_operation(name, fields: nil, quota_user: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::DlpV2beta1::GoogleLongrunningOperation

Gets the latest state of a long-running operation. Clients can use this method to poll the operation result at intervals as recommended by the API service.

Parameters:

  • name (String)

    The name of the operation resource.

  • fields (String)

    Selector specifying which fields to include in a partial response.

  • quota_user (String)

    Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters.

  • options (Google::Apis::RequestOptions)

    Request-specific options

Yields:

  • (result, err)

    Result & error if block supplied

Yield Parameters:

Returns:

Raises:



478
479
480
481
482
483
484
485
486
# File 'generated/google/apis/dlp_v2beta1/service.rb', line 478

def get_risk_analysis_operation(name, fields: nil, quota_user: nil, options: nil, &block)
  command =  make_simple_command(:get, 'v2beta1/{+name}', options)
  command.response_representation = Google::Apis::DlpV2beta1::GoogleLongrunningOperation::Representation
  command.response_class = Google::Apis::DlpV2beta1::GoogleLongrunningOperation
  command.params['name'] = name unless name.nil?
  command.query['fields'] = fields unless fields.nil?
  command.query['quotaUser'] = quota_user unless quota_user.nil?
  execute_or_queue_command(command, &block)
end

#inspect_content(google_privacy_dlp_v2beta1_inspect_content_request_object = nil, fields: nil, quota_user: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::DlpV2beta1::GooglePrivacyDlpV2beta1InspectContentResponse

Finds potentially sensitive info in a list of strings. This method has limits on input size, processing time, and output size.

Parameters:

Yields:

  • (result, err)

    Result & error if block supplied

Yield Parameters:

Returns:

Raises:



103
104
105
106
107
108
109
110
111
112
# File 'generated/google/apis/dlp_v2beta1/service.rb', line 103

def inspect_content(google_privacy_dlp_v2beta1_inspect_content_request_object = nil, fields: nil, quota_user: nil, options: nil, &block)
  command =  make_simple_command(:post, 'v2beta1/content:inspect', options)
  command.request_representation = Google::Apis::DlpV2beta1::GooglePrivacyDlpV2beta1InspectContentRequest::Representation
  command.request_object = google_privacy_dlp_v2beta1_inspect_content_request_object
  command.response_representation = Google::Apis::DlpV2beta1::GooglePrivacyDlpV2beta1InspectContentResponse::Representation
  command.response_class = Google::Apis::DlpV2beta1::GooglePrivacyDlpV2beta1InspectContentResponse
  command.query['fields'] = fields unless fields.nil?
  command.query['quotaUser'] = quota_user unless quota_user.nil?
  execute_or_queue_command(command, &block)
end

#list_inspect_operations(name, filter: nil, page_size: nil, page_token: nil, fields: nil, quota_user: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::DlpV2beta1::GoogleLongrunningListOperationsResponse

Fetches the list of long running operations.

Parameters:

  • name (String)

    The name of the operation's parent resource.

  • filter (String)

    Filters by done. That is, done=true or done=false.

  • page_size (Fixnum)

    The list page size. The maximum allowed value is 256 and the default is 100.

  • page_token (String)

    The standard list page token.

  • fields (String)

    Selector specifying which fields to include in a partial response.

  • quota_user (String)

    Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters.

  • options (Google::Apis::RequestOptions)

    Request-specific options

Yields:

  • (result, err)

    Result & error if block supplied

Yield Parameters:

Returns:

Raises:



329
330
331
332
333
334
335
336
337
338
339
340
# File 'generated/google/apis/dlp_v2beta1/service.rb', line 329

def list_inspect_operations(name, filter: nil, page_size: nil, page_token: nil, fields: nil, quota_user: nil, options: nil, &block)
  command =  make_simple_command(:get, 'v2beta1/{+name}', options)
  command.response_representation = Google::Apis::DlpV2beta1::GoogleLongrunningListOperationsResponse::Representation
  command.response_class = Google::Apis::DlpV2beta1::GoogleLongrunningListOperationsResponse
  command.params['name'] = name unless name.nil?
  command.query['filter'] = filter unless filter.nil?
  command.query['pageSize'] = page_size unless page_size.nil?
  command.query['pageToken'] = page_token unless page_token.nil?
  command.query['fields'] = fields unless fields.nil?
  command.query['quotaUser'] = quota_user unless quota_user.nil?
  execute_or_queue_command(command, &block)
end

#list_inspect_result_findings(name, filter: nil, page_size: nil, page_token: nil, fields: nil, quota_user: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::DlpV2beta1::GooglePrivacyDlpV2beta1ListInspectFindingsResponse

Returns list of results for given inspect operation result set id.

Parameters:

  • name (String)

    Identifier of the results set returned as metadata of the longrunning operation created by a call to InspectDataSource. Should be in the format of inspect/results/id``.

  • filter (String)

    Restricts findings to items that match. Supports info_type and likelihood. Examples:

    • info_type=EMAIL_ADDRESS
    • info_type=PHONE_NUMBER,EMAIL_ADDRESS
    • likelihood=VERY_LIKELY
    • likelihood=VERY_LIKELY,LIKELY
    • info_type=EMAIL_ADDRESS,likelihood=VERY_LIKELY,LIKELY
  • page_size (Fixnum)

    Maximum number of results to return. If 0, the implementation selects a reasonable value.

  • page_token (String)

    The value returned by the last ListInspectFindingsResponse; indicates that this is a continuation of a prior ListInspectFindings call, and that the system should return the next page of data.

  • fields (String)

    Selector specifying which fields to include in a partial response.

  • quota_user (String)

    Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters.

  • options (Google::Apis::RequestOptions)

    Request-specific options

Yields:

  • (result, err)

    Result & error if block supplied

Yield Parameters:

Returns:

Raises:



379
380
381
382
383
384
385
386
387
388
389
390
# File 'generated/google/apis/dlp_v2beta1/service.rb', line 379

def list_inspect_result_findings(name, filter: nil, page_size: nil, page_token: nil, fields: nil, quota_user: nil, options: nil, &block)
  command =  make_simple_command(:get, 'v2beta1/{+name}/findings', options)
  command.response_representation = Google::Apis::DlpV2beta1::GooglePrivacyDlpV2beta1ListInspectFindingsResponse::Representation
  command.response_class = Google::Apis::DlpV2beta1::GooglePrivacyDlpV2beta1ListInspectFindingsResponse
  command.params['name'] = name unless name.nil?
  command.query['filter'] = filter unless filter.nil?
  command.query['pageSize'] = page_size unless page_size.nil?
  command.query['pageToken'] = page_token unless page_token.nil?
  command.query['fields'] = fields unless fields.nil?
  command.query['quotaUser'] = quota_user unless quota_user.nil?
  execute_or_queue_command(command, &block)
end

#list_risk_analysis_operations(name, filter: nil, page_size: nil, page_token: nil, fields: nil, quota_user: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::DlpV2beta1::GoogleLongrunningListOperationsResponse

Fetches the list of long running operations.

Parameters:

  • name (String)

    The name of the operation's parent resource.

  • filter (String)

    Filters by done. That is, done=true or done=false.

  • page_size (Fixnum)

    The list page size. The maximum allowed value is 256 and the default is 100.

  • page_token (String)

    The standard list page token.

  • fields (String)

    Selector specifying which fields to include in a partial response.

  • quota_user (String)

    Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters.

  • options (Google::Apis::RequestOptions)

    Request-specific options

Yields:

  • (result, err)

    Result & error if block supplied

Yield Parameters:

Returns:

Raises:



514
515
516
517
518
519
520
521
522
523
524
525
# File 'generated/google/apis/dlp_v2beta1/service.rb', line 514

def list_risk_analysis_operations(name, filter: nil, page_size: nil, page_token: nil, fields: nil, quota_user: nil, options: nil, &block)
  command =  make_simple_command(:get, 'v2beta1/{+name}', options)
  command.response_representation = Google::Apis::DlpV2beta1::GoogleLongrunningListOperationsResponse::Representation
  command.response_class = Google::Apis::DlpV2beta1::GoogleLongrunningListOperationsResponse
  command.params['name'] = name unless name.nil?
  command.query['filter'] = filter unless filter.nil?
  command.query['pageSize'] = page_size unless page_size.nil?
  command.query['pageToken'] = page_token unless page_token.nil?
  command.query['fields'] = fields unless fields.nil?
  command.query['quotaUser'] = quota_user unless quota_user.nil?
  execute_or_queue_command(command, &block)
end

#list_root_categories(language_code: nil, fields: nil, quota_user: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::DlpV2beta1::GooglePrivacyDlpV2beta1ListRootCategoriesResponse

Returns the list of root categories of sensitive information.

Parameters:

  • language_code (String)

    Optional language code for localized friendly category names. If omitted or if localized strings are not available, en-US strings will be returned.

  • fields (String)

    Selector specifying which fields to include in a partial response.

  • quota_user (String)

    Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters.

  • options (Google::Apis::RequestOptions)

    Request-specific options

Yields:

  • (result, err)

    Result & error if block supplied

Yield Parameters:

Returns:

Raises:



549
550
551
552
553
554
555
556
557
# File 'generated/google/apis/dlp_v2beta1/service.rb', line 549

def list_root_categories(language_code: nil, fields: nil, quota_user: nil, options: nil, &block)
  command =  make_simple_command(:get, 'v2beta1/rootCategories', options)
  command.response_representation = Google::Apis::DlpV2beta1::GooglePrivacyDlpV2beta1ListRootCategoriesResponse::Representation
  command.response_class = Google::Apis::DlpV2beta1::GooglePrivacyDlpV2beta1ListRootCategoriesResponse
  command.query['languageCode'] = language_code unless language_code.nil?
  command.query['fields'] = fields unless fields.nil?
  command.query['quotaUser'] = quota_user unless quota_user.nil?
  execute_or_queue_command(command, &block)
end

#list_root_category_info_types(category, language_code: nil, fields: nil, quota_user: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::DlpV2beta1::GooglePrivacyDlpV2beta1ListInfoTypesResponse

Returns sensitive information types for given category.

Parameters:

  • category (String)

    Category name as returned by ListRootCategories.

  • language_code (String)

    Optional BCP-47 language code for localized info type friendly names. If omitted, or if localized strings are not available, en-US strings will be returned.

  • fields (String)

    Selector specifying which fields to include in a partial response.

  • quota_user (String)

    Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters.

  • options (Google::Apis::RequestOptions)

    Request-specific options

Yields:

  • (result, err)

    Result & error if block supplied

Yield Parameters:

Returns:

Raises:



583
584
585
586
587
588
589
590
591
592
# File 'generated/google/apis/dlp_v2beta1/service.rb', line 583

def list_root_category_info_types(category, language_code: nil, fields: nil, quota_user: nil, options: nil, &block)
  command =  make_simple_command(:get, 'v2beta1/rootCategories/{+category}/infoTypes', options)
  command.response_representation = Google::Apis::DlpV2beta1::GooglePrivacyDlpV2beta1ListInfoTypesResponse::Representation
  command.response_class = Google::Apis::DlpV2beta1::GooglePrivacyDlpV2beta1ListInfoTypesResponse
  command.params['category'] = category unless category.nil?
  command.query['languageCode'] = language_code unless language_code.nil?
  command.query['fields'] = fields unless fields.nil?
  command.query['quotaUser'] = quota_user unless quota_user.nil?
  execute_or_queue_command(command, &block)
end

#redact_content(google_privacy_dlp_v2beta1_redact_content_request_object = nil, fields: nil, quota_user: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::DlpV2beta1::GooglePrivacyDlpV2beta1RedactContentResponse

Redacts potentially sensitive info from a list of strings. This method has limits on input size, processing time, and output size.

Parameters:

Yields:

  • (result, err)

    Result & error if block supplied

Yield Parameters:

Returns:

Raises:



134
135
136
137
138
139
140
141
142
143
# File 'generated/google/apis/dlp_v2beta1/service.rb', line 134

def redact_content(google_privacy_dlp_v2beta1_redact_content_request_object = nil, fields: nil, quota_user: nil, options: nil, &block)
  command =  make_simple_command(:post, 'v2beta1/content:redact', options)
  command.request_representation = Google::Apis::DlpV2beta1::GooglePrivacyDlpV2beta1RedactContentRequest::Representation
  command.request_object = google_privacy_dlp_v2beta1_redact_content_request_object
  command.response_representation = Google::Apis::DlpV2beta1::GooglePrivacyDlpV2beta1RedactContentResponse::Representation
  command.response_class = Google::Apis::DlpV2beta1::GooglePrivacyDlpV2beta1RedactContentResponse
  command.query['fields'] = fields unless fields.nil?
  command.query['quotaUser'] = quota_user unless quota_user.nil?
  execute_or_queue_command(command, &block)
end