diff --git a/aiplatform/v1/aiplatform-api.json b/aiplatform/v1/aiplatform-api.json index 89d4cd10ae6..67bdf579788 100644 --- a/aiplatform/v1/aiplatform-api.json +++ b/aiplatform/v1/aiplatform-api.json @@ -2067,6 +2067,171 @@ } } }, + "datasetVersions": { + "methods": { + "create": { + "description": "Create a version from a Dataset.", + "flatPath": "v1/projects/{projectsId}/locations/{locationsId}/datasets/{datasetsId}/datasetVersions", + "httpMethod": "POST", + "id": "aiplatform.projects.locations.datasets.datasetVersions.create", + "parameterOrder": [ + "parent" + ], + "parameters": { + "parent": { + "description": "Required. The name of the Dataset resource. Format: `projects/{project}/locations/{location}/datasets/{dataset}`", + "location": "path", + "pattern": "^projects/[^/]+/locations/[^/]+/datasets/[^/]+$", + "required": true, + "type": "string" + } + }, + "path": "v1/{+parent}/datasetVersions", + "request": { + "$ref": "GoogleCloudAiplatformV1DatasetVersion" + }, + "response": { + "$ref": "GoogleLongrunningOperation" + }, + "scopes": [ + "https://www.googleapis.com/auth/cloud-platform" + ] + }, + "delete": { + "description": "Deletes a Dataset version.", + "flatPath": "v1/projects/{projectsId}/locations/{locationsId}/datasets/{datasetsId}/datasetVersions/{datasetVersionsId}", + "httpMethod": "DELETE", + "id": "aiplatform.projects.locations.datasets.datasetVersions.delete", + "parameterOrder": [ + "name" + ], + "parameters": { + "name": { + "description": "Required. The resource name of the Dataset version to delete. Format: `projects/{project}/locations/{location}/datasets/{dataset}/datasetVersions/{dataset_version}`", + "location": "path", + "pattern": "^projects/[^/]+/locations/[^/]+/datasets/[^/]+/datasetVersions/[^/]+$", + "required": true, + "type": "string" + } + }, + "path": "v1/{+name}", + "response": { + "$ref": "GoogleLongrunningOperation" + }, + "scopes": [ + "https://www.googleapis.com/auth/cloud-platform" + ] + }, + "get": { + "description": "Gets a Dataset version.", + "flatPath": "v1/projects/{projectsId}/locations/{locationsId}/datasets/{datasetsId}/datasetVersions/{datasetVersionsId}", + "httpMethod": "GET", + "id": "aiplatform.projects.locations.datasets.datasetVersions.get", + "parameterOrder": [ + "name" + ], + "parameters": { + "name": { + "description": "Required. The resource name of the Dataset version to delete. Format: `projects/{project}/locations/{location}/datasets/{dataset}/datasetVersions/{dataset_version}`", + "location": "path", + "pattern": "^projects/[^/]+/locations/[^/]+/datasets/[^/]+/datasetVersions/[^/]+$", + "required": true, + "type": "string" + }, + "readMask": { + "description": "Mask specifying which fields to read.", + "format": "google-fieldmask", + "location": "query", + "type": "string" + } + }, + "path": "v1/{+name}", + "response": { + "$ref": "GoogleCloudAiplatformV1DatasetVersion" + }, + "scopes": [ + "https://www.googleapis.com/auth/cloud-platform" + ] + }, + "list": { + "description": "Lists DatasetVersions in a Dataset.", + "flatPath": "v1/projects/{projectsId}/locations/{locationsId}/datasets/{datasetsId}/datasetVersions", + "httpMethod": "GET", + "id": "aiplatform.projects.locations.datasets.datasetVersions.list", + "parameterOrder": [ + "parent" + ], + "parameters": { + "filter": { + "description": "Optional. The standard list filter.", + "location": "query", + "type": "string" + }, + "orderBy": { + "description": "Optional. A comma-separated list of fields to order by, sorted in ascending order. Use \"desc\" after a field name for descending.", + "location": "query", + "type": "string" + }, + "pageSize": { + "description": "Optional. The standard list page size.", + "format": "int32", + "location": "query", + "type": "integer" + }, + "pageToken": { + "description": "Optional. The standard list page token.", + "location": "query", + "type": "string" + }, + "parent": { + "description": "Required. The resource name of the Dataset to list DatasetVersions from. Format: `projects/{project}/locations/{location}/datasets/{dataset}`", + "location": "path", + "pattern": "^projects/[^/]+/locations/[^/]+/datasets/[^/]+$", + "required": true, + "type": "string" + }, + "readMask": { + "description": "Optional. Mask specifying which fields to read.", + "format": "google-fieldmask", + "location": "query", + "type": "string" + } + }, + "path": "v1/{+parent}/datasetVersions", + "response": { + "$ref": "GoogleCloudAiplatformV1ListDatasetVersionsResponse" + }, + "scopes": [ + "https://www.googleapis.com/auth/cloud-platform" + ] + }, + "restore": { + "description": "Restores a dataset version.", + "flatPath": "v1/projects/{projectsId}/locations/{locationsId}/datasets/{datasetsId}/datasetVersions/{datasetVersionsId}:restore", + "httpMethod": "GET", + "id": "aiplatform.projects.locations.datasets.datasetVersions.restore", + "parameterOrder": [ + "name" + ], + "parameters": { + "name": { + "description": "Required. The name of the DatasetVersion resource. Format: `projects/{project}/locations/{location}/datasets/{dataset}/datasetVersions/{dataset_version}`", + "location": "path", + "pattern": "^projects/[^/]+/locations/[^/]+/datasets/[^/]+/datasetVersions/[^/]+$", + "required": true, + "type": "string" + } + }, + "path": "v1/{+name}:restore", + "response": { + "$ref": "GoogleLongrunningOperation" + }, + "scopes": [ + "https://www.googleapis.com/auth/cloud-platform" + ] + } + } + }, "operations": { "methods": { "cancel": { @@ -14838,6 +15003,39 @@ }, "type": "object" }, + "GoogleCloudAiplatformV1DatasetVersion": { + "description": "Describes the dataset version.", + "id": "GoogleCloudAiplatformV1DatasetVersion", + "properties": { + "bigQueryDatasetName": { + "description": "Output only. Name of the associated BigQuery dataset.", + "readOnly": true, + "type": "string" + }, + "createTime": { + "description": "Output only. Timestamp when this DatasetVersion was created.", + "format": "google-datetime", + "readOnly": true, + "type": "string" + }, + "etag": { + "description": "Used to perform consistent read-modify-write updates. If not set, a blind \"overwrite\" update happens.", + "type": "string" + }, + "name": { + "description": "Output only. The resource name of the DatasetVersion.", + "readOnly": true, + "type": "string" + }, + "updateTime": { + "description": "Output only. Timestamp when this DatasetVersion was last updated.", + "format": "google-datetime", + "readOnly": true, + "type": "string" + } + }, + "type": "object" + }, "GoogleCloudAiplatformV1DedicatedResources": { "description": "A description of resources that are dedicated to a DeployedModel, and that need a higher degree of manual configuration.", "id": "GoogleCloudAiplatformV1DedicatedResources", @@ -16270,6 +16468,10 @@ "description": "An expression for filtering what part of the Dataset is to be exported. Only Annotations that match this filter will be exported. The filter syntax is the same as in ListAnnotations.", "type": "string" }, + "filterSplit": { + "$ref": "GoogleCloudAiplatformV1ExportFilterSplit", + "description": "Split based on the provided filters for each set." + }, "fractionSplit": { "$ref": "GoogleCloudAiplatformV1ExportFractionSplit", "description": "Split based on fractions defining the size of each set." @@ -16402,6 +16604,25 @@ "properties": {}, "type": "object" }, + "GoogleCloudAiplatformV1ExportFilterSplit": { + "description": "Assigns input data to training, validation, and test sets based on the given filters, data pieces not matched by any filter are ignored. Currently only supported for Datasets containing DataItems. If any of the filters in this message are to match nothing, then they can be set as '-' (the minus sign). Supported only for unstructured Datasets.", + "id": "GoogleCloudAiplatformV1ExportFilterSplit", + "properties": { + "testFilter": { + "description": "Required. A filter on DataItems of the Dataset. DataItems that match this filter are used to test the Model. A filter with same syntax as the one used in DatasetService.ListDataItems may be used. If a single DataItem is matched by more than one of the FilterSplit filters, then it is assigned to the first set that applies to it in the training, validation, test order.", + "type": "string" + }, + "trainingFilter": { + "description": "Required. A filter on DataItems of the Dataset. DataItems that match this filter are used to train the Model. A filter with same syntax as the one used in DatasetService.ListDataItems may be used. If a single DataItem is matched by more than one of the FilterSplit filters, then it is assigned to the first set that applies to it in the training, validation, test order.", + "type": "string" + }, + "validationFilter": { + "description": "Required. A filter on DataItems of the Dataset. DataItems that match this filter are used to validate the Model. A filter with same syntax as the one used in DatasetService.ListDataItems may be used. If a single DataItem is matched by more than one of the FilterSplit filters, then it is assigned to the first set that applies to it in the training, validation, test order.", + "type": "string" + } + }, + "type": "object" + }, "GoogleCloudAiplatformV1ExportFractionSplit": { "description": "Assigns the input data to training, validation, and test sets as per the given fractions. Any of `training_fraction`, `validation_fraction` and `test_fraction` may optionally be provided, they must sum to up to 1. If the provided ones sum to less than 1, the remainder is assigned to sets as decided by Vertex AI. If none of the fractions are set, by default roughly 80% of data is used for training, 10% for validation, and 10% for test.", "id": "GoogleCloudAiplatformV1ExportFractionSplit", @@ -18064,6 +18285,24 @@ }, "type": "object" }, + "GoogleCloudAiplatformV1ListDatasetVersionsResponse": { + "description": "Response message for DatasetService.ListDatasetVersions.", + "id": "GoogleCloudAiplatformV1ListDatasetVersionsResponse", + "properties": { + "datasetVersions": { + "description": "A list of DatasetVersions that matches the specified filter in the request.", + "items": { + "$ref": "GoogleCloudAiplatformV1DatasetVersion" + }, + "type": "array" + }, + "nextPageToken": { + "description": "The standard List next-page token.", + "type": "string" + } + }, + "type": "object" + }, "GoogleCloudAiplatformV1ListDatasetsResponse": { "description": "Response message for DatasetService.ListDatasets.", "id": "GoogleCloudAiplatformV1ListDatasetsResponse", @@ -19836,6 +20075,13 @@ "enableLogging": { "description": "Dump the anomalies to Cloud Logging. The anomalies will be put to json payload encoded from proto google.cloud.aiplatform.logging.ModelMonitoringAnomaliesLogEntry. This can be further sinked to Pub/Sub or any other services supported by Cloud Logging.", "type": "boolean" + }, + "notificationChannels": { + "description": "Resource names of the NotificationChannels to send alert. Must be of the format `projects//notificationChannels/`", + "items": { + "type": "string" + }, + "type": "array" } }, "type": "object" @@ -20735,7 +20981,7 @@ "additionalProperties": { "type": "string" }, - "description": "The labels with user-defined metadata to organize your NotebookRuntime. Label keys and values can be no longer than 64 characters (Unicode codepoints), can only contain lowercase letters, numeric characters, underscores and dashes. International characters are allowed. No more than 64 user labels can be associated with one Dataset (System labels are excluded). See https://goo.gl/xmQnxf for more information and examples of labels. System reserved label keys are prefixed with \"aiplatform.googleapis.com/\" and are immutable. Following system labels exist for NotebookRuntime: * \"aiplatform.googleapis.com/notebook_runtime_gce_instance_id\": output only, its value is the Compute Engine instance id. * \"aiplatform.googleapis.com/colab_enterprise_entry_service\": its value is either \"BigQuery\" or \"Vertex\"; if absent, it should be \"Vertex\". This is to describe the entry service, either BigQuery or Vertex.", + "description": "The labels with user-defined metadata to organize your NotebookRuntime. Label keys and values can be no longer than 64 characters (Unicode codepoints), can only contain lowercase letters, numeric characters, underscores and dashes. International characters are allowed. No more than 64 user labels can be associated with one NotebookRuntime (System labels are excluded). See https://goo.gl/xmQnxf for more information and examples of labels. System reserved label keys are prefixed with \"aiplatform.googleapis.com/\" and are immutable. Following system labels exist for NotebookRuntime: * \"aiplatform.googleapis.com/notebook_runtime_gce_instance_id\": output only, its value is the Compute Engine instance id. * \"aiplatform.googleapis.com/colab_enterprise_entry_service\": its value is either \"bigquery\" or \"vertex\"; if absent, it should be \"vertex\". This is to describe the entry service, either BigQuery or Vertex.", "type": "object" }, "name": { @@ -20748,6 +20994,21 @@ "description": "Output only. The pointer to NotebookRuntimeTemplate this NotebookRuntime is created from.", "readOnly": true }, + "notebookRuntimeType": { + "description": "Output only. The type of the notebook runtime.", + "enum": [ + "NOTEBOOK_RUNTIME_TYPE_UNSPECIFIED", + "USER_DEFINED", + "ONE_CLICK" + ], + "enumDescriptions": [ + "Unspecified notebook runtime type, NotebookRuntimeType will default to USER_DEFINED.", + "runtime or template with coustomized configurations from user.", + "runtime or template with system defined configurations." + ], + "readOnly": true, + "type": "string" + }, "proxyUri": { "description": "Output only. The proxy endpoint used to access the NotebookRuntime.", "readOnly": true, @@ -20856,6 +21117,20 @@ "$ref": "GoogleCloudAiplatformV1NetworkSpec", "description": "Optional. Network spec." }, + "notebookRuntimeType": { + "description": "Optional. Immutable. The type of the notebook runtime template.", + "enum": [ + "NOTEBOOK_RUNTIME_TYPE_UNSPECIFIED", + "USER_DEFINED", + "ONE_CLICK" + ], + "enumDescriptions": [ + "Unspecified notebook runtime type, NotebookRuntimeType will default to USER_DEFINED.", + "runtime or template with coustomized configurations from user.", + "runtime or template with system defined configurations." + ], + "type": "string" + }, "serviceAccount": { "description": "The service account that the runtime workload runs as. You can use any service account within the same project, but you must have the service account user permission to use the instance. If not specified, the [Compute Engine default service account](https://cloud.google.com/compute/docs/access/service-accounts#default_service_account) is used.", "type": "string" @@ -21025,7 +21300,7 @@ "readOnly": true }, "templateUri": { - "description": "A template uri from where the PipelineJob.pipeline_spec, if empty, will be downloaded.", + "description": "A template uri from where the PipelineJob.pipeline_spec, if empty, will be downloaded. Currently, only uri from Vertex Template Registry \u0026 Gallery is supported. Reference to https://cloud.google.com/vertex-ai/docs/pipelines/create-pipeline-template.", "type": "string" }, "updateTime": { diff --git a/aiplatform/v1/aiplatform-gen.go b/aiplatform/v1/aiplatform-gen.go index a0533e4d55b..45e2d9d4ab6 100644 --- a/aiplatform/v1/aiplatform-gen.go +++ b/aiplatform/v1/aiplatform-gen.go @@ -315,6 +315,7 @@ func NewProjectsLocationsDatasetsService(s *Service) *ProjectsLocationsDatasetsS rs := &ProjectsLocationsDatasetsService{s: s} rs.AnnotationSpecs = NewProjectsLocationsDatasetsAnnotationSpecsService(s) rs.DataItems = NewProjectsLocationsDatasetsDataItemsService(s) + rs.DatasetVersions = NewProjectsLocationsDatasetsDatasetVersionsService(s) rs.Operations = NewProjectsLocationsDatasetsOperationsService(s) rs.SavedQueries = NewProjectsLocationsDatasetsSavedQueriesService(s) return rs @@ -327,6 +328,8 @@ type ProjectsLocationsDatasetsService struct { DataItems *ProjectsLocationsDatasetsDataItemsService + DatasetVersions *ProjectsLocationsDatasetsDatasetVersionsService + Operations *ProjectsLocationsDatasetsOperationsService SavedQueries *ProjectsLocationsDatasetsSavedQueriesService @@ -398,6 +401,15 @@ type ProjectsLocationsDatasetsDataItemsOperationsService struct { s *Service } +func NewProjectsLocationsDatasetsDatasetVersionsService(s *Service) *ProjectsLocationsDatasetsDatasetVersionsService { + rs := &ProjectsLocationsDatasetsDatasetVersionsService{s: s} + return rs +} + +type ProjectsLocationsDatasetsDatasetVersionsService struct { + s *Service +} + func NewProjectsLocationsDatasetsOperationsService(s *Service) *ProjectsLocationsDatasetsOperationsService { rs := &ProjectsLocationsDatasetsOperationsService{s: s} return rs @@ -4803,6 +4815,55 @@ func (s *GoogleCloudAiplatformV1Dataset) MarshalJSON() ([]byte, error) { return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } +// GoogleCloudAiplatformV1DatasetVersion: Describes the dataset version. +type GoogleCloudAiplatformV1DatasetVersion struct { + // BigQueryDatasetName: Output only. Name of the associated BigQuery + // dataset. + BigQueryDatasetName string `json:"bigQueryDatasetName,omitempty"` + + // CreateTime: Output only. Timestamp when this DatasetVersion was + // created. + CreateTime string `json:"createTime,omitempty"` + + // Etag: Used to perform consistent read-modify-write updates. If not + // set, a blind "overwrite" update happens. + Etag string `json:"etag,omitempty"` + + // Name: Output only. The resource name of the DatasetVersion. + Name string `json:"name,omitempty"` + + // UpdateTime: Output only. Timestamp when this DatasetVersion was last + // updated. + UpdateTime string `json:"updateTime,omitempty"` + + // ServerResponse contains the HTTP response code and headers from the + // server. + googleapi.ServerResponse `json:"-"` + + // ForceSendFields is a list of field names (e.g. "BigQueryDatasetName") + // to unconditionally include in API requests. By default, fields with + // empty or default values are omitted from API requests. However, any + // non-pointer, non-interface field appearing in ForceSendFields will be + // sent to the server regardless of whether the field is empty or not. + // This may be used to include empty fields in Patch requests. + ForceSendFields []string `json:"-"` + + // NullFields is a list of field names (e.g. "BigQueryDatasetName") to + // include in API requests with the JSON null value. By default, fields + // with empty values are omitted from API requests. However, any field + // with an empty value appearing in NullFields will be sent to the + // server as null. It is an error if a field in this list has a + // non-empty value. This may be used to include null fields in Patch + // requests. + NullFields []string `json:"-"` +} + +func (s *GoogleCloudAiplatformV1DatasetVersion) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudAiplatformV1DatasetVersion + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + // GoogleCloudAiplatformV1DedicatedResources: A description of resources // that are dedicated to a DeployedModel, and that need a higher degree // of manual configuration. @@ -7503,6 +7564,9 @@ type GoogleCloudAiplatformV1ExportDataConfig struct { // ListAnnotations. AnnotationsFilter string `json:"annotationsFilter,omitempty"` + // FilterSplit: Split based on the provided filters for each set. + FilterSplit *GoogleCloudAiplatformV1ExportFilterSplit `json:"filterSplit,omitempty"` + // FractionSplit: Split based on fractions defining the size of each // set. FractionSplit *GoogleCloudAiplatformV1ExportFractionSplit `json:"fractionSplit,omitempty"` @@ -7790,6 +7854,62 @@ func (s *GoogleCloudAiplatformV1ExportFeatureValuesRequestSnapshotExport) Marsha type GoogleCloudAiplatformV1ExportFeatureValuesResponse struct { } +// GoogleCloudAiplatformV1ExportFilterSplit: Assigns input data to +// training, validation, and test sets based on the given filters, data +// pieces not matched by any filter are ignored. Currently only +// supported for Datasets containing DataItems. If any of the filters in +// this message are to match nothing, then they can be set as '-' (the +// minus sign). Supported only for unstructured Datasets. +type GoogleCloudAiplatformV1ExportFilterSplit struct { + // TestFilter: Required. A filter on DataItems of the Dataset. DataItems + // that match this filter are used to test the Model. A filter with same + // syntax as the one used in DatasetService.ListDataItems may be used. + // If a single DataItem is matched by more than one of the FilterSplit + // filters, then it is assigned to the first set that applies to it in + // the training, validation, test order. + TestFilter string `json:"testFilter,omitempty"` + + // TrainingFilter: Required. A filter on DataItems of the Dataset. + // DataItems that match this filter are used to train the Model. A + // filter with same syntax as the one used in + // DatasetService.ListDataItems may be used. If a single DataItem is + // matched by more than one of the FilterSplit filters, then it is + // assigned to the first set that applies to it in the training, + // validation, test order. + TrainingFilter string `json:"trainingFilter,omitempty"` + + // ValidationFilter: Required. A filter on DataItems of the Dataset. + // DataItems that match this filter are used to validate the Model. A + // filter with same syntax as the one used in + // DatasetService.ListDataItems may be used. If a single DataItem is + // matched by more than one of the FilterSplit filters, then it is + // assigned to the first set that applies to it in the training, + // validation, test order. + ValidationFilter string `json:"validationFilter,omitempty"` + + // ForceSendFields is a list of field names (e.g. "TestFilter") to + // unconditionally include in API requests. By default, fields with + // empty or default values are omitted from API requests. However, any + // non-pointer, non-interface field appearing in ForceSendFields will be + // sent to the server regardless of whether the field is empty or not. + // This may be used to include empty fields in Patch requests. + ForceSendFields []string `json:"-"` + + // NullFields is a list of field names (e.g. "TestFilter") to include in + // API requests with the JSON null value. By default, fields with empty + // values are omitted from API requests. However, any field with an + // empty value appearing in NullFields will be sent to the server as + // null. It is an error if a field in this list has a non-empty value. + // This may be used to include null fields in Patch requests. + NullFields []string `json:"-"` +} + +func (s *GoogleCloudAiplatformV1ExportFilterSplit) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudAiplatformV1ExportFilterSplit + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + // GoogleCloudAiplatformV1ExportFractionSplit: Assigns the input data to // training, validation, and test sets as per the given fractions. Any // of `training_fraction`, `validation_fraction` and `test_fraction` may @@ -10931,6 +11051,44 @@ func (s *GoogleCloudAiplatformV1ListDataLabelingJobsResponse) MarshalJSON() ([]b return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } +// GoogleCloudAiplatformV1ListDatasetVersionsResponse: Response message +// for DatasetService.ListDatasetVersions. +type GoogleCloudAiplatformV1ListDatasetVersionsResponse struct { + // DatasetVersions: A list of DatasetVersions that matches the specified + // filter in the request. + DatasetVersions []*GoogleCloudAiplatformV1DatasetVersion `json:"datasetVersions,omitempty"` + + // NextPageToken: The standard List next-page token. + NextPageToken string `json:"nextPageToken,omitempty"` + + // ServerResponse contains the HTTP response code and headers from the + // server. + googleapi.ServerResponse `json:"-"` + + // ForceSendFields is a list of field names (e.g. "DatasetVersions") to + // unconditionally include in API requests. By default, fields with + // empty or default values are omitted from API requests. However, any + // non-pointer, non-interface field appearing in ForceSendFields will be + // sent to the server regardless of whether the field is empty or not. + // This may be used to include empty fields in Patch requests. + ForceSendFields []string `json:"-"` + + // NullFields is a list of field names (e.g. "DatasetVersions") to + // include in API requests with the JSON null value. By default, fields + // with empty values are omitted from API requests. However, any field + // with an empty value appearing in NullFields will be sent to the + // server as null. It is an error if a field in this list has a + // non-empty value. This may be used to include null fields in Patch + // requests. + NullFields []string `json:"-"` +} + +func (s *GoogleCloudAiplatformV1ListDatasetVersionsResponse) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudAiplatformV1ListDatasetVersionsResponse + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + // GoogleCloudAiplatformV1ListDatasetsResponse: Response message for // DatasetService.ListDatasets. type GoogleCloudAiplatformV1ListDatasetsResponse struct { @@ -14337,6 +14495,10 @@ type GoogleCloudAiplatformV1ModelMonitoringAlertConfig struct { // by Cloud Logging. EnableLogging bool `json:"enableLogging,omitempty"` + // NotificationChannels: Resource names of the NotificationChannels to + // send alert. Must be of the format `projects//notificationChannels/` + NotificationChannels []string `json:"notificationChannels,omitempty"` + // ForceSendFields is a list of field names (e.g. "EmailAlertConfig") to // unconditionally include in API requests. By default, fields with // empty or default values are omitted from API requests. However, any @@ -15846,14 +16008,15 @@ type GoogleCloudAiplatformV1NotebookRuntime struct { // characters (Unicode codepoints), can only contain lowercase letters, // numeric characters, underscores and dashes. International characters // are allowed. No more than 64 user labels can be associated with one - // Dataset (System labels are excluded). See https://goo.gl/xmQnxf for - // more information and examples of labels. System reserved label keys - // are prefixed with "aiplatform.googleapis.com/" and are immutable. - // Following system labels exist for NotebookRuntime: * + // NotebookRuntime (System labels are excluded). See + // https://goo.gl/xmQnxf for more information and examples of labels. + // System reserved label keys are prefixed with + // "aiplatform.googleapis.com/" and are immutable. Following system + // labels exist for NotebookRuntime: * // "aiplatform.googleapis.com/notebook_runtime_gce_instance_id": output // only, its value is the Compute Engine instance id. * // "aiplatform.googleapis.com/colab_enterprise_entry_service": its value - // is either "BigQuery" or "Vertex"; if absent, it should be "Vertex". + // is either "bigquery" or "vertex"; if absent, it should be "vertex". // This is to describe the entry service, either BigQuery or Vertex. Labels map[string]string `json:"labels,omitempty"` @@ -15864,6 +16027,17 @@ type GoogleCloudAiplatformV1NotebookRuntime struct { // NotebookRuntimeTemplate this NotebookRuntime is created from. NotebookRuntimeTemplateRef *GoogleCloudAiplatformV1NotebookRuntimeTemplateRef `json:"notebookRuntimeTemplateRef,omitempty"` + // NotebookRuntimeType: Output only. The type of the notebook runtime. + // + // Possible values: + // "NOTEBOOK_RUNTIME_TYPE_UNSPECIFIED" - Unspecified notebook runtime + // type, NotebookRuntimeType will default to USER_DEFINED. + // "USER_DEFINED" - runtime or template with coustomized + // configurations from user. + // "ONE_CLICK" - runtime or template with system defined + // configurations. + NotebookRuntimeType string `json:"notebookRuntimeType,omitempty"` + // ProxyUri: Output only. The proxy endpoint used to access the // NotebookRuntime. ProxyUri string `json:"proxyUri,omitempty"` @@ -15976,6 +16150,18 @@ type GoogleCloudAiplatformV1NotebookRuntimeTemplate struct { // NetworkSpec: Optional. Network spec. NetworkSpec *GoogleCloudAiplatformV1NetworkSpec `json:"networkSpec,omitempty"` + // NotebookRuntimeType: Optional. Immutable. The type of the notebook + // runtime template. + // + // Possible values: + // "NOTEBOOK_RUNTIME_TYPE_UNSPECIFIED" - Unspecified notebook runtime + // type, NotebookRuntimeType will default to USER_DEFINED. + // "USER_DEFINED" - runtime or template with coustomized + // configurations from user. + // "ONE_CLICK" - runtime or template with system defined + // configurations. + NotebookRuntimeType string `json:"notebookRuntimeType,omitempty"` + // ServiceAccount: The service account that the runtime workload runs // as. You can use any service account within the same project, but you // must have the service account user permission to use the instance. If @@ -16200,7 +16386,9 @@ type GoogleCloudAiplatformV1PipelineJob struct { TemplateMetadata *GoogleCloudAiplatformV1PipelineTemplateMetadata `json:"templateMetadata,omitempty"` // TemplateUri: A template uri from where the PipelineJob.pipeline_spec, - // if empty, will be downloaded. + // if empty, will be downloaded. Currently, only uri from Vertex + // Template Registry & Gallery is supported. Reference to + // https://cloud.google.com/vertex-ai/docs/pipelines/create-pipeline-template. TemplateUri string `json:"templateUri,omitempty"` // UpdateTime: Output only. Timestamp when this PipelineJob was most @@ -39115,38 +39303,819 @@ func (c *ProjectsLocationsDatasetsDataItemsAnnotationsOperationsWaitCall) Do(opt } -// method id "aiplatform.projects.locations.datasets.dataItems.operations.cancel": +// method id "aiplatform.projects.locations.datasets.dataItems.operations.cancel": + +type ProjectsLocationsDatasetsDataItemsOperationsCancelCall struct { + s *Service + name string + urlParams_ gensupport.URLParams + ctx_ context.Context + header_ http.Header +} + +// Cancel: Starts asynchronous cancellation on a long-running operation. +// The server makes a best effort to cancel the operation, but success +// is not guaranteed. If the server doesn't support this method, it +// returns `google.rpc.Code.UNIMPLEMENTED`. Clients can use +// Operations.GetOperation or other methods to check whether the +// cancellation succeeded or whether the operation completed despite +// cancellation. On successful cancellation, the operation is not +// deleted; instead, it becomes an operation with an Operation.error +// value with a google.rpc.Status.code of 1, corresponding to +// `Code.CANCELLED`. +// +// - name: The name of the operation resource to be cancelled. +func (r *ProjectsLocationsDatasetsDataItemsOperationsService) Cancel(name string) *ProjectsLocationsDatasetsDataItemsOperationsCancelCall { + c := &ProjectsLocationsDatasetsDataItemsOperationsCancelCall{s: r.s, urlParams_: make(gensupport.URLParams)} + c.name = name + return c +} + +// Fields allows partial responses to be retrieved. See +// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse +// for more information. +func (c *ProjectsLocationsDatasetsDataItemsOperationsCancelCall) Fields(s ...googleapi.Field) *ProjectsLocationsDatasetsDataItemsOperationsCancelCall { + c.urlParams_.Set("fields", googleapi.CombineFields(s)) + return c +} + +// Context sets the context to be used in this call's Do method. Any +// pending HTTP request will be aborted if the provided context is +// canceled. +func (c *ProjectsLocationsDatasetsDataItemsOperationsCancelCall) Context(ctx context.Context) *ProjectsLocationsDatasetsDataItemsOperationsCancelCall { + c.ctx_ = ctx + return c +} + +// Header returns an http.Header that can be modified by the caller to +// add HTTP headers to the request. +func (c *ProjectsLocationsDatasetsDataItemsOperationsCancelCall) Header() http.Header { + if c.header_ == nil { + c.header_ = make(http.Header) + } + return c.header_ +} + +func (c *ProjectsLocationsDatasetsDataItemsOperationsCancelCall) doRequest(alt string) (*http.Response, error) { + reqHeaders := make(http.Header) + reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version) + for k, v := range c.header_ { + reqHeaders[k] = v + } + reqHeaders.Set("User-Agent", c.s.userAgent()) + var body io.Reader = nil + c.urlParams_.Set("alt", alt) + c.urlParams_.Set("prettyPrint", "false") + urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+name}:cancel") + urls += "?" + c.urlParams_.Encode() + req, err := http.NewRequest("POST", urls, body) + if err != nil { + return nil, err + } + req.Header = reqHeaders + googleapi.Expand(req.URL, map[string]string{ + "name": c.name, + }) + return gensupport.SendRequest(c.ctx_, c.s.client, req) +} + +// Do executes the "aiplatform.projects.locations.datasets.dataItems.operations.cancel" call. +// Exactly one of *GoogleProtobufEmpty or error will be non-nil. Any +// non-2xx status code is an error. Response headers are in either +// *GoogleProtobufEmpty.ServerResponse.Header or (if a response was +// returned at all) in error.(*googleapi.Error).Header. Use +// googleapi.IsNotModified to check whether the returned error was +// because http.StatusNotModified was returned. +func (c *ProjectsLocationsDatasetsDataItemsOperationsCancelCall) Do(opts ...googleapi.CallOption) (*GoogleProtobufEmpty, error) { + gensupport.SetOptions(c.urlParams_, opts...) + res, err := c.doRequest("json") + if res != nil && res.StatusCode == http.StatusNotModified { + if res.Body != nil { + res.Body.Close() + } + return nil, gensupport.WrapError(&googleapi.Error{ + Code: res.StatusCode, + Header: res.Header, + }) + } + if err != nil { + return nil, err + } + defer googleapi.CloseBody(res) + if err := googleapi.CheckResponse(res); err != nil { + return nil, gensupport.WrapError(err) + } + ret := &GoogleProtobufEmpty{ + ServerResponse: googleapi.ServerResponse{ + Header: res.Header, + HTTPStatusCode: res.StatusCode, + }, + } + target := &ret + if err := gensupport.DecodeResponse(target, res); err != nil { + return nil, err + } + return ret, nil + // { + // "description": "Starts asynchronous cancellation on a long-running operation. The server makes a best effort to cancel the operation, but success is not guaranteed. If the server doesn't support this method, it returns `google.rpc.Code.UNIMPLEMENTED`. Clients can use Operations.GetOperation or other methods to check whether the cancellation succeeded or whether the operation completed despite cancellation. On successful cancellation, the operation is not deleted; instead, it becomes an operation with an Operation.error value with a google.rpc.Status.code of 1, corresponding to `Code.CANCELLED`.", + // "flatPath": "v1/projects/{projectsId}/locations/{locationsId}/datasets/{datasetsId}/dataItems/{dataItemsId}/operations/{operationsId}:cancel", + // "httpMethod": "POST", + // "id": "aiplatform.projects.locations.datasets.dataItems.operations.cancel", + // "parameterOrder": [ + // "name" + // ], + // "parameters": { + // "name": { + // "description": "The name of the operation resource to be cancelled.", + // "location": "path", + // "pattern": "^projects/[^/]+/locations/[^/]+/datasets/[^/]+/dataItems/[^/]+/operations/[^/]+$", + // "required": true, + // "type": "string" + // } + // }, + // "path": "v1/{+name}:cancel", + // "response": { + // "$ref": "GoogleProtobufEmpty" + // }, + // "scopes": [ + // "https://www.googleapis.com/auth/cloud-platform" + // ] + // } + +} + +// method id "aiplatform.projects.locations.datasets.dataItems.operations.delete": + +type ProjectsLocationsDatasetsDataItemsOperationsDeleteCall struct { + s *Service + name string + urlParams_ gensupport.URLParams + ctx_ context.Context + header_ http.Header +} + +// Delete: Deletes a long-running operation. This method indicates that +// the client is no longer interested in the operation result. It does +// not cancel the operation. If the server doesn't support this method, +// it returns `google.rpc.Code.UNIMPLEMENTED`. +// +// - name: The name of the operation resource to be deleted. +func (r *ProjectsLocationsDatasetsDataItemsOperationsService) Delete(name string) *ProjectsLocationsDatasetsDataItemsOperationsDeleteCall { + c := &ProjectsLocationsDatasetsDataItemsOperationsDeleteCall{s: r.s, urlParams_: make(gensupport.URLParams)} + c.name = name + return c +} + +// Fields allows partial responses to be retrieved. See +// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse +// for more information. +func (c *ProjectsLocationsDatasetsDataItemsOperationsDeleteCall) Fields(s ...googleapi.Field) *ProjectsLocationsDatasetsDataItemsOperationsDeleteCall { + c.urlParams_.Set("fields", googleapi.CombineFields(s)) + return c +} + +// Context sets the context to be used in this call's Do method. Any +// pending HTTP request will be aborted if the provided context is +// canceled. +func (c *ProjectsLocationsDatasetsDataItemsOperationsDeleteCall) Context(ctx context.Context) *ProjectsLocationsDatasetsDataItemsOperationsDeleteCall { + c.ctx_ = ctx + return c +} + +// Header returns an http.Header that can be modified by the caller to +// add HTTP headers to the request. +func (c *ProjectsLocationsDatasetsDataItemsOperationsDeleteCall) Header() http.Header { + if c.header_ == nil { + c.header_ = make(http.Header) + } + return c.header_ +} + +func (c *ProjectsLocationsDatasetsDataItemsOperationsDeleteCall) doRequest(alt string) (*http.Response, error) { + reqHeaders := make(http.Header) + reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version) + for k, v := range c.header_ { + reqHeaders[k] = v + } + reqHeaders.Set("User-Agent", c.s.userAgent()) + var body io.Reader = nil + c.urlParams_.Set("alt", alt) + c.urlParams_.Set("prettyPrint", "false") + urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+name}") + urls += "?" + c.urlParams_.Encode() + req, err := http.NewRequest("DELETE", urls, body) + if err != nil { + return nil, err + } + req.Header = reqHeaders + googleapi.Expand(req.URL, map[string]string{ + "name": c.name, + }) + return gensupport.SendRequest(c.ctx_, c.s.client, req) +} + +// Do executes the "aiplatform.projects.locations.datasets.dataItems.operations.delete" call. +// Exactly one of *GoogleProtobufEmpty or error will be non-nil. Any +// non-2xx status code is an error. Response headers are in either +// *GoogleProtobufEmpty.ServerResponse.Header or (if a response was +// returned at all) in error.(*googleapi.Error).Header. Use +// googleapi.IsNotModified to check whether the returned error was +// because http.StatusNotModified was returned. +func (c *ProjectsLocationsDatasetsDataItemsOperationsDeleteCall) Do(opts ...googleapi.CallOption) (*GoogleProtobufEmpty, error) { + gensupport.SetOptions(c.urlParams_, opts...) + res, err := c.doRequest("json") + if res != nil && res.StatusCode == http.StatusNotModified { + if res.Body != nil { + res.Body.Close() + } + return nil, gensupport.WrapError(&googleapi.Error{ + Code: res.StatusCode, + Header: res.Header, + }) + } + if err != nil { + return nil, err + } + defer googleapi.CloseBody(res) + if err := googleapi.CheckResponse(res); err != nil { + return nil, gensupport.WrapError(err) + } + ret := &GoogleProtobufEmpty{ + ServerResponse: googleapi.ServerResponse{ + Header: res.Header, + HTTPStatusCode: res.StatusCode, + }, + } + target := &ret + if err := gensupport.DecodeResponse(target, res); err != nil { + return nil, err + } + return ret, nil + // { + // "description": "Deletes a long-running operation. This method indicates that the client is no longer interested in the operation result. It does not cancel the operation. If the server doesn't support this method, it returns `google.rpc.Code.UNIMPLEMENTED`.", + // "flatPath": "v1/projects/{projectsId}/locations/{locationsId}/datasets/{datasetsId}/dataItems/{dataItemsId}/operations/{operationsId}", + // "httpMethod": "DELETE", + // "id": "aiplatform.projects.locations.datasets.dataItems.operations.delete", + // "parameterOrder": [ + // "name" + // ], + // "parameters": { + // "name": { + // "description": "The name of the operation resource to be deleted.", + // "location": "path", + // "pattern": "^projects/[^/]+/locations/[^/]+/datasets/[^/]+/dataItems/[^/]+/operations/[^/]+$", + // "required": true, + // "type": "string" + // } + // }, + // "path": "v1/{+name}", + // "response": { + // "$ref": "GoogleProtobufEmpty" + // }, + // "scopes": [ + // "https://www.googleapis.com/auth/cloud-platform" + // ] + // } + +} + +// method id "aiplatform.projects.locations.datasets.dataItems.operations.get": + +type ProjectsLocationsDatasetsDataItemsOperationsGetCall struct { + s *Service + name string + urlParams_ gensupport.URLParams + ifNoneMatch_ string + ctx_ context.Context + header_ http.Header +} + +// Get: Gets the latest state of a long-running operation. Clients can +// use this method to poll the operation result at intervals as +// recommended by the API service. +// +// - name: The name of the operation resource. +func (r *ProjectsLocationsDatasetsDataItemsOperationsService) Get(name string) *ProjectsLocationsDatasetsDataItemsOperationsGetCall { + c := &ProjectsLocationsDatasetsDataItemsOperationsGetCall{s: r.s, urlParams_: make(gensupport.URLParams)} + c.name = name + return c +} + +// Fields allows partial responses to be retrieved. See +// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse +// for more information. +func (c *ProjectsLocationsDatasetsDataItemsOperationsGetCall) Fields(s ...googleapi.Field) *ProjectsLocationsDatasetsDataItemsOperationsGetCall { + c.urlParams_.Set("fields", googleapi.CombineFields(s)) + return c +} + +// IfNoneMatch sets the optional parameter which makes the operation +// fail if the object's ETag matches the given value. This is useful for +// getting updates only after the object has changed since the last +// request. Use googleapi.IsNotModified to check whether the response +// error from Do is the result of In-None-Match. +func (c *ProjectsLocationsDatasetsDataItemsOperationsGetCall) IfNoneMatch(entityTag string) *ProjectsLocationsDatasetsDataItemsOperationsGetCall { + c.ifNoneMatch_ = entityTag + return c +} + +// Context sets the context to be used in this call's Do method. Any +// pending HTTP request will be aborted if the provided context is +// canceled. +func (c *ProjectsLocationsDatasetsDataItemsOperationsGetCall) Context(ctx context.Context) *ProjectsLocationsDatasetsDataItemsOperationsGetCall { + c.ctx_ = ctx + return c +} + +// Header returns an http.Header that can be modified by the caller to +// add HTTP headers to the request. +func (c *ProjectsLocationsDatasetsDataItemsOperationsGetCall) Header() http.Header { + if c.header_ == nil { + c.header_ = make(http.Header) + } + return c.header_ +} + +func (c *ProjectsLocationsDatasetsDataItemsOperationsGetCall) doRequest(alt string) (*http.Response, error) { + reqHeaders := make(http.Header) + reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version) + for k, v := range c.header_ { + reqHeaders[k] = v + } + reqHeaders.Set("User-Agent", c.s.userAgent()) + if c.ifNoneMatch_ != "" { + reqHeaders.Set("If-None-Match", c.ifNoneMatch_) + } + var body io.Reader = nil + c.urlParams_.Set("alt", alt) + c.urlParams_.Set("prettyPrint", "false") + urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+name}") + urls += "?" + c.urlParams_.Encode() + req, err := http.NewRequest("GET", urls, body) + if err != nil { + return nil, err + } + req.Header = reqHeaders + googleapi.Expand(req.URL, map[string]string{ + "name": c.name, + }) + return gensupport.SendRequest(c.ctx_, c.s.client, req) +} + +// Do executes the "aiplatform.projects.locations.datasets.dataItems.operations.get" call. +// Exactly one of *GoogleLongrunningOperation or error will be non-nil. +// Any non-2xx status code is an error. Response headers are in either +// *GoogleLongrunningOperation.ServerResponse.Header or (if a response +// was returned at all) in error.(*googleapi.Error).Header. Use +// googleapi.IsNotModified to check whether the returned error was +// because http.StatusNotModified was returned. +func (c *ProjectsLocationsDatasetsDataItemsOperationsGetCall) Do(opts ...googleapi.CallOption) (*GoogleLongrunningOperation, error) { + gensupport.SetOptions(c.urlParams_, opts...) + res, err := c.doRequest("json") + if res != nil && res.StatusCode == http.StatusNotModified { + if res.Body != nil { + res.Body.Close() + } + return nil, gensupport.WrapError(&googleapi.Error{ + Code: res.StatusCode, + Header: res.Header, + }) + } + if err != nil { + return nil, err + } + defer googleapi.CloseBody(res) + if err := googleapi.CheckResponse(res); err != nil { + return nil, gensupport.WrapError(err) + } + ret := &GoogleLongrunningOperation{ + ServerResponse: googleapi.ServerResponse{ + Header: res.Header, + HTTPStatusCode: res.StatusCode, + }, + } + target := &ret + if err := gensupport.DecodeResponse(target, res); err != nil { + return nil, err + } + return ret, nil + // { + // "description": "Gets the latest state of a long-running operation. Clients can use this method to poll the operation result at intervals as recommended by the API service.", + // "flatPath": "v1/projects/{projectsId}/locations/{locationsId}/datasets/{datasetsId}/dataItems/{dataItemsId}/operations/{operationsId}", + // "httpMethod": "GET", + // "id": "aiplatform.projects.locations.datasets.dataItems.operations.get", + // "parameterOrder": [ + // "name" + // ], + // "parameters": { + // "name": { + // "description": "The name of the operation resource.", + // "location": "path", + // "pattern": "^projects/[^/]+/locations/[^/]+/datasets/[^/]+/dataItems/[^/]+/operations/[^/]+$", + // "required": true, + // "type": "string" + // } + // }, + // "path": "v1/{+name}", + // "response": { + // "$ref": "GoogleLongrunningOperation" + // }, + // "scopes": [ + // "https://www.googleapis.com/auth/cloud-platform" + // ] + // } + +} + +// method id "aiplatform.projects.locations.datasets.dataItems.operations.list": + +type ProjectsLocationsDatasetsDataItemsOperationsListCall struct { + s *Service + name string + urlParams_ gensupport.URLParams + ifNoneMatch_ string + ctx_ context.Context + header_ http.Header +} + +// List: Lists operations that match the specified filter in the +// request. If the server doesn't support this method, it returns +// `UNIMPLEMENTED`. +// +// - name: The name of the operation's parent resource. +func (r *ProjectsLocationsDatasetsDataItemsOperationsService) List(name string) *ProjectsLocationsDatasetsDataItemsOperationsListCall { + c := &ProjectsLocationsDatasetsDataItemsOperationsListCall{s: r.s, urlParams_: make(gensupport.URLParams)} + c.name = name + return c +} + +// Filter sets the optional parameter "filter": The standard list +// filter. +func (c *ProjectsLocationsDatasetsDataItemsOperationsListCall) Filter(filter string) *ProjectsLocationsDatasetsDataItemsOperationsListCall { + c.urlParams_.Set("filter", filter) + return c +} + +// PageSize sets the optional parameter "pageSize": The standard list +// page size. +func (c *ProjectsLocationsDatasetsDataItemsOperationsListCall) PageSize(pageSize int64) *ProjectsLocationsDatasetsDataItemsOperationsListCall { + c.urlParams_.Set("pageSize", fmt.Sprint(pageSize)) + return c +} + +// PageToken sets the optional parameter "pageToken": The standard list +// page token. +func (c *ProjectsLocationsDatasetsDataItemsOperationsListCall) PageToken(pageToken string) *ProjectsLocationsDatasetsDataItemsOperationsListCall { + c.urlParams_.Set("pageToken", pageToken) + return c +} + +// Fields allows partial responses to be retrieved. See +// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse +// for more information. +func (c *ProjectsLocationsDatasetsDataItemsOperationsListCall) Fields(s ...googleapi.Field) *ProjectsLocationsDatasetsDataItemsOperationsListCall { + c.urlParams_.Set("fields", googleapi.CombineFields(s)) + return c +} + +// IfNoneMatch sets the optional parameter which makes the operation +// fail if the object's ETag matches the given value. This is useful for +// getting updates only after the object has changed since the last +// request. Use googleapi.IsNotModified to check whether the response +// error from Do is the result of In-None-Match. +func (c *ProjectsLocationsDatasetsDataItemsOperationsListCall) IfNoneMatch(entityTag string) *ProjectsLocationsDatasetsDataItemsOperationsListCall { + c.ifNoneMatch_ = entityTag + return c +} + +// Context sets the context to be used in this call's Do method. Any +// pending HTTP request will be aborted if the provided context is +// canceled. +func (c *ProjectsLocationsDatasetsDataItemsOperationsListCall) Context(ctx context.Context) *ProjectsLocationsDatasetsDataItemsOperationsListCall { + c.ctx_ = ctx + return c +} + +// Header returns an http.Header that can be modified by the caller to +// add HTTP headers to the request. +func (c *ProjectsLocationsDatasetsDataItemsOperationsListCall) Header() http.Header { + if c.header_ == nil { + c.header_ = make(http.Header) + } + return c.header_ +} + +func (c *ProjectsLocationsDatasetsDataItemsOperationsListCall) doRequest(alt string) (*http.Response, error) { + reqHeaders := make(http.Header) + reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version) + for k, v := range c.header_ { + reqHeaders[k] = v + } + reqHeaders.Set("User-Agent", c.s.userAgent()) + if c.ifNoneMatch_ != "" { + reqHeaders.Set("If-None-Match", c.ifNoneMatch_) + } + var body io.Reader = nil + c.urlParams_.Set("alt", alt) + c.urlParams_.Set("prettyPrint", "false") + urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+name}/operations") + urls += "?" + c.urlParams_.Encode() + req, err := http.NewRequest("GET", urls, body) + if err != nil { + return nil, err + } + req.Header = reqHeaders + googleapi.Expand(req.URL, map[string]string{ + "name": c.name, + }) + return gensupport.SendRequest(c.ctx_, c.s.client, req) +} + +// Do executes the "aiplatform.projects.locations.datasets.dataItems.operations.list" call. +// Exactly one of *GoogleLongrunningListOperationsResponse or error will +// be non-nil. Any non-2xx status code is an error. Response headers are +// in either +// *GoogleLongrunningListOperationsResponse.ServerResponse.Header or (if +// a response was returned at all) in error.(*googleapi.Error).Header. +// Use googleapi.IsNotModified to check whether the returned error was +// because http.StatusNotModified was returned. +func (c *ProjectsLocationsDatasetsDataItemsOperationsListCall) Do(opts ...googleapi.CallOption) (*GoogleLongrunningListOperationsResponse, error) { + gensupport.SetOptions(c.urlParams_, opts...) + res, err := c.doRequest("json") + if res != nil && res.StatusCode == http.StatusNotModified { + if res.Body != nil { + res.Body.Close() + } + return nil, gensupport.WrapError(&googleapi.Error{ + Code: res.StatusCode, + Header: res.Header, + }) + } + if err != nil { + return nil, err + } + defer googleapi.CloseBody(res) + if err := googleapi.CheckResponse(res); err != nil { + return nil, gensupport.WrapError(err) + } + ret := &GoogleLongrunningListOperationsResponse{ + ServerResponse: googleapi.ServerResponse{ + Header: res.Header, + HTTPStatusCode: res.StatusCode, + }, + } + target := &ret + if err := gensupport.DecodeResponse(target, res); err != nil { + return nil, err + } + return ret, nil + // { + // "description": "Lists operations that match the specified filter in the request. If the server doesn't support this method, it returns `UNIMPLEMENTED`.", + // "flatPath": "v1/projects/{projectsId}/locations/{locationsId}/datasets/{datasetsId}/dataItems/{dataItemsId}/operations", + // "httpMethod": "GET", + // "id": "aiplatform.projects.locations.datasets.dataItems.operations.list", + // "parameterOrder": [ + // "name" + // ], + // "parameters": { + // "filter": { + // "description": "The standard list filter.", + // "location": "query", + // "type": "string" + // }, + // "name": { + // "description": "The name of the operation's parent resource.", + // "location": "path", + // "pattern": "^projects/[^/]+/locations/[^/]+/datasets/[^/]+/dataItems/[^/]+$", + // "required": true, + // "type": "string" + // }, + // "pageSize": { + // "description": "The standard list page size.", + // "format": "int32", + // "location": "query", + // "type": "integer" + // }, + // "pageToken": { + // "description": "The standard list page token.", + // "location": "query", + // "type": "string" + // } + // }, + // "path": "v1/{+name}/operations", + // "response": { + // "$ref": "GoogleLongrunningListOperationsResponse" + // }, + // "scopes": [ + // "https://www.googleapis.com/auth/cloud-platform" + // ] + // } + +} + +// Pages invokes f for each page of results. +// A non-nil error returned from f will halt the iteration. +// The provided context supersedes any context provided to the Context method. +func (c *ProjectsLocationsDatasetsDataItemsOperationsListCall) Pages(ctx context.Context, f func(*GoogleLongrunningListOperationsResponse) error) error { + c.ctx_ = ctx + defer c.PageToken(c.urlParams_.Get("pageToken")) // reset paging to original point + for { + x, err := c.Do() + if err != nil { + return err + } + if err := f(x); err != nil { + return err + } + if x.NextPageToken == "" { + return nil + } + c.PageToken(x.NextPageToken) + } +} + +// method id "aiplatform.projects.locations.datasets.dataItems.operations.wait": + +type ProjectsLocationsDatasetsDataItemsOperationsWaitCall struct { + s *Service + name string + urlParams_ gensupport.URLParams + ctx_ context.Context + header_ http.Header +} + +// Wait: Waits until the specified long-running operation is done or +// reaches at most a specified timeout, returning the latest state. If +// the operation is already done, the latest state is immediately +// returned. If the timeout specified is greater than the default +// HTTP/RPC timeout, the HTTP/RPC timeout is used. If the server does +// not support this method, it returns `google.rpc.Code.UNIMPLEMENTED`. +// Note that this method is on a best-effort basis. It may return the +// latest state before the specified timeout (including immediately), +// meaning even an immediate response is no guarantee that the operation +// is done. +// +// - name: The name of the operation resource to wait on. +func (r *ProjectsLocationsDatasetsDataItemsOperationsService) Wait(name string) *ProjectsLocationsDatasetsDataItemsOperationsWaitCall { + c := &ProjectsLocationsDatasetsDataItemsOperationsWaitCall{s: r.s, urlParams_: make(gensupport.URLParams)} + c.name = name + return c +} + +// Timeout sets the optional parameter "timeout": The maximum duration +// to wait before timing out. If left blank, the wait will be at most +// the time permitted by the underlying HTTP/RPC protocol. If RPC +// context deadline is also specified, the shorter one will be used. +func (c *ProjectsLocationsDatasetsDataItemsOperationsWaitCall) Timeout(timeout string) *ProjectsLocationsDatasetsDataItemsOperationsWaitCall { + c.urlParams_.Set("timeout", timeout) + return c +} + +// Fields allows partial responses to be retrieved. See +// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse +// for more information. +func (c *ProjectsLocationsDatasetsDataItemsOperationsWaitCall) Fields(s ...googleapi.Field) *ProjectsLocationsDatasetsDataItemsOperationsWaitCall { + c.urlParams_.Set("fields", googleapi.CombineFields(s)) + return c +} + +// Context sets the context to be used in this call's Do method. Any +// pending HTTP request will be aborted if the provided context is +// canceled. +func (c *ProjectsLocationsDatasetsDataItemsOperationsWaitCall) Context(ctx context.Context) *ProjectsLocationsDatasetsDataItemsOperationsWaitCall { + c.ctx_ = ctx + return c +} + +// Header returns an http.Header that can be modified by the caller to +// add HTTP headers to the request. +func (c *ProjectsLocationsDatasetsDataItemsOperationsWaitCall) Header() http.Header { + if c.header_ == nil { + c.header_ = make(http.Header) + } + return c.header_ +} + +func (c *ProjectsLocationsDatasetsDataItemsOperationsWaitCall) doRequest(alt string) (*http.Response, error) { + reqHeaders := make(http.Header) + reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version) + for k, v := range c.header_ { + reqHeaders[k] = v + } + reqHeaders.Set("User-Agent", c.s.userAgent()) + var body io.Reader = nil + c.urlParams_.Set("alt", alt) + c.urlParams_.Set("prettyPrint", "false") + urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+name}:wait") + urls += "?" + c.urlParams_.Encode() + req, err := http.NewRequest("POST", urls, body) + if err != nil { + return nil, err + } + req.Header = reqHeaders + googleapi.Expand(req.URL, map[string]string{ + "name": c.name, + }) + return gensupport.SendRequest(c.ctx_, c.s.client, req) +} + +// Do executes the "aiplatform.projects.locations.datasets.dataItems.operations.wait" call. +// Exactly one of *GoogleLongrunningOperation or error will be non-nil. +// Any non-2xx status code is an error. Response headers are in either +// *GoogleLongrunningOperation.ServerResponse.Header or (if a response +// was returned at all) in error.(*googleapi.Error).Header. Use +// googleapi.IsNotModified to check whether the returned error was +// because http.StatusNotModified was returned. +func (c *ProjectsLocationsDatasetsDataItemsOperationsWaitCall) Do(opts ...googleapi.CallOption) (*GoogleLongrunningOperation, error) { + gensupport.SetOptions(c.urlParams_, opts...) + res, err := c.doRequest("json") + if res != nil && res.StatusCode == http.StatusNotModified { + if res.Body != nil { + res.Body.Close() + } + return nil, gensupport.WrapError(&googleapi.Error{ + Code: res.StatusCode, + Header: res.Header, + }) + } + if err != nil { + return nil, err + } + defer googleapi.CloseBody(res) + if err := googleapi.CheckResponse(res); err != nil { + return nil, gensupport.WrapError(err) + } + ret := &GoogleLongrunningOperation{ + ServerResponse: googleapi.ServerResponse{ + Header: res.Header, + HTTPStatusCode: res.StatusCode, + }, + } + target := &ret + if err := gensupport.DecodeResponse(target, res); err != nil { + return nil, err + } + return ret, nil + // { + // "description": "Waits until the specified long-running operation is done or reaches at most a specified timeout, returning the latest state. If the operation is already done, the latest state is immediately returned. If the timeout specified is greater than the default HTTP/RPC timeout, the HTTP/RPC timeout is used. If the server does not support this method, it returns `google.rpc.Code.UNIMPLEMENTED`. Note that this method is on a best-effort basis. It may return the latest state before the specified timeout (including immediately), meaning even an immediate response is no guarantee that the operation is done.", + // "flatPath": "v1/projects/{projectsId}/locations/{locationsId}/datasets/{datasetsId}/dataItems/{dataItemsId}/operations/{operationsId}:wait", + // "httpMethod": "POST", + // "id": "aiplatform.projects.locations.datasets.dataItems.operations.wait", + // "parameterOrder": [ + // "name" + // ], + // "parameters": { + // "name": { + // "description": "The name of the operation resource to wait on.", + // "location": "path", + // "pattern": "^projects/[^/]+/locations/[^/]+/datasets/[^/]+/dataItems/[^/]+/operations/[^/]+$", + // "required": true, + // "type": "string" + // }, + // "timeout": { + // "description": "The maximum duration to wait before timing out. If left blank, the wait will be at most the time permitted by the underlying HTTP/RPC protocol. If RPC context deadline is also specified, the shorter one will be used.", + // "format": "google-duration", + // "location": "query", + // "type": "string" + // } + // }, + // "path": "v1/{+name}:wait", + // "response": { + // "$ref": "GoogleLongrunningOperation" + // }, + // "scopes": [ + // "https://www.googleapis.com/auth/cloud-platform" + // ] + // } + +} + +// method id "aiplatform.projects.locations.datasets.datasetVersions.create": -type ProjectsLocationsDatasetsDataItemsOperationsCancelCall struct { - s *Service - name string - urlParams_ gensupport.URLParams - ctx_ context.Context - header_ http.Header +type ProjectsLocationsDatasetsDatasetVersionsCreateCall struct { + s *Service + parent string + googlecloudaiplatformv1datasetversion *GoogleCloudAiplatformV1DatasetVersion + urlParams_ gensupport.URLParams + ctx_ context.Context + header_ http.Header } -// Cancel: Starts asynchronous cancellation on a long-running operation. -// The server makes a best effort to cancel the operation, but success -// is not guaranteed. If the server doesn't support this method, it -// returns `google.rpc.Code.UNIMPLEMENTED`. Clients can use -// Operations.GetOperation or other methods to check whether the -// cancellation succeeded or whether the operation completed despite -// cancellation. On successful cancellation, the operation is not -// deleted; instead, it becomes an operation with an Operation.error -// value with a google.rpc.Status.code of 1, corresponding to -// `Code.CANCELLED`. +// Create: Create a version from a Dataset. // -// - name: The name of the operation resource to be cancelled. -func (r *ProjectsLocationsDatasetsDataItemsOperationsService) Cancel(name string) *ProjectsLocationsDatasetsDataItemsOperationsCancelCall { - c := &ProjectsLocationsDatasetsDataItemsOperationsCancelCall{s: r.s, urlParams_: make(gensupport.URLParams)} - c.name = name +// - parent: The name of the Dataset resource. Format: +// `projects/{project}/locations/{location}/datasets/{dataset}`. +func (r *ProjectsLocationsDatasetsDatasetVersionsService) Create(parent string, googlecloudaiplatformv1datasetversion *GoogleCloudAiplatformV1DatasetVersion) *ProjectsLocationsDatasetsDatasetVersionsCreateCall { + c := &ProjectsLocationsDatasetsDatasetVersionsCreateCall{s: r.s, urlParams_: make(gensupport.URLParams)} + c.parent = parent + c.googlecloudaiplatformv1datasetversion = googlecloudaiplatformv1datasetversion return c } // Fields allows partial responses to be retrieved. See // https://developers.google.com/gdata/docs/2.0/basics#PartialResponse // for more information. -func (c *ProjectsLocationsDatasetsDataItemsOperationsCancelCall) Fields(s ...googleapi.Field) *ProjectsLocationsDatasetsDataItemsOperationsCancelCall { +func (c *ProjectsLocationsDatasetsDatasetVersionsCreateCall) Fields(s ...googleapi.Field) *ProjectsLocationsDatasetsDatasetVersionsCreateCall { c.urlParams_.Set("fields", googleapi.CombineFields(s)) return c } @@ -39154,21 +40123,21 @@ func (c *ProjectsLocationsDatasetsDataItemsOperationsCancelCall) Fields(s ...goo // Context sets the context to be used in this call's Do method. Any // pending HTTP request will be aborted if the provided context is // canceled. -func (c *ProjectsLocationsDatasetsDataItemsOperationsCancelCall) Context(ctx context.Context) *ProjectsLocationsDatasetsDataItemsOperationsCancelCall { +func (c *ProjectsLocationsDatasetsDatasetVersionsCreateCall) Context(ctx context.Context) *ProjectsLocationsDatasetsDatasetVersionsCreateCall { c.ctx_ = ctx return c } // Header returns an http.Header that can be modified by the caller to // add HTTP headers to the request. -func (c *ProjectsLocationsDatasetsDataItemsOperationsCancelCall) Header() http.Header { +func (c *ProjectsLocationsDatasetsDatasetVersionsCreateCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) } return c.header_ } -func (c *ProjectsLocationsDatasetsDataItemsOperationsCancelCall) doRequest(alt string) (*http.Response, error) { +func (c *ProjectsLocationsDatasetsDatasetVersionsCreateCall) doRequest(alt string) (*http.Response, error) { reqHeaders := make(http.Header) reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version) for k, v := range c.header_ { @@ -39176,9 +40145,14 @@ func (c *ProjectsLocationsDatasetsDataItemsOperationsCancelCall) doRequest(alt s } reqHeaders.Set("User-Agent", c.s.userAgent()) var body io.Reader = nil + body, err := googleapi.WithoutDataWrapper.JSONReader(c.googlecloudaiplatformv1datasetversion) + if err != nil { + return nil, err + } + reqHeaders.Set("Content-Type", "application/json") c.urlParams_.Set("alt", alt) c.urlParams_.Set("prettyPrint", "false") - urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+name}:cancel") + urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+parent}/datasetVersions") urls += "?" + c.urlParams_.Encode() req, err := http.NewRequest("POST", urls, body) if err != nil { @@ -39186,19 +40160,19 @@ func (c *ProjectsLocationsDatasetsDataItemsOperationsCancelCall) doRequest(alt s } req.Header = reqHeaders googleapi.Expand(req.URL, map[string]string{ - "name": c.name, + "parent": c.parent, }) return gensupport.SendRequest(c.ctx_, c.s.client, req) } -// Do executes the "aiplatform.projects.locations.datasets.dataItems.operations.cancel" call. -// Exactly one of *GoogleProtobufEmpty or error will be non-nil. Any -// non-2xx status code is an error. Response headers are in either -// *GoogleProtobufEmpty.ServerResponse.Header or (if a response was -// returned at all) in error.(*googleapi.Error).Header. Use +// Do executes the "aiplatform.projects.locations.datasets.datasetVersions.create" call. +// Exactly one of *GoogleLongrunningOperation or error will be non-nil. +// Any non-2xx status code is an error. Response headers are in either +// *GoogleLongrunningOperation.ServerResponse.Header or (if a response +// was returned at all) in error.(*googleapi.Error).Header. Use // googleapi.IsNotModified to check whether the returned error was // because http.StatusNotModified was returned. -func (c *ProjectsLocationsDatasetsDataItemsOperationsCancelCall) Do(opts ...googleapi.CallOption) (*GoogleProtobufEmpty, error) { +func (c *ProjectsLocationsDatasetsDatasetVersionsCreateCall) Do(opts ...googleapi.CallOption) (*GoogleLongrunningOperation, error) { gensupport.SetOptions(c.urlParams_, opts...) res, err := c.doRequest("json") if res != nil && res.StatusCode == http.StatusNotModified { @@ -39217,7 +40191,7 @@ func (c *ProjectsLocationsDatasetsDataItemsOperationsCancelCall) Do(opts ...goog if err := googleapi.CheckResponse(res); err != nil { return nil, gensupport.WrapError(err) } - ret := &GoogleProtobufEmpty{ + ret := &GoogleLongrunningOperation{ ServerResponse: googleapi.ServerResponse{ Header: res.Header, HTTPStatusCode: res.StatusCode, @@ -39229,25 +40203,28 @@ func (c *ProjectsLocationsDatasetsDataItemsOperationsCancelCall) Do(opts ...goog } return ret, nil // { - // "description": "Starts asynchronous cancellation on a long-running operation. The server makes a best effort to cancel the operation, but success is not guaranteed. If the server doesn't support this method, it returns `google.rpc.Code.UNIMPLEMENTED`. Clients can use Operations.GetOperation or other methods to check whether the cancellation succeeded or whether the operation completed despite cancellation. On successful cancellation, the operation is not deleted; instead, it becomes an operation with an Operation.error value with a google.rpc.Status.code of 1, corresponding to `Code.CANCELLED`.", - // "flatPath": "v1/projects/{projectsId}/locations/{locationsId}/datasets/{datasetsId}/dataItems/{dataItemsId}/operations/{operationsId}:cancel", + // "description": "Create a version from a Dataset.", + // "flatPath": "v1/projects/{projectsId}/locations/{locationsId}/datasets/{datasetsId}/datasetVersions", // "httpMethod": "POST", - // "id": "aiplatform.projects.locations.datasets.dataItems.operations.cancel", + // "id": "aiplatform.projects.locations.datasets.datasetVersions.create", // "parameterOrder": [ - // "name" + // "parent" // ], // "parameters": { - // "name": { - // "description": "The name of the operation resource to be cancelled.", + // "parent": { + // "description": "Required. The name of the Dataset resource. Format: `projects/{project}/locations/{location}/datasets/{dataset}`", // "location": "path", - // "pattern": "^projects/[^/]+/locations/[^/]+/datasets/[^/]+/dataItems/[^/]+/operations/[^/]+$", + // "pattern": "^projects/[^/]+/locations/[^/]+/datasets/[^/]+$", // "required": true, // "type": "string" // } // }, - // "path": "v1/{+name}:cancel", + // "path": "v1/{+parent}/datasetVersions", + // "request": { + // "$ref": "GoogleCloudAiplatformV1DatasetVersion" + // }, // "response": { - // "$ref": "GoogleProtobufEmpty" + // "$ref": "GoogleLongrunningOperation" // }, // "scopes": [ // "https://www.googleapis.com/auth/cloud-platform" @@ -39256,9 +40233,9 @@ func (c *ProjectsLocationsDatasetsDataItemsOperationsCancelCall) Do(opts ...goog } -// method id "aiplatform.projects.locations.datasets.dataItems.operations.delete": +// method id "aiplatform.projects.locations.datasets.datasetVersions.delete": -type ProjectsLocationsDatasetsDataItemsOperationsDeleteCall struct { +type ProjectsLocationsDatasetsDatasetVersionsDeleteCall struct { s *Service name string urlParams_ gensupport.URLParams @@ -39266,14 +40243,13 @@ type ProjectsLocationsDatasetsDataItemsOperationsDeleteCall struct { header_ http.Header } -// Delete: Deletes a long-running operation. This method indicates that -// the client is no longer interested in the operation result. It does -// not cancel the operation. If the server doesn't support this method, -// it returns `google.rpc.Code.UNIMPLEMENTED`. +// Delete: Deletes a Dataset version. // -// - name: The name of the operation resource to be deleted. -func (r *ProjectsLocationsDatasetsDataItemsOperationsService) Delete(name string) *ProjectsLocationsDatasetsDataItemsOperationsDeleteCall { - c := &ProjectsLocationsDatasetsDataItemsOperationsDeleteCall{s: r.s, urlParams_: make(gensupport.URLParams)} +// - name: The resource name of the Dataset version to delete. Format: +// `projects/{project}/locations/{location}/datasets/{dataset}/datasetV +// ersions/{dataset_version}`. +func (r *ProjectsLocationsDatasetsDatasetVersionsService) Delete(name string) *ProjectsLocationsDatasetsDatasetVersionsDeleteCall { + c := &ProjectsLocationsDatasetsDatasetVersionsDeleteCall{s: r.s, urlParams_: make(gensupport.URLParams)} c.name = name return c } @@ -39281,7 +40257,7 @@ func (r *ProjectsLocationsDatasetsDataItemsOperationsService) Delete(name string // Fields allows partial responses to be retrieved. See // https://developers.google.com/gdata/docs/2.0/basics#PartialResponse // for more information. -func (c *ProjectsLocationsDatasetsDataItemsOperationsDeleteCall) Fields(s ...googleapi.Field) *ProjectsLocationsDatasetsDataItemsOperationsDeleteCall { +func (c *ProjectsLocationsDatasetsDatasetVersionsDeleteCall) Fields(s ...googleapi.Field) *ProjectsLocationsDatasetsDatasetVersionsDeleteCall { c.urlParams_.Set("fields", googleapi.CombineFields(s)) return c } @@ -39289,21 +40265,21 @@ func (c *ProjectsLocationsDatasetsDataItemsOperationsDeleteCall) Fields(s ...goo // Context sets the context to be used in this call's Do method. Any // pending HTTP request will be aborted if the provided context is // canceled. -func (c *ProjectsLocationsDatasetsDataItemsOperationsDeleteCall) Context(ctx context.Context) *ProjectsLocationsDatasetsDataItemsOperationsDeleteCall { +func (c *ProjectsLocationsDatasetsDatasetVersionsDeleteCall) Context(ctx context.Context) *ProjectsLocationsDatasetsDatasetVersionsDeleteCall { c.ctx_ = ctx return c } // Header returns an http.Header that can be modified by the caller to // add HTTP headers to the request. -func (c *ProjectsLocationsDatasetsDataItemsOperationsDeleteCall) Header() http.Header { +func (c *ProjectsLocationsDatasetsDatasetVersionsDeleteCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) } return c.header_ } -func (c *ProjectsLocationsDatasetsDataItemsOperationsDeleteCall) doRequest(alt string) (*http.Response, error) { +func (c *ProjectsLocationsDatasetsDatasetVersionsDeleteCall) doRequest(alt string) (*http.Response, error) { reqHeaders := make(http.Header) reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version) for k, v := range c.header_ { @@ -39326,14 +40302,14 @@ func (c *ProjectsLocationsDatasetsDataItemsOperationsDeleteCall) doRequest(alt s return gensupport.SendRequest(c.ctx_, c.s.client, req) } -// Do executes the "aiplatform.projects.locations.datasets.dataItems.operations.delete" call. -// Exactly one of *GoogleProtobufEmpty or error will be non-nil. Any -// non-2xx status code is an error. Response headers are in either -// *GoogleProtobufEmpty.ServerResponse.Header or (if a response was -// returned at all) in error.(*googleapi.Error).Header. Use +// Do executes the "aiplatform.projects.locations.datasets.datasetVersions.delete" call. +// Exactly one of *GoogleLongrunningOperation or error will be non-nil. +// Any non-2xx status code is an error. Response headers are in either +// *GoogleLongrunningOperation.ServerResponse.Header or (if a response +// was returned at all) in error.(*googleapi.Error).Header. Use // googleapi.IsNotModified to check whether the returned error was // because http.StatusNotModified was returned. -func (c *ProjectsLocationsDatasetsDataItemsOperationsDeleteCall) Do(opts ...googleapi.CallOption) (*GoogleProtobufEmpty, error) { +func (c *ProjectsLocationsDatasetsDatasetVersionsDeleteCall) Do(opts ...googleapi.CallOption) (*GoogleLongrunningOperation, error) { gensupport.SetOptions(c.urlParams_, opts...) res, err := c.doRequest("json") if res != nil && res.StatusCode == http.StatusNotModified { @@ -39352,7 +40328,7 @@ func (c *ProjectsLocationsDatasetsDataItemsOperationsDeleteCall) Do(opts ...goog if err := googleapi.CheckResponse(res); err != nil { return nil, gensupport.WrapError(err) } - ret := &GoogleProtobufEmpty{ + ret := &GoogleLongrunningOperation{ ServerResponse: googleapi.ServerResponse{ Header: res.Header, HTTPStatusCode: res.StatusCode, @@ -39364,25 +40340,25 @@ func (c *ProjectsLocationsDatasetsDataItemsOperationsDeleteCall) Do(opts ...goog } return ret, nil // { - // "description": "Deletes a long-running operation. This method indicates that the client is no longer interested in the operation result. It does not cancel the operation. If the server doesn't support this method, it returns `google.rpc.Code.UNIMPLEMENTED`.", - // "flatPath": "v1/projects/{projectsId}/locations/{locationsId}/datasets/{datasetsId}/dataItems/{dataItemsId}/operations/{operationsId}", + // "description": "Deletes a Dataset version.", + // "flatPath": "v1/projects/{projectsId}/locations/{locationsId}/datasets/{datasetsId}/datasetVersions/{datasetVersionsId}", // "httpMethod": "DELETE", - // "id": "aiplatform.projects.locations.datasets.dataItems.operations.delete", + // "id": "aiplatform.projects.locations.datasets.datasetVersions.delete", // "parameterOrder": [ // "name" // ], // "parameters": { // "name": { - // "description": "The name of the operation resource to be deleted.", + // "description": "Required. The resource name of the Dataset version to delete. Format: `projects/{project}/locations/{location}/datasets/{dataset}/datasetVersions/{dataset_version}`", // "location": "path", - // "pattern": "^projects/[^/]+/locations/[^/]+/datasets/[^/]+/dataItems/[^/]+/operations/[^/]+$", + // "pattern": "^projects/[^/]+/locations/[^/]+/datasets/[^/]+/datasetVersions/[^/]+$", // "required": true, // "type": "string" // } // }, // "path": "v1/{+name}", // "response": { - // "$ref": "GoogleProtobufEmpty" + // "$ref": "GoogleLongrunningOperation" // }, // "scopes": [ // "https://www.googleapis.com/auth/cloud-platform" @@ -39391,9 +40367,9 @@ func (c *ProjectsLocationsDatasetsDataItemsOperationsDeleteCall) Do(opts ...goog } -// method id "aiplatform.projects.locations.datasets.dataItems.operations.get": +// method id "aiplatform.projects.locations.datasets.datasetVersions.get": -type ProjectsLocationsDatasetsDataItemsOperationsGetCall struct { +type ProjectsLocationsDatasetsDatasetVersionsGetCall struct { s *Service name string urlParams_ gensupport.URLParams @@ -39402,21 +40378,28 @@ type ProjectsLocationsDatasetsDataItemsOperationsGetCall struct { header_ http.Header } -// Get: Gets the latest state of a long-running operation. Clients can -// use this method to poll the operation result at intervals as -// recommended by the API service. +// Get: Gets a Dataset version. // -// - name: The name of the operation resource. -func (r *ProjectsLocationsDatasetsDataItemsOperationsService) Get(name string) *ProjectsLocationsDatasetsDataItemsOperationsGetCall { - c := &ProjectsLocationsDatasetsDataItemsOperationsGetCall{s: r.s, urlParams_: make(gensupport.URLParams)} +// - name: The resource name of the Dataset version to delete. Format: +// `projects/{project}/locations/{location}/datasets/{dataset}/datasetV +// ersions/{dataset_version}`. +func (r *ProjectsLocationsDatasetsDatasetVersionsService) Get(name string) *ProjectsLocationsDatasetsDatasetVersionsGetCall { + c := &ProjectsLocationsDatasetsDatasetVersionsGetCall{s: r.s, urlParams_: make(gensupport.URLParams)} c.name = name return c } +// ReadMask sets the optional parameter "readMask": Mask specifying +// which fields to read. +func (c *ProjectsLocationsDatasetsDatasetVersionsGetCall) ReadMask(readMask string) *ProjectsLocationsDatasetsDatasetVersionsGetCall { + c.urlParams_.Set("readMask", readMask) + return c +} + // Fields allows partial responses to be retrieved. See // https://developers.google.com/gdata/docs/2.0/basics#PartialResponse // for more information. -func (c *ProjectsLocationsDatasetsDataItemsOperationsGetCall) Fields(s ...googleapi.Field) *ProjectsLocationsDatasetsDataItemsOperationsGetCall { +func (c *ProjectsLocationsDatasetsDatasetVersionsGetCall) Fields(s ...googleapi.Field) *ProjectsLocationsDatasetsDatasetVersionsGetCall { c.urlParams_.Set("fields", googleapi.CombineFields(s)) return c } @@ -39426,7 +40409,7 @@ func (c *ProjectsLocationsDatasetsDataItemsOperationsGetCall) Fields(s ...google // getting updates only after the object has changed since the last // request. Use googleapi.IsNotModified to check whether the response // error from Do is the result of In-None-Match. -func (c *ProjectsLocationsDatasetsDataItemsOperationsGetCall) IfNoneMatch(entityTag string) *ProjectsLocationsDatasetsDataItemsOperationsGetCall { +func (c *ProjectsLocationsDatasetsDatasetVersionsGetCall) IfNoneMatch(entityTag string) *ProjectsLocationsDatasetsDatasetVersionsGetCall { c.ifNoneMatch_ = entityTag return c } @@ -39434,21 +40417,21 @@ func (c *ProjectsLocationsDatasetsDataItemsOperationsGetCall) IfNoneMatch(entity // Context sets the context to be used in this call's Do method. Any // pending HTTP request will be aborted if the provided context is // canceled. -func (c *ProjectsLocationsDatasetsDataItemsOperationsGetCall) Context(ctx context.Context) *ProjectsLocationsDatasetsDataItemsOperationsGetCall { +func (c *ProjectsLocationsDatasetsDatasetVersionsGetCall) Context(ctx context.Context) *ProjectsLocationsDatasetsDatasetVersionsGetCall { c.ctx_ = ctx return c } // Header returns an http.Header that can be modified by the caller to // add HTTP headers to the request. -func (c *ProjectsLocationsDatasetsDataItemsOperationsGetCall) Header() http.Header { +func (c *ProjectsLocationsDatasetsDatasetVersionsGetCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) } return c.header_ } -func (c *ProjectsLocationsDatasetsDataItemsOperationsGetCall) doRequest(alt string) (*http.Response, error) { +func (c *ProjectsLocationsDatasetsDatasetVersionsGetCall) doRequest(alt string) (*http.Response, error) { reqHeaders := make(http.Header) reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version) for k, v := range c.header_ { @@ -39474,14 +40457,15 @@ func (c *ProjectsLocationsDatasetsDataItemsOperationsGetCall) doRequest(alt stri return gensupport.SendRequest(c.ctx_, c.s.client, req) } -// Do executes the "aiplatform.projects.locations.datasets.dataItems.operations.get" call. -// Exactly one of *GoogleLongrunningOperation or error will be non-nil. -// Any non-2xx status code is an error. Response headers are in either -// *GoogleLongrunningOperation.ServerResponse.Header or (if a response -// was returned at all) in error.(*googleapi.Error).Header. Use +// Do executes the "aiplatform.projects.locations.datasets.datasetVersions.get" call. +// Exactly one of *GoogleCloudAiplatformV1DatasetVersion or error will +// be non-nil. Any non-2xx status code is an error. Response headers are +// in either +// *GoogleCloudAiplatformV1DatasetVersion.ServerResponse.Header or (if a +// response was returned at all) in error.(*googleapi.Error).Header. Use // googleapi.IsNotModified to check whether the returned error was // because http.StatusNotModified was returned. -func (c *ProjectsLocationsDatasetsDataItemsOperationsGetCall) Do(opts ...googleapi.CallOption) (*GoogleLongrunningOperation, error) { +func (c *ProjectsLocationsDatasetsDatasetVersionsGetCall) Do(opts ...googleapi.CallOption) (*GoogleCloudAiplatformV1DatasetVersion, error) { gensupport.SetOptions(c.urlParams_, opts...) res, err := c.doRequest("json") if res != nil && res.StatusCode == http.StatusNotModified { @@ -39500,7 +40484,7 @@ func (c *ProjectsLocationsDatasetsDataItemsOperationsGetCall) Do(opts ...googlea if err := googleapi.CheckResponse(res); err != nil { return nil, gensupport.WrapError(err) } - ret := &GoogleLongrunningOperation{ + ret := &GoogleCloudAiplatformV1DatasetVersion{ ServerResponse: googleapi.ServerResponse{ Header: res.Header, HTTPStatusCode: res.StatusCode, @@ -39512,25 +40496,31 @@ func (c *ProjectsLocationsDatasetsDataItemsOperationsGetCall) Do(opts ...googlea } return ret, nil // { - // "description": "Gets the latest state of a long-running operation. Clients can use this method to poll the operation result at intervals as recommended by the API service.", - // "flatPath": "v1/projects/{projectsId}/locations/{locationsId}/datasets/{datasetsId}/dataItems/{dataItemsId}/operations/{operationsId}", + // "description": "Gets a Dataset version.", + // "flatPath": "v1/projects/{projectsId}/locations/{locationsId}/datasets/{datasetsId}/datasetVersions/{datasetVersionsId}", // "httpMethod": "GET", - // "id": "aiplatform.projects.locations.datasets.dataItems.operations.get", + // "id": "aiplatform.projects.locations.datasets.datasetVersions.get", // "parameterOrder": [ // "name" // ], // "parameters": { // "name": { - // "description": "The name of the operation resource.", + // "description": "Required. The resource name of the Dataset version to delete. Format: `projects/{project}/locations/{location}/datasets/{dataset}/datasetVersions/{dataset_version}`", // "location": "path", - // "pattern": "^projects/[^/]+/locations/[^/]+/datasets/[^/]+/dataItems/[^/]+/operations/[^/]+$", + // "pattern": "^projects/[^/]+/locations/[^/]+/datasets/[^/]+/datasetVersions/[^/]+$", // "required": true, // "type": "string" + // }, + // "readMask": { + // "description": "Mask specifying which fields to read.", + // "format": "google-fieldmask", + // "location": "query", + // "type": "string" // } // }, // "path": "v1/{+name}", // "response": { - // "$ref": "GoogleLongrunningOperation" + // "$ref": "GoogleCloudAiplatformV1DatasetVersion" // }, // "scopes": [ // "https://www.googleapis.com/auth/cloud-platform" @@ -39539,53 +40529,68 @@ func (c *ProjectsLocationsDatasetsDataItemsOperationsGetCall) Do(opts ...googlea } -// method id "aiplatform.projects.locations.datasets.dataItems.operations.list": +// method id "aiplatform.projects.locations.datasets.datasetVersions.list": -type ProjectsLocationsDatasetsDataItemsOperationsListCall struct { +type ProjectsLocationsDatasetsDatasetVersionsListCall struct { s *Service - name string + parent string urlParams_ gensupport.URLParams ifNoneMatch_ string ctx_ context.Context header_ http.Header } -// List: Lists operations that match the specified filter in the -// request. If the server doesn't support this method, it returns -// `UNIMPLEMENTED`. +// List: Lists DatasetVersions in a Dataset. // -// - name: The name of the operation's parent resource. -func (r *ProjectsLocationsDatasetsDataItemsOperationsService) List(name string) *ProjectsLocationsDatasetsDataItemsOperationsListCall { - c := &ProjectsLocationsDatasetsDataItemsOperationsListCall{s: r.s, urlParams_: make(gensupport.URLParams)} - c.name = name +// - parent: The resource name of the Dataset to list DatasetVersions +// from. Format: +// `projects/{project}/locations/{location}/datasets/{dataset}`. +func (r *ProjectsLocationsDatasetsDatasetVersionsService) List(parent string) *ProjectsLocationsDatasetsDatasetVersionsListCall { + c := &ProjectsLocationsDatasetsDatasetVersionsListCall{s: r.s, urlParams_: make(gensupport.URLParams)} + c.parent = parent return c } // Filter sets the optional parameter "filter": The standard list // filter. -func (c *ProjectsLocationsDatasetsDataItemsOperationsListCall) Filter(filter string) *ProjectsLocationsDatasetsDataItemsOperationsListCall { +func (c *ProjectsLocationsDatasetsDatasetVersionsListCall) Filter(filter string) *ProjectsLocationsDatasetsDatasetVersionsListCall { c.urlParams_.Set("filter", filter) return c } +// OrderBy sets the optional parameter "orderBy": A comma-separated list +// of fields to order by, sorted in ascending order. Use "desc" after a +// field name for descending. +func (c *ProjectsLocationsDatasetsDatasetVersionsListCall) OrderBy(orderBy string) *ProjectsLocationsDatasetsDatasetVersionsListCall { + c.urlParams_.Set("orderBy", orderBy) + return c +} + // PageSize sets the optional parameter "pageSize": The standard list // page size. -func (c *ProjectsLocationsDatasetsDataItemsOperationsListCall) PageSize(pageSize int64) *ProjectsLocationsDatasetsDataItemsOperationsListCall { +func (c *ProjectsLocationsDatasetsDatasetVersionsListCall) PageSize(pageSize int64) *ProjectsLocationsDatasetsDatasetVersionsListCall { c.urlParams_.Set("pageSize", fmt.Sprint(pageSize)) return c } // PageToken sets the optional parameter "pageToken": The standard list // page token. -func (c *ProjectsLocationsDatasetsDataItemsOperationsListCall) PageToken(pageToken string) *ProjectsLocationsDatasetsDataItemsOperationsListCall { +func (c *ProjectsLocationsDatasetsDatasetVersionsListCall) PageToken(pageToken string) *ProjectsLocationsDatasetsDatasetVersionsListCall { c.urlParams_.Set("pageToken", pageToken) return c } +// ReadMask sets the optional parameter "readMask": Mask specifying +// which fields to read. +func (c *ProjectsLocationsDatasetsDatasetVersionsListCall) ReadMask(readMask string) *ProjectsLocationsDatasetsDatasetVersionsListCall { + c.urlParams_.Set("readMask", readMask) + return c +} + // Fields allows partial responses to be retrieved. See // https://developers.google.com/gdata/docs/2.0/basics#PartialResponse // for more information. -func (c *ProjectsLocationsDatasetsDataItemsOperationsListCall) Fields(s ...googleapi.Field) *ProjectsLocationsDatasetsDataItemsOperationsListCall { +func (c *ProjectsLocationsDatasetsDatasetVersionsListCall) Fields(s ...googleapi.Field) *ProjectsLocationsDatasetsDatasetVersionsListCall { c.urlParams_.Set("fields", googleapi.CombineFields(s)) return c } @@ -39595,7 +40600,7 @@ func (c *ProjectsLocationsDatasetsDataItemsOperationsListCall) Fields(s ...googl // getting updates only after the object has changed since the last // request. Use googleapi.IsNotModified to check whether the response // error from Do is the result of In-None-Match. -func (c *ProjectsLocationsDatasetsDataItemsOperationsListCall) IfNoneMatch(entityTag string) *ProjectsLocationsDatasetsDataItemsOperationsListCall { +func (c *ProjectsLocationsDatasetsDatasetVersionsListCall) IfNoneMatch(entityTag string) *ProjectsLocationsDatasetsDatasetVersionsListCall { c.ifNoneMatch_ = entityTag return c } @@ -39603,21 +40608,21 @@ func (c *ProjectsLocationsDatasetsDataItemsOperationsListCall) IfNoneMatch(entit // Context sets the context to be used in this call's Do method. Any // pending HTTP request will be aborted if the provided context is // canceled. -func (c *ProjectsLocationsDatasetsDataItemsOperationsListCall) Context(ctx context.Context) *ProjectsLocationsDatasetsDataItemsOperationsListCall { +func (c *ProjectsLocationsDatasetsDatasetVersionsListCall) Context(ctx context.Context) *ProjectsLocationsDatasetsDatasetVersionsListCall { c.ctx_ = ctx return c } // Header returns an http.Header that can be modified by the caller to // add HTTP headers to the request. -func (c *ProjectsLocationsDatasetsDataItemsOperationsListCall) Header() http.Header { +func (c *ProjectsLocationsDatasetsDatasetVersionsListCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) } return c.header_ } -func (c *ProjectsLocationsDatasetsDataItemsOperationsListCall) doRequest(alt string) (*http.Response, error) { +func (c *ProjectsLocationsDatasetsDatasetVersionsListCall) doRequest(alt string) (*http.Response, error) { reqHeaders := make(http.Header) reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version) for k, v := range c.header_ { @@ -39630,7 +40635,7 @@ func (c *ProjectsLocationsDatasetsDataItemsOperationsListCall) doRequest(alt str var body io.Reader = nil c.urlParams_.Set("alt", alt) c.urlParams_.Set("prettyPrint", "false") - urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+name}/operations") + urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+parent}/datasetVersions") urls += "?" + c.urlParams_.Encode() req, err := http.NewRequest("GET", urls, body) if err != nil { @@ -39638,20 +40643,21 @@ func (c *ProjectsLocationsDatasetsDataItemsOperationsListCall) doRequest(alt str } req.Header = reqHeaders googleapi.Expand(req.URL, map[string]string{ - "name": c.name, + "parent": c.parent, }) return gensupport.SendRequest(c.ctx_, c.s.client, req) } -// Do executes the "aiplatform.projects.locations.datasets.dataItems.operations.list" call. -// Exactly one of *GoogleLongrunningListOperationsResponse or error will -// be non-nil. Any non-2xx status code is an error. Response headers are -// in either -// *GoogleLongrunningListOperationsResponse.ServerResponse.Header or (if -// a response was returned at all) in error.(*googleapi.Error).Header. -// Use googleapi.IsNotModified to check whether the returned error was -// because http.StatusNotModified was returned. -func (c *ProjectsLocationsDatasetsDataItemsOperationsListCall) Do(opts ...googleapi.CallOption) (*GoogleLongrunningListOperationsResponse, error) { +// Do executes the "aiplatform.projects.locations.datasets.datasetVersions.list" call. +// Exactly one of *GoogleCloudAiplatformV1ListDatasetVersionsResponse or +// error will be non-nil. Any non-2xx status code is an error. Response +// headers are in either +// *GoogleCloudAiplatformV1ListDatasetVersionsResponse.ServerResponse.Hea +// der or (if a response was returned at all) in +// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check +// whether the returned error was because http.StatusNotModified was +// returned. +func (c *ProjectsLocationsDatasetsDatasetVersionsListCall) Do(opts ...googleapi.CallOption) (*GoogleCloudAiplatformV1ListDatasetVersionsResponse, error) { gensupport.SetOptions(c.urlParams_, opts...) res, err := c.doRequest("json") if res != nil && res.StatusCode == http.StatusNotModified { @@ -39670,7 +40676,7 @@ func (c *ProjectsLocationsDatasetsDataItemsOperationsListCall) Do(opts ...google if err := googleapi.CheckResponse(res); err != nil { return nil, gensupport.WrapError(err) } - ret := &GoogleLongrunningListOperationsResponse{ + ret := &GoogleCloudAiplatformV1ListDatasetVersionsResponse{ ServerResponse: googleapi.ServerResponse{ Header: res.Header, HTTPStatusCode: res.StatusCode, @@ -39682,41 +40688,52 @@ func (c *ProjectsLocationsDatasetsDataItemsOperationsListCall) Do(opts ...google } return ret, nil // { - // "description": "Lists operations that match the specified filter in the request. If the server doesn't support this method, it returns `UNIMPLEMENTED`.", - // "flatPath": "v1/projects/{projectsId}/locations/{locationsId}/datasets/{datasetsId}/dataItems/{dataItemsId}/operations", + // "description": "Lists DatasetVersions in a Dataset.", + // "flatPath": "v1/projects/{projectsId}/locations/{locationsId}/datasets/{datasetsId}/datasetVersions", // "httpMethod": "GET", - // "id": "aiplatform.projects.locations.datasets.dataItems.operations.list", + // "id": "aiplatform.projects.locations.datasets.datasetVersions.list", // "parameterOrder": [ - // "name" + // "parent" // ], // "parameters": { // "filter": { - // "description": "The standard list filter.", + // "description": "Optional. The standard list filter.", // "location": "query", // "type": "string" // }, - // "name": { - // "description": "The name of the operation's parent resource.", - // "location": "path", - // "pattern": "^projects/[^/]+/locations/[^/]+/datasets/[^/]+/dataItems/[^/]+$", - // "required": true, + // "orderBy": { + // "description": "Optional. A comma-separated list of fields to order by, sorted in ascending order. Use \"desc\" after a field name for descending.", + // "location": "query", // "type": "string" // }, // "pageSize": { - // "description": "The standard list page size.", + // "description": "Optional. The standard list page size.", // "format": "int32", // "location": "query", // "type": "integer" // }, // "pageToken": { - // "description": "The standard list page token.", + // "description": "Optional. The standard list page token.", + // "location": "query", + // "type": "string" + // }, + // "parent": { + // "description": "Required. The resource name of the Dataset to list DatasetVersions from. Format: `projects/{project}/locations/{location}/datasets/{dataset}`", + // "location": "path", + // "pattern": "^projects/[^/]+/locations/[^/]+/datasets/[^/]+$", + // "required": true, + // "type": "string" + // }, + // "readMask": { + // "description": "Optional. Mask specifying which fields to read.", + // "format": "google-fieldmask", // "location": "query", // "type": "string" // } // }, - // "path": "v1/{+name}/operations", + // "path": "v1/{+parent}/datasetVersions", // "response": { - // "$ref": "GoogleLongrunningListOperationsResponse" + // "$ref": "GoogleCloudAiplatformV1ListDatasetVersionsResponse" // }, // "scopes": [ // "https://www.googleapis.com/auth/cloud-platform" @@ -39728,7 +40745,7 @@ func (c *ProjectsLocationsDatasetsDataItemsOperationsListCall) Do(opts ...google // Pages invokes f for each page of results. // A non-nil error returned from f will halt the iteration. // The provided context supersedes any context provided to the Context method. -func (c *ProjectsLocationsDatasetsDataItemsOperationsListCall) Pages(ctx context.Context, f func(*GoogleLongrunningListOperationsResponse) error) error { +func (c *ProjectsLocationsDatasetsDatasetVersionsListCall) Pages(ctx context.Context, f func(*GoogleCloudAiplatformV1ListDatasetVersionsResponse) error) error { c.ctx_ = ctx defer c.PageToken(c.urlParams_.Get("pageToken")) // reset paging to original point for { @@ -39746,81 +40763,79 @@ func (c *ProjectsLocationsDatasetsDataItemsOperationsListCall) Pages(ctx context } } -// method id "aiplatform.projects.locations.datasets.dataItems.operations.wait": +// method id "aiplatform.projects.locations.datasets.datasetVersions.restore": -type ProjectsLocationsDatasetsDataItemsOperationsWaitCall struct { - s *Service - name string - urlParams_ gensupport.URLParams - ctx_ context.Context - header_ http.Header +type ProjectsLocationsDatasetsDatasetVersionsRestoreCall struct { + s *Service + name string + urlParams_ gensupport.URLParams + ifNoneMatch_ string + ctx_ context.Context + header_ http.Header } -// Wait: Waits until the specified long-running operation is done or -// reaches at most a specified timeout, returning the latest state. If -// the operation is already done, the latest state is immediately -// returned. If the timeout specified is greater than the default -// HTTP/RPC timeout, the HTTP/RPC timeout is used. If the server does -// not support this method, it returns `google.rpc.Code.UNIMPLEMENTED`. -// Note that this method is on a best-effort basis. It may return the -// latest state before the specified timeout (including immediately), -// meaning even an immediate response is no guarantee that the operation -// is done. +// Restore: Restores a dataset version. // -// - name: The name of the operation resource to wait on. -func (r *ProjectsLocationsDatasetsDataItemsOperationsService) Wait(name string) *ProjectsLocationsDatasetsDataItemsOperationsWaitCall { - c := &ProjectsLocationsDatasetsDataItemsOperationsWaitCall{s: r.s, urlParams_: make(gensupport.URLParams)} +// - name: The name of the DatasetVersion resource. Format: +// `projects/{project}/locations/{location}/datasets/{dataset}/datasetV +// ersions/{dataset_version}`. +func (r *ProjectsLocationsDatasetsDatasetVersionsService) Restore(name string) *ProjectsLocationsDatasetsDatasetVersionsRestoreCall { + c := &ProjectsLocationsDatasetsDatasetVersionsRestoreCall{s: r.s, urlParams_: make(gensupport.URLParams)} c.name = name return c } -// Timeout sets the optional parameter "timeout": The maximum duration -// to wait before timing out. If left blank, the wait will be at most -// the time permitted by the underlying HTTP/RPC protocol. If RPC -// context deadline is also specified, the shorter one will be used. -func (c *ProjectsLocationsDatasetsDataItemsOperationsWaitCall) Timeout(timeout string) *ProjectsLocationsDatasetsDataItemsOperationsWaitCall { - c.urlParams_.Set("timeout", timeout) - return c -} - // Fields allows partial responses to be retrieved. See // https://developers.google.com/gdata/docs/2.0/basics#PartialResponse // for more information. -func (c *ProjectsLocationsDatasetsDataItemsOperationsWaitCall) Fields(s ...googleapi.Field) *ProjectsLocationsDatasetsDataItemsOperationsWaitCall { +func (c *ProjectsLocationsDatasetsDatasetVersionsRestoreCall) Fields(s ...googleapi.Field) *ProjectsLocationsDatasetsDatasetVersionsRestoreCall { c.urlParams_.Set("fields", googleapi.CombineFields(s)) return c } +// IfNoneMatch sets the optional parameter which makes the operation +// fail if the object's ETag matches the given value. This is useful for +// getting updates only after the object has changed since the last +// request. Use googleapi.IsNotModified to check whether the response +// error from Do is the result of In-None-Match. +func (c *ProjectsLocationsDatasetsDatasetVersionsRestoreCall) IfNoneMatch(entityTag string) *ProjectsLocationsDatasetsDatasetVersionsRestoreCall { + c.ifNoneMatch_ = entityTag + return c +} + // Context sets the context to be used in this call's Do method. Any // pending HTTP request will be aborted if the provided context is // canceled. -func (c *ProjectsLocationsDatasetsDataItemsOperationsWaitCall) Context(ctx context.Context) *ProjectsLocationsDatasetsDataItemsOperationsWaitCall { +func (c *ProjectsLocationsDatasetsDatasetVersionsRestoreCall) Context(ctx context.Context) *ProjectsLocationsDatasetsDatasetVersionsRestoreCall { c.ctx_ = ctx return c } // Header returns an http.Header that can be modified by the caller to // add HTTP headers to the request. -func (c *ProjectsLocationsDatasetsDataItemsOperationsWaitCall) Header() http.Header { +func (c *ProjectsLocationsDatasetsDatasetVersionsRestoreCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) } return c.header_ } -func (c *ProjectsLocationsDatasetsDataItemsOperationsWaitCall) doRequest(alt string) (*http.Response, error) { +func (c *ProjectsLocationsDatasetsDatasetVersionsRestoreCall) doRequest(alt string) (*http.Response, error) { reqHeaders := make(http.Header) reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version) for k, v := range c.header_ { reqHeaders[k] = v } reqHeaders.Set("User-Agent", c.s.userAgent()) + if c.ifNoneMatch_ != "" { + reqHeaders.Set("If-None-Match", c.ifNoneMatch_) + } var body io.Reader = nil c.urlParams_.Set("alt", alt) c.urlParams_.Set("prettyPrint", "false") - urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+name}:wait") + urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+name}:restore") urls += "?" + c.urlParams_.Encode() - req, err := http.NewRequest("POST", urls, body) + req, err := http.NewRequest("GET", urls, body) if err != nil { return nil, err } @@ -39831,14 +40846,14 @@ func (c *ProjectsLocationsDatasetsDataItemsOperationsWaitCall) doRequest(alt str return gensupport.SendRequest(c.ctx_, c.s.client, req) } -// Do executes the "aiplatform.projects.locations.datasets.dataItems.operations.wait" call. +// Do executes the "aiplatform.projects.locations.datasets.datasetVersions.restore" call. // Exactly one of *GoogleLongrunningOperation or error will be non-nil. // Any non-2xx status code is an error. Response headers are in either // *GoogleLongrunningOperation.ServerResponse.Header or (if a response // was returned at all) in error.(*googleapi.Error).Header. Use // googleapi.IsNotModified to check whether the returned error was // because http.StatusNotModified was returned. -func (c *ProjectsLocationsDatasetsDataItemsOperationsWaitCall) Do(opts ...googleapi.CallOption) (*GoogleLongrunningOperation, error) { +func (c *ProjectsLocationsDatasetsDatasetVersionsRestoreCall) Do(opts ...googleapi.CallOption) (*GoogleLongrunningOperation, error) { gensupport.SetOptions(c.urlParams_, opts...) res, err := c.doRequest("json") if res != nil && res.StatusCode == http.StatusNotModified { @@ -39869,29 +40884,23 @@ func (c *ProjectsLocationsDatasetsDataItemsOperationsWaitCall) Do(opts ...google } return ret, nil // { - // "description": "Waits until the specified long-running operation is done or reaches at most a specified timeout, returning the latest state. If the operation is already done, the latest state is immediately returned. If the timeout specified is greater than the default HTTP/RPC timeout, the HTTP/RPC timeout is used. If the server does not support this method, it returns `google.rpc.Code.UNIMPLEMENTED`. Note that this method is on a best-effort basis. It may return the latest state before the specified timeout (including immediately), meaning even an immediate response is no guarantee that the operation is done.", - // "flatPath": "v1/projects/{projectsId}/locations/{locationsId}/datasets/{datasetsId}/dataItems/{dataItemsId}/operations/{operationsId}:wait", - // "httpMethod": "POST", - // "id": "aiplatform.projects.locations.datasets.dataItems.operations.wait", + // "description": "Restores a dataset version.", + // "flatPath": "v1/projects/{projectsId}/locations/{locationsId}/datasets/{datasetsId}/datasetVersions/{datasetVersionsId}:restore", + // "httpMethod": "GET", + // "id": "aiplatform.projects.locations.datasets.datasetVersions.restore", // "parameterOrder": [ // "name" // ], // "parameters": { // "name": { - // "description": "The name of the operation resource to wait on.", + // "description": "Required. The name of the DatasetVersion resource. Format: `projects/{project}/locations/{location}/datasets/{dataset}/datasetVersions/{dataset_version}`", // "location": "path", - // "pattern": "^projects/[^/]+/locations/[^/]+/datasets/[^/]+/dataItems/[^/]+/operations/[^/]+$", + // "pattern": "^projects/[^/]+/locations/[^/]+/datasets/[^/]+/datasetVersions/[^/]+$", // "required": true, // "type": "string" - // }, - // "timeout": { - // "description": "The maximum duration to wait before timing out. If left blank, the wait will be at most the time permitted by the underlying HTTP/RPC protocol. If RPC context deadline is also specified, the shorter one will be used.", - // "format": "google-duration", - // "location": "query", - // "type": "string" // } // }, - // "path": "v1/{+name}:wait", + // "path": "v1/{+name}:restore", // "response": { // "$ref": "GoogleLongrunningOperation" // }, diff --git a/aiplatform/v1beta1/aiplatform-api.json b/aiplatform/v1beta1/aiplatform-api.json index 358fa800875..159b3a53d7a 100644 --- a/aiplatform/v1beta1/aiplatform-api.json +++ b/aiplatform/v1beta1/aiplatform-api.json @@ -2067,6 +2067,171 @@ } } }, + "datasetVersions": { + "methods": { + "create": { + "description": "Create a version from a Dataset.", + "flatPath": "v1beta1/projects/{projectsId}/locations/{locationsId}/datasets/{datasetsId}/datasetVersions", + "httpMethod": "POST", + "id": "aiplatform.projects.locations.datasets.datasetVersions.create", + "parameterOrder": [ + "parent" + ], + "parameters": { + "parent": { + "description": "Required. The name of the Dataset resource. Format: `projects/{project}/locations/{location}/datasets/{dataset}`", + "location": "path", + "pattern": "^projects/[^/]+/locations/[^/]+/datasets/[^/]+$", + "required": true, + "type": "string" + } + }, + "path": "v1beta1/{+parent}/datasetVersions", + "request": { + "$ref": "GoogleCloudAiplatformV1beta1DatasetVersion" + }, + "response": { + "$ref": "GoogleLongrunningOperation" + }, + "scopes": [ + "https://www.googleapis.com/auth/cloud-platform" + ] + }, + "delete": { + "description": "Deletes a Dataset version.", + "flatPath": "v1beta1/projects/{projectsId}/locations/{locationsId}/datasets/{datasetsId}/datasetVersions/{datasetVersionsId}", + "httpMethod": "DELETE", + "id": "aiplatform.projects.locations.datasets.datasetVersions.delete", + "parameterOrder": [ + "name" + ], + "parameters": { + "name": { + "description": "Required. The resource name of the Dataset version to delete. Format: `projects/{project}/locations/{location}/datasets/{dataset}/datasetVersions/{dataset_version}`", + "location": "path", + "pattern": "^projects/[^/]+/locations/[^/]+/datasets/[^/]+/datasetVersions/[^/]+$", + "required": true, + "type": "string" + } + }, + "path": "v1beta1/{+name}", + "response": { + "$ref": "GoogleLongrunningOperation" + }, + "scopes": [ + "https://www.googleapis.com/auth/cloud-platform" + ] + }, + "get": { + "description": "Gets a Dataset version.", + "flatPath": "v1beta1/projects/{projectsId}/locations/{locationsId}/datasets/{datasetsId}/datasetVersions/{datasetVersionsId}", + "httpMethod": "GET", + "id": "aiplatform.projects.locations.datasets.datasetVersions.get", + "parameterOrder": [ + "name" + ], + "parameters": { + "name": { + "description": "Required. The resource name of the Dataset version to delete. Format: `projects/{project}/locations/{location}/datasets/{dataset}/datasetVersions/{dataset_version}`", + "location": "path", + "pattern": "^projects/[^/]+/locations/[^/]+/datasets/[^/]+/datasetVersions/[^/]+$", + "required": true, + "type": "string" + }, + "readMask": { + "description": "Mask specifying which fields to read.", + "format": "google-fieldmask", + "location": "query", + "type": "string" + } + }, + "path": "v1beta1/{+name}", + "response": { + "$ref": "GoogleCloudAiplatformV1beta1DatasetVersion" + }, + "scopes": [ + "https://www.googleapis.com/auth/cloud-platform" + ] + }, + "list": { + "description": "Lists DatasetVersions in a Dataset.", + "flatPath": "v1beta1/projects/{projectsId}/locations/{locationsId}/datasets/{datasetsId}/datasetVersions", + "httpMethod": "GET", + "id": "aiplatform.projects.locations.datasets.datasetVersions.list", + "parameterOrder": [ + "parent" + ], + "parameters": { + "filter": { + "description": "Optional. The standard list filter.", + "location": "query", + "type": "string" + }, + "orderBy": { + "description": "Optional. A comma-separated list of fields to order by, sorted in ascending order. Use \"desc\" after a field name for descending.", + "location": "query", + "type": "string" + }, + "pageSize": { + "description": "Optional. The standard list page size.", + "format": "int32", + "location": "query", + "type": "integer" + }, + "pageToken": { + "description": "Optional. The standard list page token.", + "location": "query", + "type": "string" + }, + "parent": { + "description": "Required. The resource name of the Dataset to list DatasetVersions from. Format: `projects/{project}/locations/{location}/datasets/{dataset}`", + "location": "path", + "pattern": "^projects/[^/]+/locations/[^/]+/datasets/[^/]+$", + "required": true, + "type": "string" + }, + "readMask": { + "description": "Optional. Mask specifying which fields to read.", + "format": "google-fieldmask", + "location": "query", + "type": "string" + } + }, + "path": "v1beta1/{+parent}/datasetVersions", + "response": { + "$ref": "GoogleCloudAiplatformV1beta1ListDatasetVersionsResponse" + }, + "scopes": [ + "https://www.googleapis.com/auth/cloud-platform" + ] + }, + "restore": { + "description": "Restores a dataset version.", + "flatPath": "v1beta1/projects/{projectsId}/locations/{locationsId}/datasets/{datasetsId}/datasetVersions/{datasetVersionsId}:restore", + "httpMethod": "GET", + "id": "aiplatform.projects.locations.datasets.datasetVersions.restore", + "parameterOrder": [ + "name" + ], + "parameters": { + "name": { + "description": "Required. The name of the DatasetVersion resource. Format: `projects/{project}/locations/{location}/datasets/{dataset}/datasetVersions/{dataset_version}`", + "location": "path", + "pattern": "^projects/[^/]+/locations/[^/]+/datasets/[^/]+/datasetVersions/[^/]+$", + "required": true, + "type": "string" + } + }, + "path": "v1beta1/{+name}:restore", + "response": { + "$ref": "GoogleLongrunningOperation" + }, + "scopes": [ + "https://www.googleapis.com/auth/cloud-platform" + ] + } + } + }, "operations": { "methods": { "cancel": { @@ -17141,6 +17306,39 @@ }, "type": "object" }, + "GoogleCloudAiplatformV1beta1DatasetVersion": { + "description": "Describes the dataset version.", + "id": "GoogleCloudAiplatformV1beta1DatasetVersion", + "properties": { + "bigQueryDatasetName": { + "description": "Output only. Name of the associated BigQuery dataset.", + "readOnly": true, + "type": "string" + }, + "createTime": { + "description": "Output only. Timestamp when this DatasetVersion was created.", + "format": "google-datetime", + "readOnly": true, + "type": "string" + }, + "etag": { + "description": "Used to perform consistent read-modify-write updates. If not set, a blind \"overwrite\" update happens.", + "type": "string" + }, + "name": { + "description": "Output only. The resource name of the DatasetVersion.", + "readOnly": true, + "type": "string" + }, + "updateTime": { + "description": "Output only. Timestamp when this DatasetVersion was last updated.", + "format": "google-datetime", + "readOnly": true, + "type": "string" + } + }, + "type": "object" + }, "GoogleCloudAiplatformV1beta1DedicatedResources": { "description": "A description of resources that are dedicated to a DeployedModel, and that need a higher degree of manual configuration.", "id": "GoogleCloudAiplatformV1beta1DedicatedResources", @@ -18617,6 +18815,10 @@ "description": "An expression for filtering what part of the Dataset is to be exported. Only Annotations that match this filter will be exported. The filter syntax is the same as in ListAnnotations.", "type": "string" }, + "filterSplit": { + "$ref": "GoogleCloudAiplatformV1beta1ExportFilterSplit", + "description": "Split based on the provided filters for each set." + }, "fractionSplit": { "$ref": "GoogleCloudAiplatformV1beta1ExportFractionSplit", "description": "Split based on fractions defining the size of each set." @@ -18782,6 +18984,25 @@ "properties": {}, "type": "object" }, + "GoogleCloudAiplatformV1beta1ExportFilterSplit": { + "description": "Assigns input data to training, validation, and test sets based on the given filters, data pieces not matched by any filter are ignored. Currently only supported for Datasets containing DataItems. If any of the filters in this message are to match nothing, then they can be set as '-' (the minus sign). Supported only for unstructured Datasets.", + "id": "GoogleCloudAiplatformV1beta1ExportFilterSplit", + "properties": { + "testFilter": { + "description": "Required. A filter on DataItems of the Dataset. DataItems that match this filter are used to test the Model. A filter with same syntax as the one used in DatasetService.ListDataItems may be used. If a single DataItem is matched by more than one of the FilterSplit filters, then it is assigned to the first set that applies to it in the training, validation, test order.", + "type": "string" + }, + "trainingFilter": { + "description": "Required. A filter on DataItems of the Dataset. DataItems that match this filter are used to train the Model. A filter with same syntax as the one used in DatasetService.ListDataItems may be used. If a single DataItem is matched by more than one of the FilterSplit filters, then it is assigned to the first set that applies to it in the training, validation, test order.", + "type": "string" + }, + "validationFilter": { + "description": "Required. A filter on DataItems of the Dataset. DataItems that match this filter are used to validate the Model. A filter with same syntax as the one used in DatasetService.ListDataItems may be used. If a single DataItem is matched by more than one of the FilterSplit filters, then it is assigned to the first set that applies to it in the training, validation, test order.", + "type": "string" + } + }, + "type": "object" + }, "GoogleCloudAiplatformV1beta1ExportFractionSplit": { "description": "Assigns the input data to training, validation, and test sets as per the given fractions. Any of `training_fraction`, `validation_fraction` and `test_fraction` may optionally be provided, they must sum to up to 1. If the provided ones sum to less than 1, the remainder is assigned to sets as decided by Vertex AI. If none of the fractions are set, by default roughly 80% of data is used for training, 10% for validation, and 10% for test.", "id": "GoogleCloudAiplatformV1beta1ExportFractionSplit", @@ -20509,6 +20730,24 @@ }, "type": "object" }, + "GoogleCloudAiplatformV1beta1ListDatasetVersionsResponse": { + "description": "Response message for DatasetService.ListDatasetVersions.", + "id": "GoogleCloudAiplatformV1beta1ListDatasetVersionsResponse", + "properties": { + "datasetVersions": { + "description": "A list of DatasetVersions that matches the specified filter in the request.", + "items": { + "$ref": "GoogleCloudAiplatformV1beta1DatasetVersion" + }, + "type": "array" + }, + "nextPageToken": { + "description": "The standard List next-page token.", + "type": "string" + } + }, + "type": "object" + }, "GoogleCloudAiplatformV1beta1ListDatasetsResponse": { "description": "Response message for DatasetService.ListDatasets.", "id": "GoogleCloudAiplatformV1beta1ListDatasetsResponse", @@ -23262,7 +23501,7 @@ "additionalProperties": { "type": "string" }, - "description": "The labels with user-defined metadata to organize your NotebookRuntime. Label keys and values can be no longer than 64 characters (Unicode codepoints), can only contain lowercase letters, numeric characters, underscores and dashes. International characters are allowed. No more than 64 user labels can be associated with one Dataset (System labels are excluded). See https://goo.gl/xmQnxf for more information and examples of labels. System reserved label keys are prefixed with \"aiplatform.googleapis.com/\" and are immutable. Following system labels exist for NotebookRuntime: * \"aiplatform.googleapis.com/notebook_runtime_gce_instance_id\": output only, its value is the Compute Engine instance id. * \"aiplatform.googleapis.com/colab_enterprise_entry_service\": its value is either \"BigQuery\" or \"Vertex\"; if absent, it should be \"Vertex\". This is to describe the entry service, either BigQuery or Vertex.", + "description": "The labels with user-defined metadata to organize your NotebookRuntime. Label keys and values can be no longer than 64 characters (Unicode codepoints), can only contain lowercase letters, numeric characters, underscores and dashes. International characters are allowed. No more than 64 user labels can be associated with one NotebookRuntime (System labels are excluded). See https://goo.gl/xmQnxf for more information and examples of labels. System reserved label keys are prefixed with \"aiplatform.googleapis.com/\" and are immutable. Following system labels exist for NotebookRuntime: * \"aiplatform.googleapis.com/notebook_runtime_gce_instance_id\": output only, its value is the Compute Engine instance id. * \"aiplatform.googleapis.com/colab_enterprise_entry_service\": its value is either \"bigquery\" or \"vertex\"; if absent, it should be \"vertex\". This is to describe the entry service, either BigQuery or Vertex.", "type": "object" }, "name": { @@ -23275,6 +23514,21 @@ "description": "Output only. The pointer to NotebookRuntimeTemplate this NotebookRuntime is created from.", "readOnly": true }, + "notebookRuntimeType": { + "description": "Output only. The type of the notebook runtime.", + "enum": [ + "NOTEBOOK_RUNTIME_TYPE_UNSPECIFIED", + "USER_DEFINED", + "ONE_CLICK" + ], + "enumDescriptions": [ + "Unspecified notebook runtime type, NotebookRuntimeType will default to USER_DEFINED.", + "runtime or template with coustomized configurations from user.", + "runtime or template with system defined configurations." + ], + "readOnly": true, + "type": "string" + }, "proxyUri": { "description": "Output only. The proxy endpoint used to access the NotebookRuntime.", "readOnly": true, @@ -23383,6 +23637,20 @@ "$ref": "GoogleCloudAiplatformV1beta1NetworkSpec", "description": "Optional. Network spec." }, + "notebookRuntimeType": { + "description": "Optional. Immutable. The type of the notebook runtime template.", + "enum": [ + "NOTEBOOK_RUNTIME_TYPE_UNSPECIFIED", + "USER_DEFINED", + "ONE_CLICK" + ], + "enumDescriptions": [ + "Unspecified notebook runtime type, NotebookRuntimeType will default to USER_DEFINED.", + "runtime or template with coustomized configurations from user.", + "runtime or template with system defined configurations." + ], + "type": "string" + }, "serviceAccount": { "description": "The service account that the runtime workload runs as. You can use any service account within the same project, but you must have the service account user permission to use the instance. If not specified, the [Compute Engine default service account](https://cloud.google.com/compute/docs/access/service-accounts#default_service_account) is used.", "type": "string" @@ -23470,11 +23738,11 @@ "type": "string" }, "network": { - "description": "Optional. The full name of the Compute Engine [network](/compute/docs/networks-and-firewalls#networks) to peered with Vertex AI to host the persistent resources. For example, `projects/12345/global/networks/myVPC`. [Format](/compute/docs/reference/rest/v1/networks/insert) is of the form `projects/{project}/global/networks/{network}`. Where {project} is a project number, as in `12345`, and {network} is a network name. To specify this field, you must have already [configured VPC Network Peering for Vertex AI](https://cloud.google.com/vertex-ai/docs/general/vpc-peering). If this field is left unspecified, the resources is not peered with any network.", + "description": "Optional. The full name of the Compute Engine [network](/compute/docs/networks-and-firewalls#networks) to peered with Vertex AI to host the persistent resources. For example, `projects/12345/global/networks/myVPC`. [Format](/compute/docs/reference/rest/v1/networks/insert) is of the form `projects/{project}/global/networks/{network}`. Where {project} is a project number, as in `12345`, and {network} is a network name. To specify this field, you must have already [configured VPC Network Peering for Vertex AI](https://cloud.google.com/vertex-ai/docs/general/vpc-peering). If this field is left unspecified, the resources aren't peered with any network.", "type": "string" }, "reservedIpRanges": { - "description": "Optional. A list of names for the reserved ip ranges under the VPC network that can be used for this persistent resource. If set, we will deploy the persistent resource within the provided ip ranges. Otherwise, the persistent resource will be deployed to any ip ranges under the provided VPC network. Example: ['vertex-ai-ip-range'].", + "description": "Optional. A list of names for the reserved IP ranges under the VPC network that can be used for this persistent resource. If set, we will deploy the persistent resource within the provided IP ranges. Otherwise, the persistent resource is deployed to any IP ranges under the provided VPC network. Example: ['vertex-ai-ip-range'].", "items": { "type": "string" }, @@ -23494,7 +23762,7 @@ }, "resourceRuntimeSpec": { "$ref": "GoogleCloudAiplatformV1beta1ResourceRuntimeSpec", - "description": "Optional. Persistent Resource runtime spec. Used for e.g. Ray cluster configuration." + "description": "Optional. Persistent Resource runtime spec. For example, used for Ray cluster configuration." }, "startTime": { "description": "Output only. Time when the PersistentResource for the first time entered the `RUNNING` state.", @@ -23647,7 +23915,7 @@ "readOnly": true }, "templateUri": { - "description": "A template uri from where the PipelineJob.pipeline_spec, if empty, will be downloaded.", + "description": "A template uri from where the PipelineJob.pipeline_spec, if empty, will be downloaded. Currently, only uri from Vertex Template Registry \u0026 Gallery is supported. Reference to https://cloud.google.com/vertex-ai/docs/pipelines/create-pipeline-template.", "type": "string" }, "updateTime": { @@ -24662,18 +24930,18 @@ "id": "GoogleCloudAiplatformV1beta1RaySpec", "properties": { "headNodeResourcePoolId": { - "description": "Optional. This will be used to indicate which resource pool will serve as the Ray head node(the first node within that pool). Will use the machine from the first workerpool as the head node by default if this field is not set.", + "description": "Optional. This will be used to indicate which resource pool will serve as the Ray head node(the first node within that pool). Will use the machine from the first workerpool as the head node by default if this field isn't set.", "type": "string" }, "imageUri": { - "description": "Optional. Default image for user to choose a preferred ML framework(e.g. tensorflow or Pytorch) by choosing from Vertex prebuild images(https://cloud.google.com/vertex-ai/docs/training/pre-built-containers). Either this or the resource_pool_images is required. Use this field if you need all the resource pools to have the same Ray image, Otherwise, use the {@code resource_pool_images} field.", + "description": "Optional. Default image for user to choose a preferred ML framework (for example, TensorFlow or Pytorch) by choosing from [Vertex prebuilt images](https://cloud.google.com/vertex-ai/docs/training/pre-built-containers). Either this or the resource_pool_images is required. Use this field if you need all the resource pools to have the same Ray image. Otherwise, use the {@code resource_pool_images} field.", "type": "string" }, "resourcePoolImages": { "additionalProperties": { "type": "string" }, - "description": "Optional. Required if image_uri is not set. A map of resource_pool_id to prebuild Ray image if user need to use different images for different head/worker pools. This map needs to cover all the resource pool ids. Example: { \"ray_head_node_pool\": \"head image\" \"ray_worker_node_pool1\": \"worker image\" \"ray_worker_node_pool2\": \"another worker image\" }", + "description": "Optional. Required if image_uri isn't set. A map of resource_pool_id to prebuild Ray image if user need to use different images for different head/worker pools. This map needs to cover all the resource pool ids. Example: { \"ray_head_node_pool\": \"head image\" \"ray_worker_node_pool1\": \"worker image\" \"ray_worker_node_pool2\": \"another worker image\" }", "type": "object" } }, @@ -24968,7 +25236,7 @@ "type": "object" }, "GoogleCloudAiplatformV1beta1ResourcePool": { - "description": "Represents the spec a group of resources of same type, e.g. machine, disk and accelerators, in a PersistentResource.", + "description": "Represents the spec of a group of resources of the same type, for example machine type, disk, and accelerators, in a PersistentResource.", "id": "GoogleCloudAiplatformV1beta1ResourcePool", "properties": { "autoscalingSpec": { @@ -24980,7 +25248,7 @@ "description": "Optional. Disk spec for the machine in this node pool." }, "id": { - "description": "Immutable. The unique ID in a PersistentResource to refer the this resource pool. User can specify it if need to use it, otherwise we will generate it automatically.", + "description": "Immutable. The unique ID in a PersistentResource for referring to this resource pool. User can specify it if necessary. Otherwise, it's generated automatically.", "type": "string" }, "machineSpec": { @@ -25039,7 +25307,7 @@ "type": "object" }, "GoogleCloudAiplatformV1beta1ResourceRuntimeSpec": { - "description": "Configure runtime on a PersistentResource instance, including but may not limited to: * Service accounts used to run the workloads; * Whether make it a dedicated Ray Cluster;", + "description": "Configuration for the runtime on a PersistentResource instance, including but not limited to: * Service accounts used to run the workloads. * Whether to make it a dedicated Ray Cluster.", "id": "GoogleCloudAiplatformV1beta1ResourceRuntimeSpec", "properties": { "raySpec": { @@ -29108,11 +29376,11 @@ "id": "GoogleCloudAiplatformV1beta1ServiceAccountSpec", "properties": { "enableCustomServiceAccount": { - "description": "Required. If true, custom user-managed service account is enforced to run any workloads (e.g. Vertex Jobs) on the resource; Otherwise, will always use [Vertex AI Custom Code Service Agent](https://cloud.google.com/vertex-ai/docs/general/access-control#service-agents)", + "description": "Required. If true, custom user-managed service account is enforced to run any workloads (for example, Vertex Jobs) on the resource. Otherwise, uses the [Vertex AI Custom Code Service Agent](https://cloud.google.com/vertex-ai/docs/general/access-control#service-agents).", "type": "boolean" }, "serviceAccount": { - "description": "Optional. Default service account that this PersistentResource's workloads run as. The workloads include: * Any runtime specified via `ResourceRuntimeSpec` on creation time, e.g. Ray; * Jobs submitted to PersistentResource, if no other service account specified in the job specs. Only works when custom service account is enabled and users have the `iam.serviceAccounts.actAs` permission on this service account. Required if any containers specified in `ResourceRuntimeSpec`.", + "description": "Optional. Default service account that this PersistentResource's workloads run as. The workloads include: * Any runtime specified via `ResourceRuntimeSpec` on creation time, for example, Ray. * Jobs submitted to PersistentResource, if no other service account specified in the job specs. Only works when custom service account is enabled and users have the `iam.serviceAccounts.actAs` permission on this service account. Required if any containers are specified in `ResourceRuntimeSpec`.", "type": "string" } }, diff --git a/aiplatform/v1beta1/aiplatform-gen.go b/aiplatform/v1beta1/aiplatform-gen.go index 0a878a1c848..dd340098caf 100644 --- a/aiplatform/v1beta1/aiplatform-gen.go +++ b/aiplatform/v1beta1/aiplatform-gen.go @@ -342,6 +342,7 @@ func NewProjectsLocationsDatasetsService(s *Service) *ProjectsLocationsDatasetsS rs := &ProjectsLocationsDatasetsService{s: s} rs.AnnotationSpecs = NewProjectsLocationsDatasetsAnnotationSpecsService(s) rs.DataItems = NewProjectsLocationsDatasetsDataItemsService(s) + rs.DatasetVersions = NewProjectsLocationsDatasetsDatasetVersionsService(s) rs.Operations = NewProjectsLocationsDatasetsOperationsService(s) rs.SavedQueries = NewProjectsLocationsDatasetsSavedQueriesService(s) return rs @@ -354,6 +355,8 @@ type ProjectsLocationsDatasetsService struct { DataItems *ProjectsLocationsDatasetsDataItemsService + DatasetVersions *ProjectsLocationsDatasetsDatasetVersionsService + Operations *ProjectsLocationsDatasetsOperationsService SavedQueries *ProjectsLocationsDatasetsSavedQueriesService @@ -425,6 +428,15 @@ type ProjectsLocationsDatasetsDataItemsOperationsService struct { s *Service } +func NewProjectsLocationsDatasetsDatasetVersionsService(s *Service) *ProjectsLocationsDatasetsDatasetVersionsService { + rs := &ProjectsLocationsDatasetsDatasetVersionsService{s: s} + return rs +} + +type ProjectsLocationsDatasetsDatasetVersionsService struct { + s *Service +} + func NewProjectsLocationsDatasetsOperationsService(s *Service) *ProjectsLocationsDatasetsOperationsService { rs := &ProjectsLocationsDatasetsOperationsService{s: s} return rs @@ -5367,6 +5379,56 @@ func (s *GoogleCloudAiplatformV1beta1Dataset) MarshalJSON() ([]byte, error) { return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } +// GoogleCloudAiplatformV1beta1DatasetVersion: Describes the dataset +// version. +type GoogleCloudAiplatformV1beta1DatasetVersion struct { + // BigQueryDatasetName: Output only. Name of the associated BigQuery + // dataset. + BigQueryDatasetName string `json:"bigQueryDatasetName,omitempty"` + + // CreateTime: Output only. Timestamp when this DatasetVersion was + // created. + CreateTime string `json:"createTime,omitempty"` + + // Etag: Used to perform consistent read-modify-write updates. If not + // set, a blind "overwrite" update happens. + Etag string `json:"etag,omitempty"` + + // Name: Output only. The resource name of the DatasetVersion. + Name string `json:"name,omitempty"` + + // UpdateTime: Output only. Timestamp when this DatasetVersion was last + // updated. + UpdateTime string `json:"updateTime,omitempty"` + + // ServerResponse contains the HTTP response code and headers from the + // server. + googleapi.ServerResponse `json:"-"` + + // ForceSendFields is a list of field names (e.g. "BigQueryDatasetName") + // to unconditionally include in API requests. By default, fields with + // empty or default values are omitted from API requests. However, any + // non-pointer, non-interface field appearing in ForceSendFields will be + // sent to the server regardless of whether the field is empty or not. + // This may be used to include empty fields in Patch requests. + ForceSendFields []string `json:"-"` + + // NullFields is a list of field names (e.g. "BigQueryDatasetName") to + // include in API requests with the JSON null value. By default, fields + // with empty values are omitted from API requests. However, any field + // with an empty value appearing in NullFields will be sent to the + // server as null. It is an error if a field in this list has a + // non-empty value. This may be used to include null fields in Patch + // requests. + NullFields []string `json:"-"` +} + +func (s *GoogleCloudAiplatformV1beta1DatasetVersion) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudAiplatformV1beta1DatasetVersion + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + // GoogleCloudAiplatformV1beta1DedicatedResources: A description of // resources that are dedicated to a DeployedModel, and that need a // higher degree of manual configuration. @@ -8162,6 +8224,9 @@ type GoogleCloudAiplatformV1beta1ExportDataConfig struct { // ListAnnotations. AnnotationsFilter string `json:"annotationsFilter,omitempty"` + // FilterSplit: Split based on the provided filters for each set. + FilterSplit *GoogleCloudAiplatformV1beta1ExportFilterSplit `json:"filterSplit,omitempty"` + // FractionSplit: Split based on fractions defining the size of each // set. FractionSplit *GoogleCloudAiplatformV1beta1ExportFractionSplit `json:"fractionSplit,omitempty"` @@ -8540,6 +8605,62 @@ func (s *GoogleCloudAiplatformV1beta1ExportFeatureValuesRequestSnapshotExport) M type GoogleCloudAiplatformV1beta1ExportFeatureValuesResponse struct { } +// GoogleCloudAiplatformV1beta1ExportFilterSplit: Assigns input data to +// training, validation, and test sets based on the given filters, data +// pieces not matched by any filter are ignored. Currently only +// supported for Datasets containing DataItems. If any of the filters in +// this message are to match nothing, then they can be set as '-' (the +// minus sign). Supported only for unstructured Datasets. +type GoogleCloudAiplatformV1beta1ExportFilterSplit struct { + // TestFilter: Required. A filter on DataItems of the Dataset. DataItems + // that match this filter are used to test the Model. A filter with same + // syntax as the one used in DatasetService.ListDataItems may be used. + // If a single DataItem is matched by more than one of the FilterSplit + // filters, then it is assigned to the first set that applies to it in + // the training, validation, test order. + TestFilter string `json:"testFilter,omitempty"` + + // TrainingFilter: Required. A filter on DataItems of the Dataset. + // DataItems that match this filter are used to train the Model. A + // filter with same syntax as the one used in + // DatasetService.ListDataItems may be used. If a single DataItem is + // matched by more than one of the FilterSplit filters, then it is + // assigned to the first set that applies to it in the training, + // validation, test order. + TrainingFilter string `json:"trainingFilter,omitempty"` + + // ValidationFilter: Required. A filter on DataItems of the Dataset. + // DataItems that match this filter are used to validate the Model. A + // filter with same syntax as the one used in + // DatasetService.ListDataItems may be used. If a single DataItem is + // matched by more than one of the FilterSplit filters, then it is + // assigned to the first set that applies to it in the training, + // validation, test order. + ValidationFilter string `json:"validationFilter,omitempty"` + + // ForceSendFields is a list of field names (e.g. "TestFilter") to + // unconditionally include in API requests. By default, fields with + // empty or default values are omitted from API requests. However, any + // non-pointer, non-interface field appearing in ForceSendFields will be + // sent to the server regardless of whether the field is empty or not. + // This may be used to include empty fields in Patch requests. + ForceSendFields []string `json:"-"` + + // NullFields is a list of field names (e.g. "TestFilter") to include in + // API requests with the JSON null value. By default, fields with empty + // values are omitted from API requests. However, any field with an + // empty value appearing in NullFields will be sent to the server as + // null. It is an error if a field in this list has a non-empty value. + // This may be used to include null fields in Patch requests. + NullFields []string `json:"-"` +} + +func (s *GoogleCloudAiplatformV1beta1ExportFilterSplit) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudAiplatformV1beta1ExportFilterSplit + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + // GoogleCloudAiplatformV1beta1ExportFractionSplit: Assigns the input // data to training, validation, and test sets as per the given // fractions. Any of `training_fraction`, `validation_fraction` and @@ -11819,6 +11940,44 @@ func (s *GoogleCloudAiplatformV1beta1ListDataLabelingJobsResponse) MarshalJSON() return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } +// GoogleCloudAiplatformV1beta1ListDatasetVersionsResponse: Response +// message for DatasetService.ListDatasetVersions. +type GoogleCloudAiplatformV1beta1ListDatasetVersionsResponse struct { + // DatasetVersions: A list of DatasetVersions that matches the specified + // filter in the request. + DatasetVersions []*GoogleCloudAiplatformV1beta1DatasetVersion `json:"datasetVersions,omitempty"` + + // NextPageToken: The standard List next-page token. + NextPageToken string `json:"nextPageToken,omitempty"` + + // ServerResponse contains the HTTP response code and headers from the + // server. + googleapi.ServerResponse `json:"-"` + + // ForceSendFields is a list of field names (e.g. "DatasetVersions") to + // unconditionally include in API requests. By default, fields with + // empty or default values are omitted from API requests. However, any + // non-pointer, non-interface field appearing in ForceSendFields will be + // sent to the server regardless of whether the field is empty or not. + // This may be used to include empty fields in Patch requests. + ForceSendFields []string `json:"-"` + + // NullFields is a list of field names (e.g. "DatasetVersions") to + // include in API requests with the JSON null value. By default, fields + // with empty values are omitted from API requests. However, any field + // with an empty value appearing in NullFields will be sent to the + // server as null. It is an error if a field in this list has a + // non-empty value. This may be used to include null fields in Patch + // requests. + NullFields []string `json:"-"` +} + +func (s *GoogleCloudAiplatformV1beta1ListDatasetVersionsResponse) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudAiplatformV1beta1ListDatasetVersionsResponse + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + // GoogleCloudAiplatformV1beta1ListDatasetsResponse: Response message // for DatasetService.ListDatasets. type GoogleCloudAiplatformV1beta1ListDatasetsResponse struct { @@ -16892,14 +17051,15 @@ type GoogleCloudAiplatformV1beta1NotebookRuntime struct { // characters (Unicode codepoints), can only contain lowercase letters, // numeric characters, underscores and dashes. International characters // are allowed. No more than 64 user labels can be associated with one - // Dataset (System labels are excluded). See https://goo.gl/xmQnxf for - // more information and examples of labels. System reserved label keys - // are prefixed with "aiplatform.googleapis.com/" and are immutable. - // Following system labels exist for NotebookRuntime: * + // NotebookRuntime (System labels are excluded). See + // https://goo.gl/xmQnxf for more information and examples of labels. + // System reserved label keys are prefixed with + // "aiplatform.googleapis.com/" and are immutable. Following system + // labels exist for NotebookRuntime: * // "aiplatform.googleapis.com/notebook_runtime_gce_instance_id": output // only, its value is the Compute Engine instance id. * // "aiplatform.googleapis.com/colab_enterprise_entry_service": its value - // is either "BigQuery" or "Vertex"; if absent, it should be "Vertex". + // is either "bigquery" or "vertex"; if absent, it should be "vertex". // This is to describe the entry service, either BigQuery or Vertex. Labels map[string]string `json:"labels,omitempty"` @@ -16910,6 +17070,17 @@ type GoogleCloudAiplatformV1beta1NotebookRuntime struct { // NotebookRuntimeTemplate this NotebookRuntime is created from. NotebookRuntimeTemplateRef *GoogleCloudAiplatformV1beta1NotebookRuntimeTemplateRef `json:"notebookRuntimeTemplateRef,omitempty"` + // NotebookRuntimeType: Output only. The type of the notebook runtime. + // + // Possible values: + // "NOTEBOOK_RUNTIME_TYPE_UNSPECIFIED" - Unspecified notebook runtime + // type, NotebookRuntimeType will default to USER_DEFINED. + // "USER_DEFINED" - runtime or template with coustomized + // configurations from user. + // "ONE_CLICK" - runtime or template with system defined + // configurations. + NotebookRuntimeType string `json:"notebookRuntimeType,omitempty"` + // ProxyUri: Output only. The proxy endpoint used to access the // NotebookRuntime. ProxyUri string `json:"proxyUri,omitempty"` @@ -17022,6 +17193,18 @@ type GoogleCloudAiplatformV1beta1NotebookRuntimeTemplate struct { // NetworkSpec: Optional. Network spec. NetworkSpec *GoogleCloudAiplatformV1beta1NetworkSpec `json:"networkSpec,omitempty"` + // NotebookRuntimeType: Optional. Immutable. The type of the notebook + // runtime template. + // + // Possible values: + // "NOTEBOOK_RUNTIME_TYPE_UNSPECIFIED" - Unspecified notebook runtime + // type, NotebookRuntimeType will default to USER_DEFINED. + // "USER_DEFINED" - runtime or template with coustomized + // configurations from user. + // "ONE_CLICK" - runtime or template with system defined + // configurations. + NotebookRuntimeType string `json:"notebookRuntimeType,omitempty"` + // ServiceAccount: The service account that the runtime workload runs // as. You can use any service account within the same project, but you // must have the service account user permission to use the instance. If @@ -17182,15 +17365,15 @@ type GoogleCloudAiplatformV1beta1PersistentResource struct { // specify this field, you must have already configured VPC Network // Peering for Vertex AI // (https://cloud.google.com/vertex-ai/docs/general/vpc-peering). If - // this field is left unspecified, the resources is not peered with any + // this field is left unspecified, the resources aren't peered with any // network. Network string `json:"network,omitempty"` - // ReservedIpRanges: Optional. A list of names for the reserved ip + // ReservedIpRanges: Optional. A list of names for the reserved IP // ranges under the VPC network that can be used for this persistent // resource. If set, we will deploy the persistent resource within the - // provided ip ranges. Otherwise, the persistent resource will be - // deployed to any ip ranges under the provided VPC network. Example: + // provided IP ranges. Otherwise, the persistent resource is deployed to + // any IP ranges under the provided VPC network. Example: // ['vertex-ai-ip-range']. ReservedIpRanges []string `json:"reservedIpRanges,omitempty"` @@ -17202,8 +17385,8 @@ type GoogleCloudAiplatformV1beta1PersistentResource struct { // Resource. ResourceRuntime *GoogleCloudAiplatformV1beta1ResourceRuntime `json:"resourceRuntime,omitempty"` - // ResourceRuntimeSpec: Optional. Persistent Resource runtime spec. Used - // for e.g. Ray cluster configuration. + // ResourceRuntimeSpec: Optional. Persistent Resource runtime spec. For + // example, used for Ray cluster configuration. ResourceRuntimeSpec *GoogleCloudAiplatformV1beta1ResourceRuntimeSpec `json:"resourceRuntimeSpec,omitempty"` // StartTime: Output only. Time when the PersistentResource for the @@ -17363,7 +17546,9 @@ type GoogleCloudAiplatformV1beta1PipelineJob struct { TemplateMetadata *GoogleCloudAiplatformV1beta1PipelineTemplateMetadata `json:"templateMetadata,omitempty"` // TemplateUri: A template uri from where the PipelineJob.pipeline_spec, - // if empty, will be downloaded. + // if empty, will be downloaded. Currently, only uri from Vertex + // Template Registry & Gallery is supported. Reference to + // https://cloud.google.com/vertex-ai/docs/pipelines/create-pipeline-template. TemplateUri string `json:"templateUri,omitempty"` // UpdateTime: Output only. Timestamp when this PipelineJob was most @@ -19112,19 +19297,19 @@ type GoogleCloudAiplatformV1beta1RaySpec struct { // HeadNodeResourcePoolId: Optional. This will be used to indicate which // resource pool will serve as the Ray head node(the first node within // that pool). Will use the machine from the first workerpool as the - // head node by default if this field is not set. + // head node by default if this field isn't set. HeadNodeResourcePoolId string `json:"headNodeResourcePoolId,omitempty"` // ImageUri: Optional. Default image for user to choose a preferred ML - // framework(e.g. tensorflow or Pytorch) by choosing from Vertex - // prebuild - // images(https://cloud.google.com/vertex-ai/docs/training/pre-built-cont - // ainers). Either this or the resource_pool_images is required. Use - // this field if you need all the resource pools to have the same Ray - // image, Otherwise, use the {@code resource_pool_images} field. + // framework (for example, TensorFlow or Pytorch) by choosing from + // Vertex prebuilt images + // (https://cloud.google.com/vertex-ai/docs/training/pre-built-containers). + // Either this or the resource_pool_images is required. Use this field + // if you need all the resource pools to have the same Ray image. + // Otherwise, use the {@code resource_pool_images} field. ImageUri string `json:"imageUri,omitempty"` - // ResourcePoolImages: Optional. Required if image_uri is not set. A map + // ResourcePoolImages: Optional. Required if image_uri isn't set. A map // of resource_pool_id to prebuild Ray image if user need to use // different images for different head/worker pools. This map needs to // cover all the resource pool ids. Example: { "ray_head_node_pool": @@ -19787,9 +19972,9 @@ func (s *GoogleCloudAiplatformV1beta1ReportRuntimeEventResponse) MarshalJSON() ( return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } -// GoogleCloudAiplatformV1beta1ResourcePool: Represents the spec a group -// of resources of same type, e.g. machine, disk and accelerators, in a -// PersistentResource. +// GoogleCloudAiplatformV1beta1ResourcePool: Represents the spec of a +// group of resources of the same type, for example machine type, disk, +// and accelerators, in a PersistentResource. type GoogleCloudAiplatformV1beta1ResourcePool struct { // AutoscalingSpec: Optional. Optional spec to configure GKE autoscaling AutoscalingSpec *GoogleCloudAiplatformV1beta1ResourcePoolAutoscalingSpec `json:"autoscalingSpec,omitempty"` @@ -19797,9 +19982,9 @@ type GoogleCloudAiplatformV1beta1ResourcePool struct { // DiskSpec: Optional. Disk spec for the machine in this node pool. DiskSpec *GoogleCloudAiplatformV1beta1DiskSpec `json:"diskSpec,omitempty"` - // Id: Immutable. The unique ID in a PersistentResource to refer the - // this resource pool. User can specify it if need to use it, otherwise - // we will generate it automatically. + // Id: Immutable. The unique ID in a PersistentResource for referring to + // this resource pool. User can specify it if necessary. Otherwise, it's + // generated automatically. Id string `json:"id,omitempty"` // MachineSpec: Required. Immutable. The specification of a single @@ -19912,10 +20097,10 @@ func (s *GoogleCloudAiplatformV1beta1ResourceRuntime) MarshalJSON() ([]byte, err return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } -// GoogleCloudAiplatformV1beta1ResourceRuntimeSpec: Configure runtime on -// a PersistentResource instance, including but may not limited to: * -// Service accounts used to run the workloads; * Whether make it a -// dedicated Ray Cluster; +// GoogleCloudAiplatformV1beta1ResourceRuntimeSpec: Configuration for +// the runtime on a PersistentResource instance, including but not +// limited to: * Service accounts used to run the workloads. * Whether +// to make it a dedicated Ray Cluster. type GoogleCloudAiplatformV1beta1ResourceRuntimeSpec struct { // RaySpec: Optional. Ray cluster configuration. Required when creating // a dedicated RayCluster on the PersistentResource. @@ -28389,20 +28574,20 @@ func (s *GoogleCloudAiplatformV1beta1SearchModelDeploymentMonitoringStatsAnomali // use of custom service account to run the workloads. type GoogleCloudAiplatformV1beta1ServiceAccountSpec struct { // EnableCustomServiceAccount: Required. If true, custom user-managed - // service account is enforced to run any workloads (e.g. Vertex Jobs) - // on the resource; Otherwise, will always use Vertex AI Custom Code + // service account is enforced to run any workloads (for example, Vertex + // Jobs) on the resource. Otherwise, uses the Vertex AI Custom Code // Service Agent - // (https://cloud.google.com/vertex-ai/docs/general/access-control#service-agents) + // (https://cloud.google.com/vertex-ai/docs/general/access-control#service-agents). EnableCustomServiceAccount bool `json:"enableCustomServiceAccount,omitempty"` // ServiceAccount: Optional. Default service account that this // PersistentResource's workloads run as. The workloads include: * Any - // runtime specified via `ResourceRuntimeSpec` on creation time, e.g. - // Ray; * Jobs submitted to PersistentResource, if no other service - // account specified in the job specs. Only works when custom service - // account is enabled and users have the `iam.serviceAccounts.actAs` - // permission on this service account. Required if any containers - // specified in `ResourceRuntimeSpec`. + // runtime specified via `ResourceRuntimeSpec` on creation time, for + // example, Ray. * Jobs submitted to PersistentResource, if no other + // service account specified in the job specs. Only works when custom + // service account is enabled and users have the + // `iam.serviceAccounts.actAs` permission on this service account. + // Required if any containers are specified in `ResourceRuntimeSpec`. ServiceAccount string `json:"serviceAccount,omitempty"` // ForceSendFields is a list of field names (e.g. @@ -40970,38 +41155,819 @@ func (c *ProjectsLocationsDatasetsDataItemsAnnotationsOperationsWaitCall) Do(opt } -// method id "aiplatform.projects.locations.datasets.dataItems.operations.cancel": +// method id "aiplatform.projects.locations.datasets.dataItems.operations.cancel": + +type ProjectsLocationsDatasetsDataItemsOperationsCancelCall struct { + s *Service + name string + urlParams_ gensupport.URLParams + ctx_ context.Context + header_ http.Header +} + +// Cancel: Starts asynchronous cancellation on a long-running operation. +// The server makes a best effort to cancel the operation, but success +// is not guaranteed. If the server doesn't support this method, it +// returns `google.rpc.Code.UNIMPLEMENTED`. Clients can use +// Operations.GetOperation or other methods to check whether the +// cancellation succeeded or whether the operation completed despite +// cancellation. On successful cancellation, the operation is not +// deleted; instead, it becomes an operation with an Operation.error +// value with a google.rpc.Status.code of 1, corresponding to +// `Code.CANCELLED`. +// +// - name: The name of the operation resource to be cancelled. +func (r *ProjectsLocationsDatasetsDataItemsOperationsService) Cancel(name string) *ProjectsLocationsDatasetsDataItemsOperationsCancelCall { + c := &ProjectsLocationsDatasetsDataItemsOperationsCancelCall{s: r.s, urlParams_: make(gensupport.URLParams)} + c.name = name + return c +} + +// Fields allows partial responses to be retrieved. See +// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse +// for more information. +func (c *ProjectsLocationsDatasetsDataItemsOperationsCancelCall) Fields(s ...googleapi.Field) *ProjectsLocationsDatasetsDataItemsOperationsCancelCall { + c.urlParams_.Set("fields", googleapi.CombineFields(s)) + return c +} + +// Context sets the context to be used in this call's Do method. Any +// pending HTTP request will be aborted if the provided context is +// canceled. +func (c *ProjectsLocationsDatasetsDataItemsOperationsCancelCall) Context(ctx context.Context) *ProjectsLocationsDatasetsDataItemsOperationsCancelCall { + c.ctx_ = ctx + return c +} + +// Header returns an http.Header that can be modified by the caller to +// add HTTP headers to the request. +func (c *ProjectsLocationsDatasetsDataItemsOperationsCancelCall) Header() http.Header { + if c.header_ == nil { + c.header_ = make(http.Header) + } + return c.header_ +} + +func (c *ProjectsLocationsDatasetsDataItemsOperationsCancelCall) doRequest(alt string) (*http.Response, error) { + reqHeaders := make(http.Header) + reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version) + for k, v := range c.header_ { + reqHeaders[k] = v + } + reqHeaders.Set("User-Agent", c.s.userAgent()) + var body io.Reader = nil + c.urlParams_.Set("alt", alt) + c.urlParams_.Set("prettyPrint", "false") + urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta1/{+name}:cancel") + urls += "?" + c.urlParams_.Encode() + req, err := http.NewRequest("POST", urls, body) + if err != nil { + return nil, err + } + req.Header = reqHeaders + googleapi.Expand(req.URL, map[string]string{ + "name": c.name, + }) + return gensupport.SendRequest(c.ctx_, c.s.client, req) +} + +// Do executes the "aiplatform.projects.locations.datasets.dataItems.operations.cancel" call. +// Exactly one of *GoogleProtobufEmpty or error will be non-nil. Any +// non-2xx status code is an error. Response headers are in either +// *GoogleProtobufEmpty.ServerResponse.Header or (if a response was +// returned at all) in error.(*googleapi.Error).Header. Use +// googleapi.IsNotModified to check whether the returned error was +// because http.StatusNotModified was returned. +func (c *ProjectsLocationsDatasetsDataItemsOperationsCancelCall) Do(opts ...googleapi.CallOption) (*GoogleProtobufEmpty, error) { + gensupport.SetOptions(c.urlParams_, opts...) + res, err := c.doRequest("json") + if res != nil && res.StatusCode == http.StatusNotModified { + if res.Body != nil { + res.Body.Close() + } + return nil, gensupport.WrapError(&googleapi.Error{ + Code: res.StatusCode, + Header: res.Header, + }) + } + if err != nil { + return nil, err + } + defer googleapi.CloseBody(res) + if err := googleapi.CheckResponse(res); err != nil { + return nil, gensupport.WrapError(err) + } + ret := &GoogleProtobufEmpty{ + ServerResponse: googleapi.ServerResponse{ + Header: res.Header, + HTTPStatusCode: res.StatusCode, + }, + } + target := &ret + if err := gensupport.DecodeResponse(target, res); err != nil { + return nil, err + } + return ret, nil + // { + // "description": "Starts asynchronous cancellation on a long-running operation. The server makes a best effort to cancel the operation, but success is not guaranteed. If the server doesn't support this method, it returns `google.rpc.Code.UNIMPLEMENTED`. Clients can use Operations.GetOperation or other methods to check whether the cancellation succeeded or whether the operation completed despite cancellation. On successful cancellation, the operation is not deleted; instead, it becomes an operation with an Operation.error value with a google.rpc.Status.code of 1, corresponding to `Code.CANCELLED`.", + // "flatPath": "v1beta1/projects/{projectsId}/locations/{locationsId}/datasets/{datasetsId}/dataItems/{dataItemsId}/operations/{operationsId}:cancel", + // "httpMethod": "POST", + // "id": "aiplatform.projects.locations.datasets.dataItems.operations.cancel", + // "parameterOrder": [ + // "name" + // ], + // "parameters": { + // "name": { + // "description": "The name of the operation resource to be cancelled.", + // "location": "path", + // "pattern": "^projects/[^/]+/locations/[^/]+/datasets/[^/]+/dataItems/[^/]+/operations/[^/]+$", + // "required": true, + // "type": "string" + // } + // }, + // "path": "v1beta1/{+name}:cancel", + // "response": { + // "$ref": "GoogleProtobufEmpty" + // }, + // "scopes": [ + // "https://www.googleapis.com/auth/cloud-platform" + // ] + // } + +} + +// method id "aiplatform.projects.locations.datasets.dataItems.operations.delete": + +type ProjectsLocationsDatasetsDataItemsOperationsDeleteCall struct { + s *Service + name string + urlParams_ gensupport.URLParams + ctx_ context.Context + header_ http.Header +} + +// Delete: Deletes a long-running operation. This method indicates that +// the client is no longer interested in the operation result. It does +// not cancel the operation. If the server doesn't support this method, +// it returns `google.rpc.Code.UNIMPLEMENTED`. +// +// - name: The name of the operation resource to be deleted. +func (r *ProjectsLocationsDatasetsDataItemsOperationsService) Delete(name string) *ProjectsLocationsDatasetsDataItemsOperationsDeleteCall { + c := &ProjectsLocationsDatasetsDataItemsOperationsDeleteCall{s: r.s, urlParams_: make(gensupport.URLParams)} + c.name = name + return c +} + +// Fields allows partial responses to be retrieved. See +// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse +// for more information. +func (c *ProjectsLocationsDatasetsDataItemsOperationsDeleteCall) Fields(s ...googleapi.Field) *ProjectsLocationsDatasetsDataItemsOperationsDeleteCall { + c.urlParams_.Set("fields", googleapi.CombineFields(s)) + return c +} + +// Context sets the context to be used in this call's Do method. Any +// pending HTTP request will be aborted if the provided context is +// canceled. +func (c *ProjectsLocationsDatasetsDataItemsOperationsDeleteCall) Context(ctx context.Context) *ProjectsLocationsDatasetsDataItemsOperationsDeleteCall { + c.ctx_ = ctx + return c +} + +// Header returns an http.Header that can be modified by the caller to +// add HTTP headers to the request. +func (c *ProjectsLocationsDatasetsDataItemsOperationsDeleteCall) Header() http.Header { + if c.header_ == nil { + c.header_ = make(http.Header) + } + return c.header_ +} + +func (c *ProjectsLocationsDatasetsDataItemsOperationsDeleteCall) doRequest(alt string) (*http.Response, error) { + reqHeaders := make(http.Header) + reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version) + for k, v := range c.header_ { + reqHeaders[k] = v + } + reqHeaders.Set("User-Agent", c.s.userAgent()) + var body io.Reader = nil + c.urlParams_.Set("alt", alt) + c.urlParams_.Set("prettyPrint", "false") + urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta1/{+name}") + urls += "?" + c.urlParams_.Encode() + req, err := http.NewRequest("DELETE", urls, body) + if err != nil { + return nil, err + } + req.Header = reqHeaders + googleapi.Expand(req.URL, map[string]string{ + "name": c.name, + }) + return gensupport.SendRequest(c.ctx_, c.s.client, req) +} + +// Do executes the "aiplatform.projects.locations.datasets.dataItems.operations.delete" call. +// Exactly one of *GoogleProtobufEmpty or error will be non-nil. Any +// non-2xx status code is an error. Response headers are in either +// *GoogleProtobufEmpty.ServerResponse.Header or (if a response was +// returned at all) in error.(*googleapi.Error).Header. Use +// googleapi.IsNotModified to check whether the returned error was +// because http.StatusNotModified was returned. +func (c *ProjectsLocationsDatasetsDataItemsOperationsDeleteCall) Do(opts ...googleapi.CallOption) (*GoogleProtobufEmpty, error) { + gensupport.SetOptions(c.urlParams_, opts...) + res, err := c.doRequest("json") + if res != nil && res.StatusCode == http.StatusNotModified { + if res.Body != nil { + res.Body.Close() + } + return nil, gensupport.WrapError(&googleapi.Error{ + Code: res.StatusCode, + Header: res.Header, + }) + } + if err != nil { + return nil, err + } + defer googleapi.CloseBody(res) + if err := googleapi.CheckResponse(res); err != nil { + return nil, gensupport.WrapError(err) + } + ret := &GoogleProtobufEmpty{ + ServerResponse: googleapi.ServerResponse{ + Header: res.Header, + HTTPStatusCode: res.StatusCode, + }, + } + target := &ret + if err := gensupport.DecodeResponse(target, res); err != nil { + return nil, err + } + return ret, nil + // { + // "description": "Deletes a long-running operation. This method indicates that the client is no longer interested in the operation result. It does not cancel the operation. If the server doesn't support this method, it returns `google.rpc.Code.UNIMPLEMENTED`.", + // "flatPath": "v1beta1/projects/{projectsId}/locations/{locationsId}/datasets/{datasetsId}/dataItems/{dataItemsId}/operations/{operationsId}", + // "httpMethod": "DELETE", + // "id": "aiplatform.projects.locations.datasets.dataItems.operations.delete", + // "parameterOrder": [ + // "name" + // ], + // "parameters": { + // "name": { + // "description": "The name of the operation resource to be deleted.", + // "location": "path", + // "pattern": "^projects/[^/]+/locations/[^/]+/datasets/[^/]+/dataItems/[^/]+/operations/[^/]+$", + // "required": true, + // "type": "string" + // } + // }, + // "path": "v1beta1/{+name}", + // "response": { + // "$ref": "GoogleProtobufEmpty" + // }, + // "scopes": [ + // "https://www.googleapis.com/auth/cloud-platform" + // ] + // } + +} + +// method id "aiplatform.projects.locations.datasets.dataItems.operations.get": + +type ProjectsLocationsDatasetsDataItemsOperationsGetCall struct { + s *Service + name string + urlParams_ gensupport.URLParams + ifNoneMatch_ string + ctx_ context.Context + header_ http.Header +} + +// Get: Gets the latest state of a long-running operation. Clients can +// use this method to poll the operation result at intervals as +// recommended by the API service. +// +// - name: The name of the operation resource. +func (r *ProjectsLocationsDatasetsDataItemsOperationsService) Get(name string) *ProjectsLocationsDatasetsDataItemsOperationsGetCall { + c := &ProjectsLocationsDatasetsDataItemsOperationsGetCall{s: r.s, urlParams_: make(gensupport.URLParams)} + c.name = name + return c +} + +// Fields allows partial responses to be retrieved. See +// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse +// for more information. +func (c *ProjectsLocationsDatasetsDataItemsOperationsGetCall) Fields(s ...googleapi.Field) *ProjectsLocationsDatasetsDataItemsOperationsGetCall { + c.urlParams_.Set("fields", googleapi.CombineFields(s)) + return c +} + +// IfNoneMatch sets the optional parameter which makes the operation +// fail if the object's ETag matches the given value. This is useful for +// getting updates only after the object has changed since the last +// request. Use googleapi.IsNotModified to check whether the response +// error from Do is the result of In-None-Match. +func (c *ProjectsLocationsDatasetsDataItemsOperationsGetCall) IfNoneMatch(entityTag string) *ProjectsLocationsDatasetsDataItemsOperationsGetCall { + c.ifNoneMatch_ = entityTag + return c +} + +// Context sets the context to be used in this call's Do method. Any +// pending HTTP request will be aborted if the provided context is +// canceled. +func (c *ProjectsLocationsDatasetsDataItemsOperationsGetCall) Context(ctx context.Context) *ProjectsLocationsDatasetsDataItemsOperationsGetCall { + c.ctx_ = ctx + return c +} + +// Header returns an http.Header that can be modified by the caller to +// add HTTP headers to the request. +func (c *ProjectsLocationsDatasetsDataItemsOperationsGetCall) Header() http.Header { + if c.header_ == nil { + c.header_ = make(http.Header) + } + return c.header_ +} + +func (c *ProjectsLocationsDatasetsDataItemsOperationsGetCall) doRequest(alt string) (*http.Response, error) { + reqHeaders := make(http.Header) + reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version) + for k, v := range c.header_ { + reqHeaders[k] = v + } + reqHeaders.Set("User-Agent", c.s.userAgent()) + if c.ifNoneMatch_ != "" { + reqHeaders.Set("If-None-Match", c.ifNoneMatch_) + } + var body io.Reader = nil + c.urlParams_.Set("alt", alt) + c.urlParams_.Set("prettyPrint", "false") + urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta1/{+name}") + urls += "?" + c.urlParams_.Encode() + req, err := http.NewRequest("GET", urls, body) + if err != nil { + return nil, err + } + req.Header = reqHeaders + googleapi.Expand(req.URL, map[string]string{ + "name": c.name, + }) + return gensupport.SendRequest(c.ctx_, c.s.client, req) +} + +// Do executes the "aiplatform.projects.locations.datasets.dataItems.operations.get" call. +// Exactly one of *GoogleLongrunningOperation or error will be non-nil. +// Any non-2xx status code is an error. Response headers are in either +// *GoogleLongrunningOperation.ServerResponse.Header or (if a response +// was returned at all) in error.(*googleapi.Error).Header. Use +// googleapi.IsNotModified to check whether the returned error was +// because http.StatusNotModified was returned. +func (c *ProjectsLocationsDatasetsDataItemsOperationsGetCall) Do(opts ...googleapi.CallOption) (*GoogleLongrunningOperation, error) { + gensupport.SetOptions(c.urlParams_, opts...) + res, err := c.doRequest("json") + if res != nil && res.StatusCode == http.StatusNotModified { + if res.Body != nil { + res.Body.Close() + } + return nil, gensupport.WrapError(&googleapi.Error{ + Code: res.StatusCode, + Header: res.Header, + }) + } + if err != nil { + return nil, err + } + defer googleapi.CloseBody(res) + if err := googleapi.CheckResponse(res); err != nil { + return nil, gensupport.WrapError(err) + } + ret := &GoogleLongrunningOperation{ + ServerResponse: googleapi.ServerResponse{ + Header: res.Header, + HTTPStatusCode: res.StatusCode, + }, + } + target := &ret + if err := gensupport.DecodeResponse(target, res); err != nil { + return nil, err + } + return ret, nil + // { + // "description": "Gets the latest state of a long-running operation. Clients can use this method to poll the operation result at intervals as recommended by the API service.", + // "flatPath": "v1beta1/projects/{projectsId}/locations/{locationsId}/datasets/{datasetsId}/dataItems/{dataItemsId}/operations/{operationsId}", + // "httpMethod": "GET", + // "id": "aiplatform.projects.locations.datasets.dataItems.operations.get", + // "parameterOrder": [ + // "name" + // ], + // "parameters": { + // "name": { + // "description": "The name of the operation resource.", + // "location": "path", + // "pattern": "^projects/[^/]+/locations/[^/]+/datasets/[^/]+/dataItems/[^/]+/operations/[^/]+$", + // "required": true, + // "type": "string" + // } + // }, + // "path": "v1beta1/{+name}", + // "response": { + // "$ref": "GoogleLongrunningOperation" + // }, + // "scopes": [ + // "https://www.googleapis.com/auth/cloud-platform" + // ] + // } + +} + +// method id "aiplatform.projects.locations.datasets.dataItems.operations.list": + +type ProjectsLocationsDatasetsDataItemsOperationsListCall struct { + s *Service + name string + urlParams_ gensupport.URLParams + ifNoneMatch_ string + ctx_ context.Context + header_ http.Header +} + +// List: Lists operations that match the specified filter in the +// request. If the server doesn't support this method, it returns +// `UNIMPLEMENTED`. +// +// - name: The name of the operation's parent resource. +func (r *ProjectsLocationsDatasetsDataItemsOperationsService) List(name string) *ProjectsLocationsDatasetsDataItemsOperationsListCall { + c := &ProjectsLocationsDatasetsDataItemsOperationsListCall{s: r.s, urlParams_: make(gensupport.URLParams)} + c.name = name + return c +} + +// Filter sets the optional parameter "filter": The standard list +// filter. +func (c *ProjectsLocationsDatasetsDataItemsOperationsListCall) Filter(filter string) *ProjectsLocationsDatasetsDataItemsOperationsListCall { + c.urlParams_.Set("filter", filter) + return c +} + +// PageSize sets the optional parameter "pageSize": The standard list +// page size. +func (c *ProjectsLocationsDatasetsDataItemsOperationsListCall) PageSize(pageSize int64) *ProjectsLocationsDatasetsDataItemsOperationsListCall { + c.urlParams_.Set("pageSize", fmt.Sprint(pageSize)) + return c +} + +// PageToken sets the optional parameter "pageToken": The standard list +// page token. +func (c *ProjectsLocationsDatasetsDataItemsOperationsListCall) PageToken(pageToken string) *ProjectsLocationsDatasetsDataItemsOperationsListCall { + c.urlParams_.Set("pageToken", pageToken) + return c +} + +// Fields allows partial responses to be retrieved. See +// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse +// for more information. +func (c *ProjectsLocationsDatasetsDataItemsOperationsListCall) Fields(s ...googleapi.Field) *ProjectsLocationsDatasetsDataItemsOperationsListCall { + c.urlParams_.Set("fields", googleapi.CombineFields(s)) + return c +} + +// IfNoneMatch sets the optional parameter which makes the operation +// fail if the object's ETag matches the given value. This is useful for +// getting updates only after the object has changed since the last +// request. Use googleapi.IsNotModified to check whether the response +// error from Do is the result of In-None-Match. +func (c *ProjectsLocationsDatasetsDataItemsOperationsListCall) IfNoneMatch(entityTag string) *ProjectsLocationsDatasetsDataItemsOperationsListCall { + c.ifNoneMatch_ = entityTag + return c +} + +// Context sets the context to be used in this call's Do method. Any +// pending HTTP request will be aborted if the provided context is +// canceled. +func (c *ProjectsLocationsDatasetsDataItemsOperationsListCall) Context(ctx context.Context) *ProjectsLocationsDatasetsDataItemsOperationsListCall { + c.ctx_ = ctx + return c +} + +// Header returns an http.Header that can be modified by the caller to +// add HTTP headers to the request. +func (c *ProjectsLocationsDatasetsDataItemsOperationsListCall) Header() http.Header { + if c.header_ == nil { + c.header_ = make(http.Header) + } + return c.header_ +} + +func (c *ProjectsLocationsDatasetsDataItemsOperationsListCall) doRequest(alt string) (*http.Response, error) { + reqHeaders := make(http.Header) + reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version) + for k, v := range c.header_ { + reqHeaders[k] = v + } + reqHeaders.Set("User-Agent", c.s.userAgent()) + if c.ifNoneMatch_ != "" { + reqHeaders.Set("If-None-Match", c.ifNoneMatch_) + } + var body io.Reader = nil + c.urlParams_.Set("alt", alt) + c.urlParams_.Set("prettyPrint", "false") + urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta1/{+name}/operations") + urls += "?" + c.urlParams_.Encode() + req, err := http.NewRequest("GET", urls, body) + if err != nil { + return nil, err + } + req.Header = reqHeaders + googleapi.Expand(req.URL, map[string]string{ + "name": c.name, + }) + return gensupport.SendRequest(c.ctx_, c.s.client, req) +} + +// Do executes the "aiplatform.projects.locations.datasets.dataItems.operations.list" call. +// Exactly one of *GoogleLongrunningListOperationsResponse or error will +// be non-nil. Any non-2xx status code is an error. Response headers are +// in either +// *GoogleLongrunningListOperationsResponse.ServerResponse.Header or (if +// a response was returned at all) in error.(*googleapi.Error).Header. +// Use googleapi.IsNotModified to check whether the returned error was +// because http.StatusNotModified was returned. +func (c *ProjectsLocationsDatasetsDataItemsOperationsListCall) Do(opts ...googleapi.CallOption) (*GoogleLongrunningListOperationsResponse, error) { + gensupport.SetOptions(c.urlParams_, opts...) + res, err := c.doRequest("json") + if res != nil && res.StatusCode == http.StatusNotModified { + if res.Body != nil { + res.Body.Close() + } + return nil, gensupport.WrapError(&googleapi.Error{ + Code: res.StatusCode, + Header: res.Header, + }) + } + if err != nil { + return nil, err + } + defer googleapi.CloseBody(res) + if err := googleapi.CheckResponse(res); err != nil { + return nil, gensupport.WrapError(err) + } + ret := &GoogleLongrunningListOperationsResponse{ + ServerResponse: googleapi.ServerResponse{ + Header: res.Header, + HTTPStatusCode: res.StatusCode, + }, + } + target := &ret + if err := gensupport.DecodeResponse(target, res); err != nil { + return nil, err + } + return ret, nil + // { + // "description": "Lists operations that match the specified filter in the request. If the server doesn't support this method, it returns `UNIMPLEMENTED`.", + // "flatPath": "v1beta1/projects/{projectsId}/locations/{locationsId}/datasets/{datasetsId}/dataItems/{dataItemsId}/operations", + // "httpMethod": "GET", + // "id": "aiplatform.projects.locations.datasets.dataItems.operations.list", + // "parameterOrder": [ + // "name" + // ], + // "parameters": { + // "filter": { + // "description": "The standard list filter.", + // "location": "query", + // "type": "string" + // }, + // "name": { + // "description": "The name of the operation's parent resource.", + // "location": "path", + // "pattern": "^projects/[^/]+/locations/[^/]+/datasets/[^/]+/dataItems/[^/]+$", + // "required": true, + // "type": "string" + // }, + // "pageSize": { + // "description": "The standard list page size.", + // "format": "int32", + // "location": "query", + // "type": "integer" + // }, + // "pageToken": { + // "description": "The standard list page token.", + // "location": "query", + // "type": "string" + // } + // }, + // "path": "v1beta1/{+name}/operations", + // "response": { + // "$ref": "GoogleLongrunningListOperationsResponse" + // }, + // "scopes": [ + // "https://www.googleapis.com/auth/cloud-platform" + // ] + // } + +} + +// Pages invokes f for each page of results. +// A non-nil error returned from f will halt the iteration. +// The provided context supersedes any context provided to the Context method. +func (c *ProjectsLocationsDatasetsDataItemsOperationsListCall) Pages(ctx context.Context, f func(*GoogleLongrunningListOperationsResponse) error) error { + c.ctx_ = ctx + defer c.PageToken(c.urlParams_.Get("pageToken")) // reset paging to original point + for { + x, err := c.Do() + if err != nil { + return err + } + if err := f(x); err != nil { + return err + } + if x.NextPageToken == "" { + return nil + } + c.PageToken(x.NextPageToken) + } +} + +// method id "aiplatform.projects.locations.datasets.dataItems.operations.wait": + +type ProjectsLocationsDatasetsDataItemsOperationsWaitCall struct { + s *Service + name string + urlParams_ gensupport.URLParams + ctx_ context.Context + header_ http.Header +} + +// Wait: Waits until the specified long-running operation is done or +// reaches at most a specified timeout, returning the latest state. If +// the operation is already done, the latest state is immediately +// returned. If the timeout specified is greater than the default +// HTTP/RPC timeout, the HTTP/RPC timeout is used. If the server does +// not support this method, it returns `google.rpc.Code.UNIMPLEMENTED`. +// Note that this method is on a best-effort basis. It may return the +// latest state before the specified timeout (including immediately), +// meaning even an immediate response is no guarantee that the operation +// is done. +// +// - name: The name of the operation resource to wait on. +func (r *ProjectsLocationsDatasetsDataItemsOperationsService) Wait(name string) *ProjectsLocationsDatasetsDataItemsOperationsWaitCall { + c := &ProjectsLocationsDatasetsDataItemsOperationsWaitCall{s: r.s, urlParams_: make(gensupport.URLParams)} + c.name = name + return c +} + +// Timeout sets the optional parameter "timeout": The maximum duration +// to wait before timing out. If left blank, the wait will be at most +// the time permitted by the underlying HTTP/RPC protocol. If RPC +// context deadline is also specified, the shorter one will be used. +func (c *ProjectsLocationsDatasetsDataItemsOperationsWaitCall) Timeout(timeout string) *ProjectsLocationsDatasetsDataItemsOperationsWaitCall { + c.urlParams_.Set("timeout", timeout) + return c +} + +// Fields allows partial responses to be retrieved. See +// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse +// for more information. +func (c *ProjectsLocationsDatasetsDataItemsOperationsWaitCall) Fields(s ...googleapi.Field) *ProjectsLocationsDatasetsDataItemsOperationsWaitCall { + c.urlParams_.Set("fields", googleapi.CombineFields(s)) + return c +} + +// Context sets the context to be used in this call's Do method. Any +// pending HTTP request will be aborted if the provided context is +// canceled. +func (c *ProjectsLocationsDatasetsDataItemsOperationsWaitCall) Context(ctx context.Context) *ProjectsLocationsDatasetsDataItemsOperationsWaitCall { + c.ctx_ = ctx + return c +} + +// Header returns an http.Header that can be modified by the caller to +// add HTTP headers to the request. +func (c *ProjectsLocationsDatasetsDataItemsOperationsWaitCall) Header() http.Header { + if c.header_ == nil { + c.header_ = make(http.Header) + } + return c.header_ +} + +func (c *ProjectsLocationsDatasetsDataItemsOperationsWaitCall) doRequest(alt string) (*http.Response, error) { + reqHeaders := make(http.Header) + reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version) + for k, v := range c.header_ { + reqHeaders[k] = v + } + reqHeaders.Set("User-Agent", c.s.userAgent()) + var body io.Reader = nil + c.urlParams_.Set("alt", alt) + c.urlParams_.Set("prettyPrint", "false") + urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta1/{+name}:wait") + urls += "?" + c.urlParams_.Encode() + req, err := http.NewRequest("POST", urls, body) + if err != nil { + return nil, err + } + req.Header = reqHeaders + googleapi.Expand(req.URL, map[string]string{ + "name": c.name, + }) + return gensupport.SendRequest(c.ctx_, c.s.client, req) +} + +// Do executes the "aiplatform.projects.locations.datasets.dataItems.operations.wait" call. +// Exactly one of *GoogleLongrunningOperation or error will be non-nil. +// Any non-2xx status code is an error. Response headers are in either +// *GoogleLongrunningOperation.ServerResponse.Header or (if a response +// was returned at all) in error.(*googleapi.Error).Header. Use +// googleapi.IsNotModified to check whether the returned error was +// because http.StatusNotModified was returned. +func (c *ProjectsLocationsDatasetsDataItemsOperationsWaitCall) Do(opts ...googleapi.CallOption) (*GoogleLongrunningOperation, error) { + gensupport.SetOptions(c.urlParams_, opts...) + res, err := c.doRequest("json") + if res != nil && res.StatusCode == http.StatusNotModified { + if res.Body != nil { + res.Body.Close() + } + return nil, gensupport.WrapError(&googleapi.Error{ + Code: res.StatusCode, + Header: res.Header, + }) + } + if err != nil { + return nil, err + } + defer googleapi.CloseBody(res) + if err := googleapi.CheckResponse(res); err != nil { + return nil, gensupport.WrapError(err) + } + ret := &GoogleLongrunningOperation{ + ServerResponse: googleapi.ServerResponse{ + Header: res.Header, + HTTPStatusCode: res.StatusCode, + }, + } + target := &ret + if err := gensupport.DecodeResponse(target, res); err != nil { + return nil, err + } + return ret, nil + // { + // "description": "Waits until the specified long-running operation is done or reaches at most a specified timeout, returning the latest state. If the operation is already done, the latest state is immediately returned. If the timeout specified is greater than the default HTTP/RPC timeout, the HTTP/RPC timeout is used. If the server does not support this method, it returns `google.rpc.Code.UNIMPLEMENTED`. Note that this method is on a best-effort basis. It may return the latest state before the specified timeout (including immediately), meaning even an immediate response is no guarantee that the operation is done.", + // "flatPath": "v1beta1/projects/{projectsId}/locations/{locationsId}/datasets/{datasetsId}/dataItems/{dataItemsId}/operations/{operationsId}:wait", + // "httpMethod": "POST", + // "id": "aiplatform.projects.locations.datasets.dataItems.operations.wait", + // "parameterOrder": [ + // "name" + // ], + // "parameters": { + // "name": { + // "description": "The name of the operation resource to wait on.", + // "location": "path", + // "pattern": "^projects/[^/]+/locations/[^/]+/datasets/[^/]+/dataItems/[^/]+/operations/[^/]+$", + // "required": true, + // "type": "string" + // }, + // "timeout": { + // "description": "The maximum duration to wait before timing out. If left blank, the wait will be at most the time permitted by the underlying HTTP/RPC protocol. If RPC context deadline is also specified, the shorter one will be used.", + // "format": "google-duration", + // "location": "query", + // "type": "string" + // } + // }, + // "path": "v1beta1/{+name}:wait", + // "response": { + // "$ref": "GoogleLongrunningOperation" + // }, + // "scopes": [ + // "https://www.googleapis.com/auth/cloud-platform" + // ] + // } + +} + +// method id "aiplatform.projects.locations.datasets.datasetVersions.create": -type ProjectsLocationsDatasetsDataItemsOperationsCancelCall struct { - s *Service - name string - urlParams_ gensupport.URLParams - ctx_ context.Context - header_ http.Header +type ProjectsLocationsDatasetsDatasetVersionsCreateCall struct { + s *Service + parent string + googlecloudaiplatformv1beta1datasetversion *GoogleCloudAiplatformV1beta1DatasetVersion + urlParams_ gensupport.URLParams + ctx_ context.Context + header_ http.Header } -// Cancel: Starts asynchronous cancellation on a long-running operation. -// The server makes a best effort to cancel the operation, but success -// is not guaranteed. If the server doesn't support this method, it -// returns `google.rpc.Code.UNIMPLEMENTED`. Clients can use -// Operations.GetOperation or other methods to check whether the -// cancellation succeeded or whether the operation completed despite -// cancellation. On successful cancellation, the operation is not -// deleted; instead, it becomes an operation with an Operation.error -// value with a google.rpc.Status.code of 1, corresponding to -// `Code.CANCELLED`. +// Create: Create a version from a Dataset. // -// - name: The name of the operation resource to be cancelled. -func (r *ProjectsLocationsDatasetsDataItemsOperationsService) Cancel(name string) *ProjectsLocationsDatasetsDataItemsOperationsCancelCall { - c := &ProjectsLocationsDatasetsDataItemsOperationsCancelCall{s: r.s, urlParams_: make(gensupport.URLParams)} - c.name = name +// - parent: The name of the Dataset resource. Format: +// `projects/{project}/locations/{location}/datasets/{dataset}`. +func (r *ProjectsLocationsDatasetsDatasetVersionsService) Create(parent string, googlecloudaiplatformv1beta1datasetversion *GoogleCloudAiplatformV1beta1DatasetVersion) *ProjectsLocationsDatasetsDatasetVersionsCreateCall { + c := &ProjectsLocationsDatasetsDatasetVersionsCreateCall{s: r.s, urlParams_: make(gensupport.URLParams)} + c.parent = parent + c.googlecloudaiplatformv1beta1datasetversion = googlecloudaiplatformv1beta1datasetversion return c } // Fields allows partial responses to be retrieved. See // https://developers.google.com/gdata/docs/2.0/basics#PartialResponse // for more information. -func (c *ProjectsLocationsDatasetsDataItemsOperationsCancelCall) Fields(s ...googleapi.Field) *ProjectsLocationsDatasetsDataItemsOperationsCancelCall { +func (c *ProjectsLocationsDatasetsDatasetVersionsCreateCall) Fields(s ...googleapi.Field) *ProjectsLocationsDatasetsDatasetVersionsCreateCall { c.urlParams_.Set("fields", googleapi.CombineFields(s)) return c } @@ -41009,21 +41975,21 @@ func (c *ProjectsLocationsDatasetsDataItemsOperationsCancelCall) Fields(s ...goo // Context sets the context to be used in this call's Do method. Any // pending HTTP request will be aborted if the provided context is // canceled. -func (c *ProjectsLocationsDatasetsDataItemsOperationsCancelCall) Context(ctx context.Context) *ProjectsLocationsDatasetsDataItemsOperationsCancelCall { +func (c *ProjectsLocationsDatasetsDatasetVersionsCreateCall) Context(ctx context.Context) *ProjectsLocationsDatasetsDatasetVersionsCreateCall { c.ctx_ = ctx return c } // Header returns an http.Header that can be modified by the caller to // add HTTP headers to the request. -func (c *ProjectsLocationsDatasetsDataItemsOperationsCancelCall) Header() http.Header { +func (c *ProjectsLocationsDatasetsDatasetVersionsCreateCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) } return c.header_ } -func (c *ProjectsLocationsDatasetsDataItemsOperationsCancelCall) doRequest(alt string) (*http.Response, error) { +func (c *ProjectsLocationsDatasetsDatasetVersionsCreateCall) doRequest(alt string) (*http.Response, error) { reqHeaders := make(http.Header) reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version) for k, v := range c.header_ { @@ -41031,9 +41997,14 @@ func (c *ProjectsLocationsDatasetsDataItemsOperationsCancelCall) doRequest(alt s } reqHeaders.Set("User-Agent", c.s.userAgent()) var body io.Reader = nil + body, err := googleapi.WithoutDataWrapper.JSONReader(c.googlecloudaiplatformv1beta1datasetversion) + if err != nil { + return nil, err + } + reqHeaders.Set("Content-Type", "application/json") c.urlParams_.Set("alt", alt) c.urlParams_.Set("prettyPrint", "false") - urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta1/{+name}:cancel") + urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta1/{+parent}/datasetVersions") urls += "?" + c.urlParams_.Encode() req, err := http.NewRequest("POST", urls, body) if err != nil { @@ -41041,19 +42012,19 @@ func (c *ProjectsLocationsDatasetsDataItemsOperationsCancelCall) doRequest(alt s } req.Header = reqHeaders googleapi.Expand(req.URL, map[string]string{ - "name": c.name, + "parent": c.parent, }) return gensupport.SendRequest(c.ctx_, c.s.client, req) } -// Do executes the "aiplatform.projects.locations.datasets.dataItems.operations.cancel" call. -// Exactly one of *GoogleProtobufEmpty or error will be non-nil. Any -// non-2xx status code is an error. Response headers are in either -// *GoogleProtobufEmpty.ServerResponse.Header or (if a response was -// returned at all) in error.(*googleapi.Error).Header. Use +// Do executes the "aiplatform.projects.locations.datasets.datasetVersions.create" call. +// Exactly one of *GoogleLongrunningOperation or error will be non-nil. +// Any non-2xx status code is an error. Response headers are in either +// *GoogleLongrunningOperation.ServerResponse.Header or (if a response +// was returned at all) in error.(*googleapi.Error).Header. Use // googleapi.IsNotModified to check whether the returned error was // because http.StatusNotModified was returned. -func (c *ProjectsLocationsDatasetsDataItemsOperationsCancelCall) Do(opts ...googleapi.CallOption) (*GoogleProtobufEmpty, error) { +func (c *ProjectsLocationsDatasetsDatasetVersionsCreateCall) Do(opts ...googleapi.CallOption) (*GoogleLongrunningOperation, error) { gensupport.SetOptions(c.urlParams_, opts...) res, err := c.doRequest("json") if res != nil && res.StatusCode == http.StatusNotModified { @@ -41072,7 +42043,7 @@ func (c *ProjectsLocationsDatasetsDataItemsOperationsCancelCall) Do(opts ...goog if err := googleapi.CheckResponse(res); err != nil { return nil, gensupport.WrapError(err) } - ret := &GoogleProtobufEmpty{ + ret := &GoogleLongrunningOperation{ ServerResponse: googleapi.ServerResponse{ Header: res.Header, HTTPStatusCode: res.StatusCode, @@ -41084,25 +42055,28 @@ func (c *ProjectsLocationsDatasetsDataItemsOperationsCancelCall) Do(opts ...goog } return ret, nil // { - // "description": "Starts asynchronous cancellation on a long-running operation. The server makes a best effort to cancel the operation, but success is not guaranteed. If the server doesn't support this method, it returns `google.rpc.Code.UNIMPLEMENTED`. Clients can use Operations.GetOperation or other methods to check whether the cancellation succeeded or whether the operation completed despite cancellation. On successful cancellation, the operation is not deleted; instead, it becomes an operation with an Operation.error value with a google.rpc.Status.code of 1, corresponding to `Code.CANCELLED`.", - // "flatPath": "v1beta1/projects/{projectsId}/locations/{locationsId}/datasets/{datasetsId}/dataItems/{dataItemsId}/operations/{operationsId}:cancel", + // "description": "Create a version from a Dataset.", + // "flatPath": "v1beta1/projects/{projectsId}/locations/{locationsId}/datasets/{datasetsId}/datasetVersions", // "httpMethod": "POST", - // "id": "aiplatform.projects.locations.datasets.dataItems.operations.cancel", + // "id": "aiplatform.projects.locations.datasets.datasetVersions.create", // "parameterOrder": [ - // "name" + // "parent" // ], // "parameters": { - // "name": { - // "description": "The name of the operation resource to be cancelled.", + // "parent": { + // "description": "Required. The name of the Dataset resource. Format: `projects/{project}/locations/{location}/datasets/{dataset}`", // "location": "path", - // "pattern": "^projects/[^/]+/locations/[^/]+/datasets/[^/]+/dataItems/[^/]+/operations/[^/]+$", + // "pattern": "^projects/[^/]+/locations/[^/]+/datasets/[^/]+$", // "required": true, // "type": "string" // } // }, - // "path": "v1beta1/{+name}:cancel", + // "path": "v1beta1/{+parent}/datasetVersions", + // "request": { + // "$ref": "GoogleCloudAiplatformV1beta1DatasetVersion" + // }, // "response": { - // "$ref": "GoogleProtobufEmpty" + // "$ref": "GoogleLongrunningOperation" // }, // "scopes": [ // "https://www.googleapis.com/auth/cloud-platform" @@ -41111,9 +42085,9 @@ func (c *ProjectsLocationsDatasetsDataItemsOperationsCancelCall) Do(opts ...goog } -// method id "aiplatform.projects.locations.datasets.dataItems.operations.delete": +// method id "aiplatform.projects.locations.datasets.datasetVersions.delete": -type ProjectsLocationsDatasetsDataItemsOperationsDeleteCall struct { +type ProjectsLocationsDatasetsDatasetVersionsDeleteCall struct { s *Service name string urlParams_ gensupport.URLParams @@ -41121,14 +42095,13 @@ type ProjectsLocationsDatasetsDataItemsOperationsDeleteCall struct { header_ http.Header } -// Delete: Deletes a long-running operation. This method indicates that -// the client is no longer interested in the operation result. It does -// not cancel the operation. If the server doesn't support this method, -// it returns `google.rpc.Code.UNIMPLEMENTED`. +// Delete: Deletes a Dataset version. // -// - name: The name of the operation resource to be deleted. -func (r *ProjectsLocationsDatasetsDataItemsOperationsService) Delete(name string) *ProjectsLocationsDatasetsDataItemsOperationsDeleteCall { - c := &ProjectsLocationsDatasetsDataItemsOperationsDeleteCall{s: r.s, urlParams_: make(gensupport.URLParams)} +// - name: The resource name of the Dataset version to delete. Format: +// `projects/{project}/locations/{location}/datasets/{dataset}/datasetV +// ersions/{dataset_version}`. +func (r *ProjectsLocationsDatasetsDatasetVersionsService) Delete(name string) *ProjectsLocationsDatasetsDatasetVersionsDeleteCall { + c := &ProjectsLocationsDatasetsDatasetVersionsDeleteCall{s: r.s, urlParams_: make(gensupport.URLParams)} c.name = name return c } @@ -41136,7 +42109,7 @@ func (r *ProjectsLocationsDatasetsDataItemsOperationsService) Delete(name string // Fields allows partial responses to be retrieved. See // https://developers.google.com/gdata/docs/2.0/basics#PartialResponse // for more information. -func (c *ProjectsLocationsDatasetsDataItemsOperationsDeleteCall) Fields(s ...googleapi.Field) *ProjectsLocationsDatasetsDataItemsOperationsDeleteCall { +func (c *ProjectsLocationsDatasetsDatasetVersionsDeleteCall) Fields(s ...googleapi.Field) *ProjectsLocationsDatasetsDatasetVersionsDeleteCall { c.urlParams_.Set("fields", googleapi.CombineFields(s)) return c } @@ -41144,21 +42117,21 @@ func (c *ProjectsLocationsDatasetsDataItemsOperationsDeleteCall) Fields(s ...goo // Context sets the context to be used in this call's Do method. Any // pending HTTP request will be aborted if the provided context is // canceled. -func (c *ProjectsLocationsDatasetsDataItemsOperationsDeleteCall) Context(ctx context.Context) *ProjectsLocationsDatasetsDataItemsOperationsDeleteCall { +func (c *ProjectsLocationsDatasetsDatasetVersionsDeleteCall) Context(ctx context.Context) *ProjectsLocationsDatasetsDatasetVersionsDeleteCall { c.ctx_ = ctx return c } // Header returns an http.Header that can be modified by the caller to // add HTTP headers to the request. -func (c *ProjectsLocationsDatasetsDataItemsOperationsDeleteCall) Header() http.Header { +func (c *ProjectsLocationsDatasetsDatasetVersionsDeleteCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) } return c.header_ } -func (c *ProjectsLocationsDatasetsDataItemsOperationsDeleteCall) doRequest(alt string) (*http.Response, error) { +func (c *ProjectsLocationsDatasetsDatasetVersionsDeleteCall) doRequest(alt string) (*http.Response, error) { reqHeaders := make(http.Header) reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version) for k, v := range c.header_ { @@ -41181,14 +42154,14 @@ func (c *ProjectsLocationsDatasetsDataItemsOperationsDeleteCall) doRequest(alt s return gensupport.SendRequest(c.ctx_, c.s.client, req) } -// Do executes the "aiplatform.projects.locations.datasets.dataItems.operations.delete" call. -// Exactly one of *GoogleProtobufEmpty or error will be non-nil. Any -// non-2xx status code is an error. Response headers are in either -// *GoogleProtobufEmpty.ServerResponse.Header or (if a response was -// returned at all) in error.(*googleapi.Error).Header. Use +// Do executes the "aiplatform.projects.locations.datasets.datasetVersions.delete" call. +// Exactly one of *GoogleLongrunningOperation or error will be non-nil. +// Any non-2xx status code is an error. Response headers are in either +// *GoogleLongrunningOperation.ServerResponse.Header or (if a response +// was returned at all) in error.(*googleapi.Error).Header. Use // googleapi.IsNotModified to check whether the returned error was // because http.StatusNotModified was returned. -func (c *ProjectsLocationsDatasetsDataItemsOperationsDeleteCall) Do(opts ...googleapi.CallOption) (*GoogleProtobufEmpty, error) { +func (c *ProjectsLocationsDatasetsDatasetVersionsDeleteCall) Do(opts ...googleapi.CallOption) (*GoogleLongrunningOperation, error) { gensupport.SetOptions(c.urlParams_, opts...) res, err := c.doRequest("json") if res != nil && res.StatusCode == http.StatusNotModified { @@ -41207,7 +42180,7 @@ func (c *ProjectsLocationsDatasetsDataItemsOperationsDeleteCall) Do(opts ...goog if err := googleapi.CheckResponse(res); err != nil { return nil, gensupport.WrapError(err) } - ret := &GoogleProtobufEmpty{ + ret := &GoogleLongrunningOperation{ ServerResponse: googleapi.ServerResponse{ Header: res.Header, HTTPStatusCode: res.StatusCode, @@ -41219,25 +42192,25 @@ func (c *ProjectsLocationsDatasetsDataItemsOperationsDeleteCall) Do(opts ...goog } return ret, nil // { - // "description": "Deletes a long-running operation. This method indicates that the client is no longer interested in the operation result. It does not cancel the operation. If the server doesn't support this method, it returns `google.rpc.Code.UNIMPLEMENTED`.", - // "flatPath": "v1beta1/projects/{projectsId}/locations/{locationsId}/datasets/{datasetsId}/dataItems/{dataItemsId}/operations/{operationsId}", + // "description": "Deletes a Dataset version.", + // "flatPath": "v1beta1/projects/{projectsId}/locations/{locationsId}/datasets/{datasetsId}/datasetVersions/{datasetVersionsId}", // "httpMethod": "DELETE", - // "id": "aiplatform.projects.locations.datasets.dataItems.operations.delete", + // "id": "aiplatform.projects.locations.datasets.datasetVersions.delete", // "parameterOrder": [ // "name" // ], // "parameters": { // "name": { - // "description": "The name of the operation resource to be deleted.", + // "description": "Required. The resource name of the Dataset version to delete. Format: `projects/{project}/locations/{location}/datasets/{dataset}/datasetVersions/{dataset_version}`", // "location": "path", - // "pattern": "^projects/[^/]+/locations/[^/]+/datasets/[^/]+/dataItems/[^/]+/operations/[^/]+$", + // "pattern": "^projects/[^/]+/locations/[^/]+/datasets/[^/]+/datasetVersions/[^/]+$", // "required": true, // "type": "string" // } // }, // "path": "v1beta1/{+name}", // "response": { - // "$ref": "GoogleProtobufEmpty" + // "$ref": "GoogleLongrunningOperation" // }, // "scopes": [ // "https://www.googleapis.com/auth/cloud-platform" @@ -41246,9 +42219,9 @@ func (c *ProjectsLocationsDatasetsDataItemsOperationsDeleteCall) Do(opts ...goog } -// method id "aiplatform.projects.locations.datasets.dataItems.operations.get": +// method id "aiplatform.projects.locations.datasets.datasetVersions.get": -type ProjectsLocationsDatasetsDataItemsOperationsGetCall struct { +type ProjectsLocationsDatasetsDatasetVersionsGetCall struct { s *Service name string urlParams_ gensupport.URLParams @@ -41257,21 +42230,28 @@ type ProjectsLocationsDatasetsDataItemsOperationsGetCall struct { header_ http.Header } -// Get: Gets the latest state of a long-running operation. Clients can -// use this method to poll the operation result at intervals as -// recommended by the API service. +// Get: Gets a Dataset version. // -// - name: The name of the operation resource. -func (r *ProjectsLocationsDatasetsDataItemsOperationsService) Get(name string) *ProjectsLocationsDatasetsDataItemsOperationsGetCall { - c := &ProjectsLocationsDatasetsDataItemsOperationsGetCall{s: r.s, urlParams_: make(gensupport.URLParams)} +// - name: The resource name of the Dataset version to delete. Format: +// `projects/{project}/locations/{location}/datasets/{dataset}/datasetV +// ersions/{dataset_version}`. +func (r *ProjectsLocationsDatasetsDatasetVersionsService) Get(name string) *ProjectsLocationsDatasetsDatasetVersionsGetCall { + c := &ProjectsLocationsDatasetsDatasetVersionsGetCall{s: r.s, urlParams_: make(gensupport.URLParams)} c.name = name return c } +// ReadMask sets the optional parameter "readMask": Mask specifying +// which fields to read. +func (c *ProjectsLocationsDatasetsDatasetVersionsGetCall) ReadMask(readMask string) *ProjectsLocationsDatasetsDatasetVersionsGetCall { + c.urlParams_.Set("readMask", readMask) + return c +} + // Fields allows partial responses to be retrieved. See // https://developers.google.com/gdata/docs/2.0/basics#PartialResponse // for more information. -func (c *ProjectsLocationsDatasetsDataItemsOperationsGetCall) Fields(s ...googleapi.Field) *ProjectsLocationsDatasetsDataItemsOperationsGetCall { +func (c *ProjectsLocationsDatasetsDatasetVersionsGetCall) Fields(s ...googleapi.Field) *ProjectsLocationsDatasetsDatasetVersionsGetCall { c.urlParams_.Set("fields", googleapi.CombineFields(s)) return c } @@ -41281,7 +42261,7 @@ func (c *ProjectsLocationsDatasetsDataItemsOperationsGetCall) Fields(s ...google // getting updates only after the object has changed since the last // request. Use googleapi.IsNotModified to check whether the response // error from Do is the result of In-None-Match. -func (c *ProjectsLocationsDatasetsDataItemsOperationsGetCall) IfNoneMatch(entityTag string) *ProjectsLocationsDatasetsDataItemsOperationsGetCall { +func (c *ProjectsLocationsDatasetsDatasetVersionsGetCall) IfNoneMatch(entityTag string) *ProjectsLocationsDatasetsDatasetVersionsGetCall { c.ifNoneMatch_ = entityTag return c } @@ -41289,21 +42269,21 @@ func (c *ProjectsLocationsDatasetsDataItemsOperationsGetCall) IfNoneMatch(entity // Context sets the context to be used in this call's Do method. Any // pending HTTP request will be aborted if the provided context is // canceled. -func (c *ProjectsLocationsDatasetsDataItemsOperationsGetCall) Context(ctx context.Context) *ProjectsLocationsDatasetsDataItemsOperationsGetCall { +func (c *ProjectsLocationsDatasetsDatasetVersionsGetCall) Context(ctx context.Context) *ProjectsLocationsDatasetsDatasetVersionsGetCall { c.ctx_ = ctx return c } // Header returns an http.Header that can be modified by the caller to // add HTTP headers to the request. -func (c *ProjectsLocationsDatasetsDataItemsOperationsGetCall) Header() http.Header { +func (c *ProjectsLocationsDatasetsDatasetVersionsGetCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) } return c.header_ } -func (c *ProjectsLocationsDatasetsDataItemsOperationsGetCall) doRequest(alt string) (*http.Response, error) { +func (c *ProjectsLocationsDatasetsDatasetVersionsGetCall) doRequest(alt string) (*http.Response, error) { reqHeaders := make(http.Header) reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version) for k, v := range c.header_ { @@ -41329,14 +42309,16 @@ func (c *ProjectsLocationsDatasetsDataItemsOperationsGetCall) doRequest(alt stri return gensupport.SendRequest(c.ctx_, c.s.client, req) } -// Do executes the "aiplatform.projects.locations.datasets.dataItems.operations.get" call. -// Exactly one of *GoogleLongrunningOperation or error will be non-nil. -// Any non-2xx status code is an error. Response headers are in either -// *GoogleLongrunningOperation.ServerResponse.Header or (if a response -// was returned at all) in error.(*googleapi.Error).Header. Use -// googleapi.IsNotModified to check whether the returned error was -// because http.StatusNotModified was returned. -func (c *ProjectsLocationsDatasetsDataItemsOperationsGetCall) Do(opts ...googleapi.CallOption) (*GoogleLongrunningOperation, error) { +// Do executes the "aiplatform.projects.locations.datasets.datasetVersions.get" call. +// Exactly one of *GoogleCloudAiplatformV1beta1DatasetVersion or error +// will be non-nil. Any non-2xx status code is an error. Response +// headers are in either +// *GoogleCloudAiplatformV1beta1DatasetVersion.ServerResponse.Header or +// (if a response was returned at all) in +// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check +// whether the returned error was because http.StatusNotModified was +// returned. +func (c *ProjectsLocationsDatasetsDatasetVersionsGetCall) Do(opts ...googleapi.CallOption) (*GoogleCloudAiplatformV1beta1DatasetVersion, error) { gensupport.SetOptions(c.urlParams_, opts...) res, err := c.doRequest("json") if res != nil && res.StatusCode == http.StatusNotModified { @@ -41355,7 +42337,7 @@ func (c *ProjectsLocationsDatasetsDataItemsOperationsGetCall) Do(opts ...googlea if err := googleapi.CheckResponse(res); err != nil { return nil, gensupport.WrapError(err) } - ret := &GoogleLongrunningOperation{ + ret := &GoogleCloudAiplatformV1beta1DatasetVersion{ ServerResponse: googleapi.ServerResponse{ Header: res.Header, HTTPStatusCode: res.StatusCode, @@ -41367,25 +42349,31 @@ func (c *ProjectsLocationsDatasetsDataItemsOperationsGetCall) Do(opts ...googlea } return ret, nil // { - // "description": "Gets the latest state of a long-running operation. Clients can use this method to poll the operation result at intervals as recommended by the API service.", - // "flatPath": "v1beta1/projects/{projectsId}/locations/{locationsId}/datasets/{datasetsId}/dataItems/{dataItemsId}/operations/{operationsId}", + // "description": "Gets a Dataset version.", + // "flatPath": "v1beta1/projects/{projectsId}/locations/{locationsId}/datasets/{datasetsId}/datasetVersions/{datasetVersionsId}", // "httpMethod": "GET", - // "id": "aiplatform.projects.locations.datasets.dataItems.operations.get", + // "id": "aiplatform.projects.locations.datasets.datasetVersions.get", // "parameterOrder": [ // "name" // ], // "parameters": { // "name": { - // "description": "The name of the operation resource.", + // "description": "Required. The resource name of the Dataset version to delete. Format: `projects/{project}/locations/{location}/datasets/{dataset}/datasetVersions/{dataset_version}`", // "location": "path", - // "pattern": "^projects/[^/]+/locations/[^/]+/datasets/[^/]+/dataItems/[^/]+/operations/[^/]+$", + // "pattern": "^projects/[^/]+/locations/[^/]+/datasets/[^/]+/datasetVersions/[^/]+$", // "required": true, // "type": "string" + // }, + // "readMask": { + // "description": "Mask specifying which fields to read.", + // "format": "google-fieldmask", + // "location": "query", + // "type": "string" // } // }, // "path": "v1beta1/{+name}", // "response": { - // "$ref": "GoogleLongrunningOperation" + // "$ref": "GoogleCloudAiplatformV1beta1DatasetVersion" // }, // "scopes": [ // "https://www.googleapis.com/auth/cloud-platform" @@ -41394,53 +42382,68 @@ func (c *ProjectsLocationsDatasetsDataItemsOperationsGetCall) Do(opts ...googlea } -// method id "aiplatform.projects.locations.datasets.dataItems.operations.list": +// method id "aiplatform.projects.locations.datasets.datasetVersions.list": -type ProjectsLocationsDatasetsDataItemsOperationsListCall struct { +type ProjectsLocationsDatasetsDatasetVersionsListCall struct { s *Service - name string + parent string urlParams_ gensupport.URLParams ifNoneMatch_ string ctx_ context.Context header_ http.Header } -// List: Lists operations that match the specified filter in the -// request. If the server doesn't support this method, it returns -// `UNIMPLEMENTED`. +// List: Lists DatasetVersions in a Dataset. // -// - name: The name of the operation's parent resource. -func (r *ProjectsLocationsDatasetsDataItemsOperationsService) List(name string) *ProjectsLocationsDatasetsDataItemsOperationsListCall { - c := &ProjectsLocationsDatasetsDataItemsOperationsListCall{s: r.s, urlParams_: make(gensupport.URLParams)} - c.name = name +// - parent: The resource name of the Dataset to list DatasetVersions +// from. Format: +// `projects/{project}/locations/{location}/datasets/{dataset}`. +func (r *ProjectsLocationsDatasetsDatasetVersionsService) List(parent string) *ProjectsLocationsDatasetsDatasetVersionsListCall { + c := &ProjectsLocationsDatasetsDatasetVersionsListCall{s: r.s, urlParams_: make(gensupport.URLParams)} + c.parent = parent return c } // Filter sets the optional parameter "filter": The standard list // filter. -func (c *ProjectsLocationsDatasetsDataItemsOperationsListCall) Filter(filter string) *ProjectsLocationsDatasetsDataItemsOperationsListCall { +func (c *ProjectsLocationsDatasetsDatasetVersionsListCall) Filter(filter string) *ProjectsLocationsDatasetsDatasetVersionsListCall { c.urlParams_.Set("filter", filter) return c } +// OrderBy sets the optional parameter "orderBy": A comma-separated list +// of fields to order by, sorted in ascending order. Use "desc" after a +// field name for descending. +func (c *ProjectsLocationsDatasetsDatasetVersionsListCall) OrderBy(orderBy string) *ProjectsLocationsDatasetsDatasetVersionsListCall { + c.urlParams_.Set("orderBy", orderBy) + return c +} + // PageSize sets the optional parameter "pageSize": The standard list // page size. -func (c *ProjectsLocationsDatasetsDataItemsOperationsListCall) PageSize(pageSize int64) *ProjectsLocationsDatasetsDataItemsOperationsListCall { +func (c *ProjectsLocationsDatasetsDatasetVersionsListCall) PageSize(pageSize int64) *ProjectsLocationsDatasetsDatasetVersionsListCall { c.urlParams_.Set("pageSize", fmt.Sprint(pageSize)) return c } // PageToken sets the optional parameter "pageToken": The standard list // page token. -func (c *ProjectsLocationsDatasetsDataItemsOperationsListCall) PageToken(pageToken string) *ProjectsLocationsDatasetsDataItemsOperationsListCall { +func (c *ProjectsLocationsDatasetsDatasetVersionsListCall) PageToken(pageToken string) *ProjectsLocationsDatasetsDatasetVersionsListCall { c.urlParams_.Set("pageToken", pageToken) return c } +// ReadMask sets the optional parameter "readMask": Mask specifying +// which fields to read. +func (c *ProjectsLocationsDatasetsDatasetVersionsListCall) ReadMask(readMask string) *ProjectsLocationsDatasetsDatasetVersionsListCall { + c.urlParams_.Set("readMask", readMask) + return c +} + // Fields allows partial responses to be retrieved. See // https://developers.google.com/gdata/docs/2.0/basics#PartialResponse // for more information. -func (c *ProjectsLocationsDatasetsDataItemsOperationsListCall) Fields(s ...googleapi.Field) *ProjectsLocationsDatasetsDataItemsOperationsListCall { +func (c *ProjectsLocationsDatasetsDatasetVersionsListCall) Fields(s ...googleapi.Field) *ProjectsLocationsDatasetsDatasetVersionsListCall { c.urlParams_.Set("fields", googleapi.CombineFields(s)) return c } @@ -41450,7 +42453,7 @@ func (c *ProjectsLocationsDatasetsDataItemsOperationsListCall) Fields(s ...googl // getting updates only after the object has changed since the last // request. Use googleapi.IsNotModified to check whether the response // error from Do is the result of In-None-Match. -func (c *ProjectsLocationsDatasetsDataItemsOperationsListCall) IfNoneMatch(entityTag string) *ProjectsLocationsDatasetsDataItemsOperationsListCall { +func (c *ProjectsLocationsDatasetsDatasetVersionsListCall) IfNoneMatch(entityTag string) *ProjectsLocationsDatasetsDatasetVersionsListCall { c.ifNoneMatch_ = entityTag return c } @@ -41458,21 +42461,21 @@ func (c *ProjectsLocationsDatasetsDataItemsOperationsListCall) IfNoneMatch(entit // Context sets the context to be used in this call's Do method. Any // pending HTTP request will be aborted if the provided context is // canceled. -func (c *ProjectsLocationsDatasetsDataItemsOperationsListCall) Context(ctx context.Context) *ProjectsLocationsDatasetsDataItemsOperationsListCall { +func (c *ProjectsLocationsDatasetsDatasetVersionsListCall) Context(ctx context.Context) *ProjectsLocationsDatasetsDatasetVersionsListCall { c.ctx_ = ctx return c } // Header returns an http.Header that can be modified by the caller to // add HTTP headers to the request. -func (c *ProjectsLocationsDatasetsDataItemsOperationsListCall) Header() http.Header { +func (c *ProjectsLocationsDatasetsDatasetVersionsListCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) } return c.header_ } -func (c *ProjectsLocationsDatasetsDataItemsOperationsListCall) doRequest(alt string) (*http.Response, error) { +func (c *ProjectsLocationsDatasetsDatasetVersionsListCall) doRequest(alt string) (*http.Response, error) { reqHeaders := make(http.Header) reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version) for k, v := range c.header_ { @@ -41485,7 +42488,7 @@ func (c *ProjectsLocationsDatasetsDataItemsOperationsListCall) doRequest(alt str var body io.Reader = nil c.urlParams_.Set("alt", alt) c.urlParams_.Set("prettyPrint", "false") - urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta1/{+name}/operations") + urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta1/{+parent}/datasetVersions") urls += "?" + c.urlParams_.Encode() req, err := http.NewRequest("GET", urls, body) if err != nil { @@ -41493,20 +42496,22 @@ func (c *ProjectsLocationsDatasetsDataItemsOperationsListCall) doRequest(alt str } req.Header = reqHeaders googleapi.Expand(req.URL, map[string]string{ - "name": c.name, + "parent": c.parent, }) return gensupport.SendRequest(c.ctx_, c.s.client, req) } -// Do executes the "aiplatform.projects.locations.datasets.dataItems.operations.list" call. -// Exactly one of *GoogleLongrunningListOperationsResponse or error will -// be non-nil. Any non-2xx status code is an error. Response headers are -// in either -// *GoogleLongrunningListOperationsResponse.ServerResponse.Header or (if -// a response was returned at all) in error.(*googleapi.Error).Header. -// Use googleapi.IsNotModified to check whether the returned error was -// because http.StatusNotModified was returned. -func (c *ProjectsLocationsDatasetsDataItemsOperationsListCall) Do(opts ...googleapi.CallOption) (*GoogleLongrunningListOperationsResponse, error) { +// Do executes the "aiplatform.projects.locations.datasets.datasetVersions.list" call. +// Exactly one of +// *GoogleCloudAiplatformV1beta1ListDatasetVersionsResponse or error +// will be non-nil. Any non-2xx status code is an error. Response +// headers are in either +// *GoogleCloudAiplatformV1beta1ListDatasetVersionsResponse.ServerRespons +// e.Header or (if a response was returned at all) in +// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check +// whether the returned error was because http.StatusNotModified was +// returned. +func (c *ProjectsLocationsDatasetsDatasetVersionsListCall) Do(opts ...googleapi.CallOption) (*GoogleCloudAiplatformV1beta1ListDatasetVersionsResponse, error) { gensupport.SetOptions(c.urlParams_, opts...) res, err := c.doRequest("json") if res != nil && res.StatusCode == http.StatusNotModified { @@ -41525,7 +42530,7 @@ func (c *ProjectsLocationsDatasetsDataItemsOperationsListCall) Do(opts ...google if err := googleapi.CheckResponse(res); err != nil { return nil, gensupport.WrapError(err) } - ret := &GoogleLongrunningListOperationsResponse{ + ret := &GoogleCloudAiplatformV1beta1ListDatasetVersionsResponse{ ServerResponse: googleapi.ServerResponse{ Header: res.Header, HTTPStatusCode: res.StatusCode, @@ -41537,41 +42542,52 @@ func (c *ProjectsLocationsDatasetsDataItemsOperationsListCall) Do(opts ...google } return ret, nil // { - // "description": "Lists operations that match the specified filter in the request. If the server doesn't support this method, it returns `UNIMPLEMENTED`.", - // "flatPath": "v1beta1/projects/{projectsId}/locations/{locationsId}/datasets/{datasetsId}/dataItems/{dataItemsId}/operations", + // "description": "Lists DatasetVersions in a Dataset.", + // "flatPath": "v1beta1/projects/{projectsId}/locations/{locationsId}/datasets/{datasetsId}/datasetVersions", // "httpMethod": "GET", - // "id": "aiplatform.projects.locations.datasets.dataItems.operations.list", + // "id": "aiplatform.projects.locations.datasets.datasetVersions.list", // "parameterOrder": [ - // "name" + // "parent" // ], // "parameters": { // "filter": { - // "description": "The standard list filter.", + // "description": "Optional. The standard list filter.", // "location": "query", // "type": "string" // }, - // "name": { - // "description": "The name of the operation's parent resource.", - // "location": "path", - // "pattern": "^projects/[^/]+/locations/[^/]+/datasets/[^/]+/dataItems/[^/]+$", - // "required": true, + // "orderBy": { + // "description": "Optional. A comma-separated list of fields to order by, sorted in ascending order. Use \"desc\" after a field name for descending.", + // "location": "query", // "type": "string" // }, // "pageSize": { - // "description": "The standard list page size.", + // "description": "Optional. The standard list page size.", // "format": "int32", // "location": "query", // "type": "integer" // }, // "pageToken": { - // "description": "The standard list page token.", + // "description": "Optional. The standard list page token.", + // "location": "query", + // "type": "string" + // }, + // "parent": { + // "description": "Required. The resource name of the Dataset to list DatasetVersions from. Format: `projects/{project}/locations/{location}/datasets/{dataset}`", + // "location": "path", + // "pattern": "^projects/[^/]+/locations/[^/]+/datasets/[^/]+$", + // "required": true, + // "type": "string" + // }, + // "readMask": { + // "description": "Optional. Mask specifying which fields to read.", + // "format": "google-fieldmask", // "location": "query", // "type": "string" // } // }, - // "path": "v1beta1/{+name}/operations", + // "path": "v1beta1/{+parent}/datasetVersions", // "response": { - // "$ref": "GoogleLongrunningListOperationsResponse" + // "$ref": "GoogleCloudAiplatformV1beta1ListDatasetVersionsResponse" // }, // "scopes": [ // "https://www.googleapis.com/auth/cloud-platform" @@ -41583,7 +42599,7 @@ func (c *ProjectsLocationsDatasetsDataItemsOperationsListCall) Do(opts ...google // Pages invokes f for each page of results. // A non-nil error returned from f will halt the iteration. // The provided context supersedes any context provided to the Context method. -func (c *ProjectsLocationsDatasetsDataItemsOperationsListCall) Pages(ctx context.Context, f func(*GoogleLongrunningListOperationsResponse) error) error { +func (c *ProjectsLocationsDatasetsDatasetVersionsListCall) Pages(ctx context.Context, f func(*GoogleCloudAiplatformV1beta1ListDatasetVersionsResponse) error) error { c.ctx_ = ctx defer c.PageToken(c.urlParams_.Get("pageToken")) // reset paging to original point for { @@ -41601,81 +42617,79 @@ func (c *ProjectsLocationsDatasetsDataItemsOperationsListCall) Pages(ctx context } } -// method id "aiplatform.projects.locations.datasets.dataItems.operations.wait": +// method id "aiplatform.projects.locations.datasets.datasetVersions.restore": -type ProjectsLocationsDatasetsDataItemsOperationsWaitCall struct { - s *Service - name string - urlParams_ gensupport.URLParams - ctx_ context.Context - header_ http.Header +type ProjectsLocationsDatasetsDatasetVersionsRestoreCall struct { + s *Service + name string + urlParams_ gensupport.URLParams + ifNoneMatch_ string + ctx_ context.Context + header_ http.Header } -// Wait: Waits until the specified long-running operation is done or -// reaches at most a specified timeout, returning the latest state. If -// the operation is already done, the latest state is immediately -// returned. If the timeout specified is greater than the default -// HTTP/RPC timeout, the HTTP/RPC timeout is used. If the server does -// not support this method, it returns `google.rpc.Code.UNIMPLEMENTED`. -// Note that this method is on a best-effort basis. It may return the -// latest state before the specified timeout (including immediately), -// meaning even an immediate response is no guarantee that the operation -// is done. +// Restore: Restores a dataset version. // -// - name: The name of the operation resource to wait on. -func (r *ProjectsLocationsDatasetsDataItemsOperationsService) Wait(name string) *ProjectsLocationsDatasetsDataItemsOperationsWaitCall { - c := &ProjectsLocationsDatasetsDataItemsOperationsWaitCall{s: r.s, urlParams_: make(gensupport.URLParams)} +// - name: The name of the DatasetVersion resource. Format: +// `projects/{project}/locations/{location}/datasets/{dataset}/datasetV +// ersions/{dataset_version}`. +func (r *ProjectsLocationsDatasetsDatasetVersionsService) Restore(name string) *ProjectsLocationsDatasetsDatasetVersionsRestoreCall { + c := &ProjectsLocationsDatasetsDatasetVersionsRestoreCall{s: r.s, urlParams_: make(gensupport.URLParams)} c.name = name return c } -// Timeout sets the optional parameter "timeout": The maximum duration -// to wait before timing out. If left blank, the wait will be at most -// the time permitted by the underlying HTTP/RPC protocol. If RPC -// context deadline is also specified, the shorter one will be used. -func (c *ProjectsLocationsDatasetsDataItemsOperationsWaitCall) Timeout(timeout string) *ProjectsLocationsDatasetsDataItemsOperationsWaitCall { - c.urlParams_.Set("timeout", timeout) - return c -} - // Fields allows partial responses to be retrieved. See // https://developers.google.com/gdata/docs/2.0/basics#PartialResponse // for more information. -func (c *ProjectsLocationsDatasetsDataItemsOperationsWaitCall) Fields(s ...googleapi.Field) *ProjectsLocationsDatasetsDataItemsOperationsWaitCall { +func (c *ProjectsLocationsDatasetsDatasetVersionsRestoreCall) Fields(s ...googleapi.Field) *ProjectsLocationsDatasetsDatasetVersionsRestoreCall { c.urlParams_.Set("fields", googleapi.CombineFields(s)) return c } +// IfNoneMatch sets the optional parameter which makes the operation +// fail if the object's ETag matches the given value. This is useful for +// getting updates only after the object has changed since the last +// request. Use googleapi.IsNotModified to check whether the response +// error from Do is the result of In-None-Match. +func (c *ProjectsLocationsDatasetsDatasetVersionsRestoreCall) IfNoneMatch(entityTag string) *ProjectsLocationsDatasetsDatasetVersionsRestoreCall { + c.ifNoneMatch_ = entityTag + return c +} + // Context sets the context to be used in this call's Do method. Any // pending HTTP request will be aborted if the provided context is // canceled. -func (c *ProjectsLocationsDatasetsDataItemsOperationsWaitCall) Context(ctx context.Context) *ProjectsLocationsDatasetsDataItemsOperationsWaitCall { +func (c *ProjectsLocationsDatasetsDatasetVersionsRestoreCall) Context(ctx context.Context) *ProjectsLocationsDatasetsDatasetVersionsRestoreCall { c.ctx_ = ctx return c } // Header returns an http.Header that can be modified by the caller to // add HTTP headers to the request. -func (c *ProjectsLocationsDatasetsDataItemsOperationsWaitCall) Header() http.Header { +func (c *ProjectsLocationsDatasetsDatasetVersionsRestoreCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) } return c.header_ } -func (c *ProjectsLocationsDatasetsDataItemsOperationsWaitCall) doRequest(alt string) (*http.Response, error) { +func (c *ProjectsLocationsDatasetsDatasetVersionsRestoreCall) doRequest(alt string) (*http.Response, error) { reqHeaders := make(http.Header) reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version) for k, v := range c.header_ { reqHeaders[k] = v } reqHeaders.Set("User-Agent", c.s.userAgent()) + if c.ifNoneMatch_ != "" { + reqHeaders.Set("If-None-Match", c.ifNoneMatch_) + } var body io.Reader = nil c.urlParams_.Set("alt", alt) c.urlParams_.Set("prettyPrint", "false") - urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta1/{+name}:wait") + urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta1/{+name}:restore") urls += "?" + c.urlParams_.Encode() - req, err := http.NewRequest("POST", urls, body) + req, err := http.NewRequest("GET", urls, body) if err != nil { return nil, err } @@ -41686,14 +42700,14 @@ func (c *ProjectsLocationsDatasetsDataItemsOperationsWaitCall) doRequest(alt str return gensupport.SendRequest(c.ctx_, c.s.client, req) } -// Do executes the "aiplatform.projects.locations.datasets.dataItems.operations.wait" call. +// Do executes the "aiplatform.projects.locations.datasets.datasetVersions.restore" call. // Exactly one of *GoogleLongrunningOperation or error will be non-nil. // Any non-2xx status code is an error. Response headers are in either // *GoogleLongrunningOperation.ServerResponse.Header or (if a response // was returned at all) in error.(*googleapi.Error).Header. Use // googleapi.IsNotModified to check whether the returned error was // because http.StatusNotModified was returned. -func (c *ProjectsLocationsDatasetsDataItemsOperationsWaitCall) Do(opts ...googleapi.CallOption) (*GoogleLongrunningOperation, error) { +func (c *ProjectsLocationsDatasetsDatasetVersionsRestoreCall) Do(opts ...googleapi.CallOption) (*GoogleLongrunningOperation, error) { gensupport.SetOptions(c.urlParams_, opts...) res, err := c.doRequest("json") if res != nil && res.StatusCode == http.StatusNotModified { @@ -41724,29 +42738,23 @@ func (c *ProjectsLocationsDatasetsDataItemsOperationsWaitCall) Do(opts ...google } return ret, nil // { - // "description": "Waits until the specified long-running operation is done or reaches at most a specified timeout, returning the latest state. If the operation is already done, the latest state is immediately returned. If the timeout specified is greater than the default HTTP/RPC timeout, the HTTP/RPC timeout is used. If the server does not support this method, it returns `google.rpc.Code.UNIMPLEMENTED`. Note that this method is on a best-effort basis. It may return the latest state before the specified timeout (including immediately), meaning even an immediate response is no guarantee that the operation is done.", - // "flatPath": "v1beta1/projects/{projectsId}/locations/{locationsId}/datasets/{datasetsId}/dataItems/{dataItemsId}/operations/{operationsId}:wait", - // "httpMethod": "POST", - // "id": "aiplatform.projects.locations.datasets.dataItems.operations.wait", + // "description": "Restores a dataset version.", + // "flatPath": "v1beta1/projects/{projectsId}/locations/{locationsId}/datasets/{datasetsId}/datasetVersions/{datasetVersionsId}:restore", + // "httpMethod": "GET", + // "id": "aiplatform.projects.locations.datasets.datasetVersions.restore", // "parameterOrder": [ // "name" // ], // "parameters": { // "name": { - // "description": "The name of the operation resource to wait on.", + // "description": "Required. The name of the DatasetVersion resource. Format: `projects/{project}/locations/{location}/datasets/{dataset}/datasetVersions/{dataset_version}`", // "location": "path", - // "pattern": "^projects/[^/]+/locations/[^/]+/datasets/[^/]+/dataItems/[^/]+/operations/[^/]+$", + // "pattern": "^projects/[^/]+/locations/[^/]+/datasets/[^/]+/datasetVersions/[^/]+$", // "required": true, // "type": "string" - // }, - // "timeout": { - // "description": "The maximum duration to wait before timing out. If left blank, the wait will be at most the time permitted by the underlying HTTP/RPC protocol. If RPC context deadline is also specified, the shorter one will be used.", - // "format": "google-duration", - // "location": "query", - // "type": "string" // } // }, - // "path": "v1beta1/{+name}:wait", + // "path": "v1beta1/{+name}:restore", // "response": { // "$ref": "GoogleLongrunningOperation" // }, diff --git a/discoveryengine/v1alpha/discoveryengine-api.json b/discoveryengine/v1alpha/discoveryengine-api.json index 03c33917f6d..f216025d7c3 100644 --- a/discoveryengine/v1alpha/discoveryengine-api.json +++ b/discoveryengine/v1alpha/discoveryengine-api.json @@ -256,7 +256,7 @@ "type": "string" }, "queryModel": { - "description": "Selects data model of query suggestions for serving. Currently supported values: * `document` - Using suggestions generated from user-imported documents. * `search-history` - Using suggestions generated from the past history of SearchService.Search API calls. Do not use it when there is no traffic for Search API. * `user-event` - Using suggestions generated from user-imported search events. * `document-completable` - Using suggestions taken directly from user-imported document fields marked as completable. Default values: * `document` is the default model for regular dataStores. * `search-history` is the default model for IndustryVertical.SITE_SEARCH dataStores.", + "description": "Selects data model of query suggestions for serving. Currently supported values: * `document` - Using suggestions generated from user-imported documents. * `search-history` - Using suggestions generated from the past history of SearchService.Search API calls. Do not use it when there is no traffic for Search API. * `user-event` - Using suggestions generated from user-imported search events. * `document-completable` - Using suggestions taken directly from user-imported document fields marked as completable. Default values: * `document` is the default model for regular dataStores. * `search-history` is the default model for site search dataStores.", "location": "query", "type": "string" }, @@ -1185,6 +1185,36 @@ } }, "siteSearchEngine": { + "methods": { + "recrawlUris": { + "description": "Request on-demand recrawl for a list of URIs.", + "flatPath": "v1alpha/projects/{projectsId}/locations/{locationsId}/collections/{collectionsId}/dataStores/{dataStoresId}/siteSearchEngine:recrawlUris", + "httpMethod": "POST", + "id": "discoveryengine.projects.locations.collections.dataStores.siteSearchEngine.recrawlUris", + "parameterOrder": [ + "siteSearchEngine" + ], + "parameters": { + "siteSearchEngine": { + "description": "Required. Full resource name of the SiteSearchEngine, such as `projects/*/locations/*/collections/*/dataStores/*/siteSearchEngine`.", + "location": "path", + "pattern": "^projects/[^/]+/locations/[^/]+/collections/[^/]+/dataStores/[^/]+/siteSearchEngine$", + "required": true, + "type": "string" + } + }, + "path": "v1alpha/{+siteSearchEngine}:recrawlUris", + "request": { + "$ref": "GoogleCloudDiscoveryengineV1alphaRecrawlUrisRequest" + }, + "response": { + "$ref": "GoogleLongrunningOperation" + }, + "scopes": [ + "https://www.googleapis.com/auth/cloud-platform" + ] + } + }, "resources": { "operations": { "methods": { @@ -1638,7 +1668,7 @@ "type": "string" }, "queryModel": { - "description": "Selects data model of query suggestions for serving. Currently supported values: * `document` - Using suggestions generated from user-imported documents. * `search-history` - Using suggestions generated from the past history of SearchService.Search API calls. Do not use it when there is no traffic for Search API. * `user-event` - Using suggestions generated from user-imported search events. * `document-completable` - Using suggestions taken directly from user-imported document fields marked as completable. Default values: * `document` is the default model for regular dataStores. * `search-history` is the default model for IndustryVertical.SITE_SEARCH dataStores.", + "description": "Selects data model of query suggestions for serving. Currently supported values: * `document` - Using suggestions generated from user-imported documents. * `search-history` - Using suggestions generated from the past history of SearchService.Search API calls. Do not use it when there is no traffic for Search API. * `user-event` - Using suggestions generated from user-imported search events. * `document-completable` - Using suggestions taken directly from user-imported document fields marked as completable. Default values: * `document` is the default model for regular dataStores. * `search-history` is the default model for site search dataStores.", "location": "query", "type": "string" }, @@ -2494,6 +2524,38 @@ } } }, + "siteSearchEngine": { + "methods": { + "recrawlUris": { + "description": "Request on-demand recrawl for a list of URIs.", + "flatPath": "v1alpha/projects/{projectsId}/locations/{locationsId}/dataStores/{dataStoresId}/siteSearchEngine:recrawlUris", + "httpMethod": "POST", + "id": "discoveryengine.projects.locations.dataStores.siteSearchEngine.recrawlUris", + "parameterOrder": [ + "siteSearchEngine" + ], + "parameters": { + "siteSearchEngine": { + "description": "Required. Full resource name of the SiteSearchEngine, such as `projects/*/locations/*/collections/*/dataStores/*/siteSearchEngine`.", + "location": "path", + "pattern": "^projects/[^/]+/locations/[^/]+/dataStores/[^/]+/siteSearchEngine$", + "required": true, + "type": "string" + } + }, + "path": "v1alpha/{+siteSearchEngine}:recrawlUris", + "request": { + "$ref": "GoogleCloudDiscoveryengineV1alphaRecrawlUrisRequest" + }, + "response": { + "$ref": "GoogleLongrunningOperation" + }, + "scopes": [ + "https://www.googleapis.com/auth/cloud-platform" + ] + } + } + }, "userEvents": { "methods": { "collect": { @@ -2770,7 +2832,7 @@ } } }, - "revision": "20230914", + "revision": "20230925", "rootUrl": "https://discoveryengine.googleapis.com/", "schemas": { "GoogleApiHttpBody": { @@ -3223,7 +3285,7 @@ "type": "string" }, "queryModel": { - "description": "Selects data model of query suggestions for serving. Currently supported values: * `document` - Using suggestions generated from user-imported documents. * `search-history` - Using suggestions generated from the past history of SearchService.Search API calls. Do not use it when there is no traffic for Search API. * `user-event` - Using suggestions generated from user-imported search events. * `document-completable` - Using suggestions taken directly from user-imported document fields marked as completable. Default values: * `document` is the default model for regular dataStores. * `search-history` is the default model for IndustryVertical.SITE_SEARCH dataStores.", + "description": "Selects data model of query suggestions for serving. Currently supported values: * `document` - Using suggestions generated from user-imported documents. * `search-history` - Using suggestions generated from the past history of SearchService.Search API calls. Do not use it when there is no traffic for Search API. * `user-event` - Using suggestions generated from user-imported search events. * `document-completable` - Using suggestions taken directly from user-imported document fields marked as completable. Default values: * `document` is the default model for regular dataStores. * `search-history` is the default model for site search dataStores.", "type": "string" }, "userPseudoId": { @@ -4327,6 +4389,128 @@ }, "type": "object" }, + "GoogleCloudDiscoveryengineV1alphaRecrawlUrisMetadata": { + "description": "Metadata related to the progress of the SiteSearchEngineService.RecrawlUris operation. This will be returned by the google.longrunning.Operation.metadata field.", + "id": "GoogleCloudDiscoveryengineV1alphaRecrawlUrisMetadata", + "properties": { + "createTime": { + "description": "Operation create time.", + "format": "google-datetime", + "type": "string" + }, + "invalidUris": { + "description": "Unique URIs in the request that don't match any TargetSite in the DataStore, only match TargetSites that haven't been fully indexed, or match a TargetSite with type EXCLUDE.", + "items": { + "type": "string" + }, + "type": "array" + }, + "pendingCount": { + "description": "Total number of URIs that have yet to be crawled.", + "format": "int32", + "type": "integer" + }, + "quotaExceededCount": { + "description": "Total number of URIs that were rejected due to insufficient indexing resources.", + "format": "int32", + "type": "integer" + }, + "successCount": { + "description": "Total number of URIs that have been crawled so far.", + "format": "int32", + "type": "integer" + }, + "updateTime": { + "description": "Operation last update time. If the operation is done, this is also the finish time.", + "format": "google-datetime", + "type": "string" + }, + "validUrisCount": { + "description": "Total number of unique URIs in the request that are not in invalid_uris.", + "format": "int32", + "type": "integer" + } + }, + "type": "object" + }, + "GoogleCloudDiscoveryengineV1alphaRecrawlUrisRequest": { + "description": "Request message for SiteSearchEngineService.RecrawlUris method.", + "id": "GoogleCloudDiscoveryengineV1alphaRecrawlUrisRequest", + "properties": { + "uris": { + "description": "Required. List of URIs to crawl. At most 10K URIs are supported, otherwise an INVALID_ARGUMENT error is thrown. Each URI should match at least one TargetSite in `site_search_engine`.", + "items": { + "type": "string" + }, + "type": "array" + } + }, + "type": "object" + }, + "GoogleCloudDiscoveryengineV1alphaRecrawlUrisResponse": { + "description": "Response message for SiteSearchEngineService.RecrawlUris method.", + "id": "GoogleCloudDiscoveryengineV1alphaRecrawlUrisResponse", + "properties": { + "failedUris": { + "description": "URIs that were not crawled before the LRO terminated.", + "items": { + "type": "string" + }, + "type": "array" + }, + "failureSamples": { + "description": "Details for a sample of up to 10 `failed_uris`.", + "items": { + "$ref": "GoogleCloudDiscoveryengineV1alphaRecrawlUrisResponseFailureInfo" + }, + "type": "array" + } + }, + "type": "object" + }, + "GoogleCloudDiscoveryengineV1alphaRecrawlUrisResponseFailureInfo": { + "description": "Details about why a particular URI failed to be crawled. Each FailureInfo contains one FailureReason per CorpusType.", + "id": "GoogleCloudDiscoveryengineV1alphaRecrawlUrisResponseFailureInfo", + "properties": { + "failureReasons": { + "description": "List of failure reasons by corpus type (e.g. desktop, mobile).", + "items": { + "$ref": "GoogleCloudDiscoveryengineV1alphaRecrawlUrisResponseFailureInfoFailureReason" + }, + "type": "array" + }, + "uri": { + "description": "URI that failed to be crawled.", + "type": "string" + } + }, + "type": "object" + }, + "GoogleCloudDiscoveryengineV1alphaRecrawlUrisResponseFailureInfoFailureReason": { + "description": "Details about why crawling failed for a particular CorpusType, e.g. DESKTOP and MOBILE crawling may fail for different reasons.", + "id": "GoogleCloudDiscoveryengineV1alphaRecrawlUrisResponseFailureInfoFailureReason", + "properties": { + "corpusType": { + "description": "DESKTOP, MOBILE, or CORPUS_TYPE_UNSPECIFIED.", + "enum": [ + "CORPUS_TYPE_UNSPECIFIED", + "DESKTOP", + "MOBILE" + ], + "enumDescriptions": [ + "Default value.", + "Denotes a crawling attempt for the desktop version of a page.", + "Denotes a crawling attempt for the mobile version of a page." + ], + "type": "string" + }, + "errorMessage": { + "description": "Reason why the URI was not crawled.", + "type": "string" + } + }, + "type": "object" + }, "GoogleCloudDiscoveryengineV1alphaReply": { "description": "Defines a reply message to user.", "id": "GoogleCloudDiscoveryengineV1alphaReply", diff --git a/discoveryengine/v1alpha/discoveryengine-gen.go b/discoveryengine/v1alpha/discoveryengine-gen.go index 5a82ced3333..d1fff2e3179 100644 --- a/discoveryengine/v1alpha/discoveryengine-gen.go +++ b/discoveryengine/v1alpha/discoveryengine-gen.go @@ -441,6 +441,7 @@ func NewProjectsLocationsDataStoresService(s *Service) *ProjectsLocationsDataSto rs.Operations = NewProjectsLocationsDataStoresOperationsService(s) rs.Schemas = NewProjectsLocationsDataStoresSchemasService(s) rs.ServingConfigs = NewProjectsLocationsDataStoresServingConfigsService(s) + rs.SiteSearchEngine = NewProjectsLocationsDataStoresSiteSearchEngineService(s) rs.UserEvents = NewProjectsLocationsDataStoresUserEventsService(s) return rs } @@ -460,6 +461,8 @@ type ProjectsLocationsDataStoresService struct { ServingConfigs *ProjectsLocationsDataStoresServingConfigsService + SiteSearchEngine *ProjectsLocationsDataStoresSiteSearchEngineService + UserEvents *ProjectsLocationsDataStoresUserEventsService } @@ -553,6 +556,15 @@ type ProjectsLocationsDataStoresServingConfigsService struct { s *Service } +func NewProjectsLocationsDataStoresSiteSearchEngineService(s *Service) *ProjectsLocationsDataStoresSiteSearchEngineService { + rs := &ProjectsLocationsDataStoresSiteSearchEngineService{s: s} + return rs +} + +type ProjectsLocationsDataStoresSiteSearchEngineService struct { + s *Service +} + func NewProjectsLocationsDataStoresUserEventsService(s *Service) *ProjectsLocationsDataStoresUserEventsService { rs := &ProjectsLocationsDataStoresUserEventsService{s: s} return rs @@ -1437,8 +1449,7 @@ type GoogleCloudDiscoveryengineV1alphaCompleteQueryRequest struct { // events. * `document-completable` - Using suggestions taken directly // from user-imported document fields marked as completable. Default // values: * `document` is the default model for regular dataStores. * - // `search-history` is the default model for - // IndustryVertical.SITE_SEARCH dataStores. + // `search-history` is the default model for site search dataStores. QueryModel string `json:"queryModel,omitempty"` // UserPseudoId: A unique identifier for tracking visitors. For example, @@ -3566,6 +3577,199 @@ func (s *GoogleCloudDiscoveryengineV1alphaRecommendResponseRecommendationResult) return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } +// GoogleCloudDiscoveryengineV1alphaRecrawlUrisMetadata: Metadata +// related to the progress of the SiteSearchEngineService.RecrawlUris +// operation. This will be returned by the +// google.longrunning.Operation.metadata field. +type GoogleCloudDiscoveryengineV1alphaRecrawlUrisMetadata struct { + // CreateTime: Operation create time. + CreateTime string `json:"createTime,omitempty"` + + // InvalidUris: Unique URIs in the request that don't match any + // TargetSite in the DataStore, only match TargetSites that haven't been + // fully indexed, or match a TargetSite with type EXCLUDE. + InvalidUris []string `json:"invalidUris,omitempty"` + + // PendingCount: Total number of URIs that have yet to be crawled. + PendingCount int64 `json:"pendingCount,omitempty"` + + // QuotaExceededCount: Total number of URIs that were rejected due to + // insufficient indexing resources. + QuotaExceededCount int64 `json:"quotaExceededCount,omitempty"` + + // SuccessCount: Total number of URIs that have been crawled so far. + SuccessCount int64 `json:"successCount,omitempty"` + + // UpdateTime: Operation last update time. If the operation is done, + // this is also the finish time. + UpdateTime string `json:"updateTime,omitempty"` + + // ValidUrisCount: Total number of unique URIs in the request that are + // not in invalid_uris. + ValidUrisCount int64 `json:"validUrisCount,omitempty"` + + // ForceSendFields is a list of field names (e.g. "CreateTime") to + // unconditionally include in API requests. By default, fields with + // empty or default values are omitted from API requests. However, any + // non-pointer, non-interface field appearing in ForceSendFields will be + // sent to the server regardless of whether the field is empty or not. + // This may be used to include empty fields in Patch requests. + ForceSendFields []string `json:"-"` + + // NullFields is a list of field names (e.g. "CreateTime") to include in + // API requests with the JSON null value. By default, fields with empty + // values are omitted from API requests. However, any field with an + // empty value appearing in NullFields will be sent to the server as + // null. It is an error if a field in this list has a non-empty value. + // This may be used to include null fields in Patch requests. + NullFields []string `json:"-"` +} + +func (s *GoogleCloudDiscoveryengineV1alphaRecrawlUrisMetadata) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaRecrawlUrisMetadata + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + +// GoogleCloudDiscoveryengineV1alphaRecrawlUrisRequest: Request message +// for SiteSearchEngineService.RecrawlUris method. +type GoogleCloudDiscoveryengineV1alphaRecrawlUrisRequest struct { + // Uris: Required. List of URIs to crawl. At most 10K URIs are + // supported, otherwise an INVALID_ARGUMENT error is thrown. Each URI + // should match at least one TargetSite in `site_search_engine`. + Uris []string `json:"uris,omitempty"` + + // ForceSendFields is a list of field names (e.g. "Uris") to + // unconditionally include in API requests. By default, fields with + // empty or default values are omitted from API requests. However, any + // non-pointer, non-interface field appearing in ForceSendFields will be + // sent to the server regardless of whether the field is empty or not. + // This may be used to include empty fields in Patch requests. + ForceSendFields []string `json:"-"` + + // NullFields is a list of field names (e.g. "Uris") to include in API + // requests with the JSON null value. By default, fields with empty + // values are omitted from API requests. However, any field with an + // empty value appearing in NullFields will be sent to the server as + // null. It is an error if a field in this list has a non-empty value. + // This may be used to include null fields in Patch requests. + NullFields []string `json:"-"` +} + +func (s *GoogleCloudDiscoveryengineV1alphaRecrawlUrisRequest) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaRecrawlUrisRequest + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + +// GoogleCloudDiscoveryengineV1alphaRecrawlUrisResponse: Response +// message for SiteSearchEngineService.RecrawlUris method. +type GoogleCloudDiscoveryengineV1alphaRecrawlUrisResponse struct { + // FailedUris: URIs that were not crawled before the LRO terminated. + FailedUris []string `json:"failedUris,omitempty"` + + // FailureSamples: Details for a sample of up to 10 `failed_uris`. + FailureSamples []*GoogleCloudDiscoveryengineV1alphaRecrawlUrisResponseFailureInfo `json:"failureSamples,omitempty"` + + // ForceSendFields is a list of field names (e.g. "FailedUris") to + // unconditionally include in API requests. By default, fields with + // empty or default values are omitted from API requests. However, any + // non-pointer, non-interface field appearing in ForceSendFields will be + // sent to the server regardless of whether the field is empty or not. + // This may be used to include empty fields in Patch requests. + ForceSendFields []string `json:"-"` + + // NullFields is a list of field names (e.g. "FailedUris") to include in + // API requests with the JSON null value. By default, fields with empty + // values are omitted from API requests. However, any field with an + // empty value appearing in NullFields will be sent to the server as + // null. It is an error if a field in this list has a non-empty value. + // This may be used to include null fields in Patch requests. + NullFields []string `json:"-"` +} + +func (s *GoogleCloudDiscoveryengineV1alphaRecrawlUrisResponse) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaRecrawlUrisResponse + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + +// GoogleCloudDiscoveryengineV1alphaRecrawlUrisResponseFailureInfo: +// Details about why a particular URI failed to be crawled. Each +// FailureInfo contains one FailureReason per CorpusType. +type GoogleCloudDiscoveryengineV1alphaRecrawlUrisResponseFailureInfo struct { + // FailureReasons: List of failure reasons by corpus type (e.g. desktop, + // mobile). + FailureReasons []*GoogleCloudDiscoveryengineV1alphaRecrawlUrisResponseFailureInfoFailureReason `json:"failureReasons,omitempty"` + + // Uri: URI that failed to be crawled. + Uri string `json:"uri,omitempty"` + + // ForceSendFields is a list of field names (e.g. "FailureReasons") to + // unconditionally include in API requests. By default, fields with + // empty or default values are omitted from API requests. However, any + // non-pointer, non-interface field appearing in ForceSendFields will be + // sent to the server regardless of whether the field is empty or not. + // This may be used to include empty fields in Patch requests. + ForceSendFields []string `json:"-"` + + // NullFields is a list of field names (e.g. "FailureReasons") to + // include in API requests with the JSON null value. By default, fields + // with empty values are omitted from API requests. However, any field + // with an empty value appearing in NullFields will be sent to the + // server as null. It is an error if a field in this list has a + // non-empty value. This may be used to include null fields in Patch + // requests. + NullFields []string `json:"-"` +} + +func (s *GoogleCloudDiscoveryengineV1alphaRecrawlUrisResponseFailureInfo) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaRecrawlUrisResponseFailureInfo + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + +// GoogleCloudDiscoveryengineV1alphaRecrawlUrisResponseFailureInfoFailure +// Reason: Details about why crawling failed for a particular +// CorpusType, e.g. DESKTOP and MOBILE crawling may fail for different +// reasons. +type GoogleCloudDiscoveryengineV1alphaRecrawlUrisResponseFailureInfoFailureReason struct { + // CorpusType: DESKTOP, MOBILE, or CORPUS_TYPE_UNSPECIFIED. + // + // Possible values: + // "CORPUS_TYPE_UNSPECIFIED" - Default value. + // "DESKTOP" - Denotes a crawling attempt for the desktop version of a + // page. + // "MOBILE" - Denotes a crawling attempt for the mobile version of a + // page. + CorpusType string `json:"corpusType,omitempty"` + + // ErrorMessage: Reason why the URI was not crawled. + ErrorMessage string `json:"errorMessage,omitempty"` + + // ForceSendFields is a list of field names (e.g. "CorpusType") to + // unconditionally include in API requests. By default, fields with + // empty or default values are omitted from API requests. However, any + // non-pointer, non-interface field appearing in ForceSendFields will be + // sent to the server regardless of whether the field is empty or not. + // This may be used to include empty fields in Patch requests. + ForceSendFields []string `json:"-"` + + // NullFields is a list of field names (e.g. "CorpusType") to include in + // API requests with the JSON null value. By default, fields with empty + // values are omitted from API requests. However, any field with an + // empty value appearing in NullFields will be sent to the server as + // null. It is an error if a field in this list has a non-empty value. + // This may be used to include null fields in Patch requests. + NullFields []string `json:"-"` +} + +func (s *GoogleCloudDiscoveryengineV1alphaRecrawlUrisResponseFailureInfoFailureReason) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaRecrawlUrisResponseFailureInfoFailureReason + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + // GoogleCloudDiscoveryengineV1alphaReply: Defines a reply message to // user. type GoogleCloudDiscoveryengineV1alphaReply struct { @@ -7204,8 +7408,7 @@ func (c *ProjectsLocationsCollectionsDataStoresCompleteQueryCall) Query(query st // `document-completable` - Using suggestions taken directly from // user-imported document fields marked as completable. Default values: // * `document` is the default model for regular dataStores. * -// `search-history` is the default model for -// IndustryVertical.SITE_SEARCH dataStores. +// `search-history` is the default model for site search dataStores. func (c *ProjectsLocationsCollectionsDataStoresCompleteQueryCall) QueryModel(queryModel string) *ProjectsLocationsCollectionsDataStoresCompleteQueryCall { c.urlParams_.Set("queryModel", queryModel) return c @@ -7354,7 +7557,7 @@ func (c *ProjectsLocationsCollectionsDataStoresCompleteQueryCall) Do(opts ...goo // "type": "string" // }, // "queryModel": { - // "description": "Selects data model of query suggestions for serving. Currently supported values: * `document` - Using suggestions generated from user-imported documents. * `search-history` - Using suggestions generated from the past history of SearchService.Search API calls. Do not use it when there is no traffic for Search API. * `user-event` - Using suggestions generated from user-imported search events. * `document-completable` - Using suggestions taken directly from user-imported document fields marked as completable. Default values: * `document` is the default model for regular dataStores. * `search-history` is the default model for IndustryVertical.SITE_SEARCH dataStores.", + // "description": "Selects data model of query suggestions for serving. Currently supported values: * `document` - Using suggestions generated from user-imported documents. * `search-history` - Using suggestions generated from the past history of SearchService.Search API calls. Do not use it when there is no traffic for Search API. * `user-event` - Using suggestions generated from user-imported search events. * `document-completable` - Using suggestions taken directly from user-imported document fields marked as completable. Default values: * `document` is the default model for regular dataStores. * `search-history` is the default model for site search dataStores.", // "location": "query", // "type": "string" // }, @@ -12013,6 +12216,151 @@ func (c *ProjectsLocationsCollectionsDataStoresServingConfigsSearchCall) Pages(c } } +// method id "discoveryengine.projects.locations.collections.dataStores.siteSearchEngine.recrawlUris": + +type ProjectsLocationsCollectionsDataStoresSiteSearchEngineRecrawlUrisCall struct { + s *Service + siteSearchEngine string + googleclouddiscoveryenginev1alpharecrawlurisrequest *GoogleCloudDiscoveryengineV1alphaRecrawlUrisRequest + urlParams_ gensupport.URLParams + ctx_ context.Context + header_ http.Header +} + +// RecrawlUris: Request on-demand recrawl for a list of URIs. +// +// - siteSearchEngine: Full resource name of the SiteSearchEngine, such +// as +// `projects/*/locations/*/collections/*/dataStores/*/siteSearchEngine` +// . +func (r *ProjectsLocationsCollectionsDataStoresSiteSearchEngineService) RecrawlUris(siteSearchEngine string, googleclouddiscoveryenginev1alpharecrawlurisrequest *GoogleCloudDiscoveryengineV1alphaRecrawlUrisRequest) *ProjectsLocationsCollectionsDataStoresSiteSearchEngineRecrawlUrisCall { + c := &ProjectsLocationsCollectionsDataStoresSiteSearchEngineRecrawlUrisCall{s: r.s, urlParams_: make(gensupport.URLParams)} + c.siteSearchEngine = siteSearchEngine + c.googleclouddiscoveryenginev1alpharecrawlurisrequest = googleclouddiscoveryenginev1alpharecrawlurisrequest + return c +} + +// Fields allows partial responses to be retrieved. See +// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse +// for more information. +func (c *ProjectsLocationsCollectionsDataStoresSiteSearchEngineRecrawlUrisCall) Fields(s ...googleapi.Field) *ProjectsLocationsCollectionsDataStoresSiteSearchEngineRecrawlUrisCall { + c.urlParams_.Set("fields", googleapi.CombineFields(s)) + return c +} + +// Context sets the context to be used in this call's Do method. Any +// pending HTTP request will be aborted if the provided context is +// canceled. +func (c *ProjectsLocationsCollectionsDataStoresSiteSearchEngineRecrawlUrisCall) Context(ctx context.Context) *ProjectsLocationsCollectionsDataStoresSiteSearchEngineRecrawlUrisCall { + c.ctx_ = ctx + return c +} + +// Header returns an http.Header that can be modified by the caller to +// add HTTP headers to the request. +func (c *ProjectsLocationsCollectionsDataStoresSiteSearchEngineRecrawlUrisCall) Header() http.Header { + if c.header_ == nil { + c.header_ = make(http.Header) + } + return c.header_ +} + +func (c *ProjectsLocationsCollectionsDataStoresSiteSearchEngineRecrawlUrisCall) doRequest(alt string) (*http.Response, error) { + reqHeaders := make(http.Header) + reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version) + for k, v := range c.header_ { + reqHeaders[k] = v + } + reqHeaders.Set("User-Agent", c.s.userAgent()) + var body io.Reader = nil + body, err := googleapi.WithoutDataWrapper.JSONReader(c.googleclouddiscoveryenginev1alpharecrawlurisrequest) + if err != nil { + return nil, err + } + reqHeaders.Set("Content-Type", "application/json") + c.urlParams_.Set("alt", alt) + c.urlParams_.Set("prettyPrint", "false") + urls := googleapi.ResolveRelative(c.s.BasePath, "v1alpha/{+siteSearchEngine}:recrawlUris") + urls += "?" + c.urlParams_.Encode() + req, err := http.NewRequest("POST", urls, body) + if err != nil { + return nil, err + } + req.Header = reqHeaders + googleapi.Expand(req.URL, map[string]string{ + "siteSearchEngine": c.siteSearchEngine, + }) + return gensupport.SendRequest(c.ctx_, c.s.client, req) +} + +// Do executes the "discoveryengine.projects.locations.collections.dataStores.siteSearchEngine.recrawlUris" call. +// Exactly one of *GoogleLongrunningOperation or error will be non-nil. +// Any non-2xx status code is an error. Response headers are in either +// *GoogleLongrunningOperation.ServerResponse.Header or (if a response +// was returned at all) in error.(*googleapi.Error).Header. Use +// googleapi.IsNotModified to check whether the returned error was +// because http.StatusNotModified was returned. +func (c *ProjectsLocationsCollectionsDataStoresSiteSearchEngineRecrawlUrisCall) Do(opts ...googleapi.CallOption) (*GoogleLongrunningOperation, error) { + gensupport.SetOptions(c.urlParams_, opts...) + res, err := c.doRequest("json") + if res != nil && res.StatusCode == http.StatusNotModified { + if res.Body != nil { + res.Body.Close() + } + return nil, gensupport.WrapError(&googleapi.Error{ + Code: res.StatusCode, + Header: res.Header, + }) + } + if err != nil { + return nil, err + } + defer googleapi.CloseBody(res) + if err := googleapi.CheckResponse(res); err != nil { + return nil, gensupport.WrapError(err) + } + ret := &GoogleLongrunningOperation{ + ServerResponse: googleapi.ServerResponse{ + Header: res.Header, + HTTPStatusCode: res.StatusCode, + }, + } + target := &ret + if err := gensupport.DecodeResponse(target, res); err != nil { + return nil, err + } + return ret, nil + // { + // "description": "Request on-demand recrawl for a list of URIs.", + // "flatPath": "v1alpha/projects/{projectsId}/locations/{locationsId}/collections/{collectionsId}/dataStores/{dataStoresId}/siteSearchEngine:recrawlUris", + // "httpMethod": "POST", + // "id": "discoveryengine.projects.locations.collections.dataStores.siteSearchEngine.recrawlUris", + // "parameterOrder": [ + // "siteSearchEngine" + // ], + // "parameters": { + // "siteSearchEngine": { + // "description": "Required. Full resource name of the SiteSearchEngine, such as `projects/*/locations/*/collections/*/dataStores/*/siteSearchEngine`.", + // "location": "path", + // "pattern": "^projects/[^/]+/locations/[^/]+/collections/[^/]+/dataStores/[^/]+/siteSearchEngine$", + // "required": true, + // "type": "string" + // } + // }, + // "path": "v1alpha/{+siteSearchEngine}:recrawlUris", + // "request": { + // "$ref": "GoogleCloudDiscoveryengineV1alphaRecrawlUrisRequest" + // }, + // "response": { + // "$ref": "GoogleLongrunningOperation" + // }, + // "scopes": [ + // "https://www.googleapis.com/auth/cloud-platform" + // ] + // } + +} + // method id "discoveryengine.projects.locations.collections.dataStores.siteSearchEngine.operations.get": type ProjectsLocationsCollectionsDataStoresSiteSearchEngineOperationsGetCall struct { @@ -14119,8 +14467,7 @@ func (c *ProjectsLocationsDataStoresCompleteQueryCall) Query(query string) *Proj // `document-completable` - Using suggestions taken directly from // user-imported document fields marked as completable. Default values: // * `document` is the default model for regular dataStores. * -// `search-history` is the default model for -// IndustryVertical.SITE_SEARCH dataStores. +// `search-history` is the default model for site search dataStores. func (c *ProjectsLocationsDataStoresCompleteQueryCall) QueryModel(queryModel string) *ProjectsLocationsDataStoresCompleteQueryCall { c.urlParams_.Set("queryModel", queryModel) return c @@ -14269,7 +14616,7 @@ func (c *ProjectsLocationsDataStoresCompleteQueryCall) Do(opts ...googleapi.Call // "type": "string" // }, // "queryModel": { - // "description": "Selects data model of query suggestions for serving. Currently supported values: * `document` - Using suggestions generated from user-imported documents. * `search-history` - Using suggestions generated from the past history of SearchService.Search API calls. Do not use it when there is no traffic for Search API. * `user-event` - Using suggestions generated from user-imported search events. * `document-completable` - Using suggestions taken directly from user-imported document fields marked as completable. Default values: * `document` is the default model for regular dataStores. * `search-history` is the default model for IndustryVertical.SITE_SEARCH dataStores.", + // "description": "Selects data model of query suggestions for serving. Currently supported values: * `document` - Using suggestions generated from user-imported documents. * `search-history` - Using suggestions generated from the past history of SearchService.Search API calls. Do not use it when there is no traffic for Search API. * `user-event` - Using suggestions generated from user-imported search events. * `document-completable` - Using suggestions taken directly from user-imported document fields marked as completable. Default values: * `document` is the default model for regular dataStores. * `search-history` is the default model for site search dataStores.", // "location": "query", // "type": "string" // }, @@ -18573,6 +18920,151 @@ func (c *ProjectsLocationsDataStoresServingConfigsSearchCall) Pages(ctx context. } } +// method id "discoveryengine.projects.locations.dataStores.siteSearchEngine.recrawlUris": + +type ProjectsLocationsDataStoresSiteSearchEngineRecrawlUrisCall struct { + s *Service + siteSearchEngine string + googleclouddiscoveryenginev1alpharecrawlurisrequest *GoogleCloudDiscoveryengineV1alphaRecrawlUrisRequest + urlParams_ gensupport.URLParams + ctx_ context.Context + header_ http.Header +} + +// RecrawlUris: Request on-demand recrawl for a list of URIs. +// +// - siteSearchEngine: Full resource name of the SiteSearchEngine, such +// as +// `projects/*/locations/*/collections/*/dataStores/*/siteSearchEngine` +// . +func (r *ProjectsLocationsDataStoresSiteSearchEngineService) RecrawlUris(siteSearchEngine string, googleclouddiscoveryenginev1alpharecrawlurisrequest *GoogleCloudDiscoveryengineV1alphaRecrawlUrisRequest) *ProjectsLocationsDataStoresSiteSearchEngineRecrawlUrisCall { + c := &ProjectsLocationsDataStoresSiteSearchEngineRecrawlUrisCall{s: r.s, urlParams_: make(gensupport.URLParams)} + c.siteSearchEngine = siteSearchEngine + c.googleclouddiscoveryenginev1alpharecrawlurisrequest = googleclouddiscoveryenginev1alpharecrawlurisrequest + return c +} + +// Fields allows partial responses to be retrieved. See +// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse +// for more information. +func (c *ProjectsLocationsDataStoresSiteSearchEngineRecrawlUrisCall) Fields(s ...googleapi.Field) *ProjectsLocationsDataStoresSiteSearchEngineRecrawlUrisCall { + c.urlParams_.Set("fields", googleapi.CombineFields(s)) + return c +} + +// Context sets the context to be used in this call's Do method. Any +// pending HTTP request will be aborted if the provided context is +// canceled. +func (c *ProjectsLocationsDataStoresSiteSearchEngineRecrawlUrisCall) Context(ctx context.Context) *ProjectsLocationsDataStoresSiteSearchEngineRecrawlUrisCall { + c.ctx_ = ctx + return c +} + +// Header returns an http.Header that can be modified by the caller to +// add HTTP headers to the request. +func (c *ProjectsLocationsDataStoresSiteSearchEngineRecrawlUrisCall) Header() http.Header { + if c.header_ == nil { + c.header_ = make(http.Header) + } + return c.header_ +} + +func (c *ProjectsLocationsDataStoresSiteSearchEngineRecrawlUrisCall) doRequest(alt string) (*http.Response, error) { + reqHeaders := make(http.Header) + reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version) + for k, v := range c.header_ { + reqHeaders[k] = v + } + reqHeaders.Set("User-Agent", c.s.userAgent()) + var body io.Reader = nil + body, err := googleapi.WithoutDataWrapper.JSONReader(c.googleclouddiscoveryenginev1alpharecrawlurisrequest) + if err != nil { + return nil, err + } + reqHeaders.Set("Content-Type", "application/json") + c.urlParams_.Set("alt", alt) + c.urlParams_.Set("prettyPrint", "false") + urls := googleapi.ResolveRelative(c.s.BasePath, "v1alpha/{+siteSearchEngine}:recrawlUris") + urls += "?" + c.urlParams_.Encode() + req, err := http.NewRequest("POST", urls, body) + if err != nil { + return nil, err + } + req.Header = reqHeaders + googleapi.Expand(req.URL, map[string]string{ + "siteSearchEngine": c.siteSearchEngine, + }) + return gensupport.SendRequest(c.ctx_, c.s.client, req) +} + +// Do executes the "discoveryengine.projects.locations.dataStores.siteSearchEngine.recrawlUris" call. +// Exactly one of *GoogleLongrunningOperation or error will be non-nil. +// Any non-2xx status code is an error. Response headers are in either +// *GoogleLongrunningOperation.ServerResponse.Header or (if a response +// was returned at all) in error.(*googleapi.Error).Header. Use +// googleapi.IsNotModified to check whether the returned error was +// because http.StatusNotModified was returned. +func (c *ProjectsLocationsDataStoresSiteSearchEngineRecrawlUrisCall) Do(opts ...googleapi.CallOption) (*GoogleLongrunningOperation, error) { + gensupport.SetOptions(c.urlParams_, opts...) + res, err := c.doRequest("json") + if res != nil && res.StatusCode == http.StatusNotModified { + if res.Body != nil { + res.Body.Close() + } + return nil, gensupport.WrapError(&googleapi.Error{ + Code: res.StatusCode, + Header: res.Header, + }) + } + if err != nil { + return nil, err + } + defer googleapi.CloseBody(res) + if err := googleapi.CheckResponse(res); err != nil { + return nil, gensupport.WrapError(err) + } + ret := &GoogleLongrunningOperation{ + ServerResponse: googleapi.ServerResponse{ + Header: res.Header, + HTTPStatusCode: res.StatusCode, + }, + } + target := &ret + if err := gensupport.DecodeResponse(target, res); err != nil { + return nil, err + } + return ret, nil + // { + // "description": "Request on-demand recrawl for a list of URIs.", + // "flatPath": "v1alpha/projects/{projectsId}/locations/{locationsId}/dataStores/{dataStoresId}/siteSearchEngine:recrawlUris", + // "httpMethod": "POST", + // "id": "discoveryengine.projects.locations.dataStores.siteSearchEngine.recrawlUris", + // "parameterOrder": [ + // "siteSearchEngine" + // ], + // "parameters": { + // "siteSearchEngine": { + // "description": "Required. Full resource name of the SiteSearchEngine, such as `projects/*/locations/*/collections/*/dataStores/*/siteSearchEngine`.", + // "location": "path", + // "pattern": "^projects/[^/]+/locations/[^/]+/dataStores/[^/]+/siteSearchEngine$", + // "required": true, + // "type": "string" + // } + // }, + // "path": "v1alpha/{+siteSearchEngine}:recrawlUris", + // "request": { + // "$ref": "GoogleCloudDiscoveryengineV1alphaRecrawlUrisRequest" + // }, + // "response": { + // "$ref": "GoogleLongrunningOperation" + // }, + // "scopes": [ + // "https://www.googleapis.com/auth/cloud-platform" + // ] + // } + +} + // method id "discoveryengine.projects.locations.dataStores.userEvents.collect": type ProjectsLocationsDataStoresUserEventsCollectCall struct { diff --git a/discoveryengine/v1beta/discoveryengine-api.json b/discoveryengine/v1beta/discoveryengine-api.json index 348f8ba3e2b..fcde93b24af 100644 --- a/discoveryengine/v1beta/discoveryengine-api.json +++ b/discoveryengine/v1beta/discoveryengine-api.json @@ -140,7 +140,7 @@ "type": "string" }, "queryModel": { - "description": "Selects data model of query suggestions for serving. Currently supported values: * `document` - Using suggestions generated from user-imported documents. * `search-history` - Using suggestions generated from the past history of SearchService.Search API calls. Do not use it when there is no traffic for Search API. * `user-event` - Using suggestions generated from user-imported search events. * `document-completable` - Using suggestions taken directly from user-imported document fields marked as completable. Default values: * `document` is the default model for regular dataStores. * `search-history` is the default model for IndustryVertical.SITE_SEARCH dataStores.", + "description": "Selects data model of query suggestions for serving. Currently supported values: * `document` - Using suggestions generated from user-imported documents. * `search-history` - Using suggestions generated from the past history of SearchService.Search API calls. Do not use it when there is no traffic for Search API. * `user-event` - Using suggestions generated from user-imported search events. * `document-completable` - Using suggestions taken directly from user-imported document fields marked as completable. Default values: * `document` is the default model for regular dataStores. * `search-history` is the default model for site search dataStores.", "location": "query", "type": "string" }, @@ -1494,7 +1494,7 @@ "type": "string" }, "queryModel": { - "description": "Selects data model of query suggestions for serving. Currently supported values: * `document` - Using suggestions generated from user-imported documents. * `search-history` - Using suggestions generated from the past history of SearchService.Search API calls. Do not use it when there is no traffic for Search API. * `user-event` - Using suggestions generated from user-imported search events. * `document-completable` - Using suggestions taken directly from user-imported document fields marked as completable. Default values: * `document` is the default model for regular dataStores. * `search-history` is the default model for IndustryVertical.SITE_SEARCH dataStores.", + "description": "Selects data model of query suggestions for serving. Currently supported values: * `document` - Using suggestions generated from user-imported documents. * `search-history` - Using suggestions generated from the past history of SearchService.Search API calls. Do not use it when there is no traffic for Search API. * `user-event` - Using suggestions generated from user-imported search events. * `document-completable` - Using suggestions taken directly from user-imported document fields marked as completable. Default values: * `document` is the default model for regular dataStores. * `search-history` is the default model for site search dataStores.", "location": "query", "type": "string" }, @@ -2598,7 +2598,7 @@ } } }, - "revision": "20230914", + "revision": "20230925", "rootUrl": "https://discoveryengine.googleapis.com/", "schemas": { "GoogleApiHttpBody": { @@ -3343,6 +3343,114 @@ }, "type": "object" }, + "GoogleCloudDiscoveryengineV1alphaRecrawlUrisMetadata": { + "description": "Metadata related to the progress of the SiteSearchEngineService.RecrawlUris operation. This will be returned by the google.longrunning.Operation.metadata field.", + "id": "GoogleCloudDiscoveryengineV1alphaRecrawlUrisMetadata", + "properties": { + "createTime": { + "description": "Operation create time.", + "format": "google-datetime", + "type": "string" + }, + "invalidUris": { + "description": "Unique URIs in the request that don't match any TargetSite in the DataStore, only match TargetSites that haven't been fully indexed, or match a TargetSite with type EXCLUDE.", + "items": { + "type": "string" + }, + "type": "array" + }, + "pendingCount": { + "description": "Total number of URIs that have yet to be crawled.", + "format": "int32", + "type": "integer" + }, + "quotaExceededCount": { + "description": "Total number of URIs that were rejected due to insufficient indexing resources.", + "format": "int32", + "type": "integer" + }, + "successCount": { + "description": "Total number of URIs that have been crawled so far.", + "format": "int32", + "type": "integer" + }, + "updateTime": { + "description": "Operation last update time. If the operation is done, this is also the finish time.", + "format": "google-datetime", + "type": "string" + }, + "validUrisCount": { + "description": "Total number of unique URIs in the request that are not in invalid_uris.", + "format": "int32", + "type": "integer" + } + }, + "type": "object" + }, + "GoogleCloudDiscoveryengineV1alphaRecrawlUrisResponse": { + "description": "Response message for SiteSearchEngineService.RecrawlUris method.", + "id": "GoogleCloudDiscoveryengineV1alphaRecrawlUrisResponse", + "properties": { + "failedUris": { + "description": "URIs that were not crawled before the LRO terminated.", + "items": { + "type": "string" + }, + "type": "array" + }, + "failureSamples": { + "description": "Details for a sample of up to 10 `failed_uris`.", + "items": { + "$ref": "GoogleCloudDiscoveryengineV1alphaRecrawlUrisResponseFailureInfo" + }, + "type": "array" + } + }, + "type": "object" + }, + "GoogleCloudDiscoveryengineV1alphaRecrawlUrisResponseFailureInfo": { + "description": "Details about why a particular URI failed to be crawled. Each FailureInfo contains one FailureReason per CorpusType.", + "id": "GoogleCloudDiscoveryengineV1alphaRecrawlUrisResponseFailureInfo", + "properties": { + "failureReasons": { + "description": "List of failure reasons by corpus type (e.g. desktop, mobile).", + "items": { + "$ref": "GoogleCloudDiscoveryengineV1alphaRecrawlUrisResponseFailureInfoFailureReason" + }, + "type": "array" + }, + "uri": { + "description": "URI that failed to be crawled.", + "type": "string" + } + }, + "type": "object" + }, + "GoogleCloudDiscoveryengineV1alphaRecrawlUrisResponseFailureInfoFailureReason": { + "description": "Details about why crawling failed for a particular CorpusType, e.g. DESKTOP and MOBILE crawling may fail for different reasons.", + "id": "GoogleCloudDiscoveryengineV1alphaRecrawlUrisResponseFailureInfoFailureReason", + "properties": { + "corpusType": { + "description": "DESKTOP, MOBILE, or CORPUS_TYPE_UNSPECIFIED.", + "enum": [ + "CORPUS_TYPE_UNSPECIFIED", + "DESKTOP", + "MOBILE" + ], + "enumDescriptions": [ + "Default value.", + "Denotes a crawling attempt for the desktop version of a page.", + "Denotes a crawling attempt for the mobile version of a page." + ], + "type": "string" + }, + "errorMessage": { + "description": "Reason why the URI was not crawled.", + "type": "string" + } + }, + "type": "object" + }, "GoogleCloudDiscoveryengineV1alphaSchema": { "description": "Defines the structure and layout of a type of document data.", "id": "GoogleCloudDiscoveryengineV1alphaSchema", diff --git a/discoveryengine/v1beta/discoveryengine-gen.go b/discoveryengine/v1beta/discoveryengine-gen.go index 863f59033f3..8c6107f3cf2 100644 --- a/discoveryengine/v1beta/discoveryengine-gen.go +++ b/discoveryengine/v1beta/discoveryengine-gen.go @@ -1885,6 +1885,168 @@ func (s *GoogleCloudDiscoveryengineV1alphaPurgeUserEventsResponse) MarshalJSON() return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } +// GoogleCloudDiscoveryengineV1alphaRecrawlUrisMetadata: Metadata +// related to the progress of the SiteSearchEngineService.RecrawlUris +// operation. This will be returned by the +// google.longrunning.Operation.metadata field. +type GoogleCloudDiscoveryengineV1alphaRecrawlUrisMetadata struct { + // CreateTime: Operation create time. + CreateTime string `json:"createTime,omitempty"` + + // InvalidUris: Unique URIs in the request that don't match any + // TargetSite in the DataStore, only match TargetSites that haven't been + // fully indexed, or match a TargetSite with type EXCLUDE. + InvalidUris []string `json:"invalidUris,omitempty"` + + // PendingCount: Total number of URIs that have yet to be crawled. + PendingCount int64 `json:"pendingCount,omitempty"` + + // QuotaExceededCount: Total number of URIs that were rejected due to + // insufficient indexing resources. + QuotaExceededCount int64 `json:"quotaExceededCount,omitempty"` + + // SuccessCount: Total number of URIs that have been crawled so far. + SuccessCount int64 `json:"successCount,omitempty"` + + // UpdateTime: Operation last update time. If the operation is done, + // this is also the finish time. + UpdateTime string `json:"updateTime,omitempty"` + + // ValidUrisCount: Total number of unique URIs in the request that are + // not in invalid_uris. + ValidUrisCount int64 `json:"validUrisCount,omitempty"` + + // ForceSendFields is a list of field names (e.g. "CreateTime") to + // unconditionally include in API requests. By default, fields with + // empty or default values are omitted from API requests. However, any + // non-pointer, non-interface field appearing in ForceSendFields will be + // sent to the server regardless of whether the field is empty or not. + // This may be used to include empty fields in Patch requests. + ForceSendFields []string `json:"-"` + + // NullFields is a list of field names (e.g. "CreateTime") to include in + // API requests with the JSON null value. By default, fields with empty + // values are omitted from API requests. However, any field with an + // empty value appearing in NullFields will be sent to the server as + // null. It is an error if a field in this list has a non-empty value. + // This may be used to include null fields in Patch requests. + NullFields []string `json:"-"` +} + +func (s *GoogleCloudDiscoveryengineV1alphaRecrawlUrisMetadata) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaRecrawlUrisMetadata + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + +// GoogleCloudDiscoveryengineV1alphaRecrawlUrisResponse: Response +// message for SiteSearchEngineService.RecrawlUris method. +type GoogleCloudDiscoveryengineV1alphaRecrawlUrisResponse struct { + // FailedUris: URIs that were not crawled before the LRO terminated. + FailedUris []string `json:"failedUris,omitempty"` + + // FailureSamples: Details for a sample of up to 10 `failed_uris`. + FailureSamples []*GoogleCloudDiscoveryengineV1alphaRecrawlUrisResponseFailureInfo `json:"failureSamples,omitempty"` + + // ForceSendFields is a list of field names (e.g. "FailedUris") to + // unconditionally include in API requests. By default, fields with + // empty or default values are omitted from API requests. However, any + // non-pointer, non-interface field appearing in ForceSendFields will be + // sent to the server regardless of whether the field is empty or not. + // This may be used to include empty fields in Patch requests. + ForceSendFields []string `json:"-"` + + // NullFields is a list of field names (e.g. "FailedUris") to include in + // API requests with the JSON null value. By default, fields with empty + // values are omitted from API requests. However, any field with an + // empty value appearing in NullFields will be sent to the server as + // null. It is an error if a field in this list has a non-empty value. + // This may be used to include null fields in Patch requests. + NullFields []string `json:"-"` +} + +func (s *GoogleCloudDiscoveryengineV1alphaRecrawlUrisResponse) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaRecrawlUrisResponse + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + +// GoogleCloudDiscoveryengineV1alphaRecrawlUrisResponseFailureInfo: +// Details about why a particular URI failed to be crawled. Each +// FailureInfo contains one FailureReason per CorpusType. +type GoogleCloudDiscoveryengineV1alphaRecrawlUrisResponseFailureInfo struct { + // FailureReasons: List of failure reasons by corpus type (e.g. desktop, + // mobile). + FailureReasons []*GoogleCloudDiscoveryengineV1alphaRecrawlUrisResponseFailureInfoFailureReason `json:"failureReasons,omitempty"` + + // Uri: URI that failed to be crawled. + Uri string `json:"uri,omitempty"` + + // ForceSendFields is a list of field names (e.g. "FailureReasons") to + // unconditionally include in API requests. By default, fields with + // empty or default values are omitted from API requests. However, any + // non-pointer, non-interface field appearing in ForceSendFields will be + // sent to the server regardless of whether the field is empty or not. + // This may be used to include empty fields in Patch requests. + ForceSendFields []string `json:"-"` + + // NullFields is a list of field names (e.g. "FailureReasons") to + // include in API requests with the JSON null value. By default, fields + // with empty values are omitted from API requests. However, any field + // with an empty value appearing in NullFields will be sent to the + // server as null. It is an error if a field in this list has a + // non-empty value. This may be used to include null fields in Patch + // requests. + NullFields []string `json:"-"` +} + +func (s *GoogleCloudDiscoveryengineV1alphaRecrawlUrisResponseFailureInfo) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaRecrawlUrisResponseFailureInfo + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + +// GoogleCloudDiscoveryengineV1alphaRecrawlUrisResponseFailureInfoFailure +// Reason: Details about why crawling failed for a particular +// CorpusType, e.g. DESKTOP and MOBILE crawling may fail for different +// reasons. +type GoogleCloudDiscoveryengineV1alphaRecrawlUrisResponseFailureInfoFailureReason struct { + // CorpusType: DESKTOP, MOBILE, or CORPUS_TYPE_UNSPECIFIED. + // + // Possible values: + // "CORPUS_TYPE_UNSPECIFIED" - Default value. + // "DESKTOP" - Denotes a crawling attempt for the desktop version of a + // page. + // "MOBILE" - Denotes a crawling attempt for the mobile version of a + // page. + CorpusType string `json:"corpusType,omitempty"` + + // ErrorMessage: Reason why the URI was not crawled. + ErrorMessage string `json:"errorMessage,omitempty"` + + // ForceSendFields is a list of field names (e.g. "CorpusType") to + // unconditionally include in API requests. By default, fields with + // empty or default values are omitted from API requests. However, any + // non-pointer, non-interface field appearing in ForceSendFields will be + // sent to the server regardless of whether the field is empty or not. + // This may be used to include empty fields in Patch requests. + ForceSendFields []string `json:"-"` + + // NullFields is a list of field names (e.g. "CorpusType") to include in + // API requests with the JSON null value. By default, fields with empty + // values are omitted from API requests. However, any field with an + // empty value appearing in NullFields will be sent to the server as + // null. It is an error if a field in this list has a non-empty value. + // This may be used to include null fields in Patch requests. + NullFields []string `json:"-"` +} + +func (s *GoogleCloudDiscoveryengineV1alphaRecrawlUrisResponseFailureInfoFailureReason) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaRecrawlUrisResponseFailureInfoFailureReason + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + // GoogleCloudDiscoveryengineV1alphaSchema: Defines the structure and // layout of a type of document data. type GoogleCloudDiscoveryengineV1alphaSchema struct { @@ -5903,8 +6065,7 @@ func (c *ProjectsLocationsCollectionsDataStoresCompleteQueryCall) Query(query st // `document-completable` - Using suggestions taken directly from // user-imported document fields marked as completable. Default values: // * `document` is the default model for regular dataStores. * -// `search-history` is the default model for -// IndustryVertical.SITE_SEARCH dataStores. +// `search-history` is the default model for site search dataStores. func (c *ProjectsLocationsCollectionsDataStoresCompleteQueryCall) QueryModel(queryModel string) *ProjectsLocationsCollectionsDataStoresCompleteQueryCall { c.urlParams_.Set("queryModel", queryModel) return c @@ -6052,7 +6213,7 @@ func (c *ProjectsLocationsCollectionsDataStoresCompleteQueryCall) Do(opts ...goo // "type": "string" // }, // "queryModel": { - // "description": "Selects data model of query suggestions for serving. Currently supported values: * `document` - Using suggestions generated from user-imported documents. * `search-history` - Using suggestions generated from the past history of SearchService.Search API calls. Do not use it when there is no traffic for Search API. * `user-event` - Using suggestions generated from user-imported search events. * `document-completable` - Using suggestions taken directly from user-imported document fields marked as completable. Default values: * `document` is the default model for regular dataStores. * `search-history` is the default model for IndustryVertical.SITE_SEARCH dataStores.", + // "description": "Selects data model of query suggestions for serving. Currently supported values: * `document` - Using suggestions generated from user-imported documents. * `search-history` - Using suggestions generated from the past history of SearchService.Search API calls. Do not use it when there is no traffic for Search API. * `user-event` - Using suggestions generated from user-imported search events. * `document-completable` - Using suggestions taken directly from user-imported document fields marked as completable. Default values: * `document` is the default model for regular dataStores. * `search-history` is the default model for site search dataStores.", // "location": "query", // "type": "string" // }, @@ -12666,8 +12827,7 @@ func (c *ProjectsLocationsDataStoresCompleteQueryCall) Query(query string) *Proj // `document-completable` - Using suggestions taken directly from // user-imported document fields marked as completable. Default values: // * `document` is the default model for regular dataStores. * -// `search-history` is the default model for -// IndustryVertical.SITE_SEARCH dataStores. +// `search-history` is the default model for site search dataStores. func (c *ProjectsLocationsDataStoresCompleteQueryCall) QueryModel(queryModel string) *ProjectsLocationsDataStoresCompleteQueryCall { c.urlParams_.Set("queryModel", queryModel) return c @@ -12815,7 +12975,7 @@ func (c *ProjectsLocationsDataStoresCompleteQueryCall) Do(opts ...googleapi.Call // "type": "string" // }, // "queryModel": { - // "description": "Selects data model of query suggestions for serving. Currently supported values: * `document` - Using suggestions generated from user-imported documents. * `search-history` - Using suggestions generated from the past history of SearchService.Search API calls. Do not use it when there is no traffic for Search API. * `user-event` - Using suggestions generated from user-imported search events. * `document-completable` - Using suggestions taken directly from user-imported document fields marked as completable. Default values: * `document` is the default model for regular dataStores. * `search-history` is the default model for IndustryVertical.SITE_SEARCH dataStores.", + // "description": "Selects data model of query suggestions for serving. Currently supported values: * `document` - Using suggestions generated from user-imported documents. * `search-history` - Using suggestions generated from the past history of SearchService.Search API calls. Do not use it when there is no traffic for Search API. * `user-event` - Using suggestions generated from user-imported search events. * `document-completable` - Using suggestions taken directly from user-imported document fields marked as completable. Default values: * `document` is the default model for regular dataStores. * `search-history` is the default model for site search dataStores.", // "location": "query", // "type": "string" // }, diff --git a/documentai/v1/documentai-api.json b/documentai/v1/documentai-api.json index fbd8f1672ce..bc930acf32a 100644 --- a/documentai/v1/documentai-api.json +++ b/documentai/v1/documentai-api.json @@ -1042,7 +1042,7 @@ } } }, - "revision": "20230914", + "revision": "20230923", "rootUrl": "https://documentai.googleapis.com/", "schemas": { "GoogleCloudDocumentaiUiv1beta3AutoLabelDocumentsMetadata": { @@ -4034,7 +4034,7 @@ "type": "boolean" }, "disableCharacterBoxesDetection": { - "description": "Turn off character box detector in OCR engine. Character box detection is enabled by default in OCR 2.0+ processors.", + "description": "Turn off character box detector in OCR engine. Character box detection is enabled by default in OCR 2.0 (and later) processors.", "type": "boolean" }, "enableImageQualityScores": { @@ -4087,7 +4087,7 @@ "type": "boolean" }, "enableSelectionMarkDetection": { - "description": "Turn on selection mark detector in OCR engine. Only available in OCR 2.0+ processors.", + "description": "Turn on selection mark detector in OCR engine. Only available in OCR 2.0 (and later) processors.", "type": "boolean" } }, @@ -4103,7 +4103,7 @@ "type": "integer" }, "fromStart": { - "description": "Only process certain pages from the start, process all if the document has less pages.", + "description": "Only process certain pages from the start. Process all if the document has fewer pages.", "format": "int32", "type": "integer" }, @@ -7670,7 +7670,7 @@ "type": "object" }, "GoogleCloudDocumentaiV1beta3Dataset": { - "description": "A singleton resource under a Processor which configures a collection of documents. Next Id: 8.", + "description": "A singleton resource under a Processor which configures a collection of documents.", "id": "GoogleCloudDocumentaiV1beta3Dataset", "properties": { "documentWarehouseConfig": { diff --git a/documentai/v1/documentai-gen.go b/documentai/v1/documentai-gen.go index 64819a78787..acb33422ec5 100644 --- a/documentai/v1/documentai-gen.go +++ b/documentai/v1/documentai-gen.go @@ -5379,8 +5379,8 @@ type GoogleCloudDocumentaiV1OcrConfig struct { ComputeStyleInfo bool `json:"computeStyleInfo,omitempty"` // DisableCharacterBoxesDetection: Turn off character box detector in - // OCR engine. Character box detection is enabled by default in OCR 2.0+ - // processors. + // OCR engine. Character box detection is enabled by default in OCR 2.0 + // (and later) processors. DisableCharacterBoxesDetection bool `json:"disableCharacterBoxesDetection,omitempty"` // EnableImageQualityScores: Enables intelligent document quality scores @@ -5473,7 +5473,7 @@ type GoogleCloudDocumentaiV1OcrConfigPremiumFeatures struct { EnableMathOcr bool `json:"enableMathOcr,omitempty"` // EnableSelectionMarkDetection: Turn on selection mark detector in OCR - // engine. Only available in OCR 2.0+ processors. + // engine. Only available in OCR 2.0 (and later) processors. EnableSelectionMarkDetection bool `json:"enableSelectionMarkDetection,omitempty"` // ForceSendFields is a list of field names (e.g. "ComputeStyleInfo") to @@ -5505,8 +5505,8 @@ type GoogleCloudDocumentaiV1ProcessOptions struct { // FromEnd: Only process certain pages from the end, same as above. FromEnd int64 `json:"fromEnd,omitempty"` - // FromStart: Only process certain pages from the start, process all if - // the document has less pages. + // FromStart: Only process certain pages from the start. Process all if + // the document has fewer pages. FromStart int64 `json:"fromStart,omitempty"` // IndividualPageSelector: Which pages to process (1-indexed). @@ -11279,7 +11279,7 @@ func (s *GoogleCloudDocumentaiV1beta3CommonOperationMetadata) MarshalJSON() ([]b } // GoogleCloudDocumentaiV1beta3Dataset: A singleton resource under a -// Processor which configures a collection of documents. Next Id: 8. +// Processor which configures a collection of documents. type GoogleCloudDocumentaiV1beta3Dataset struct { // DocumentWarehouseConfig: Optional. Document AI Warehouse-based // dataset configuration. diff --git a/documentai/v1beta2/documentai-api.json b/documentai/v1beta2/documentai-api.json index 792021eb00d..dba399c1763 100644 --- a/documentai/v1beta2/documentai-api.json +++ b/documentai/v1beta2/documentai-api.json @@ -292,7 +292,7 @@ } } }, - "revision": "20230914", + "revision": "20230923", "rootUrl": "https://documentai.googleapis.com/", "schemas": { "GoogleCloudDocumentaiUiv1beta3AutoLabelDocumentsMetadata": { @@ -4722,7 +4722,7 @@ "type": "object" }, "GoogleCloudDocumentaiV1beta3Dataset": { - "description": "A singleton resource under a Processor which configures a collection of documents. Next Id: 8.", + "description": "A singleton resource under a Processor which configures a collection of documents.", "id": "GoogleCloudDocumentaiV1beta3Dataset", "properties": { "documentWarehouseConfig": { diff --git a/documentai/v1beta2/documentai-gen.go b/documentai/v1beta2/documentai-gen.go index 1c943364129..51d3a95fbe3 100644 --- a/documentai/v1beta2/documentai-gen.go +++ b/documentai/v1beta2/documentai-gen.go @@ -7661,7 +7661,7 @@ func (s *GoogleCloudDocumentaiV1beta3CommonOperationMetadata) MarshalJSON() ([]b } // GoogleCloudDocumentaiV1beta3Dataset: A singleton resource under a -// Processor which configures a collection of documents. Next Id: 8. +// Processor which configures a collection of documents. type GoogleCloudDocumentaiV1beta3Dataset struct { // DocumentWarehouseConfig: Optional. Document AI Warehouse-based // dataset configuration. diff --git a/documentai/v1beta3/documentai-api.json b/documentai/v1beta3/documentai-api.json index d58f099ce19..e7b8d4601a3 100644 --- a/documentai/v1beta3/documentai-api.json +++ b/documentai/v1beta3/documentai-api.json @@ -828,6 +828,34 @@ "https://www.googleapis.com/auth/cloud-platform" ] }, + "listDocuments": { + "description": "Returns a list of documents present in the dataset.", + "flatPath": "v1beta3/projects/{projectsId}/locations/{locationsId}/processors/{processorsId}/dataset:listDocuments", + "httpMethod": "POST", + "id": "documentai.projects.locations.processors.dataset.listDocuments", + "parameterOrder": [ + "dataset" + ], + "parameters": { + "dataset": { + "description": "Required. The resource name of the dataset to be listed. Format: projects/{project}/locations/{location}/processors/{processor}/dataset", + "location": "path", + "pattern": "^projects/[^/]+/locations/[^/]+/processors/[^/]+/dataset$", + "required": true, + "type": "string" + } + }, + "path": "v1beta3/{+dataset}:listDocuments", + "request": { + "$ref": "GoogleCloudDocumentaiV1beta3ListDocumentsRequest" + }, + "response": { + "$ref": "GoogleCloudDocumentaiV1beta3ListDocumentsResponse" + }, + "scopes": [ + "https://www.googleapis.com/auth/cloud-platform" + ] + }, "updateDatasetSchema": { "description": "Updates a `DatasetSchema`.", "flatPath": "v1beta3/projects/{projectsId}/locations/{locationsId}/processors/{processorsId}/dataset/datasetSchema", @@ -1256,7 +1284,7 @@ } } }, - "revision": "20230914", + "revision": "20230923", "rootUrl": "https://documentai.googleapis.com/", "schemas": { "GoogleCloudDocumentaiUiv1beta3AutoLabelDocumentsMetadata": { @@ -5662,7 +5690,7 @@ "type": "object" }, "GoogleCloudDocumentaiV1beta3Dataset": { - "description": "A singleton resource under a Processor which configures a collection of documents. Next Id: 8.", + "description": "A singleton resource under a Processor which configures a collection of documents.", "id": "GoogleCloudDocumentaiV1beta3Dataset", "properties": { "documentWarehouseConfig": { @@ -6063,6 +6091,58 @@ }, "type": "object" }, + "GoogleCloudDocumentaiV1beta3DocumentMetadata": { + "description": "Metadata about a document.", + "id": "GoogleCloudDocumentaiV1beta3DocumentMetadata", + "properties": { + "datasetType": { + "description": "Type of the dataset split to which the document belongs.", + "enum": [ + "DATASET_SPLIT_TYPE_UNSPECIFIED", + "DATASET_SPLIT_TRAIN", + "DATASET_SPLIT_TEST", + "DATASET_SPLIT_UNASSIGNED" + ], + "enumDescriptions": [ + "Default value if the enum is not set.", + "Identifies the train documents.", + "Identifies the test documents.", + "Identifies the unassigned documents." + ], + "type": "string" + }, + "displayName": { + "description": "The display name of the document.", + "type": "string" + }, + "documentId": { + "$ref": "GoogleCloudDocumentaiV1beta3DocumentId", + "description": "Document identifier." + }, + "labelingState": { + "description": "Labelling state of the document.", + "enum": [ + "DOCUMENT_LABELING_STATE_UNSPECIFIED", + "DOCUMENT_LABELED", + "DOCUMENT_UNLABELED", + "DOCUMENT_AUTO_LABELED" + ], + "enumDescriptions": [ + "Default value if the enum is not set.", + "Document has been labelled.", + "Document has not been labelled.", + "Document has been auto-labelled." + ], + "type": "string" + }, + "pageCount": { + "description": "Number of pages in the document.", + "format": "int32", + "type": "integer" + } + }, + "type": "object" + }, "GoogleCloudDocumentaiV1beta3DocumentOutputConfig": { "description": "Config that controls the output of documents. All documents will be written as a JSON file.", "id": "GoogleCloudDocumentaiV1beta3DocumentOutputConfig", @@ -7807,6 +7887,56 @@ }, "type": "object" }, + "GoogleCloudDocumentaiV1beta3ListDocumentsRequest": { + "id": "GoogleCloudDocumentaiV1beta3ListDocumentsRequest", + "properties": { + "filter": { + "description": "Optional. Query to filter the documents based on https://google.aip.dev/160. ## Currently support query strings are: `SplitType=DATASET_SPLIT_TEST|DATASET_SPLIT_TRAIN|DATASET_SPLIT_UNASSIGNED` - `LabelingState=DOCUMENT_LABELED|DOCUMENT_UNLABELED|DOCUMENT_AUTO_LABELED` - `DisplayName=\\\"file_name.pdf\\\"` - `EntityType=abc/def` - `TagName=\\\"auto-labeling-running\\\"|\\\"sampled\\\"` Note: - Only `AND`, `=` and `!=` are supported. e.g. `DisplayName=file_name AND EntityType!=abc` IS supported. - Wildcard `*` is supported only in `DisplayName` filter - No duplicate filter keys are allowed, e.g. `EntityType=a AND EntityType=b` is NOT supported. - String match is case sensitive (for filter `DisplayName` \u0026 `EntityType`).", + "type": "string" + }, + "pageSize": { + "description": "The maximum number of documents to return. The service may return fewer than this value. If unspecified, at most 20 documents will be returned. The maximum value is 100; values above 100 will be coerced to 100.", + "format": "int32", + "type": "integer" + }, + "pageToken": { + "description": "A page token, received from a previous `ListDocuments` call. Provide this to retrieve the subsequent page. When paginating, all other parameters provided to `ListDocuments` must match the call that provided the page token.", + "type": "string" + }, + "returnTotalSize": { + "description": "Optional. Controls if the ListDocuments request requires a total size of matched documents. See ListDocumentsResponse.total_size. Enabling this flag may adversely impact performance. Defaults to false.", + "type": "boolean" + }, + "skip": { + "description": "Optional. Number of results to skip beginning from the `page_token` if provided. https://google.aip.dev/158#skipping-results. It must be a non-negative integer. Negative values wil be rejected. Note that this is not the number of pages to skip. If this value causes the cursor to move past the end of results, `ListDocumentsResponse.document_metadata` and `ListDocumentsResponse.next_page_token` will be empty.", + "format": "int32", + "type": "integer" + } + }, + "type": "object" + }, + "GoogleCloudDocumentaiV1beta3ListDocumentsResponse": { + "id": "GoogleCloudDocumentaiV1beta3ListDocumentsResponse", + "properties": { + "documentMetadata": { + "description": "Document metadata corresponding to the listed documents.", + "items": { + "$ref": "GoogleCloudDocumentaiV1beta3DocumentMetadata" + }, + "type": "array" + }, + "nextPageToken": { + "description": "A token, which can be sent as `page_token` to retrieve the next page. If this field is omitted, there are no subsequent pages.", + "type": "string" + }, + "totalSize": { + "description": "Total count of documents queried.", + "format": "int32", + "type": "integer" + } + }, + "type": "object" + }, "GoogleCloudDocumentaiV1beta3ListEvaluationsResponse": { "description": "The response from `ListEvaluations`.", "id": "GoogleCloudDocumentaiV1beta3ListEvaluationsResponse", @@ -7913,7 +8043,7 @@ "type": "boolean" }, "disableCharacterBoxesDetection": { - "description": "Turn off character box detector in OCR engine. Character box detection is enabled by default in OCR 2.0+ processors.", + "description": "Turn off character box detector in OCR engine. Character box detection is enabled by default in OCR 2.0 (and later) processors.", "type": "boolean" }, "enableImageQualityScores": { @@ -7966,7 +8096,7 @@ "type": "boolean" }, "enableSelectionMarkDetection": { - "description": "Turn on selection mark detector in OCR engine. Only available in OCR 2.0+ processors.", + "description": "Turn on selection mark detector in OCR engine. Only available in OCR 2.0 (and later) processors.", "type": "boolean" } }, @@ -7982,7 +8112,7 @@ "type": "integer" }, "fromStart": { - "description": "Only process certain pages from the start, process all if the document has less pages.", + "description": "Only process certain pages from the start. Process all if the document has fewer pages.", "format": "int32", "type": "integer" }, diff --git a/documentai/v1beta3/documentai-gen.go b/documentai/v1beta3/documentai-gen.go index a27d3fd97f2..e0969298274 100644 --- a/documentai/v1beta3/documentai-gen.go +++ b/documentai/v1beta3/documentai-gen.go @@ -7675,7 +7675,7 @@ func (s *GoogleCloudDocumentaiV1beta3CommonOperationMetadata) MarshalJSON() ([]b } // GoogleCloudDocumentaiV1beta3Dataset: A singleton resource under a -// Processor which configures a collection of documents. Next Id: 8. +// Processor which configures a collection of documents. type GoogleCloudDocumentaiV1beta3Dataset struct { // DocumentWarehouseConfig: Optional. Document AI Warehouse-based // dataset configuration. @@ -8365,6 +8365,61 @@ func (s *GoogleCloudDocumentaiV1beta3DocumentIdUnmanagedDocumentId) MarshalJSON( return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } +// GoogleCloudDocumentaiV1beta3DocumentMetadata: Metadata about a +// document. +type GoogleCloudDocumentaiV1beta3DocumentMetadata struct { + // DatasetType: Type of the dataset split to which the document belongs. + // + // Possible values: + // "DATASET_SPLIT_TYPE_UNSPECIFIED" - Default value if the enum is not + // set. + // "DATASET_SPLIT_TRAIN" - Identifies the train documents. + // "DATASET_SPLIT_TEST" - Identifies the test documents. + // "DATASET_SPLIT_UNASSIGNED" - Identifies the unassigned documents. + DatasetType string `json:"datasetType,omitempty"` + + // DisplayName: The display name of the document. + DisplayName string `json:"displayName,omitempty"` + + // DocumentId: Document identifier. + DocumentId *GoogleCloudDocumentaiV1beta3DocumentId `json:"documentId,omitempty"` + + // LabelingState: Labelling state of the document. + // + // Possible values: + // "DOCUMENT_LABELING_STATE_UNSPECIFIED" - Default value if the enum + // is not set. + // "DOCUMENT_LABELED" - Document has been labelled. + // "DOCUMENT_UNLABELED" - Document has not been labelled. + // "DOCUMENT_AUTO_LABELED" - Document has been auto-labelled. + LabelingState string `json:"labelingState,omitempty"` + + // PageCount: Number of pages in the document. + PageCount int64 `json:"pageCount,omitempty"` + + // ForceSendFields is a list of field names (e.g. "DatasetType") to + // unconditionally include in API requests. By default, fields with + // empty or default values are omitted from API requests. However, any + // non-pointer, non-interface field appearing in ForceSendFields will be + // sent to the server regardless of whether the field is empty or not. + // This may be used to include empty fields in Patch requests. + ForceSendFields []string `json:"-"` + + // NullFields is a list of field names (e.g. "DatasetType") to include + // in API requests with the JSON null value. By default, fields with + // empty values are omitted from API requests. However, any field with + // an empty value appearing in NullFields will be sent to the server as + // null. It is an error if a field in this list has a non-empty value. + // This may be used to include null fields in Patch requests. + NullFields []string `json:"-"` +} + +func (s *GoogleCloudDocumentaiV1beta3DocumentMetadata) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDocumentaiV1beta3DocumentMetadata + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + // GoogleCloudDocumentaiV1beta3DocumentOutputConfig: Config that // controls the output of documents. All documents will be written as a // JSON file. @@ -11353,6 +11408,113 @@ func (s *GoogleCloudDocumentaiV1beta3ImportProcessorVersionResponse) MarshalJSON return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } +type GoogleCloudDocumentaiV1beta3ListDocumentsRequest struct { + // Filter: Optional. Query to filter the documents based on + // https://google.aip.dev/160. ## Currently support query strings are: + // `SplitType=DATASET_SPLIT_TEST|DATASET_SPLIT_TRAIN|DATASET_SPLIT_UNASSI + // GNED` - + // `LabelingState=DOCUMENT_LABELED|DOCUMENT_UNLABELED|DOCUMENT_AUTO_LABEL + // ED` - `DisplayName=\"file_name.pdf\" - `EntityType=abc/def` - + // `TagName=\"auto-labeling-running\"|\"sampled\" Note: - Only `AND`, + // `=` and `!=` are supported. e.g. `DisplayName=file_name AND + // EntityType!=abc` IS supported. - Wildcard `*` is supported only in + // `DisplayName` filter - No duplicate filter keys are allowed, e.g. + // `EntityType=a AND EntityType=b` is NOT supported. - String match is + // case sensitive (for filter `DisplayName` & `EntityType`). + Filter string `json:"filter,omitempty"` + + // PageSize: The maximum number of documents to return. The service may + // return fewer than this value. If unspecified, at most 20 documents + // will be returned. The maximum value is 100; values above 100 will be + // coerced to 100. + PageSize int64 `json:"pageSize,omitempty"` + + // PageToken: A page token, received from a previous `ListDocuments` + // call. Provide this to retrieve the subsequent page. When paginating, + // all other parameters provided to `ListDocuments` must match the call + // that provided the page token. + PageToken string `json:"pageToken,omitempty"` + + // ReturnTotalSize: Optional. Controls if the ListDocuments request + // requires a total size of matched documents. See + // ListDocumentsResponse.total_size. Enabling this flag may adversely + // impact performance. Defaults to false. + ReturnTotalSize bool `json:"returnTotalSize,omitempty"` + + // Skip: Optional. Number of results to skip beginning from the + // `page_token` if provided. + // https://google.aip.dev/158#skipping-results. It must be a + // non-negative integer. Negative values wil be rejected. Note that this + // is not the number of pages to skip. If this value causes the cursor + // to move past the end of results, + // `ListDocumentsResponse.document_metadata` and + // `ListDocumentsResponse.next_page_token` will be empty. + Skip int64 `json:"skip,omitempty"` + + // ForceSendFields is a list of field names (e.g. "Filter") to + // unconditionally include in API requests. By default, fields with + // empty or default values are omitted from API requests. However, any + // non-pointer, non-interface field appearing in ForceSendFields will be + // sent to the server regardless of whether the field is empty or not. + // This may be used to include empty fields in Patch requests. + ForceSendFields []string `json:"-"` + + // NullFields is a list of field names (e.g. "Filter") to include in API + // requests with the JSON null value. By default, fields with empty + // values are omitted from API requests. However, any field with an + // empty value appearing in NullFields will be sent to the server as + // null. It is an error if a field in this list has a non-empty value. + // This may be used to include null fields in Patch requests. + NullFields []string `json:"-"` +} + +func (s *GoogleCloudDocumentaiV1beta3ListDocumentsRequest) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDocumentaiV1beta3ListDocumentsRequest + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + +type GoogleCloudDocumentaiV1beta3ListDocumentsResponse struct { + // DocumentMetadata: Document metadata corresponding to the listed + // documents. + DocumentMetadata []*GoogleCloudDocumentaiV1beta3DocumentMetadata `json:"documentMetadata,omitempty"` + + // NextPageToken: A token, which can be sent as `page_token` to retrieve + // the next page. If this field is omitted, there are no subsequent + // pages. + NextPageToken string `json:"nextPageToken,omitempty"` + + // TotalSize: Total count of documents queried. + TotalSize int64 `json:"totalSize,omitempty"` + + // ServerResponse contains the HTTP response code and headers from the + // server. + googleapi.ServerResponse `json:"-"` + + // ForceSendFields is a list of field names (e.g. "DocumentMetadata") to + // unconditionally include in API requests. By default, fields with + // empty or default values are omitted from API requests. However, any + // non-pointer, non-interface field appearing in ForceSendFields will be + // sent to the server regardless of whether the field is empty or not. + // This may be used to include empty fields in Patch requests. + ForceSendFields []string `json:"-"` + + // NullFields is a list of field names (e.g. "DocumentMetadata") to + // include in API requests with the JSON null value. By default, fields + // with empty values are omitted from API requests. However, any field + // with an empty value appearing in NullFields will be sent to the + // server as null. It is an error if a field in this list has a + // non-empty value. This may be used to include null fields in Patch + // requests. + NullFields []string `json:"-"` +} + +func (s *GoogleCloudDocumentaiV1beta3ListDocumentsResponse) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDocumentaiV1beta3ListDocumentsResponse + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + // GoogleCloudDocumentaiV1beta3ListEvaluationsResponse: The response // from `ListEvaluations`. type GoogleCloudDocumentaiV1beta3ListEvaluationsResponse struct { @@ -11564,8 +11726,8 @@ type GoogleCloudDocumentaiV1beta3OcrConfig struct { ComputeStyleInfo bool `json:"computeStyleInfo,omitempty"` // DisableCharacterBoxesDetection: Turn off character box detector in - // OCR engine. Character box detection is enabled by default in OCR 2.0+ - // processors. + // OCR engine. Character box detection is enabled by default in OCR 2.0 + // (and later) processors. DisableCharacterBoxesDetection bool `json:"disableCharacterBoxesDetection,omitempty"` // EnableImageQualityScores: Enables intelligent document quality scores @@ -11658,7 +11820,7 @@ type GoogleCloudDocumentaiV1beta3OcrConfigPremiumFeatures struct { EnableMathOcr bool `json:"enableMathOcr,omitempty"` // EnableSelectionMarkDetection: Turn on selection mark detector in OCR - // engine. Only available in OCR 2.0+ processors. + // engine. Only available in OCR 2.0 (and later) processors. EnableSelectionMarkDetection bool `json:"enableSelectionMarkDetection,omitempty"` // ForceSendFields is a list of field names (e.g. "ComputeStyleInfo") to @@ -11690,8 +11852,8 @@ type GoogleCloudDocumentaiV1beta3ProcessOptions struct { // FromEnd: Only process certain pages from the end, same as above. FromEnd int64 `json:"fromEnd,omitempty"` - // FromStart: Only process certain pages from the start, process all if - // the document has less pages. + // FromStart: Only process certain pages from the start. Process all if + // the document has fewer pages. FromStart int64 `json:"fromStart,omitempty"` // IndividualPageSelector: Which pages to process (1-indexed). @@ -17217,6 +17379,173 @@ func (c *ProjectsLocationsProcessorsDatasetImportDocumentsCall) Do(opts ...googl } +// method id "documentai.projects.locations.processors.dataset.listDocuments": + +type ProjectsLocationsProcessorsDatasetListDocumentsCall struct { + s *Service + dataset string + googleclouddocumentaiv1beta3listdocumentsrequest *GoogleCloudDocumentaiV1beta3ListDocumentsRequest + urlParams_ gensupport.URLParams + ctx_ context.Context + header_ http.Header +} + +// ListDocuments: Returns a list of documents present in the dataset. +// +// - dataset: The resource name of the dataset to be listed. Format: +// projects/{project}/locations/{location}/processors/{processor}/datas +// et. +func (r *ProjectsLocationsProcessorsDatasetService) ListDocuments(dataset string, googleclouddocumentaiv1beta3listdocumentsrequest *GoogleCloudDocumentaiV1beta3ListDocumentsRequest) *ProjectsLocationsProcessorsDatasetListDocumentsCall { + c := &ProjectsLocationsProcessorsDatasetListDocumentsCall{s: r.s, urlParams_: make(gensupport.URLParams)} + c.dataset = dataset + c.googleclouddocumentaiv1beta3listdocumentsrequest = googleclouddocumentaiv1beta3listdocumentsrequest + return c +} + +// Fields allows partial responses to be retrieved. See +// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse +// for more information. +func (c *ProjectsLocationsProcessorsDatasetListDocumentsCall) Fields(s ...googleapi.Field) *ProjectsLocationsProcessorsDatasetListDocumentsCall { + c.urlParams_.Set("fields", googleapi.CombineFields(s)) + return c +} + +// Context sets the context to be used in this call's Do method. Any +// pending HTTP request will be aborted if the provided context is +// canceled. +func (c *ProjectsLocationsProcessorsDatasetListDocumentsCall) Context(ctx context.Context) *ProjectsLocationsProcessorsDatasetListDocumentsCall { + c.ctx_ = ctx + return c +} + +// Header returns an http.Header that can be modified by the caller to +// add HTTP headers to the request. +func (c *ProjectsLocationsProcessorsDatasetListDocumentsCall) Header() http.Header { + if c.header_ == nil { + c.header_ = make(http.Header) + } + return c.header_ +} + +func (c *ProjectsLocationsProcessorsDatasetListDocumentsCall) doRequest(alt string) (*http.Response, error) { + reqHeaders := make(http.Header) + reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version) + for k, v := range c.header_ { + reqHeaders[k] = v + } + reqHeaders.Set("User-Agent", c.s.userAgent()) + var body io.Reader = nil + body, err := googleapi.WithoutDataWrapper.JSONReader(c.googleclouddocumentaiv1beta3listdocumentsrequest) + if err != nil { + return nil, err + } + reqHeaders.Set("Content-Type", "application/json") + c.urlParams_.Set("alt", alt) + c.urlParams_.Set("prettyPrint", "false") + urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta3/{+dataset}:listDocuments") + urls += "?" + c.urlParams_.Encode() + req, err := http.NewRequest("POST", urls, body) + if err != nil { + return nil, err + } + req.Header = reqHeaders + googleapi.Expand(req.URL, map[string]string{ + "dataset": c.dataset, + }) + return gensupport.SendRequest(c.ctx_, c.s.client, req) +} + +// Do executes the "documentai.projects.locations.processors.dataset.listDocuments" call. +// Exactly one of *GoogleCloudDocumentaiV1beta3ListDocumentsResponse or +// error will be non-nil. Any non-2xx status code is an error. Response +// headers are in either +// *GoogleCloudDocumentaiV1beta3ListDocumentsResponse.ServerResponse.Head +// er or (if a response was returned at all) in +// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check +// whether the returned error was because http.StatusNotModified was +// returned. +func (c *ProjectsLocationsProcessorsDatasetListDocumentsCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDocumentaiV1beta3ListDocumentsResponse, error) { + gensupport.SetOptions(c.urlParams_, opts...) + res, err := c.doRequest("json") + if res != nil && res.StatusCode == http.StatusNotModified { + if res.Body != nil { + res.Body.Close() + } + return nil, gensupport.WrapError(&googleapi.Error{ + Code: res.StatusCode, + Header: res.Header, + }) + } + if err != nil { + return nil, err + } + defer googleapi.CloseBody(res) + if err := googleapi.CheckResponse(res); err != nil { + return nil, gensupport.WrapError(err) + } + ret := &GoogleCloudDocumentaiV1beta3ListDocumentsResponse{ + ServerResponse: googleapi.ServerResponse{ + Header: res.Header, + HTTPStatusCode: res.StatusCode, + }, + } + target := &ret + if err := gensupport.DecodeResponse(target, res); err != nil { + return nil, err + } + return ret, nil + // { + // "description": "Returns a list of documents present in the dataset.", + // "flatPath": "v1beta3/projects/{projectsId}/locations/{locationsId}/processors/{processorsId}/dataset:listDocuments", + // "httpMethod": "POST", + // "id": "documentai.projects.locations.processors.dataset.listDocuments", + // "parameterOrder": [ + // "dataset" + // ], + // "parameters": { + // "dataset": { + // "description": "Required. The resource name of the dataset to be listed. Format: projects/{project}/locations/{location}/processors/{processor}/dataset", + // "location": "path", + // "pattern": "^projects/[^/]+/locations/[^/]+/processors/[^/]+/dataset$", + // "required": true, + // "type": "string" + // } + // }, + // "path": "v1beta3/{+dataset}:listDocuments", + // "request": { + // "$ref": "GoogleCloudDocumentaiV1beta3ListDocumentsRequest" + // }, + // "response": { + // "$ref": "GoogleCloudDocumentaiV1beta3ListDocumentsResponse" + // }, + // "scopes": [ + // "https://www.googleapis.com/auth/cloud-platform" + // ] + // } + +} + +// Pages invokes f for each page of results. +// A non-nil error returned from f will halt the iteration. +// The provided context supersedes any context provided to the Context method. +func (c *ProjectsLocationsProcessorsDatasetListDocumentsCall) Pages(ctx context.Context, f func(*GoogleCloudDocumentaiV1beta3ListDocumentsResponse) error) error { + c.ctx_ = ctx + defer func(pt string) { c.googleclouddocumentaiv1beta3listdocumentsrequest.PageToken = pt }(c.googleclouddocumentaiv1beta3listdocumentsrequest.PageToken) // reset paging to original point + for { + x, err := c.Do() + if err != nil { + return err + } + if err := f(x); err != nil { + return err + } + if x.NextPageToken == "" { + return nil + } + c.googleclouddocumentaiv1beta3listdocumentsrequest.PageToken = x.NextPageToken + } +} + // method id "documentai.projects.locations.processors.dataset.updateDatasetSchema": type ProjectsLocationsProcessorsDatasetUpdateDatasetSchemaCall struct { diff --git a/places/v1/places-api.json b/places/v1/places-api.json index e6b84139e03..89a50088dfb 100644 --- a/places/v1/places-api.json +++ b/places/v1/places-api.json @@ -136,7 +136,7 @@ } } }, - "revision": "20230912", + "revision": "20230925", "rootUrl": "https://places.googleapis.com/", "schemas": { "GoogleGeoTypeViewport": { @@ -317,11 +317,6 @@ "readOnly": true, "type": "string" }, - "openingHours": { - "$ref": "GoogleMapsPlacesV1PlaceOpeningHours", - "description": "Output only. The regular hours of operation.", - "readOnly": true - }, "plusCode": { "$ref": "GoogleMapsPlacesV1PlacePlusCode", "description": "Output only. Plus code of the place location lat/long.", @@ -354,6 +349,19 @@ "readOnly": true, "type": "number" }, + "regularOpeningHours": { + "$ref": "GoogleMapsPlacesV1PlaceOpeningHours", + "description": "Output only. The regular hours of operation.", + "readOnly": true + }, + "regularSecondaryOpeningHours": { + "description": "Output only. Contains an array of entries for information about regular secondary hours of a business. Secondary hours are different from a business's main hours. For example, a restaurant can specify drive through hours or delivery hours as its secondary hours. This field populates the type subfield, which draws from a predefined list of opening hours types (such as DRIVE_THROUGH, PICKUP, or TAKEOUT) based on the types of the place.", + "items": { + "$ref": "GoogleMapsPlacesV1PlaceOpeningHours" + }, + "readOnly": true, + "type": "array" + }, "reservable": { "description": "Output only. Specifies if the place supports reservations.", "readOnly": true, @@ -367,14 +375,6 @@ "readOnly": true, "type": "array" }, - "secondaryOpeningHours": { - "description": "Output only. Contains an array of entries for information about regular secondary hours of a business. Secondary hours are different from a business's main hours. For example, a restaurant can specify drive through hours or delivery hours as its secondary hours. This field populates the type subfield, which draws from a predefined list of opening hours types (such as DRIVE_THROUGH, PICKUP, or TAKEOUT) based on the types of the place.", - "items": { - "$ref": "GoogleMapsPlacesV1PlaceOpeningHours" - }, - "readOnly": true, - "type": "array" - }, "servesBeer": { "description": "Output only. Specifies if the place serves beer.", "readOnly": true, @@ -444,12 +444,6 @@ "description": "Output only. The authoritative website for this place, e.g. a business' homepage. Note that for places that are part of a chain (e.g. an IKEA store), this will usually be the website for the individual store, not the overall chain.", "readOnly": true, "type": "string" - }, - "wheelchairAccessibleEntrance": { - "deprecated": true, - "description": "Output only. [Deprecated!] Specifies if the place has an entrance that is wheelchair-accessible.", - "readOnly": true, - "type": "boolean" } }, "type": "object" diff --git a/places/v1/places-gen.go b/places/v1/places-gen.go index 2027c6450a3..2e81952e2a5 100644 --- a/places/v1/places-gen.go +++ b/places/v1/places-gen.go @@ -406,9 +406,6 @@ type GoogleMapsPlacesV1Place struct { // the place, in national format. NationalPhoneNumber string `json:"nationalPhoneNumber,omitempty"` - // OpeningHours: Output only. The regular hours of operation. - OpeningHours *GoogleMapsPlacesV1PlaceOpeningHours `json:"openingHours,omitempty"` - // PlusCode: Output only. Plus code of the place location lat/long. PlusCode *GoogleMapsPlacesV1PlacePlusCode `json:"plusCode,omitempty"` @@ -429,6 +426,18 @@ type GoogleMapsPlacesV1Place struct { // reviews of this place. Rating float64 `json:"rating,omitempty"` + // RegularOpeningHours: Output only. The regular hours of operation. + RegularOpeningHours *GoogleMapsPlacesV1PlaceOpeningHours `json:"regularOpeningHours,omitempty"` + + // RegularSecondaryOpeningHours: Output only. Contains an array of + // entries for information about regular secondary hours of a business. + // Secondary hours are different from a business's main hours. For + // example, a restaurant can specify drive through hours or delivery + // hours as its secondary hours. This field populates the type subfield, + // which draws from a predefined list of opening hours types (such as + // DRIVE_THROUGH, PICKUP, or TAKEOUT) based on the types of the place. + RegularSecondaryOpeningHours []*GoogleMapsPlacesV1PlaceOpeningHours `json:"regularSecondaryOpeningHours,omitempty"` + // Reservable: Output only. Specifies if the place supports // reservations. Reservable bool `json:"reservable,omitempty"` @@ -436,15 +445,6 @@ type GoogleMapsPlacesV1Place struct { // Reviews: Output only. List of reviews about this place. Reviews []*GoogleMapsPlacesV1Review `json:"reviews,omitempty"` - // SecondaryOpeningHours: Output only. Contains an array of entries for - // information about regular secondary hours of a business. Secondary - // hours are different from a business's main hours. For example, a - // restaurant can specify drive through hours or delivery hours as its - // secondary hours. This field populates the type subfield, which draws - // from a predefined list of opening hours types (such as DRIVE_THROUGH, - // PICKUP, or TAKEOUT) based on the types of the place. - SecondaryOpeningHours []*GoogleMapsPlacesV1PlaceOpeningHours `json:"secondaryOpeningHours,omitempty"` - // ServesBeer: Output only. Specifies if the place serves beer. ServesBeer bool `json:"servesBeer,omitempty"` @@ -495,10 +495,6 @@ type GoogleMapsPlacesV1Place struct { // individual store, not the overall chain. WebsiteUri string `json:"websiteUri,omitempty"` - // WheelchairAccessibleEntrance: Output only. [Deprecated!] Specifies if - // the place has an entrance that is wheelchair-accessible. - WheelchairAccessibleEntrance bool `json:"wheelchairAccessibleEntrance,omitempty"` - // ForceSendFields is a list of field names (e.g. "AddressComponents") // to unconditionally include in API requests. By default, fields with // empty or default values are omitted from API requests. However, any diff --git a/run/v1/run-api.json b/run/v1/run-api.json index e7dee9a1f8c..eb51e505023 100644 --- a/run/v1/run-api.json +++ b/run/v1/run-api.json @@ -2289,7 +2289,7 @@ } } }, - "revision": "20230910", + "revision": "20230924", "rootUrl": "https://run.googleapis.com/", "schemas": { "Addressable": { @@ -3590,7 +3590,7 @@ "additionalProperties": { "type": "string" }, - "description": "Unstructured key value map stored with a resource that may be set by external tools to store and retrieve arbitrary metadata. They are not queryable and should be preserved when modifying objects. In Cloud Run, annotations with 'run.googleapis.com/' and 'autoscaling.knative.dev' are restricted, and the accepted annotations will be different depending on the resource type. * `autoscaling.knative.dev/maxScale`: Revision. * `autoscaling.knative.dev/minScale`: Revision. * `run.googleapis.com/binary-authorization-breakglass`: Service, Job, * `run.googleapis.com/binary-authorization`: Service, Job, Execution. * `run.googleapis.com/client-name`: All resources. * `run.googleapis.com/cloudsql-instances`: Revision, Execution. * `run.googleapis.com/container-dependencies`: Revision. * `run.googleapis.com/cpu-throttling`: Revision. * `run.googleapis.com/custom-audiences`: Service. * `run.googleapis.com/description`: Service. * `run.googleapis.com/disable-default-uri`: Service. * `run.googleapis.com/encryption-key-shutdown-hours`: Revision * `run.googleapis.com/encryption-key`: Revision, Execution. * `run.googleapis.com/execution-environment`: Revision, Execution. * `run.googleapis.com/gc-traffic-tags`: Service. * `run.googleapis.com/ingress`: Service. * `run.googleapis.com/launch-stage`: Service, Job. * `run.googleapis.com/network-interfaces`: Revision, Execution. * `run.googleapis.com/post-key-revocation-action-type`: Revision. * `run.googleapis.com/secrets`: Revision, Execution. * `run.googleapis.com/secure-session-agent`: Revision. * `run.googleapis.com/sessionAffinity`: Revision. * `run.googleapis.com/startup-cpu-boost`: Revision. * `run.googleapis.com/vpc-access-connector`: Revision, Execution. * `run.googleapis.com/vpc-access-egress`: Revision, Execution.", + "description": "Unstructured key value map stored with a resource that may be set by external tools to store and retrieve arbitrary metadata. They are not queryable and should be preserved when modifying objects. In Cloud Run, annotations with 'run.googleapis.com/' and 'autoscaling.knative.dev' are restricted, and the accepted annotations will be different depending on the resource type. * `autoscaling.knative.dev/maxScale`: Revision. * `autoscaling.knative.dev/minScale`: Revision. * `run.googleapis.com/binary-authorization-breakglass`: Service, Job, * `run.googleapis.com/binary-authorization`: Service, Job, Execution. * `run.googleapis.com/client-name`: All resources. * `run.googleapis.com/cloudsql-instances`: Revision, Execution. * `run.googleapis.com/container-dependencies`: Revision. * `run.googleapis.com/cpu-throttling`: Revision. * `run.googleapis.com/custom-audiences`: Service. * `run.googleapis.com/description`: Service. * `run.googleapis.com/disable-default-url`: Service. * `run.googleapis.com/encryption-key-shutdown-hours`: Revision * `run.googleapis.com/encryption-key`: Revision, Execution. * `run.googleapis.com/execution-environment`: Revision, Execution. * `run.googleapis.com/gc-traffic-tags`: Service. * `run.googleapis.com/ingress`: Service. * `run.googleapis.com/launch-stage`: Service, Job. * `run.googleapis.com/network-interfaces`: Revision, Execution. * `run.googleapis.com/post-key-revocation-action-type`: Revision. * `run.googleapis.com/secrets`: Revision, Execution. * `run.googleapis.com/secure-session-agent`: Revision. * `run.googleapis.com/sessionAffinity`: Revision. * `run.googleapis.com/startup-cpu-boost`: Revision. * `run.googleapis.com/vpc-access-connector`: Revision, Execution. * `run.googleapis.com/vpc-access-egress`: Revision, Execution.", "type": "object" }, "clusterName": { @@ -4152,7 +4152,7 @@ }, "metadata": { "$ref": "ObjectMeta", - "description": "Metadata associated with this Service, including name, namespace, labels, and annotations. In Cloud Run, annotations with 'run.googleapis.com/' and 'autoscaling.knative.dev' are restricted, and the accepted annotations will be different depending on the resource type. The following Cloud Run-specific annotations are accepted in Service.metadata.annotations. * `run.googleapis.com/binary-authorization-breakglass` * `run.googleapis.com/binary-authorization` * `run.googleapis.com/client-name` * `run.googleapis.com/custom-audiences` * `run.googleapis.com/description` * `run.googleapis.com/disable-default-uri` * `run.googleapis.com/gc-traffic-tags` * `run.googleapis.com/ingress` * `run.googleapis.com/ingress` sets the ingress settings for the Service. See [the ingress settings documentation](/run/docs/securing/ingress) for details on configuring ingress settings. * `run.googleapis.com/ingress-status` is output-only and contains the currently active ingress settings for the Service. `run.googleapis.com/ingress-status` may differ from `run.googleapis.com/ingress` while the system is processing a change to `run.googleapis.com/ingress` or if the system failed to process a change to `run.googleapis.com/ingress`. When the system has processed all changes successfully `run.googleapis.com/ingress-status` and `run.googleapis.com/ingress` are equal." + "description": "Metadata associated with this Service, including name, namespace, labels, and annotations. In Cloud Run, annotations with 'run.googleapis.com/' and 'autoscaling.knative.dev' are restricted, and the accepted annotations will be different depending on the resource type. The following Cloud Run-specific annotations are accepted in Service.metadata.annotations. * `run.googleapis.com/binary-authorization-breakglass` * `run.googleapis.com/binary-authorization` * `run.googleapis.com/client-name` * `run.googleapis.com/custom-audiences` * `run.googleapis.com/description` * `run.googleapis.com/disable-default-url` * `run.googleapis.com/gc-traffic-tags` * `run.googleapis.com/ingress` * `run.googleapis.com/ingress` sets the ingress settings for the Service. See [the ingress settings documentation](/run/docs/securing/ingress) for details on configuring ingress settings. * `run.googleapis.com/ingress-status` is output-only and contains the currently active ingress settings for the Service. `run.googleapis.com/ingress-status` may differ from `run.googleapis.com/ingress` while the system is processing a change to `run.googleapis.com/ingress` or if the system failed to process a change to `run.googleapis.com/ingress`. When the system has processed all changes successfully `run.googleapis.com/ingress-status` and `run.googleapis.com/ingress` are equal." }, "spec": { "$ref": "ServiceSpec", @@ -4207,7 +4207,7 @@ "type": "string" }, "observedGeneration": { - "description": "Returns the generation last fully processed by the system. This will only match metadata.generation when reconciliation is complete. Clients polling for completed reconciliation should poll until observedGeneration = metadata.generation and the Ready condition's status is True or False.", + "description": "Returns the generation last seen by the system. Clients polling for completed reconciliation should poll until observedGeneration = metadata.generation and the Ready condition's status is True or False.", "format": "int32", "type": "integer" }, diff --git a/run/v1/run-gen.go b/run/v1/run-gen.go index 0f32a258fb1..35e77820eb2 100644 --- a/run/v1/run-gen.go +++ b/run/v1/run-gen.go @@ -2692,7 +2692,7 @@ type ObjectMeta struct { // `run.googleapis.com/cpu-throttling`: Revision. * // `run.googleapis.com/custom-audiences`: Service. * // `run.googleapis.com/description`: Service. * - // `run.googleapis.com/disable-default-uri`: Service. * + // `run.googleapis.com/disable-default-url`: Service. * // `run.googleapis.com/encryption-key-shutdown-hours`: Revision * // `run.googleapis.com/encryption-key`: Revision, Execution. * // `run.googleapis.com/execution-environment`: Revision, Execution. * @@ -3738,7 +3738,7 @@ type Service struct { // `run.googleapis.com/client-name` * // `run.googleapis.com/custom-audiences` * // `run.googleapis.com/description` * - // `run.googleapis.com/disable-default-uri` * + // `run.googleapis.com/disable-default-url` * // `run.googleapis.com/gc-traffic-tags` * `run.googleapis.com/ingress` * // `run.googleapis.com/ingress` sets the ingress settings for the // Service. See the ingress settings documentation @@ -3845,12 +3845,10 @@ type ServiceStatus struct { // `True`. LatestReadyRevisionName string `json:"latestReadyRevisionName,omitempty"` - // ObservedGeneration: Returns the generation last fully processed by - // the system. This will only match metadata.generation when - // reconciliation is complete. Clients polling for completed - // reconciliation should poll until observedGeneration = - // metadata.generation and the Ready condition's status is True or - // False. + // ObservedGeneration: Returns the generation last seen by the system. + // Clients polling for completed reconciliation should poll until + // observedGeneration = metadata.generation and the Ready condition's + // status is True or False. ObservedGeneration int64 `json:"observedGeneration,omitempty"` // Traffic: Holds the configured traffic distribution. These entries diff --git a/run/v2/run-api.json b/run/v2/run-api.json index 566a959b140..3810e0948bb 100644 --- a/run/v2/run-api.json +++ b/run/v2/run-api.json @@ -417,7 +417,7 @@ ], "parameters": { "name": { - "description": "Required. The name of the Execution to cancel. Format: projects/{project}/locations/{location}/jobs/{job}/executions/{execution}, where {project} can be project id or number.", + "description": "Required. The name of the Execution to cancel. Format: `projects/{project}/locations/{location}/jobs/{job}/executions/{execution}`, where `{project}` can be project id or number.", "location": "path", "pattern": "^projects/[^/]+/locations/[^/]+/jobs/[^/]+/executions/[^/]+$", "required": true, @@ -450,7 +450,7 @@ "type": "string" }, "name": { - "description": "Required. The name of the Execution to delete. Format: projects/{project}/locations/{location}/jobs/{job}/executions/{execution}, where {project} can be project id or number.", + "description": "Required. The name of the Execution to delete. Format: `projects/{project}/locations/{location}/jobs/{job}/executions/{execution}`, where `{project}` can be project id or number.", "location": "path", "pattern": "^projects/[^/]+/locations/[^/]+/jobs/[^/]+/executions/[^/]+$", "required": true, @@ -480,7 +480,7 @@ ], "parameters": { "name": { - "description": "Required. The full name of the Execution. Format: projects/{project}/locations/{location}/jobs/{job}/executions/{execution}, where {project} can be project id or number.", + "description": "Required. The full name of the Execution. Format: `projects/{project}/locations/{location}/jobs/{job}/executions/{execution}`, where `{project}` can be project id or number.", "location": "path", "pattern": "^projects/[^/]+/locations/[^/]+/jobs/[^/]+/executions/[^/]+$", "required": true, @@ -516,7 +516,7 @@ "type": "string" }, "parent": { - "description": "Required. The Execution from which the Executions should be listed. To list all Executions across Jobs, use \"-\" instead of Job name. Format: projects/{project}/locations/{location}/jobs/{job}, where {project} can be project id or number.", + "description": "Required. The Execution from which the Executions should be listed. To list all Executions across Jobs, use \"-\" instead of Job name. Format: `projects/{project}/locations/{location}/jobs/{job}`, where `{project}` can be project id or number.", "location": "path", "pattern": "^projects/[^/]+/locations/[^/]+/jobs/[^/]+$", "required": true, @@ -1115,7 +1115,7 @@ } } }, - "revision": "20230917", + "revision": "20230924", "rootUrl": "https://run.googleapis.com/", "schemas": { "GoogleCloudRunV2BinaryAuthorization": { @@ -1381,6 +1381,35 @@ }, "type": "object" }, + "GoogleCloudRunV2ContainerOverride": { + "description": "Per-container override specification.", + "id": "GoogleCloudRunV2ContainerOverride", + "properties": { + "args": { + "description": "Optional. Arguments to the entrypoint. Will replace existing args for override.", + "items": { + "type": "string" + }, + "type": "array" + }, + "clearArgs": { + "description": "Optional. True if the intention is to clear out existing args list.", + "type": "boolean" + }, + "env": { + "description": "List of environment variables to set in the container. Will be merged with existing env for override.", + "items": { + "$ref": "GoogleCloudRunV2EnvVar" + }, + "type": "array" + }, + "name": { + "description": "The name of the container specified as a DNS_LABEL.", + "type": "string" + } + }, + "type": "object" + }, "GoogleCloudRunV2ContainerPort": { "description": "ContainerPort represents a network port in a single container.", "id": "GoogleCloudRunV2ContainerPort", @@ -2012,6 +2041,30 @@ }, "type": "object" }, + "GoogleCloudRunV2Overrides": { + "description": "RunJob Overrides that contains Execution fields to be overridden.", + "id": "GoogleCloudRunV2Overrides", + "properties": { + "containerOverrides": { + "description": "Per container override specification.", + "items": { + "$ref": "GoogleCloudRunV2ContainerOverride" + }, + "type": "array" + }, + "taskCount": { + "description": "Optional. The desired number of tasks the execution should run. Will replace existing task_count value.", + "format": "int32", + "type": "integer" + }, + "timeout": { + "description": "Duration in seconds the task may be active before the system will actively try to mark it failed and kill associated containers. Will replace existing timeout_seconds value.", + "format": "google-duration", + "type": "string" + } + }, + "type": "object" + }, "GoogleCloudRunV2Probe": { "description": "Probe describes a health check to be performed against a container to determine whether it is alive or ready to receive traffic.", "id": "GoogleCloudRunV2Probe", @@ -2384,6 +2437,10 @@ "description": "A system-generated fingerprint for this version of the resource. May be used to detect modification conflict during updates.", "type": "string" }, + "overrides": { + "$ref": "GoogleCloudRunV2Overrides", + "description": "Overrides specification for a given execution of a job. If provided, overrides will be applied to update the execution or task spec." + }, "validateOnly": { "description": "Indicates that the request should be validated without actually deleting any resources.", "type": "boolean" diff --git a/run/v2/run-gen.go b/run/v2/run-gen.go index 3b67e19b5dd..9e59160290f 100644 --- a/run/v2/run-gen.go +++ b/run/v2/run-gen.go @@ -569,6 +569,47 @@ func (s *GoogleCloudRunV2Container) MarshalJSON() ([]byte, error) { return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } +// GoogleCloudRunV2ContainerOverride: Per-container override +// specification. +type GoogleCloudRunV2ContainerOverride struct { + // Args: Optional. Arguments to the entrypoint. Will replace existing + // args for override. + Args []string `json:"args,omitempty"` + + // ClearArgs: Optional. True if the intention is to clear out existing + // args list. + ClearArgs bool `json:"clearArgs,omitempty"` + + // Env: List of environment variables to set in the container. Will be + // merged with existing env for override. + Env []*GoogleCloudRunV2EnvVar `json:"env,omitempty"` + + // Name: The name of the container specified as a DNS_LABEL. + Name string `json:"name,omitempty"` + + // ForceSendFields is a list of field names (e.g. "Args") to + // unconditionally include in API requests. By default, fields with + // empty or default values are omitted from API requests. However, any + // non-pointer, non-interface field appearing in ForceSendFields will be + // sent to the server regardless of whether the field is empty or not. + // This may be used to include empty fields in Patch requests. + ForceSendFields []string `json:"-"` + + // NullFields is a list of field names (e.g. "Args") to include in API + // requests with the JSON null value. By default, fields with empty + // values are omitted from API requests. However, any field with an + // empty value appearing in NullFields will be sent to the server as + // null. It is an error if a field in this list has a non-empty value. + // This may be used to include null fields in Patch requests. + NullFields []string `json:"-"` +} + +func (s *GoogleCloudRunV2ContainerOverride) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudRunV2ContainerOverride + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + // GoogleCloudRunV2ContainerPort: ContainerPort represents a network // port in a single container. type GoogleCloudRunV2ContainerPort struct { @@ -1559,6 +1600,45 @@ func (s *GoogleCloudRunV2NetworkInterface) MarshalJSON() ([]byte, error) { return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } +// GoogleCloudRunV2Overrides: RunJob Overrides that contains Execution +// fields to be overridden. +type GoogleCloudRunV2Overrides struct { + // ContainerOverrides: Per container override specification. + ContainerOverrides []*GoogleCloudRunV2ContainerOverride `json:"containerOverrides,omitempty"` + + // TaskCount: Optional. The desired number of tasks the execution should + // run. Will replace existing task_count value. + TaskCount int64 `json:"taskCount,omitempty"` + + // Timeout: Duration in seconds the task may be active before the system + // will actively try to mark it failed and kill associated containers. + // Will replace existing timeout_seconds value. + Timeout string `json:"timeout,omitempty"` + + // ForceSendFields is a list of field names (e.g. "ContainerOverrides") + // to unconditionally include in API requests. By default, fields with + // empty or default values are omitted from API requests. However, any + // non-pointer, non-interface field appearing in ForceSendFields will be + // sent to the server regardless of whether the field is empty or not. + // This may be used to include empty fields in Patch requests. + ForceSendFields []string `json:"-"` + + // NullFields is a list of field names (e.g. "ContainerOverrides") to + // include in API requests with the JSON null value. By default, fields + // with empty values are omitted from API requests. However, any field + // with an empty value appearing in NullFields will be sent to the + // server as null. It is an error if a field in this list has a + // non-empty value. This may be used to include null fields in Patch + // requests. + NullFields []string `json:"-"` +} + +func (s *GoogleCloudRunV2Overrides) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudRunV2Overrides + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + // GoogleCloudRunV2Probe: Probe describes a health check to be performed // against a container to determine whether it is alive or ready to // receive traffic. @@ -2014,6 +2094,11 @@ type GoogleCloudRunV2RunJobRequest struct { // resource. May be used to detect modification conflict during updates. Etag string `json:"etag,omitempty"` + // Overrides: Overrides specification for a given execution of a job. If + // provided, overrides will be applied to update the execution or task + // spec. + Overrides *GoogleCloudRunV2Overrides `json:"overrides,omitempty"` + // ValidateOnly: Indicates that the request should be validated without // actually deleting any resources. ValidateOnly bool `json:"validateOnly,omitempty"` @@ -5097,8 +5182,8 @@ type ProjectsLocationsJobsExecutionsCancelCall struct { // Cancel: Cancels an Execution. // // - name: The name of the Execution to cancel. Format: -// projects/{project}/locations/{location}/jobs/{job}/executions/{execu -// tion}, where {project} can be project id or number. +// `projects/{project}/locations/{location}/jobs/{job}/executions/{exec +// ution}`, where `{project}` can be project id or number. func (r *ProjectsLocationsJobsExecutionsService) Cancel(name string, googlecloudrunv2cancelexecutionrequest *GoogleCloudRunV2CancelExecutionRequest) *ProjectsLocationsJobsExecutionsCancelCall { c := &ProjectsLocationsJobsExecutionsCancelCall{s: r.s, urlParams_: make(gensupport.URLParams)} c.name = name @@ -5206,7 +5291,7 @@ func (c *ProjectsLocationsJobsExecutionsCancelCall) Do(opts ...googleapi.CallOpt // ], // "parameters": { // "name": { - // "description": "Required. The name of the Execution to cancel. Format: projects/{project}/locations/{location}/jobs/{job}/executions/{execution}, where {project} can be project id or number.", + // "description": "Required. The name of the Execution to cancel. Format: `projects/{project}/locations/{location}/jobs/{job}/executions/{execution}`, where `{project}` can be project id or number.", // "location": "path", // "pattern": "^projects/[^/]+/locations/[^/]+/jobs/[^/]+/executions/[^/]+$", // "required": true, @@ -5240,8 +5325,8 @@ type ProjectsLocationsJobsExecutionsDeleteCall struct { // Delete: Deletes an Execution. // // - name: The name of the Execution to delete. Format: -// projects/{project}/locations/{location}/jobs/{job}/executions/{execu -// tion}, where {project} can be project id or number. +// `projects/{project}/locations/{location}/jobs/{job}/executions/{exec +// ution}`, where `{project}` can be project id or number. func (r *ProjectsLocationsJobsExecutionsService) Delete(name string) *ProjectsLocationsJobsExecutionsDeleteCall { c := &ProjectsLocationsJobsExecutionsDeleteCall{s: r.s, urlParams_: make(gensupport.URLParams)} c.name = name @@ -5364,7 +5449,7 @@ func (c *ProjectsLocationsJobsExecutionsDeleteCall) Do(opts ...googleapi.CallOpt // "type": "string" // }, // "name": { - // "description": "Required. The name of the Execution to delete. Format: projects/{project}/locations/{location}/jobs/{job}/executions/{execution}, where {project} can be project id or number.", + // "description": "Required. The name of the Execution to delete. Format: `projects/{project}/locations/{location}/jobs/{job}/executions/{execution}`, where `{project}` can be project id or number.", // "location": "path", // "pattern": "^projects/[^/]+/locations/[^/]+/jobs/[^/]+/executions/[^/]+$", // "required": true, @@ -5401,8 +5486,8 @@ type ProjectsLocationsJobsExecutionsGetCall struct { // Get: Gets information about an Execution. // // - name: The full name of the Execution. Format: -// projects/{project}/locations/{location}/jobs/{job}/executions/{execu -// tion}, where {project} can be project id or number. +// `projects/{project}/locations/{location}/jobs/{job}/executions/{exec +// ution}`, where `{project}` can be project id or number. func (r *ProjectsLocationsJobsExecutionsService) Get(name string) *ProjectsLocationsJobsExecutionsGetCall { c := &ProjectsLocationsJobsExecutionsGetCall{s: r.s, urlParams_: make(gensupport.URLParams)} c.name = name @@ -5517,7 +5602,7 @@ func (c *ProjectsLocationsJobsExecutionsGetCall) Do(opts ...googleapi.CallOption // ], // "parameters": { // "name": { - // "description": "Required. The full name of the Execution. Format: projects/{project}/locations/{location}/jobs/{job}/executions/{execution}, where {project} can be project id or number.", + // "description": "Required. The full name of the Execution. Format: `projects/{project}/locations/{location}/jobs/{job}/executions/{execution}`, where `{project}` can be project id or number.", // "location": "path", // "pattern": "^projects/[^/]+/locations/[^/]+/jobs/[^/]+/executions/[^/]+$", // "required": true, @@ -5550,8 +5635,8 @@ type ProjectsLocationsJobsExecutionsListCall struct { // // - parent: The Execution from which the Executions should be listed. // To list all Executions across Jobs, use "-" instead of Job name. -// Format: projects/{project}/locations/{location}/jobs/{job}, where -// {project} can be project id or number. +// Format: `projects/{project}/locations/{location}/jobs/{job}`, where +// `{project}` can be project id or number. func (r *ProjectsLocationsJobsExecutionsService) List(parent string) *ProjectsLocationsJobsExecutionsListCall { c := &ProjectsLocationsJobsExecutionsListCall{s: r.s, urlParams_: make(gensupport.URLParams)} c.parent = parent @@ -5700,7 +5785,7 @@ func (c *ProjectsLocationsJobsExecutionsListCall) Do(opts ...googleapi.CallOptio // "type": "string" // }, // "parent": { - // "description": "Required. The Execution from which the Executions should be listed. To list all Executions across Jobs, use \"-\" instead of Job name. Format: projects/{project}/locations/{location}/jobs/{job}, where {project} can be project id or number.", + // "description": "Required. The Execution from which the Executions should be listed. To list all Executions across Jobs, use \"-\" instead of Job name. Format: `projects/{project}/locations/{location}/jobs/{job}`, where `{project}` can be project id or number.", // "location": "path", // "pattern": "^projects/[^/]+/locations/[^/]+/jobs/[^/]+$", // "required": true, diff --git a/tagmanager/v2/tagmanager-api.json b/tagmanager/v2/tagmanager-api.json index b3b2021c464..f35e227c292 100644 --- a/tagmanager/v2/tagmanager-api.json +++ b/tagmanager/v2/tagmanager-api.json @@ -3890,7 +3890,7 @@ } } }, - "revision": "20230906", + "revision": "20230926", "rootUrl": "https://tagmanager.googleapis.com/", "schemas": { "Account": { @@ -4887,6 +4887,10 @@ "description": "A workspace entity that may represent a tag, trigger, variable, or folder in addition to its status in the workspace.", "id": "Entity", "properties": { + "builtInVariable": { + "$ref": "BuiltInVariable", + "description": "The built in variable being represented by the entity." + }, "changeStatus": { "description": "Represents how the entity has been changed in the workspace.", "enum": [ @@ -4909,10 +4913,18 @@ "$ref": "Client", "description": "The client being represented by the entity." }, + "customTemplate": { + "$ref": "CustomTemplate", + "description": "The custom template being represented by the entity." + }, "folder": { "$ref": "Folder", "description": "The folder being represented by the entity." }, + "gtagConfig": { + "$ref": "GtagConfig", + "description": "The gtag config being represented by the entity." + }, "tag": { "$ref": "Tag", "description": "The tag being represented by the entity." @@ -4928,6 +4940,10 @@ "variable": { "$ref": "Variable", "description": "The variable being represented by the entity." + }, + "zone": { + "$ref": "Zone", + "description": "The zone being represented by the entity." } }, "type": "object" diff --git a/tagmanager/v2/tagmanager-gen.go b/tagmanager/v2/tagmanager-gen.go index 6c26751d38c..7ef3be7f949 100644 --- a/tagmanager/v2/tagmanager-gen.go +++ b/tagmanager/v2/tagmanager-gen.go @@ -1453,6 +1453,10 @@ func (s *Destination) MarshalJSON() ([]byte, error) { // Entity: A workspace entity that may represent a tag, trigger, // variable, or folder in addition to its status in the workspace. type Entity struct { + // BuiltInVariable: The built in variable being represented by the + // entity. + BuiltInVariable *BuiltInVariable `json:"builtInVariable,omitempty"` + // ChangeStatus: Represents how the entity has been changed in the // workspace. // @@ -1467,9 +1471,15 @@ type Entity struct { // Client: The client being represented by the entity. Client *Client `json:"client,omitempty"` + // CustomTemplate: The custom template being represented by the entity. + CustomTemplate *CustomTemplate `json:"customTemplate,omitempty"` + // Folder: The folder being represented by the entity. Folder *Folder `json:"folder,omitempty"` + // GtagConfig: The gtag config being represented by the entity. + GtagConfig *GtagConfig `json:"gtagConfig,omitempty"` + // Tag: The tag being represented by the entity. Tag *Tag `json:"tag,omitempty"` @@ -1482,7 +1492,10 @@ type Entity struct { // Variable: The variable being represented by the entity. Variable *Variable `json:"variable,omitempty"` - // ForceSendFields is a list of field names (e.g. "ChangeStatus") to + // Zone: The zone being represented by the entity. + Zone *Zone `json:"zone,omitempty"` + + // ForceSendFields is a list of field names (e.g. "BuiltInVariable") to // unconditionally include in API requests. By default, fields with // empty or default values are omitted from API requests. However, any // non-pointer, non-interface field appearing in ForceSendFields will be @@ -1490,12 +1503,13 @@ type Entity struct { // This may be used to include empty fields in Patch requests. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "ChangeStatus") to include - // in API requests with the JSON null value. By default, fields with - // empty values are omitted from API requests. However, any field with - // an empty value appearing in NullFields will be sent to the server as - // null. It is an error if a field in this list has a non-empty value. - // This may be used to include null fields in Patch requests. + // NullFields is a list of field names (e.g. "BuiltInVariable") to + // include in API requests with the JSON null value. By default, fields + // with empty values are omitted from API requests. However, any field + // with an empty value appearing in NullFields will be sent to the + // server as null. It is an error if a field in this list has a + // non-empty value. This may be used to include null fields in Patch + // requests. NullFields []string `json:"-"` } diff --git a/translate/v3/translate-api.json b/translate/v3/translate-api.json index 5830e53d675..83a1a39614e 100644 --- a/translate/v3/translate-api.json +++ b/translate/v3/translate-api.json @@ -171,8 +171,7 @@ "$ref": "SupportedLanguages" }, "scopes": [ - "https://www.googleapis.com/auth/cloud-platform", - "https://www.googleapis.com/auth/cloud-translation" + "https://www.googleapis.com/auth/cloud-platform" ] }, "romanizeText": { @@ -380,8 +379,7 @@ "$ref": "SupportedLanguages" }, "scopes": [ - "https://www.googleapis.com/auth/cloud-platform", - "https://www.googleapis.com/auth/cloud-translation" + "https://www.googleapis.com/auth/cloud-platform" ] }, "list": { @@ -795,8 +793,7 @@ "$ref": "Operation" }, "scopes": [ - "https://www.googleapis.com/auth/cloud-platform", - "https://www.googleapis.com/auth/cloud-translation" + "https://www.googleapis.com/auth/cloud-platform" ] }, "get": { @@ -821,8 +818,7 @@ "$ref": "Glossary" }, "scopes": [ - "https://www.googleapis.com/auth/cloud-platform", - "https://www.googleapis.com/auth/cloud-translation" + "https://www.googleapis.com/auth/cloud-platform" ] }, "list": { @@ -863,8 +859,7 @@ "$ref": "ListGlossariesResponse" }, "scopes": [ - "https://www.googleapis.com/auth/cloud-platform", - "https://www.googleapis.com/auth/cloud-translation" + "https://www.googleapis.com/auth/cloud-platform" ] }, "patch": { @@ -982,8 +977,7 @@ "$ref": "GlossaryEntry" }, "scopes": [ - "https://www.googleapis.com/auth/cloud-platform", - "https://www.googleapis.com/auth/cloud-translation" + "https://www.googleapis.com/auth/cloud-platform" ] }, "list": { @@ -1019,8 +1013,7 @@ "$ref": "ListGlossaryEntriesResponse" }, "scopes": [ - "https://www.googleapis.com/auth/cloud-platform", - "https://www.googleapis.com/auth/cloud-translation" + "https://www.googleapis.com/auth/cloud-platform" ] }, "patch": { @@ -1344,7 +1337,7 @@ } } }, - "revision": "20230808", + "revision": "20230922", "rootUrl": "https://translation.googleapis.com/", "schemas": { "BatchDocumentInputConfig": { @@ -1389,7 +1382,7 @@ "additionalProperties": { "type": "string" }, - "description": "Optional.", + "description": "Optional. The file format conversion map that is applied to all input files. The map key is the original mime_type. The map value is the target mime_type of translated documents. Supported file format conversion includes: - `application/pdf` to `application/vnd.openxmlformats-officedocument.wordprocessingml.document` If nothing specified, output files will be in the same format as the original file.", "type": "object" }, "glossaries": { diff --git a/translate/v3/translate-gen.go b/translate/v3/translate-gen.go index 1d33cc5f72e..e78fee2fe6f 100644 --- a/translate/v3/translate-gen.go +++ b/translate/v3/translate-gen.go @@ -384,7 +384,13 @@ type BatchTranslateDocumentRequest struct { // is_translate_native_pdf_only: false && pdf_native_only: false EnableShadowRemovalNativePdf bool `json:"enableShadowRemovalNativePdf,omitempty"` - // FormatConversions: Optional. + // FormatConversions: Optional. The file format conversion map that is + // applied to all input files. The map key is the original mime_type. + // The map value is the target mime_type of translated documents. + // Supported file format conversion includes: - `application/pdf` to + // `application/vnd.openxmlformats-officedocument.wordprocessingml.docume + // nt` If nothing specified, output files will be in the same format as + // the original file. FormatConversions map[string]string `json:"formatConversions,omitempty"` // Glossaries: Optional. Glossaries to be applied. It's keyed by target @@ -3042,8 +3048,7 @@ func (c *ProjectsGetSupportedLanguagesCall) Do(opts ...googleapi.CallOption) (*S // "$ref": "SupportedLanguages" // }, // "scopes": [ - // "https://www.googleapis.com/auth/cloud-platform", - // "https://www.googleapis.com/auth/cloud-translation" + // "https://www.googleapis.com/auth/cloud-platform" // ] // } @@ -4133,8 +4138,7 @@ func (c *ProjectsLocationsGetSupportedLanguagesCall) Do(opts ...googleapi.CallOp // "$ref": "SupportedLanguages" // }, // "scopes": [ - // "https://www.googleapis.com/auth/cloud-platform", - // "https://www.googleapis.com/auth/cloud-translation" + // "https://www.googleapis.com/auth/cloud-platform" // ] // } @@ -6191,8 +6195,7 @@ func (c *ProjectsLocationsGlossariesDeleteCall) Do(opts ...googleapi.CallOption) // "$ref": "Operation" // }, // "scopes": [ - // "https://www.googleapis.com/auth/cloud-platform", - // "https://www.googleapis.com/auth/cloud-translation" + // "https://www.googleapis.com/auth/cloud-platform" // ] // } @@ -6339,8 +6342,7 @@ func (c *ProjectsLocationsGlossariesGetCall) Do(opts ...googleapi.CallOption) (* // "$ref": "Glossary" // }, // "scopes": [ - // "https://www.googleapis.com/auth/cloud-platform", - // "https://www.googleapis.com/auth/cloud-translation" + // "https://www.googleapis.com/auth/cloud-platform" // ] // } @@ -6543,8 +6545,7 @@ func (c *ProjectsLocationsGlossariesListCall) Do(opts ...googleapi.CallOption) ( // "$ref": "ListGlossariesResponse" // }, // "scopes": [ - // "https://www.googleapis.com/auth/cloud-platform", - // "https://www.googleapis.com/auth/cloud-translation" + // "https://www.googleapis.com/auth/cloud-platform" // ] // } @@ -7148,8 +7149,7 @@ func (c *ProjectsLocationsGlossariesGlossaryEntriesGetCall) Do(opts ...googleapi // "$ref": "GlossaryEntry" // }, // "scopes": [ - // "https://www.googleapis.com/auth/cloud-platform", - // "https://www.googleapis.com/auth/cloud-translation" + // "https://www.googleapis.com/auth/cloud-platform" // ] // } @@ -7325,8 +7325,7 @@ func (c *ProjectsLocationsGlossariesGlossaryEntriesListCall) Do(opts ...googleap // "$ref": "ListGlossaryEntriesResponse" // }, // "scopes": [ - // "https://www.googleapis.com/auth/cloud-platform", - // "https://www.googleapis.com/auth/cloud-translation" + // "https://www.googleapis.com/auth/cloud-platform" // ] // } diff --git a/translate/v3beta1/translate-api.json b/translate/v3beta1/translate-api.json index 0d45dcdb507..1cc859cc5f5 100644 --- a/translate/v3beta1/translate-api.json +++ b/translate/v3beta1/translate-api.json @@ -744,7 +744,7 @@ } } }, - "revision": "20230808", + "revision": "20230922", "rootUrl": "https://translation.googleapis.com/", "schemas": { "BatchDocumentInputConfig": { @@ -789,7 +789,7 @@ "additionalProperties": { "type": "string" }, - "description": "Optional.", + "description": "Optional. File format conversion map to be applied to all input files. Map's key is the original mime_type. Map's value is the target mime_type of translated documents. Supported file format conversion includes: - `application/pdf` to `application/vnd.openxmlformats-officedocument.wordprocessingml.document` If nothing specified, output files will be in the same format as the original file.", "type": "object" }, "glossaries": { diff --git a/translate/v3beta1/translate-gen.go b/translate/v3beta1/translate-gen.go index 888d0310289..6cb8e4db140 100644 --- a/translate/v3beta1/translate-gen.go +++ b/translate/v3beta1/translate-gen.go @@ -336,7 +336,13 @@ type BatchTranslateDocumentRequest struct { // is_translate_native_pdf_only: false && pdf_native_only: false EnableShadowRemovalNativePdf bool `json:"enableShadowRemovalNativePdf,omitempty"` - // FormatConversions: Optional. + // FormatConversions: Optional. File format conversion map to be applied + // to all input files. Map's key is the original mime_type. Map's value + // is the target mime_type of translated documents. Supported file + // format conversion includes: - `application/pdf` to + // `application/vnd.openxmlformats-officedocument.wordprocessingml.docume + // nt` If nothing specified, output files will be in the same format as + // the original file. FormatConversions map[string]string `json:"formatConversions,omitempty"` // Glossaries: Optional. Glossaries to be applied. It's keyed by target