NAME
Google::Cloud::Retail::V2::ImportConfig - Compiled Protocol Buffers messages for google/cloud/retail/v2/import_config.proto
SYNOPSIS
use Google::Cloud::Retail::V2::ImportConfig;
my $msg = Google::Cloud::Retail::V2::ImportConfig::GcsSource->new({
input_uris => $input_uris,
data_schema => $data_schema,
});
# Read or update a field
my $val = $msg->input_uris();
# Binary wire-format roundtrip
my $bytes = $msg->serialize();
my $decoded = Google::Cloud::Retail::V2::ImportConfig::GcsSource->parse($bytes);
# Canonical ProtoJSON
my $json = $msg->to_json();
DESCRIPTION
Auto-generated Protobuf message classes compiled from google/cloud/retail/v2/import_config.proto. All message classes inherit from Protobuf::Message and support new(), serialize(), parse(), to_json(), from_json(), to_text(), and to_perl().
MESSAGES
Google::Cloud::Retail::V2::ImportConfig::GcsSource
Google Cloud Storage location for input content.
Inherits from Protobuf::Message.
Accessors
$msg->input_uris()/$msg->input_uris($value)Type:
StringRequired. Google Cloud Storage URIs to input files. URI can be up to 2000 characters long. URIs can match the full object path (for example, `gs://bucket/directory/object.json`) or a pattern matching one or more files, such as `gs://bucket/directory/*.json`. A request can contain at most 100 files, and each file can be up to 2 GB. See [Importing product information](https://cloud.google.com/retail/recommendations-ai/docs/upload-catalog) for the expected file format and setup instructions.
$msg->data_schema()/$msg->data_schema($value)Type:
StringThe schema to use when parsing the data from the source.
Supported values for product imports:
* `product` (default): One JSON [Product][google.cloud.retail.v2.Product] per line. Each product must have a valid [Product.id][google.cloud.retail.v2.Product.id]. * `product_merchant_center`: See [Importing catalog data from Merchant Center](https://cloud.google.com/retail/recommendations-ai/docs/upload-catalog#mc).
Supported values for user events imports:
* `user_event` (default): One JSON [UserEvent][google.cloud.retail.v2.UserEvent] per line. * `user_event_ga360`: Using https://support.google.com/analytics/answer/3437719.
Supported values for control imports:
* `control` (default): One JSON [Control][google.cloud.retail.v2.Control] per line.
Supported values for catalog attribute imports:
* `catalog_attribute` (default): One CSV [CatalogAttribute][google.cloud.retail.v2.CatalogAttribute] per line.
Google::Cloud::Retail::V2::ImportConfig::BigQuerySource
BigQuery source import data from.
Inherits from Protobuf::Message.
Accessors
$msg->partition_date()/$msg->partition_date($value)Type:
Message(Google::Type::Date::Date)BigQuery time partitioned table's _PARTITIONDATE in YYYY-MM-DD format.
$msg->project_id()/$msg->project_id($value)Type:
StringThe project ID (can be project # or ID) that the BigQuery source is in with a length limit of 128 characters. If not specified, inherits the project ID from the parent request.
$msg->dataset_id()/$msg->dataset_id($value)Type:
StringRequired. The BigQuery data set to copy the data from with a length limit of 1,024 characters.
$msg->table_id()/$msg->table_id($value)Type:
StringRequired. The BigQuery table to copy the data from with a length limit of 1,024 characters.
$msg->gcs_staging_dir()/$msg->gcs_staging_dir($value)Type:
StringIntermediate Cloud Storage directory used for the import with a length limit of 2,000 characters. Can be specified if one wants to have the BigQuery export to a specific Cloud Storage directory.
$msg->data_schema()/$msg->data_schema($value)Type:
StringThe schema to use when parsing the data from the source.
Supported values for product imports:
* `product` (default): One JSON [Product][google.cloud.retail.v2.Product] per line. Each product must have a valid [Product.id][google.cloud.retail.v2.Product.id]. * `product_merchant_center`: See [Importing catalog data from Merchant Center](https://cloud.google.com/retail/recommendations-ai/docs/upload-catalog#mc).
Supported values for user events imports:
* `user_event` (default): One JSON [UserEvent][google.cloud.retail.v2.UserEvent] per line. * `user_event_ga360`: The schema is available here: https://support.google.com/analytics/answer/3437719. * `user_event_ga4`: The schema is available here: https://support.google.com/analytics/answer/7029846.
Supported values for autocomplete imports:
* `suggestions` (default): One JSON completion suggestion per line. * `denylist`: One JSON deny suggestion per line. * `allowlist`: One JSON allow suggestion per line.
Google::Cloud::Retail::V2::ImportConfig::ProductInlineSource
The inline source for the input config for ImportProducts method.
Inherits from Protobuf::Message.
Accessors
$msg->products()/$msg->products($value)Type:
Message(Google::Cloud::Retail::V2::Product::Product)Required. A list of products to update/create. Each product must have a valid [Product.id][google.cloud.retail.v2.Product.id]. Recommended max of 100 items.
Google::Cloud::Retail::V2::ImportConfig::UserEventInlineSource
The inline source for the input config for ImportUserEvents method.
Inherits from Protobuf::Message.
Accessors
$msg->user_events()/$msg->user_events($value)Type:
Message(Google::Cloud::Retail::V2::UserEvent::UserEvent)Required. A list of user events to import. Recommended max of 10k items.
Google::Cloud::Retail::V2::ImportConfig::ImportErrorsConfig
Configuration of destination for Import related errors.
Inherits from Protobuf::Message.
Accessors
$msg->gcs_prefix()/$msg->gcs_prefix($value)Type:
StringGoogle Cloud Storage prefix for import errors. This must be an empty, existing Cloud Storage directory. Import errors are written to sharded files in this directory, one per line, as a JSON-encoded `google.rpc.Status` message.
Google::Cloud::Retail::V2::ImportConfig::ImportProductsRequest
Request message for Import methods.
Inherits from Protobuf::Message.
Accessors
$msg->parent()/$msg->parent($value)Type:
StringRequired. `projects/1234/locations/global/catalogs/default_catalog/branches/default_branch`
If no updateMask is specified, requires products.create permission. If updateMask is specified, requires products.update permission.
$msg->request_id()/$msg->request_id($value)Type:
StringDeprecated. This field has no effect.
$msg->input_config()/$msg->input_config($value)Type:
Message(Google::Cloud::Retail::V2::ImportConfig::ProductInputConfig)Required. The desired input location of the data.
$msg->errors_config()/$msg->errors_config($value)Type:
Message(Google::Cloud::Retail::V2::ImportConfig::ImportErrorsConfig)The desired location of errors incurred during the Import.
$msg->update_mask()/$msg->update_mask($value)Type:
Message(Google::Protobuf::FieldMask::FieldMask)Indicates which fields in the provided imported `products` to update. If not set, all fields are updated. If provided, only the existing product fields are updated. Missing products will not be created.
$msg->reconciliation_mode()/$msg->reconciliation_mode($value)Type:
Enum(Google::Cloud::Retail::V2::ImportProductsRequest::ReconciliationMode)The mode of reconciliation between existing products and the products to be imported. Defaults to [ReconciliationMode.INCREMENTAL][google.cloud.retail.v2.ImportProductsRequest.ReconciliationMode.INCREMENTAL].
$msg->notification_pubsub_topic()/$msg->notification_pubsub_topic($value)Type:
StringFull Pub/Sub topic name for receiving notification. If this field is set, when the import is finished, a notification is sent to specified Pub/Sub topic. The message data is JSON string of a [Operation][google.longrunning.Operation].
Format of the Pub/Sub topic is `projects/{project}/topics/{topic}`. It has to be within the same project as [ImportProductsRequest.parent][google.cloud.retail.v2.ImportProductsRequest.parent]. Make sure that both `cloud-retail-customer-data-access@system.gserviceaccount.com` and `service-<project number>@gcp-sa-retail.iam.gserviceaccount.com` have the `pubsub.topics.publish` IAM permission on the topic.
Only supported when [ImportProductsRequest.reconciliation_mode][google.cloud.retail.v2.ImportProductsRequest.reconciliation_mode] is set to `FULL`.
Enum: ImportProductsRequest::ReconciliationMode
RECONCILIATION_MODE_UNSPECIFIED=>0INCREMENTAL=>1FULL=>2
Google::Cloud::Retail::V2::ImportConfig::ImportUserEventsRequest
Request message for the ImportUserEvents request.
Inherits from Protobuf::Message.
Accessors
$msg->parent()/$msg->parent($value)Type:
StringRequired. `projects/1234/locations/global/catalogs/default_catalog`
$msg->input_config()/$msg->input_config($value)Type:
Message(Google::Cloud::Retail::V2::ImportConfig::UserEventInputConfig)Required. The desired input location of the data.
$msg->errors_config()/$msg->errors_config($value)Type:
Message(Google::Cloud::Retail::V2::ImportConfig::ImportErrorsConfig)The desired location of errors incurred during the Import. Cannot be set for inline user event imports.
Google::Cloud::Retail::V2::ImportConfig::ImportCompletionDataRequest
Request message for ImportCompletionData methods.
Inherits from Protobuf::Message.
Accessors
$msg->parent()/$msg->parent($value)Type:
StringRequired. The catalog which the suggestions dataset belongs to.
Format: `projects/1234/locations/global/catalogs/default_catalog`.
$msg->input_config()/$msg->input_config($value)Type:
Message(Google::Cloud::Retail::V2::ImportConfig::CompletionDataInputConfig)Required. The desired input location of the data.
$msg->notification_pubsub_topic()/$msg->notification_pubsub_topic($value)Type:
StringPub/Sub topic for receiving notification. If this field is set, when the import is finished, a notification is sent to specified Pub/Sub topic. The message data is JSON string of a [Operation][google.longrunning.Operation]. Format of the Pub/Sub topic is `projects/{project}/topics/{topic}`.
Google::Cloud::Retail::V2::ImportConfig::ProductInputConfig
The input config source for products.
Inherits from Protobuf::Message.
Accessors
$msg->product_inline_source()/$msg->product_inline_source($value)Type:
Message(Google::Cloud::Retail::V2::ImportConfig::ProductInlineSource)The Inline source for the input content for products.
$msg->gcs_source()/$msg->gcs_source($value)Type:
Message(Google::Cloud::Retail::V2::ImportConfig::GcsSource)Google Cloud Storage location for the input content.
$msg->big_query_source()/$msg->big_query_source($value)Type:
Message(Google::Cloud::Retail::V2::ImportConfig::BigQuerySource)BigQuery input source.
Google::Cloud::Retail::V2::ImportConfig::UserEventInputConfig
The input config source for user events.
Inherits from Protobuf::Message.
Accessors
$msg->user_event_inline_source()/$msg->user_event_inline_source($value)Type:
Message(Google::Cloud::Retail::V2::ImportConfig::UserEventInlineSource)Required. The Inline source for the input content for UserEvents.
$msg->gcs_source()/$msg->gcs_source($value)Type:
Message(Google::Cloud::Retail::V2::ImportConfig::GcsSource)Required. Google Cloud Storage location for the input content.
$msg->big_query_source()/$msg->big_query_source($value)Type:
Message(Google::Cloud::Retail::V2::ImportConfig::BigQuerySource)Required. BigQuery input source.
Google::Cloud::Retail::V2::ImportConfig::CompletionDataInputConfig
The input config source for completion data.
Inherits from Protobuf::Message.
Accessors
$msg->big_query_source()/$msg->big_query_source($value)Type:
Message(Google::Cloud::Retail::V2::ImportConfig::BigQuerySource)Required. BigQuery input source.
Add the IAM permission "BigQuery Data Viewer" for cloud-retail-customer-data-access@system.gserviceaccount.com before using this feature otherwise an error is thrown.
Google::Cloud::Retail::V2::ImportConfig::ImportMetadata
Metadata related to the progress of the Import operation. This is returned by the google.longrunning.Operation.metadata field.
Inherits from Protobuf::Message.
Accessors
$msg->create_time()/$msg->create_time($value)Type:
Message(Google::Protobuf::Timestamp::Timestamp)Operation create time.
$msg->update_time()/$msg->update_time($value)Type:
Message(Google::Protobuf::Timestamp::Timestamp)Operation last update time. If the operation is done, this is also the finish time.
$msg->success_count()/$msg->success_count($value)Type:
Int64Count of entries that were processed successfully.
$msg->failure_count()/$msg->failure_count($value)Type:
Int64Count of entries that encountered errors while processing.
$msg->request_id()/$msg->request_id($value)Type:
StringDeprecated. This field is never set.
$msg->notification_pubsub_topic()/$msg->notification_pubsub_topic($value)Type:
StringPub/Sub topic for receiving notification. If this field is set, when the import is finished, a notification is sent to specified Pub/Sub topic. The message data is JSON string of a [Operation][google.longrunning.Operation]. Format of the Pub/Sub topic is `projects/{project}/topics/{topic}`.
Google::Cloud::Retail::V2::ImportConfig::ImportProductsResponse
Response of the [ImportProductsRequest][google.cloud.retail.v2.ImportProductsRequest]. If the long running operation is done, then this message is returned by the google.longrunning.Operations.response field if the operation was successful.
Inherits from Protobuf::Message.
Accessors
$msg->error_samples()/$msg->error_samples($value)Type:
Message(Google::Rpc::Status::Status)A sample of errors encountered while processing the request.
$msg->errors_config()/$msg->errors_config($value)Type:
Message(Google::Cloud::Retail::V2::ImportConfig::ImportErrorsConfig)Echoes the destination for the complete errors in the request if set.
Google::Cloud::Retail::V2::ImportConfig::ImportUserEventsResponse
Response of the ImportUserEventsRequest. If the long running operation was successful, then this message is returned by the google.longrunning.Operations.response field if the operation was successful.
Inherits from Protobuf::Message.
Accessors
$msg->error_samples()/$msg->error_samples($value)Type:
Message(Google::Rpc::Status::Status)A sample of errors encountered while processing the request.
$msg->errors_config()/$msg->errors_config($value)Type:
Message(Google::Cloud::Retail::V2::ImportConfig::ImportErrorsConfig)Echoes the destination for the complete errors if this field was set in the request.
$msg->import_summary()/$msg->import_summary($value)Type:
Message(Google::Cloud::Retail::V2::ImportConfig::UserEventImportSummary)Aggregated statistics of user event import status.
Google::Cloud::Retail::V2::ImportConfig::UserEventImportSummary
A summary of import result. The UserEventImportSummary summarizes the import status for user events.
Inherits from Protobuf::Message.
Accessors
$msg->joined_events_count()/$msg->joined_events_count($value)Type:
Int64Count of user events imported with complete existing catalog information.
$msg->unjoined_events_count()/$msg->unjoined_events_count($value)Type:
Int64Count of user events imported, but with catalog information not found in the imported catalog.
Google::Cloud::Retail::V2::ImportConfig::ImportCompletionDataResponse
Response of the [ImportCompletionDataRequest][google.cloud.retail.v2.ImportCompletionDataRequest]. If the long running operation is done, this message is returned by the google.longrunning.Operations.response field if the operation is successful.
Inherits from Protobuf::Message.
Accessors
$msg->error_samples()/$msg->error_samples($value)Type:
Message(Google::Rpc::Status::Status)A sample of errors encountered while processing the request.
SEE ALSO
Protobuf, Protobuf::Message, Google::Cloud::Retail::V2::ImportConfig::Types, https://protobuf.dev/
LICENSE AND COPYRIGHT
Copyright (C) 2026 Google LLC
This program is released under the Apache 2.0 license.