diff --git a/clients/dlp/README.md b/clients/dlp/README.md index aa598af132..e0ad3b8fa1 100644 --- a/clients/dlp/README.md +++ b/clients/dlp/README.md @@ -1,8 +1,8 @@ # GoogleApi.DLP -Cloud Data Loss Prevention (DLP) API client library. +Sensitive Data Protection (DLP) client library. -Provides methods for detection, risk analysis, and de-identification of privacy-sensitive fragments in text, images, and Google Cloud Platform storage repositories. +Discover and protect your sensitive data. A fully managed service designed to help you discover, classify, and protect your valuable data assets with ease. ## Installation @@ -17,7 +17,7 @@ end ## For more information -Product documentation is available at [https://cloud.google.com/dlp/docs/](https://cloud.google.com/dlp/docs/). +Product documentation is available at [https://cloud.google.com/sensitive-data-protection/docs/](https://cloud.google.com/sensitive-data-protection/docs/). Library reference documentation is published on Hexdocs at [https://hexdocs.pm/google_api_dlp](https://hexdocs.pm/google_api_dlp). diff --git a/clients/dlp/lib/google_api/dlp/v2/api/info_types.ex b/clients/dlp/lib/google_api/dlp/v2/api/info_types.ex index 6ed6dc3b1d..c74d463218 100644 --- a/clients/dlp/lib/google_api/dlp/v2/api/info_types.ex +++ b/clients/dlp/lib/google_api/dlp/v2/api/info_types.ex @@ -26,7 +26,7 @@ defmodule GoogleApi.DLP.V2.Api.InfoTypes do @library_version Mix.Project.config() |> Keyword.get(:version, "") @doc """ - Returns a list of the sensitive information types that DLP API supports. See https://cloud.google.com/dlp/docs/infotypes-reference to learn more. + Returns a list of the sensitive information types that DLP API supports. See https://cloud.google.com/sensitive-data-protection/docs/infotypes-reference to learn more. ## Parameters diff --git a/clients/dlp/lib/google_api/dlp/v2/api/locations.ex b/clients/dlp/lib/google_api/dlp/v2/api/locations.ex index 854c5ee478..ac5345495d 100644 --- a/clients/dlp/lib/google_api/dlp/v2/api/locations.ex +++ b/clients/dlp/lib/google_api/dlp/v2/api/locations.ex @@ -26,7 +26,7 @@ defmodule GoogleApi.DLP.V2.Api.Locations do @library_version Mix.Project.config() |> Keyword.get(:version, "") @doc """ - Returns a list of the sensitive information types that DLP API supports. See https://cloud.google.com/dlp/docs/infotypes-reference to learn more. + Returns a list of the sensitive information types that DLP API supports. See https://cloud.google.com/sensitive-data-protection/docs/infotypes-reference to learn more. ## Parameters diff --git a/clients/dlp/lib/google_api/dlp/v2/api/organizations.ex b/clients/dlp/lib/google_api/dlp/v2/api/organizations.ex index 9451583638..4aeddaad49 100644 --- a/clients/dlp/lib/google_api/dlp/v2/api/organizations.ex +++ b/clients/dlp/lib/google_api/dlp/v2/api/organizations.ex @@ -26,12 +26,12 @@ defmodule GoogleApi.DLP.V2.Api.Organizations do @library_version Mix.Project.config() |> Keyword.get(:version, "") @doc """ - Creates a DeidentifyTemplate for reusing frequently used configuration for de-identifying content, images, and storage. See https://cloud.google.com/dlp/docs/creating-templates-deid to learn more. + Creates a DeidentifyTemplate for reusing frequently used configuration for de-identifying content, images, and storage. See https://cloud.google.com/sensitive-data-protection/docs/creating-templates-deid to learn more. ## Parameters * `connection` (*type:* `GoogleApi.DLP.V2.Connection.t`) - Connection to server - * `parent` (*type:* `String.t`) - Required. Parent resource name. The format of this value varies depending on the scope of the request (project or organization) and whether you have [specified a processing location](https://cloud.google.com/dlp/docs/specifying-location): + Projects scope, location specified: `projects/`PROJECT_ID`/locations/`LOCATION_ID + Projects scope, no location specified (defaults to global): `projects/`PROJECT_ID + Organizations scope, location specified: `organizations/`ORG_ID`/locations/`LOCATION_ID + Organizations scope, no location specified (defaults to global): `organizations/`ORG_ID The following example `parent` string specifies a parent project with the identifier `example-project`, and specifies the `europe-west3` location for processing data: parent=projects/example-project/locations/europe-west3 + * `parent` (*type:* `String.t`) - Required. Parent resource name. The format of this value varies depending on the scope of the request (project or organization) and whether you have [specified a processing location](https://cloud.google.com/sensitive-data-protection/docs/specifying-location): + Projects scope, location specified: `projects/`PROJECT_ID`/locations/`LOCATION_ID + Projects scope, no location specified (defaults to global): `projects/`PROJECT_ID + Organizations scope, location specified: `organizations/`ORG_ID`/locations/`LOCATION_ID + Organizations scope, no location specified (defaults to global): `organizations/`ORG_ID The following example `parent` string specifies a parent project with the identifier `example-project`, and specifies the `europe-west3` location for processing data: parent=projects/example-project/locations/europe-west3 * `optional_params` (*type:* `keyword()`) - Optional parameters * `:"$.xgafv"` (*type:* `String.t`) - V1 error format. * `:access_token` (*type:* `String.t`) - OAuth access token. @@ -100,7 +100,7 @@ defmodule GoogleApi.DLP.V2.Api.Organizations do end @doc """ - Deletes a DeidentifyTemplate. See https://cloud.google.com/dlp/docs/creating-templates-deid to learn more. + Deletes a DeidentifyTemplate. See https://cloud.google.com/sensitive-data-protection/docs/creating-templates-deid to learn more. ## Parameters @@ -170,7 +170,7 @@ defmodule GoogleApi.DLP.V2.Api.Organizations do end @doc """ - Gets a DeidentifyTemplate. See https://cloud.google.com/dlp/docs/creating-templates-deid to learn more. + Gets a DeidentifyTemplate. See https://cloud.google.com/sensitive-data-protection/docs/creating-templates-deid to learn more. ## Parameters @@ -242,12 +242,12 @@ defmodule GoogleApi.DLP.V2.Api.Organizations do end @doc """ - Lists DeidentifyTemplates. See https://cloud.google.com/dlp/docs/creating-templates-deid to learn more. + Lists DeidentifyTemplates. See https://cloud.google.com/sensitive-data-protection/docs/creating-templates-deid to learn more. ## Parameters * `connection` (*type:* `GoogleApi.DLP.V2.Connection.t`) - Connection to server - * `parent` (*type:* `String.t`) - Required. Parent resource name. The format of this value varies depending on the scope of the request (project or organization) and whether you have [specified a processing location](https://cloud.google.com/dlp/docs/specifying-location): + Projects scope, location specified: `projects/`PROJECT_ID`/locations/`LOCATION_ID + Projects scope, no location specified (defaults to global): `projects/`PROJECT_ID + Organizations scope, location specified: `organizations/`ORG_ID`/locations/`LOCATION_ID + Organizations scope, no location specified (defaults to global): `organizations/`ORG_ID The following example `parent` string specifies a parent project with the identifier `example-project`, and specifies the `europe-west3` location for processing data: parent=projects/example-project/locations/europe-west3 + * `parent` (*type:* `String.t`) - Required. Parent resource name. The format of this value varies depending on the scope of the request (project or organization) and whether you have [specified a processing location](https://cloud.google.com/sensitive-data-protection/docs/specifying-location): + Projects scope, location specified: `projects/`PROJECT_ID`/locations/`LOCATION_ID + Projects scope, no location specified (defaults to global): `projects/`PROJECT_ID + Organizations scope, location specified: `organizations/`ORG_ID`/locations/`LOCATION_ID + Organizations scope, no location specified (defaults to global): `organizations/`ORG_ID The following example `parent` string specifies a parent project with the identifier `example-project`, and specifies the `europe-west3` location for processing data: parent=projects/example-project/locations/europe-west3 * `optional_params` (*type:* `keyword()`) - Optional parameters * `:"$.xgafv"` (*type:* `String.t`) - V1 error format. * `:access_token` (*type:* `String.t`) - OAuth access token. @@ -261,9 +261,9 @@ defmodule GoogleApi.DLP.V2.Api.Organizations do * `:uploadType` (*type:* `String.t`) - Legacy upload protocol for media (e.g. "media", "multipart"). * `:upload_protocol` (*type:* `String.t`) - Upload protocol for media (e.g. "raw", "multipart"). * `:locationId` (*type:* `String.t`) - Deprecated. This field has no effect. - * `:orderBy` (*type:* `String.t`) - Comma separated list of fields to order by, followed by `asc` or `desc` postfix. This list is case-insensitive, default sorting order is ascending, redundant space characters are insignificant. Example: `name asc,update_time, create_time desc` Supported fields are: - `create_time`: corresponds to the time the template was created. - `update_time`: corresponds to the time the template was last updated. - `name`: corresponds to the template's name. - `display_name`: corresponds to the template's display name. - * `:pageSize` (*type:* `integer()`) - Size of the page, can be limited by the server. If zero server returns a page of max size 100. - * `:pageToken` (*type:* `String.t`) - Page token to continue retrieval. Comes from previous call to `ListDeidentifyTemplates`. + * `:orderBy` (*type:* `String.t`) - Comma separated list of fields to order by, followed by `asc` or `desc` postfix. This list is case insensitive. The default sorting order is ascending. Redundant space characters are insignificant. Example: `name asc,update_time, create_time desc` Supported fields are: - `create_time`: corresponds to the time the template was created. - `update_time`: corresponds to the time the template was last updated. - `name`: corresponds to the template's name. - `display_name`: corresponds to the template's display name. + * `:pageSize` (*type:* `integer()`) - Size of the page. This value can be limited by the server. If zero server returns a page of max size 100. + * `:pageToken` (*type:* `String.t`) - Page token to continue retrieval. Comes from the previous call to `ListDeidentifyTemplates`. * `opts` (*type:* `keyword()`) - Call options ## Returns @@ -323,7 +323,7 @@ defmodule GoogleApi.DLP.V2.Api.Organizations do end @doc """ - Updates the DeidentifyTemplate. See https://cloud.google.com/dlp/docs/creating-templates-deid to learn more. + Updates the DeidentifyTemplate. See https://cloud.google.com/sensitive-data-protection/docs/creating-templates-deid to learn more. ## Parameters @@ -397,12 +397,12 @@ defmodule GoogleApi.DLP.V2.Api.Organizations do end @doc """ - Creates an InspectTemplate for reusing frequently used configuration for inspecting content, images, and storage. See https://cloud.google.com/dlp/docs/creating-templates to learn more. + Creates an InspectTemplate for reusing frequently used configuration for inspecting content, images, and storage. See https://cloud.google.com/sensitive-data-protection/docs/creating-templates to learn more. ## Parameters * `connection` (*type:* `GoogleApi.DLP.V2.Connection.t`) - Connection to server - * `parent` (*type:* `String.t`) - Required. Parent resource name. The format of this value varies depending on the scope of the request (project or organization) and whether you have [specified a processing location](https://cloud.google.com/dlp/docs/specifying-location): + Projects scope, location specified: `projects/`PROJECT_ID`/locations/`LOCATION_ID + Projects scope, no location specified (defaults to global): `projects/`PROJECT_ID + Organizations scope, location specified: `organizations/`ORG_ID`/locations/`LOCATION_ID + Organizations scope, no location specified (defaults to global): `organizations/`ORG_ID The following example `parent` string specifies a parent project with the identifier `example-project`, and specifies the `europe-west3` location for processing data: parent=projects/example-project/locations/europe-west3 + * `parent` (*type:* `String.t`) - Required. Parent resource name. The format of this value varies depending on the scope of the request (project or organization) and whether you have [specified a processing location](https://cloud.google.com/sensitive-data-protection/docs/specifying-location): + Projects scope, location specified: `projects/`PROJECT_ID`/locations/`LOCATION_ID + Projects scope, no location specified (defaults to global): `projects/`PROJECT_ID + Organizations scope, location specified: `organizations/`ORG_ID`/locations/`LOCATION_ID + Organizations scope, no location specified (defaults to global): `organizations/`ORG_ID The following example `parent` string specifies a parent project with the identifier `example-project`, and specifies the `europe-west3` location for processing data: parent=projects/example-project/locations/europe-west3 * `optional_params` (*type:* `keyword()`) - Optional parameters * `:"$.xgafv"` (*type:* `String.t`) - V1 error format. * `:access_token` (*type:* `String.t`) - OAuth access token. @@ -471,7 +471,7 @@ defmodule GoogleApi.DLP.V2.Api.Organizations do end @doc """ - Deletes an InspectTemplate. See https://cloud.google.com/dlp/docs/creating-templates to learn more. + Deletes an InspectTemplate. See https://cloud.google.com/sensitive-data-protection/docs/creating-templates to learn more. ## Parameters @@ -541,7 +541,7 @@ defmodule GoogleApi.DLP.V2.Api.Organizations do end @doc """ - Gets an InspectTemplate. See https://cloud.google.com/dlp/docs/creating-templates to learn more. + Gets an InspectTemplate. See https://cloud.google.com/sensitive-data-protection/docs/creating-templates to learn more. ## Parameters @@ -608,12 +608,12 @@ defmodule GoogleApi.DLP.V2.Api.Organizations do end @doc """ - Lists InspectTemplates. See https://cloud.google.com/dlp/docs/creating-templates to learn more. + Lists InspectTemplates. See https://cloud.google.com/sensitive-data-protection/docs/creating-templates to learn more. ## Parameters * `connection` (*type:* `GoogleApi.DLP.V2.Connection.t`) - Connection to server - * `parent` (*type:* `String.t`) - Required. Parent resource name. The format of this value varies depending on the scope of the request (project or organization) and whether you have [specified a processing location](https://cloud.google.com/dlp/docs/specifying-location): + Projects scope, location specified: `projects/`PROJECT_ID`/locations/`LOCATION_ID + Projects scope, no location specified (defaults to global): `projects/`PROJECT_ID + Organizations scope, location specified: `organizations/`ORG_ID`/locations/`LOCATION_ID + Organizations scope, no location specified (defaults to global): `organizations/`ORG_ID The following example `parent` string specifies a parent project with the identifier `example-project`, and specifies the `europe-west3` location for processing data: parent=projects/example-project/locations/europe-west3 + * `parent` (*type:* `String.t`) - Required. Parent resource name. The format of this value varies depending on the scope of the request (project or organization) and whether you have [specified a processing location](https://cloud.google.com/sensitive-data-protection/docs/specifying-location): + Projects scope, location specified: `projects/`PROJECT_ID`/locations/`LOCATION_ID + Projects scope, no location specified (defaults to global): `projects/`PROJECT_ID + Organizations scope, location specified: `organizations/`ORG_ID`/locations/`LOCATION_ID + Organizations scope, no location specified (defaults to global): `organizations/`ORG_ID The following example `parent` string specifies a parent project with the identifier `example-project`, and specifies the `europe-west3` location for processing data: parent=projects/example-project/locations/europe-west3 * `optional_params` (*type:* `keyword()`) - Optional parameters * `:"$.xgafv"` (*type:* `String.t`) - V1 error format. * `:access_token` (*type:* `String.t`) - OAuth access token. @@ -627,9 +627,9 @@ defmodule GoogleApi.DLP.V2.Api.Organizations do * `:uploadType` (*type:* `String.t`) - Legacy upload protocol for media (e.g. "media", "multipart"). * `:upload_protocol` (*type:* `String.t`) - Upload protocol for media (e.g. "raw", "multipart"). * `:locationId` (*type:* `String.t`) - Deprecated. This field has no effect. - * `:orderBy` (*type:* `String.t`) - Comma separated list of fields to order by, followed by `asc` or `desc` postfix. This list is case-insensitive, default sorting order is ascending, redundant space characters are insignificant. Example: `name asc,update_time, create_time desc` Supported fields are: - `create_time`: corresponds to the time the template was created. - `update_time`: corresponds to the time the template was last updated. - `name`: corresponds to the template's name. - `display_name`: corresponds to the template's display name. - * `:pageSize` (*type:* `integer()`) - Size of the page, can be limited by the server. If zero server returns a page of max size 100. - * `:pageToken` (*type:* `String.t`) - Page token to continue retrieval. Comes from previous call to `ListInspectTemplates`. + * `:orderBy` (*type:* `String.t`) - Comma separated list of fields to order by, followed by `asc` or `desc` postfix. This list is case insensitive. The default sorting order is ascending. Redundant space characters are insignificant. Example: `name asc,update_time, create_time desc` Supported fields are: - `create_time`: corresponds to the time the template was created. - `update_time`: corresponds to the time the template was last updated. - `name`: corresponds to the template's name. - `display_name`: corresponds to the template's display name. + * `:pageSize` (*type:* `integer()`) - Size of the page. This value can be limited by the server. If zero server returns a page of max size 100. + * `:pageToken` (*type:* `String.t`) - Page token to continue retrieval. Comes from the previous call to `ListInspectTemplates`. * `opts` (*type:* `keyword()`) - Call options ## Returns @@ -688,7 +688,7 @@ defmodule GoogleApi.DLP.V2.Api.Organizations do end @doc """ - Updates the InspectTemplate. See https://cloud.google.com/dlp/docs/creating-templates to learn more. + Updates the InspectTemplate. See https://cloud.google.com/sensitive-data-protection/docs/creating-templates to learn more. ## Parameters @@ -762,12 +762,164 @@ defmodule GoogleApi.DLP.V2.Api.Organizations do end @doc """ - Creates a DeidentifyTemplate for reusing frequently used configuration for de-identifying content, images, and storage. See https://cloud.google.com/dlp/docs/creating-templates-deid to learn more. + Gets a column data profile. ## Parameters * `connection` (*type:* `GoogleApi.DLP.V2.Connection.t`) - Connection to server - * `parent` (*type:* `String.t`) - Required. Parent resource name. The format of this value varies depending on the scope of the request (project or organization) and whether you have [specified a processing location](https://cloud.google.com/dlp/docs/specifying-location): + Projects scope, location specified: `projects/`PROJECT_ID`/locations/`LOCATION_ID + Projects scope, no location specified (defaults to global): `projects/`PROJECT_ID + Organizations scope, location specified: `organizations/`ORG_ID`/locations/`LOCATION_ID + Organizations scope, no location specified (defaults to global): `organizations/`ORG_ID The following example `parent` string specifies a parent project with the identifier `example-project`, and specifies the `europe-west3` location for processing data: parent=projects/example-project/locations/europe-west3 + * `name` (*type:* `String.t`) - Required. Resource name, for example `organizations/12345/locations/us/columnDataProfiles/53234423`. + * `optional_params` (*type:* `keyword()`) - Optional parameters + * `:"$.xgafv"` (*type:* `String.t`) - V1 error format. + * `:access_token` (*type:* `String.t`) - OAuth access token. + * `:alt` (*type:* `String.t`) - Data format for response. + * `:callback` (*type:* `String.t`) - JSONP + * `:fields` (*type:* `String.t`) - Selector specifying which fields to include in a partial response. + * `:key` (*type:* `String.t`) - 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. + * `:oauth_token` (*type:* `String.t`) - OAuth 2.0 token for the current user. + * `:prettyPrint` (*type:* `boolean()`) - Returns response with indentations and line breaks. + * `:quotaUser` (*type:* `String.t`) - 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. + * `:uploadType` (*type:* `String.t`) - Legacy upload protocol for media (e.g. "media", "multipart"). + * `:upload_protocol` (*type:* `String.t`) - Upload protocol for media (e.g. "raw", "multipart"). + * `opts` (*type:* `keyword()`) - Call options + + ## Returns + + * `{:ok, %GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2ColumnDataProfile{}}` on success + * `{:error, info}` on failure + """ + @spec dlp_organizations_locations_column_data_profiles_get( + Tesla.Env.client(), + String.t(), + keyword(), + keyword() + ) :: + {:ok, GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2ColumnDataProfile.t()} + | {:ok, Tesla.Env.t()} + | {:ok, list()} + | {:error, any()} + def dlp_organizations_locations_column_data_profiles_get( + connection, + name, + optional_params \\ [], + opts \\ [] + ) do + optional_params_config = %{ + :"$.xgafv" => :query, + :access_token => :query, + :alt => :query, + :callback => :query, + :fields => :query, + :key => :query, + :oauth_token => :query, + :prettyPrint => :query, + :quotaUser => :query, + :uploadType => :query, + :upload_protocol => :query + } + + request = + Request.new() + |> Request.method(:get) + |> Request.url("/v2/{+name}", %{ + "name" => URI.encode(name, &URI.char_unreserved?/1) + }) + |> Request.add_optional_params(optional_params_config, optional_params) + |> Request.library_version(@library_version) + + connection + |> Connection.execute(request) + |> Response.decode( + opts ++ [struct: %GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2ColumnDataProfile{}] + ) + end + + @doc """ + Lists data profiles for an organization. + + ## Parameters + + * `connection` (*type:* `GoogleApi.DLP.V2.Connection.t`) - Connection to server + * `parent` (*type:* `String.t`) - Required. Resource name of the organization or project, for example `organizations/433245324/locations/europe` or projects/project-id/locations/asia. + * `optional_params` (*type:* `keyword()`) - Optional parameters + * `:"$.xgafv"` (*type:* `String.t`) - V1 error format. + * `:access_token` (*type:* `String.t`) - OAuth access token. + * `:alt` (*type:* `String.t`) - Data format for response. + * `:callback` (*type:* `String.t`) - JSONP + * `:fields` (*type:* `String.t`) - Selector specifying which fields to include in a partial response. + * `:key` (*type:* `String.t`) - 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. + * `:oauth_token` (*type:* `String.t`) - OAuth 2.0 token for the current user. + * `:prettyPrint` (*type:* `boolean()`) - Returns response with indentations and line breaks. + * `:quotaUser` (*type:* `String.t`) - 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. + * `:uploadType` (*type:* `String.t`) - Legacy upload protocol for media (e.g. "media", "multipart"). + * `:upload_protocol` (*type:* `String.t`) - Upload protocol for media (e.g. "raw", "multipart"). + * `:filter` (*type:* `String.t`) - Allows filtering. Supported syntax: * Filter expressions are made up of one or more restrictions. * Restrictions can be combined by `AND` or `OR` logical operators. A sequence of restrictions implicitly uses `AND`. * A restriction has the form of `{field} {operator} {value}`. * Supported fields/values: - `table_data_profile_name` - The name of the related table data profile. - `project_id` - The Google Cloud project ID. (REQUIRED) - `dataset_id` - The BigQuery dataset ID. (REQUIRED) - `table_id` - The BigQuery table ID. (REQUIRED) - `field_id` - The ID of the BigQuery field. - `info_type` - The infotype detected in the resource. - `sensitivity_level` - HIGH|MEDIUM|LOW - `data_risk_level`: How much risk is associated with this data. - `status_code` - an RPC status code as defined in https://github.com/googleapis/googleapis/blob/master/google/rpc/code.proto * The operator must be `=` for project_id, dataset_id, and table_id. Other filters also support `!=`. Examples: * project_id = 12345 AND status_code = 1 * project_id = 12345 AND sensitivity_level = HIGH * project_id = 12345 AND info_type = STREET_ADDRESS The length of this field should be no more than 500 characters. + * `:orderBy` (*type:* `String.t`) - Comma separated list of fields to order by, followed by `asc` or `desc` postfix. This list is case insensitive. The default sorting order is ascending. Redundant space characters are insignificant. Only one order field at a time is allowed. Examples: * `project_id asc` * `table_id` * `sensitivity_level desc` Supported fields are: - `project_id`: The Google Cloud project ID. - `dataset_id`: The ID of a BigQuery dataset. - `table_id`: The ID of a BigQuery table. - `sensitivity_level`: How sensitive the data in a column is, at most. - `data_risk_level`: How much risk is associated with this data. - `profile_last_generated`: When the profile was last updated in epoch seconds. + * `:pageSize` (*type:* `integer()`) - Size of the page. This value can be limited by the server. If zero, server returns a page of max size 100. + * `:pageToken` (*type:* `String.t`) - Page token to continue retrieval. + * `opts` (*type:* `keyword()`) - Call options + + ## Returns + + * `{:ok, %GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2ListColumnDataProfilesResponse{}}` on success + * `{:error, info}` on failure + """ + @spec dlp_organizations_locations_column_data_profiles_list( + Tesla.Env.client(), + String.t(), + keyword(), + keyword() + ) :: + {:ok, GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2ListColumnDataProfilesResponse.t()} + | {:ok, Tesla.Env.t()} + | {:ok, list()} + | {:error, any()} + def dlp_organizations_locations_column_data_profiles_list( + connection, + parent, + optional_params \\ [], + opts \\ [] + ) do + optional_params_config = %{ + :"$.xgafv" => :query, + :access_token => :query, + :alt => :query, + :callback => :query, + :fields => :query, + :key => :query, + :oauth_token => :query, + :prettyPrint => :query, + :quotaUser => :query, + :uploadType => :query, + :upload_protocol => :query, + :filter => :query, + :orderBy => :query, + :pageSize => :query, + :pageToken => :query + } + + request = + Request.new() + |> Request.method(:get) + |> Request.url("/v2/{+parent}/columnDataProfiles", %{ + "parent" => URI.encode(parent, &URI.char_unreserved?/1) + }) + |> Request.add_optional_params(optional_params_config, optional_params) + |> Request.library_version(@library_version) + + connection + |> Connection.execute(request) + |> Response.decode( + opts ++ [struct: %GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2ListColumnDataProfilesResponse{}] + ) + end + + @doc """ + Creates a DeidentifyTemplate for reusing frequently used configuration for de-identifying content, images, and storage. See https://cloud.google.com/sensitive-data-protection/docs/creating-templates-deid to learn more. + + ## Parameters + + * `connection` (*type:* `GoogleApi.DLP.V2.Connection.t`) - Connection to server + * `parent` (*type:* `String.t`) - Required. Parent resource name. The format of this value varies depending on the scope of the request (project or organization) and whether you have [specified a processing location](https://cloud.google.com/sensitive-data-protection/docs/specifying-location): + Projects scope, location specified: `projects/`PROJECT_ID`/locations/`LOCATION_ID + Projects scope, no location specified (defaults to global): `projects/`PROJECT_ID + Organizations scope, location specified: `organizations/`ORG_ID`/locations/`LOCATION_ID + Organizations scope, no location specified (defaults to global): `organizations/`ORG_ID The following example `parent` string specifies a parent project with the identifier `example-project`, and specifies the `europe-west3` location for processing data: parent=projects/example-project/locations/europe-west3 * `optional_params` (*type:* `keyword()`) - Optional parameters * `:"$.xgafv"` (*type:* `String.t`) - V1 error format. * `:access_token` (*type:* `String.t`) - OAuth access token. @@ -836,7 +988,7 @@ defmodule GoogleApi.DLP.V2.Api.Organizations do end @doc """ - Deletes a DeidentifyTemplate. See https://cloud.google.com/dlp/docs/creating-templates-deid to learn more. + Deletes a DeidentifyTemplate. See https://cloud.google.com/sensitive-data-protection/docs/creating-templates-deid to learn more. ## Parameters @@ -906,7 +1058,7 @@ defmodule GoogleApi.DLP.V2.Api.Organizations do end @doc """ - Gets a DeidentifyTemplate. See https://cloud.google.com/dlp/docs/creating-templates-deid to learn more. + Gets a DeidentifyTemplate. See https://cloud.google.com/sensitive-data-protection/docs/creating-templates-deid to learn more. ## Parameters @@ -978,12 +1130,12 @@ defmodule GoogleApi.DLP.V2.Api.Organizations do end @doc """ - Lists DeidentifyTemplates. See https://cloud.google.com/dlp/docs/creating-templates-deid to learn more. + Lists DeidentifyTemplates. See https://cloud.google.com/sensitive-data-protection/docs/creating-templates-deid to learn more. ## Parameters * `connection` (*type:* `GoogleApi.DLP.V2.Connection.t`) - Connection to server - * `parent` (*type:* `String.t`) - Required. Parent resource name. The format of this value varies depending on the scope of the request (project or organization) and whether you have [specified a processing location](https://cloud.google.com/dlp/docs/specifying-location): + Projects scope, location specified: `projects/`PROJECT_ID`/locations/`LOCATION_ID + Projects scope, no location specified (defaults to global): `projects/`PROJECT_ID + Organizations scope, location specified: `organizations/`ORG_ID`/locations/`LOCATION_ID + Organizations scope, no location specified (defaults to global): `organizations/`ORG_ID The following example `parent` string specifies a parent project with the identifier `example-project`, and specifies the `europe-west3` location for processing data: parent=projects/example-project/locations/europe-west3 + * `parent` (*type:* `String.t`) - Required. Parent resource name. The format of this value varies depending on the scope of the request (project or organization) and whether you have [specified a processing location](https://cloud.google.com/sensitive-data-protection/docs/specifying-location): + Projects scope, location specified: `projects/`PROJECT_ID`/locations/`LOCATION_ID + Projects scope, no location specified (defaults to global): `projects/`PROJECT_ID + Organizations scope, location specified: `organizations/`ORG_ID`/locations/`LOCATION_ID + Organizations scope, no location specified (defaults to global): `organizations/`ORG_ID The following example `parent` string specifies a parent project with the identifier `example-project`, and specifies the `europe-west3` location for processing data: parent=projects/example-project/locations/europe-west3 * `optional_params` (*type:* `keyword()`) - Optional parameters * `:"$.xgafv"` (*type:* `String.t`) - V1 error format. * `:access_token` (*type:* `String.t`) - OAuth access token. @@ -997,9 +1149,9 @@ defmodule GoogleApi.DLP.V2.Api.Organizations do * `:uploadType` (*type:* `String.t`) - Legacy upload protocol for media (e.g. "media", "multipart"). * `:upload_protocol` (*type:* `String.t`) - Upload protocol for media (e.g. "raw", "multipart"). * `:locationId` (*type:* `String.t`) - Deprecated. This field has no effect. - * `:orderBy` (*type:* `String.t`) - Comma separated list of fields to order by, followed by `asc` or `desc` postfix. This list is case-insensitive, default sorting order is ascending, redundant space characters are insignificant. Example: `name asc,update_time, create_time desc` Supported fields are: - `create_time`: corresponds to the time the template was created. - `update_time`: corresponds to the time the template was last updated. - `name`: corresponds to the template's name. - `display_name`: corresponds to the template's display name. - * `:pageSize` (*type:* `integer()`) - Size of the page, can be limited by the server. If zero server returns a page of max size 100. - * `:pageToken` (*type:* `String.t`) - Page token to continue retrieval. Comes from previous call to `ListDeidentifyTemplates`. + * `:orderBy` (*type:* `String.t`) - Comma separated list of fields to order by, followed by `asc` or `desc` postfix. This list is case insensitive. The default sorting order is ascending. Redundant space characters are insignificant. Example: `name asc,update_time, create_time desc` Supported fields are: - `create_time`: corresponds to the time the template was created. - `update_time`: corresponds to the time the template was last updated. - `name`: corresponds to the template's name. - `display_name`: corresponds to the template's display name. + * `:pageSize` (*type:* `integer()`) - Size of the page. This value can be limited by the server. If zero server returns a page of max size 100. + * `:pageToken` (*type:* `String.t`) - Page token to continue retrieval. Comes from the previous call to `ListDeidentifyTemplates`. * `opts` (*type:* `keyword()`) - Call options ## Returns @@ -1059,7 +1211,7 @@ defmodule GoogleApi.DLP.V2.Api.Organizations do end @doc """ - Updates the DeidentifyTemplate. See https://cloud.google.com/dlp/docs/creating-templates-deid to learn more. + Updates the DeidentifyTemplate. See https://cloud.google.com/sensitive-data-protection/docs/creating-templates-deid to learn more. ## Parameters @@ -1133,12 +1285,12 @@ defmodule GoogleApi.DLP.V2.Api.Organizations do end @doc """ - Lists DlpJobs that match the specified filter in the request. See https://cloud.google.com/dlp/docs/inspecting-storage and https://cloud.google.com/dlp/docs/compute-risk-analysis to learn more. + Creates a config for discovery to scan and profile storage. ## Parameters * `connection` (*type:* `GoogleApi.DLP.V2.Connection.t`) - Connection to server - * `parent` (*type:* `String.t`) - Required. Parent resource name. The format of this value varies depending on whether you have [specified a processing location](https://cloud.google.com/dlp/docs/specifying-location): + Projects scope, location specified: `projects/`PROJECT_ID`/locations/`LOCATION_ID + Projects scope, no location specified (defaults to global): `projects/`PROJECT_ID The following example `parent` string specifies a parent project with the identifier `example-project`, and specifies the `europe-west3` location for processing data: parent=projects/example-project/locations/europe-west3 + * `parent` (*type:* `String.t`) - Required. Parent resource name. The format of this value is as follows: `projects/`PROJECT_ID`/locations/`LOCATION_ID The following example `parent` string specifies a parent project with the identifier `example-project`, and specifies the `europe-west3` location for processing data: parent=projects/example-project/locations/europe-west3 * `optional_params` (*type:* `keyword()`) - Optional parameters * `:"$.xgafv"` (*type:* `String.t`) - V1 error format. * `:access_token` (*type:* `String.t`) - OAuth access token. @@ -1151,30 +1303,25 @@ defmodule GoogleApi.DLP.V2.Api.Organizations do * `:quotaUser` (*type:* `String.t`) - 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. * `:uploadType` (*type:* `String.t`) - Legacy upload protocol for media (e.g. "media", "multipart"). * `:upload_protocol` (*type:* `String.t`) - Upload protocol for media (e.g. "raw", "multipart"). - * `:filter` (*type:* `String.t`) - Allows filtering. Supported syntax: * Filter expressions are made up of one or more restrictions. * Restrictions can be combined by `AND` or `OR` logical operators. A sequence of restrictions implicitly uses `AND`. * A restriction has the form of `{field} {operator} {value}`. * Supported fields/values for inspect jobs: - `state` - PENDING|RUNNING|CANCELED|FINISHED|FAILED - `inspected_storage` - DATASTORE|CLOUD_STORAGE|BIGQUERY - `trigger_name` - The name of the trigger that created the job. - 'end_time` - Corresponds to the time the job finished. - 'start_time` - Corresponds to the time the job finished. * Supported fields for risk analysis jobs: - `state` - RUNNING|CANCELED|FINISHED|FAILED - 'end_time` - Corresponds to the time the job finished. - 'start_time` - Corresponds to the time the job finished. * The operator must be `=` or `!=`. Examples: * inspected_storage = cloud_storage AND state = done * inspected_storage = cloud_storage OR inspected_storage = bigquery * inspected_storage = cloud_storage AND (state = done OR state = canceled) * end_time > \\"2017-12-12T00:00:00+00:00\\" The length of this field should be no more than 500 characters. - * `:locationId` (*type:* `String.t`) - Deprecated. This field has no effect. - * `:orderBy` (*type:* `String.t`) - Comma separated list of fields to order by, followed by `asc` or `desc` postfix. This list is case-insensitive, default sorting order is ascending, redundant space characters are insignificant. Example: `name asc, end_time asc, create_time desc` Supported fields are: - `create_time`: corresponds to the time the job was created. - `end_time`: corresponds to the time the job ended. - `name`: corresponds to the job's name. - `state`: corresponds to `state` - * `:pageSize` (*type:* `integer()`) - The standard list page size. - * `:pageToken` (*type:* `String.t`) - The standard list page token. - * `:type` (*type:* `String.t`) - The type of job. Defaults to `DlpJobType.INSPECT` + * `:body` (*type:* `GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2CreateDiscoveryConfigRequest.t`) - * `opts` (*type:* `keyword()`) - Call options ## Returns - * `{:ok, %GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2ListDlpJobsResponse{}}` on success + * `{:ok, %GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2DiscoveryConfig{}}` on success * `{:error, info}` on failure """ - @spec dlp_organizations_locations_dlp_jobs_list( + @spec dlp_organizations_locations_discovery_configs_create( Tesla.Env.client(), String.t(), keyword(), keyword() ) :: - {:ok, GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2ListDlpJobsResponse.t()} + {:ok, GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2DiscoveryConfig.t()} | {:ok, Tesla.Env.t()} | {:ok, list()} | {:error, any()} - def dlp_organizations_locations_dlp_jobs_list( + def dlp_organizations_locations_discovery_configs_create( connection, parent, optional_params \\ [], @@ -1192,18 +1339,13 @@ defmodule GoogleApi.DLP.V2.Api.Organizations do :quotaUser => :query, :uploadType => :query, :upload_protocol => :query, - :filter => :query, - :locationId => :query, - :orderBy => :query, - :pageSize => :query, - :pageToken => :query, - :type => :query + :body => :body } request = Request.new() - |> Request.method(:get) - |> Request.url("/v2/{+parent}/dlpJobs", %{ + |> Request.method(:post) + |> Request.url("/v2/{+parent}/discoveryConfigs", %{ "parent" => URI.encode(parent, &URI.char_unreserved?/1) }) |> Request.add_optional_params(optional_params_config, optional_params) @@ -1212,17 +1354,17 @@ defmodule GoogleApi.DLP.V2.Api.Organizations do connection |> Connection.execute(request) |> Response.decode( - opts ++ [struct: %GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2ListDlpJobsResponse{}] + opts ++ [struct: %GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2DiscoveryConfig{}] ) end @doc """ - Creates an InspectTemplate for reusing frequently used configuration for inspecting content, images, and storage. See https://cloud.google.com/dlp/docs/creating-templates to learn more. + Deletes a discovery configuration. ## Parameters * `connection` (*type:* `GoogleApi.DLP.V2.Connection.t`) - Connection to server - * `parent` (*type:* `String.t`) - Required. Parent resource name. The format of this value varies depending on the scope of the request (project or organization) and whether you have [specified a processing location](https://cloud.google.com/dlp/docs/specifying-location): + Projects scope, location specified: `projects/`PROJECT_ID`/locations/`LOCATION_ID + Projects scope, no location specified (defaults to global): `projects/`PROJECT_ID + Organizations scope, location specified: `organizations/`ORG_ID`/locations/`LOCATION_ID + Organizations scope, no location specified (defaults to global): `organizations/`ORG_ID The following example `parent` string specifies a parent project with the identifier `example-project`, and specifies the `europe-west3` location for processing data: parent=projects/example-project/locations/europe-west3 + * `name` (*type:* `String.t`) - Required. Resource name of the project and the config, for example `projects/dlp-test-project/discoveryConfigs/53234423`. * `optional_params` (*type:* `keyword()`) - Optional parameters * `:"$.xgafv"` (*type:* `String.t`) - V1 error format. * `:access_token` (*type:* `String.t`) - OAuth access token. @@ -1235,27 +1377,26 @@ defmodule GoogleApi.DLP.V2.Api.Organizations do * `:quotaUser` (*type:* `String.t`) - 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. * `:uploadType` (*type:* `String.t`) - Legacy upload protocol for media (e.g. "media", "multipart"). * `:upload_protocol` (*type:* `String.t`) - Upload protocol for media (e.g. "raw", "multipart"). - * `:body` (*type:* `GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2CreateInspectTemplateRequest.t`) - * `opts` (*type:* `keyword()`) - Call options ## Returns - * `{:ok, %GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2InspectTemplate{}}` on success + * `{:ok, %GoogleApi.DLP.V2.Model.GoogleProtobufEmpty{}}` on success * `{:error, info}` on failure """ - @spec dlp_organizations_locations_inspect_templates_create( + @spec dlp_organizations_locations_discovery_configs_delete( Tesla.Env.client(), String.t(), keyword(), keyword() ) :: - {:ok, GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2InspectTemplate.t()} + {:ok, GoogleApi.DLP.V2.Model.GoogleProtobufEmpty.t()} | {:ok, Tesla.Env.t()} | {:ok, list()} | {:error, any()} - def dlp_organizations_locations_inspect_templates_create( + def dlp_organizations_locations_discovery_configs_delete( connection, - parent, + name, optional_params \\ [], opts \\ [] ) do @@ -1270,33 +1411,30 @@ defmodule GoogleApi.DLP.V2.Api.Organizations do :prettyPrint => :query, :quotaUser => :query, :uploadType => :query, - :upload_protocol => :query, - :body => :body + :upload_protocol => :query } request = Request.new() - |> Request.method(:post) - |> Request.url("/v2/{+parent}/inspectTemplates", %{ - "parent" => URI.encode(parent, &URI.char_unreserved?/1) + |> Request.method(:delete) + |> Request.url("/v2/{+name}", %{ + "name" => URI.encode(name, &URI.char_unreserved?/1) }) |> Request.add_optional_params(optional_params_config, optional_params) |> Request.library_version(@library_version) connection |> Connection.execute(request) - |> Response.decode( - opts ++ [struct: %GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2InspectTemplate{}] - ) + |> Response.decode(opts ++ [struct: %GoogleApi.DLP.V2.Model.GoogleProtobufEmpty{}]) end @doc """ - Deletes an InspectTemplate. See https://cloud.google.com/dlp/docs/creating-templates to learn more. + Gets a discovery configuration. ## Parameters * `connection` (*type:* `GoogleApi.DLP.V2.Connection.t`) - Connection to server - * `name` (*type:* `String.t`) - Required. Resource name of the organization and inspectTemplate to be deleted, for example `organizations/433245324/inspectTemplates/432452342` or projects/project-id/inspectTemplates/432452342. + * `name` (*type:* `String.t`) - Required. Resource name of the project and the configuration, for example `projects/dlp-test-project/discoveryConfigs/53234423`. * `optional_params` (*type:* `keyword()`) - Optional parameters * `:"$.xgafv"` (*type:* `String.t`) - V1 error format. * `:access_token` (*type:* `String.t`) - OAuth access token. @@ -1313,20 +1451,20 @@ defmodule GoogleApi.DLP.V2.Api.Organizations do ## Returns - * `{:ok, %GoogleApi.DLP.V2.Model.GoogleProtobufEmpty{}}` on success + * `{:ok, %GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2DiscoveryConfig{}}` on success * `{:error, info}` on failure """ - @spec dlp_organizations_locations_inspect_templates_delete( + @spec dlp_organizations_locations_discovery_configs_get( Tesla.Env.client(), String.t(), keyword(), keyword() ) :: - {:ok, GoogleApi.DLP.V2.Model.GoogleProtobufEmpty.t()} + {:ok, GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2DiscoveryConfig.t()} | {:ok, Tesla.Env.t()} | {:ok, list()} | {:error, any()} - def dlp_organizations_locations_inspect_templates_delete( + def dlp_organizations_locations_discovery_configs_get( connection, name, optional_params \\ [], @@ -1348,7 +1486,7 @@ defmodule GoogleApi.DLP.V2.Api.Organizations do request = Request.new() - |> Request.method(:delete) + |> Request.method(:get) |> Request.url("/v2/{+name}", %{ "name" => URI.encode(name, &URI.char_unreserved?/1) }) @@ -1357,16 +1495,696 @@ defmodule GoogleApi.DLP.V2.Api.Organizations do connection |> Connection.execute(request) - |> Response.decode(opts ++ [struct: %GoogleApi.DLP.V2.Model.GoogleProtobufEmpty{}]) + |> Response.decode( + opts ++ [struct: %GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2DiscoveryConfig{}] + ) + end + + @doc """ + Lists discovery configurations. + + ## Parameters + + * `connection` (*type:* `GoogleApi.DLP.V2.Connection.t`) - Connection to server + * `parent` (*type:* `String.t`) - Required. Parent resource name. The format of this value is as follows: `projects/`PROJECT_ID`/locations/`LOCATION_ID The following example `parent` string specifies a parent project with the identifier `example-project`, and specifies the `europe-west3` location for processing data: parent=projects/example-project/locations/europe-west3 + * `optional_params` (*type:* `keyword()`) - Optional parameters + * `:"$.xgafv"` (*type:* `String.t`) - V1 error format. + * `:access_token` (*type:* `String.t`) - OAuth access token. + * `:alt` (*type:* `String.t`) - Data format for response. + * `:callback` (*type:* `String.t`) - JSONP + * `:fields` (*type:* `String.t`) - Selector specifying which fields to include in a partial response. + * `:key` (*type:* `String.t`) - 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. + * `:oauth_token` (*type:* `String.t`) - OAuth 2.0 token for the current user. + * `:prettyPrint` (*type:* `boolean()`) - Returns response with indentations and line breaks. + * `:quotaUser` (*type:* `String.t`) - 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. + * `:uploadType` (*type:* `String.t`) - Legacy upload protocol for media (e.g. "media", "multipart"). + * `:upload_protocol` (*type:* `String.t`) - Upload protocol for media (e.g. "raw", "multipart"). + * `:orderBy` (*type:* `String.t`) - Comma separated list of config fields to order by, followed by `asc` or `desc` postfix. This list is case insensitive. The default sorting order is ascending. Redundant space characters are insignificant. Example: `name asc,update_time, create_time desc` Supported fields are: - `last_run_time`: corresponds to the last time the DiscoveryConfig ran. - `name`: corresponds to the DiscoveryConfig's name. - `status`: corresponds to DiscoveryConfig's status. + * `:pageSize` (*type:* `integer()`) - Size of the page. This value can be limited by a server. + * `:pageToken` (*type:* `String.t`) - Page token to continue retrieval. Comes from the previous call to ListDiscoveryConfigs. `order_by` field must not change for subsequent calls. + * `opts` (*type:* `keyword()`) - Call options + + ## Returns + + * `{:ok, %GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2ListDiscoveryConfigsResponse{}}` on success + * `{:error, info}` on failure + """ + @spec dlp_organizations_locations_discovery_configs_list( + Tesla.Env.client(), + String.t(), + keyword(), + keyword() + ) :: + {:ok, GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2ListDiscoveryConfigsResponse.t()} + | {:ok, Tesla.Env.t()} + | {:ok, list()} + | {:error, any()} + def dlp_organizations_locations_discovery_configs_list( + connection, + parent, + optional_params \\ [], + opts \\ [] + ) do + optional_params_config = %{ + :"$.xgafv" => :query, + :access_token => :query, + :alt => :query, + :callback => :query, + :fields => :query, + :key => :query, + :oauth_token => :query, + :prettyPrint => :query, + :quotaUser => :query, + :uploadType => :query, + :upload_protocol => :query, + :orderBy => :query, + :pageSize => :query, + :pageToken => :query + } + + request = + Request.new() + |> Request.method(:get) + |> Request.url("/v2/{+parent}/discoveryConfigs", %{ + "parent" => URI.encode(parent, &URI.char_unreserved?/1) + }) + |> Request.add_optional_params(optional_params_config, optional_params) + |> Request.library_version(@library_version) + + connection + |> Connection.execute(request) + |> Response.decode( + opts ++ [struct: %GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2ListDiscoveryConfigsResponse{}] + ) + end + + @doc """ + Updates a discovery configuration. + + ## Parameters + + * `connection` (*type:* `GoogleApi.DLP.V2.Connection.t`) - Connection to server + * `name` (*type:* `String.t`) - Required. Resource name of the project and the configuration, for example `projects/dlp-test-project/discoveryConfigs/53234423`. + * `optional_params` (*type:* `keyword()`) - Optional parameters + * `:"$.xgafv"` (*type:* `String.t`) - V1 error format. + * `:access_token` (*type:* `String.t`) - OAuth access token. + * `:alt` (*type:* `String.t`) - Data format for response. + * `:callback` (*type:* `String.t`) - JSONP + * `:fields` (*type:* `String.t`) - Selector specifying which fields to include in a partial response. + * `:key` (*type:* `String.t`) - 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. + * `:oauth_token` (*type:* `String.t`) - OAuth 2.0 token for the current user. + * `:prettyPrint` (*type:* `boolean()`) - Returns response with indentations and line breaks. + * `:quotaUser` (*type:* `String.t`) - 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. + * `:uploadType` (*type:* `String.t`) - Legacy upload protocol for media (e.g. "media", "multipart"). + * `:upload_protocol` (*type:* `String.t`) - Upload protocol for media (e.g. "raw", "multipart"). + * `:body` (*type:* `GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2UpdateDiscoveryConfigRequest.t`) - + * `opts` (*type:* `keyword()`) - Call options + + ## Returns + + * `{:ok, %GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2DiscoveryConfig{}}` on success + * `{:error, info}` on failure + """ + @spec dlp_organizations_locations_discovery_configs_patch( + Tesla.Env.client(), + String.t(), + keyword(), + keyword() + ) :: + {:ok, GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2DiscoveryConfig.t()} + | {:ok, Tesla.Env.t()} + | {:ok, list()} + | {:error, any()} + def dlp_organizations_locations_discovery_configs_patch( + connection, + name, + optional_params \\ [], + opts \\ [] + ) do + optional_params_config = %{ + :"$.xgafv" => :query, + :access_token => :query, + :alt => :query, + :callback => :query, + :fields => :query, + :key => :query, + :oauth_token => :query, + :prettyPrint => :query, + :quotaUser => :query, + :uploadType => :query, + :upload_protocol => :query, + :body => :body + } + + request = + Request.new() + |> Request.method(:patch) + |> Request.url("/v2/{+name}", %{ + "name" => URI.encode(name, &URI.char_unreserved?/1) + }) + |> Request.add_optional_params(optional_params_config, optional_params) + |> Request.library_version(@library_version) + + connection + |> Connection.execute(request) + |> Response.decode( + opts ++ [struct: %GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2DiscoveryConfig{}] + ) + end + + @doc """ + Lists DlpJobs that match the specified filter in the request. See https://cloud.google.com/sensitive-data-protection/docs/inspecting-storage and https://cloud.google.com/sensitive-data-protection/docs/compute-risk-analysis to learn more. + + ## Parameters + + * `connection` (*type:* `GoogleApi.DLP.V2.Connection.t`) - Connection to server + * `parent` (*type:* `String.t`) - Required. Parent resource name. The format of this value varies depending on whether you have [specified a processing location](https://cloud.google.com/sensitive-data-protection/docs/specifying-location): + Projects scope, location specified: `projects/`PROJECT_ID`/locations/`LOCATION_ID + Projects scope, no location specified (defaults to global): `projects/`PROJECT_ID The following example `parent` string specifies a parent project with the identifier `example-project`, and specifies the `europe-west3` location for processing data: parent=projects/example-project/locations/europe-west3 + * `optional_params` (*type:* `keyword()`) - Optional parameters + * `:"$.xgafv"` (*type:* `String.t`) - V1 error format. + * `:access_token` (*type:* `String.t`) - OAuth access token. + * `:alt` (*type:* `String.t`) - Data format for response. + * `:callback` (*type:* `String.t`) - JSONP + * `:fields` (*type:* `String.t`) - Selector specifying which fields to include in a partial response. + * `:key` (*type:* `String.t`) - 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. + * `:oauth_token` (*type:* `String.t`) - OAuth 2.0 token for the current user. + * `:prettyPrint` (*type:* `boolean()`) - Returns response with indentations and line breaks. + * `:quotaUser` (*type:* `String.t`) - 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. + * `:uploadType` (*type:* `String.t`) - Legacy upload protocol for media (e.g. "media", "multipart"). + * `:upload_protocol` (*type:* `String.t`) - Upload protocol for media (e.g. "raw", "multipart"). + * `:filter` (*type:* `String.t`) - Allows filtering. Supported syntax: * Filter expressions are made up of one or more restrictions. * Restrictions can be combined by `AND` or `OR` logical operators. A sequence of restrictions implicitly uses `AND`. * A restriction has the form of `{field} {operator} {value}`. * Supported fields/values for inspect jobs: - `state` - PENDING|RUNNING|CANCELED|FINISHED|FAILED - `inspected_storage` - DATASTORE|CLOUD_STORAGE|BIGQUERY - `trigger_name` - The name of the trigger that created the job. - 'end_time` - Corresponds to the time the job finished. - 'start_time` - Corresponds to the time the job finished. * Supported fields for risk analysis jobs: - `state` - RUNNING|CANCELED|FINISHED|FAILED - 'end_time` - Corresponds to the time the job finished. - 'start_time` - Corresponds to the time the job finished. * The operator must be `=` or `!=`. Examples: * inspected_storage = cloud_storage AND state = done * inspected_storage = cloud_storage OR inspected_storage = bigquery * inspected_storage = cloud_storage AND (state = done OR state = canceled) * end_time > \\"2017-12-12T00:00:00+00:00\\" The length of this field should be no more than 500 characters. + * `:locationId` (*type:* `String.t`) - Deprecated. This field has no effect. + * `:orderBy` (*type:* `String.t`) - Comma separated list of fields to order by, followed by `asc` or `desc` postfix. This list is case insensitive. The default sorting order is ascending. Redundant space characters are insignificant. Example: `name asc, end_time asc, create_time desc` Supported fields are: - `create_time`: corresponds to the time the job was created. - `end_time`: corresponds to the time the job ended. - `name`: corresponds to the job's name. - `state`: corresponds to `state` + * `:pageSize` (*type:* `integer()`) - The standard list page size. + * `:pageToken` (*type:* `String.t`) - The standard list page token. + * `:type` (*type:* `String.t`) - The type of job. Defaults to `DlpJobType.INSPECT` + * `opts` (*type:* `keyword()`) - Call options + + ## Returns + + * `{:ok, %GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2ListDlpJobsResponse{}}` on success + * `{:error, info}` on failure + """ + @spec dlp_organizations_locations_dlp_jobs_list( + Tesla.Env.client(), + String.t(), + keyword(), + keyword() + ) :: + {:ok, GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2ListDlpJobsResponse.t()} + | {:ok, Tesla.Env.t()} + | {:ok, list()} + | {:error, any()} + def dlp_organizations_locations_dlp_jobs_list( + connection, + parent, + optional_params \\ [], + opts \\ [] + ) do + optional_params_config = %{ + :"$.xgafv" => :query, + :access_token => :query, + :alt => :query, + :callback => :query, + :fields => :query, + :key => :query, + :oauth_token => :query, + :prettyPrint => :query, + :quotaUser => :query, + :uploadType => :query, + :upload_protocol => :query, + :filter => :query, + :locationId => :query, + :orderBy => :query, + :pageSize => :query, + :pageToken => :query, + :type => :query + } + + request = + Request.new() + |> Request.method(:get) + |> Request.url("/v2/{+parent}/dlpJobs", %{ + "parent" => URI.encode(parent, &URI.char_unreserved?/1) + }) + |> Request.add_optional_params(optional_params_config, optional_params) + |> Request.library_version(@library_version) + + connection + |> Connection.execute(request) + |> Response.decode( + opts ++ [struct: %GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2ListDlpJobsResponse{}] + ) + end + + @doc """ + Creates an InspectTemplate for reusing frequently used configuration for inspecting content, images, and storage. See https://cloud.google.com/sensitive-data-protection/docs/creating-templates to learn more. + + ## Parameters + + * `connection` (*type:* `GoogleApi.DLP.V2.Connection.t`) - Connection to server + * `parent` (*type:* `String.t`) - Required. Parent resource name. The format of this value varies depending on the scope of the request (project or organization) and whether you have [specified a processing location](https://cloud.google.com/sensitive-data-protection/docs/specifying-location): + Projects scope, location specified: `projects/`PROJECT_ID`/locations/`LOCATION_ID + Projects scope, no location specified (defaults to global): `projects/`PROJECT_ID + Organizations scope, location specified: `organizations/`ORG_ID`/locations/`LOCATION_ID + Organizations scope, no location specified (defaults to global): `organizations/`ORG_ID The following example `parent` string specifies a parent project with the identifier `example-project`, and specifies the `europe-west3` location for processing data: parent=projects/example-project/locations/europe-west3 + * `optional_params` (*type:* `keyword()`) - Optional parameters + * `:"$.xgafv"` (*type:* `String.t`) - V1 error format. + * `:access_token` (*type:* `String.t`) - OAuth access token. + * `:alt` (*type:* `String.t`) - Data format for response. + * `:callback` (*type:* `String.t`) - JSONP + * `:fields` (*type:* `String.t`) - Selector specifying which fields to include in a partial response. + * `:key` (*type:* `String.t`) - 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. + * `:oauth_token` (*type:* `String.t`) - OAuth 2.0 token for the current user. + * `:prettyPrint` (*type:* `boolean()`) - Returns response with indentations and line breaks. + * `:quotaUser` (*type:* `String.t`) - 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. + * `:uploadType` (*type:* `String.t`) - Legacy upload protocol for media (e.g. "media", "multipart"). + * `:upload_protocol` (*type:* `String.t`) - Upload protocol for media (e.g. "raw", "multipart"). + * `:body` (*type:* `GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2CreateInspectTemplateRequest.t`) - + * `opts` (*type:* `keyword()`) - Call options + + ## Returns + + * `{:ok, %GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2InspectTemplate{}}` on success + * `{:error, info}` on failure + """ + @spec dlp_organizations_locations_inspect_templates_create( + Tesla.Env.client(), + String.t(), + keyword(), + keyword() + ) :: + {:ok, GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2InspectTemplate.t()} + | {:ok, Tesla.Env.t()} + | {:ok, list()} + | {:error, any()} + def dlp_organizations_locations_inspect_templates_create( + connection, + parent, + optional_params \\ [], + opts \\ [] + ) do + optional_params_config = %{ + :"$.xgafv" => :query, + :access_token => :query, + :alt => :query, + :callback => :query, + :fields => :query, + :key => :query, + :oauth_token => :query, + :prettyPrint => :query, + :quotaUser => :query, + :uploadType => :query, + :upload_protocol => :query, + :body => :body + } + + request = + Request.new() + |> Request.method(:post) + |> Request.url("/v2/{+parent}/inspectTemplates", %{ + "parent" => URI.encode(parent, &URI.char_unreserved?/1) + }) + |> Request.add_optional_params(optional_params_config, optional_params) + |> Request.library_version(@library_version) + + connection + |> Connection.execute(request) + |> Response.decode( + opts ++ [struct: %GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2InspectTemplate{}] + ) + end + + @doc """ + Deletes an InspectTemplate. See https://cloud.google.com/sensitive-data-protection/docs/creating-templates to learn more. + + ## Parameters + + * `connection` (*type:* `GoogleApi.DLP.V2.Connection.t`) - Connection to server + * `name` (*type:* `String.t`) - Required. Resource name of the organization and inspectTemplate to be deleted, for example `organizations/433245324/inspectTemplates/432452342` or projects/project-id/inspectTemplates/432452342. + * `optional_params` (*type:* `keyword()`) - Optional parameters + * `:"$.xgafv"` (*type:* `String.t`) - V1 error format. + * `:access_token` (*type:* `String.t`) - OAuth access token. + * `:alt` (*type:* `String.t`) - Data format for response. + * `:callback` (*type:* `String.t`) - JSONP + * `:fields` (*type:* `String.t`) - Selector specifying which fields to include in a partial response. + * `:key` (*type:* `String.t`) - 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. + * `:oauth_token` (*type:* `String.t`) - OAuth 2.0 token for the current user. + * `:prettyPrint` (*type:* `boolean()`) - Returns response with indentations and line breaks. + * `:quotaUser` (*type:* `String.t`) - 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. + * `:uploadType` (*type:* `String.t`) - Legacy upload protocol for media (e.g. "media", "multipart"). + * `:upload_protocol` (*type:* `String.t`) - Upload protocol for media (e.g. "raw", "multipart"). + * `opts` (*type:* `keyword()`) - Call options + + ## Returns + + * `{:ok, %GoogleApi.DLP.V2.Model.GoogleProtobufEmpty{}}` on success + * `{:error, info}` on failure + """ + @spec dlp_organizations_locations_inspect_templates_delete( + Tesla.Env.client(), + String.t(), + keyword(), + keyword() + ) :: + {:ok, GoogleApi.DLP.V2.Model.GoogleProtobufEmpty.t()} + | {:ok, Tesla.Env.t()} + | {:ok, list()} + | {:error, any()} + def dlp_organizations_locations_inspect_templates_delete( + connection, + name, + optional_params \\ [], + opts \\ [] + ) do + optional_params_config = %{ + :"$.xgafv" => :query, + :access_token => :query, + :alt => :query, + :callback => :query, + :fields => :query, + :key => :query, + :oauth_token => :query, + :prettyPrint => :query, + :quotaUser => :query, + :uploadType => :query, + :upload_protocol => :query + } + + request = + Request.new() + |> Request.method(:delete) + |> Request.url("/v2/{+name}", %{ + "name" => URI.encode(name, &URI.char_unreserved?/1) + }) + |> Request.add_optional_params(optional_params_config, optional_params) + |> Request.library_version(@library_version) + + connection + |> Connection.execute(request) + |> Response.decode(opts ++ [struct: %GoogleApi.DLP.V2.Model.GoogleProtobufEmpty{}]) + end + + @doc """ + Gets an InspectTemplate. See https://cloud.google.com/sensitive-data-protection/docs/creating-templates to learn more. + + ## Parameters + + * `connection` (*type:* `GoogleApi.DLP.V2.Connection.t`) - Connection to server + * `name` (*type:* `String.t`) - Required. Resource name of the organization and inspectTemplate to be read, for example `organizations/433245324/inspectTemplates/432452342` or projects/project-id/inspectTemplates/432452342. + * `optional_params` (*type:* `keyword()`) - Optional parameters + * `:"$.xgafv"` (*type:* `String.t`) - V1 error format. + * `:access_token` (*type:* `String.t`) - OAuth access token. + * `:alt` (*type:* `String.t`) - Data format for response. + * `:callback` (*type:* `String.t`) - JSONP + * `:fields` (*type:* `String.t`) - Selector specifying which fields to include in a partial response. + * `:key` (*type:* `String.t`) - 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. + * `:oauth_token` (*type:* `String.t`) - OAuth 2.0 token for the current user. + * `:prettyPrint` (*type:* `boolean()`) - Returns response with indentations and line breaks. + * `:quotaUser` (*type:* `String.t`) - 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. + * `:uploadType` (*type:* `String.t`) - Legacy upload protocol for media (e.g. "media", "multipart"). + * `:upload_protocol` (*type:* `String.t`) - Upload protocol for media (e.g. "raw", "multipart"). + * `opts` (*type:* `keyword()`) - Call options + + ## Returns + + * `{:ok, %GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2InspectTemplate{}}` on success + * `{:error, info}` on failure + """ + @spec dlp_organizations_locations_inspect_templates_get( + Tesla.Env.client(), + String.t(), + keyword(), + keyword() + ) :: + {:ok, GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2InspectTemplate.t()} + | {:ok, Tesla.Env.t()} + | {:ok, list()} + | {:error, any()} + def dlp_organizations_locations_inspect_templates_get( + connection, + name, + optional_params \\ [], + opts \\ [] + ) do + optional_params_config = %{ + :"$.xgafv" => :query, + :access_token => :query, + :alt => :query, + :callback => :query, + :fields => :query, + :key => :query, + :oauth_token => :query, + :prettyPrint => :query, + :quotaUser => :query, + :uploadType => :query, + :upload_protocol => :query + } + + request = + Request.new() + |> Request.method(:get) + |> Request.url("/v2/{+name}", %{ + "name" => URI.encode(name, &URI.char_unreserved?/1) + }) + |> Request.add_optional_params(optional_params_config, optional_params) + |> Request.library_version(@library_version) + + connection + |> Connection.execute(request) + |> Response.decode( + opts ++ [struct: %GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2InspectTemplate{}] + ) + end + + @doc """ + Lists InspectTemplates. See https://cloud.google.com/sensitive-data-protection/docs/creating-templates to learn more. + + ## Parameters + + * `connection` (*type:* `GoogleApi.DLP.V2.Connection.t`) - Connection to server + * `parent` (*type:* `String.t`) - Required. Parent resource name. The format of this value varies depending on the scope of the request (project or organization) and whether you have [specified a processing location](https://cloud.google.com/sensitive-data-protection/docs/specifying-location): + Projects scope, location specified: `projects/`PROJECT_ID`/locations/`LOCATION_ID + Projects scope, no location specified (defaults to global): `projects/`PROJECT_ID + Organizations scope, location specified: `organizations/`ORG_ID`/locations/`LOCATION_ID + Organizations scope, no location specified (defaults to global): `organizations/`ORG_ID The following example `parent` string specifies a parent project with the identifier `example-project`, and specifies the `europe-west3` location for processing data: parent=projects/example-project/locations/europe-west3 + * `optional_params` (*type:* `keyword()`) - Optional parameters + * `:"$.xgafv"` (*type:* `String.t`) - V1 error format. + * `:access_token` (*type:* `String.t`) - OAuth access token. + * `:alt` (*type:* `String.t`) - Data format for response. + * `:callback` (*type:* `String.t`) - JSONP + * `:fields` (*type:* `String.t`) - Selector specifying which fields to include in a partial response. + * `:key` (*type:* `String.t`) - 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. + * `:oauth_token` (*type:* `String.t`) - OAuth 2.0 token for the current user. + * `:prettyPrint` (*type:* `boolean()`) - Returns response with indentations and line breaks. + * `:quotaUser` (*type:* `String.t`) - 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. + * `:uploadType` (*type:* `String.t`) - Legacy upload protocol for media (e.g. "media", "multipart"). + * `:upload_protocol` (*type:* `String.t`) - Upload protocol for media (e.g. "raw", "multipart"). + * `:locationId` (*type:* `String.t`) - Deprecated. This field has no effect. + * `:orderBy` (*type:* `String.t`) - Comma separated list of fields to order by, followed by `asc` or `desc` postfix. This list is case insensitive. The default sorting order is ascending. Redundant space characters are insignificant. Example: `name asc,update_time, create_time desc` Supported fields are: - `create_time`: corresponds to the time the template was created. - `update_time`: corresponds to the time the template was last updated. - `name`: corresponds to the template's name. - `display_name`: corresponds to the template's display name. + * `:pageSize` (*type:* `integer()`) - Size of the page. This value can be limited by the server. If zero server returns a page of max size 100. + * `:pageToken` (*type:* `String.t`) - Page token to continue retrieval. Comes from the previous call to `ListInspectTemplates`. + * `opts` (*type:* `keyword()`) - Call options + + ## Returns + + * `{:ok, %GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2ListInspectTemplatesResponse{}}` on success + * `{:error, info}` on failure + """ + @spec dlp_organizations_locations_inspect_templates_list( + Tesla.Env.client(), + String.t(), + keyword(), + keyword() + ) :: + {:ok, GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2ListInspectTemplatesResponse.t()} + | {:ok, Tesla.Env.t()} + | {:ok, list()} + | {:error, any()} + def dlp_organizations_locations_inspect_templates_list( + connection, + parent, + optional_params \\ [], + opts \\ [] + ) do + optional_params_config = %{ + :"$.xgafv" => :query, + :access_token => :query, + :alt => :query, + :callback => :query, + :fields => :query, + :key => :query, + :oauth_token => :query, + :prettyPrint => :query, + :quotaUser => :query, + :uploadType => :query, + :upload_protocol => :query, + :locationId => :query, + :orderBy => :query, + :pageSize => :query, + :pageToken => :query + } + + request = + Request.new() + |> Request.method(:get) + |> Request.url("/v2/{+parent}/inspectTemplates", %{ + "parent" => URI.encode(parent, &URI.char_unreserved?/1) + }) + |> Request.add_optional_params(optional_params_config, optional_params) + |> Request.library_version(@library_version) + + connection + |> Connection.execute(request) + |> Response.decode( + opts ++ [struct: %GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2ListInspectTemplatesResponse{}] + ) + end + + @doc """ + Updates the InspectTemplate. See https://cloud.google.com/sensitive-data-protection/docs/creating-templates to learn more. + + ## Parameters + + * `connection` (*type:* `GoogleApi.DLP.V2.Connection.t`) - Connection to server + * `name` (*type:* `String.t`) - Required. Resource name of organization and inspectTemplate to be updated, for example `organizations/433245324/inspectTemplates/432452342` or projects/project-id/inspectTemplates/432452342. + * `optional_params` (*type:* `keyword()`) - Optional parameters + * `:"$.xgafv"` (*type:* `String.t`) - V1 error format. + * `:access_token` (*type:* `String.t`) - OAuth access token. + * `:alt` (*type:* `String.t`) - Data format for response. + * `:callback` (*type:* `String.t`) - JSONP + * `:fields` (*type:* `String.t`) - Selector specifying which fields to include in a partial response. + * `:key` (*type:* `String.t`) - 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. + * `:oauth_token` (*type:* `String.t`) - OAuth 2.0 token for the current user. + * `:prettyPrint` (*type:* `boolean()`) - Returns response with indentations and line breaks. + * `:quotaUser` (*type:* `String.t`) - 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. + * `:uploadType` (*type:* `String.t`) - Legacy upload protocol for media (e.g. "media", "multipart"). + * `:upload_protocol` (*type:* `String.t`) - Upload protocol for media (e.g. "raw", "multipart"). + * `:body` (*type:* `GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2UpdateInspectTemplateRequest.t`) - + * `opts` (*type:* `keyword()`) - Call options + + ## Returns + + * `{:ok, %GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2InspectTemplate{}}` on success + * `{:error, info}` on failure + """ + @spec dlp_organizations_locations_inspect_templates_patch( + Tesla.Env.client(), + String.t(), + keyword(), + keyword() + ) :: + {:ok, GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2InspectTemplate.t()} + | {:ok, Tesla.Env.t()} + | {:ok, list()} + | {:error, any()} + def dlp_organizations_locations_inspect_templates_patch( + connection, + name, + optional_params \\ [], + opts \\ [] + ) do + optional_params_config = %{ + :"$.xgafv" => :query, + :access_token => :query, + :alt => :query, + :callback => :query, + :fields => :query, + :key => :query, + :oauth_token => :query, + :prettyPrint => :query, + :quotaUser => :query, + :uploadType => :query, + :upload_protocol => :query, + :body => :body + } + + request = + Request.new() + |> Request.method(:patch) + |> Request.url("/v2/{+name}", %{ + "name" => URI.encode(name, &URI.char_unreserved?/1) + }) + |> Request.add_optional_params(optional_params_config, optional_params) + |> Request.library_version(@library_version) + + connection + |> Connection.execute(request) + |> Response.decode( + opts ++ [struct: %GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2InspectTemplate{}] + ) + end + + @doc """ + Creates a job trigger to run DLP actions such as scanning storage for sensitive information on a set schedule. See https://cloud.google.com/sensitive-data-protection/docs/creating-job-triggers to learn more. + + ## Parameters + + * `connection` (*type:* `GoogleApi.DLP.V2.Connection.t`) - Connection to server + * `parent` (*type:* `String.t`) - Required. Parent resource name. The format of this value varies depending on whether you have [specified a processing location](https://cloud.google.com/sensitive-data-protection/docs/specifying-location): + Projects scope, location specified: `projects/`PROJECT_ID`/locations/`LOCATION_ID + Projects scope, no location specified (defaults to global): `projects/`PROJECT_ID The following example `parent` string specifies a parent project with the identifier `example-project`, and specifies the `europe-west3` location for processing data: parent=projects/example-project/locations/europe-west3 + * `optional_params` (*type:* `keyword()`) - Optional parameters + * `:"$.xgafv"` (*type:* `String.t`) - V1 error format. + * `:access_token` (*type:* `String.t`) - OAuth access token. + * `:alt` (*type:* `String.t`) - Data format for response. + * `:callback` (*type:* `String.t`) - JSONP + * `:fields` (*type:* `String.t`) - Selector specifying which fields to include in a partial response. + * `:key` (*type:* `String.t`) - 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. + * `:oauth_token` (*type:* `String.t`) - OAuth 2.0 token for the current user. + * `:prettyPrint` (*type:* `boolean()`) - Returns response with indentations and line breaks. + * `:quotaUser` (*type:* `String.t`) - 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. + * `:uploadType` (*type:* `String.t`) - Legacy upload protocol for media (e.g. "media", "multipart"). + * `:upload_protocol` (*type:* `String.t`) - Upload protocol for media (e.g. "raw", "multipart"). + * `:body` (*type:* `GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2CreateJobTriggerRequest.t`) - + * `opts` (*type:* `keyword()`) - Call options + + ## Returns + + * `{:ok, %GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2JobTrigger{}}` on success + * `{:error, info}` on failure + """ + @spec dlp_organizations_locations_job_triggers_create( + Tesla.Env.client(), + String.t(), + keyword(), + keyword() + ) :: + {:ok, GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2JobTrigger.t()} + | {:ok, Tesla.Env.t()} + | {:ok, list()} + | {:error, any()} + def dlp_organizations_locations_job_triggers_create( + connection, + parent, + optional_params \\ [], + opts \\ [] + ) do + optional_params_config = %{ + :"$.xgafv" => :query, + :access_token => :query, + :alt => :query, + :callback => :query, + :fields => :query, + :key => :query, + :oauth_token => :query, + :prettyPrint => :query, + :quotaUser => :query, + :uploadType => :query, + :upload_protocol => :query, + :body => :body + } + + request = + Request.new() + |> Request.method(:post) + |> Request.url("/v2/{+parent}/jobTriggers", %{ + "parent" => URI.encode(parent, &URI.char_unreserved?/1) + }) + |> Request.add_optional_params(optional_params_config, optional_params) + |> Request.library_version(@library_version) + + connection + |> Connection.execute(request) + |> Response.decode(opts ++ [struct: %GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2JobTrigger{}]) end @doc """ - Gets an InspectTemplate. See https://cloud.google.com/dlp/docs/creating-templates to learn more. + Deletes a job trigger. See https://cloud.google.com/sensitive-data-protection/docs/creating-job-triggers to learn more. ## Parameters * `connection` (*type:* `GoogleApi.DLP.V2.Connection.t`) - Connection to server - * `name` (*type:* `String.t`) - Required. Resource name of the organization and inspectTemplate to be read, for example `organizations/433245324/inspectTemplates/432452342` or projects/project-id/inspectTemplates/432452342. + * `name` (*type:* `String.t`) - Required. Resource name of the project and the triggeredJob, for example `projects/dlp-test-project/jobTriggers/53234423`. * `optional_params` (*type:* `keyword()`) - Optional parameters * `:"$.xgafv"` (*type:* `String.t`) - V1 error format. * `:access_token` (*type:* `String.t`) - OAuth access token. @@ -1383,20 +2201,20 @@ defmodule GoogleApi.DLP.V2.Api.Organizations do ## Returns - * `{:ok, %GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2InspectTemplate{}}` on success + * `{:ok, %GoogleApi.DLP.V2.Model.GoogleProtobufEmpty{}}` on success * `{:error, info}` on failure """ - @spec dlp_organizations_locations_inspect_templates_get( + @spec dlp_organizations_locations_job_triggers_delete( Tesla.Env.client(), String.t(), keyword(), keyword() ) :: - {:ok, GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2InspectTemplate.t()} + {:ok, GoogleApi.DLP.V2.Model.GoogleProtobufEmpty.t()} | {:ok, Tesla.Env.t()} | {:ok, list()} | {:error, any()} - def dlp_organizations_locations_inspect_templates_get( + def dlp_organizations_locations_job_triggers_delete( connection, name, optional_params \\ [], @@ -1418,7 +2236,7 @@ defmodule GoogleApi.DLP.V2.Api.Organizations do request = Request.new() - |> Request.method(:get) + |> Request.method(:delete) |> Request.url("/v2/{+name}", %{ "name" => URI.encode(name, &URI.char_unreserved?/1) }) @@ -1427,18 +2245,16 @@ defmodule GoogleApi.DLP.V2.Api.Organizations do connection |> Connection.execute(request) - |> Response.decode( - opts ++ [struct: %GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2InspectTemplate{}] - ) + |> Response.decode(opts ++ [struct: %GoogleApi.DLP.V2.Model.GoogleProtobufEmpty{}]) end @doc """ - Lists InspectTemplates. See https://cloud.google.com/dlp/docs/creating-templates to learn more. + Gets a job trigger. See https://cloud.google.com/sensitive-data-protection/docs/creating-job-triggers to learn more. ## Parameters * `connection` (*type:* `GoogleApi.DLP.V2.Connection.t`) - Connection to server - * `parent` (*type:* `String.t`) - Required. Parent resource name. The format of this value varies depending on the scope of the request (project or organization) and whether you have [specified a processing location](https://cloud.google.com/dlp/docs/specifying-location): + Projects scope, location specified: `projects/`PROJECT_ID`/locations/`LOCATION_ID + Projects scope, no location specified (defaults to global): `projects/`PROJECT_ID + Organizations scope, location specified: `organizations/`ORG_ID`/locations/`LOCATION_ID + Organizations scope, no location specified (defaults to global): `organizations/`ORG_ID The following example `parent` string specifies a parent project with the identifier `example-project`, and specifies the `europe-west3` location for processing data: parent=projects/example-project/locations/europe-west3 + * `name` (*type:* `String.t`) - Required. Resource name of the project and the triggeredJob, for example `projects/dlp-test-project/jobTriggers/53234423`. * `optional_params` (*type:* `keyword()`) - Optional parameters * `:"$.xgafv"` (*type:* `String.t`) - V1 error format. * `:access_token` (*type:* `String.t`) - OAuth access token. @@ -1451,30 +2267,26 @@ defmodule GoogleApi.DLP.V2.Api.Organizations do * `:quotaUser` (*type:* `String.t`) - 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. * `:uploadType` (*type:* `String.t`) - Legacy upload protocol for media (e.g. "media", "multipart"). * `:upload_protocol` (*type:* `String.t`) - Upload protocol for media (e.g. "raw", "multipart"). - * `:locationId` (*type:* `String.t`) - Deprecated. This field has no effect. - * `:orderBy` (*type:* `String.t`) - Comma separated list of fields to order by, followed by `asc` or `desc` postfix. This list is case-insensitive, default sorting order is ascending, redundant space characters are insignificant. Example: `name asc,update_time, create_time desc` Supported fields are: - `create_time`: corresponds to the time the template was created. - `update_time`: corresponds to the time the template was last updated. - `name`: corresponds to the template's name. - `display_name`: corresponds to the template's display name. - * `:pageSize` (*type:* `integer()`) - Size of the page, can be limited by the server. If zero server returns a page of max size 100. - * `:pageToken` (*type:* `String.t`) - Page token to continue retrieval. Comes from previous call to `ListInspectTemplates`. * `opts` (*type:* `keyword()`) - Call options ## Returns - * `{:ok, %GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2ListInspectTemplatesResponse{}}` on success + * `{:ok, %GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2JobTrigger{}}` on success * `{:error, info}` on failure """ - @spec dlp_organizations_locations_inspect_templates_list( + @spec dlp_organizations_locations_job_triggers_get( Tesla.Env.client(), String.t(), keyword(), keyword() ) :: - {:ok, GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2ListInspectTemplatesResponse.t()} + {:ok, GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2JobTrigger.t()} | {:ok, Tesla.Env.t()} | {:ok, list()} | {:error, any()} - def dlp_organizations_locations_inspect_templates_list( + def dlp_organizations_locations_job_triggers_get( connection, - parent, + name, optional_params \\ [], opts \\ [] ) do @@ -1489,36 +2301,30 @@ defmodule GoogleApi.DLP.V2.Api.Organizations do :prettyPrint => :query, :quotaUser => :query, :uploadType => :query, - :upload_protocol => :query, - :locationId => :query, - :orderBy => :query, - :pageSize => :query, - :pageToken => :query + :upload_protocol => :query } request = Request.new() |> Request.method(:get) - |> Request.url("/v2/{+parent}/inspectTemplates", %{ - "parent" => URI.encode(parent, &URI.char_unreserved?/1) + |> Request.url("/v2/{+name}", %{ + "name" => URI.encode(name, &URI.char_unreserved?/1) }) |> Request.add_optional_params(optional_params_config, optional_params) |> Request.library_version(@library_version) connection |> Connection.execute(request) - |> Response.decode( - opts ++ [struct: %GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2ListInspectTemplatesResponse{}] - ) + |> Response.decode(opts ++ [struct: %GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2JobTrigger{}]) end @doc """ - Updates the InspectTemplate. See https://cloud.google.com/dlp/docs/creating-templates to learn more. + Lists job triggers. See https://cloud.google.com/sensitive-data-protection/docs/creating-job-triggers to learn more. ## Parameters * `connection` (*type:* `GoogleApi.DLP.V2.Connection.t`) - Connection to server - * `name` (*type:* `String.t`) - Required. Resource name of organization and inspectTemplate to be updated, for example `organizations/433245324/inspectTemplates/432452342` or projects/project-id/inspectTemplates/432452342. + * `parent` (*type:* `String.t`) - Required. Parent resource name. The format of this value varies depending on whether you have [specified a processing location](https://cloud.google.com/sensitive-data-protection/docs/specifying-location): + Projects scope, location specified: `projects/`PROJECT_ID`/locations/`LOCATION_ID + Projects scope, no location specified (defaults to global): `projects/`PROJECT_ID The following example `parent` string specifies a parent project with the identifier `example-project`, and specifies the `europe-west3` location for processing data: parent=projects/example-project/locations/europe-west3 * `optional_params` (*type:* `keyword()`) - Optional parameters * `:"$.xgafv"` (*type:* `String.t`) - V1 error format. * `:access_token` (*type:* `String.t`) - OAuth access token. @@ -1531,27 +2337,32 @@ defmodule GoogleApi.DLP.V2.Api.Organizations do * `:quotaUser` (*type:* `String.t`) - 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. * `:uploadType` (*type:* `String.t`) - Legacy upload protocol for media (e.g. "media", "multipart"). * `:upload_protocol` (*type:* `String.t`) - Upload protocol for media (e.g. "raw", "multipart"). - * `:body` (*type:* `GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2UpdateInspectTemplateRequest.t`) - + * `:filter` (*type:* `String.t`) - Allows filtering. Supported syntax: * Filter expressions are made up of one or more restrictions. * Restrictions can be combined by `AND` or `OR` logical operators. A sequence of restrictions implicitly uses `AND`. * A restriction has the form of `{field} {operator} {value}`. * Supported fields/values for inspect triggers: - `status` - HEALTHY|PAUSED|CANCELLED - `inspected_storage` - DATASTORE|CLOUD_STORAGE|BIGQUERY - 'last_run_time` - RFC 3339 formatted timestamp, surrounded by quotation marks. Nanoseconds are ignored. - 'error_count' - Number of errors that have occurred while running. * The operator must be `=` or `!=` for status and inspected_storage. Examples: * inspected_storage = cloud_storage AND status = HEALTHY * inspected_storage = cloud_storage OR inspected_storage = bigquery * inspected_storage = cloud_storage AND (state = PAUSED OR state = HEALTHY) * last_run_time > \\"2017-12-12T00:00:00+00:00\\" The length of this field should be no more than 500 characters. + * `:locationId` (*type:* `String.t`) - Deprecated. This field has no effect. + * `:orderBy` (*type:* `String.t`) - Comma separated list of triggeredJob fields to order by, followed by `asc` or `desc` postfix. This list is case insensitive. The default sorting order is ascending. Redundant space characters are insignificant. Example: `name asc,update_time, create_time desc` Supported fields are: - `create_time`: corresponds to the time the JobTrigger was created. - `update_time`: corresponds to the time the JobTrigger was last updated. - `last_run_time`: corresponds to the last time the JobTrigger ran. - `name`: corresponds to the JobTrigger's name. - `display_name`: corresponds to the JobTrigger's display name. - `status`: corresponds to JobTrigger's status. + * `:pageSize` (*type:* `integer()`) - Size of the page. This value can be limited by a server. + * `:pageToken` (*type:* `String.t`) - Page token to continue retrieval. Comes from the previous call to ListJobTriggers. `order_by` field must not change for subsequent calls. + * `:type` (*type:* `String.t`) - The type of jobs. Will use `DlpJobType.INSPECT` if not set. * `opts` (*type:* `keyword()`) - Call options ## Returns - * `{:ok, %GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2InspectTemplate{}}` on success + * `{:ok, %GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2ListJobTriggersResponse{}}` on success * `{:error, info}` on failure """ - @spec dlp_organizations_locations_inspect_templates_patch( + @spec dlp_organizations_locations_job_triggers_list( Tesla.Env.client(), String.t(), keyword(), keyword() ) :: - {:ok, GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2InspectTemplate.t()} + {:ok, GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2ListJobTriggersResponse.t()} | {:ok, Tesla.Env.t()} | {:ok, list()} | {:error, any()} - def dlp_organizations_locations_inspect_templates_patch( + def dlp_organizations_locations_job_triggers_list( connection, - name, + parent, optional_params \\ [], opts \\ [] ) do @@ -1567,14 +2378,19 @@ defmodule GoogleApi.DLP.V2.Api.Organizations do :quotaUser => :query, :uploadType => :query, :upload_protocol => :query, - :body => :body + :filter => :query, + :locationId => :query, + :orderBy => :query, + :pageSize => :query, + :pageToken => :query, + :type => :query } request = Request.new() - |> Request.method(:patch) - |> Request.url("/v2/{+name}", %{ - "name" => URI.encode(name, &URI.char_unreserved?/1) + |> Request.method(:get) + |> Request.url("/v2/{+parent}/jobTriggers", %{ + "parent" => URI.encode(parent, &URI.char_unreserved?/1) }) |> Request.add_optional_params(optional_params_config, optional_params) |> Request.library_version(@library_version) @@ -1582,17 +2398,17 @@ defmodule GoogleApi.DLP.V2.Api.Organizations do connection |> Connection.execute(request) |> Response.decode( - opts ++ [struct: %GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2InspectTemplate{}] + opts ++ [struct: %GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2ListJobTriggersResponse{}] ) end @doc """ - Creates a job trigger to run DLP actions such as scanning storage for sensitive information on a set schedule. See https://cloud.google.com/dlp/docs/creating-job-triggers to learn more. + Updates a job trigger. See https://cloud.google.com/sensitive-data-protection/docs/creating-job-triggers to learn more. ## Parameters * `connection` (*type:* `GoogleApi.DLP.V2.Connection.t`) - Connection to server - * `parent` (*type:* `String.t`) - Required. Parent resource name. The format of this value varies depending on whether you have [specified a processing location](https://cloud.google.com/dlp/docs/specifying-location): + Projects scope, location specified: `projects/`PROJECT_ID`/locations/`LOCATION_ID + Projects scope, no location specified (defaults to global): `projects/`PROJECT_ID The following example `parent` string specifies a parent project with the identifier `example-project`, and specifies the `europe-west3` location for processing data: parent=projects/example-project/locations/europe-west3 + * `name` (*type:* `String.t`) - Required. Resource name of the project and the triggeredJob, for example `projects/dlp-test-project/jobTriggers/53234423`. * `optional_params` (*type:* `keyword()`) - Optional parameters * `:"$.xgafv"` (*type:* `String.t`) - V1 error format. * `:access_token` (*type:* `String.t`) - OAuth access token. @@ -1605,7 +2421,7 @@ defmodule GoogleApi.DLP.V2.Api.Organizations do * `:quotaUser` (*type:* `String.t`) - 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. * `:uploadType` (*type:* `String.t`) - Legacy upload protocol for media (e.g. "media", "multipart"). * `:upload_protocol` (*type:* `String.t`) - Upload protocol for media (e.g. "raw", "multipart"). - * `:body` (*type:* `GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2CreateJobTriggerRequest.t`) - + * `:body` (*type:* `GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2UpdateJobTriggerRequest.t`) - * `opts` (*type:* `keyword()`) - Call options ## Returns @@ -1613,7 +2429,7 @@ defmodule GoogleApi.DLP.V2.Api.Organizations do * `{:ok, %GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2JobTrigger{}}` on success * `{:error, info}` on failure """ - @spec dlp_organizations_locations_job_triggers_create( + @spec dlp_organizations_locations_job_triggers_patch( Tesla.Env.client(), String.t(), keyword(), @@ -1623,9 +2439,9 @@ defmodule GoogleApi.DLP.V2.Api.Organizations do | {:ok, Tesla.Env.t()} | {:ok, list()} | {:error, any()} - def dlp_organizations_locations_job_triggers_create( + def dlp_organizations_locations_job_triggers_patch( connection, - parent, + name, optional_params \\ [], opts \\ [] ) do @@ -1646,9 +2462,9 @@ defmodule GoogleApi.DLP.V2.Api.Organizations do request = Request.new() - |> Request.method(:post) - |> Request.url("/v2/{+parent}/jobTriggers", %{ - "parent" => URI.encode(parent, &URI.char_unreserved?/1) + |> Request.method(:patch) + |> Request.url("/v2/{+name}", %{ + "name" => URI.encode(name, &URI.char_unreserved?/1) }) |> Request.add_optional_params(optional_params_config, optional_params) |> Request.library_version(@library_version) @@ -1659,12 +2475,12 @@ defmodule GoogleApi.DLP.V2.Api.Organizations do end @doc """ - Deletes a job trigger. See https://cloud.google.com/dlp/docs/creating-job-triggers to learn more. + Gets a project data profile. ## Parameters * `connection` (*type:* `GoogleApi.DLP.V2.Connection.t`) - Connection to server - * `name` (*type:* `String.t`) - Required. Resource name of the project and the triggeredJob, for example `projects/dlp-test-project/jobTriggers/53234423`. + * `name` (*type:* `String.t`) - Required. Resource name, for example `organizations/12345/locations/us/projectDataProfiles/53234423`. * `optional_params` (*type:* `keyword()`) - Optional parameters * `:"$.xgafv"` (*type:* `String.t`) - V1 error format. * `:access_token` (*type:* `String.t`) - OAuth access token. @@ -1681,20 +2497,20 @@ defmodule GoogleApi.DLP.V2.Api.Organizations do ## Returns - * `{:ok, %GoogleApi.DLP.V2.Model.GoogleProtobufEmpty{}}` on success + * `{:ok, %GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2ProjectDataProfile{}}` on success * `{:error, info}` on failure """ - @spec dlp_organizations_locations_job_triggers_delete( + @spec dlp_organizations_locations_project_data_profiles_get( Tesla.Env.client(), String.t(), keyword(), keyword() ) :: - {:ok, GoogleApi.DLP.V2.Model.GoogleProtobufEmpty.t()} + {:ok, GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2ProjectDataProfile.t()} | {:ok, Tesla.Env.t()} | {:ok, list()} | {:error, any()} - def dlp_organizations_locations_job_triggers_delete( + def dlp_organizations_locations_project_data_profiles_get( connection, name, optional_params \\ [], @@ -1716,7 +2532,7 @@ defmodule GoogleApi.DLP.V2.Api.Organizations do request = Request.new() - |> Request.method(:delete) + |> Request.method(:get) |> Request.url("/v2/{+name}", %{ "name" => URI.encode(name, &URI.char_unreserved?/1) }) @@ -1725,16 +2541,18 @@ defmodule GoogleApi.DLP.V2.Api.Organizations do connection |> Connection.execute(request) - |> Response.decode(opts ++ [struct: %GoogleApi.DLP.V2.Model.GoogleProtobufEmpty{}]) + |> Response.decode( + opts ++ [struct: %GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2ProjectDataProfile{}] + ) end @doc """ - Gets a job trigger. See https://cloud.google.com/dlp/docs/creating-job-triggers to learn more. + Lists data profiles for an organization. ## Parameters * `connection` (*type:* `GoogleApi.DLP.V2.Connection.t`) - Connection to server - * `name` (*type:* `String.t`) - Required. Resource name of the project and the triggeredJob, for example `projects/dlp-test-project/jobTriggers/53234423`. + * `parent` (*type:* `String.t`) - Required. organizations/{org_id}/locations/{loc_id} * `optional_params` (*type:* `keyword()`) - Optional parameters * `:"$.xgafv"` (*type:* `String.t`) - V1 error format. * `:access_token` (*type:* `String.t`) - OAuth access token. @@ -1747,26 +2565,30 @@ defmodule GoogleApi.DLP.V2.Api.Organizations do * `:quotaUser` (*type:* `String.t`) - 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. * `:uploadType` (*type:* `String.t`) - Legacy upload protocol for media (e.g. "media", "multipart"). * `:upload_protocol` (*type:* `String.t`) - Upload protocol for media (e.g. "raw", "multipart"). + * `:filter` (*type:* `String.t`) - Allows filtering. Supported syntax: * Filter expressions are made up of one or more restrictions. * Restrictions can be combined by `AND` or `OR` logical operators. A sequence of restrictions implicitly uses `AND`. * A restriction has the form of `{field} {operator} {value}`. * Supported fields/values: - `sensitivity_level` - HIGH|MODERATE|LOW - `data_risk_level` - HIGH|MODERATE|LOW - `status_code` - an RPC status code as defined in https://github.com/googleapis/googleapis/blob/master/google/rpc/code.proto * The operator must be `=` or `!=`. Examples: * project_id = 12345 AND status_code = 1 * project_id = 12345 AND sensitivity_level = HIGH The length of this field should be no more than 500 characters. + * `:orderBy` (*type:* `String.t`) - Comma separated list of fields to order by, followed by `asc` or `desc` postfix. This list is case insensitive. The default sorting order is ascending. Redundant space characters are insignificant. Only one order field at a time is allowed. Examples: * `project_id` * `sensitivity_level desc` Supported fields are: - `project_id`: GCP project ID - `sensitivity_level`: How sensitive the data in a project is, at most. - `data_risk_level`: How much risk is associated with this data. - `profile_last_generated`: When the profile was last updated in epoch seconds. + * `:pageSize` (*type:* `integer()`) - Size of the page. This value can be limited by the server. If zero, server returns a page of max size 100. + * `:pageToken` (*type:* `String.t`) - Page token to continue retrieval. * `opts` (*type:* `keyword()`) - Call options ## Returns - * `{:ok, %GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2JobTrigger{}}` on success + * `{:ok, %GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2ListProjectDataProfilesResponse{}}` on success * `{:error, info}` on failure """ - @spec dlp_organizations_locations_job_triggers_get( + @spec dlp_organizations_locations_project_data_profiles_list( Tesla.Env.client(), String.t(), keyword(), keyword() ) :: - {:ok, GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2JobTrigger.t()} + {:ok, GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2ListProjectDataProfilesResponse.t()} | {:ok, Tesla.Env.t()} | {:ok, list()} | {:error, any()} - def dlp_organizations_locations_job_triggers_get( + def dlp_organizations_locations_project_data_profiles_list( connection, - name, + parent, optional_params \\ [], opts \\ [] ) do @@ -1781,30 +2603,37 @@ defmodule GoogleApi.DLP.V2.Api.Organizations do :prettyPrint => :query, :quotaUser => :query, :uploadType => :query, - :upload_protocol => :query + :upload_protocol => :query, + :filter => :query, + :orderBy => :query, + :pageSize => :query, + :pageToken => :query } request = Request.new() |> Request.method(:get) - |> Request.url("/v2/{+name}", %{ - "name" => URI.encode(name, &URI.char_unreserved?/1) + |> Request.url("/v2/{+parent}/projectDataProfiles", %{ + "parent" => URI.encode(parent, &URI.char_unreserved?/1) }) |> Request.add_optional_params(optional_params_config, optional_params) |> Request.library_version(@library_version) connection |> Connection.execute(request) - |> Response.decode(opts ++ [struct: %GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2JobTrigger{}]) + |> Response.decode( + opts ++ + [struct: %GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2ListProjectDataProfilesResponse{}] + ) end @doc """ - Lists job triggers. See https://cloud.google.com/dlp/docs/creating-job-triggers to learn more. + Creates a pre-built stored infoType to be used for inspection. See https://cloud.google.com/sensitive-data-protection/docs/creating-stored-infotypes to learn more. ## Parameters * `connection` (*type:* `GoogleApi.DLP.V2.Connection.t`) - Connection to server - * `parent` (*type:* `String.t`) - Required. Parent resource name. The format of this value varies depending on whether you have [specified a processing location](https://cloud.google.com/dlp/docs/specifying-location): + Projects scope, location specified: `projects/`PROJECT_ID`/locations/`LOCATION_ID + Projects scope, no location specified (defaults to global): `projects/`PROJECT_ID The following example `parent` string specifies a parent project with the identifier `example-project`, and specifies the `europe-west3` location for processing data: parent=projects/example-project/locations/europe-west3 + * `parent` (*type:* `String.t`) - Required. Parent resource name. The format of this value varies depending on the scope of the request (project or organization) and whether you have [specified a processing location](https://cloud.google.com/sensitive-data-protection/docs/specifying-location): + Projects scope, location specified: `projects/`PROJECT_ID`/locations/`LOCATION_ID + Projects scope, no location specified (defaults to global): `projects/`PROJECT_ID + Organizations scope, location specified: `organizations/`ORG_ID`/locations/`LOCATION_ID + Organizations scope, no location specified (defaults to global): `organizations/`ORG_ID The following example `parent` string specifies a parent project with the identifier `example-project`, and specifies the `europe-west3` location for processing data: parent=projects/example-project/locations/europe-west3 * `optional_params` (*type:* `keyword()`) - Optional parameters * `:"$.xgafv"` (*type:* `String.t`) - V1 error format. * `:access_token` (*type:* `String.t`) - OAuth access token. @@ -1817,30 +2646,25 @@ defmodule GoogleApi.DLP.V2.Api.Organizations do * `:quotaUser` (*type:* `String.t`) - 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. * `:uploadType` (*type:* `String.t`) - Legacy upload protocol for media (e.g. "media", "multipart"). * `:upload_protocol` (*type:* `String.t`) - Upload protocol for media (e.g. "raw", "multipart"). - * `:filter` (*type:* `String.t`) - Allows filtering. Supported syntax: * Filter expressions are made up of one or more restrictions. * Restrictions can be combined by `AND` or `OR` logical operators. A sequence of restrictions implicitly uses `AND`. * A restriction has the form of `{field} {operator} {value}`. * Supported fields/values for inspect triggers: - `status` - HEALTHY|PAUSED|CANCELLED - `inspected_storage` - DATASTORE|CLOUD_STORAGE|BIGQUERY - 'last_run_time` - RFC 3339 formatted timestamp, surrounded by quotation marks. Nanoseconds are ignored. - 'error_count' - Number of errors that have occurred while running. * The operator must be `=` or `!=` for status and inspected_storage. Examples: * inspected_storage = cloud_storage AND status = HEALTHY * inspected_storage = cloud_storage OR inspected_storage = bigquery * inspected_storage = cloud_storage AND (state = PAUSED OR state = HEALTHY) * last_run_time > \\"2017-12-12T00:00:00+00:00\\" The length of this field should be no more than 500 characters. - * `:locationId` (*type:* `String.t`) - Deprecated. This field has no effect. - * `:orderBy` (*type:* `String.t`) - Comma separated list of triggeredJob fields to order by, followed by `asc` or `desc` postfix. This list is case-insensitive, default sorting order is ascending, redundant space characters are insignificant. Example: `name asc,update_time, create_time desc` Supported fields are: - `create_time`: corresponds to the time the JobTrigger was created. - `update_time`: corresponds to the time the JobTrigger was last updated. - `last_run_time`: corresponds to the last time the JobTrigger ran. - `name`: corresponds to the JobTrigger's name. - `display_name`: corresponds to the JobTrigger's display name. - `status`: corresponds to JobTrigger's status. - * `:pageSize` (*type:* `integer()`) - Size of the page, can be limited by a server. - * `:pageToken` (*type:* `String.t`) - Page token to continue retrieval. Comes from previous call to ListJobTriggers. `order_by` field must not change for subsequent calls. - * `:type` (*type:* `String.t`) - The type of jobs. Will use `DlpJobType.INSPECT` if not set. + * `:body` (*type:* `GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2CreateStoredInfoTypeRequest.t`) - * `opts` (*type:* `keyword()`) - Call options ## Returns - * `{:ok, %GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2ListJobTriggersResponse{}}` on success + * `{:ok, %GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2StoredInfoType{}}` on success * `{:error, info}` on failure """ - @spec dlp_organizations_locations_job_triggers_list( + @spec dlp_organizations_locations_stored_info_types_create( Tesla.Env.client(), String.t(), keyword(), keyword() ) :: - {:ok, GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2ListJobTriggersResponse.t()} + {:ok, GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2StoredInfoType.t()} | {:ok, Tesla.Env.t()} | {:ok, list()} | {:error, any()} - def dlp_organizations_locations_job_triggers_list( + def dlp_organizations_locations_stored_info_types_create( connection, parent, optional_params \\ [], @@ -1858,18 +2682,13 @@ defmodule GoogleApi.DLP.V2.Api.Organizations do :quotaUser => :query, :uploadType => :query, :upload_protocol => :query, - :filter => :query, - :locationId => :query, - :orderBy => :query, - :pageSize => :query, - :pageToken => :query, - :type => :query + :body => :body } request = Request.new() - |> Request.method(:get) - |> Request.url("/v2/{+parent}/jobTriggers", %{ + |> Request.method(:post) + |> Request.url("/v2/{+parent}/storedInfoTypes", %{ "parent" => URI.encode(parent, &URI.char_unreserved?/1) }) |> Request.add_optional_params(optional_params_config, optional_params) @@ -1878,17 +2697,17 @@ defmodule GoogleApi.DLP.V2.Api.Organizations do connection |> Connection.execute(request) |> Response.decode( - opts ++ [struct: %GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2ListJobTriggersResponse{}] + opts ++ [struct: %GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2StoredInfoType{}] ) end @doc """ - Updates a job trigger. See https://cloud.google.com/dlp/docs/creating-job-triggers to learn more. + Deletes a stored infoType. See https://cloud.google.com/sensitive-data-protection/docs/creating-stored-infotypes to learn more. ## Parameters * `connection` (*type:* `GoogleApi.DLP.V2.Connection.t`) - Connection to server - * `name` (*type:* `String.t`) - Required. Resource name of the project and the triggeredJob, for example `projects/dlp-test-project/jobTriggers/53234423`. + * `name` (*type:* `String.t`) - Required. Resource name of the organization and storedInfoType to be deleted, for example `organizations/433245324/storedInfoTypes/432452342` or projects/project-id/storedInfoTypes/432452342. * `optional_params` (*type:* `keyword()`) - Optional parameters * `:"$.xgafv"` (*type:* `String.t`) - V1 error format. * `:access_token` (*type:* `String.t`) - OAuth access token. @@ -1901,25 +2720,24 @@ defmodule GoogleApi.DLP.V2.Api.Organizations do * `:quotaUser` (*type:* `String.t`) - 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. * `:uploadType` (*type:* `String.t`) - Legacy upload protocol for media (e.g. "media", "multipart"). * `:upload_protocol` (*type:* `String.t`) - Upload protocol for media (e.g. "raw", "multipart"). - * `:body` (*type:* `GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2UpdateJobTriggerRequest.t`) - * `opts` (*type:* `keyword()`) - Call options ## Returns - * `{:ok, %GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2JobTrigger{}}` on success + * `{:ok, %GoogleApi.DLP.V2.Model.GoogleProtobufEmpty{}}` on success * `{:error, info}` on failure """ - @spec dlp_organizations_locations_job_triggers_patch( + @spec dlp_organizations_locations_stored_info_types_delete( Tesla.Env.client(), String.t(), keyword(), keyword() ) :: - {:ok, GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2JobTrigger.t()} + {:ok, GoogleApi.DLP.V2.Model.GoogleProtobufEmpty.t()} | {:ok, Tesla.Env.t()} | {:ok, list()} | {:error, any()} - def dlp_organizations_locations_job_triggers_patch( + def dlp_organizations_locations_stored_info_types_delete( connection, name, optional_params \\ [], @@ -1936,13 +2754,12 @@ defmodule GoogleApi.DLP.V2.Api.Organizations do :prettyPrint => :query, :quotaUser => :query, :uploadType => :query, - :upload_protocol => :query, - :body => :body + :upload_protocol => :query } request = Request.new() - |> Request.method(:patch) + |> Request.method(:delete) |> Request.url("/v2/{+name}", %{ "name" => URI.encode(name, &URI.char_unreserved?/1) }) @@ -1951,16 +2768,16 @@ defmodule GoogleApi.DLP.V2.Api.Organizations do connection |> Connection.execute(request) - |> Response.decode(opts ++ [struct: %GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2JobTrigger{}]) + |> Response.decode(opts ++ [struct: %GoogleApi.DLP.V2.Model.GoogleProtobufEmpty{}]) end @doc """ - Creates a pre-built stored infoType to be used for inspection. See https://cloud.google.com/dlp/docs/creating-stored-infotypes to learn more. + Gets a stored infoType. See https://cloud.google.com/sensitive-data-protection/docs/creating-stored-infotypes to learn more. ## Parameters * `connection` (*type:* `GoogleApi.DLP.V2.Connection.t`) - Connection to server - * `parent` (*type:* `String.t`) - Required. Parent resource name. The format of this value varies depending on the scope of the request (project or organization) and whether you have [specified a processing location](https://cloud.google.com/dlp/docs/specifying-location): + Projects scope, location specified: `projects/`PROJECT_ID`/locations/`LOCATION_ID + Projects scope, no location specified (defaults to global): `projects/`PROJECT_ID + Organizations scope, location specified: `organizations/`ORG_ID`/locations/`LOCATION_ID + Organizations scope, no location specified (defaults to global): `organizations/`ORG_ID The following example `parent` string specifies a parent project with the identifier `example-project`, and specifies the `europe-west3` location for processing data: parent=projects/example-project/locations/europe-west3 + * `name` (*type:* `String.t`) - Required. Resource name of the organization and storedInfoType to be read, for example `organizations/433245324/storedInfoTypes/432452342` or projects/project-id/storedInfoTypes/432452342. * `optional_params` (*type:* `keyword()`) - Optional parameters * `:"$.xgafv"` (*type:* `String.t`) - V1 error format. * `:access_token` (*type:* `String.t`) - OAuth access token. @@ -1973,7 +2790,6 @@ defmodule GoogleApi.DLP.V2.Api.Organizations do * `:quotaUser` (*type:* `String.t`) - 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. * `:uploadType` (*type:* `String.t`) - Legacy upload protocol for media (e.g. "media", "multipart"). * `:upload_protocol` (*type:* `String.t`) - Upload protocol for media (e.g. "raw", "multipart"). - * `:body` (*type:* `GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2CreateStoredInfoTypeRequest.t`) - * `opts` (*type:* `keyword()`) - Call options ## Returns @@ -1981,7 +2797,7 @@ defmodule GoogleApi.DLP.V2.Api.Organizations do * `{:ok, %GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2StoredInfoType{}}` on success * `{:error, info}` on failure """ - @spec dlp_organizations_locations_stored_info_types_create( + @spec dlp_organizations_locations_stored_info_types_get( Tesla.Env.client(), String.t(), keyword(), @@ -1991,9 +2807,9 @@ defmodule GoogleApi.DLP.V2.Api.Organizations do | {:ok, Tesla.Env.t()} | {:ok, list()} | {:error, any()} - def dlp_organizations_locations_stored_info_types_create( + def dlp_organizations_locations_stored_info_types_get( connection, - parent, + name, optional_params \\ [], opts \\ [] ) do @@ -2008,15 +2824,14 @@ defmodule GoogleApi.DLP.V2.Api.Organizations do :prettyPrint => :query, :quotaUser => :query, :uploadType => :query, - :upload_protocol => :query, - :body => :body + :upload_protocol => :query } request = Request.new() - |> Request.method(:post) - |> Request.url("/v2/{+parent}/storedInfoTypes", %{ - "parent" => URI.encode(parent, &URI.char_unreserved?/1) + |> Request.method(:get) + |> Request.url("/v2/{+name}", %{ + "name" => URI.encode(name, &URI.char_unreserved?/1) }) |> Request.add_optional_params(optional_params_config, optional_params) |> Request.library_version(@library_version) @@ -2029,12 +2844,12 @@ defmodule GoogleApi.DLP.V2.Api.Organizations do end @doc """ - Deletes a stored infoType. See https://cloud.google.com/dlp/docs/creating-stored-infotypes to learn more. + Lists stored infoTypes. See https://cloud.google.com/sensitive-data-protection/docs/creating-stored-infotypes to learn more. ## Parameters * `connection` (*type:* `GoogleApi.DLP.V2.Connection.t`) - Connection to server - * `name` (*type:* `String.t`) - Required. Resource name of the organization and storedInfoType to be deleted, for example `organizations/433245324/storedInfoTypes/432452342` or projects/project-id/storedInfoTypes/432452342. + * `parent` (*type:* `String.t`) - Required. Parent resource name. The format of this value varies depending on the scope of the request (project or organization) and whether you have [specified a processing location](https://cloud.google.com/sensitive-data-protection/docs/specifying-location): + Projects scope, location specified: `projects/`PROJECT_ID`/locations/`LOCATION_ID + Projects scope, no location specified (defaults to global): `projects/`PROJECT_ID The following example `parent` string specifies a parent project with the identifier `example-project`, and specifies the `europe-west3` location for processing data: parent=projects/example-project/locations/europe-west3 * `optional_params` (*type:* `keyword()`) - Optional parameters * `:"$.xgafv"` (*type:* `String.t`) - V1 error format. * `:access_token` (*type:* `String.t`) - OAuth access token. @@ -2047,26 +2862,30 @@ defmodule GoogleApi.DLP.V2.Api.Organizations do * `:quotaUser` (*type:* `String.t`) - 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. * `:uploadType` (*type:* `String.t`) - Legacy upload protocol for media (e.g. "media", "multipart"). * `:upload_protocol` (*type:* `String.t`) - Upload protocol for media (e.g. "raw", "multipart"). + * `:locationId` (*type:* `String.t`) - Deprecated. This field has no effect. + * `:orderBy` (*type:* `String.t`) - Comma separated list of fields to order by, followed by `asc` or `desc` postfix. This list is case insensitive. The default sorting order is ascending. Redundant space characters are insignificant. Example: `name asc, display_name, create_time desc` Supported fields are: - `create_time`: corresponds to the time the most recent version of the resource was created. - `state`: corresponds to the state of the resource. - `name`: corresponds to resource name. - `display_name`: corresponds to info type's display name. + * `:pageSize` (*type:* `integer()`) - Size of the page. This value can be limited by the server. If zero server returns a page of max size 100. + * `:pageToken` (*type:* `String.t`) - Page token to continue retrieval. Comes from the previous call to `ListStoredInfoTypes`. * `opts` (*type:* `keyword()`) - Call options ## Returns - * `{:ok, %GoogleApi.DLP.V2.Model.GoogleProtobufEmpty{}}` on success + * `{:ok, %GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2ListStoredInfoTypesResponse{}}` on success * `{:error, info}` on failure """ - @spec dlp_organizations_locations_stored_info_types_delete( + @spec dlp_organizations_locations_stored_info_types_list( Tesla.Env.client(), String.t(), keyword(), keyword() ) :: - {:ok, GoogleApi.DLP.V2.Model.GoogleProtobufEmpty.t()} + {:ok, GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2ListStoredInfoTypesResponse.t()} | {:ok, Tesla.Env.t()} | {:ok, list()} | {:error, any()} - def dlp_organizations_locations_stored_info_types_delete( + def dlp_organizations_locations_stored_info_types_list( connection, - name, + parent, optional_params \\ [], opts \\ [] ) do @@ -2081,30 +2900,36 @@ defmodule GoogleApi.DLP.V2.Api.Organizations do :prettyPrint => :query, :quotaUser => :query, :uploadType => :query, - :upload_protocol => :query + :upload_protocol => :query, + :locationId => :query, + :orderBy => :query, + :pageSize => :query, + :pageToken => :query } request = Request.new() - |> Request.method(:delete) - |> Request.url("/v2/{+name}", %{ - "name" => URI.encode(name, &URI.char_unreserved?/1) + |> Request.method(:get) + |> Request.url("/v2/{+parent}/storedInfoTypes", %{ + "parent" => URI.encode(parent, &URI.char_unreserved?/1) }) |> Request.add_optional_params(optional_params_config, optional_params) |> Request.library_version(@library_version) connection |> Connection.execute(request) - |> Response.decode(opts ++ [struct: %GoogleApi.DLP.V2.Model.GoogleProtobufEmpty{}]) + |> Response.decode( + opts ++ [struct: %GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2ListStoredInfoTypesResponse{}] + ) end @doc """ - Gets a stored infoType. See https://cloud.google.com/dlp/docs/creating-stored-infotypes to learn more. + Updates the stored infoType by creating a new version. The existing version will continue to be used until the new version is ready. See https://cloud.google.com/sensitive-data-protection/docs/creating-stored-infotypes to learn more. ## Parameters * `connection` (*type:* `GoogleApi.DLP.V2.Connection.t`) - Connection to server - * `name` (*type:* `String.t`) - Required. Resource name of the organization and storedInfoType to be read, for example `organizations/433245324/storedInfoTypes/432452342` or projects/project-id/storedInfoTypes/432452342. + * `name` (*type:* `String.t`) - Required. Resource name of organization and storedInfoType to be updated, for example `organizations/433245324/storedInfoTypes/432452342` or projects/project-id/storedInfoTypes/432452342. * `optional_params` (*type:* `keyword()`) - Optional parameters * `:"$.xgafv"` (*type:* `String.t`) - V1 error format. * `:access_token` (*type:* `String.t`) - OAuth access token. @@ -2117,6 +2942,7 @@ defmodule GoogleApi.DLP.V2.Api.Organizations do * `:quotaUser` (*type:* `String.t`) - 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. * `:uploadType` (*type:* `String.t`) - Legacy upload protocol for media (e.g. "media", "multipart"). * `:upload_protocol` (*type:* `String.t`) - Upload protocol for media (e.g. "raw", "multipart"). + * `:body` (*type:* `GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2UpdateStoredInfoTypeRequest.t`) - * `opts` (*type:* `keyword()`) - Call options ## Returns @@ -2124,7 +2950,7 @@ defmodule GoogleApi.DLP.V2.Api.Organizations do * `{:ok, %GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2StoredInfoType{}}` on success * `{:error, info}` on failure """ - @spec dlp_organizations_locations_stored_info_types_get( + @spec dlp_organizations_locations_stored_info_types_patch( Tesla.Env.client(), String.t(), keyword(), @@ -2134,7 +2960,7 @@ defmodule GoogleApi.DLP.V2.Api.Organizations do | {:ok, Tesla.Env.t()} | {:ok, list()} | {:error, any()} - def dlp_organizations_locations_stored_info_types_get( + def dlp_organizations_locations_stored_info_types_patch( connection, name, optional_params \\ [], @@ -2151,12 +2977,13 @@ defmodule GoogleApi.DLP.V2.Api.Organizations do :prettyPrint => :query, :quotaUser => :query, :uploadType => :query, - :upload_protocol => :query + :upload_protocol => :query, + :body => :body } request = Request.new() - |> Request.method(:get) + |> Request.method(:patch) |> Request.url("/v2/{+name}", %{ "name" => URI.encode(name, &URI.char_unreserved?/1) }) @@ -2171,12 +2998,12 @@ defmodule GoogleApi.DLP.V2.Api.Organizations do end @doc """ - Lists stored infoTypes. See https://cloud.google.com/dlp/docs/creating-stored-infotypes to learn more. + Gets a table data profile. ## Parameters * `connection` (*type:* `GoogleApi.DLP.V2.Connection.t`) - Connection to server - * `parent` (*type:* `String.t`) - Required. Parent resource name. The format of this value varies depending on the scope of the request (project or organization) and whether you have [specified a processing location](https://cloud.google.com/dlp/docs/specifying-location): + Projects scope, location specified: `projects/`PROJECT_ID`/locations/`LOCATION_ID + Projects scope, no location specified (defaults to global): `projects/`PROJECT_ID The following example `parent` string specifies a parent project with the identifier `example-project`, and specifies the `europe-west3` location for processing data: parent=projects/example-project/locations/europe-west3 + * `name` (*type:* `String.t`) - Required. Resource name, for example `organizations/12345/locations/us/tableDataProfiles/53234423`. * `optional_params` (*type:* `keyword()`) - Optional parameters * `:"$.xgafv"` (*type:* `String.t`) - V1 error format. * `:access_token` (*type:* `String.t`) - OAuth access token. @@ -2189,30 +3016,26 @@ defmodule GoogleApi.DLP.V2.Api.Organizations do * `:quotaUser` (*type:* `String.t`) - 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. * `:uploadType` (*type:* `String.t`) - Legacy upload protocol for media (e.g. "media", "multipart"). * `:upload_protocol` (*type:* `String.t`) - Upload protocol for media (e.g. "raw", "multipart"). - * `:locationId` (*type:* `String.t`) - Deprecated. This field has no effect. - * `:orderBy` (*type:* `String.t`) - Comma separated list of fields to order by, followed by `asc` or `desc` postfix. This list is case-insensitive, default sorting order is ascending, redundant space characters are insignificant. Example: `name asc, display_name, create_time desc` Supported fields are: - `create_time`: corresponds to the time the most recent version of the resource was created. - `state`: corresponds to the state of the resource. - `name`: corresponds to resource name. - `display_name`: corresponds to info type's display name. - * `:pageSize` (*type:* `integer()`) - Size of the page, can be limited by the server. If zero server returns a page of max size 100. - * `:pageToken` (*type:* `String.t`) - Page token to continue retrieval. Comes from previous call to `ListStoredInfoTypes`. * `opts` (*type:* `keyword()`) - Call options ## Returns - * `{:ok, %GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2ListStoredInfoTypesResponse{}}` on success + * `{:ok, %GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2TableDataProfile{}}` on success * `{:error, info}` on failure """ - @spec dlp_organizations_locations_stored_info_types_list( + @spec dlp_organizations_locations_table_data_profiles_get( Tesla.Env.client(), String.t(), keyword(), keyword() ) :: - {:ok, GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2ListStoredInfoTypesResponse.t()} + {:ok, GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2TableDataProfile.t()} | {:ok, Tesla.Env.t()} | {:ok, list()} | {:error, any()} - def dlp_organizations_locations_stored_info_types_list( + def dlp_organizations_locations_table_data_profiles_get( connection, - parent, + name, optional_params \\ [], opts \\ [] ) do @@ -2227,18 +3050,14 @@ defmodule GoogleApi.DLP.V2.Api.Organizations do :prettyPrint => :query, :quotaUser => :query, :uploadType => :query, - :upload_protocol => :query, - :locationId => :query, - :orderBy => :query, - :pageSize => :query, - :pageToken => :query + :upload_protocol => :query } request = Request.new() |> Request.method(:get) - |> Request.url("/v2/{+parent}/storedInfoTypes", %{ - "parent" => URI.encode(parent, &URI.char_unreserved?/1) + |> Request.url("/v2/{+name}", %{ + "name" => URI.encode(name, &URI.char_unreserved?/1) }) |> Request.add_optional_params(optional_params_config, optional_params) |> Request.library_version(@library_version) @@ -2246,17 +3065,17 @@ defmodule GoogleApi.DLP.V2.Api.Organizations do connection |> Connection.execute(request) |> Response.decode( - opts ++ [struct: %GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2ListStoredInfoTypesResponse{}] + opts ++ [struct: %GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2TableDataProfile{}] ) end @doc """ - Updates the stored infoType by creating a new version. The existing version will continue to be used until the new version is ready. See https://cloud.google.com/dlp/docs/creating-stored-infotypes to learn more. + Lists data profiles for an organization. ## Parameters * `connection` (*type:* `GoogleApi.DLP.V2.Connection.t`) - Connection to server - * `name` (*type:* `String.t`) - Required. Resource name of organization and storedInfoType to be updated, for example `organizations/433245324/storedInfoTypes/432452342` or projects/project-id/storedInfoTypes/432452342. + * `parent` (*type:* `String.t`) - Required. Resource name of the organization or project, for example `organizations/433245324/locations/europe` or `projects/project-id/locations/asia`. * `optional_params` (*type:* `keyword()`) - Optional parameters * `:"$.xgafv"` (*type:* `String.t`) - V1 error format. * `:access_token` (*type:* `String.t`) - OAuth access token. @@ -2269,27 +3088,30 @@ defmodule GoogleApi.DLP.V2.Api.Organizations do * `:quotaUser` (*type:* `String.t`) - 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. * `:uploadType` (*type:* `String.t`) - Legacy upload protocol for media (e.g. "media", "multipart"). * `:upload_protocol` (*type:* `String.t`) - Upload protocol for media (e.g. "raw", "multipart"). - * `:body` (*type:* `GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2UpdateStoredInfoTypeRequest.t`) - + * `:filter` (*type:* `String.t`) - Allows filtering. Supported syntax: * Filter expressions are made up of one or more restrictions. * Restrictions can be combined by `AND` or `OR` logical operators. A sequence of restrictions implicitly uses `AND`. * A restriction has the form of `{field} {operator} {value}`. * Supported fields/values: - `project_id` - The GCP project ID. - `dataset_id` - The BigQuery dataset ID. - `table_id` - The ID of the BigQuery table. - `sensitivity_level` - HIGH|MODERATE|LOW - `data_risk_level` - HIGH|MODERATE|LOW - `resource_visibility`: PUBLIC|RESTRICTED - `status_code` - an RPC status code as defined in https://github.com/googleapis/googleapis/blob/master/google/rpc/code.proto * The operator must be `=` or `!=`. Examples: * project_id = 12345 AND status_code = 1 * project_id = 12345 AND sensitivity_level = HIGH * project_id = 12345 AND resource_visibility = PUBLIC The length of this field should be no more than 500 characters. + * `:orderBy` (*type:* `String.t`) - Comma separated list of fields to order by, followed by `asc` or `desc` postfix. This list is case insensitive. The default sorting order is ascending. Redundant space characters are insignificant. Only one order field at a time is allowed. Examples: * `project_id asc` * `table_id` * `sensitivity_level desc` Supported fields are: - `project_id`: The GCP project ID. - `dataset_id`: The ID of a BigQuery dataset. - `table_id`: The ID of a BigQuery table. - `sensitivity_level`: How sensitive the data in a table is, at most. - `data_risk_level`: How much risk is associated with this data. - `profile_last_generated`: When the profile was last updated in epoch seconds. - `last_modified`: The last time the resource was modified. - `resource_visibility`: Visibility restriction for this resource. - `row_count`: Number of rows in this resource. + * `:pageSize` (*type:* `integer()`) - Size of the page. This value can be limited by the server. If zero, server returns a page of max size 100. + * `:pageToken` (*type:* `String.t`) - Page token to continue retrieval. * `opts` (*type:* `keyword()`) - Call options ## Returns - * `{:ok, %GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2StoredInfoType{}}` on success + * `{:ok, %GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2ListTableDataProfilesResponse{}}` on success * `{:error, info}` on failure """ - @spec dlp_organizations_locations_stored_info_types_patch( + @spec dlp_organizations_locations_table_data_profiles_list( Tesla.Env.client(), String.t(), keyword(), keyword() ) :: - {:ok, GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2StoredInfoType.t()} + {:ok, GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2ListTableDataProfilesResponse.t()} | {:ok, Tesla.Env.t()} | {:ok, list()} | {:error, any()} - def dlp_organizations_locations_stored_info_types_patch( + def dlp_organizations_locations_table_data_profiles_list( connection, - name, + parent, optional_params \\ [], opts \\ [] ) do @@ -2305,14 +3127,17 @@ defmodule GoogleApi.DLP.V2.Api.Organizations do :quotaUser => :query, :uploadType => :query, :upload_protocol => :query, - :body => :body + :filter => :query, + :orderBy => :query, + :pageSize => :query, + :pageToken => :query } request = Request.new() - |> Request.method(:patch) - |> Request.url("/v2/{+name}", %{ - "name" => URI.encode(name, &URI.char_unreserved?/1) + |> Request.method(:get) + |> Request.url("/v2/{+parent}/tableDataProfiles", %{ + "parent" => URI.encode(parent, &URI.char_unreserved?/1) }) |> Request.add_optional_params(optional_params_config, optional_params) |> Request.library_version(@library_version) @@ -2320,17 +3145,17 @@ defmodule GoogleApi.DLP.V2.Api.Organizations do connection |> Connection.execute(request) |> Response.decode( - opts ++ [struct: %GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2StoredInfoType{}] + opts ++ [struct: %GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2ListTableDataProfilesResponse{}] ) end @doc """ - Creates a pre-built stored infoType to be used for inspection. See https://cloud.google.com/dlp/docs/creating-stored-infotypes to learn more. + Creates a pre-built stored infoType to be used for inspection. See https://cloud.google.com/sensitive-data-protection/docs/creating-stored-infotypes to learn more. ## Parameters * `connection` (*type:* `GoogleApi.DLP.V2.Connection.t`) - Connection to server - * `parent` (*type:* `String.t`) - Required. Parent resource name. The format of this value varies depending on the scope of the request (project or organization) and whether you have [specified a processing location](https://cloud.google.com/dlp/docs/specifying-location): + Projects scope, location specified: `projects/`PROJECT_ID`/locations/`LOCATION_ID + Projects scope, no location specified (defaults to global): `projects/`PROJECT_ID + Organizations scope, location specified: `organizations/`ORG_ID`/locations/`LOCATION_ID + Organizations scope, no location specified (defaults to global): `organizations/`ORG_ID The following example `parent` string specifies a parent project with the identifier `example-project`, and specifies the `europe-west3` location for processing data: parent=projects/example-project/locations/europe-west3 + * `parent` (*type:* `String.t`) - Required. Parent resource name. The format of this value varies depending on the scope of the request (project or organization) and whether you have [specified a processing location](https://cloud.google.com/sensitive-data-protection/docs/specifying-location): + Projects scope, location specified: `projects/`PROJECT_ID`/locations/`LOCATION_ID + Projects scope, no location specified (defaults to global): `projects/`PROJECT_ID + Organizations scope, location specified: `organizations/`ORG_ID`/locations/`LOCATION_ID + Organizations scope, no location specified (defaults to global): `organizations/`ORG_ID The following example `parent` string specifies a parent project with the identifier `example-project`, and specifies the `europe-west3` location for processing data: parent=projects/example-project/locations/europe-west3 * `optional_params` (*type:* `keyword()`) - Optional parameters * `:"$.xgafv"` (*type:* `String.t`) - V1 error format. * `:access_token` (*type:* `String.t`) - OAuth access token. @@ -2399,7 +3224,7 @@ defmodule GoogleApi.DLP.V2.Api.Organizations do end @doc """ - Deletes a stored infoType. See https://cloud.google.com/dlp/docs/creating-stored-infotypes to learn more. + Deletes a stored infoType. See https://cloud.google.com/sensitive-data-protection/docs/creating-stored-infotypes to learn more. ## Parameters @@ -2469,7 +3294,7 @@ defmodule GoogleApi.DLP.V2.Api.Organizations do end @doc """ - Gets a stored infoType. See https://cloud.google.com/dlp/docs/creating-stored-infotypes to learn more. + Gets a stored infoType. See https://cloud.google.com/sensitive-data-protection/docs/creating-stored-infotypes to learn more. ## Parameters @@ -2536,12 +3361,12 @@ defmodule GoogleApi.DLP.V2.Api.Organizations do end @doc """ - Lists stored infoTypes. See https://cloud.google.com/dlp/docs/creating-stored-infotypes to learn more. + Lists stored infoTypes. See https://cloud.google.com/sensitive-data-protection/docs/creating-stored-infotypes to learn more. ## Parameters * `connection` (*type:* `GoogleApi.DLP.V2.Connection.t`) - Connection to server - * `parent` (*type:* `String.t`) - Required. Parent resource name. The format of this value varies depending on the scope of the request (project or organization) and whether you have [specified a processing location](https://cloud.google.com/dlp/docs/specifying-location): + Projects scope, location specified: `projects/`PROJECT_ID`/locations/`LOCATION_ID + Projects scope, no location specified (defaults to global): `projects/`PROJECT_ID The following example `parent` string specifies a parent project with the identifier `example-project`, and specifies the `europe-west3` location for processing data: parent=projects/example-project/locations/europe-west3 + * `parent` (*type:* `String.t`) - Required. Parent resource name. The format of this value varies depending on the scope of the request (project or organization) and whether you have [specified a processing location](https://cloud.google.com/sensitive-data-protection/docs/specifying-location): + Projects scope, location specified: `projects/`PROJECT_ID`/locations/`LOCATION_ID + Projects scope, no location specified (defaults to global): `projects/`PROJECT_ID The following example `parent` string specifies a parent project with the identifier `example-project`, and specifies the `europe-west3` location for processing data: parent=projects/example-project/locations/europe-west3 * `optional_params` (*type:* `keyword()`) - Optional parameters * `:"$.xgafv"` (*type:* `String.t`) - V1 error format. * `:access_token` (*type:* `String.t`) - OAuth access token. @@ -2555,9 +3380,9 @@ defmodule GoogleApi.DLP.V2.Api.Organizations do * `:uploadType` (*type:* `String.t`) - Legacy upload protocol for media (e.g. "media", "multipart"). * `:upload_protocol` (*type:* `String.t`) - Upload protocol for media (e.g. "raw", "multipart"). * `:locationId` (*type:* `String.t`) - Deprecated. This field has no effect. - * `:orderBy` (*type:* `String.t`) - Comma separated list of fields to order by, followed by `asc` or `desc` postfix. This list is case-insensitive, default sorting order is ascending, redundant space characters are insignificant. Example: `name asc, display_name, create_time desc` Supported fields are: - `create_time`: corresponds to the time the most recent version of the resource was created. - `state`: corresponds to the state of the resource. - `name`: corresponds to resource name. - `display_name`: corresponds to info type's display name. - * `:pageSize` (*type:* `integer()`) - Size of the page, can be limited by the server. If zero server returns a page of max size 100. - * `:pageToken` (*type:* `String.t`) - Page token to continue retrieval. Comes from previous call to `ListStoredInfoTypes`. + * `:orderBy` (*type:* `String.t`) - Comma separated list of fields to order by, followed by `asc` or `desc` postfix. This list is case insensitive. The default sorting order is ascending. Redundant space characters are insignificant. Example: `name asc, display_name, create_time desc` Supported fields are: - `create_time`: corresponds to the time the most recent version of the resource was created. - `state`: corresponds to the state of the resource. - `name`: corresponds to resource name. - `display_name`: corresponds to info type's display name. + * `:pageSize` (*type:* `integer()`) - Size of the page. This value can be limited by the server. If zero server returns a page of max size 100. + * `:pageToken` (*type:* `String.t`) - Page token to continue retrieval. Comes from the previous call to `ListStoredInfoTypes`. * `opts` (*type:* `keyword()`) - Call options ## Returns @@ -2616,7 +3441,7 @@ defmodule GoogleApi.DLP.V2.Api.Organizations do end @doc """ - Updates the stored infoType by creating a new version. The existing version will continue to be used until the new version is ready. See https://cloud.google.com/dlp/docs/creating-stored-infotypes to learn more. + Updates the stored infoType by creating a new version. The existing version will continue to be used until the new version is ready. See https://cloud.google.com/sensitive-data-protection/docs/creating-stored-infotypes to learn more. ## Parameters diff --git a/clients/dlp/lib/google_api/dlp/v2/api/projects.ex b/clients/dlp/lib/google_api/dlp/v2/api/projects.ex index 0663abcb9f..a702d0da8d 100644 --- a/clients/dlp/lib/google_api/dlp/v2/api/projects.ex +++ b/clients/dlp/lib/google_api/dlp/v2/api/projects.ex @@ -26,12 +26,12 @@ defmodule GoogleApi.DLP.V2.Api.Projects do @library_version Mix.Project.config() |> Keyword.get(:version, "") @doc """ - De-identifies potentially sensitive info from a ContentItem. This method has limits on input size and output size. See https://cloud.google.com/dlp/docs/deidentify-sensitive-data to learn more. When no InfoTypes or CustomInfoTypes are specified in this request, the system will automatically choose what detectors to run. By default this may be all types, but may change over time as detectors are updated. + De-identifies potentially sensitive info from a ContentItem. This method has limits on input size and output size. See https://cloud.google.com/sensitive-data-protection/docs/deidentify-sensitive-data to learn more. When no InfoTypes or CustomInfoTypes are specified in this request, the system will automatically choose what detectors to run. By default this may be all types, but may change over time as detectors are updated. ## Parameters * `connection` (*type:* `GoogleApi.DLP.V2.Connection.t`) - Connection to server - * `parent` (*type:* `String.t`) - Parent resource name. The format of this value varies depending on whether you have [specified a processing location](https://cloud.google.com/dlp/docs/specifying-location): + Projects scope, location specified: `projects/`PROJECT_ID`/locations/`LOCATION_ID + Projects scope, no location specified (defaults to global): `projects/`PROJECT_ID The following example `parent` string specifies a parent project with the identifier `example-project`, and specifies the `europe-west3` location for processing data: parent=projects/example-project/locations/europe-west3 + * `parent` (*type:* `String.t`) - Parent resource name. The format of this value varies depending on whether you have [specified a processing location](https://cloud.google.com/sensitive-data-protection/docs/specifying-location): + Projects scope, location specified: `projects/`PROJECT_ID`/locations/`LOCATION_ID + Projects scope, no location specified (defaults to global): `projects/`PROJECT_ID The following example `parent` string specifies a parent project with the identifier `example-project`, and specifies the `europe-west3` location for processing data: parent=projects/example-project/locations/europe-west3 * `optional_params` (*type:* `keyword()`) - Optional parameters * `:"$.xgafv"` (*type:* `String.t`) - V1 error format. * `:access_token` (*type:* `String.t`) - OAuth access token. @@ -90,12 +90,12 @@ defmodule GoogleApi.DLP.V2.Api.Projects do end @doc """ - Finds potentially sensitive info in content. This method has limits on input size, processing time, and output size. When no InfoTypes or CustomInfoTypes are specified in this request, the system will automatically choose what detectors to run. By default this may be all types, but may change over time as detectors are updated. For how to guides, see https://cloud.google.com/dlp/docs/inspecting-images and https://cloud.google.com/dlp/docs/inspecting-text, + Finds potentially sensitive info in content. This method has limits on input size, processing time, and output size. When no InfoTypes or CustomInfoTypes are specified in this request, the system will automatically choose what detectors to run. By default this may be all types, but may change over time as detectors are updated. For how to guides, see https://cloud.google.com/sensitive-data-protection/docs/inspecting-images and https://cloud.google.com/sensitive-data-protection/docs/inspecting-text, ## Parameters * `connection` (*type:* `GoogleApi.DLP.V2.Connection.t`) - Connection to server - * `parent` (*type:* `String.t`) - Parent resource name. The format of this value varies depending on whether you have [specified a processing location](https://cloud.google.com/dlp/docs/specifying-location): + Projects scope, location specified: `projects/`PROJECT_ID`/locations/`LOCATION_ID + Projects scope, no location specified (defaults to global): `projects/`PROJECT_ID The following example `parent` string specifies a parent project with the identifier `example-project`, and specifies the `europe-west3` location for processing data: parent=projects/example-project/locations/europe-west3 + * `parent` (*type:* `String.t`) - Parent resource name. The format of this value varies depending on whether you have [specified a processing location](https://cloud.google.com/sensitive-data-protection/docs/specifying-location): + Projects scope, location specified: `projects/`PROJECT_ID`/locations/`LOCATION_ID + Projects scope, no location specified (defaults to global): `projects/`PROJECT_ID The following example `parent` string specifies a parent project with the identifier `example-project`, and specifies the `europe-west3` location for processing data: parent=projects/example-project/locations/europe-west3 * `optional_params` (*type:* `keyword()`) - Optional parameters * `:"$.xgafv"` (*type:* `String.t`) - V1 error format. * `:access_token` (*type:* `String.t`) - OAuth access token. @@ -154,12 +154,12 @@ defmodule GoogleApi.DLP.V2.Api.Projects do end @doc """ - Re-identifies content that has been de-identified. See https://cloud.google.com/dlp/docs/pseudonymization#re-identification_in_free_text_code_example to learn more. + Re-identifies content that has been de-identified. See https://cloud.google.com/sensitive-data-protection/docs/pseudonymization#re-identification_in_free_text_code_example to learn more. ## Parameters * `connection` (*type:* `GoogleApi.DLP.V2.Connection.t`) - Connection to server - * `parent` (*type:* `String.t`) - Required. Parent resource name. The format of this value varies depending on whether you have [specified a processing location](https://cloud.google.com/dlp/docs/specifying-location): + Projects scope, location specified: `projects/`PROJECT_ID`/locations/`LOCATION_ID + Projects scope, no location specified (defaults to global): `projects/`PROJECT_ID The following example `parent` string specifies a parent project with the identifier `example-project`, and specifies the `europe-west3` location for processing data: parent=projects/example-project/locations/europe-west3 + * `parent` (*type:* `String.t`) - Required. Parent resource name. The format of this value varies depending on whether you have [specified a processing location](https://cloud.google.com/sensitive-data-protection/docs/specifying-location): + Projects scope, location specified: `projects/`PROJECT_ID`/locations/`LOCATION_ID + Projects scope, no location specified (defaults to global): `projects/`PROJECT_ID The following example `parent` string specifies a parent project with the identifier `example-project`, and specifies the `europe-west3` location for processing data: parent=projects/example-project/locations/europe-west3 * `optional_params` (*type:* `keyword()`) - Optional parameters * `:"$.xgafv"` (*type:* `String.t`) - V1 error format. * `:access_token` (*type:* `String.t`) - OAuth access token. @@ -218,12 +218,12 @@ defmodule GoogleApi.DLP.V2.Api.Projects do end @doc """ - Creates a DeidentifyTemplate for reusing frequently used configuration for de-identifying content, images, and storage. See https://cloud.google.com/dlp/docs/creating-templates-deid to learn more. + Creates a DeidentifyTemplate for reusing frequently used configuration for de-identifying content, images, and storage. See https://cloud.google.com/sensitive-data-protection/docs/creating-templates-deid to learn more. ## Parameters * `connection` (*type:* `GoogleApi.DLP.V2.Connection.t`) - Connection to server - * `parent` (*type:* `String.t`) - Required. Parent resource name. The format of this value varies depending on the scope of the request (project or organization) and whether you have [specified a processing location](https://cloud.google.com/dlp/docs/specifying-location): + Projects scope, location specified: `projects/`PROJECT_ID`/locations/`LOCATION_ID + Projects scope, no location specified (defaults to global): `projects/`PROJECT_ID + Organizations scope, location specified: `organizations/`ORG_ID`/locations/`LOCATION_ID + Organizations scope, no location specified (defaults to global): `organizations/`ORG_ID The following example `parent` string specifies a parent project with the identifier `example-project`, and specifies the `europe-west3` location for processing data: parent=projects/example-project/locations/europe-west3 + * `parent` (*type:* `String.t`) - Required. Parent resource name. The format of this value varies depending on the scope of the request (project or organization) and whether you have [specified a processing location](https://cloud.google.com/sensitive-data-protection/docs/specifying-location): + Projects scope, location specified: `projects/`PROJECT_ID`/locations/`LOCATION_ID + Projects scope, no location specified (defaults to global): `projects/`PROJECT_ID + Organizations scope, location specified: `organizations/`ORG_ID`/locations/`LOCATION_ID + Organizations scope, no location specified (defaults to global): `organizations/`ORG_ID The following example `parent` string specifies a parent project with the identifier `example-project`, and specifies the `europe-west3` location for processing data: parent=projects/example-project/locations/europe-west3 * `optional_params` (*type:* `keyword()`) - Optional parameters * `:"$.xgafv"` (*type:* `String.t`) - V1 error format. * `:access_token` (*type:* `String.t`) - OAuth access token. @@ -292,7 +292,7 @@ defmodule GoogleApi.DLP.V2.Api.Projects do end @doc """ - Deletes a DeidentifyTemplate. See https://cloud.google.com/dlp/docs/creating-templates-deid to learn more. + Deletes a DeidentifyTemplate. See https://cloud.google.com/sensitive-data-protection/docs/creating-templates-deid to learn more. ## Parameters @@ -362,7 +362,7 @@ defmodule GoogleApi.DLP.V2.Api.Projects do end @doc """ - Gets a DeidentifyTemplate. See https://cloud.google.com/dlp/docs/creating-templates-deid to learn more. + Gets a DeidentifyTemplate. See https://cloud.google.com/sensitive-data-protection/docs/creating-templates-deid to learn more. ## Parameters @@ -429,12 +429,12 @@ defmodule GoogleApi.DLP.V2.Api.Projects do end @doc """ - Lists DeidentifyTemplates. See https://cloud.google.com/dlp/docs/creating-templates-deid to learn more. + Lists DeidentifyTemplates. See https://cloud.google.com/sensitive-data-protection/docs/creating-templates-deid to learn more. ## Parameters * `connection` (*type:* `GoogleApi.DLP.V2.Connection.t`) - Connection to server - * `parent` (*type:* `String.t`) - Required. Parent resource name. The format of this value varies depending on the scope of the request (project or organization) and whether you have [specified a processing location](https://cloud.google.com/dlp/docs/specifying-location): + Projects scope, location specified: `projects/`PROJECT_ID`/locations/`LOCATION_ID + Projects scope, no location specified (defaults to global): `projects/`PROJECT_ID + Organizations scope, location specified: `organizations/`ORG_ID`/locations/`LOCATION_ID + Organizations scope, no location specified (defaults to global): `organizations/`ORG_ID The following example `parent` string specifies a parent project with the identifier `example-project`, and specifies the `europe-west3` location for processing data: parent=projects/example-project/locations/europe-west3 + * `parent` (*type:* `String.t`) - Required. Parent resource name. The format of this value varies depending on the scope of the request (project or organization) and whether you have [specified a processing location](https://cloud.google.com/sensitive-data-protection/docs/specifying-location): + Projects scope, location specified: `projects/`PROJECT_ID`/locations/`LOCATION_ID + Projects scope, no location specified (defaults to global): `projects/`PROJECT_ID + Organizations scope, location specified: `organizations/`ORG_ID`/locations/`LOCATION_ID + Organizations scope, no location specified (defaults to global): `organizations/`ORG_ID The following example `parent` string specifies a parent project with the identifier `example-project`, and specifies the `europe-west3` location for processing data: parent=projects/example-project/locations/europe-west3 * `optional_params` (*type:* `keyword()`) - Optional parameters * `:"$.xgafv"` (*type:* `String.t`) - V1 error format. * `:access_token` (*type:* `String.t`) - OAuth access token. @@ -448,9 +448,9 @@ defmodule GoogleApi.DLP.V2.Api.Projects do * `:uploadType` (*type:* `String.t`) - Legacy upload protocol for media (e.g. "media", "multipart"). * `:upload_protocol` (*type:* `String.t`) - Upload protocol for media (e.g. "raw", "multipart"). * `:locationId` (*type:* `String.t`) - Deprecated. This field has no effect. - * `:orderBy` (*type:* `String.t`) - Comma separated list of fields to order by, followed by `asc` or `desc` postfix. This list is case-insensitive, default sorting order is ascending, redundant space characters are insignificant. Example: `name asc,update_time, create_time desc` Supported fields are: - `create_time`: corresponds to the time the template was created. - `update_time`: corresponds to the time the template was last updated. - `name`: corresponds to the template's name. - `display_name`: corresponds to the template's display name. - * `:pageSize` (*type:* `integer()`) - Size of the page, can be limited by the server. If zero server returns a page of max size 100. - * `:pageToken` (*type:* `String.t`) - Page token to continue retrieval. Comes from previous call to `ListDeidentifyTemplates`. + * `:orderBy` (*type:* `String.t`) - Comma separated list of fields to order by, followed by `asc` or `desc` postfix. This list is case insensitive. The default sorting order is ascending. Redundant space characters are insignificant. Example: `name asc,update_time, create_time desc` Supported fields are: - `create_time`: corresponds to the time the template was created. - `update_time`: corresponds to the time the template was last updated. - `name`: corresponds to the template's name. - `display_name`: corresponds to the template's display name. + * `:pageSize` (*type:* `integer()`) - Size of the page. This value can be limited by the server. If zero server returns a page of max size 100. + * `:pageToken` (*type:* `String.t`) - Page token to continue retrieval. Comes from the previous call to `ListDeidentifyTemplates`. * `opts` (*type:* `keyword()`) - Call options ## Returns @@ -510,7 +510,7 @@ defmodule GoogleApi.DLP.V2.Api.Projects do end @doc """ - Updates the DeidentifyTemplate. See https://cloud.google.com/dlp/docs/creating-templates-deid to learn more. + Updates the DeidentifyTemplate. See https://cloud.google.com/sensitive-data-protection/docs/creating-templates-deid to learn more. ## Parameters @@ -579,7 +579,7 @@ defmodule GoogleApi.DLP.V2.Api.Projects do end @doc """ - Starts asynchronous cancellation on a long-running DlpJob. The server makes a best effort to cancel the DlpJob, but success is not guaranteed. See https://cloud.google.com/dlp/docs/inspecting-storage and https://cloud.google.com/dlp/docs/compute-risk-analysis to learn more. + Starts asynchronous cancellation on a long-running DlpJob. The server makes a best effort to cancel the DlpJob, but success is not guaranteed. See https://cloud.google.com/sensitive-data-protection/docs/inspecting-storage and https://cloud.google.com/sensitive-data-protection/docs/compute-risk-analysis to learn more. ## Parameters @@ -641,12 +641,12 @@ defmodule GoogleApi.DLP.V2.Api.Projects do end @doc """ - Creates a new job to inspect storage or calculate risk metrics. See https://cloud.google.com/dlp/docs/inspecting-storage and https://cloud.google.com/dlp/docs/compute-risk-analysis to learn more. When no InfoTypes or CustomInfoTypes are specified in inspect jobs, the system will automatically choose what detectors to run. By default this may be all types, but may change over time as detectors are updated. + Creates a new job to inspect storage or calculate risk metrics. See https://cloud.google.com/sensitive-data-protection/docs/inspecting-storage and https://cloud.google.com/sensitive-data-protection/docs/compute-risk-analysis to learn more. When no InfoTypes or CustomInfoTypes are specified in inspect jobs, the system will automatically choose what detectors to run. By default this may be all types, but may change over time as detectors are updated. ## Parameters * `connection` (*type:* `GoogleApi.DLP.V2.Connection.t`) - Connection to server - * `parent` (*type:* `String.t`) - Required. Parent resource name. The format of this value varies depending on whether you have [specified a processing location](https://cloud.google.com/dlp/docs/specifying-location): + Projects scope, location specified: `projects/`PROJECT_ID`/locations/`LOCATION_ID + Projects scope, no location specified (defaults to global): `projects/`PROJECT_ID The following example `parent` string specifies a parent project with the identifier `example-project`, and specifies the `europe-west3` location for processing data: parent=projects/example-project/locations/europe-west3 + * `parent` (*type:* `String.t`) - Required. Parent resource name. The format of this value varies depending on whether you have [specified a processing location](https://cloud.google.com/sensitive-data-protection/docs/specifying-location): + Projects scope, location specified: `projects/`PROJECT_ID`/locations/`LOCATION_ID + Projects scope, no location specified (defaults to global): `projects/`PROJECT_ID The following example `parent` string specifies a parent project with the identifier `example-project`, and specifies the `europe-west3` location for processing data: parent=projects/example-project/locations/europe-west3 * `optional_params` (*type:* `keyword()`) - Optional parameters * `:"$.xgafv"` (*type:* `String.t`) - V1 error format. * `:access_token` (*type:* `String.t`) - OAuth access token. @@ -703,7 +703,7 @@ defmodule GoogleApi.DLP.V2.Api.Projects do end @doc """ - Deletes a long-running DlpJob. This method indicates that the client is no longer interested in the DlpJob result. The job will be canceled if possible. See https://cloud.google.com/dlp/docs/inspecting-storage and https://cloud.google.com/dlp/docs/compute-risk-analysis to learn more. + Deletes a long-running DlpJob. This method indicates that the client is no longer interested in the DlpJob result. The job will be canceled if possible. See https://cloud.google.com/sensitive-data-protection/docs/inspecting-storage and https://cloud.google.com/sensitive-data-protection/docs/compute-risk-analysis to learn more. ## Parameters @@ -763,7 +763,7 @@ defmodule GoogleApi.DLP.V2.Api.Projects do end @doc """ - Gets the latest state of a long-running DlpJob. See https://cloud.google.com/dlp/docs/inspecting-storage and https://cloud.google.com/dlp/docs/compute-risk-analysis to learn more. + Gets the latest state of a long-running DlpJob. See https://cloud.google.com/sensitive-data-protection/docs/inspecting-storage and https://cloud.google.com/sensitive-data-protection/docs/compute-risk-analysis to learn more. ## Parameters @@ -823,12 +823,12 @@ defmodule GoogleApi.DLP.V2.Api.Projects do end @doc """ - Lists DlpJobs that match the specified filter in the request. See https://cloud.google.com/dlp/docs/inspecting-storage and https://cloud.google.com/dlp/docs/compute-risk-analysis to learn more. + Lists DlpJobs that match the specified filter in the request. See https://cloud.google.com/sensitive-data-protection/docs/inspecting-storage and https://cloud.google.com/sensitive-data-protection/docs/compute-risk-analysis to learn more. ## Parameters * `connection` (*type:* `GoogleApi.DLP.V2.Connection.t`) - Connection to server - * `parent` (*type:* `String.t`) - Required. Parent resource name. The format of this value varies depending on whether you have [specified a processing location](https://cloud.google.com/dlp/docs/specifying-location): + Projects scope, location specified: `projects/`PROJECT_ID`/locations/`LOCATION_ID + Projects scope, no location specified (defaults to global): `projects/`PROJECT_ID The following example `parent` string specifies a parent project with the identifier `example-project`, and specifies the `europe-west3` location for processing data: parent=projects/example-project/locations/europe-west3 + * `parent` (*type:* `String.t`) - Required. Parent resource name. The format of this value varies depending on whether you have [specified a processing location](https://cloud.google.com/sensitive-data-protection/docs/specifying-location): + Projects scope, location specified: `projects/`PROJECT_ID`/locations/`LOCATION_ID + Projects scope, no location specified (defaults to global): `projects/`PROJECT_ID The following example `parent` string specifies a parent project with the identifier `example-project`, and specifies the `europe-west3` location for processing data: parent=projects/example-project/locations/europe-west3 * `optional_params` (*type:* `keyword()`) - Optional parameters * `:"$.xgafv"` (*type:* `String.t`) - V1 error format. * `:access_token` (*type:* `String.t`) - OAuth access token. @@ -843,7 +843,7 @@ defmodule GoogleApi.DLP.V2.Api.Projects do * `:upload_protocol` (*type:* `String.t`) - Upload protocol for media (e.g. "raw", "multipart"). * `:filter` (*type:* `String.t`) - Allows filtering. Supported syntax: * Filter expressions are made up of one or more restrictions. * Restrictions can be combined by `AND` or `OR` logical operators. A sequence of restrictions implicitly uses `AND`. * A restriction has the form of `{field} {operator} {value}`. * Supported fields/values for inspect jobs: - `state` - PENDING|RUNNING|CANCELED|FINISHED|FAILED - `inspected_storage` - DATASTORE|CLOUD_STORAGE|BIGQUERY - `trigger_name` - The name of the trigger that created the job. - 'end_time` - Corresponds to the time the job finished. - 'start_time` - Corresponds to the time the job finished. * Supported fields for risk analysis jobs: - `state` - RUNNING|CANCELED|FINISHED|FAILED - 'end_time` - Corresponds to the time the job finished. - 'start_time` - Corresponds to the time the job finished. * The operator must be `=` or `!=`. Examples: * inspected_storage = cloud_storage AND state = done * inspected_storage = cloud_storage OR inspected_storage = bigquery * inspected_storage = cloud_storage AND (state = done OR state = canceled) * end_time > \\"2017-12-12T00:00:00+00:00\\" The length of this field should be no more than 500 characters. * `:locationId` (*type:* `String.t`) - Deprecated. This field has no effect. - * `:orderBy` (*type:* `String.t`) - Comma separated list of fields to order by, followed by `asc` or `desc` postfix. This list is case-insensitive, default sorting order is ascending, redundant space characters are insignificant. Example: `name asc, end_time asc, create_time desc` Supported fields are: - `create_time`: corresponds to the time the job was created. - `end_time`: corresponds to the time the job ended. - `name`: corresponds to the job's name. - `state`: corresponds to `state` + * `:orderBy` (*type:* `String.t`) - Comma separated list of fields to order by, followed by `asc` or `desc` postfix. This list is case insensitive. The default sorting order is ascending. Redundant space characters are insignificant. Example: `name asc, end_time asc, create_time desc` Supported fields are: - `create_time`: corresponds to the time the job was created. - `end_time`: corresponds to the time the job ended. - `name`: corresponds to the job's name. - `state`: corresponds to `state` * `:pageSize` (*type:* `integer()`) - The standard list page size. * `:pageToken` (*type:* `String.t`) - The standard list page token. * `:type` (*type:* `String.t`) - The type of job. Defaults to `DlpJobType.INSPECT` @@ -897,12 +897,12 @@ defmodule GoogleApi.DLP.V2.Api.Projects do end @doc """ - Redacts potentially sensitive info from an image. This method has limits on input size, processing time, and output size. See https://cloud.google.com/dlp/docs/redacting-sensitive-data-images to learn more. When no InfoTypes or CustomInfoTypes are specified in this request, the system will automatically choose what detectors to run. By default this may be all types, but may change over time as detectors are updated. + Redacts potentially sensitive info from an image. This method has limits on input size, processing time, and output size. See https://cloud.google.com/sensitive-data-protection/docs/redacting-sensitive-data-images to learn more. When no InfoTypes or CustomInfoTypes are specified in this request, the system will automatically choose what detectors to run. By default this may be all types, but may change over time as detectors are updated. ## Parameters * `connection` (*type:* `GoogleApi.DLP.V2.Connection.t`) - Connection to server - * `parent` (*type:* `String.t`) - Parent resource name. The format of this value varies depending on whether you have [specified a processing location](https://cloud.google.com/dlp/docs/specifying-location): + Projects scope, location specified: `projects/`PROJECT_ID`/locations/`LOCATION_ID + Projects scope, no location specified (defaults to global): `projects/`PROJECT_ID The following example `parent` string specifies a parent project with the identifier `example-project`, and specifies the `europe-west3` location for processing data: parent=projects/example-project/locations/europe-west3 + * `parent` (*type:* `String.t`) - Parent resource name. The format of this value varies depending on whether you have [specified a processing location](https://cloud.google.com/sensitive-data-protection/docs/specifying-location): + Projects scope, location specified: `projects/`PROJECT_ID`/locations/`LOCATION_ID + Projects scope, no location specified (defaults to global): `projects/`PROJECT_ID The following example `parent` string specifies a parent project with the identifier `example-project`, and specifies the `europe-west3` location for processing data: parent=projects/example-project/locations/europe-west3 * `optional_params` (*type:* `keyword()`) - Optional parameters * `:"$.xgafv"` (*type:* `String.t`) - V1 error format. * `:access_token` (*type:* `String.t`) - OAuth access token. @@ -961,12 +961,12 @@ defmodule GoogleApi.DLP.V2.Api.Projects do end @doc """ - Creates an InspectTemplate for reusing frequently used configuration for inspecting content, images, and storage. See https://cloud.google.com/dlp/docs/creating-templates to learn more. + Creates an InspectTemplate for reusing frequently used configuration for inspecting content, images, and storage. See https://cloud.google.com/sensitive-data-protection/docs/creating-templates to learn more. ## Parameters * `connection` (*type:* `GoogleApi.DLP.V2.Connection.t`) - Connection to server - * `parent` (*type:* `String.t`) - Required. Parent resource name. The format of this value varies depending on the scope of the request (project or organization) and whether you have [specified a processing location](https://cloud.google.com/dlp/docs/specifying-location): + Projects scope, location specified: `projects/`PROJECT_ID`/locations/`LOCATION_ID + Projects scope, no location specified (defaults to global): `projects/`PROJECT_ID + Organizations scope, location specified: `organizations/`ORG_ID`/locations/`LOCATION_ID + Organizations scope, no location specified (defaults to global): `organizations/`ORG_ID The following example `parent` string specifies a parent project with the identifier `example-project`, and specifies the `europe-west3` location for processing data: parent=projects/example-project/locations/europe-west3 + * `parent` (*type:* `String.t`) - Required. Parent resource name. The format of this value varies depending on the scope of the request (project or organization) and whether you have [specified a processing location](https://cloud.google.com/sensitive-data-protection/docs/specifying-location): + Projects scope, location specified: `projects/`PROJECT_ID`/locations/`LOCATION_ID + Projects scope, no location specified (defaults to global): `projects/`PROJECT_ID + Organizations scope, location specified: `organizations/`ORG_ID`/locations/`LOCATION_ID + Organizations scope, no location specified (defaults to global): `organizations/`ORG_ID The following example `parent` string specifies a parent project with the identifier `example-project`, and specifies the `europe-west3` location for processing data: parent=projects/example-project/locations/europe-west3 * `optional_params` (*type:* `keyword()`) - Optional parameters * `:"$.xgafv"` (*type:* `String.t`) - V1 error format. * `:access_token` (*type:* `String.t`) - OAuth access token. @@ -1030,7 +1030,7 @@ defmodule GoogleApi.DLP.V2.Api.Projects do end @doc """ - Deletes an InspectTemplate. See https://cloud.google.com/dlp/docs/creating-templates to learn more. + Deletes an InspectTemplate. See https://cloud.google.com/sensitive-data-protection/docs/creating-templates to learn more. ## Parameters @@ -1095,7 +1095,7 @@ defmodule GoogleApi.DLP.V2.Api.Projects do end @doc """ - Gets an InspectTemplate. See https://cloud.google.com/dlp/docs/creating-templates to learn more. + Gets an InspectTemplate. See https://cloud.google.com/sensitive-data-protection/docs/creating-templates to learn more. ## Parameters @@ -1157,12 +1157,12 @@ defmodule GoogleApi.DLP.V2.Api.Projects do end @doc """ - Lists InspectTemplates. See https://cloud.google.com/dlp/docs/creating-templates to learn more. + Lists InspectTemplates. See https://cloud.google.com/sensitive-data-protection/docs/creating-templates to learn more. ## Parameters * `connection` (*type:* `GoogleApi.DLP.V2.Connection.t`) - Connection to server - * `parent` (*type:* `String.t`) - Required. Parent resource name. The format of this value varies depending on the scope of the request (project or organization) and whether you have [specified a processing location](https://cloud.google.com/dlp/docs/specifying-location): + Projects scope, location specified: `projects/`PROJECT_ID`/locations/`LOCATION_ID + Projects scope, no location specified (defaults to global): `projects/`PROJECT_ID + Organizations scope, location specified: `organizations/`ORG_ID`/locations/`LOCATION_ID + Organizations scope, no location specified (defaults to global): `organizations/`ORG_ID The following example `parent` string specifies a parent project with the identifier `example-project`, and specifies the `europe-west3` location for processing data: parent=projects/example-project/locations/europe-west3 + * `parent` (*type:* `String.t`) - Required. Parent resource name. The format of this value varies depending on the scope of the request (project or organization) and whether you have [specified a processing location](https://cloud.google.com/sensitive-data-protection/docs/specifying-location): + Projects scope, location specified: `projects/`PROJECT_ID`/locations/`LOCATION_ID + Projects scope, no location specified (defaults to global): `projects/`PROJECT_ID + Organizations scope, location specified: `organizations/`ORG_ID`/locations/`LOCATION_ID + Organizations scope, no location specified (defaults to global): `organizations/`ORG_ID The following example `parent` string specifies a parent project with the identifier `example-project`, and specifies the `europe-west3` location for processing data: parent=projects/example-project/locations/europe-west3 * `optional_params` (*type:* `keyword()`) - Optional parameters * `:"$.xgafv"` (*type:* `String.t`) - V1 error format. * `:access_token` (*type:* `String.t`) - OAuth access token. @@ -1176,9 +1176,9 @@ defmodule GoogleApi.DLP.V2.Api.Projects do * `:uploadType` (*type:* `String.t`) - Legacy upload protocol for media (e.g. "media", "multipart"). * `:upload_protocol` (*type:* `String.t`) - Upload protocol for media (e.g. "raw", "multipart"). * `:locationId` (*type:* `String.t`) - Deprecated. This field has no effect. - * `:orderBy` (*type:* `String.t`) - Comma separated list of fields to order by, followed by `asc` or `desc` postfix. This list is case-insensitive, default sorting order is ascending, redundant space characters are insignificant. Example: `name asc,update_time, create_time desc` Supported fields are: - `create_time`: corresponds to the time the template was created. - `update_time`: corresponds to the time the template was last updated. - `name`: corresponds to the template's name. - `display_name`: corresponds to the template's display name. - * `:pageSize` (*type:* `integer()`) - Size of the page, can be limited by the server. If zero server returns a page of max size 100. - * `:pageToken` (*type:* `String.t`) - Page token to continue retrieval. Comes from previous call to `ListInspectTemplates`. + * `:orderBy` (*type:* `String.t`) - Comma separated list of fields to order by, followed by `asc` or `desc` postfix. This list is case insensitive. The default sorting order is ascending. Redundant space characters are insignificant. Example: `name asc,update_time, create_time desc` Supported fields are: - `create_time`: corresponds to the time the template was created. - `update_time`: corresponds to the time the template was last updated. - `name`: corresponds to the template's name. - `display_name`: corresponds to the template's display name. + * `:pageSize` (*type:* `integer()`) - Size of the page. This value can be limited by the server. If zero server returns a page of max size 100. + * `:pageToken` (*type:* `String.t`) - Page token to continue retrieval. Comes from the previous call to `ListInspectTemplates`. * `opts` (*type:* `keyword()`) - Call options ## Returns @@ -1227,7 +1227,7 @@ defmodule GoogleApi.DLP.V2.Api.Projects do end @doc """ - Updates the InspectTemplate. See https://cloud.google.com/dlp/docs/creating-templates to learn more. + Updates the InspectTemplate. See https://cloud.google.com/sensitive-data-protection/docs/creating-templates to learn more. ## Parameters @@ -1353,12 +1353,12 @@ defmodule GoogleApi.DLP.V2.Api.Projects do end @doc """ - Creates a job trigger to run DLP actions such as scanning storage for sensitive information on a set schedule. See https://cloud.google.com/dlp/docs/creating-job-triggers to learn more. + Creates a job trigger to run DLP actions such as scanning storage for sensitive information on a set schedule. See https://cloud.google.com/sensitive-data-protection/docs/creating-job-triggers to learn more. ## Parameters * `connection` (*type:* `GoogleApi.DLP.V2.Connection.t`) - Connection to server - * `parent` (*type:* `String.t`) - Required. Parent resource name. The format of this value varies depending on whether you have [specified a processing location](https://cloud.google.com/dlp/docs/specifying-location): + Projects scope, location specified: `projects/`PROJECT_ID`/locations/`LOCATION_ID + Projects scope, no location specified (defaults to global): `projects/`PROJECT_ID The following example `parent` string specifies a parent project with the identifier `example-project`, and specifies the `europe-west3` location for processing data: parent=projects/example-project/locations/europe-west3 + * `parent` (*type:* `String.t`) - Required. Parent resource name. The format of this value varies depending on whether you have [specified a processing location](https://cloud.google.com/sensitive-data-protection/docs/specifying-location): + Projects scope, location specified: `projects/`PROJECT_ID`/locations/`LOCATION_ID + Projects scope, no location specified (defaults to global): `projects/`PROJECT_ID The following example `parent` string specifies a parent project with the identifier `example-project`, and specifies the `europe-west3` location for processing data: parent=projects/example-project/locations/europe-west3 * `optional_params` (*type:* `keyword()`) - Optional parameters * `:"$.xgafv"` (*type:* `String.t`) - V1 error format. * `:access_token` (*type:* `String.t`) - OAuth access token. @@ -1415,7 +1415,7 @@ defmodule GoogleApi.DLP.V2.Api.Projects do end @doc """ - Deletes a job trigger. See https://cloud.google.com/dlp/docs/creating-job-triggers to learn more. + Deletes a job trigger. See https://cloud.google.com/sensitive-data-protection/docs/creating-job-triggers to learn more. ## Parameters @@ -1475,7 +1475,7 @@ defmodule GoogleApi.DLP.V2.Api.Projects do end @doc """ - Gets a job trigger. See https://cloud.google.com/dlp/docs/creating-job-triggers to learn more. + Gets a job trigger. See https://cloud.google.com/sensitive-data-protection/docs/creating-job-triggers to learn more. ## Parameters @@ -1535,12 +1535,12 @@ defmodule GoogleApi.DLP.V2.Api.Projects do end @doc """ - Lists job triggers. See https://cloud.google.com/dlp/docs/creating-job-triggers to learn more. + Lists job triggers. See https://cloud.google.com/sensitive-data-protection/docs/creating-job-triggers to learn more. ## Parameters * `connection` (*type:* `GoogleApi.DLP.V2.Connection.t`) - Connection to server - * `parent` (*type:* `String.t`) - Required. Parent resource name. The format of this value varies depending on whether you have [specified a processing location](https://cloud.google.com/dlp/docs/specifying-location): + Projects scope, location specified: `projects/`PROJECT_ID`/locations/`LOCATION_ID + Projects scope, no location specified (defaults to global): `projects/`PROJECT_ID The following example `parent` string specifies a parent project with the identifier `example-project`, and specifies the `europe-west3` location for processing data: parent=projects/example-project/locations/europe-west3 + * `parent` (*type:* `String.t`) - Required. Parent resource name. The format of this value varies depending on whether you have [specified a processing location](https://cloud.google.com/sensitive-data-protection/docs/specifying-location): + Projects scope, location specified: `projects/`PROJECT_ID`/locations/`LOCATION_ID + Projects scope, no location specified (defaults to global): `projects/`PROJECT_ID The following example `parent` string specifies a parent project with the identifier `example-project`, and specifies the `europe-west3` location for processing data: parent=projects/example-project/locations/europe-west3 * `optional_params` (*type:* `keyword()`) - Optional parameters * `:"$.xgafv"` (*type:* `String.t`) - V1 error format. * `:access_token` (*type:* `String.t`) - OAuth access token. @@ -1555,9 +1555,9 @@ defmodule GoogleApi.DLP.V2.Api.Projects do * `:upload_protocol` (*type:* `String.t`) - Upload protocol for media (e.g. "raw", "multipart"). * `:filter` (*type:* `String.t`) - Allows filtering. Supported syntax: * Filter expressions are made up of one or more restrictions. * Restrictions can be combined by `AND` or `OR` logical operators. A sequence of restrictions implicitly uses `AND`. * A restriction has the form of `{field} {operator} {value}`. * Supported fields/values for inspect triggers: - `status` - HEALTHY|PAUSED|CANCELLED - `inspected_storage` - DATASTORE|CLOUD_STORAGE|BIGQUERY - 'last_run_time` - RFC 3339 formatted timestamp, surrounded by quotation marks. Nanoseconds are ignored. - 'error_count' - Number of errors that have occurred while running. * The operator must be `=` or `!=` for status and inspected_storage. Examples: * inspected_storage = cloud_storage AND status = HEALTHY * inspected_storage = cloud_storage OR inspected_storage = bigquery * inspected_storage = cloud_storage AND (state = PAUSED OR state = HEALTHY) * last_run_time > \\"2017-12-12T00:00:00+00:00\\" The length of this field should be no more than 500 characters. * `:locationId` (*type:* `String.t`) - Deprecated. This field has no effect. - * `:orderBy` (*type:* `String.t`) - Comma separated list of triggeredJob fields to order by, followed by `asc` or `desc` postfix. This list is case-insensitive, default sorting order is ascending, redundant space characters are insignificant. Example: `name asc,update_time, create_time desc` Supported fields are: - `create_time`: corresponds to the time the JobTrigger was created. - `update_time`: corresponds to the time the JobTrigger was last updated. - `last_run_time`: corresponds to the last time the JobTrigger ran. - `name`: corresponds to the JobTrigger's name. - `display_name`: corresponds to the JobTrigger's display name. - `status`: corresponds to JobTrigger's status. - * `:pageSize` (*type:* `integer()`) - Size of the page, can be limited by a server. - * `:pageToken` (*type:* `String.t`) - Page token to continue retrieval. Comes from previous call to ListJobTriggers. `order_by` field must not change for subsequent calls. + * `:orderBy` (*type:* `String.t`) - Comma separated list of triggeredJob fields to order by, followed by `asc` or `desc` postfix. This list is case insensitive. The default sorting order is ascending. Redundant space characters are insignificant. Example: `name asc,update_time, create_time desc` Supported fields are: - `create_time`: corresponds to the time the JobTrigger was created. - `update_time`: corresponds to the time the JobTrigger was last updated. - `last_run_time`: corresponds to the last time the JobTrigger ran. - `name`: corresponds to the JobTrigger's name. - `display_name`: corresponds to the JobTrigger's display name. - `status`: corresponds to JobTrigger's status. + * `:pageSize` (*type:* `integer()`) - Size of the page. This value can be limited by a server. + * `:pageToken` (*type:* `String.t`) - Page token to continue retrieval. Comes from the previous call to ListJobTriggers. `order_by` field must not change for subsequent calls. * `:type` (*type:* `String.t`) - The type of jobs. Will use `DlpJobType.INSPECT` if not set. * `opts` (*type:* `keyword()`) - Call options @@ -1609,7 +1609,7 @@ defmodule GoogleApi.DLP.V2.Api.Projects do end @doc """ - Updates a job trigger. See https://cloud.google.com/dlp/docs/creating-job-triggers to learn more. + Updates a job trigger. See https://cloud.google.com/sensitive-data-protection/docs/creating-job-triggers to learn more. ## Parameters @@ -1671,12 +1671,164 @@ defmodule GoogleApi.DLP.V2.Api.Projects do end @doc """ - De-identifies potentially sensitive info from a ContentItem. This method has limits on input size and output size. See https://cloud.google.com/dlp/docs/deidentify-sensitive-data to learn more. When no InfoTypes or CustomInfoTypes are specified in this request, the system will automatically choose what detectors to run. By default this may be all types, but may change over time as detectors are updated. + Gets a column data profile. ## Parameters * `connection` (*type:* `GoogleApi.DLP.V2.Connection.t`) - Connection to server - * `parent` (*type:* `String.t`) - Parent resource name. The format of this value varies depending on whether you have [specified a processing location](https://cloud.google.com/dlp/docs/specifying-location): + Projects scope, location specified: `projects/`PROJECT_ID`/locations/`LOCATION_ID + Projects scope, no location specified (defaults to global): `projects/`PROJECT_ID The following example `parent` string specifies a parent project with the identifier `example-project`, and specifies the `europe-west3` location for processing data: parent=projects/example-project/locations/europe-west3 + * `name` (*type:* `String.t`) - Required. Resource name, for example `organizations/12345/locations/us/columnDataProfiles/53234423`. + * `optional_params` (*type:* `keyword()`) - Optional parameters + * `:"$.xgafv"` (*type:* `String.t`) - V1 error format. + * `:access_token` (*type:* `String.t`) - OAuth access token. + * `:alt` (*type:* `String.t`) - Data format for response. + * `:callback` (*type:* `String.t`) - JSONP + * `:fields` (*type:* `String.t`) - Selector specifying which fields to include in a partial response. + * `:key` (*type:* `String.t`) - 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. + * `:oauth_token` (*type:* `String.t`) - OAuth 2.0 token for the current user. + * `:prettyPrint` (*type:* `boolean()`) - Returns response with indentations and line breaks. + * `:quotaUser` (*type:* `String.t`) - 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. + * `:uploadType` (*type:* `String.t`) - Legacy upload protocol for media (e.g. "media", "multipart"). + * `:upload_protocol` (*type:* `String.t`) - Upload protocol for media (e.g. "raw", "multipart"). + * `opts` (*type:* `keyword()`) - Call options + + ## Returns + + * `{:ok, %GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2ColumnDataProfile{}}` on success + * `{:error, info}` on failure + """ + @spec dlp_projects_locations_column_data_profiles_get( + Tesla.Env.client(), + String.t(), + keyword(), + keyword() + ) :: + {:ok, GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2ColumnDataProfile.t()} + | {:ok, Tesla.Env.t()} + | {:ok, list()} + | {:error, any()} + def dlp_projects_locations_column_data_profiles_get( + connection, + name, + optional_params \\ [], + opts \\ [] + ) do + optional_params_config = %{ + :"$.xgafv" => :query, + :access_token => :query, + :alt => :query, + :callback => :query, + :fields => :query, + :key => :query, + :oauth_token => :query, + :prettyPrint => :query, + :quotaUser => :query, + :uploadType => :query, + :upload_protocol => :query + } + + request = + Request.new() + |> Request.method(:get) + |> Request.url("/v2/{+name}", %{ + "name" => URI.encode(name, &URI.char_unreserved?/1) + }) + |> Request.add_optional_params(optional_params_config, optional_params) + |> Request.library_version(@library_version) + + connection + |> Connection.execute(request) + |> Response.decode( + opts ++ [struct: %GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2ColumnDataProfile{}] + ) + end + + @doc """ + Lists data profiles for an organization. + + ## Parameters + + * `connection` (*type:* `GoogleApi.DLP.V2.Connection.t`) - Connection to server + * `parent` (*type:* `String.t`) - Required. Resource name of the organization or project, for example `organizations/433245324/locations/europe` or projects/project-id/locations/asia. + * `optional_params` (*type:* `keyword()`) - Optional parameters + * `:"$.xgafv"` (*type:* `String.t`) - V1 error format. + * `:access_token` (*type:* `String.t`) - OAuth access token. + * `:alt` (*type:* `String.t`) - Data format for response. + * `:callback` (*type:* `String.t`) - JSONP + * `:fields` (*type:* `String.t`) - Selector specifying which fields to include in a partial response. + * `:key` (*type:* `String.t`) - 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. + * `:oauth_token` (*type:* `String.t`) - OAuth 2.0 token for the current user. + * `:prettyPrint` (*type:* `boolean()`) - Returns response with indentations and line breaks. + * `:quotaUser` (*type:* `String.t`) - 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. + * `:uploadType` (*type:* `String.t`) - Legacy upload protocol for media (e.g. "media", "multipart"). + * `:upload_protocol` (*type:* `String.t`) - Upload protocol for media (e.g. "raw", "multipart"). + * `:filter` (*type:* `String.t`) - Allows filtering. Supported syntax: * Filter expressions are made up of one or more restrictions. * Restrictions can be combined by `AND` or `OR` logical operators. A sequence of restrictions implicitly uses `AND`. * A restriction has the form of `{field} {operator} {value}`. * Supported fields/values: - `table_data_profile_name` - The name of the related table data profile. - `project_id` - The Google Cloud project ID. (REQUIRED) - `dataset_id` - The BigQuery dataset ID. (REQUIRED) - `table_id` - The BigQuery table ID. (REQUIRED) - `field_id` - The ID of the BigQuery field. - `info_type` - The infotype detected in the resource. - `sensitivity_level` - HIGH|MEDIUM|LOW - `data_risk_level`: How much risk is associated with this data. - `status_code` - an RPC status code as defined in https://github.com/googleapis/googleapis/blob/master/google/rpc/code.proto * The operator must be `=` for project_id, dataset_id, and table_id. Other filters also support `!=`. Examples: * project_id = 12345 AND status_code = 1 * project_id = 12345 AND sensitivity_level = HIGH * project_id = 12345 AND info_type = STREET_ADDRESS The length of this field should be no more than 500 characters. + * `:orderBy` (*type:* `String.t`) - Comma separated list of fields to order by, followed by `asc` or `desc` postfix. This list is case insensitive. The default sorting order is ascending. Redundant space characters are insignificant. Only one order field at a time is allowed. Examples: * `project_id asc` * `table_id` * `sensitivity_level desc` Supported fields are: - `project_id`: The Google Cloud project ID. - `dataset_id`: The ID of a BigQuery dataset. - `table_id`: The ID of a BigQuery table. - `sensitivity_level`: How sensitive the data in a column is, at most. - `data_risk_level`: How much risk is associated with this data. - `profile_last_generated`: When the profile was last updated in epoch seconds. + * `:pageSize` (*type:* `integer()`) - Size of the page. This value can be limited by the server. If zero, server returns a page of max size 100. + * `:pageToken` (*type:* `String.t`) - Page token to continue retrieval. + * `opts` (*type:* `keyword()`) - Call options + + ## Returns + + * `{:ok, %GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2ListColumnDataProfilesResponse{}}` on success + * `{:error, info}` on failure + """ + @spec dlp_projects_locations_column_data_profiles_list( + Tesla.Env.client(), + String.t(), + keyword(), + keyword() + ) :: + {:ok, GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2ListColumnDataProfilesResponse.t()} + | {:ok, Tesla.Env.t()} + | {:ok, list()} + | {:error, any()} + def dlp_projects_locations_column_data_profiles_list( + connection, + parent, + optional_params \\ [], + opts \\ [] + ) do + optional_params_config = %{ + :"$.xgafv" => :query, + :access_token => :query, + :alt => :query, + :callback => :query, + :fields => :query, + :key => :query, + :oauth_token => :query, + :prettyPrint => :query, + :quotaUser => :query, + :uploadType => :query, + :upload_protocol => :query, + :filter => :query, + :orderBy => :query, + :pageSize => :query, + :pageToken => :query + } + + request = + Request.new() + |> Request.method(:get) + |> Request.url("/v2/{+parent}/columnDataProfiles", %{ + "parent" => URI.encode(parent, &URI.char_unreserved?/1) + }) + |> Request.add_optional_params(optional_params_config, optional_params) + |> Request.library_version(@library_version) + + connection + |> Connection.execute(request) + |> Response.decode( + opts ++ [struct: %GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2ListColumnDataProfilesResponse{}] + ) + end + + @doc """ + De-identifies potentially sensitive info from a ContentItem. This method has limits on input size and output size. See https://cloud.google.com/sensitive-data-protection/docs/deidentify-sensitive-data to learn more. When no InfoTypes or CustomInfoTypes are specified in this request, the system will automatically choose what detectors to run. By default this may be all types, but may change over time as detectors are updated. + + ## Parameters + + * `connection` (*type:* `GoogleApi.DLP.V2.Connection.t`) - Connection to server + * `parent` (*type:* `String.t`) - Parent resource name. The format of this value varies depending on whether you have [specified a processing location](https://cloud.google.com/sensitive-data-protection/docs/specifying-location): + Projects scope, location specified: `projects/`PROJECT_ID`/locations/`LOCATION_ID + Projects scope, no location specified (defaults to global): `projects/`PROJECT_ID The following example `parent` string specifies a parent project with the identifier `example-project`, and specifies the `europe-west3` location for processing data: parent=projects/example-project/locations/europe-west3 * `optional_params` (*type:* `keyword()`) - Optional parameters * `:"$.xgafv"` (*type:* `String.t`) - V1 error format. * `:access_token` (*type:* `String.t`) - OAuth access token. @@ -1745,12 +1897,12 @@ defmodule GoogleApi.DLP.V2.Api.Projects do end @doc """ - Finds potentially sensitive info in content. This method has limits on input size, processing time, and output size. When no InfoTypes or CustomInfoTypes are specified in this request, the system will automatically choose what detectors to run. By default this may be all types, but may change over time as detectors are updated. For how to guides, see https://cloud.google.com/dlp/docs/inspecting-images and https://cloud.google.com/dlp/docs/inspecting-text, + Finds potentially sensitive info in content. This method has limits on input size, processing time, and output size. When no InfoTypes or CustomInfoTypes are specified in this request, the system will automatically choose what detectors to run. By default this may be all types, but may change over time as detectors are updated. For how to guides, see https://cloud.google.com/sensitive-data-protection/docs/inspecting-images and https://cloud.google.com/sensitive-data-protection/docs/inspecting-text, ## Parameters * `connection` (*type:* `GoogleApi.DLP.V2.Connection.t`) - Connection to server - * `parent` (*type:* `String.t`) - Parent resource name. The format of this value varies depending on whether you have [specified a processing location](https://cloud.google.com/dlp/docs/specifying-location): + Projects scope, location specified: `projects/`PROJECT_ID`/locations/`LOCATION_ID + Projects scope, no location specified (defaults to global): `projects/`PROJECT_ID The following example `parent` string specifies a parent project with the identifier `example-project`, and specifies the `europe-west3` location for processing data: parent=projects/example-project/locations/europe-west3 + * `parent` (*type:* `String.t`) - Parent resource name. The format of this value varies depending on whether you have [specified a processing location](https://cloud.google.com/sensitive-data-protection/docs/specifying-location): + Projects scope, location specified: `projects/`PROJECT_ID`/locations/`LOCATION_ID + Projects scope, no location specified (defaults to global): `projects/`PROJECT_ID The following example `parent` string specifies a parent project with the identifier `example-project`, and specifies the `europe-west3` location for processing data: parent=projects/example-project/locations/europe-west3 * `optional_params` (*type:* `keyword()`) - Optional parameters * `:"$.xgafv"` (*type:* `String.t`) - V1 error format. * `:access_token` (*type:* `String.t`) - OAuth access token. @@ -1819,12 +1971,12 @@ defmodule GoogleApi.DLP.V2.Api.Projects do end @doc """ - Re-identifies content that has been de-identified. See https://cloud.google.com/dlp/docs/pseudonymization#re-identification_in_free_text_code_example to learn more. + Re-identifies content that has been de-identified. See https://cloud.google.com/sensitive-data-protection/docs/pseudonymization#re-identification_in_free_text_code_example to learn more. ## Parameters * `connection` (*type:* `GoogleApi.DLP.V2.Connection.t`) - Connection to server - * `parent` (*type:* `String.t`) - Required. Parent resource name. The format of this value varies depending on whether you have [specified a processing location](https://cloud.google.com/dlp/docs/specifying-location): + Projects scope, location specified: `projects/`PROJECT_ID`/locations/`LOCATION_ID + Projects scope, no location specified (defaults to global): `projects/`PROJECT_ID The following example `parent` string specifies a parent project with the identifier `example-project`, and specifies the `europe-west3` location for processing data: parent=projects/example-project/locations/europe-west3 + * `parent` (*type:* `String.t`) - Required. Parent resource name. The format of this value varies depending on whether you have [specified a processing location](https://cloud.google.com/sensitive-data-protection/docs/specifying-location): + Projects scope, location specified: `projects/`PROJECT_ID`/locations/`LOCATION_ID + Projects scope, no location specified (defaults to global): `projects/`PROJECT_ID The following example `parent` string specifies a parent project with the identifier `example-project`, and specifies the `europe-west3` location for processing data: parent=projects/example-project/locations/europe-west3 * `optional_params` (*type:* `keyword()`) - Optional parameters * `:"$.xgafv"` (*type:* `String.t`) - V1 error format. * `:access_token` (*type:* `String.t`) - OAuth access token. @@ -1893,12 +2045,12 @@ defmodule GoogleApi.DLP.V2.Api.Projects do end @doc """ - Creates a DeidentifyTemplate for reusing frequently used configuration for de-identifying content, images, and storage. See https://cloud.google.com/dlp/docs/creating-templates-deid to learn more. + Creates a DeidentifyTemplate for reusing frequently used configuration for de-identifying content, images, and storage. See https://cloud.google.com/sensitive-data-protection/docs/creating-templates-deid to learn more. ## Parameters * `connection` (*type:* `GoogleApi.DLP.V2.Connection.t`) - Connection to server - * `parent` (*type:* `String.t`) - Required. Parent resource name. The format of this value varies depending on the scope of the request (project or organization) and whether you have [specified a processing location](https://cloud.google.com/dlp/docs/specifying-location): + Projects scope, location specified: `projects/`PROJECT_ID`/locations/`LOCATION_ID + Projects scope, no location specified (defaults to global): `projects/`PROJECT_ID + Organizations scope, location specified: `organizations/`ORG_ID`/locations/`LOCATION_ID + Organizations scope, no location specified (defaults to global): `organizations/`ORG_ID The following example `parent` string specifies a parent project with the identifier `example-project`, and specifies the `europe-west3` location for processing data: parent=projects/example-project/locations/europe-west3 + * `parent` (*type:* `String.t`) - Required. Parent resource name. The format of this value varies depending on the scope of the request (project or organization) and whether you have [specified a processing location](https://cloud.google.com/sensitive-data-protection/docs/specifying-location): + Projects scope, location specified: `projects/`PROJECT_ID`/locations/`LOCATION_ID + Projects scope, no location specified (defaults to global): `projects/`PROJECT_ID + Organizations scope, location specified: `organizations/`ORG_ID`/locations/`LOCATION_ID + Organizations scope, no location specified (defaults to global): `organizations/`ORG_ID The following example `parent` string specifies a parent project with the identifier `example-project`, and specifies the `europe-west3` location for processing data: parent=projects/example-project/locations/europe-west3 * `optional_params` (*type:* `keyword()`) - Optional parameters * `:"$.xgafv"` (*type:* `String.t`) - V1 error format. * `:access_token` (*type:* `String.t`) - OAuth access token. @@ -1967,7 +2119,7 @@ defmodule GoogleApi.DLP.V2.Api.Projects do end @doc """ - Deletes a DeidentifyTemplate. See https://cloud.google.com/dlp/docs/creating-templates-deid to learn more. + Deletes a DeidentifyTemplate. See https://cloud.google.com/sensitive-data-protection/docs/creating-templates-deid to learn more. ## Parameters @@ -2037,7 +2189,7 @@ defmodule GoogleApi.DLP.V2.Api.Projects do end @doc """ - Gets a DeidentifyTemplate. See https://cloud.google.com/dlp/docs/creating-templates-deid to learn more. + Gets a DeidentifyTemplate. See https://cloud.google.com/sensitive-data-protection/docs/creating-templates-deid to learn more. ## Parameters @@ -2109,12 +2261,12 @@ defmodule GoogleApi.DLP.V2.Api.Projects do end @doc """ - Lists DeidentifyTemplates. See https://cloud.google.com/dlp/docs/creating-templates-deid to learn more. + Lists DeidentifyTemplates. See https://cloud.google.com/sensitive-data-protection/docs/creating-templates-deid to learn more. ## Parameters * `connection` (*type:* `GoogleApi.DLP.V2.Connection.t`) - Connection to server - * `parent` (*type:* `String.t`) - Required. Parent resource name. The format of this value varies depending on the scope of the request (project or organization) and whether you have [specified a processing location](https://cloud.google.com/dlp/docs/specifying-location): + Projects scope, location specified: `projects/`PROJECT_ID`/locations/`LOCATION_ID + Projects scope, no location specified (defaults to global): `projects/`PROJECT_ID + Organizations scope, location specified: `organizations/`ORG_ID`/locations/`LOCATION_ID + Organizations scope, no location specified (defaults to global): `organizations/`ORG_ID The following example `parent` string specifies a parent project with the identifier `example-project`, and specifies the `europe-west3` location for processing data: parent=projects/example-project/locations/europe-west3 + * `parent` (*type:* `String.t`) - Required. Parent resource name. The format of this value varies depending on the scope of the request (project or organization) and whether you have [specified a processing location](https://cloud.google.com/sensitive-data-protection/docs/specifying-location): + Projects scope, location specified: `projects/`PROJECT_ID`/locations/`LOCATION_ID + Projects scope, no location specified (defaults to global): `projects/`PROJECT_ID + Organizations scope, location specified: `organizations/`ORG_ID`/locations/`LOCATION_ID + Organizations scope, no location specified (defaults to global): `organizations/`ORG_ID The following example `parent` string specifies a parent project with the identifier `example-project`, and specifies the `europe-west3` location for processing data: parent=projects/example-project/locations/europe-west3 * `optional_params` (*type:* `keyword()`) - Optional parameters * `:"$.xgafv"` (*type:* `String.t`) - V1 error format. * `:access_token` (*type:* `String.t`) - OAuth access token. @@ -2128,9 +2280,9 @@ defmodule GoogleApi.DLP.V2.Api.Projects do * `:uploadType` (*type:* `String.t`) - Legacy upload protocol for media (e.g. "media", "multipart"). * `:upload_protocol` (*type:* `String.t`) - Upload protocol for media (e.g. "raw", "multipart"). * `:locationId` (*type:* `String.t`) - Deprecated. This field has no effect. - * `:orderBy` (*type:* `String.t`) - Comma separated list of fields to order by, followed by `asc` or `desc` postfix. This list is case-insensitive, default sorting order is ascending, redundant space characters are insignificant. Example: `name asc,update_time, create_time desc` Supported fields are: - `create_time`: corresponds to the time the template was created. - `update_time`: corresponds to the time the template was last updated. - `name`: corresponds to the template's name. - `display_name`: corresponds to the template's display name. - * `:pageSize` (*type:* `integer()`) - Size of the page, can be limited by the server. If zero server returns a page of max size 100. - * `:pageToken` (*type:* `String.t`) - Page token to continue retrieval. Comes from previous call to `ListDeidentifyTemplates`. + * `:orderBy` (*type:* `String.t`) - Comma separated list of fields to order by, followed by `asc` or `desc` postfix. This list is case insensitive. The default sorting order is ascending. Redundant space characters are insignificant. Example: `name asc,update_time, create_time desc` Supported fields are: - `create_time`: corresponds to the time the template was created. - `update_time`: corresponds to the time the template was last updated. - `name`: corresponds to the template's name. - `display_name`: corresponds to the template's display name. + * `:pageSize` (*type:* `integer()`) - Size of the page. This value can be limited by the server. If zero server returns a page of max size 100. + * `:pageToken` (*type:* `String.t`) - Page token to continue retrieval. Comes from the previous call to `ListDeidentifyTemplates`. * `opts` (*type:* `keyword()`) - Call options ## Returns @@ -2190,7 +2342,7 @@ defmodule GoogleApi.DLP.V2.Api.Projects do end @doc """ - Updates the DeidentifyTemplate. See https://cloud.google.com/dlp/docs/creating-templates-deid to learn more. + Updates the DeidentifyTemplate. See https://cloud.google.com/sensitive-data-protection/docs/creating-templates-deid to learn more. ## Parameters @@ -2264,12 +2416,12 @@ defmodule GoogleApi.DLP.V2.Api.Projects do end @doc """ - Starts asynchronous cancellation on a long-running DlpJob. The server makes a best effort to cancel the DlpJob, but success is not guaranteed. See https://cloud.google.com/dlp/docs/inspecting-storage and https://cloud.google.com/dlp/docs/compute-risk-analysis to learn more. + Creates a config for discovery to scan and profile storage. ## Parameters * `connection` (*type:* `GoogleApi.DLP.V2.Connection.t`) - Connection to server - * `name` (*type:* `String.t`) - Required. The name of the DlpJob resource to be cancelled. + * `parent` (*type:* `String.t`) - Required. Parent resource name. The format of this value is as follows: `projects/`PROJECT_ID`/locations/`LOCATION_ID The following example `parent` string specifies a parent project with the identifier `example-project`, and specifies the `europe-west3` location for processing data: parent=projects/example-project/locations/europe-west3 * `optional_params` (*type:* `keyword()`) - Optional parameters * `:"$.xgafv"` (*type:* `String.t`) - V1 error format. * `:access_token` (*type:* `String.t`) - OAuth access token. @@ -2282,25 +2434,30 @@ defmodule GoogleApi.DLP.V2.Api.Projects do * `:quotaUser` (*type:* `String.t`) - 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. * `:uploadType` (*type:* `String.t`) - Legacy upload protocol for media (e.g. "media", "multipart"). * `:upload_protocol` (*type:* `String.t`) - Upload protocol for media (e.g. "raw", "multipart"). - * `:body` (*type:* `GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2CancelDlpJobRequest.t`) - + * `:body` (*type:* `GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2CreateDiscoveryConfigRequest.t`) - * `opts` (*type:* `keyword()`) - Call options ## Returns - * `{:ok, %GoogleApi.DLP.V2.Model.GoogleProtobufEmpty{}}` on success + * `{:ok, %GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2DiscoveryConfig{}}` on success * `{:error, info}` on failure """ - @spec dlp_projects_locations_dlp_jobs_cancel( + @spec dlp_projects_locations_discovery_configs_create( Tesla.Env.client(), String.t(), keyword(), keyword() ) :: - {:ok, GoogleApi.DLP.V2.Model.GoogleProtobufEmpty.t()} + {:ok, GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2DiscoveryConfig.t()} | {:ok, Tesla.Env.t()} | {:ok, list()} | {:error, any()} - def dlp_projects_locations_dlp_jobs_cancel(connection, name, optional_params \\ [], opts \\ []) do + def dlp_projects_locations_discovery_configs_create( + connection, + parent, + optional_params \\ [], + opts \\ [] + ) do optional_params_config = %{ :"$.xgafv" => :query, :access_token => :query, @@ -2319,24 +2476,26 @@ defmodule GoogleApi.DLP.V2.Api.Projects do request = Request.new() |> Request.method(:post) - |> Request.url("/v2/{+name}:cancel", %{ - "name" => URI.encode(name, &URI.char_unreserved?/1) + |> Request.url("/v2/{+parent}/discoveryConfigs", %{ + "parent" => URI.encode(parent, &URI.char_unreserved?/1) }) |> Request.add_optional_params(optional_params_config, optional_params) |> Request.library_version(@library_version) connection |> Connection.execute(request) - |> Response.decode(opts ++ [struct: %GoogleApi.DLP.V2.Model.GoogleProtobufEmpty{}]) + |> Response.decode( + opts ++ [struct: %GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2DiscoveryConfig{}] + ) end @doc """ - Creates a new job to inspect storage or calculate risk metrics. See https://cloud.google.com/dlp/docs/inspecting-storage and https://cloud.google.com/dlp/docs/compute-risk-analysis to learn more. When no InfoTypes or CustomInfoTypes are specified in inspect jobs, the system will automatically choose what detectors to run. By default this may be all types, but may change over time as detectors are updated. + Deletes a discovery configuration. ## Parameters * `connection` (*type:* `GoogleApi.DLP.V2.Connection.t`) - Connection to server - * `parent` (*type:* `String.t`) - Required. Parent resource name. The format of this value varies depending on whether you have [specified a processing location](https://cloud.google.com/dlp/docs/specifying-location): + Projects scope, location specified: `projects/`PROJECT_ID`/locations/`LOCATION_ID + Projects scope, no location specified (defaults to global): `projects/`PROJECT_ID The following example `parent` string specifies a parent project with the identifier `example-project`, and specifies the `europe-west3` location for processing data: parent=projects/example-project/locations/europe-west3 + * `name` (*type:* `String.t`) - Required. Resource name of the project and the config, for example `projects/dlp-test-project/discoveryConfigs/53234423`. * `optional_params` (*type:* `keyword()`) - Optional parameters * `:"$.xgafv"` (*type:* `String.t`) - V1 error format. * `:access_token` (*type:* `String.t`) - OAuth access token. @@ -2349,27 +2508,26 @@ defmodule GoogleApi.DLP.V2.Api.Projects do * `:quotaUser` (*type:* `String.t`) - 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. * `:uploadType` (*type:* `String.t`) - Legacy upload protocol for media (e.g. "media", "multipart"). * `:upload_protocol` (*type:* `String.t`) - Upload protocol for media (e.g. "raw", "multipart"). - * `:body` (*type:* `GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2CreateDlpJobRequest.t`) - * `opts` (*type:* `keyword()`) - Call options ## Returns - * `{:ok, %GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2DlpJob{}}` on success + * `{:ok, %GoogleApi.DLP.V2.Model.GoogleProtobufEmpty{}}` on success * `{:error, info}` on failure """ - @spec dlp_projects_locations_dlp_jobs_create( + @spec dlp_projects_locations_discovery_configs_delete( Tesla.Env.client(), String.t(), keyword(), keyword() ) :: - {:ok, GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2DlpJob.t()} + {:ok, GoogleApi.DLP.V2.Model.GoogleProtobufEmpty.t()} | {:ok, Tesla.Env.t()} | {:ok, list()} | {:error, any()} - def dlp_projects_locations_dlp_jobs_create( + def dlp_projects_locations_discovery_configs_delete( connection, - parent, + name, optional_params \\ [], opts \\ [] ) do @@ -2384,31 +2542,30 @@ defmodule GoogleApi.DLP.V2.Api.Projects do :prettyPrint => :query, :quotaUser => :query, :uploadType => :query, - :upload_protocol => :query, - :body => :body + :upload_protocol => :query } request = Request.new() - |> Request.method(:post) - |> Request.url("/v2/{+parent}/dlpJobs", %{ - "parent" => URI.encode(parent, &URI.char_unreserved?/1) + |> Request.method(:delete) + |> Request.url("/v2/{+name}", %{ + "name" => URI.encode(name, &URI.char_unreserved?/1) }) |> Request.add_optional_params(optional_params_config, optional_params) |> Request.library_version(@library_version) connection |> Connection.execute(request) - |> Response.decode(opts ++ [struct: %GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2DlpJob{}]) + |> Response.decode(opts ++ [struct: %GoogleApi.DLP.V2.Model.GoogleProtobufEmpty{}]) end @doc """ - Deletes a long-running DlpJob. This method indicates that the client is no longer interested in the DlpJob result. The job will be canceled if possible. See https://cloud.google.com/dlp/docs/inspecting-storage and https://cloud.google.com/dlp/docs/compute-risk-analysis to learn more. + Gets a discovery configuration. ## Parameters * `connection` (*type:* `GoogleApi.DLP.V2.Connection.t`) - Connection to server - * `name` (*type:* `String.t`) - Required. The name of the DlpJob resource to be deleted. + * `name` (*type:* `String.t`) - Required. Resource name of the project and the configuration, for example `projects/dlp-test-project/discoveryConfigs/53234423`. * `optional_params` (*type:* `keyword()`) - Optional parameters * `:"$.xgafv"` (*type:* `String.t`) - V1 error format. * `:access_token` (*type:* `String.t`) - OAuth access token. @@ -2425,20 +2582,25 @@ defmodule GoogleApi.DLP.V2.Api.Projects do ## Returns - * `{:ok, %GoogleApi.DLP.V2.Model.GoogleProtobufEmpty{}}` on success + * `{:ok, %GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2DiscoveryConfig{}}` on success * `{:error, info}` on failure """ - @spec dlp_projects_locations_dlp_jobs_delete( + @spec dlp_projects_locations_discovery_configs_get( Tesla.Env.client(), String.t(), keyword(), keyword() ) :: - {:ok, GoogleApi.DLP.V2.Model.GoogleProtobufEmpty.t()} + {:ok, GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2DiscoveryConfig.t()} | {:ok, Tesla.Env.t()} | {:ok, list()} | {:error, any()} - def dlp_projects_locations_dlp_jobs_delete(connection, name, optional_params \\ [], opts \\ []) do + def dlp_projects_locations_discovery_configs_get( + connection, + name, + optional_params \\ [], + opts \\ [] + ) do optional_params_config = %{ :"$.xgafv" => :query, :access_token => :query, @@ -2455,7 +2617,7 @@ defmodule GoogleApi.DLP.V2.Api.Projects do request = Request.new() - |> Request.method(:delete) + |> Request.method(:get) |> Request.url("/v2/{+name}", %{ "name" => URI.encode(name, &URI.char_unreserved?/1) }) @@ -2464,16 +2626,18 @@ defmodule GoogleApi.DLP.V2.Api.Projects do connection |> Connection.execute(request) - |> Response.decode(opts ++ [struct: %GoogleApi.DLP.V2.Model.GoogleProtobufEmpty{}]) + |> Response.decode( + opts ++ [struct: %GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2DiscoveryConfig{}] + ) end @doc """ - Finish a running hybrid DlpJob. Triggers the finalization steps and running of any enabled actions that have not yet run. + Lists discovery configurations. ## Parameters * `connection` (*type:* `GoogleApi.DLP.V2.Connection.t`) - Connection to server - * `name` (*type:* `String.t`) - Required. The name of the DlpJob resource to be cancelled. + * `parent` (*type:* `String.t`) - Required. Parent resource name. The format of this value is as follows: `projects/`PROJECT_ID`/locations/`LOCATION_ID The following example `parent` string specifies a parent project with the identifier `example-project`, and specifies the `europe-west3` location for processing data: parent=projects/example-project/locations/europe-west3 * `optional_params` (*type:* `keyword()`) - Optional parameters * `:"$.xgafv"` (*type:* `String.t`) - V1 error format. * `:access_token` (*type:* `String.t`) - OAuth access token. @@ -2486,25 +2650,32 @@ defmodule GoogleApi.DLP.V2.Api.Projects do * `:quotaUser` (*type:* `String.t`) - 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. * `:uploadType` (*type:* `String.t`) - Legacy upload protocol for media (e.g. "media", "multipart"). * `:upload_protocol` (*type:* `String.t`) - Upload protocol for media (e.g. "raw", "multipart"). - * `:body` (*type:* `GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2FinishDlpJobRequest.t`) - + * `:orderBy` (*type:* `String.t`) - Comma separated list of config fields to order by, followed by `asc` or `desc` postfix. This list is case insensitive. The default sorting order is ascending. Redundant space characters are insignificant. Example: `name asc,update_time, create_time desc` Supported fields are: - `last_run_time`: corresponds to the last time the DiscoveryConfig ran. - `name`: corresponds to the DiscoveryConfig's name. - `status`: corresponds to DiscoveryConfig's status. + * `:pageSize` (*type:* `integer()`) - Size of the page. This value can be limited by a server. + * `:pageToken` (*type:* `String.t`) - Page token to continue retrieval. Comes from the previous call to ListDiscoveryConfigs. `order_by` field must not change for subsequent calls. * `opts` (*type:* `keyword()`) - Call options ## Returns - * `{:ok, %GoogleApi.DLP.V2.Model.GoogleProtobufEmpty{}}` on success + * `{:ok, %GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2ListDiscoveryConfigsResponse{}}` on success * `{:error, info}` on failure """ - @spec dlp_projects_locations_dlp_jobs_finish( + @spec dlp_projects_locations_discovery_configs_list( Tesla.Env.client(), String.t(), keyword(), keyword() ) :: - {:ok, GoogleApi.DLP.V2.Model.GoogleProtobufEmpty.t()} + {:ok, GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2ListDiscoveryConfigsResponse.t()} | {:ok, Tesla.Env.t()} | {:ok, list()} | {:error, any()} - def dlp_projects_locations_dlp_jobs_finish(connection, name, optional_params \\ [], opts \\ []) do + def dlp_projects_locations_discovery_configs_list( + connection, + parent, + optional_params \\ [], + opts \\ [] + ) do optional_params_config = %{ :"$.xgafv" => :query, :access_token => :query, @@ -2517,30 +2688,34 @@ defmodule GoogleApi.DLP.V2.Api.Projects do :quotaUser => :query, :uploadType => :query, :upload_protocol => :query, - :body => :body + :orderBy => :query, + :pageSize => :query, + :pageToken => :query } request = Request.new() - |> Request.method(:post) - |> Request.url("/v2/{+name}:finish", %{ - "name" => URI.encode(name, &URI.char_unreserved?/1) + |> Request.method(:get) + |> Request.url("/v2/{+parent}/discoveryConfigs", %{ + "parent" => URI.encode(parent, &URI.char_unreserved?/1) }) |> Request.add_optional_params(optional_params_config, optional_params) |> Request.library_version(@library_version) connection |> Connection.execute(request) - |> Response.decode(opts ++ [struct: %GoogleApi.DLP.V2.Model.GoogleProtobufEmpty{}]) + |> Response.decode( + opts ++ [struct: %GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2ListDiscoveryConfigsResponse{}] + ) end @doc """ - Gets the latest state of a long-running DlpJob. See https://cloud.google.com/dlp/docs/inspecting-storage and https://cloud.google.com/dlp/docs/compute-risk-analysis to learn more. + Updates a discovery configuration. ## Parameters * `connection` (*type:* `GoogleApi.DLP.V2.Connection.t`) - Connection to server - * `name` (*type:* `String.t`) - Required. The name of the DlpJob resource. + * `name` (*type:* `String.t`) - Required. Resource name of the project and the configuration, for example `projects/dlp-test-project/discoveryConfigs/53234423`. * `optional_params` (*type:* `keyword()`) - Optional parameters * `:"$.xgafv"` (*type:* `String.t`) - V1 error format. * `:access_token` (*type:* `String.t`) - OAuth access token. @@ -2553,19 +2728,30 @@ defmodule GoogleApi.DLP.V2.Api.Projects do * `:quotaUser` (*type:* `String.t`) - 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. * `:uploadType` (*type:* `String.t`) - Legacy upload protocol for media (e.g. "media", "multipart"). * `:upload_protocol` (*type:* `String.t`) - Upload protocol for media (e.g. "raw", "multipart"). + * `:body` (*type:* `GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2UpdateDiscoveryConfigRequest.t`) - * `opts` (*type:* `keyword()`) - Call options ## Returns - * `{:ok, %GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2DlpJob{}}` on success + * `{:ok, %GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2DiscoveryConfig{}}` on success * `{:error, info}` on failure """ - @spec dlp_projects_locations_dlp_jobs_get(Tesla.Env.client(), String.t(), keyword(), keyword()) :: - {:ok, GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2DlpJob.t()} + @spec dlp_projects_locations_discovery_configs_patch( + Tesla.Env.client(), + String.t(), + keyword(), + keyword() + ) :: + {:ok, GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2DiscoveryConfig.t()} | {:ok, Tesla.Env.t()} | {:ok, list()} | {:error, any()} - def dlp_projects_locations_dlp_jobs_get(connection, name, optional_params \\ [], opts \\ []) do + def dlp_projects_locations_discovery_configs_patch( + connection, + name, + optional_params \\ [], + opts \\ [] + ) do optional_params_config = %{ :"$.xgafv" => :query, :access_token => :query, @@ -2577,12 +2763,13 @@ defmodule GoogleApi.DLP.V2.Api.Projects do :prettyPrint => :query, :quotaUser => :query, :uploadType => :query, - :upload_protocol => :query + :upload_protocol => :query, + :body => :body } request = Request.new() - |> Request.method(:get) + |> Request.method(:patch) |> Request.url("/v2/{+name}", %{ "name" => URI.encode(name, &URI.char_unreserved?/1) }) @@ -2591,16 +2778,18 @@ defmodule GoogleApi.DLP.V2.Api.Projects do connection |> Connection.execute(request) - |> Response.decode(opts ++ [struct: %GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2DlpJob{}]) + |> Response.decode( + opts ++ [struct: %GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2DiscoveryConfig{}] + ) end @doc """ - Inspect hybrid content and store findings to a job. To review the findings, inspect the job. Inspection will occur asynchronously. + Starts asynchronous cancellation on a long-running DlpJob. The server makes a best effort to cancel the DlpJob, but success is not guaranteed. See https://cloud.google.com/sensitive-data-protection/docs/inspecting-storage and https://cloud.google.com/sensitive-data-protection/docs/compute-risk-analysis to learn more. ## Parameters * `connection` (*type:* `GoogleApi.DLP.V2.Connection.t`) - Connection to server - * `name` (*type:* `String.t`) - Required. Resource name of the job to execute a hybrid inspect on, for example `projects/dlp-test-project/dlpJob/53234423`. + * `name` (*type:* `String.t`) - Required. The name of the DlpJob resource to be cancelled. * `optional_params` (*type:* `keyword()`) - Optional parameters * `:"$.xgafv"` (*type:* `String.t`) - V1 error format. * `:access_token` (*type:* `String.t`) - OAuth access token. @@ -2613,30 +2802,25 @@ defmodule GoogleApi.DLP.V2.Api.Projects do * `:quotaUser` (*type:* `String.t`) - 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. * `:uploadType` (*type:* `String.t`) - Legacy upload protocol for media (e.g. "media", "multipart"). * `:upload_protocol` (*type:* `String.t`) - Upload protocol for media (e.g. "raw", "multipart"). - * `:body` (*type:* `GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2HybridInspectDlpJobRequest.t`) - + * `:body` (*type:* `GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2CancelDlpJobRequest.t`) - * `opts` (*type:* `keyword()`) - Call options ## Returns - * `{:ok, %GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2HybridInspectResponse{}}` on success + * `{:ok, %GoogleApi.DLP.V2.Model.GoogleProtobufEmpty{}}` on success * `{:error, info}` on failure """ - @spec dlp_projects_locations_dlp_jobs_hybrid_inspect( + @spec dlp_projects_locations_dlp_jobs_cancel( Tesla.Env.client(), String.t(), keyword(), keyword() ) :: - {:ok, GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2HybridInspectResponse.t()} + {:ok, GoogleApi.DLP.V2.Model.GoogleProtobufEmpty.t()} | {:ok, Tesla.Env.t()} | {:ok, list()} | {:error, any()} - def dlp_projects_locations_dlp_jobs_hybrid_inspect( - connection, - name, - optional_params \\ [], - opts \\ [] - ) do + def dlp_projects_locations_dlp_jobs_cancel(connection, name, optional_params \\ [], opts \\ []) do optional_params_config = %{ :"$.xgafv" => :query, :access_token => :query, @@ -2655,7 +2839,7 @@ defmodule GoogleApi.DLP.V2.Api.Projects do request = Request.new() |> Request.method(:post) - |> Request.url("/v2/{+name}:hybridInspect", %{ + |> Request.url("/v2/{+name}:cancel", %{ "name" => URI.encode(name, &URI.char_unreserved?/1) }) |> Request.add_optional_params(optional_params_config, optional_params) @@ -2663,18 +2847,354 @@ defmodule GoogleApi.DLP.V2.Api.Projects do connection |> Connection.execute(request) - |> Response.decode( - opts ++ [struct: %GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2HybridInspectResponse{}] - ) + |> Response.decode(opts ++ [struct: %GoogleApi.DLP.V2.Model.GoogleProtobufEmpty{}]) end @doc """ - Lists DlpJobs that match the specified filter in the request. See https://cloud.google.com/dlp/docs/inspecting-storage and https://cloud.google.com/dlp/docs/compute-risk-analysis to learn more. + Creates a new job to inspect storage or calculate risk metrics. See https://cloud.google.com/sensitive-data-protection/docs/inspecting-storage and https://cloud.google.com/sensitive-data-protection/docs/compute-risk-analysis to learn more. When no InfoTypes or CustomInfoTypes are specified in inspect jobs, the system will automatically choose what detectors to run. By default this may be all types, but may change over time as detectors are updated. ## Parameters * `connection` (*type:* `GoogleApi.DLP.V2.Connection.t`) - Connection to server - * `parent` (*type:* `String.t`) - Required. Parent resource name. The format of this value varies depending on whether you have [specified a processing location](https://cloud.google.com/dlp/docs/specifying-location): + Projects scope, location specified: `projects/`PROJECT_ID`/locations/`LOCATION_ID + Projects scope, no location specified (defaults to global): `projects/`PROJECT_ID The following example `parent` string specifies a parent project with the identifier `example-project`, and specifies the `europe-west3` location for processing data: parent=projects/example-project/locations/europe-west3 + * `parent` (*type:* `String.t`) - Required. Parent resource name. The format of this value varies depending on whether you have [specified a processing location](https://cloud.google.com/sensitive-data-protection/docs/specifying-location): + Projects scope, location specified: `projects/`PROJECT_ID`/locations/`LOCATION_ID + Projects scope, no location specified (defaults to global): `projects/`PROJECT_ID The following example `parent` string specifies a parent project with the identifier `example-project`, and specifies the `europe-west3` location for processing data: parent=projects/example-project/locations/europe-west3 + * `optional_params` (*type:* `keyword()`) - Optional parameters + * `:"$.xgafv"` (*type:* `String.t`) - V1 error format. + * `:access_token` (*type:* `String.t`) - OAuth access token. + * `:alt` (*type:* `String.t`) - Data format for response. + * `:callback` (*type:* `String.t`) - JSONP + * `:fields` (*type:* `String.t`) - Selector specifying which fields to include in a partial response. + * `:key` (*type:* `String.t`) - 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. + * `:oauth_token` (*type:* `String.t`) - OAuth 2.0 token for the current user. + * `:prettyPrint` (*type:* `boolean()`) - Returns response with indentations and line breaks. + * `:quotaUser` (*type:* `String.t`) - 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. + * `:uploadType` (*type:* `String.t`) - Legacy upload protocol for media (e.g. "media", "multipart"). + * `:upload_protocol` (*type:* `String.t`) - Upload protocol for media (e.g. "raw", "multipart"). + * `:body` (*type:* `GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2CreateDlpJobRequest.t`) - + * `opts` (*type:* `keyword()`) - Call options + + ## Returns + + * `{:ok, %GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2DlpJob{}}` on success + * `{:error, info}` on failure + """ + @spec dlp_projects_locations_dlp_jobs_create( + Tesla.Env.client(), + String.t(), + keyword(), + keyword() + ) :: + {:ok, GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2DlpJob.t()} + | {:ok, Tesla.Env.t()} + | {:ok, list()} + | {:error, any()} + def dlp_projects_locations_dlp_jobs_create( + connection, + parent, + optional_params \\ [], + opts \\ [] + ) do + optional_params_config = %{ + :"$.xgafv" => :query, + :access_token => :query, + :alt => :query, + :callback => :query, + :fields => :query, + :key => :query, + :oauth_token => :query, + :prettyPrint => :query, + :quotaUser => :query, + :uploadType => :query, + :upload_protocol => :query, + :body => :body + } + + request = + Request.new() + |> Request.method(:post) + |> Request.url("/v2/{+parent}/dlpJobs", %{ + "parent" => URI.encode(parent, &URI.char_unreserved?/1) + }) + |> Request.add_optional_params(optional_params_config, optional_params) + |> Request.library_version(@library_version) + + connection + |> Connection.execute(request) + |> Response.decode(opts ++ [struct: %GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2DlpJob{}]) + end + + @doc """ + Deletes a long-running DlpJob. This method indicates that the client is no longer interested in the DlpJob result. The job will be canceled if possible. See https://cloud.google.com/sensitive-data-protection/docs/inspecting-storage and https://cloud.google.com/sensitive-data-protection/docs/compute-risk-analysis to learn more. + + ## Parameters + + * `connection` (*type:* `GoogleApi.DLP.V2.Connection.t`) - Connection to server + * `name` (*type:* `String.t`) - Required. The name of the DlpJob resource to be deleted. + * `optional_params` (*type:* `keyword()`) - Optional parameters + * `:"$.xgafv"` (*type:* `String.t`) - V1 error format. + * `:access_token` (*type:* `String.t`) - OAuth access token. + * `:alt` (*type:* `String.t`) - Data format for response. + * `:callback` (*type:* `String.t`) - JSONP + * `:fields` (*type:* `String.t`) - Selector specifying which fields to include in a partial response. + * `:key` (*type:* `String.t`) - 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. + * `:oauth_token` (*type:* `String.t`) - OAuth 2.0 token for the current user. + * `:prettyPrint` (*type:* `boolean()`) - Returns response with indentations and line breaks. + * `:quotaUser` (*type:* `String.t`) - 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. + * `:uploadType` (*type:* `String.t`) - Legacy upload protocol for media (e.g. "media", "multipart"). + * `:upload_protocol` (*type:* `String.t`) - Upload protocol for media (e.g. "raw", "multipart"). + * `opts` (*type:* `keyword()`) - Call options + + ## Returns + + * `{:ok, %GoogleApi.DLP.V2.Model.GoogleProtobufEmpty{}}` on success + * `{:error, info}` on failure + """ + @spec dlp_projects_locations_dlp_jobs_delete( + Tesla.Env.client(), + String.t(), + keyword(), + keyword() + ) :: + {:ok, GoogleApi.DLP.V2.Model.GoogleProtobufEmpty.t()} + | {:ok, Tesla.Env.t()} + | {:ok, list()} + | {:error, any()} + def dlp_projects_locations_dlp_jobs_delete(connection, name, optional_params \\ [], opts \\ []) do + optional_params_config = %{ + :"$.xgafv" => :query, + :access_token => :query, + :alt => :query, + :callback => :query, + :fields => :query, + :key => :query, + :oauth_token => :query, + :prettyPrint => :query, + :quotaUser => :query, + :uploadType => :query, + :upload_protocol => :query + } + + request = + Request.new() + |> Request.method(:delete) + |> Request.url("/v2/{+name}", %{ + "name" => URI.encode(name, &URI.char_unreserved?/1) + }) + |> Request.add_optional_params(optional_params_config, optional_params) + |> Request.library_version(@library_version) + + connection + |> Connection.execute(request) + |> Response.decode(opts ++ [struct: %GoogleApi.DLP.V2.Model.GoogleProtobufEmpty{}]) + end + + @doc """ + Finish a running hybrid DlpJob. Triggers the finalization steps and running of any enabled actions that have not yet run. + + ## Parameters + + * `connection` (*type:* `GoogleApi.DLP.V2.Connection.t`) - Connection to server + * `name` (*type:* `String.t`) - Required. The name of the DlpJob resource to be finished. + * `optional_params` (*type:* `keyword()`) - Optional parameters + * `:"$.xgafv"` (*type:* `String.t`) - V1 error format. + * `:access_token` (*type:* `String.t`) - OAuth access token. + * `:alt` (*type:* `String.t`) - Data format for response. + * `:callback` (*type:* `String.t`) - JSONP + * `:fields` (*type:* `String.t`) - Selector specifying which fields to include in a partial response. + * `:key` (*type:* `String.t`) - 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. + * `:oauth_token` (*type:* `String.t`) - OAuth 2.0 token for the current user. + * `:prettyPrint` (*type:* `boolean()`) - Returns response with indentations and line breaks. + * `:quotaUser` (*type:* `String.t`) - 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. + * `:uploadType` (*type:* `String.t`) - Legacy upload protocol for media (e.g. "media", "multipart"). + * `:upload_protocol` (*type:* `String.t`) - Upload protocol for media (e.g. "raw", "multipart"). + * `:body` (*type:* `GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2FinishDlpJobRequest.t`) - + * `opts` (*type:* `keyword()`) - Call options + + ## Returns + + * `{:ok, %GoogleApi.DLP.V2.Model.GoogleProtobufEmpty{}}` on success + * `{:error, info}` on failure + """ + @spec dlp_projects_locations_dlp_jobs_finish( + Tesla.Env.client(), + String.t(), + keyword(), + keyword() + ) :: + {:ok, GoogleApi.DLP.V2.Model.GoogleProtobufEmpty.t()} + | {:ok, Tesla.Env.t()} + | {:ok, list()} + | {:error, any()} + def dlp_projects_locations_dlp_jobs_finish(connection, name, optional_params \\ [], opts \\ []) do + optional_params_config = %{ + :"$.xgafv" => :query, + :access_token => :query, + :alt => :query, + :callback => :query, + :fields => :query, + :key => :query, + :oauth_token => :query, + :prettyPrint => :query, + :quotaUser => :query, + :uploadType => :query, + :upload_protocol => :query, + :body => :body + } + + request = + Request.new() + |> Request.method(:post) + |> Request.url("/v2/{+name}:finish", %{ + "name" => URI.encode(name, &URI.char_unreserved?/1) + }) + |> Request.add_optional_params(optional_params_config, optional_params) + |> Request.library_version(@library_version) + + connection + |> Connection.execute(request) + |> Response.decode(opts ++ [struct: %GoogleApi.DLP.V2.Model.GoogleProtobufEmpty{}]) + end + + @doc """ + Gets the latest state of a long-running DlpJob. See https://cloud.google.com/sensitive-data-protection/docs/inspecting-storage and https://cloud.google.com/sensitive-data-protection/docs/compute-risk-analysis to learn more. + + ## Parameters + + * `connection` (*type:* `GoogleApi.DLP.V2.Connection.t`) - Connection to server + * `name` (*type:* `String.t`) - Required. The name of the DlpJob resource. + * `optional_params` (*type:* `keyword()`) - Optional parameters + * `:"$.xgafv"` (*type:* `String.t`) - V1 error format. + * `:access_token` (*type:* `String.t`) - OAuth access token. + * `:alt` (*type:* `String.t`) - Data format for response. + * `:callback` (*type:* `String.t`) - JSONP + * `:fields` (*type:* `String.t`) - Selector specifying which fields to include in a partial response. + * `:key` (*type:* `String.t`) - 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. + * `:oauth_token` (*type:* `String.t`) - OAuth 2.0 token for the current user. + * `:prettyPrint` (*type:* `boolean()`) - Returns response with indentations and line breaks. + * `:quotaUser` (*type:* `String.t`) - 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. + * `:uploadType` (*type:* `String.t`) - Legacy upload protocol for media (e.g. "media", "multipart"). + * `:upload_protocol` (*type:* `String.t`) - Upload protocol for media (e.g. "raw", "multipart"). + * `opts` (*type:* `keyword()`) - Call options + + ## Returns + + * `{:ok, %GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2DlpJob{}}` on success + * `{:error, info}` on failure + """ + @spec dlp_projects_locations_dlp_jobs_get(Tesla.Env.client(), String.t(), keyword(), keyword()) :: + {:ok, GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2DlpJob.t()} + | {:ok, Tesla.Env.t()} + | {:ok, list()} + | {:error, any()} + def dlp_projects_locations_dlp_jobs_get(connection, name, optional_params \\ [], opts \\ []) do + optional_params_config = %{ + :"$.xgafv" => :query, + :access_token => :query, + :alt => :query, + :callback => :query, + :fields => :query, + :key => :query, + :oauth_token => :query, + :prettyPrint => :query, + :quotaUser => :query, + :uploadType => :query, + :upload_protocol => :query + } + + request = + Request.new() + |> Request.method(:get) + |> Request.url("/v2/{+name}", %{ + "name" => URI.encode(name, &URI.char_unreserved?/1) + }) + |> Request.add_optional_params(optional_params_config, optional_params) + |> Request.library_version(@library_version) + + connection + |> Connection.execute(request) + |> Response.decode(opts ++ [struct: %GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2DlpJob{}]) + end + + @doc """ + Inspect hybrid content and store findings to a job. To review the findings, inspect the job. Inspection will occur asynchronously. + + ## Parameters + + * `connection` (*type:* `GoogleApi.DLP.V2.Connection.t`) - Connection to server + * `name` (*type:* `String.t`) - Required. Resource name of the job to execute a hybrid inspect on, for example `projects/dlp-test-project/dlpJob/53234423`. + * `optional_params` (*type:* `keyword()`) - Optional parameters + * `:"$.xgafv"` (*type:* `String.t`) - V1 error format. + * `:access_token` (*type:* `String.t`) - OAuth access token. + * `:alt` (*type:* `String.t`) - Data format for response. + * `:callback` (*type:* `String.t`) - JSONP + * `:fields` (*type:* `String.t`) - Selector specifying which fields to include in a partial response. + * `:key` (*type:* `String.t`) - 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. + * `:oauth_token` (*type:* `String.t`) - OAuth 2.0 token for the current user. + * `:prettyPrint` (*type:* `boolean()`) - Returns response with indentations and line breaks. + * `:quotaUser` (*type:* `String.t`) - 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. + * `:uploadType` (*type:* `String.t`) - Legacy upload protocol for media (e.g. "media", "multipart"). + * `:upload_protocol` (*type:* `String.t`) - Upload protocol for media (e.g. "raw", "multipart"). + * `:body` (*type:* `GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2HybridInspectDlpJobRequest.t`) - + * `opts` (*type:* `keyword()`) - Call options + + ## Returns + + * `{:ok, %GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2HybridInspectResponse{}}` on success + * `{:error, info}` on failure + """ + @spec dlp_projects_locations_dlp_jobs_hybrid_inspect( + Tesla.Env.client(), + String.t(), + keyword(), + keyword() + ) :: + {:ok, GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2HybridInspectResponse.t()} + | {:ok, Tesla.Env.t()} + | {:ok, list()} + | {:error, any()} + def dlp_projects_locations_dlp_jobs_hybrid_inspect( + connection, + name, + optional_params \\ [], + opts \\ [] + ) do + optional_params_config = %{ + :"$.xgafv" => :query, + :access_token => :query, + :alt => :query, + :callback => :query, + :fields => :query, + :key => :query, + :oauth_token => :query, + :prettyPrint => :query, + :quotaUser => :query, + :uploadType => :query, + :upload_protocol => :query, + :body => :body + } + + request = + Request.new() + |> Request.method(:post) + |> Request.url("/v2/{+name}:hybridInspect", %{ + "name" => URI.encode(name, &URI.char_unreserved?/1) + }) + |> Request.add_optional_params(optional_params_config, optional_params) + |> Request.library_version(@library_version) + + connection + |> Connection.execute(request) + |> Response.decode( + opts ++ [struct: %GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2HybridInspectResponse{}] + ) + end + + @doc """ + Lists DlpJobs that match the specified filter in the request. See https://cloud.google.com/sensitive-data-protection/docs/inspecting-storage and https://cloud.google.com/sensitive-data-protection/docs/compute-risk-analysis to learn more. + + ## Parameters + + * `connection` (*type:* `GoogleApi.DLP.V2.Connection.t`) - Connection to server + * `parent` (*type:* `String.t`) - Required. Parent resource name. The format of this value varies depending on whether you have [specified a processing location](https://cloud.google.com/sensitive-data-protection/docs/specifying-location): + Projects scope, location specified: `projects/`PROJECT_ID`/locations/`LOCATION_ID + Projects scope, no location specified (defaults to global): `projects/`PROJECT_ID The following example `parent` string specifies a parent project with the identifier `example-project`, and specifies the `europe-west3` location for processing data: parent=projects/example-project/locations/europe-west3 * `optional_params` (*type:* `keyword()`) - Optional parameters * `:"$.xgafv"` (*type:* `String.t`) - V1 error format. * `:access_token` (*type:* `String.t`) - OAuth access token. @@ -2689,7 +3209,7 @@ defmodule GoogleApi.DLP.V2.Api.Projects do * `:upload_protocol` (*type:* `String.t`) - Upload protocol for media (e.g. "raw", "multipart"). * `:filter` (*type:* `String.t`) - Allows filtering. Supported syntax: * Filter expressions are made up of one or more restrictions. * Restrictions can be combined by `AND` or `OR` logical operators. A sequence of restrictions implicitly uses `AND`. * A restriction has the form of `{field} {operator} {value}`. * Supported fields/values for inspect jobs: - `state` - PENDING|RUNNING|CANCELED|FINISHED|FAILED - `inspected_storage` - DATASTORE|CLOUD_STORAGE|BIGQUERY - `trigger_name` - The name of the trigger that created the job. - 'end_time` - Corresponds to the time the job finished. - 'start_time` - Corresponds to the time the job finished. * Supported fields for risk analysis jobs: - `state` - RUNNING|CANCELED|FINISHED|FAILED - 'end_time` - Corresponds to the time the job finished. - 'start_time` - Corresponds to the time the job finished. * The operator must be `=` or `!=`. Examples: * inspected_storage = cloud_storage AND state = done * inspected_storage = cloud_storage OR inspected_storage = bigquery * inspected_storage = cloud_storage AND (state = done OR state = canceled) * end_time > \\"2017-12-12T00:00:00+00:00\\" The length of this field should be no more than 500 characters. * `:locationId` (*type:* `String.t`) - Deprecated. This field has no effect. - * `:orderBy` (*type:* `String.t`) - Comma separated list of fields to order by, followed by `asc` or `desc` postfix. This list is case-insensitive, default sorting order is ascending, redundant space characters are insignificant. Example: `name asc, end_time asc, create_time desc` Supported fields are: - `create_time`: corresponds to the time the job was created. - `end_time`: corresponds to the time the job ended. - `name`: corresponds to the job's name. - `state`: corresponds to `state` + * `:orderBy` (*type:* `String.t`) - Comma separated list of fields to order by, followed by `asc` or `desc` postfix. This list is case insensitive. The default sorting order is ascending. Redundant space characters are insignificant. Example: `name asc, end_time asc, create_time desc` Supported fields are: - `create_time`: corresponds to the time the job was created. - `end_time`: corresponds to the time the job ended. - `name`: corresponds to the job's name. - `state`: corresponds to `state` * `:pageSize` (*type:* `integer()`) - The standard list page size. * `:pageToken` (*type:* `String.t`) - The standard list page token. * `:type` (*type:* `String.t`) - The type of job. Defaults to `DlpJobType.INSPECT` @@ -2697,15 +3217,231 @@ defmodule GoogleApi.DLP.V2.Api.Projects do ## Returns - * `{:ok, %GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2ListDlpJobsResponse{}}` on success + * `{:ok, %GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2ListDlpJobsResponse{}}` on success + * `{:error, info}` on failure + """ + @spec dlp_projects_locations_dlp_jobs_list(Tesla.Env.client(), String.t(), keyword(), keyword()) :: + {:ok, GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2ListDlpJobsResponse.t()} + | {:ok, Tesla.Env.t()} + | {:ok, list()} + | {:error, any()} + def dlp_projects_locations_dlp_jobs_list(connection, parent, optional_params \\ [], opts \\ []) do + optional_params_config = %{ + :"$.xgafv" => :query, + :access_token => :query, + :alt => :query, + :callback => :query, + :fields => :query, + :key => :query, + :oauth_token => :query, + :prettyPrint => :query, + :quotaUser => :query, + :uploadType => :query, + :upload_protocol => :query, + :filter => :query, + :locationId => :query, + :orderBy => :query, + :pageSize => :query, + :pageToken => :query, + :type => :query + } + + request = + Request.new() + |> Request.method(:get) + |> Request.url("/v2/{+parent}/dlpJobs", %{ + "parent" => URI.encode(parent, &URI.char_unreserved?/1) + }) + |> Request.add_optional_params(optional_params_config, optional_params) + |> Request.library_version(@library_version) + + connection + |> Connection.execute(request) + |> Response.decode( + opts ++ [struct: %GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2ListDlpJobsResponse{}] + ) + end + + @doc """ + Redacts potentially sensitive info from an image. This method has limits on input size, processing time, and output size. See https://cloud.google.com/sensitive-data-protection/docs/redacting-sensitive-data-images to learn more. When no InfoTypes or CustomInfoTypes are specified in this request, the system will automatically choose what detectors to run. By default this may be all types, but may change over time as detectors are updated. + + ## Parameters + + * `connection` (*type:* `GoogleApi.DLP.V2.Connection.t`) - Connection to server + * `parent` (*type:* `String.t`) - Parent resource name. The format of this value varies depending on whether you have [specified a processing location](https://cloud.google.com/sensitive-data-protection/docs/specifying-location): + Projects scope, location specified: `projects/`PROJECT_ID`/locations/`LOCATION_ID + Projects scope, no location specified (defaults to global): `projects/`PROJECT_ID The following example `parent` string specifies a parent project with the identifier `example-project`, and specifies the `europe-west3` location for processing data: parent=projects/example-project/locations/europe-west3 + * `optional_params` (*type:* `keyword()`) - Optional parameters + * `:"$.xgafv"` (*type:* `String.t`) - V1 error format. + * `:access_token` (*type:* `String.t`) - OAuth access token. + * `:alt` (*type:* `String.t`) - Data format for response. + * `:callback` (*type:* `String.t`) - JSONP + * `:fields` (*type:* `String.t`) - Selector specifying which fields to include in a partial response. + * `:key` (*type:* `String.t`) - 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. + * `:oauth_token` (*type:* `String.t`) - OAuth 2.0 token for the current user. + * `:prettyPrint` (*type:* `boolean()`) - Returns response with indentations and line breaks. + * `:quotaUser` (*type:* `String.t`) - 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. + * `:uploadType` (*type:* `String.t`) - Legacy upload protocol for media (e.g. "media", "multipart"). + * `:upload_protocol` (*type:* `String.t`) - Upload protocol for media (e.g. "raw", "multipart"). + * `:body` (*type:* `GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2RedactImageRequest.t`) - + * `opts` (*type:* `keyword()`) - Call options + + ## Returns + + * `{:ok, %GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2RedactImageResponse{}}` on success + * `{:error, info}` on failure + """ + @spec dlp_projects_locations_image_redact(Tesla.Env.client(), String.t(), keyword(), keyword()) :: + {:ok, GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2RedactImageResponse.t()} + | {:ok, Tesla.Env.t()} + | {:ok, list()} + | {:error, any()} + def dlp_projects_locations_image_redact(connection, parent, optional_params \\ [], opts \\ []) do + optional_params_config = %{ + :"$.xgafv" => :query, + :access_token => :query, + :alt => :query, + :callback => :query, + :fields => :query, + :key => :query, + :oauth_token => :query, + :prettyPrint => :query, + :quotaUser => :query, + :uploadType => :query, + :upload_protocol => :query, + :body => :body + } + + request = + Request.new() + |> Request.method(:post) + |> Request.url("/v2/{+parent}/image:redact", %{ + "parent" => URI.encode(parent, &URI.char_unreserved?/1) + }) + |> Request.add_optional_params(optional_params_config, optional_params) + |> Request.library_version(@library_version) + + connection + |> Connection.execute(request) + |> Response.decode( + opts ++ [struct: %GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2RedactImageResponse{}] + ) + end + + @doc """ + Creates an InspectTemplate for reusing frequently used configuration for inspecting content, images, and storage. See https://cloud.google.com/sensitive-data-protection/docs/creating-templates to learn more. + + ## Parameters + + * `connection` (*type:* `GoogleApi.DLP.V2.Connection.t`) - Connection to server + * `parent` (*type:* `String.t`) - Required. Parent resource name. The format of this value varies depending on the scope of the request (project or organization) and whether you have [specified a processing location](https://cloud.google.com/sensitive-data-protection/docs/specifying-location): + Projects scope, location specified: `projects/`PROJECT_ID`/locations/`LOCATION_ID + Projects scope, no location specified (defaults to global): `projects/`PROJECT_ID + Organizations scope, location specified: `organizations/`ORG_ID`/locations/`LOCATION_ID + Organizations scope, no location specified (defaults to global): `organizations/`ORG_ID The following example `parent` string specifies a parent project with the identifier `example-project`, and specifies the `europe-west3` location for processing data: parent=projects/example-project/locations/europe-west3 + * `optional_params` (*type:* `keyword()`) - Optional parameters + * `:"$.xgafv"` (*type:* `String.t`) - V1 error format. + * `:access_token` (*type:* `String.t`) - OAuth access token. + * `:alt` (*type:* `String.t`) - Data format for response. + * `:callback` (*type:* `String.t`) - JSONP + * `:fields` (*type:* `String.t`) - Selector specifying which fields to include in a partial response. + * `:key` (*type:* `String.t`) - 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. + * `:oauth_token` (*type:* `String.t`) - OAuth 2.0 token for the current user. + * `:prettyPrint` (*type:* `boolean()`) - Returns response with indentations and line breaks. + * `:quotaUser` (*type:* `String.t`) - 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. + * `:uploadType` (*type:* `String.t`) - Legacy upload protocol for media (e.g. "media", "multipart"). + * `:upload_protocol` (*type:* `String.t`) - Upload protocol for media (e.g. "raw", "multipart"). + * `:body` (*type:* `GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2CreateInspectTemplateRequest.t`) - + * `opts` (*type:* `keyword()`) - Call options + + ## Returns + + * `{:ok, %GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2InspectTemplate{}}` on success + * `{:error, info}` on failure + """ + @spec dlp_projects_locations_inspect_templates_create( + Tesla.Env.client(), + String.t(), + keyword(), + keyword() + ) :: + {:ok, GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2InspectTemplate.t()} + | {:ok, Tesla.Env.t()} + | {:ok, list()} + | {:error, any()} + def dlp_projects_locations_inspect_templates_create( + connection, + parent, + optional_params \\ [], + opts \\ [] + ) do + optional_params_config = %{ + :"$.xgafv" => :query, + :access_token => :query, + :alt => :query, + :callback => :query, + :fields => :query, + :key => :query, + :oauth_token => :query, + :prettyPrint => :query, + :quotaUser => :query, + :uploadType => :query, + :upload_protocol => :query, + :body => :body + } + + request = + Request.new() + |> Request.method(:post) + |> Request.url("/v2/{+parent}/inspectTemplates", %{ + "parent" => URI.encode(parent, &URI.char_unreserved?/1) + }) + |> Request.add_optional_params(optional_params_config, optional_params) + |> Request.library_version(@library_version) + + connection + |> Connection.execute(request) + |> Response.decode( + opts ++ [struct: %GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2InspectTemplate{}] + ) + end + + @doc """ + Deletes an InspectTemplate. See https://cloud.google.com/sensitive-data-protection/docs/creating-templates to learn more. + + ## Parameters + + * `connection` (*type:* `GoogleApi.DLP.V2.Connection.t`) - Connection to server + * `name` (*type:* `String.t`) - Required. Resource name of the organization and inspectTemplate to be deleted, for example `organizations/433245324/inspectTemplates/432452342` or projects/project-id/inspectTemplates/432452342. + * `optional_params` (*type:* `keyword()`) - Optional parameters + * `:"$.xgafv"` (*type:* `String.t`) - V1 error format. + * `:access_token` (*type:* `String.t`) - OAuth access token. + * `:alt` (*type:* `String.t`) - Data format for response. + * `:callback` (*type:* `String.t`) - JSONP + * `:fields` (*type:* `String.t`) - Selector specifying which fields to include in a partial response. + * `:key` (*type:* `String.t`) - 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. + * `:oauth_token` (*type:* `String.t`) - OAuth 2.0 token for the current user. + * `:prettyPrint` (*type:* `boolean()`) - Returns response with indentations and line breaks. + * `:quotaUser` (*type:* `String.t`) - 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. + * `:uploadType` (*type:* `String.t`) - Legacy upload protocol for media (e.g. "media", "multipart"). + * `:upload_protocol` (*type:* `String.t`) - Upload protocol for media (e.g. "raw", "multipart"). + * `opts` (*type:* `keyword()`) - Call options + + ## Returns + + * `{:ok, %GoogleApi.DLP.V2.Model.GoogleProtobufEmpty{}}` on success * `{:error, info}` on failure """ - @spec dlp_projects_locations_dlp_jobs_list(Tesla.Env.client(), String.t(), keyword(), keyword()) :: - {:ok, GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2ListDlpJobsResponse.t()} + @spec dlp_projects_locations_inspect_templates_delete( + Tesla.Env.client(), + String.t(), + keyword(), + keyword() + ) :: + {:ok, GoogleApi.DLP.V2.Model.GoogleProtobufEmpty.t()} | {:ok, Tesla.Env.t()} | {:ok, list()} | {:error, any()} - def dlp_projects_locations_dlp_jobs_list(connection, parent, optional_params \\ [], opts \\ []) do + def dlp_projects_locations_inspect_templates_delete( + connection, + name, + optional_params \\ [], + opts \\ [] + ) do optional_params_config = %{ :"$.xgafv" => :query, :access_token => :query, @@ -2717,38 +3453,30 @@ defmodule GoogleApi.DLP.V2.Api.Projects do :prettyPrint => :query, :quotaUser => :query, :uploadType => :query, - :upload_protocol => :query, - :filter => :query, - :locationId => :query, - :orderBy => :query, - :pageSize => :query, - :pageToken => :query, - :type => :query + :upload_protocol => :query } request = Request.new() - |> Request.method(:get) - |> Request.url("/v2/{+parent}/dlpJobs", %{ - "parent" => URI.encode(parent, &URI.char_unreserved?/1) + |> Request.method(:delete) + |> Request.url("/v2/{+name}", %{ + "name" => URI.encode(name, &URI.char_unreserved?/1) }) |> Request.add_optional_params(optional_params_config, optional_params) |> Request.library_version(@library_version) connection |> Connection.execute(request) - |> Response.decode( - opts ++ [struct: %GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2ListDlpJobsResponse{}] - ) + |> Response.decode(opts ++ [struct: %GoogleApi.DLP.V2.Model.GoogleProtobufEmpty{}]) end @doc """ - Redacts potentially sensitive info from an image. This method has limits on input size, processing time, and output size. See https://cloud.google.com/dlp/docs/redacting-sensitive-data-images to learn more. When no InfoTypes or CustomInfoTypes are specified in this request, the system will automatically choose what detectors to run. By default this may be all types, but may change over time as detectors are updated. + Gets an InspectTemplate. See https://cloud.google.com/sensitive-data-protection/docs/creating-templates to learn more. ## Parameters * `connection` (*type:* `GoogleApi.DLP.V2.Connection.t`) - Connection to server - * `parent` (*type:* `String.t`) - Parent resource name. The format of this value varies depending on whether you have [specified a processing location](https://cloud.google.com/dlp/docs/specifying-location): + Projects scope, location specified: `projects/`PROJECT_ID`/locations/`LOCATION_ID + Projects scope, no location specified (defaults to global): `projects/`PROJECT_ID The following example `parent` string specifies a parent project with the identifier `example-project`, and specifies the `europe-west3` location for processing data: parent=projects/example-project/locations/europe-west3 + * `name` (*type:* `String.t`) - Required. Resource name of the organization and inspectTemplate to be read, for example `organizations/433245324/inspectTemplates/432452342` or projects/project-id/inspectTemplates/432452342. * `optional_params` (*type:* `keyword()`) - Optional parameters * `:"$.xgafv"` (*type:* `String.t`) - V1 error format. * `:access_token` (*type:* `String.t`) - OAuth access token. @@ -2761,20 +3489,29 @@ defmodule GoogleApi.DLP.V2.Api.Projects do * `:quotaUser` (*type:* `String.t`) - 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. * `:uploadType` (*type:* `String.t`) - Legacy upload protocol for media (e.g. "media", "multipart"). * `:upload_protocol` (*type:* `String.t`) - Upload protocol for media (e.g. "raw", "multipart"). - * `:body` (*type:* `GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2RedactImageRequest.t`) - * `opts` (*type:* `keyword()`) - Call options ## Returns - * `{:ok, %GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2RedactImageResponse{}}` on success + * `{:ok, %GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2InspectTemplate{}}` on success * `{:error, info}` on failure """ - @spec dlp_projects_locations_image_redact(Tesla.Env.client(), String.t(), keyword(), keyword()) :: - {:ok, GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2RedactImageResponse.t()} + @spec dlp_projects_locations_inspect_templates_get( + Tesla.Env.client(), + String.t(), + keyword(), + keyword() + ) :: + {:ok, GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2InspectTemplate.t()} | {:ok, Tesla.Env.t()} | {:ok, list()} | {:error, any()} - def dlp_projects_locations_image_redact(connection, parent, optional_params \\ [], opts \\ []) do + def dlp_projects_locations_inspect_templates_get( + connection, + name, + optional_params \\ [], + opts \\ [] + ) do optional_params_config = %{ :"$.xgafv" => :query, :access_token => :query, @@ -2786,15 +3523,14 @@ defmodule GoogleApi.DLP.V2.Api.Projects do :prettyPrint => :query, :quotaUser => :query, :uploadType => :query, - :upload_protocol => :query, - :body => :body + :upload_protocol => :query } request = Request.new() - |> Request.method(:post) - |> Request.url("/v2/{+parent}/image:redact", %{ - "parent" => URI.encode(parent, &URI.char_unreserved?/1) + |> Request.method(:get) + |> Request.url("/v2/{+name}", %{ + "name" => URI.encode(name, &URI.char_unreserved?/1) }) |> Request.add_optional_params(optional_params_config, optional_params) |> Request.library_version(@library_version) @@ -2802,17 +3538,17 @@ defmodule GoogleApi.DLP.V2.Api.Projects do connection |> Connection.execute(request) |> Response.decode( - opts ++ [struct: %GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2RedactImageResponse{}] + opts ++ [struct: %GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2InspectTemplate{}] ) end @doc """ - Creates an InspectTemplate for reusing frequently used configuration for inspecting content, images, and storage. See https://cloud.google.com/dlp/docs/creating-templates to learn more. + Lists InspectTemplates. See https://cloud.google.com/sensitive-data-protection/docs/creating-templates to learn more. ## Parameters * `connection` (*type:* `GoogleApi.DLP.V2.Connection.t`) - Connection to server - * `parent` (*type:* `String.t`) - Required. Parent resource name. The format of this value varies depending on the scope of the request (project or organization) and whether you have [specified a processing location](https://cloud.google.com/dlp/docs/specifying-location): + Projects scope, location specified: `projects/`PROJECT_ID`/locations/`LOCATION_ID + Projects scope, no location specified (defaults to global): `projects/`PROJECT_ID + Organizations scope, location specified: `organizations/`ORG_ID`/locations/`LOCATION_ID + Organizations scope, no location specified (defaults to global): `organizations/`ORG_ID The following example `parent` string specifies a parent project with the identifier `example-project`, and specifies the `europe-west3` location for processing data: parent=projects/example-project/locations/europe-west3 + * `parent` (*type:* `String.t`) - Required. Parent resource name. The format of this value varies depending on the scope of the request (project or organization) and whether you have [specified a processing location](https://cloud.google.com/sensitive-data-protection/docs/specifying-location): + Projects scope, location specified: `projects/`PROJECT_ID`/locations/`LOCATION_ID + Projects scope, no location specified (defaults to global): `projects/`PROJECT_ID + Organizations scope, location specified: `organizations/`ORG_ID`/locations/`LOCATION_ID + Organizations scope, no location specified (defaults to global): `organizations/`ORG_ID The following example `parent` string specifies a parent project with the identifier `example-project`, and specifies the `europe-west3` location for processing data: parent=projects/example-project/locations/europe-west3 * `optional_params` (*type:* `keyword()`) - Optional parameters * `:"$.xgafv"` (*type:* `String.t`) - V1 error format. * `:access_token` (*type:* `String.t`) - OAuth access token. @@ -2825,25 +3561,28 @@ defmodule GoogleApi.DLP.V2.Api.Projects do * `:quotaUser` (*type:* `String.t`) - 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. * `:uploadType` (*type:* `String.t`) - Legacy upload protocol for media (e.g. "media", "multipart"). * `:upload_protocol` (*type:* `String.t`) - Upload protocol for media (e.g. "raw", "multipart"). - * `:body` (*type:* `GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2CreateInspectTemplateRequest.t`) - + * `:locationId` (*type:* `String.t`) - Deprecated. This field has no effect. + * `:orderBy` (*type:* `String.t`) - Comma separated list of fields to order by, followed by `asc` or `desc` postfix. This list is case insensitive. The default sorting order is ascending. Redundant space characters are insignificant. Example: `name asc,update_time, create_time desc` Supported fields are: - `create_time`: corresponds to the time the template was created. - `update_time`: corresponds to the time the template was last updated. - `name`: corresponds to the template's name. - `display_name`: corresponds to the template's display name. + * `:pageSize` (*type:* `integer()`) - Size of the page. This value can be limited by the server. If zero server returns a page of max size 100. + * `:pageToken` (*type:* `String.t`) - Page token to continue retrieval. Comes from the previous call to `ListInspectTemplates`. * `opts` (*type:* `keyword()`) - Call options ## Returns - * `{:ok, %GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2InspectTemplate{}}` on success + * `{:ok, %GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2ListInspectTemplatesResponse{}}` on success * `{:error, info}` on failure """ - @spec dlp_projects_locations_inspect_templates_create( + @spec dlp_projects_locations_inspect_templates_list( Tesla.Env.client(), String.t(), keyword(), keyword() ) :: - {:ok, GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2InspectTemplate.t()} + {:ok, GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2ListInspectTemplatesResponse.t()} | {:ok, Tesla.Env.t()} | {:ok, list()} | {:error, any()} - def dlp_projects_locations_inspect_templates_create( + def dlp_projects_locations_inspect_templates_list( connection, parent, optional_params \\ [], @@ -2861,12 +3600,15 @@ defmodule GoogleApi.DLP.V2.Api.Projects do :quotaUser => :query, :uploadType => :query, :upload_protocol => :query, - :body => :body + :locationId => :query, + :orderBy => :query, + :pageSize => :query, + :pageToken => :query } request = Request.new() - |> Request.method(:post) + |> Request.method(:get) |> Request.url("/v2/{+parent}/inspectTemplates", %{ "parent" => URI.encode(parent, &URI.char_unreserved?/1) }) @@ -2876,17 +3618,17 @@ defmodule GoogleApi.DLP.V2.Api.Projects do connection |> Connection.execute(request) |> Response.decode( - opts ++ [struct: %GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2InspectTemplate{}] + opts ++ [struct: %GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2ListInspectTemplatesResponse{}] ) end @doc """ - Deletes an InspectTemplate. See https://cloud.google.com/dlp/docs/creating-templates to learn more. + Updates the InspectTemplate. See https://cloud.google.com/sensitive-data-protection/docs/creating-templates to learn more. ## Parameters * `connection` (*type:* `GoogleApi.DLP.V2.Connection.t`) - Connection to server - * `name` (*type:* `String.t`) - Required. Resource name of the organization and inspectTemplate to be deleted, for example `organizations/433245324/inspectTemplates/432452342` or projects/project-id/inspectTemplates/432452342. + * `name` (*type:* `String.t`) - Required. Resource name of organization and inspectTemplate to be updated, for example `organizations/433245324/inspectTemplates/432452342` or projects/project-id/inspectTemplates/432452342. * `optional_params` (*type:* `keyword()`) - Optional parameters * `:"$.xgafv"` (*type:* `String.t`) - V1 error format. * `:access_token` (*type:* `String.t`) - OAuth access token. @@ -2899,24 +3641,25 @@ defmodule GoogleApi.DLP.V2.Api.Projects do * `:quotaUser` (*type:* `String.t`) - 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. * `:uploadType` (*type:* `String.t`) - Legacy upload protocol for media (e.g. "media", "multipart"). * `:upload_protocol` (*type:* `String.t`) - Upload protocol for media (e.g. "raw", "multipart"). + * `:body` (*type:* `GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2UpdateInspectTemplateRequest.t`) - * `opts` (*type:* `keyword()`) - Call options ## Returns - * `{:ok, %GoogleApi.DLP.V2.Model.GoogleProtobufEmpty{}}` on success + * `{:ok, %GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2InspectTemplate{}}` on success * `{:error, info}` on failure """ - @spec dlp_projects_locations_inspect_templates_delete( + @spec dlp_projects_locations_inspect_templates_patch( Tesla.Env.client(), String.t(), keyword(), keyword() ) :: - {:ok, GoogleApi.DLP.V2.Model.GoogleProtobufEmpty.t()} + {:ok, GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2InspectTemplate.t()} | {:ok, Tesla.Env.t()} | {:ok, list()} | {:error, any()} - def dlp_projects_locations_inspect_templates_delete( + def dlp_projects_locations_inspect_templates_patch( connection, name, optional_params \\ [], @@ -2933,12 +3676,13 @@ defmodule GoogleApi.DLP.V2.Api.Projects do :prettyPrint => :query, :quotaUser => :query, :uploadType => :query, - :upload_protocol => :query + :upload_protocol => :query, + :body => :body } request = Request.new() - |> Request.method(:delete) + |> Request.method(:patch) |> Request.url("/v2/{+name}", %{ "name" => URI.encode(name, &URI.char_unreserved?/1) }) @@ -2947,16 +3691,18 @@ defmodule GoogleApi.DLP.V2.Api.Projects do connection |> Connection.execute(request) - |> Response.decode(opts ++ [struct: %GoogleApi.DLP.V2.Model.GoogleProtobufEmpty{}]) + |> Response.decode( + opts ++ [struct: %GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2InspectTemplate{}] + ) end @doc """ - Gets an InspectTemplate. See https://cloud.google.com/dlp/docs/creating-templates to learn more. + Activate a job trigger. Causes the immediate execute of a trigger instead of waiting on the trigger event to occur. ## Parameters * `connection` (*type:* `GoogleApi.DLP.V2.Connection.t`) - Connection to server - * `name` (*type:* `String.t`) - Required. Resource name of the organization and inspectTemplate to be read, for example `organizations/433245324/inspectTemplates/432452342` or projects/project-id/inspectTemplates/432452342. + * `name` (*type:* `String.t`) - Required. Resource name of the trigger to activate, for example `projects/dlp-test-project/jobTriggers/53234423`. * `optional_params` (*type:* `keyword()`) - Optional parameters * `:"$.xgafv"` (*type:* `String.t`) - V1 error format. * `:access_token` (*type:* `String.t`) - OAuth access token. @@ -2969,24 +3715,25 @@ defmodule GoogleApi.DLP.V2.Api.Projects do * `:quotaUser` (*type:* `String.t`) - 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. * `:uploadType` (*type:* `String.t`) - Legacy upload protocol for media (e.g. "media", "multipart"). * `:upload_protocol` (*type:* `String.t`) - Upload protocol for media (e.g. "raw", "multipart"). + * `:body` (*type:* `GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2ActivateJobTriggerRequest.t`) - * `opts` (*type:* `keyword()`) - Call options ## Returns - * `{:ok, %GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2InspectTemplate{}}` on success + * `{:ok, %GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2DlpJob{}}` on success * `{:error, info}` on failure """ - @spec dlp_projects_locations_inspect_templates_get( + @spec dlp_projects_locations_job_triggers_activate( Tesla.Env.client(), String.t(), keyword(), keyword() ) :: - {:ok, GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2InspectTemplate.t()} + {:ok, GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2DlpJob.t()} | {:ok, Tesla.Env.t()} | {:ok, list()} | {:error, any()} - def dlp_projects_locations_inspect_templates_get( + def dlp_projects_locations_job_triggers_activate( connection, name, optional_params \\ [], @@ -3003,13 +3750,14 @@ defmodule GoogleApi.DLP.V2.Api.Projects do :prettyPrint => :query, :quotaUser => :query, :uploadType => :query, - :upload_protocol => :query + :upload_protocol => :query, + :body => :body } request = Request.new() - |> Request.method(:get) - |> Request.url("/v2/{+name}", %{ + |> Request.method(:post) + |> Request.url("/v2/{+name}:activate", %{ "name" => URI.encode(name, &URI.char_unreserved?/1) }) |> Request.add_optional_params(optional_params_config, optional_params) @@ -3017,18 +3765,16 @@ defmodule GoogleApi.DLP.V2.Api.Projects do connection |> Connection.execute(request) - |> Response.decode( - opts ++ [struct: %GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2InspectTemplate{}] - ) + |> Response.decode(opts ++ [struct: %GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2DlpJob{}]) end @doc """ - Lists InspectTemplates. See https://cloud.google.com/dlp/docs/creating-templates to learn more. + Creates a job trigger to run DLP actions such as scanning storage for sensitive information on a set schedule. See https://cloud.google.com/sensitive-data-protection/docs/creating-job-triggers to learn more. ## Parameters * `connection` (*type:* `GoogleApi.DLP.V2.Connection.t`) - Connection to server - * `parent` (*type:* `String.t`) - Required. Parent resource name. The format of this value varies depending on the scope of the request (project or organization) and whether you have [specified a processing location](https://cloud.google.com/dlp/docs/specifying-location): + Projects scope, location specified: `projects/`PROJECT_ID`/locations/`LOCATION_ID + Projects scope, no location specified (defaults to global): `projects/`PROJECT_ID + Organizations scope, location specified: `organizations/`ORG_ID`/locations/`LOCATION_ID + Organizations scope, no location specified (defaults to global): `organizations/`ORG_ID The following example `parent` string specifies a parent project with the identifier `example-project`, and specifies the `europe-west3` location for processing data: parent=projects/example-project/locations/europe-west3 + * `parent` (*type:* `String.t`) - Required. Parent resource name. The format of this value varies depending on whether you have [specified a processing location](https://cloud.google.com/sensitive-data-protection/docs/specifying-location): + Projects scope, location specified: `projects/`PROJECT_ID`/locations/`LOCATION_ID + Projects scope, no location specified (defaults to global): `projects/`PROJECT_ID The following example `parent` string specifies a parent project with the identifier `example-project`, and specifies the `europe-west3` location for processing data: parent=projects/example-project/locations/europe-west3 * `optional_params` (*type:* `keyword()`) - Optional parameters * `:"$.xgafv"` (*type:* `String.t`) - V1 error format. * `:access_token` (*type:* `String.t`) - OAuth access token. @@ -3041,28 +3787,25 @@ defmodule GoogleApi.DLP.V2.Api.Projects do * `:quotaUser` (*type:* `String.t`) - 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. * `:uploadType` (*type:* `String.t`) - Legacy upload protocol for media (e.g. "media", "multipart"). * `:upload_protocol` (*type:* `String.t`) - Upload protocol for media (e.g. "raw", "multipart"). - * `:locationId` (*type:* `String.t`) - Deprecated. This field has no effect. - * `:orderBy` (*type:* `String.t`) - Comma separated list of fields to order by, followed by `asc` or `desc` postfix. This list is case-insensitive, default sorting order is ascending, redundant space characters are insignificant. Example: `name asc,update_time, create_time desc` Supported fields are: - `create_time`: corresponds to the time the template was created. - `update_time`: corresponds to the time the template was last updated. - `name`: corresponds to the template's name. - `display_name`: corresponds to the template's display name. - * `:pageSize` (*type:* `integer()`) - Size of the page, can be limited by the server. If zero server returns a page of max size 100. - * `:pageToken` (*type:* `String.t`) - Page token to continue retrieval. Comes from previous call to `ListInspectTemplates`. + * `:body` (*type:* `GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2CreateJobTriggerRequest.t`) - * `opts` (*type:* `keyword()`) - Call options ## Returns - * `{:ok, %GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2ListInspectTemplatesResponse{}}` on success + * `{:ok, %GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2JobTrigger{}}` on success * `{:error, info}` on failure """ - @spec dlp_projects_locations_inspect_templates_list( + @spec dlp_projects_locations_job_triggers_create( Tesla.Env.client(), String.t(), keyword(), keyword() ) :: - {:ok, GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2ListInspectTemplatesResponse.t()} + {:ok, GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2JobTrigger.t()} | {:ok, Tesla.Env.t()} | {:ok, list()} | {:error, any()} - def dlp_projects_locations_inspect_templates_list( + def dlp_projects_locations_job_triggers_create( connection, parent, optional_params \\ [], @@ -3080,16 +3823,13 @@ defmodule GoogleApi.DLP.V2.Api.Projects do :quotaUser => :query, :uploadType => :query, :upload_protocol => :query, - :locationId => :query, - :orderBy => :query, - :pageSize => :query, - :pageToken => :query + :body => :body } request = Request.new() - |> Request.method(:get) - |> Request.url("/v2/{+parent}/inspectTemplates", %{ + |> Request.method(:post) + |> Request.url("/v2/{+parent}/jobTriggers", %{ "parent" => URI.encode(parent, &URI.char_unreserved?/1) }) |> Request.add_optional_params(optional_params_config, optional_params) @@ -3097,18 +3837,86 @@ defmodule GoogleApi.DLP.V2.Api.Projects do connection |> Connection.execute(request) - |> Response.decode( - opts ++ [struct: %GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2ListInspectTemplatesResponse{}] - ) + |> Response.decode(opts ++ [struct: %GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2JobTrigger{}]) end @doc """ - Updates the InspectTemplate. See https://cloud.google.com/dlp/docs/creating-templates to learn more. + Deletes a job trigger. See https://cloud.google.com/sensitive-data-protection/docs/creating-job-triggers to learn more. ## Parameters * `connection` (*type:* `GoogleApi.DLP.V2.Connection.t`) - Connection to server - * `name` (*type:* `String.t`) - Required. Resource name of organization and inspectTemplate to be updated, for example `organizations/433245324/inspectTemplates/432452342` or projects/project-id/inspectTemplates/432452342. + * `name` (*type:* `String.t`) - Required. Resource name of the project and the triggeredJob, for example `projects/dlp-test-project/jobTriggers/53234423`. + * `optional_params` (*type:* `keyword()`) - Optional parameters + * `:"$.xgafv"` (*type:* `String.t`) - V1 error format. + * `:access_token` (*type:* `String.t`) - OAuth access token. + * `:alt` (*type:* `String.t`) - Data format for response. + * `:callback` (*type:* `String.t`) - JSONP + * `:fields` (*type:* `String.t`) - Selector specifying which fields to include in a partial response. + * `:key` (*type:* `String.t`) - 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. + * `:oauth_token` (*type:* `String.t`) - OAuth 2.0 token for the current user. + * `:prettyPrint` (*type:* `boolean()`) - Returns response with indentations and line breaks. + * `:quotaUser` (*type:* `String.t`) - 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. + * `:uploadType` (*type:* `String.t`) - Legacy upload protocol for media (e.g. "media", "multipart"). + * `:upload_protocol` (*type:* `String.t`) - Upload protocol for media (e.g. "raw", "multipart"). + * `opts` (*type:* `keyword()`) - Call options + + ## Returns + + * `{:ok, %GoogleApi.DLP.V2.Model.GoogleProtobufEmpty{}}` on success + * `{:error, info}` on failure + """ + @spec dlp_projects_locations_job_triggers_delete( + Tesla.Env.client(), + String.t(), + keyword(), + keyword() + ) :: + {:ok, GoogleApi.DLP.V2.Model.GoogleProtobufEmpty.t()} + | {:ok, Tesla.Env.t()} + | {:ok, list()} + | {:error, any()} + def dlp_projects_locations_job_triggers_delete( + connection, + name, + optional_params \\ [], + opts \\ [] + ) do + optional_params_config = %{ + :"$.xgafv" => :query, + :access_token => :query, + :alt => :query, + :callback => :query, + :fields => :query, + :key => :query, + :oauth_token => :query, + :prettyPrint => :query, + :quotaUser => :query, + :uploadType => :query, + :upload_protocol => :query + } + + request = + Request.new() + |> Request.method(:delete) + |> Request.url("/v2/{+name}", %{ + "name" => URI.encode(name, &URI.char_unreserved?/1) + }) + |> Request.add_optional_params(optional_params_config, optional_params) + |> Request.library_version(@library_version) + + connection + |> Connection.execute(request) + |> Response.decode(opts ++ [struct: %GoogleApi.DLP.V2.Model.GoogleProtobufEmpty{}]) + end + + @doc """ + Gets a job trigger. See https://cloud.google.com/sensitive-data-protection/docs/creating-job-triggers to learn more. + + ## Parameters + + * `connection` (*type:* `GoogleApi.DLP.V2.Connection.t`) - Connection to server + * `name` (*type:* `String.t`) - Required. Resource name of the project and the triggeredJob, for example `projects/dlp-test-project/jobTriggers/53234423`. * `optional_params` (*type:* `keyword()`) - Optional parameters * `:"$.xgafv"` (*type:* `String.t`) - V1 error format. * `:access_token` (*type:* `String.t`) - OAuth access token. @@ -3121,30 +3929,24 @@ defmodule GoogleApi.DLP.V2.Api.Projects do * `:quotaUser` (*type:* `String.t`) - 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. * `:uploadType` (*type:* `String.t`) - Legacy upload protocol for media (e.g. "media", "multipart"). * `:upload_protocol` (*type:* `String.t`) - Upload protocol for media (e.g. "raw", "multipart"). - * `:body` (*type:* `GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2UpdateInspectTemplateRequest.t`) - * `opts` (*type:* `keyword()`) - Call options ## Returns - * `{:ok, %GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2InspectTemplate{}}` on success + * `{:ok, %GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2JobTrigger{}}` on success * `{:error, info}` on failure """ - @spec dlp_projects_locations_inspect_templates_patch( + @spec dlp_projects_locations_job_triggers_get( Tesla.Env.client(), String.t(), keyword(), keyword() ) :: - {:ok, GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2InspectTemplate.t()} + {:ok, GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2JobTrigger.t()} | {:ok, Tesla.Env.t()} | {:ok, list()} | {:error, any()} - def dlp_projects_locations_inspect_templates_patch( - connection, - name, - optional_params \\ [], - opts \\ [] - ) do + def dlp_projects_locations_job_triggers_get(connection, name, optional_params \\ [], opts \\ []) do optional_params_config = %{ :"$.xgafv" => :query, :access_token => :query, @@ -3156,13 +3958,12 @@ defmodule GoogleApi.DLP.V2.Api.Projects do :prettyPrint => :query, :quotaUser => :query, :uploadType => :query, - :upload_protocol => :query, - :body => :body + :upload_protocol => :query } request = Request.new() - |> Request.method(:patch) + |> Request.method(:get) |> Request.url("/v2/{+name}", %{ "name" => URI.encode(name, &URI.char_unreserved?/1) }) @@ -3171,18 +3972,16 @@ defmodule GoogleApi.DLP.V2.Api.Projects do connection |> Connection.execute(request) - |> Response.decode( - opts ++ [struct: %GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2InspectTemplate{}] - ) + |> Response.decode(opts ++ [struct: %GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2JobTrigger{}]) end @doc """ - Activate a job trigger. Causes the immediate execute of a trigger instead of waiting on the trigger event to occur. + Inspect hybrid content and store findings to a trigger. The inspection will be processed asynchronously. To review the findings monitor the jobs within the trigger. ## Parameters * `connection` (*type:* `GoogleApi.DLP.V2.Connection.t`) - Connection to server - * `name` (*type:* `String.t`) - Required. Resource name of the trigger to activate, for example `projects/dlp-test-project/jobTriggers/53234423`. + * `name` (*type:* `String.t`) - Required. Resource name of the trigger to execute a hybrid inspect on, for example `projects/dlp-test-project/jobTriggers/53234423`. * `optional_params` (*type:* `keyword()`) - Optional parameters * `:"$.xgafv"` (*type:* `String.t`) - V1 error format. * `:access_token` (*type:* `String.t`) - OAuth access token. @@ -3195,25 +3994,25 @@ defmodule GoogleApi.DLP.V2.Api.Projects do * `:quotaUser` (*type:* `String.t`) - 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. * `:uploadType` (*type:* `String.t`) - Legacy upload protocol for media (e.g. "media", "multipart"). * `:upload_protocol` (*type:* `String.t`) - Upload protocol for media (e.g. "raw", "multipart"). - * `:body` (*type:* `GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2ActivateJobTriggerRequest.t`) - + * `:body` (*type:* `GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2HybridInspectJobTriggerRequest.t`) - * `opts` (*type:* `keyword()`) - Call options ## Returns - * `{:ok, %GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2DlpJob{}}` on success + * `{:ok, %GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2HybridInspectResponse{}}` on success * `{:error, info}` on failure """ - @spec dlp_projects_locations_job_triggers_activate( + @spec dlp_projects_locations_job_triggers_hybrid_inspect( Tesla.Env.client(), String.t(), keyword(), keyword() ) :: - {:ok, GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2DlpJob.t()} + {:ok, GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2HybridInspectResponse.t()} | {:ok, Tesla.Env.t()} | {:ok, list()} | {:error, any()} - def dlp_projects_locations_job_triggers_activate( + def dlp_projects_locations_job_triggers_hybrid_inspect( connection, name, optional_params \\ [], @@ -3237,7 +4036,7 @@ defmodule GoogleApi.DLP.V2.Api.Projects do request = Request.new() |> Request.method(:post) - |> Request.url("/v2/{+name}:activate", %{ + |> Request.url("/v2/{+name}:hybridInspect", %{ "name" => URI.encode(name, &URI.char_unreserved?/1) }) |> Request.add_optional_params(optional_params_config, optional_params) @@ -3245,16 +4044,18 @@ defmodule GoogleApi.DLP.V2.Api.Projects do connection |> Connection.execute(request) - |> Response.decode(opts ++ [struct: %GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2DlpJob{}]) + |> Response.decode( + opts ++ [struct: %GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2HybridInspectResponse{}] + ) end @doc """ - Creates a job trigger to run DLP actions such as scanning storage for sensitive information on a set schedule. See https://cloud.google.com/dlp/docs/creating-job-triggers to learn more. + Lists job triggers. See https://cloud.google.com/sensitive-data-protection/docs/creating-job-triggers to learn more. ## Parameters * `connection` (*type:* `GoogleApi.DLP.V2.Connection.t`) - Connection to server - * `parent` (*type:* `String.t`) - Required. Parent resource name. The format of this value varies depending on whether you have [specified a processing location](https://cloud.google.com/dlp/docs/specifying-location): + Projects scope, location specified: `projects/`PROJECT_ID`/locations/`LOCATION_ID + Projects scope, no location specified (defaults to global): `projects/`PROJECT_ID The following example `parent` string specifies a parent project with the identifier `example-project`, and specifies the `europe-west3` location for processing data: parent=projects/example-project/locations/europe-west3 + * `parent` (*type:* `String.t`) - Required. Parent resource name. The format of this value varies depending on whether you have [specified a processing location](https://cloud.google.com/sensitive-data-protection/docs/specifying-location): + Projects scope, location specified: `projects/`PROJECT_ID`/locations/`LOCATION_ID + Projects scope, no location specified (defaults to global): `projects/`PROJECT_ID The following example `parent` string specifies a parent project with the identifier `example-project`, and specifies the `europe-west3` location for processing data: parent=projects/example-project/locations/europe-west3 * `optional_params` (*type:* `keyword()`) - Optional parameters * `:"$.xgafv"` (*type:* `String.t`) - V1 error format. * `:access_token` (*type:* `String.t`) - OAuth access token. @@ -3267,25 +4068,30 @@ defmodule GoogleApi.DLP.V2.Api.Projects do * `:quotaUser` (*type:* `String.t`) - 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. * `:uploadType` (*type:* `String.t`) - Legacy upload protocol for media (e.g. "media", "multipart"). * `:upload_protocol` (*type:* `String.t`) - Upload protocol for media (e.g. "raw", "multipart"). - * `:body` (*type:* `GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2CreateJobTriggerRequest.t`) - + * `:filter` (*type:* `String.t`) - Allows filtering. Supported syntax: * Filter expressions are made up of one or more restrictions. * Restrictions can be combined by `AND` or `OR` logical operators. A sequence of restrictions implicitly uses `AND`. * A restriction has the form of `{field} {operator} {value}`. * Supported fields/values for inspect triggers: - `status` - HEALTHY|PAUSED|CANCELLED - `inspected_storage` - DATASTORE|CLOUD_STORAGE|BIGQUERY - 'last_run_time` - RFC 3339 formatted timestamp, surrounded by quotation marks. Nanoseconds are ignored. - 'error_count' - Number of errors that have occurred while running. * The operator must be `=` or `!=` for status and inspected_storage. Examples: * inspected_storage = cloud_storage AND status = HEALTHY * inspected_storage = cloud_storage OR inspected_storage = bigquery * inspected_storage = cloud_storage AND (state = PAUSED OR state = HEALTHY) * last_run_time > \\"2017-12-12T00:00:00+00:00\\" The length of this field should be no more than 500 characters. + * `:locationId` (*type:* `String.t`) - Deprecated. This field has no effect. + * `:orderBy` (*type:* `String.t`) - Comma separated list of triggeredJob fields to order by, followed by `asc` or `desc` postfix. This list is case insensitive. The default sorting order is ascending. Redundant space characters are insignificant. Example: `name asc,update_time, create_time desc` Supported fields are: - `create_time`: corresponds to the time the JobTrigger was created. - `update_time`: corresponds to the time the JobTrigger was last updated. - `last_run_time`: corresponds to the last time the JobTrigger ran. - `name`: corresponds to the JobTrigger's name. - `display_name`: corresponds to the JobTrigger's display name. - `status`: corresponds to JobTrigger's status. + * `:pageSize` (*type:* `integer()`) - Size of the page. This value can be limited by a server. + * `:pageToken` (*type:* `String.t`) - Page token to continue retrieval. Comes from the previous call to ListJobTriggers. `order_by` field must not change for subsequent calls. + * `:type` (*type:* `String.t`) - The type of jobs. Will use `DlpJobType.INSPECT` if not set. * `opts` (*type:* `keyword()`) - Call options ## Returns - * `{:ok, %GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2JobTrigger{}}` on success + * `{:ok, %GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2ListJobTriggersResponse{}}` on success * `{:error, info}` on failure """ - @spec dlp_projects_locations_job_triggers_create( + @spec dlp_projects_locations_job_triggers_list( Tesla.Env.client(), String.t(), keyword(), keyword() ) :: - {:ok, GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2JobTrigger.t()} + {:ok, GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2ListJobTriggersResponse.t()} | {:ok, Tesla.Env.t()} | {:ok, list()} | {:error, any()} - def dlp_projects_locations_job_triggers_create( + def dlp_projects_locations_job_triggers_list( connection, parent, optional_params \\ [], @@ -3303,12 +4109,17 @@ defmodule GoogleApi.DLP.V2.Api.Projects do :quotaUser => :query, :uploadType => :query, :upload_protocol => :query, - :body => :body + :filter => :query, + :locationId => :query, + :orderBy => :query, + :pageSize => :query, + :pageToken => :query, + :type => :query } request = Request.new() - |> Request.method(:post) + |> Request.method(:get) |> Request.url("/v2/{+parent}/jobTriggers", %{ "parent" => URI.encode(parent, &URI.char_unreserved?/1) }) @@ -3317,11 +4128,13 @@ defmodule GoogleApi.DLP.V2.Api.Projects do connection |> Connection.execute(request) - |> Response.decode(opts ++ [struct: %GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2JobTrigger{}]) + |> Response.decode( + opts ++ [struct: %GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2ListJobTriggersResponse{}] + ) end @doc """ - Deletes a job trigger. See https://cloud.google.com/dlp/docs/creating-job-triggers to learn more. + Updates a job trigger. See https://cloud.google.com/sensitive-data-protection/docs/creating-job-triggers to learn more. ## Parameters @@ -3339,24 +4152,25 @@ defmodule GoogleApi.DLP.V2.Api.Projects do * `:quotaUser` (*type:* `String.t`) - 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. * `:uploadType` (*type:* `String.t`) - Legacy upload protocol for media (e.g. "media", "multipart"). * `:upload_protocol` (*type:* `String.t`) - Upload protocol for media (e.g. "raw", "multipart"). + * `:body` (*type:* `GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2UpdateJobTriggerRequest.t`) - * `opts` (*type:* `keyword()`) - Call options ## Returns - * `{:ok, %GoogleApi.DLP.V2.Model.GoogleProtobufEmpty{}}` on success + * `{:ok, %GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2JobTrigger{}}` on success * `{:error, info}` on failure """ - @spec dlp_projects_locations_job_triggers_delete( + @spec dlp_projects_locations_job_triggers_patch( Tesla.Env.client(), String.t(), keyword(), keyword() ) :: - {:ok, GoogleApi.DLP.V2.Model.GoogleProtobufEmpty.t()} + {:ok, GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2JobTrigger.t()} | {:ok, Tesla.Env.t()} | {:ok, list()} | {:error, any()} - def dlp_projects_locations_job_triggers_delete( + def dlp_projects_locations_job_triggers_patch( connection, name, optional_params \\ [], @@ -3373,12 +4187,13 @@ defmodule GoogleApi.DLP.V2.Api.Projects do :prettyPrint => :query, :quotaUser => :query, :uploadType => :query, - :upload_protocol => :query + :upload_protocol => :query, + :body => :body } request = Request.new() - |> Request.method(:delete) + |> Request.method(:patch) |> Request.url("/v2/{+name}", %{ "name" => URI.encode(name, &URI.char_unreserved?/1) }) @@ -3387,16 +4202,16 @@ defmodule GoogleApi.DLP.V2.Api.Projects do connection |> Connection.execute(request) - |> Response.decode(opts ++ [struct: %GoogleApi.DLP.V2.Model.GoogleProtobufEmpty{}]) + |> Response.decode(opts ++ [struct: %GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2JobTrigger{}]) end @doc """ - Gets a job trigger. See https://cloud.google.com/dlp/docs/creating-job-triggers to learn more. + Gets a project data profile. ## Parameters * `connection` (*type:* `GoogleApi.DLP.V2.Connection.t`) - Connection to server - * `name` (*type:* `String.t`) - Required. Resource name of the project and the triggeredJob, for example `projects/dlp-test-project/jobTriggers/53234423`. + * `name` (*type:* `String.t`) - Required. Resource name, for example `organizations/12345/locations/us/projectDataProfiles/53234423`. * `optional_params` (*type:* `keyword()`) - Optional parameters * `:"$.xgafv"` (*type:* `String.t`) - V1 error format. * `:access_token` (*type:* `String.t`) - OAuth access token. @@ -3413,20 +4228,25 @@ defmodule GoogleApi.DLP.V2.Api.Projects do ## Returns - * `{:ok, %GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2JobTrigger{}}` on success + * `{:ok, %GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2ProjectDataProfile{}}` on success * `{:error, info}` on failure """ - @spec dlp_projects_locations_job_triggers_get( + @spec dlp_projects_locations_project_data_profiles_get( Tesla.Env.client(), String.t(), keyword(), keyword() ) :: - {:ok, GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2JobTrigger.t()} + {:ok, GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2ProjectDataProfile.t()} | {:ok, Tesla.Env.t()} | {:ok, list()} | {:error, any()} - def dlp_projects_locations_job_triggers_get(connection, name, optional_params \\ [], opts \\ []) do + def dlp_projects_locations_project_data_profiles_get( + connection, + name, + optional_params \\ [], + opts \\ [] + ) do optional_params_config = %{ :"$.xgafv" => :query, :access_token => :query, @@ -3452,16 +4272,18 @@ defmodule GoogleApi.DLP.V2.Api.Projects do connection |> Connection.execute(request) - |> Response.decode(opts ++ [struct: %GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2JobTrigger{}]) + |> Response.decode( + opts ++ [struct: %GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2ProjectDataProfile{}] + ) end @doc """ - Inspect hybrid content and store findings to a trigger. The inspection will be processed asynchronously. To review the findings monitor the jobs within the trigger. + Lists data profiles for an organization. ## Parameters * `connection` (*type:* `GoogleApi.DLP.V2.Connection.t`) - Connection to server - * `name` (*type:* `String.t`) - Required. Resource name of the trigger to execute a hybrid inspect on, for example `projects/dlp-test-project/jobTriggers/53234423`. + * `parent` (*type:* `String.t`) - Required. organizations/{org_id}/locations/{loc_id} * `optional_params` (*type:* `keyword()`) - Optional parameters * `:"$.xgafv"` (*type:* `String.t`) - V1 error format. * `:access_token` (*type:* `String.t`) - OAuth access token. @@ -3474,27 +4296,30 @@ defmodule GoogleApi.DLP.V2.Api.Projects do * `:quotaUser` (*type:* `String.t`) - 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. * `:uploadType` (*type:* `String.t`) - Legacy upload protocol for media (e.g. "media", "multipart"). * `:upload_protocol` (*type:* `String.t`) - Upload protocol for media (e.g. "raw", "multipart"). - * `:body` (*type:* `GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2HybridInspectJobTriggerRequest.t`) - + * `:filter` (*type:* `String.t`) - Allows filtering. Supported syntax: * Filter expressions are made up of one or more restrictions. * Restrictions can be combined by `AND` or `OR` logical operators. A sequence of restrictions implicitly uses `AND`. * A restriction has the form of `{field} {operator} {value}`. * Supported fields/values: - `sensitivity_level` - HIGH|MODERATE|LOW - `data_risk_level` - HIGH|MODERATE|LOW - `status_code` - an RPC status code as defined in https://github.com/googleapis/googleapis/blob/master/google/rpc/code.proto * The operator must be `=` or `!=`. Examples: * project_id = 12345 AND status_code = 1 * project_id = 12345 AND sensitivity_level = HIGH The length of this field should be no more than 500 characters. + * `:orderBy` (*type:* `String.t`) - Comma separated list of fields to order by, followed by `asc` or `desc` postfix. This list is case insensitive. The default sorting order is ascending. Redundant space characters are insignificant. Only one order field at a time is allowed. Examples: * `project_id` * `sensitivity_level desc` Supported fields are: - `project_id`: GCP project ID - `sensitivity_level`: How sensitive the data in a project is, at most. - `data_risk_level`: How much risk is associated with this data. - `profile_last_generated`: When the profile was last updated in epoch seconds. + * `:pageSize` (*type:* `integer()`) - Size of the page. This value can be limited by the server. If zero, server returns a page of max size 100. + * `:pageToken` (*type:* `String.t`) - Page token to continue retrieval. * `opts` (*type:* `keyword()`) - Call options ## Returns - * `{:ok, %GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2HybridInspectResponse{}}` on success + * `{:ok, %GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2ListProjectDataProfilesResponse{}}` on success * `{:error, info}` on failure """ - @spec dlp_projects_locations_job_triggers_hybrid_inspect( + @spec dlp_projects_locations_project_data_profiles_list( Tesla.Env.client(), String.t(), keyword(), keyword() ) :: - {:ok, GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2HybridInspectResponse.t()} + {:ok, GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2ListProjectDataProfilesResponse.t()} | {:ok, Tesla.Env.t()} | {:ok, list()} | {:error, any()} - def dlp_projects_locations_job_triggers_hybrid_inspect( + def dlp_projects_locations_project_data_profiles_list( connection, - name, + parent, optional_params \\ [], opts \\ [] ) do @@ -3510,14 +4335,17 @@ defmodule GoogleApi.DLP.V2.Api.Projects do :quotaUser => :query, :uploadType => :query, :upload_protocol => :query, - :body => :body + :filter => :query, + :orderBy => :query, + :pageSize => :query, + :pageToken => :query } request = Request.new() - |> Request.method(:post) - |> Request.url("/v2/{+name}:hybridInspect", %{ - "name" => URI.encode(name, &URI.char_unreserved?/1) + |> Request.method(:get) + |> Request.url("/v2/{+parent}/projectDataProfiles", %{ + "parent" => URI.encode(parent, &URI.char_unreserved?/1) }) |> Request.add_optional_params(optional_params_config, optional_params) |> Request.library_version(@library_version) @@ -3525,17 +4353,18 @@ defmodule GoogleApi.DLP.V2.Api.Projects do connection |> Connection.execute(request) |> Response.decode( - opts ++ [struct: %GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2HybridInspectResponse{}] + opts ++ + [struct: %GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2ListProjectDataProfilesResponse{}] ) end @doc """ - Lists job triggers. See https://cloud.google.com/dlp/docs/creating-job-triggers to learn more. + Creates a pre-built stored infoType to be used for inspection. See https://cloud.google.com/sensitive-data-protection/docs/creating-stored-infotypes to learn more. ## Parameters * `connection` (*type:* `GoogleApi.DLP.V2.Connection.t`) - Connection to server - * `parent` (*type:* `String.t`) - Required. Parent resource name. The format of this value varies depending on whether you have [specified a processing location](https://cloud.google.com/dlp/docs/specifying-location): + Projects scope, location specified: `projects/`PROJECT_ID`/locations/`LOCATION_ID + Projects scope, no location specified (defaults to global): `projects/`PROJECT_ID The following example `parent` string specifies a parent project with the identifier `example-project`, and specifies the `europe-west3` location for processing data: parent=projects/example-project/locations/europe-west3 + * `parent` (*type:* `String.t`) - Required. Parent resource name. The format of this value varies depending on the scope of the request (project or organization) and whether you have [specified a processing location](https://cloud.google.com/sensitive-data-protection/docs/specifying-location): + Projects scope, location specified: `projects/`PROJECT_ID`/locations/`LOCATION_ID + Projects scope, no location specified (defaults to global): `projects/`PROJECT_ID + Organizations scope, location specified: `organizations/`ORG_ID`/locations/`LOCATION_ID + Organizations scope, no location specified (defaults to global): `organizations/`ORG_ID The following example `parent` string specifies a parent project with the identifier `example-project`, and specifies the `europe-west3` location for processing data: parent=projects/example-project/locations/europe-west3 * `optional_params` (*type:* `keyword()`) - Optional parameters * `:"$.xgafv"` (*type:* `String.t`) - V1 error format. * `:access_token` (*type:* `String.t`) - OAuth access token. @@ -3548,30 +4377,25 @@ defmodule GoogleApi.DLP.V2.Api.Projects do * `:quotaUser` (*type:* `String.t`) - 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. * `:uploadType` (*type:* `String.t`) - Legacy upload protocol for media (e.g. "media", "multipart"). * `:upload_protocol` (*type:* `String.t`) - Upload protocol for media (e.g. "raw", "multipart"). - * `:filter` (*type:* `String.t`) - Allows filtering. Supported syntax: * Filter expressions are made up of one or more restrictions. * Restrictions can be combined by `AND` or `OR` logical operators. A sequence of restrictions implicitly uses `AND`. * A restriction has the form of `{field} {operator} {value}`. * Supported fields/values for inspect triggers: - `status` - HEALTHY|PAUSED|CANCELLED - `inspected_storage` - DATASTORE|CLOUD_STORAGE|BIGQUERY - 'last_run_time` - RFC 3339 formatted timestamp, surrounded by quotation marks. Nanoseconds are ignored. - 'error_count' - Number of errors that have occurred while running. * The operator must be `=` or `!=` for status and inspected_storage. Examples: * inspected_storage = cloud_storage AND status = HEALTHY * inspected_storage = cloud_storage OR inspected_storage = bigquery * inspected_storage = cloud_storage AND (state = PAUSED OR state = HEALTHY) * last_run_time > \\"2017-12-12T00:00:00+00:00\\" The length of this field should be no more than 500 characters. - * `:locationId` (*type:* `String.t`) - Deprecated. This field has no effect. - * `:orderBy` (*type:* `String.t`) - Comma separated list of triggeredJob fields to order by, followed by `asc` or `desc` postfix. This list is case-insensitive, default sorting order is ascending, redundant space characters are insignificant. Example: `name asc,update_time, create_time desc` Supported fields are: - `create_time`: corresponds to the time the JobTrigger was created. - `update_time`: corresponds to the time the JobTrigger was last updated. - `last_run_time`: corresponds to the last time the JobTrigger ran. - `name`: corresponds to the JobTrigger's name. - `display_name`: corresponds to the JobTrigger's display name. - `status`: corresponds to JobTrigger's status. - * `:pageSize` (*type:* `integer()`) - Size of the page, can be limited by a server. - * `:pageToken` (*type:* `String.t`) - Page token to continue retrieval. Comes from previous call to ListJobTriggers. `order_by` field must not change for subsequent calls. - * `:type` (*type:* `String.t`) - The type of jobs. Will use `DlpJobType.INSPECT` if not set. + * `:body` (*type:* `GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2CreateStoredInfoTypeRequest.t`) - * `opts` (*type:* `keyword()`) - Call options ## Returns - * `{:ok, %GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2ListJobTriggersResponse{}}` on success + * `{:ok, %GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2StoredInfoType{}}` on success * `{:error, info}` on failure """ - @spec dlp_projects_locations_job_triggers_list( + @spec dlp_projects_locations_stored_info_types_create( Tesla.Env.client(), String.t(), keyword(), keyword() ) :: - {:ok, GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2ListJobTriggersResponse.t()} + {:ok, GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2StoredInfoType.t()} | {:ok, Tesla.Env.t()} | {:ok, list()} | {:error, any()} - def dlp_projects_locations_job_triggers_list( + def dlp_projects_locations_stored_info_types_create( connection, parent, optional_params \\ [], @@ -3589,18 +4413,13 @@ defmodule GoogleApi.DLP.V2.Api.Projects do :quotaUser => :query, :uploadType => :query, :upload_protocol => :query, - :filter => :query, - :locationId => :query, - :orderBy => :query, - :pageSize => :query, - :pageToken => :query, - :type => :query + :body => :body } request = Request.new() - |> Request.method(:get) - |> Request.url("/v2/{+parent}/jobTriggers", %{ + |> Request.method(:post) + |> Request.url("/v2/{+parent}/storedInfoTypes", %{ "parent" => URI.encode(parent, &URI.char_unreserved?/1) }) |> Request.add_optional_params(optional_params_config, optional_params) @@ -3609,17 +4428,17 @@ defmodule GoogleApi.DLP.V2.Api.Projects do connection |> Connection.execute(request) |> Response.decode( - opts ++ [struct: %GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2ListJobTriggersResponse{}] + opts ++ [struct: %GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2StoredInfoType{}] ) end @doc """ - Updates a job trigger. See https://cloud.google.com/dlp/docs/creating-job-triggers to learn more. + Deletes a stored infoType. See https://cloud.google.com/sensitive-data-protection/docs/creating-stored-infotypes to learn more. ## Parameters * `connection` (*type:* `GoogleApi.DLP.V2.Connection.t`) - Connection to server - * `name` (*type:* `String.t`) - Required. Resource name of the project and the triggeredJob, for example `projects/dlp-test-project/jobTriggers/53234423`. + * `name` (*type:* `String.t`) - Required. Resource name of the organization and storedInfoType to be deleted, for example `organizations/433245324/storedInfoTypes/432452342` or projects/project-id/storedInfoTypes/432452342. * `optional_params` (*type:* `keyword()`) - Optional parameters * `:"$.xgafv"` (*type:* `String.t`) - V1 error format. * `:access_token` (*type:* `String.t`) - OAuth access token. @@ -3632,25 +4451,24 @@ defmodule GoogleApi.DLP.V2.Api.Projects do * `:quotaUser` (*type:* `String.t`) - 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. * `:uploadType` (*type:* `String.t`) - Legacy upload protocol for media (e.g. "media", "multipart"). * `:upload_protocol` (*type:* `String.t`) - Upload protocol for media (e.g. "raw", "multipart"). - * `:body` (*type:* `GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2UpdateJobTriggerRequest.t`) - * `opts` (*type:* `keyword()`) - Call options ## Returns - * `{:ok, %GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2JobTrigger{}}` on success + * `{:ok, %GoogleApi.DLP.V2.Model.GoogleProtobufEmpty{}}` on success * `{:error, info}` on failure """ - @spec dlp_projects_locations_job_triggers_patch( + @spec dlp_projects_locations_stored_info_types_delete( Tesla.Env.client(), String.t(), keyword(), keyword() ) :: - {:ok, GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2JobTrigger.t()} + {:ok, GoogleApi.DLP.V2.Model.GoogleProtobufEmpty.t()} | {:ok, Tesla.Env.t()} | {:ok, list()} | {:error, any()} - def dlp_projects_locations_job_triggers_patch( + def dlp_projects_locations_stored_info_types_delete( connection, name, optional_params \\ [], @@ -3667,13 +4485,12 @@ defmodule GoogleApi.DLP.V2.Api.Projects do :prettyPrint => :query, :quotaUser => :query, :uploadType => :query, - :upload_protocol => :query, - :body => :body + :upload_protocol => :query } request = Request.new() - |> Request.method(:patch) + |> Request.method(:delete) |> Request.url("/v2/{+name}", %{ "name" => URI.encode(name, &URI.char_unreserved?/1) }) @@ -3682,16 +4499,16 @@ defmodule GoogleApi.DLP.V2.Api.Projects do connection |> Connection.execute(request) - |> Response.decode(opts ++ [struct: %GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2JobTrigger{}]) + |> Response.decode(opts ++ [struct: %GoogleApi.DLP.V2.Model.GoogleProtobufEmpty{}]) end @doc """ - Creates a pre-built stored infoType to be used for inspection. See https://cloud.google.com/dlp/docs/creating-stored-infotypes to learn more. + Gets a stored infoType. See https://cloud.google.com/sensitive-data-protection/docs/creating-stored-infotypes to learn more. ## Parameters * `connection` (*type:* `GoogleApi.DLP.V2.Connection.t`) - Connection to server - * `parent` (*type:* `String.t`) - Required. Parent resource name. The format of this value varies depending on the scope of the request (project or organization) and whether you have [specified a processing location](https://cloud.google.com/dlp/docs/specifying-location): + Projects scope, location specified: `projects/`PROJECT_ID`/locations/`LOCATION_ID + Projects scope, no location specified (defaults to global): `projects/`PROJECT_ID + Organizations scope, location specified: `organizations/`ORG_ID`/locations/`LOCATION_ID + Organizations scope, no location specified (defaults to global): `organizations/`ORG_ID The following example `parent` string specifies a parent project with the identifier `example-project`, and specifies the `europe-west3` location for processing data: parent=projects/example-project/locations/europe-west3 + * `name` (*type:* `String.t`) - Required. Resource name of the organization and storedInfoType to be read, for example `organizations/433245324/storedInfoTypes/432452342` or projects/project-id/storedInfoTypes/432452342. * `optional_params` (*type:* `keyword()`) - Optional parameters * `:"$.xgafv"` (*type:* `String.t`) - V1 error format. * `:access_token` (*type:* `String.t`) - OAuth access token. @@ -3704,7 +4521,6 @@ defmodule GoogleApi.DLP.V2.Api.Projects do * `:quotaUser` (*type:* `String.t`) - 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. * `:uploadType` (*type:* `String.t`) - Legacy upload protocol for media (e.g. "media", "multipart"). * `:upload_protocol` (*type:* `String.t`) - Upload protocol for media (e.g. "raw", "multipart"). - * `:body` (*type:* `GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2CreateStoredInfoTypeRequest.t`) - * `opts` (*type:* `keyword()`) - Call options ## Returns @@ -3712,7 +4528,7 @@ defmodule GoogleApi.DLP.V2.Api.Projects do * `{:ok, %GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2StoredInfoType{}}` on success * `{:error, info}` on failure """ - @spec dlp_projects_locations_stored_info_types_create( + @spec dlp_projects_locations_stored_info_types_get( Tesla.Env.client(), String.t(), keyword(), @@ -3722,9 +4538,9 @@ defmodule GoogleApi.DLP.V2.Api.Projects do | {:ok, Tesla.Env.t()} | {:ok, list()} | {:error, any()} - def dlp_projects_locations_stored_info_types_create( + def dlp_projects_locations_stored_info_types_get( connection, - parent, + name, optional_params \\ [], opts \\ [] ) do @@ -3739,15 +4555,14 @@ defmodule GoogleApi.DLP.V2.Api.Projects do :prettyPrint => :query, :quotaUser => :query, :uploadType => :query, - :upload_protocol => :query, - :body => :body + :upload_protocol => :query } request = Request.new() - |> Request.method(:post) - |> Request.url("/v2/{+parent}/storedInfoTypes", %{ - "parent" => URI.encode(parent, &URI.char_unreserved?/1) + |> Request.method(:get) + |> Request.url("/v2/{+name}", %{ + "name" => URI.encode(name, &URI.char_unreserved?/1) }) |> Request.add_optional_params(optional_params_config, optional_params) |> Request.library_version(@library_version) @@ -3760,12 +4575,12 @@ defmodule GoogleApi.DLP.V2.Api.Projects do end @doc """ - Deletes a stored infoType. See https://cloud.google.com/dlp/docs/creating-stored-infotypes to learn more. + Lists stored infoTypes. See https://cloud.google.com/sensitive-data-protection/docs/creating-stored-infotypes to learn more. ## Parameters * `connection` (*type:* `GoogleApi.DLP.V2.Connection.t`) - Connection to server - * `name` (*type:* `String.t`) - Required. Resource name of the organization and storedInfoType to be deleted, for example `organizations/433245324/storedInfoTypes/432452342` or projects/project-id/storedInfoTypes/432452342. + * `parent` (*type:* `String.t`) - Required. Parent resource name. The format of this value varies depending on the scope of the request (project or organization) and whether you have [specified a processing location](https://cloud.google.com/sensitive-data-protection/docs/specifying-location): + Projects scope, location specified: `projects/`PROJECT_ID`/locations/`LOCATION_ID + Projects scope, no location specified (defaults to global): `projects/`PROJECT_ID The following example `parent` string specifies a parent project with the identifier `example-project`, and specifies the `europe-west3` location for processing data: parent=projects/example-project/locations/europe-west3 * `optional_params` (*type:* `keyword()`) - Optional parameters * `:"$.xgafv"` (*type:* `String.t`) - V1 error format. * `:access_token` (*type:* `String.t`) - OAuth access token. @@ -3778,26 +4593,30 @@ defmodule GoogleApi.DLP.V2.Api.Projects do * `:quotaUser` (*type:* `String.t`) - 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. * `:uploadType` (*type:* `String.t`) - Legacy upload protocol for media (e.g. "media", "multipart"). * `:upload_protocol` (*type:* `String.t`) - Upload protocol for media (e.g. "raw", "multipart"). + * `:locationId` (*type:* `String.t`) - Deprecated. This field has no effect. + * `:orderBy` (*type:* `String.t`) - Comma separated list of fields to order by, followed by `asc` or `desc` postfix. This list is case insensitive. The default sorting order is ascending. Redundant space characters are insignificant. Example: `name asc, display_name, create_time desc` Supported fields are: - `create_time`: corresponds to the time the most recent version of the resource was created. - `state`: corresponds to the state of the resource. - `name`: corresponds to resource name. - `display_name`: corresponds to info type's display name. + * `:pageSize` (*type:* `integer()`) - Size of the page. This value can be limited by the server. If zero server returns a page of max size 100. + * `:pageToken` (*type:* `String.t`) - Page token to continue retrieval. Comes from the previous call to `ListStoredInfoTypes`. * `opts` (*type:* `keyword()`) - Call options ## Returns - * `{:ok, %GoogleApi.DLP.V2.Model.GoogleProtobufEmpty{}}` on success + * `{:ok, %GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2ListStoredInfoTypesResponse{}}` on success * `{:error, info}` on failure """ - @spec dlp_projects_locations_stored_info_types_delete( + @spec dlp_projects_locations_stored_info_types_list( Tesla.Env.client(), String.t(), keyword(), keyword() ) :: - {:ok, GoogleApi.DLP.V2.Model.GoogleProtobufEmpty.t()} + {:ok, GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2ListStoredInfoTypesResponse.t()} | {:ok, Tesla.Env.t()} | {:ok, list()} | {:error, any()} - def dlp_projects_locations_stored_info_types_delete( + def dlp_projects_locations_stored_info_types_list( connection, - name, + parent, optional_params \\ [], opts \\ [] ) do @@ -3812,30 +4631,36 @@ defmodule GoogleApi.DLP.V2.Api.Projects do :prettyPrint => :query, :quotaUser => :query, :uploadType => :query, - :upload_protocol => :query + :upload_protocol => :query, + :locationId => :query, + :orderBy => :query, + :pageSize => :query, + :pageToken => :query } request = Request.new() - |> Request.method(:delete) - |> Request.url("/v2/{+name}", %{ - "name" => URI.encode(name, &URI.char_unreserved?/1) + |> Request.method(:get) + |> Request.url("/v2/{+parent}/storedInfoTypes", %{ + "parent" => URI.encode(parent, &URI.char_unreserved?/1) }) |> Request.add_optional_params(optional_params_config, optional_params) |> Request.library_version(@library_version) connection |> Connection.execute(request) - |> Response.decode(opts ++ [struct: %GoogleApi.DLP.V2.Model.GoogleProtobufEmpty{}]) + |> Response.decode( + opts ++ [struct: %GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2ListStoredInfoTypesResponse{}] + ) end @doc """ - Gets a stored infoType. See https://cloud.google.com/dlp/docs/creating-stored-infotypes to learn more. + Updates the stored infoType by creating a new version. The existing version will continue to be used until the new version is ready. See https://cloud.google.com/sensitive-data-protection/docs/creating-stored-infotypes to learn more. ## Parameters * `connection` (*type:* `GoogleApi.DLP.V2.Connection.t`) - Connection to server - * `name` (*type:* `String.t`) - Required. Resource name of the organization and storedInfoType to be read, for example `organizations/433245324/storedInfoTypes/432452342` or projects/project-id/storedInfoTypes/432452342. + * `name` (*type:* `String.t`) - Required. Resource name of organization and storedInfoType to be updated, for example `organizations/433245324/storedInfoTypes/432452342` or projects/project-id/storedInfoTypes/432452342. * `optional_params` (*type:* `keyword()`) - Optional parameters * `:"$.xgafv"` (*type:* `String.t`) - V1 error format. * `:access_token` (*type:* `String.t`) - OAuth access token. @@ -3848,6 +4673,7 @@ defmodule GoogleApi.DLP.V2.Api.Projects do * `:quotaUser` (*type:* `String.t`) - 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. * `:uploadType` (*type:* `String.t`) - Legacy upload protocol for media (e.g. "media", "multipart"). * `:upload_protocol` (*type:* `String.t`) - Upload protocol for media (e.g. "raw", "multipart"). + * `:body` (*type:* `GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2UpdateStoredInfoTypeRequest.t`) - * `opts` (*type:* `keyword()`) - Call options ## Returns @@ -3855,7 +4681,7 @@ defmodule GoogleApi.DLP.V2.Api.Projects do * `{:ok, %GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2StoredInfoType{}}` on success * `{:error, info}` on failure """ - @spec dlp_projects_locations_stored_info_types_get( + @spec dlp_projects_locations_stored_info_types_patch( Tesla.Env.client(), String.t(), keyword(), @@ -3865,7 +4691,7 @@ defmodule GoogleApi.DLP.V2.Api.Projects do | {:ok, Tesla.Env.t()} | {:ok, list()} | {:error, any()} - def dlp_projects_locations_stored_info_types_get( + def dlp_projects_locations_stored_info_types_patch( connection, name, optional_params \\ [], @@ -3882,12 +4708,13 @@ defmodule GoogleApi.DLP.V2.Api.Projects do :prettyPrint => :query, :quotaUser => :query, :uploadType => :query, - :upload_protocol => :query + :upload_protocol => :query, + :body => :body } request = Request.new() - |> Request.method(:get) + |> Request.method(:patch) |> Request.url("/v2/{+name}", %{ "name" => URI.encode(name, &URI.char_unreserved?/1) }) @@ -3902,12 +4729,12 @@ defmodule GoogleApi.DLP.V2.Api.Projects do end @doc """ - Lists stored infoTypes. See https://cloud.google.com/dlp/docs/creating-stored-infotypes to learn more. + Gets a table data profile. ## Parameters * `connection` (*type:* `GoogleApi.DLP.V2.Connection.t`) - Connection to server - * `parent` (*type:* `String.t`) - Required. Parent resource name. The format of this value varies depending on the scope of the request (project or organization) and whether you have [specified a processing location](https://cloud.google.com/dlp/docs/specifying-location): + Projects scope, location specified: `projects/`PROJECT_ID`/locations/`LOCATION_ID + Projects scope, no location specified (defaults to global): `projects/`PROJECT_ID The following example `parent` string specifies a parent project with the identifier `example-project`, and specifies the `europe-west3` location for processing data: parent=projects/example-project/locations/europe-west3 + * `name` (*type:* `String.t`) - Required. Resource name, for example `organizations/12345/locations/us/tableDataProfiles/53234423`. * `optional_params` (*type:* `keyword()`) - Optional parameters * `:"$.xgafv"` (*type:* `String.t`) - V1 error format. * `:access_token` (*type:* `String.t`) - OAuth access token. @@ -3920,30 +4747,26 @@ defmodule GoogleApi.DLP.V2.Api.Projects do * `:quotaUser` (*type:* `String.t`) - 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. * `:uploadType` (*type:* `String.t`) - Legacy upload protocol for media (e.g. "media", "multipart"). * `:upload_protocol` (*type:* `String.t`) - Upload protocol for media (e.g. "raw", "multipart"). - * `:locationId` (*type:* `String.t`) - Deprecated. This field has no effect. - * `:orderBy` (*type:* `String.t`) - Comma separated list of fields to order by, followed by `asc` or `desc` postfix. This list is case-insensitive, default sorting order is ascending, redundant space characters are insignificant. Example: `name asc, display_name, create_time desc` Supported fields are: - `create_time`: corresponds to the time the most recent version of the resource was created. - `state`: corresponds to the state of the resource. - `name`: corresponds to resource name. - `display_name`: corresponds to info type's display name. - * `:pageSize` (*type:* `integer()`) - Size of the page, can be limited by the server. If zero server returns a page of max size 100. - * `:pageToken` (*type:* `String.t`) - Page token to continue retrieval. Comes from previous call to `ListStoredInfoTypes`. * `opts` (*type:* `keyword()`) - Call options ## Returns - * `{:ok, %GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2ListStoredInfoTypesResponse{}}` on success + * `{:ok, %GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2TableDataProfile{}}` on success * `{:error, info}` on failure """ - @spec dlp_projects_locations_stored_info_types_list( + @spec dlp_projects_locations_table_data_profiles_get( Tesla.Env.client(), String.t(), keyword(), keyword() ) :: - {:ok, GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2ListStoredInfoTypesResponse.t()} + {:ok, GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2TableDataProfile.t()} | {:ok, Tesla.Env.t()} | {:ok, list()} | {:error, any()} - def dlp_projects_locations_stored_info_types_list( + def dlp_projects_locations_table_data_profiles_get( connection, - parent, + name, optional_params \\ [], opts \\ [] ) do @@ -3958,18 +4781,14 @@ defmodule GoogleApi.DLP.V2.Api.Projects do :prettyPrint => :query, :quotaUser => :query, :uploadType => :query, - :upload_protocol => :query, - :locationId => :query, - :orderBy => :query, - :pageSize => :query, - :pageToken => :query + :upload_protocol => :query } request = Request.new() |> Request.method(:get) - |> Request.url("/v2/{+parent}/storedInfoTypes", %{ - "parent" => URI.encode(parent, &URI.char_unreserved?/1) + |> Request.url("/v2/{+name}", %{ + "name" => URI.encode(name, &URI.char_unreserved?/1) }) |> Request.add_optional_params(optional_params_config, optional_params) |> Request.library_version(@library_version) @@ -3977,17 +4796,17 @@ defmodule GoogleApi.DLP.V2.Api.Projects do connection |> Connection.execute(request) |> Response.decode( - opts ++ [struct: %GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2ListStoredInfoTypesResponse{}] + opts ++ [struct: %GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2TableDataProfile{}] ) end @doc """ - Updates the stored infoType by creating a new version. The existing version will continue to be used until the new version is ready. See https://cloud.google.com/dlp/docs/creating-stored-infotypes to learn more. + Lists data profiles for an organization. ## Parameters * `connection` (*type:* `GoogleApi.DLP.V2.Connection.t`) - Connection to server - * `name` (*type:* `String.t`) - Required. Resource name of organization and storedInfoType to be updated, for example `organizations/433245324/storedInfoTypes/432452342` or projects/project-id/storedInfoTypes/432452342. + * `parent` (*type:* `String.t`) - Required. Resource name of the organization or project, for example `organizations/433245324/locations/europe` or `projects/project-id/locations/asia`. * `optional_params` (*type:* `keyword()`) - Optional parameters * `:"$.xgafv"` (*type:* `String.t`) - V1 error format. * `:access_token` (*type:* `String.t`) - OAuth access token. @@ -4000,27 +4819,30 @@ defmodule GoogleApi.DLP.V2.Api.Projects do * `:quotaUser` (*type:* `String.t`) - 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. * `:uploadType` (*type:* `String.t`) - Legacy upload protocol for media (e.g. "media", "multipart"). * `:upload_protocol` (*type:* `String.t`) - Upload protocol for media (e.g. "raw", "multipart"). - * `:body` (*type:* `GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2UpdateStoredInfoTypeRequest.t`) - + * `:filter` (*type:* `String.t`) - Allows filtering. Supported syntax: * Filter expressions are made up of one or more restrictions. * Restrictions can be combined by `AND` or `OR` logical operators. A sequence of restrictions implicitly uses `AND`. * A restriction has the form of `{field} {operator} {value}`. * Supported fields/values: - `project_id` - The GCP project ID. - `dataset_id` - The BigQuery dataset ID. - `table_id` - The ID of the BigQuery table. - `sensitivity_level` - HIGH|MODERATE|LOW - `data_risk_level` - HIGH|MODERATE|LOW - `resource_visibility`: PUBLIC|RESTRICTED - `status_code` - an RPC status code as defined in https://github.com/googleapis/googleapis/blob/master/google/rpc/code.proto * The operator must be `=` or `!=`. Examples: * project_id = 12345 AND status_code = 1 * project_id = 12345 AND sensitivity_level = HIGH * project_id = 12345 AND resource_visibility = PUBLIC The length of this field should be no more than 500 characters. + * `:orderBy` (*type:* `String.t`) - Comma separated list of fields to order by, followed by `asc` or `desc` postfix. This list is case insensitive. The default sorting order is ascending. Redundant space characters are insignificant. Only one order field at a time is allowed. Examples: * `project_id asc` * `table_id` * `sensitivity_level desc` Supported fields are: - `project_id`: The GCP project ID. - `dataset_id`: The ID of a BigQuery dataset. - `table_id`: The ID of a BigQuery table. - `sensitivity_level`: How sensitive the data in a table is, at most. - `data_risk_level`: How much risk is associated with this data. - `profile_last_generated`: When the profile was last updated in epoch seconds. - `last_modified`: The last time the resource was modified. - `resource_visibility`: Visibility restriction for this resource. - `row_count`: Number of rows in this resource. + * `:pageSize` (*type:* `integer()`) - Size of the page. This value can be limited by the server. If zero, server returns a page of max size 100. + * `:pageToken` (*type:* `String.t`) - Page token to continue retrieval. * `opts` (*type:* `keyword()`) - Call options ## Returns - * `{:ok, %GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2StoredInfoType{}}` on success + * `{:ok, %GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2ListTableDataProfilesResponse{}}` on success * `{:error, info}` on failure """ - @spec dlp_projects_locations_stored_info_types_patch( + @spec dlp_projects_locations_table_data_profiles_list( Tesla.Env.client(), String.t(), keyword(), keyword() ) :: - {:ok, GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2StoredInfoType.t()} + {:ok, GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2ListTableDataProfilesResponse.t()} | {:ok, Tesla.Env.t()} | {:ok, list()} | {:error, any()} - def dlp_projects_locations_stored_info_types_patch( + def dlp_projects_locations_table_data_profiles_list( connection, - name, + parent, optional_params \\ [], opts \\ [] ) do @@ -4036,14 +4858,17 @@ defmodule GoogleApi.DLP.V2.Api.Projects do :quotaUser => :query, :uploadType => :query, :upload_protocol => :query, - :body => :body + :filter => :query, + :orderBy => :query, + :pageSize => :query, + :pageToken => :query } request = Request.new() - |> Request.method(:patch) - |> Request.url("/v2/{+name}", %{ - "name" => URI.encode(name, &URI.char_unreserved?/1) + |> Request.method(:get) + |> Request.url("/v2/{+parent}/tableDataProfiles", %{ + "parent" => URI.encode(parent, &URI.char_unreserved?/1) }) |> Request.add_optional_params(optional_params_config, optional_params) |> Request.library_version(@library_version) @@ -4051,17 +4876,17 @@ defmodule GoogleApi.DLP.V2.Api.Projects do connection |> Connection.execute(request) |> Response.decode( - opts ++ [struct: %GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2StoredInfoType{}] + opts ++ [struct: %GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2ListTableDataProfilesResponse{}] ) end @doc """ - Creates a pre-built stored infoType to be used for inspection. See https://cloud.google.com/dlp/docs/creating-stored-infotypes to learn more. + Creates a pre-built stored infoType to be used for inspection. See https://cloud.google.com/sensitive-data-protection/docs/creating-stored-infotypes to learn more. ## Parameters * `connection` (*type:* `GoogleApi.DLP.V2.Connection.t`) - Connection to server - * `parent` (*type:* `String.t`) - Required. Parent resource name. The format of this value varies depending on the scope of the request (project or organization) and whether you have [specified a processing location](https://cloud.google.com/dlp/docs/specifying-location): + Projects scope, location specified: `projects/`PROJECT_ID`/locations/`LOCATION_ID + Projects scope, no location specified (defaults to global): `projects/`PROJECT_ID + Organizations scope, location specified: `organizations/`ORG_ID`/locations/`LOCATION_ID + Organizations scope, no location specified (defaults to global): `organizations/`ORG_ID The following example `parent` string specifies a parent project with the identifier `example-project`, and specifies the `europe-west3` location for processing data: parent=projects/example-project/locations/europe-west3 + * `parent` (*type:* `String.t`) - Required. Parent resource name. The format of this value varies depending on the scope of the request (project or organization) and whether you have [specified a processing location](https://cloud.google.com/sensitive-data-protection/docs/specifying-location): + Projects scope, location specified: `projects/`PROJECT_ID`/locations/`LOCATION_ID + Projects scope, no location specified (defaults to global): `projects/`PROJECT_ID + Organizations scope, location specified: `organizations/`ORG_ID`/locations/`LOCATION_ID + Organizations scope, no location specified (defaults to global): `organizations/`ORG_ID The following example `parent` string specifies a parent project with the identifier `example-project`, and specifies the `europe-west3` location for processing data: parent=projects/example-project/locations/europe-west3 * `optional_params` (*type:* `keyword()`) - Optional parameters * `:"$.xgafv"` (*type:* `String.t`) - V1 error format. * `:access_token` (*type:* `String.t`) - OAuth access token. @@ -4125,7 +4950,7 @@ defmodule GoogleApi.DLP.V2.Api.Projects do end @doc """ - Deletes a stored infoType. See https://cloud.google.com/dlp/docs/creating-stored-infotypes to learn more. + Deletes a stored infoType. See https://cloud.google.com/sensitive-data-protection/docs/creating-stored-infotypes to learn more. ## Parameters @@ -4190,7 +5015,7 @@ defmodule GoogleApi.DLP.V2.Api.Projects do end @doc """ - Gets a stored infoType. See https://cloud.google.com/dlp/docs/creating-stored-infotypes to learn more. + Gets a stored infoType. See https://cloud.google.com/sensitive-data-protection/docs/creating-stored-infotypes to learn more. ## Parameters @@ -4252,12 +5077,12 @@ defmodule GoogleApi.DLP.V2.Api.Projects do end @doc """ - Lists stored infoTypes. See https://cloud.google.com/dlp/docs/creating-stored-infotypes to learn more. + Lists stored infoTypes. See https://cloud.google.com/sensitive-data-protection/docs/creating-stored-infotypes to learn more. ## Parameters * `connection` (*type:* `GoogleApi.DLP.V2.Connection.t`) - Connection to server - * `parent` (*type:* `String.t`) - Required. Parent resource name. The format of this value varies depending on the scope of the request (project or organization) and whether you have [specified a processing location](https://cloud.google.com/dlp/docs/specifying-location): + Projects scope, location specified: `projects/`PROJECT_ID`/locations/`LOCATION_ID + Projects scope, no location specified (defaults to global): `projects/`PROJECT_ID The following example `parent` string specifies a parent project with the identifier `example-project`, and specifies the `europe-west3` location for processing data: parent=projects/example-project/locations/europe-west3 + * `parent` (*type:* `String.t`) - Required. Parent resource name. The format of this value varies depending on the scope of the request (project or organization) and whether you have [specified a processing location](https://cloud.google.com/sensitive-data-protection/docs/specifying-location): + Projects scope, location specified: `projects/`PROJECT_ID`/locations/`LOCATION_ID + Projects scope, no location specified (defaults to global): `projects/`PROJECT_ID The following example `parent` string specifies a parent project with the identifier `example-project`, and specifies the `europe-west3` location for processing data: parent=projects/example-project/locations/europe-west3 * `optional_params` (*type:* `keyword()`) - Optional parameters * `:"$.xgafv"` (*type:* `String.t`) - V1 error format. * `:access_token` (*type:* `String.t`) - OAuth access token. @@ -4271,9 +5096,9 @@ defmodule GoogleApi.DLP.V2.Api.Projects do * `:uploadType` (*type:* `String.t`) - Legacy upload protocol for media (e.g. "media", "multipart"). * `:upload_protocol` (*type:* `String.t`) - Upload protocol for media (e.g. "raw", "multipart"). * `:locationId` (*type:* `String.t`) - Deprecated. This field has no effect. - * `:orderBy` (*type:* `String.t`) - Comma separated list of fields to order by, followed by `asc` or `desc` postfix. This list is case-insensitive, default sorting order is ascending, redundant space characters are insignificant. Example: `name asc, display_name, create_time desc` Supported fields are: - `create_time`: corresponds to the time the most recent version of the resource was created. - `state`: corresponds to the state of the resource. - `name`: corresponds to resource name. - `display_name`: corresponds to info type's display name. - * `:pageSize` (*type:* `integer()`) - Size of the page, can be limited by the server. If zero server returns a page of max size 100. - * `:pageToken` (*type:* `String.t`) - Page token to continue retrieval. Comes from previous call to `ListStoredInfoTypes`. + * `:orderBy` (*type:* `String.t`) - Comma separated list of fields to order by, followed by `asc` or `desc` postfix. This list is case insensitive. The default sorting order is ascending. Redundant space characters are insignificant. Example: `name asc, display_name, create_time desc` Supported fields are: - `create_time`: corresponds to the time the most recent version of the resource was created. - `state`: corresponds to the state of the resource. - `name`: corresponds to resource name. - `display_name`: corresponds to info type's display name. + * `:pageSize` (*type:* `integer()`) - Size of the page. This value can be limited by the server. If zero server returns a page of max size 100. + * `:pageToken` (*type:* `String.t`) - Page token to continue retrieval. Comes from the previous call to `ListStoredInfoTypes`. * `opts` (*type:* `keyword()`) - Call options ## Returns @@ -4322,7 +5147,7 @@ defmodule GoogleApi.DLP.V2.Api.Projects do end @doc """ - Updates the stored infoType by creating a new version. The existing version will continue to be used until the new version is ready. See https://cloud.google.com/dlp/docs/creating-stored-infotypes to learn more. + Updates the stored infoType by creating a new version. The existing version will continue to be used until the new version is ready. See https://cloud.google.com/sensitive-data-protection/docs/creating-stored-infotypes to learn more. ## Parameters diff --git a/clients/dlp/lib/google_api/dlp/v2/metadata.ex b/clients/dlp/lib/google_api/dlp/v2/metadata.ex index 7019b66bfd..550d2c8fac 100644 --- a/clients/dlp/lib/google_api/dlp/v2/metadata.ex +++ b/clients/dlp/lib/google_api/dlp/v2/metadata.ex @@ -20,7 +20,7 @@ defmodule GoogleApi.DLP.V2 do API client metadata for GoogleApi.DLP.V2. """ - @discovery_revision "20221115" + @discovery_revision "20240303" def discovery_revision(), do: @discovery_revision end diff --git a/clients/dlp/lib/google_api/dlp/v2/model/google_privacy_dlp_v2_action.ex b/clients/dlp/lib/google_api/dlp/v2/model/google_privacy_dlp_v2_action.ex index 628cc812b1..86de23223a 100644 --- a/clients/dlp/lib/google_api/dlp/v2/model/google_privacy_dlp_v2_action.ex +++ b/clients/dlp/lib/google_api/dlp/v2/model/google_privacy_dlp_v2_action.ex @@ -17,7 +17,7 @@ defmodule GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2Action do @moduledoc """ - A task to execute on the completion of a job. See https://cloud.google.com/dlp/docs/concepts-actions to learn more. + A task to execute on the completion of a job. See https://cloud.google.com/sensitive-data-protection/docs/concepts-actions to learn more. ## Attributes diff --git a/clients/dlp/lib/google_api/dlp/v2/model/google_privacy_dlp_v2_action_details.ex b/clients/dlp/lib/google_api/dlp/v2/model/google_privacy_dlp_v2_action_details.ex new file mode 100644 index 0000000000..a0698a7d59 --- /dev/null +++ b/clients/dlp/lib/google_api/dlp/v2/model/google_privacy_dlp_v2_action_details.ex @@ -0,0 +1,49 @@ +# Copyright 2019 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# NOTE: This file is auto generated by the elixir code generator program. +# Do not edit this file manually. + +defmodule GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2ActionDetails do + @moduledoc """ + The results of an Action. + + ## Attributes + + * `deidentifyDetails` (*type:* `GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2DeidentifyDataSourceDetails.t`, *default:* `nil`) - Outcome of a de-identification action. + """ + + use GoogleApi.Gax.ModelBase + + @type t :: %__MODULE__{ + :deidentifyDetails => + GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2DeidentifyDataSourceDetails.t() | nil + } + + field(:deidentifyDetails, + as: GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2DeidentifyDataSourceDetails + ) +end + +defimpl Poison.Decoder, for: GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2ActionDetails do + def decode(value, options) do + GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2ActionDetails.decode(value, options) + end +end + +defimpl Poison.Encoder, for: GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2ActionDetails do + def encode(value, options) do + GoogleApi.Gax.ModelBase.encode(value, options) + end +end diff --git a/clients/dlp/lib/google_api/dlp/v2/model/google_privacy_dlp_v2_all_other_big_query_tables.ex b/clients/dlp/lib/google_api/dlp/v2/model/google_privacy_dlp_v2_all_other_big_query_tables.ex new file mode 100644 index 0000000000..5b33c1a8e9 --- /dev/null +++ b/clients/dlp/lib/google_api/dlp/v2/model/google_privacy_dlp_v2_all_other_big_query_tables.ex @@ -0,0 +1,41 @@ +# Copyright 2019 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# NOTE: This file is auto generated by the elixir code generator program. +# Do not edit this file manually. + +defmodule GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2AllOtherBigQueryTables do + @moduledoc """ + Catch-all for all other tables not specified by other filters. Should always be last, except for single-table configurations, which will only have a TableReference target. + + ## Attributes + + """ + + use GoogleApi.Gax.ModelBase + + @type t :: %__MODULE__{} +end + +defimpl Poison.Decoder, for: GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2AllOtherBigQueryTables do + def decode(value, options) do + GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2AllOtherBigQueryTables.decode(value, options) + end +end + +defimpl Poison.Encoder, for: GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2AllOtherBigQueryTables do + def encode(value, options) do + GoogleApi.Gax.ModelBase.encode(value, options) + end +end diff --git a/clients/dlp/lib/google_api/dlp/v2/model/google_privacy_dlp_v2_big_query_discovery_target.ex b/clients/dlp/lib/google_api/dlp/v2/model/google_privacy_dlp_v2_big_query_discovery_target.ex new file mode 100644 index 0000000000..c86bdd182b --- /dev/null +++ b/clients/dlp/lib/google_api/dlp/v2/model/google_privacy_dlp_v2_big_query_discovery_target.ex @@ -0,0 +1,57 @@ +# Copyright 2019 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# NOTE: This file is auto generated by the elixir code generator program. +# Do not edit this file manually. + +defmodule GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2BigQueryDiscoveryTarget do + @moduledoc """ + Target used to match against for discovery with BigQuery tables + + ## Attributes + + * `cadence` (*type:* `GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2DiscoveryGenerationCadence.t`, *default:* `nil`) - How often and when to update profiles. New tables that match both the filter and conditions are scanned as quickly as possible depending on system capacity. + * `conditions` (*type:* `GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2DiscoveryBigQueryConditions.t`, *default:* `nil`) - In addition to matching the filter, these conditions must be true before a profile is generated. + * `disabled` (*type:* `GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2Disabled.t`, *default:* `nil`) - Tables that match this filter will not have profiles created. + * `filter` (*type:* `GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2DiscoveryBigQueryFilter.t`, *default:* `nil`) - Required. The tables the discovery cadence applies to. The first target with a matching filter will be the one to apply to a table. + """ + + use GoogleApi.Gax.ModelBase + + @type t :: %__MODULE__{ + :cadence => + GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2DiscoveryGenerationCadence.t() | nil, + :conditions => + GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2DiscoveryBigQueryConditions.t() | nil, + :disabled => GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2Disabled.t() | nil, + :filter => GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2DiscoveryBigQueryFilter.t() | nil + } + + field(:cadence, as: GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2DiscoveryGenerationCadence) + field(:conditions, as: GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2DiscoveryBigQueryConditions) + field(:disabled, as: GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2Disabled) + field(:filter, as: GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2DiscoveryBigQueryFilter) +end + +defimpl Poison.Decoder, for: GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2BigQueryDiscoveryTarget do + def decode(value, options) do + GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2BigQueryDiscoveryTarget.decode(value, options) + end +end + +defimpl Poison.Encoder, for: GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2BigQueryDiscoveryTarget do + def encode(value, options) do + GoogleApi.Gax.ModelBase.encode(value, options) + end +end diff --git a/clients/dlp/lib/google_api/dlp/v2/model/google_privacy_dlp_v2_big_query_options.ex b/clients/dlp/lib/google_api/dlp/v2/model/google_privacy_dlp_v2_big_query_options.ex index 9d041852d2..6fbd53da98 100644 --- a/clients/dlp/lib/google_api/dlp/v2/model/google_privacy_dlp_v2_big_query_options.ex +++ b/clients/dlp/lib/google_api/dlp/v2/model/google_privacy_dlp_v2_big_query_options.ex @@ -21,12 +21,12 @@ defmodule GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2BigQueryOptions do ## Attributes - * `excludedFields` (*type:* `list(GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2FieldId.t)`, *default:* `nil`) - References to fields excluded from scanning. This allows you to skip inspection of entire columns which you know have no findings. + * `excludedFields` (*type:* `list(GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2FieldId.t)`, *default:* `nil`) - References to fields excluded from scanning. This allows you to skip inspection of entire columns which you know have no findings. When inspecting a table, we recommend that you inspect all columns. Otherwise, findings might be affected because hints from excluded columns will not be used. * `identifyingFields` (*type:* `list(GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2FieldId.t)`, *default:* `nil`) - Table fields that may uniquely identify a row within the table. When `actions.saveFindings.outputConfig.table` is specified, the values of columns specified here are available in the output table under `location.content_locations.record_location.record_key.id_values`. Nested fields such as `person.birthdate.year` are allowed. - * `includedFields` (*type:* `list(GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2FieldId.t)`, *default:* `nil`) - Limit scanning only to these fields. + * `includedFields` (*type:* `list(GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2FieldId.t)`, *default:* `nil`) - Limit scanning only to these fields. When inspecting a table, we recommend that you inspect all columns. Otherwise, findings might be affected because hints from excluded columns will not be used. * `rowsLimit` (*type:* `String.t`, *default:* `nil`) - Max number of rows to scan. If the table has more rows than this value, the rest of the rows are omitted. If not set, or if set to 0, all rows will be scanned. Only one of rows_limit and rows_limit_percent can be specified. Cannot be used in conjunction with TimespanConfig. - * `rowsLimitPercent` (*type:* `integer()`, *default:* `nil`) - Max percentage of rows to scan. The rest are omitted. The number of rows scanned is rounded down. Must be between 0 and 100, inclusively. Both 0 and 100 means no limit. Defaults to 0. Only one of rows_limit and rows_limit_percent can be specified. Cannot be used in conjunction with TimespanConfig. - * `sampleMethod` (*type:* `String.t`, *default:* `nil`) - + * `rowsLimitPercent` (*type:* `integer()`, *default:* `nil`) - Max percentage of rows to scan. The rest are omitted. The number of rows scanned is rounded down. Must be between 0 and 100, inclusively. Both 0 and 100 means no limit. Defaults to 0. Only one of rows_limit and rows_limit_percent can be specified. Cannot be used in conjunction with TimespanConfig. Caution: A [known issue](https://cloud.google.com/sensitive-data-protection/docs/known-issues#bq-sampling) is causing the `rowsLimitPercent` field to behave unexpectedly. We recommend using `rowsLimit` instead. + * `sampleMethod` (*type:* `String.t`, *default:* `nil`) - How to sample the data. * `tableReference` (*type:* `GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2BigQueryTable.t`, *default:* `nil`) - Complete BigQuery table reference. """ diff --git a/clients/dlp/lib/google_api/dlp/v2/model/google_privacy_dlp_v2_big_query_regex.ex b/clients/dlp/lib/google_api/dlp/v2/model/google_privacy_dlp_v2_big_query_regex.ex new file mode 100644 index 0000000000..5c235c40ae --- /dev/null +++ b/clients/dlp/lib/google_api/dlp/v2/model/google_privacy_dlp_v2_big_query_regex.ex @@ -0,0 +1,52 @@ +# Copyright 2019 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# NOTE: This file is auto generated by the elixir code generator program. +# Do not edit this file manually. + +defmodule GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2BigQueryRegex do + @moduledoc """ + A pattern to match against one or more tables, datasets, or projects that contain BigQuery tables. At least one pattern must be specified. Regular expressions use RE2 [syntax](https://github.com/google/re2/wiki/Syntax); a guide can be found under the google/re2 repository on GitHub. + + ## Attributes + + * `datasetIdRegex` (*type:* `String.t`, *default:* `nil`) - If unset, this property matches all datasets. + * `projectIdRegex` (*type:* `String.t`, *default:* `nil`) - For organizations, if unset, will match all projects. Has no effect for data profile configurations created within a project. + * `tableIdRegex` (*type:* `String.t`, *default:* `nil`) - If unset, this property matches all tables. + """ + + use GoogleApi.Gax.ModelBase + + @type t :: %__MODULE__{ + :datasetIdRegex => String.t() | nil, + :projectIdRegex => String.t() | nil, + :tableIdRegex => String.t() | nil + } + + field(:datasetIdRegex) + field(:projectIdRegex) + field(:tableIdRegex) +end + +defimpl Poison.Decoder, for: GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2BigQueryRegex do + def decode(value, options) do + GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2BigQueryRegex.decode(value, options) + end +end + +defimpl Poison.Encoder, for: GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2BigQueryRegex do + def encode(value, options) do + GoogleApi.Gax.ModelBase.encode(value, options) + end +end diff --git a/clients/dlp/lib/google_api/dlp/v2/model/google_privacy_dlp_v2_big_query_regexes.ex b/clients/dlp/lib/google_api/dlp/v2/model/google_privacy_dlp_v2_big_query_regexes.ex new file mode 100644 index 0000000000..765fd5cf3f --- /dev/null +++ b/clients/dlp/lib/google_api/dlp/v2/model/google_privacy_dlp_v2_big_query_regexes.ex @@ -0,0 +1,46 @@ +# Copyright 2019 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# NOTE: This file is auto generated by the elixir code generator program. +# Do not edit this file manually. + +defmodule GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2BigQueryRegexes do + @moduledoc """ + A collection of regular expressions to determine what tables to match against. + + ## Attributes + + * `patterns` (*type:* `list(GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2BigQueryRegex.t)`, *default:* `nil`) - A single BigQuery regular expression pattern to match against one or more tables, datasets, or projects that contain BigQuery tables. + """ + + use GoogleApi.Gax.ModelBase + + @type t :: %__MODULE__{ + :patterns => list(GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2BigQueryRegex.t()) | nil + } + + field(:patterns, as: GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2BigQueryRegex, type: :list) +end + +defimpl Poison.Decoder, for: GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2BigQueryRegexes do + def decode(value, options) do + GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2BigQueryRegexes.decode(value, options) + end +end + +defimpl Poison.Encoder, for: GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2BigQueryRegexes do + def encode(value, options) do + GoogleApi.Gax.ModelBase.encode(value, options) + end +end diff --git a/clients/dlp/lib/google_api/dlp/v2/model/google_privacy_dlp_v2_big_query_table_collection.ex b/clients/dlp/lib/google_api/dlp/v2/model/google_privacy_dlp_v2_big_query_table_collection.ex new file mode 100644 index 0000000000..82244d11e8 --- /dev/null +++ b/clients/dlp/lib/google_api/dlp/v2/model/google_privacy_dlp_v2_big_query_table_collection.ex @@ -0,0 +1,46 @@ +# Copyright 2019 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# NOTE: This file is auto generated by the elixir code generator program. +# Do not edit this file manually. + +defmodule GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2BigQueryTableCollection do + @moduledoc """ + Specifies a collection of BigQuery tables. Used for Discovery. + + ## Attributes + + * `includeRegexes` (*type:* `GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2BigQueryRegexes.t`, *default:* `nil`) - A collection of regular expressions to match a BigQuery table against. + """ + + use GoogleApi.Gax.ModelBase + + @type t :: %__MODULE__{ + :includeRegexes => GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2BigQueryRegexes.t() | nil + } + + field(:includeRegexes, as: GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2BigQueryRegexes) +end + +defimpl Poison.Decoder, for: GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2BigQueryTableCollection do + def decode(value, options) do + GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2BigQueryTableCollection.decode(value, options) + end +end + +defimpl Poison.Encoder, for: GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2BigQueryTableCollection do + def encode(value, options) do + GoogleApi.Gax.ModelBase.encode(value, options) + end +end diff --git a/clients/dlp/lib/google_api/dlp/v2/model/google_privacy_dlp_v2_big_query_table_types.ex b/clients/dlp/lib/google_api/dlp/v2/model/google_privacy_dlp_v2_big_query_table_types.ex new file mode 100644 index 0000000000..288dc9f4df --- /dev/null +++ b/clients/dlp/lib/google_api/dlp/v2/model/google_privacy_dlp_v2_big_query_table_types.ex @@ -0,0 +1,46 @@ +# Copyright 2019 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# NOTE: This file is auto generated by the elixir code generator program. +# Do not edit this file manually. + +defmodule GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2BigQueryTableTypes do + @moduledoc """ + The types of BigQuery tables supported by Cloud DLP. + + ## Attributes + + * `types` (*type:* `list(String.t)`, *default:* `nil`) - A set of BigQuery table types. + """ + + use GoogleApi.Gax.ModelBase + + @type t :: %__MODULE__{ + :types => list(String.t()) | nil + } + + field(:types, type: :list) +end + +defimpl Poison.Decoder, for: GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2BigQueryTableTypes do + def decode(value, options) do + GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2BigQueryTableTypes.decode(value, options) + end +end + +defimpl Poison.Encoder, for: GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2BigQueryTableTypes do + def encode(value, options) do + GoogleApi.Gax.ModelBase.encode(value, options) + end +end diff --git a/clients/dlp/lib/google_api/dlp/v2/model/google_privacy_dlp_v2_bucketing_config.ex b/clients/dlp/lib/google_api/dlp/v2/model/google_privacy_dlp_v2_bucketing_config.ex index 71c8212a1b..ca2857f1ef 100644 --- a/clients/dlp/lib/google_api/dlp/v2/model/google_privacy_dlp_v2_bucketing_config.ex +++ b/clients/dlp/lib/google_api/dlp/v2/model/google_privacy_dlp_v2_bucketing_config.ex @@ -17,7 +17,7 @@ defmodule GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2BucketingConfig do @moduledoc """ - Generalization function that buckets values based on ranges. The ranges and replacement values are dynamically provided by the user for custom behavior, such as 1-30 -> LOW 31-65 -> MEDIUM 66-100 -> HIGH This can be used on data of type: number, long, string, timestamp. If the bound `Value` type differs from the type of data being transformed, we will first attempt converting the type of the data to be transformed to match the type of the bound before comparing. See https://cloud.google.com/dlp/docs/concepts-bucketing to learn more. + Generalization function that buckets values based on ranges. The ranges and replacement values are dynamically provided by the user for custom behavior, such as 1-30 -> LOW 31-65 -> MEDIUM 66-100 -> HIGH This can be used on data of type: number, long, string, timestamp. If the bound `Value` type differs from the type of data being transformed, we will first attempt converting the type of the data to be transformed to match the type of the bound before comparing. See https://cloud.google.com/sensitive-data-protection/docs/concepts-bucketing to learn more. ## Attributes diff --git a/clients/dlp/lib/google_api/dlp/v2/model/google_privacy_dlp_v2_cloud_storage_options.ex b/clients/dlp/lib/google_api/dlp/v2/model/google_privacy_dlp_v2_cloud_storage_options.ex index 845ebb76e6..213258cbec 100644 --- a/clients/dlp/lib/google_api/dlp/v2/model/google_privacy_dlp_v2_cloud_storage_options.ex +++ b/clients/dlp/lib/google_api/dlp/v2/model/google_privacy_dlp_v2_cloud_storage_options.ex @@ -21,12 +21,12 @@ defmodule GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2CloudStorageOptions do ## Attributes - * `bytesLimitPerFile` (*type:* `String.t`, *default:* `nil`) - Max number of bytes to scan from a file. If a scanned file's size is bigger than this value then the rest of the bytes are omitted. Only one of bytes_limit_per_file and bytes_limit_per_file_percent can be specified. Cannot be set if de-identification is requested. - * `bytesLimitPerFilePercent` (*type:* `integer()`, *default:* `nil`) - Max percentage of bytes to scan from a file. The rest are omitted. The number of bytes scanned is rounded down. Must be between 0 and 100, inclusively. Both 0 and 100 means no limit. Defaults to 0. Only one of bytes_limit_per_file and bytes_limit_per_file_percent can be specified. Cannot be set if de-identification is requested. + * `bytesLimitPerFile` (*type:* `String.t`, *default:* `nil`) - Max number of bytes to scan from a file. If a scanned file's size is bigger than this value then the rest of the bytes are omitted. Only one of `bytes_limit_per_file` and `bytes_limit_per_file_percent` can be specified. This field can't be set if de-identification is requested. For certain file types, setting this field has no effect. For more information, see [Limits on bytes scanned per file](https://cloud.google.com/sensitive-data-protection/docs/supported-file-types#max-byte-size-per-file). + * `bytesLimitPerFilePercent` (*type:* `integer()`, *default:* `nil`) - Max percentage of bytes to scan from a file. The rest are omitted. The number of bytes scanned is rounded down. Must be between 0 and 100, inclusively. Both 0 and 100 means no limit. Defaults to 0. Only one of bytes_limit_per_file and bytes_limit_per_file_percent can be specified. This field can't be set if de-identification is requested. For certain file types, setting this field has no effect. For more information, see [Limits on bytes scanned per file](https://cloud.google.com/sensitive-data-protection/docs/supported-file-types#max-byte-size-per-file). * `fileSet` (*type:* `GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2FileSet.t`, *default:* `nil`) - The set of one or more files to scan. * `fileTypes` (*type:* `list(String.t)`, *default:* `nil`) - List of file type groups to include in the scan. If empty, all files are scanned and available data format processors are applied. In addition, the binary content of the selected files is always scanned as well. Images are scanned only as binary if the specified region does not support image inspection and no file_types were specified. Image inspection is restricted to 'global', 'us', 'asia', and 'europe'. * `filesLimitPercent` (*type:* `integer()`, *default:* `nil`) - Limits the number of files to scan to this percentage of the input FileSet. Number of files scanned is rounded down. Must be between 0 and 100, inclusively. Both 0 and 100 means no limit. Defaults to 0. - * `sampleMethod` (*type:* `String.t`, *default:* `nil`) - + * `sampleMethod` (*type:* `String.t`, *default:* `nil`) - How to sample the data. """ use GoogleApi.Gax.ModelBase diff --git a/clients/dlp/lib/google_api/dlp/v2/model/google_privacy_dlp_v2_cloud_storage_path.ex b/clients/dlp/lib/google_api/dlp/v2/model/google_privacy_dlp_v2_cloud_storage_path.ex index 01b812efab..ca57b15204 100644 --- a/clients/dlp/lib/google_api/dlp/v2/model/google_privacy_dlp_v2_cloud_storage_path.ex +++ b/clients/dlp/lib/google_api/dlp/v2/model/google_privacy_dlp_v2_cloud_storage_path.ex @@ -21,7 +21,7 @@ defmodule GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2CloudStoragePath do ## Attributes - * `path` (*type:* `String.t`, *default:* `nil`) - A url representing a file or path (no wildcards) in Cloud Storage. Example: gs://[BUCKET_NAME]/dictionary.txt + * `path` (*type:* `String.t`, *default:* `nil`) - A URL representing a file or path (no wildcards) in Cloud Storage. Example: `gs://[BUCKET_NAME]/dictionary.txt` """ use GoogleApi.Gax.ModelBase diff --git a/clients/dlp/lib/google_api/dlp/v2/model/google_privacy_dlp_v2_column_data_profile.ex b/clients/dlp/lib/google_api/dlp/v2/model/google_privacy_dlp_v2_column_data_profile.ex new file mode 100644 index 0000000000..259d86eaa8 --- /dev/null +++ b/clients/dlp/lib/google_api/dlp/v2/model/google_privacy_dlp_v2_column_data_profile.ex @@ -0,0 +1,110 @@ +# Copyright 2019 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# NOTE: This file is auto generated by the elixir code generator program. +# Do not edit this file manually. + +defmodule GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2ColumnDataProfile do + @moduledoc """ + The profile for a scanned column within a table. + + ## Attributes + + * `column` (*type:* `String.t`, *default:* `nil`) - The name of the column. + * `columnInfoType` (*type:* `GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2InfoTypeSummary.t`, *default:* `nil`) - If it's been determined this column can be identified as a single type, this will be set. Otherwise the column either has unidentifiable content or mixed types. + * `columnType` (*type:* `String.t`, *default:* `nil`) - The data type of a given column. + * `dataRiskLevel` (*type:* `GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2DataRiskLevel.t`, *default:* `nil`) - The data risk level for this column. + * `datasetId` (*type:* `String.t`, *default:* `nil`) - The BigQuery dataset ID. + * `datasetLocation` (*type:* `String.t`, *default:* `nil`) - The BigQuery location where the dataset's data is stored. See https://cloud.google.com/bigquery/docs/locations for supported locations. + * `datasetProjectId` (*type:* `String.t`, *default:* `nil`) - The Google Cloud project ID that owns the profiled resource. + * `estimatedNullPercentage` (*type:* `String.t`, *default:* `nil`) - Approximate percentage of entries being null in the column. + * `estimatedUniquenessScore` (*type:* `String.t`, *default:* `nil`) - Approximate uniqueness of the column. + * `freeTextScore` (*type:* `float()`, *default:* `nil`) - The likelihood that this column contains free-form text. A value close to 1 may indicate the column is likely to contain free-form or natural language text. Range in 0-1. + * `name` (*type:* `String.t`, *default:* `nil`) - The name of the profile. + * `otherMatches` (*type:* `list(GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2OtherInfoTypeSummary.t)`, *default:* `nil`) - Other types found within this column. List will be unordered. + * `policyState` (*type:* `String.t`, *default:* `nil`) - Indicates if a policy tag has been applied to the column. + * `profileLastGenerated` (*type:* `DateTime.t`, *default:* `nil`) - The last time the profile was generated. + * `profileStatus` (*type:* `GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2ProfileStatus.t`, *default:* `nil`) - Success or error status from the most recent profile generation attempt. May be empty if the profile is still being generated. + * `sensitivityScore` (*type:* `GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2SensitivityScore.t`, *default:* `nil`) - The sensitivity of this column. + * `state` (*type:* `String.t`, *default:* `nil`) - State of a profile. + * `tableDataProfile` (*type:* `String.t`, *default:* `nil`) - The resource name of the table data profile. + * `tableFullResource` (*type:* `String.t`, *default:* `nil`) - The resource name of the resource this column is within. + * `tableId` (*type:* `String.t`, *default:* `nil`) - The BigQuery table ID. + """ + + use GoogleApi.Gax.ModelBase + + @type t :: %__MODULE__{ + :column => String.t() | nil, + :columnInfoType => GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2InfoTypeSummary.t() | nil, + :columnType => String.t() | nil, + :dataRiskLevel => GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2DataRiskLevel.t() | nil, + :datasetId => String.t() | nil, + :datasetLocation => String.t() | nil, + :datasetProjectId => String.t() | nil, + :estimatedNullPercentage => String.t() | nil, + :estimatedUniquenessScore => String.t() | nil, + :freeTextScore => float() | nil, + :name => String.t() | nil, + :otherMatches => + list(GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2OtherInfoTypeSummary.t()) | nil, + :policyState => String.t() | nil, + :profileLastGenerated => DateTime.t() | nil, + :profileStatus => GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2ProfileStatus.t() | nil, + :sensitivityScore => + GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2SensitivityScore.t() | nil, + :state => String.t() | nil, + :tableDataProfile => String.t() | nil, + :tableFullResource => String.t() | nil, + :tableId => String.t() | nil + } + + field(:column) + field(:columnInfoType, as: GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2InfoTypeSummary) + field(:columnType) + field(:dataRiskLevel, as: GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2DataRiskLevel) + field(:datasetId) + field(:datasetLocation) + field(:datasetProjectId) + field(:estimatedNullPercentage) + field(:estimatedUniquenessScore) + field(:freeTextScore) + field(:name) + + field(:otherMatches, + as: GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2OtherInfoTypeSummary, + type: :list + ) + + field(:policyState) + field(:profileLastGenerated, as: DateTime) + field(:profileStatus, as: GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2ProfileStatus) + field(:sensitivityScore, as: GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2SensitivityScore) + field(:state) + field(:tableDataProfile) + field(:tableFullResource) + field(:tableId) +end + +defimpl Poison.Decoder, for: GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2ColumnDataProfile do + def decode(value, options) do + GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2ColumnDataProfile.decode(value, options) + end +end + +defimpl Poison.Encoder, for: GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2ColumnDataProfile do + def encode(value, options) do + GoogleApi.Gax.ModelBase.encode(value, options) + end +end diff --git a/clients/dlp/lib/google_api/dlp/v2/model/google_privacy_dlp_v2_content_item.ex b/clients/dlp/lib/google_api/dlp/v2/model/google_privacy_dlp_v2_content_item.ex index 6e88a9f3c5..b131cee87f 100644 --- a/clients/dlp/lib/google_api/dlp/v2/model/google_privacy_dlp_v2_content_item.ex +++ b/clients/dlp/lib/google_api/dlp/v2/model/google_privacy_dlp_v2_content_item.ex @@ -17,12 +17,12 @@ defmodule GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2ContentItem do @moduledoc """ - + Type of content to inspect. ## Attributes * `byteItem` (*type:* `GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2ByteContentItem.t`, *default:* `nil`) - Content data to inspect or redact. Replaces `type` and `data`. - * `table` (*type:* `GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2Table.t`, *default:* `nil`) - Structured content for inspection. See https://cloud.google.com/dlp/docs/inspecting-text#inspecting_a_table to learn more. + * `table` (*type:* `GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2Table.t`, *default:* `nil`) - Structured content for inspection. See https://cloud.google.com/sensitive-data-protection/docs/inspecting-text#inspecting_a_table to learn more. * `value` (*type:* `String.t`, *default:* `nil`) - String data to inspect or redact. """ diff --git a/clients/dlp/lib/google_api/dlp/v2/model/google_privacy_dlp_v2_create_discovery_config_request.ex b/clients/dlp/lib/google_api/dlp/v2/model/google_privacy_dlp_v2_create_discovery_config_request.ex new file mode 100644 index 0000000000..72e21b77ac --- /dev/null +++ b/clients/dlp/lib/google_api/dlp/v2/model/google_privacy_dlp_v2_create_discovery_config_request.ex @@ -0,0 +1,49 @@ +# Copyright 2019 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# NOTE: This file is auto generated by the elixir code generator program. +# Do not edit this file manually. + +defmodule GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2CreateDiscoveryConfigRequest do + @moduledoc """ + Request message for CreateDiscoveryConfig. + + ## Attributes + + * `configId` (*type:* `String.t`, *default:* `nil`) - The config ID can contain uppercase and lowercase letters, numbers, and hyphens; that is, it must match the regular expression: `[a-zA-Z\\d-_]+`. The maximum length is 100 characters. Can be empty to allow the system to generate one. + * `discoveryConfig` (*type:* `GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2DiscoveryConfig.t`, *default:* `nil`) - Required. The DiscoveryConfig to create. + """ + + use GoogleApi.Gax.ModelBase + + @type t :: %__MODULE__{ + :configId => String.t() | nil, + :discoveryConfig => GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2DiscoveryConfig.t() | nil + } + + field(:configId) + field(:discoveryConfig, as: GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2DiscoveryConfig) +end + +defimpl Poison.Decoder, for: GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2CreateDiscoveryConfigRequest do + def decode(value, options) do + GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2CreateDiscoveryConfigRequest.decode(value, options) + end +end + +defimpl Poison.Encoder, for: GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2CreateDiscoveryConfigRequest do + def encode(value, options) do + GoogleApi.Gax.ModelBase.encode(value, options) + end +end diff --git a/clients/dlp/lib/google_api/dlp/v2/model/google_privacy_dlp_v2_crypto_hash_config.ex b/clients/dlp/lib/google_api/dlp/v2/model/google_privacy_dlp_v2_crypto_hash_config.ex index 16258ec060..2581dcd389 100644 --- a/clients/dlp/lib/google_api/dlp/v2/model/google_privacy_dlp_v2_crypto_hash_config.ex +++ b/clients/dlp/lib/google_api/dlp/v2/model/google_privacy_dlp_v2_crypto_hash_config.ex @@ -17,7 +17,7 @@ defmodule GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2CryptoHashConfig do @moduledoc """ - Pseudonymization method that generates surrogates via cryptographic hashing. Uses SHA-256. The key size must be either 32 or 64 bytes. Outputs a base64 encoded representation of the hashed output (for example, L7k0BHmF1ha5U3NfGykjro4xWi1MPVQPjhMAZbSV9mM=). Currently, only string and integer values can be hashed. See https://cloud.google.com/dlp/docs/pseudonymization to learn more. + Pseudonymization method that generates surrogates via cryptographic hashing. Uses SHA-256. The key size must be either 32 or 64 bytes. Outputs a base64 encoded representation of the hashed output (for example, L7k0BHmF1ha5U3NfGykjro4xWi1MPVQPjhMAZbSV9mM=). Currently, only string and integer values can be hashed. See https://cloud.google.com/sensitive-data-protection/docs/pseudonymization to learn more. ## Attributes diff --git a/clients/dlp/lib/google_api/dlp/v2/model/google_privacy_dlp_v2_crypto_replace_ffx_fpe_config.ex b/clients/dlp/lib/google_api/dlp/v2/model/google_privacy_dlp_v2_crypto_replace_ffx_fpe_config.ex index cc59797945..8419126a76 100644 --- a/clients/dlp/lib/google_api/dlp/v2/model/google_privacy_dlp_v2_crypto_replace_ffx_fpe_config.ex +++ b/clients/dlp/lib/google_api/dlp/v2/model/google_privacy_dlp_v2_crypto_replace_ffx_fpe_config.ex @@ -17,7 +17,7 @@ defmodule GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2CryptoReplaceFfxFpeConfig do @moduledoc """ - Replaces an identifier with a surrogate using Format Preserving Encryption (FPE) with the FFX mode of operation; however when used in the `ReidentifyContent` API method, it serves the opposite function by reversing the surrogate back into the original identifier. The identifier must be encoded as ASCII. For a given crypto key and context, the same identifier will be replaced with the same surrogate. Identifiers must be at least two characters long. In the case that the identifier is the empty string, it will be skipped. See https://cloud.google.com/dlp/docs/pseudonymization to learn more. Note: We recommend using CryptoDeterministicConfig for all use cases which do not require preserving the input alphabet space and size, plus warrant referential integrity. + Replaces an identifier with a surrogate using Format Preserving Encryption (FPE) with the FFX mode of operation; however when used in the `ReidentifyContent` API method, it serves the opposite function by reversing the surrogate back into the original identifier. The identifier must be encoded as ASCII. For a given crypto key and context, the same identifier will be replaced with the same surrogate. Identifiers must be at least two characters long. In the case that the identifier is the empty string, it will be skipped. See https://cloud.google.com/sensitive-data-protection/docs/pseudonymization to learn more. Note: We recommend using CryptoDeterministicConfig for all use cases which do not require preserving the input alphabet space and size, plus warrant referential integrity. ## Attributes @@ -26,7 +26,7 @@ defmodule GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2CryptoReplaceFfxFpeConfig do * `cryptoKey` (*type:* `GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2CryptoKey.t`, *default:* `nil`) - Required. The key used by the encryption algorithm. * `customAlphabet` (*type:* `String.t`, *default:* `nil`) - This is supported by mapping these to the alphanumeric characters that the FFX mode natively supports. This happens before/after encryption/decryption. Each character listed must appear only once. Number of characters must be in the range [2, 95]. This must be encoded as ASCII. The order of characters does not matter. The full list of allowed characters is: 0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz ~`!@#$%^&*()_-+={[}]|\\:;"'<,>.?/ * `radix` (*type:* `integer()`, *default:* `nil`) - The native way to select the alphabet. Must be in the range [2, 95]. - * `surrogateInfoType` (*type:* `GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2InfoType.t`, *default:* `nil`) - The custom infoType to annotate the surrogate with. This annotation will be applied to the surrogate by prefixing it with the name of the custom infoType followed by the number of characters comprising the surrogate. The following scheme defines the format: info_type_name(surrogate_character_count):surrogate For example, if the name of custom infoType is 'MY_TOKEN_INFO_TYPE' and the surrogate is 'abc', the full replacement value will be: 'MY_TOKEN_INFO_TYPE(3):abc' This annotation identifies the surrogate when inspecting content using the custom infoType [`SurrogateType`](https://cloud.google.com/dlp/docs/reference/rest/v2/InspectConfig#surrogatetype). This facilitates reversal of the surrogate when it occurs in free text. In order for inspection to work properly, the name of this infoType must not occur naturally anywhere in your data; otherwise, inspection may find a surrogate that does not correspond to an actual identifier. Therefore, choose your custom infoType name carefully after considering what your data looks like. One way to select a name that has a high chance of yielding reliable detection is to include one or more unicode characters that are highly improbable to exist in your data. For example, assuming your data is entered from a regular ASCII keyboard, the symbol with the hex code point 29DD might be used like so: ⧝MY_TOKEN_TYPE + * `surrogateInfoType` (*type:* `GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2InfoType.t`, *default:* `nil`) - The custom infoType to annotate the surrogate with. This annotation will be applied to the surrogate by prefixing it with the name of the custom infoType followed by the number of characters comprising the surrogate. The following scheme defines the format: info_type_name(surrogate_character_count):surrogate For example, if the name of custom infoType is 'MY_TOKEN_INFO_TYPE' and the surrogate is 'abc', the full replacement value will be: 'MY_TOKEN_INFO_TYPE(3):abc' This annotation identifies the surrogate when inspecting content using the custom infoType [`SurrogateType`](https://cloud.google.com/sensitive-data-protection/docs/reference/rest/v2/InspectConfig#surrogatetype). This facilitates reversal of the surrogate when it occurs in free text. In order for inspection to work properly, the name of this infoType must not occur naturally anywhere in your data; otherwise, inspection may find a surrogate that does not correspond to an actual identifier. Therefore, choose your custom infoType name carefully after considering what your data looks like. One way to select a name that has a high chance of yielding reliable detection is to include one or more unicode characters that are highly improbable to exist in your data. For example, assuming your data is entered from a regular ASCII keyboard, the symbol with the hex code point 29DD might be used like so: ⧝MY_TOKEN_TYPE """ use GoogleApi.Gax.ModelBase diff --git a/clients/dlp/lib/google_api/dlp/v2/model/google_privacy_dlp_v2_custom_info_type.ex b/clients/dlp/lib/google_api/dlp/v2/model/google_privacy_dlp_v2_custom_info_type.ex index eaa82b3352..36b7271cf7 100644 --- a/clients/dlp/lib/google_api/dlp/v2/model/google_privacy_dlp_v2_custom_info_type.ex +++ b/clients/dlp/lib/google_api/dlp/v2/model/google_privacy_dlp_v2_custom_info_type.ex @@ -27,6 +27,7 @@ defmodule GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2CustomInfoType do * `infoType` (*type:* `GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2InfoType.t`, *default:* `nil`) - CustomInfoType can either be a new infoType, or an extension of built-in infoType, when the name matches one of existing infoTypes and that infoType is specified in `InspectContent.info_types` field. Specifying the latter adds findings to the one detected by the system. If built-in info type is not specified in `InspectContent.info_types` list then the name is treated as a custom info type. * `likelihood` (*type:* `String.t`, *default:* `nil`) - Likelihood to return for this CustomInfoType. This base value can be altered by a detection rule if the finding meets the criteria specified by the rule. Defaults to `VERY_LIKELY` if not specified. * `regex` (*type:* `GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2Regex.t`, *default:* `nil`) - Regular expression based CustomInfoType. + * `sensitivityScore` (*type:* `GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2SensitivityScore.t`, *default:* `nil`) - Sensitivity for this CustomInfoType. If this CustomInfoType extends an existing InfoType, the sensitivity here will take precedence over that of the original InfoType. If unset for a CustomInfoType, it will default to HIGH. This only applies to data profiling. * `storedType` (*type:* `GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2StoredType.t`, *default:* `nil`) - Load an existing `StoredInfoType` resource for use in `InspectDataSource`. Not currently supported in `InspectContent`. * `surrogateType` (*type:* `GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2SurrogateType.t`, *default:* `nil`) - Message for detecting output from deidentification transformations that support reversing. """ @@ -41,6 +42,8 @@ defmodule GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2CustomInfoType do :infoType => GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2InfoType.t() | nil, :likelihood => String.t() | nil, :regex => GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2Regex.t() | nil, + :sensitivityScore => + GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2SensitivityScore.t() | nil, :storedType => GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2StoredType.t() | nil, :surrogateType => GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2SurrogateType.t() | nil } @@ -51,6 +54,7 @@ defmodule GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2CustomInfoType do field(:infoType, as: GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2InfoType) field(:likelihood) field(:regex, as: GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2Regex) + field(:sensitivityScore, as: GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2SensitivityScore) field(:storedType, as: GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2StoredType) field(:surrogateType, as: GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2SurrogateType) end diff --git a/clients/dlp/lib/google_api/dlp/v2/model/google_privacy_dlp_v2_data_profile_big_query_row_schema.ex b/clients/dlp/lib/google_api/dlp/v2/model/google_privacy_dlp_v2_data_profile_big_query_row_schema.ex new file mode 100644 index 0000000000..be60cbf337 --- /dev/null +++ b/clients/dlp/lib/google_api/dlp/v2/model/google_privacy_dlp_v2_data_profile_big_query_row_schema.ex @@ -0,0 +1,49 @@ +# Copyright 2019 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# NOTE: This file is auto generated by the elixir code generator program. +# Do not edit this file manually. + +defmodule GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2DataProfileBigQueryRowSchema do + @moduledoc """ + The schema of data to be saved to the BigQuery table when the `DataProfileAction` is enabled. + + ## Attributes + + * `columnProfile` (*type:* `GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2ColumnDataProfile.t`, *default:* `nil`) - Column data profile column + * `tableProfile` (*type:* `GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2TableDataProfile.t`, *default:* `nil`) - Table data profile column + """ + + use GoogleApi.Gax.ModelBase + + @type t :: %__MODULE__{ + :columnProfile => GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2ColumnDataProfile.t() | nil, + :tableProfile => GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2TableDataProfile.t() | nil + } + + field(:columnProfile, as: GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2ColumnDataProfile) + field(:tableProfile, as: GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2TableDataProfile) +end + +defimpl Poison.Decoder, for: GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2DataProfileBigQueryRowSchema do + def decode(value, options) do + GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2DataProfileBigQueryRowSchema.decode(value, options) + end +end + +defimpl Poison.Encoder, for: GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2DataProfileBigQueryRowSchema do + def encode(value, options) do + GoogleApi.Gax.ModelBase.encode(value, options) + end +end diff --git a/clients/dlp/lib/google_api/dlp/v2/model/google_privacy_dlp_v2_data_profile_config_snapshot.ex b/clients/dlp/lib/google_api/dlp/v2/model/google_privacy_dlp_v2_data_profile_config_snapshot.ex index fb81d0c3ce..93fed96ac6 100644 --- a/clients/dlp/lib/google_api/dlp/v2/model/google_privacy_dlp_v2_data_profile_config_snapshot.ex +++ b/clients/dlp/lib/google_api/dlp/v2/model/google_privacy_dlp_v2_data_profile_config_snapshot.ex @@ -21,8 +21,11 @@ defmodule GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2DataProfileConfigSnapshot do ## Attributes - * `dataProfileJob` (*type:* `GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2DataProfileJobConfig.t`, *default:* `nil`) - A copy of the configuration used to generate this profile. + * `dataProfileJob` (*type:* `GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2DataProfileJobConfig.t`, *default:* `nil`) - A copy of the configuration used to generate this profile. This is deprecated, and the DiscoveryConfig field is preferred moving forward. DataProfileJobConfig will still be written here for Discovery in BigQuery for backwards compatibility, but will not be updated with new fields, while DiscoveryConfig will. + * `discoveryConfig` (*type:* `GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2DiscoveryConfig.t`, *default:* `nil`) - A copy of the configuration used to generate this profile. * `inspectConfig` (*type:* `GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2InspectConfig.t`, *default:* `nil`) - A copy of the inspection config used to generate this profile. This is a copy of the inspect_template specified in `DataProfileJobConfig`. + * `inspectTemplateModifiedTime` (*type:* `DateTime.t`, *default:* `nil`) - Timestamp when the template was modified + * `inspectTemplateName` (*type:* `String.t`, *default:* `nil`) - Name of the inspection template used to generate this profile """ use GoogleApi.Gax.ModelBase @@ -30,11 +33,17 @@ defmodule GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2DataProfileConfigSnapshot do @type t :: %__MODULE__{ :dataProfileJob => GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2DataProfileJobConfig.t() | nil, - :inspectConfig => GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2InspectConfig.t() | nil + :discoveryConfig => GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2DiscoveryConfig.t() | nil, + :inspectConfig => GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2InspectConfig.t() | nil, + :inspectTemplateModifiedTime => DateTime.t() | nil, + :inspectTemplateName => String.t() | nil } field(:dataProfileJob, as: GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2DataProfileJobConfig) + field(:discoveryConfig, as: GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2DiscoveryConfig) field(:inspectConfig, as: GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2InspectConfig) + field(:inspectTemplateModifiedTime, as: DateTime) + field(:inspectTemplateName) end defimpl Poison.Decoder, for: GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2DataProfileConfigSnapshot do diff --git a/clients/dlp/lib/google_api/dlp/v2/model/google_privacy_dlp_v2_data_profile_job_config.ex b/clients/dlp/lib/google_api/dlp/v2/model/google_privacy_dlp_v2_data_profile_job_config.ex index 182537c543..896a909d4f 100644 --- a/clients/dlp/lib/google_api/dlp/v2/model/google_privacy_dlp_v2_data_profile_job_config.ex +++ b/clients/dlp/lib/google_api/dlp/v2/model/google_privacy_dlp_v2_data_profile_job_config.ex @@ -17,12 +17,12 @@ defmodule GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2DataProfileJobConfig do @moduledoc """ - Configuration for setting up a job to scan resources for profile generation. Only one data profile configuration may exist per organization, folder, or project. The generated data profiles are retained according to the [data retention policy] (https://cloud.google.com/dlp/docs/data-profiles#retention). + Configuration for setting up a job to scan resources for profile generation. Only one data profile configuration may exist per organization, folder, or project. The generated data profiles are retained according to the [data retention policy] (https://cloud.google.com/sensitive-data-protection/docs/data-profiles#retention). ## Attributes * `dataProfileActions` (*type:* `list(GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2DataProfileAction.t)`, *default:* `nil`) - Actions to execute at the completion of the job. - * `inspectTemplates` (*type:* `list(String.t)`, *default:* `nil`) - Detection logic for profile generation. Not all template features are used by profiles. FindingLimits, include_quote and exclude_info_types have no impact on data profiling. Multiple templates may be provided if there is data in multiple regions. At most one template must be specified per-region (including "global"). Each region is scanned using the applicable template. If no region-specific template is specified, but a "global" template is specified, it will be copied to that region and used instead. If no global or region-specific template is provided for a region with data, that region's data will not be scanned. For more information, see https://cloud.google.com/dlp/docs/data-profiles#data_residency. + * `inspectTemplates` (*type:* `list(String.t)`, *default:* `nil`) - Detection logic for profile generation. Not all template features are used by profiles. FindingLimits, include_quote and exclude_info_types have no impact on data profiling. Multiple templates may be provided if there is data in multiple regions. At most one template must be specified per-region (including "global"). Each region is scanned using the applicable template. If no region-specific template is specified, but a "global" template is specified, it will be copied to that region and used instead. If no global or region-specific template is provided for a region with data, that region's data will not be scanned. For more information, see https://cloud.google.com/sensitive-data-protection/docs/data-profiles#data-residency. * `location` (*type:* `GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2DataProfileLocation.t`, *default:* `nil`) - The data to scan. * `projectId` (*type:* `String.t`, *default:* `nil`) - The project that will run the scan. The DLP service account that exists within this project must have access to all resources that are profiled, and the Cloud DLP API must be enabled. """ diff --git a/clients/dlp/lib/google_api/dlp/v2/model/google_privacy_dlp_v2_data_source_type.ex b/clients/dlp/lib/google_api/dlp/v2/model/google_privacy_dlp_v2_data_source_type.ex new file mode 100644 index 0000000000..70947a200d --- /dev/null +++ b/clients/dlp/lib/google_api/dlp/v2/model/google_privacy_dlp_v2_data_source_type.ex @@ -0,0 +1,46 @@ +# Copyright 2019 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# NOTE: This file is auto generated by the elixir code generator program. +# Do not edit this file manually. + +defmodule GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2DataSourceType do + @moduledoc """ + Message used to identify the type of resource being profiled. + + ## Attributes + + * `dataSource` (*type:* `String.t`, *default:* `nil`) - Output only. An identifying string to the type of resource being profiled. Current values: google/bigquery/table, google/project + """ + + use GoogleApi.Gax.ModelBase + + @type t :: %__MODULE__{ + :dataSource => String.t() | nil + } + + field(:dataSource) +end + +defimpl Poison.Decoder, for: GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2DataSourceType do + def decode(value, options) do + GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2DataSourceType.decode(value, options) + end +end + +defimpl Poison.Encoder, for: GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2DataSourceType do + def encode(value, options) do + GoogleApi.Gax.ModelBase.encode(value, options) + end +end diff --git a/clients/dlp/lib/google_api/dlp/v2/model/google_privacy_dlp_v2_date_shift_config.ex b/clients/dlp/lib/google_api/dlp/v2/model/google_privacy_dlp_v2_date_shift_config.ex index e5a7ec82c6..6e02ad3497 100644 --- a/clients/dlp/lib/google_api/dlp/v2/model/google_privacy_dlp_v2_date_shift_config.ex +++ b/clients/dlp/lib/google_api/dlp/v2/model/google_privacy_dlp_v2_date_shift_config.ex @@ -17,7 +17,7 @@ defmodule GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2DateShiftConfig do @moduledoc """ - Shifts dates by random number of days, with option to be consistent for the same context. See https://cloud.google.com/dlp/docs/concepts-date-shifting to learn more. + Shifts dates by random number of days, with option to be consistent for the same context. See https://cloud.google.com/sensitive-data-protection/docs/concepts-date-shifting to learn more. ## Attributes diff --git a/clients/dlp/lib/google_api/dlp/v2/model/google_privacy_dlp_v2_deidentify_data_source_details.ex b/clients/dlp/lib/google_api/dlp/v2/model/google_privacy_dlp_v2_deidentify_data_source_details.ex new file mode 100644 index 0000000000..dec4804734 --- /dev/null +++ b/clients/dlp/lib/google_api/dlp/v2/model/google_privacy_dlp_v2_deidentify_data_source_details.ex @@ -0,0 +1,52 @@ +# Copyright 2019 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# NOTE: This file is auto generated by the elixir code generator program. +# Do not edit this file manually. + +defmodule GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2DeidentifyDataSourceDetails do + @moduledoc """ + The results of a Deidentify action from an inspect job. + + ## Attributes + + * `deidentifyStats` (*type:* `GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2DeidentifyDataSourceStats.t`, *default:* `nil`) - Stats about the de-identification operation. + * `requestedOptions` (*type:* `GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2RequestedDeidentifyOptions.t`, *default:* `nil`) - De-identification config used for the request. + """ + + use GoogleApi.Gax.ModelBase + + @type t :: %__MODULE__{ + :deidentifyStats => + GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2DeidentifyDataSourceStats.t() | nil, + :requestedOptions => + GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2RequestedDeidentifyOptions.t() | nil + } + + field(:deidentifyStats, as: GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2DeidentifyDataSourceStats) + + field(:requestedOptions, as: GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2RequestedDeidentifyOptions) +end + +defimpl Poison.Decoder, for: GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2DeidentifyDataSourceDetails do + def decode(value, options) do + GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2DeidentifyDataSourceDetails.decode(value, options) + end +end + +defimpl Poison.Encoder, for: GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2DeidentifyDataSourceDetails do + def encode(value, options) do + GoogleApi.Gax.ModelBase.encode(value, options) + end +end diff --git a/clients/dlp/lib/google_api/dlp/v2/model/google_privacy_dlp_v2_deidentify_data_source_stats.ex b/clients/dlp/lib/google_api/dlp/v2/model/google_privacy_dlp_v2_deidentify_data_source_stats.ex new file mode 100644 index 0000000000..28d850c481 --- /dev/null +++ b/clients/dlp/lib/google_api/dlp/v2/model/google_privacy_dlp_v2_deidentify_data_source_stats.ex @@ -0,0 +1,52 @@ +# Copyright 2019 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# NOTE: This file is auto generated by the elixir code generator program. +# Do not edit this file manually. + +defmodule GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2DeidentifyDataSourceStats do + @moduledoc """ + Summary of what was modified during a transformation. + + ## Attributes + + * `transformationCount` (*type:* `String.t`, *default:* `nil`) - Number of successfully applied transformations. + * `transformationErrorCount` (*type:* `String.t`, *default:* `nil`) - Number of errors encountered while trying to apply transformations. + * `transformedBytes` (*type:* `String.t`, *default:* `nil`) - Total size in bytes that were transformed in some way. + """ + + use GoogleApi.Gax.ModelBase + + @type t :: %__MODULE__{ + :transformationCount => String.t() | nil, + :transformationErrorCount => String.t() | nil, + :transformedBytes => String.t() | nil + } + + field(:transformationCount) + field(:transformationErrorCount) + field(:transformedBytes) +end + +defimpl Poison.Decoder, for: GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2DeidentifyDataSourceStats do + def decode(value, options) do + GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2DeidentifyDataSourceStats.decode(value, options) + end +end + +defimpl Poison.Encoder, for: GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2DeidentifyDataSourceStats do + def encode(value, options) do + GoogleApi.Gax.ModelBase.encode(value, options) + end +end diff --git a/clients/dlp/lib/google_api/dlp/v2/model/google_privacy_dlp_v2_deidentify_template.ex b/clients/dlp/lib/google_api/dlp/v2/model/google_privacy_dlp_v2_deidentify_template.ex index 4484e63ef3..ba76e1ccb9 100644 --- a/clients/dlp/lib/google_api/dlp/v2/model/google_privacy_dlp_v2_deidentify_template.ex +++ b/clients/dlp/lib/google_api/dlp/v2/model/google_privacy_dlp_v2_deidentify_template.ex @@ -17,7 +17,7 @@ defmodule GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2DeidentifyTemplate do @moduledoc """ - DeidentifyTemplates contains instructions on how to de-identify content. See https://cloud.google.com/dlp/docs/concepts-templates to learn more. + DeidentifyTemplates contains instructions on how to de-identify content. See https://cloud.google.com/sensitive-data-protection/docs/concepts-templates to learn more. ## Attributes diff --git a/clients/dlp/lib/google_api/dlp/v2/model/google_privacy_dlp_v2_dictionary.ex b/clients/dlp/lib/google_api/dlp/v2/model/google_privacy_dlp_v2_dictionary.ex index ef13d24e69..6ea5c2cebb 100644 --- a/clients/dlp/lib/google_api/dlp/v2/model/google_privacy_dlp_v2_dictionary.ex +++ b/clients/dlp/lib/google_api/dlp/v2/model/google_privacy_dlp_v2_dictionary.ex @@ -17,7 +17,7 @@ defmodule GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2Dictionary do @moduledoc """ - Custom information type based on a dictionary of words or phrases. This can be used to match sensitive information specific to the data, such as a list of employee IDs or job titles. Dictionary words are case-insensitive and all characters other than letters and digits in the unicode [Basic Multilingual Plane](https://en.wikipedia.org/wiki/Plane_%28Unicode%29#Basic_Multilingual_Plane) will be replaced with whitespace when scanning for matches, so the dictionary phrase "Sam Johnson" will match all three phrases "sam johnson", "Sam, Johnson", and "Sam (Johnson)". Additionally, the characters surrounding any match must be of a different type than the adjacent characters within the word, so letters must be next to non-letters and digits next to non-digits. For example, the dictionary word "jen" will match the first three letters of the text "jen123" but will return no matches for "jennifer". Dictionary words containing a large number of characters that are not letters or digits may result in unexpected findings because such characters are treated as whitespace. The [limits](https://cloud.google.com/dlp/limits) page contains details about the size limits of dictionaries. For dictionaries that do not fit within these constraints, consider using `LargeCustomDictionaryConfig` in the `StoredInfoType` API. + Custom information type based on a dictionary of words or phrases. This can be used to match sensitive information specific to the data, such as a list of employee IDs or job titles. Dictionary words are case-insensitive and all characters other than letters and digits in the unicode [Basic Multilingual Plane](https://en.wikipedia.org/wiki/Plane_%28Unicode%29#Basic_Multilingual_Plane) will be replaced with whitespace when scanning for matches, so the dictionary phrase "Sam Johnson" will match all three phrases "sam johnson", "Sam, Johnson", and "Sam (Johnson)". Additionally, the characters surrounding any match must be of a different type than the adjacent characters within the word, so letters must be next to non-letters and digits next to non-digits. For example, the dictionary word "jen" will match the first three letters of the text "jen123" but will return no matches for "jennifer". Dictionary words containing a large number of characters that are not letters or digits may result in unexpected findings because such characters are treated as whitespace. The [limits](https://cloud.google.com/sensitive-data-protection/limits) page contains details about the size limits of dictionaries. For dictionaries that do not fit within these constraints, consider using `LargeCustomDictionaryConfig` in the `StoredInfoType` API. ## Attributes diff --git a/clients/dlp/lib/google_api/dlp/v2/model/google_privacy_dlp_v2_disabled.ex b/clients/dlp/lib/google_api/dlp/v2/model/google_privacy_dlp_v2_disabled.ex new file mode 100644 index 0000000000..ff0fac5781 --- /dev/null +++ b/clients/dlp/lib/google_api/dlp/v2/model/google_privacy_dlp_v2_disabled.ex @@ -0,0 +1,41 @@ +# Copyright 2019 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# NOTE: This file is auto generated by the elixir code generator program. +# Do not edit this file manually. + +defmodule GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2Disabled do + @moduledoc """ + Do not profile the tables. + + ## Attributes + + """ + + use GoogleApi.Gax.ModelBase + + @type t :: %__MODULE__{} +end + +defimpl Poison.Decoder, for: GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2Disabled do + def decode(value, options) do + GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2Disabled.decode(value, options) + end +end + +defimpl Poison.Encoder, for: GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2Disabled do + def encode(value, options) do + GoogleApi.Gax.ModelBase.encode(value, options) + end +end diff --git a/clients/dlp/lib/google_api/dlp/v2/model/google_privacy_dlp_v2_discovery_big_query_conditions.ex b/clients/dlp/lib/google_api/dlp/v2/model/google_privacy_dlp_v2_discovery_big_query_conditions.ex new file mode 100644 index 0000000000..599d92333a --- /dev/null +++ b/clients/dlp/lib/google_api/dlp/v2/model/google_privacy_dlp_v2_discovery_big_query_conditions.ex @@ -0,0 +1,55 @@ +# Copyright 2019 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# NOTE: This file is auto generated by the elixir code generator program. +# Do not edit this file manually. + +defmodule GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2DiscoveryBigQueryConditions do + @moduledoc """ + Requirements that must be true before a table is scanned in discovery for the first time. There is an AND relationship between the top-level attributes. Additionally, minimum conditions with an OR relationship that must be met before Cloud DLP scans a table can be set (like a minimum row count or a minimum table age). + + ## Attributes + + * `createdAfter` (*type:* `DateTime.t`, *default:* `nil`) - BigQuery table must have been created after this date. Used to avoid backfilling. + * `orConditions` (*type:* `GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2OrConditions.t`, *default:* `nil`) - At least one of the conditions must be true for a table to be scanned. + * `typeCollection` (*type:* `String.t`, *default:* `nil`) - Restrict discovery to categories of table types. + * `types` (*type:* `GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2BigQueryTableTypes.t`, *default:* `nil`) - Restrict discovery to specific table types. + """ + + use GoogleApi.Gax.ModelBase + + @type t :: %__MODULE__{ + :createdAfter => DateTime.t() | nil, + :orConditions => GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2OrConditions.t() | nil, + :typeCollection => String.t() | nil, + :types => GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2BigQueryTableTypes.t() | nil + } + + field(:createdAfter, as: DateTime) + field(:orConditions, as: GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2OrConditions) + field(:typeCollection) + field(:types, as: GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2BigQueryTableTypes) +end + +defimpl Poison.Decoder, for: GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2DiscoveryBigQueryConditions do + def decode(value, options) do + GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2DiscoveryBigQueryConditions.decode(value, options) + end +end + +defimpl Poison.Encoder, for: GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2DiscoveryBigQueryConditions do + def encode(value, options) do + GoogleApi.Gax.ModelBase.encode(value, options) + end +end diff --git a/clients/dlp/lib/google_api/dlp/v2/model/google_privacy_dlp_v2_discovery_big_query_filter.ex b/clients/dlp/lib/google_api/dlp/v2/model/google_privacy_dlp_v2_discovery_big_query_filter.ex new file mode 100644 index 0000000000..ef43e1708f --- /dev/null +++ b/clients/dlp/lib/google_api/dlp/v2/model/google_privacy_dlp_v2_discovery_big_query_filter.ex @@ -0,0 +1,50 @@ +# Copyright 2019 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# NOTE: This file is auto generated by the elixir code generator program. +# Do not edit this file manually. + +defmodule GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2DiscoveryBigQueryFilter do + @moduledoc """ + Determines what tables will have profiles generated within an organization or project. Includes the ability to filter by regular expression patterns on project ID, dataset ID, and table ID. + + ## Attributes + + * `otherTables` (*type:* `GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2AllOtherBigQueryTables.t`, *default:* `nil`) - Catch-all. This should always be the last filter in the list because anything above it will apply first. Should only appear once in a configuration. If none is specified, a default one will be added automatically. + * `tables` (*type:* `GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2BigQueryTableCollection.t`, *default:* `nil`) - A specific set of tables for this filter to apply to. A table collection must be specified in only one filter per config. If a table id or dataset is empty, Cloud DLP assumes all tables in that collection must be profiled. Must specify a project ID. + """ + + use GoogleApi.Gax.ModelBase + + @type t :: %__MODULE__{ + :otherTables => + GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2AllOtherBigQueryTables.t() | nil, + :tables => GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2BigQueryTableCollection.t() | nil + } + + field(:otherTables, as: GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2AllOtherBigQueryTables) + field(:tables, as: GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2BigQueryTableCollection) +end + +defimpl Poison.Decoder, for: GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2DiscoveryBigQueryFilter do + def decode(value, options) do + GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2DiscoveryBigQueryFilter.decode(value, options) + end +end + +defimpl Poison.Encoder, for: GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2DiscoveryBigQueryFilter do + def encode(value, options) do + GoogleApi.Gax.ModelBase.encode(value, options) + end +end diff --git a/clients/dlp/lib/google_api/dlp/v2/model/google_privacy_dlp_v2_discovery_config.ex b/clients/dlp/lib/google_api/dlp/v2/model/google_privacy_dlp_v2_discovery_config.ex new file mode 100644 index 0000000000..ac745334c8 --- /dev/null +++ b/clients/dlp/lib/google_api/dlp/v2/model/google_privacy_dlp_v2_discovery_config.ex @@ -0,0 +1,76 @@ +# Copyright 2019 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# NOTE: This file is auto generated by the elixir code generator program. +# Do not edit this file manually. + +defmodule GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2DiscoveryConfig do + @moduledoc """ + Configuration for discovery to scan resources for profile generation. Only one discovery configuration may exist per organization, folder, or project. The generated data profiles are retained according to the [data retention policy] (https://cloud.google.com/sensitive-data-protection/docs/data-profiles#retention). + + ## Attributes + + * `actions` (*type:* `list(GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2DataProfileAction.t)`, *default:* `nil`) - Actions to execute at the completion of scanning. + * `createTime` (*type:* `DateTime.t`, *default:* `nil`) - Output only. The creation timestamp of a DiscoveryConfig. + * `displayName` (*type:* `String.t`, *default:* `nil`) - Display name (max 100 chars) + * `errors` (*type:* `list(GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2Error.t)`, *default:* `nil`) - Output only. A stream of errors encountered when the config was activated. Repeated errors may result in the config automatically being paused. Output only field. Will return the last 100 errors. Whenever the config is modified this list will be cleared. + * `inspectTemplates` (*type:* `list(String.t)`, *default:* `nil`) - Detection logic for profile generation. Not all template features are used by Discovery. FindingLimits, include_quote and exclude_info_types have no impact on Discovery. Multiple templates may be provided if there is data in multiple regions. At most one template must be specified per-region (including "global"). Each region is scanned using the applicable template. If no region-specific template is specified, but a "global" template is specified, it will be copied to that region and used instead. If no global or region-specific template is provided for a region with data, that region's data will not be scanned. For more information, see https://cloud.google.com/sensitive-data-protection/docs/data-profiles#data-residency. + * `lastRunTime` (*type:* `DateTime.t`, *default:* `nil`) - Output only. The timestamp of the last time this config was executed. + * `name` (*type:* `String.t`, *default:* `nil`) - Unique resource name for the DiscoveryConfig, assigned by the service when the DiscoveryConfig is created, for example `projects/dlp-test-project/locations/global/discoveryConfigs/53234423`. + * `orgConfig` (*type:* `GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2OrgConfig.t`, *default:* `nil`) - Only set when the parent is an org. + * `status` (*type:* `String.t`, *default:* `nil`) - Required. A status for this configuration. + * `targets` (*type:* `list(GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2DiscoveryTarget.t)`, *default:* `nil`) - Target to match against for determining what to scan and how frequently. + * `updateTime` (*type:* `DateTime.t`, *default:* `nil`) - Output only. The last update timestamp of a DiscoveryConfig. + """ + + use GoogleApi.Gax.ModelBase + + @type t :: %__MODULE__{ + :actions => list(GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2DataProfileAction.t()) | nil, + :createTime => DateTime.t() | nil, + :displayName => String.t() | nil, + :errors => list(GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2Error.t()) | nil, + :inspectTemplates => list(String.t()) | nil, + :lastRunTime => DateTime.t() | nil, + :name => String.t() | nil, + :orgConfig => GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2OrgConfig.t() | nil, + :status => String.t() | nil, + :targets => list(GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2DiscoveryTarget.t()) | nil, + :updateTime => DateTime.t() | nil + } + + field(:actions, as: GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2DataProfileAction, type: :list) + field(:createTime, as: DateTime) + field(:displayName) + field(:errors, as: GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2Error, type: :list) + field(:inspectTemplates, type: :list) + field(:lastRunTime, as: DateTime) + field(:name) + field(:orgConfig, as: GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2OrgConfig) + field(:status) + field(:targets, as: GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2DiscoveryTarget, type: :list) + field(:updateTime, as: DateTime) +end + +defimpl Poison.Decoder, for: GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2DiscoveryConfig do + def decode(value, options) do + GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2DiscoveryConfig.decode(value, options) + end +end + +defimpl Poison.Encoder, for: GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2DiscoveryConfig do + def encode(value, options) do + GoogleApi.Gax.ModelBase.encode(value, options) + end +end diff --git a/clients/dlp/lib/google_api/dlp/v2/model/google_privacy_dlp_v2_discovery_generation_cadence.ex b/clients/dlp/lib/google_api/dlp/v2/model/google_privacy_dlp_v2_discovery_generation_cadence.ex new file mode 100644 index 0000000000..345b3cdcee --- /dev/null +++ b/clients/dlp/lib/google_api/dlp/v2/model/google_privacy_dlp_v2_discovery_generation_cadence.ex @@ -0,0 +1,56 @@ +# Copyright 2019 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# NOTE: This file is auto generated by the elixir code generator program. +# Do not edit this file manually. + +defmodule GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2DiscoveryGenerationCadence do + @moduledoc """ + What must take place for a profile to be updated and how frequently it should occur. New tables are scanned as quickly as possible depending on system capacity. + + ## Attributes + + * `schemaModifiedCadence` (*type:* `GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2DiscoverySchemaModifiedCadence.t`, *default:* `nil`) - Governs when to update data profiles when a schema is modified. + * `tableModifiedCadence` (*type:* `GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2DiscoveryTableModifiedCadence.t`, *default:* `nil`) - Governs when to update data profiles when a table is modified. + """ + + use GoogleApi.Gax.ModelBase + + @type t :: %__MODULE__{ + :schemaModifiedCadence => + GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2DiscoverySchemaModifiedCadence.t() | nil, + :tableModifiedCadence => + GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2DiscoveryTableModifiedCadence.t() | nil + } + + field(:schemaModifiedCadence, + as: GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2DiscoverySchemaModifiedCadence + ) + + field(:tableModifiedCadence, + as: GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2DiscoveryTableModifiedCadence + ) +end + +defimpl Poison.Decoder, for: GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2DiscoveryGenerationCadence do + def decode(value, options) do + GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2DiscoveryGenerationCadence.decode(value, options) + end +end + +defimpl Poison.Encoder, for: GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2DiscoveryGenerationCadence do + def encode(value, options) do + GoogleApi.Gax.ModelBase.encode(value, options) + end +end diff --git a/clients/dlp/lib/google_api/dlp/v2/model/google_privacy_dlp_v2_discovery_schema_modified_cadence.ex b/clients/dlp/lib/google_api/dlp/v2/model/google_privacy_dlp_v2_discovery_schema_modified_cadence.ex new file mode 100644 index 0000000000..e5dd6ace1b --- /dev/null +++ b/clients/dlp/lib/google_api/dlp/v2/model/google_privacy_dlp_v2_discovery_schema_modified_cadence.ex @@ -0,0 +1,51 @@ +# Copyright 2019 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# NOTE: This file is auto generated by the elixir code generator program. +# Do not edit this file manually. + +defmodule GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2DiscoverySchemaModifiedCadence do + @moduledoc """ + The cadence at which to update data profiles when a schema is modified. + + ## Attributes + + * `frequency` (*type:* `String.t`, *default:* `nil`) - How frequently profiles may be updated when schemas are modified. Defaults to monthly. + * `types` (*type:* `list(String.t)`, *default:* `nil`) - The type of events to consider when deciding if the table's schema has been modified and should have the profile updated. Defaults to NEW_COLUMNS. + """ + + use GoogleApi.Gax.ModelBase + + @type t :: %__MODULE__{ + :frequency => String.t() | nil, + :types => list(String.t()) | nil + } + + field(:frequency) + field(:types, type: :list) +end + +defimpl Poison.Decoder, + for: GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2DiscoverySchemaModifiedCadence do + def decode(value, options) do + GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2DiscoverySchemaModifiedCadence.decode(value, options) + end +end + +defimpl Poison.Encoder, + for: GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2DiscoverySchemaModifiedCadence do + def encode(value, options) do + GoogleApi.Gax.ModelBase.encode(value, options) + end +end diff --git a/clients/dlp/lib/google_api/dlp/v2/model/google_privacy_dlp_v2_discovery_starting_location.ex b/clients/dlp/lib/google_api/dlp/v2/model/google_privacy_dlp_v2_discovery_starting_location.ex new file mode 100644 index 0000000000..b0842b507c --- /dev/null +++ b/clients/dlp/lib/google_api/dlp/v2/model/google_privacy_dlp_v2_discovery_starting_location.ex @@ -0,0 +1,49 @@ +# Copyright 2019 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# NOTE: This file is auto generated by the elixir code generator program. +# Do not edit this file manually. + +defmodule GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2DiscoveryStartingLocation do + @moduledoc """ + The location to begin a discovery scan. Denotes an organization ID or folder ID within an organization. + + ## Attributes + + * `folderId` (*type:* `String.t`, *default:* `nil`) - The ID of the Folder within an organization to scan. + * `organizationId` (*type:* `String.t`, *default:* `nil`) - The ID of an organization to scan. + """ + + use GoogleApi.Gax.ModelBase + + @type t :: %__MODULE__{ + :folderId => String.t() | nil, + :organizationId => String.t() | nil + } + + field(:folderId) + field(:organizationId) +end + +defimpl Poison.Decoder, for: GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2DiscoveryStartingLocation do + def decode(value, options) do + GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2DiscoveryStartingLocation.decode(value, options) + end +end + +defimpl Poison.Encoder, for: GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2DiscoveryStartingLocation do + def encode(value, options) do + GoogleApi.Gax.ModelBase.encode(value, options) + end +end diff --git a/clients/dlp/lib/google_api/dlp/v2/model/google_privacy_dlp_v2_discovery_table_modified_cadence.ex b/clients/dlp/lib/google_api/dlp/v2/model/google_privacy_dlp_v2_discovery_table_modified_cadence.ex new file mode 100644 index 0000000000..e46020e50a --- /dev/null +++ b/clients/dlp/lib/google_api/dlp/v2/model/google_privacy_dlp_v2_discovery_table_modified_cadence.ex @@ -0,0 +1,51 @@ +# Copyright 2019 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# NOTE: This file is auto generated by the elixir code generator program. +# Do not edit this file manually. + +defmodule GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2DiscoveryTableModifiedCadence do + @moduledoc """ + The cadence at which to update data profiles when a table is modified. + + ## Attributes + + * `frequency` (*type:* `String.t`, *default:* `nil`) - How frequently data profiles can be updated when tables are modified. Defaults to never. + * `types` (*type:* `list(String.t)`, *default:* `nil`) - The type of events to consider when deciding if the table has been modified and should have the profile updated. Defaults to MODIFIED_TIMESTAMP. + """ + + use GoogleApi.Gax.ModelBase + + @type t :: %__MODULE__{ + :frequency => String.t() | nil, + :types => list(String.t()) | nil + } + + field(:frequency) + field(:types, type: :list) +end + +defimpl Poison.Decoder, + for: GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2DiscoveryTableModifiedCadence do + def decode(value, options) do + GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2DiscoveryTableModifiedCadence.decode(value, options) + end +end + +defimpl Poison.Encoder, + for: GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2DiscoveryTableModifiedCadence do + def encode(value, options) do + GoogleApi.Gax.ModelBase.encode(value, options) + end +end diff --git a/clients/dlp/lib/google_api/dlp/v2/model/google_privacy_dlp_v2_discovery_target.ex b/clients/dlp/lib/google_api/dlp/v2/model/google_privacy_dlp_v2_discovery_target.ex new file mode 100644 index 0000000000..bd9be5ed29 --- /dev/null +++ b/clients/dlp/lib/google_api/dlp/v2/model/google_privacy_dlp_v2_discovery_target.ex @@ -0,0 +1,47 @@ +# Copyright 2019 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# NOTE: This file is auto generated by the elixir code generator program. +# Do not edit this file manually. + +defmodule GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2DiscoveryTarget do + @moduledoc """ + Target used to match against for Discovery. + + ## Attributes + + * `bigQueryTarget` (*type:* `GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2BigQueryDiscoveryTarget.t`, *default:* `nil`) - BigQuery target for Discovery. The first target to match a table will be the one applied. + """ + + use GoogleApi.Gax.ModelBase + + @type t :: %__MODULE__{ + :bigQueryTarget => + GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2BigQueryDiscoveryTarget.t() | nil + } + + field(:bigQueryTarget, as: GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2BigQueryDiscoveryTarget) +end + +defimpl Poison.Decoder, for: GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2DiscoveryTarget do + def decode(value, options) do + GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2DiscoveryTarget.decode(value, options) + end +end + +defimpl Poison.Encoder, for: GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2DiscoveryTarget do + def encode(value, options) do + GoogleApi.Gax.ModelBase.encode(value, options) + end +end diff --git a/clients/dlp/lib/google_api/dlp/v2/model/google_privacy_dlp_v2_dlp_job.ex b/clients/dlp/lib/google_api/dlp/v2/model/google_privacy_dlp_v2_dlp_job.ex index eb3a858d13..0f27b24362 100644 --- a/clients/dlp/lib/google_api/dlp/v2/model/google_privacy_dlp_v2_dlp_job.ex +++ b/clients/dlp/lib/google_api/dlp/v2/model/google_privacy_dlp_v2_dlp_job.ex @@ -21,11 +21,13 @@ defmodule GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2DlpJob do ## Attributes + * `actionDetails` (*type:* `list(GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2ActionDetails.t)`, *default:* `nil`) - Events that should occur after the job has completed. * `createTime` (*type:* `DateTime.t`, *default:* `nil`) - Time when the job was created. * `endTime` (*type:* `DateTime.t`, *default:* `nil`) - Time when the job finished. * `errors` (*type:* `list(GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2Error.t)`, *default:* `nil`) - A stream of errors encountered running the job. * `inspectDetails` (*type:* `GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2InspectDataSourceDetails.t`, *default:* `nil`) - Results from inspecting a data source. * `jobTriggerName` (*type:* `String.t`, *default:* `nil`) - If created by a job trigger, the resource name of the trigger that instantiated the job. + * `lastModified` (*type:* `DateTime.t`, *default:* `nil`) - Time when the job was last modified by the system. * `name` (*type:* `String.t`, *default:* `nil`) - The server-assigned name. * `riskDetails` (*type:* `GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2AnalyzeDataSourceRiskDetails.t`, *default:* `nil`) - Results from analyzing risk of a data source. * `startTime` (*type:* `DateTime.t`, *default:* `nil`) - Time when the job started. @@ -36,12 +38,15 @@ defmodule GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2DlpJob do use GoogleApi.Gax.ModelBase @type t :: %__MODULE__{ + :actionDetails => + list(GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2ActionDetails.t()) | nil, :createTime => DateTime.t() | nil, :endTime => DateTime.t() | nil, :errors => list(GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2Error.t()) | nil, :inspectDetails => GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2InspectDataSourceDetails.t() | nil, :jobTriggerName => String.t() | nil, + :lastModified => DateTime.t() | nil, :name => String.t() | nil, :riskDetails => GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2AnalyzeDataSourceRiskDetails.t() | nil, @@ -50,11 +55,13 @@ defmodule GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2DlpJob do :type => String.t() | nil } + field(:actionDetails, as: GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2ActionDetails, type: :list) field(:createTime, as: DateTime) field(:endTime, as: DateTime) field(:errors, as: GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2Error, type: :list) field(:inspectDetails, as: GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2InspectDataSourceDetails) field(:jobTriggerName) + field(:lastModified, as: DateTime) field(:name) field(:riskDetails, as: GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2AnalyzeDataSourceRiskDetails) field(:startTime, as: DateTime) diff --git a/clients/dlp/lib/google_api/dlp/v2/model/google_privacy_dlp_v2_error.ex b/clients/dlp/lib/google_api/dlp/v2/model/google_privacy_dlp_v2_error.ex index f64bb6f5a4..0c2390f127 100644 --- a/clients/dlp/lib/google_api/dlp/v2/model/google_privacy_dlp_v2_error.ex +++ b/clients/dlp/lib/google_api/dlp/v2/model/google_privacy_dlp_v2_error.ex @@ -22,7 +22,7 @@ defmodule GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2Error do ## Attributes * `details` (*type:* `GoogleApi.DLP.V2.Model.GoogleRpcStatus.t`, *default:* `nil`) - Detailed error codes and messages. - * `timestamps` (*type:* `list(DateTime.t)`, *default:* `nil`) - The times the error occurred. + * `timestamps` (*type:* `list(DateTime.t)`, *default:* `nil`) - The times the error occurred. List includes the oldest timestamp and the last 9 timestamps. """ use GoogleApi.Gax.ModelBase diff --git a/clients/dlp/lib/google_api/dlp/v2/model/google_privacy_dlp_v2_finding_limits.ex b/clients/dlp/lib/google_api/dlp/v2/model/google_privacy_dlp_v2_finding_limits.ex index 4c4f11665c..e14e9450fa 100644 --- a/clients/dlp/lib/google_api/dlp/v2/model/google_privacy_dlp_v2_finding_limits.ex +++ b/clients/dlp/lib/google_api/dlp/v2/model/google_privacy_dlp_v2_finding_limits.ex @@ -22,8 +22,8 @@ defmodule GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2FindingLimits do ## Attributes * `maxFindingsPerInfoType` (*type:* `list(GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2InfoTypeLimit.t)`, *default:* `nil`) - Configuration of findings limit given for specified infoTypes. - * `maxFindingsPerItem` (*type:* `integer()`, *default:* `nil`) - Max number of findings that will be returned for each item scanned. When set within `InspectJobConfig`, the maximum returned is 2000 regardless if this is set higher. When set within `InspectContentRequest`, this field is ignored. - * `maxFindingsPerRequest` (*type:* `integer()`, *default:* `nil`) - Max number of findings that will be returned per request/job. When set within `InspectContentRequest`, the maximum returned is 2000 regardless if this is set higher. + * `maxFindingsPerItem` (*type:* `integer()`, *default:* `nil`) - Max number of findings that are returned for each item scanned. When set within an InspectContentRequest, this field is ignored. This value isn't a hard limit. If the number of findings for an item reaches this limit, the inspection of that item ends gradually, not abruptly. Therefore, the actual number of findings that Cloud DLP returns for the item can be multiple times higher than this value. + * `maxFindingsPerRequest` (*type:* `integer()`, *default:* `nil`) - Max number of findings that are returned per request or job. If you set this field in an InspectContentRequest, the resulting maximum value is the value that you set or 3,000, whichever is lower. This value isn't a hard limit. If an inspection reaches this limit, the inspection ends gradually, not abruptly. Therefore, the actual number of findings that Cloud DLP returns can be multiple times higher than this value. """ use GoogleApi.Gax.ModelBase diff --git a/clients/dlp/lib/google_api/dlp/v2/model/google_privacy_dlp_v2_fixed_size_bucketing_config.ex b/clients/dlp/lib/google_api/dlp/v2/model/google_privacy_dlp_v2_fixed_size_bucketing_config.ex index f4db41635b..81a98a4f9d 100644 --- a/clients/dlp/lib/google_api/dlp/v2/model/google_privacy_dlp_v2_fixed_size_bucketing_config.ex +++ b/clients/dlp/lib/google_api/dlp/v2/model/google_privacy_dlp_v2_fixed_size_bucketing_config.ex @@ -17,7 +17,7 @@ defmodule GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2FixedSizeBucketingConfig do @moduledoc """ - Buckets values based on fixed size ranges. The Bucketing transformation can provide all of this functionality, but requires more configuration. This message is provided as a convenience to the user for simple bucketing strategies. The transformed value will be a hyphenated string of {lower_bound}-{upper_bound}. For example, if lower_bound = 10 and upper_bound = 20, all values that are within this bucket will be replaced with "10-20". This can be used on data of type: double, long. If the bound Value type differs from the type of data being transformed, we will first attempt converting the type of the data to be transformed to match the type of the bound before comparing. See https://cloud.google.com/dlp/docs/concepts-bucketing to learn more. + Buckets values based on fixed size ranges. The Bucketing transformation can provide all of this functionality, but requires more configuration. This message is provided as a convenience to the user for simple bucketing strategies. The transformed value will be a hyphenated string of {lower_bound}-{upper_bound}. For example, if lower_bound = 10 and upper_bound = 20, all values that are within this bucket will be replaced with "10-20". This can be used on data of type: double, long. If the bound Value type differs from the type of data being transformed, we will first attempt converting the type of the data to be transformed to match the type of the bound before comparing. See https://cloud.google.com/sensitive-data-protection/docs/concepts-bucketing to learn more. ## Attributes diff --git a/clients/dlp/lib/google_api/dlp/v2/model/google_privacy_dlp_v2_hotword_rule.ex b/clients/dlp/lib/google_api/dlp/v2/model/google_privacy_dlp_v2_hotword_rule.ex index a3333b9561..51e115420e 100644 --- a/clients/dlp/lib/google_api/dlp/v2/model/google_privacy_dlp_v2_hotword_rule.ex +++ b/clients/dlp/lib/google_api/dlp/v2/model/google_privacy_dlp_v2_hotword_rule.ex @@ -23,7 +23,7 @@ defmodule GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2HotwordRule do * `hotwordRegex` (*type:* `GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2Regex.t`, *default:* `nil`) - Regular expression pattern defining what qualifies as a hotword. * `likelihoodAdjustment` (*type:* `GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2LikelihoodAdjustment.t`, *default:* `nil`) - Likelihood adjustment to apply to all matching findings. - * `proximity` (*type:* `GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2Proximity.t`, *default:* `nil`) - Range of characters within which the entire hotword must reside. The total length of the window cannot exceed 1000 characters. The finding itself will be included in the window, so that hotwords can be used to match substrings of the finding itself. Suppose you want Cloud DLP to promote the likelihood of the phone number regex "\\(\\d{3}\\) \\d{3}-\\d{4}" if the area code is known to be the area code of a company's office. In this case, use the hotword regex "\\(xxx\\)", where "xxx" is the area code in question. For tabular data, if you want to modify the likelihood of an entire column of findngs, see [Hotword example: Set the match likelihood of a table column] (https://cloud.google.com/dlp/docs/creating-custom-infotypes-likelihood#match-column-values). + * `proximity` (*type:* `GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2Proximity.t`, *default:* `nil`) - Range of characters within which the entire hotword must reside. The total length of the window cannot exceed 1000 characters. The finding itself will be included in the window, so that hotwords can be used to match substrings of the finding itself. Suppose you want Cloud DLP to promote the likelihood of the phone number regex "\\(\\d{3}\\) \\d{3}-\\d{4}" if the area code is known to be the area code of a company's office. In this case, use the hotword regex "\\(xxx\\)", where "xxx" is the area code in question. For tabular data, if you want to modify the likelihood of an entire column of findngs, see [Hotword example: Set the match likelihood of a table column] (https://cloud.google.com/sensitive-data-protection/docs/creating-custom-infotypes-likelihood#match-column-values). """ use GoogleApi.Gax.ModelBase diff --git a/clients/dlp/lib/google_api/dlp/v2/model/google_privacy_dlp_v2_image_transformations.ex b/clients/dlp/lib/google_api/dlp/v2/model/google_privacy_dlp_v2_image_transformations.ex index 6a47b9272d..f6df5f8e3b 100644 --- a/clients/dlp/lib/google_api/dlp/v2/model/google_privacy_dlp_v2_image_transformations.ex +++ b/clients/dlp/lib/google_api/dlp/v2/model/google_privacy_dlp_v2_image_transformations.ex @@ -21,7 +21,7 @@ defmodule GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2ImageTransformations do ## Attributes - * `transforms` (*type:* `list(GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2ImageTransformation.t)`, *default:* `nil`) - + * `transforms` (*type:* `list(GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2ImageTransformation.t)`, *default:* `nil`) - List of transforms to make. """ use GoogleApi.Gax.ModelBase diff --git a/clients/dlp/lib/google_api/dlp/v2/model/google_privacy_dlp_v2_info_type.ex b/clients/dlp/lib/google_api/dlp/v2/model/google_privacy_dlp_v2_info_type.ex index ea35693b20..06a9da6563 100644 --- a/clients/dlp/lib/google_api/dlp/v2/model/google_privacy_dlp_v2_info_type.ex +++ b/clients/dlp/lib/google_api/dlp/v2/model/google_privacy_dlp_v2_info_type.ex @@ -21,7 +21,8 @@ defmodule GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2InfoType do ## Attributes - * `name` (*type:* `String.t`, *default:* `nil`) - Name of the information type. Either a name of your choosing when creating a CustomInfoType, or one of the names listed at https://cloud.google.com/dlp/docs/infotypes-reference when specifying a built-in type. When sending Cloud DLP results to Data Catalog, infoType names should conform to the pattern `[A-Za-z0-9$_-]{1,64}`. + * `name` (*type:* `String.t`, *default:* `nil`) - Name of the information type. Either a name of your choosing when creating a CustomInfoType, or one of the names listed at https://cloud.google.com/sensitive-data-protection/docs/infotypes-reference when specifying a built-in type. When sending Cloud DLP results to Data Catalog, infoType names should conform to the pattern `[A-Za-z0-9$_-]{1,64}`. + * `sensitivityScore` (*type:* `GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2SensitivityScore.t`, *default:* `nil`) - Optional custom sensitivity for this InfoType. This only applies to data profiling. * `version` (*type:* `String.t`, *default:* `nil`) - Optional version name for this InfoType. """ @@ -29,10 +30,13 @@ defmodule GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2InfoType do @type t :: %__MODULE__{ :name => String.t() | nil, + :sensitivityScore => + GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2SensitivityScore.t() | nil, :version => String.t() | nil } field(:name) + field(:sensitivityScore, as: GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2SensitivityScore) field(:version) end diff --git a/clients/dlp/lib/google_api/dlp/v2/model/google_privacy_dlp_v2_info_type_likelihood.ex b/clients/dlp/lib/google_api/dlp/v2/model/google_privacy_dlp_v2_info_type_likelihood.ex new file mode 100644 index 0000000000..2c43d14814 --- /dev/null +++ b/clients/dlp/lib/google_api/dlp/v2/model/google_privacy_dlp_v2_info_type_likelihood.ex @@ -0,0 +1,49 @@ +# Copyright 2019 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# NOTE: This file is auto generated by the elixir code generator program. +# Do not edit this file manually. + +defmodule GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2InfoTypeLikelihood do + @moduledoc """ + Configuration for setting a minimum likelihood per infotype. Used to customize the minimum likelihood level for specific infotypes in the request. For example, use this if you want to lower the precision for PERSON_NAME without lowering the precision for the other infotypes in the request. + + ## Attributes + + * `infoType` (*type:* `GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2InfoType.t`, *default:* `nil`) - Type of information the likelihood threshold applies to. Only one likelihood per info_type should be provided. If InfoTypeLikelihood does not have an info_type, the configuration fails. + * `minLikelihood` (*type:* `String.t`, *default:* `nil`) - Only returns findings equal to or above this threshold. This field is required or else the configuration fails. + """ + + use GoogleApi.Gax.ModelBase + + @type t :: %__MODULE__{ + :infoType => GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2InfoType.t() | nil, + :minLikelihood => String.t() | nil + } + + field(:infoType, as: GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2InfoType) + field(:minLikelihood) +end + +defimpl Poison.Decoder, for: GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2InfoTypeLikelihood do + def decode(value, options) do + GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2InfoTypeLikelihood.decode(value, options) + end +end + +defimpl Poison.Encoder, for: GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2InfoTypeLikelihood do + def encode(value, options) do + GoogleApi.Gax.ModelBase.encode(value, options) + end +end diff --git a/clients/dlp/lib/google_api/dlp/v2/model/google_privacy_dlp_v2_inspect_config.ex b/clients/dlp/lib/google_api/dlp/v2/model/google_privacy_dlp_v2_inspect_config.ex index 0712e8fed7..2df63f1b36 100644 --- a/clients/dlp/lib/google_api/dlp/v2/model/google_privacy_dlp_v2_inspect_config.ex +++ b/clients/dlp/lib/google_api/dlp/v2/model/google_privacy_dlp_v2_inspect_config.ex @@ -22,12 +22,13 @@ defmodule GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2InspectConfig do ## Attributes * `contentOptions` (*type:* `list(String.t)`, *default:* `nil`) - Deprecated and unused. - * `customInfoTypes` (*type:* `list(GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2CustomInfoType.t)`, *default:* `nil`) - CustomInfoTypes provided by the user. See https://cloud.google.com/dlp/docs/creating-custom-infotypes to learn more. + * `customInfoTypes` (*type:* `list(GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2CustomInfoType.t)`, *default:* `nil`) - CustomInfoTypes provided by the user. See https://cloud.google.com/sensitive-data-protection/docs/creating-custom-infotypes to learn more. * `excludeInfoTypes` (*type:* `boolean()`, *default:* `nil`) - When true, excludes type information of the findings. This is not used for data profiling. * `includeQuote` (*type:* `boolean()`, *default:* `nil`) - When true, a contextual quote from the data that triggered a finding is included in the response; see Finding.quote. This is not used for data profiling. - * `infoTypes` (*type:* `list(GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2InfoType.t)`, *default:* `nil`) - Restricts what info_types to look for. The values must correspond to InfoType values returned by ListInfoTypes or listed at https://cloud.google.com/dlp/docs/infotypes-reference. When no InfoTypes or CustomInfoTypes are specified in a request, the system may automatically choose what detectors to run. By default this may be all types, but may change over time as detectors are updated. If you need precise control and predictability as to what detectors are run you should specify specific InfoTypes listed in the reference, otherwise a default list will be used, which may change over time. - * `limits` (*type:* `GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2FindingLimits.t`, *default:* `nil`) - Configuration to control the number of findings returned. This is not used for data profiling. When redacting sensitive data from images, finding limits don't apply. They can cause unexpected or inconsistent results, where only some data is redacted. Don't include finding limits in RedactImage requests. Otherwise, Cloud DLP returns an error. - * `minLikelihood` (*type:* `String.t`, *default:* `nil`) - Only returns findings equal or above this threshold. The default is POSSIBLE. See https://cloud.google.com/dlp/docs/likelihood to learn more. + * `infoTypes` (*type:* `list(GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2InfoType.t)`, *default:* `nil`) - Restricts what info_types to look for. The values must correspond to InfoType values returned by ListInfoTypes or listed at https://cloud.google.com/sensitive-data-protection/docs/infotypes-reference. When no InfoTypes or CustomInfoTypes are specified in a request, the system may automatically choose a default list of detectors to run, which may change over time. If you need precise control and predictability as to what detectors are run you should specify specific InfoTypes listed in the reference, otherwise a default list will be used, which may change over time. + * `limits` (*type:* `GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2FindingLimits.t`, *default:* `nil`) - Configuration to control the number of findings returned. This is not used for data profiling. When redacting sensitive data from images, finding limits don't apply. They can cause unexpected or inconsistent results, where only some data is redacted. Don't include finding limits in RedactImage requests. Otherwise, Cloud DLP returns an error. When set within an InspectJobConfig, the specified maximum values aren't hard limits. If an inspection job reaches these limits, the job ends gradually, not abruptly. Therefore, the actual number of findings that Cloud DLP returns can be multiple times higher than these maximum values. + * `minLikelihood` (*type:* `String.t`, *default:* `nil`) - Only returns findings equal to or above this threshold. The default is POSSIBLE. In general, the highest likelihood setting yields the fewest findings in results and the lowest chance of a false positive. For more information, see [Match likelihood](https://cloud.google.com/sensitive-data-protection/docs/likelihood). + * `minLikelihoodPerInfoType` (*type:* `list(GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2InfoTypeLikelihood.t)`, *default:* `nil`) - Minimum likelihood per infotype. For each infotype, a user can specify a minimum likelihood. The system only returns a finding if its likelihood is above this threshold. If this field is not set, the system uses the InspectConfig min_likelihood. * `ruleSet` (*type:* `list(GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2InspectionRuleSet.t)`, *default:* `nil`) - Set of rules to apply to the findings for this InspectConfig. Exclusion rules, contained in the set are executed in the end, other rules are executed in the order they are specified for each info type. """ @@ -42,6 +43,8 @@ defmodule GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2InspectConfig do :infoTypes => list(GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2InfoType.t()) | nil, :limits => GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2FindingLimits.t() | nil, :minLikelihood => String.t() | nil, + :minLikelihoodPerInfoType => + list(GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2InfoTypeLikelihood.t()) | nil, :ruleSet => list(GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2InspectionRuleSet.t()) | nil } @@ -54,6 +57,12 @@ defmodule GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2InspectConfig do field(:infoTypes, as: GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2InfoType, type: :list) field(:limits, as: GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2FindingLimits) field(:minLikelihood) + + field(:minLikelihoodPerInfoType, + as: GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2InfoTypeLikelihood, + type: :list + ) + field(:ruleSet, as: GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2InspectionRuleSet, type: :list) end diff --git a/clients/dlp/lib/google_api/dlp/v2/model/google_privacy_dlp_v2_inspect_template.ex b/clients/dlp/lib/google_api/dlp/v2/model/google_privacy_dlp_v2_inspect_template.ex index fbc569c6bb..16dcafa5ba 100644 --- a/clients/dlp/lib/google_api/dlp/v2/model/google_privacy_dlp_v2_inspect_template.ex +++ b/clients/dlp/lib/google_api/dlp/v2/model/google_privacy_dlp_v2_inspect_template.ex @@ -17,7 +17,7 @@ defmodule GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2InspectTemplate do @moduledoc """ - The inspectTemplate contains a configuration (set of types of sensitive data to be detected) to be used anywhere you otherwise would normally specify InspectConfig. See https://cloud.google.com/dlp/docs/concepts-templates to learn more. + The inspectTemplate contains a configuration (set of types of sensitive data to be detected) to be used anywhere you otherwise would normally specify InspectConfig. See https://cloud.google.com/sensitive-data-protection/docs/concepts-templates to learn more. ## Attributes diff --git a/clients/dlp/lib/google_api/dlp/v2/model/google_privacy_dlp_v2_job_trigger.ex b/clients/dlp/lib/google_api/dlp/v2/model/google_privacy_dlp_v2_job_trigger.ex index 9102f0773c..23b21b2a8d 100644 --- a/clients/dlp/lib/google_api/dlp/v2/model/google_privacy_dlp_v2_job_trigger.ex +++ b/clients/dlp/lib/google_api/dlp/v2/model/google_privacy_dlp_v2_job_trigger.ex @@ -17,7 +17,7 @@ defmodule GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2JobTrigger do @moduledoc """ - Contains a configuration to make dlp api calls on a repeating basis. See https://cloud.google.com/dlp/docs/concepts-job-triggers to learn more. + Contains a configuration to make dlp api calls on a repeating basis. See https://cloud.google.com/sensitive-data-protection/docs/concepts-job-triggers to learn more. ## Attributes diff --git a/clients/dlp/lib/google_api/dlp/v2/model/google_privacy_dlp_v2_kms_wrapped_crypto_key.ex b/clients/dlp/lib/google_api/dlp/v2/model/google_privacy_dlp_v2_kms_wrapped_crypto_key.ex index 689c5ac300..9f3f72293c 100644 --- a/clients/dlp/lib/google_api/dlp/v2/model/google_privacy_dlp_v2_kms_wrapped_crypto_key.ex +++ b/clients/dlp/lib/google_api/dlp/v2/model/google_privacy_dlp_v2_kms_wrapped_crypto_key.ex @@ -17,7 +17,7 @@ defmodule GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2KmsWrappedCryptoKey do @moduledoc """ - Include to use an existing data crypto key wrapped by KMS. The wrapped key must be a 128-, 192-, or 256-bit key. Authorization requires the following IAM permissions when sending a request to perform a crypto transformation using a KMS-wrapped crypto key: dlp.kms.encrypt For more information, see [Creating a wrapped key] (https://cloud.google.com/dlp/docs/create-wrapped-key). Note: When you use Cloud KMS for cryptographic operations, [charges apply](https://cloud.google.com/kms/pricing). + Include to use an existing data crypto key wrapped by KMS. The wrapped key must be a 128-, 192-, or 256-bit key. Authorization requires the following IAM permissions when sending a request to perform a crypto transformation using a KMS-wrapped crypto key: dlp.kms.encrypt For more information, see [Creating a wrapped key] (https://cloud.google.com/sensitive-data-protection/docs/create-wrapped-key). Note: When you use Cloud KMS for cryptographic operations, [charges apply](https://cloud.google.com/kms/pricing). ## Attributes diff --git a/clients/dlp/lib/google_api/dlp/v2/model/google_privacy_dlp_v2_large_custom_dictionary_config.ex b/clients/dlp/lib/google_api/dlp/v2/model/google_privacy_dlp_v2_large_custom_dictionary_config.ex index 4ece7bb511..1082e1961b 100644 --- a/clients/dlp/lib/google_api/dlp/v2/model/google_privacy_dlp_v2_large_custom_dictionary_config.ex +++ b/clients/dlp/lib/google_api/dlp/v2/model/google_privacy_dlp_v2_large_custom_dictionary_config.ex @@ -17,7 +17,7 @@ defmodule GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2LargeCustomDictionaryConfig do @moduledoc """ - Configuration for a custom dictionary created from a data source of any size up to the maximum size defined in the [limits](https://cloud.google.com/dlp/limits) page. The artifacts of dictionary creation are stored in the specified Cloud Storage location. Consider using `CustomInfoType.Dictionary` for smaller dictionaries that satisfy the size requirements. + Configuration for a custom dictionary created from a data source of any size up to the maximum size defined in the [limits](https://cloud.google.com/sensitive-data-protection/limits) page. The artifacts of dictionary creation are stored in the specified Cloud Storage location. Consider using `CustomInfoType.Dictionary` for smaller dictionaries that satisfy the size requirements. ## Attributes diff --git a/clients/dlp/lib/google_api/dlp/v2/model/google_privacy_dlp_v2_list_column_data_profiles_response.ex b/clients/dlp/lib/google_api/dlp/v2/model/google_privacy_dlp_v2_list_column_data_profiles_response.ex new file mode 100644 index 0000000000..af49175a42 --- /dev/null +++ b/clients/dlp/lib/google_api/dlp/v2/model/google_privacy_dlp_v2_list_column_data_profiles_response.ex @@ -0,0 +1,56 @@ +# Copyright 2019 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# NOTE: This file is auto generated by the elixir code generator program. +# Do not edit this file manually. + +defmodule GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2ListColumnDataProfilesResponse do + @moduledoc """ + List of profiles generated for a given organization or project. + + ## Attributes + + * `columnDataProfiles` (*type:* `list(GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2ColumnDataProfile.t)`, *default:* `nil`) - List of data profiles. + * `nextPageToken` (*type:* `String.t`, *default:* `nil`) - The next page token. + """ + + use GoogleApi.Gax.ModelBase + + @type t :: %__MODULE__{ + :columnDataProfiles => + list(GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2ColumnDataProfile.t()) | nil, + :nextPageToken => String.t() | nil + } + + field(:columnDataProfiles, + as: GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2ColumnDataProfile, + type: :list + ) + + field(:nextPageToken) +end + +defimpl Poison.Decoder, + for: GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2ListColumnDataProfilesResponse do + def decode(value, options) do + GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2ListColumnDataProfilesResponse.decode(value, options) + end +end + +defimpl Poison.Encoder, + for: GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2ListColumnDataProfilesResponse do + def encode(value, options) do + GoogleApi.Gax.ModelBase.encode(value, options) + end +end diff --git a/clients/dlp/lib/google_api/dlp/v2/model/google_privacy_dlp_v2_list_deidentify_templates_response.ex b/clients/dlp/lib/google_api/dlp/v2/model/google_privacy_dlp_v2_list_deidentify_templates_response.ex index 7b53bb3b42..976e2643bc 100644 --- a/clients/dlp/lib/google_api/dlp/v2/model/google_privacy_dlp_v2_list_deidentify_templates_response.ex +++ b/clients/dlp/lib/google_api/dlp/v2/model/google_privacy_dlp_v2_list_deidentify_templates_response.ex @@ -22,7 +22,7 @@ defmodule GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2ListDeidentifyTemplatesRespon ## Attributes * `deidentifyTemplates` (*type:* `list(GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2DeidentifyTemplate.t)`, *default:* `nil`) - List of deidentify templates, up to page_size in ListDeidentifyTemplatesRequest. - * `nextPageToken` (*type:* `String.t`, *default:* `nil`) - If the next page is available then the next page token to be used in following ListDeidentifyTemplates request. + * `nextPageToken` (*type:* `String.t`, *default:* `nil`) - If the next page is available then the next page token to be used in the following ListDeidentifyTemplates request. """ use GoogleApi.Gax.ModelBase diff --git a/clients/dlp/lib/google_api/dlp/v2/model/google_privacy_dlp_v2_list_discovery_configs_response.ex b/clients/dlp/lib/google_api/dlp/v2/model/google_privacy_dlp_v2_list_discovery_configs_response.ex new file mode 100644 index 0000000000..350af0422f --- /dev/null +++ b/clients/dlp/lib/google_api/dlp/v2/model/google_privacy_dlp_v2_list_discovery_configs_response.ex @@ -0,0 +1,54 @@ +# Copyright 2019 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# NOTE: This file is auto generated by the elixir code generator program. +# Do not edit this file manually. + +defmodule GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2ListDiscoveryConfigsResponse do + @moduledoc """ + Response message for ListDiscoveryConfigs. + + ## Attributes + + * `discoveryConfigs` (*type:* `list(GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2DiscoveryConfig.t)`, *default:* `nil`) - List of configs, up to page_size in ListDiscoveryConfigsRequest. + * `nextPageToken` (*type:* `String.t`, *default:* `nil`) - If the next page is available then this value is the next page token to be used in the following ListDiscoveryConfigs request. + """ + + use GoogleApi.Gax.ModelBase + + @type t :: %__MODULE__{ + :discoveryConfigs => + list(GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2DiscoveryConfig.t()) | nil, + :nextPageToken => String.t() | nil + } + + field(:discoveryConfigs, + as: GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2DiscoveryConfig, + type: :list + ) + + field(:nextPageToken) +end + +defimpl Poison.Decoder, for: GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2ListDiscoveryConfigsResponse do + def decode(value, options) do + GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2ListDiscoveryConfigsResponse.decode(value, options) + end +end + +defimpl Poison.Encoder, for: GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2ListDiscoveryConfigsResponse do + def encode(value, options) do + GoogleApi.Gax.ModelBase.encode(value, options) + end +end diff --git a/clients/dlp/lib/google_api/dlp/v2/model/google_privacy_dlp_v2_list_inspect_templates_response.ex b/clients/dlp/lib/google_api/dlp/v2/model/google_privacy_dlp_v2_list_inspect_templates_response.ex index 74abeb5953..30f606be6f 100644 --- a/clients/dlp/lib/google_api/dlp/v2/model/google_privacy_dlp_v2_list_inspect_templates_response.ex +++ b/clients/dlp/lib/google_api/dlp/v2/model/google_privacy_dlp_v2_list_inspect_templates_response.ex @@ -22,7 +22,7 @@ defmodule GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2ListInspectTemplatesResponse ## Attributes * `inspectTemplates` (*type:* `list(GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2InspectTemplate.t)`, *default:* `nil`) - List of inspectTemplates, up to page_size in ListInspectTemplatesRequest. - * `nextPageToken` (*type:* `String.t`, *default:* `nil`) - If the next page is available then the next page token to be used in following ListInspectTemplates request. + * `nextPageToken` (*type:* `String.t`, *default:* `nil`) - If the next page is available then the next page token to be used in the following ListInspectTemplates request. """ use GoogleApi.Gax.ModelBase diff --git a/clients/dlp/lib/google_api/dlp/v2/model/google_privacy_dlp_v2_list_job_triggers_response.ex b/clients/dlp/lib/google_api/dlp/v2/model/google_privacy_dlp_v2_list_job_triggers_response.ex index 8e545e8bf6..21329a8a11 100644 --- a/clients/dlp/lib/google_api/dlp/v2/model/google_privacy_dlp_v2_list_job_triggers_response.ex +++ b/clients/dlp/lib/google_api/dlp/v2/model/google_privacy_dlp_v2_list_job_triggers_response.ex @@ -22,7 +22,7 @@ defmodule GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2ListJobTriggersResponse do ## Attributes * `jobTriggers` (*type:* `list(GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2JobTrigger.t)`, *default:* `nil`) - List of triggeredJobs, up to page_size in ListJobTriggersRequest. - * `nextPageToken` (*type:* `String.t`, *default:* `nil`) - If the next page is available then the next page token to be used in following ListJobTriggers request. + * `nextPageToken` (*type:* `String.t`, *default:* `nil`) - If the next page is available then this value is the next page token to be used in the following ListJobTriggers request. """ use GoogleApi.Gax.ModelBase diff --git a/clients/dlp/lib/google_api/dlp/v2/model/google_privacy_dlp_v2_list_project_data_profiles_response.ex b/clients/dlp/lib/google_api/dlp/v2/model/google_privacy_dlp_v2_list_project_data_profiles_response.ex new file mode 100644 index 0000000000..387e83637f --- /dev/null +++ b/clients/dlp/lib/google_api/dlp/v2/model/google_privacy_dlp_v2_list_project_data_profiles_response.ex @@ -0,0 +1,59 @@ +# Copyright 2019 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# NOTE: This file is auto generated by the elixir code generator program. +# Do not edit this file manually. + +defmodule GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2ListProjectDataProfilesResponse do + @moduledoc """ + List of profiles generated for a given organization or project. + + ## Attributes + + * `nextPageToken` (*type:* `String.t`, *default:* `nil`) - The next page token. + * `projectDataProfiles` (*type:* `list(GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2ProjectDataProfile.t)`, *default:* `nil`) - List of data profiles. + """ + + use GoogleApi.Gax.ModelBase + + @type t :: %__MODULE__{ + :nextPageToken => String.t() | nil, + :projectDataProfiles => + list(GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2ProjectDataProfile.t()) | nil + } + + field(:nextPageToken) + + field(:projectDataProfiles, + as: GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2ProjectDataProfile, + type: :list + ) +end + +defimpl Poison.Decoder, + for: GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2ListProjectDataProfilesResponse do + def decode(value, options) do + GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2ListProjectDataProfilesResponse.decode( + value, + options + ) + end +end + +defimpl Poison.Encoder, + for: GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2ListProjectDataProfilesResponse do + def encode(value, options) do + GoogleApi.Gax.ModelBase.encode(value, options) + end +end diff --git a/clients/dlp/lib/google_api/dlp/v2/model/google_privacy_dlp_v2_list_stored_info_types_response.ex b/clients/dlp/lib/google_api/dlp/v2/model/google_privacy_dlp_v2_list_stored_info_types_response.ex index b552779b37..13c30fbc7e 100644 --- a/clients/dlp/lib/google_api/dlp/v2/model/google_privacy_dlp_v2_list_stored_info_types_response.ex +++ b/clients/dlp/lib/google_api/dlp/v2/model/google_privacy_dlp_v2_list_stored_info_types_response.ex @@ -21,7 +21,7 @@ defmodule GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2ListStoredInfoTypesResponse d ## Attributes - * `nextPageToken` (*type:* `String.t`, *default:* `nil`) - If the next page is available then the next page token to be used in following ListStoredInfoTypes request. + * `nextPageToken` (*type:* `String.t`, *default:* `nil`) - If the next page is available then the next page token to be used in the following ListStoredInfoTypes request. * `storedInfoTypes` (*type:* `list(GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2StoredInfoType.t)`, *default:* `nil`) - List of storedInfoTypes, up to page_size in ListStoredInfoTypesRequest. """ diff --git a/clients/dlp/lib/google_api/dlp/v2/model/google_privacy_dlp_v2_list_table_data_profiles_response.ex b/clients/dlp/lib/google_api/dlp/v2/model/google_privacy_dlp_v2_list_table_data_profiles_response.ex new file mode 100644 index 0000000000..f29a155209 --- /dev/null +++ b/clients/dlp/lib/google_api/dlp/v2/model/google_privacy_dlp_v2_list_table_data_profiles_response.ex @@ -0,0 +1,56 @@ +# Copyright 2019 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# NOTE: This file is auto generated by the elixir code generator program. +# Do not edit this file manually. + +defmodule GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2ListTableDataProfilesResponse do + @moduledoc """ + List of profiles generated for a given organization or project. + + ## Attributes + + * `nextPageToken` (*type:* `String.t`, *default:* `nil`) - The next page token. + * `tableDataProfiles` (*type:* `list(GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2TableDataProfile.t)`, *default:* `nil`) - List of data profiles. + """ + + use GoogleApi.Gax.ModelBase + + @type t :: %__MODULE__{ + :nextPageToken => String.t() | nil, + :tableDataProfiles => + list(GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2TableDataProfile.t()) | nil + } + + field(:nextPageToken) + + field(:tableDataProfiles, + as: GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2TableDataProfile, + type: :list + ) +end + +defimpl Poison.Decoder, + for: GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2ListTableDataProfilesResponse do + def decode(value, options) do + GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2ListTableDataProfilesResponse.decode(value, options) + end +end + +defimpl Poison.Encoder, + for: GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2ListTableDataProfilesResponse do + def encode(value, options) do + GoogleApi.Gax.ModelBase.encode(value, options) + end +end diff --git a/clients/dlp/lib/google_api/dlp/v2/model/google_privacy_dlp_v2_or_conditions.ex b/clients/dlp/lib/google_api/dlp/v2/model/google_privacy_dlp_v2_or_conditions.ex new file mode 100644 index 0000000000..3c38eab49f --- /dev/null +++ b/clients/dlp/lib/google_api/dlp/v2/model/google_privacy_dlp_v2_or_conditions.ex @@ -0,0 +1,49 @@ +# Copyright 2019 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# NOTE: This file is auto generated by the elixir code generator program. +# Do not edit this file manually. + +defmodule GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2OrConditions do + @moduledoc """ + There is an OR relationship between these attributes. They are used to determine if a table should be scanned or not in Discovery. + + ## Attributes + + * `minAge` (*type:* `String.t`, *default:* `nil`) - Minimum age a table must have before Cloud DLP can profile it. Value must be 1 hour or greater. + * `minRowCount` (*type:* `integer()`, *default:* `nil`) - Minimum number of rows that should be present before Cloud DLP profiles a table + """ + + use GoogleApi.Gax.ModelBase + + @type t :: %__MODULE__{ + :minAge => String.t() | nil, + :minRowCount => integer() | nil + } + + field(:minAge) + field(:minRowCount) +end + +defimpl Poison.Decoder, for: GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2OrConditions do + def decode(value, options) do + GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2OrConditions.decode(value, options) + end +end + +defimpl Poison.Encoder, for: GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2OrConditions do + def encode(value, options) do + GoogleApi.Gax.ModelBase.encode(value, options) + end +end diff --git a/clients/dlp/lib/google_api/dlp/v2/model/google_privacy_dlp_v2_org_config.ex b/clients/dlp/lib/google_api/dlp/v2/model/google_privacy_dlp_v2_org_config.ex new file mode 100644 index 0000000000..1140dcaa68 --- /dev/null +++ b/clients/dlp/lib/google_api/dlp/v2/model/google_privacy_dlp_v2_org_config.ex @@ -0,0 +1,50 @@ +# Copyright 2019 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# NOTE: This file is auto generated by the elixir code generator program. +# Do not edit this file manually. + +defmodule GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2OrgConfig do + @moduledoc """ + Project and scan location information. Only set when the parent is an org. + + ## Attributes + + * `location` (*type:* `GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2DiscoveryStartingLocation.t`, *default:* `nil`) - The data to scan: folder, org, or project + * `projectId` (*type:* `String.t`, *default:* `nil`) - The project that will run the scan. The DLP service account that exists within this project must have access to all resources that are profiled, and the Cloud DLP API must be enabled. + """ + + use GoogleApi.Gax.ModelBase + + @type t :: %__MODULE__{ + :location => + GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2DiscoveryStartingLocation.t() | nil, + :projectId => String.t() | nil + } + + field(:location, as: GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2DiscoveryStartingLocation) + field(:projectId) +end + +defimpl Poison.Decoder, for: GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2OrgConfig do + def decode(value, options) do + GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2OrgConfig.decode(value, options) + end +end + +defimpl Poison.Encoder, for: GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2OrgConfig do + def encode(value, options) do + GoogleApi.Gax.ModelBase.encode(value, options) + end +end diff --git a/clients/dlp/lib/google_api/dlp/v2/model/google_privacy_dlp_v2_other_info_type_summary.ex b/clients/dlp/lib/google_api/dlp/v2/model/google_privacy_dlp_v2_other_info_type_summary.ex index e9f82a58cb..71a37f73f2 100644 --- a/clients/dlp/lib/google_api/dlp/v2/model/google_privacy_dlp_v2_other_info_type_summary.ex +++ b/clients/dlp/lib/google_api/dlp/v2/model/google_privacy_dlp_v2_other_info_type_summary.ex @@ -22,6 +22,7 @@ defmodule GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2OtherInfoTypeSummary do ## Attributes * `estimatedPrevalence` (*type:* `integer()`, *default:* `nil`) - Approximate percentage of non-null rows that contained data detected by this infotype. + * `excludedFromAnalysis` (*type:* `boolean()`, *default:* `nil`) - Whether this infoType was excluded from sensitivity and risk analysis due to factors such as low prevalence (subject to change). * `infoType` (*type:* `GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2InfoType.t`, *default:* `nil`) - The other infoType. """ @@ -29,10 +30,12 @@ defmodule GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2OtherInfoTypeSummary do @type t :: %__MODULE__{ :estimatedPrevalence => integer() | nil, + :excludedFromAnalysis => boolean() | nil, :infoType => GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2InfoType.t() | nil } field(:estimatedPrevalence) + field(:excludedFromAnalysis) field(:infoType, as: GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2InfoType) end diff --git a/clients/dlp/lib/google_api/dlp/v2/model/google_privacy_dlp_v2_profile_status.ex b/clients/dlp/lib/google_api/dlp/v2/model/google_privacy_dlp_v2_profile_status.ex index dceec7f585..ea08c379a0 100644 --- a/clients/dlp/lib/google_api/dlp/v2/model/google_privacy_dlp_v2_profile_status.ex +++ b/clients/dlp/lib/google_api/dlp/v2/model/google_privacy_dlp_v2_profile_status.ex @@ -17,11 +17,11 @@ defmodule GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2ProfileStatus do @moduledoc """ - + Success or errors for the profile generation. ## Attributes - * `status` (*type:* `GoogleApi.DLP.V2.Model.GoogleRpcStatus.t`, *default:* `nil`) - Profiling status code and optional message + * `status` (*type:* `GoogleApi.DLP.V2.Model.GoogleRpcStatus.t`, *default:* `nil`) - Profiling status code and optional message. The `status.code` value is 0 (default value) for OK. * `timestamp` (*type:* `DateTime.t`, *default:* `nil`) - Time when the profile generation status was updated """ diff --git a/clients/dlp/lib/google_api/dlp/v2/model/google_privacy_dlp_v2_project_data_profile.ex b/clients/dlp/lib/google_api/dlp/v2/model/google_privacy_dlp_v2_project_data_profile.ex new file mode 100644 index 0000000000..886fdb0450 --- /dev/null +++ b/clients/dlp/lib/google_api/dlp/v2/model/google_privacy_dlp_v2_project_data_profile.ex @@ -0,0 +1,61 @@ +# Copyright 2019 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# NOTE: This file is auto generated by the elixir code generator program. +# Do not edit this file manually. + +defmodule GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2ProjectDataProfile do + @moduledoc """ + An aggregated profile for this project, based on the resources profiled within it. + + ## Attributes + + * `dataRiskLevel` (*type:* `GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2DataRiskLevel.t`, *default:* `nil`) - The data risk level of this project. + * `name` (*type:* `String.t`, *default:* `nil`) - The resource name of the profile. + * `profileLastGenerated` (*type:* `DateTime.t`, *default:* `nil`) - The last time the profile was generated. + * `profileStatus` (*type:* `GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2ProfileStatus.t`, *default:* `nil`) - Success or error status of the last attempt to profile the project. + * `projectId` (*type:* `String.t`, *default:* `nil`) - Project ID that was profiled. + * `sensitivityScore` (*type:* `GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2SensitivityScore.t`, *default:* `nil`) - The sensitivity score of this project. + """ + + use GoogleApi.Gax.ModelBase + + @type t :: %__MODULE__{ + :dataRiskLevel => GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2DataRiskLevel.t() | nil, + :name => String.t() | nil, + :profileLastGenerated => DateTime.t() | nil, + :profileStatus => GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2ProfileStatus.t() | nil, + :projectId => String.t() | nil, + :sensitivityScore => GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2SensitivityScore.t() | nil + } + + field(:dataRiskLevel, as: GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2DataRiskLevel) + field(:name) + field(:profileLastGenerated, as: DateTime) + field(:profileStatus, as: GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2ProfileStatus) + field(:projectId) + field(:sensitivityScore, as: GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2SensitivityScore) +end + +defimpl Poison.Decoder, for: GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2ProjectDataProfile do + def decode(value, options) do + GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2ProjectDataProfile.decode(value, options) + end +end + +defimpl Poison.Encoder, for: GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2ProjectDataProfile do + def encode(value, options) do + GoogleApi.Gax.ModelBase.encode(value, options) + end +end diff --git a/clients/dlp/lib/google_api/dlp/v2/model/google_privacy_dlp_v2_proximity.ex b/clients/dlp/lib/google_api/dlp/v2/model/google_privacy_dlp_v2_proximity.ex index fe04851012..1e15b99c23 100644 --- a/clients/dlp/lib/google_api/dlp/v2/model/google_privacy_dlp_v2_proximity.ex +++ b/clients/dlp/lib/google_api/dlp/v2/model/google_privacy_dlp_v2_proximity.ex @@ -22,7 +22,7 @@ defmodule GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2Proximity do ## Attributes * `windowAfter` (*type:* `integer()`, *default:* `nil`) - Number of characters after the finding to consider. - * `windowBefore` (*type:* `integer()`, *default:* `nil`) - Number of characters before the finding to consider. For tabular data, if you want to modify the likelihood of an entire column of findngs, set this to 1. For more information, see [Hotword example: Set the match likelihood of a table column] (https://cloud.google.com/dlp/docs/creating-custom-infotypes-likelihood#match-column-values). + * `windowBefore` (*type:* `integer()`, *default:* `nil`) - Number of characters before the finding to consider. For tabular data, if you want to modify the likelihood of an entire column of findngs, set this to 1. For more information, see [Hotword example: Set the match likelihood of a table column] (https://cloud.google.com/sensitive-data-protection/docs/creating-custom-infotypes-likelihood#match-column-values). """ use GoogleApi.Gax.ModelBase diff --git a/clients/dlp/lib/google_api/dlp/v2/model/google_privacy_dlp_v2_publish_summary_to_cscc.ex b/clients/dlp/lib/google_api/dlp/v2/model/google_privacy_dlp_v2_publish_summary_to_cscc.ex index 7879ba69fc..0d474099c2 100644 --- a/clients/dlp/lib/google_api/dlp/v2/model/google_privacy_dlp_v2_publish_summary_to_cscc.ex +++ b/clients/dlp/lib/google_api/dlp/v2/model/google_privacy_dlp_v2_publish_summary_to_cscc.ex @@ -17,7 +17,7 @@ defmodule GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2PublishSummaryToCscc do @moduledoc """ - Publish the result summary of a DlpJob to the Cloud Security Command Center (CSCC Alpha). This action is only available for projects which are parts of an organization and whitelisted for the alpha Cloud Security Command Center. The action will publish the count of finding instances and their info types. The summary of findings will be persisted in CSCC and are governed by CSCC service-specific policy, see https://cloud.google.com/terms/service-terms Only a single instance of this action can be specified. Compatible with: Inspect + Publish the result summary of a DlpJob to [Security Command Center](https://cloud.google.com/security-command-center). This action is available for only projects that belong to an organization. This action publishes the count of finding instances and their infoTypes. The summary of findings are persisted in Security Command Center and are governed by [service-specific policies for Security Command Center](https://cloud.google.com/terms/service-terms). Only a single instance of this action can be specified. Compatible with: Inspect ## Attributes diff --git a/clients/dlp/lib/google_api/dlp/v2/model/google_privacy_dlp_v2_publish_to_pub_sub.ex b/clients/dlp/lib/google_api/dlp/v2/model/google_privacy_dlp_v2_publish_to_pub_sub.ex index 3bda824a1e..6cc6ea23b2 100644 --- a/clients/dlp/lib/google_api/dlp/v2/model/google_privacy_dlp_v2_publish_to_pub_sub.ex +++ b/clients/dlp/lib/google_api/dlp/v2/model/google_privacy_dlp_v2_publish_to_pub_sub.ex @@ -17,7 +17,7 @@ defmodule GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2PublishToPubSub do @moduledoc """ - Publish a message into a given Pub/Sub topic when DlpJob has completed. The message contains a single field, `DlpJobName`, which is equal to the finished job's [`DlpJob.name`](https://cloud.google.com/dlp/docs/reference/rest/v2/projects.dlpJobs#DlpJob). Compatible with: Inspect, Risk + Publish a message into a given Pub/Sub topic when DlpJob has completed. The message contains a single field, `DlpJobName`, which is equal to the finished job's [`DlpJob.name`](https://cloud.google.com/sensitive-data-protection/docs/reference/rest/v2/projects.dlpJobs#DlpJob). Compatible with: Inspect, Risk ## Attributes diff --git a/clients/dlp/lib/google_api/dlp/v2/model/google_privacy_dlp_v2_record_key.ex b/clients/dlp/lib/google_api/dlp/v2/model/google_privacy_dlp_v2_record_key.ex index 3b4fad88f0..c1c90293e6 100644 --- a/clients/dlp/lib/google_api/dlp/v2/model/google_privacy_dlp_v2_record_key.ex +++ b/clients/dlp/lib/google_api/dlp/v2/model/google_privacy_dlp_v2_record_key.ex @@ -21,8 +21,8 @@ defmodule GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2RecordKey do ## Attributes - * `bigQueryKey` (*type:* `GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2BigQueryKey.t`, *default:* `nil`) - - * `datastoreKey` (*type:* `GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2DatastoreKey.t`, *default:* `nil`) - + * `bigQueryKey` (*type:* `GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2BigQueryKey.t`, *default:* `nil`) - Datastore key + * `datastoreKey` (*type:* `GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2DatastoreKey.t`, *default:* `nil`) - BigQuery key * `idValues` (*type:* `list(String.t)`, *default:* `nil`) - Values of identifying columns in the given row. Order of values matches the order of `identifying_fields` specified in the scanning request. """ diff --git a/clients/dlp/lib/google_api/dlp/v2/model/google_privacy_dlp_v2_record_transformation.ex b/clients/dlp/lib/google_api/dlp/v2/model/google_privacy_dlp_v2_record_transformation.ex index 54469c7b46..e63ffbb7aa 100644 --- a/clients/dlp/lib/google_api/dlp/v2/model/google_privacy_dlp_v2_record_transformation.ex +++ b/clients/dlp/lib/google_api/dlp/v2/model/google_privacy_dlp_v2_record_transformation.ex @@ -17,7 +17,7 @@ defmodule GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2RecordTransformation do @moduledoc """ - + The field in a record to transform. ## Attributes diff --git a/clients/dlp/lib/google_api/dlp/v2/model/google_privacy_dlp_v2_replace_dictionary_config.ex b/clients/dlp/lib/google_api/dlp/v2/model/google_privacy_dlp_v2_replace_dictionary_config.ex index ac61340084..8edac83add 100644 --- a/clients/dlp/lib/google_api/dlp/v2/model/google_privacy_dlp_v2_replace_dictionary_config.ex +++ b/clients/dlp/lib/google_api/dlp/v2/model/google_privacy_dlp_v2_replace_dictionary_config.ex @@ -21,7 +21,7 @@ defmodule GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2ReplaceDictionaryConfig do ## Attributes - * `wordList` (*type:* `GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2WordList.t`, *default:* `nil`) - A list of words to select from for random replacement. The [limits](https://cloud.google.com/dlp/limits) page contains details about the size limits of dictionaries. + * `wordList` (*type:* `GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2WordList.t`, *default:* `nil`) - A list of words to select from for random replacement. The [limits](https://cloud.google.com/sensitive-data-protection/limits) page contains details about the size limits of dictionaries. """ use GoogleApi.Gax.ModelBase diff --git a/clients/dlp/lib/google_api/dlp/v2/model/google_privacy_dlp_v2_requested_deidentify_options.ex b/clients/dlp/lib/google_api/dlp/v2/model/google_privacy_dlp_v2_requested_deidentify_options.ex new file mode 100644 index 0000000000..8e3489afd4 --- /dev/null +++ b/clients/dlp/lib/google_api/dlp/v2/model/google_privacy_dlp_v2_requested_deidentify_options.ex @@ -0,0 +1,63 @@ +# Copyright 2019 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# NOTE: This file is auto generated by the elixir code generator program. +# Do not edit this file manually. + +defmodule GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2RequestedDeidentifyOptions do + @moduledoc """ + De-identification options. + + ## Attributes + + * `snapshotDeidentifyTemplate` (*type:* `GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2DeidentifyTemplate.t`, *default:* `nil`) - Snapshot of the state of the `DeidentifyTemplate` from the Deidentify action at the time this job was run. + * `snapshotImageRedactTemplate` (*type:* `GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2DeidentifyTemplate.t`, *default:* `nil`) - Snapshot of the state of the image transformation `DeidentifyTemplate` from the `Deidentify` action at the time this job was run. + * `snapshotStructuredDeidentifyTemplate` (*type:* `GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2DeidentifyTemplate.t`, *default:* `nil`) - Snapshot of the state of the structured `DeidentifyTemplate` from the `Deidentify` action at the time this job was run. + """ + + use GoogleApi.Gax.ModelBase + + @type t :: %__MODULE__{ + :snapshotDeidentifyTemplate => + GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2DeidentifyTemplate.t() | nil, + :snapshotImageRedactTemplate => + GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2DeidentifyTemplate.t() | nil, + :snapshotStructuredDeidentifyTemplate => + GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2DeidentifyTemplate.t() | nil + } + + field(:snapshotDeidentifyTemplate, + as: GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2DeidentifyTemplate + ) + + field(:snapshotImageRedactTemplate, + as: GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2DeidentifyTemplate + ) + + field(:snapshotStructuredDeidentifyTemplate, + as: GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2DeidentifyTemplate + ) +end + +defimpl Poison.Decoder, for: GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2RequestedDeidentifyOptions do + def decode(value, options) do + GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2RequestedDeidentifyOptions.decode(value, options) + end +end + +defimpl Poison.Encoder, for: GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2RequestedDeidentifyOptions do + def encode(value, options) do + GoogleApi.Gax.ModelBase.encode(value, options) + end +end diff --git a/clients/dlp/lib/google_api/dlp/v2/model/google_privacy_dlp_v2_risk_analysis_job_config.ex b/clients/dlp/lib/google_api/dlp/v2/model/google_privacy_dlp_v2_risk_analysis_job_config.ex index 0cf43313d3..94e8deee29 100644 --- a/clients/dlp/lib/google_api/dlp/v2/model/google_privacy_dlp_v2_risk_analysis_job_config.ex +++ b/clients/dlp/lib/google_api/dlp/v2/model/google_privacy_dlp_v2_risk_analysis_job_config.ex @@ -17,7 +17,7 @@ defmodule GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2RiskAnalysisJobConfig do @moduledoc """ - Configuration for a risk analysis job. See https://cloud.google.com/dlp/docs/concepts-risk-analysis to learn more. + Configuration for a risk analysis job. See https://cloud.google.com/sensitive-data-protection/docs/concepts-risk-analysis to learn more. ## Attributes diff --git a/clients/dlp/lib/google_api/dlp/v2/model/google_privacy_dlp_v2_sensitivity_score.ex b/clients/dlp/lib/google_api/dlp/v2/model/google_privacy_dlp_v2_sensitivity_score.ex index db3f5c9679..90a81dc361 100644 --- a/clients/dlp/lib/google_api/dlp/v2/model/google_privacy_dlp_v2_sensitivity_score.ex +++ b/clients/dlp/lib/google_api/dlp/v2/model/google_privacy_dlp_v2_sensitivity_score.ex @@ -17,11 +17,11 @@ defmodule GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2SensitivityScore do @moduledoc """ - Score is a summary of all elements in the data profile. A higher number means more sensitive. + Score is calculated from of all elements in the data profile. A higher level means the data is more sensitive. ## Attributes - * `score` (*type:* `String.t`, *default:* `nil`) - The score applied to the resource. + * `score` (*type:* `String.t`, *default:* `nil`) - The sensitivity score applied to the resource. """ use GoogleApi.Gax.ModelBase diff --git a/clients/dlp/lib/google_api/dlp/v2/model/google_privacy_dlp_v2_storage_config.ex b/clients/dlp/lib/google_api/dlp/v2/model/google_privacy_dlp_v2_storage_config.ex index 37592b1172..5fa1ba88fa 100644 --- a/clients/dlp/lib/google_api/dlp/v2/model/google_privacy_dlp_v2_storage_config.ex +++ b/clients/dlp/lib/google_api/dlp/v2/model/google_privacy_dlp_v2_storage_config.ex @@ -25,7 +25,7 @@ defmodule GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2StorageConfig do * `cloudStorageOptions` (*type:* `GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2CloudStorageOptions.t`, *default:* `nil`) - Cloud Storage options. * `datastoreOptions` (*type:* `GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2DatastoreOptions.t`, *default:* `nil`) - Google Cloud Datastore options. * `hybridOptions` (*type:* `GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2HybridOptions.t`, *default:* `nil`) - Hybrid inspection options. - * `timespanConfig` (*type:* `GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2TimespanConfig.t`, *default:* `nil`) - + * `timespanConfig` (*type:* `GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2TimespanConfig.t`, *default:* `nil`) - Configuration of the timespan of the items to include in scanning. """ use GoogleApi.Gax.ModelBase diff --git a/clients/dlp/lib/google_api/dlp/v2/model/google_privacy_dlp_v2_storage_metadata_label.ex b/clients/dlp/lib/google_api/dlp/v2/model/google_privacy_dlp_v2_storage_metadata_label.ex index 295f8ae6f7..617c332ba5 100644 --- a/clients/dlp/lib/google_api/dlp/v2/model/google_privacy_dlp_v2_storage_metadata_label.ex +++ b/clients/dlp/lib/google_api/dlp/v2/model/google_privacy_dlp_v2_storage_metadata_label.ex @@ -21,7 +21,7 @@ defmodule GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2StorageMetadataLabel do ## Attributes - * `key` (*type:* `String.t`, *default:* `nil`) - + * `key` (*type:* `String.t`, *default:* `nil`) - Label name. """ use GoogleApi.Gax.ModelBase diff --git a/clients/dlp/lib/google_api/dlp/v2/model/google_privacy_dlp_v2_stored_info_type_config.ex b/clients/dlp/lib/google_api/dlp/v2/model/google_privacy_dlp_v2_stored_info_type_config.ex index 0ae997b5f8..a5a700a69c 100644 --- a/clients/dlp/lib/google_api/dlp/v2/model/google_privacy_dlp_v2_stored_info_type_config.ex +++ b/clients/dlp/lib/google_api/dlp/v2/model/google_privacy_dlp_v2_stored_info_type_config.ex @@ -17,7 +17,7 @@ defmodule GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2StoredInfoTypeConfig do @moduledoc """ - Configuration for stored infoTypes. All fields and subfield are provided by the user. For more information, see https://cloud.google.com/dlp/docs/creating-custom-infotypes. + Configuration for stored infoTypes. All fields and subfield are provided by the user. For more information, see https://cloud.google.com/sensitive-data-protection/docs/creating-custom-infotypes. ## Attributes diff --git a/clients/dlp/lib/google_api/dlp/v2/model/google_privacy_dlp_v2_surrogate_type.ex b/clients/dlp/lib/google_api/dlp/v2/model/google_privacy_dlp_v2_surrogate_type.ex index c3e1cab4dc..2e883bc753 100644 --- a/clients/dlp/lib/google_api/dlp/v2/model/google_privacy_dlp_v2_surrogate_type.ex +++ b/clients/dlp/lib/google_api/dlp/v2/model/google_privacy_dlp_v2_surrogate_type.ex @@ -17,7 +17,7 @@ defmodule GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2SurrogateType do @moduledoc """ - Message for detecting output from deidentification transformations such as [`CryptoReplaceFfxFpeConfig`](https://cloud.google.com/dlp/docs/reference/rest/v2/organizations.deidentifyTemplates#cryptoreplaceffxfpeconfig). These types of transformations are those that perform pseudonymization, thereby producing a "surrogate" as output. This should be used in conjunction with a field on the transformation such as `surrogate_info_type`. This CustomInfoType does not support the use of `detection_rules`. + Message for detecting output from deidentification transformations such as [`CryptoReplaceFfxFpeConfig`](https://cloud.google.com/sensitive-data-protection/docs/reference/rest/v2/organizations.deidentifyTemplates#cryptoreplaceffxfpeconfig). These types of transformations are those that perform pseudonymization, thereby producing a "surrogate" as output. This should be used in conjunction with a field on the transformation such as `surrogate_info_type`. This CustomInfoType does not support the use of `detection_rules`. ## Attributes diff --git a/clients/dlp/lib/google_api/dlp/v2/model/google_privacy_dlp_v2_table.ex b/clients/dlp/lib/google_api/dlp/v2/model/google_privacy_dlp_v2_table.ex index 39ed6bd894..ce200cfb40 100644 --- a/clients/dlp/lib/google_api/dlp/v2/model/google_privacy_dlp_v2_table.ex +++ b/clients/dlp/lib/google_api/dlp/v2/model/google_privacy_dlp_v2_table.ex @@ -17,7 +17,7 @@ defmodule GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2Table do @moduledoc """ - Structured content to inspect. Up to 50,000 `Value`s per request allowed. See https://cloud.google.com/dlp/docs/inspecting-structured-text#inspecting_a_table to learn more. + Structured content to inspect. Up to 50,000 `Value`s per request allowed. See https://cloud.google.com/sensitive-data-protection/docs/inspecting-structured-text#inspecting_a_table to learn more. ## Attributes diff --git a/clients/dlp/lib/google_api/dlp/v2/model/google_privacy_dlp_v2_table_data_profile.ex b/clients/dlp/lib/google_api/dlp/v2/model/google_privacy_dlp_v2_table_data_profile.ex index 1811324e1d..0addf0a451 100644 --- a/clients/dlp/lib/google_api/dlp/v2/model/google_privacy_dlp_v2_table_data_profile.ex +++ b/clients/dlp/lib/google_api/dlp/v2/model/google_privacy_dlp_v2_table_data_profile.ex @@ -24,13 +24,14 @@ defmodule GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2TableDataProfile do * `configSnapshot` (*type:* `GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2DataProfileConfigSnapshot.t`, *default:* `nil`) - The snapshot of the configurations used to generate the profile. * `createTime` (*type:* `DateTime.t`, *default:* `nil`) - The time at which the table was created. * `dataRiskLevel` (*type:* `GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2DataRiskLevel.t`, *default:* `nil`) - The data risk level of this table. - * `datasetId` (*type:* `String.t`, *default:* `nil`) - The BigQuery dataset ID. - * `datasetLocation` (*type:* `String.t`, *default:* `nil`) - The BigQuery location where the dataset's data is stored. See https://cloud.google.com/bigquery/docs/locations for supported locations. - * `datasetProjectId` (*type:* `String.t`, *default:* `nil`) - The GCP project ID that owns the BigQuery dataset. + * `dataSourceType` (*type:* `GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2DataSourceType.t`, *default:* `nil`) - The resource type that was profiled. + * `datasetId` (*type:* `String.t`, *default:* `nil`) - If the resource is BigQuery, the dataset ID. + * `datasetLocation` (*type:* `String.t`, *default:* `nil`) - If supported, the location where the dataset's data is stored. See https://cloud.google.com/bigquery/docs/locations for supported locations. + * `datasetProjectId` (*type:* `String.t`, *default:* `nil`) - The Google Cloud project ID that owns the resource. * `encryptionStatus` (*type:* `String.t`, *default:* `nil`) - How the table is encrypted. * `expirationTime` (*type:* `DateTime.t`, *default:* `nil`) - Optional. The time when this table expires. * `failedColumnCount` (*type:* `String.t`, *default:* `nil`) - The number of columns skipped in the table because of an error. - * `fullResource` (*type:* `String.t`, *default:* `nil`) - The resource name of the table. https://cloud.google.com/apis/design/resource_names#full_resource_name + * `fullResource` (*type:* `String.t`, *default:* `nil`) - The resource name of the resource profiled. https://cloud.google.com/apis/design/resource_names#full_resource_name * `lastModifiedTime` (*type:* `DateTime.t`, *default:* `nil`) - The time when this table was last modified * `name` (*type:* `String.t`, *default:* `nil`) - The name of the profile. * `otherInfoTypes` (*type:* `list(GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2OtherInfoTypeSummary.t)`, *default:* `nil`) - Other infoTypes found in this table's data. @@ -44,7 +45,7 @@ defmodule GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2TableDataProfile do * `scannedColumnCount` (*type:* `String.t`, *default:* `nil`) - The number of columns profiled in the table. * `sensitivityScore` (*type:* `GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2SensitivityScore.t`, *default:* `nil`) - The sensitivity score of this table. * `state` (*type:* `String.t`, *default:* `nil`) - State of a profile. - * `tableId` (*type:* `String.t`, *default:* `nil`) - The BigQuery table ID. + * `tableId` (*type:* `String.t`, *default:* `nil`) - If the resource is BigQuery, the BigQuery table ID. * `tableSizeBytes` (*type:* `String.t`, *default:* `nil`) - The size of the table when the profile was generated. """ @@ -55,6 +56,7 @@ defmodule GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2TableDataProfile do GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2DataProfileConfigSnapshot.t() | nil, :createTime => DateTime.t() | nil, :dataRiskLevel => GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2DataRiskLevel.t() | nil, + :dataSourceType => GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2DataSourceType.t() | nil, :datasetId => String.t() | nil, :datasetLocation => String.t() | nil, :datasetProjectId => String.t() | nil, @@ -85,6 +87,7 @@ defmodule GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2TableDataProfile do field(:configSnapshot, as: GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2DataProfileConfigSnapshot) field(:createTime, as: DateTime) field(:dataRiskLevel, as: GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2DataRiskLevel) + field(:dataSourceType, as: GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2DataSourceType) field(:datasetId) field(:datasetLocation) field(:datasetProjectId) diff --git a/clients/dlp/lib/google_api/dlp/v2/model/google_privacy_dlp_v2_timespan_config.ex b/clients/dlp/lib/google_api/dlp/v2/model/google_privacy_dlp_v2_timespan_config.ex index ea0853ce63..6a923826a8 100644 --- a/clients/dlp/lib/google_api/dlp/v2/model/google_privacy_dlp_v2_timespan_config.ex +++ b/clients/dlp/lib/google_api/dlp/v2/model/google_privacy_dlp_v2_timespan_config.ex @@ -24,7 +24,7 @@ defmodule GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2TimespanConfig do * `enableAutoPopulationOfTimespanConfig` (*type:* `boolean()`, *default:* `nil`) - When the job is started by a JobTrigger we will automatically figure out a valid start_time to avoid scanning files that have not been modified since the last time the JobTrigger executed. This will be based on the time of the execution of the last run of the JobTrigger or the timespan end_time used in the last run of the JobTrigger. * `endTime` (*type:* `DateTime.t`, *default:* `nil`) - Exclude files, tables, or rows newer than this value. If not set, no upper time limit is applied. * `startTime` (*type:* `DateTime.t`, *default:* `nil`) - Exclude files, tables, or rows older than this value. If not set, no lower time limit is applied. - * `timestampField` (*type:* `GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2FieldId.t`, *default:* `nil`) - Specification of the field containing the timestamp of scanned items. Used for data sources like Datastore and BigQuery. *For BigQuery* If this value is not specified and the table was modified between the given start and end times, the entire table will be scanned. If this value is specified, then rows are filtered based on the given start and end times. Rows with a `NULL` value in the provided BigQuery column are skipped. Valid data types of the provided BigQuery column are: `INTEGER`, `DATE`, `TIMESTAMP`, and `DATETIME`. If your BigQuery table is [partitioned at ingestion time](https://cloud.google.com/bigquery/docs/partitioned-tables#ingestion_time), you can use any of the following pseudo-columns as your timestamp field. When used with Cloud DLP, these pseudo-column names are case sensitive. - _PARTITIONTIME - _PARTITIONDATE - _PARTITION_LOAD_TIME *For Datastore* If this value is specified, then entities are filtered based on the given start and end times. If an entity does not contain the provided timestamp property or contains empty or invalid values, then it is included. Valid data types of the provided timestamp property are: `TIMESTAMP`. See the [known issue](https://cloud.google.com/dlp/docs/known-issues#bq-timespan) related to this operation. + * `timestampField` (*type:* `GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2FieldId.t`, *default:* `nil`) - Specification of the field containing the timestamp of scanned items. Used for data sources like Datastore and BigQuery. *For BigQuery* If this value is not specified and the table was modified between the given start and end times, the entire table will be scanned. If this value is specified, then rows are filtered based on the given start and end times. Rows with a `NULL` value in the provided BigQuery column are skipped. Valid data types of the provided BigQuery column are: `INTEGER`, `DATE`, `TIMESTAMP`, and `DATETIME`. If your BigQuery table is [partitioned at ingestion time](https://cloud.google.com/bigquery/docs/partitioned-tables#ingestion_time), you can use any of the following pseudo-columns as your timestamp field. When used with Cloud DLP, these pseudo-column names are case sensitive. - _PARTITIONTIME - _PARTITIONDATE - _PARTITION_LOAD_TIME *For Datastore* If this value is specified, then entities are filtered based on the given start and end times. If an entity does not contain the provided timestamp property or contains empty or invalid values, then it is included. Valid data types of the provided timestamp property are: `TIMESTAMP`. See the [known issue](https://cloud.google.com/sensitive-data-protection/docs/known-issues#bq-timespan) related to this operation. """ use GoogleApi.Gax.ModelBase diff --git a/clients/dlp/lib/google_api/dlp/v2/model/google_privacy_dlp_v2_transformation_result_status.ex b/clients/dlp/lib/google_api/dlp/v2/model/google_privacy_dlp_v2_transformation_result_status.ex index fe93a69f53..8db8950cf0 100644 --- a/clients/dlp/lib/google_api/dlp/v2/model/google_privacy_dlp_v2_transformation_result_status.ex +++ b/clients/dlp/lib/google_api/dlp/v2/model/google_privacy_dlp_v2_transformation_result_status.ex @@ -17,7 +17,7 @@ defmodule GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2TransformationResultStatus do @moduledoc """ - + The outcome of a transformation. ## Attributes diff --git a/clients/dlp/lib/google_api/dlp/v2/model/google_privacy_dlp_v2_update_discovery_config_request.ex b/clients/dlp/lib/google_api/dlp/v2/model/google_privacy_dlp_v2_update_discovery_config_request.ex new file mode 100644 index 0000000000..16ee1fa4ad --- /dev/null +++ b/clients/dlp/lib/google_api/dlp/v2/model/google_privacy_dlp_v2_update_discovery_config_request.ex @@ -0,0 +1,49 @@ +# Copyright 2019 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. + +# NOTE: This file is auto generated by the elixir code generator program. +# Do not edit this file manually. + +defmodule GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2UpdateDiscoveryConfigRequest do + @moduledoc """ + Request message for UpdateDiscoveryConfig. + + ## Attributes + + * `discoveryConfig` (*type:* `GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2DiscoveryConfig.t`, *default:* `nil`) - Required. New DiscoveryConfig value. + * `updateMask` (*type:* `String.t`, *default:* `nil`) - Mask to control which fields get updated. + """ + + use GoogleApi.Gax.ModelBase + + @type t :: %__MODULE__{ + :discoveryConfig => GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2DiscoveryConfig.t() | nil, + :updateMask => String.t() | nil + } + + field(:discoveryConfig, as: GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2DiscoveryConfig) + field(:updateMask) +end + +defimpl Poison.Decoder, for: GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2UpdateDiscoveryConfigRequest do + def decode(value, options) do + GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2UpdateDiscoveryConfigRequest.decode(value, options) + end +end + +defimpl Poison.Encoder, for: GoogleApi.DLP.V2.Model.GooglePrivacyDlpV2UpdateDiscoveryConfigRequest do + def encode(value, options) do + GoogleApi.Gax.ModelBase.encode(value, options) + end +end diff --git a/clients/dlp/mix.exs b/clients/dlp/mix.exs index a4efda4dc8..731005c29d 100644 --- a/clients/dlp/mix.exs +++ b/clients/dlp/mix.exs @@ -48,7 +48,7 @@ defmodule GoogleApi.DLP.Mixfile do defp description() do """ - Cloud Data Loss Prevention (DLP) API client library. Provides methods for detection, risk analysis, and de-identification of privacy-sensitive fragments in text, images, and Google Cloud Platform storage repositories. + Sensitive Data Protection (DLP) client library. Discover and protect your sensitive data. A fully managed service designed to help you discover, classify, and protect your valuable data assets with ease. """ end @@ -59,7 +59,7 @@ defmodule GoogleApi.DLP.Mixfile do licenses: ["Apache 2.0"], links: %{ "GitHub" => "https://github.com/googleapis/elixir-google-api/tree/master/clients/dlp", - "Homepage" => "https://cloud.google.com/dlp/docs/" + "Homepage" => "https://cloud.google.com/sensitive-data-protection/docs/" } ] end