From e88ee8ac45e49f73b275bce6924180c0f184f277 Mon Sep 17 00:00:00 2001 From: Yoshi Automation Bot Date: Tue, 7 Mar 2023 07:54:26 -0800 Subject: [PATCH] feat(all): auto-regenerate discovery clients (#1893) --- accessapproval/v1/accessapproval-api.json | 4 +- accessapproval/v1/accessapproval-gen.go | 21 +- .../v1alpha/analyticsadmin-api.json | 108 +- analyticsadmin/v1alpha/analyticsadmin-gen.go | 450 +- .../v1/androiddeviceprovisioning-api.json | 9 +- .../v1/androiddeviceprovisioning-gen.go | 7 +- api-list.json | 21 +- chat/v1/chat-api.json | 12 +- chat/v1/chat-gen.go | 37 +- chromepolicy/v1/chromepolicy-api.json | 8 +- chromepolicy/v1/chromepolicy-gen.go | 13 +- cloudasset/v1/cloudasset-api.json | 14 +- cloudasset/v1/cloudasset-gen.go | 24 +- cloudchannel/v1/cloudchannel-api.json | 4 +- cloudchannel/v1/cloudchannel-gen.go | 11 +- cloudsearch/v1/cloudsearch-api.json | 94 +- cloudsearch/v1/cloudsearch-gen.go | 104 +- cloudtasks/v2beta2/cloudtasks-api.json | 20 +- cloudtasks/v2beta2/cloudtasks-gen.go | 42 +- cloudtasks/v2beta3/cloudtasks-api.json | 20 +- cloudtasks/v2beta3/cloudtasks-gen.go | 44 +- .../v1/contactcenterinsights-api.json | 42 +- .../v1/contactcenterinsights-gen.go | 78 +- datastore/v1/datastore-api.json | 8 +- datastore/v1/datastore-gen.go | 2 + datastore/v1beta3/datastore-api.json | 8 +- datastore/v1beta3/datastore-gen.go | 2 + .../v1alpha/discoveryengine-api.json | 445 +- .../v1alpha/discoveryengine-gen.go | 2242 ++++- .../v1beta/discoveryengine-api.json | 445 +- discoveryengine/v1beta/discoveryengine-gen.go | 2242 ++++- firebasehosting/v1/firebasehosting-api.json | 4 +- firebasehosting/v1/firebasehosting-gen.go | 11 +- firestore/v1/firestore-api.json | 23 +- firestore/v1/firestore-gen.go | 44 +- firestore/v1beta1/firestore-api.json | 16 +- firestore/v1beta1/firestore-gen.go | 23 +- metastore/v1/metastore-api.json | 68 +- metastore/v1/metastore-gen.go | 122 +- metastore/v1alpha/metastore-api.json | 38 +- metastore/v1alpha/metastore-gen.go | 62 + metastore/v1beta/metastore-api.json | 38 +- metastore/v1beta/metastore-gen.go | 62 + .../v1alpha1/migrationcenter-api.json | 3079 +++++++ .../v1alpha1/migrationcenter-gen.go | 7790 +++++++++++++++++ .../v1/networkmanagement-api.json | 10 +- networkmanagement/v1/networkmanagement-gen.go | 5 + .../v1beta1/networkmanagement-api.json | 8 +- .../v1beta1/networkmanagement-gen.go | 2 + orgpolicy/v2/orgpolicy-api.json | 6 +- orgpolicy/v2/orgpolicy-gen.go | 4 + .../v1alpha1/playdeveloperreporting-api.json | 66 +- .../v1alpha1/playdeveloperreporting-gen.go | 88 + .../v1beta1/playdeveloperreporting-api.json | 66 +- .../v1beta1/playdeveloperreporting-gen.go | 88 + securitycenter/v1/securitycenter-api.json | 4 +- securitycenter/v1/securitycenter-gen.go | 11 +- .../v1beta1/securitycenter-api.json | 4 +- securitycenter/v1beta1/securitycenter-gen.go | 11 +- .../v1/serviceconsumermanagement-api.json | 4 +- .../v1/serviceconsumermanagement-gen.go | 11 +- .../v1/servicenetworking-api.json | 4 +- servicenetworking/v1/servicenetworking-gen.go | 11 +- serviceusage/v1/serviceusage-api.json | 4 +- serviceusage/v1/serviceusage-gen.go | 11 +- serviceusage/v1beta1/serviceusage-api.json | 4 +- serviceusage/v1beta1/serviceusage-gen.go | 11 +- storage/v1/storage-api.json | 9 +- storage/v1/storage-gen.go | 12 + webrisk/v1/webrisk-api.json | 105 +- webrisk/v1/webrisk-gen.go | 273 +- 71 files changed, 16874 insertions(+), 1919 deletions(-) create mode 100644 migrationcenter/v1alpha1/migrationcenter-api.json create mode 100644 migrationcenter/v1alpha1/migrationcenter-gen.go diff --git a/accessapproval/v1/accessapproval-api.json b/accessapproval/v1/accessapproval-api.json index 9ad100a3cd0..c3ffe1650d4 100644 --- a/accessapproval/v1/accessapproval-api.json +++ b/accessapproval/v1/accessapproval-api.json @@ -913,7 +913,7 @@ } } }, - "revision": "20230224", + "revision": "20230303", "rootUrl": "https://accessapproval.googleapis.com/", "schemas": { "AccessApprovalServiceAccount": { @@ -1140,7 +1140,7 @@ "id": "EnrolledService", "properties": { "cloudProduct": { - "description": "The product for which Access Approval will be enrolled. Allowed values are listed below (case-sensitive): * all * GA * App Engine * Artifact Registry * BigQuery * Cloud Bigtable * Cloud Key Management Service * Compute Engine * Cloud Composer * Cloud Dataflow * Cloud Dataproc * Cloud DLP * Cloud EKM * Cloud HSM * Cloud Identity and Access Management * Cloud Logging * Cloud NAT * Cloud Pub/Sub * Cloud Spanner * Cloud SQL * Cloud Storage * Google Kubernetes Engine * Organization Policy Serivice * Persistent Disk * Resource Manager * Secret Manager * Speaker ID Note: These values are supported as input for legacy purposes, but will not be returned from the API. * all * ga-only * appengine.googleapis.com * artifactregistry.googleapis.com * bigquery.googleapis.com * bigtable.googleapis.com * container.googleapis.com * cloudkms.googleapis.com * cloudresourcemanager.googleapis.com * cloudsql.googleapis.com * compute.googleapis.com * dataflow.googleapis.com * dataproc.googleapis.com * dlp.googleapis.com * iam.googleapis.com * logging.googleapis.com * orgpolicy.googleapis.com * pubsub.googleapis.com * spanner.googleapis.com * secretmanager.googleapis.com * speakerid.googleapis.com * storage.googleapis.com Calls to UpdateAccessApprovalSettings using 'all' or any of the XXX.googleapis.com will be translated to the associated product name ('all', 'App Engine', etc.). Note: 'all' will enroll the resource in all products supported at both 'GA' and 'Preview' levels. More information about levels of support is available at https://cloud.google.com/access-approval/docs/supported-services", + "description": "The product for which Access Approval will be enrolled. Allowed values are listed below (case-sensitive): * all * GA * App Engine * Artifact Registry * BigQuery * Certificate Authority Service * Cloud Bigtable * Cloud Key Management Service * Compute Engine * Cloud Composer * Cloud Dataflow * Cloud Dataproc * Cloud DLP * Cloud EKM * Cloud HSM * Cloud Identity and Access Management * Cloud Logging * Cloud NAT * Cloud Pub/Sub * Cloud Spanner * Cloud SQL * Cloud Storage * Google Kubernetes Engine * Organization Policy Serivice * Persistent Disk * Resource Manager * Secret Manager * Speaker ID Note: These values are supported as input for legacy purposes, but will not be returned from the API. * all * ga-only * appengine.googleapis.com * artifactregistry.googleapis.com * bigquery.googleapis.com * bigtable.googleapis.com * container.googleapis.com * cloudkms.googleapis.com * cloudresourcemanager.googleapis.com * cloudsql.googleapis.com * compute.googleapis.com * dataflow.googleapis.com * dataproc.googleapis.com * dlp.googleapis.com * iam.googleapis.com * logging.googleapis.com * orgpolicy.googleapis.com * pubsub.googleapis.com * spanner.googleapis.com * secretmanager.googleapis.com * speakerid.googleapis.com * storage.googleapis.com Calls to UpdateAccessApprovalSettings using 'all' or any of the XXX.googleapis.com will be translated to the associated product name ('all', 'App Engine', etc.). Note: 'all' will enroll the resource in all products supported at both 'GA' and 'Preview' levels. More information about levels of support is available at https://cloud.google.com/access-approval/docs/supported-services", "type": "string" }, "enrollmentLevel": { diff --git a/accessapproval/v1/accessapproval-gen.go b/accessapproval/v1/accessapproval-gen.go index 7619fa53307..3b85168ad20 100644 --- a/accessapproval/v1/accessapproval-gen.go +++ b/accessapproval/v1/accessapproval-gen.go @@ -626,16 +626,17 @@ type Empty struct { type EnrolledService struct { // CloudProduct: The product for which Access Approval will be enrolled. // Allowed values are listed below (case-sensitive): * all * GA * App - // Engine * Artifact Registry * BigQuery * Cloud Bigtable * Cloud Key - // Management Service * Compute Engine * Cloud Composer * Cloud Dataflow - // * Cloud Dataproc * Cloud DLP * Cloud EKM * Cloud HSM * Cloud Identity - // and Access Management * Cloud Logging * Cloud NAT * Cloud Pub/Sub * - // Cloud Spanner * Cloud SQL * Cloud Storage * Google Kubernetes Engine - // * Organization Policy Serivice * Persistent Disk * Resource Manager * - // Secret Manager * Speaker ID Note: These values are supported as input - // for legacy purposes, but will not be returned from the API. * all * - // ga-only * appengine.googleapis.com * artifactregistry.googleapis.com - // * bigquery.googleapis.com * bigtable.googleapis.com * + // Engine * Artifact Registry * BigQuery * Certificate Authority Service + // * Cloud Bigtable * Cloud Key Management Service * Compute Engine * + // Cloud Composer * Cloud Dataflow * Cloud Dataproc * Cloud DLP * Cloud + // EKM * Cloud HSM * Cloud Identity and Access Management * Cloud + // Logging * Cloud NAT * Cloud Pub/Sub * Cloud Spanner * Cloud SQL * + // Cloud Storage * Google Kubernetes Engine * Organization Policy + // Serivice * Persistent Disk * Resource Manager * Secret Manager * + // Speaker ID Note: These values are supported as input for legacy + // purposes, but will not be returned from the API. * all * ga-only * + // appengine.googleapis.com * artifactregistry.googleapis.com * + // bigquery.googleapis.com * bigtable.googleapis.com * // container.googleapis.com * cloudkms.googleapis.com * // cloudresourcemanager.googleapis.com * cloudsql.googleapis.com * // compute.googleapis.com * dataflow.googleapis.com * diff --git a/analyticsadmin/v1alpha/analyticsadmin-api.json b/analyticsadmin/v1alpha/analyticsadmin-api.json index 30e6e91508d..6aa1d809a2a 100644 --- a/analyticsadmin/v1alpha/analyticsadmin-api.json +++ b/analyticsadmin/v1alpha/analyticsadmin-api.json @@ -409,7 +409,7 @@ ], "parameters": { "parent": { - "description": "Required. The account or property that owns the access bindings. The parent field in the DeleteAccessBindingRequest messages must either be empty or match this field. Formats: - accounts/{account} - properties/{property}", + "description": "Required. The account or property that owns the access bindings. The parent of all provided values for the 'names' field in DeleteAccessBindingRequest messages must match this field. Formats: - accounts/{account} - properties/{property}", "location": "path", "pattern": "^accounts/[^/]+$", "required": true, @@ -469,7 +469,7 @@ ], "parameters": { "parent": { - "description": "Required. The account or property that owns the access bindings. The parent field in the UpdateAccessBindingRequest messages must either be empty or match this field. Formats: - accounts/{account} - properties/{property}", + "description": "Required. The account or property that owns the access bindings. The parent of all provided AccessBinding in UpdateAccessBindingRequest messages must match this field. Formats: - accounts/{account} - properties/{property}", "location": "path", "pattern": "^accounts/[^/]+$", "required": true, @@ -1006,21 +1006,6 @@ "https://www.googleapis.com/auth/analytics.edit" ] }, - "deleteConnectedSiteTag": { - "description": "Deletes a connected site tag for a Universal Analytics property. Note: this has no effect on GA4 properties.", - "flatPath": "v1alpha/properties:deleteConnectedSiteTag", - "httpMethod": "POST", - "id": "analyticsadmin.properties.deleteConnectedSiteTag", - "parameterOrder": [], - "parameters": {}, - "path": "v1alpha/properties:deleteConnectedSiteTag", - "request": { - "$ref": "GoogleAnalyticsAdminV1alphaDeleteConnectedSiteTagRequest" - }, - "response": { - "$ref": "GoogleProtobufEmpty" - } - }, "fetchAutomatedGa4ConfigurationOptOut": { "description": "Fetches the opt out status for the automated GA4 setup process for a UA property. Note: this has no effect on GA4 property.", "flatPath": "v1alpha/properties:fetchAutomatedGa4ConfigurationOptOut", @@ -1182,21 +1167,6 @@ "https://www.googleapis.com/auth/analytics.readonly" ] }, - "listConnectedSiteTags": { - "description": "Lists the connected site tags for a Universal Analytics property. Note: this has no effect on GA4 property.", - "flatPath": "v1alpha/properties:listConnectedSiteTags", - "httpMethod": "POST", - "id": "analyticsadmin.properties.listConnectedSiteTags", - "parameterOrder": [], - "parameters": {}, - "path": "v1alpha/properties:listConnectedSiteTags", - "request": { - "$ref": "GoogleAnalyticsAdminV1alphaListConnectedSiteTagsRequest" - }, - "response": { - "$ref": "GoogleAnalyticsAdminV1alphaListConnectedSiteTagsResponse" - } - }, "patch": { "description": "Updates a property.", "flatPath": "v1alpha/properties/{propertiesId}", @@ -1422,7 +1392,7 @@ ], "parameters": { "parent": { - "description": "Required. The account or property that owns the access bindings. The parent field in the DeleteAccessBindingRequest messages must either be empty or match this field. Formats: - accounts/{account} - properties/{property}", + "description": "Required. The account or property that owns the access bindings. The parent of all provided values for the 'names' field in DeleteAccessBindingRequest messages must match this field. Formats: - accounts/{account} - properties/{property}", "location": "path", "pattern": "^properties/[^/]+$", "required": true, @@ -1482,7 +1452,7 @@ ], "parameters": { "parent": { - "description": "Required. The account or property that owns the access bindings. The parent field in the UpdateAccessBindingRequest messages must either be empty or match this field. Formats: - accounts/{account} - properties/{property}", + "description": "Required. The account or property that owns the access bindings. The parent of all provided AccessBinding in UpdateAccessBindingRequest messages must match this field. Formats: - accounts/{account} - properties/{property}", "location": "path", "pattern": "^properties/[^/]+$", "required": true, @@ -3801,7 +3771,7 @@ } } }, - "revision": "20230302", + "revision": "20230304", "rootUrl": "https://analyticsadmin.googleapis.com/", "schemas": { "GoogleAnalyticsAdminV1alphaAccessBetweenFilter": { @@ -5237,21 +5207,6 @@ }, "type": "object" }, - "GoogleAnalyticsAdminV1alphaConnectedSiteTag": { - "description": "Configuration for a specific Connected Site Tag.", - "id": "GoogleAnalyticsAdminV1alphaConnectedSiteTag", - "properties": { - "displayName": { - "description": "Required. User-provided display name for the connected site tag. Must be less than 256 characters.", - "type": "string" - }, - "tagId": { - "description": "Required. \"Tag ID to forward events to. Also known as the Measurement ID, or the \"G-ID\" (For example: G-12345).", - "type": "string" - } - }, - "type": "object" - }, "GoogleAnalyticsAdminV1alphaConversionEvent": { "description": "A conversion event in a Google Analytics property.", "id": "GoogleAnalyticsAdminV1alphaConversionEvent", @@ -5631,21 +5586,6 @@ }, "type": "object" }, - "GoogleAnalyticsAdminV1alphaDeleteConnectedSiteTagRequest": { - "description": "Request message for DeleteConnectedSiteTag RPC.", - "id": "GoogleAnalyticsAdminV1alphaDeleteConnectedSiteTagRequest", - "properties": { - "property": { - "description": "The Universal Analytics property to delete connected site tags for. This API does not support GA4 properties. Format: properties/{universalAnalyticsPropertyId} Example: properties/1234", - "type": "string" - }, - "tagId": { - "description": "Tag ID to forward events to. Also known as the Measurement ID, or the \"G-ID\" (For example: G-12345).", - "type": "string" - } - }, - "type": "object" - }, "GoogleAnalyticsAdminV1alphaDeleteUserLinkRequest": { "description": "Request message for DeleteUserLink RPC.", "id": "GoogleAnalyticsAdminV1alphaDeleteUserLinkRequest", @@ -6158,44 +6098,6 @@ }, "type": "object" }, - "GoogleAnalyticsAdminV1alphaListConnectedSiteTagsRequest": { - "description": "Request message for ListConnectedSiteTags RPC.", - "id": "GoogleAnalyticsAdminV1alphaListConnectedSiteTagsRequest", - "properties": { - "pageSize": { - "description": "The maximum number of resources to return. The service may return fewer than this value, even if there are additional pages. If unspecified, at most 50 resources will be returned. The maximum value is 200; (higher values will be coerced to the maximum)", - "format": "int32", - "type": "integer" - }, - "pageToken": { - "description": "A page token, received from a previous `ListConnectedSiteTags` call. Provide this to retrieve the subsequent page. When paginating, all other parameters provided to `ListConnectedSiteTags` must match the call that provided the page token.", - "type": "string" - }, - "property": { - "description": "The Universal Analytics property to fetch connected site tags for. This does not work on GA4 properties. Format: `properties/1234`", - "type": "string" - } - }, - "type": "object" - }, - "GoogleAnalyticsAdminV1alphaListConnectedSiteTagsResponse": { - "description": "Response message for ListConnectedSiteTags RPC.", - "id": "GoogleAnalyticsAdminV1alphaListConnectedSiteTagsResponse", - "properties": { - "connectedSiteTags": { - "description": "The site tags for the Universal Analytics property", - "items": { - "$ref": "GoogleAnalyticsAdminV1alphaConnectedSiteTag" - }, - "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" - } - }, - "type": "object" - }, "GoogleAnalyticsAdminV1alphaListConversionEventsResponse": { "description": "Response message for ListConversionEvents RPC.", "id": "GoogleAnalyticsAdminV1alphaListConversionEventsResponse", diff --git a/analyticsadmin/v1alpha/analyticsadmin-gen.go b/analyticsadmin/v1alpha/analyticsadmin-gen.go index 930b25a2889..f99e332f099 100644 --- a/analyticsadmin/v1alpha/analyticsadmin-gen.go +++ b/analyticsadmin/v1alpha/analyticsadmin-gen.go @@ -2941,40 +2941,6 @@ func (s *GoogleAnalyticsAdminV1alphaChangeHistoryEvent) MarshalJSON() ([]byte, e return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } -// GoogleAnalyticsAdminV1alphaConnectedSiteTag: Configuration for a -// specific Connected Site Tag. -type GoogleAnalyticsAdminV1alphaConnectedSiteTag struct { - // DisplayName: Required. User-provided display name for the connected - // site tag. Must be less than 256 characters. - DisplayName string `json:"displayName,omitempty"` - - // TagId: Required. "Tag ID to forward events to. Also known as the - // Measurement ID, or the "G-ID" (For example: G-12345). - TagId string `json:"tagId,omitempty"` - - // ForceSendFields is a list of field names (e.g. "DisplayName") 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. "DisplayName") 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 *GoogleAnalyticsAdminV1alphaConnectedSiteTag) MarshalJSON() ([]byte, error) { - type NoMethod GoogleAnalyticsAdminV1alphaConnectedSiteTag - raw := NoMethod(*s) - return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) -} - // GoogleAnalyticsAdminV1alphaConversionEvent: A conversion event in a // Google Analytics property. type GoogleAnalyticsAdminV1alphaConversionEvent struct { @@ -3582,41 +3548,6 @@ func (s *GoogleAnalyticsAdminV1alphaDeleteAccessBindingRequest) MarshalJSON() ([ return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } -// GoogleAnalyticsAdminV1alphaDeleteConnectedSiteTagRequest: Request -// message for DeleteConnectedSiteTag RPC. -type GoogleAnalyticsAdminV1alphaDeleteConnectedSiteTagRequest struct { - // Property: The Universal Analytics property to delete connected site - // tags for. This API does not support GA4 properties. Format: - // properties/{universalAnalyticsPropertyId} Example: properties/1234 - Property string `json:"property,omitempty"` - - // TagId: Tag ID to forward events to. Also known as the Measurement ID, - // or the "G-ID" (For example: G-12345). - TagId string `json:"tagId,omitempty"` - - // ForceSendFields is a list of field names (e.g. "Property") 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. "Property") 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 *GoogleAnalyticsAdminV1alphaDeleteConnectedSiteTagRequest) MarshalJSON() ([]byte, error) { - type NoMethod GoogleAnalyticsAdminV1alphaDeleteConnectedSiteTagRequest - raw := NoMethod(*s) - return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) -} - // GoogleAnalyticsAdminV1alphaDeleteUserLinkRequest: Request message for // DeleteUserLink RPC. type GoogleAnalyticsAdminV1alphaDeleteUserLinkRequest struct { @@ -4579,89 +4510,6 @@ func (s *GoogleAnalyticsAdminV1alphaListBigQueryLinksResponse) MarshalJSON() ([] return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } -// GoogleAnalyticsAdminV1alphaListConnectedSiteTagsRequest: Request -// message for ListConnectedSiteTags RPC. -type GoogleAnalyticsAdminV1alphaListConnectedSiteTagsRequest struct { - // PageSize: The maximum number of resources to return. The service may - // return fewer than this value, even if there are additional pages. If - // unspecified, at most 50 resources will be returned. The maximum value - // is 200; (higher values will be coerced to the maximum) - PageSize int64 `json:"pageSize,omitempty"` - - // PageToken: A page token, received from a previous - // `ListConnectedSiteTags` call. Provide this to retrieve the subsequent - // page. When paginating, all other parameters provided to - // `ListConnectedSiteTags` must match the call that provided the page - // token. - PageToken string `json:"pageToken,omitempty"` - - // Property: The Universal Analytics property to fetch connected site - // tags for. This does not work on GA4 properties. Format: - // `properties/1234` - Property string `json:"property,omitempty"` - - // ForceSendFields is a list of field names (e.g. "PageSize") 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. "PageSize") 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 *GoogleAnalyticsAdminV1alphaListConnectedSiteTagsRequest) MarshalJSON() ([]byte, error) { - type NoMethod GoogleAnalyticsAdminV1alphaListConnectedSiteTagsRequest - raw := NoMethod(*s) - return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) -} - -// GoogleAnalyticsAdminV1alphaListConnectedSiteTagsResponse: Response -// message for ListConnectedSiteTags RPC. -type GoogleAnalyticsAdminV1alphaListConnectedSiteTagsResponse struct { - // ConnectedSiteTags: The site tags for the Universal Analytics property - ConnectedSiteTags []*GoogleAnalyticsAdminV1alphaConnectedSiteTag `json:"connectedSiteTags,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"` - - // ServerResponse contains the HTTP response code and headers from the - // server. - googleapi.ServerResponse `json:"-"` - - // ForceSendFields is a list of field names (e.g. "ConnectedSiteTags") - // 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. "ConnectedSiteTags") 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 *GoogleAnalyticsAdminV1alphaListConnectedSiteTagsResponse) MarshalJSON() ([]byte, error) { - type NoMethod GoogleAnalyticsAdminV1alphaListConnectedSiteTagsResponse - raw := NoMethod(*s) - return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) -} - // GoogleAnalyticsAdminV1alphaListConversionEventsResponse: Response // message for ListConversionEvents RPC. type GoogleAnalyticsAdminV1alphaListConversionEventsResponse struct { @@ -7644,9 +7492,9 @@ type AccountsAccessBindingsBatchDeleteCall struct { // account or property. // // - parent: The account or property that owns the access bindings. The -// parent field in the DeleteAccessBindingRequest messages must either -// be empty or match this field. Formats: - accounts/{account} - -// properties/{property}. +// parent of all provided values for the 'names' field in +// DeleteAccessBindingRequest messages must match this field. Formats: +// - accounts/{account} - properties/{property}. func (r *AccountsAccessBindingsService) BatchDelete(parent string, googleanalyticsadminv1alphabatchdeleteaccessbindingsrequest *GoogleAnalyticsAdminV1alphaBatchDeleteAccessBindingsRequest) *AccountsAccessBindingsBatchDeleteCall { c := &AccountsAccessBindingsBatchDeleteCall{s: r.s, urlParams_: make(gensupport.URLParams)} c.parent = parent @@ -7754,7 +7602,7 @@ func (c *AccountsAccessBindingsBatchDeleteCall) Do(opts ...googleapi.CallOption) // ], // "parameters": { // "parent": { - // "description": "Required. The account or property that owns the access bindings. The parent field in the DeleteAccessBindingRequest messages must either be empty or match this field. Formats: - accounts/{account} - properties/{property}", + // "description": "Required. The account or property that owns the access bindings. The parent of all provided values for the 'names' field in DeleteAccessBindingRequest messages must match this field. Formats: - accounts/{account} - properties/{property}", // "location": "path", // "pattern": "^accounts/[^/]+$", // "required": true, @@ -7959,8 +7807,8 @@ type AccountsAccessBindingsBatchUpdateCall struct { // account or property. // // - parent: The account or property that owns the access bindings. The -// parent field in the UpdateAccessBindingRequest messages must either -// be empty or match this field. Formats: - accounts/{account} - +// parent of all provided AccessBinding in UpdateAccessBindingRequest +// messages must match this field. Formats: - accounts/{account} - // properties/{property}. func (r *AccountsAccessBindingsService) BatchUpdate(parent string, googleanalyticsadminv1alphabatchupdateaccessbindingsrequest *GoogleAnalyticsAdminV1alphaBatchUpdateAccessBindingsRequest) *AccountsAccessBindingsBatchUpdateCall { c := &AccountsAccessBindingsBatchUpdateCall{s: r.s, urlParams_: make(gensupport.URLParams)} @@ -8072,7 +7920,7 @@ func (c *AccountsAccessBindingsBatchUpdateCall) Do(opts ...googleapi.CallOption) // ], // "parameters": { // "parent": { - // "description": "Required. The account or property that owns the access bindings. The parent field in the UpdateAccessBindingRequest messages must either be empty or match this field. Formats: - accounts/{account} - properties/{property}", + // "description": "Required. The account or property that owns the access bindings. The parent of all provided AccessBinding in UpdateAccessBindingRequest messages must match this field. Formats: - accounts/{account} - properties/{property}", // "location": "path", // "pattern": "^accounts/[^/]+$", // "required": true, @@ -10849,129 +10697,6 @@ func (c *PropertiesDeleteCall) Do(opts ...googleapi.CallOption) (*GoogleAnalytic } -// method id "analyticsadmin.properties.deleteConnectedSiteTag": - -type PropertiesDeleteConnectedSiteTagCall struct { - s *Service - googleanalyticsadminv1alphadeleteconnectedsitetagrequest *GoogleAnalyticsAdminV1alphaDeleteConnectedSiteTagRequest - urlParams_ gensupport.URLParams - ctx_ context.Context - header_ http.Header -} - -// DeleteConnectedSiteTag: Deletes a connected site tag for a Universal -// Analytics property. Note: this has no effect on GA4 properties. -func (r *PropertiesService) DeleteConnectedSiteTag(googleanalyticsadminv1alphadeleteconnectedsitetagrequest *GoogleAnalyticsAdminV1alphaDeleteConnectedSiteTagRequest) *PropertiesDeleteConnectedSiteTagCall { - c := &PropertiesDeleteConnectedSiteTagCall{s: r.s, urlParams_: make(gensupport.URLParams)} - c.googleanalyticsadminv1alphadeleteconnectedsitetagrequest = googleanalyticsadminv1alphadeleteconnectedsitetagrequest - 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 *PropertiesDeleteConnectedSiteTagCall) Fields(s ...googleapi.Field) *PropertiesDeleteConnectedSiteTagCall { - 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 *PropertiesDeleteConnectedSiteTagCall) Context(ctx context.Context) *PropertiesDeleteConnectedSiteTagCall { - 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 *PropertiesDeleteConnectedSiteTagCall) Header() http.Header { - if c.header_ == nil { - c.header_ = make(http.Header) - } - return c.header_ -} - -func (c *PropertiesDeleteConnectedSiteTagCall) 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.googleanalyticsadminv1alphadeleteconnectedsitetagrequest) - 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/properties:deleteConnectedSiteTag") - urls += "?" + c.urlParams_.Encode() - req, err := http.NewRequest("POST", urls, body) - if err != nil { - return nil, err - } - req.Header = reqHeaders - return gensupport.SendRequest(c.ctx_, c.s.client, req) -} - -// Do executes the "analyticsadmin.properties.deleteConnectedSiteTag" 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 *PropertiesDeleteConnectedSiteTagCall) 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 connected site tag for a Universal Analytics property. Note: this has no effect on GA4 properties.", - // "flatPath": "v1alpha/properties:deleteConnectedSiteTag", - // "httpMethod": "POST", - // "id": "analyticsadmin.properties.deleteConnectedSiteTag", - // "parameterOrder": [], - // "parameters": {}, - // "path": "v1alpha/properties:deleteConnectedSiteTag", - // "request": { - // "$ref": "GoogleAnalyticsAdminV1alphaDeleteConnectedSiteTagRequest" - // }, - // "response": { - // "$ref": "GoogleProtobufEmpty" - // } - // } - -} - // method id "analyticsadmin.properties.fetchAutomatedGa4ConfigurationOptOut": type PropertiesFetchAutomatedGa4ConfigurationOptOutCall struct { @@ -11932,153 +11657,6 @@ func (c *PropertiesListCall) Pages(ctx context.Context, f func(*GoogleAnalyticsA } } -// method id "analyticsadmin.properties.listConnectedSiteTags": - -type PropertiesListConnectedSiteTagsCall struct { - s *Service - googleanalyticsadminv1alphalistconnectedsitetagsrequest *GoogleAnalyticsAdminV1alphaListConnectedSiteTagsRequest - urlParams_ gensupport.URLParams - ctx_ context.Context - header_ http.Header -} - -// ListConnectedSiteTags: Lists the connected site tags for a Universal -// Analytics property. Note: this has no effect on GA4 property. -func (r *PropertiesService) ListConnectedSiteTags(googleanalyticsadminv1alphalistconnectedsitetagsrequest *GoogleAnalyticsAdminV1alphaListConnectedSiteTagsRequest) *PropertiesListConnectedSiteTagsCall { - c := &PropertiesListConnectedSiteTagsCall{s: r.s, urlParams_: make(gensupport.URLParams)} - c.googleanalyticsadminv1alphalistconnectedsitetagsrequest = googleanalyticsadminv1alphalistconnectedsitetagsrequest - 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 *PropertiesListConnectedSiteTagsCall) Fields(s ...googleapi.Field) *PropertiesListConnectedSiteTagsCall { - 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 *PropertiesListConnectedSiteTagsCall) Context(ctx context.Context) *PropertiesListConnectedSiteTagsCall { - 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 *PropertiesListConnectedSiteTagsCall) Header() http.Header { - if c.header_ == nil { - c.header_ = make(http.Header) - } - return c.header_ -} - -func (c *PropertiesListConnectedSiteTagsCall) 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.googleanalyticsadminv1alphalistconnectedsitetagsrequest) - 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/properties:listConnectedSiteTags") - urls += "?" + c.urlParams_.Encode() - req, err := http.NewRequest("POST", urls, body) - if err != nil { - return nil, err - } - req.Header = reqHeaders - return gensupport.SendRequest(c.ctx_, c.s.client, req) -} - -// Do executes the "analyticsadmin.properties.listConnectedSiteTags" call. -// Exactly one of -// *GoogleAnalyticsAdminV1alphaListConnectedSiteTagsResponse or error -// will be non-nil. Any non-2xx status code is an error. Response -// headers are in either -// *GoogleAnalyticsAdminV1alphaListConnectedSiteTagsResponse.ServerRespon -// se.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 *PropertiesListConnectedSiteTagsCall) Do(opts ...googleapi.CallOption) (*GoogleAnalyticsAdminV1alphaListConnectedSiteTagsResponse, 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 := &GoogleAnalyticsAdminV1alphaListConnectedSiteTagsResponse{ - 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 the connected site tags for a Universal Analytics property. Note: this has no effect on GA4 property.", - // "flatPath": "v1alpha/properties:listConnectedSiteTags", - // "httpMethod": "POST", - // "id": "analyticsadmin.properties.listConnectedSiteTags", - // "parameterOrder": [], - // "parameters": {}, - // "path": "v1alpha/properties:listConnectedSiteTags", - // "request": { - // "$ref": "GoogleAnalyticsAdminV1alphaListConnectedSiteTagsRequest" - // }, - // "response": { - // "$ref": "GoogleAnalyticsAdminV1alphaListConnectedSiteTagsResponse" - // } - // } - -} - -// 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 *PropertiesListConnectedSiteTagsCall) Pages(ctx context.Context, f func(*GoogleAnalyticsAdminV1alphaListConnectedSiteTagsResponse) error) error { - c.ctx_ = ctx - defer func(pt string) { c.googleanalyticsadminv1alphalistconnectedsitetagsrequest.PageToken = pt }(c.googleanalyticsadminv1alphalistconnectedsitetagsrequest.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.googleanalyticsadminv1alphalistconnectedsitetagsrequest.PageToken = x.NextPageToken - } -} - // method id "analyticsadmin.properties.patch": type PropertiesPatchCall struct { @@ -13187,9 +12765,9 @@ type PropertiesAccessBindingsBatchDeleteCall struct { // account or property. // // - parent: The account or property that owns the access bindings. The -// parent field in the DeleteAccessBindingRequest messages must either -// be empty or match this field. Formats: - accounts/{account} - -// properties/{property}. +// parent of all provided values for the 'names' field in +// DeleteAccessBindingRequest messages must match this field. Formats: +// - accounts/{account} - properties/{property}. func (r *PropertiesAccessBindingsService) BatchDelete(parent string, googleanalyticsadminv1alphabatchdeleteaccessbindingsrequest *GoogleAnalyticsAdminV1alphaBatchDeleteAccessBindingsRequest) *PropertiesAccessBindingsBatchDeleteCall { c := &PropertiesAccessBindingsBatchDeleteCall{s: r.s, urlParams_: make(gensupport.URLParams)} c.parent = parent @@ -13297,7 +12875,7 @@ func (c *PropertiesAccessBindingsBatchDeleteCall) Do(opts ...googleapi.CallOptio // ], // "parameters": { // "parent": { - // "description": "Required. The account or property that owns the access bindings. The parent field in the DeleteAccessBindingRequest messages must either be empty or match this field. Formats: - accounts/{account} - properties/{property}", + // "description": "Required. The account or property that owns the access bindings. The parent of all provided values for the 'names' field in DeleteAccessBindingRequest messages must match this field. Formats: - accounts/{account} - properties/{property}", // "location": "path", // "pattern": "^properties/[^/]+$", // "required": true, @@ -13502,8 +13080,8 @@ type PropertiesAccessBindingsBatchUpdateCall struct { // account or property. // // - parent: The account or property that owns the access bindings. The -// parent field in the UpdateAccessBindingRequest messages must either -// be empty or match this field. Formats: - accounts/{account} - +// parent of all provided AccessBinding in UpdateAccessBindingRequest +// messages must match this field. Formats: - accounts/{account} - // properties/{property}. func (r *PropertiesAccessBindingsService) BatchUpdate(parent string, googleanalyticsadminv1alphabatchupdateaccessbindingsrequest *GoogleAnalyticsAdminV1alphaBatchUpdateAccessBindingsRequest) *PropertiesAccessBindingsBatchUpdateCall { c := &PropertiesAccessBindingsBatchUpdateCall{s: r.s, urlParams_: make(gensupport.URLParams)} @@ -13615,7 +13193,7 @@ func (c *PropertiesAccessBindingsBatchUpdateCall) Do(opts ...googleapi.CallOptio // ], // "parameters": { // "parent": { - // "description": "Required. The account or property that owns the access bindings. The parent field in the UpdateAccessBindingRequest messages must either be empty or match this field. Formats: - accounts/{account} - properties/{property}", + // "description": "Required. The account or property that owns the access bindings. The parent of all provided AccessBinding in UpdateAccessBindingRequest messages must match this field. Formats: - accounts/{account} - properties/{property}", // "location": "path", // "pattern": "^properties/[^/]+$", // "required": true, diff --git a/androiddeviceprovisioning/v1/androiddeviceprovisioning-api.json b/androiddeviceprovisioning/v1/androiddeviceprovisioning-api.json index 6fa84e5c7eb..6e2d2218d90 100644 --- a/androiddeviceprovisioning/v1/androiddeviceprovisioning-api.json +++ b/androiddeviceprovisioning/v1/androiddeviceprovisioning-api.json @@ -825,7 +825,7 @@ } } }, - "revision": "20221203", + "revision": "20230304", "rootUrl": "https://androiddeviceprovisioning.googleapis.com/", "schemas": { "ClaimDeviceRequest": { @@ -868,7 +868,7 @@ "type": "string" }, "simlockProfileId": { - "description": "Optional. Must and can only be set when DeviceProvisioningSectionType is SECTION_TYPE_SIM_LOCK. The unique identifier of the SimLock profile (go/simlock/profiles).", + "description": "Optional. Must and can only be set when DeviceProvisioningSectionType is SECTION_TYPE_SIM_LOCK. The unique identifier of the SimLock profile.", "format": "int64", "type": "string" } @@ -1679,6 +1679,11 @@ "Zero-touch enrollment section type." ], "type": "string" + }, + "simlockProfileId": { + "description": "Optional. Must and can only be set when DeviceProvisioningSectionType is SECTION_TYPE_SIM_LOCK. The unique identifier of the SimLock profile.", + "format": "int64", + "type": "string" } }, "type": "object" diff --git a/androiddeviceprovisioning/v1/androiddeviceprovisioning-gen.go b/androiddeviceprovisioning/v1/androiddeviceprovisioning-gen.go index fff1390323b..9e1f3e6df6c 100644 --- a/androiddeviceprovisioning/v1/androiddeviceprovisioning-gen.go +++ b/androiddeviceprovisioning/v1/androiddeviceprovisioning-gen.go @@ -274,7 +274,7 @@ type ClaimDeviceRequest struct { // SimlockProfileId: Optional. Must and can only be set when // DeviceProvisioningSectionType is SECTION_TYPE_SIM_LOCK. The unique - // identifier of the SimLock profile (go/simlock/profiles). + // identifier of the SimLock profile. SimlockProfileId int64 `json:"simlockProfileId,omitempty,string"` // ForceSendFields is a list of field names (e.g. "CustomerId") to @@ -1676,6 +1676,11 @@ type PartnerClaim struct { // "SECTION_TYPE_ZERO_TOUCH" - Zero-touch enrollment section type. SectionType string `json:"sectionType,omitempty"` + // SimlockProfileId: Optional. Must and can only be set when + // DeviceProvisioningSectionType is SECTION_TYPE_SIM_LOCK. The unique + // identifier of the SimLock profile. + SimlockProfileId int64 `json:"simlockProfileId,omitempty,string"` + // ForceSendFields is a list of field names (e.g. "CustomerId") to // unconditionally include in API requests. By default, fields with // empty or default values are omitted from API requests. However, any diff --git a/api-list.json b/api-list.json index 2ecaf4f2e04..28f4c267d0c 100644 --- a/api-list.json +++ b/api-list.json @@ -1326,7 +1326,7 @@ "id": "cloudprofiler:v2", "name": "cloudprofiler", "version": "v2", - "title": "Stackdriver Profiler API", + "title": "Cloud Profiler API", "description": "Manages continuous profiling information.", "discoveryRestUrl": "https://cloudprofiler.googleapis.com/$discovery/rest?version=v2", "icons": { @@ -3786,6 +3786,21 @@ "documentationLink": "https://cloud.google.com/dataproc-metastore/docs", "preferred": true }, + { + "kind": "discovery#directoryItem", + "id": "migrationcenter:v1alpha1", + "name": "migrationcenter", + "version": "v1alpha1", + "title": "Migration Center API", + "description": "", + "discoveryRestUrl": "https://migrationcenter.googleapis.com/$discovery/rest?version=v1alpha1", + "icons": { + "x16": "https://www.gstatic.com/images/branding/product/1x/googleg_16dp.png", + "x32": "https://www.gstatic.com/images/branding/product/1x/googleg_32dp.png" + }, + "documentationLink": "https://cloud.google.com/migration-center", + "preferred": true + }, { "kind": "discovery#directoryItem", "id": "ml:v1", @@ -4378,7 +4393,7 @@ "name": "policysimulator", "version": "v1alpha", "title": "Policy Simulator API", - "description": "Policy Simulator is a collection of endpoints for creating, running, and viewing a [Replay][google.cloud.policysimulator.v1beta1.Replay]. A `Replay` is a type of simulation that lets you see how your members' access to resources might change if you changed your IAM policy. During a `Replay`, Policy Simulator re-evaluates, or replays, past access attempts under both the current policy and your proposed policy, and compares those results to determine how your members' access might change under the proposed policy.", + "description": "Policy Simulator is a collection of endpoints for creating, running, and viewing a [Replay][google.cloud.policysimulator.v1.Replay]. A `Replay` is a type of simulation that lets you see how your members' access to resources might change if you changed your IAM policy. During a `Replay`, Policy Simulator re-evaluates, or replays, past access attempts under both the current policy and your proposed policy, and compares those results to determine how your members' access might change under the proposed policy.", "discoveryRestUrl": "https://policysimulator.googleapis.com/$discovery/rest?version=v1alpha", "icons": { "x16": "https://www.gstatic.com/images/branding/product/1x/googleg_16dp.png", @@ -4408,7 +4423,7 @@ "name": "policysimulator", "version": "v1", "title": "Policy Simulator API", - "description": "Policy Simulator is a collection of endpoints for creating, running, and viewing a [Replay][google.cloud.policysimulator.v1beta1.Replay]. A `Replay` is a type of simulation that lets you see how your members' access to resources might change if you changed your IAM policy. During a `Replay`, Policy Simulator re-evaluates, or replays, past access attempts under both the current policy and your proposed policy, and compares those results to determine how your members' access might change under the proposed policy.", + "description": "Policy Simulator is a collection of endpoints for creating, running, and viewing a [Replay][google.cloud.policysimulator.v1.Replay]. A `Replay` is a type of simulation that lets you see how your members' access to resources might change if you changed your IAM policy. During a `Replay`, Policy Simulator re-evaluates, or replays, past access attempts under both the current policy and your proposed policy, and compares those results to determine how your members' access might change under the proposed policy.", "discoveryRestUrl": "https://policysimulator.googleapis.com/$discovery/rest?version=v1", "icons": { "x16": "https://www.gstatic.com/images/branding/product/1x/googleg_16dp.png", diff --git a/chat/v1/chat-api.json b/chat/v1/chat-api.json index be330538427..85a0bc07c52 100644 --- a/chat/v1/chat-api.json +++ b/chat/v1/chat-api.json @@ -195,7 +195,7 @@ "parameterOrder": [], "parameters": { "pageSize": { - "description": "Optional. The maximum number of spaces to return. The service may return fewer than this value. If unspecified, at most 100 spaces are returned. The maximum value is 1000; values above 1000 are coerced to 1000. Negative values return an INVALID_ARGUMENT error.", + "description": "Optional. The maximum number of spaces to return. The service may return fewer than this value. If unspecified, at most 100 spaces are returned. The maximum value is 1000; values above 1000 are coerced to 1000. Negative values return an `INVALID_ARGUMENT` error.", "format": "int32", "location": "query", "type": "integer" @@ -263,7 +263,7 @@ "type": "integer" }, "pageToken": { - "description": "A page token, received from a previous list memberships call. Provide this to retrieve the subsequent page. When paginating, all other parameters provided should match the call that provided the page token. Passing different values to the other parameters may lead to unexpected results.", + "description": "A page token, received from a previous call to list memberships. Provide this to retrieve the subsequent page. When paginating, all other parameters provided should match the call that provided the page token. Passing different values to the other parameters may lead to unexpected results.", "location": "query", "type": "string" }, @@ -518,7 +518,7 @@ } } }, - "revision": "20230221", + "revision": "20230302", "rootUrl": "https://chat.googleapis.com/", "schemas": { "ActionParameter": { @@ -2341,7 +2341,7 @@ "type": "array" }, "cardsV2": { - "description": "Richly formatted and interactive cards that display UI elements and editable widgets, such as: - Formatted text - Buttons - Clickable images - Checkboxes - Radio buttons - Input widgets. Cards are usually displayed below the text body of a Chat message, but can situationally appear other places, such as [dialogs](https://developers.google.com/chat/how-tos/dialogs). `cards_v2` and `cards` can have a maximum size of 32 KB. The `cardId` is a unique identifier among cards in the same message and for identifying user input values. Currently supported widgets include: - `TextParagraph` - `DecoratedText` - `Image` - `ButtonList` - `Divider` - `TextInput` - `SelectionInput` (CHECKBOX, RADIO_BUTTON, SWITCH, DROPDOWN) - `Grid`", + "description": "Richly formatted and interactive cards that display UI elements and editable widgets, such as: - Formatted text - Buttons - Clickable images - Checkboxes - Radio buttons - Input widgets. Cards are usually displayed below the text body of a Chat message, but can situationally appear other places, such as [dialogs](https://developers.google.com/chat/how-tos/dialogs). Each card can have a maximum size of 32 KB. The `cardId` is a unique identifier among cards in the same message and for identifying user input values. Currently supported widgets include: - `TextParagraph` - `DecoratedText` - `Image` - `ButtonList` - `Divider` - `TextInput` - `SelectionInput` - `Grid`", "items": { "$ref": "CardWithId" }, @@ -2378,7 +2378,7 @@ }, "sender": { "$ref": "User", - "description": "Output only. The user who created the message.", + "description": "Output only. The user who created the message. If your Chat app [authenticates as a user](https://developers.google.com/chat/api/guides/auth/users), the output populates the [user](https://developers.google.com/chat/api/reference/rest/v1/User) `name` and `type`.", "readOnly": true }, "slashCommand": { @@ -2388,7 +2388,7 @@ }, "space": { "$ref": "Space", - "description": "The space the message belongs to. When accessed with [user authentication](https://developers.google.com/chat/api/guides/auth/users), only the name of the Space is populated." + "description": "If your Chat app [authenticates as a user](https://developers.google.com/chat/api/guides/auth/users), the output populates the [space](https://developers.google.com/chat/api/reference/rest/v1/spaces) `name`." }, "text": { "description": "Plain-text body of the message. The first link to an image, video, web page, or other preview-able item generates a preview chip.", diff --git a/chat/v1/chat-gen.go b/chat/v1/chat-gen.go index 43b668b60ec..7fcd09bb7c3 100644 --- a/chat/v1/chat-gen.go +++ b/chat/v1/chat-gen.go @@ -3368,13 +3368,12 @@ type Message struct { // Clickable images - Checkboxes - Radio buttons - Input widgets. Cards // are usually displayed below the text body of a Chat message, but can // situationally appear other places, such as dialogs - // (https://developers.google.com/chat/how-tos/dialogs). `cards_v2` and - // `cards` can have a maximum size of 32 KB. The `cardId` is a unique - // identifier among cards in the same message and for identifying user - // input values. Currently supported widgets include: - `TextParagraph` - // - `DecoratedText` - `Image` - `ButtonList` - `Divider` - `TextInput` - // - `SelectionInput` (CHECKBOX, RADIO_BUTTON, SWITCH, DROPDOWN) - - // `Grid` + // (https://developers.google.com/chat/how-tos/dialogs). Each card can + // have a maximum size of 32 KB. The `cardId` is a unique identifier + // among cards in the same message and for identifying user input + // values. Currently supported widgets include: - `TextParagraph` - + // `DecoratedText` - `Image` - `ButtonList` - `Divider` - `TextInput` - + // `SelectionInput` - `Grid` CardsV2 []*CardWithId `json:"cardsV2,omitempty"` // ClientAssignedMessageId: A custom name for a Chat message assigned at @@ -3408,16 +3407,22 @@ type Message struct { // `spaces/AAAAAAAAAAA/messages/BBBBBBBBBBB.BBBBBBBBBBB` Name string `json:"name,omitempty"` - // Sender: Output only. The user who created the message. + // Sender: Output only. The user who created the message. If your Chat + // app authenticates as a user + // (https://developers.google.com/chat/api/guides/auth/users), the + // output populates the user + // (https://developers.google.com/chat/api/reference/rest/v1/User) + // `name` and `type`. Sender *User `json:"sender,omitempty"` // SlashCommand: Output only. Slash command information, if applicable. SlashCommand *SlashCommand `json:"slashCommand,omitempty"` - // Space: The space the message belongs to. When accessed with user - // authentication - // (https://developers.google.com/chat/api/guides/auth/users), only the - // name of the Space is populated. + // Space: If your Chat app authenticates as a user + // (https://developers.google.com/chat/api/guides/auth/users), the + // output populates the space + // (https://developers.google.com/chat/api/reference/rest/v1/spaces) + // `name`. Space *Space `json:"space,omitempty"` // Text: Plain-text body of the message. The first link to an image, @@ -4475,7 +4480,7 @@ func (r *SpacesService) List() *SpacesListCall { // of spaces to return. The service may return fewer than this value. If // unspecified, at most 100 spaces are returned. The maximum value is // 1000; values above 1000 are coerced to 1000. Negative values return -// an INVALID_ARGUMENT error. +// an `INVALID_ARGUMENT` error. func (c *SpacesListCall) PageSize(pageSize int64) *SpacesListCall { c.urlParams_.Set("pageSize", fmt.Sprint(pageSize)) return c @@ -4594,7 +4599,7 @@ func (c *SpacesListCall) Do(opts ...googleapi.CallOption) (*ListSpacesResponse, // "parameterOrder": [], // "parameters": { // "pageSize": { - // "description": "Optional. The maximum number of spaces to return. The service may return fewer than this value. If unspecified, at most 100 spaces are returned. The maximum value is 1000; values above 1000 are coerced to 1000. Negative values return an INVALID_ARGUMENT error.", + // "description": "Optional. The maximum number of spaces to return. The service may return fewer than this value. If unspecified, at most 100 spaces are returned. The maximum value is 1000; values above 1000 are coerced to 1000. Negative values return an `INVALID_ARGUMENT` error.", // "format": "int32", // "location": "query", // "type": "integer" @@ -4842,7 +4847,7 @@ func (c *SpacesMembersListCall) PageSize(pageSize int64) *SpacesMembersListCall } // PageToken sets the optional parameter "pageToken": A page token, -// received from a previous list memberships call. Provide this to +// received from a previous call to list memberships. Provide this to // retrieve the subsequent page. When paginating, all other parameters // provided should match the call that provided the page token. Passing // different values to the other parameters may lead to unexpected @@ -4966,7 +4971,7 @@ func (c *SpacesMembersListCall) Do(opts ...googleapi.CallOption) (*ListMembershi // "type": "integer" // }, // "pageToken": { - // "description": "A page token, received from a previous list memberships call. Provide this to retrieve the subsequent page. When paginating, all other parameters provided should match the call that provided the page token. Passing different values to the other parameters may lead to unexpected results.", + // "description": "A page token, received from a previous call to list memberships. Provide this to retrieve the subsequent page. When paginating, all other parameters provided should match the call that provided the page token. Passing different values to the other parameters may lead to unexpected results.", // "location": "query", // "type": "string" // }, diff --git a/chromepolicy/v1/chromepolicy-api.json b/chromepolicy/v1/chromepolicy-api.json index c1c0e0b32a6..6c01c5aa4f1 100644 --- a/chromepolicy/v1/chromepolicy-api.json +++ b/chromepolicy/v1/chromepolicy-api.json @@ -557,7 +557,7 @@ } } }, - "revision": "20230220", + "revision": "20230304", "rootUrl": "https://chromepolicy.googleapis.com/", "schemas": { "ChromeCrosDpanelAutosettingsProtoPolicyApiLifecycle": { @@ -1072,10 +1072,6 @@ "description": "Output only. Current lifecycle information.", "readOnly": true }, - "policyApiLifeycle": { - "$ref": "ChromeCrosDpanelAutosettingsProtoPolicyApiLifecycle", - "description": "Deprecated field because of typo." - }, "policyDescription": { "description": "Output only. Description about the policy schema for user consumption.", "readOnly": true, @@ -1373,7 +1369,7 @@ "type": "string" }, "policySchemaFilter": { - "description": "The schema filter to apply to the resolve request. Specify a schema name to view a particular schema, for example: chrome.users.ShowLogoutButton Wildcards are supported, but only in the leaf portion of the schema name. Wildcards cannot be used in namespace directly. Please read https://developers.google.com/chrome/policy/guides/policy-schemas for details on schema namespaces. For example: Valid: \"chrome.users.*\", \"chrome.users.apps.*\", \"chrome.printers.*\" Invalid: \"*\", \"*.users\", \"chrome.*\", \"chrome.*.apps.*\"", + "description": "Required. The schema filter to apply to the resolve request. Specify a schema name to view a particular schema, for example: chrome.users.ShowLogoutButton Wildcards are supported, but only in the leaf portion of the schema name. Wildcards cannot be used in namespace directly. Please read https://developers.google.com/chrome/policy/guides/policy-schemas for details on schema namespaces. For example: Valid: \"chrome.users.*\", \"chrome.users.apps.*\", \"chrome.printers.*\" Invalid: \"*\", \"*.users\", \"chrome.*\", \"chrome.*.apps.*\"", "type": "string" }, "policyTargetKey": { diff --git a/chromepolicy/v1/chromepolicy-gen.go b/chromepolicy/v1/chromepolicy-gen.go index 98e8b5afb9d..61c5abd4bdb 100644 --- a/chromepolicy/v1/chromepolicy-gen.go +++ b/chromepolicy/v1/chromepolicy-gen.go @@ -1169,9 +1169,6 @@ type GoogleChromePolicyVersionsV1PolicySchema struct { // PolicyApiLifecycle: Output only. Current lifecycle information. PolicyApiLifecycle *ChromeCrosDpanelAutosettingsProtoPolicyApiLifecycle `json:"policyApiLifecycle,omitempty"` - // PolicyApiLifeycle: Deprecated field because of typo. - PolicyApiLifeycle *ChromeCrosDpanelAutosettingsProtoPolicyApiLifecycle `json:"policyApiLifeycle,omitempty"` - // PolicyDescription: Output only. Description about the policy schema // for user consumption. PolicyDescription string `json:"policyDescription,omitempty"` @@ -1644,11 +1641,11 @@ type GoogleChromePolicyVersionsV1ResolveRequest struct { // request. PageToken string `json:"pageToken,omitempty"` - // PolicySchemaFilter: The schema filter to apply to the resolve - // request. Specify a schema name to view a particular schema, for - // example: chrome.users.ShowLogoutButton Wildcards are supported, but - // only in the leaf portion of the schema name. Wildcards cannot be used - // in namespace directly. Please read + // PolicySchemaFilter: Required. The schema filter to apply to the + // resolve request. Specify a schema name to view a particular schema, + // for example: chrome.users.ShowLogoutButton Wildcards are supported, + // but only in the leaf portion of the schema name. Wildcards cannot be + // used in namespace directly. Please read // https://developers.google.com/chrome/policy/guides/policy-schemas for // details on schema namespaces. For example: Valid: "chrome.users.*", // "chrome.users.apps.*", "chrome.printers.*" Invalid: "*", "*.users", diff --git a/cloudasset/v1/cloudasset-api.json b/cloudasset/v1/cloudasset-api.json index d31ab80108f..4ee84f33f22 100644 --- a/cloudasset/v1/cloudasset-api.json +++ b/cloudasset/v1/cloudasset-api.json @@ -1095,7 +1095,7 @@ } } }, - "revision": "20230211", + "revision": "20230304", "rootUrl": "https://cloudasset.googleapis.com/", "schemas": { "AccessSelector": { @@ -1872,14 +1872,14 @@ "type": "string" }, "folders": { - "description": "The folder(s) that this IAM policy belongs to, in the form of folders/{FOLDER_NUMBER}. This field is available when the IAM policy belongs(directly or cascadingly) to one or more folders.", + "description": "The folder(s) that this IAM policy belongs to, in the format of folders/{FOLDER_NUMBER}. This field is available when the IAM policy belongs (directly or cascadingly) to one or more folders.", "items": { "type": "string" }, "type": "array" }, "organization": { - "description": "The organization that this IAM policy belongs to, in the form of organizations/{ORGANIZATION_NUMBER}. This field is available when the IAM policy belongs(directly or cascadingly) to an organization.", + "description": "The organization that this IAM policy belongs to, in the format of organizations/{ORGANIZATION_NUMBER}. This field is available when the IAM policy belongs (directly or cascadingly) to an organization.", "type": "string" }, "policy": { @@ -1887,7 +1887,7 @@ "description": "The IAM policy directly set on the given resource." }, "project": { - "description": "The project that this IAM policy belongs to, in the form of projects/{PROJECT_NUMBER}. This field is available when the IAM policy belongs to a project.", + "description": "The project that this IAM policy belongs to, in the format of projects/{PROJECT_NUMBER}. This field is available when the IAM policy belongs to a project.", "type": "string" } }, @@ -1898,7 +1898,7 @@ "id": "GoogleCloudAssetV1AnalyzeOrgPolicyGovernedAssetsResponseGovernedResource", "properties": { "folders": { - "description": "The folder(s) that this resource belongs to, in the form of folders/{FOLDER_NUMBER}. This field is available when the resource belongs(directly or cascadingly) to one or more folders.", + "description": "The folder(s) that this resource belongs to, in the format of folders/{FOLDER_NUMBER}. This field is available when the resource belongs (directly or cascadingly) to one or more folders.", "items": { "type": "string" }, @@ -1909,7 +1909,7 @@ "type": "string" }, "organization": { - "description": "The organization that this resource belongs to, in the form of organizations/{ORGANIZATION_NUMBER}. This field is available when the resource belongs(directly or cascadingly) to an organization.", + "description": "The organization that this resource belongs to, in the format of organizations/{ORGANIZATION_NUMBER}. This field is available when the resource belongs (directly or cascadingly) to an organization.", "type": "string" }, "parent": { @@ -1917,7 +1917,7 @@ "type": "string" }, "project": { - "description": "The project that this resource belongs to, in the form of projects/{PROJECT_NUMBER}. This field is available when the resource belongs to a project.", + "description": "The project that this resource belongs to, in the format of projects/{PROJECT_NUMBER}. This field is available when the resource belongs to a project.", "type": "string" } }, diff --git a/cloudasset/v1/cloudasset-gen.go b/cloudasset/v1/cloudasset-gen.go index adeaa1f6952..764cc277ae2 100644 --- a/cloudasset/v1/cloudasset-gen.go +++ b/cloudasset/v1/cloudasset-gen.go @@ -1817,22 +1817,22 @@ type GoogleCloudAssetV1AnalyzeOrgPolicyGovernedAssetsResponseGovernedIamPolicy s // for more information. AttachedResource string `json:"attachedResource,omitempty"` - // Folders: The folder(s) that this IAM policy belongs to, in the form + // Folders: The folder(s) that this IAM policy belongs to, in the format // of folders/{FOLDER_NUMBER}. This field is available when the IAM - // policy belongs(directly or cascadingly) to one or more folders. + // policy belongs (directly or cascadingly) to one or more folders. Folders []string `json:"folders,omitempty"` // Organization: The organization that this IAM policy belongs to, in - // the form of organizations/{ORGANIZATION_NUMBER}. This field is - // available when the IAM policy belongs(directly or cascadingly) to an + // the format of organizations/{ORGANIZATION_NUMBER}. This field is + // available when the IAM policy belongs (directly or cascadingly) to an // organization. Organization string `json:"organization,omitempty"` // Policy: The IAM policy directly set on the given resource. Policy *Policy `json:"policy,omitempty"` - // Project: The project that this IAM policy belongs to, in the form of - // projects/{PROJECT_NUMBER}. This field is available when the IAM + // Project: The project that this IAM policy belongs to, in the format + // of projects/{PROJECT_NUMBER}. This field is available when the IAM // policy belongs to a project. Project string `json:"project,omitempty"` @@ -1864,9 +1864,9 @@ func (s *GoogleCloudAssetV1AnalyzeOrgPolicyGovernedAssetsResponseGovernedIamPoli // ce: The Google Cloud resources governed by the organization policies // of the AnalyzeOrgPolicyGovernedAssetsRequest.constraint. type GoogleCloudAssetV1AnalyzeOrgPolicyGovernedAssetsResponseGovernedResource struct { - // Folders: The folder(s) that this resource belongs to, in the form of - // folders/{FOLDER_NUMBER}. This field is available when the resource - // belongs(directly or cascadingly) to one or more folders. + // Folders: The folder(s) that this resource belongs to, in the format + // of folders/{FOLDER_NUMBER}. This field is available when the resource + // belongs (directly or cascadingly) to one or more folders. Folders []string `json:"folders,omitempty"` // FullResourceName: The [full resource name] @@ -1875,8 +1875,8 @@ type GoogleCloudAssetV1AnalyzeOrgPolicyGovernedAssetsResponseGovernedResource st FullResourceName string `json:"fullResourceName,omitempty"` // Organization: The organization that this resource belongs to, in the - // form of organizations/{ORGANIZATION_NUMBER}. This field is available - // when the resource belongs(directly or cascadingly) to an + // format of organizations/{ORGANIZATION_NUMBER}. This field is + // available when the resource belongs (directly or cascadingly) to an // organization. Organization string `json:"organization,omitempty"` @@ -1887,7 +1887,7 @@ type GoogleCloudAssetV1AnalyzeOrgPolicyGovernedAssetsResponseGovernedResource st // name. Parent string `json:"parent,omitempty"` - // Project: The project that this resource belongs to, in the form of + // Project: The project that this resource belongs to, in the format of // projects/{PROJECT_NUMBER}. This field is available when the resource // belongs to a project. Project string `json:"project,omitempty"` diff --git a/cloudchannel/v1/cloudchannel-api.json b/cloudchannel/v1/cloudchannel-api.json index ff8e660ad82..22241eadf5a 100644 --- a/cloudchannel/v1/cloudchannel-api.json +++ b/cloudchannel/v1/cloudchannel-api.json @@ -1873,7 +1873,7 @@ ] }, "list": { - "description": "Lists operations that match the specified filter in the request. If the server doesn't support this method, it returns `UNIMPLEMENTED`. NOTE: the `name` binding allows API services to override the binding to use different resource name schemes, such as `users/*/operations`. To override the binding, API services can add a binding such as `\"/v1/{name=users/*}/operations\"` to their service configuration. For backwards compatibility, the default name includes the operations collection id, however overriding users must ensure the name binding is the parent resource, without the operations collection id.", + "description": "Lists operations that match the specified filter in the request. If the server doesn't support this method, it returns `UNIMPLEMENTED`.", "flatPath": "v1/operations", "httpMethod": "GET", "id": "cloudchannel.operations.list", @@ -2009,7 +2009,7 @@ } } }, - "revision": "20230226", + "revision": "20230304", "rootUrl": "https://cloudchannel.googleapis.com/", "schemas": { "GoogleCloudChannelV1ActivateEntitlementRequest": { diff --git a/cloudchannel/v1/cloudchannel-gen.go b/cloudchannel/v1/cloudchannel-gen.go index 4bc481f1c0a..cc50a8eb3e1 100644 --- a/cloudchannel/v1/cloudchannel-gen.go +++ b/cloudchannel/v1/cloudchannel-gen.go @@ -15416,14 +15416,7 @@ type OperationsListCall struct { // List: Lists operations that match the specified filter in the // request. If the server doesn't support this method, it returns -// `UNIMPLEMENTED`. NOTE: the `name` binding allows API services to -// override the binding to use different resource name schemes, such as -// `users/*/operations`. To override the binding, API services can add a -// binding such as "/v1/{name=users/*}/operations" to their service -// configuration. For backwards compatibility, the default name includes -// the operations collection id, however overriding users must ensure -// the name binding is the parent resource, without the operations -// collection id. +// `UNIMPLEMENTED`. // // - name: The name of the operation's parent resource. func (r *OperationsService) List(name string) *OperationsListCall { @@ -15553,7 +15546,7 @@ func (c *OperationsListCall) Do(opts ...googleapi.CallOption) (*GoogleLongrunnin } 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`. NOTE: the `name` binding allows API services to override the binding to use different resource name schemes, such as `users/*/operations`. To override the binding, API services can add a binding such as `\"/v1/{name=users/*}/operations\"` to their service configuration. For backwards compatibility, the default name includes the operations collection id, however overriding users must ensure the name binding is the parent resource, without the operations collection id.", + // "description": "Lists operations that match the specified filter in the request. If the server doesn't support this method, it returns `UNIMPLEMENTED`.", // "flatPath": "v1/operations", // "httpMethod": "GET", // "id": "cloudchannel.operations.list", diff --git a/cloudsearch/v1/cloudsearch-api.json b/cloudsearch/v1/cloudsearch-api.json index fd5f6ebfc7f..87ce04b50c7 100644 --- a/cloudsearch/v1/cloudsearch-api.json +++ b/cloudsearch/v1/cloudsearch-api.json @@ -2077,7 +2077,7 @@ } } }, - "revision": "20230221", + "revision": "20230228", "rootUrl": "https://cloudsearch.googleapis.com/", "schemas": { "AbuseReportingConfig": { @@ -5857,13 +5857,15 @@ "ACCESS_TYPE_UNSPECIFIED", "ACCESS_TYPE_OPEN", "ACCESS_TYPE_TRUSTED", - "ACCESS_TYPE_RESTRICTED" + "ACCESS_TYPE_RESTRICTED", + "ACCESS_TYPE_CLOSED" ], "enumDescriptions": [ "Default value. This value is unused.", "Anyone with meeting join information (url, phone access...) can join, no knocking required. (Subject to organization policies)", "Members of the Host's organization, invited external users, and dial-in users can join without knocking, everyone else must knock. (Subject to organization policies)", - "Only participants invited by a host can automatically join, everyone else must knock and be admitted. (Subject to organization policies) Participants cannot dial out from the meeting. And only hosts can accept knocks." + "Only participants invited by a host can automatically join, everyone else must knock and be admitted. (Subject to organization policies) Participants cannot dial out from the meeting. And only hosts can accept knocks.", + "Only participants invited by a host can join. Knocking is not allowed, dial in and dial out are also disabled." ], "type": "string" }, @@ -5970,13 +5972,15 @@ "ACCESS_TYPE_UNSPECIFIED", "ACCESS_TYPE_OPEN", "ACCESS_TYPE_TRUSTED", - "ACCESS_TYPE_RESTRICTED" + "ACCESS_TYPE_RESTRICTED", + "ACCESS_TYPE_CLOSED" ], "enumDescriptions": [ "Default value. This value is unused.", "Anyone with meeting join information (url, phone access...) can join, no knocking required. (Subject to organization policies)", "Members of the Host's organization, invited external users, and dial-in users can join without knocking, everyone else must knock. (Subject to organization policies)", - "Only participants invited by a host can automatically join, everyone else must knock and be admitted. (Subject to organization policies) Participants cannot dial out from the meeting. And only hosts can accept knocks." + "Only participants invited by a host can automatically join, everyone else must knock and be admitted. (Subject to organization policies) Participants cannot dial out from the meeting. And only hosts can accept knocks.", + "Only participants invited by a host can join. Knocking is not allowed, dial in and dial out are also disabled." ], "type": "string" }, @@ -7170,7 +7174,7 @@ "type": "string" }, "scanNotApplicableForContext": { - "description": "Indicates that was no attempt to scan a message or attachment because it was not applicable in the given context (e.g. atomic mutuate). If this is true, scan_outcome should not be set. This flag is used to identify messages that DLP did not attempt to scan for monitoring scan coverage. Contents that DLP attempted to scan but skipped can be identified by DlpScanOutcome.SCAN_SKIPPED_* reasons.", + "description": "Indicates that was no attempt to scan a message or attachment because it was not applicable in the given context (e.g. atomic mutuate). If this is true, scan_outcome should not be set. This flag is used to identify messages that DLP did not attempt to scan for monitoring scan coverage. Contents that DLP attempted to scan but skipped can be identified by DlpScanOutcome.SCAN_SKIPPED_* reasons. DEPRECATED: The prober can determine this from the context.", "type": "boolean" }, "scanOutcome": { @@ -7572,6 +7576,10 @@ "creatorInSearcherContactList": { "type": "boolean" }, + "crowdingMultiplier": { + "format": "double", + "type": "number" + }, "dasContactCount": { "format": "int64", "type": "string" @@ -12785,71 +12793,9 @@ "description": "Was this message deleted by Vault (Only used for Vault support) This is false if message is live or message was deleted by user.", "type": "boolean" }, - "dlpScanOutcome": { - "description": "Data Loss Prevention scan information for this message. Messages are evaluated in the backend on create message/topic and edit message actions. DEPRECATED: use dlp_scan_summary instead.", - "enum": [ - "SCAN_UNKNOWN_OUTCOME", - "SCAN_SUCCEEDED_NO_VIOLATION", - "SCAN_SUCCEEDED_BLOCK", - "SCAN_SUCCEEDED_WARN", - "SCAN_SUCCEEDED_AUDIT_ONLY", - "SCAN_FAILURE_EXCEPTION", - "SCAN_FAILURE_RULE_FETCH_FAILED", - "SCAN_FAILURE_TIMEOUT", - "SCAN_FAILURE_ALL_RULES_FAILED", - "SCAN_FAILURE_ILLEGAL_STATE_FOR_ATTACHMENTS", - "SCAN_SKIPPED_EXPERIMENT_DISABLED", - "SCAN_SKIPPED_CONSUMER", - "SCAN_SKIPPED_NON_HUMAN_USER", - "SCAN_SKIPPED_NO_MESSAGE", - "SCAN_SKIPPED_USER_ACKNOWLEDGED_WARNING", - "SCAN_SKIPPED_MESSAGE_FROM_UNSUPPORTED_ORIGIN", - "SCAN_SKIPPED_MESSAGE_SENT_DURING_SPACE_MIGRATION", - "SCAN_RULE_EVALUATION_SKIPPED_NO_RULES_FOUND", - "SCAN_RULE_EVALUATION_SKIPPED_NO_APPLICABLE_RULES_FOR_ACTION_PARAMS", - "SCAN_RULE_EVALUATION_SKIPPED_NO_APPLICABLE_RULES_FOR_TRIGGER", - "SCAN_RULE_EVALUATION_SKIPPED_CHANGELING_PERMANENT_ERROR", - "SCAN_RULE_EVALUATION_SKIPPED_CHANGELING_EMPTY_RESPONSE", - "SCAN_RULE_EVALUATION_SKIPPED_UNSUPPORTED_FILE_TYPE", - "SCAN_SUCCEEDED_WITH_FAILURES_NO_VIOLATION", - "SCAN_SUCCEEDED_WITH_FAILURES_BLOCK", - "SCAN_SUCCEEDED_WITH_FAILURES_WARN", - "SCAN_SUCCEEDED_WITH_FAILURES_AUDIT_ONLY" - ], - "enumDescriptions": [ - "", - "This means no violation is detected on the given message/attachment.", - "Violation is detected. The message/attachment will be blocked (or deleted if this happens in failure recovery), the user will be warned, and the violation will be logged to BIP.", - "Violation is detected. The user will be warned, and the violation will be logged to BIP.", - "Violation is detected and will be logged to BIP (no user-facing action performed).", - "Rule fetch and evaluation were attempted but an exception occurred.", - "Rule fetch was attempted but failed, so rule evaluation could not be performed.", - "Rule fetch and evaluation were attempted but the scanning timed out.", - "Rule fetch completed and evaluation were attempted, but all of the rules failed to be evaluated.", - "An IllegalStateException is thrown when executing DLP on attachments. This could happen if the space row is missing.", - "Rule fetch and evaluation is skipped because DLP is not enabled for the user.", - "Rule fetch and evaluation are skipped because the user sending message is consumer.", - "Rule fetch and evaluation are skipped because the user sending message is a non-human user (i.e. a bot).", - "Rule fetch and evaluation are skipped because there is no message to scan. Deprecated: this should not happen since there must be message or attachment for DLP scan.", - "Rule fetch and evaluation are skipped because the user has acknowledged the warning on the message that triggered the Warn violation and sent the message anyway.", - "Scanning was skipped because the message originated from Interop or Babel.", - "Scanning was skipped because the message was sent while the space is in migration mode. See go/migration-mode for details.", - "Rule fetch happened, but rule evaluation is skipped because no rules were found.", - "Rule fetch happened, but rule evaluation is skipped because none of the rules are applicable to the given action params.", - "Rule fetch happened, but rule evaluation is skipped because none of the rules are applicable to the given trigger.", - "Rule fetch happened, but rule evaluation is skipped because Changeling returned permanent failure while converting the attachment to text.", - "Rule fetch happened, but rule evaluation is skipped because Changeling returned an empty response while converting the attachment to text.", - "Rule fetch happened, but rule evaluation is skipped because file type is unsupported.", - "Rules were fetched but some evaluations failed. No violation was found in the rules that were successfully evaluated.", - "Rules were fetched but some evaluations failed. A blocking violation was found in the rules that were successfully evaluated. The message/attachment will be blocked, the user will be notified, and the violation will be logged to BIP. A blocking violation takes precedence over all other violation types.", - "Rules were fetched but some evaluations failed. A warn violation was found in the rules that were successfully evaluated. The user will be warned, and the violation will be logged to BIP.", - "Rules were fetched but some evaluations failed. An audit-only violation was found in the rules that were successfully evaluated. The violation will be logged to BIP (no user-facing action performed)." - ], - "type": "string" - }, "dlpScanSummary": { "$ref": "DlpScanSummary", - "description": "Data Loss Prevention scan information for this message. Messages are evaluated in the backend on create message/topic and edit message actions." + "description": "Data Loss Prevention scan information for this message. Messages are evaluated in the backend on create message/topic and edit message actions. DEPRECATED: Use DATA_LOSS_PREVENTION Annotation." }, "editableBy": { "description": "Indicates who can edit the message. This field is set on the read path (e.g. ListTopics) but doesn’t have any effect on the write path (e.g. CreateMessageRequest).", @@ -15097,12 +15043,14 @@ "REQUIRED_FEATURE_UNSPECIFIED", "REQUIRED_FEATURE_MESSAGE_QUOTING", "REQUIRED_FEATURE_TOMBSTONES_IN_DMS_AND_UFRS", - "REQUIRED_FEATURE_CUSTOM_HYPERLINK" + "REQUIRED_FEATURE_CUSTOM_HYPERLINK", + "REQUIRED_FEATURE_SMART_CHIP" ], "enumDescriptions": [ "", "", "", + "", "" ], "type": "string" @@ -16047,13 +15995,15 @@ "ACCESS_TYPE_UNSPECIFIED", "ACCESS_TYPE_OPEN", "ACCESS_TYPE_TRUSTED", - "ACCESS_TYPE_RESTRICTED" + "ACCESS_TYPE_RESTRICTED", + "ACCESS_TYPE_CLOSED" ], "enumDescriptions": [ "Default value. This value is unused.", "Anyone with meeting join information (url, phone access...) can join, no knocking required. (Subject to organization policies)", "Members of the Host's organization, invited external users, and dial-in users can join without knocking, everyone else must knock. (Subject to organization policies)", - "Only participants invited by a host can automatically join, everyone else must knock and be admitted. (Subject to organization policies) Participants cannot dial out from the meeting. And only hosts can accept knocks." + "Only participants invited by a host can automatically join, everyone else must knock and be admitted. (Subject to organization policies) Participants cannot dial out from the meeting. And only hosts can accept knocks.", + "Only participants invited by a host can join. Knocking is not allowed, dial in and dial out are also disabled." ], "type": "string" }, diff --git a/cloudsearch/v1/cloudsearch-gen.go b/cloudsearch/v1/cloudsearch-gen.go index fd6c0e6b9fb..0287102223e 100644 --- a/cloudsearch/v1/cloudsearch-gen.go +++ b/cloudsearch/v1/cloudsearch-gen.go @@ -6265,6 +6265,9 @@ type CallInfo struct { // automatically join, everyone else must knock and be admitted. // (Subject to organization policies) Participants cannot dial out from // the meeting. And only hosts can accept knocks. + // "ACCESS_TYPE_CLOSED" - Only participants invited by a host can + // join. Knocking is not allowed, dial in and dial out are also + // disabled. AvailableAccessTypes []string `json:"availableAccessTypes,omitempty"` // AvailableReactions: Output only. The set of reactions that clients @@ -6409,6 +6412,9 @@ type CallSettings struct { // automatically join, everyone else must knock and be admitted. // (Subject to organization policies) Participants cannot dial out from // the meeting. And only hosts can accept knocks. + // "ACCESS_TYPE_CLOSED" - Only participants invited by a host can + // join. Knocking is not allowed, dial in and dial out are also + // disabled. AccessType string `json:"accessType,omitempty"` // AllowJoiningBeforeHost: Whether users can join this conference before @@ -8688,7 +8694,8 @@ type DlpScanSummary struct { // not be set. This flag is used to identify messages that DLP did not // attempt to scan for monitoring scan coverage. Contents that DLP // attempted to scan but skipped can be identified by - // DlpScanOutcome.SCAN_SKIPPED_* reasons. + // DlpScanOutcome.SCAN_SKIPPED_* reasons. DEPRECATED: The prober can + // determine this from the context. ScanNotApplicableForContext bool `json:"scanNotApplicableForContext,omitempty"` // ScanOutcome: The outcome of a DLP Scan. If this is set, @@ -9268,6 +9275,8 @@ type DynamiteMessagesScoringInfo struct { CreatorInSearcherContactList bool `json:"creatorInSearcherContactList,omitempty"` + CrowdingMultiplier float64 `json:"crowdingMultiplier,omitempty"` + DasContactCount int64 `json:"dasContactCount,omitempty,string"` FinalScore float64 `json:"finalScore,omitempty"` @@ -9319,6 +9328,7 @@ func (s *DynamiteMessagesScoringInfo) UnmarshalJSON(data []byte) error { var s1 struct { CommonCountToContactListCountRatio gensupport.JSONFloat64 `json:"commonCountToContactListCountRatio"` CommonCountToMembershipCountRatio gensupport.JSONFloat64 `json:"commonCountToMembershipCountRatio"` + CrowdingMultiplier gensupport.JSONFloat64 `json:"crowdingMultiplier"` FinalScore gensupport.JSONFloat64 `json:"finalScore"` FreshnessScore gensupport.JSONFloat64 `json:"freshnessScore"` JoinedSpaceAffinityScore gensupport.JSONFloat64 `json:"joinedSpaceAffinityScore"` @@ -9335,6 +9345,7 @@ func (s *DynamiteMessagesScoringInfo) UnmarshalJSON(data []byte) error { } s.CommonCountToContactListCountRatio = float64(s1.CommonCountToContactListCountRatio) s.CommonCountToMembershipCountRatio = float64(s1.CommonCountToMembershipCountRatio) + s.CrowdingMultiplier = float64(s1.CrowdingMultiplier) s.FinalScore = float64(s1.FinalScore) s.FreshnessScore = float64(s1.FreshnessScore) s.JoinedSpaceAffinityScore = float64(s1.JoinedSpaceAffinityScore) @@ -16350,93 +16361,10 @@ type Message struct { // deleted by user. DeletedByVault bool `json:"deletedByVault,omitempty"` - // DlpScanOutcome: Data Loss Prevention scan information for this - // message. Messages are evaluated in the backend on create - // message/topic and edit message actions. DEPRECATED: use - // dlp_scan_summary instead. - // - // Possible values: - // "SCAN_UNKNOWN_OUTCOME" - // "SCAN_SUCCEEDED_NO_VIOLATION" - This means no violation is detected - // on the given message/attachment. - // "SCAN_SUCCEEDED_BLOCK" - Violation is detected. The - // message/attachment will be blocked (or deleted if this happens in - // failure recovery), the user will be warned, and the violation will be - // logged to BIP. - // "SCAN_SUCCEEDED_WARN" - Violation is detected. The user will be - // warned, and the violation will be logged to BIP. - // "SCAN_SUCCEEDED_AUDIT_ONLY" - Violation is detected and will be - // logged to BIP (no user-facing action performed). - // "SCAN_FAILURE_EXCEPTION" - Rule fetch and evaluation were attempted - // but an exception occurred. - // "SCAN_FAILURE_RULE_FETCH_FAILED" - Rule fetch was attempted but - // failed, so rule evaluation could not be performed. - // "SCAN_FAILURE_TIMEOUT" - Rule fetch and evaluation were attempted - // but the scanning timed out. - // "SCAN_FAILURE_ALL_RULES_FAILED" - Rule fetch completed and - // evaluation were attempted, but all of the rules failed to be - // evaluated. - // "SCAN_FAILURE_ILLEGAL_STATE_FOR_ATTACHMENTS" - An - // IllegalStateException is thrown when executing DLP on attachments. - // This could happen if the space row is missing. - // "SCAN_SKIPPED_EXPERIMENT_DISABLED" - Rule fetch and evaluation is - // skipped because DLP is not enabled for the user. - // "SCAN_SKIPPED_CONSUMER" - Rule fetch and evaluation are skipped - // because the user sending message is consumer. - // "SCAN_SKIPPED_NON_HUMAN_USER" - Rule fetch and evaluation are - // skipped because the user sending message is a non-human user (i.e. a - // bot). - // "SCAN_SKIPPED_NO_MESSAGE" - Rule fetch and evaluation are skipped - // because there is no message to scan. Deprecated: this should not - // happen since there must be message or attachment for DLP scan. - // "SCAN_SKIPPED_USER_ACKNOWLEDGED_WARNING" - Rule fetch and - // evaluation are skipped because the user has acknowledged the warning - // on the message that triggered the Warn violation and sent the message - // anyway. - // "SCAN_SKIPPED_MESSAGE_FROM_UNSUPPORTED_ORIGIN" - Scanning was - // skipped because the message originated from Interop or Babel. - // "SCAN_SKIPPED_MESSAGE_SENT_DURING_SPACE_MIGRATION" - Scanning was - // skipped because the message was sent while the space is in migration - // mode. See go/migration-mode for details. - // "SCAN_RULE_EVALUATION_SKIPPED_NO_RULES_FOUND" - Rule fetch - // happened, but rule evaluation is skipped because no rules were found. - // - // "SCAN_RULE_EVALUATION_SKIPPED_NO_APPLICABLE_RULES_FOR_ACTION_PARAMS" - // - Rule fetch happened, but rule evaluation is skipped because none of - // the rules are applicable to the given action params. - // "SCAN_RULE_EVALUATION_SKIPPED_NO_APPLICABLE_RULES_FOR_TRIGGER" - - // Rule fetch happened, but rule evaluation is skipped because none of - // the rules are applicable to the given trigger. - // "SCAN_RULE_EVALUATION_SKIPPED_CHANGELING_PERMANENT_ERROR" - Rule - // fetch happened, but rule evaluation is skipped because Changeling - // returned permanent failure while converting the attachment to text. - // "SCAN_RULE_EVALUATION_SKIPPED_CHANGELING_EMPTY_RESPONSE" - Rule - // fetch happened, but rule evaluation is skipped because Changeling - // returned an empty response while converting the attachment to text. - // "SCAN_RULE_EVALUATION_SKIPPED_UNSUPPORTED_FILE_TYPE" - Rule fetch - // happened, but rule evaluation is skipped because file type is - // unsupported. - // "SCAN_SUCCEEDED_WITH_FAILURES_NO_VIOLATION" - Rules were fetched - // but some evaluations failed. No violation was found in the rules that - // were successfully evaluated. - // "SCAN_SUCCEEDED_WITH_FAILURES_BLOCK" - Rules were fetched but some - // evaluations failed. A blocking violation was found in the rules that - // were successfully evaluated. The message/attachment will be blocked, - // the user will be notified, and the violation will be logged to BIP. A - // blocking violation takes precedence over all other violation types. - // "SCAN_SUCCEEDED_WITH_FAILURES_WARN" - Rules were fetched but some - // evaluations failed. A warn violation was found in the rules that were - // successfully evaluated. The user will be warned, and the violation - // will be logged to BIP. - // "SCAN_SUCCEEDED_WITH_FAILURES_AUDIT_ONLY" - Rules were fetched but - // some evaluations failed. An audit-only violation was found in the - // rules that were successfully evaluated. The violation will be logged - // to BIP (no user-facing action performed). - DlpScanOutcome string `json:"dlpScanOutcome,omitempty"` - // DlpScanSummary: Data Loss Prevention scan information for this // message. Messages are evaluated in the backend on create - // message/topic and edit message actions. + // message/topic and edit message actions. DEPRECATED: Use + // DATA_LOSS_PREVENTION Annotation. DlpScanSummary *DlpScanSummary `json:"dlpScanSummary,omitempty"` // EditableBy: Indicates who can edit the message. This field is set on @@ -19928,6 +19856,7 @@ type RequiredMessageFeaturesMetadata struct { // "REQUIRED_FEATURE_MESSAGE_QUOTING" // "REQUIRED_FEATURE_TOMBSTONES_IN_DMS_AND_UFRS" // "REQUIRED_FEATURE_CUSTOM_HYPERLINK" + // "REQUIRED_FEATURE_SMART_CHIP" RequiredFeatures []string `json:"requiredFeatures,omitempty"` // ForceSendFields is a list of field names (e.g. "RequiredFeatures") to @@ -21471,6 +21400,9 @@ type Settings struct { // automatically join, everyone else must knock and be admitted. // (Subject to organization policies) Participants cannot dial out from // the meeting. And only hosts can accept knocks. + // "ACCESS_TYPE_CLOSED" - Only participants invited by a host can + // join. Knocking is not allowed, dial in and dial out are also + // disabled. AccessType string `json:"accessType,omitempty"` // AllowJoiningBeforeHost: Whether users can join before host in the diff --git a/cloudtasks/v2beta2/cloudtasks-api.json b/cloudtasks/v2beta2/cloudtasks-api.json index 9b5cda8ff33..5fcc92094c4 100644 --- a/cloudtasks/v2beta2/cloudtasks-api.json +++ b/cloudtasks/v2beta2/cloudtasks-api.json @@ -876,7 +876,7 @@ } } }, - "revision": "20230214", + "revision": "20230224", "rootUrl": "https://cloudtasks.googleapis.com/", "schemas": { "AcknowledgeTaskRequest": { @@ -1092,7 +1092,7 @@ }, "task": { "$ref": "Task", - "description": "Required. The task to add. Task names have the following format: `projects/PROJECT_ID/locations/LOCATION_ID/queues/QUEUE_ID/tasks/TASK_ID`. The user can optionally specify a task name. If a name is not specified then the system will generate a random unique task id, which will be set in the task returned in the response. If schedule_time is not set or is in the past then Cloud Tasks will set it to the current time. Task De-duplication: Explicitly specifying a task ID enables task de-duplication. If a task's ID is identical to that of an existing task or a task that was deleted or completed recently then the call will fail with ALREADY_EXISTS. If the task's queue was created using Cloud Tasks, then another task with the same name can't be created for ~1hour after the original task was deleted or completed. If the task's queue was created using queue.yaml or queue.xml, then another task with the same name can't be created for ~9days after the original task was deleted or completed. Because there is an extra lookup cost to identify duplicate task names, these CreateTask calls have significantly increased latency. Using hashed strings for the task id or for the prefix of the task id is recommended. Choosing task ids that are sequential or have sequential prefixes, for example using a timestamp, causes an increase in latency and error rates in all task commands. The infrastructure relies on an approximately uniform distribution of task ids to store and serve tasks efficiently." + "description": "Required. The task to add. Task names have the following format: `projects/PROJECT_ID/locations/LOCATION_ID/queues/QUEUE_ID/tasks/TASK_ID`. The user can optionally specify a task name. If a name is not specified then the system will generate a random unique task id, which will be set in the task returned in the response. If schedule_time is not set or is in the past then Cloud Tasks will set it to the current time. Task De-duplication: Explicitly specifying a task ID enables task de-duplication. If a task's ID is identical to that of an existing task or a task that was deleted or completed recently then the call will fail with ALREADY_EXISTS. If the task's queue was created using Cloud Tasks, then another task with the same name can't be created for ~1 hour after the original task was deleted or completed. If the task's queue was created using queue.yaml or queue.xml, then another task with the same name can't be created for ~9 days after the original task was deleted or completed. Because there is an extra lookup cost to identify duplicate task names, these CreateTask calls have significantly increased latency. Using hashed strings for the task id or for the prefix of the task id is recommended. Choosing task ids that are sequential or have sequential prefixes, for example using a timestamp, causes an increase in latency and error rates in all task commands. The infrastructure relies on an approximately uniform distribution of task ids to store and serve tasks efficiently." } }, "type": "object" @@ -1269,7 +1269,7 @@ "type": "array" }, "httpMethod": { - "description": "The HTTP method to use for the request. When specified, it will override HttpRequest for the task. Note that if the value is set to HttpMethod the HttpRequest of the task will be ignored at execution time.", + "description": "The HTTP method to use for the request. When specified, it overrides HttpRequest for the task. Note that if the value is set to HttpMethod the HttpRequest of the task will be ignored at execution time.", "enum": [ "HTTP_METHOD_UNSPECIFIED", "POST", @@ -1302,7 +1302,7 @@ }, "uriOverride": { "$ref": "UriOverride", - "description": "Uri override. When specified, modifies the execution Uri for all the tasks in the queue." + "description": "Uri override. When specified, overrides the execution Uri for all the tasks in the queue." } }, "type": "object" @@ -1479,7 +1479,7 @@ "id": "PathOverride", "properties": { "path": { - "description": "The URI path (e.g., a/b/c). Default is Empty string.", + "description": "The URI path (e.g., /users/1234). Default is an empty string.", "type": "string" } }, @@ -1548,7 +1548,7 @@ "id": "QueryOverride", "properties": { "queryParams": { - "description": "The query parameters (e.g., qparam1=123\u0026qparam2=456). Default is Empty string.", + "description": "The query parameters (e.g., qparam1=123\u0026qparam2=456). Default is an empty string.", "type": "string" } }, @@ -1921,21 +1921,21 @@ "id": "UriOverride", "properties": { "host": { - "description": "Host override. When specified, will replace the host part of the task URL. For example, if the task URL is \"https://www.google.com\", and host value is set to \"example.net\", the overridden URI will be changed to \"https://example.net\". Host value cannot be an empty string.", + "description": "Host override. When specified, replaces the host part of the task URL. For example, if the task URL is \"https://www.google.com,\" and host value is set to \"example.net\", the overridden URI will be changed to \"https://example.net.\" Host value cannot be an empty string (INVALID_ARGUMENT).", "type": "string" }, "pathOverride": { "$ref": "PathOverride", - "description": "URI path. When specified, will replace the existing path of the task URL. Setting the path value to an empty string clears the URI path segment." + "description": "URI path. When specified, replaces the existing path of the task URL. Setting the path value to an empty string clears the URI path segment." }, "port": { - "description": "Port override. When specified, will replace the port part of the task URI. For instance, for a URI http://www.google.com/foo and port=123, the overridden URI becomes http://www.google.com:123/foo. Note that the port value must be a positive integer. Setting the port to 0 (Zero) clears the URI port.", + "description": "Port override. When specified, replaces the port part of the task URI. For instance, for a URI http://www.google.com/foo and port=123, the overridden URI becomes http://www.google.com:123/foo. Note that the port value must be a positive integer. Setting the port to 0 (Zero) clears the URI port.", "format": "int64", "type": "string" }, "queryOverride": { "$ref": "QueryOverride", - "description": "URI Query. When specified, will replace the query part of the task URI. Setting the query value to an empty string clears the URI query segment." + "description": "URI Query. When specified, replaces the query part of the task URI. Setting the query value to an empty string clears the URI query segment." }, "scheme": { "description": "Scheme override. When specified, the task URI scheme is replaced by the provided value (HTTP or HTTPS).", diff --git a/cloudtasks/v2beta2/cloudtasks-gen.go b/cloudtasks/v2beta2/cloudtasks-gen.go index 059cbd024ab..285cb1515e7 100644 --- a/cloudtasks/v2beta2/cloudtasks-gen.go +++ b/cloudtasks/v2beta2/cloudtasks-gen.go @@ -778,10 +778,10 @@ type CreateTaskRequest struct { // that of an existing task or a task that was deleted or completed // recently then the call will fail with ALREADY_EXISTS. If the task's // queue was created using Cloud Tasks, then another task with the same - // name can't be created for ~1hour after the original task was deleted + // name can't be created for ~1 hour after the original task was deleted // or completed. If the task's queue was created using queue.yaml or // queue.xml, then another task with the same name can't be created for - // ~9days after the original task was deleted or completed. Because + // ~9 days after the original task was deleted or completed. Because // there is an extra lookup cost to identify duplicate task names, these // CreateTask calls have significantly increased latency. Using hashed // strings for the task id or for the prefix of the task id is @@ -1184,8 +1184,8 @@ type HttpTarget struct { HeaderOverrides []*HeaderOverride `json:"headerOverrides,omitempty"` // HttpMethod: The HTTP method to use for the request. When specified, - // it will override HttpRequest for the task. Note that if the value is - // set to HttpMethod the HttpRequest of the task will be ignored at + // it overrides HttpRequest for the task. Note that if the value is set + // to HttpMethod the HttpRequest of the task will be ignored at // execution time. // // Possible values: @@ -1214,8 +1214,8 @@ type HttpTarget struct { // to validate the token yourself. OidcToken *OidcToken `json:"oidcToken,omitempty"` - // UriOverride: Uri override. When specified, modifies the execution Uri - // for all the tasks in the queue. + // UriOverride: Uri override. When specified, overrides the execution + // Uri for all the tasks in the queue. UriOverride *UriOverride `json:"uriOverride,omitempty"` // ForceSendFields is a list of field names (e.g. "HeaderOverrides") to @@ -1606,7 +1606,7 @@ func (s *OidcToken) MarshalJSON() ([]byte, error) { // PathOverride: PathOverride. Path message defines path override for // HTTP targets. type PathOverride struct { - // Path: The URI path (e.g., a/b/c). Default is Empty string. + // Path: The URI path (e.g., /users/1234). Default is an empty string. Path string `json:"path,omitempty"` // ForceSendFields is a list of field names (e.g. "Path") to @@ -1798,7 +1798,7 @@ type PurgeQueueRequest struct { // for HTTP targets. type QueryOverride struct { // QueryParams: The query parameters (e.g., qparam1=123&qparam2=456). - // Default is Empty string. + // Default is an empty string. QueryParams string `json:"queryParams,omitempty"` // ForceSendFields is a list of field names (e.g. "QueryParams") to @@ -2603,28 +2603,28 @@ func (s *TestIamPermissionsResponse) MarshalJSON() ([]byte, error) { // the queue will be partially or fully overridden depending on the // configured values. type UriOverride struct { - // Host: Host override. When specified, will replace the host part of - // the task URL. For example, if the task URL is - // "https://www.google.com", and host value is set to "example.net", the - // overridden URI will be changed to "https://example.net". Host value - // cannot be an empty string. + // Host: Host override. When specified, replaces the host part of the + // task URL. For example, if the task URL is "https://www.google.com," + // and host value is set to "example.net", the overridden URI will be + // changed to "https://example.net." Host value cannot be an empty + // string (INVALID_ARGUMENT). Host string `json:"host,omitempty"` - // PathOverride: URI path. When specified, will replace the existing - // path of the task URL. Setting the path value to an empty string - // clears the URI path segment. + // PathOverride: URI path. When specified, replaces the existing path of + // the task URL. Setting the path value to an empty string clears the + // URI path segment. PathOverride *PathOverride `json:"pathOverride,omitempty"` - // Port: Port override. When specified, will replace the port part of - // the task URI. For instance, for a URI http://www.google.com/foo and + // Port: Port override. When specified, replaces the port part of the + // task URI. For instance, for a URI http://www.google.com/foo and // port=123, the overridden URI becomes http://www.google.com:123/foo. // Note that the port value must be a positive integer. Setting the port // to 0 (Zero) clears the URI port. Port int64 `json:"port,omitempty,string"` - // QueryOverride: URI Query. When specified, will replace the query part - // of the task URI. Setting the query value to an empty string clears - // the URI query segment. + // QueryOverride: URI Query. When specified, replaces the query part of + // the task URI. Setting the query value to an empty string clears the + // URI query segment. QueryOverride *QueryOverride `json:"queryOverride,omitempty"` // Scheme: Scheme override. When specified, the task URI scheme is diff --git a/cloudtasks/v2beta3/cloudtasks-api.json b/cloudtasks/v2beta3/cloudtasks-api.json index 8694da295e4..54f7d27796c 100644 --- a/cloudtasks/v2beta3/cloudtasks-api.json +++ b/cloudtasks/v2beta3/cloudtasks-api.json @@ -732,7 +732,7 @@ } } }, - "revision": "20230214", + "revision": "20230224", "rootUrl": "https://cloudtasks.googleapis.com/", "schemas": { "AppEngineHttpQueue": { @@ -910,7 +910,7 @@ }, "task": { "$ref": "Task", - "description": "Required. The task to add. Task names have the following format: `projects/PROJECT_ID/locations/LOCATION_ID/queues/QUEUE_ID/tasks/TASK_ID`. The user can optionally specify a task name. If a name is not specified then the system will generate a random unique task id, which will be set in the task returned in the response. If schedule_time is not set or is in the past then Cloud Tasks will set it to the current time. Task De-duplication: Explicitly specifying a task ID enables task de-duplication. If a task's ID is identical to that of an existing task or a task that was deleted or executed recently then the call will fail with ALREADY_EXISTS. If the task's queue was created using Cloud Tasks, then another task with the same name can't be created for ~1hour after the original task was deleted or executed. If the task's queue was created using queue.yaml or queue.xml, then another task with the same name can't be created for ~9days after the original task was deleted or executed. Because there is an extra lookup cost to identify duplicate task names, these CreateTask calls have significantly increased latency. Using hashed strings for the task id or for the prefix of the task id is recommended. Choosing task ids that are sequential or have sequential prefixes, for example using a timestamp, causes an increase in latency and error rates in all task commands. The infrastructure relies on an approximately uniform distribution of task ids to store and serve tasks efficiently." + "description": "Required. The task to add. Task names have the following format: `projects/PROJECT_ID/locations/LOCATION_ID/queues/QUEUE_ID/tasks/TASK_ID`. The user can optionally specify a task name. If a name is not specified then the system will generate a random unique task id, which will be set in the task returned in the response. If schedule_time is not set or is in the past then Cloud Tasks will set it to the current time. Task De-duplication: Explicitly specifying a task ID enables task de-duplication. If a task's ID is identical to that of an existing task or a task that was deleted or executed recently then the call will fail with ALREADY_EXISTS. If the task's queue was created using Cloud Tasks, then another task with the same name can't be created for ~1 hour after the original task was deleted or executed. If the task's queue was created using queue.yaml or queue.xml, then another task with the same name can't be created for ~9 days after the original task was deleted or executed. Because there is an extra lookup cost to identify duplicate task names, these CreateTask calls have significantly increased latency. Using hashed strings for the task id or for the prefix of the task id is recommended. Choosing task ids that are sequential or have sequential prefixes, for example using a timestamp, causes an increase in latency and error rates in all task commands. The infrastructure relies on an approximately uniform distribution of task ids to store and serve tasks efficiently." } }, "type": "object" @@ -1087,7 +1087,7 @@ "type": "array" }, "httpMethod": { - "description": "The HTTP method to use for the request. When specified, it will override HttpRequest for the task. Note that if the value is set to HttpMethod the HttpRequest of the task will be ignored at execution time.", + "description": "The HTTP method to use for the request. When specified, it overrides HttpRequest for the task. Note that if the value is set to HttpMethod the HttpRequest of the task will be ignored at execution time.", "enum": [ "HTTP_METHOD_UNSPECIFIED", "POST", @@ -1112,7 +1112,7 @@ }, "uriOverride": { "$ref": "UriOverride", - "description": "URI override. When specified, modifies the execution URI for all the tasks in the queue." + "description": "URI override. When specified, overrides the execution URI for all the tasks in the queue." } }, "type": "object" @@ -1240,7 +1240,7 @@ "id": "PathOverride", "properties": { "path": { - "description": "The URI path (e.g., a/b/c). Default is Empty string.", + "description": "The URI path (e.g., /users/1234). Default is an empty string.", "type": "string" } }, @@ -1303,7 +1303,7 @@ "id": "QueryOverride", "properties": { "queryParams": { - "description": "The query parameters (e.g., qparam1=123\u0026qparam2=456). Default is Empty string.", + "description": "The query parameters (e.g., qparam1=123\u0026qparam2=456). Default is an empty string.", "type": "string" } }, @@ -1661,21 +1661,21 @@ "id": "UriOverride", "properties": { "host": { - "description": "Host override. When specified, will replace the host part of the task URL. For example, if the task URL is \"https://www.google.com\", and host value is set to \"example.net\", the overridden URI will be changed to \"https://example.net\". Host value cannot be an empty string.", + "description": "Host override. When specified, replaces the host part of the task URL. For example, if the task URL is \"https://www.google.com,\" and host value is set to \"example.net\", the overridden URI will be changed to \"https://example.net.\" Host value cannot be an empty string (INVALID_ARGUMENT).", "type": "string" }, "pathOverride": { "$ref": "PathOverride", - "description": "URI path. When specified, will replace the existing path of the task URL. Setting the path value to an empty string clears the URI path segment." + "description": "URI path. When specified, replaces the existing path of the task URL. Setting the path value to an empty string clears the URI path segment." }, "port": { - "description": "Port override. When specified, will replace the port part of the task URI. For instance, for a URI http://www.google.com/foo and port=123, the overridden URI becomes http://www.google.com:123/foo. Note that the port value must be a positive integer. Setting the port to 0 (Zero) clears the URI port.", + "description": "Port override. When specified, replaces the port part of the task URI. For instance, for a URI http://www.google.com/foo and port=123, the overridden URI becomes http://www.google.com:123/foo. Note that the port value must be a positive integer. Setting the port to 0 (Zero) clears the URI port.", "format": "int64", "type": "string" }, "queryOverride": { "$ref": "QueryOverride", - "description": "URI Query. When specified, will replace the query part of the task URI. Setting the query value to an empty string clears the URI query segment." + "description": "URI Query. When specified, replaces the query part of the task URI. Setting the query value to an empty string clears the URI query segment." }, "scheme": { "description": "Scheme override. When specified, the task URI scheme is replaced by the provided value (HTTP or HTTPS).", diff --git a/cloudtasks/v2beta3/cloudtasks-gen.go b/cloudtasks/v2beta3/cloudtasks-gen.go index 00924de2b8b..6e3fbcfbcec 100644 --- a/cloudtasks/v2beta3/cloudtasks-gen.go +++ b/cloudtasks/v2beta3/cloudtasks-gen.go @@ -647,11 +647,11 @@ type CreateTaskRequest struct { // that of an existing task or a task that was deleted or executed // recently then the call will fail with ALREADY_EXISTS. If the task's // queue was created using Cloud Tasks, then another task with the same - // name can't be created for ~1hour after the original task was deleted + // name can't be created for ~1 hour after the original task was deleted // or executed. If the task's queue was created using queue.yaml or // queue.xml, then another task with the same name can't be created for - // ~9days after the original task was deleted or executed. Because there - // is an extra lookup cost to identify duplicate task names, these + // ~9 days after the original task was deleted or executed. Because + // there is an extra lookup cost to identify duplicate task names, these // CreateTask calls have significantly increased latency. Using hashed // strings for the task id or for the prefix of the task id is // recommended. Choosing task ids that are sequential or have sequential @@ -1069,8 +1069,8 @@ type HttpTarget struct { HeaderOverrides []*HeaderOverride `json:"headerOverrides,omitempty"` // HttpMethod: The HTTP method to use for the request. When specified, - // it will override HttpRequest for the task. Note that if the value is - // set to HttpMethod the HttpRequest of the task will be ignored at + // it overrides HttpRequest for the task. Note that if the value is set + // to HttpMethod the HttpRequest of the task will be ignored at // execution time. // // Possible values: @@ -1084,8 +1084,8 @@ type HttpTarget struct { // "OPTIONS" - HTTP OPTIONS HttpMethod string `json:"httpMethod,omitempty"` - // UriOverride: URI override. When specified, modifies the execution URI - // for all the tasks in the queue. + // UriOverride: URI override. When specified, overrides the execution + // URI for all the tasks in the queue. UriOverride *UriOverride `json:"uriOverride,omitempty"` // ForceSendFields is a list of field names (e.g. "HeaderOverrides") to @@ -1360,7 +1360,7 @@ func (s *OidcToken) MarshalJSON() ([]byte, error) { // PathOverride: PathOverride. Path message defines path override for // HTTP targets. type PathOverride struct { - // Path: The URI path (e.g., a/b/c). Default is Empty string. + // Path: The URI path (e.g., /users/1234). Default is an empty string. Path string `json:"path,omitempty"` // ForceSendFields is a list of field names (e.g. "Path") to @@ -1545,7 +1545,7 @@ type PurgeQueueRequest struct { // for HTTP targets. type QueryOverride struct { // QueryParams: The query parameters (e.g., qparam1=123&qparam2=456). - // Default is Empty string. + // Default is an empty string. QueryParams string `json:"queryParams,omitempty"` // ForceSendFields is a list of field names (e.g. "QueryParams") to @@ -2336,28 +2336,28 @@ func (s *TestIamPermissionsResponse) MarshalJSON() ([]byte, error) { // the queue will be partially or fully overridden depending on the // configured values. type UriOverride struct { - // Host: Host override. When specified, will replace the host part of - // the task URL. For example, if the task URL is - // "https://www.google.com", and host value is set to "example.net", the - // overridden URI will be changed to "https://example.net". Host value - // cannot be an empty string. + // Host: Host override. When specified, replaces the host part of the + // task URL. For example, if the task URL is "https://www.google.com," + // and host value is set to "example.net", the overridden URI will be + // changed to "https://example.net." Host value cannot be an empty + // string (INVALID_ARGUMENT). Host string `json:"host,omitempty"` - // PathOverride: URI path. When specified, will replace the existing - // path of the task URL. Setting the path value to an empty string - // clears the URI path segment. + // PathOverride: URI path. When specified, replaces the existing path of + // the task URL. Setting the path value to an empty string clears the + // URI path segment. PathOverride *PathOverride `json:"pathOverride,omitempty"` - // Port: Port override. When specified, will replace the port part of - // the task URI. For instance, for a URI http://www.google.com/foo and + // Port: Port override. When specified, replaces the port part of the + // task URI. For instance, for a URI http://www.google.com/foo and // port=123, the overridden URI becomes http://www.google.com:123/foo. // Note that the port value must be a positive integer. Setting the port // to 0 (Zero) clears the URI port. Port int64 `json:"port,omitempty,string"` - // QueryOverride: URI Query. When specified, will replace the query part - // of the task URI. Setting the query value to an empty string clears - // the URI query segment. + // QueryOverride: URI Query. When specified, replaces the query part of + // the task URI. Setting the query value to an empty string clears the + // URI query segment. QueryOverride *QueryOverride `json:"queryOverride,omitempty"` // Scheme: Scheme override. When specified, the task URI scheme is diff --git a/contactcenterinsights/v1/contactcenterinsights-api.json b/contactcenterinsights/v1/contactcenterinsights-api.json index 3a4558ca892..d3afdd5f6df 100644 --- a/contactcenterinsights/v1/contactcenterinsights-api.json +++ b/contactcenterinsights/v1/contactcenterinsights-api.json @@ -1000,7 +1000,7 @@ ] }, "list": { - "description": "Lists operations that match the specified filter in the request. If the server doesn't support this method, it returns `UNIMPLEMENTED`. NOTE: the `name` binding allows API services to override the binding to use different resource name schemes, such as `users/*/operations`. To override the binding, API services can add a binding such as `\"/v1/{name=users/*}/operations\"` to their service configuration. For backwards compatibility, the default name includes the operations collection id, however overriding users must ensure the name binding is the parent resource, without the operations collection id.", + "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}/operations", "httpMethod": "GET", "id": "contactcenterinsights.projects.locations.operations.list", @@ -1356,7 +1356,7 @@ } } }, - "revision": "20230226", + "revision": "20230304", "rootUrl": "https://contactcenterinsights.googleapis.com/", "schemas": { "GoogleCloudContactcenterinsightsV1Analysis": { @@ -2153,6 +2153,29 @@ }, "type": "object" }, + "GoogleCloudContactcenterinsightsV1CreateIssueMetadata": { + "description": "Metadata for creating an issue.", + "id": "GoogleCloudContactcenterinsightsV1CreateIssueMetadata", + "properties": { + "createTime": { + "description": "Output only. The time the operation was created.", + "format": "google-datetime", + "readOnly": true, + "type": "string" + }, + "endTime": { + "description": "Output only. The time the operation finished running.", + "format": "google-datetime", + "readOnly": true, + "type": "string" + }, + "request": { + "$ref": "GoogleCloudContactcenterinsightsV1CreateIssueRequest", + "description": "The original request for creation." + } + }, + "type": "object" + }, "GoogleCloudContactcenterinsightsV1CreateIssueModelMetadata": { "description": "Metadata for creating an issue model.", "id": "GoogleCloudContactcenterinsightsV1CreateIssueModelMetadata", @@ -2191,6 +2214,21 @@ }, "type": "object" }, + "GoogleCloudContactcenterinsightsV1CreateIssueRequest": { + "description": "The request to create an issue.", + "id": "GoogleCloudContactcenterinsightsV1CreateIssueRequest", + "properties": { + "issue": { + "$ref": "GoogleCloudContactcenterinsightsV1Issue", + "description": "Required. The values for the new issue." + }, + "parent": { + "description": "Required. The parent resource of the issue.", + "type": "string" + } + }, + "type": "object" + }, "GoogleCloudContactcenterinsightsV1DeleteIssueModelMetadata": { "description": "Metadata for deleting an issue model.", "id": "GoogleCloudContactcenterinsightsV1DeleteIssueModelMetadata", diff --git a/contactcenterinsights/v1/contactcenterinsights-gen.go b/contactcenterinsights/v1/contactcenterinsights-gen.go index aef558060c8..b98feecd4a1 100644 --- a/contactcenterinsights/v1/contactcenterinsights-gen.go +++ b/contactcenterinsights/v1/contactcenterinsights-gen.go @@ -1474,6 +1474,41 @@ func (s *GoogleCloudContactcenterinsightsV1CreateAnalysisOperationMetadata) Mars return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } +// GoogleCloudContactcenterinsightsV1CreateIssueMetadata: Metadata for +// creating an issue. +type GoogleCloudContactcenterinsightsV1CreateIssueMetadata struct { + // CreateTime: Output only. The time the operation was created. + CreateTime string `json:"createTime,omitempty"` + + // EndTime: Output only. The time the operation finished running. + EndTime string `json:"endTime,omitempty"` + + // Request: The original request for creation. + Request *GoogleCloudContactcenterinsightsV1CreateIssueRequest `json:"request,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 *GoogleCloudContactcenterinsightsV1CreateIssueMetadata) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudContactcenterinsightsV1CreateIssueMetadata + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + // GoogleCloudContactcenterinsightsV1CreateIssueModelMetadata: Metadata // for creating an issue model. type GoogleCloudContactcenterinsightsV1CreateIssueModelMetadata struct { @@ -1541,6 +1576,38 @@ func (s *GoogleCloudContactcenterinsightsV1CreateIssueModelRequest) MarshalJSON( return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } +// GoogleCloudContactcenterinsightsV1CreateIssueRequest: The request to +// create an issue. +type GoogleCloudContactcenterinsightsV1CreateIssueRequest struct { + // Issue: Required. The values for the new issue. + Issue *GoogleCloudContactcenterinsightsV1Issue `json:"issue,omitempty"` + + // Parent: Required. The parent resource of the issue. + Parent string `json:"parent,omitempty"` + + // ForceSendFields is a list of field names (e.g. "Issue") 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. "Issue") 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 *GoogleCloudContactcenterinsightsV1CreateIssueRequest) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudContactcenterinsightsV1CreateIssueRequest + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + // GoogleCloudContactcenterinsightsV1DeleteIssueModelMetadata: Metadata // for deleting an issue model. type GoogleCloudContactcenterinsightsV1DeleteIssueModelMetadata struct { @@ -9485,14 +9552,7 @@ type ProjectsLocationsOperationsListCall struct { // List: Lists operations that match the specified filter in the // request. If the server doesn't support this method, it returns -// `UNIMPLEMENTED`. NOTE: the `name` binding allows API services to -// override the binding to use different resource name schemes, such as -// `users/*/operations`. To override the binding, API services can add a -// binding such as "/v1/{name=users/*}/operations" to their service -// configuration. For backwards compatibility, the default name includes -// the operations collection id, however overriding users must ensure -// the name binding is the parent resource, without the operations -// collection id. +// `UNIMPLEMENTED`. // // - name: The name of the operation's parent resource. func (r *ProjectsLocationsOperationsService) List(name string) *ProjectsLocationsOperationsListCall { @@ -9622,7 +9682,7 @@ func (c *ProjectsLocationsOperationsListCall) Do(opts ...googleapi.CallOption) ( } 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`. NOTE: the `name` binding allows API services to override the binding to use different resource name schemes, such as `users/*/operations`. To override the binding, API services can add a binding such as `\"/v1/{name=users/*}/operations\"` to their service configuration. For backwards compatibility, the default name includes the operations collection id, however overriding users must ensure the name binding is the parent resource, without the operations collection id.", + // "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}/operations", // "httpMethod": "GET", // "id": "contactcenterinsights.projects.locations.operations.list", diff --git a/datastore/v1/datastore-api.json b/datastore/v1/datastore-api.json index c50dd504090..29c8bb4bca9 100644 --- a/datastore/v1/datastore-api.json +++ b/datastore/v1/datastore-api.json @@ -654,7 +654,7 @@ } } }, - "revision": "20230126", + "revision": "20230228", "rootUrl": "https://datastore.googleapis.com/", "schemas": { "Aggregation": { @@ -894,11 +894,13 @@ "description": "The operator for combining multiple filters.", "enum": [ "OPERATOR_UNSPECIFIED", - "AND" + "AND", + "OR" ], "enumDescriptions": [ "Unspecified. This value must not be used.", - "The results are required to satisfy each of the combined filters." + "The results are required to satisfy each of the combined filters.", + "Documents are required to satisfy at least one of the combined filters." ], "type": "string" } diff --git a/datastore/v1/datastore-gen.go b/datastore/v1/datastore-gen.go index 30dc9749d9a..628e9d39bbb 100644 --- a/datastore/v1/datastore-gen.go +++ b/datastore/v1/datastore-gen.go @@ -619,6 +619,8 @@ type CompositeFilter struct { // "OPERATOR_UNSPECIFIED" - Unspecified. This value must not be used. // "AND" - The results are required to satisfy each of the combined // filters. + // "OR" - Documents are required to satisfy at least one of the + // combined filters. Op string `json:"op,omitempty"` // ForceSendFields is a list of field names (e.g. "Filters") to diff --git a/datastore/v1beta3/datastore-api.json b/datastore/v1beta3/datastore-api.json index 65e933e3918..2512060a24e 100644 --- a/datastore/v1beta3/datastore-api.json +++ b/datastore/v1beta3/datastore-api.json @@ -336,7 +336,7 @@ } } }, - "revision": "20230118", + "revision": "20230228", "rootUrl": "https://datastore.googleapis.com/", "schemas": { "Aggregation": { @@ -560,11 +560,13 @@ "description": "The operator for combining multiple filters.", "enum": [ "OPERATOR_UNSPECIFIED", - "AND" + "AND", + "OR" ], "enumDescriptions": [ "Unspecified. This value must not be used.", - "The results are required to satisfy each of the combined filters." + "The results are required to satisfy each of the combined filters.", + "Documents are required to satisfy at least one of the combined filters." ], "type": "string" } diff --git a/datastore/v1beta3/datastore-gen.go b/datastore/v1beta3/datastore-gen.go index 94008475101..2e80335ef3a 100644 --- a/datastore/v1beta3/datastore-gen.go +++ b/datastore/v1beta3/datastore-gen.go @@ -575,6 +575,8 @@ type CompositeFilter struct { // "OPERATOR_UNSPECIFIED" - Unspecified. This value must not be used. // "AND" - The results are required to satisfy each of the combined // filters. + // "OR" - Documents are required to satisfy at least one of the + // combined filters. Op string `json:"op,omitempty"` // ForceSendFields is a list of field names (e.g. "Filters") to diff --git a/discoveryengine/v1alpha/discoveryengine-api.json b/discoveryengine/v1alpha/discoveryengine-api.json index 6cbe5bed152..2b83a7fd01e 100644 --- a/discoveryengine/v1alpha/discoveryengine-api.json +++ b/discoveryengine/v1alpha/discoveryengine-api.json @@ -298,6 +298,220 @@ ] } } + }, + "operations": { + "methods": { + "get": { + "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": "v1alpha/projects/{projectsId}/locations/{locationsId}/collections/{collectionsId}/dataStores/{dataStoresId}/branches/{branchesId}/operations/{operationsId}", + "httpMethod": "GET", + "id": "discoveryengine.projects.locations.collections.dataStores.branches.operations.get", + "parameterOrder": [ + "name" + ], + "parameters": { + "name": { + "description": "The name of the operation resource.", + "location": "path", + "pattern": "^projects/[^/]+/locations/[^/]+/collections/[^/]+/dataStores/[^/]+/branches/[^/]+/operations/[^/]+$", + "required": true, + "type": "string" + } + }, + "path": "v1alpha/{+name}", + "response": { + "$ref": "GoogleLongrunningOperation" + }, + "scopes": [ + "https://www.googleapis.com/auth/cloud-platform" + ] + }, + "list": { + "description": "Lists operations that match the specified filter in the request. If the server doesn't support this method, it returns `UNIMPLEMENTED`.", + "flatPath": "v1alpha/projects/{projectsId}/locations/{locationsId}/collections/{collectionsId}/dataStores/{dataStoresId}/branches/{branchesId}/operations", + "httpMethod": "GET", + "id": "discoveryengine.projects.locations.collections.dataStores.branches.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/[^/]+/collections/[^/]+/dataStores/[^/]+/branches/[^/]+$", + "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": "v1alpha/{+name}/operations", + "response": { + "$ref": "GoogleLongrunningListOperationsResponse" + }, + "scopes": [ + "https://www.googleapis.com/auth/cloud-platform" + ] + } + } + } + } + }, + "models": { + "resources": { + "operations": { + "methods": { + "get": { + "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": "v1alpha/projects/{projectsId}/locations/{locationsId}/collections/{collectionsId}/dataStores/{dataStoresId}/models/{modelsId}/operations/{operationsId}", + "httpMethod": "GET", + "id": "discoveryengine.projects.locations.collections.dataStores.models.operations.get", + "parameterOrder": [ + "name" + ], + "parameters": { + "name": { + "description": "The name of the operation resource.", + "location": "path", + "pattern": "^projects/[^/]+/locations/[^/]+/collections/[^/]+/dataStores/[^/]+/models/[^/]+/operations/[^/]+$", + "required": true, + "type": "string" + } + }, + "path": "v1alpha/{+name}", + "response": { + "$ref": "GoogleLongrunningOperation" + }, + "scopes": [ + "https://www.googleapis.com/auth/cloud-platform" + ] + }, + "list": { + "description": "Lists operations that match the specified filter in the request. If the server doesn't support this method, it returns `UNIMPLEMENTED`.", + "flatPath": "v1alpha/projects/{projectsId}/locations/{locationsId}/collections/{collectionsId}/dataStores/{dataStoresId}/models/{modelsId}/operations", + "httpMethod": "GET", + "id": "discoveryengine.projects.locations.collections.dataStores.models.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/[^/]+/collections/[^/]+/dataStores/[^/]+/models/[^/]+$", + "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": "v1alpha/{+name}/operations", + "response": { + "$ref": "GoogleLongrunningListOperationsResponse" + }, + "scopes": [ + "https://www.googleapis.com/auth/cloud-platform" + ] + } + } + } + } + }, + "operations": { + "methods": { + "get": { + "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": "v1alpha/projects/{projectsId}/locations/{locationsId}/collections/{collectionsId}/dataStores/{dataStoresId}/operations/{operationsId}", + "httpMethod": "GET", + "id": "discoveryengine.projects.locations.collections.dataStores.operations.get", + "parameterOrder": [ + "name" + ], + "parameters": { + "name": { + "description": "The name of the operation resource.", + "location": "path", + "pattern": "^projects/[^/]+/locations/[^/]+/collections/[^/]+/dataStores/[^/]+/operations/[^/]+$", + "required": true, + "type": "string" + } + }, + "path": "v1alpha/{+name}", + "response": { + "$ref": "GoogleLongrunningOperation" + }, + "scopes": [ + "https://www.googleapis.com/auth/cloud-platform" + ] + }, + "list": { + "description": "Lists operations that match the specified filter in the request. If the server doesn't support this method, it returns `UNIMPLEMENTED`.", + "flatPath": "v1alpha/projects/{projectsId}/locations/{locationsId}/collections/{collectionsId}/dataStores/{dataStoresId}/operations", + "httpMethod": "GET", + "id": "discoveryengine.projects.locations.collections.dataStores.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/[^/]+/collections/[^/]+/dataStores/[^/]+$", + "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": "v1alpha/{+name}/operations", + "response": { + "$ref": "GoogleLongrunningListOperationsResponse" + }, + "scopes": [ + "https://www.googleapis.com/auth/cloud-platform" + ] } } }, @@ -435,6 +649,76 @@ } } } + }, + "operations": { + "methods": { + "get": { + "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": "v1alpha/projects/{projectsId}/locations/{locationsId}/collections/{collectionsId}/operations/{operationsId}", + "httpMethod": "GET", + "id": "discoveryengine.projects.locations.collections.operations.get", + "parameterOrder": [ + "name" + ], + "parameters": { + "name": { + "description": "The name of the operation resource.", + "location": "path", + "pattern": "^projects/[^/]+/locations/[^/]+/collections/[^/]+/operations/[^/]+$", + "required": true, + "type": "string" + } + }, + "path": "v1alpha/{+name}", + "response": { + "$ref": "GoogleLongrunningOperation" + }, + "scopes": [ + "https://www.googleapis.com/auth/cloud-platform" + ] + }, + "list": { + "description": "Lists operations that match the specified filter in the request. If the server doesn't support this method, it returns `UNIMPLEMENTED`.", + "flatPath": "v1alpha/projects/{projectsId}/locations/{locationsId}/collections/{collectionsId}/operations", + "httpMethod": "GET", + "id": "discoveryengine.projects.locations.collections.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/[^/]+/collections/[^/]+$", + "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": "v1alpha/{+name}/operations", + "response": { + "$ref": "GoogleLongrunningListOperationsResponse" + }, + "scopes": [ + "https://www.googleapis.com/auth/cloud-platform" + ] + } + } } } }, @@ -654,7 +938,7 @@ ] }, "list": { - "description": "Lists operations that match the specified filter in the request. If the server doesn't support this method, it returns `UNIMPLEMENTED`. NOTE: the `name` binding allows API services to override the binding to use different resource name schemes, such as `users/*/operations`. To override the binding, API services can add a binding such as `\"/v1/{name=users/*}/operations\"` to their service configuration. For backwards compatibility, the default name includes the operations collection id, however overriding users must ensure the name binding is the parent resource, without the operations collection id.", + "description": "Lists operations that match the specified filter in the request. If the server doesn't support this method, it returns `UNIMPLEMENTED`.", "flatPath": "v1alpha/projects/{projectsId}/locations/{locationsId}/dataStores/{dataStoresId}/branches/{branchesId}/operations", "httpMethod": "GET", "id": "discoveryengine.projects.locations.dataStores.branches.operations.list", @@ -728,7 +1012,7 @@ ] }, "list": { - "description": "Lists operations that match the specified filter in the request. If the server doesn't support this method, it returns `UNIMPLEMENTED`. NOTE: the `name` binding allows API services to override the binding to use different resource name schemes, such as `users/*/operations`. To override the binding, API services can add a binding such as `\"/v1/{name=users/*}/operations\"` to their service configuration. For backwards compatibility, the default name includes the operations collection id, however overriding users must ensure the name binding is the parent resource, without the operations collection id.", + "description": "Lists operations that match the specified filter in the request. If the server doesn't support this method, it returns `UNIMPLEMENTED`.", "flatPath": "v1alpha/projects/{projectsId}/locations/{locationsId}/dataStores/{dataStoresId}/models/{modelsId}/operations", "httpMethod": "GET", "id": "discoveryengine.projects.locations.dataStores.models.operations.list", @@ -800,7 +1084,7 @@ ] }, "list": { - "description": "Lists operations that match the specified filter in the request. If the server doesn't support this method, it returns `UNIMPLEMENTED`. NOTE: the `name` binding allows API services to override the binding to use different resource name schemes, such as `users/*/operations`. To override the binding, API services can add a binding such as `\"/v1/{name=users/*}/operations\"` to their service configuration. For backwards compatibility, the default name includes the operations collection id, however overriding users must ensure the name binding is the parent resource, without the operations collection id.", + "description": "Lists operations that match the specified filter in the request. If the server doesn't support this method, it returns `UNIMPLEMENTED`.", "flatPath": "v1alpha/projects/{projectsId}/locations/{locationsId}/dataStores/{dataStoresId}/operations", "httpMethod": "GET", "id": "discoveryengine.projects.locations.dataStores.operations.list", @@ -1005,7 +1289,7 @@ ] }, "list": { - "description": "Lists operations that match the specified filter in the request. If the server doesn't support this method, it returns `UNIMPLEMENTED`. NOTE: the `name` binding allows API services to override the binding to use different resource name schemes, such as `users/*/operations`. To override the binding, API services can add a binding such as `\"/v1/{name=users/*}/operations\"` to their service configuration. For backwards compatibility, the default name includes the operations collection id, however overriding users must ensure the name binding is the parent resource, without the operations collection id.", + "description": "Lists operations that match the specified filter in the request. If the server doesn't support this method, it returns `UNIMPLEMENTED`.", "flatPath": "v1alpha/projects/{projectsId}/locations/{locationsId}/operations", "httpMethod": "GET", "id": "discoveryengine.projects.locations.operations.list", @@ -1077,7 +1361,7 @@ ] }, "list": { - "description": "Lists operations that match the specified filter in the request. If the server doesn't support this method, it returns `UNIMPLEMENTED`. NOTE: the `name` binding allows API services to override the binding to use different resource name schemes, such as `users/*/operations`. To override the binding, API services can add a binding such as `\"/v1/{name=users/*}/operations\"` to their service configuration. For backwards compatibility, the default name includes the operations collection id, however overriding users must ensure the name binding is the parent resource, without the operations collection id.", + "description": "Lists operations that match the specified filter in the request. If the server doesn't support this method, it returns `UNIMPLEMENTED`.", "flatPath": "v1alpha/projects/{projectsId}/operations", "httpMethod": "GET", "id": "discoveryengine.projects.operations.list", @@ -1122,7 +1406,7 @@ } } }, - "revision": "20230227", + "revision": "20230306", "rootUrl": "https://discoveryengine.googleapis.com/", "schemas": { "GoogleApiHttpBody": { @@ -1302,6 +1586,155 @@ }, "type": "object" }, + "GoogleCloudDiscoveryengineV1alphaCondition": { + "description": "Defines circumstances to be checked before allowing a behavior", + "id": "GoogleCloudDiscoveryengineV1alphaCondition", + "properties": { + "activeTimeRange": { + "description": "Optional. Range of time(s) specifying when condition is active. Maximum of 10 time ranges.", + "items": { + "$ref": "GoogleCloudDiscoveryengineV1alphaConditionTimeRange" + }, + "type": "array" + }, + "queryTerms": { + "description": "Optional. Search only A list of terms to match the query on. Maximum of 10 query terms.", + "items": { + "$ref": "GoogleCloudDiscoveryengineV1alphaConditionQueryTerm" + }, + "type": "array" + } + }, + "type": "object" + }, + "GoogleCloudDiscoveryengineV1alphaConditionQueryTerm": { + "description": "Matcher for search request query", + "id": "GoogleCloudDiscoveryengineV1alphaConditionQueryTerm", + "properties": { + "fullMatch": { + "description": "Whether the search query needs to exactly match the query term.", + "type": "boolean" + }, + "value": { + "description": "The specific query value to match against Must be lowercase, must be UTF-8. Can have at most 3 space separated terms if full_match is true. Cannot be an empty string. Maximum length of 5000 characters.", + "type": "string" + } + }, + "type": "object" + }, + "GoogleCloudDiscoveryengineV1alphaConditionTimeRange": { + "description": "Used for time-dependent conditions.", + "id": "GoogleCloudDiscoveryengineV1alphaConditionTimeRange", + "properties": { + "endTime": { + "description": "End of time range. Range is inclusive. Must be in the future.", + "format": "google-datetime", + "type": "string" + }, + "startTime": { + "description": "Start of time range. Range is inclusive.", + "format": "google-datetime", + "type": "string" + } + }, + "type": "object" + }, + "GoogleCloudDiscoveryengineV1alphaControl": { + "description": "Defines a conditioned behavior to employ during serving. Must be attached to a [ServingConfig] to be considered at serving time. Permitted actions dependent on Solution Type.", + "id": "GoogleCloudDiscoveryengineV1alphaControl", + "properties": { + "associatedServingConfigIds": { + "description": "Output only. List of all [ServingConfig] ids this control is attached to. May take up to 10 minutes to update after changes.", + "items": { + "type": "string" + }, + "readOnly": true, + "type": "array" + }, + "boostAction": { + "$ref": "GoogleCloudDiscoveryengineV1alphaControlBoostAction", + "description": "Defines a boost-type control" + }, + "conditions": { + "description": "Determines when the associated action will trigger. Omit to always apply the action. Currently only a single condition may be specified. Otherwise an INVALID ARGUMENT error is thrown.", + "items": { + "$ref": "GoogleCloudDiscoveryengineV1alphaCondition" + }, + "type": "array" + }, + "displayName": { + "description": "Required. Human readable name. The identifier used in UI views. Must be UTF-8 encoded string. Length limit is 128 characters. Otherwise an INVALID ARGUMENT error is thrown.", + "type": "string" + }, + "filterAction": { + "$ref": "GoogleCloudDiscoveryengineV1alphaControlFilterAction", + "description": "Defines a filter-type control Currently not supported by Recommendation" + }, + "name": { + "description": "Immutable. Fully qualified name `projects/*/locations/global/dataStore/*/controls/*`", + "type": "string" + }, + "solutionType": { + "description": "Required. What solution the control belongs to. Must be compatible with vertical of resource. Otherwise an INVALID ARGUMENT error is thrown.", + "enum": [ + "SOLUTION_TYPE_UNSPECIFIED", + "SOLUTION_TYPE_RECOMMENDATION", + "SOLUTION_TYPE_SEARCH" + ], + "enumDescriptions": [ + "Default value.", + "Used for Recommendations AI.", + "Used for Discovery Search." + ], + "type": "string" + }, + "useCases": { + "description": "Specifies the use case for the control. Affects what condition fields can be set. Only applies to SOLUTION_TYPE_SEARCH. Currently only allow one use case per control. Must be set when solution_type is SolutionType.SOLUTION_TYPE_SEARCH.", + "items": { + "enum": [ + "SEARCH_USE_CASE_UNSPECIFIED", + "SEARCH_USE_CASE_SEARCH", + "SEARCH_USE_CASE_BROWSE" + ], + "enumDescriptions": [ + "Value used when unset. Will not occur in CSS.", + "Search use case. Expects the traffic has a non-empty query.", + "Browse use case. Expects the traffic has an empty query." + ], + "type": "string" + }, + "type": "array" + } + }, + "type": "object" + }, + "GoogleCloudDiscoveryengineV1alphaControlBoostAction": { + "description": "Adjusts order of products in returned list.", + "id": "GoogleCloudDiscoveryengineV1alphaControlBoostAction", + "properties": { + "boost": { + "description": "Required. Strength of the boost, which should be in [-1, 1]. Negative boost means demotion. Default is 0.0 (No-op).", + "format": "float", + "type": "number" + }, + "filter": { + "description": "Required. Specifies which products to apply the boost to. If no filter is provided all products will be boosted (No-op). Syntax documentation: https://cloud.google.com/retail/docs/filter-and-order Maximum length is 5000 characters. Otherwise an INVALID ARGUMENT error is thrown.", + "type": "string" + } + }, + "type": "object" + }, + "GoogleCloudDiscoveryengineV1alphaControlFilterAction": { + "description": "Specified which products may be included in results. Uses same filter as boost.", + "id": "GoogleCloudDiscoveryengineV1alphaControlFilterAction", + "properties": { + "filter": { + "description": "Required. A filter to apply on the matching condition results. Required Syntax documentation: https://cloud.google.com/retail/docs/filter-and-order Maximum length is 5000 characters. Otherwise an INVALID ARGUMENT error is thrown.", + "type": "string" + } + }, + "type": "object" + }, "GoogleCloudDiscoveryengineV1alphaCustomAttribute": { "description": "A custom attribute that is not explicitly modeled in a resource, e.g. UserEvent.", "id": "GoogleCloudDiscoveryengineV1alphaCustomAttribute", diff --git a/discoveryengine/v1alpha/discoveryengine-gen.go b/discoveryengine/v1alpha/discoveryengine-gen.go index 39b26b65dca..ea32216add9 100644 --- a/discoveryengine/v1alpha/discoveryengine-gen.go +++ b/discoveryengine/v1alpha/discoveryengine-gen.go @@ -173,6 +173,7 @@ type ProjectsLocationsService struct { func NewProjectsLocationsCollectionsService(s *Service) *ProjectsLocationsCollectionsService { rs := &ProjectsLocationsCollectionsService{s: s} rs.DataStores = NewProjectsLocationsCollectionsDataStoresService(s) + rs.Operations = NewProjectsLocationsCollectionsOperationsService(s) return rs } @@ -180,11 +181,15 @@ type ProjectsLocationsCollectionsService struct { s *Service DataStores *ProjectsLocationsCollectionsDataStoresService + + Operations *ProjectsLocationsCollectionsOperationsService } func NewProjectsLocationsCollectionsDataStoresService(s *Service) *ProjectsLocationsCollectionsDataStoresService { rs := &ProjectsLocationsCollectionsDataStoresService{s: s} rs.Branches = NewProjectsLocationsCollectionsDataStoresBranchesService(s) + rs.Models = NewProjectsLocationsCollectionsDataStoresModelsService(s) + rs.Operations = NewProjectsLocationsCollectionsDataStoresOperationsService(s) rs.ServingConfigs = NewProjectsLocationsCollectionsDataStoresServingConfigsService(s) rs.UserEvents = NewProjectsLocationsCollectionsDataStoresUserEventsService(s) return rs @@ -195,6 +200,10 @@ type ProjectsLocationsCollectionsDataStoresService struct { Branches *ProjectsLocationsCollectionsDataStoresBranchesService + Models *ProjectsLocationsCollectionsDataStoresModelsService + + Operations *ProjectsLocationsCollectionsDataStoresOperationsService + ServingConfigs *ProjectsLocationsCollectionsDataStoresServingConfigsService UserEvents *ProjectsLocationsCollectionsDataStoresUserEventsService @@ -203,6 +212,7 @@ type ProjectsLocationsCollectionsDataStoresService struct { func NewProjectsLocationsCollectionsDataStoresBranchesService(s *Service) *ProjectsLocationsCollectionsDataStoresBranchesService { rs := &ProjectsLocationsCollectionsDataStoresBranchesService{s: s} rs.Documents = NewProjectsLocationsCollectionsDataStoresBranchesDocumentsService(s) + rs.Operations = NewProjectsLocationsCollectionsDataStoresBranchesOperationsService(s) return rs } @@ -210,6 +220,8 @@ type ProjectsLocationsCollectionsDataStoresBranchesService struct { s *Service Documents *ProjectsLocationsCollectionsDataStoresBranchesDocumentsService + + Operations *ProjectsLocationsCollectionsDataStoresBranchesOperationsService } func NewProjectsLocationsCollectionsDataStoresBranchesDocumentsService(s *Service) *ProjectsLocationsCollectionsDataStoresBranchesDocumentsService { @@ -221,6 +233,45 @@ type ProjectsLocationsCollectionsDataStoresBranchesDocumentsService struct { s *Service } +func NewProjectsLocationsCollectionsDataStoresBranchesOperationsService(s *Service) *ProjectsLocationsCollectionsDataStoresBranchesOperationsService { + rs := &ProjectsLocationsCollectionsDataStoresBranchesOperationsService{s: s} + return rs +} + +type ProjectsLocationsCollectionsDataStoresBranchesOperationsService struct { + s *Service +} + +func NewProjectsLocationsCollectionsDataStoresModelsService(s *Service) *ProjectsLocationsCollectionsDataStoresModelsService { + rs := &ProjectsLocationsCollectionsDataStoresModelsService{s: s} + rs.Operations = NewProjectsLocationsCollectionsDataStoresModelsOperationsService(s) + return rs +} + +type ProjectsLocationsCollectionsDataStoresModelsService struct { + s *Service + + Operations *ProjectsLocationsCollectionsDataStoresModelsOperationsService +} + +func NewProjectsLocationsCollectionsDataStoresModelsOperationsService(s *Service) *ProjectsLocationsCollectionsDataStoresModelsOperationsService { + rs := &ProjectsLocationsCollectionsDataStoresModelsOperationsService{s: s} + return rs +} + +type ProjectsLocationsCollectionsDataStoresModelsOperationsService struct { + s *Service +} + +func NewProjectsLocationsCollectionsDataStoresOperationsService(s *Service) *ProjectsLocationsCollectionsDataStoresOperationsService { + rs := &ProjectsLocationsCollectionsDataStoresOperationsService{s: s} + return rs +} + +type ProjectsLocationsCollectionsDataStoresOperationsService struct { + s *Service +} + func NewProjectsLocationsCollectionsDataStoresServingConfigsService(s *Service) *ProjectsLocationsCollectionsDataStoresServingConfigsService { rs := &ProjectsLocationsCollectionsDataStoresServingConfigsService{s: s} return rs @@ -239,6 +290,15 @@ type ProjectsLocationsCollectionsDataStoresUserEventsService struct { s *Service } +func NewProjectsLocationsCollectionsOperationsService(s *Service) *ProjectsLocationsCollectionsOperationsService { + rs := &ProjectsLocationsCollectionsOperationsService{s: s} + return rs +} + +type ProjectsLocationsCollectionsOperationsService struct { + s *Service +} + func NewProjectsLocationsDataStoresService(s *Service) *ProjectsLocationsDataStoresService { rs := &ProjectsLocationsDataStoresService{s: s} rs.Branches = NewProjectsLocationsDataStoresBranchesService(s) @@ -731,6 +791,273 @@ func (s *GoogleCloudDiscoveryengineV1alphaCompletionInfo) MarshalJSON() ([]byte, return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } +// GoogleCloudDiscoveryengineV1alphaCondition: Defines circumstances to +// be checked before allowing a behavior +type GoogleCloudDiscoveryengineV1alphaCondition struct { + // ActiveTimeRange: Optional. Range of time(s) specifying when condition + // is active. Maximum of 10 time ranges. + ActiveTimeRange []*GoogleCloudDiscoveryengineV1alphaConditionTimeRange `json:"activeTimeRange,omitempty"` + + // QueryTerms: Optional. Search only A list of terms to match the query + // on. Maximum of 10 query terms. + QueryTerms []*GoogleCloudDiscoveryengineV1alphaConditionQueryTerm `json:"queryTerms,omitempty"` + + // ForceSendFields is a list of field names (e.g. "ActiveTimeRange") 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. "ActiveTimeRange") 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 *GoogleCloudDiscoveryengineV1alphaCondition) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaCondition + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + +// GoogleCloudDiscoveryengineV1alphaConditionQueryTerm: Matcher for +// search request query +type GoogleCloudDiscoveryengineV1alphaConditionQueryTerm struct { + // FullMatch: Whether the search query needs to exactly match the query + // term. + FullMatch bool `json:"fullMatch,omitempty"` + + // Value: The specific query value to match against Must be lowercase, + // must be UTF-8. Can have at most 3 space separated terms if full_match + // is true. Cannot be an empty string. Maximum length of 5000 + // characters. + Value string `json:"value,omitempty"` + + // ForceSendFields is a list of field names (e.g. "FullMatch") 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. "FullMatch") 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 *GoogleCloudDiscoveryengineV1alphaConditionQueryTerm) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaConditionQueryTerm + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + +// GoogleCloudDiscoveryengineV1alphaConditionTimeRange: Used for +// time-dependent conditions. +type GoogleCloudDiscoveryengineV1alphaConditionTimeRange struct { + // EndTime: End of time range. Range is inclusive. Must be in the + // future. + EndTime string `json:"endTime,omitempty"` + + // StartTime: Start of time range. Range is inclusive. + StartTime string `json:"startTime,omitempty"` + + // ForceSendFields is a list of field names (e.g. "EndTime") 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. "EndTime") 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 *GoogleCloudDiscoveryengineV1alphaConditionTimeRange) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaConditionTimeRange + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + +// GoogleCloudDiscoveryengineV1alphaControl: Defines a conditioned +// behavior to employ during serving. Must be attached to a +// [ServingConfig] to be considered at serving time. Permitted actions +// dependent on Solution Type. +type GoogleCloudDiscoveryengineV1alphaControl struct { + // AssociatedServingConfigIds: Output only. List of all [ServingConfig] + // ids this control is attached to. May take up to 10 minutes to update + // after changes. + AssociatedServingConfigIds []string `json:"associatedServingConfigIds,omitempty"` + + // BoostAction: Defines a boost-type control + BoostAction *GoogleCloudDiscoveryengineV1alphaControlBoostAction `json:"boostAction,omitempty"` + + // Conditions: Determines when the associated action will trigger. Omit + // to always apply the action. Currently only a single condition may be + // specified. Otherwise an INVALID ARGUMENT error is thrown. + Conditions []*GoogleCloudDiscoveryengineV1alphaCondition `json:"conditions,omitempty"` + + // DisplayName: Required. Human readable name. The identifier used in UI + // views. Must be UTF-8 encoded string. Length limit is 128 characters. + // Otherwise an INVALID ARGUMENT error is thrown. + DisplayName string `json:"displayName,omitempty"` + + // FilterAction: Defines a filter-type control Currently not supported + // by Recommendation + FilterAction *GoogleCloudDiscoveryengineV1alphaControlFilterAction `json:"filterAction,omitempty"` + + // Name: Immutable. Fully qualified name + // `projects/*/locations/global/dataStore/*/controls/*` + Name string `json:"name,omitempty"` + + // SolutionType: Required. What solution the control belongs to. Must be + // compatible with vertical of resource. Otherwise an INVALID ARGUMENT + // error is thrown. + // + // Possible values: + // "SOLUTION_TYPE_UNSPECIFIED" - Default value. + // "SOLUTION_TYPE_RECOMMENDATION" - Used for Recommendations AI. + // "SOLUTION_TYPE_SEARCH" - Used for Discovery Search. + SolutionType string `json:"solutionType,omitempty"` + + // UseCases: Specifies the use case for the control. Affects what + // condition fields can be set. Only applies to SOLUTION_TYPE_SEARCH. + // Currently only allow one use case per control. Must be set when + // solution_type is SolutionType.SOLUTION_TYPE_SEARCH. + // + // Possible values: + // "SEARCH_USE_CASE_UNSPECIFIED" - Value used when unset. Will not + // occur in CSS. + // "SEARCH_USE_CASE_SEARCH" - Search use case. Expects the traffic has + // a non-empty query. + // "SEARCH_USE_CASE_BROWSE" - Browse use case. Expects the traffic has + // an empty query. + UseCases []string `json:"useCases,omitempty"` + + // ForceSendFields is a list of field names (e.g. + // "AssociatedServingConfigIds") 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. + // "AssociatedServingConfigIds") 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 *GoogleCloudDiscoveryengineV1alphaControl) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaControl + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + +// GoogleCloudDiscoveryengineV1alphaControlBoostAction: Adjusts order of +// products in returned list. +type GoogleCloudDiscoveryengineV1alphaControlBoostAction struct { + // Boost: Required. Strength of the boost, which should be in [-1, 1]. + // Negative boost means demotion. Default is 0.0 (No-op). + Boost float64 `json:"boost,omitempty"` + + // Filter: Required. Specifies which products to apply the boost to. If + // no filter is provided all products will be boosted (No-op). Syntax + // documentation: https://cloud.google.com/retail/docs/filter-and-order + // Maximum length is 5000 characters. Otherwise an INVALID ARGUMENT + // error is thrown. + Filter string `json:"filter,omitempty"` + + // ForceSendFields is a list of field names (e.g. "Boost") 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. "Boost") 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 *GoogleCloudDiscoveryengineV1alphaControlBoostAction) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaControlBoostAction + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + +func (s *GoogleCloudDiscoveryengineV1alphaControlBoostAction) UnmarshalJSON(data []byte) error { + type NoMethod GoogleCloudDiscoveryengineV1alphaControlBoostAction + var s1 struct { + Boost gensupport.JSONFloat64 `json:"boost"` + *NoMethod + } + s1.NoMethod = (*NoMethod)(s) + if err := json.Unmarshal(data, &s1); err != nil { + return err + } + s.Boost = float64(s1.Boost) + return nil +} + +// GoogleCloudDiscoveryengineV1alphaControlFilterAction: Specified which +// products may be included in results. Uses same filter as boost. +type GoogleCloudDiscoveryengineV1alphaControlFilterAction struct { + // Filter: Required. A filter to apply on the matching condition + // results. Required Syntax documentation: + // https://cloud.google.com/retail/docs/filter-and-order Maximum length + // is 5000 characters. Otherwise an INVALID ARGUMENT error is thrown. + Filter string `json:"filter,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 *GoogleCloudDiscoveryengineV1alphaControlFilterAction) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaControlFilterAction + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + // GoogleCloudDiscoveryengineV1alphaCustomAttribute: A custom attribute // that is not explicitly modeled in a resource, e.g. UserEvent. type GoogleCloudDiscoveryengineV1alphaCustomAttribute struct { @@ -3353,94 +3680,97 @@ func (c *ProjectsLocationsCollectionsDataStoresBranchesDocumentsPatchCall) Do(op } -// method id "discoveryengine.projects.locations.collections.dataStores.servingConfigs.recommend": +// method id "discoveryengine.projects.locations.collections.dataStores.branches.operations.get": -type ProjectsLocationsCollectionsDataStoresServingConfigsRecommendCall struct { - s *Service - servingConfig string - googleclouddiscoveryenginev1alpharecommendrequest *GoogleCloudDiscoveryengineV1alphaRecommendRequest - urlParams_ gensupport.URLParams - ctx_ context.Context - header_ http.Header +type ProjectsLocationsCollectionsDataStoresBranchesOperationsGetCall struct { + s *Service + name string + urlParams_ gensupport.URLParams + ifNoneMatch_ string + ctx_ context.Context + header_ http.Header } -// Recommend: Makes a recommendation, which requires a contextual user -// event. +// 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. // -// - servingConfig: Full resource name of the format: -// projects/*/locations/global/collections/*/dataStores/*/servingConfig -// s/* Before you can request recommendations from your model, you -// must create at least one serving config for it. -func (r *ProjectsLocationsCollectionsDataStoresServingConfigsService) Recommend(servingConfig string, googleclouddiscoveryenginev1alpharecommendrequest *GoogleCloudDiscoveryengineV1alphaRecommendRequest) *ProjectsLocationsCollectionsDataStoresServingConfigsRecommendCall { - c := &ProjectsLocationsCollectionsDataStoresServingConfigsRecommendCall{s: r.s, urlParams_: make(gensupport.URLParams)} - c.servingConfig = servingConfig - c.googleclouddiscoveryenginev1alpharecommendrequest = googleclouddiscoveryenginev1alpharecommendrequest +// - name: The name of the operation resource. +func (r *ProjectsLocationsCollectionsDataStoresBranchesOperationsService) Get(name string) *ProjectsLocationsCollectionsDataStoresBranchesOperationsGetCall { + c := &ProjectsLocationsCollectionsDataStoresBranchesOperationsGetCall{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 *ProjectsLocationsCollectionsDataStoresServingConfigsRecommendCall) Fields(s ...googleapi.Field) *ProjectsLocationsCollectionsDataStoresServingConfigsRecommendCall { +func (c *ProjectsLocationsCollectionsDataStoresBranchesOperationsGetCall) Fields(s ...googleapi.Field) *ProjectsLocationsCollectionsDataStoresBranchesOperationsGetCall { 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 *ProjectsLocationsCollectionsDataStoresBranchesOperationsGetCall) IfNoneMatch(entityTag string) *ProjectsLocationsCollectionsDataStoresBranchesOperationsGetCall { + 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 *ProjectsLocationsCollectionsDataStoresServingConfigsRecommendCall) Context(ctx context.Context) *ProjectsLocationsCollectionsDataStoresServingConfigsRecommendCall { +func (c *ProjectsLocationsCollectionsDataStoresBranchesOperationsGetCall) Context(ctx context.Context) *ProjectsLocationsCollectionsDataStoresBranchesOperationsGetCall { 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 *ProjectsLocationsCollectionsDataStoresServingConfigsRecommendCall) Header() http.Header { +func (c *ProjectsLocationsCollectionsDataStoresBranchesOperationsGetCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) } return c.header_ } -func (c *ProjectsLocationsCollectionsDataStoresServingConfigsRecommendCall) doRequest(alt string) (*http.Response, error) { +func (c *ProjectsLocationsCollectionsDataStoresBranchesOperationsGetCall) 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.googleclouddiscoveryenginev1alpharecommendrequest) - if err != nil { - return nil, err + if c.ifNoneMatch_ != "" { + reqHeaders.Set("If-None-Match", c.ifNoneMatch_) } - reqHeaders.Set("Content-Type", "application/json") + var body io.Reader = nil c.urlParams_.Set("alt", alt) c.urlParams_.Set("prettyPrint", "false") - urls := googleapi.ResolveRelative(c.s.BasePath, "v1alpha/{+servingConfig}:recommend") + urls := googleapi.ResolveRelative(c.s.BasePath, "v1alpha/{+name}") urls += "?" + c.urlParams_.Encode() - req, err := http.NewRequest("POST", urls, body) + req, err := http.NewRequest("GET", urls, body) if err != nil { return nil, err } req.Header = reqHeaders googleapi.Expand(req.URL, map[string]string{ - "servingConfig": c.servingConfig, + "name": c.name, }) return gensupport.SendRequest(c.ctx_, c.s.client, req) } -// Do executes the "discoveryengine.projects.locations.collections.dataStores.servingConfigs.recommend" call. -// Exactly one of *GoogleCloudDiscoveryengineV1alphaRecommendResponse or -// error will be non-nil. Any non-2xx status code is an error. Response -// headers are in either -// *GoogleCloudDiscoveryengineV1alphaRecommendResponse.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 *ProjectsLocationsCollectionsDataStoresServingConfigsRecommendCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDiscoveryengineV1alphaRecommendResponse, error) { +// Do executes the "discoveryengine.projects.locations.collections.dataStores.branches.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 *ProjectsLocationsCollectionsDataStoresBranchesOperationsGetCall) Do(opts ...googleapi.CallOption) (*GoogleLongrunningOperation, error) { gensupport.SetOptions(c.urlParams_, opts...) res, err := c.doRequest("json") if res != nil && res.StatusCode == http.StatusNotModified { @@ -3459,7 +3789,7 @@ func (c *ProjectsLocationsCollectionsDataStoresServingConfigsRecommendCall) Do(o if err := googleapi.CheckResponse(res); err != nil { return nil, gensupport.WrapError(err) } - ret := &GoogleCloudDiscoveryengineV1alphaRecommendResponse{ + ret := &GoogleLongrunningOperation{ ServerResponse: googleapi.ServerResponse{ Header: res.Header, HTTPStatusCode: res.StatusCode, @@ -3471,28 +3801,25 @@ func (c *ProjectsLocationsCollectionsDataStoresServingConfigsRecommendCall) Do(o } return ret, nil // { - // "description": "Makes a recommendation, which requires a contextual user event.", - // "flatPath": "v1alpha/projects/{projectsId}/locations/{locationsId}/collections/{collectionsId}/dataStores/{dataStoresId}/servingConfigs/{servingConfigsId}:recommend", - // "httpMethod": "POST", - // "id": "discoveryengine.projects.locations.collections.dataStores.servingConfigs.recommend", + // "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": "v1alpha/projects/{projectsId}/locations/{locationsId}/collections/{collectionsId}/dataStores/{dataStoresId}/branches/{branchesId}/operations/{operationsId}", + // "httpMethod": "GET", + // "id": "discoveryengine.projects.locations.collections.dataStores.branches.operations.get", // "parameterOrder": [ - // "servingConfig" + // "name" // ], // "parameters": { - // "servingConfig": { - // "description": "Required. Full resource name of the format: projects/*/locations/global/collections/*/dataStores/*/servingConfigs/* Before you can request recommendations from your model, you must create at least one serving config for it.", + // "name": { + // "description": "The name of the operation resource.", // "location": "path", - // "pattern": "^projects/[^/]+/locations/[^/]+/collections/[^/]+/dataStores/[^/]+/servingConfigs/[^/]+$", + // "pattern": "^projects/[^/]+/locations/[^/]+/collections/[^/]+/dataStores/[^/]+/branches/[^/]+/operations/[^/]+$", // "required": true, // "type": "string" // } // }, - // "path": "v1alpha/{+servingConfig}:recommend", - // "request": { - // "$ref": "GoogleCloudDiscoveryengineV1alphaRecommendRequest" - // }, + // "path": "v1alpha/{+name}", // "response": { - // "$ref": "GoogleCloudDiscoveryengineV1alphaRecommendResponse" + // "$ref": "GoogleLongrunningOperation" // }, // "scopes": [ // "https://www.googleapis.com/auth/cloud-platform" @@ -3501,60 +3828,53 @@ func (c *ProjectsLocationsCollectionsDataStoresServingConfigsRecommendCall) Do(o } -// method id "discoveryengine.projects.locations.collections.dataStores.userEvents.collect": +// method id "discoveryengine.projects.locations.collections.dataStores.branches.operations.list": -type ProjectsLocationsCollectionsDataStoresUserEventsCollectCall struct { +type ProjectsLocationsCollectionsDataStoresBranchesOperationsListCall struct { s *Service - parent string + name string urlParams_ gensupport.URLParams ifNoneMatch_ string ctx_ context.Context header_ http.Header } -// Collect: Writes a single user event from the browser. This uses a GET -// request to due to browser restriction of POST-ing to a 3rd party -// domain. This method is used only by the Discovery Engine API -// JavaScript pixel and Google Tag Manager. Users should not call this -// method directly. +// List: Lists operations that match the specified filter in the +// request. If the server doesn't support this method, it returns +// `UNIMPLEMENTED`. // -// - parent: The parent DataStore resource name, such as -// `projects/{project}/locations/{location}/collections/{collection}/da -// taStores/{data_store}`. -func (r *ProjectsLocationsCollectionsDataStoresUserEventsService) Collect(parent string) *ProjectsLocationsCollectionsDataStoresUserEventsCollectCall { - c := &ProjectsLocationsCollectionsDataStoresUserEventsCollectCall{s: r.s, urlParams_: make(gensupport.URLParams)} - c.parent = parent +// - name: The name of the operation's parent resource. +func (r *ProjectsLocationsCollectionsDataStoresBranchesOperationsService) List(name string) *ProjectsLocationsCollectionsDataStoresBranchesOperationsListCall { + c := &ProjectsLocationsCollectionsDataStoresBranchesOperationsListCall{s: r.s, urlParams_: make(gensupport.URLParams)} + c.name = name return c } -// Ets sets the optional parameter "ets": The event timestamp in -// milliseconds. This prevents browser caching of otherwise identical -// get requests. The name is abbreviated to reduce the payload bytes. -func (c *ProjectsLocationsCollectionsDataStoresUserEventsCollectCall) Ets(ets int64) *ProjectsLocationsCollectionsDataStoresUserEventsCollectCall { - c.urlParams_.Set("ets", fmt.Sprint(ets)) +// Filter sets the optional parameter "filter": The standard list +// filter. +func (c *ProjectsLocationsCollectionsDataStoresBranchesOperationsListCall) Filter(filter string) *ProjectsLocationsCollectionsDataStoresBranchesOperationsListCall { + c.urlParams_.Set("filter", filter) return c } -// Uri sets the optional parameter "uri": The URL including -// cgi-parameters but excluding the hash fragment with a length limit of -// 5,000 characters. This is often more useful than the referer URL, -// because many browsers only send the domain for 3rd party requests. -func (c *ProjectsLocationsCollectionsDataStoresUserEventsCollectCall) Uri(uri string) *ProjectsLocationsCollectionsDataStoresUserEventsCollectCall { - c.urlParams_.Set("uri", uri) +// PageSize sets the optional parameter "pageSize": The standard list +// page size. +func (c *ProjectsLocationsCollectionsDataStoresBranchesOperationsListCall) PageSize(pageSize int64) *ProjectsLocationsCollectionsDataStoresBranchesOperationsListCall { + c.urlParams_.Set("pageSize", fmt.Sprint(pageSize)) return c } -// UserEvent sets the optional parameter "userEvent": Required. URL -// encoded UserEvent proto with a length limit of 2,000,000 characters. -func (c *ProjectsLocationsCollectionsDataStoresUserEventsCollectCall) UserEvent(userEvent string) *ProjectsLocationsCollectionsDataStoresUserEventsCollectCall { - c.urlParams_.Set("userEvent", userEvent) +// PageToken sets the optional parameter "pageToken": The standard list +// page token. +func (c *ProjectsLocationsCollectionsDataStoresBranchesOperationsListCall) PageToken(pageToken string) *ProjectsLocationsCollectionsDataStoresBranchesOperationsListCall { + 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 *ProjectsLocationsCollectionsDataStoresUserEventsCollectCall) Fields(s ...googleapi.Field) *ProjectsLocationsCollectionsDataStoresUserEventsCollectCall { +func (c *ProjectsLocationsCollectionsDataStoresBranchesOperationsListCall) Fields(s ...googleapi.Field) *ProjectsLocationsCollectionsDataStoresBranchesOperationsListCall { c.urlParams_.Set("fields", googleapi.CombineFields(s)) return c } @@ -3564,7 +3884,7 @@ func (c *ProjectsLocationsCollectionsDataStoresUserEventsCollectCall) Fields(s . // 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 *ProjectsLocationsCollectionsDataStoresUserEventsCollectCall) IfNoneMatch(entityTag string) *ProjectsLocationsCollectionsDataStoresUserEventsCollectCall { +func (c *ProjectsLocationsCollectionsDataStoresBranchesOperationsListCall) IfNoneMatch(entityTag string) *ProjectsLocationsCollectionsDataStoresBranchesOperationsListCall { c.ifNoneMatch_ = entityTag return c } @@ -3572,21 +3892,21 @@ func (c *ProjectsLocationsCollectionsDataStoresUserEventsCollectCall) IfNoneMatc // 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 *ProjectsLocationsCollectionsDataStoresUserEventsCollectCall) Context(ctx context.Context) *ProjectsLocationsCollectionsDataStoresUserEventsCollectCall { +func (c *ProjectsLocationsCollectionsDataStoresBranchesOperationsListCall) Context(ctx context.Context) *ProjectsLocationsCollectionsDataStoresBranchesOperationsListCall { 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 *ProjectsLocationsCollectionsDataStoresUserEventsCollectCall) Header() http.Header { +func (c *ProjectsLocationsCollectionsDataStoresBranchesOperationsListCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) } return c.header_ } -func (c *ProjectsLocationsCollectionsDataStoresUserEventsCollectCall) doRequest(alt string) (*http.Response, error) { +func (c *ProjectsLocationsCollectionsDataStoresBranchesOperationsListCall) 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_ { @@ -3599,7 +3919,7 @@ func (c *ProjectsLocationsCollectionsDataStoresUserEventsCollectCall) doRequest( var body io.Reader = nil c.urlParams_.Set("alt", alt) c.urlParams_.Set("prettyPrint", "false") - urls := googleapi.ResolveRelative(c.s.BasePath, "v1alpha/{+parent}/userEvents:collect") + urls := googleapi.ResolveRelative(c.s.BasePath, "v1alpha/{+name}/operations") urls += "?" + c.urlParams_.Encode() req, err := http.NewRequest("GET", urls, body) if err != nil { @@ -3607,19 +3927,20 @@ func (c *ProjectsLocationsCollectionsDataStoresUserEventsCollectCall) doRequest( } req.Header = reqHeaders googleapi.Expand(req.URL, map[string]string{ - "parent": c.parent, + "name": c.name, }) return gensupport.SendRequest(c.ctx_, c.s.client, req) } -// Do executes the "discoveryengine.projects.locations.collections.dataStores.userEvents.collect" call. -// Exactly one of *GoogleApiHttpBody or error will be non-nil. Any -// non-2xx status code is an error. Response headers are in either -// *GoogleApiHttpBody.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 +// Do executes the "discoveryengine.projects.locations.collections.dataStores.branches.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 *ProjectsLocationsCollectionsDataStoresUserEventsCollectCall) Do(opts ...googleapi.CallOption) (*GoogleApiHttpBody, error) { +func (c *ProjectsLocationsCollectionsDataStoresBranchesOperationsListCall) Do(opts ...googleapi.CallOption) (*GoogleLongrunningListOperationsResponse, error) { gensupport.SetOptions(c.urlParams_, opts...) res, err := c.doRequest("json") if res != nil && res.StatusCode == http.StatusNotModified { @@ -3638,7 +3959,7 @@ func (c *ProjectsLocationsCollectionsDataStoresUserEventsCollectCall) Do(opts .. if err := googleapi.CheckResponse(res); err != nil { return nil, gensupport.WrapError(err) } - ret := &GoogleApiHttpBody{ + ret := &GoogleLongrunningListOperationsResponse{ ServerResponse: googleapi.ServerResponse{ Header: res.Header, HTTPStatusCode: res.StatusCode, @@ -3650,41 +3971,41 @@ func (c *ProjectsLocationsCollectionsDataStoresUserEventsCollectCall) Do(opts .. } return ret, nil // { - // "description": "Writes a single user event from the browser. This uses a GET request to due to browser restriction of POST-ing to a 3rd party domain. This method is used only by the Discovery Engine API JavaScript pixel and Google Tag Manager. Users should not call this method directly.", - // "flatPath": "v1alpha/projects/{projectsId}/locations/{locationsId}/collections/{collectionsId}/dataStores/{dataStoresId}/userEvents:collect", + // "description": "Lists operations that match the specified filter in the request. If the server doesn't support this method, it returns `UNIMPLEMENTED`.", + // "flatPath": "v1alpha/projects/{projectsId}/locations/{locationsId}/collections/{collectionsId}/dataStores/{dataStoresId}/branches/{branchesId}/operations", // "httpMethod": "GET", - // "id": "discoveryengine.projects.locations.collections.dataStores.userEvents.collect", + // "id": "discoveryengine.projects.locations.collections.dataStores.branches.operations.list", // "parameterOrder": [ - // "parent" + // "name" // ], // "parameters": { - // "ets": { - // "description": "The event timestamp in milliseconds. This prevents browser caching of otherwise identical get requests. The name is abbreviated to reduce the payload bytes.", - // "format": "int64", + // "filter": { + // "description": "The standard list filter.", // "location": "query", // "type": "string" // }, - // "parent": { - // "description": "Required. The parent DataStore resource name, such as `projects/{project}/locations/{location}/collections/{collection}/dataStores/{data_store}`.", + // "name": { + // "description": "The name of the operation's parent resource.", // "location": "path", - // "pattern": "^projects/[^/]+/locations/[^/]+/collections/[^/]+/dataStores/[^/]+$", + // "pattern": "^projects/[^/]+/locations/[^/]+/collections/[^/]+/dataStores/[^/]+/branches/[^/]+$", // "required": true, // "type": "string" // }, - // "uri": { - // "description": "The URL including cgi-parameters but excluding the hash fragment with a length limit of 5,000 characters. This is often more useful than the referer URL, because many browsers only send the domain for 3rd party requests.", + // "pageSize": { + // "description": "The standard list page size.", + // "format": "int32", // "location": "query", - // "type": "string" + // "type": "integer" // }, - // "userEvent": { - // "description": "Required. URL encoded UserEvent proto with a length limit of 2,000,000 characters.", + // "pageToken": { + // "description": "The standard list page token.", // "location": "query", // "type": "string" // } // }, - // "path": "v1alpha/{+parent}/userEvents:collect", + // "path": "v1alpha/{+name}/operations", // "response": { - // "$ref": "GoogleApiHttpBody" + // "$ref": "GoogleLongrunningListOperationsResponse" // }, // "scopes": [ // "https://www.googleapis.com/auth/cloud-platform" @@ -3693,95 +4014,118 @@ func (c *ProjectsLocationsCollectionsDataStoresUserEventsCollectCall) Do(opts .. } -// method id "discoveryengine.projects.locations.collections.dataStores.userEvents.import": +// 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 *ProjectsLocationsCollectionsDataStoresBranchesOperationsListCall) 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) + } +} -type ProjectsLocationsCollectionsDataStoresUserEventsImportCall struct { - s *Service - parent string - googleclouddiscoveryenginev1alphaimportusereventsrequest *GoogleCloudDiscoveryengineV1alphaImportUserEventsRequest - urlParams_ gensupport.URLParams - ctx_ context.Context - header_ http.Header +// method id "discoveryengine.projects.locations.collections.dataStores.models.operations.get": + +type ProjectsLocationsCollectionsDataStoresModelsOperationsGetCall struct { + s *Service + name string + urlParams_ gensupport.URLParams + ifNoneMatch_ string + ctx_ context.Context + header_ http.Header } -// Import: Bulk import of User events. Request processing might be -// synchronous. Events that already exist are skipped. Use this method -// for backfilling historical user events. Operation.response is of type -// ImportResponse. Note that it is possible for a subset of the items to -// be successfully inserted. Operation.metadata is of type -// ImportMetadata. +// 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. // -// - parent: Parent DataStore resource name, of the form -// `projects/{project}/locations/{location}/collections/{collection}/da -// taStores/{data_store}`. -func (r *ProjectsLocationsCollectionsDataStoresUserEventsService) Import(parent string, googleclouddiscoveryenginev1alphaimportusereventsrequest *GoogleCloudDiscoveryengineV1alphaImportUserEventsRequest) *ProjectsLocationsCollectionsDataStoresUserEventsImportCall { - c := &ProjectsLocationsCollectionsDataStoresUserEventsImportCall{s: r.s, urlParams_: make(gensupport.URLParams)} - c.parent = parent - c.googleclouddiscoveryenginev1alphaimportusereventsrequest = googleclouddiscoveryenginev1alphaimportusereventsrequest +// - name: The name of the operation resource. +func (r *ProjectsLocationsCollectionsDataStoresModelsOperationsService) Get(name string) *ProjectsLocationsCollectionsDataStoresModelsOperationsGetCall { + c := &ProjectsLocationsCollectionsDataStoresModelsOperationsGetCall{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 *ProjectsLocationsCollectionsDataStoresUserEventsImportCall) Fields(s ...googleapi.Field) *ProjectsLocationsCollectionsDataStoresUserEventsImportCall { +func (c *ProjectsLocationsCollectionsDataStoresModelsOperationsGetCall) Fields(s ...googleapi.Field) *ProjectsLocationsCollectionsDataStoresModelsOperationsGetCall { 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 *ProjectsLocationsCollectionsDataStoresModelsOperationsGetCall) IfNoneMatch(entityTag string) *ProjectsLocationsCollectionsDataStoresModelsOperationsGetCall { + 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 *ProjectsLocationsCollectionsDataStoresUserEventsImportCall) Context(ctx context.Context) *ProjectsLocationsCollectionsDataStoresUserEventsImportCall { +func (c *ProjectsLocationsCollectionsDataStoresModelsOperationsGetCall) Context(ctx context.Context) *ProjectsLocationsCollectionsDataStoresModelsOperationsGetCall { 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 *ProjectsLocationsCollectionsDataStoresUserEventsImportCall) Header() http.Header { +func (c *ProjectsLocationsCollectionsDataStoresModelsOperationsGetCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) } return c.header_ } -func (c *ProjectsLocationsCollectionsDataStoresUserEventsImportCall) doRequest(alt string) (*http.Response, error) { +func (c *ProjectsLocationsCollectionsDataStoresModelsOperationsGetCall) 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.googleclouddiscoveryenginev1alphaimportusereventsrequest) - if err != nil { - return nil, err + if c.ifNoneMatch_ != "" { + reqHeaders.Set("If-None-Match", c.ifNoneMatch_) } - reqHeaders.Set("Content-Type", "application/json") + var body io.Reader = nil c.urlParams_.Set("alt", alt) c.urlParams_.Set("prettyPrint", "false") - urls := googleapi.ResolveRelative(c.s.BasePath, "v1alpha/{+parent}/userEvents:import") + urls := googleapi.ResolveRelative(c.s.BasePath, "v1alpha/{+name}") urls += "?" + c.urlParams_.Encode() - req, err := http.NewRequest("POST", urls, body) + req, err := http.NewRequest("GET", urls, body) if err != nil { return nil, err } req.Header = reqHeaders googleapi.Expand(req.URL, map[string]string{ - "parent": c.parent, + "name": c.name, }) return gensupport.SendRequest(c.ctx_, c.s.client, req) } -// Do executes the "discoveryengine.projects.locations.collections.dataStores.userEvents.import" call. +// Do executes the "discoveryengine.projects.locations.collections.dataStores.models.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 *ProjectsLocationsCollectionsDataStoresUserEventsImportCall) Do(opts ...googleapi.CallOption) (*GoogleLongrunningOperation, error) { +func (c *ProjectsLocationsCollectionsDataStoresModelsOperationsGetCall) Do(opts ...googleapi.CallOption) (*GoogleLongrunningOperation, error) { gensupport.SetOptions(c.urlParams_, opts...) res, err := c.doRequest("json") if res != nil && res.StatusCode == http.StatusNotModified { @@ -3812,26 +4156,23 @@ func (c *ProjectsLocationsCollectionsDataStoresUserEventsImportCall) Do(opts ... } return ret, nil // { - // "description": "Bulk import of User events. Request processing might be synchronous. Events that already exist are skipped. Use this method for backfilling historical user events. Operation.response is of type ImportResponse. Note that it is possible for a subset of the items to be successfully inserted. Operation.metadata is of type ImportMetadata.", - // "flatPath": "v1alpha/projects/{projectsId}/locations/{locationsId}/collections/{collectionsId}/dataStores/{dataStoresId}/userEvents:import", - // "httpMethod": "POST", - // "id": "discoveryengine.projects.locations.collections.dataStores.userEvents.import", + // "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": "v1alpha/projects/{projectsId}/locations/{locationsId}/collections/{collectionsId}/dataStores/{dataStoresId}/models/{modelsId}/operations/{operationsId}", + // "httpMethod": "GET", + // "id": "discoveryengine.projects.locations.collections.dataStores.models.operations.get", // "parameterOrder": [ - // "parent" + // "name" // ], // "parameters": { - // "parent": { - // "description": "Required. Parent DataStore resource name, of the form `projects/{project}/locations/{location}/collections/{collection}/dataStores/{data_store}`", + // "name": { + // "description": "The name of the operation resource.", // "location": "path", - // "pattern": "^projects/[^/]+/locations/[^/]+/collections/[^/]+/dataStores/[^/]+$", + // "pattern": "^projects/[^/]+/locations/[^/]+/collections/[^/]+/dataStores/[^/]+/models/[^/]+/operations/[^/]+$", // "required": true, // "type": "string" // } // }, - // "path": "v1alpha/{+parent}/userEvents:import", - // "request": { - // "$ref": "GoogleCloudDiscoveryengineV1alphaImportUserEventsRequest" - // }, + // "path": "v1alpha/{+name}", // "response": { // "$ref": "GoogleLongrunningOperation" // }, @@ -3842,92 +4183,1464 @@ func (c *ProjectsLocationsCollectionsDataStoresUserEventsImportCall) Do(opts ... } -// method id "discoveryengine.projects.locations.collections.dataStores.userEvents.write": +// method id "discoveryengine.projects.locations.collections.dataStores.models.operations.list": -type ProjectsLocationsCollectionsDataStoresUserEventsWriteCall struct { - s *Service - parent string - googleclouddiscoveryenginev1alphauserevent *GoogleCloudDiscoveryengineV1alphaUserEvent - urlParams_ gensupport.URLParams - ctx_ context.Context - header_ http.Header +type ProjectsLocationsCollectionsDataStoresModelsOperationsListCall struct { + s *Service + name string + urlParams_ gensupport.URLParams + ifNoneMatch_ string + ctx_ context.Context + header_ http.Header } -// Write: Writes a single user event. +// List: Lists operations that match the specified filter in the +// request. If the server doesn't support this method, it returns +// `UNIMPLEMENTED`. // -// - parent: The parent DataStore resource name, such as -// `projects/{project}/locations/{location}/collections/{collection}/da -// taStores/{data_store}`. -func (r *ProjectsLocationsCollectionsDataStoresUserEventsService) Write(parent string, googleclouddiscoveryenginev1alphauserevent *GoogleCloudDiscoveryengineV1alphaUserEvent) *ProjectsLocationsCollectionsDataStoresUserEventsWriteCall { - c := &ProjectsLocationsCollectionsDataStoresUserEventsWriteCall{s: r.s, urlParams_: make(gensupport.URLParams)} - c.parent = parent - c.googleclouddiscoveryenginev1alphauserevent = googleclouddiscoveryenginev1alphauserevent +// - name: The name of the operation's parent resource. +func (r *ProjectsLocationsCollectionsDataStoresModelsOperationsService) List(name string) *ProjectsLocationsCollectionsDataStoresModelsOperationsListCall { + c := &ProjectsLocationsCollectionsDataStoresModelsOperationsListCall{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 *ProjectsLocationsCollectionsDataStoresUserEventsWriteCall) Fields(s ...googleapi.Field) *ProjectsLocationsCollectionsDataStoresUserEventsWriteCall { - c.urlParams_.Set("fields", googleapi.CombineFields(s)) +// Filter sets the optional parameter "filter": The standard list +// filter. +func (c *ProjectsLocationsCollectionsDataStoresModelsOperationsListCall) Filter(filter string) *ProjectsLocationsCollectionsDataStoresModelsOperationsListCall { + c.urlParams_.Set("filter", filter) 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 *ProjectsLocationsCollectionsDataStoresUserEventsWriteCall) Context(ctx context.Context) *ProjectsLocationsCollectionsDataStoresUserEventsWriteCall { - c.ctx_ = ctx +// PageSize sets the optional parameter "pageSize": The standard list +// page size. +func (c *ProjectsLocationsCollectionsDataStoresModelsOperationsListCall) PageSize(pageSize int64) *ProjectsLocationsCollectionsDataStoresModelsOperationsListCall { + c.urlParams_.Set("pageSize", fmt.Sprint(pageSize)) return c } -// Header returns an http.Header that can be modified by the caller to +// PageToken sets the optional parameter "pageToken": The standard list +// page token. +func (c *ProjectsLocationsCollectionsDataStoresModelsOperationsListCall) PageToken(pageToken string) *ProjectsLocationsCollectionsDataStoresModelsOperationsListCall { + 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 *ProjectsLocationsCollectionsDataStoresModelsOperationsListCall) Fields(s ...googleapi.Field) *ProjectsLocationsCollectionsDataStoresModelsOperationsListCall { + 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 *ProjectsLocationsCollectionsDataStoresModelsOperationsListCall) IfNoneMatch(entityTag string) *ProjectsLocationsCollectionsDataStoresModelsOperationsListCall { + 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 *ProjectsLocationsCollectionsDataStoresModelsOperationsListCall) Context(ctx context.Context) *ProjectsLocationsCollectionsDataStoresModelsOperationsListCall { + 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 *ProjectsLocationsCollectionsDataStoresModelsOperationsListCall) Header() http.Header { + if c.header_ == nil { + c.header_ = make(http.Header) + } + return c.header_ +} + +func (c *ProjectsLocationsCollectionsDataStoresModelsOperationsListCall) 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, "v1alpha/{+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 "discoveryengine.projects.locations.collections.dataStores.models.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 *ProjectsLocationsCollectionsDataStoresModelsOperationsListCall) 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": "v1alpha/projects/{projectsId}/locations/{locationsId}/collections/{collectionsId}/dataStores/{dataStoresId}/models/{modelsId}/operations", + // "httpMethod": "GET", + // "id": "discoveryengine.projects.locations.collections.dataStores.models.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/[^/]+/collections/[^/]+/dataStores/[^/]+/models/[^/]+$", + // "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": "v1alpha/{+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 *ProjectsLocationsCollectionsDataStoresModelsOperationsListCall) 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 "discoveryengine.projects.locations.collections.dataStores.operations.get": + +type ProjectsLocationsCollectionsDataStoresOperationsGetCall 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 *ProjectsLocationsCollectionsDataStoresOperationsService) Get(name string) *ProjectsLocationsCollectionsDataStoresOperationsGetCall { + c := &ProjectsLocationsCollectionsDataStoresOperationsGetCall{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 *ProjectsLocationsCollectionsDataStoresOperationsGetCall) Fields(s ...googleapi.Field) *ProjectsLocationsCollectionsDataStoresOperationsGetCall { + 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 *ProjectsLocationsCollectionsDataStoresOperationsGetCall) IfNoneMatch(entityTag string) *ProjectsLocationsCollectionsDataStoresOperationsGetCall { + 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 *ProjectsLocationsCollectionsDataStoresOperationsGetCall) Context(ctx context.Context) *ProjectsLocationsCollectionsDataStoresOperationsGetCall { + 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 *ProjectsLocationsCollectionsDataStoresOperationsGetCall) Header() http.Header { + if c.header_ == nil { + c.header_ = make(http.Header) + } + return c.header_ +} + +func (c *ProjectsLocationsCollectionsDataStoresOperationsGetCall) 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, "v1alpha/{+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 "discoveryengine.projects.locations.collections.dataStores.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 *ProjectsLocationsCollectionsDataStoresOperationsGetCall) 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": "v1alpha/projects/{projectsId}/locations/{locationsId}/collections/{collectionsId}/dataStores/{dataStoresId}/operations/{operationsId}", + // "httpMethod": "GET", + // "id": "discoveryengine.projects.locations.collections.dataStores.operations.get", + // "parameterOrder": [ + // "name" + // ], + // "parameters": { + // "name": { + // "description": "The name of the operation resource.", + // "location": "path", + // "pattern": "^projects/[^/]+/locations/[^/]+/collections/[^/]+/dataStores/[^/]+/operations/[^/]+$", + // "required": true, + // "type": "string" + // } + // }, + // "path": "v1alpha/{+name}", + // "response": { + // "$ref": "GoogleLongrunningOperation" + // }, + // "scopes": [ + // "https://www.googleapis.com/auth/cloud-platform" + // ] + // } + +} + +// method id "discoveryengine.projects.locations.collections.dataStores.operations.list": + +type ProjectsLocationsCollectionsDataStoresOperationsListCall 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 *ProjectsLocationsCollectionsDataStoresOperationsService) List(name string) *ProjectsLocationsCollectionsDataStoresOperationsListCall { + c := &ProjectsLocationsCollectionsDataStoresOperationsListCall{s: r.s, urlParams_: make(gensupport.URLParams)} + c.name = name + return c +} + +// Filter sets the optional parameter "filter": The standard list +// filter. +func (c *ProjectsLocationsCollectionsDataStoresOperationsListCall) Filter(filter string) *ProjectsLocationsCollectionsDataStoresOperationsListCall { + c.urlParams_.Set("filter", filter) + return c +} + +// PageSize sets the optional parameter "pageSize": The standard list +// page size. +func (c *ProjectsLocationsCollectionsDataStoresOperationsListCall) PageSize(pageSize int64) *ProjectsLocationsCollectionsDataStoresOperationsListCall { + c.urlParams_.Set("pageSize", fmt.Sprint(pageSize)) + return c +} + +// PageToken sets the optional parameter "pageToken": The standard list +// page token. +func (c *ProjectsLocationsCollectionsDataStoresOperationsListCall) PageToken(pageToken string) *ProjectsLocationsCollectionsDataStoresOperationsListCall { + 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 *ProjectsLocationsCollectionsDataStoresOperationsListCall) Fields(s ...googleapi.Field) *ProjectsLocationsCollectionsDataStoresOperationsListCall { + 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 *ProjectsLocationsCollectionsDataStoresOperationsListCall) IfNoneMatch(entityTag string) *ProjectsLocationsCollectionsDataStoresOperationsListCall { + 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 *ProjectsLocationsCollectionsDataStoresOperationsListCall) Context(ctx context.Context) *ProjectsLocationsCollectionsDataStoresOperationsListCall { + 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 *ProjectsLocationsCollectionsDataStoresOperationsListCall) Header() http.Header { + if c.header_ == nil { + c.header_ = make(http.Header) + } + return c.header_ +} + +func (c *ProjectsLocationsCollectionsDataStoresOperationsListCall) 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, "v1alpha/{+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 "discoveryengine.projects.locations.collections.dataStores.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 *ProjectsLocationsCollectionsDataStoresOperationsListCall) 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": "v1alpha/projects/{projectsId}/locations/{locationsId}/collections/{collectionsId}/dataStores/{dataStoresId}/operations", + // "httpMethod": "GET", + // "id": "discoveryengine.projects.locations.collections.dataStores.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/[^/]+/collections/[^/]+/dataStores/[^/]+$", + // "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": "v1alpha/{+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 *ProjectsLocationsCollectionsDataStoresOperationsListCall) 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 "discoveryengine.projects.locations.collections.dataStores.servingConfigs.recommend": + +type ProjectsLocationsCollectionsDataStoresServingConfigsRecommendCall struct { + s *Service + servingConfig string + googleclouddiscoveryenginev1alpharecommendrequest *GoogleCloudDiscoveryengineV1alphaRecommendRequest + urlParams_ gensupport.URLParams + ctx_ context.Context + header_ http.Header +} + +// Recommend: Makes a recommendation, which requires a contextual user +// event. +// +// - servingConfig: Full resource name of the format: +// projects/*/locations/global/collections/*/dataStores/*/servingConfig +// s/* Before you can request recommendations from your model, you +// must create at least one serving config for it. +func (r *ProjectsLocationsCollectionsDataStoresServingConfigsService) Recommend(servingConfig string, googleclouddiscoveryenginev1alpharecommendrequest *GoogleCloudDiscoveryengineV1alphaRecommendRequest) *ProjectsLocationsCollectionsDataStoresServingConfigsRecommendCall { + c := &ProjectsLocationsCollectionsDataStoresServingConfigsRecommendCall{s: r.s, urlParams_: make(gensupport.URLParams)} + c.servingConfig = servingConfig + c.googleclouddiscoveryenginev1alpharecommendrequest = googleclouddiscoveryenginev1alpharecommendrequest + 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 *ProjectsLocationsCollectionsDataStoresServingConfigsRecommendCall) Fields(s ...googleapi.Field) *ProjectsLocationsCollectionsDataStoresServingConfigsRecommendCall { + 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 *ProjectsLocationsCollectionsDataStoresServingConfigsRecommendCall) Context(ctx context.Context) *ProjectsLocationsCollectionsDataStoresServingConfigsRecommendCall { + 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 *ProjectsLocationsCollectionsDataStoresServingConfigsRecommendCall) Header() http.Header { + if c.header_ == nil { + c.header_ = make(http.Header) + } + return c.header_ +} + +func (c *ProjectsLocationsCollectionsDataStoresServingConfigsRecommendCall) 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.googleclouddiscoveryenginev1alpharecommendrequest) + 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/{+servingConfig}:recommend") + 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{ + "servingConfig": c.servingConfig, + }) + return gensupport.SendRequest(c.ctx_, c.s.client, req) +} + +// Do executes the "discoveryengine.projects.locations.collections.dataStores.servingConfigs.recommend" call. +// Exactly one of *GoogleCloudDiscoveryengineV1alphaRecommendResponse or +// error will be non-nil. Any non-2xx status code is an error. Response +// headers are in either +// *GoogleCloudDiscoveryengineV1alphaRecommendResponse.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 *ProjectsLocationsCollectionsDataStoresServingConfigsRecommendCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDiscoveryengineV1alphaRecommendResponse, 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 := &GoogleCloudDiscoveryengineV1alphaRecommendResponse{ + 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": "Makes a recommendation, which requires a contextual user event.", + // "flatPath": "v1alpha/projects/{projectsId}/locations/{locationsId}/collections/{collectionsId}/dataStores/{dataStoresId}/servingConfigs/{servingConfigsId}:recommend", + // "httpMethod": "POST", + // "id": "discoveryengine.projects.locations.collections.dataStores.servingConfigs.recommend", + // "parameterOrder": [ + // "servingConfig" + // ], + // "parameters": { + // "servingConfig": { + // "description": "Required. Full resource name of the format: projects/*/locations/global/collections/*/dataStores/*/servingConfigs/* Before you can request recommendations from your model, you must create at least one serving config for it.", + // "location": "path", + // "pattern": "^projects/[^/]+/locations/[^/]+/collections/[^/]+/dataStores/[^/]+/servingConfigs/[^/]+$", + // "required": true, + // "type": "string" + // } + // }, + // "path": "v1alpha/{+servingConfig}:recommend", + // "request": { + // "$ref": "GoogleCloudDiscoveryengineV1alphaRecommendRequest" + // }, + // "response": { + // "$ref": "GoogleCloudDiscoveryengineV1alphaRecommendResponse" + // }, + // "scopes": [ + // "https://www.googleapis.com/auth/cloud-platform" + // ] + // } + +} + +// method id "discoveryengine.projects.locations.collections.dataStores.userEvents.collect": + +type ProjectsLocationsCollectionsDataStoresUserEventsCollectCall struct { + s *Service + parent string + urlParams_ gensupport.URLParams + ifNoneMatch_ string + ctx_ context.Context + header_ http.Header +} + +// Collect: Writes a single user event from the browser. This uses a GET +// request to due to browser restriction of POST-ing to a 3rd party +// domain. This method is used only by the Discovery Engine API +// JavaScript pixel and Google Tag Manager. Users should not call this +// method directly. +// +// - parent: The parent DataStore resource name, such as +// `projects/{project}/locations/{location}/collections/{collection}/da +// taStores/{data_store}`. +func (r *ProjectsLocationsCollectionsDataStoresUserEventsService) Collect(parent string) *ProjectsLocationsCollectionsDataStoresUserEventsCollectCall { + c := &ProjectsLocationsCollectionsDataStoresUserEventsCollectCall{s: r.s, urlParams_: make(gensupport.URLParams)} + c.parent = parent + return c +} + +// Ets sets the optional parameter "ets": The event timestamp in +// milliseconds. This prevents browser caching of otherwise identical +// get requests. The name is abbreviated to reduce the payload bytes. +func (c *ProjectsLocationsCollectionsDataStoresUserEventsCollectCall) Ets(ets int64) *ProjectsLocationsCollectionsDataStoresUserEventsCollectCall { + c.urlParams_.Set("ets", fmt.Sprint(ets)) + return c +} + +// Uri sets the optional parameter "uri": The URL including +// cgi-parameters but excluding the hash fragment with a length limit of +// 5,000 characters. This is often more useful than the referer URL, +// because many browsers only send the domain for 3rd party requests. +func (c *ProjectsLocationsCollectionsDataStoresUserEventsCollectCall) Uri(uri string) *ProjectsLocationsCollectionsDataStoresUserEventsCollectCall { + c.urlParams_.Set("uri", uri) + return c +} + +// UserEvent sets the optional parameter "userEvent": Required. URL +// encoded UserEvent proto with a length limit of 2,000,000 characters. +func (c *ProjectsLocationsCollectionsDataStoresUserEventsCollectCall) UserEvent(userEvent string) *ProjectsLocationsCollectionsDataStoresUserEventsCollectCall { + c.urlParams_.Set("userEvent", userEvent) + 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 *ProjectsLocationsCollectionsDataStoresUserEventsCollectCall) Fields(s ...googleapi.Field) *ProjectsLocationsCollectionsDataStoresUserEventsCollectCall { + 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 *ProjectsLocationsCollectionsDataStoresUserEventsCollectCall) IfNoneMatch(entityTag string) *ProjectsLocationsCollectionsDataStoresUserEventsCollectCall { + 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 *ProjectsLocationsCollectionsDataStoresUserEventsCollectCall) Context(ctx context.Context) *ProjectsLocationsCollectionsDataStoresUserEventsCollectCall { + 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 *ProjectsLocationsCollectionsDataStoresUserEventsCollectCall) Header() http.Header { + if c.header_ == nil { + c.header_ = make(http.Header) + } + return c.header_ +} + +func (c *ProjectsLocationsCollectionsDataStoresUserEventsCollectCall) 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, "v1alpha/{+parent}/userEvents:collect") + 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{ + "parent": c.parent, + }) + return gensupport.SendRequest(c.ctx_, c.s.client, req) +} + +// Do executes the "discoveryengine.projects.locations.collections.dataStores.userEvents.collect" call. +// Exactly one of *GoogleApiHttpBody or error will be non-nil. Any +// non-2xx status code is an error. Response headers are in either +// *GoogleApiHttpBody.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 *ProjectsLocationsCollectionsDataStoresUserEventsCollectCall) Do(opts ...googleapi.CallOption) (*GoogleApiHttpBody, 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 := &GoogleApiHttpBody{ + 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": "Writes a single user event from the browser. This uses a GET request to due to browser restriction of POST-ing to a 3rd party domain. This method is used only by the Discovery Engine API JavaScript pixel and Google Tag Manager. Users should not call this method directly.", + // "flatPath": "v1alpha/projects/{projectsId}/locations/{locationsId}/collections/{collectionsId}/dataStores/{dataStoresId}/userEvents:collect", + // "httpMethod": "GET", + // "id": "discoveryengine.projects.locations.collections.dataStores.userEvents.collect", + // "parameterOrder": [ + // "parent" + // ], + // "parameters": { + // "ets": { + // "description": "The event timestamp in milliseconds. This prevents browser caching of otherwise identical get requests. The name is abbreviated to reduce the payload bytes.", + // "format": "int64", + // "location": "query", + // "type": "string" + // }, + // "parent": { + // "description": "Required. The parent DataStore resource name, such as `projects/{project}/locations/{location}/collections/{collection}/dataStores/{data_store}`.", + // "location": "path", + // "pattern": "^projects/[^/]+/locations/[^/]+/collections/[^/]+/dataStores/[^/]+$", + // "required": true, + // "type": "string" + // }, + // "uri": { + // "description": "The URL including cgi-parameters but excluding the hash fragment with a length limit of 5,000 characters. This is often more useful than the referer URL, because many browsers only send the domain for 3rd party requests.", + // "location": "query", + // "type": "string" + // }, + // "userEvent": { + // "description": "Required. URL encoded UserEvent proto with a length limit of 2,000,000 characters.", + // "location": "query", + // "type": "string" + // } + // }, + // "path": "v1alpha/{+parent}/userEvents:collect", + // "response": { + // "$ref": "GoogleApiHttpBody" + // }, + // "scopes": [ + // "https://www.googleapis.com/auth/cloud-platform" + // ] + // } + +} + +// method id "discoveryengine.projects.locations.collections.dataStores.userEvents.import": + +type ProjectsLocationsCollectionsDataStoresUserEventsImportCall struct { + s *Service + parent string + googleclouddiscoveryenginev1alphaimportusereventsrequest *GoogleCloudDiscoveryengineV1alphaImportUserEventsRequest + urlParams_ gensupport.URLParams + ctx_ context.Context + header_ http.Header +} + +// Import: Bulk import of User events. Request processing might be +// synchronous. Events that already exist are skipped. Use this method +// for backfilling historical user events. Operation.response is of type +// ImportResponse. Note that it is possible for a subset of the items to +// be successfully inserted. Operation.metadata is of type +// ImportMetadata. +// +// - parent: Parent DataStore resource name, of the form +// `projects/{project}/locations/{location}/collections/{collection}/da +// taStores/{data_store}`. +func (r *ProjectsLocationsCollectionsDataStoresUserEventsService) Import(parent string, googleclouddiscoveryenginev1alphaimportusereventsrequest *GoogleCloudDiscoveryengineV1alphaImportUserEventsRequest) *ProjectsLocationsCollectionsDataStoresUserEventsImportCall { + c := &ProjectsLocationsCollectionsDataStoresUserEventsImportCall{s: r.s, urlParams_: make(gensupport.URLParams)} + c.parent = parent + c.googleclouddiscoveryenginev1alphaimportusereventsrequest = googleclouddiscoveryenginev1alphaimportusereventsrequest + 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 *ProjectsLocationsCollectionsDataStoresUserEventsImportCall) Fields(s ...googleapi.Field) *ProjectsLocationsCollectionsDataStoresUserEventsImportCall { + 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 *ProjectsLocationsCollectionsDataStoresUserEventsImportCall) Context(ctx context.Context) *ProjectsLocationsCollectionsDataStoresUserEventsImportCall { + 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 *ProjectsLocationsCollectionsDataStoresUserEventsImportCall) Header() http.Header { + if c.header_ == nil { + c.header_ = make(http.Header) + } + return c.header_ +} + +func (c *ProjectsLocationsCollectionsDataStoresUserEventsImportCall) 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.googleclouddiscoveryenginev1alphaimportusereventsrequest) + 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/{+parent}/userEvents:import") + 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{ + "parent": c.parent, + }) + return gensupport.SendRequest(c.ctx_, c.s.client, req) +} + +// Do executes the "discoveryengine.projects.locations.collections.dataStores.userEvents.import" 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 *ProjectsLocationsCollectionsDataStoresUserEventsImportCall) 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": "Bulk import of User events. Request processing might be synchronous. Events that already exist are skipped. Use this method for backfilling historical user events. Operation.response is of type ImportResponse. Note that it is possible for a subset of the items to be successfully inserted. Operation.metadata is of type ImportMetadata.", + // "flatPath": "v1alpha/projects/{projectsId}/locations/{locationsId}/collections/{collectionsId}/dataStores/{dataStoresId}/userEvents:import", + // "httpMethod": "POST", + // "id": "discoveryengine.projects.locations.collections.dataStores.userEvents.import", + // "parameterOrder": [ + // "parent" + // ], + // "parameters": { + // "parent": { + // "description": "Required. Parent DataStore resource name, of the form `projects/{project}/locations/{location}/collections/{collection}/dataStores/{data_store}`", + // "location": "path", + // "pattern": "^projects/[^/]+/locations/[^/]+/collections/[^/]+/dataStores/[^/]+$", + // "required": true, + // "type": "string" + // } + // }, + // "path": "v1alpha/{+parent}/userEvents:import", + // "request": { + // "$ref": "GoogleCloudDiscoveryengineV1alphaImportUserEventsRequest" + // }, + // "response": { + // "$ref": "GoogleLongrunningOperation" + // }, + // "scopes": [ + // "https://www.googleapis.com/auth/cloud-platform" + // ] + // } + +} + +// method id "discoveryengine.projects.locations.collections.dataStores.userEvents.write": + +type ProjectsLocationsCollectionsDataStoresUserEventsWriteCall struct { + s *Service + parent string + googleclouddiscoveryenginev1alphauserevent *GoogleCloudDiscoveryengineV1alphaUserEvent + urlParams_ gensupport.URLParams + ctx_ context.Context + header_ http.Header +} + +// Write: Writes a single user event. +// +// - parent: The parent DataStore resource name, such as +// `projects/{project}/locations/{location}/collections/{collection}/da +// taStores/{data_store}`. +func (r *ProjectsLocationsCollectionsDataStoresUserEventsService) Write(parent string, googleclouddiscoveryenginev1alphauserevent *GoogleCloudDiscoveryengineV1alphaUserEvent) *ProjectsLocationsCollectionsDataStoresUserEventsWriteCall { + c := &ProjectsLocationsCollectionsDataStoresUserEventsWriteCall{s: r.s, urlParams_: make(gensupport.URLParams)} + c.parent = parent + c.googleclouddiscoveryenginev1alphauserevent = googleclouddiscoveryenginev1alphauserevent + 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 *ProjectsLocationsCollectionsDataStoresUserEventsWriteCall) Fields(s ...googleapi.Field) *ProjectsLocationsCollectionsDataStoresUserEventsWriteCall { + 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 *ProjectsLocationsCollectionsDataStoresUserEventsWriteCall) Context(ctx context.Context) *ProjectsLocationsCollectionsDataStoresUserEventsWriteCall { + 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 *ProjectsLocationsCollectionsDataStoresUserEventsWriteCall) Header() http.Header { + if c.header_ == nil { + c.header_ = make(http.Header) + } + return c.header_ +} + +func (c *ProjectsLocationsCollectionsDataStoresUserEventsWriteCall) 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.googleclouddiscoveryenginev1alphauserevent) + 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/{+parent}/userEvents:write") + 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{ + "parent": c.parent, + }) + return gensupport.SendRequest(c.ctx_, c.s.client, req) +} + +// Do executes the "discoveryengine.projects.locations.collections.dataStores.userEvents.write" call. +// Exactly one of *GoogleCloudDiscoveryengineV1alphaUserEvent or error +// will be non-nil. Any non-2xx status code is an error. Response +// headers are in either +// *GoogleCloudDiscoveryengineV1alphaUserEvent.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 *ProjectsLocationsCollectionsDataStoresUserEventsWriteCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDiscoveryengineV1alphaUserEvent, 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 := &GoogleCloudDiscoveryengineV1alphaUserEvent{ + 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": "Writes a single user event.", + // "flatPath": "v1alpha/projects/{projectsId}/locations/{locationsId}/collections/{collectionsId}/dataStores/{dataStoresId}/userEvents:write", + // "httpMethod": "POST", + // "id": "discoveryengine.projects.locations.collections.dataStores.userEvents.write", + // "parameterOrder": [ + // "parent" + // ], + // "parameters": { + // "parent": { + // "description": "Required. The parent DataStore resource name, such as `projects/{project}/locations/{location}/collections/{collection}/dataStores/{data_store}`.", + // "location": "path", + // "pattern": "^projects/[^/]+/locations/[^/]+/collections/[^/]+/dataStores/[^/]+$", + // "required": true, + // "type": "string" + // } + // }, + // "path": "v1alpha/{+parent}/userEvents:write", + // "request": { + // "$ref": "GoogleCloudDiscoveryengineV1alphaUserEvent" + // }, + // "response": { + // "$ref": "GoogleCloudDiscoveryengineV1alphaUserEvent" + // }, + // "scopes": [ + // "https://www.googleapis.com/auth/cloud-platform" + // ] + // } + +} + +// method id "discoveryengine.projects.locations.collections.operations.get": + +type ProjectsLocationsCollectionsOperationsGetCall 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 *ProjectsLocationsCollectionsOperationsService) Get(name string) *ProjectsLocationsCollectionsOperationsGetCall { + c := &ProjectsLocationsCollectionsOperationsGetCall{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 *ProjectsLocationsCollectionsOperationsGetCall) Fields(s ...googleapi.Field) *ProjectsLocationsCollectionsOperationsGetCall { + 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 *ProjectsLocationsCollectionsOperationsGetCall) IfNoneMatch(entityTag string) *ProjectsLocationsCollectionsOperationsGetCall { + 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 *ProjectsLocationsCollectionsOperationsGetCall) Context(ctx context.Context) *ProjectsLocationsCollectionsOperationsGetCall { + 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 *ProjectsLocationsCollectionsDataStoresUserEventsWriteCall) Header() http.Header { +func (c *ProjectsLocationsCollectionsOperationsGetCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) } return c.header_ } -func (c *ProjectsLocationsCollectionsDataStoresUserEventsWriteCall) doRequest(alt string) (*http.Response, error) { +func (c *ProjectsLocationsCollectionsOperationsGetCall) 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 - body, err := googleapi.WithoutDataWrapper.JSONReader(c.googleclouddiscoveryenginev1alphauserevent) + c.urlParams_.Set("alt", alt) + c.urlParams_.Set("prettyPrint", "false") + urls := googleapi.ResolveRelative(c.s.BasePath, "v1alpha/{+name}") + urls += "?" + c.urlParams_.Encode() + req, err := http.NewRequest("GET", urls, body) if err != nil { return nil, err } - reqHeaders.Set("Content-Type", "application/json") + 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 "discoveryengine.projects.locations.collections.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 *ProjectsLocationsCollectionsOperationsGetCall) 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": "v1alpha/projects/{projectsId}/locations/{locationsId}/collections/{collectionsId}/operations/{operationsId}", + // "httpMethod": "GET", + // "id": "discoveryengine.projects.locations.collections.operations.get", + // "parameterOrder": [ + // "name" + // ], + // "parameters": { + // "name": { + // "description": "The name of the operation resource.", + // "location": "path", + // "pattern": "^projects/[^/]+/locations/[^/]+/collections/[^/]+/operations/[^/]+$", + // "required": true, + // "type": "string" + // } + // }, + // "path": "v1alpha/{+name}", + // "response": { + // "$ref": "GoogleLongrunningOperation" + // }, + // "scopes": [ + // "https://www.googleapis.com/auth/cloud-platform" + // ] + // } + +} + +// method id "discoveryengine.projects.locations.collections.operations.list": + +type ProjectsLocationsCollectionsOperationsListCall 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 *ProjectsLocationsCollectionsOperationsService) List(name string) *ProjectsLocationsCollectionsOperationsListCall { + c := &ProjectsLocationsCollectionsOperationsListCall{s: r.s, urlParams_: make(gensupport.URLParams)} + c.name = name + return c +} + +// Filter sets the optional parameter "filter": The standard list +// filter. +func (c *ProjectsLocationsCollectionsOperationsListCall) Filter(filter string) *ProjectsLocationsCollectionsOperationsListCall { + c.urlParams_.Set("filter", filter) + return c +} + +// PageSize sets the optional parameter "pageSize": The standard list +// page size. +func (c *ProjectsLocationsCollectionsOperationsListCall) PageSize(pageSize int64) *ProjectsLocationsCollectionsOperationsListCall { + c.urlParams_.Set("pageSize", fmt.Sprint(pageSize)) + return c +} + +// PageToken sets the optional parameter "pageToken": The standard list +// page token. +func (c *ProjectsLocationsCollectionsOperationsListCall) PageToken(pageToken string) *ProjectsLocationsCollectionsOperationsListCall { + 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 *ProjectsLocationsCollectionsOperationsListCall) Fields(s ...googleapi.Field) *ProjectsLocationsCollectionsOperationsListCall { + 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 *ProjectsLocationsCollectionsOperationsListCall) IfNoneMatch(entityTag string) *ProjectsLocationsCollectionsOperationsListCall { + 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 *ProjectsLocationsCollectionsOperationsListCall) Context(ctx context.Context) *ProjectsLocationsCollectionsOperationsListCall { + 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 *ProjectsLocationsCollectionsOperationsListCall) Header() http.Header { + if c.header_ == nil { + c.header_ = make(http.Header) + } + return c.header_ +} + +func (c *ProjectsLocationsCollectionsOperationsListCall) 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, "v1alpha/{+parent}/userEvents:write") + urls := googleapi.ResolveRelative(c.s.BasePath, "v1alpha/{+name}/operations") urls += "?" + c.urlParams_.Encode() - req, err := http.NewRequest("POST", urls, body) + req, err := http.NewRequest("GET", urls, body) if err != nil { return nil, err } req.Header = reqHeaders googleapi.Expand(req.URL, map[string]string{ - "parent": c.parent, + "name": c.name, }) return gensupport.SendRequest(c.ctx_, c.s.client, req) } -// Do executes the "discoveryengine.projects.locations.collections.dataStores.userEvents.write" call. -// Exactly one of *GoogleCloudDiscoveryengineV1alphaUserEvent or error -// will be non-nil. Any non-2xx status code is an error. Response -// headers are in either -// *GoogleCloudDiscoveryengineV1alphaUserEvent.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 *ProjectsLocationsCollectionsDataStoresUserEventsWriteCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDiscoveryengineV1alphaUserEvent, error) { +// Do executes the "discoveryengine.projects.locations.collections.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 *ProjectsLocationsCollectionsOperationsListCall) Do(opts ...googleapi.CallOption) (*GoogleLongrunningListOperationsResponse, error) { gensupport.SetOptions(c.urlParams_, opts...) res, err := c.doRequest("json") if res != nil && res.StatusCode == http.StatusNotModified { @@ -3946,7 +5659,7 @@ func (c *ProjectsLocationsCollectionsDataStoresUserEventsWriteCall) Do(opts ...g if err := googleapi.CheckResponse(res); err != nil { return nil, gensupport.WrapError(err) } - ret := &GoogleCloudDiscoveryengineV1alphaUserEvent{ + ret := &GoogleLongrunningListOperationsResponse{ ServerResponse: googleapi.ServerResponse{ Header: res.Header, HTTPStatusCode: res.StatusCode, @@ -3958,28 +5671,41 @@ func (c *ProjectsLocationsCollectionsDataStoresUserEventsWriteCall) Do(opts ...g } return ret, nil // { - // "description": "Writes a single user event.", - // "flatPath": "v1alpha/projects/{projectsId}/locations/{locationsId}/collections/{collectionsId}/dataStores/{dataStoresId}/userEvents:write", - // "httpMethod": "POST", - // "id": "discoveryengine.projects.locations.collections.dataStores.userEvents.write", + // "description": "Lists operations that match the specified filter in the request. If the server doesn't support this method, it returns `UNIMPLEMENTED`.", + // "flatPath": "v1alpha/projects/{projectsId}/locations/{locationsId}/collections/{collectionsId}/operations", + // "httpMethod": "GET", + // "id": "discoveryengine.projects.locations.collections.operations.list", // "parameterOrder": [ - // "parent" + // "name" // ], // "parameters": { - // "parent": { - // "description": "Required. The parent DataStore resource name, such as `projects/{project}/locations/{location}/collections/{collection}/dataStores/{data_store}`.", + // "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/[^/]+/collections/[^/]+/dataStores/[^/]+$", + // "pattern": "^projects/[^/]+/locations/[^/]+/collections/[^/]+$", // "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": "v1alpha/{+parent}/userEvents:write", - // "request": { - // "$ref": "GoogleCloudDiscoveryengineV1alphaUserEvent" - // }, + // "path": "v1alpha/{+name}/operations", // "response": { - // "$ref": "GoogleCloudDiscoveryengineV1alphaUserEvent" + // "$ref": "GoogleLongrunningListOperationsResponse" // }, // "scopes": [ // "https://www.googleapis.com/auth/cloud-platform" @@ -3988,6 +5714,27 @@ func (c *ProjectsLocationsCollectionsDataStoresUserEventsWriteCall) Do(opts ...g } +// 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 *ProjectsLocationsCollectionsOperationsListCall) 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 "discoveryengine.projects.locations.dataStores.branches.documents.create": type ProjectsLocationsDataStoresBranchesDocumentsCreateCall struct { @@ -5120,14 +6867,7 @@ type ProjectsLocationsDataStoresBranchesOperationsListCall struct { // List: Lists operations that match the specified filter in the // request. If the server doesn't support this method, it returns -// `UNIMPLEMENTED`. NOTE: the `name` binding allows API services to -// override the binding to use different resource name schemes, such as -// `users/*/operations`. To override the binding, API services can add a -// binding such as "/v1/{name=users/*}/operations" to their service -// configuration. For backwards compatibility, the default name includes -// the operations collection id, however overriding users must ensure -// the name binding is the parent resource, without the operations -// collection id. +// `UNIMPLEMENTED`. // // - name: The name of the operation's parent resource. func (r *ProjectsLocationsDataStoresBranchesOperationsService) List(name string) *ProjectsLocationsDataStoresBranchesOperationsListCall { @@ -5257,7 +6997,7 @@ func (c *ProjectsLocationsDataStoresBranchesOperationsListCall) Do(opts ...googl } 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`. NOTE: the `name` binding allows API services to override the binding to use different resource name schemes, such as `users/*/operations`. To override the binding, API services can add a binding such as `\"/v1/{name=users/*}/operations\"` to their service configuration. For backwards compatibility, the default name includes the operations collection id, however overriding users must ensure the name binding is the parent resource, without the operations collection id.", + // "description": "Lists operations that match the specified filter in the request. If the server doesn't support this method, it returns `UNIMPLEMENTED`.", // "flatPath": "v1alpha/projects/{projectsId}/locations/{locationsId}/dataStores/{dataStoresId}/branches/{branchesId}/operations", // "httpMethod": "GET", // "id": "discoveryengine.projects.locations.dataStores.branches.operations.list", @@ -5482,14 +7222,7 @@ type ProjectsLocationsDataStoresModelsOperationsListCall struct { // List: Lists operations that match the specified filter in the // request. If the server doesn't support this method, it returns -// `UNIMPLEMENTED`. NOTE: the `name` binding allows API services to -// override the binding to use different resource name schemes, such as -// `users/*/operations`. To override the binding, API services can add a -// binding such as "/v1/{name=users/*}/operations" to their service -// configuration. For backwards compatibility, the default name includes -// the operations collection id, however overriding users must ensure -// the name binding is the parent resource, without the operations -// collection id. +// `UNIMPLEMENTED`. // // - name: The name of the operation's parent resource. func (r *ProjectsLocationsDataStoresModelsOperationsService) List(name string) *ProjectsLocationsDataStoresModelsOperationsListCall { @@ -5619,7 +7352,7 @@ func (c *ProjectsLocationsDataStoresModelsOperationsListCall) Do(opts ...googlea } 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`. NOTE: the `name` binding allows API services to override the binding to use different resource name schemes, such as `users/*/operations`. To override the binding, API services can add a binding such as `\"/v1/{name=users/*}/operations\"` to their service configuration. For backwards compatibility, the default name includes the operations collection id, however overriding users must ensure the name binding is the parent resource, without the operations collection id.", + // "description": "Lists operations that match the specified filter in the request. If the server doesn't support this method, it returns `UNIMPLEMENTED`.", // "flatPath": "v1alpha/projects/{projectsId}/locations/{locationsId}/dataStores/{dataStoresId}/models/{modelsId}/operations", // "httpMethod": "GET", // "id": "discoveryengine.projects.locations.dataStores.models.operations.list", @@ -5844,14 +7577,7 @@ type ProjectsLocationsDataStoresOperationsListCall struct { // List: Lists operations that match the specified filter in the // request. If the server doesn't support this method, it returns -// `UNIMPLEMENTED`. NOTE: the `name` binding allows API services to -// override the binding to use different resource name schemes, such as -// `users/*/operations`. To override the binding, API services can add a -// binding such as "/v1/{name=users/*}/operations" to their service -// configuration. For backwards compatibility, the default name includes -// the operations collection id, however overriding users must ensure -// the name binding is the parent resource, without the operations -// collection id. +// `UNIMPLEMENTED`. // // - name: The name of the operation's parent resource. func (r *ProjectsLocationsDataStoresOperationsService) List(name string) *ProjectsLocationsDataStoresOperationsListCall { @@ -5981,7 +7707,7 @@ func (c *ProjectsLocationsDataStoresOperationsListCall) Do(opts ...googleapi.Cal } 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`. NOTE: the `name` binding allows API services to override the binding to use different resource name schemes, such as `users/*/operations`. To override the binding, API services can add a binding such as `\"/v1/{name=users/*}/operations\"` to their service configuration. For backwards compatibility, the default name includes the operations collection id, however overriding users must ensure the name binding is the parent resource, without the operations collection id.", + // "description": "Lists operations that match the specified filter in the request. If the server doesn't support this method, it returns `UNIMPLEMENTED`.", // "flatPath": "v1alpha/projects/{projectsId}/locations/{locationsId}/dataStores/{dataStoresId}/operations", // "httpMethod": "GET", // "id": "discoveryengine.projects.locations.dataStores.operations.list", @@ -6841,14 +8567,7 @@ type ProjectsLocationsOperationsListCall struct { // List: Lists operations that match the specified filter in the // request. If the server doesn't support this method, it returns -// `UNIMPLEMENTED`. NOTE: the `name` binding allows API services to -// override the binding to use different resource name schemes, such as -// `users/*/operations`. To override the binding, API services can add a -// binding such as "/v1/{name=users/*}/operations" to their service -// configuration. For backwards compatibility, the default name includes -// the operations collection id, however overriding users must ensure -// the name binding is the parent resource, without the operations -// collection id. +// `UNIMPLEMENTED`. // // - name: The name of the operation's parent resource. func (r *ProjectsLocationsOperationsService) List(name string) *ProjectsLocationsOperationsListCall { @@ -6978,7 +8697,7 @@ func (c *ProjectsLocationsOperationsListCall) Do(opts ...googleapi.CallOption) ( } 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`. NOTE: the `name` binding allows API services to override the binding to use different resource name schemes, such as `users/*/operations`. To override the binding, API services can add a binding such as `\"/v1/{name=users/*}/operations\"` to their service configuration. For backwards compatibility, the default name includes the operations collection id, however overriding users must ensure the name binding is the parent resource, without the operations collection id.", + // "description": "Lists operations that match the specified filter in the request. If the server doesn't support this method, it returns `UNIMPLEMENTED`.", // "flatPath": "v1alpha/projects/{projectsId}/locations/{locationsId}/operations", // "httpMethod": "GET", // "id": "discoveryengine.projects.locations.operations.list", @@ -7203,14 +8922,7 @@ type ProjectsOperationsListCall struct { // List: Lists operations that match the specified filter in the // request. If the server doesn't support this method, it returns -// `UNIMPLEMENTED`. NOTE: the `name` binding allows API services to -// override the binding to use different resource name schemes, such as -// `users/*/operations`. To override the binding, API services can add a -// binding such as "/v1/{name=users/*}/operations" to their service -// configuration. For backwards compatibility, the default name includes -// the operations collection id, however overriding users must ensure -// the name binding is the parent resource, without the operations -// collection id. +// `UNIMPLEMENTED`. // // - name: The name of the operation's parent resource. func (r *ProjectsOperationsService) List(name string) *ProjectsOperationsListCall { @@ -7340,7 +9052,7 @@ func (c *ProjectsOperationsListCall) Do(opts ...googleapi.CallOption) (*GoogleLo } 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`. NOTE: the `name` binding allows API services to override the binding to use different resource name schemes, such as `users/*/operations`. To override the binding, API services can add a binding such as `\"/v1/{name=users/*}/operations\"` to their service configuration. For backwards compatibility, the default name includes the operations collection id, however overriding users must ensure the name binding is the parent resource, without the operations collection id.", + // "description": "Lists operations that match the specified filter in the request. If the server doesn't support this method, it returns `UNIMPLEMENTED`.", // "flatPath": "v1alpha/projects/{projectsId}/operations", // "httpMethod": "GET", // "id": "discoveryengine.projects.operations.list", diff --git a/discoveryengine/v1beta/discoveryengine-api.json b/discoveryengine/v1beta/discoveryengine-api.json index d8dd5dc889b..b7de9a9a9c1 100644 --- a/discoveryengine/v1beta/discoveryengine-api.json +++ b/discoveryengine/v1beta/discoveryengine-api.json @@ -298,6 +298,220 @@ ] } } + }, + "operations": { + "methods": { + "get": { + "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": "v1beta/projects/{projectsId}/locations/{locationsId}/collections/{collectionsId}/dataStores/{dataStoresId}/branches/{branchesId}/operations/{operationsId}", + "httpMethod": "GET", + "id": "discoveryengine.projects.locations.collections.dataStores.branches.operations.get", + "parameterOrder": [ + "name" + ], + "parameters": { + "name": { + "description": "The name of the operation resource.", + "location": "path", + "pattern": "^projects/[^/]+/locations/[^/]+/collections/[^/]+/dataStores/[^/]+/branches/[^/]+/operations/[^/]+$", + "required": true, + "type": "string" + } + }, + "path": "v1beta/{+name}", + "response": { + "$ref": "GoogleLongrunningOperation" + }, + "scopes": [ + "https://www.googleapis.com/auth/cloud-platform" + ] + }, + "list": { + "description": "Lists operations that match the specified filter in the request. If the server doesn't support this method, it returns `UNIMPLEMENTED`.", + "flatPath": "v1beta/projects/{projectsId}/locations/{locationsId}/collections/{collectionsId}/dataStores/{dataStoresId}/branches/{branchesId}/operations", + "httpMethod": "GET", + "id": "discoveryengine.projects.locations.collections.dataStores.branches.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/[^/]+/collections/[^/]+/dataStores/[^/]+/branches/[^/]+$", + "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": "v1beta/{+name}/operations", + "response": { + "$ref": "GoogleLongrunningListOperationsResponse" + }, + "scopes": [ + "https://www.googleapis.com/auth/cloud-platform" + ] + } + } + } + } + }, + "models": { + "resources": { + "operations": { + "methods": { + "get": { + "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": "v1beta/projects/{projectsId}/locations/{locationsId}/collections/{collectionsId}/dataStores/{dataStoresId}/models/{modelsId}/operations/{operationsId}", + "httpMethod": "GET", + "id": "discoveryengine.projects.locations.collections.dataStores.models.operations.get", + "parameterOrder": [ + "name" + ], + "parameters": { + "name": { + "description": "The name of the operation resource.", + "location": "path", + "pattern": "^projects/[^/]+/locations/[^/]+/collections/[^/]+/dataStores/[^/]+/models/[^/]+/operations/[^/]+$", + "required": true, + "type": "string" + } + }, + "path": "v1beta/{+name}", + "response": { + "$ref": "GoogleLongrunningOperation" + }, + "scopes": [ + "https://www.googleapis.com/auth/cloud-platform" + ] + }, + "list": { + "description": "Lists operations that match the specified filter in the request. If the server doesn't support this method, it returns `UNIMPLEMENTED`.", + "flatPath": "v1beta/projects/{projectsId}/locations/{locationsId}/collections/{collectionsId}/dataStores/{dataStoresId}/models/{modelsId}/operations", + "httpMethod": "GET", + "id": "discoveryengine.projects.locations.collections.dataStores.models.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/[^/]+/collections/[^/]+/dataStores/[^/]+/models/[^/]+$", + "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": "v1beta/{+name}/operations", + "response": { + "$ref": "GoogleLongrunningListOperationsResponse" + }, + "scopes": [ + "https://www.googleapis.com/auth/cloud-platform" + ] + } + } + } + } + }, + "operations": { + "methods": { + "get": { + "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": "v1beta/projects/{projectsId}/locations/{locationsId}/collections/{collectionsId}/dataStores/{dataStoresId}/operations/{operationsId}", + "httpMethod": "GET", + "id": "discoveryengine.projects.locations.collections.dataStores.operations.get", + "parameterOrder": [ + "name" + ], + "parameters": { + "name": { + "description": "The name of the operation resource.", + "location": "path", + "pattern": "^projects/[^/]+/locations/[^/]+/collections/[^/]+/dataStores/[^/]+/operations/[^/]+$", + "required": true, + "type": "string" + } + }, + "path": "v1beta/{+name}", + "response": { + "$ref": "GoogleLongrunningOperation" + }, + "scopes": [ + "https://www.googleapis.com/auth/cloud-platform" + ] + }, + "list": { + "description": "Lists operations that match the specified filter in the request. If the server doesn't support this method, it returns `UNIMPLEMENTED`.", + "flatPath": "v1beta/projects/{projectsId}/locations/{locationsId}/collections/{collectionsId}/dataStores/{dataStoresId}/operations", + "httpMethod": "GET", + "id": "discoveryengine.projects.locations.collections.dataStores.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/[^/]+/collections/[^/]+/dataStores/[^/]+$", + "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": "v1beta/{+name}/operations", + "response": { + "$ref": "GoogleLongrunningListOperationsResponse" + }, + "scopes": [ + "https://www.googleapis.com/auth/cloud-platform" + ] } } }, @@ -435,6 +649,76 @@ } } } + }, + "operations": { + "methods": { + "get": { + "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": "v1beta/projects/{projectsId}/locations/{locationsId}/collections/{collectionsId}/operations/{operationsId}", + "httpMethod": "GET", + "id": "discoveryengine.projects.locations.collections.operations.get", + "parameterOrder": [ + "name" + ], + "parameters": { + "name": { + "description": "The name of the operation resource.", + "location": "path", + "pattern": "^projects/[^/]+/locations/[^/]+/collections/[^/]+/operations/[^/]+$", + "required": true, + "type": "string" + } + }, + "path": "v1beta/{+name}", + "response": { + "$ref": "GoogleLongrunningOperation" + }, + "scopes": [ + "https://www.googleapis.com/auth/cloud-platform" + ] + }, + "list": { + "description": "Lists operations that match the specified filter in the request. If the server doesn't support this method, it returns `UNIMPLEMENTED`.", + "flatPath": "v1beta/projects/{projectsId}/locations/{locationsId}/collections/{collectionsId}/operations", + "httpMethod": "GET", + "id": "discoveryengine.projects.locations.collections.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/[^/]+/collections/[^/]+$", + "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": "v1beta/{+name}/operations", + "response": { + "$ref": "GoogleLongrunningListOperationsResponse" + }, + "scopes": [ + "https://www.googleapis.com/auth/cloud-platform" + ] + } + } } } }, @@ -654,7 +938,7 @@ ] }, "list": { - "description": "Lists operations that match the specified filter in the request. If the server doesn't support this method, it returns `UNIMPLEMENTED`. NOTE: the `name` binding allows API services to override the binding to use different resource name schemes, such as `users/*/operations`. To override the binding, API services can add a binding such as `\"/v1/{name=users/*}/operations\"` to their service configuration. For backwards compatibility, the default name includes the operations collection id, however overriding users must ensure the name binding is the parent resource, without the operations collection id.", + "description": "Lists operations that match the specified filter in the request. If the server doesn't support this method, it returns `UNIMPLEMENTED`.", "flatPath": "v1beta/projects/{projectsId}/locations/{locationsId}/dataStores/{dataStoresId}/branches/{branchesId}/operations", "httpMethod": "GET", "id": "discoveryengine.projects.locations.dataStores.branches.operations.list", @@ -728,7 +1012,7 @@ ] }, "list": { - "description": "Lists operations that match the specified filter in the request. If the server doesn't support this method, it returns `UNIMPLEMENTED`. NOTE: the `name` binding allows API services to override the binding to use different resource name schemes, such as `users/*/operations`. To override the binding, API services can add a binding such as `\"/v1/{name=users/*}/operations\"` to their service configuration. For backwards compatibility, the default name includes the operations collection id, however overriding users must ensure the name binding is the parent resource, without the operations collection id.", + "description": "Lists operations that match the specified filter in the request. If the server doesn't support this method, it returns `UNIMPLEMENTED`.", "flatPath": "v1beta/projects/{projectsId}/locations/{locationsId}/dataStores/{dataStoresId}/models/{modelsId}/operations", "httpMethod": "GET", "id": "discoveryengine.projects.locations.dataStores.models.operations.list", @@ -800,7 +1084,7 @@ ] }, "list": { - "description": "Lists operations that match the specified filter in the request. If the server doesn't support this method, it returns `UNIMPLEMENTED`. NOTE: the `name` binding allows API services to override the binding to use different resource name schemes, such as `users/*/operations`. To override the binding, API services can add a binding such as `\"/v1/{name=users/*}/operations\"` to their service configuration. For backwards compatibility, the default name includes the operations collection id, however overriding users must ensure the name binding is the parent resource, without the operations collection id.", + "description": "Lists operations that match the specified filter in the request. If the server doesn't support this method, it returns `UNIMPLEMENTED`.", "flatPath": "v1beta/projects/{projectsId}/locations/{locationsId}/dataStores/{dataStoresId}/operations", "httpMethod": "GET", "id": "discoveryengine.projects.locations.dataStores.operations.list", @@ -1005,7 +1289,7 @@ ] }, "list": { - "description": "Lists operations that match the specified filter in the request. If the server doesn't support this method, it returns `UNIMPLEMENTED`. NOTE: the `name` binding allows API services to override the binding to use different resource name schemes, such as `users/*/operations`. To override the binding, API services can add a binding such as `\"/v1/{name=users/*}/operations\"` to their service configuration. For backwards compatibility, the default name includes the operations collection id, however overriding users must ensure the name binding is the parent resource, without the operations collection id.", + "description": "Lists operations that match the specified filter in the request. If the server doesn't support this method, it returns `UNIMPLEMENTED`.", "flatPath": "v1beta/projects/{projectsId}/locations/{locationsId}/operations", "httpMethod": "GET", "id": "discoveryengine.projects.locations.operations.list", @@ -1077,7 +1361,7 @@ ] }, "list": { - "description": "Lists operations that match the specified filter in the request. If the server doesn't support this method, it returns `UNIMPLEMENTED`. NOTE: the `name` binding allows API services to override the binding to use different resource name schemes, such as `users/*/operations`. To override the binding, API services can add a binding such as `\"/v1/{name=users/*}/operations\"` to their service configuration. For backwards compatibility, the default name includes the operations collection id, however overriding users must ensure the name binding is the parent resource, without the operations collection id.", + "description": "Lists operations that match the specified filter in the request. If the server doesn't support this method, it returns `UNIMPLEMENTED`.", "flatPath": "v1beta/projects/{projectsId}/operations", "httpMethod": "GET", "id": "discoveryengine.projects.operations.list", @@ -1122,7 +1406,7 @@ } } }, - "revision": "20230227", + "revision": "20230306", "rootUrl": "https://discoveryengine.googleapis.com/", "schemas": { "GoogleApiHttpBody": { @@ -1255,6 +1539,155 @@ }, "type": "object" }, + "GoogleCloudDiscoveryengineV1alphaCondition": { + "description": "Defines circumstances to be checked before allowing a behavior", + "id": "GoogleCloudDiscoveryengineV1alphaCondition", + "properties": { + "activeTimeRange": { + "description": "Optional. Range of time(s) specifying when condition is active. Maximum of 10 time ranges.", + "items": { + "$ref": "GoogleCloudDiscoveryengineV1alphaConditionTimeRange" + }, + "type": "array" + }, + "queryTerms": { + "description": "Optional. Search only A list of terms to match the query on. Maximum of 10 query terms.", + "items": { + "$ref": "GoogleCloudDiscoveryengineV1alphaConditionQueryTerm" + }, + "type": "array" + } + }, + "type": "object" + }, + "GoogleCloudDiscoveryengineV1alphaConditionQueryTerm": { + "description": "Matcher for search request query", + "id": "GoogleCloudDiscoveryengineV1alphaConditionQueryTerm", + "properties": { + "fullMatch": { + "description": "Whether the search query needs to exactly match the query term.", + "type": "boolean" + }, + "value": { + "description": "The specific query value to match against Must be lowercase, must be UTF-8. Can have at most 3 space separated terms if full_match is true. Cannot be an empty string. Maximum length of 5000 characters.", + "type": "string" + } + }, + "type": "object" + }, + "GoogleCloudDiscoveryengineV1alphaConditionTimeRange": { + "description": "Used for time-dependent conditions.", + "id": "GoogleCloudDiscoveryengineV1alphaConditionTimeRange", + "properties": { + "endTime": { + "description": "End of time range. Range is inclusive. Must be in the future.", + "format": "google-datetime", + "type": "string" + }, + "startTime": { + "description": "Start of time range. Range is inclusive.", + "format": "google-datetime", + "type": "string" + } + }, + "type": "object" + }, + "GoogleCloudDiscoveryengineV1alphaControl": { + "description": "Defines a conditioned behavior to employ during serving. Must be attached to a [ServingConfig] to be considered at serving time. Permitted actions dependent on Solution Type.", + "id": "GoogleCloudDiscoveryengineV1alphaControl", + "properties": { + "associatedServingConfigIds": { + "description": "Output only. List of all [ServingConfig] ids this control is attached to. May take up to 10 minutes to update after changes.", + "items": { + "type": "string" + }, + "readOnly": true, + "type": "array" + }, + "boostAction": { + "$ref": "GoogleCloudDiscoveryengineV1alphaControlBoostAction", + "description": "Defines a boost-type control" + }, + "conditions": { + "description": "Determines when the associated action will trigger. Omit to always apply the action. Currently only a single condition may be specified. Otherwise an INVALID ARGUMENT error is thrown.", + "items": { + "$ref": "GoogleCloudDiscoveryengineV1alphaCondition" + }, + "type": "array" + }, + "displayName": { + "description": "Required. Human readable name. The identifier used in UI views. Must be UTF-8 encoded string. Length limit is 128 characters. Otherwise an INVALID ARGUMENT error is thrown.", + "type": "string" + }, + "filterAction": { + "$ref": "GoogleCloudDiscoveryengineV1alphaControlFilterAction", + "description": "Defines a filter-type control Currently not supported by Recommendation" + }, + "name": { + "description": "Immutable. Fully qualified name `projects/*/locations/global/dataStore/*/controls/*`", + "type": "string" + }, + "solutionType": { + "description": "Required. What solution the control belongs to. Must be compatible with vertical of resource. Otherwise an INVALID ARGUMENT error is thrown.", + "enum": [ + "SOLUTION_TYPE_UNSPECIFIED", + "SOLUTION_TYPE_RECOMMENDATION", + "SOLUTION_TYPE_SEARCH" + ], + "enumDescriptions": [ + "Default value.", + "Used for Recommendations AI.", + "Used for Discovery Search." + ], + "type": "string" + }, + "useCases": { + "description": "Specifies the use case for the control. Affects what condition fields can be set. Only applies to SOLUTION_TYPE_SEARCH. Currently only allow one use case per control. Must be set when solution_type is SolutionType.SOLUTION_TYPE_SEARCH.", + "items": { + "enum": [ + "SEARCH_USE_CASE_UNSPECIFIED", + "SEARCH_USE_CASE_SEARCH", + "SEARCH_USE_CASE_BROWSE" + ], + "enumDescriptions": [ + "Value used when unset. Will not occur in CSS.", + "Search use case. Expects the traffic has a non-empty query.", + "Browse use case. Expects the traffic has an empty query." + ], + "type": "string" + }, + "type": "array" + } + }, + "type": "object" + }, + "GoogleCloudDiscoveryengineV1alphaControlBoostAction": { + "description": "Adjusts order of products in returned list.", + "id": "GoogleCloudDiscoveryengineV1alphaControlBoostAction", + "properties": { + "boost": { + "description": "Required. Strength of the boost, which should be in [-1, 1]. Negative boost means demotion. Default is 0.0 (No-op).", + "format": "float", + "type": "number" + }, + "filter": { + "description": "Required. Specifies which products to apply the boost to. If no filter is provided all products will be boosted (No-op). Syntax documentation: https://cloud.google.com/retail/docs/filter-and-order Maximum length is 5000 characters. Otherwise an INVALID ARGUMENT error is thrown.", + "type": "string" + } + }, + "type": "object" + }, + "GoogleCloudDiscoveryengineV1alphaControlFilterAction": { + "description": "Specified which products may be included in results. Uses same filter as boost.", + "id": "GoogleCloudDiscoveryengineV1alphaControlFilterAction", + "properties": { + "filter": { + "description": "Required. A filter to apply on the matching condition results. Required Syntax documentation: https://cloud.google.com/retail/docs/filter-and-order Maximum length is 5000 characters. Otherwise an INVALID ARGUMENT error is thrown.", + "type": "string" + } + }, + "type": "object" + }, "GoogleCloudDiscoveryengineV1alphaImportDocumentsMetadata": { "description": "Metadata related to the progress of the ImportDocuments operation. This will be returned by the google.longrunning.Operation.metadata field.", "id": "GoogleCloudDiscoveryengineV1alphaImportDocumentsMetadata", diff --git a/discoveryengine/v1beta/discoveryengine-gen.go b/discoveryengine/v1beta/discoveryengine-gen.go index 538a5436c1d..8399993b17c 100644 --- a/discoveryengine/v1beta/discoveryengine-gen.go +++ b/discoveryengine/v1beta/discoveryengine-gen.go @@ -173,6 +173,7 @@ type ProjectsLocationsService struct { func NewProjectsLocationsCollectionsService(s *Service) *ProjectsLocationsCollectionsService { rs := &ProjectsLocationsCollectionsService{s: s} rs.DataStores = NewProjectsLocationsCollectionsDataStoresService(s) + rs.Operations = NewProjectsLocationsCollectionsOperationsService(s) return rs } @@ -180,11 +181,15 @@ type ProjectsLocationsCollectionsService struct { s *Service DataStores *ProjectsLocationsCollectionsDataStoresService + + Operations *ProjectsLocationsCollectionsOperationsService } func NewProjectsLocationsCollectionsDataStoresService(s *Service) *ProjectsLocationsCollectionsDataStoresService { rs := &ProjectsLocationsCollectionsDataStoresService{s: s} rs.Branches = NewProjectsLocationsCollectionsDataStoresBranchesService(s) + rs.Models = NewProjectsLocationsCollectionsDataStoresModelsService(s) + rs.Operations = NewProjectsLocationsCollectionsDataStoresOperationsService(s) rs.ServingConfigs = NewProjectsLocationsCollectionsDataStoresServingConfigsService(s) rs.UserEvents = NewProjectsLocationsCollectionsDataStoresUserEventsService(s) return rs @@ -195,6 +200,10 @@ type ProjectsLocationsCollectionsDataStoresService struct { Branches *ProjectsLocationsCollectionsDataStoresBranchesService + Models *ProjectsLocationsCollectionsDataStoresModelsService + + Operations *ProjectsLocationsCollectionsDataStoresOperationsService + ServingConfigs *ProjectsLocationsCollectionsDataStoresServingConfigsService UserEvents *ProjectsLocationsCollectionsDataStoresUserEventsService @@ -203,6 +212,7 @@ type ProjectsLocationsCollectionsDataStoresService struct { func NewProjectsLocationsCollectionsDataStoresBranchesService(s *Service) *ProjectsLocationsCollectionsDataStoresBranchesService { rs := &ProjectsLocationsCollectionsDataStoresBranchesService{s: s} rs.Documents = NewProjectsLocationsCollectionsDataStoresBranchesDocumentsService(s) + rs.Operations = NewProjectsLocationsCollectionsDataStoresBranchesOperationsService(s) return rs } @@ -210,6 +220,8 @@ type ProjectsLocationsCollectionsDataStoresBranchesService struct { s *Service Documents *ProjectsLocationsCollectionsDataStoresBranchesDocumentsService + + Operations *ProjectsLocationsCollectionsDataStoresBranchesOperationsService } func NewProjectsLocationsCollectionsDataStoresBranchesDocumentsService(s *Service) *ProjectsLocationsCollectionsDataStoresBranchesDocumentsService { @@ -221,6 +233,45 @@ type ProjectsLocationsCollectionsDataStoresBranchesDocumentsService struct { s *Service } +func NewProjectsLocationsCollectionsDataStoresBranchesOperationsService(s *Service) *ProjectsLocationsCollectionsDataStoresBranchesOperationsService { + rs := &ProjectsLocationsCollectionsDataStoresBranchesOperationsService{s: s} + return rs +} + +type ProjectsLocationsCollectionsDataStoresBranchesOperationsService struct { + s *Service +} + +func NewProjectsLocationsCollectionsDataStoresModelsService(s *Service) *ProjectsLocationsCollectionsDataStoresModelsService { + rs := &ProjectsLocationsCollectionsDataStoresModelsService{s: s} + rs.Operations = NewProjectsLocationsCollectionsDataStoresModelsOperationsService(s) + return rs +} + +type ProjectsLocationsCollectionsDataStoresModelsService struct { + s *Service + + Operations *ProjectsLocationsCollectionsDataStoresModelsOperationsService +} + +func NewProjectsLocationsCollectionsDataStoresModelsOperationsService(s *Service) *ProjectsLocationsCollectionsDataStoresModelsOperationsService { + rs := &ProjectsLocationsCollectionsDataStoresModelsOperationsService{s: s} + return rs +} + +type ProjectsLocationsCollectionsDataStoresModelsOperationsService struct { + s *Service +} + +func NewProjectsLocationsCollectionsDataStoresOperationsService(s *Service) *ProjectsLocationsCollectionsDataStoresOperationsService { + rs := &ProjectsLocationsCollectionsDataStoresOperationsService{s: s} + return rs +} + +type ProjectsLocationsCollectionsDataStoresOperationsService struct { + s *Service +} + func NewProjectsLocationsCollectionsDataStoresServingConfigsService(s *Service) *ProjectsLocationsCollectionsDataStoresServingConfigsService { rs := &ProjectsLocationsCollectionsDataStoresServingConfigsService{s: s} return rs @@ -239,6 +290,15 @@ type ProjectsLocationsCollectionsDataStoresUserEventsService struct { s *Service } +func NewProjectsLocationsCollectionsOperationsService(s *Service) *ProjectsLocationsCollectionsOperationsService { + rs := &ProjectsLocationsCollectionsOperationsService{s: s} + return rs +} + +type ProjectsLocationsCollectionsOperationsService struct { + s *Service +} + func NewProjectsLocationsDataStoresService(s *Service) *ProjectsLocationsDataStoresService { rs := &ProjectsLocationsDataStoresService{s: s} rs.Branches = NewProjectsLocationsDataStoresBranchesService(s) @@ -639,6 +699,273 @@ func (s *GoogleCloudDiscoveryengineLoggingSourceLocation) MarshalJSON() ([]byte, return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } +// GoogleCloudDiscoveryengineV1alphaCondition: Defines circumstances to +// be checked before allowing a behavior +type GoogleCloudDiscoveryengineV1alphaCondition struct { + // ActiveTimeRange: Optional. Range of time(s) specifying when condition + // is active. Maximum of 10 time ranges. + ActiveTimeRange []*GoogleCloudDiscoveryengineV1alphaConditionTimeRange `json:"activeTimeRange,omitempty"` + + // QueryTerms: Optional. Search only A list of terms to match the query + // on. Maximum of 10 query terms. + QueryTerms []*GoogleCloudDiscoveryengineV1alphaConditionQueryTerm `json:"queryTerms,omitempty"` + + // ForceSendFields is a list of field names (e.g. "ActiveTimeRange") 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. "ActiveTimeRange") 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 *GoogleCloudDiscoveryengineV1alphaCondition) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaCondition + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + +// GoogleCloudDiscoveryengineV1alphaConditionQueryTerm: Matcher for +// search request query +type GoogleCloudDiscoveryengineV1alphaConditionQueryTerm struct { + // FullMatch: Whether the search query needs to exactly match the query + // term. + FullMatch bool `json:"fullMatch,omitempty"` + + // Value: The specific query value to match against Must be lowercase, + // must be UTF-8. Can have at most 3 space separated terms if full_match + // is true. Cannot be an empty string. Maximum length of 5000 + // characters. + Value string `json:"value,omitempty"` + + // ForceSendFields is a list of field names (e.g. "FullMatch") 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. "FullMatch") 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 *GoogleCloudDiscoveryengineV1alphaConditionQueryTerm) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaConditionQueryTerm + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + +// GoogleCloudDiscoveryengineV1alphaConditionTimeRange: Used for +// time-dependent conditions. +type GoogleCloudDiscoveryengineV1alphaConditionTimeRange struct { + // EndTime: End of time range. Range is inclusive. Must be in the + // future. + EndTime string `json:"endTime,omitempty"` + + // StartTime: Start of time range. Range is inclusive. + StartTime string `json:"startTime,omitempty"` + + // ForceSendFields is a list of field names (e.g. "EndTime") 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. "EndTime") 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 *GoogleCloudDiscoveryengineV1alphaConditionTimeRange) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaConditionTimeRange + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + +// GoogleCloudDiscoveryengineV1alphaControl: Defines a conditioned +// behavior to employ during serving. Must be attached to a +// [ServingConfig] to be considered at serving time. Permitted actions +// dependent on Solution Type. +type GoogleCloudDiscoveryengineV1alphaControl struct { + // AssociatedServingConfigIds: Output only. List of all [ServingConfig] + // ids this control is attached to. May take up to 10 minutes to update + // after changes. + AssociatedServingConfigIds []string `json:"associatedServingConfigIds,omitempty"` + + // BoostAction: Defines a boost-type control + BoostAction *GoogleCloudDiscoveryengineV1alphaControlBoostAction `json:"boostAction,omitempty"` + + // Conditions: Determines when the associated action will trigger. Omit + // to always apply the action. Currently only a single condition may be + // specified. Otherwise an INVALID ARGUMENT error is thrown. + Conditions []*GoogleCloudDiscoveryengineV1alphaCondition `json:"conditions,omitempty"` + + // DisplayName: Required. Human readable name. The identifier used in UI + // views. Must be UTF-8 encoded string. Length limit is 128 characters. + // Otherwise an INVALID ARGUMENT error is thrown. + DisplayName string `json:"displayName,omitempty"` + + // FilterAction: Defines a filter-type control Currently not supported + // by Recommendation + FilterAction *GoogleCloudDiscoveryengineV1alphaControlFilterAction `json:"filterAction,omitempty"` + + // Name: Immutable. Fully qualified name + // `projects/*/locations/global/dataStore/*/controls/*` + Name string `json:"name,omitempty"` + + // SolutionType: Required. What solution the control belongs to. Must be + // compatible with vertical of resource. Otherwise an INVALID ARGUMENT + // error is thrown. + // + // Possible values: + // "SOLUTION_TYPE_UNSPECIFIED" - Default value. + // "SOLUTION_TYPE_RECOMMENDATION" - Used for Recommendations AI. + // "SOLUTION_TYPE_SEARCH" - Used for Discovery Search. + SolutionType string `json:"solutionType,omitempty"` + + // UseCases: Specifies the use case for the control. Affects what + // condition fields can be set. Only applies to SOLUTION_TYPE_SEARCH. + // Currently only allow one use case per control. Must be set when + // solution_type is SolutionType.SOLUTION_TYPE_SEARCH. + // + // Possible values: + // "SEARCH_USE_CASE_UNSPECIFIED" - Value used when unset. Will not + // occur in CSS. + // "SEARCH_USE_CASE_SEARCH" - Search use case. Expects the traffic has + // a non-empty query. + // "SEARCH_USE_CASE_BROWSE" - Browse use case. Expects the traffic has + // an empty query. + UseCases []string `json:"useCases,omitempty"` + + // ForceSendFields is a list of field names (e.g. + // "AssociatedServingConfigIds") 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. + // "AssociatedServingConfigIds") 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 *GoogleCloudDiscoveryengineV1alphaControl) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaControl + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + +// GoogleCloudDiscoveryengineV1alphaControlBoostAction: Adjusts order of +// products in returned list. +type GoogleCloudDiscoveryengineV1alphaControlBoostAction struct { + // Boost: Required. Strength of the boost, which should be in [-1, 1]. + // Negative boost means demotion. Default is 0.0 (No-op). + Boost float64 `json:"boost,omitempty"` + + // Filter: Required. Specifies which products to apply the boost to. If + // no filter is provided all products will be boosted (No-op). Syntax + // documentation: https://cloud.google.com/retail/docs/filter-and-order + // Maximum length is 5000 characters. Otherwise an INVALID ARGUMENT + // error is thrown. + Filter string `json:"filter,omitempty"` + + // ForceSendFields is a list of field names (e.g. "Boost") 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. "Boost") 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 *GoogleCloudDiscoveryengineV1alphaControlBoostAction) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaControlBoostAction + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + +func (s *GoogleCloudDiscoveryengineV1alphaControlBoostAction) UnmarshalJSON(data []byte) error { + type NoMethod GoogleCloudDiscoveryengineV1alphaControlBoostAction + var s1 struct { + Boost gensupport.JSONFloat64 `json:"boost"` + *NoMethod + } + s1.NoMethod = (*NoMethod)(s) + if err := json.Unmarshal(data, &s1); err != nil { + return err + } + s.Boost = float64(s1.Boost) + return nil +} + +// GoogleCloudDiscoveryengineV1alphaControlFilterAction: Specified which +// products may be included in results. Uses same filter as boost. +type GoogleCloudDiscoveryengineV1alphaControlFilterAction struct { + // Filter: Required. A filter to apply on the matching condition + // results. Required Syntax documentation: + // https://cloud.google.com/retail/docs/filter-and-order Maximum length + // is 5000 characters. Otherwise an INVALID ARGUMENT error is thrown. + Filter string `json:"filter,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 *GoogleCloudDiscoveryengineV1alphaControlFilterAction) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaControlFilterAction + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + // GoogleCloudDiscoveryengineV1alphaImportDocumentsMetadata: Metadata // related to the progress of the ImportDocuments operation. This will // be returned by the google.longrunning.Operation.metadata field. @@ -3353,94 +3680,97 @@ func (c *ProjectsLocationsCollectionsDataStoresBranchesDocumentsPatchCall) Do(op } -// method id "discoveryengine.projects.locations.collections.dataStores.servingConfigs.recommend": +// method id "discoveryengine.projects.locations.collections.dataStores.branches.operations.get": -type ProjectsLocationsCollectionsDataStoresServingConfigsRecommendCall struct { - s *Service - servingConfig string - googleclouddiscoveryenginev1betarecommendrequest *GoogleCloudDiscoveryengineV1betaRecommendRequest - urlParams_ gensupport.URLParams - ctx_ context.Context - header_ http.Header +type ProjectsLocationsCollectionsDataStoresBranchesOperationsGetCall struct { + s *Service + name string + urlParams_ gensupport.URLParams + ifNoneMatch_ string + ctx_ context.Context + header_ http.Header } -// Recommend: Makes a recommendation, which requires a contextual user -// event. +// 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. // -// - servingConfig: Full resource name of the format: -// projects/*/locations/global/collections/*/dataStores/*/servingConfig -// s/* Before you can request recommendations from your model, you -// must create at least one serving config for it. -func (r *ProjectsLocationsCollectionsDataStoresServingConfigsService) Recommend(servingConfig string, googleclouddiscoveryenginev1betarecommendrequest *GoogleCloudDiscoveryengineV1betaRecommendRequest) *ProjectsLocationsCollectionsDataStoresServingConfigsRecommendCall { - c := &ProjectsLocationsCollectionsDataStoresServingConfigsRecommendCall{s: r.s, urlParams_: make(gensupport.URLParams)} - c.servingConfig = servingConfig - c.googleclouddiscoveryenginev1betarecommendrequest = googleclouddiscoveryenginev1betarecommendrequest +// - name: The name of the operation resource. +func (r *ProjectsLocationsCollectionsDataStoresBranchesOperationsService) Get(name string) *ProjectsLocationsCollectionsDataStoresBranchesOperationsGetCall { + c := &ProjectsLocationsCollectionsDataStoresBranchesOperationsGetCall{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 *ProjectsLocationsCollectionsDataStoresServingConfigsRecommendCall) Fields(s ...googleapi.Field) *ProjectsLocationsCollectionsDataStoresServingConfigsRecommendCall { +func (c *ProjectsLocationsCollectionsDataStoresBranchesOperationsGetCall) Fields(s ...googleapi.Field) *ProjectsLocationsCollectionsDataStoresBranchesOperationsGetCall { 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 *ProjectsLocationsCollectionsDataStoresBranchesOperationsGetCall) IfNoneMatch(entityTag string) *ProjectsLocationsCollectionsDataStoresBranchesOperationsGetCall { + 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 *ProjectsLocationsCollectionsDataStoresServingConfigsRecommendCall) Context(ctx context.Context) *ProjectsLocationsCollectionsDataStoresServingConfigsRecommendCall { +func (c *ProjectsLocationsCollectionsDataStoresBranchesOperationsGetCall) Context(ctx context.Context) *ProjectsLocationsCollectionsDataStoresBranchesOperationsGetCall { 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 *ProjectsLocationsCollectionsDataStoresServingConfigsRecommendCall) Header() http.Header { +func (c *ProjectsLocationsCollectionsDataStoresBranchesOperationsGetCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) } return c.header_ } -func (c *ProjectsLocationsCollectionsDataStoresServingConfigsRecommendCall) doRequest(alt string) (*http.Response, error) { +func (c *ProjectsLocationsCollectionsDataStoresBranchesOperationsGetCall) 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.googleclouddiscoveryenginev1betarecommendrequest) - if err != nil { - return nil, err + if c.ifNoneMatch_ != "" { + reqHeaders.Set("If-None-Match", c.ifNoneMatch_) } - reqHeaders.Set("Content-Type", "application/json") + var body io.Reader = nil c.urlParams_.Set("alt", alt) c.urlParams_.Set("prettyPrint", "false") - urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta/{+servingConfig}:recommend") + urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta/{+name}") urls += "?" + c.urlParams_.Encode() - req, err := http.NewRequest("POST", urls, body) + req, err := http.NewRequest("GET", urls, body) if err != nil { return nil, err } req.Header = reqHeaders googleapi.Expand(req.URL, map[string]string{ - "servingConfig": c.servingConfig, + "name": c.name, }) return gensupport.SendRequest(c.ctx_, c.s.client, req) } -// Do executes the "discoveryengine.projects.locations.collections.dataStores.servingConfigs.recommend" call. -// Exactly one of *GoogleCloudDiscoveryengineV1betaRecommendResponse or -// error will be non-nil. Any non-2xx status code is an error. Response -// headers are in either -// *GoogleCloudDiscoveryengineV1betaRecommendResponse.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 *ProjectsLocationsCollectionsDataStoresServingConfigsRecommendCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDiscoveryengineV1betaRecommendResponse, error) { +// Do executes the "discoveryengine.projects.locations.collections.dataStores.branches.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 *ProjectsLocationsCollectionsDataStoresBranchesOperationsGetCall) Do(opts ...googleapi.CallOption) (*GoogleLongrunningOperation, error) { gensupport.SetOptions(c.urlParams_, opts...) res, err := c.doRequest("json") if res != nil && res.StatusCode == http.StatusNotModified { @@ -3459,7 +3789,7 @@ func (c *ProjectsLocationsCollectionsDataStoresServingConfigsRecommendCall) Do(o if err := googleapi.CheckResponse(res); err != nil { return nil, gensupport.WrapError(err) } - ret := &GoogleCloudDiscoveryengineV1betaRecommendResponse{ + ret := &GoogleLongrunningOperation{ ServerResponse: googleapi.ServerResponse{ Header: res.Header, HTTPStatusCode: res.StatusCode, @@ -3471,28 +3801,25 @@ func (c *ProjectsLocationsCollectionsDataStoresServingConfigsRecommendCall) Do(o } return ret, nil // { - // "description": "Makes a recommendation, which requires a contextual user event.", - // "flatPath": "v1beta/projects/{projectsId}/locations/{locationsId}/collections/{collectionsId}/dataStores/{dataStoresId}/servingConfigs/{servingConfigsId}:recommend", - // "httpMethod": "POST", - // "id": "discoveryengine.projects.locations.collections.dataStores.servingConfigs.recommend", + // "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": "v1beta/projects/{projectsId}/locations/{locationsId}/collections/{collectionsId}/dataStores/{dataStoresId}/branches/{branchesId}/operations/{operationsId}", + // "httpMethod": "GET", + // "id": "discoveryengine.projects.locations.collections.dataStores.branches.operations.get", // "parameterOrder": [ - // "servingConfig" + // "name" // ], // "parameters": { - // "servingConfig": { - // "description": "Required. Full resource name of the format: projects/*/locations/global/collections/*/dataStores/*/servingConfigs/* Before you can request recommendations from your model, you must create at least one serving config for it.", + // "name": { + // "description": "The name of the operation resource.", // "location": "path", - // "pattern": "^projects/[^/]+/locations/[^/]+/collections/[^/]+/dataStores/[^/]+/servingConfigs/[^/]+$", + // "pattern": "^projects/[^/]+/locations/[^/]+/collections/[^/]+/dataStores/[^/]+/branches/[^/]+/operations/[^/]+$", // "required": true, // "type": "string" // } // }, - // "path": "v1beta/{+servingConfig}:recommend", - // "request": { - // "$ref": "GoogleCloudDiscoveryengineV1betaRecommendRequest" - // }, + // "path": "v1beta/{+name}", // "response": { - // "$ref": "GoogleCloudDiscoveryengineV1betaRecommendResponse" + // "$ref": "GoogleLongrunningOperation" // }, // "scopes": [ // "https://www.googleapis.com/auth/cloud-platform" @@ -3501,60 +3828,53 @@ func (c *ProjectsLocationsCollectionsDataStoresServingConfigsRecommendCall) Do(o } -// method id "discoveryengine.projects.locations.collections.dataStores.userEvents.collect": +// method id "discoveryengine.projects.locations.collections.dataStores.branches.operations.list": -type ProjectsLocationsCollectionsDataStoresUserEventsCollectCall struct { +type ProjectsLocationsCollectionsDataStoresBranchesOperationsListCall struct { s *Service - parent string + name string urlParams_ gensupport.URLParams ifNoneMatch_ string ctx_ context.Context header_ http.Header } -// Collect: Writes a single user event from the browser. This uses a GET -// request to due to browser restriction of POST-ing to a 3rd party -// domain. This method is used only by the Discovery Engine API -// JavaScript pixel and Google Tag Manager. Users should not call this -// method directly. +// List: Lists operations that match the specified filter in the +// request. If the server doesn't support this method, it returns +// `UNIMPLEMENTED`. // -// - parent: The parent DataStore resource name, such as -// `projects/{project}/locations/{location}/collections/{collection}/da -// taStores/{data_store}`. -func (r *ProjectsLocationsCollectionsDataStoresUserEventsService) Collect(parent string) *ProjectsLocationsCollectionsDataStoresUserEventsCollectCall { - c := &ProjectsLocationsCollectionsDataStoresUserEventsCollectCall{s: r.s, urlParams_: make(gensupport.URLParams)} - c.parent = parent +// - name: The name of the operation's parent resource. +func (r *ProjectsLocationsCollectionsDataStoresBranchesOperationsService) List(name string) *ProjectsLocationsCollectionsDataStoresBranchesOperationsListCall { + c := &ProjectsLocationsCollectionsDataStoresBranchesOperationsListCall{s: r.s, urlParams_: make(gensupport.URLParams)} + c.name = name return c } -// Ets sets the optional parameter "ets": The event timestamp in -// milliseconds. This prevents browser caching of otherwise identical -// get requests. The name is abbreviated to reduce the payload bytes. -func (c *ProjectsLocationsCollectionsDataStoresUserEventsCollectCall) Ets(ets int64) *ProjectsLocationsCollectionsDataStoresUserEventsCollectCall { - c.urlParams_.Set("ets", fmt.Sprint(ets)) +// Filter sets the optional parameter "filter": The standard list +// filter. +func (c *ProjectsLocationsCollectionsDataStoresBranchesOperationsListCall) Filter(filter string) *ProjectsLocationsCollectionsDataStoresBranchesOperationsListCall { + c.urlParams_.Set("filter", filter) return c } -// Uri sets the optional parameter "uri": The URL including -// cgi-parameters but excluding the hash fragment with a length limit of -// 5,000 characters. This is often more useful than the referer URL, -// because many browsers only send the domain for 3rd party requests. -func (c *ProjectsLocationsCollectionsDataStoresUserEventsCollectCall) Uri(uri string) *ProjectsLocationsCollectionsDataStoresUserEventsCollectCall { - c.urlParams_.Set("uri", uri) +// PageSize sets the optional parameter "pageSize": The standard list +// page size. +func (c *ProjectsLocationsCollectionsDataStoresBranchesOperationsListCall) PageSize(pageSize int64) *ProjectsLocationsCollectionsDataStoresBranchesOperationsListCall { + c.urlParams_.Set("pageSize", fmt.Sprint(pageSize)) return c } -// UserEvent sets the optional parameter "userEvent": Required. URL -// encoded UserEvent proto with a length limit of 2,000,000 characters. -func (c *ProjectsLocationsCollectionsDataStoresUserEventsCollectCall) UserEvent(userEvent string) *ProjectsLocationsCollectionsDataStoresUserEventsCollectCall { - c.urlParams_.Set("userEvent", userEvent) +// PageToken sets the optional parameter "pageToken": The standard list +// page token. +func (c *ProjectsLocationsCollectionsDataStoresBranchesOperationsListCall) PageToken(pageToken string) *ProjectsLocationsCollectionsDataStoresBranchesOperationsListCall { + 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 *ProjectsLocationsCollectionsDataStoresUserEventsCollectCall) Fields(s ...googleapi.Field) *ProjectsLocationsCollectionsDataStoresUserEventsCollectCall { +func (c *ProjectsLocationsCollectionsDataStoresBranchesOperationsListCall) Fields(s ...googleapi.Field) *ProjectsLocationsCollectionsDataStoresBranchesOperationsListCall { c.urlParams_.Set("fields", googleapi.CombineFields(s)) return c } @@ -3564,7 +3884,7 @@ func (c *ProjectsLocationsCollectionsDataStoresUserEventsCollectCall) Fields(s . // 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 *ProjectsLocationsCollectionsDataStoresUserEventsCollectCall) IfNoneMatch(entityTag string) *ProjectsLocationsCollectionsDataStoresUserEventsCollectCall { +func (c *ProjectsLocationsCollectionsDataStoresBranchesOperationsListCall) IfNoneMatch(entityTag string) *ProjectsLocationsCollectionsDataStoresBranchesOperationsListCall { c.ifNoneMatch_ = entityTag return c } @@ -3572,21 +3892,21 @@ func (c *ProjectsLocationsCollectionsDataStoresUserEventsCollectCall) IfNoneMatc // 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 *ProjectsLocationsCollectionsDataStoresUserEventsCollectCall) Context(ctx context.Context) *ProjectsLocationsCollectionsDataStoresUserEventsCollectCall { +func (c *ProjectsLocationsCollectionsDataStoresBranchesOperationsListCall) Context(ctx context.Context) *ProjectsLocationsCollectionsDataStoresBranchesOperationsListCall { 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 *ProjectsLocationsCollectionsDataStoresUserEventsCollectCall) Header() http.Header { +func (c *ProjectsLocationsCollectionsDataStoresBranchesOperationsListCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) } return c.header_ } -func (c *ProjectsLocationsCollectionsDataStoresUserEventsCollectCall) doRequest(alt string) (*http.Response, error) { +func (c *ProjectsLocationsCollectionsDataStoresBranchesOperationsListCall) 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_ { @@ -3599,7 +3919,7 @@ func (c *ProjectsLocationsCollectionsDataStoresUserEventsCollectCall) doRequest( var body io.Reader = nil c.urlParams_.Set("alt", alt) c.urlParams_.Set("prettyPrint", "false") - urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta/{+parent}/userEvents:collect") + urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta/{+name}/operations") urls += "?" + c.urlParams_.Encode() req, err := http.NewRequest("GET", urls, body) if err != nil { @@ -3607,19 +3927,20 @@ func (c *ProjectsLocationsCollectionsDataStoresUserEventsCollectCall) doRequest( } req.Header = reqHeaders googleapi.Expand(req.URL, map[string]string{ - "parent": c.parent, + "name": c.name, }) return gensupport.SendRequest(c.ctx_, c.s.client, req) } -// Do executes the "discoveryengine.projects.locations.collections.dataStores.userEvents.collect" call. -// Exactly one of *GoogleApiHttpBody or error will be non-nil. Any -// non-2xx status code is an error. Response headers are in either -// *GoogleApiHttpBody.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 +// Do executes the "discoveryengine.projects.locations.collections.dataStores.branches.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 *ProjectsLocationsCollectionsDataStoresUserEventsCollectCall) Do(opts ...googleapi.CallOption) (*GoogleApiHttpBody, error) { +func (c *ProjectsLocationsCollectionsDataStoresBranchesOperationsListCall) Do(opts ...googleapi.CallOption) (*GoogleLongrunningListOperationsResponse, error) { gensupport.SetOptions(c.urlParams_, opts...) res, err := c.doRequest("json") if res != nil && res.StatusCode == http.StatusNotModified { @@ -3638,7 +3959,7 @@ func (c *ProjectsLocationsCollectionsDataStoresUserEventsCollectCall) Do(opts .. if err := googleapi.CheckResponse(res); err != nil { return nil, gensupport.WrapError(err) } - ret := &GoogleApiHttpBody{ + ret := &GoogleLongrunningListOperationsResponse{ ServerResponse: googleapi.ServerResponse{ Header: res.Header, HTTPStatusCode: res.StatusCode, @@ -3650,41 +3971,41 @@ func (c *ProjectsLocationsCollectionsDataStoresUserEventsCollectCall) Do(opts .. } return ret, nil // { - // "description": "Writes a single user event from the browser. This uses a GET request to due to browser restriction of POST-ing to a 3rd party domain. This method is used only by the Discovery Engine API JavaScript pixel and Google Tag Manager. Users should not call this method directly.", - // "flatPath": "v1beta/projects/{projectsId}/locations/{locationsId}/collections/{collectionsId}/dataStores/{dataStoresId}/userEvents:collect", + // "description": "Lists operations that match the specified filter in the request. If the server doesn't support this method, it returns `UNIMPLEMENTED`.", + // "flatPath": "v1beta/projects/{projectsId}/locations/{locationsId}/collections/{collectionsId}/dataStores/{dataStoresId}/branches/{branchesId}/operations", // "httpMethod": "GET", - // "id": "discoveryengine.projects.locations.collections.dataStores.userEvents.collect", + // "id": "discoveryengine.projects.locations.collections.dataStores.branches.operations.list", // "parameterOrder": [ - // "parent" + // "name" // ], // "parameters": { - // "ets": { - // "description": "The event timestamp in milliseconds. This prevents browser caching of otherwise identical get requests. The name is abbreviated to reduce the payload bytes.", - // "format": "int64", + // "filter": { + // "description": "The standard list filter.", // "location": "query", // "type": "string" // }, - // "parent": { - // "description": "Required. The parent DataStore resource name, such as `projects/{project}/locations/{location}/collections/{collection}/dataStores/{data_store}`.", + // "name": { + // "description": "The name of the operation's parent resource.", // "location": "path", - // "pattern": "^projects/[^/]+/locations/[^/]+/collections/[^/]+/dataStores/[^/]+$", + // "pattern": "^projects/[^/]+/locations/[^/]+/collections/[^/]+/dataStores/[^/]+/branches/[^/]+$", // "required": true, // "type": "string" // }, - // "uri": { - // "description": "The URL including cgi-parameters but excluding the hash fragment with a length limit of 5,000 characters. This is often more useful than the referer URL, because many browsers only send the domain for 3rd party requests.", + // "pageSize": { + // "description": "The standard list page size.", + // "format": "int32", // "location": "query", - // "type": "string" + // "type": "integer" // }, - // "userEvent": { - // "description": "Required. URL encoded UserEvent proto with a length limit of 2,000,000 characters.", + // "pageToken": { + // "description": "The standard list page token.", // "location": "query", // "type": "string" // } // }, - // "path": "v1beta/{+parent}/userEvents:collect", + // "path": "v1beta/{+name}/operations", // "response": { - // "$ref": "GoogleApiHttpBody" + // "$ref": "GoogleLongrunningListOperationsResponse" // }, // "scopes": [ // "https://www.googleapis.com/auth/cloud-platform" @@ -3693,95 +4014,118 @@ func (c *ProjectsLocationsCollectionsDataStoresUserEventsCollectCall) Do(opts .. } -// method id "discoveryengine.projects.locations.collections.dataStores.userEvents.import": +// 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 *ProjectsLocationsCollectionsDataStoresBranchesOperationsListCall) 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) + } +} -type ProjectsLocationsCollectionsDataStoresUserEventsImportCall struct { - s *Service - parent string - googleclouddiscoveryenginev1betaimportusereventsrequest *GoogleCloudDiscoveryengineV1betaImportUserEventsRequest - urlParams_ gensupport.URLParams - ctx_ context.Context - header_ http.Header +// method id "discoveryengine.projects.locations.collections.dataStores.models.operations.get": + +type ProjectsLocationsCollectionsDataStoresModelsOperationsGetCall struct { + s *Service + name string + urlParams_ gensupport.URLParams + ifNoneMatch_ string + ctx_ context.Context + header_ http.Header } -// Import: Bulk import of User events. Request processing might be -// synchronous. Events that already exist are skipped. Use this method -// for backfilling historical user events. Operation.response is of type -// ImportResponse. Note that it is possible for a subset of the items to -// be successfully inserted. Operation.metadata is of type -// ImportMetadata. +// 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. // -// - parent: Parent DataStore resource name, of the form -// `projects/{project}/locations/{location}/collections/{collection}/da -// taStores/{data_store}`. -func (r *ProjectsLocationsCollectionsDataStoresUserEventsService) Import(parent string, googleclouddiscoveryenginev1betaimportusereventsrequest *GoogleCloudDiscoveryengineV1betaImportUserEventsRequest) *ProjectsLocationsCollectionsDataStoresUserEventsImportCall { - c := &ProjectsLocationsCollectionsDataStoresUserEventsImportCall{s: r.s, urlParams_: make(gensupport.URLParams)} - c.parent = parent - c.googleclouddiscoveryenginev1betaimportusereventsrequest = googleclouddiscoveryenginev1betaimportusereventsrequest +// - name: The name of the operation resource. +func (r *ProjectsLocationsCollectionsDataStoresModelsOperationsService) Get(name string) *ProjectsLocationsCollectionsDataStoresModelsOperationsGetCall { + c := &ProjectsLocationsCollectionsDataStoresModelsOperationsGetCall{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 *ProjectsLocationsCollectionsDataStoresUserEventsImportCall) Fields(s ...googleapi.Field) *ProjectsLocationsCollectionsDataStoresUserEventsImportCall { +func (c *ProjectsLocationsCollectionsDataStoresModelsOperationsGetCall) Fields(s ...googleapi.Field) *ProjectsLocationsCollectionsDataStoresModelsOperationsGetCall { 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 *ProjectsLocationsCollectionsDataStoresModelsOperationsGetCall) IfNoneMatch(entityTag string) *ProjectsLocationsCollectionsDataStoresModelsOperationsGetCall { + 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 *ProjectsLocationsCollectionsDataStoresUserEventsImportCall) Context(ctx context.Context) *ProjectsLocationsCollectionsDataStoresUserEventsImportCall { +func (c *ProjectsLocationsCollectionsDataStoresModelsOperationsGetCall) Context(ctx context.Context) *ProjectsLocationsCollectionsDataStoresModelsOperationsGetCall { 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 *ProjectsLocationsCollectionsDataStoresUserEventsImportCall) Header() http.Header { +func (c *ProjectsLocationsCollectionsDataStoresModelsOperationsGetCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) } return c.header_ } -func (c *ProjectsLocationsCollectionsDataStoresUserEventsImportCall) doRequest(alt string) (*http.Response, error) { +func (c *ProjectsLocationsCollectionsDataStoresModelsOperationsGetCall) 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.googleclouddiscoveryenginev1betaimportusereventsrequest) - if err != nil { - return nil, err + if c.ifNoneMatch_ != "" { + reqHeaders.Set("If-None-Match", c.ifNoneMatch_) } - reqHeaders.Set("Content-Type", "application/json") + var body io.Reader = nil c.urlParams_.Set("alt", alt) c.urlParams_.Set("prettyPrint", "false") - urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta/{+parent}/userEvents:import") + urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta/{+name}") urls += "?" + c.urlParams_.Encode() - req, err := http.NewRequest("POST", urls, body) + req, err := http.NewRequest("GET", urls, body) if err != nil { return nil, err } req.Header = reqHeaders googleapi.Expand(req.URL, map[string]string{ - "parent": c.parent, + "name": c.name, }) return gensupport.SendRequest(c.ctx_, c.s.client, req) } -// Do executes the "discoveryengine.projects.locations.collections.dataStores.userEvents.import" call. +// Do executes the "discoveryengine.projects.locations.collections.dataStores.models.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 *ProjectsLocationsCollectionsDataStoresUserEventsImportCall) Do(opts ...googleapi.CallOption) (*GoogleLongrunningOperation, error) { +func (c *ProjectsLocationsCollectionsDataStoresModelsOperationsGetCall) Do(opts ...googleapi.CallOption) (*GoogleLongrunningOperation, error) { gensupport.SetOptions(c.urlParams_, opts...) res, err := c.doRequest("json") if res != nil && res.StatusCode == http.StatusNotModified { @@ -3812,26 +4156,23 @@ func (c *ProjectsLocationsCollectionsDataStoresUserEventsImportCall) Do(opts ... } return ret, nil // { - // "description": "Bulk import of User events. Request processing might be synchronous. Events that already exist are skipped. Use this method for backfilling historical user events. Operation.response is of type ImportResponse. Note that it is possible for a subset of the items to be successfully inserted. Operation.metadata is of type ImportMetadata.", - // "flatPath": "v1beta/projects/{projectsId}/locations/{locationsId}/collections/{collectionsId}/dataStores/{dataStoresId}/userEvents:import", - // "httpMethod": "POST", - // "id": "discoveryengine.projects.locations.collections.dataStores.userEvents.import", + // "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": "v1beta/projects/{projectsId}/locations/{locationsId}/collections/{collectionsId}/dataStores/{dataStoresId}/models/{modelsId}/operations/{operationsId}", + // "httpMethod": "GET", + // "id": "discoveryengine.projects.locations.collections.dataStores.models.operations.get", // "parameterOrder": [ - // "parent" + // "name" // ], // "parameters": { - // "parent": { - // "description": "Required. Parent DataStore resource name, of the form `projects/{project}/locations/{location}/collections/{collection}/dataStores/{data_store}`", + // "name": { + // "description": "The name of the operation resource.", // "location": "path", - // "pattern": "^projects/[^/]+/locations/[^/]+/collections/[^/]+/dataStores/[^/]+$", + // "pattern": "^projects/[^/]+/locations/[^/]+/collections/[^/]+/dataStores/[^/]+/models/[^/]+/operations/[^/]+$", // "required": true, // "type": "string" // } // }, - // "path": "v1beta/{+parent}/userEvents:import", - // "request": { - // "$ref": "GoogleCloudDiscoveryengineV1betaImportUserEventsRequest" - // }, + // "path": "v1beta/{+name}", // "response": { // "$ref": "GoogleLongrunningOperation" // }, @@ -3842,92 +4183,1464 @@ func (c *ProjectsLocationsCollectionsDataStoresUserEventsImportCall) Do(opts ... } -// method id "discoveryengine.projects.locations.collections.dataStores.userEvents.write": +// method id "discoveryengine.projects.locations.collections.dataStores.models.operations.list": -type ProjectsLocationsCollectionsDataStoresUserEventsWriteCall struct { - s *Service - parent string - googleclouddiscoveryenginev1betauserevent *GoogleCloudDiscoveryengineV1betaUserEvent - urlParams_ gensupport.URLParams - ctx_ context.Context - header_ http.Header +type ProjectsLocationsCollectionsDataStoresModelsOperationsListCall struct { + s *Service + name string + urlParams_ gensupport.URLParams + ifNoneMatch_ string + ctx_ context.Context + header_ http.Header } -// Write: Writes a single user event. +// List: Lists operations that match the specified filter in the +// request. If the server doesn't support this method, it returns +// `UNIMPLEMENTED`. // -// - parent: The parent DataStore resource name, such as -// `projects/{project}/locations/{location}/collections/{collection}/da -// taStores/{data_store}`. -func (r *ProjectsLocationsCollectionsDataStoresUserEventsService) Write(parent string, googleclouddiscoveryenginev1betauserevent *GoogleCloudDiscoveryengineV1betaUserEvent) *ProjectsLocationsCollectionsDataStoresUserEventsWriteCall { - c := &ProjectsLocationsCollectionsDataStoresUserEventsWriteCall{s: r.s, urlParams_: make(gensupport.URLParams)} - c.parent = parent - c.googleclouddiscoveryenginev1betauserevent = googleclouddiscoveryenginev1betauserevent +// - name: The name of the operation's parent resource. +func (r *ProjectsLocationsCollectionsDataStoresModelsOperationsService) List(name string) *ProjectsLocationsCollectionsDataStoresModelsOperationsListCall { + c := &ProjectsLocationsCollectionsDataStoresModelsOperationsListCall{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 *ProjectsLocationsCollectionsDataStoresUserEventsWriteCall) Fields(s ...googleapi.Field) *ProjectsLocationsCollectionsDataStoresUserEventsWriteCall { - c.urlParams_.Set("fields", googleapi.CombineFields(s)) +// Filter sets the optional parameter "filter": The standard list +// filter. +func (c *ProjectsLocationsCollectionsDataStoresModelsOperationsListCall) Filter(filter string) *ProjectsLocationsCollectionsDataStoresModelsOperationsListCall { + c.urlParams_.Set("filter", filter) 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 *ProjectsLocationsCollectionsDataStoresUserEventsWriteCall) Context(ctx context.Context) *ProjectsLocationsCollectionsDataStoresUserEventsWriteCall { - c.ctx_ = ctx +// PageSize sets the optional parameter "pageSize": The standard list +// page size. +func (c *ProjectsLocationsCollectionsDataStoresModelsOperationsListCall) PageSize(pageSize int64) *ProjectsLocationsCollectionsDataStoresModelsOperationsListCall { + c.urlParams_.Set("pageSize", fmt.Sprint(pageSize)) return c } -// Header returns an http.Header that can be modified by the caller to +// PageToken sets the optional parameter "pageToken": The standard list +// page token. +func (c *ProjectsLocationsCollectionsDataStoresModelsOperationsListCall) PageToken(pageToken string) *ProjectsLocationsCollectionsDataStoresModelsOperationsListCall { + 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 *ProjectsLocationsCollectionsDataStoresModelsOperationsListCall) Fields(s ...googleapi.Field) *ProjectsLocationsCollectionsDataStoresModelsOperationsListCall { + 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 *ProjectsLocationsCollectionsDataStoresModelsOperationsListCall) IfNoneMatch(entityTag string) *ProjectsLocationsCollectionsDataStoresModelsOperationsListCall { + 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 *ProjectsLocationsCollectionsDataStoresModelsOperationsListCall) Context(ctx context.Context) *ProjectsLocationsCollectionsDataStoresModelsOperationsListCall { + 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 *ProjectsLocationsCollectionsDataStoresModelsOperationsListCall) Header() http.Header { + if c.header_ == nil { + c.header_ = make(http.Header) + } + return c.header_ +} + +func (c *ProjectsLocationsCollectionsDataStoresModelsOperationsListCall) 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, "v1beta/{+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 "discoveryengine.projects.locations.collections.dataStores.models.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 *ProjectsLocationsCollectionsDataStoresModelsOperationsListCall) 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": "v1beta/projects/{projectsId}/locations/{locationsId}/collections/{collectionsId}/dataStores/{dataStoresId}/models/{modelsId}/operations", + // "httpMethod": "GET", + // "id": "discoveryengine.projects.locations.collections.dataStores.models.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/[^/]+/collections/[^/]+/dataStores/[^/]+/models/[^/]+$", + // "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": "v1beta/{+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 *ProjectsLocationsCollectionsDataStoresModelsOperationsListCall) 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 "discoveryengine.projects.locations.collections.dataStores.operations.get": + +type ProjectsLocationsCollectionsDataStoresOperationsGetCall 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 *ProjectsLocationsCollectionsDataStoresOperationsService) Get(name string) *ProjectsLocationsCollectionsDataStoresOperationsGetCall { + c := &ProjectsLocationsCollectionsDataStoresOperationsGetCall{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 *ProjectsLocationsCollectionsDataStoresOperationsGetCall) Fields(s ...googleapi.Field) *ProjectsLocationsCollectionsDataStoresOperationsGetCall { + 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 *ProjectsLocationsCollectionsDataStoresOperationsGetCall) IfNoneMatch(entityTag string) *ProjectsLocationsCollectionsDataStoresOperationsGetCall { + 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 *ProjectsLocationsCollectionsDataStoresOperationsGetCall) Context(ctx context.Context) *ProjectsLocationsCollectionsDataStoresOperationsGetCall { + 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 *ProjectsLocationsCollectionsDataStoresOperationsGetCall) Header() http.Header { + if c.header_ == nil { + c.header_ = make(http.Header) + } + return c.header_ +} + +func (c *ProjectsLocationsCollectionsDataStoresOperationsGetCall) 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, "v1beta/{+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 "discoveryengine.projects.locations.collections.dataStores.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 *ProjectsLocationsCollectionsDataStoresOperationsGetCall) 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": "v1beta/projects/{projectsId}/locations/{locationsId}/collections/{collectionsId}/dataStores/{dataStoresId}/operations/{operationsId}", + // "httpMethod": "GET", + // "id": "discoveryengine.projects.locations.collections.dataStores.operations.get", + // "parameterOrder": [ + // "name" + // ], + // "parameters": { + // "name": { + // "description": "The name of the operation resource.", + // "location": "path", + // "pattern": "^projects/[^/]+/locations/[^/]+/collections/[^/]+/dataStores/[^/]+/operations/[^/]+$", + // "required": true, + // "type": "string" + // } + // }, + // "path": "v1beta/{+name}", + // "response": { + // "$ref": "GoogleLongrunningOperation" + // }, + // "scopes": [ + // "https://www.googleapis.com/auth/cloud-platform" + // ] + // } + +} + +// method id "discoveryengine.projects.locations.collections.dataStores.operations.list": + +type ProjectsLocationsCollectionsDataStoresOperationsListCall 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 *ProjectsLocationsCollectionsDataStoresOperationsService) List(name string) *ProjectsLocationsCollectionsDataStoresOperationsListCall { + c := &ProjectsLocationsCollectionsDataStoresOperationsListCall{s: r.s, urlParams_: make(gensupport.URLParams)} + c.name = name + return c +} + +// Filter sets the optional parameter "filter": The standard list +// filter. +func (c *ProjectsLocationsCollectionsDataStoresOperationsListCall) Filter(filter string) *ProjectsLocationsCollectionsDataStoresOperationsListCall { + c.urlParams_.Set("filter", filter) + return c +} + +// PageSize sets the optional parameter "pageSize": The standard list +// page size. +func (c *ProjectsLocationsCollectionsDataStoresOperationsListCall) PageSize(pageSize int64) *ProjectsLocationsCollectionsDataStoresOperationsListCall { + c.urlParams_.Set("pageSize", fmt.Sprint(pageSize)) + return c +} + +// PageToken sets the optional parameter "pageToken": The standard list +// page token. +func (c *ProjectsLocationsCollectionsDataStoresOperationsListCall) PageToken(pageToken string) *ProjectsLocationsCollectionsDataStoresOperationsListCall { + 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 *ProjectsLocationsCollectionsDataStoresOperationsListCall) Fields(s ...googleapi.Field) *ProjectsLocationsCollectionsDataStoresOperationsListCall { + 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 *ProjectsLocationsCollectionsDataStoresOperationsListCall) IfNoneMatch(entityTag string) *ProjectsLocationsCollectionsDataStoresOperationsListCall { + 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 *ProjectsLocationsCollectionsDataStoresOperationsListCall) Context(ctx context.Context) *ProjectsLocationsCollectionsDataStoresOperationsListCall { + 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 *ProjectsLocationsCollectionsDataStoresOperationsListCall) Header() http.Header { + if c.header_ == nil { + c.header_ = make(http.Header) + } + return c.header_ +} + +func (c *ProjectsLocationsCollectionsDataStoresOperationsListCall) 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, "v1beta/{+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 "discoveryengine.projects.locations.collections.dataStores.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 *ProjectsLocationsCollectionsDataStoresOperationsListCall) 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": "v1beta/projects/{projectsId}/locations/{locationsId}/collections/{collectionsId}/dataStores/{dataStoresId}/operations", + // "httpMethod": "GET", + // "id": "discoveryengine.projects.locations.collections.dataStores.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/[^/]+/collections/[^/]+/dataStores/[^/]+$", + // "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": "v1beta/{+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 *ProjectsLocationsCollectionsDataStoresOperationsListCall) 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 "discoveryengine.projects.locations.collections.dataStores.servingConfigs.recommend": + +type ProjectsLocationsCollectionsDataStoresServingConfigsRecommendCall struct { + s *Service + servingConfig string + googleclouddiscoveryenginev1betarecommendrequest *GoogleCloudDiscoveryengineV1betaRecommendRequest + urlParams_ gensupport.URLParams + ctx_ context.Context + header_ http.Header +} + +// Recommend: Makes a recommendation, which requires a contextual user +// event. +// +// - servingConfig: Full resource name of the format: +// projects/*/locations/global/collections/*/dataStores/*/servingConfig +// s/* Before you can request recommendations from your model, you +// must create at least one serving config for it. +func (r *ProjectsLocationsCollectionsDataStoresServingConfigsService) Recommend(servingConfig string, googleclouddiscoveryenginev1betarecommendrequest *GoogleCloudDiscoveryengineV1betaRecommendRequest) *ProjectsLocationsCollectionsDataStoresServingConfigsRecommendCall { + c := &ProjectsLocationsCollectionsDataStoresServingConfigsRecommendCall{s: r.s, urlParams_: make(gensupport.URLParams)} + c.servingConfig = servingConfig + c.googleclouddiscoveryenginev1betarecommendrequest = googleclouddiscoveryenginev1betarecommendrequest + 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 *ProjectsLocationsCollectionsDataStoresServingConfigsRecommendCall) Fields(s ...googleapi.Field) *ProjectsLocationsCollectionsDataStoresServingConfigsRecommendCall { + 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 *ProjectsLocationsCollectionsDataStoresServingConfigsRecommendCall) Context(ctx context.Context) *ProjectsLocationsCollectionsDataStoresServingConfigsRecommendCall { + 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 *ProjectsLocationsCollectionsDataStoresServingConfigsRecommendCall) Header() http.Header { + if c.header_ == nil { + c.header_ = make(http.Header) + } + return c.header_ +} + +func (c *ProjectsLocationsCollectionsDataStoresServingConfigsRecommendCall) 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.googleclouddiscoveryenginev1betarecommendrequest) + 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, "v1beta/{+servingConfig}:recommend") + 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{ + "servingConfig": c.servingConfig, + }) + return gensupport.SendRequest(c.ctx_, c.s.client, req) +} + +// Do executes the "discoveryengine.projects.locations.collections.dataStores.servingConfigs.recommend" call. +// Exactly one of *GoogleCloudDiscoveryengineV1betaRecommendResponse or +// error will be non-nil. Any non-2xx status code is an error. Response +// headers are in either +// *GoogleCloudDiscoveryengineV1betaRecommendResponse.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 *ProjectsLocationsCollectionsDataStoresServingConfigsRecommendCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDiscoveryengineV1betaRecommendResponse, 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 := &GoogleCloudDiscoveryengineV1betaRecommendResponse{ + 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": "Makes a recommendation, which requires a contextual user event.", + // "flatPath": "v1beta/projects/{projectsId}/locations/{locationsId}/collections/{collectionsId}/dataStores/{dataStoresId}/servingConfigs/{servingConfigsId}:recommend", + // "httpMethod": "POST", + // "id": "discoveryengine.projects.locations.collections.dataStores.servingConfigs.recommend", + // "parameterOrder": [ + // "servingConfig" + // ], + // "parameters": { + // "servingConfig": { + // "description": "Required. Full resource name of the format: projects/*/locations/global/collections/*/dataStores/*/servingConfigs/* Before you can request recommendations from your model, you must create at least one serving config for it.", + // "location": "path", + // "pattern": "^projects/[^/]+/locations/[^/]+/collections/[^/]+/dataStores/[^/]+/servingConfigs/[^/]+$", + // "required": true, + // "type": "string" + // } + // }, + // "path": "v1beta/{+servingConfig}:recommend", + // "request": { + // "$ref": "GoogleCloudDiscoveryengineV1betaRecommendRequest" + // }, + // "response": { + // "$ref": "GoogleCloudDiscoveryengineV1betaRecommendResponse" + // }, + // "scopes": [ + // "https://www.googleapis.com/auth/cloud-platform" + // ] + // } + +} + +// method id "discoveryengine.projects.locations.collections.dataStores.userEvents.collect": + +type ProjectsLocationsCollectionsDataStoresUserEventsCollectCall struct { + s *Service + parent string + urlParams_ gensupport.URLParams + ifNoneMatch_ string + ctx_ context.Context + header_ http.Header +} + +// Collect: Writes a single user event from the browser. This uses a GET +// request to due to browser restriction of POST-ing to a 3rd party +// domain. This method is used only by the Discovery Engine API +// JavaScript pixel and Google Tag Manager. Users should not call this +// method directly. +// +// - parent: The parent DataStore resource name, such as +// `projects/{project}/locations/{location}/collections/{collection}/da +// taStores/{data_store}`. +func (r *ProjectsLocationsCollectionsDataStoresUserEventsService) Collect(parent string) *ProjectsLocationsCollectionsDataStoresUserEventsCollectCall { + c := &ProjectsLocationsCollectionsDataStoresUserEventsCollectCall{s: r.s, urlParams_: make(gensupport.URLParams)} + c.parent = parent + return c +} + +// Ets sets the optional parameter "ets": The event timestamp in +// milliseconds. This prevents browser caching of otherwise identical +// get requests. The name is abbreviated to reduce the payload bytes. +func (c *ProjectsLocationsCollectionsDataStoresUserEventsCollectCall) Ets(ets int64) *ProjectsLocationsCollectionsDataStoresUserEventsCollectCall { + c.urlParams_.Set("ets", fmt.Sprint(ets)) + return c +} + +// Uri sets the optional parameter "uri": The URL including +// cgi-parameters but excluding the hash fragment with a length limit of +// 5,000 characters. This is often more useful than the referer URL, +// because many browsers only send the domain for 3rd party requests. +func (c *ProjectsLocationsCollectionsDataStoresUserEventsCollectCall) Uri(uri string) *ProjectsLocationsCollectionsDataStoresUserEventsCollectCall { + c.urlParams_.Set("uri", uri) + return c +} + +// UserEvent sets the optional parameter "userEvent": Required. URL +// encoded UserEvent proto with a length limit of 2,000,000 characters. +func (c *ProjectsLocationsCollectionsDataStoresUserEventsCollectCall) UserEvent(userEvent string) *ProjectsLocationsCollectionsDataStoresUserEventsCollectCall { + c.urlParams_.Set("userEvent", userEvent) + 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 *ProjectsLocationsCollectionsDataStoresUserEventsCollectCall) Fields(s ...googleapi.Field) *ProjectsLocationsCollectionsDataStoresUserEventsCollectCall { + 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 *ProjectsLocationsCollectionsDataStoresUserEventsCollectCall) IfNoneMatch(entityTag string) *ProjectsLocationsCollectionsDataStoresUserEventsCollectCall { + 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 *ProjectsLocationsCollectionsDataStoresUserEventsCollectCall) Context(ctx context.Context) *ProjectsLocationsCollectionsDataStoresUserEventsCollectCall { + 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 *ProjectsLocationsCollectionsDataStoresUserEventsCollectCall) Header() http.Header { + if c.header_ == nil { + c.header_ = make(http.Header) + } + return c.header_ +} + +func (c *ProjectsLocationsCollectionsDataStoresUserEventsCollectCall) 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, "v1beta/{+parent}/userEvents:collect") + 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{ + "parent": c.parent, + }) + return gensupport.SendRequest(c.ctx_, c.s.client, req) +} + +// Do executes the "discoveryengine.projects.locations.collections.dataStores.userEvents.collect" call. +// Exactly one of *GoogleApiHttpBody or error will be non-nil. Any +// non-2xx status code is an error. Response headers are in either +// *GoogleApiHttpBody.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 *ProjectsLocationsCollectionsDataStoresUserEventsCollectCall) Do(opts ...googleapi.CallOption) (*GoogleApiHttpBody, 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 := &GoogleApiHttpBody{ + 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": "Writes a single user event from the browser. This uses a GET request to due to browser restriction of POST-ing to a 3rd party domain. This method is used only by the Discovery Engine API JavaScript pixel and Google Tag Manager. Users should not call this method directly.", + // "flatPath": "v1beta/projects/{projectsId}/locations/{locationsId}/collections/{collectionsId}/dataStores/{dataStoresId}/userEvents:collect", + // "httpMethod": "GET", + // "id": "discoveryengine.projects.locations.collections.dataStores.userEvents.collect", + // "parameterOrder": [ + // "parent" + // ], + // "parameters": { + // "ets": { + // "description": "The event timestamp in milliseconds. This prevents browser caching of otherwise identical get requests. The name is abbreviated to reduce the payload bytes.", + // "format": "int64", + // "location": "query", + // "type": "string" + // }, + // "parent": { + // "description": "Required. The parent DataStore resource name, such as `projects/{project}/locations/{location}/collections/{collection}/dataStores/{data_store}`.", + // "location": "path", + // "pattern": "^projects/[^/]+/locations/[^/]+/collections/[^/]+/dataStores/[^/]+$", + // "required": true, + // "type": "string" + // }, + // "uri": { + // "description": "The URL including cgi-parameters but excluding the hash fragment with a length limit of 5,000 characters. This is often more useful than the referer URL, because many browsers only send the domain for 3rd party requests.", + // "location": "query", + // "type": "string" + // }, + // "userEvent": { + // "description": "Required. URL encoded UserEvent proto with a length limit of 2,000,000 characters.", + // "location": "query", + // "type": "string" + // } + // }, + // "path": "v1beta/{+parent}/userEvents:collect", + // "response": { + // "$ref": "GoogleApiHttpBody" + // }, + // "scopes": [ + // "https://www.googleapis.com/auth/cloud-platform" + // ] + // } + +} + +// method id "discoveryengine.projects.locations.collections.dataStores.userEvents.import": + +type ProjectsLocationsCollectionsDataStoresUserEventsImportCall struct { + s *Service + parent string + googleclouddiscoveryenginev1betaimportusereventsrequest *GoogleCloudDiscoveryengineV1betaImportUserEventsRequest + urlParams_ gensupport.URLParams + ctx_ context.Context + header_ http.Header +} + +// Import: Bulk import of User events. Request processing might be +// synchronous. Events that already exist are skipped. Use this method +// for backfilling historical user events. Operation.response is of type +// ImportResponse. Note that it is possible for a subset of the items to +// be successfully inserted. Operation.metadata is of type +// ImportMetadata. +// +// - parent: Parent DataStore resource name, of the form +// `projects/{project}/locations/{location}/collections/{collection}/da +// taStores/{data_store}`. +func (r *ProjectsLocationsCollectionsDataStoresUserEventsService) Import(parent string, googleclouddiscoveryenginev1betaimportusereventsrequest *GoogleCloudDiscoveryengineV1betaImportUserEventsRequest) *ProjectsLocationsCollectionsDataStoresUserEventsImportCall { + c := &ProjectsLocationsCollectionsDataStoresUserEventsImportCall{s: r.s, urlParams_: make(gensupport.URLParams)} + c.parent = parent + c.googleclouddiscoveryenginev1betaimportusereventsrequest = googleclouddiscoveryenginev1betaimportusereventsrequest + 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 *ProjectsLocationsCollectionsDataStoresUserEventsImportCall) Fields(s ...googleapi.Field) *ProjectsLocationsCollectionsDataStoresUserEventsImportCall { + 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 *ProjectsLocationsCollectionsDataStoresUserEventsImportCall) Context(ctx context.Context) *ProjectsLocationsCollectionsDataStoresUserEventsImportCall { + 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 *ProjectsLocationsCollectionsDataStoresUserEventsImportCall) Header() http.Header { + if c.header_ == nil { + c.header_ = make(http.Header) + } + return c.header_ +} + +func (c *ProjectsLocationsCollectionsDataStoresUserEventsImportCall) 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.googleclouddiscoveryenginev1betaimportusereventsrequest) + 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, "v1beta/{+parent}/userEvents:import") + 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{ + "parent": c.parent, + }) + return gensupport.SendRequest(c.ctx_, c.s.client, req) +} + +// Do executes the "discoveryengine.projects.locations.collections.dataStores.userEvents.import" 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 *ProjectsLocationsCollectionsDataStoresUserEventsImportCall) 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": "Bulk import of User events. Request processing might be synchronous. Events that already exist are skipped. Use this method for backfilling historical user events. Operation.response is of type ImportResponse. Note that it is possible for a subset of the items to be successfully inserted. Operation.metadata is of type ImportMetadata.", + // "flatPath": "v1beta/projects/{projectsId}/locations/{locationsId}/collections/{collectionsId}/dataStores/{dataStoresId}/userEvents:import", + // "httpMethod": "POST", + // "id": "discoveryengine.projects.locations.collections.dataStores.userEvents.import", + // "parameterOrder": [ + // "parent" + // ], + // "parameters": { + // "parent": { + // "description": "Required. Parent DataStore resource name, of the form `projects/{project}/locations/{location}/collections/{collection}/dataStores/{data_store}`", + // "location": "path", + // "pattern": "^projects/[^/]+/locations/[^/]+/collections/[^/]+/dataStores/[^/]+$", + // "required": true, + // "type": "string" + // } + // }, + // "path": "v1beta/{+parent}/userEvents:import", + // "request": { + // "$ref": "GoogleCloudDiscoveryengineV1betaImportUserEventsRequest" + // }, + // "response": { + // "$ref": "GoogleLongrunningOperation" + // }, + // "scopes": [ + // "https://www.googleapis.com/auth/cloud-platform" + // ] + // } + +} + +// method id "discoveryengine.projects.locations.collections.dataStores.userEvents.write": + +type ProjectsLocationsCollectionsDataStoresUserEventsWriteCall struct { + s *Service + parent string + googleclouddiscoveryenginev1betauserevent *GoogleCloudDiscoveryengineV1betaUserEvent + urlParams_ gensupport.URLParams + ctx_ context.Context + header_ http.Header +} + +// Write: Writes a single user event. +// +// - parent: The parent DataStore resource name, such as +// `projects/{project}/locations/{location}/collections/{collection}/da +// taStores/{data_store}`. +func (r *ProjectsLocationsCollectionsDataStoresUserEventsService) Write(parent string, googleclouddiscoveryenginev1betauserevent *GoogleCloudDiscoveryengineV1betaUserEvent) *ProjectsLocationsCollectionsDataStoresUserEventsWriteCall { + c := &ProjectsLocationsCollectionsDataStoresUserEventsWriteCall{s: r.s, urlParams_: make(gensupport.URLParams)} + c.parent = parent + c.googleclouddiscoveryenginev1betauserevent = googleclouddiscoveryenginev1betauserevent + 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 *ProjectsLocationsCollectionsDataStoresUserEventsWriteCall) Fields(s ...googleapi.Field) *ProjectsLocationsCollectionsDataStoresUserEventsWriteCall { + 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 *ProjectsLocationsCollectionsDataStoresUserEventsWriteCall) Context(ctx context.Context) *ProjectsLocationsCollectionsDataStoresUserEventsWriteCall { + 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 *ProjectsLocationsCollectionsDataStoresUserEventsWriteCall) Header() http.Header { + if c.header_ == nil { + c.header_ = make(http.Header) + } + return c.header_ +} + +func (c *ProjectsLocationsCollectionsDataStoresUserEventsWriteCall) 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.googleclouddiscoveryenginev1betauserevent) + 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, "v1beta/{+parent}/userEvents:write") + 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{ + "parent": c.parent, + }) + return gensupport.SendRequest(c.ctx_, c.s.client, req) +} + +// Do executes the "discoveryengine.projects.locations.collections.dataStores.userEvents.write" call. +// Exactly one of *GoogleCloudDiscoveryengineV1betaUserEvent or error +// will be non-nil. Any non-2xx status code is an error. Response +// headers are in either +// *GoogleCloudDiscoveryengineV1betaUserEvent.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 *ProjectsLocationsCollectionsDataStoresUserEventsWriteCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDiscoveryengineV1betaUserEvent, 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 := &GoogleCloudDiscoveryengineV1betaUserEvent{ + 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": "Writes a single user event.", + // "flatPath": "v1beta/projects/{projectsId}/locations/{locationsId}/collections/{collectionsId}/dataStores/{dataStoresId}/userEvents:write", + // "httpMethod": "POST", + // "id": "discoveryengine.projects.locations.collections.dataStores.userEvents.write", + // "parameterOrder": [ + // "parent" + // ], + // "parameters": { + // "parent": { + // "description": "Required. The parent DataStore resource name, such as `projects/{project}/locations/{location}/collections/{collection}/dataStores/{data_store}`.", + // "location": "path", + // "pattern": "^projects/[^/]+/locations/[^/]+/collections/[^/]+/dataStores/[^/]+$", + // "required": true, + // "type": "string" + // } + // }, + // "path": "v1beta/{+parent}/userEvents:write", + // "request": { + // "$ref": "GoogleCloudDiscoveryengineV1betaUserEvent" + // }, + // "response": { + // "$ref": "GoogleCloudDiscoveryengineV1betaUserEvent" + // }, + // "scopes": [ + // "https://www.googleapis.com/auth/cloud-platform" + // ] + // } + +} + +// method id "discoveryengine.projects.locations.collections.operations.get": + +type ProjectsLocationsCollectionsOperationsGetCall 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 *ProjectsLocationsCollectionsOperationsService) Get(name string) *ProjectsLocationsCollectionsOperationsGetCall { + c := &ProjectsLocationsCollectionsOperationsGetCall{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 *ProjectsLocationsCollectionsOperationsGetCall) Fields(s ...googleapi.Field) *ProjectsLocationsCollectionsOperationsGetCall { + 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 *ProjectsLocationsCollectionsOperationsGetCall) IfNoneMatch(entityTag string) *ProjectsLocationsCollectionsOperationsGetCall { + 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 *ProjectsLocationsCollectionsOperationsGetCall) Context(ctx context.Context) *ProjectsLocationsCollectionsOperationsGetCall { + 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 *ProjectsLocationsCollectionsDataStoresUserEventsWriteCall) Header() http.Header { +func (c *ProjectsLocationsCollectionsOperationsGetCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) } return c.header_ } -func (c *ProjectsLocationsCollectionsDataStoresUserEventsWriteCall) doRequest(alt string) (*http.Response, error) { +func (c *ProjectsLocationsCollectionsOperationsGetCall) 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 - body, err := googleapi.WithoutDataWrapper.JSONReader(c.googleclouddiscoveryenginev1betauserevent) + c.urlParams_.Set("alt", alt) + c.urlParams_.Set("prettyPrint", "false") + urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta/{+name}") + urls += "?" + c.urlParams_.Encode() + req, err := http.NewRequest("GET", urls, body) if err != nil { return nil, err } - reqHeaders.Set("Content-Type", "application/json") + 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 "discoveryengine.projects.locations.collections.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 *ProjectsLocationsCollectionsOperationsGetCall) 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": "v1beta/projects/{projectsId}/locations/{locationsId}/collections/{collectionsId}/operations/{operationsId}", + // "httpMethod": "GET", + // "id": "discoveryengine.projects.locations.collections.operations.get", + // "parameterOrder": [ + // "name" + // ], + // "parameters": { + // "name": { + // "description": "The name of the operation resource.", + // "location": "path", + // "pattern": "^projects/[^/]+/locations/[^/]+/collections/[^/]+/operations/[^/]+$", + // "required": true, + // "type": "string" + // } + // }, + // "path": "v1beta/{+name}", + // "response": { + // "$ref": "GoogleLongrunningOperation" + // }, + // "scopes": [ + // "https://www.googleapis.com/auth/cloud-platform" + // ] + // } + +} + +// method id "discoveryengine.projects.locations.collections.operations.list": + +type ProjectsLocationsCollectionsOperationsListCall 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 *ProjectsLocationsCollectionsOperationsService) List(name string) *ProjectsLocationsCollectionsOperationsListCall { + c := &ProjectsLocationsCollectionsOperationsListCall{s: r.s, urlParams_: make(gensupport.URLParams)} + c.name = name + return c +} + +// Filter sets the optional parameter "filter": The standard list +// filter. +func (c *ProjectsLocationsCollectionsOperationsListCall) Filter(filter string) *ProjectsLocationsCollectionsOperationsListCall { + c.urlParams_.Set("filter", filter) + return c +} + +// PageSize sets the optional parameter "pageSize": The standard list +// page size. +func (c *ProjectsLocationsCollectionsOperationsListCall) PageSize(pageSize int64) *ProjectsLocationsCollectionsOperationsListCall { + c.urlParams_.Set("pageSize", fmt.Sprint(pageSize)) + return c +} + +// PageToken sets the optional parameter "pageToken": The standard list +// page token. +func (c *ProjectsLocationsCollectionsOperationsListCall) PageToken(pageToken string) *ProjectsLocationsCollectionsOperationsListCall { + 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 *ProjectsLocationsCollectionsOperationsListCall) Fields(s ...googleapi.Field) *ProjectsLocationsCollectionsOperationsListCall { + 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 *ProjectsLocationsCollectionsOperationsListCall) IfNoneMatch(entityTag string) *ProjectsLocationsCollectionsOperationsListCall { + 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 *ProjectsLocationsCollectionsOperationsListCall) Context(ctx context.Context) *ProjectsLocationsCollectionsOperationsListCall { + 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 *ProjectsLocationsCollectionsOperationsListCall) Header() http.Header { + if c.header_ == nil { + c.header_ = make(http.Header) + } + return c.header_ +} + +func (c *ProjectsLocationsCollectionsOperationsListCall) 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, "v1beta/{+parent}/userEvents:write") + urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta/{+name}/operations") urls += "?" + c.urlParams_.Encode() - req, err := http.NewRequest("POST", urls, body) + req, err := http.NewRequest("GET", urls, body) if err != nil { return nil, err } req.Header = reqHeaders googleapi.Expand(req.URL, map[string]string{ - "parent": c.parent, + "name": c.name, }) return gensupport.SendRequest(c.ctx_, c.s.client, req) } -// Do executes the "discoveryengine.projects.locations.collections.dataStores.userEvents.write" call. -// Exactly one of *GoogleCloudDiscoveryengineV1betaUserEvent or error -// will be non-nil. Any non-2xx status code is an error. Response -// headers are in either -// *GoogleCloudDiscoveryengineV1betaUserEvent.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 *ProjectsLocationsCollectionsDataStoresUserEventsWriteCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDiscoveryengineV1betaUserEvent, error) { +// Do executes the "discoveryengine.projects.locations.collections.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 *ProjectsLocationsCollectionsOperationsListCall) Do(opts ...googleapi.CallOption) (*GoogleLongrunningListOperationsResponse, error) { gensupport.SetOptions(c.urlParams_, opts...) res, err := c.doRequest("json") if res != nil && res.StatusCode == http.StatusNotModified { @@ -3946,7 +5659,7 @@ func (c *ProjectsLocationsCollectionsDataStoresUserEventsWriteCall) Do(opts ...g if err := googleapi.CheckResponse(res); err != nil { return nil, gensupport.WrapError(err) } - ret := &GoogleCloudDiscoveryengineV1betaUserEvent{ + ret := &GoogleLongrunningListOperationsResponse{ ServerResponse: googleapi.ServerResponse{ Header: res.Header, HTTPStatusCode: res.StatusCode, @@ -3958,28 +5671,41 @@ func (c *ProjectsLocationsCollectionsDataStoresUserEventsWriteCall) Do(opts ...g } return ret, nil // { - // "description": "Writes a single user event.", - // "flatPath": "v1beta/projects/{projectsId}/locations/{locationsId}/collections/{collectionsId}/dataStores/{dataStoresId}/userEvents:write", - // "httpMethod": "POST", - // "id": "discoveryengine.projects.locations.collections.dataStores.userEvents.write", + // "description": "Lists operations that match the specified filter in the request. If the server doesn't support this method, it returns `UNIMPLEMENTED`.", + // "flatPath": "v1beta/projects/{projectsId}/locations/{locationsId}/collections/{collectionsId}/operations", + // "httpMethod": "GET", + // "id": "discoveryengine.projects.locations.collections.operations.list", // "parameterOrder": [ - // "parent" + // "name" // ], // "parameters": { - // "parent": { - // "description": "Required. The parent DataStore resource name, such as `projects/{project}/locations/{location}/collections/{collection}/dataStores/{data_store}`.", + // "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/[^/]+/collections/[^/]+/dataStores/[^/]+$", + // "pattern": "^projects/[^/]+/locations/[^/]+/collections/[^/]+$", // "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": "v1beta/{+parent}/userEvents:write", - // "request": { - // "$ref": "GoogleCloudDiscoveryengineV1betaUserEvent" - // }, + // "path": "v1beta/{+name}/operations", // "response": { - // "$ref": "GoogleCloudDiscoveryengineV1betaUserEvent" + // "$ref": "GoogleLongrunningListOperationsResponse" // }, // "scopes": [ // "https://www.googleapis.com/auth/cloud-platform" @@ -3988,6 +5714,27 @@ func (c *ProjectsLocationsCollectionsDataStoresUserEventsWriteCall) Do(opts ...g } +// 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 *ProjectsLocationsCollectionsOperationsListCall) 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 "discoveryengine.projects.locations.dataStores.branches.documents.create": type ProjectsLocationsDataStoresBranchesDocumentsCreateCall struct { @@ -5119,14 +6866,7 @@ type ProjectsLocationsDataStoresBranchesOperationsListCall struct { // List: Lists operations that match the specified filter in the // request. If the server doesn't support this method, it returns -// `UNIMPLEMENTED`. NOTE: the `name` binding allows API services to -// override the binding to use different resource name schemes, such as -// `users/*/operations`. To override the binding, API services can add a -// binding such as "/v1/{name=users/*}/operations" to their service -// configuration. For backwards compatibility, the default name includes -// the operations collection id, however overriding users must ensure -// the name binding is the parent resource, without the operations -// collection id. +// `UNIMPLEMENTED`. // // - name: The name of the operation's parent resource. func (r *ProjectsLocationsDataStoresBranchesOperationsService) List(name string) *ProjectsLocationsDataStoresBranchesOperationsListCall { @@ -5256,7 +6996,7 @@ func (c *ProjectsLocationsDataStoresBranchesOperationsListCall) Do(opts ...googl } 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`. NOTE: the `name` binding allows API services to override the binding to use different resource name schemes, such as `users/*/operations`. To override the binding, API services can add a binding such as `\"/v1/{name=users/*}/operations\"` to their service configuration. For backwards compatibility, the default name includes the operations collection id, however overriding users must ensure the name binding is the parent resource, without the operations collection id.", + // "description": "Lists operations that match the specified filter in the request. If the server doesn't support this method, it returns `UNIMPLEMENTED`.", // "flatPath": "v1beta/projects/{projectsId}/locations/{locationsId}/dataStores/{dataStoresId}/branches/{branchesId}/operations", // "httpMethod": "GET", // "id": "discoveryengine.projects.locations.dataStores.branches.operations.list", @@ -5481,14 +7221,7 @@ type ProjectsLocationsDataStoresModelsOperationsListCall struct { // List: Lists operations that match the specified filter in the // request. If the server doesn't support this method, it returns -// `UNIMPLEMENTED`. NOTE: the `name` binding allows API services to -// override the binding to use different resource name schemes, such as -// `users/*/operations`. To override the binding, API services can add a -// binding such as "/v1/{name=users/*}/operations" to their service -// configuration. For backwards compatibility, the default name includes -// the operations collection id, however overriding users must ensure -// the name binding is the parent resource, without the operations -// collection id. +// `UNIMPLEMENTED`. // // - name: The name of the operation's parent resource. func (r *ProjectsLocationsDataStoresModelsOperationsService) List(name string) *ProjectsLocationsDataStoresModelsOperationsListCall { @@ -5618,7 +7351,7 @@ func (c *ProjectsLocationsDataStoresModelsOperationsListCall) Do(opts ...googlea } 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`. NOTE: the `name` binding allows API services to override the binding to use different resource name schemes, such as `users/*/operations`. To override the binding, API services can add a binding such as `\"/v1/{name=users/*}/operations\"` to their service configuration. For backwards compatibility, the default name includes the operations collection id, however overriding users must ensure the name binding is the parent resource, without the operations collection id.", + // "description": "Lists operations that match the specified filter in the request. If the server doesn't support this method, it returns `UNIMPLEMENTED`.", // "flatPath": "v1beta/projects/{projectsId}/locations/{locationsId}/dataStores/{dataStoresId}/models/{modelsId}/operations", // "httpMethod": "GET", // "id": "discoveryengine.projects.locations.dataStores.models.operations.list", @@ -5843,14 +7576,7 @@ type ProjectsLocationsDataStoresOperationsListCall struct { // List: Lists operations that match the specified filter in the // request. If the server doesn't support this method, it returns -// `UNIMPLEMENTED`. NOTE: the `name` binding allows API services to -// override the binding to use different resource name schemes, such as -// `users/*/operations`. To override the binding, API services can add a -// binding such as "/v1/{name=users/*}/operations" to their service -// configuration. For backwards compatibility, the default name includes -// the operations collection id, however overriding users must ensure -// the name binding is the parent resource, without the operations -// collection id. +// `UNIMPLEMENTED`. // // - name: The name of the operation's parent resource. func (r *ProjectsLocationsDataStoresOperationsService) List(name string) *ProjectsLocationsDataStoresOperationsListCall { @@ -5980,7 +7706,7 @@ func (c *ProjectsLocationsDataStoresOperationsListCall) Do(opts ...googleapi.Cal } 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`. NOTE: the `name` binding allows API services to override the binding to use different resource name schemes, such as `users/*/operations`. To override the binding, API services can add a binding such as `\"/v1/{name=users/*}/operations\"` to their service configuration. For backwards compatibility, the default name includes the operations collection id, however overriding users must ensure the name binding is the parent resource, without the operations collection id.", + // "description": "Lists operations that match the specified filter in the request. If the server doesn't support this method, it returns `UNIMPLEMENTED`.", // "flatPath": "v1beta/projects/{projectsId}/locations/{locationsId}/dataStores/{dataStoresId}/operations", // "httpMethod": "GET", // "id": "discoveryengine.projects.locations.dataStores.operations.list", @@ -6840,14 +8566,7 @@ type ProjectsLocationsOperationsListCall struct { // List: Lists operations that match the specified filter in the // request. If the server doesn't support this method, it returns -// `UNIMPLEMENTED`. NOTE: the `name` binding allows API services to -// override the binding to use different resource name schemes, such as -// `users/*/operations`. To override the binding, API services can add a -// binding such as "/v1/{name=users/*}/operations" to their service -// configuration. For backwards compatibility, the default name includes -// the operations collection id, however overriding users must ensure -// the name binding is the parent resource, without the operations -// collection id. +// `UNIMPLEMENTED`. // // - name: The name of the operation's parent resource. func (r *ProjectsLocationsOperationsService) List(name string) *ProjectsLocationsOperationsListCall { @@ -6977,7 +8696,7 @@ func (c *ProjectsLocationsOperationsListCall) Do(opts ...googleapi.CallOption) ( } 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`. NOTE: the `name` binding allows API services to override the binding to use different resource name schemes, such as `users/*/operations`. To override the binding, API services can add a binding such as `\"/v1/{name=users/*}/operations\"` to their service configuration. For backwards compatibility, the default name includes the operations collection id, however overriding users must ensure the name binding is the parent resource, without the operations collection id.", + // "description": "Lists operations that match the specified filter in the request. If the server doesn't support this method, it returns `UNIMPLEMENTED`.", // "flatPath": "v1beta/projects/{projectsId}/locations/{locationsId}/operations", // "httpMethod": "GET", // "id": "discoveryengine.projects.locations.operations.list", @@ -7202,14 +8921,7 @@ type ProjectsOperationsListCall struct { // List: Lists operations that match the specified filter in the // request. If the server doesn't support this method, it returns -// `UNIMPLEMENTED`. NOTE: the `name` binding allows API services to -// override the binding to use different resource name schemes, such as -// `users/*/operations`. To override the binding, API services can add a -// binding such as "/v1/{name=users/*}/operations" to their service -// configuration. For backwards compatibility, the default name includes -// the operations collection id, however overriding users must ensure -// the name binding is the parent resource, without the operations -// collection id. +// `UNIMPLEMENTED`. // // - name: The name of the operation's parent resource. func (r *ProjectsOperationsService) List(name string) *ProjectsOperationsListCall { @@ -7339,7 +9051,7 @@ func (c *ProjectsOperationsListCall) Do(opts ...googleapi.CallOption) (*GoogleLo } 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`. NOTE: the `name` binding allows API services to override the binding to use different resource name schemes, such as `users/*/operations`. To override the binding, API services can add a binding such as `\"/v1/{name=users/*}/operations\"` to their service configuration. For backwards compatibility, the default name includes the operations collection id, however overriding users must ensure the name binding is the parent resource, without the operations collection id.", + // "description": "Lists operations that match the specified filter in the request. If the server doesn't support this method, it returns `UNIMPLEMENTED`.", // "flatPath": "v1beta/projects/{projectsId}/operations", // "httpMethod": "GET", // "id": "discoveryengine.projects.operations.list", diff --git a/firebasehosting/v1/firebasehosting-api.json b/firebasehosting/v1/firebasehosting-api.json index 4745b686f2d..d433b0c3cd1 100644 --- a/firebasehosting/v1/firebasehosting-api.json +++ b/firebasehosting/v1/firebasehosting-api.json @@ -146,7 +146,7 @@ } }, "list": { - "description": "Lists operations that match the specified filter in the request. If the server doesn't support this method, it returns `UNIMPLEMENTED`. NOTE: the `name` binding allows API services to override the binding to use different resource name schemes, such as `users/*/operations`. To override the binding, API services can add a binding such as `\"/v1/{name=users/*}/operations\"` to their service configuration. For backwards compatibility, the default name includes the operations collection id, however overriding users must ensure the name binding is the parent resource, without the operations collection id.", + "description": "Lists operations that match the specified filter in the request. If the server doesn't support this method, it returns `UNIMPLEMENTED`.", "flatPath": "v1/operations", "httpMethod": "GET", "id": "firebasehosting.operations.list", @@ -186,7 +186,7 @@ } } }, - "revision": "20220322", + "revision": "20230304", "rootUrl": "https://firebasehosting.googleapis.com/", "schemas": { "CancelOperationRequest": { diff --git a/firebasehosting/v1/firebasehosting-gen.go b/firebasehosting/v1/firebasehosting-gen.go index 11c7e933f81..d9267ccb16b 100644 --- a/firebasehosting/v1/firebasehosting-gen.go +++ b/firebasehosting/v1/firebasehosting-gen.go @@ -582,14 +582,7 @@ type OperationsListCall struct { // List: Lists operations that match the specified filter in the // request. If the server doesn't support this method, it returns -// `UNIMPLEMENTED`. NOTE: the `name` binding allows API services to -// override the binding to use different resource name schemes, such as -// `users/*/operations`. To override the binding, API services can add a -// binding such as "/v1/{name=users/*}/operations" to their service -// configuration. For backwards compatibility, the default name includes -// the operations collection id, however overriding users must ensure -// the name binding is the parent resource, without the operations -// collection id. +// `UNIMPLEMENTED`. // // - name: The name of the operation's parent resource. func (r *OperationsService) List(name string) *OperationsListCall { @@ -718,7 +711,7 @@ func (c *OperationsListCall) Do(opts ...googleapi.CallOption) (*ListOperationsRe } 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`. NOTE: the `name` binding allows API services to override the binding to use different resource name schemes, such as `users/*/operations`. To override the binding, API services can add a binding such as `\"/v1/{name=users/*}/operations\"` to their service configuration. For backwards compatibility, the default name includes the operations collection id, however overriding users must ensure the name binding is the parent resource, without the operations collection id.", + // "description": "Lists operations that match the specified filter in the request. If the server doesn't support this method, it returns `UNIMPLEMENTED`.", // "flatPath": "v1/operations", // "httpMethod": "GET", // "id": "firebasehosting.operations.list", diff --git a/firestore/v1/firestore-api.json b/firestore/v1/firestore-api.json index d0c69d9c3c6..297c7525b92 100644 --- a/firestore/v1/firestore-api.json +++ b/firestore/v1/firestore-api.json @@ -122,7 +122,7 @@ ], "parameters": { "databaseId": { - "description": "Required. The ID to use for the database, which will become the final component of the database's resource name. This value should be 4-63 characters. Valid characters are /a-z-/ with first character a letter and the last a letter or a number. Must not be UUID-like /[0-9a-f]{8}(-[0-9a-f]{4}){3}-[0-9a-f]{12}/. \"(default)\" database id is also valid.", + "description": "Required. The ID to use for the database, which will become the final component of the database's resource name. The value must be set to \"(default)\".", "location": "query", "type": "string" }, @@ -165,11 +165,6 @@ "location": "query", "type": "string" }, - "freeId": { - "description": "If set, will free the database_id associated with this database. uid will be used as the resource id to identify this deleted database.", - "location": "query", - "type": "boolean" - }, "name": { "description": "Required. A name of the form `projects/{project_id}/databases/{database_id}`", "location": "path", @@ -997,7 +992,7 @@ ] }, "listen": { - "description": "Listens to changes. This method is only available via the gRPC API (not REST).", + "description": "Listens to changes. This method is only available via gRPC or WebChannel (not REST).", "flatPath": "v1/projects/{projectsId}/databases/{databasesId}/documents:listen", "httpMethod": "POST", "id": "firestore.projects.databases.documents.listen", @@ -1194,7 +1189,7 @@ ] }, "write": { - "description": "Streams batches of document updates and deletes, in order. This method is only available via the gRPC API (not REST).", + "description": "Streams batches of document updates and deletes, in order. This method is only available via gRPC or WebChannel (not REST).", "flatPath": "v1/projects/{projectsId}/databases/{databasesId}/documents:write", "httpMethod": "POST", "id": "firestore.projects.databases.documents.write", @@ -1428,7 +1423,7 @@ } } }, - "revision": "20230214", + "revision": "20230228", "rootUrl": "https://firestore.googleapis.com/", "schemas": { "Aggregation": { @@ -1664,11 +1659,13 @@ "description": "The operator for combining multiple filters.", "enum": [ "OPERATOR_UNSPECIFIED", - "AND" + "AND", + "OR" ], "enumDescriptions": [ "Unspecified. This value must not be used.", - "Documents are required to satisfy all of the combined filters." + "Documents are required to satisfy all of the combined filters.", + "Documents are required to satisfy at least one of the combined filters." ], "type": "string" } @@ -3118,7 +3115,7 @@ "id": "RunAggregationQueryResponse", "properties": { "readTime": { - "description": "The time at which the aggregate value is valid for.", + "description": "The time at which the aggregate result was computed. This is always monotonically increasing; in this case, the previous AggregationResult in the result stream are guaranteed not to have changed between their `read_time` and this one. If the query returns no results, a response with `read_time` and no `result` will be sent, and this represents the time at which the query was run.", "format": "google-datetime", "type": "string" }, @@ -3268,7 +3265,7 @@ }, "select": { "$ref": "Projection", - "description": "The projection to return." + "description": "Optional sub-set of the fields to return. This acts as a DocumentMask over the documents returned from a query. When not set, assumes that the caller wants all fields returned." }, "startAt": { "$ref": "Cursor", diff --git a/firestore/v1/firestore-gen.go b/firestore/v1/firestore-gen.go index 4b67d16c15c..5412bae99b4 100644 --- a/firestore/v1/firestore-gen.go +++ b/firestore/v1/firestore-gen.go @@ -693,6 +693,8 @@ type CompositeFilter struct { // "OPERATOR_UNSPECIFIED" - Unspecified. This value must not be used. // "AND" - Documents are required to satisfy all of the combined // filters. + // "OR" - Documents are required to satisfy at least one of the + // combined filters. Op string `json:"op,omitempty"` // ForceSendFields is a list of field names (e.g. "Filters") to @@ -3216,7 +3218,12 @@ func (s *RunAggregationQueryRequest) MarshalJSON() ([]byte, error) { // RunAggregationQueryResponse: The response for // Firestore.RunAggregationQuery. type RunAggregationQueryResponse struct { - // ReadTime: The time at which the aggregate value is valid for. + // ReadTime: The time at which the aggregate result was computed. This + // is always monotonically increasing; in this case, the previous + // AggregationResult in the result stream are guaranteed not to have + // changed between their `read_time` and this one. If the query returns + // no results, a response with `read_time` and no `result` will be sent, + // and this represents the time at which the query was run. ReadTime string `json:"readTime,omitempty"` // Result: A single aggregation result. Not present when reporting @@ -3469,7 +3476,9 @@ type StructuredQuery struct { // ASC, __name__ ASC` OrderBy []*Order `json:"orderBy,omitempty"` - // Select: The projection to return. + // Select: Optional sub-set of the fields to return. This acts as a + // DocumentMask over the documents returned from a query. When not set, + // assumes that the caller wants all fields returned. Select *Projection `json:"select,omitempty"` // StartAt: A potential prefix of a position in the result set to start @@ -4005,11 +4014,7 @@ func (r *ProjectsDatabasesService) Create(parent string, googlefirestoreadminv1d // DatabaseId sets the optional parameter "databaseId": Required. The ID // to use for the database, which will become the final component of the -// database's resource name. This value should be 4-63 characters. Valid -// characters are /a-z-/ with first character a letter and the last a -// letter or a number. Must not be UUID-like -// /[0-9a-f]{8}(-[0-9a-f]{4}){3}-[0-9a-f]{12}/. "(default)" database id -// is also valid. +// database's resource name. The value must be set to "(default)". func (c *ProjectsDatabasesCreateCall) DatabaseId(databaseId string) *ProjectsDatabasesCreateCall { c.urlParams_.Set("databaseId", databaseId) return c @@ -4115,7 +4120,7 @@ func (c *ProjectsDatabasesCreateCall) Do(opts ...googleapi.CallOption) (*GoogleL // ], // "parameters": { // "databaseId": { - // "description": "Required. The ID to use for the database, which will become the final component of the database's resource name. This value should be 4-63 characters. Valid characters are /a-z-/ with first character a letter and the last a letter or a number. Must not be UUID-like /[0-9a-f]{8}(-[0-9a-f]{4}){3}-[0-9a-f]{12}/. \"(default)\" database id is also valid.", + // "description": "Required. The ID to use for the database, which will become the final component of the database's resource name. The value must be set to \"(default)\".", // "location": "query", // "type": "string" // }, @@ -4179,14 +4184,6 @@ func (c *ProjectsDatabasesDeleteCall) Etag(etag string) *ProjectsDatabasesDelete return c } -// FreeId sets the optional parameter "freeId": If set, will free the -// database_id associated with this database. uid will be used as the -// resource id to identify this deleted database. -func (c *ProjectsDatabasesDeleteCall) FreeId(freeId bool) *ProjectsDatabasesDeleteCall { - c.urlParams_.Set("freeId", fmt.Sprint(freeId)) - return c -} - // ValidateOnly sets the optional parameter "validateOnly": If set, // validate the request and preview the response, but do not actually // delete the database. @@ -4299,11 +4296,6 @@ func (c *ProjectsDatabasesDeleteCall) Do(opts ...googleapi.CallOption) (*GoogleL // "location": "query", // "type": "string" // }, - // "freeId": { - // "description": "If set, will free the database_id associated with this database. uid will be used as the resource id to identify this deleted database.", - // "location": "query", - // "type": "boolean" - // }, // "name": { // "description": "Required. A name of the form `projects/{project_id}/databases/{database_id}`", // "location": "path", @@ -8158,8 +8150,8 @@ type ProjectsDatabasesDocumentsListenCall struct { header_ http.Header } -// Listen: Listens to changes. This method is only available via the -// gRPC API (not REST). +// Listen: Listens to changes. This method is only available via gRPC or +// WebChannel (not REST). // // - database: The database name. In the format: // `projects/{project_id}/databases/{database_id}`. @@ -8261,7 +8253,7 @@ func (c *ProjectsDatabasesDocumentsListenCall) Do(opts ...googleapi.CallOption) } return ret, nil // { - // "description": "Listens to changes. This method is only available via the gRPC API (not REST).", + // "description": "Listens to changes. This method is only available via gRPC or WebChannel (not REST).", // "flatPath": "v1/projects/{projectsId}/databases/{databasesId}/documents:listen", // "httpMethod": "POST", // "id": "firestore.projects.databases.documents.listen", @@ -9122,7 +9114,7 @@ type ProjectsDatabasesDocumentsWriteCall struct { } // Write: Streams batches of document updates and deletes, in order. -// This method is only available via the gRPC API (not REST). +// This method is only available via gRPC or WebChannel (not REST). // // - database: The database name. In the format: // `projects/{project_id}/databases/{database_id}`. This is only @@ -9225,7 +9217,7 @@ func (c *ProjectsDatabasesDocumentsWriteCall) Do(opts ...googleapi.CallOption) ( } return ret, nil // { - // "description": "Streams batches of document updates and deletes, in order. This method is only available via the gRPC API (not REST).", + // "description": "Streams batches of document updates and deletes, in order. This method is only available via gRPC or WebChannel (not REST).", // "flatPath": "v1/projects/{projectsId}/databases/{databasesId}/documents:write", // "httpMethod": "POST", // "id": "firestore.projects.databases.documents.write", diff --git a/firestore/v1beta1/firestore-api.json b/firestore/v1beta1/firestore-api.json index 14257013c51..5c85fd26d1d 100644 --- a/firestore/v1beta1/firestore-api.json +++ b/firestore/v1beta1/firestore-api.json @@ -592,7 +592,7 @@ ] }, "listen": { - "description": "Listens to changes. This method is only available via the gRPC API (not REST).", + "description": "Listens to changes. This method is only available via gRPC or WebChannel (not REST).", "flatPath": "v1beta1/projects/{projectsId}/databases/{databasesId}/documents:listen", "httpMethod": "POST", "id": "firestore.projects.databases.documents.listen", @@ -789,7 +789,7 @@ ] }, "write": { - "description": "Streams batches of document updates and deletes, in order. This method is only available via the gRPC API (not REST).", + "description": "Streams batches of document updates and deletes, in order. This method is only available via gRPC or WebChannel (not REST).", "flatPath": "v1beta1/projects/{projectsId}/databases/{databasesId}/documents:write", "httpMethod": "POST", "id": "firestore.projects.databases.documents.write", @@ -950,7 +950,7 @@ } } }, - "revision": "20230214", + "revision": "20230228", "rootUrl": "https://firestore.googleapis.com/", "schemas": { "Aggregation": { @@ -1186,11 +1186,13 @@ "description": "The operator for combining multiple filters.", "enum": [ "OPERATOR_UNSPECIFIED", - "AND" + "AND", + "OR" ], "enumDescriptions": [ "Unspecified. This value must not be used.", - "Documents are required to satisfy all of the combined filters." + "Documents are required to satisfy all of the combined filters.", + "Documents are required to satisfy at least one of the combined filters." ], "type": "string" } @@ -2194,7 +2196,7 @@ "id": "RunAggregationQueryResponse", "properties": { "readTime": { - "description": "The time at which the aggregate value is valid for.", + "description": "The time at which the aggregate result was computed. This is always monotonically increasing; in this case, the previous AggregationResult in the result stream are guaranteed not to have changed between their `read_time` and this one. If the query returns no results, a response with `read_time` and no `result` will be sent, and this represents the time at which the query was run.", "format": "google-datetime", "type": "string" }, @@ -2344,7 +2346,7 @@ }, "select": { "$ref": "Projection", - "description": "The projection to return." + "description": "Optional sub-set of the fields to return. This acts as a DocumentMask over the documents returned from a query. When not set, assumes that the caller wants all fields returned." }, "startAt": { "$ref": "Cursor", diff --git a/firestore/v1beta1/firestore-gen.go b/firestore/v1beta1/firestore-gen.go index 441184fb583..6d0dc4c9684 100644 --- a/firestore/v1beta1/firestore-gen.go +++ b/firestore/v1beta1/firestore-gen.go @@ -645,6 +645,8 @@ type CompositeFilter struct { // "OPERATOR_UNSPECIFIED" - Unspecified. This value must not be used. // "AND" - Documents are required to satisfy all of the combined // filters. + // "OR" - Documents are required to satisfy at least one of the + // combined filters. Op string `json:"op,omitempty"` // ForceSendFields is a list of field names (e.g. "Filters") to @@ -2482,7 +2484,12 @@ func (s *RunAggregationQueryRequest) MarshalJSON() ([]byte, error) { // RunAggregationQueryResponse: The response for // Firestore.RunAggregationQuery. type RunAggregationQueryResponse struct { - // ReadTime: The time at which the aggregate value is valid for. + // ReadTime: The time at which the aggregate result was computed. This + // is always monotonically increasing; in this case, the previous + // AggregationResult in the result stream are guaranteed not to have + // changed between their `read_time` and this one. If the query returns + // no results, a response with `read_time` and no `result` will be sent, + // and this represents the time at which the query was run. ReadTime string `json:"readTime,omitempty"` // Result: A single aggregation result. Not present when reporting @@ -2735,7 +2742,9 @@ type StructuredQuery struct { // ASC, __name__ ASC` OrderBy []*Order `json:"orderBy,omitempty"` - // Select: The projection to return. + // Select: Optional sub-set of the fields to return. This acts as a + // DocumentMask over the documents returned from a query. When not set, + // assumes that the caller wants all fields returned. Select *Projection `json:"select,omitempty"` // StartAt: A potential prefix of a position in the result set to start @@ -5425,8 +5434,8 @@ type ProjectsDatabasesDocumentsListenCall struct { header_ http.Header } -// Listen: Listens to changes. This method is only available via the -// gRPC API (not REST). +// Listen: Listens to changes. This method is only available via gRPC or +// WebChannel (not REST). // // - database: The database name. In the format: // `projects/{project_id}/databases/{database_id}`. @@ -5528,7 +5537,7 @@ func (c *ProjectsDatabasesDocumentsListenCall) Do(opts ...googleapi.CallOption) } return ret, nil // { - // "description": "Listens to changes. This method is only available via the gRPC API (not REST).", + // "description": "Listens to changes. This method is only available via gRPC or WebChannel (not REST).", // "flatPath": "v1beta1/projects/{projectsId}/databases/{databasesId}/documents:listen", // "httpMethod": "POST", // "id": "firestore.projects.databases.documents.listen", @@ -6389,7 +6398,7 @@ type ProjectsDatabasesDocumentsWriteCall struct { } // Write: Streams batches of document updates and deletes, in order. -// This method is only available via the gRPC API (not REST). +// This method is only available via gRPC or WebChannel (not REST). // // - database: The database name. In the format: // `projects/{project_id}/databases/{database_id}`. This is only @@ -6492,7 +6501,7 @@ func (c *ProjectsDatabasesDocumentsWriteCall) Do(opts ...googleapi.CallOption) ( } return ret, nil // { - // "description": "Streams batches of document updates and deletes, in order. This method is only available via the gRPC API (not REST).", + // "description": "Streams batches of document updates and deletes, in order. This method is only available via gRPC or WebChannel (not REST).", // "flatPath": "v1beta1/projects/{projectsId}/databases/{databasesId}/documents:write", // "httpMethod": "POST", // "id": "firestore.projects.databases.documents.write", diff --git a/metastore/v1/metastore-api.json b/metastore/v1/metastore-api.json index c89b065e156..96f7adfcfa5 100644 --- a/metastore/v1/metastore-api.json +++ b/metastore/v1/metastore-api.json @@ -1255,7 +1255,7 @@ } } }, - "revision": "20230131", + "revision": "20230228", "rootUrl": "https://metastore.googleapis.com/", "schemas": { "AuditConfig": { @@ -1306,6 +1306,29 @@ }, "type": "object" }, + "AuxiliaryVersionConfig": { + "description": "Configuration information for the auxiliary service versions.", + "id": "AuxiliaryVersionConfig", + "properties": { + "configOverrides": { + "additionalProperties": { + "type": "string" + }, + "description": "A mapping of Hive metastore configuration key-value pairs to apply to the auxiliary Hive metastore (configured in hive-site.xml) in addition to the primary version's overrides. If keys are present in both the auxiliary version's overrides and the primary version's overrides, the value from the auxiliary version's overrides takes precedence.", + "type": "object" + }, + "networkConfig": { + "$ref": "NetworkConfig", + "description": "Output only. The network configuration contains the endpoint URI(s) of the auxiliary Hive metastore service.", + "readOnly": true + }, + "version": { + "description": "The Hive metastore version of the auxiliary service. It must be less than the primary Hive metastore service's version.", + "type": "string" + } + }, + "type": "object" + }, "BackendMetastore": { "description": "Represents a backend metastore for the federation.", "id": "BackendMetastore", @@ -1625,6 +1648,13 @@ "description": "Specifies configuration information specific to running Hive metastore software as the metastore service.", "id": "HiveMetastoreConfig", "properties": { + "auxiliaryVersions": { + "additionalProperties": { + "$ref": "AuxiliaryVersionConfig" + }, + "description": "A mapping of Hive metastore version to the auxiliary version configuration. When specified, a secondary Hive metastore service is created along with the primary service. All auxiliary versions must be less than the service's primary version. The key is the auxiliary service name and it must match the regular expression a-z?. This means that the first character must be a lowercase letter, and all the following characters must be hyphens, lowercase letters, or digits, except the last character, which cannot be a hyphen.", + "type": "object" + }, "configOverrides": { "additionalProperties": { "type": "string" @@ -2250,6 +2280,38 @@ }, "type": "object" }, + "ScalingConfig": { + "description": "Represents the scaling configuration of a metastore service.", + "id": "ScalingConfig", + "properties": { + "instanceSize": { + "description": "An enum of readable instance sizes, with each instance size mapping to a float value (e.g. InstanceSize.EXTRA_SMALL = scaling_factor(0.1))", + "enum": [ + "INSTANCE_SIZE_UNSPECIFIED", + "EXTRA_SMALL", + "SMALL", + "MEDIUM", + "LARGE", + "EXTRA_LARGE" + ], + "enumDescriptions": [ + "Unspecified instance size", + "Extra small instance size, maps to a scaling factor of 0.1.", + "Small instance size, maps to a scaling factor of 0.5.", + "Medium instance size, maps to a scaling factor of 1.0.", + "Large instance size, maps to a scaling factor of 3.0.", + "Extra large instance size, maps to a scaling factor of 6.0." + ], + "type": "string" + }, + "scalingFactor": { + "description": "Scaling factor, increments of 0.1 for values less than 1.0, and increments of 1.0 for values greater than 1.0.", + "format": "float", + "type": "number" + } + }, + "type": "object" + }, "Secret": { "description": "A securely stored value.", "id": "Secret", @@ -2350,6 +2412,10 @@ ], "type": "string" }, + "scalingConfig": { + "$ref": "ScalingConfig", + "description": "Scaling configuration of the metastore service." + }, "state": { "description": "Output only. The current state of the metastore service.", "enum": [ diff --git a/metastore/v1/metastore-gen.go b/metastore/v1/metastore-gen.go index 3e80e860846..9d04daffd51 100644 --- a/metastore/v1/metastore-gen.go +++ b/metastore/v1/metastore-gen.go @@ -315,6 +315,49 @@ func (s *AuditLogConfig) MarshalJSON() ([]byte, error) { return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } +// AuxiliaryVersionConfig: Configuration information for the auxiliary +// service versions. +type AuxiliaryVersionConfig struct { + // ConfigOverrides: A mapping of Hive metastore configuration key-value + // pairs to apply to the auxiliary Hive metastore (configured in + // hive-site.xml) in addition to the primary version's overrides. If + // keys are present in both the auxiliary version's overrides and the + // primary version's overrides, the value from the auxiliary version's + // overrides takes precedence. + ConfigOverrides map[string]string `json:"configOverrides,omitempty"` + + // NetworkConfig: Output only. The network configuration contains the + // endpoint URI(s) of the auxiliary Hive metastore service. + NetworkConfig *NetworkConfig `json:"networkConfig,omitempty"` + + // Version: The Hive metastore version of the auxiliary service. It must + // be less than the primary Hive metastore service's version. + Version string `json:"version,omitempty"` + + // ForceSendFields is a list of field names (e.g. "ConfigOverrides") 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. "ConfigOverrides") 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 *AuxiliaryVersionConfig) MarshalJSON() ([]byte, error) { + type NoMethod AuxiliaryVersionConfig + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + // BackendMetastore: Represents a backend metastore for the federation. type BackendMetastore struct { // MetastoreType: The type of the backend metastore. @@ -837,6 +880,17 @@ func (s *Federation) MarshalJSON() ([]byte, error) { // HiveMetastoreConfig: Specifies configuration information specific to // running Hive metastore software as the metastore service. type HiveMetastoreConfig struct { + // AuxiliaryVersions: A mapping of Hive metastore version to the + // auxiliary version configuration. When specified, a secondary Hive + // metastore service is created along with the primary service. All + // auxiliary versions must be less than the service's primary version. + // The key is the auxiliary service name and it must match the regular + // expression a-z?. This means that the first character must be a + // lowercase letter, and all the following characters must be hyphens, + // lowercase letters, or digits, except the last character, which cannot + // be a hyphen. + AuxiliaryVersions map[string]AuxiliaryVersionConfig `json:"auxiliaryVersions,omitempty"` + // ConfigOverrides: A mapping of Hive metastore configuration key-value // pairs to apply to the Hive metastore (configured in hive-site.xml). // The mappings override system defaults (some keys cannot be @@ -855,15 +909,15 @@ type HiveMetastoreConfig struct { // Version: Immutable. The Hive metastore schema version. Version string `json:"version,omitempty"` - // ForceSendFields is a list of field names (e.g. "ConfigOverrides") to - // unconditionally include in API requests. By default, fields with + // ForceSendFields is a list of field names (e.g. "AuxiliaryVersions") + // 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. "ConfigOverrides") to + // NullFields is a list of field names (e.g. "AuxiliaryVersions") 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 @@ -1828,6 +1882,65 @@ func (s *RestoreServiceRequest) MarshalJSON() ([]byte, error) { return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } +// ScalingConfig: Represents the scaling configuration of a metastore +// service. +type ScalingConfig struct { + // InstanceSize: An enum of readable instance sizes, with each instance + // size mapping to a float value (e.g. InstanceSize.EXTRA_SMALL = + // scaling_factor(0.1)) + // + // Possible values: + // "INSTANCE_SIZE_UNSPECIFIED" - Unspecified instance size + // "EXTRA_SMALL" - Extra small instance size, maps to a scaling factor + // of 0.1. + // "SMALL" - Small instance size, maps to a scaling factor of 0.5. + // "MEDIUM" - Medium instance size, maps to a scaling factor of 1.0. + // "LARGE" - Large instance size, maps to a scaling factor of 3.0. + // "EXTRA_LARGE" - Extra large instance size, maps to a scaling factor + // of 6.0. + InstanceSize string `json:"instanceSize,omitempty"` + + // ScalingFactor: Scaling factor, increments of 0.1 for values less than + // 1.0, and increments of 1.0 for values greater than 1.0. + ScalingFactor float64 `json:"scalingFactor,omitempty"` + + // ForceSendFields is a list of field names (e.g. "InstanceSize") 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. "InstanceSize") 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 *ScalingConfig) MarshalJSON() ([]byte, error) { + type NoMethod ScalingConfig + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + +func (s *ScalingConfig) UnmarshalJSON(data []byte) error { + type NoMethod ScalingConfig + var s1 struct { + ScalingFactor gensupport.JSONFloat64 `json:"scalingFactor"` + *NoMethod + } + s1.NoMethod = (*NoMethod)(s) + if err := json.Unmarshal(data, &s1); err != nil { + return err + } + s.ScalingFactor = float64(s1.ScalingFactor) + return nil +} + // Secret: A securely stored value. type Secret struct { // CloudSecret: The relative resource name of a Secret Manager secret @@ -1937,6 +2050,9 @@ type Service struct { // considered stable and have been validated for production use. ReleaseChannel string `json:"releaseChannel,omitempty"` + // ScalingConfig: Scaling configuration of the metastore service. + ScalingConfig *ScalingConfig `json:"scalingConfig,omitempty"` + // State: Output only. The current state of the metastore service. // // Possible values: diff --git a/metastore/v1alpha/metastore-api.json b/metastore/v1alpha/metastore-api.json index cc8393401ba..ad2e640309f 100644 --- a/metastore/v1alpha/metastore-api.json +++ b/metastore/v1alpha/metastore-api.json @@ -1579,7 +1579,7 @@ } } }, - "revision": "20230131", + "revision": "20230228", "rootUrl": "https://metastore.googleapis.com/", "schemas": { "AlterMetadataResourceLocationRequest": { @@ -2761,6 +2761,38 @@ }, "type": "object" }, + "ScalingConfig": { + "description": "Represents the scaling configuration of a metastore service.", + "id": "ScalingConfig", + "properties": { + "instanceSize": { + "description": "An enum of readable instance sizes, with each instance size mapping to a float value (e.g. InstanceSize.EXTRA_SMALL = scaling_factor(0.1))", + "enum": [ + "INSTANCE_SIZE_UNSPECIFIED", + "EXTRA_SMALL", + "SMALL", + "MEDIUM", + "LARGE", + "EXTRA_LARGE" + ], + "enumDescriptions": [ + "Unspecified instance size", + "Extra small instance size, maps to a scaling factor of 0.1.", + "Small instance size, maps to a scaling factor of 0.5.", + "Medium instance size, maps to a scaling factor of 1.0.", + "Large instance size, maps to a scaling factor of 3.0.", + "Extra large instance size, maps to a scaling factor of 6.0." + ], + "type": "string" + }, + "scalingFactor": { + "description": "Scaling factor, increments of 0.1 for values less than 1.0, and increments of 1.0 for values greater than 1.0.", + "format": "float", + "type": "number" + } + }, + "type": "object" + }, "Secret": { "description": "A securely stored value.", "id": "Secret", @@ -2865,6 +2897,10 @@ ], "type": "string" }, + "scalingConfig": { + "$ref": "ScalingConfig", + "description": "Scaling configuration of the metastore service." + }, "state": { "description": "Output only. The current state of the metastore service.", "enum": [ diff --git a/metastore/v1alpha/metastore-gen.go b/metastore/v1alpha/metastore-gen.go index 2a93e05a3ca..dbefd80dd73 100644 --- a/metastore/v1alpha/metastore-gen.go +++ b/metastore/v1alpha/metastore-gen.go @@ -2251,6 +2251,65 @@ func (s *RestoreServiceRequest) MarshalJSON() ([]byte, error) { return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } +// ScalingConfig: Represents the scaling configuration of a metastore +// service. +type ScalingConfig struct { + // InstanceSize: An enum of readable instance sizes, with each instance + // size mapping to a float value (e.g. InstanceSize.EXTRA_SMALL = + // scaling_factor(0.1)) + // + // Possible values: + // "INSTANCE_SIZE_UNSPECIFIED" - Unspecified instance size + // "EXTRA_SMALL" - Extra small instance size, maps to a scaling factor + // of 0.1. + // "SMALL" - Small instance size, maps to a scaling factor of 0.5. + // "MEDIUM" - Medium instance size, maps to a scaling factor of 1.0. + // "LARGE" - Large instance size, maps to a scaling factor of 3.0. + // "EXTRA_LARGE" - Extra large instance size, maps to a scaling factor + // of 6.0. + InstanceSize string `json:"instanceSize,omitempty"` + + // ScalingFactor: Scaling factor, increments of 0.1 for values less than + // 1.0, and increments of 1.0 for values greater than 1.0. + ScalingFactor float64 `json:"scalingFactor,omitempty"` + + // ForceSendFields is a list of field names (e.g. "InstanceSize") 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. "InstanceSize") 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 *ScalingConfig) MarshalJSON() ([]byte, error) { + type NoMethod ScalingConfig + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + +func (s *ScalingConfig) UnmarshalJSON(data []byte) error { + type NoMethod ScalingConfig + var s1 struct { + ScalingFactor gensupport.JSONFloat64 `json:"scalingFactor"` + *NoMethod + } + s1.NoMethod = (*NoMethod)(s) + if err := json.Unmarshal(data, &s1); err != nil { + return err + } + s.ScalingFactor = float64(s1.ScalingFactor) + return nil +} + // Secret: A securely stored value. type Secret struct { // CloudSecret: The relative resource name of a Secret Manager secret @@ -2364,6 +2423,9 @@ type Service struct { // considered stable and have been validated for production use. ReleaseChannel string `json:"releaseChannel,omitempty"` + // ScalingConfig: Scaling configuration of the metastore service. + ScalingConfig *ScalingConfig `json:"scalingConfig,omitempty"` + // State: Output only. The current state of the metastore service. // // Possible values: diff --git a/metastore/v1beta/metastore-api.json b/metastore/v1beta/metastore-api.json index 328be36e177..a124c89f5ce 100644 --- a/metastore/v1beta/metastore-api.json +++ b/metastore/v1beta/metastore-api.json @@ -1579,7 +1579,7 @@ } } }, - "revision": "20230131", + "revision": "20230228", "rootUrl": "https://metastore.googleapis.com/", "schemas": { "AlterMetadataResourceLocationRequest": { @@ -2761,6 +2761,38 @@ }, "type": "object" }, + "ScalingConfig": { + "description": "Represents the scaling configuration of a metastore service.", + "id": "ScalingConfig", + "properties": { + "instanceSize": { + "description": "An enum of readable instance sizes, with each instance size mapping to a float value (e.g. InstanceSize.EXTRA_SMALL = scaling_factor(0.1))", + "enum": [ + "INSTANCE_SIZE_UNSPECIFIED", + "EXTRA_SMALL", + "SMALL", + "MEDIUM", + "LARGE", + "EXTRA_LARGE" + ], + "enumDescriptions": [ + "Unspecified instance size", + "Extra small instance size, maps to a scaling factor of 0.1.", + "Small instance size, maps to a scaling factor of 0.5.", + "Medium instance size, maps to a scaling factor of 1.0.", + "Large instance size, maps to a scaling factor of 3.0.", + "Extra large instance size, maps to a scaling factor of 6.0." + ], + "type": "string" + }, + "scalingFactor": { + "description": "Scaling factor, increments of 0.1 for values less than 1.0, and increments of 1.0 for values greater than 1.0.", + "format": "float", + "type": "number" + } + }, + "type": "object" + }, "Secret": { "description": "A securely stored value.", "id": "Secret", @@ -2865,6 +2897,10 @@ ], "type": "string" }, + "scalingConfig": { + "$ref": "ScalingConfig", + "description": "Scaling configuration of the metastore service." + }, "state": { "description": "Output only. The current state of the metastore service.", "enum": [ diff --git a/metastore/v1beta/metastore-gen.go b/metastore/v1beta/metastore-gen.go index dbc92aa774f..8d25effea28 100644 --- a/metastore/v1beta/metastore-gen.go +++ b/metastore/v1beta/metastore-gen.go @@ -2251,6 +2251,65 @@ func (s *RestoreServiceRequest) MarshalJSON() ([]byte, error) { return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } +// ScalingConfig: Represents the scaling configuration of a metastore +// service. +type ScalingConfig struct { + // InstanceSize: An enum of readable instance sizes, with each instance + // size mapping to a float value (e.g. InstanceSize.EXTRA_SMALL = + // scaling_factor(0.1)) + // + // Possible values: + // "INSTANCE_SIZE_UNSPECIFIED" - Unspecified instance size + // "EXTRA_SMALL" - Extra small instance size, maps to a scaling factor + // of 0.1. + // "SMALL" - Small instance size, maps to a scaling factor of 0.5. + // "MEDIUM" - Medium instance size, maps to a scaling factor of 1.0. + // "LARGE" - Large instance size, maps to a scaling factor of 3.0. + // "EXTRA_LARGE" - Extra large instance size, maps to a scaling factor + // of 6.0. + InstanceSize string `json:"instanceSize,omitempty"` + + // ScalingFactor: Scaling factor, increments of 0.1 for values less than + // 1.0, and increments of 1.0 for values greater than 1.0. + ScalingFactor float64 `json:"scalingFactor,omitempty"` + + // ForceSendFields is a list of field names (e.g. "InstanceSize") 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. "InstanceSize") 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 *ScalingConfig) MarshalJSON() ([]byte, error) { + type NoMethod ScalingConfig + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + +func (s *ScalingConfig) UnmarshalJSON(data []byte) error { + type NoMethod ScalingConfig + var s1 struct { + ScalingFactor gensupport.JSONFloat64 `json:"scalingFactor"` + *NoMethod + } + s1.NoMethod = (*NoMethod)(s) + if err := json.Unmarshal(data, &s1); err != nil { + return err + } + s.ScalingFactor = float64(s1.ScalingFactor) + return nil +} + // Secret: A securely stored value. type Secret struct { // CloudSecret: The relative resource name of a Secret Manager secret @@ -2364,6 +2423,9 @@ type Service struct { // considered stable and have been validated for production use. ReleaseChannel string `json:"releaseChannel,omitempty"` + // ScalingConfig: Scaling configuration of the metastore service. + ScalingConfig *ScalingConfig `json:"scalingConfig,omitempty"` + // State: Output only. The current state of the metastore service. // // Possible values: diff --git a/migrationcenter/v1alpha1/migrationcenter-api.json b/migrationcenter/v1alpha1/migrationcenter-api.json new file mode 100644 index 00000000000..8357c312d1b --- /dev/null +++ b/migrationcenter/v1alpha1/migrationcenter-api.json @@ -0,0 +1,3079 @@ +{ + "auth": { + "oauth2": { + "scopes": { + "https://www.googleapis.com/auth/cloud-platform": { + "description": "See, edit, configure, and delete your Google Cloud data and see the email address for your Google Account." + } + } + } + }, + "basePath": "", + "baseUrl": "https://migrationcenter.googleapis.com/", + "batchPath": "batch", + "canonicalName": "Migration Center API", + "description": "", + "discoveryVersion": "v1", + "documentationLink": "https://cloud.google.com/migration-center", + "fullyEncodeReservedExpansion": true, + "icons": { + "x16": "http://www.google.com/images/icons/product/search-16.gif", + "x32": "http://www.google.com/images/icons/product/search-32.gif" + }, + "id": "migrationcenter:v1alpha1", + "kind": "discovery#restDescription", + "mtlsRootUrl": "https://migrationcenter.mtls.googleapis.com/", + "name": "migrationcenter", + "ownerDomain": "google.com", + "ownerName": "Google", + "parameters": { + "$.xgafv": { + "description": "V1 error format.", + "enum": [ + "1", + "2" + ], + "enumDescriptions": [ + "v1 error format", + "v2 error format" + ], + "location": "query", + "type": "string" + }, + "access_token": { + "description": "OAuth access token.", + "location": "query", + "type": "string" + }, + "alt": { + "default": "json", + "description": "Data format for response.", + "enum": [ + "json", + "media", + "proto" + ], + "enumDescriptions": [ + "Responses with Content-Type of application/json", + "Media download with context-dependent Content-Type", + "Responses with Content-Type of application/x-protobuf" + ], + "location": "query", + "type": "string" + }, + "callback": { + "description": "JSONP", + "location": "query", + "type": "string" + }, + "fields": { + "description": "Selector specifying which fields to include in a partial response.", + "location": "query", + "type": "string" + }, + "key": { + "description": "API key. Your API key identifies your project and provides you with API access, quota, and reports. Required unless you provide an OAuth 2.0 token.", + "location": "query", + "type": "string" + }, + "oauth_token": { + "description": "OAuth 2.0 token for the current user.", + "location": "query", + "type": "string" + }, + "prettyPrint": { + "default": "true", + "description": "Returns response with indentations and line breaks.", + "location": "query", + "type": "boolean" + }, + "quotaUser": { + "description": "Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters.", + "location": "query", + "type": "string" + }, + "uploadType": { + "description": "Legacy upload protocol for media (e.g. \"media\", \"multipart\").", + "location": "query", + "type": "string" + }, + "upload_protocol": { + "description": "Upload protocol for media (e.g. \"raw\", \"multipart\").", + "location": "query", + "type": "string" + } + }, + "protocol": "rest", + "resources": { + "projects": { + "resources": { + "locations": { + "methods": { + "get": { + "description": "Gets information about a location.", + "flatPath": "v1alpha1/projects/{projectsId}/locations/{locationsId}", + "httpMethod": "GET", + "id": "migrationcenter.projects.locations.get", + "parameterOrder": [ + "name" + ], + "parameters": { + "name": { + "description": "Resource name for the location.", + "location": "path", + "pattern": "^projects/[^/]+/locations/[^/]+$", + "required": true, + "type": "string" + } + }, + "path": "v1alpha1/{+name}", + "response": { + "$ref": "Location" + }, + "scopes": [ + "https://www.googleapis.com/auth/cloud-platform" + ] + }, + "list": { + "description": "Lists information about the supported locations for this service.", + "flatPath": "v1alpha1/projects/{projectsId}/locations", + "httpMethod": "GET", + "id": "migrationcenter.projects.locations.list", + "parameterOrder": [ + "name" + ], + "parameters": { + "filter": { + "description": "A filter to narrow down results to a preferred subset. The filtering language accepts strings like `\"displayName=tokyo\"`, and is documented in more detail in [AIP-160](https://google.aip.dev/160).", + "location": "query", + "type": "string" + }, + "name": { + "description": "The resource that owns the locations collection, if applicable.", + "location": "path", + "pattern": "^projects/[^/]+$", + "required": true, + "type": "string" + }, + "pageSize": { + "description": "The maximum number of results to return. If not set, the service selects a default.", + "format": "int32", + "location": "query", + "type": "integer" + }, + "pageToken": { + "description": "A page token received from the `next_page_token` field in the response. Send that page token to receive the subsequent page.", + "location": "query", + "type": "string" + } + }, + "path": "v1alpha1/{+name}/locations", + "response": { + "$ref": "ListLocationsResponse" + }, + "scopes": [ + "https://www.googleapis.com/auth/cloud-platform" + ] + } + }, + "resources": { + "assets": { + "methods": { + "aggregateValues": { + "description": "Aggregates the requested fields based on provided function.", + "flatPath": "v1alpha1/projects/{projectsId}/locations/{locationsId}/assets:aggregateValues", + "httpMethod": "POST", + "id": "migrationcenter.projects.locations.assets.aggregateValues", + "parameterOrder": [ + "parent" + ], + "parameters": { + "parent": { + "description": "Required. Parent value for `AggregateAssetsValuesRequest`.", + "location": "path", + "pattern": "^projects/[^/]+/locations/[^/]+$", + "required": true, + "type": "string" + } + }, + "path": "v1alpha1/{+parent}/assets:aggregateValues", + "request": { + "$ref": "AggregateAssetsValuesRequest" + }, + "response": { + "$ref": "AggregateAssetsValuesResponse" + }, + "scopes": [ + "https://www.googleapis.com/auth/cloud-platform" + ] + }, + "create": { + "description": "Creates a new asset in a given project and location. Deprecated: Use ReportAssetFrames instead.", + "flatPath": "v1alpha1/projects/{projectsId}/locations/{locationsId}/assets", + "httpMethod": "POST", + "id": "migrationcenter.projects.locations.assets.create", + "parameterOrder": [ + "parent" + ], + "parameters": { + "assetId": { + "location": "query", + "type": "string" + }, + "parent": { + "description": "Required. Value for parent.", + "location": "path", + "pattern": "^projects/[^/]+/locations/[^/]+$", + "required": true, + "type": "string" + }, + "requestId": { + "description": "Optional. An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. The server will guarantee that for at least 60 minutes since the first request. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000).", + "location": "query", + "type": "string" + } + }, + "path": "v1alpha1/{+parent}/assets", + "request": { + "$ref": "Asset" + }, + "response": { + "$ref": "Operation" + }, + "scopes": [ + "https://www.googleapis.com/auth/cloud-platform" + ] + }, + "delete": { + "description": "Deletes an asset.", + "flatPath": "v1alpha1/projects/{projectsId}/locations/{locationsId}/assets/{assetsId}", + "httpMethod": "DELETE", + "id": "migrationcenter.projects.locations.assets.delete", + "parameterOrder": [ + "name" + ], + "parameters": { + "name": { + "description": "Required. Name of the resource.", + "location": "path", + "pattern": "^projects/[^/]+/locations/[^/]+/assets/[^/]+$", + "required": true, + "type": "string" + }, + "requestId": { + "description": "Optional. An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. The server will guarantee that for at least 60 minutes after the first request. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000).", + "location": "query", + "type": "string" + } + }, + "path": "v1alpha1/{+name}", + "response": { + "$ref": "Operation" + }, + "scopes": [ + "https://www.googleapis.com/auth/cloud-platform" + ] + }, + "get": { + "description": "Gets the details of an asset.", + "flatPath": "v1alpha1/projects/{projectsId}/locations/{locationsId}/assets/{assetsId}", + "httpMethod": "GET", + "id": "migrationcenter.projects.locations.assets.get", + "parameterOrder": [ + "name" + ], + "parameters": { + "name": { + "description": "Required. Name of the resource.", + "location": "path", + "pattern": "^projects/[^/]+/locations/[^/]+/assets/[^/]+$", + "required": true, + "type": "string" + }, + "view": { + "description": "View of the assets. Defaults to BASIC.", + "enum": [ + "ASSET_VIEW_UNSPECIFIED", + "ASSET_VIEW_BASIC", + "ASSET_VIEW_FULL", + "ASSET_VIEW_STANDARD" + ], + "enumDescriptions": [ + "The asset view is not specified. The API displays the basic view by default.", + "The asset view includes only basic metadata of the asset.", + "The asset view includes all the metadata of an asset.", + "The asset view includes the standard metadata of an asset." + ], + "location": "query", + "type": "string" + } + }, + "path": "v1alpha1/{+name}", + "response": { + "$ref": "Asset" + }, + "scopes": [ + "https://www.googleapis.com/auth/cloud-platform" + ] + }, + "list": { + "description": "Lists all the assets in a given project and location.", + "flatPath": "v1alpha1/projects/{projectsId}/locations/{locationsId}/assets", + "httpMethod": "GET", + "id": "migrationcenter.projects.locations.assets.list", + "parameterOrder": [ + "parent" + ], + "parameters": { + "filter": { + "description": "Filtering results.", + "location": "query", + "type": "string" + }, + "orderBy": { + "description": "Field to sort by. See https://google.aip.dev/132#ordering for more details.", + "location": "query", + "type": "string" + }, + "pageSize": { + "description": "Requested page size. Server may return fewer items than requested. If unspecified, server will pick an appropriate default.", + "format": "int32", + "location": "query", + "type": "integer" + }, + "pageToken": { + "description": "A token identifying a page of results the server should return.", + "location": "query", + "type": "string" + }, + "parent": { + "description": "Required. Parent value for `ListAssetsRequest`.", + "location": "path", + "pattern": "^projects/[^/]+/locations/[^/]+$", + "required": true, + "type": "string" + }, + "view": { + "description": "View of the assets. Defaults to BASIC.", + "enum": [ + "ASSET_VIEW_UNSPECIFIED", + "ASSET_VIEW_BASIC", + "ASSET_VIEW_FULL", + "ASSET_VIEW_STANDARD" + ], + "enumDescriptions": [ + "The asset view is not specified. The API displays the basic view by default.", + "The asset view includes only basic metadata of the asset.", + "The asset view includes all the metadata of an asset.", + "The asset view includes the standard metadata of an asset." + ], + "location": "query", + "type": "string" + } + }, + "path": "v1alpha1/{+parent}/assets", + "response": { + "$ref": "ListAssetsResponse" + }, + "scopes": [ + "https://www.googleapis.com/auth/cloud-platform" + ] + }, + "patch": { + "description": "Updates the parameters of an asset.", + "flatPath": "v1alpha1/projects/{projectsId}/locations/{locationsId}/assets/{assetsId}", + "httpMethod": "PATCH", + "id": "migrationcenter.projects.locations.assets.patch", + "parameterOrder": [ + "name" + ], + "parameters": { + "name": { + "description": "Output only. The full name of the asset.", + "location": "path", + "pattern": "^projects/[^/]+/locations/[^/]+/assets/[^/]+$", + "required": true, + "type": "string" + }, + "requestId": { + "description": "Optional. An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. The server will guarantee that for at least 60 minutes since the first request. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000).", + "location": "query", + "type": "string" + }, + "updateMask": { + "description": "Required. Field mask is used to specify the fields to be overwritten in the `Asset` resource by the update. The values specified in the `update_mask` field are relative to the resource, not the full request. A field will be overwritten if it is in the mask. A single * value in the mask lets you to overwrite all fields.", + "format": "google-fieldmask", + "location": "query", + "type": "string" + } + }, + "path": "v1alpha1/{+name}", + "request": { + "$ref": "Asset" + }, + "response": { + "$ref": "Operation" + }, + "scopes": [ + "https://www.googleapis.com/auth/cloud-platform" + ] + }, + "reportAssetFrames": { + "description": "Reports a set of frames.", + "flatPath": "v1alpha1/projects/{projectsId}/locations/{locationsId}/assets:reportAssetFrames", + "httpMethod": "POST", + "id": "migrationcenter.projects.locations.assets.reportAssetFrames", + "parameterOrder": [ + "parent" + ], + "parameters": { + "parent": { + "description": "Required. Parent of the resource.", + "location": "path", + "pattern": "^projects/[^/]+/locations/[^/]+$", + "required": true, + "type": "string" + }, + "source": { + "description": "Required. Reference to a source.", + "location": "query", + "type": "string" + } + }, + "path": "v1alpha1/{+parent}/assets:reportAssetFrames", + "request": { + "$ref": "Frames" + }, + "response": { + "$ref": "ReportAssetFramesResponse" + }, + "scopes": [ + "https://www.googleapis.com/auth/cloud-platform" + ] + } + } + }, + "importJobs": { + "methods": { + "create": { + "description": "Creates an import job.", + "flatPath": "v1alpha1/projects/{projectsId}/locations/{locationsId}/importJobs", + "httpMethod": "POST", + "id": "migrationcenter.projects.locations.importJobs.create", + "parameterOrder": [ + "parent" + ], + "parameters": { + "importJobId": { + "description": "Required. ID of the import job.", + "location": "query", + "type": "string" + }, + "parent": { + "description": "Required. Value for parent.", + "location": "path", + "pattern": "^projects/[^/]+/locations/[^/]+$", + "required": true, + "type": "string" + }, + "requestId": { + "description": "Optional. An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. The server will guarantee that for at least 60 minutes since the first request. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000).", + "location": "query", + "type": "string" + } + }, + "path": "v1alpha1/{+parent}/importJobs", + "request": { + "$ref": "ImportJob" + }, + "response": { + "$ref": "Operation" + }, + "scopes": [ + "https://www.googleapis.com/auth/cloud-platform" + ] + }, + "delete": { + "description": "Deletes an import job.", + "flatPath": "v1alpha1/projects/{projectsId}/locations/{locationsId}/importJobs/{importJobsId}", + "httpMethod": "DELETE", + "id": "migrationcenter.projects.locations.importJobs.delete", + "parameterOrder": [ + "name" + ], + "parameters": { + "name": { + "description": "Required. Name of the resource.", + "location": "path", + "pattern": "^projects/[^/]+/locations/[^/]+/importJobs/[^/]+$", + "required": true, + "type": "string" + }, + "requestId": { + "description": "Optional. An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. The server will guarantee that for at least 60 minutes after the first request. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000).", + "location": "query", + "type": "string" + } + }, + "path": "v1alpha1/{+name}", + "response": { + "$ref": "Operation" + }, + "scopes": [ + "https://www.googleapis.com/auth/cloud-platform" + ] + }, + "get": { + "description": "Gets the details of an import job.", + "flatPath": "v1alpha1/projects/{projectsId}/locations/{locationsId}/importJobs/{importJobsId}", + "httpMethod": "GET", + "id": "migrationcenter.projects.locations.importJobs.get", + "parameterOrder": [ + "name" + ], + "parameters": { + "name": { + "description": "Required. Name of the resource.", + "location": "path", + "pattern": "^projects/[^/]+/locations/[^/]+/importJobs/[^/]+$", + "required": true, + "type": "string" + }, + "view": { + "description": "Optional. The level of details of the import job. Default value is FULL.", + "enum": [ + "IMPORT_JOB_VIEW_UNSPECIFIED", + "IMPORT_JOB_VIEW_BASIC", + "IMPORT_JOB_VIEW_FULL" + ], + "enumDescriptions": [ + "The import job view is not specified. The API displays the basic view by default.", + "The import job view includes basic metadata of an import job. This view does not include payload information.", + "The import job view includes all metadata of an import job." + ], + "location": "query", + "type": "string" + } + }, + "path": "v1alpha1/{+name}", + "response": { + "$ref": "ImportJob" + }, + "scopes": [ + "https://www.googleapis.com/auth/cloud-platform" + ] + }, + "list": { + "description": "Lists all import jobs.", + "flatPath": "v1alpha1/projects/{projectsId}/locations/{locationsId}/importJobs", + "httpMethod": "GET", + "id": "migrationcenter.projects.locations.importJobs.list", + "parameterOrder": [ + "parent" + ], + "parameters": { + "filter": { + "description": "Filtering results.", + "location": "query", + "type": "string" + }, + "orderBy": { + "description": "Field to sort by. See https://google.aip.dev/132#ordering for more details.", + "location": "query", + "type": "string" + }, + "pageSize": { + "description": "Requested page size. Server may return fewer items than requested. If unspecified, server will pick an appropriate default.", + "format": "int32", + "location": "query", + "type": "integer" + }, + "pageToken": { + "description": "A token identifying a page of results the server should return.", + "location": "query", + "type": "string" + }, + "parent": { + "description": "Required. Parent value for `ListImportJobsRequest`.", + "location": "path", + "pattern": "^projects/[^/]+/locations/[^/]+$", + "required": true, + "type": "string" + }, + "view": { + "description": "Optional. The level of details of each import job. Default value is BASIC.", + "enum": [ + "IMPORT_JOB_VIEW_UNSPECIFIED", + "IMPORT_JOB_VIEW_BASIC", + "IMPORT_JOB_VIEW_FULL" + ], + "enumDescriptions": [ + "The import job view is not specified. The API displays the basic view by default.", + "The import job view includes basic metadata of an import job. This view does not include payload information.", + "The import job view includes all metadata of an import job." + ], + "location": "query", + "type": "string" + } + }, + "path": "v1alpha1/{+parent}/importJobs", + "response": { + "$ref": "ListImportJobsResponse" + }, + "scopes": [ + "https://www.googleapis.com/auth/cloud-platform" + ] + }, + "patch": { + "description": "Updates an import job.", + "flatPath": "v1alpha1/projects/{projectsId}/locations/{locationsId}/importJobs/{importJobsId}", + "httpMethod": "PATCH", + "id": "migrationcenter.projects.locations.importJobs.patch", + "parameterOrder": [ + "name" + ], + "parameters": { + "name": { + "description": "Output only. The full name of the import job.", + "location": "path", + "pattern": "^projects/[^/]+/locations/[^/]+/importJobs/[^/]+$", + "required": true, + "type": "string" + }, + "requestId": { + "description": "Optional. An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. The server will guarantee that for at least 60 minutes since the first request. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000).", + "location": "query", + "type": "string" + }, + "updateMask": { + "description": "Required. Field mask is used to specify the fields to be overwritten in the `Asset` resource by the update. The values specified in the `update_mask` field are relative to the resource, not the full request. A field will be overwritten if it is in the mask. A single * value in the mask lets you to overwrite all fields.", + "format": "google-fieldmask", + "location": "query", + "type": "string" + } + }, + "path": "v1alpha1/{+name}", + "request": { + "$ref": "ImportJob" + }, + "response": { + "$ref": "Operation" + }, + "scopes": [ + "https://www.googleapis.com/auth/cloud-platform" + ] + }, + "run": { + "description": "Runs an import job.", + "flatPath": "v1alpha1/projects/{projectsId}/locations/{locationsId}/importJobs/{importJobsId}:run", + "httpMethod": "POST", + "id": "migrationcenter.projects.locations.importJobs.run", + "parameterOrder": [ + "name" + ], + "parameters": { + "name": { + "description": "Required. The name of the import job to run.", + "location": "path", + "pattern": "^projects/[^/]+/locations/[^/]+/importJobs/[^/]+$", + "required": true, + "type": "string" + } + }, + "path": "v1alpha1/{+name}:run", + "request": { + "$ref": "RunImportJobRequest" + }, + "response": { + "$ref": "Operation" + }, + "scopes": [ + "https://www.googleapis.com/auth/cloud-platform" + ] + }, + "validate": { + "description": "Validates an import job.", + "flatPath": "v1alpha1/projects/{projectsId}/locations/{locationsId}/importJobs/{importJobsId}:validate", + "httpMethod": "POST", + "id": "migrationcenter.projects.locations.importJobs.validate", + "parameterOrder": [ + "name" + ], + "parameters": { + "name": { + "description": "Required. The name of the import job to validate.", + "location": "path", + "pattern": "^projects/[^/]+/locations/[^/]+/importJobs/[^/]+$", + "required": true, + "type": "string" + } + }, + "path": "v1alpha1/{+name}:validate", + "request": { + "$ref": "ValidateImportJobRequest" + }, + "response": { + "$ref": "Operation" + }, + "scopes": [ + "https://www.googleapis.com/auth/cloud-platform" + ] + } + } + }, + "operations": { + "methods": { + "cancel": { + "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": "v1alpha1/projects/{projectsId}/locations/{locationsId}/operations/{operationsId}:cancel", + "httpMethod": "POST", + "id": "migrationcenter.projects.locations.operations.cancel", + "parameterOrder": [ + "name" + ], + "parameters": { + "name": { + "description": "The name of the operation resource to be cancelled.", + "location": "path", + "pattern": "^projects/[^/]+/locations/[^/]+/operations/[^/]+$", + "required": true, + "type": "string" + } + }, + "path": "v1alpha1/{+name}:cancel", + "request": { + "$ref": "CancelOperationRequest" + }, + "response": { + "$ref": "Empty" + }, + "scopes": [ + "https://www.googleapis.com/auth/cloud-platform" + ] + }, + "delete": { + "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": "v1alpha1/projects/{projectsId}/locations/{locationsId}/operations/{operationsId}", + "httpMethod": "DELETE", + "id": "migrationcenter.projects.locations.operations.delete", + "parameterOrder": [ + "name" + ], + "parameters": { + "name": { + "description": "The name of the operation resource to be deleted.", + "location": "path", + "pattern": "^projects/[^/]+/locations/[^/]+/operations/[^/]+$", + "required": true, + "type": "string" + } + }, + "path": "v1alpha1/{+name}", + "response": { + "$ref": "Empty" + }, + "scopes": [ + "https://www.googleapis.com/auth/cloud-platform" + ] + }, + "get": { + "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": "v1alpha1/projects/{projectsId}/locations/{locationsId}/operations/{operationsId}", + "httpMethod": "GET", + "id": "migrationcenter.projects.locations.operations.get", + "parameterOrder": [ + "name" + ], + "parameters": { + "name": { + "description": "The name of the operation resource.", + "location": "path", + "pattern": "^projects/[^/]+/locations/[^/]+/operations/[^/]+$", + "required": true, + "type": "string" + } + }, + "path": "v1alpha1/{+name}", + "response": { + "$ref": "Operation" + }, + "scopes": [ + "https://www.googleapis.com/auth/cloud-platform" + ] + }, + "list": { + "description": "Lists operations that match the specified filter in the request. If the server doesn't support this method, it returns `UNIMPLEMENTED`. NOTE: the `name` binding allows API services to override the binding to use different resource name schemes, such as `users/*/operations`. To override the binding, API services can add a binding such as `\"/v1/{name=users/*}/operations\"` to their service configuration. For backwards compatibility, the default name includes the operations collection id, however overriding users must ensure the name binding is the parent resource, without the operations collection id.", + "flatPath": "v1alpha1/projects/{projectsId}/locations/{locationsId}/operations", + "httpMethod": "GET", + "id": "migrationcenter.projects.locations.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/[^/]+$", + "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": "v1alpha1/{+name}/operations", + "response": { + "$ref": "ListOperationsResponse" + }, + "scopes": [ + "https://www.googleapis.com/auth/cloud-platform" + ] + } + } + }, + "sources": { + "methods": { + "create": { + "description": "Creates a new source in a given project and location.", + "flatPath": "v1alpha1/projects/{projectsId}/locations/{locationsId}/sources", + "httpMethod": "POST", + "id": "migrationcenter.projects.locations.sources.create", + "parameterOrder": [ + "parent" + ], + "parameters": { + "parent": { + "description": "Required. Value for parent.", + "location": "path", + "pattern": "^projects/[^/]+/locations/[^/]+$", + "required": true, + "type": "string" + }, + "requestId": { + "description": "Optional. An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. The server will guarantee that for at least 60 minutes since the first request. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000).", + "location": "query", + "type": "string" + }, + "sourceId": { + "description": "Required. User specified ID for the source. It will become the last component of the source name. The ID must be unique within the project, must conform with RFC-1034, is restricted to lower-cased letters, and has a maximum length of 63 characters. The ID must match the regular expression: `[a-z]([a-z0-9-]{0,61}[a-z0-9])?`.", + "location": "query", + "type": "string" + } + }, + "path": "v1alpha1/{+parent}/sources", + "request": { + "$ref": "Source" + }, + "response": { + "$ref": "Operation" + }, + "scopes": [ + "https://www.googleapis.com/auth/cloud-platform" + ] + }, + "delete": { + "description": "Deletes a source.", + "flatPath": "v1alpha1/projects/{projectsId}/locations/{locationsId}/sources/{sourcesId}", + "httpMethod": "DELETE", + "id": "migrationcenter.projects.locations.sources.delete", + "parameterOrder": [ + "name" + ], + "parameters": { + "name": { + "description": "Required. Name of the resource.", + "location": "path", + "pattern": "^projects/[^/]+/locations/[^/]+/sources/[^/]+$", + "required": true, + "type": "string" + }, + "requestId": { + "description": "Optional. An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. The server will guarantee that for at least 60 minutes after the first request. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000).", + "location": "query", + "type": "string" + } + }, + "path": "v1alpha1/{+name}", + "response": { + "$ref": "Operation" + }, + "scopes": [ + "https://www.googleapis.com/auth/cloud-platform" + ] + }, + "get": { + "description": "Gets the details of a source.", + "flatPath": "v1alpha1/projects/{projectsId}/locations/{locationsId}/sources/{sourcesId}", + "httpMethod": "GET", + "id": "migrationcenter.projects.locations.sources.get", + "parameterOrder": [ + "name" + ], + "parameters": { + "name": { + "description": "Required. Name of the resource.", + "location": "path", + "pattern": "^projects/[^/]+/locations/[^/]+/sources/[^/]+$", + "required": true, + "type": "string" + } + }, + "path": "v1alpha1/{+name}", + "response": { + "$ref": "Source" + }, + "scopes": [ + "https://www.googleapis.com/auth/cloud-platform" + ] + }, + "list": { + "description": "Lists all the sources in a given project and location.", + "flatPath": "v1alpha1/projects/{projectsId}/locations/{locationsId}/sources", + "httpMethod": "GET", + "id": "migrationcenter.projects.locations.sources.list", + "parameterOrder": [ + "parent" + ], + "parameters": { + "filter": { + "description": "Filtering results.", + "location": "query", + "type": "string" + }, + "orderBy": { + "description": "Field to sort by. See https://google.aip.dev/132#ordering for more details.", + "location": "query", + "type": "string" + }, + "pageSize": { + "description": "Requested page size. The server may return fewer items than requested. If unspecified, the server will pick an appropriate default value.", + "format": "int32", + "location": "query", + "type": "integer" + }, + "pageToken": { + "description": "A token identifying a page of results that the server should return.", + "location": "query", + "type": "string" + }, + "parent": { + "description": "Required. Parent value for `ListSourcesRequest`.", + "location": "path", + "pattern": "^projects/[^/]+/locations/[^/]+$", + "required": true, + "type": "string" + } + }, + "path": "v1alpha1/{+parent}/sources", + "response": { + "$ref": "ListSourcesResponse" + }, + "scopes": [ + "https://www.googleapis.com/auth/cloud-platform" + ] + }, + "patch": { + "description": "Updates the parameters of a source.", + "flatPath": "v1alpha1/projects/{projectsId}/locations/{locationsId}/sources/{sourcesId}", + "httpMethod": "PATCH", + "id": "migrationcenter.projects.locations.sources.patch", + "parameterOrder": [ + "name" + ], + "parameters": { + "name": { + "description": "Output only. The full name of the source.", + "location": "path", + "pattern": "^projects/[^/]+/locations/[^/]+/sources/[^/]+$", + "required": true, + "type": "string" + }, + "requestId": { + "description": "Optional. An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. The server will guarantee that for at least 60 minutes since the first request. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000).", + "location": "query", + "type": "string" + }, + "updateMask": { + "description": "Required. Field mask is used to specify the fields to be overwritten in the `Source` resource by the update. The values specified in the `update_mask` field are relative to the resource, not the full request. A field will be overwritten if it is in the mask. A single * value in the mask lets you to overwrite all fields.", + "format": "google-fieldmask", + "location": "query", + "type": "string" + } + }, + "path": "v1alpha1/{+name}", + "request": { + "$ref": "Source" + }, + "response": { + "$ref": "Operation" + }, + "scopes": [ + "https://www.googleapis.com/auth/cloud-platform" + ] + } + } + } + } + } + } + } + }, + "revision": "20230224", + "rootUrl": "https://migrationcenter.googleapis.com/", + "schemas": { + "AggregateAssetsValuesRequest": { + "description": "A request to aggregate one or more values.", + "id": "AggregateAssetsValuesRequest", + "properties": { + "aggregations": { + "description": "Array of aggregations to perform. Up to 25 aggregations can be defined.", + "items": { + "$ref": "Aggregation" + }, + "type": "array" + }, + "filter": { + "description": "The aggregation will be performed on assets that match the provided filter.", + "type": "string" + } + }, + "type": "object" + }, + "AggregateAssetsValuesResponse": { + "description": "A response to a request to aggregated assets values.", + "id": "AggregateAssetsValuesResponse", + "properties": { + "results": { + "description": "The aggregation results.", + "items": { + "$ref": "AggregationResult" + }, + "type": "array" + } + }, + "type": "object" + }, + "Aggregation": { + "description": "Message describing an aggregation. The message includes the aggregation type, parameters, and the field on which to perform the aggregation.", + "id": "Aggregation", + "properties": { + "count": { + "$ref": "AggregationCount", + "description": "Count the number of matching objects." + }, + "field": { + "description": "The name of the field on which to aggregate.", + "type": "string" + }, + "frequency": { + "$ref": "AggregationFrequency", + "description": "Creates a frequency distribution of all field values." + }, + "histogram": { + "$ref": "AggregationHistogram", + "description": "Creates a bucketed histogram of field values." + }, + "sum": { + "$ref": "AggregationSum", + "description": "Sum over a numeric field." + } + }, + "type": "object" + }, + "AggregationCount": { + "description": "Object count.", + "id": "AggregationCount", + "properties": {}, + "type": "object" + }, + "AggregationFrequency": { + "description": "Frequency distribution of all field values.", + "id": "AggregationFrequency", + "properties": {}, + "type": "object" + }, + "AggregationHistogram": { + "description": "Histogram of bucketed assets counts by field value.", + "id": "AggregationHistogram", + "properties": { + "lowerBounds": { + "description": "Lower bounds of buckets. The response will contain `n+1` buckets for `n` bounds. The first bucket will count all assets for which the field value is smaller than the first bound. Subsequent buckets will count assets for which the field value is greater or equal to a lower bound and smaller than the next one. The last bucket will count assets for which the field value is greater or equal to the final lower bound. You can define up to 20 lower bounds.", + "items": { + "format": "double", + "type": "number" + }, + "type": "array" + } + }, + "type": "object" + }, + "AggregationResult": { + "description": "Message describing a result of an aggregation.", + "id": "AggregationResult", + "properties": { + "count": { + "$ref": "AggregationResultCount" + }, + "field": { + "type": "string" + }, + "frequency": { + "$ref": "AggregationResultFrequency" + }, + "histogram": { + "$ref": "AggregationResultHistogram" + }, + "sum": { + "$ref": "AggregationResultSum" + } + }, + "type": "object" + }, + "AggregationResultCount": { + "description": "The result of a count aggregation.", + "id": "AggregationResultCount", + "properties": { + "value": { + "format": "int64", + "type": "string" + } + }, + "type": "object" + }, + "AggregationResultFrequency": { + "description": "The result of a frequency distribution aggregation.", + "id": "AggregationResultFrequency", + "properties": { + "values": { + "additionalProperties": { + "format": "int64", + "type": "string" + }, + "type": "object" + } + }, + "type": "object" + }, + "AggregationResultHistogram": { + "description": "The result of a bucketed histogram aggregation.", + "id": "AggregationResultHistogram", + "properties": { + "buckets": { + "description": "Buckets in the histogram. There will be `n+1` buckets matching `n` lower bounds in the request. The first bucket will be from -infinity to the first bound. Subsequent buckets will be between one bound and the next. The final bucket will be from the final bound to infinity.", + "items": { + "$ref": "AggregationResultHistogramBucket" + }, + "type": "array" + } + }, + "type": "object" + }, + "AggregationResultHistogramBucket": { + "description": "A histogram bucket with a lower and upper bound, and a count of items with a field value between those bounds. The lower bound is inclusive and the upper bound is exclusive. Lower bound may be -infinity and upper bound may be infinity.", + "id": "AggregationResultHistogramBucket", + "properties": { + "count": { + "description": "Count of items in the bucket.", + "format": "int64", + "type": "string" + }, + "lowerBound": { + "description": "Lower bound - inclusive.", + "format": "double", + "type": "number" + }, + "upperBound": { + "description": "Upper bound - exclusive.", + "format": "double", + "type": "number" + } + }, + "type": "object" + }, + "AggregationResultSum": { + "description": "The result of a sum aggregation.", + "id": "AggregationResultSum", + "properties": { + "value": { + "format": "double", + "type": "number" + } + }, + "type": "object" + }, + "AggregationSum": { + "description": "Sum of field values.", + "id": "AggregationSum", + "properties": {}, + "type": "object" + }, + "Asset": { + "description": "An asset represents a resource in your environment. Asset types include virtual machines and databases.", + "id": "Asset", + "properties": { + "attributes": { + "additionalProperties": { + "type": "string" + }, + "description": "Generic asset attributes.", + "type": "object" + }, + "createTime": { + "description": "Output only. The timestamp when the asset was created.", + "format": "google-datetime", + "readOnly": true, + "type": "string" + }, + "labels": { + "additionalProperties": { + "type": "string" + }, + "description": "Labels as key value pairs.", + "type": "object" + }, + "name": { + "description": "Output only. The full name of the asset.", + "readOnly": true, + "type": "string" + }, + "sources": { + "description": "Output only. The list of sources contributing to the asset.", + "items": { + "type": "string" + }, + "readOnly": true, + "type": "array" + }, + "updateTime": { + "description": "Output only. The timestamp when the asset was last updated.", + "format": "google-datetime", + "readOnly": true, + "type": "string" + }, + "virtualMachineDetails": { + "$ref": "VirtualMachineDetails", + "description": "Output only. Asset information specific for virtual machines.", + "readOnly": true + } + }, + "type": "object" + }, + "AssetFrame": { + "description": "Contains data reported from an inventory source on an asset.", + "id": "AssetFrame", + "properties": { + "attributes": { + "additionalProperties": { + "type": "string" + }, + "description": "Generic asset attributes.", + "type": "object" + }, + "labels": { + "additionalProperties": { + "type": "string" + }, + "description": "Labels as key value pairs.", + "type": "object" + }, + "performanceSamples": { + "description": "Asset performance data samples.", + "items": { + "$ref": "PerformanceSample" + }, + "type": "array" + }, + "reportTime": { + "description": "The time the data was reported.", + "format": "google-datetime", + "type": "string" + }, + "traceToken": { + "description": "Optional. Trace token is optionally provided to assist with debugging and traceability.", + "type": "string" + }, + "virtualMachineDetails": { + "$ref": "VirtualMachineDetails", + "description": "Asset information specific for virtual machines." + } + }, + "type": "object" + }, + "BiosDetails": { + "description": "Details about the bios.", + "id": "BiosDetails", + "properties": { + "biosManufacturer": { + "description": "Bios manufacturer.", + "type": "string" + }, + "biosName": { + "description": "Bios name.", + "type": "string" + }, + "biosReleaseDate": { + "description": "Bios release date.", + "type": "string" + }, + "biosVersion": { + "description": "Bios version.", + "type": "string" + }, + "smbiosUuid": { + "description": "SMBios UUID.", + "type": "string" + } + }, + "type": "object" + }, + "CancelOperationRequest": { + "description": "The request message for Operations.CancelOperation.", + "id": "CancelOperationRequest", + "properties": {}, + "type": "object" + }, + "CpuUsageSample": { + "description": "CPU usage sample.", + "id": "CpuUsageSample", + "properties": { + "utilizedPercentage": { + "description": "Percentage of total CPU capacity utilized. Must be in the interval [0, 100]. On most systems can be calculated using 100 - idle percentage.", + "format": "float", + "type": "number" + } + }, + "type": "object" + }, + "Date": { + "description": "Represents a whole or partial calendar date, such as a birthday. The time of day and time zone are either specified elsewhere or are insignificant. The date is relative to the Gregorian Calendar. This can represent one of the following: * A full date, with non-zero year, month, and day values. * A month and day, with a zero year (for example, an anniversary). * A year on its own, with a zero month and a zero day. * A year and month, with a zero day (for example, a credit card expiration date). Related types: * google.type.TimeOfDay * google.type.DateTime * google.protobuf.Timestamp", + "id": "Date", + "properties": { + "day": { + "description": "Day of a month. Must be from 1 to 31 and valid for the year and month, or 0 to specify a year by itself or a year and month where the day isn't significant.", + "format": "int32", + "type": "integer" + }, + "month": { + "description": "Month of a year. Must be from 1 to 12, or 0 to specify a year without a month and day.", + "format": "int32", + "type": "integer" + }, + "year": { + "description": "Year of the date. Must be from 1 to 9999, or 0 to specify a date without a year.", + "format": "int32", + "type": "integer" + } + }, + "type": "object" + }, + "DateTime": { + "description": "Represents civil time (or occasionally physical time). This type can represent a civil time in one of a few possible ways: * When utc_offset is set and time_zone is unset: a civil time on a calendar day with a particular offset from UTC. * When time_zone is set and utc_offset is unset: a civil time on a calendar day in a particular time zone. * When neither time_zone nor utc_offset is set: a civil time on a calendar day in local time. The date is relative to the Proleptic Gregorian Calendar. If year, month, or day are 0, the DateTime is considered not to have a specific year, month, or day respectively. This type may also be used to represent a physical time if all the date and time fields are set and either case of the `time_offset` oneof is set. Consider using `Timestamp` message for physical time instead. If your use case also would like to store the user's timezone, that can be done in another field. This type is more flexible than some applications may want. Make sure to document and validate your application's limitations.", + "id": "DateTime", + "properties": { + "day": { + "description": "Optional. Day of month. Must be from 1 to 31 and valid for the year and month, or 0 if specifying a datetime without a day.", + "format": "int32", + "type": "integer" + }, + "hours": { + "description": "Optional. Hours of day in 24 hour format. Should be from 0 to 23, defaults to 0 (midnight). An API may choose to allow the value \"24:00:00\" for scenarios like business closing time.", + "format": "int32", + "type": "integer" + }, + "minutes": { + "description": "Optional. Minutes of hour of day. Must be from 0 to 59, defaults to 0.", + "format": "int32", + "type": "integer" + }, + "month": { + "description": "Optional. Month of year. Must be from 1 to 12, or 0 if specifying a datetime without a month.", + "format": "int32", + "type": "integer" + }, + "nanos": { + "description": "Optional. Fractions of seconds in nanoseconds. Must be from 0 to 999,999,999, defaults to 0.", + "format": "int32", + "type": "integer" + }, + "seconds": { + "description": "Optional. Seconds of minutes of the time. Must normally be from 0 to 59, defaults to 0. An API may allow the value 60 if it allows leap-seconds.", + "format": "int32", + "type": "integer" + }, + "timeZone": { + "$ref": "TimeZone", + "description": "Time zone." + }, + "utcOffset": { + "description": "UTC offset. Must be whole seconds, between -18 hours and +18 hours. For example, a UTC offset of -4:00 would be represented as { seconds: -14400 }.", + "format": "google-duration", + "type": "string" + }, + "year": { + "description": "Optional. Year of date. Must be from 1 to 9999, or 0 if specifying a datetime without a year.", + "format": "int32", + "type": "integer" + } + }, + "type": "object" + }, + "DiskEntry": { + "description": "Single disk entry.", + "id": "DiskEntry", + "properties": { + "diskLabel": { + "description": "Disk label.", + "type": "string" + }, + "diskLabelType": { + "description": "Disk label type (e.g. BIOS/GPT)", + "type": "string" + }, + "hwAddress": { + "description": "Disk hardware address (e.g. 0:1 for SCSI).", + "type": "string" + }, + "interfaceType": { + "description": "Disks interface type (e.g. SATA/SCSI)", + "type": "string" + }, + "partitions": { + "$ref": "DiskPartitionList", + "description": "Partition layout." + }, + "status": { + "description": "Disk status (e.g. online).", + "type": "string" + }, + "totalCapacityBytes": { + "description": "Disk Capacity (required).", + "format": "int64", + "type": "string" + }, + "totalFreeBytes": { + "description": "Disk Free Space.", + "format": "int64", + "type": "string" + }, + "vmwareConfig": { + "$ref": "VmwareDiskConfig", + "description": "Optional. Optional disk VMware details." + } + }, + "type": "object" + }, + "DiskEntryList": { + "description": "VM disks.", + "id": "DiskEntryList", + "properties": { + "entries": { + "description": "Disk entries.", + "items": { + "$ref": "DiskEntry" + }, + "type": "array" + } + }, + "type": "object" + }, + "DiskPartition": { + "description": "Disk Partition details.", + "id": "DiskPartition", + "properties": { + "capacityBytes": { + "description": "Partition capacity.", + "format": "int64", + "type": "string" + }, + "fileSystem": { + "description": "Partition file system.", + "type": "string" + }, + "freeBytes": { + "description": "Partition free space.", + "format": "int64", + "type": "string" + }, + "mountPoint": { + "description": "Mount pount (Linux/Windows) or drive letter (Windows).", + "type": "string" + }, + "subPartitions": { + "$ref": "DiskPartitionList", + "description": "Sub-partitions." + }, + "type": { + "description": "Partition type (e.g. BIOS boot).", + "type": "string" + }, + "uuid": { + "description": "Partition UUID.", + "type": "string" + } + }, + "type": "object" + }, + "DiskPartitionList": { + "id": "DiskPartitionList", + "properties": { + "entries": { + "description": "Partition entries.", + "items": { + "$ref": "DiskPartition" + }, + "type": "array" + } + }, + "type": "object" + }, + "DiskUsageSample": { + "description": "Disk usage sample. Values are across all disks.", + "id": "DiskUsageSample", + "properties": { + "averageIops": { + "description": "Average IOPS sampled over a short window. Must be non-negative.", + "format": "float", + "type": "number" + } + }, + "type": "object" + }, + "Empty": { + "description": "A generic empty message that you can re-use to avoid defining duplicated empty messages in your APIs. A typical example is to use it as the request or the response type of an API method. For instance: service Foo { rpc Bar(google.protobuf.Empty) returns (google.protobuf.Empty); }", + "id": "Empty", + "properties": {}, + "type": "object" + }, + "ExecutionReport": { + "description": "A resource that reports result of the import job execution.", + "id": "ExecutionReport", + "properties": { + "executionErrors": { + "$ref": "ValidationReport", + "description": "Validation errors encountered during the execution of the import job." + }, + "framesReported": { + "description": "Total number of asset frames reported for the import job.", + "format": "int32", + "type": "integer" + }, + "jobErrors": { + "description": "List of job-level errors. Deprecated, use the job errors under execution_errors instead.", + "items": { + "$ref": "ImportError" + }, + "type": "array" + }, + "totalRowsCount": { + "description": "Total number of rows in the import job.", + "format": "int32", + "type": "integer" + } + }, + "type": "object" + }, + "FileValidationReport": { + "description": "A resource that aggregates the validation errors found in an import job file.", + "id": "FileValidationReport", + "properties": { + "fileErrors": { + "description": "List of file level errors.", + "items": { + "$ref": "ImportError" + }, + "type": "array" + }, + "fileName": { + "description": "The name of the file.", + "type": "string" + }, + "partialReport": { + "description": "Flag indicating that processing was aborted due to maximum number of errors.", + "type": "boolean" + }, + "rowErrors": { + "description": "Partial list of rows that encountered validation error.", + "items": { + "$ref": "ImportRowError" + }, + "type": "array" + } + }, + "type": "object" + }, + "Frames": { + "description": "Collection of frame data.", + "id": "Frames", + "properties": { + "framesData": { + "description": "A repeated field of asset data.", + "items": { + "$ref": "AssetFrame" + }, + "type": "array" + } + }, + "type": "object" + }, + "FstabEntry": { + "description": "Single fstab entry.", + "id": "FstabEntry", + "properties": { + "file": { + "description": "The mount point for the filesystem.", + "type": "string" + }, + "freq": { + "description": "Used by dump to determine which filesystems need to be dumped.", + "format": "int32", + "type": "integer" + }, + "mntops": { + "description": "Mount options associated with the filesystem.", + "type": "string" + }, + "passno": { + "description": "Used by the fsck(8) program to determine the order in which filesystem checks are done at reboot time.", + "format": "int32", + "type": "integer" + }, + "spec": { + "description": "The block special device or remote filesystem to be mounted.", + "type": "string" + }, + "vfstype": { + "description": "The type of the filesystem.", + "type": "string" + } + }, + "type": "object" + }, + "FstabEntryList": { + "description": "Fstab content.", + "id": "FstabEntryList", + "properties": { + "entries": { + "description": "Fstab entries.", + "items": { + "$ref": "FstabEntry" + }, + "type": "array" + } + }, + "type": "object" + }, + "GCSPayloadInfo": { + "description": "A resource that represents a payload hosted on Google Cloud Storage.", + "id": "GCSPayloadInfo", + "properties": { + "format": { + "description": "The import job format.", + "enum": [ + "IMPORT_JOB_FORMAT_UNSPECIFIED", + "IMPORT_JOB_FORMAT_CMDB", + "IMPORT_JOB_FORMAT_RVTOOLS_XLSX", + "IMPORT_JOB_FORMAT_RVTOOLS_CSV", + "IMPORT_JOB_FORMAT_JSON_FRAME" + ], + "enumDescriptions": [ + "Default value.", + "Configuration management DB format.", + "RVTools format (XLSX).", + "RVTools format (CSV).", + "`AssetFrame` list in JSON format." + ], + "type": "string" + }, + "path": { + "description": "The payload path in Google Cloud Storage.", + "type": "string" + } + }, + "type": "object" + }, + "GuestConfigDetails": { + "description": "Guest OS config information.", + "id": "GuestConfigDetails", + "properties": { + "fstab": { + "$ref": "FstabEntryList", + "description": "Mount list (Linux fstab)." + }, + "hosts": { + "$ref": "HostsEntryList", + "description": "Hosts file (/etc/hosts)." + }, + "issue": { + "description": "OS issue (typically /etc/issue in Linux).", + "type": "string" + }, + "nfsExports": { + "$ref": "NfsExportList", + "description": "NFS exports." + }, + "selinux": { + "$ref": "Selinux", + "description": "SELinux details." + } + }, + "type": "object" + }, + "GuestInstalledApplication": { + "description": "Guest installed application information.", + "id": "GuestInstalledApplication", + "properties": { + "name": { + "description": "Installed application name .", + "type": "string" + }, + "path": { + "description": "Source path.", + "type": "string" + }, + "time": { + "description": "Date application was installed.", + "type": "string" + }, + "vendor": { + "description": "Installed application vendor.", + "type": "string" + }, + "version": { + "description": "Installed application version.", + "type": "string" + } + }, + "type": "object" + }, + "GuestInstalledApplicationList": { + "description": "Guest installed application list.", + "id": "GuestInstalledApplicationList", + "properties": { + "entries": { + "items": { + "$ref": "GuestInstalledApplication" + }, + "type": "array" + } + }, + "type": "object" + }, + "GuestOsDetails": { + "description": "Information from Guest-level collections.", + "id": "GuestOsDetails", + "properties": { + "config": { + "$ref": "GuestConfigDetails", + "description": "OS and app configuration." + }, + "runtime": { + "$ref": "GuestRuntimeDetails", + "description": "Runtime information." + } + }, + "type": "object" + }, + "GuestRuntimeDetails": { + "description": "Guest OS runtime information.", + "id": "GuestRuntimeDetails", + "properties": { + "domain": { + "description": "Domain, e.g. c.stratozone-development.internal.", + "type": "string" + }, + "installedApps": { + "$ref": "GuestInstalledApplicationList", + "description": "Installed applications information." + }, + "lastUptime": { + "$ref": "Date", + "description": "Date since last booted (last uptime date)." + }, + "machineName": { + "description": "Machine name.", + "type": "string" + }, + "networkInfo": { + "$ref": "RuntimeNetworkInfo", + "description": "Runtime network information (connections ports)." + }, + "openFileList": { + "$ref": "OpenFileList", + "description": "Open files information." + }, + "processes": { + "$ref": "RunningProcessList", + "description": "Running processes." + }, + "services": { + "$ref": "RunningServiceList", + "description": "Running background services." + } + }, + "type": "object" + }, + "HostsEntry": { + "description": "Single /etc/hosts entry.", + "id": "HostsEntry", + "properties": { + "hostNames": { + "description": "List of host names / aliases.", + "items": { + "type": "string" + }, + "type": "array" + }, + "ip": { + "description": "IP (raw, IPv4/6 agnostic).", + "type": "string" + } + }, + "type": "object" + }, + "HostsEntryList": { + "description": "Hosts content.", + "id": "HostsEntryList", + "properties": { + "entries": { + "description": "Hosts entries.", + "items": { + "$ref": "HostsEntry" + }, + "type": "array" + } + }, + "type": "object" + }, + "ImportError": { + "description": "A resource that reports the errors encountered while processing an import job.", + "id": "ImportError", + "properties": { + "errorDetails": { + "description": "The error information.", + "type": "string" + }, + "severity": { + "description": "The severity of the error.", + "enum": [ + "SEVERITY_UNSPECIFIED", + "ERROR", + "WARNING", + "INFO" + ], + "enumDescriptions": [ + "", + "", + "", + "" + ], + "type": "string" + } + }, + "type": "object" + }, + "ImportJob": { + "description": "A resource that represents the background job that imports asset frames.", + "id": "ImportJob", + "properties": { + "assetSource": { + "description": "Required. Reference to a source.", + "type": "string" + }, + "completeTime": { + "description": "Output only. The timestamp when the import job was completed.", + "format": "google-datetime", + "readOnly": true, + "type": "string" + }, + "createTime": { + "description": "Output only. The timestamp when the import job was created.", + "format": "google-datetime", + "readOnly": true, + "type": "string" + }, + "executionReport": { + "$ref": "ExecutionReport", + "description": "Output only. The report with the results of running the import job.", + "readOnly": true + }, + "gcsPayload": { + "$ref": "GCSPayloadInfo", + "description": "The payload is in Google Cloud Storage." + }, + "inlinePayload": { + "$ref": "InlinePayloadInfo", + "description": "The payload is included in the request, mainly used for small import jobs." + }, + "labels": { + "additionalProperties": { + "type": "string" + }, + "description": "Labels as key value pairs.", + "type": "object" + }, + "name": { + "description": "Output only. The full name of the import job.", + "readOnly": true, + "type": "string" + }, + "state": { + "description": "Output only. The state of the import job.", + "enum": [ + "IMPORT_JOB_STATE_UNSPECIFIED", + "IMPORT_JOB_STATE_PENDING", + "IMPORT_JOB_STATE_RUNNING", + "IMPORT_JOB_STATE_COMPLETED", + "IMPORT_JOB_STATE_FAILED", + "IMPORT_JOB_STATE_VALIDATING", + "IMPORT_JOB_STATE_FAILED_VALIDATION", + "IMPORT_JOB_STATE_READY" + ], + "enumDescriptions": [ + "Default value.", + "The import job is pending.", + "The processing of the import job is ongoing.", + "The import job processing has completed.", + "The import job failed to be processed.", + "The import job is being validated.", + "The import job contains blocking errors.", + "The validation of the job completed with no blocking errors." + ], + "readOnly": true, + "type": "string" + }, + "updateTime": { + "description": "Output only. The timestamp when the import job was last updated.", + "format": "google-datetime", + "readOnly": true, + "type": "string" + }, + "validationReport": { + "$ref": "ValidationReport", + "description": "Output only. The report with the validation results of the import job.", + "readOnly": true + } + }, + "type": "object" + }, + "ImportRowError": { + "description": "A resource that reports the import job errors at row level.", + "id": "ImportRowError", + "properties": { + "errors": { + "description": "The list of errors detected in the row.", + "items": { + "$ref": "ImportError" + }, + "type": "array" + }, + "rowNumber": { + "description": "The row number where the error was detected.", + "format": "int32", + "type": "integer" + }, + "vmName": { + "description": "The name of the VM in the row.", + "type": "string" + }, + "vmUuid": { + "description": "The VM UUID.", + "type": "string" + } + }, + "type": "object" + }, + "InlinePayloadInfo": { + "description": "A resource that represents the inline import job payload.", + "id": "InlinePayloadInfo", + "properties": { + "format": { + "description": "The import job format.", + "enum": [ + "IMPORT_JOB_FORMAT_UNSPECIFIED", + "IMPORT_JOB_FORMAT_CMDB", + "IMPORT_JOB_FORMAT_RVTOOLS_XLSX", + "IMPORT_JOB_FORMAT_RVTOOLS_CSV", + "IMPORT_JOB_FORMAT_JSON_FRAME" + ], + "enumDescriptions": [ + "Default value.", + "Configuration management DB format.", + "RVTools format (XLSX).", + "RVTools format (CSV).", + "`AssetFrame` list in JSON format." + ], + "type": "string" + }, + "payload": { + "description": "List of payload files.", + "items": { + "$ref": "PayloadFile" + }, + "type": "array" + } + }, + "type": "object" + }, + "ListAssetsResponse": { + "description": "Response message for listing assets.", + "id": "ListAssetsResponse", + "properties": { + "assets": { + "description": "A list of assets.", + "items": { + "$ref": "Asset" + }, + "type": "array" + }, + "nextPageToken": { + "description": "A token identifying a page of results the server should return.", + "type": "string" + }, + "unreachable": { + "description": "Locations that could not be reached.", + "items": { + "type": "string" + }, + "type": "array" + } + }, + "type": "object" + }, + "ListImportJobsResponse": { + "description": "A response for listing import jobs.", + "id": "ListImportJobsResponse", + "properties": { + "importJobs": { + "description": "The list of import jobs.", + "items": { + "$ref": "ImportJob" + }, + "type": "array" + }, + "nextPageToken": { + "description": "A token identifying a page of results the server should return.", + "type": "string" + }, + "unreachable": { + "description": "Locations that could not be reached.", + "items": { + "type": "string" + }, + "type": "array" + } + }, + "type": "object" + }, + "ListLocationsResponse": { + "description": "The response message for Locations.ListLocations.", + "id": "ListLocationsResponse", + "properties": { + "locations": { + "description": "A list of locations that matches the specified filter in the request.", + "items": { + "$ref": "Location" + }, + "type": "array" + }, + "nextPageToken": { + "description": "The standard List next-page token.", + "type": "string" + } + }, + "type": "object" + }, + "ListOperationsResponse": { + "description": "The response message for Operations.ListOperations.", + "id": "ListOperationsResponse", + "properties": { + "nextPageToken": { + "description": "The standard List next-page token.", + "type": "string" + }, + "operations": { + "description": "A list of operations that matches the specified filter in the request.", + "items": { + "$ref": "Operation" + }, + "type": "array" + } + }, + "type": "object" + }, + "ListSourcesResponse": { + "description": "Response message for listing sources.", + "id": "ListSourcesResponse", + "properties": { + "nextPageToken": { + "description": "A token identifying a page of results the server should return.", + "type": "string" + }, + "sources": { + "description": "The list of sources.", + "items": { + "$ref": "Source" + }, + "type": "array" + }, + "unreachable": { + "description": "Locations that could not be reached.", + "items": { + "type": "string" + }, + "type": "array" + } + }, + "type": "object" + }, + "Location": { + "description": "A resource that represents Google Cloud Platform location.", + "id": "Location", + "properties": { + "displayName": { + "description": "The friendly name for this location, typically a nearby city name. For example, \"Tokyo\".", + "type": "string" + }, + "labels": { + "additionalProperties": { + "type": "string" + }, + "description": "Cross-service attributes for the location. For example {\"cloud.googleapis.com/region\": \"us-east1\"}", + "type": "object" + }, + "locationId": { + "description": "The canonical id for this location. For example: `\"us-east1\"`.", + "type": "string" + }, + "metadata": { + "additionalProperties": { + "description": "Properties of the object. Contains field @type with type URL.", + "type": "any" + }, + "description": "Service-specific metadata. For example the available capacity at the given location.", + "type": "object" + }, + "name": { + "description": "Resource name for the location, which may vary between implementations. For example: `\"projects/example-project/locations/us-east1\"`", + "type": "string" + } + }, + "type": "object" + }, + "MemoryUsageSample": { + "description": "Memory usage sample.", + "id": "MemoryUsageSample", + "properties": { + "utilizedPercentage": { + "description": "Percentage of system memory utilized. Must be in the interval [0, 100].", + "format": "float", + "type": "number" + } + }, + "type": "object" + }, + "NetworkAdapterDetails": { + "description": "Details of network adapter.", + "id": "NetworkAdapterDetails", + "properties": { + "adapterType": { + "description": "Network adapter type (e.g. VMXNET3).", + "type": "string" + }, + "addresses": { + "$ref": "NetworkAddressList", + "description": "NetworkAddressList" + }, + "macAddress": { + "description": "MAC address.", + "type": "string" + } + }, + "type": "object" + }, + "NetworkAdapterList": { + "id": "NetworkAdapterList", + "properties": { + "networkAdapters": { + "description": "Network Adapter descriptions.", + "items": { + "$ref": "NetworkAdapterDetails" + }, + "type": "array" + } + }, + "type": "object" + }, + "NetworkAddress": { + "description": "Details of network address.", + "id": "NetworkAddress", + "properties": { + "assignment": { + "description": "If DHCP is used to assign addresses.", + "enum": [ + "ADDRESS_ASSIGNMENT_UNSPECIFIED", + "ADDRESS_ASSIGNMENT_STATIC", + "ADDRESS_ASSIGNMENT_DHCP" + ], + "enumDescriptions": [ + "Unknown (default value).", + "Staticly assigned IP.", + "Dynamically assigned IP (DHCP)." + ], + "type": "string" + }, + "bcast": { + "description": "Broadcast address.", + "type": "string" + }, + "fqdn": { + "description": "Fully qualified domain name.", + "type": "string" + }, + "ipAddress": { + "description": "Assigned or configured IP Address.", + "type": "string" + }, + "subnetMask": { + "description": "Subnet mask.", + "type": "string" + } + }, + "type": "object" + }, + "NetworkAddressList": { + "description": "List of allocated/assigned network addresses.", + "id": "NetworkAddressList", + "properties": { + "addresses": { + "items": { + "$ref": "NetworkAddress" + }, + "type": "array" + } + }, + "type": "object" + }, + "NetworkConnection": { + "id": "NetworkConnection", + "properties": { + "localIpAddress": { + "description": "Local IP address.", + "type": "string" + }, + "localPort": { + "description": "Local port.", + "format": "int32", + "type": "integer" + }, + "pid": { + "description": "Process ID.", + "format": "int64", + "type": "string" + }, + "processName": { + "description": "Process or service name.", + "type": "string" + }, + "protocol": { + "description": "Connection protocol (e.g. TCP/UDP).", + "type": "string" + }, + "remoteIpAddress": { + "description": "Remote IP address.", + "type": "string" + }, + "remotePort": { + "description": "Remote port.", + "format": "int32", + "type": "integer" + }, + "state": { + "description": "Connection state (e.g. CONNECTED).", + "type": "string" + } + }, + "type": "object" + }, + "NetworkConnectionList": { + "description": "Network connection list.", + "id": "NetworkConnectionList", + "properties": { + "entries": { + "items": { + "$ref": "NetworkConnection" + }, + "type": "array" + } + }, + "type": "object" + }, + "NetworkUsageSample": { + "description": "Network usage sample. Values are across all network interfaces.", + "id": "NetworkUsageSample", + "properties": { + "averageEgressBps": { + "description": "Average network egress in B/s sampled over a short window. Must be non-negative.", + "format": "float", + "type": "number" + }, + "averageIngressBps": { + "description": "Average network ingress in B/s sampled over a short window. Must be non-negative.", + "format": "float", + "type": "number" + } + }, + "type": "object" + }, + "NfsExport": { + "description": "NFS export.", + "id": "NfsExport", + "properties": { + "exportDirectory": { + "description": "The directory being exported.", + "type": "string" + }, + "hosts": { + "description": "The hosts or networks to which the export is being shared.", + "items": { + "type": "string" + }, + "type": "array" + } + }, + "type": "object" + }, + "NfsExportList": { + "description": "NFS exports.", + "id": "NfsExportList", + "properties": { + "entries": { + "description": "NFS export entries.", + "items": { + "$ref": "NfsExport" + }, + "type": "array" + } + }, + "type": "object" + }, + "OpenFileDetails": { + "description": "Open file Information.", + "id": "OpenFileDetails", + "properties": { + "command": { + "description": "Opened file command.", + "type": "string" + }, + "filePath": { + "description": "Opened file file path.", + "type": "string" + }, + "fileType": { + "description": "Opened file file type.", + "type": "string" + }, + "user": { + "description": "Opened file user.", + "type": "string" + } + }, + "type": "object" + }, + "OpenFileList": { + "description": "Open file list.", + "id": "OpenFileList", + "properties": { + "entries": { + "description": "Open file details entries.", + "items": { + "$ref": "OpenFileDetails" + }, + "type": "array" + } + }, + "type": "object" + }, + "Operation": { + "description": "This resource represents a long-running operation that is the result of a network API call.", + "id": "Operation", + "properties": { + "done": { + "description": "If the value is `false`, it means the operation is still in progress. If `true`, the operation is completed, and either `error` or `response` is available.", + "type": "boolean" + }, + "error": { + "$ref": "Status", + "description": "The error result of the operation in case of failure or cancellation." + }, + "metadata": { + "additionalProperties": { + "description": "Properties of the object. Contains field @type with type URL.", + "type": "any" + }, + "description": "Service-specific metadata associated with the operation. It typically contains progress information and common metadata such as create time. Some services might not provide such metadata. Any method that returns a long-running operation should document the metadata type, if any.", + "type": "object" + }, + "name": { + "description": "The server-assigned name, which is only unique within the same service that originally returns it. If you use the default HTTP mapping, the `name` should be a resource name ending with `operations/{unique_id}`.", + "type": "string" + }, + "response": { + "additionalProperties": { + "description": "Properties of the object. Contains field @type with type URL.", + "type": "any" + }, + "description": "The normal response of the operation in case of success. If the original method returns no data on success, such as `Delete`, the response is `google.protobuf.Empty`. If the original method is standard `Get`/`Create`/`Update`, the response should be the resource. For other methods, the response should have the type `XxxResponse`, where `Xxx` is the original method name. For example, if the original method name is `TakeSnapshot()`, the inferred response type is `TakeSnapshotResponse`.", + "type": "object" + } + }, + "type": "object" + }, + "OperationMetadata": { + "description": "Represents the metadata of the long-running operation.", + "id": "OperationMetadata", + "properties": { + "apiVersion": { + "description": "Output only. API version used to start the operation.", + "readOnly": true, + "type": "string" + }, + "createTime": { + "description": "Output only. The time the operation was created.", + "format": "google-datetime", + "readOnly": true, + "type": "string" + }, + "endTime": { + "description": "Output only. The time the operation finished running.", + "format": "google-datetime", + "readOnly": true, + "type": "string" + }, + "requestedCancellation": { + "description": "Output only. Identifies whether the user has requested cancellation of the operation. Operations that have been cancelled successfully have Operation.error value with a google.rpc.Status.code of 1, corresponding to `Code.CANCELLED`.", + "readOnly": true, + "type": "boolean" + }, + "statusMessage": { + "description": "Output only. Human-readable status of the operation, if any.", + "readOnly": true, + "type": "string" + }, + "target": { + "description": "Output only. Server-defined resource path for the target of the operation.", + "readOnly": true, + "type": "string" + }, + "verb": { + "description": "Output only. Name of the verb executed by the operation.", + "readOnly": true, + "type": "string" + } + }, + "type": "object" + }, + "PayloadFile": { + "description": "Payload file for inline import job payload.", + "id": "PayloadFile", + "properties": { + "data": { + "description": "The file data.", + "format": "byte", + "type": "string" + }, + "name": { + "description": "The file name.", + "type": "string" + } + }, + "type": "object" + }, + "PerformanceSample": { + "description": "Performance data sample.", + "id": "PerformanceSample", + "properties": { + "cpu": { + "$ref": "CpuUsageSample", + "description": "CPU usage sample." + }, + "disk": { + "$ref": "DiskUsageSample", + "description": "Disk usage sample." + }, + "memory": { + "$ref": "MemoryUsageSample", + "description": "Memory usage sample." + }, + "network": { + "$ref": "NetworkUsageSample", + "description": "Network usage sample." + }, + "sampleTime": { + "description": "Time the sample was collected.", + "format": "google-datetime", + "type": "string" + } + }, + "type": "object" + }, + "PlatformDetails": { + "description": "Information about the platform.", + "id": "PlatformDetails", + "properties": { + "vmwareDetails": { + "$ref": "VmwarePlatformDetails", + "description": "VMware specific details." + } + }, + "type": "object" + }, + "ReportAssetFramesResponse": { + "description": "A response to a call to `ReportAssetFrame`.", + "id": "ReportAssetFramesResponse", + "properties": {}, + "type": "object" + }, + "RunImportJobRequest": { + "description": "A request to run an import job.", + "id": "RunImportJobRequest", + "properties": { + "requestId": { + "description": "Optional. An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. The server will guarantee that for at least 60 minutes after the first request. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000).", + "type": "string" + } + }, + "type": "object" + }, + "RunningProcess": { + "description": "Guest OS running process details.", + "id": "RunningProcess", + "properties": { + "attributes": { + "additionalProperties": { + "type": "string" + }, + "description": "Process extended attributes.", + "type": "object" + }, + "cmdline": { + "description": "Process full command line.", + "type": "string" + }, + "exePath": { + "description": "Process binary path.", + "type": "string" + }, + "pid": { + "description": "Process ID.", + "format": "int64", + "type": "string" + }, + "user": { + "description": "User running the process.", + "type": "string" + } + }, + "type": "object" + }, + "RunningProcessList": { + "description": "List of running guest OS processes.", + "id": "RunningProcessList", + "properties": { + "processes": { + "items": { + "$ref": "RunningProcess" + }, + "type": "array" + } + }, + "type": "object" + }, + "RunningService": { + "description": "Guest OS running service details.", + "id": "RunningService", + "properties": { + "cmdline": { + "description": "Service command line.", + "type": "string" + }, + "exePath": { + "description": "Service binary path.", + "type": "string" + }, + "name": { + "description": "Service name.", + "type": "string" + }, + "pid": { + "description": "Service pid.", + "format": "int64", + "type": "string" + }, + "startMode": { + "description": "Service start mode (raw, OS-agnostic).", + "type": "string" + }, + "state": { + "description": "Service state (raw, OS-agnostic).", + "type": "string" + }, + "status": { + "description": "Service status.", + "type": "string" + } + }, + "type": "object" + }, + "RunningServiceList": { + "description": "List of running guest OS services.", + "id": "RunningServiceList", + "properties": { + "services": { + "items": { + "$ref": "RunningService" + }, + "type": "array" + } + }, + "type": "object" + }, + "RuntimeNetworkInfo": { + "description": "Runtime networking information.", + "id": "RuntimeNetworkInfo", + "properties": { + "connections": { + "$ref": "NetworkConnectionList", + "description": "Network connections." + }, + "netstat": { + "description": "Netstat (raw, OS-agnostic).", + "type": "string" + }, + "netstatTime": { + "$ref": "DateTime", + "description": "Netstat time collected." + } + }, + "type": "object" + }, + "Selinux": { + "description": "SELinux details.", + "id": "Selinux", + "properties": { + "enabled": { + "description": "Is SELinux enabled.", + "type": "boolean" + }, + "mode": { + "description": "SELinux mode enforcing / permissive.", + "type": "string" + } + }, + "type": "object" + }, + "Source": { + "description": "Source represents an object from which asset information is streamed to Migration Center.", + "id": "Source", + "properties": { + "createTime": { + "description": "Output only. The timestamp when the source was created.", + "format": "google-datetime", + "readOnly": true, + "type": "string" + }, + "description": { + "description": "Free-text description.", + "type": "string" + }, + "displayName": { + "description": "User-friendly display name.", + "type": "string" + }, + "isManaged": { + "description": "If `true`, the source is managed by other service(s).", + "type": "boolean" + }, + "name": { + "description": "Output only. The full name of the source.", + "readOnly": true, + "type": "string" + }, + "pendingFrameCount": { + "description": "Output only. Number of frames that are still being processed.", + "format": "int32", + "readOnly": true, + "type": "integer" + }, + "priority": { + "description": "The information confidence of the source. The higher the value, the higher the confidence.", + "format": "int32", + "type": "integer" + }, + "type": { + "description": "Data source type.", + "enum": [ + "SOURCE_TYPE_UNKNOWN", + "SOURCE_TYPE_UPLOAD", + "SOURCE_TYPE_GUEST_OS_SCAN", + "SOURCE_TYPE_INVENTORY_SCAN", + "SOURCE_TYPE_CUSTOM" + ], + "enumDescriptions": [ + "Unspecified", + "Manually uploaded file (e.g. CSV)", + "Guest-level info", + "Inventory-level scan", + "Third-party owned sources." + ], + "type": "string" + }, + "updateTime": { + "description": "Output only. The timestamp when the source was last updated.", + "format": "google-datetime", + "readOnly": true, + "type": "string" + } + }, + "type": "object" + }, + "Status": { + "description": "The `Status` type defines a logical error model that is suitable for different programming environments, including REST APIs and RPC APIs. It is used by [gRPC](https://github.com/grpc). Each `Status` message contains three pieces of data: error code, error message, and error details. You can find out more about this error model and how to work with it in the [API Design Guide](https://cloud.google.com/apis/design/errors).", + "id": "Status", + "properties": { + "code": { + "description": "The status code, which should be an enum value of google.rpc.Code.", + "format": "int32", + "type": "integer" + }, + "details": { + "description": "A list of messages that carry the error details. There is a common set of message types for APIs to use.", + "items": { + "additionalProperties": { + "description": "Properties of the object. Contains field @type with type URL.", + "type": "any" + }, + "type": "object" + }, + "type": "array" + }, + "message": { + "description": "A developer-facing error message, which should be in English. Any user-facing error message should be localized and sent in the google.rpc.Status.details field, or localized by the client.", + "type": "string" + } + }, + "type": "object" + }, + "TimeZone": { + "description": "Represents a time zone from the [IANA Time Zone Database](https://www.iana.org/time-zones).", + "id": "TimeZone", + "properties": { + "id": { + "description": "IANA Time Zone Database time zone, e.g. \"America/New_York\".", + "type": "string" + }, + "version": { + "description": "Optional. IANA Time Zone Database version number, e.g. \"2019a\".", + "type": "string" + } + }, + "type": "object" + }, + "ValidateImportJobRequest": { + "description": "A request to validate an import job.", + "id": "ValidateImportJobRequest", + "properties": { + "requestId": { + "description": "Optional. An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. The server will guarantee that for at least 60 minutes after the first request. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000).", + "type": "string" + } + }, + "type": "object" + }, + "ValidationReport": { + "description": "A resource that aggregates errors across import job files.", + "id": "ValidationReport", + "properties": { + "fileValidations": { + "description": "List of errors found in files.", + "items": { + "$ref": "FileValidationReport" + }, + "type": "array" + }, + "jobErrors": { + "description": "List of job level errors.", + "items": { + "$ref": "ImportError" + }, + "type": "array" + } + }, + "type": "object" + }, + "VirtualMachineArchitectureDetails": { + "description": "Details of the VM architecture.", + "id": "VirtualMachineArchitectureDetails", + "properties": { + "bios": { + "$ref": "BiosDetails", + "description": "Bios Details." + }, + "cpuArchitecture": { + "description": "CPU architecture e.g.: \"x64-based PC\", \"x86_64\", \"i686\" etc.", + "type": "string" + }, + "cpuManufacturer": { + "description": "CPU manufacturer e.g.: \"Intel\", \"AMD\".", + "type": "string" + }, + "cpuName": { + "description": "CPU name e.g. \"Intel Xeon E5-2690\", \"AMD EPYC 7571\" etc.", + "type": "string" + }, + "cpuSocketCount": { + "description": "Number of processor sockets allocated to the machine.", + "format": "int32", + "type": "integer" + }, + "cpuThreadCount": { + "description": "Number of cpu threads allocated to the machine.", + "format": "int32", + "type": "integer" + }, + "firmware": { + "description": "Firmware (BIOS/efi).", + "type": "string" + }, + "hyperthreading": { + "description": "CPU hyperthreading support (inner enum).", + "enum": [ + "HYPER_THREADING_UNSPECIFIED", + "HYPER_THREADING_DISABLED", + "HYPER_THREADING_ENABLED" + ], + "enumDescriptions": [ + "Unknown (default value).", + "Hyperthreading is disabled.", + "Hyperthreading is enabled." + ], + "type": "string" + }, + "vendor": { + "description": "Hardware vendor.", + "type": "string" + } + }, + "type": "object" + }, + "VirtualMachineDetails": { + "description": "Details of a VirtualMachine.", + "id": "VirtualMachineDetails", + "properties": { + "coreCount": { + "description": "Number of CPU cores in the VirtualMachine. Must be non-negative.", + "format": "int32", + "type": "integer" + }, + "guestOs": { + "$ref": "GuestOsDetails", + "description": "Guest OS information." + }, + "memoryMb": { + "description": "The amount of memory in the VirtualMachine. Must be non-negative.", + "format": "int32", + "type": "integer" + }, + "osFamily": { + "description": "What family the OS belong to, if known.", + "enum": [ + "OS_FAMILY_UNKNOWN", + "OS_FAMILY_WINDOWS", + "OS_FAMILY_LINUX", + "OS_FAMILY_UNIX" + ], + "enumDescriptions": [ + "", + "Microsoft Windows Server and Desktop", + "Various Linux flavors", + "Non-Linux Unix flavors" + ], + "type": "string" + }, + "osName": { + "description": "The name of the operating system running on the VirtualMachine.", + "type": "string" + }, + "platform": { + "$ref": "PlatformDetails", + "description": "Platform information." + }, + "powerState": { + "description": "Power state of VM (poweredOn or poweredOff).", + "type": "string" + }, + "vcenterFolder": { + "description": "Folder name in vCenter where asset resides.", + "type": "string" + }, + "vcenterUrl": { + "description": "vCenter URL used in collection.", + "type": "string" + }, + "vcenterVmId": { + "description": "vCenter VM ID.", + "type": "string" + }, + "vmArchitecture": { + "$ref": "VirtualMachineArchitectureDetails", + "description": "VM architecture details (vendor, cpu arch)." + }, + "vmDisks": { + "$ref": "VirtualMachineDiskDetails", + "description": "VM disk details." + }, + "vmName": { + "description": "Virtual Machine display name.", + "type": "string" + }, + "vmNetwork": { + "$ref": "VirtualMachineNetworkDetails", + "description": "VM network details." + }, + "vmUuid": { + "description": "Virtual Machine uniqe identifier.", + "type": "string" + } + }, + "type": "object" + }, + "VirtualMachineDiskDetails": { + "description": "Details of VM disks.", + "id": "VirtualMachineDiskDetails", + "properties": { + "disks": { + "$ref": "DiskEntryList", + "description": "List of disks." + }, + "hddTotalCapacityBytes": { + "description": "Disk total Capacity.", + "format": "int64", + "type": "string" + }, + "hddTotalFreeBytes": { + "description": "Total Disk Free Space.", + "format": "int64", + "type": "string" + }, + "lsblkJson": { + "description": "Raw lsblk output in json.", + "type": "string" + } + }, + "type": "object" + }, + "VirtualMachineNetworkDetails": { + "description": "Details of network adapters and settings", + "id": "VirtualMachineNetworkDetails", + "properties": { + "defaultGw": { + "description": "Default GW address. Top-level object, will be later encriched by full RouteInfo.", + "type": "string" + }, + "networkAdapters": { + "$ref": "NetworkAdapterList", + "description": "List of Network Adapters." + }, + "primaryIpAddress": { + "description": "IP Address of the machine.", + "type": "string" + }, + "primaryMacAddress": { + "description": "MAC Address of the machine. This property is used to uniqly identify the machine.", + "type": "string" + } + }, + "type": "object" + }, + "VmwareDiskConfig": { + "description": "VMware disk config details.", + "id": "VmwareDiskConfig", + "properties": { + "backingType": { + "description": "VMDK backing type.", + "enum": [ + "BACKING_TYPE_UNSPECIFIED", + "BACKING_TYPE_FLAT_V1", + "BACKING_TYPE_FLAT_V2", + "BACKING_TYPE_PMEM", + "BACKING_TYPE_RDM_V1", + "BACKING_TYPE_RDM_V2", + "BACKING_TYPE_SESPARSE", + "BACKING_TYPE_SESPARSE_V1", + "BACKING_TYPE_SESPARSE_V2" + ], + "enumDescriptions": [ + "Default value.", + "Flat v1.", + "Flat v2.", + "Persistent memory, also known as Non-Volatile Memory (NVM).", + "Raw Disk Memory v1.", + "Raw Disk Memory v2.", + "SEsparse is a snapshot format introduced in vSphere 5.5 for large disks.", + "SEsparse v1.", + "SEsparse v1." + ], + "type": "string" + }, + "rdmCompatibilityMode": { + "description": "RDM compatibility mode.", + "type": "string" + }, + "shared": { + "description": "Is VMDK shared with other VMs.", + "type": "boolean" + }, + "vmdkDiskMode": { + "description": "VMDK disk mode.", + "type": "string" + } + }, + "type": "object" + }, + "VmwarePlatformDetails": { + "description": "VMware specific details.", + "id": "VmwarePlatformDetails", + "properties": { + "esxVersion": { + "description": "ESX version.", + "type": "string" + }, + "osid": { + "description": "VMware os enum - https://vdc-repo.vmware.com/vmwb-repository/dcr-public/da47f910-60ac-438b-8b9b-6122f4d14524/16b7274a-bf8b-4b4c-a05e-746f2aa93c8c/doc/vim.vm.GuestOsDescriptor.GuestOsIdentifier.html.", + "type": "string" + }, + "vcenterVersion": { + "description": "vCenter version.", + "type": "string" + } + }, + "type": "object" + } + }, + "servicePath": "", + "title": "Migration Center API", + "version": "v1alpha1", + "version_module": true +} \ No newline at end of file diff --git a/migrationcenter/v1alpha1/migrationcenter-gen.go b/migrationcenter/v1alpha1/migrationcenter-gen.go new file mode 100644 index 00000000000..5095677b60d --- /dev/null +++ b/migrationcenter/v1alpha1/migrationcenter-gen.go @@ -0,0 +1,7790 @@ +// Copyright 2023 Google LLC. +// Use of this source code is governed by a BSD-style +// license that can be found in the LICENSE file. + +// Code generated file. DO NOT EDIT. + +// Package migrationcenter provides access to the Migration Center API. +// +// For product documentation, see: https://cloud.google.com/migration-center +// +// # Creating a client +// +// Usage example: +// +// import "google.golang.org/api/migrationcenter/v1alpha1" +// ... +// ctx := context.Background() +// migrationcenterService, err := migrationcenter.NewService(ctx) +// +// In this example, Google Application Default Credentials are used for authentication. +// +// For information on how to create and obtain Application Default Credentials, see https://developers.google.com/identity/protocols/application-default-credentials. +// +// # Other authentication options +// +// To use an API key for authentication (note: some APIs do not support API keys), use option.WithAPIKey: +// +// migrationcenterService, err := migrationcenter.NewService(ctx, option.WithAPIKey("AIza...")) +// +// To use an OAuth token (e.g., a user token obtained via a three-legged OAuth flow), use option.WithTokenSource: +// +// config := &oauth2.Config{...} +// // ... +// token, err := config.Exchange(ctx, ...) +// migrationcenterService, err := migrationcenter.NewService(ctx, option.WithTokenSource(config.TokenSource(ctx, token))) +// +// See https://godoc.org/google.golang.org/api/option/ for details on options. +package migrationcenter // import "google.golang.org/api/migrationcenter/v1alpha1" + +import ( + "bytes" + "context" + "encoding/json" + "errors" + "fmt" + "io" + "net/http" + "net/url" + "strconv" + "strings" + + googleapi "google.golang.org/api/googleapi" + internal "google.golang.org/api/internal" + gensupport "google.golang.org/api/internal/gensupport" + option "google.golang.org/api/option" + internaloption "google.golang.org/api/option/internaloption" + htransport "google.golang.org/api/transport/http" +) + +// Always reference these packages, just in case the auto-generated code +// below doesn't. +var _ = bytes.NewBuffer +var _ = strconv.Itoa +var _ = fmt.Sprintf +var _ = json.NewDecoder +var _ = io.Copy +var _ = url.Parse +var _ = gensupport.MarshalJSON +var _ = googleapi.Version +var _ = errors.New +var _ = strings.Replace +var _ = context.Canceled +var _ = internaloption.WithDefaultEndpoint + +const apiId = "migrationcenter:v1alpha1" +const apiName = "migrationcenter" +const apiVersion = "v1alpha1" +const basePath = "https://migrationcenter.googleapis.com/" +const mtlsBasePath = "https://migrationcenter.mtls.googleapis.com/" + +// OAuth2 scopes used by this API. +const ( + // See, edit, configure, and delete your Google Cloud data and see the + // email address for your Google Account. + CloudPlatformScope = "https://www.googleapis.com/auth/cloud-platform" +) + +// NewService creates a new Service. +func NewService(ctx context.Context, opts ...option.ClientOption) (*Service, error) { + scopesOption := internaloption.WithDefaultScopes( + "https://www.googleapis.com/auth/cloud-platform", + ) + // NOTE: prepend, so we don't override user-specified scopes. + opts = append([]option.ClientOption{scopesOption}, opts...) + opts = append(opts, internaloption.WithDefaultEndpoint(basePath)) + opts = append(opts, internaloption.WithDefaultMTLSEndpoint(mtlsBasePath)) + client, endpoint, err := htransport.NewClient(ctx, opts...) + if err != nil { + return nil, err + } + s, err := New(client) + if err != nil { + return nil, err + } + if endpoint != "" { + s.BasePath = endpoint + } + return s, nil +} + +// New creates a new Service. It uses the provided http.Client for requests. +// +// Deprecated: please use NewService instead. +// To provide a custom HTTP client, use option.WithHTTPClient. +// If you are using google.golang.org/api/googleapis/transport.APIKey, use option.WithAPIKey with NewService instead. +func New(client *http.Client) (*Service, error) { + if client == nil { + return nil, errors.New("client is nil") + } + s := &Service{client: client, BasePath: basePath} + s.Projects = NewProjectsService(s) + return s, nil +} + +type Service struct { + client *http.Client + BasePath string // API endpoint base URL + UserAgent string // optional additional User-Agent fragment + + Projects *ProjectsService +} + +func (s *Service) userAgent() string { + if s.UserAgent == "" { + return googleapi.UserAgent + } + return googleapi.UserAgent + " " + s.UserAgent +} + +func NewProjectsService(s *Service) *ProjectsService { + rs := &ProjectsService{s: s} + rs.Locations = NewProjectsLocationsService(s) + return rs +} + +type ProjectsService struct { + s *Service + + Locations *ProjectsLocationsService +} + +func NewProjectsLocationsService(s *Service) *ProjectsLocationsService { + rs := &ProjectsLocationsService{s: s} + rs.Assets = NewProjectsLocationsAssetsService(s) + rs.ImportJobs = NewProjectsLocationsImportJobsService(s) + rs.Operations = NewProjectsLocationsOperationsService(s) + rs.Sources = NewProjectsLocationsSourcesService(s) + return rs +} + +type ProjectsLocationsService struct { + s *Service + + Assets *ProjectsLocationsAssetsService + + ImportJobs *ProjectsLocationsImportJobsService + + Operations *ProjectsLocationsOperationsService + + Sources *ProjectsLocationsSourcesService +} + +func NewProjectsLocationsAssetsService(s *Service) *ProjectsLocationsAssetsService { + rs := &ProjectsLocationsAssetsService{s: s} + return rs +} + +type ProjectsLocationsAssetsService struct { + s *Service +} + +func NewProjectsLocationsImportJobsService(s *Service) *ProjectsLocationsImportJobsService { + rs := &ProjectsLocationsImportJobsService{s: s} + return rs +} + +type ProjectsLocationsImportJobsService struct { + s *Service +} + +func NewProjectsLocationsOperationsService(s *Service) *ProjectsLocationsOperationsService { + rs := &ProjectsLocationsOperationsService{s: s} + return rs +} + +type ProjectsLocationsOperationsService struct { + s *Service +} + +func NewProjectsLocationsSourcesService(s *Service) *ProjectsLocationsSourcesService { + rs := &ProjectsLocationsSourcesService{s: s} + return rs +} + +type ProjectsLocationsSourcesService struct { + s *Service +} + +// AggregateAssetsValuesRequest: A request to aggregate one or more +// values. +type AggregateAssetsValuesRequest struct { + // Aggregations: Array of aggregations to perform. Up to 25 aggregations + // can be defined. + Aggregations []*Aggregation `json:"aggregations,omitempty"` + + // Filter: The aggregation will be performed on assets that match the + // provided filter. + Filter string `json:"filter,omitempty"` + + // ForceSendFields is a list of field names (e.g. "Aggregations") 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. "Aggregations") 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 *AggregateAssetsValuesRequest) MarshalJSON() ([]byte, error) { + type NoMethod AggregateAssetsValuesRequest + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + +// AggregateAssetsValuesResponse: A response to a request to aggregated +// assets values. +type AggregateAssetsValuesResponse struct { + // Results: The aggregation results. + Results []*AggregationResult `json:"results,omitempty"` + + // ServerResponse contains the HTTP response code and headers from the + // server. + googleapi.ServerResponse `json:"-"` + + // ForceSendFields is a list of field names (e.g. "Results") 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. "Results") 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 *AggregateAssetsValuesResponse) MarshalJSON() ([]byte, error) { + type NoMethod AggregateAssetsValuesResponse + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + +// Aggregation: Message describing an aggregation. The message includes +// the aggregation type, parameters, and the field on which to perform +// the aggregation. +type Aggregation struct { + // Count: Count the number of matching objects. + Count *AggregationCount `json:"count,omitempty"` + + // Field: The name of the field on which to aggregate. + Field string `json:"field,omitempty"` + + // Frequency: Creates a frequency distribution of all field values. + Frequency *AggregationFrequency `json:"frequency,omitempty"` + + // Histogram: Creates a bucketed histogram of field values. + Histogram *AggregationHistogram `json:"histogram,omitempty"` + + // Sum: Sum over a numeric field. + Sum *AggregationSum `json:"sum,omitempty"` + + // ForceSendFields is a list of field names (e.g. "Count") 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. "Count") 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 *Aggregation) MarshalJSON() ([]byte, error) { + type NoMethod Aggregation + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + +// AggregationCount: Object count. +type AggregationCount struct { +} + +// AggregationFrequency: Frequency distribution of all field values. +type AggregationFrequency struct { +} + +// AggregationHistogram: Histogram of bucketed assets counts by field +// value. +type AggregationHistogram struct { + // LowerBounds: Lower bounds of buckets. The response will contain `n+1` + // buckets for `n` bounds. The first bucket will count all assets for + // which the field value is smaller than the first bound. Subsequent + // buckets will count assets for which the field value is greater or + // equal to a lower bound and smaller than the next one. The last bucket + // will count assets for which the field value is greater or equal to + // the final lower bound. You can define up to 20 lower bounds. + LowerBounds []float64 `json:"lowerBounds,omitempty"` + + // ForceSendFields is a list of field names (e.g. "LowerBounds") 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. "LowerBounds") 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 *AggregationHistogram) MarshalJSON() ([]byte, error) { + type NoMethod AggregationHistogram + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + +// AggregationResult: Message describing a result of an aggregation. +type AggregationResult struct { + Count *AggregationResultCount `json:"count,omitempty"` + + Field string `json:"field,omitempty"` + + Frequency *AggregationResultFrequency `json:"frequency,omitempty"` + + Histogram *AggregationResultHistogram `json:"histogram,omitempty"` + + Sum *AggregationResultSum `json:"sum,omitempty"` + + // ForceSendFields is a list of field names (e.g. "Count") 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. "Count") 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 *AggregationResult) MarshalJSON() ([]byte, error) { + type NoMethod AggregationResult + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + +// AggregationResultCount: The result of a count aggregation. +type AggregationResultCount struct { + Value int64 `json:"value,omitempty,string"` + + // ForceSendFields is a list of field names (e.g. "Value") 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. "Value") 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 *AggregationResultCount) MarshalJSON() ([]byte, error) { + type NoMethod AggregationResultCount + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + +// AggregationResultFrequency: The result of a frequency distribution +// aggregation. +type AggregationResultFrequency struct { + Values map[string]string `json:"values,omitempty"` + + // ForceSendFields is a list of field names (e.g. "Values") 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. "Values") 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 *AggregationResultFrequency) MarshalJSON() ([]byte, error) { + type NoMethod AggregationResultFrequency + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + +// AggregationResultHistogram: The result of a bucketed histogram +// aggregation. +type AggregationResultHistogram struct { + // Buckets: Buckets in the histogram. There will be `n+1` buckets + // matching `n` lower bounds in the request. The first bucket will be + // from -infinity to the first bound. Subsequent buckets will be between + // one bound and the next. The final bucket will be from the final bound + // to infinity. + Buckets []*AggregationResultHistogramBucket `json:"buckets,omitempty"` + + // ForceSendFields is a list of field names (e.g. "Buckets") 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. "Buckets") 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 *AggregationResultHistogram) MarshalJSON() ([]byte, error) { + type NoMethod AggregationResultHistogram + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + +// AggregationResultHistogramBucket: A histogram bucket with a lower and +// upper bound, and a count of items with a field value between those +// bounds. The lower bound is inclusive and the upper bound is +// exclusive. Lower bound may be -infinity and upper bound may be +// infinity. +type AggregationResultHistogramBucket struct { + // Count: Count of items in the bucket. + Count int64 `json:"count,omitempty,string"` + + // LowerBound: Lower bound - inclusive. + LowerBound float64 `json:"lowerBound,omitempty"` + + // UpperBound: Upper bound - exclusive. + UpperBound float64 `json:"upperBound,omitempty"` + + // ForceSendFields is a list of field names (e.g. "Count") 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. "Count") 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 *AggregationResultHistogramBucket) MarshalJSON() ([]byte, error) { + type NoMethod AggregationResultHistogramBucket + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + +func (s *AggregationResultHistogramBucket) UnmarshalJSON(data []byte) error { + type NoMethod AggregationResultHistogramBucket + var s1 struct { + LowerBound gensupport.JSONFloat64 `json:"lowerBound"` + UpperBound gensupport.JSONFloat64 `json:"upperBound"` + *NoMethod + } + s1.NoMethod = (*NoMethod)(s) + if err := json.Unmarshal(data, &s1); err != nil { + return err + } + s.LowerBound = float64(s1.LowerBound) + s.UpperBound = float64(s1.UpperBound) + return nil +} + +// AggregationResultSum: The result of a sum aggregation. +type AggregationResultSum struct { + Value float64 `json:"value,omitempty"` + + // ForceSendFields is a list of field names (e.g. "Value") 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. "Value") 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 *AggregationResultSum) MarshalJSON() ([]byte, error) { + type NoMethod AggregationResultSum + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + +func (s *AggregationResultSum) UnmarshalJSON(data []byte) error { + type NoMethod AggregationResultSum + var s1 struct { + Value gensupport.JSONFloat64 `json:"value"` + *NoMethod + } + s1.NoMethod = (*NoMethod)(s) + if err := json.Unmarshal(data, &s1); err != nil { + return err + } + s.Value = float64(s1.Value) + return nil +} + +// AggregationSum: Sum of field values. +type AggregationSum struct { +} + +// Asset: An asset represents a resource in your environment. Asset +// types include virtual machines and databases. +type Asset struct { + // Attributes: Generic asset attributes. + Attributes map[string]string `json:"attributes,omitempty"` + + // CreateTime: Output only. The timestamp when the asset was created. + CreateTime string `json:"createTime,omitempty"` + + // Labels: Labels as key value pairs. + Labels map[string]string `json:"labels,omitempty"` + + // Name: Output only. The full name of the asset. + Name string `json:"name,omitempty"` + + // Sources: Output only. The list of sources contributing to the asset. + Sources []string `json:"sources,omitempty"` + + // UpdateTime: Output only. The timestamp when the asset was last + // updated. + UpdateTime string `json:"updateTime,omitempty"` + + // VirtualMachineDetails: Output only. Asset information specific for + // virtual machines. + VirtualMachineDetails *VirtualMachineDetails `json:"virtualMachineDetails,omitempty"` + + // ServerResponse contains the HTTP response code and headers from the + // server. + googleapi.ServerResponse `json:"-"` + + // ForceSendFields is a list of field names (e.g. "Attributes") 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. "Attributes") 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 *Asset) MarshalJSON() ([]byte, error) { + type NoMethod Asset + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + +// AssetFrame: Contains data reported from an inventory source on an +// asset. +type AssetFrame struct { + // Attributes: Generic asset attributes. + Attributes map[string]string `json:"attributes,omitempty"` + + // Labels: Labels as key value pairs. + Labels map[string]string `json:"labels,omitempty"` + + // PerformanceSamples: Asset performance data samples. + PerformanceSamples []*PerformanceSample `json:"performanceSamples,omitempty"` + + // ReportTime: The time the data was reported. + ReportTime string `json:"reportTime,omitempty"` + + // TraceToken: Optional. Trace token is optionally provided to assist + // with debugging and traceability. + TraceToken string `json:"traceToken,omitempty"` + + // VirtualMachineDetails: Asset information specific for virtual + // machines. + VirtualMachineDetails *VirtualMachineDetails `json:"virtualMachineDetails,omitempty"` + + // ForceSendFields is a list of field names (e.g. "Attributes") 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. "Attributes") 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 *AssetFrame) MarshalJSON() ([]byte, error) { + type NoMethod AssetFrame + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + +// BiosDetails: Details about the bios. +type BiosDetails struct { + // BiosManufacturer: Bios manufacturer. + BiosManufacturer string `json:"biosManufacturer,omitempty"` + + // BiosName: Bios name. + BiosName string `json:"biosName,omitempty"` + + // BiosReleaseDate: Bios release date. + BiosReleaseDate string `json:"biosReleaseDate,omitempty"` + + // BiosVersion: Bios version. + BiosVersion string `json:"biosVersion,omitempty"` + + // SmbiosUuid: SMBios UUID. + SmbiosUuid string `json:"smbiosUuid,omitempty"` + + // ForceSendFields is a list of field names (e.g. "BiosManufacturer") 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. "BiosManufacturer") 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 *BiosDetails) MarshalJSON() ([]byte, error) { + type NoMethod BiosDetails + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + +// CancelOperationRequest: The request message for +// Operations.CancelOperation. +type CancelOperationRequest struct { +} + +// CpuUsageSample: CPU usage sample. +type CpuUsageSample struct { + // UtilizedPercentage: Percentage of total CPU capacity utilized. Must + // be in the interval [0, 100]. On most systems can be calculated using + // 100 - idle percentage. + UtilizedPercentage float64 `json:"utilizedPercentage,omitempty"` + + // ForceSendFields is a list of field names (e.g. "UtilizedPercentage") + // 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. "UtilizedPercentage") 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 *CpuUsageSample) MarshalJSON() ([]byte, error) { + type NoMethod CpuUsageSample + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + +func (s *CpuUsageSample) UnmarshalJSON(data []byte) error { + type NoMethod CpuUsageSample + var s1 struct { + UtilizedPercentage gensupport.JSONFloat64 `json:"utilizedPercentage"` + *NoMethod + } + s1.NoMethod = (*NoMethod)(s) + if err := json.Unmarshal(data, &s1); err != nil { + return err + } + s.UtilizedPercentage = float64(s1.UtilizedPercentage) + return nil +} + +// Date: Represents a whole or partial calendar date, such as a +// birthday. The time of day and time zone are either specified +// elsewhere or are insignificant. The date is relative to the Gregorian +// Calendar. This can represent one of the following: * A full date, +// with non-zero year, month, and day values. * A month and day, with a +// zero year (for example, an anniversary). * A year on its own, with a +// zero month and a zero day. * A year and month, with a zero day (for +// example, a credit card expiration date). Related types: * +// google.type.TimeOfDay * google.type.DateTime * +// google.protobuf.Timestamp +type Date struct { + // Day: Day of a month. Must be from 1 to 31 and valid for the year and + // month, or 0 to specify a year by itself or a year and month where the + // day isn't significant. + Day int64 `json:"day,omitempty"` + + // Month: Month of a year. Must be from 1 to 12, or 0 to specify a year + // without a month and day. + Month int64 `json:"month,omitempty"` + + // Year: Year of the date. Must be from 1 to 9999, or 0 to specify a + // date without a year. + Year int64 `json:"year,omitempty"` + + // ForceSendFields is a list of field names (e.g. "Day") 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. "Day") 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 *Date) MarshalJSON() ([]byte, error) { + type NoMethod Date + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + +// DateTime: Represents civil time (or occasionally physical time). This +// type can represent a civil time in one of a few possible ways: * When +// utc_offset is set and time_zone is unset: a civil time on a calendar +// day with a particular offset from UTC. * When time_zone is set and +// utc_offset is unset: a civil time on a calendar day in a particular +// time zone. * When neither time_zone nor utc_offset is set: a civil +// time on a calendar day in local time. The date is relative to the +// Proleptic Gregorian Calendar. If year, month, or day are 0, the +// DateTime is considered not to have a specific year, month, or day +// respectively. This type may also be used to represent a physical time +// if all the date and time fields are set and either case of the +// `time_offset` oneof is set. Consider using `Timestamp` message for +// physical time instead. If your use case also would like to store the +// user's timezone, that can be done in another field. This type is more +// flexible than some applications may want. Make sure to document and +// validate your application's limitations. +type DateTime struct { + // Day: Optional. Day of month. Must be from 1 to 31 and valid for the + // year and month, or 0 if specifying a datetime without a day. + Day int64 `json:"day,omitempty"` + + // Hours: Optional. Hours of day in 24 hour format. Should be from 0 to + // 23, defaults to 0 (midnight). An API may choose to allow the value + // "24:00:00" for scenarios like business closing time. + Hours int64 `json:"hours,omitempty"` + + // Minutes: Optional. Minutes of hour of day. Must be from 0 to 59, + // defaults to 0. + Minutes int64 `json:"minutes,omitempty"` + + // Month: Optional. Month of year. Must be from 1 to 12, or 0 if + // specifying a datetime without a month. + Month int64 `json:"month,omitempty"` + + // Nanos: Optional. Fractions of seconds in nanoseconds. Must be from 0 + // to 999,999,999, defaults to 0. + Nanos int64 `json:"nanos,omitempty"` + + // Seconds: Optional. Seconds of minutes of the time. Must normally be + // from 0 to 59, defaults to 0. An API may allow the value 60 if it + // allows leap-seconds. + Seconds int64 `json:"seconds,omitempty"` + + // TimeZone: Time zone. + TimeZone *TimeZone `json:"timeZone,omitempty"` + + // UtcOffset: UTC offset. Must be whole seconds, between -18 hours and + // +18 hours. For example, a UTC offset of -4:00 would be represented as + // { seconds: -14400 }. + UtcOffset string `json:"utcOffset,omitempty"` + + // Year: Optional. Year of date. Must be from 1 to 9999, or 0 if + // specifying a datetime without a year. + Year int64 `json:"year,omitempty"` + + // ForceSendFields is a list of field names (e.g. "Day") 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. "Day") 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 *DateTime) MarshalJSON() ([]byte, error) { + type NoMethod DateTime + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + +// DiskEntry: Single disk entry. +type DiskEntry struct { + // DiskLabel: Disk label. + DiskLabel string `json:"diskLabel,omitempty"` + + // DiskLabelType: Disk label type (e.g. BIOS/GPT) + DiskLabelType string `json:"diskLabelType,omitempty"` + + // HwAddress: Disk hardware address (e.g. 0:1 for SCSI). + HwAddress string `json:"hwAddress,omitempty"` + + // InterfaceType: Disks interface type (e.g. SATA/SCSI) + InterfaceType string `json:"interfaceType,omitempty"` + + // Partitions: Partition layout. + Partitions *DiskPartitionList `json:"partitions,omitempty"` + + // Status: Disk status (e.g. online). + Status string `json:"status,omitempty"` + + // TotalCapacityBytes: Disk Capacity (required). + TotalCapacityBytes int64 `json:"totalCapacityBytes,omitempty,string"` + + // TotalFreeBytes: Disk Free Space. + TotalFreeBytes int64 `json:"totalFreeBytes,omitempty,string"` + + // VmwareConfig: Optional. Optional disk VMware details. + VmwareConfig *VmwareDiskConfig `json:"vmwareConfig,omitempty"` + + // ForceSendFields is a list of field names (e.g. "DiskLabel") 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. "DiskLabel") 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 *DiskEntry) MarshalJSON() ([]byte, error) { + type NoMethod DiskEntry + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + +// DiskEntryList: VM disks. +type DiskEntryList struct { + // Entries: Disk entries. + Entries []*DiskEntry `json:"entries,omitempty"` + + // ForceSendFields is a list of field names (e.g. "Entries") 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. "Entries") 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 *DiskEntryList) MarshalJSON() ([]byte, error) { + type NoMethod DiskEntryList + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + +// DiskPartition: Disk Partition details. +type DiskPartition struct { + // CapacityBytes: Partition capacity. + CapacityBytes int64 `json:"capacityBytes,omitempty,string"` + + // FileSystem: Partition file system. + FileSystem string `json:"fileSystem,omitempty"` + + // FreeBytes: Partition free space. + FreeBytes int64 `json:"freeBytes,omitempty,string"` + + // MountPoint: Mount pount (Linux/Windows) or drive letter (Windows). + MountPoint string `json:"mountPoint,omitempty"` + + // SubPartitions: Sub-partitions. + SubPartitions *DiskPartitionList `json:"subPartitions,omitempty"` + + // Type: Partition type (e.g. BIOS boot). + Type string `json:"type,omitempty"` + + // Uuid: Partition UUID. + Uuid string `json:"uuid,omitempty"` + + // ForceSendFields is a list of field names (e.g. "CapacityBytes") 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. "CapacityBytes") 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 *DiskPartition) MarshalJSON() ([]byte, error) { + type NoMethod DiskPartition + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + +type DiskPartitionList struct { + // Entries: Partition entries. + Entries []*DiskPartition `json:"entries,omitempty"` + + // ForceSendFields is a list of field names (e.g. "Entries") 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. "Entries") 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 *DiskPartitionList) MarshalJSON() ([]byte, error) { + type NoMethod DiskPartitionList + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + +// DiskUsageSample: Disk usage sample. Values are across all disks. +type DiskUsageSample struct { + // AverageIops: Average IOPS sampled over a short window. Must be + // non-negative. + AverageIops float64 `json:"averageIops,omitempty"` + + // ForceSendFields is a list of field names (e.g. "AverageIops") 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. "AverageIops") 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 *DiskUsageSample) MarshalJSON() ([]byte, error) { + type NoMethod DiskUsageSample + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + +func (s *DiskUsageSample) UnmarshalJSON(data []byte) error { + type NoMethod DiskUsageSample + var s1 struct { + AverageIops gensupport.JSONFloat64 `json:"averageIops"` + *NoMethod + } + s1.NoMethod = (*NoMethod)(s) + if err := json.Unmarshal(data, &s1); err != nil { + return err + } + s.AverageIops = float64(s1.AverageIops) + return nil +} + +// Empty: A generic empty message that you can re-use to avoid defining +// duplicated empty messages in your APIs. A typical example is to use +// it as the request or the response type of an API method. For +// instance: service Foo { rpc Bar(google.protobuf.Empty) returns +// (google.protobuf.Empty); } +type Empty struct { + // ServerResponse contains the HTTP response code and headers from the + // server. + googleapi.ServerResponse `json:"-"` +} + +// ExecutionReport: A resource that reports result of the import job +// execution. +type ExecutionReport struct { + // ExecutionErrors: Validation errors encountered during the execution + // of the import job. + ExecutionErrors *ValidationReport `json:"executionErrors,omitempty"` + + // FramesReported: Total number of asset frames reported for the import + // job. + FramesReported int64 `json:"framesReported,omitempty"` + + // JobErrors: List of job-level errors. Deprecated, use the job errors + // under execution_errors instead. + JobErrors []*ImportError `json:"jobErrors,omitempty"` + + // TotalRowsCount: Total number of rows in the import job. + TotalRowsCount int64 `json:"totalRowsCount,omitempty"` + + // ForceSendFields is a list of field names (e.g. "ExecutionErrors") 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. "ExecutionErrors") 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 *ExecutionReport) MarshalJSON() ([]byte, error) { + type NoMethod ExecutionReport + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + +// FileValidationReport: A resource that aggregates the validation +// errors found in an import job file. +type FileValidationReport struct { + // FileErrors: List of file level errors. + FileErrors []*ImportError `json:"fileErrors,omitempty"` + + // FileName: The name of the file. + FileName string `json:"fileName,omitempty"` + + // PartialReport: Flag indicating that processing was aborted due to + // maximum number of errors. + PartialReport bool `json:"partialReport,omitempty"` + + // RowErrors: Partial list of rows that encountered validation error. + RowErrors []*ImportRowError `json:"rowErrors,omitempty"` + + // ForceSendFields is a list of field names (e.g. "FileErrors") 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. "FileErrors") 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 *FileValidationReport) MarshalJSON() ([]byte, error) { + type NoMethod FileValidationReport + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + +// Frames: Collection of frame data. +type Frames struct { + // FramesData: A repeated field of asset data. + FramesData []*AssetFrame `json:"framesData,omitempty"` + + // ForceSendFields is a list of field names (e.g. "FramesData") 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. "FramesData") 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 *Frames) MarshalJSON() ([]byte, error) { + type NoMethod Frames + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + +// FstabEntry: Single fstab entry. +type FstabEntry struct { + // File: The mount point for the filesystem. + File string `json:"file,omitempty"` + + // Freq: Used by dump to determine which filesystems need to be dumped. + Freq int64 `json:"freq,omitempty"` + + // Mntops: Mount options associated with the filesystem. + Mntops string `json:"mntops,omitempty"` + + // Passno: Used by the fsck(8) program to determine the order in which + // filesystem checks are done at reboot time. + Passno int64 `json:"passno,omitempty"` + + // Spec: The block special device or remote filesystem to be mounted. + Spec string `json:"spec,omitempty"` + + // Vfstype: The type of the filesystem. + Vfstype string `json:"vfstype,omitempty"` + + // ForceSendFields is a list of field names (e.g. "File") 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. "File") 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 *FstabEntry) MarshalJSON() ([]byte, error) { + type NoMethod FstabEntry + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + +// FstabEntryList: Fstab content. +type FstabEntryList struct { + // Entries: Fstab entries. + Entries []*FstabEntry `json:"entries,omitempty"` + + // ForceSendFields is a list of field names (e.g. "Entries") 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. "Entries") 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 *FstabEntryList) MarshalJSON() ([]byte, error) { + type NoMethod FstabEntryList + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + +// GCSPayloadInfo: A resource that represents a payload hosted on Google +// Cloud Storage. +type GCSPayloadInfo struct { + // Format: The import job format. + // + // Possible values: + // "IMPORT_JOB_FORMAT_UNSPECIFIED" - Default value. + // "IMPORT_JOB_FORMAT_CMDB" - Configuration management DB format. + // "IMPORT_JOB_FORMAT_RVTOOLS_XLSX" - RVTools format (XLSX). + // "IMPORT_JOB_FORMAT_RVTOOLS_CSV" - RVTools format (CSV). + // "IMPORT_JOB_FORMAT_JSON_FRAME" - `AssetFrame` list in JSON format. + Format string `json:"format,omitempty"` + + // Path: The payload path in Google Cloud Storage. + Path string `json:"path,omitempty"` + + // ForceSendFields is a list of field names (e.g. "Format") 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. "Format") 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 *GCSPayloadInfo) MarshalJSON() ([]byte, error) { + type NoMethod GCSPayloadInfo + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + +// GuestConfigDetails: Guest OS config information. +type GuestConfigDetails struct { + // Fstab: Mount list (Linux fstab). + Fstab *FstabEntryList `json:"fstab,omitempty"` + + // Hosts: Hosts file (/etc/hosts). + Hosts *HostsEntryList `json:"hosts,omitempty"` + + // Issue: OS issue (typically /etc/issue in Linux). + Issue string `json:"issue,omitempty"` + + // NfsExports: NFS exports. + NfsExports *NfsExportList `json:"nfsExports,omitempty"` + + // Selinux: SELinux details. + Selinux *Selinux `json:"selinux,omitempty"` + + // ForceSendFields is a list of field names (e.g. "Fstab") 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. "Fstab") 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 *GuestConfigDetails) MarshalJSON() ([]byte, error) { + type NoMethod GuestConfigDetails + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + +// GuestInstalledApplication: Guest installed application information. +type GuestInstalledApplication struct { + // Name: Installed application name . + Name string `json:"name,omitempty"` + + // Path: Source path. + Path string `json:"path,omitempty"` + + // Time: Date application was installed. + Time string `json:"time,omitempty"` + + // Vendor: Installed application vendor. + Vendor string `json:"vendor,omitempty"` + + // Version: Installed application version. + Version string `json:"version,omitempty"` + + // ForceSendFields is a list of field names (e.g. "Name") 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. "Name") 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 *GuestInstalledApplication) MarshalJSON() ([]byte, error) { + type NoMethod GuestInstalledApplication + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + +// GuestInstalledApplicationList: Guest installed application list. +type GuestInstalledApplicationList struct { + Entries []*GuestInstalledApplication `json:"entries,omitempty"` + + // ForceSendFields is a list of field names (e.g. "Entries") 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. "Entries") 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 *GuestInstalledApplicationList) MarshalJSON() ([]byte, error) { + type NoMethod GuestInstalledApplicationList + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + +// GuestOsDetails: Information from Guest-level collections. +type GuestOsDetails struct { + // Config: OS and app configuration. + Config *GuestConfigDetails `json:"config,omitempty"` + + // Runtime: Runtime information. + Runtime *GuestRuntimeDetails `json:"runtime,omitempty"` + + // ForceSendFields is a list of field names (e.g. "Config") 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. "Config") 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 *GuestOsDetails) MarshalJSON() ([]byte, error) { + type NoMethod GuestOsDetails + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + +// GuestRuntimeDetails: Guest OS runtime information. +type GuestRuntimeDetails struct { + // Domain: Domain, e.g. c.stratozone-development.internal. + Domain string `json:"domain,omitempty"` + + // InstalledApps: Installed applications information. + InstalledApps *GuestInstalledApplicationList `json:"installedApps,omitempty"` + + // LastUptime: Date since last booted (last uptime date). + LastUptime *Date `json:"lastUptime,omitempty"` + + // MachineName: Machine name. + MachineName string `json:"machineName,omitempty"` + + // NetworkInfo: Runtime network information (connections ports). + NetworkInfo *RuntimeNetworkInfo `json:"networkInfo,omitempty"` + + // OpenFileList: Open files information. + OpenFileList *OpenFileList `json:"openFileList,omitempty"` + + // Processes: Running processes. + Processes *RunningProcessList `json:"processes,omitempty"` + + // Services: Running background services. + Services *RunningServiceList `json:"services,omitempty"` + + // ForceSendFields is a list of field names (e.g. "Domain") 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. "Domain") 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 *GuestRuntimeDetails) MarshalJSON() ([]byte, error) { + type NoMethod GuestRuntimeDetails + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + +// HostsEntry: Single /etc/hosts entry. +type HostsEntry struct { + // HostNames: List of host names / aliases. + HostNames []string `json:"hostNames,omitempty"` + + // Ip: IP (raw, IPv4/6 agnostic). + Ip string `json:"ip,omitempty"` + + // ForceSendFields is a list of field names (e.g. "HostNames") 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. "HostNames") 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 *HostsEntry) MarshalJSON() ([]byte, error) { + type NoMethod HostsEntry + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + +// HostsEntryList: Hosts content. +type HostsEntryList struct { + // Entries: Hosts entries. + Entries []*HostsEntry `json:"entries,omitempty"` + + // ForceSendFields is a list of field names (e.g. "Entries") 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. "Entries") 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 *HostsEntryList) MarshalJSON() ([]byte, error) { + type NoMethod HostsEntryList + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + +// ImportError: A resource that reports the errors encountered while +// processing an import job. +type ImportError struct { + // ErrorDetails: The error information. + ErrorDetails string `json:"errorDetails,omitempty"` + + // Severity: The severity of the error. + // + // Possible values: + // "SEVERITY_UNSPECIFIED" + // "ERROR" + // "WARNING" + // "INFO" + Severity string `json:"severity,omitempty"` + + // ForceSendFields is a list of field names (e.g. "ErrorDetails") 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. "ErrorDetails") 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 *ImportError) MarshalJSON() ([]byte, error) { + type NoMethod ImportError + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + +// ImportJob: A resource that represents the background job that imports +// asset frames. +type ImportJob struct { + // AssetSource: Required. Reference to a source. + AssetSource string `json:"assetSource,omitempty"` + + // CompleteTime: Output only. The timestamp when the import job was + // completed. + CompleteTime string `json:"completeTime,omitempty"` + + // CreateTime: Output only. The timestamp when the import job was + // created. + CreateTime string `json:"createTime,omitempty"` + + // ExecutionReport: Output only. The report with the results of running + // the import job. + ExecutionReport *ExecutionReport `json:"executionReport,omitempty"` + + // GcsPayload: The payload is in Google Cloud Storage. + GcsPayload *GCSPayloadInfo `json:"gcsPayload,omitempty"` + + // InlinePayload: The payload is included in the request, mainly used + // for small import jobs. + InlinePayload *InlinePayloadInfo `json:"inlinePayload,omitempty"` + + // Labels: Labels as key value pairs. + Labels map[string]string `json:"labels,omitempty"` + + // Name: Output only. The full name of the import job. + Name string `json:"name,omitempty"` + + // State: Output only. The state of the import job. + // + // Possible values: + // "IMPORT_JOB_STATE_UNSPECIFIED" - Default value. + // "IMPORT_JOB_STATE_PENDING" - The import job is pending. + // "IMPORT_JOB_STATE_RUNNING" - The processing of the import job is + // ongoing. + // "IMPORT_JOB_STATE_COMPLETED" - The import job processing has + // completed. + // "IMPORT_JOB_STATE_FAILED" - The import job failed to be processed. + // "IMPORT_JOB_STATE_VALIDATING" - The import job is being validated. + // "IMPORT_JOB_STATE_FAILED_VALIDATION" - The import job contains + // blocking errors. + // "IMPORT_JOB_STATE_READY" - The validation of the job completed with + // no blocking errors. + State string `json:"state,omitempty"` + + // UpdateTime: Output only. The timestamp when the import job was last + // updated. + UpdateTime string `json:"updateTime,omitempty"` + + // ValidationReport: Output only. The report with the validation results + // of the import job. + ValidationReport *ValidationReport `json:"validationReport,omitempty"` + + // ServerResponse contains the HTTP response code and headers from the + // server. + googleapi.ServerResponse `json:"-"` + + // ForceSendFields is a list of field names (e.g. "AssetSource") 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. "AssetSource") 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 *ImportJob) MarshalJSON() ([]byte, error) { + type NoMethod ImportJob + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + +// ImportRowError: A resource that reports the import job errors at row +// level. +type ImportRowError struct { + // Errors: The list of errors detected in the row. + Errors []*ImportError `json:"errors,omitempty"` + + // RowNumber: The row number where the error was detected. + RowNumber int64 `json:"rowNumber,omitempty"` + + // VmName: The name of the VM in the row. + VmName string `json:"vmName,omitempty"` + + // VmUuid: The VM UUID. + VmUuid string `json:"vmUuid,omitempty"` + + // ForceSendFields is a list of field names (e.g. "Errors") 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. "Errors") 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 *ImportRowError) MarshalJSON() ([]byte, error) { + type NoMethod ImportRowError + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + +// InlinePayloadInfo: A resource that represents the inline import job +// payload. +type InlinePayloadInfo struct { + // Format: The import job format. + // + // Possible values: + // "IMPORT_JOB_FORMAT_UNSPECIFIED" - Default value. + // "IMPORT_JOB_FORMAT_CMDB" - Configuration management DB format. + // "IMPORT_JOB_FORMAT_RVTOOLS_XLSX" - RVTools format (XLSX). + // "IMPORT_JOB_FORMAT_RVTOOLS_CSV" - RVTools format (CSV). + // "IMPORT_JOB_FORMAT_JSON_FRAME" - `AssetFrame` list in JSON format. + Format string `json:"format,omitempty"` + + // Payload: List of payload files. + Payload []*PayloadFile `json:"payload,omitempty"` + + // ForceSendFields is a list of field names (e.g. "Format") 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. "Format") 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 *InlinePayloadInfo) MarshalJSON() ([]byte, error) { + type NoMethod InlinePayloadInfo + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + +// ListAssetsResponse: Response message for listing assets. +type ListAssetsResponse struct { + // Assets: A list of assets. + Assets []*Asset `json:"assets,omitempty"` + + // NextPageToken: A token identifying a page of results the server + // should return. + NextPageToken string `json:"nextPageToken,omitempty"` + + // Unreachable: Locations that could not be reached. + Unreachable []string `json:"unreachable,omitempty"` + + // ServerResponse contains the HTTP response code and headers from the + // server. + googleapi.ServerResponse `json:"-"` + + // ForceSendFields is a list of field names (e.g. "Assets") 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. "Assets") 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 *ListAssetsResponse) MarshalJSON() ([]byte, error) { + type NoMethod ListAssetsResponse + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + +// ListImportJobsResponse: A response for listing import jobs. +type ListImportJobsResponse struct { + // ImportJobs: The list of import jobs. + ImportJobs []*ImportJob `json:"importJobs,omitempty"` + + // NextPageToken: A token identifying a page of results the server + // should return. + NextPageToken string `json:"nextPageToken,omitempty"` + + // Unreachable: Locations that could not be reached. + Unreachable []string `json:"unreachable,omitempty"` + + // ServerResponse contains the HTTP response code and headers from the + // server. + googleapi.ServerResponse `json:"-"` + + // ForceSendFields is a list of field names (e.g. "ImportJobs") 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. "ImportJobs") 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 *ListImportJobsResponse) MarshalJSON() ([]byte, error) { + type NoMethod ListImportJobsResponse + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + +// ListLocationsResponse: The response message for +// Locations.ListLocations. +type ListLocationsResponse struct { + // Locations: A list of locations that matches the specified filter in + // the request. + Locations []*Location `json:"locations,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. "Locations") 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. "Locations") 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 *ListLocationsResponse) MarshalJSON() ([]byte, error) { + type NoMethod ListLocationsResponse + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + +// ListOperationsResponse: The response message for +// Operations.ListOperations. +type ListOperationsResponse struct { + // NextPageToken: The standard List next-page token. + NextPageToken string `json:"nextPageToken,omitempty"` + + // Operations: A list of operations that matches the specified filter in + // the request. + Operations []*Operation `json:"operations,omitempty"` + + // ServerResponse contains the HTTP response code and headers from the + // server. + googleapi.ServerResponse `json:"-"` + + // ForceSendFields is a list of field names (e.g. "NextPageToken") 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. "NextPageToken") 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 *ListOperationsResponse) MarshalJSON() ([]byte, error) { + type NoMethod ListOperationsResponse + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + +// ListSourcesResponse: Response message for listing sources. +type ListSourcesResponse struct { + // NextPageToken: A token identifying a page of results the server + // should return. + NextPageToken string `json:"nextPageToken,omitempty"` + + // Sources: The list of sources. + Sources []*Source `json:"sources,omitempty"` + + // Unreachable: Locations that could not be reached. + Unreachable []string `json:"unreachable,omitempty"` + + // ServerResponse contains the HTTP response code and headers from the + // server. + googleapi.ServerResponse `json:"-"` + + // ForceSendFields is a list of field names (e.g. "NextPageToken") 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. "NextPageToken") 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 *ListSourcesResponse) MarshalJSON() ([]byte, error) { + type NoMethod ListSourcesResponse + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + +// Location: A resource that represents Google Cloud Platform location. +type Location struct { + // DisplayName: The friendly name for this location, typically a nearby + // city name. For example, "Tokyo". + DisplayName string `json:"displayName,omitempty"` + + // Labels: Cross-service attributes for the location. For example + // {"cloud.googleapis.com/region": "us-east1"} + Labels map[string]string `json:"labels,omitempty"` + + // LocationId: The canonical id for this location. For example: + // "us-east1". + LocationId string `json:"locationId,omitempty"` + + // Metadata: Service-specific metadata. For example the available + // capacity at the given location. + Metadata googleapi.RawMessage `json:"metadata,omitempty"` + + // Name: Resource name for the location, which may vary between + // implementations. For example: + // "projects/example-project/locations/us-east1" + Name string `json:"name,omitempty"` + + // ServerResponse contains the HTTP response code and headers from the + // server. + googleapi.ServerResponse `json:"-"` + + // ForceSendFields is a list of field names (e.g. "DisplayName") 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. "DisplayName") 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 *Location) MarshalJSON() ([]byte, error) { + type NoMethod Location + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + +// MemoryUsageSample: Memory usage sample. +type MemoryUsageSample struct { + // UtilizedPercentage: Percentage of system memory utilized. Must be in + // the interval [0, 100]. + UtilizedPercentage float64 `json:"utilizedPercentage,omitempty"` + + // ForceSendFields is a list of field names (e.g. "UtilizedPercentage") + // 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. "UtilizedPercentage") 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 *MemoryUsageSample) MarshalJSON() ([]byte, error) { + type NoMethod MemoryUsageSample + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + +func (s *MemoryUsageSample) UnmarshalJSON(data []byte) error { + type NoMethod MemoryUsageSample + var s1 struct { + UtilizedPercentage gensupport.JSONFloat64 `json:"utilizedPercentage"` + *NoMethod + } + s1.NoMethod = (*NoMethod)(s) + if err := json.Unmarshal(data, &s1); err != nil { + return err + } + s.UtilizedPercentage = float64(s1.UtilizedPercentage) + return nil +} + +// NetworkAdapterDetails: Details of network adapter. +type NetworkAdapterDetails struct { + // AdapterType: Network adapter type (e.g. VMXNET3). + AdapterType string `json:"adapterType,omitempty"` + + // Addresses: NetworkAddressList + Addresses *NetworkAddressList `json:"addresses,omitempty"` + + // MacAddress: MAC address. + MacAddress string `json:"macAddress,omitempty"` + + // ForceSendFields is a list of field names (e.g. "AdapterType") 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. "AdapterType") 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 *NetworkAdapterDetails) MarshalJSON() ([]byte, error) { + type NoMethod NetworkAdapterDetails + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + +type NetworkAdapterList struct { + // NetworkAdapters: Network Adapter descriptions. + NetworkAdapters []*NetworkAdapterDetails `json:"networkAdapters,omitempty"` + + // ForceSendFields is a list of field names (e.g. "NetworkAdapters") 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. "NetworkAdapters") 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 *NetworkAdapterList) MarshalJSON() ([]byte, error) { + type NoMethod NetworkAdapterList + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + +// NetworkAddress: Details of network address. +type NetworkAddress struct { + // Assignment: If DHCP is used to assign addresses. + // + // Possible values: + // "ADDRESS_ASSIGNMENT_UNSPECIFIED" - Unknown (default value). + // "ADDRESS_ASSIGNMENT_STATIC" - Staticly assigned IP. + // "ADDRESS_ASSIGNMENT_DHCP" - Dynamically assigned IP (DHCP). + Assignment string `json:"assignment,omitempty"` + + // Bcast: Broadcast address. + Bcast string `json:"bcast,omitempty"` + + // Fqdn: Fully qualified domain name. + Fqdn string `json:"fqdn,omitempty"` + + // IpAddress: Assigned or configured IP Address. + IpAddress string `json:"ipAddress,omitempty"` + + // SubnetMask: Subnet mask. + SubnetMask string `json:"subnetMask,omitempty"` + + // ForceSendFields is a list of field names (e.g. "Assignment") 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. "Assignment") 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 *NetworkAddress) MarshalJSON() ([]byte, error) { + type NoMethod NetworkAddress + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + +// NetworkAddressList: List of allocated/assigned network addresses. +type NetworkAddressList struct { + Addresses []*NetworkAddress `json:"addresses,omitempty"` + + // ForceSendFields is a list of field names (e.g. "Addresses") 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. "Addresses") 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 *NetworkAddressList) MarshalJSON() ([]byte, error) { + type NoMethod NetworkAddressList + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + +type NetworkConnection struct { + // LocalIpAddress: Local IP address. + LocalIpAddress string `json:"localIpAddress,omitempty"` + + // LocalPort: Local port. + LocalPort int64 `json:"localPort,omitempty"` + + // Pid: Process ID. + Pid int64 `json:"pid,omitempty,string"` + + // ProcessName: Process or service name. + ProcessName string `json:"processName,omitempty"` + + // Protocol: Connection protocol (e.g. TCP/UDP). + Protocol string `json:"protocol,omitempty"` + + // RemoteIpAddress: Remote IP address. + RemoteIpAddress string `json:"remoteIpAddress,omitempty"` + + // RemotePort: Remote port. + RemotePort int64 `json:"remotePort,omitempty"` + + // State: Connection state (e.g. CONNECTED). + State string `json:"state,omitempty"` + + // ForceSendFields is a list of field names (e.g. "LocalIpAddress") 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. "LocalIpAddress") 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 *NetworkConnection) MarshalJSON() ([]byte, error) { + type NoMethod NetworkConnection + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + +// NetworkConnectionList: Network connection list. +type NetworkConnectionList struct { + Entries []*NetworkConnection `json:"entries,omitempty"` + + // ForceSendFields is a list of field names (e.g. "Entries") 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. "Entries") 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 *NetworkConnectionList) MarshalJSON() ([]byte, error) { + type NoMethod NetworkConnectionList + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + +// NetworkUsageSample: Network usage sample. Values are across all +// network interfaces. +type NetworkUsageSample struct { + // AverageEgressBps: Average network egress in B/s sampled over a short + // window. Must be non-negative. + AverageEgressBps float64 `json:"averageEgressBps,omitempty"` + + // AverageIngressBps: Average network ingress in B/s sampled over a + // short window. Must be non-negative. + AverageIngressBps float64 `json:"averageIngressBps,omitempty"` + + // ForceSendFields is a list of field names (e.g. "AverageEgressBps") 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. "AverageEgressBps") 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 *NetworkUsageSample) MarshalJSON() ([]byte, error) { + type NoMethod NetworkUsageSample + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + +func (s *NetworkUsageSample) UnmarshalJSON(data []byte) error { + type NoMethod NetworkUsageSample + var s1 struct { + AverageEgressBps gensupport.JSONFloat64 `json:"averageEgressBps"` + AverageIngressBps gensupport.JSONFloat64 `json:"averageIngressBps"` + *NoMethod + } + s1.NoMethod = (*NoMethod)(s) + if err := json.Unmarshal(data, &s1); err != nil { + return err + } + s.AverageEgressBps = float64(s1.AverageEgressBps) + s.AverageIngressBps = float64(s1.AverageIngressBps) + return nil +} + +// NfsExport: NFS export. +type NfsExport struct { + // ExportDirectory: The directory being exported. + ExportDirectory string `json:"exportDirectory,omitempty"` + + // Hosts: The hosts or networks to which the export is being shared. + Hosts []string `json:"hosts,omitempty"` + + // ForceSendFields is a list of field names (e.g. "ExportDirectory") 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. "ExportDirectory") 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 *NfsExport) MarshalJSON() ([]byte, error) { + type NoMethod NfsExport + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + +// NfsExportList: NFS exports. +type NfsExportList struct { + // Entries: NFS export entries. + Entries []*NfsExport `json:"entries,omitempty"` + + // ForceSendFields is a list of field names (e.g. "Entries") 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. "Entries") 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 *NfsExportList) MarshalJSON() ([]byte, error) { + type NoMethod NfsExportList + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + +// OpenFileDetails: Open file Information. +type OpenFileDetails struct { + // Command: Opened file command. + Command string `json:"command,omitempty"` + + // FilePath: Opened file file path. + FilePath string `json:"filePath,omitempty"` + + // FileType: Opened file file type. + FileType string `json:"fileType,omitempty"` + + // User: Opened file user. + User string `json:"user,omitempty"` + + // ForceSendFields is a list of field names (e.g. "Command") 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. "Command") 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 *OpenFileDetails) MarshalJSON() ([]byte, error) { + type NoMethod OpenFileDetails + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + +// OpenFileList: Open file list. +type OpenFileList struct { + // Entries: Open file details entries. + Entries []*OpenFileDetails `json:"entries,omitempty"` + + // ForceSendFields is a list of field names (e.g. "Entries") 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. "Entries") 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 *OpenFileList) MarshalJSON() ([]byte, error) { + type NoMethod OpenFileList + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + +// Operation: This resource represents a long-running operation that is +// the result of a network API call. +type Operation struct { + // Done: If the value is `false`, it means the operation is still in + // progress. If `true`, the operation is completed, and either `error` + // or `response` is available. + Done bool `json:"done,omitempty"` + + // Error: The error result of the operation in case of failure or + // cancellation. + Error *Status `json:"error,omitempty"` + + // Metadata: Service-specific metadata associated with the operation. It + // typically contains progress information and common metadata such as + // create time. Some services might not provide such metadata. Any + // method that returns a long-running operation should document the + // metadata type, if any. + Metadata googleapi.RawMessage `json:"metadata,omitempty"` + + // Name: The server-assigned name, which is only unique within the same + // service that originally returns it. If you use the default HTTP + // mapping, the `name` should be a resource name ending with + // `operations/{unique_id}`. + Name string `json:"name,omitempty"` + + // Response: The normal response of the operation in case of success. If + // the original method returns no data on success, such as `Delete`, the + // response is `google.protobuf.Empty`. If the original method is + // standard `Get`/`Create`/`Update`, the response should be the + // resource. For other methods, the response should have the type + // `XxxResponse`, where `Xxx` is the original method name. For example, + // if the original method name is `TakeSnapshot()`, the inferred + // response type is `TakeSnapshotResponse`. + Response googleapi.RawMessage `json:"response,omitempty"` + + // ServerResponse contains the HTTP response code and headers from the + // server. + googleapi.ServerResponse `json:"-"` + + // ForceSendFields is a list of field names (e.g. "Done") 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. "Done") 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 *Operation) MarshalJSON() ([]byte, error) { + type NoMethod Operation + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + +// OperationMetadata: Represents the metadata of the long-running +// operation. +type OperationMetadata struct { + // ApiVersion: Output only. API version used to start the operation. + ApiVersion string `json:"apiVersion,omitempty"` + + // CreateTime: Output only. The time the operation was created. + CreateTime string `json:"createTime,omitempty"` + + // EndTime: Output only. The time the operation finished running. + EndTime string `json:"endTime,omitempty"` + + // RequestedCancellation: Output only. Identifies whether the user has + // requested cancellation of the operation. Operations that have been + // cancelled successfully have Operation.error value with a + // google.rpc.Status.code of 1, corresponding to `Code.CANCELLED`. + RequestedCancellation bool `json:"requestedCancellation,omitempty"` + + // StatusMessage: Output only. Human-readable status of the operation, + // if any. + StatusMessage string `json:"statusMessage,omitempty"` + + // Target: Output only. Server-defined resource path for the target of + // the operation. + Target string `json:"target,omitempty"` + + // Verb: Output only. Name of the verb executed by the operation. + Verb string `json:"verb,omitempty"` + + // ForceSendFields is a list of field names (e.g. "ApiVersion") 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. "ApiVersion") 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 *OperationMetadata) MarshalJSON() ([]byte, error) { + type NoMethod OperationMetadata + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + +// PayloadFile: Payload file for inline import job payload. +type PayloadFile struct { + // Data: The file data. + Data string `json:"data,omitempty"` + + // Name: The file name. + Name string `json:"name,omitempty"` + + // ForceSendFields is a list of field names (e.g. "Data") 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. "Data") 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 *PayloadFile) MarshalJSON() ([]byte, error) { + type NoMethod PayloadFile + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + +// PerformanceSample: Performance data sample. +type PerformanceSample struct { + // Cpu: CPU usage sample. + Cpu *CpuUsageSample `json:"cpu,omitempty"` + + // Disk: Disk usage sample. + Disk *DiskUsageSample `json:"disk,omitempty"` + + // Memory: Memory usage sample. + Memory *MemoryUsageSample `json:"memory,omitempty"` + + // Network: Network usage sample. + Network *NetworkUsageSample `json:"network,omitempty"` + + // SampleTime: Time the sample was collected. + SampleTime string `json:"sampleTime,omitempty"` + + // ForceSendFields is a list of field names (e.g. "Cpu") 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. "Cpu") 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 *PerformanceSample) MarshalJSON() ([]byte, error) { + type NoMethod PerformanceSample + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + +// PlatformDetails: Information about the platform. +type PlatformDetails struct { + // VmwareDetails: VMware specific details. + VmwareDetails *VmwarePlatformDetails `json:"vmwareDetails,omitempty"` + + // ForceSendFields is a list of field names (e.g. "VmwareDetails") 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. "VmwareDetails") 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 *PlatformDetails) MarshalJSON() ([]byte, error) { + type NoMethod PlatformDetails + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + +// ReportAssetFramesResponse: A response to a call to +// `ReportAssetFrame`. +type ReportAssetFramesResponse struct { + // ServerResponse contains the HTTP response code and headers from the + // server. + googleapi.ServerResponse `json:"-"` +} + +// RunImportJobRequest: A request to run an import job. +type RunImportJobRequest struct { + // RequestId: Optional. An optional request ID to identify requests. + // Specify a unique request ID so that if you must retry your request, + // the server will know to ignore the request if it has already been + // completed. The server will guarantee that for at least 60 minutes + // after the first request. For example, consider a situation where you + // make an initial request and the request times out. If you make the + // request again with the same request ID, the server can check if + // original operation with the same request ID was received, and if so, + // will ignore the second request. This prevents clients from + // accidentally creating duplicate commitments. The request ID must be a + // valid UUID with the exception that zero UUID is not supported + // (00000000-0000-0000-0000-000000000000). + RequestId string `json:"requestId,omitempty"` + + // ForceSendFields is a list of field names (e.g. "RequestId") 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. "RequestId") 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 *RunImportJobRequest) MarshalJSON() ([]byte, error) { + type NoMethod RunImportJobRequest + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + +// RunningProcess: Guest OS running process details. +type RunningProcess struct { + // Attributes: Process extended attributes. + Attributes map[string]string `json:"attributes,omitempty"` + + // Cmdline: Process full command line. + Cmdline string `json:"cmdline,omitempty"` + + // ExePath: Process binary path. + ExePath string `json:"exePath,omitempty"` + + // Pid: Process ID. + Pid int64 `json:"pid,omitempty,string"` + + // User: User running the process. + User string `json:"user,omitempty"` + + // ForceSendFields is a list of field names (e.g. "Attributes") 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. "Attributes") 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 *RunningProcess) MarshalJSON() ([]byte, error) { + type NoMethod RunningProcess + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + +// RunningProcessList: List of running guest OS processes. +type RunningProcessList struct { + Processes []*RunningProcess `json:"processes,omitempty"` + + // ForceSendFields is a list of field names (e.g. "Processes") 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. "Processes") 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 *RunningProcessList) MarshalJSON() ([]byte, error) { + type NoMethod RunningProcessList + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + +// RunningService: Guest OS running service details. +type RunningService struct { + // Cmdline: Service command line. + Cmdline string `json:"cmdline,omitempty"` + + // ExePath: Service binary path. + ExePath string `json:"exePath,omitempty"` + + // Name: Service name. + Name string `json:"name,omitempty"` + + // Pid: Service pid. + Pid int64 `json:"pid,omitempty,string"` + + // StartMode: Service start mode (raw, OS-agnostic). + StartMode string `json:"startMode,omitempty"` + + // State: Service state (raw, OS-agnostic). + State string `json:"state,omitempty"` + + // Status: Service status. + Status string `json:"status,omitempty"` + + // ForceSendFields is a list of field names (e.g. "Cmdline") 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. "Cmdline") 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 *RunningService) MarshalJSON() ([]byte, error) { + type NoMethod RunningService + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + +// RunningServiceList: List of running guest OS services. +type RunningServiceList struct { + Services []*RunningService `json:"services,omitempty"` + + // ForceSendFields is a list of field names (e.g. "Services") 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. "Services") 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 *RunningServiceList) MarshalJSON() ([]byte, error) { + type NoMethod RunningServiceList + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + +// RuntimeNetworkInfo: Runtime networking information. +type RuntimeNetworkInfo struct { + // Connections: Network connections. + Connections *NetworkConnectionList `json:"connections,omitempty"` + + // Netstat: Netstat (raw, OS-agnostic). + Netstat string `json:"netstat,omitempty"` + + // NetstatTime: Netstat time collected. + NetstatTime *DateTime `json:"netstatTime,omitempty"` + + // ForceSendFields is a list of field names (e.g. "Connections") 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. "Connections") 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 *RuntimeNetworkInfo) MarshalJSON() ([]byte, error) { + type NoMethod RuntimeNetworkInfo + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + +// Selinux: SELinux details. +type Selinux struct { + // Enabled: Is SELinux enabled. + Enabled bool `json:"enabled,omitempty"` + + // Mode: SELinux mode enforcing / permissive. + Mode string `json:"mode,omitempty"` + + // ForceSendFields is a list of field names (e.g. "Enabled") 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. "Enabled") 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 *Selinux) MarshalJSON() ([]byte, error) { + type NoMethod Selinux + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + +// Source: Source represents an object from which asset information is +// streamed to Migration Center. +type Source struct { + // CreateTime: Output only. The timestamp when the source was created. + CreateTime string `json:"createTime,omitempty"` + + // Description: Free-text description. + Description string `json:"description,omitempty"` + + // DisplayName: User-friendly display name. + DisplayName string `json:"displayName,omitempty"` + + // IsManaged: If `true`, the source is managed by other service(s). + IsManaged bool `json:"isManaged,omitempty"` + + // Name: Output only. The full name of the source. + Name string `json:"name,omitempty"` + + // PendingFrameCount: Output only. Number of frames that are still being + // processed. + PendingFrameCount int64 `json:"pendingFrameCount,omitempty"` + + // Priority: The information confidence of the source. The higher the + // value, the higher the confidence. + Priority int64 `json:"priority,omitempty"` + + // Type: Data source type. + // + // Possible values: + // "SOURCE_TYPE_UNKNOWN" - Unspecified + // "SOURCE_TYPE_UPLOAD" - Manually uploaded file (e.g. CSV) + // "SOURCE_TYPE_GUEST_OS_SCAN" - Guest-level info + // "SOURCE_TYPE_INVENTORY_SCAN" - Inventory-level scan + // "SOURCE_TYPE_CUSTOM" - Third-party owned sources. + Type string `json:"type,omitempty"` + + // UpdateTime: Output only. The timestamp when the source 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. "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 *Source) MarshalJSON() ([]byte, error) { + type NoMethod Source + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + +// Status: The `Status` type defines a logical error model that is +// suitable for different programming environments, including REST APIs +// and RPC APIs. It is used by gRPC (https://github.com/grpc). Each +// `Status` message contains three pieces of data: error code, error +// message, and error details. You can find out more about this error +// model and how to work with it in the API Design Guide +// (https://cloud.google.com/apis/design/errors). +type Status struct { + // Code: The status code, which should be an enum value of + // google.rpc.Code. + Code int64 `json:"code,omitempty"` + + // Details: A list of messages that carry the error details. There is a + // common set of message types for APIs to use. + Details []googleapi.RawMessage `json:"details,omitempty"` + + // Message: A developer-facing error message, which should be in + // English. Any user-facing error message should be localized and sent + // in the google.rpc.Status.details field, or localized by the client. + Message string `json:"message,omitempty"` + + // ForceSendFields is a list of field names (e.g. "Code") 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. "Code") 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 *Status) MarshalJSON() ([]byte, error) { + type NoMethod Status + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + +// TimeZone: Represents a time zone from the IANA Time Zone Database +// (https://www.iana.org/time-zones). +type TimeZone struct { + // Id: IANA Time Zone Database time zone, e.g. "America/New_York". + Id string `json:"id,omitempty"` + + // Version: Optional. IANA Time Zone Database version number, e.g. + // "2019a". + Version string `json:"version,omitempty"` + + // ForceSendFields is a list of field names (e.g. "Id") 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. "Id") 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 *TimeZone) MarshalJSON() ([]byte, error) { + type NoMethod TimeZone + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + +// ValidateImportJobRequest: A request to validate an import job. +type ValidateImportJobRequest struct { + // RequestId: Optional. An optional request ID to identify requests. + // Specify a unique request ID so that if you must retry your request, + // the server will know to ignore the request if it has already been + // completed. The server will guarantee that for at least 60 minutes + // after the first request. For example, consider a situation where you + // make an initial request and the request times out. If you make the + // request again with the same request ID, the server can check if + // original operation with the same request ID was received, and if so, + // will ignore the second request. This prevents clients from + // accidentally creating duplicate commitments. The request ID must be a + // valid UUID with the exception that zero UUID is not supported + // (00000000-0000-0000-0000-000000000000). + RequestId string `json:"requestId,omitempty"` + + // ForceSendFields is a list of field names (e.g. "RequestId") 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. "RequestId") 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 *ValidateImportJobRequest) MarshalJSON() ([]byte, error) { + type NoMethod ValidateImportJobRequest + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + +// ValidationReport: A resource that aggregates errors across import job +// files. +type ValidationReport struct { + // FileValidations: List of errors found in files. + FileValidations []*FileValidationReport `json:"fileValidations,omitempty"` + + // JobErrors: List of job level errors. + JobErrors []*ImportError `json:"jobErrors,omitempty"` + + // ForceSendFields is a list of field names (e.g. "FileValidations") 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. "FileValidations") 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 *ValidationReport) MarshalJSON() ([]byte, error) { + type NoMethod ValidationReport + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + +// VirtualMachineArchitectureDetails: Details of the VM architecture. +type VirtualMachineArchitectureDetails struct { + // Bios: Bios Details. + Bios *BiosDetails `json:"bios,omitempty"` + + // CpuArchitecture: CPU architecture e.g.: "x64-based PC", "x86_64", + // "i686" etc. + CpuArchitecture string `json:"cpuArchitecture,omitempty"` + + // CpuManufacturer: CPU manufacturer e.g.: "Intel", "AMD". + CpuManufacturer string `json:"cpuManufacturer,omitempty"` + + // CpuName: CPU name e.g. "Intel Xeon E5-2690", "AMD EPYC 7571" etc. + CpuName string `json:"cpuName,omitempty"` + + // CpuSocketCount: Number of processor sockets allocated to the machine. + CpuSocketCount int64 `json:"cpuSocketCount,omitempty"` + + // CpuThreadCount: Number of cpu threads allocated to the machine. + CpuThreadCount int64 `json:"cpuThreadCount,omitempty"` + + // Firmware: Firmware (BIOS/efi). + Firmware string `json:"firmware,omitempty"` + + // Hyperthreading: CPU hyperthreading support (inner enum). + // + // Possible values: + // "HYPER_THREADING_UNSPECIFIED" - Unknown (default value). + // "HYPER_THREADING_DISABLED" - Hyperthreading is disabled. + // "HYPER_THREADING_ENABLED" - Hyperthreading is enabled. + Hyperthreading string `json:"hyperthreading,omitempty"` + + // Vendor: Hardware vendor. + Vendor string `json:"vendor,omitempty"` + + // ForceSendFields is a list of field names (e.g. "Bios") 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. "Bios") 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 *VirtualMachineArchitectureDetails) MarshalJSON() ([]byte, error) { + type NoMethod VirtualMachineArchitectureDetails + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + +// VirtualMachineDetails: Details of a VirtualMachine. +type VirtualMachineDetails struct { + // CoreCount: Number of CPU cores in the VirtualMachine. Must be + // non-negative. + CoreCount int64 `json:"coreCount,omitempty"` + + // GuestOs: Guest OS information. + GuestOs *GuestOsDetails `json:"guestOs,omitempty"` + + // MemoryMb: The amount of memory in the VirtualMachine. Must be + // non-negative. + MemoryMb int64 `json:"memoryMb,omitempty"` + + // OsFamily: What family the OS belong to, if known. + // + // Possible values: + // "OS_FAMILY_UNKNOWN" + // "OS_FAMILY_WINDOWS" - Microsoft Windows Server and Desktop + // "OS_FAMILY_LINUX" - Various Linux flavors + // "OS_FAMILY_UNIX" - Non-Linux Unix flavors + OsFamily string `json:"osFamily,omitempty"` + + // OsName: The name of the operating system running on the + // VirtualMachine. + OsName string `json:"osName,omitempty"` + + // Platform: Platform information. + Platform *PlatformDetails `json:"platform,omitempty"` + + // PowerState: Power state of VM (poweredOn or poweredOff). + PowerState string `json:"powerState,omitempty"` + + // VcenterFolder: Folder name in vCenter where asset resides. + VcenterFolder string `json:"vcenterFolder,omitempty"` + + // VcenterUrl: vCenter URL used in collection. + VcenterUrl string `json:"vcenterUrl,omitempty"` + + // VcenterVmId: vCenter VM ID. + VcenterVmId string `json:"vcenterVmId,omitempty"` + + // VmArchitecture: VM architecture details (vendor, cpu arch). + VmArchitecture *VirtualMachineArchitectureDetails `json:"vmArchitecture,omitempty"` + + // VmDisks: VM disk details. + VmDisks *VirtualMachineDiskDetails `json:"vmDisks,omitempty"` + + // VmName: Virtual Machine display name. + VmName string `json:"vmName,omitempty"` + + // VmNetwork: VM network details. + VmNetwork *VirtualMachineNetworkDetails `json:"vmNetwork,omitempty"` + + // VmUuid: Virtual Machine uniqe identifier. + VmUuid string `json:"vmUuid,omitempty"` + + // ForceSendFields is a list of field names (e.g. "CoreCount") 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. "CoreCount") 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 *VirtualMachineDetails) MarshalJSON() ([]byte, error) { + type NoMethod VirtualMachineDetails + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + +// VirtualMachineDiskDetails: Details of VM disks. +type VirtualMachineDiskDetails struct { + // Disks: List of disks. + Disks *DiskEntryList `json:"disks,omitempty"` + + // HddTotalCapacityBytes: Disk total Capacity. + HddTotalCapacityBytes int64 `json:"hddTotalCapacityBytes,omitempty,string"` + + // HddTotalFreeBytes: Total Disk Free Space. + HddTotalFreeBytes int64 `json:"hddTotalFreeBytes,omitempty,string"` + + // LsblkJson: Raw lsblk output in json. + LsblkJson string `json:"lsblkJson,omitempty"` + + // ForceSendFields is a list of field names (e.g. "Disks") 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. "Disks") 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 *VirtualMachineDiskDetails) MarshalJSON() ([]byte, error) { + type NoMethod VirtualMachineDiskDetails + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + +// VirtualMachineNetworkDetails: Details of network adapters and +// settings +type VirtualMachineNetworkDetails struct { + // DefaultGw: Default GW address. Top-level object, will be later + // encriched by full RouteInfo. + DefaultGw string `json:"defaultGw,omitempty"` + + // NetworkAdapters: List of Network Adapters. + NetworkAdapters *NetworkAdapterList `json:"networkAdapters,omitempty"` + + // PrimaryIpAddress: IP Address of the machine. + PrimaryIpAddress string `json:"primaryIpAddress,omitempty"` + + // PrimaryMacAddress: MAC Address of the machine. This property is used + // to uniqly identify the machine. + PrimaryMacAddress string `json:"primaryMacAddress,omitempty"` + + // ForceSendFields is a list of field names (e.g. "DefaultGw") 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. "DefaultGw") 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 *VirtualMachineNetworkDetails) MarshalJSON() ([]byte, error) { + type NoMethod VirtualMachineNetworkDetails + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + +// VmwareDiskConfig: VMware disk config details. +type VmwareDiskConfig struct { + // BackingType: VMDK backing type. + // + // Possible values: + // "BACKING_TYPE_UNSPECIFIED" - Default value. + // "BACKING_TYPE_FLAT_V1" - Flat v1. + // "BACKING_TYPE_FLAT_V2" - Flat v2. + // "BACKING_TYPE_PMEM" - Persistent memory, also known as Non-Volatile + // Memory (NVM). + // "BACKING_TYPE_RDM_V1" - Raw Disk Memory v1. + // "BACKING_TYPE_RDM_V2" - Raw Disk Memory v2. + // "BACKING_TYPE_SESPARSE" - SEsparse is a snapshot format introduced + // in vSphere 5.5 for large disks. + // "BACKING_TYPE_SESPARSE_V1" - SEsparse v1. + // "BACKING_TYPE_SESPARSE_V2" - SEsparse v1. + BackingType string `json:"backingType,omitempty"` + + // RdmCompatibilityMode: RDM compatibility mode. + RdmCompatibilityMode string `json:"rdmCompatibilityMode,omitempty"` + + // Shared: Is VMDK shared with other VMs. + Shared bool `json:"shared,omitempty"` + + // VmdkDiskMode: VMDK disk mode. + VmdkDiskMode string `json:"vmdkDiskMode,omitempty"` + + // ForceSendFields is a list of field names (e.g. "BackingType") 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. "BackingType") 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 *VmwareDiskConfig) MarshalJSON() ([]byte, error) { + type NoMethod VmwareDiskConfig + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + +// VmwarePlatformDetails: VMware specific details. +type VmwarePlatformDetails struct { + // EsxVersion: ESX version. + EsxVersion string `json:"esxVersion,omitempty"` + + // Osid: VMware os enum - + // https://vdc-repo.vmware.com/vmwb-repository/dcr-public/da47f910-60ac-438b-8b9b-6122f4d14524/16b7274a-bf8b-4b4c-a05e-746f2aa93c8c/doc/vim.vm.GuestOsDescriptor.GuestOsIdentifier.html. + Osid string `json:"osid,omitempty"` + + // VcenterVersion: vCenter version. + VcenterVersion string `json:"vcenterVersion,omitempty"` + + // ForceSendFields is a list of field names (e.g. "EsxVersion") 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. "EsxVersion") 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 *VmwarePlatformDetails) MarshalJSON() ([]byte, error) { + type NoMethod VmwarePlatformDetails + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + +// method id "migrationcenter.projects.locations.get": + +type ProjectsLocationsGetCall struct { + s *Service + name string + urlParams_ gensupport.URLParams + ifNoneMatch_ string + ctx_ context.Context + header_ http.Header +} + +// Get: Gets information about a location. +// +// - name: Resource name for the location. +func (r *ProjectsLocationsService) Get(name string) *ProjectsLocationsGetCall { + c := &ProjectsLocationsGetCall{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 *ProjectsLocationsGetCall) Fields(s ...googleapi.Field) *ProjectsLocationsGetCall { + 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 *ProjectsLocationsGetCall) IfNoneMatch(entityTag string) *ProjectsLocationsGetCall { + 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 *ProjectsLocationsGetCall) Context(ctx context.Context) *ProjectsLocationsGetCall { + 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 *ProjectsLocationsGetCall) Header() http.Header { + if c.header_ == nil { + c.header_ = make(http.Header) + } + return c.header_ +} + +func (c *ProjectsLocationsGetCall) 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, "v1alpha1/{+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 "migrationcenter.projects.locations.get" call. +// Exactly one of *Location or error will be non-nil. Any non-2xx status +// code is an error. Response headers are in either +// *Location.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 *ProjectsLocationsGetCall) Do(opts ...googleapi.CallOption) (*Location, 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 := &Location{ + 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 information about a location.", + // "flatPath": "v1alpha1/projects/{projectsId}/locations/{locationsId}", + // "httpMethod": "GET", + // "id": "migrationcenter.projects.locations.get", + // "parameterOrder": [ + // "name" + // ], + // "parameters": { + // "name": { + // "description": "Resource name for the location.", + // "location": "path", + // "pattern": "^projects/[^/]+/locations/[^/]+$", + // "required": true, + // "type": "string" + // } + // }, + // "path": "v1alpha1/{+name}", + // "response": { + // "$ref": "Location" + // }, + // "scopes": [ + // "https://www.googleapis.com/auth/cloud-platform" + // ] + // } + +} + +// method id "migrationcenter.projects.locations.list": + +type ProjectsLocationsListCall struct { + s *Service + name string + urlParams_ gensupport.URLParams + ifNoneMatch_ string + ctx_ context.Context + header_ http.Header +} + +// List: Lists information about the supported locations for this +// service. +// +// - name: The resource that owns the locations collection, if +// applicable. +func (r *ProjectsLocationsService) List(name string) *ProjectsLocationsListCall { + c := &ProjectsLocationsListCall{s: r.s, urlParams_: make(gensupport.URLParams)} + c.name = name + return c +} + +// Filter sets the optional parameter "filter": A filter to narrow down +// results to a preferred subset. The filtering language accepts strings +// like "displayName=tokyo", and is documented in more detail in +// AIP-160 (https://google.aip.dev/160). +func (c *ProjectsLocationsListCall) Filter(filter string) *ProjectsLocationsListCall { + c.urlParams_.Set("filter", filter) + return c +} + +// PageSize sets the optional parameter "pageSize": The maximum number +// of results to return. If not set, the service selects a default. +func (c *ProjectsLocationsListCall) PageSize(pageSize int64) *ProjectsLocationsListCall { + c.urlParams_.Set("pageSize", fmt.Sprint(pageSize)) + return c +} + +// PageToken sets the optional parameter "pageToken": A page token +// received from the `next_page_token` field in the response. Send that +// page token to receive the subsequent page. +func (c *ProjectsLocationsListCall) PageToken(pageToken string) *ProjectsLocationsListCall { + 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 *ProjectsLocationsListCall) Fields(s ...googleapi.Field) *ProjectsLocationsListCall { + 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 *ProjectsLocationsListCall) IfNoneMatch(entityTag string) *ProjectsLocationsListCall { + 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 *ProjectsLocationsListCall) Context(ctx context.Context) *ProjectsLocationsListCall { + 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 *ProjectsLocationsListCall) Header() http.Header { + if c.header_ == nil { + c.header_ = make(http.Header) + } + return c.header_ +} + +func (c *ProjectsLocationsListCall) 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, "v1alpha1/{+name}/locations") + 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 "migrationcenter.projects.locations.list" call. +// Exactly one of *ListLocationsResponse or error will be non-nil. Any +// non-2xx status code is an error. Response headers are in either +// *ListLocationsResponse.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 *ProjectsLocationsListCall) Do(opts ...googleapi.CallOption) (*ListLocationsResponse, 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 := &ListLocationsResponse{ + 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 information about the supported locations for this service.", + // "flatPath": "v1alpha1/projects/{projectsId}/locations", + // "httpMethod": "GET", + // "id": "migrationcenter.projects.locations.list", + // "parameterOrder": [ + // "name" + // ], + // "parameters": { + // "filter": { + // "description": "A filter to narrow down results to a preferred subset. The filtering language accepts strings like `\"displayName=tokyo\"`, and is documented in more detail in [AIP-160](https://google.aip.dev/160).", + // "location": "query", + // "type": "string" + // }, + // "name": { + // "description": "The resource that owns the locations collection, if applicable.", + // "location": "path", + // "pattern": "^projects/[^/]+$", + // "required": true, + // "type": "string" + // }, + // "pageSize": { + // "description": "The maximum number of results to return. If not set, the service selects a default.", + // "format": "int32", + // "location": "query", + // "type": "integer" + // }, + // "pageToken": { + // "description": "A page token received from the `next_page_token` field in the response. Send that page token to receive the subsequent page.", + // "location": "query", + // "type": "string" + // } + // }, + // "path": "v1alpha1/{+name}/locations", + // "response": { + // "$ref": "ListLocationsResponse" + // }, + // "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 *ProjectsLocationsListCall) Pages(ctx context.Context, f func(*ListLocationsResponse) 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 "migrationcenter.projects.locations.assets.aggregateValues": + +type ProjectsLocationsAssetsAggregateValuesCall struct { + s *Service + parent string + aggregateassetsvaluesrequest *AggregateAssetsValuesRequest + urlParams_ gensupport.URLParams + ctx_ context.Context + header_ http.Header +} + +// AggregateValues: Aggregates the requested fields based on provided +// function. +// +// - parent: Parent value for `AggregateAssetsValuesRequest`. +func (r *ProjectsLocationsAssetsService) AggregateValues(parent string, aggregateassetsvaluesrequest *AggregateAssetsValuesRequest) *ProjectsLocationsAssetsAggregateValuesCall { + c := &ProjectsLocationsAssetsAggregateValuesCall{s: r.s, urlParams_: make(gensupport.URLParams)} + c.parent = parent + c.aggregateassetsvaluesrequest = aggregateassetsvaluesrequest + 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 *ProjectsLocationsAssetsAggregateValuesCall) Fields(s ...googleapi.Field) *ProjectsLocationsAssetsAggregateValuesCall { + 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 *ProjectsLocationsAssetsAggregateValuesCall) Context(ctx context.Context) *ProjectsLocationsAssetsAggregateValuesCall { + 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 *ProjectsLocationsAssetsAggregateValuesCall) Header() http.Header { + if c.header_ == nil { + c.header_ = make(http.Header) + } + return c.header_ +} + +func (c *ProjectsLocationsAssetsAggregateValuesCall) 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.aggregateassetsvaluesrequest) + 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, "v1alpha1/{+parent}/assets:aggregateValues") + 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{ + "parent": c.parent, + }) + return gensupport.SendRequest(c.ctx_, c.s.client, req) +} + +// Do executes the "migrationcenter.projects.locations.assets.aggregateValues" call. +// Exactly one of *AggregateAssetsValuesResponse or error will be +// non-nil. Any non-2xx status code is an error. Response headers are in +// either *AggregateAssetsValuesResponse.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 *ProjectsLocationsAssetsAggregateValuesCall) Do(opts ...googleapi.CallOption) (*AggregateAssetsValuesResponse, 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 := &AggregateAssetsValuesResponse{ + 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": "Aggregates the requested fields based on provided function.", + // "flatPath": "v1alpha1/projects/{projectsId}/locations/{locationsId}/assets:aggregateValues", + // "httpMethod": "POST", + // "id": "migrationcenter.projects.locations.assets.aggregateValues", + // "parameterOrder": [ + // "parent" + // ], + // "parameters": { + // "parent": { + // "description": "Required. Parent value for `AggregateAssetsValuesRequest`.", + // "location": "path", + // "pattern": "^projects/[^/]+/locations/[^/]+$", + // "required": true, + // "type": "string" + // } + // }, + // "path": "v1alpha1/{+parent}/assets:aggregateValues", + // "request": { + // "$ref": "AggregateAssetsValuesRequest" + // }, + // "response": { + // "$ref": "AggregateAssetsValuesResponse" + // }, + // "scopes": [ + // "https://www.googleapis.com/auth/cloud-platform" + // ] + // } + +} + +// method id "migrationcenter.projects.locations.assets.create": + +type ProjectsLocationsAssetsCreateCall struct { + s *Service + parent string + asset *Asset + urlParams_ gensupport.URLParams + ctx_ context.Context + header_ http.Header +} + +// Create: Creates a new asset in a given project and location. +// Deprecated: Use ReportAssetFrames instead. +// +// - parent: Value for parent. +func (r *ProjectsLocationsAssetsService) Create(parent string, asset *Asset) *ProjectsLocationsAssetsCreateCall { + c := &ProjectsLocationsAssetsCreateCall{s: r.s, urlParams_: make(gensupport.URLParams)} + c.parent = parent + c.asset = asset + return c +} + +// AssetId sets the optional parameter "assetId": +func (c *ProjectsLocationsAssetsCreateCall) AssetId(assetId string) *ProjectsLocationsAssetsCreateCall { + c.urlParams_.Set("assetId", assetId) + return c +} + +// RequestId sets the optional parameter "requestId": An optional +// request ID to identify requests. Specify a unique request ID so that +// if you must retry your request, the server will know to ignore the +// request if it has already been completed. The server will guarantee +// that for at least 60 minutes since the first request. For example, +// consider a situation where you make an initial request and the +// request times out. If you make the request again with the same +// request ID, the server can check if original operation with the same +// request ID was received, and if so, will ignore the second request. +// This prevents clients from accidentally creating duplicate +// commitments. The request ID must be a valid UUID with the exception +// that zero UUID is not supported +// (00000000-0000-0000-0000-000000000000). +func (c *ProjectsLocationsAssetsCreateCall) RequestId(requestId string) *ProjectsLocationsAssetsCreateCall { + c.urlParams_.Set("requestId", requestId) + 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 *ProjectsLocationsAssetsCreateCall) Fields(s ...googleapi.Field) *ProjectsLocationsAssetsCreateCall { + 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 *ProjectsLocationsAssetsCreateCall) Context(ctx context.Context) *ProjectsLocationsAssetsCreateCall { + 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 *ProjectsLocationsAssetsCreateCall) Header() http.Header { + if c.header_ == nil { + c.header_ = make(http.Header) + } + return c.header_ +} + +func (c *ProjectsLocationsAssetsCreateCall) 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.asset) + 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, "v1alpha1/{+parent}/assets") + 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{ + "parent": c.parent, + }) + return gensupport.SendRequest(c.ctx_, c.s.client, req) +} + +// Do executes the "migrationcenter.projects.locations.assets.create" call. +// Exactly one of *Operation or error will be non-nil. Any non-2xx +// status code is an error. Response headers are in either +// *Operation.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 *ProjectsLocationsAssetsCreateCall) Do(opts ...googleapi.CallOption) (*Operation, 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 := &Operation{ + 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": "Creates a new asset in a given project and location. Deprecated: Use ReportAssetFrames instead.", + // "flatPath": "v1alpha1/projects/{projectsId}/locations/{locationsId}/assets", + // "httpMethod": "POST", + // "id": "migrationcenter.projects.locations.assets.create", + // "parameterOrder": [ + // "parent" + // ], + // "parameters": { + // "assetId": { + // "location": "query", + // "type": "string" + // }, + // "parent": { + // "description": "Required. Value for parent.", + // "location": "path", + // "pattern": "^projects/[^/]+/locations/[^/]+$", + // "required": true, + // "type": "string" + // }, + // "requestId": { + // "description": "Optional. An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. The server will guarantee that for at least 60 minutes since the first request. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000).", + // "location": "query", + // "type": "string" + // } + // }, + // "path": "v1alpha1/{+parent}/assets", + // "request": { + // "$ref": "Asset" + // }, + // "response": { + // "$ref": "Operation" + // }, + // "scopes": [ + // "https://www.googleapis.com/auth/cloud-platform" + // ] + // } + +} + +// method id "migrationcenter.projects.locations.assets.delete": + +type ProjectsLocationsAssetsDeleteCall struct { + s *Service + name string + urlParams_ gensupport.URLParams + ctx_ context.Context + header_ http.Header +} + +// Delete: Deletes an asset. +// +// - name: Name of the resource. +func (r *ProjectsLocationsAssetsService) Delete(name string) *ProjectsLocationsAssetsDeleteCall { + c := &ProjectsLocationsAssetsDeleteCall{s: r.s, urlParams_: make(gensupport.URLParams)} + c.name = name + return c +} + +// RequestId sets the optional parameter "requestId": An optional +// request ID to identify requests. Specify a unique request ID so that +// if you must retry your request, the server will know to ignore the +// request if it has already been completed. The server will guarantee +// that for at least 60 minutes after the first request. For example, +// consider a situation where you make an initial request and the +// request times out. If you make the request again with the same +// request ID, the server can check if original operation with the same +// request ID was received, and if so, will ignore the second request. +// This prevents clients from accidentally creating duplicate +// commitments. The request ID must be a valid UUID with the exception +// that zero UUID is not supported +// (00000000-0000-0000-0000-000000000000). +func (c *ProjectsLocationsAssetsDeleteCall) RequestId(requestId string) *ProjectsLocationsAssetsDeleteCall { + c.urlParams_.Set("requestId", requestId) + 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 *ProjectsLocationsAssetsDeleteCall) Fields(s ...googleapi.Field) *ProjectsLocationsAssetsDeleteCall { + 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 *ProjectsLocationsAssetsDeleteCall) Context(ctx context.Context) *ProjectsLocationsAssetsDeleteCall { + 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 *ProjectsLocationsAssetsDeleteCall) Header() http.Header { + if c.header_ == nil { + c.header_ = make(http.Header) + } + return c.header_ +} + +func (c *ProjectsLocationsAssetsDeleteCall) 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, "v1alpha1/{+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 "migrationcenter.projects.locations.assets.delete" call. +// Exactly one of *Operation or error will be non-nil. Any non-2xx +// status code is an error. Response headers are in either +// *Operation.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 *ProjectsLocationsAssetsDeleteCall) Do(opts ...googleapi.CallOption) (*Operation, 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 := &Operation{ + 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 an asset.", + // "flatPath": "v1alpha1/projects/{projectsId}/locations/{locationsId}/assets/{assetsId}", + // "httpMethod": "DELETE", + // "id": "migrationcenter.projects.locations.assets.delete", + // "parameterOrder": [ + // "name" + // ], + // "parameters": { + // "name": { + // "description": "Required. Name of the resource.", + // "location": "path", + // "pattern": "^projects/[^/]+/locations/[^/]+/assets/[^/]+$", + // "required": true, + // "type": "string" + // }, + // "requestId": { + // "description": "Optional. An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. The server will guarantee that for at least 60 minutes after the first request. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000).", + // "location": "query", + // "type": "string" + // } + // }, + // "path": "v1alpha1/{+name}", + // "response": { + // "$ref": "Operation" + // }, + // "scopes": [ + // "https://www.googleapis.com/auth/cloud-platform" + // ] + // } + +} + +// method id "migrationcenter.projects.locations.assets.get": + +type ProjectsLocationsAssetsGetCall struct { + s *Service + name string + urlParams_ gensupport.URLParams + ifNoneMatch_ string + ctx_ context.Context + header_ http.Header +} + +// Get: Gets the details of an asset. +// +// - name: Name of the resource. +func (r *ProjectsLocationsAssetsService) Get(name string) *ProjectsLocationsAssetsGetCall { + c := &ProjectsLocationsAssetsGetCall{s: r.s, urlParams_: make(gensupport.URLParams)} + c.name = name + return c +} + +// View sets the optional parameter "view": View of the assets. Defaults +// to BASIC. +// +// Possible values: +// +// "ASSET_VIEW_UNSPECIFIED" - The asset view is not specified. The API +// +// displays the basic view by default. +// +// "ASSET_VIEW_BASIC" - The asset view includes only basic metadata of +// +// the asset. +// +// "ASSET_VIEW_FULL" - The asset view includes all the metadata of an +// +// asset. +// +// "ASSET_VIEW_STANDARD" - The asset view includes the standard +// +// metadata of an asset. +func (c *ProjectsLocationsAssetsGetCall) View(view string) *ProjectsLocationsAssetsGetCall { + c.urlParams_.Set("view", view) + 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 *ProjectsLocationsAssetsGetCall) Fields(s ...googleapi.Field) *ProjectsLocationsAssetsGetCall { + 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 *ProjectsLocationsAssetsGetCall) IfNoneMatch(entityTag string) *ProjectsLocationsAssetsGetCall { + 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 *ProjectsLocationsAssetsGetCall) Context(ctx context.Context) *ProjectsLocationsAssetsGetCall { + 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 *ProjectsLocationsAssetsGetCall) Header() http.Header { + if c.header_ == nil { + c.header_ = make(http.Header) + } + return c.header_ +} + +func (c *ProjectsLocationsAssetsGetCall) 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, "v1alpha1/{+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 "migrationcenter.projects.locations.assets.get" call. +// Exactly one of *Asset or error will be non-nil. Any non-2xx status +// code is an error. Response headers are in either +// *Asset.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 *ProjectsLocationsAssetsGetCall) Do(opts ...googleapi.CallOption) (*Asset, 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 := &Asset{ + 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 details of an asset.", + // "flatPath": "v1alpha1/projects/{projectsId}/locations/{locationsId}/assets/{assetsId}", + // "httpMethod": "GET", + // "id": "migrationcenter.projects.locations.assets.get", + // "parameterOrder": [ + // "name" + // ], + // "parameters": { + // "name": { + // "description": "Required. Name of the resource.", + // "location": "path", + // "pattern": "^projects/[^/]+/locations/[^/]+/assets/[^/]+$", + // "required": true, + // "type": "string" + // }, + // "view": { + // "description": "View of the assets. Defaults to BASIC.", + // "enum": [ + // "ASSET_VIEW_UNSPECIFIED", + // "ASSET_VIEW_BASIC", + // "ASSET_VIEW_FULL", + // "ASSET_VIEW_STANDARD" + // ], + // "enumDescriptions": [ + // "The asset view is not specified. The API displays the basic view by default.", + // "The asset view includes only basic metadata of the asset.", + // "The asset view includes all the metadata of an asset.", + // "The asset view includes the standard metadata of an asset." + // ], + // "location": "query", + // "type": "string" + // } + // }, + // "path": "v1alpha1/{+name}", + // "response": { + // "$ref": "Asset" + // }, + // "scopes": [ + // "https://www.googleapis.com/auth/cloud-platform" + // ] + // } + +} + +// method id "migrationcenter.projects.locations.assets.list": + +type ProjectsLocationsAssetsListCall struct { + s *Service + parent string + urlParams_ gensupport.URLParams + ifNoneMatch_ string + ctx_ context.Context + header_ http.Header +} + +// List: Lists all the assets in a given project and location. +// +// - parent: Parent value for `ListAssetsRequest`. +func (r *ProjectsLocationsAssetsService) List(parent string) *ProjectsLocationsAssetsListCall { + c := &ProjectsLocationsAssetsListCall{s: r.s, urlParams_: make(gensupport.URLParams)} + c.parent = parent + return c +} + +// Filter sets the optional parameter "filter": Filtering results. +func (c *ProjectsLocationsAssetsListCall) Filter(filter string) *ProjectsLocationsAssetsListCall { + c.urlParams_.Set("filter", filter) + return c +} + +// OrderBy sets the optional parameter "orderBy": Field to sort by. See +// https://google.aip.dev/132#ordering for more details. +func (c *ProjectsLocationsAssetsListCall) OrderBy(orderBy string) *ProjectsLocationsAssetsListCall { + c.urlParams_.Set("orderBy", orderBy) + return c +} + +// PageSize sets the optional parameter "pageSize": Requested page size. +// Server may return fewer items than requested. If unspecified, server +// will pick an appropriate default. +func (c *ProjectsLocationsAssetsListCall) PageSize(pageSize int64) *ProjectsLocationsAssetsListCall { + c.urlParams_.Set("pageSize", fmt.Sprint(pageSize)) + return c +} + +// PageToken sets the optional parameter "pageToken": A token +// identifying a page of results the server should return. +func (c *ProjectsLocationsAssetsListCall) PageToken(pageToken string) *ProjectsLocationsAssetsListCall { + c.urlParams_.Set("pageToken", pageToken) + return c +} + +// View sets the optional parameter "view": View of the assets. Defaults +// to BASIC. +// +// Possible values: +// +// "ASSET_VIEW_UNSPECIFIED" - The asset view is not specified. The API +// +// displays the basic view by default. +// +// "ASSET_VIEW_BASIC" - The asset view includes only basic metadata of +// +// the asset. +// +// "ASSET_VIEW_FULL" - The asset view includes all the metadata of an +// +// asset. +// +// "ASSET_VIEW_STANDARD" - The asset view includes the standard +// +// metadata of an asset. +func (c *ProjectsLocationsAssetsListCall) View(view string) *ProjectsLocationsAssetsListCall { + c.urlParams_.Set("view", view) + 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 *ProjectsLocationsAssetsListCall) Fields(s ...googleapi.Field) *ProjectsLocationsAssetsListCall { + 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 *ProjectsLocationsAssetsListCall) IfNoneMatch(entityTag string) *ProjectsLocationsAssetsListCall { + 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 *ProjectsLocationsAssetsListCall) Context(ctx context.Context) *ProjectsLocationsAssetsListCall { + 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 *ProjectsLocationsAssetsListCall) Header() http.Header { + if c.header_ == nil { + c.header_ = make(http.Header) + } + return c.header_ +} + +func (c *ProjectsLocationsAssetsListCall) 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, "v1alpha1/{+parent}/assets") + 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{ + "parent": c.parent, + }) + return gensupport.SendRequest(c.ctx_, c.s.client, req) +} + +// Do executes the "migrationcenter.projects.locations.assets.list" call. +// Exactly one of *ListAssetsResponse or error will be non-nil. Any +// non-2xx status code is an error. Response headers are in either +// *ListAssetsResponse.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 *ProjectsLocationsAssetsListCall) Do(opts ...googleapi.CallOption) (*ListAssetsResponse, 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 := &ListAssetsResponse{ + 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 all the assets in a given project and location.", + // "flatPath": "v1alpha1/projects/{projectsId}/locations/{locationsId}/assets", + // "httpMethod": "GET", + // "id": "migrationcenter.projects.locations.assets.list", + // "parameterOrder": [ + // "parent" + // ], + // "parameters": { + // "filter": { + // "description": "Filtering results.", + // "location": "query", + // "type": "string" + // }, + // "orderBy": { + // "description": "Field to sort by. See https://google.aip.dev/132#ordering for more details.", + // "location": "query", + // "type": "string" + // }, + // "pageSize": { + // "description": "Requested page size. Server may return fewer items than requested. If unspecified, server will pick an appropriate default.", + // "format": "int32", + // "location": "query", + // "type": "integer" + // }, + // "pageToken": { + // "description": "A token identifying a page of results the server should return.", + // "location": "query", + // "type": "string" + // }, + // "parent": { + // "description": "Required. Parent value for `ListAssetsRequest`.", + // "location": "path", + // "pattern": "^projects/[^/]+/locations/[^/]+$", + // "required": true, + // "type": "string" + // }, + // "view": { + // "description": "View of the assets. Defaults to BASIC.", + // "enum": [ + // "ASSET_VIEW_UNSPECIFIED", + // "ASSET_VIEW_BASIC", + // "ASSET_VIEW_FULL", + // "ASSET_VIEW_STANDARD" + // ], + // "enumDescriptions": [ + // "The asset view is not specified. The API displays the basic view by default.", + // "The asset view includes only basic metadata of the asset.", + // "The asset view includes all the metadata of an asset.", + // "The asset view includes the standard metadata of an asset." + // ], + // "location": "query", + // "type": "string" + // } + // }, + // "path": "v1alpha1/{+parent}/assets", + // "response": { + // "$ref": "ListAssetsResponse" + // }, + // "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 *ProjectsLocationsAssetsListCall) Pages(ctx context.Context, f func(*ListAssetsResponse) 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 "migrationcenter.projects.locations.assets.patch": + +type ProjectsLocationsAssetsPatchCall struct { + s *Service + name string + asset *Asset + urlParams_ gensupport.URLParams + ctx_ context.Context + header_ http.Header +} + +// Patch: Updates the parameters of an asset. +// +// - name: Output only. The full name of the asset. +func (r *ProjectsLocationsAssetsService) Patch(name string, asset *Asset) *ProjectsLocationsAssetsPatchCall { + c := &ProjectsLocationsAssetsPatchCall{s: r.s, urlParams_: make(gensupport.URLParams)} + c.name = name + c.asset = asset + return c +} + +// RequestId sets the optional parameter "requestId": An optional +// request ID to identify requests. Specify a unique request ID so that +// if you must retry your request, the server will know to ignore the +// request if it has already been completed. The server will guarantee +// that for at least 60 minutes since the first request. For example, +// consider a situation where you make an initial request and the +// request times out. If you make the request again with the same +// request ID, the server can check if original operation with the same +// request ID was received, and if so, will ignore the second request. +// This prevents clients from accidentally creating duplicate +// commitments. The request ID must be a valid UUID with the exception +// that zero UUID is not supported +// (00000000-0000-0000-0000-000000000000). +func (c *ProjectsLocationsAssetsPatchCall) RequestId(requestId string) *ProjectsLocationsAssetsPatchCall { + c.urlParams_.Set("requestId", requestId) + return c +} + +// UpdateMask sets the optional parameter "updateMask": Required. Field +// mask is used to specify the fields to be overwritten in the `Asset` +// resource by the update. The values specified in the `update_mask` +// field are relative to the resource, not the full request. A field +// will be overwritten if it is in the mask. A single * value in the +// mask lets you to overwrite all fields. +func (c *ProjectsLocationsAssetsPatchCall) UpdateMask(updateMask string) *ProjectsLocationsAssetsPatchCall { + c.urlParams_.Set("updateMask", updateMask) + 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 *ProjectsLocationsAssetsPatchCall) Fields(s ...googleapi.Field) *ProjectsLocationsAssetsPatchCall { + 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 *ProjectsLocationsAssetsPatchCall) Context(ctx context.Context) *ProjectsLocationsAssetsPatchCall { + 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 *ProjectsLocationsAssetsPatchCall) Header() http.Header { + if c.header_ == nil { + c.header_ = make(http.Header) + } + return c.header_ +} + +func (c *ProjectsLocationsAssetsPatchCall) 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.asset) + 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, "v1alpha1/{+name}") + urls += "?" + c.urlParams_.Encode() + req, err := http.NewRequest("PATCH", 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 "migrationcenter.projects.locations.assets.patch" call. +// Exactly one of *Operation or error will be non-nil. Any non-2xx +// status code is an error. Response headers are in either +// *Operation.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 *ProjectsLocationsAssetsPatchCall) Do(opts ...googleapi.CallOption) (*Operation, 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 := &Operation{ + 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": "Updates the parameters of an asset.", + // "flatPath": "v1alpha1/projects/{projectsId}/locations/{locationsId}/assets/{assetsId}", + // "httpMethod": "PATCH", + // "id": "migrationcenter.projects.locations.assets.patch", + // "parameterOrder": [ + // "name" + // ], + // "parameters": { + // "name": { + // "description": "Output only. The full name of the asset.", + // "location": "path", + // "pattern": "^projects/[^/]+/locations/[^/]+/assets/[^/]+$", + // "required": true, + // "type": "string" + // }, + // "requestId": { + // "description": "Optional. An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. The server will guarantee that for at least 60 minutes since the first request. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000).", + // "location": "query", + // "type": "string" + // }, + // "updateMask": { + // "description": "Required. Field mask is used to specify the fields to be overwritten in the `Asset` resource by the update. The values specified in the `update_mask` field are relative to the resource, not the full request. A field will be overwritten if it is in the mask. A single * value in the mask lets you to overwrite all fields.", + // "format": "google-fieldmask", + // "location": "query", + // "type": "string" + // } + // }, + // "path": "v1alpha1/{+name}", + // "request": { + // "$ref": "Asset" + // }, + // "response": { + // "$ref": "Operation" + // }, + // "scopes": [ + // "https://www.googleapis.com/auth/cloud-platform" + // ] + // } + +} + +// method id "migrationcenter.projects.locations.assets.reportAssetFrames": + +type ProjectsLocationsAssetsReportAssetFramesCall struct { + s *Service + parent string + frames *Frames + urlParams_ gensupport.URLParams + ctx_ context.Context + header_ http.Header +} + +// ReportAssetFrames: Reports a set of frames. +// +// - parent: Parent of the resource. +func (r *ProjectsLocationsAssetsService) ReportAssetFrames(parent string, frames *Frames) *ProjectsLocationsAssetsReportAssetFramesCall { + c := &ProjectsLocationsAssetsReportAssetFramesCall{s: r.s, urlParams_: make(gensupport.URLParams)} + c.parent = parent + c.frames = frames + return c +} + +// Source sets the optional parameter "source": Required. Reference to a +// source. +func (c *ProjectsLocationsAssetsReportAssetFramesCall) Source(source string) *ProjectsLocationsAssetsReportAssetFramesCall { + c.urlParams_.Set("source", source) + 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 *ProjectsLocationsAssetsReportAssetFramesCall) Fields(s ...googleapi.Field) *ProjectsLocationsAssetsReportAssetFramesCall { + 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 *ProjectsLocationsAssetsReportAssetFramesCall) Context(ctx context.Context) *ProjectsLocationsAssetsReportAssetFramesCall { + 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 *ProjectsLocationsAssetsReportAssetFramesCall) Header() http.Header { + if c.header_ == nil { + c.header_ = make(http.Header) + } + return c.header_ +} + +func (c *ProjectsLocationsAssetsReportAssetFramesCall) 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.frames) + 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, "v1alpha1/{+parent}/assets:reportAssetFrames") + 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{ + "parent": c.parent, + }) + return gensupport.SendRequest(c.ctx_, c.s.client, req) +} + +// Do executes the "migrationcenter.projects.locations.assets.reportAssetFrames" call. +// Exactly one of *ReportAssetFramesResponse or error will be non-nil. +// Any non-2xx status code is an error. Response headers are in either +// *ReportAssetFramesResponse.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 *ProjectsLocationsAssetsReportAssetFramesCall) Do(opts ...googleapi.CallOption) (*ReportAssetFramesResponse, 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 := &ReportAssetFramesResponse{ + 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": "Reports a set of frames.", + // "flatPath": "v1alpha1/projects/{projectsId}/locations/{locationsId}/assets:reportAssetFrames", + // "httpMethod": "POST", + // "id": "migrationcenter.projects.locations.assets.reportAssetFrames", + // "parameterOrder": [ + // "parent" + // ], + // "parameters": { + // "parent": { + // "description": "Required. Parent of the resource.", + // "location": "path", + // "pattern": "^projects/[^/]+/locations/[^/]+$", + // "required": true, + // "type": "string" + // }, + // "source": { + // "description": "Required. Reference to a source.", + // "location": "query", + // "type": "string" + // } + // }, + // "path": "v1alpha1/{+parent}/assets:reportAssetFrames", + // "request": { + // "$ref": "Frames" + // }, + // "response": { + // "$ref": "ReportAssetFramesResponse" + // }, + // "scopes": [ + // "https://www.googleapis.com/auth/cloud-platform" + // ] + // } + +} + +// method id "migrationcenter.projects.locations.importJobs.create": + +type ProjectsLocationsImportJobsCreateCall struct { + s *Service + parent string + importjob *ImportJob + urlParams_ gensupport.URLParams + ctx_ context.Context + header_ http.Header +} + +// Create: Creates an import job. +// +// - parent: Value for parent. +func (r *ProjectsLocationsImportJobsService) Create(parent string, importjob *ImportJob) *ProjectsLocationsImportJobsCreateCall { + c := &ProjectsLocationsImportJobsCreateCall{s: r.s, urlParams_: make(gensupport.URLParams)} + c.parent = parent + c.importjob = importjob + return c +} + +// ImportJobId sets the optional parameter "importJobId": Required. ID +// of the import job. +func (c *ProjectsLocationsImportJobsCreateCall) ImportJobId(importJobId string) *ProjectsLocationsImportJobsCreateCall { + c.urlParams_.Set("importJobId", importJobId) + return c +} + +// RequestId sets the optional parameter "requestId": An optional +// request ID to identify requests. Specify a unique request ID so that +// if you must retry your request, the server will know to ignore the +// request if it has already been completed. The server will guarantee +// that for at least 60 minutes since the first request. For example, +// consider a situation where you make an initial request and the +// request times out. If you make the request again with the same +// request ID, the server can check if original operation with the same +// request ID was received, and if so, will ignore the second request. +// This prevents clients from accidentally creating duplicate +// commitments. The request ID must be a valid UUID with the exception +// that zero UUID is not supported +// (00000000-0000-0000-0000-000000000000). +func (c *ProjectsLocationsImportJobsCreateCall) RequestId(requestId string) *ProjectsLocationsImportJobsCreateCall { + c.urlParams_.Set("requestId", requestId) + 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 *ProjectsLocationsImportJobsCreateCall) Fields(s ...googleapi.Field) *ProjectsLocationsImportJobsCreateCall { + 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 *ProjectsLocationsImportJobsCreateCall) Context(ctx context.Context) *ProjectsLocationsImportJobsCreateCall { + 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 *ProjectsLocationsImportJobsCreateCall) Header() http.Header { + if c.header_ == nil { + c.header_ = make(http.Header) + } + return c.header_ +} + +func (c *ProjectsLocationsImportJobsCreateCall) 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.importjob) + 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, "v1alpha1/{+parent}/importJobs") + 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{ + "parent": c.parent, + }) + return gensupport.SendRequest(c.ctx_, c.s.client, req) +} + +// Do executes the "migrationcenter.projects.locations.importJobs.create" call. +// Exactly one of *Operation or error will be non-nil. Any non-2xx +// status code is an error. Response headers are in either +// *Operation.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 *ProjectsLocationsImportJobsCreateCall) Do(opts ...googleapi.CallOption) (*Operation, 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 := &Operation{ + 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": "Creates an import job.", + // "flatPath": "v1alpha1/projects/{projectsId}/locations/{locationsId}/importJobs", + // "httpMethod": "POST", + // "id": "migrationcenter.projects.locations.importJobs.create", + // "parameterOrder": [ + // "parent" + // ], + // "parameters": { + // "importJobId": { + // "description": "Required. ID of the import job.", + // "location": "query", + // "type": "string" + // }, + // "parent": { + // "description": "Required. Value for parent.", + // "location": "path", + // "pattern": "^projects/[^/]+/locations/[^/]+$", + // "required": true, + // "type": "string" + // }, + // "requestId": { + // "description": "Optional. An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. The server will guarantee that for at least 60 minutes since the first request. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000).", + // "location": "query", + // "type": "string" + // } + // }, + // "path": "v1alpha1/{+parent}/importJobs", + // "request": { + // "$ref": "ImportJob" + // }, + // "response": { + // "$ref": "Operation" + // }, + // "scopes": [ + // "https://www.googleapis.com/auth/cloud-platform" + // ] + // } + +} + +// method id "migrationcenter.projects.locations.importJobs.delete": + +type ProjectsLocationsImportJobsDeleteCall struct { + s *Service + name string + urlParams_ gensupport.URLParams + ctx_ context.Context + header_ http.Header +} + +// Delete: Deletes an import job. +// +// - name: Name of the resource. +func (r *ProjectsLocationsImportJobsService) Delete(name string) *ProjectsLocationsImportJobsDeleteCall { + c := &ProjectsLocationsImportJobsDeleteCall{s: r.s, urlParams_: make(gensupport.URLParams)} + c.name = name + return c +} + +// RequestId sets the optional parameter "requestId": An optional +// request ID to identify requests. Specify a unique request ID so that +// if you must retry your request, the server will know to ignore the +// request if it has already been completed. The server will guarantee +// that for at least 60 minutes after the first request. For example, +// consider a situation where you make an initial request and the +// request times out. If you make the request again with the same +// request ID, the server can check if original operation with the same +// request ID was received, and if so, will ignore the second request. +// This prevents clients from accidentally creating duplicate +// commitments. The request ID must be a valid UUID with the exception +// that zero UUID is not supported +// (00000000-0000-0000-0000-000000000000). +func (c *ProjectsLocationsImportJobsDeleteCall) RequestId(requestId string) *ProjectsLocationsImportJobsDeleteCall { + c.urlParams_.Set("requestId", requestId) + 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 *ProjectsLocationsImportJobsDeleteCall) Fields(s ...googleapi.Field) *ProjectsLocationsImportJobsDeleteCall { + 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 *ProjectsLocationsImportJobsDeleteCall) Context(ctx context.Context) *ProjectsLocationsImportJobsDeleteCall { + 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 *ProjectsLocationsImportJobsDeleteCall) Header() http.Header { + if c.header_ == nil { + c.header_ = make(http.Header) + } + return c.header_ +} + +func (c *ProjectsLocationsImportJobsDeleteCall) 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, "v1alpha1/{+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 "migrationcenter.projects.locations.importJobs.delete" call. +// Exactly one of *Operation or error will be non-nil. Any non-2xx +// status code is an error. Response headers are in either +// *Operation.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 *ProjectsLocationsImportJobsDeleteCall) Do(opts ...googleapi.CallOption) (*Operation, 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 := &Operation{ + 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 an import job.", + // "flatPath": "v1alpha1/projects/{projectsId}/locations/{locationsId}/importJobs/{importJobsId}", + // "httpMethod": "DELETE", + // "id": "migrationcenter.projects.locations.importJobs.delete", + // "parameterOrder": [ + // "name" + // ], + // "parameters": { + // "name": { + // "description": "Required. Name of the resource.", + // "location": "path", + // "pattern": "^projects/[^/]+/locations/[^/]+/importJobs/[^/]+$", + // "required": true, + // "type": "string" + // }, + // "requestId": { + // "description": "Optional. An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. The server will guarantee that for at least 60 minutes after the first request. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000).", + // "location": "query", + // "type": "string" + // } + // }, + // "path": "v1alpha1/{+name}", + // "response": { + // "$ref": "Operation" + // }, + // "scopes": [ + // "https://www.googleapis.com/auth/cloud-platform" + // ] + // } + +} + +// method id "migrationcenter.projects.locations.importJobs.get": + +type ProjectsLocationsImportJobsGetCall struct { + s *Service + name string + urlParams_ gensupport.URLParams + ifNoneMatch_ string + ctx_ context.Context + header_ http.Header +} + +// Get: Gets the details of an import job. +// +// - name: Name of the resource. +func (r *ProjectsLocationsImportJobsService) Get(name string) *ProjectsLocationsImportJobsGetCall { + c := &ProjectsLocationsImportJobsGetCall{s: r.s, urlParams_: make(gensupport.URLParams)} + c.name = name + return c +} + +// View sets the optional parameter "view": The level of details of the +// import job. Default value is FULL. +// +// Possible values: +// +// "IMPORT_JOB_VIEW_UNSPECIFIED" - The import job view is not +// +// specified. The API displays the basic view by default. +// +// "IMPORT_JOB_VIEW_BASIC" - The import job view includes basic +// +// metadata of an import job. This view does not include payload +// information. +// +// "IMPORT_JOB_VIEW_FULL" - The import job view includes all metadata +// +// of an import job. +func (c *ProjectsLocationsImportJobsGetCall) View(view string) *ProjectsLocationsImportJobsGetCall { + c.urlParams_.Set("view", view) + 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 *ProjectsLocationsImportJobsGetCall) Fields(s ...googleapi.Field) *ProjectsLocationsImportJobsGetCall { + 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 *ProjectsLocationsImportJobsGetCall) IfNoneMatch(entityTag string) *ProjectsLocationsImportJobsGetCall { + 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 *ProjectsLocationsImportJobsGetCall) Context(ctx context.Context) *ProjectsLocationsImportJobsGetCall { + 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 *ProjectsLocationsImportJobsGetCall) Header() http.Header { + if c.header_ == nil { + c.header_ = make(http.Header) + } + return c.header_ +} + +func (c *ProjectsLocationsImportJobsGetCall) 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, "v1alpha1/{+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 "migrationcenter.projects.locations.importJobs.get" call. +// Exactly one of *ImportJob or error will be non-nil. Any non-2xx +// status code is an error. Response headers are in either +// *ImportJob.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 *ProjectsLocationsImportJobsGetCall) Do(opts ...googleapi.CallOption) (*ImportJob, 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 := &ImportJob{ + 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 details of an import job.", + // "flatPath": "v1alpha1/projects/{projectsId}/locations/{locationsId}/importJobs/{importJobsId}", + // "httpMethod": "GET", + // "id": "migrationcenter.projects.locations.importJobs.get", + // "parameterOrder": [ + // "name" + // ], + // "parameters": { + // "name": { + // "description": "Required. Name of the resource.", + // "location": "path", + // "pattern": "^projects/[^/]+/locations/[^/]+/importJobs/[^/]+$", + // "required": true, + // "type": "string" + // }, + // "view": { + // "description": "Optional. The level of details of the import job. Default value is FULL.", + // "enum": [ + // "IMPORT_JOB_VIEW_UNSPECIFIED", + // "IMPORT_JOB_VIEW_BASIC", + // "IMPORT_JOB_VIEW_FULL" + // ], + // "enumDescriptions": [ + // "The import job view is not specified. The API displays the basic view by default.", + // "The import job view includes basic metadata of an import job. This view does not include payload information.", + // "The import job view includes all metadata of an import job." + // ], + // "location": "query", + // "type": "string" + // } + // }, + // "path": "v1alpha1/{+name}", + // "response": { + // "$ref": "ImportJob" + // }, + // "scopes": [ + // "https://www.googleapis.com/auth/cloud-platform" + // ] + // } + +} + +// method id "migrationcenter.projects.locations.importJobs.list": + +type ProjectsLocationsImportJobsListCall struct { + s *Service + parent string + urlParams_ gensupport.URLParams + ifNoneMatch_ string + ctx_ context.Context + header_ http.Header +} + +// List: Lists all import jobs. +// +// - parent: Parent value for `ListImportJobsRequest`. +func (r *ProjectsLocationsImportJobsService) List(parent string) *ProjectsLocationsImportJobsListCall { + c := &ProjectsLocationsImportJobsListCall{s: r.s, urlParams_: make(gensupport.URLParams)} + c.parent = parent + return c +} + +// Filter sets the optional parameter "filter": Filtering results. +func (c *ProjectsLocationsImportJobsListCall) Filter(filter string) *ProjectsLocationsImportJobsListCall { + c.urlParams_.Set("filter", filter) + return c +} + +// OrderBy sets the optional parameter "orderBy": Field to sort by. See +// https://google.aip.dev/132#ordering for more details. +func (c *ProjectsLocationsImportJobsListCall) OrderBy(orderBy string) *ProjectsLocationsImportJobsListCall { + c.urlParams_.Set("orderBy", orderBy) + return c +} + +// PageSize sets the optional parameter "pageSize": Requested page size. +// Server may return fewer items than requested. If unspecified, server +// will pick an appropriate default. +func (c *ProjectsLocationsImportJobsListCall) PageSize(pageSize int64) *ProjectsLocationsImportJobsListCall { + c.urlParams_.Set("pageSize", fmt.Sprint(pageSize)) + return c +} + +// PageToken sets the optional parameter "pageToken": A token +// identifying a page of results the server should return. +func (c *ProjectsLocationsImportJobsListCall) PageToken(pageToken string) *ProjectsLocationsImportJobsListCall { + c.urlParams_.Set("pageToken", pageToken) + return c +} + +// View sets the optional parameter "view": The level of details of each +// import job. Default value is BASIC. +// +// Possible values: +// +// "IMPORT_JOB_VIEW_UNSPECIFIED" - The import job view is not +// +// specified. The API displays the basic view by default. +// +// "IMPORT_JOB_VIEW_BASIC" - The import job view includes basic +// +// metadata of an import job. This view does not include payload +// information. +// +// "IMPORT_JOB_VIEW_FULL" - The import job view includes all metadata +// +// of an import job. +func (c *ProjectsLocationsImportJobsListCall) View(view string) *ProjectsLocationsImportJobsListCall { + c.urlParams_.Set("view", view) + 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 *ProjectsLocationsImportJobsListCall) Fields(s ...googleapi.Field) *ProjectsLocationsImportJobsListCall { + 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 *ProjectsLocationsImportJobsListCall) IfNoneMatch(entityTag string) *ProjectsLocationsImportJobsListCall { + 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 *ProjectsLocationsImportJobsListCall) Context(ctx context.Context) *ProjectsLocationsImportJobsListCall { + 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 *ProjectsLocationsImportJobsListCall) Header() http.Header { + if c.header_ == nil { + c.header_ = make(http.Header) + } + return c.header_ +} + +func (c *ProjectsLocationsImportJobsListCall) 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, "v1alpha1/{+parent}/importJobs") + 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{ + "parent": c.parent, + }) + return gensupport.SendRequest(c.ctx_, c.s.client, req) +} + +// Do executes the "migrationcenter.projects.locations.importJobs.list" call. +// Exactly one of *ListImportJobsResponse or error will be non-nil. Any +// non-2xx status code is an error. Response headers are in either +// *ListImportJobsResponse.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 *ProjectsLocationsImportJobsListCall) Do(opts ...googleapi.CallOption) (*ListImportJobsResponse, 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 := &ListImportJobsResponse{ + 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 all import jobs.", + // "flatPath": "v1alpha1/projects/{projectsId}/locations/{locationsId}/importJobs", + // "httpMethod": "GET", + // "id": "migrationcenter.projects.locations.importJobs.list", + // "parameterOrder": [ + // "parent" + // ], + // "parameters": { + // "filter": { + // "description": "Filtering results.", + // "location": "query", + // "type": "string" + // }, + // "orderBy": { + // "description": "Field to sort by. See https://google.aip.dev/132#ordering for more details.", + // "location": "query", + // "type": "string" + // }, + // "pageSize": { + // "description": "Requested page size. Server may return fewer items than requested. If unspecified, server will pick an appropriate default.", + // "format": "int32", + // "location": "query", + // "type": "integer" + // }, + // "pageToken": { + // "description": "A token identifying a page of results the server should return.", + // "location": "query", + // "type": "string" + // }, + // "parent": { + // "description": "Required. Parent value for `ListImportJobsRequest`.", + // "location": "path", + // "pattern": "^projects/[^/]+/locations/[^/]+$", + // "required": true, + // "type": "string" + // }, + // "view": { + // "description": "Optional. The level of details of each import job. Default value is BASIC.", + // "enum": [ + // "IMPORT_JOB_VIEW_UNSPECIFIED", + // "IMPORT_JOB_VIEW_BASIC", + // "IMPORT_JOB_VIEW_FULL" + // ], + // "enumDescriptions": [ + // "The import job view is not specified. The API displays the basic view by default.", + // "The import job view includes basic metadata of an import job. This view does not include payload information.", + // "The import job view includes all metadata of an import job." + // ], + // "location": "query", + // "type": "string" + // } + // }, + // "path": "v1alpha1/{+parent}/importJobs", + // "response": { + // "$ref": "ListImportJobsResponse" + // }, + // "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 *ProjectsLocationsImportJobsListCall) Pages(ctx context.Context, f func(*ListImportJobsResponse) 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 "migrationcenter.projects.locations.importJobs.patch": + +type ProjectsLocationsImportJobsPatchCall struct { + s *Service + name string + importjob *ImportJob + urlParams_ gensupport.URLParams + ctx_ context.Context + header_ http.Header +} + +// Patch: Updates an import job. +// +// - name: Output only. The full name of the import job. +func (r *ProjectsLocationsImportJobsService) Patch(name string, importjob *ImportJob) *ProjectsLocationsImportJobsPatchCall { + c := &ProjectsLocationsImportJobsPatchCall{s: r.s, urlParams_: make(gensupport.URLParams)} + c.name = name + c.importjob = importjob + return c +} + +// RequestId sets the optional parameter "requestId": An optional +// request ID to identify requests. Specify a unique request ID so that +// if you must retry your request, the server will know to ignore the +// request if it has already been completed. The server will guarantee +// that for at least 60 minutes since the first request. For example, +// consider a situation where you make an initial request and the +// request times out. If you make the request again with the same +// request ID, the server can check if original operation with the same +// request ID was received, and if so, will ignore the second request. +// This prevents clients from accidentally creating duplicate +// commitments. The request ID must be a valid UUID with the exception +// that zero UUID is not supported +// (00000000-0000-0000-0000-000000000000). +func (c *ProjectsLocationsImportJobsPatchCall) RequestId(requestId string) *ProjectsLocationsImportJobsPatchCall { + c.urlParams_.Set("requestId", requestId) + return c +} + +// UpdateMask sets the optional parameter "updateMask": Required. Field +// mask is used to specify the fields to be overwritten in the `Asset` +// resource by the update. The values specified in the `update_mask` +// field are relative to the resource, not the full request. A field +// will be overwritten if it is in the mask. A single * value in the +// mask lets you to overwrite all fields. +func (c *ProjectsLocationsImportJobsPatchCall) UpdateMask(updateMask string) *ProjectsLocationsImportJobsPatchCall { + c.urlParams_.Set("updateMask", updateMask) + 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 *ProjectsLocationsImportJobsPatchCall) Fields(s ...googleapi.Field) *ProjectsLocationsImportJobsPatchCall { + 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 *ProjectsLocationsImportJobsPatchCall) Context(ctx context.Context) *ProjectsLocationsImportJobsPatchCall { + 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 *ProjectsLocationsImportJobsPatchCall) Header() http.Header { + if c.header_ == nil { + c.header_ = make(http.Header) + } + return c.header_ +} + +func (c *ProjectsLocationsImportJobsPatchCall) 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.importjob) + 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, "v1alpha1/{+name}") + urls += "?" + c.urlParams_.Encode() + req, err := http.NewRequest("PATCH", 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 "migrationcenter.projects.locations.importJobs.patch" call. +// Exactly one of *Operation or error will be non-nil. Any non-2xx +// status code is an error. Response headers are in either +// *Operation.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 *ProjectsLocationsImportJobsPatchCall) Do(opts ...googleapi.CallOption) (*Operation, 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 := &Operation{ + 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": "Updates an import job.", + // "flatPath": "v1alpha1/projects/{projectsId}/locations/{locationsId}/importJobs/{importJobsId}", + // "httpMethod": "PATCH", + // "id": "migrationcenter.projects.locations.importJobs.patch", + // "parameterOrder": [ + // "name" + // ], + // "parameters": { + // "name": { + // "description": "Output only. The full name of the import job.", + // "location": "path", + // "pattern": "^projects/[^/]+/locations/[^/]+/importJobs/[^/]+$", + // "required": true, + // "type": "string" + // }, + // "requestId": { + // "description": "Optional. An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. The server will guarantee that for at least 60 minutes since the first request. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000).", + // "location": "query", + // "type": "string" + // }, + // "updateMask": { + // "description": "Required. Field mask is used to specify the fields to be overwritten in the `Asset` resource by the update. The values specified in the `update_mask` field are relative to the resource, not the full request. A field will be overwritten if it is in the mask. A single * value in the mask lets you to overwrite all fields.", + // "format": "google-fieldmask", + // "location": "query", + // "type": "string" + // } + // }, + // "path": "v1alpha1/{+name}", + // "request": { + // "$ref": "ImportJob" + // }, + // "response": { + // "$ref": "Operation" + // }, + // "scopes": [ + // "https://www.googleapis.com/auth/cloud-platform" + // ] + // } + +} + +// method id "migrationcenter.projects.locations.importJobs.run": + +type ProjectsLocationsImportJobsRunCall struct { + s *Service + name string + runimportjobrequest *RunImportJobRequest + urlParams_ gensupport.URLParams + ctx_ context.Context + header_ http.Header +} + +// Run: Runs an import job. +// +// - name: The name of the import job to run. +func (r *ProjectsLocationsImportJobsService) Run(name string, runimportjobrequest *RunImportJobRequest) *ProjectsLocationsImportJobsRunCall { + c := &ProjectsLocationsImportJobsRunCall{s: r.s, urlParams_: make(gensupport.URLParams)} + c.name = name + c.runimportjobrequest = runimportjobrequest + 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 *ProjectsLocationsImportJobsRunCall) Fields(s ...googleapi.Field) *ProjectsLocationsImportJobsRunCall { + 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 *ProjectsLocationsImportJobsRunCall) Context(ctx context.Context) *ProjectsLocationsImportJobsRunCall { + 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 *ProjectsLocationsImportJobsRunCall) Header() http.Header { + if c.header_ == nil { + c.header_ = make(http.Header) + } + return c.header_ +} + +func (c *ProjectsLocationsImportJobsRunCall) 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.runimportjobrequest) + 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, "v1alpha1/{+name}:run") + 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 "migrationcenter.projects.locations.importJobs.run" call. +// Exactly one of *Operation or error will be non-nil. Any non-2xx +// status code is an error. Response headers are in either +// *Operation.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 *ProjectsLocationsImportJobsRunCall) Do(opts ...googleapi.CallOption) (*Operation, 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 := &Operation{ + 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": "Runs an import job.", + // "flatPath": "v1alpha1/projects/{projectsId}/locations/{locationsId}/importJobs/{importJobsId}:run", + // "httpMethod": "POST", + // "id": "migrationcenter.projects.locations.importJobs.run", + // "parameterOrder": [ + // "name" + // ], + // "parameters": { + // "name": { + // "description": "Required. The name of the import job to run.", + // "location": "path", + // "pattern": "^projects/[^/]+/locations/[^/]+/importJobs/[^/]+$", + // "required": true, + // "type": "string" + // } + // }, + // "path": "v1alpha1/{+name}:run", + // "request": { + // "$ref": "RunImportJobRequest" + // }, + // "response": { + // "$ref": "Operation" + // }, + // "scopes": [ + // "https://www.googleapis.com/auth/cloud-platform" + // ] + // } + +} + +// method id "migrationcenter.projects.locations.importJobs.validate": + +type ProjectsLocationsImportJobsValidateCall struct { + s *Service + name string + validateimportjobrequest *ValidateImportJobRequest + urlParams_ gensupport.URLParams + ctx_ context.Context + header_ http.Header +} + +// Validate: Validates an import job. +// +// - name: The name of the import job to validate. +func (r *ProjectsLocationsImportJobsService) Validate(name string, validateimportjobrequest *ValidateImportJobRequest) *ProjectsLocationsImportJobsValidateCall { + c := &ProjectsLocationsImportJobsValidateCall{s: r.s, urlParams_: make(gensupport.URLParams)} + c.name = name + c.validateimportjobrequest = validateimportjobrequest + 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 *ProjectsLocationsImportJobsValidateCall) Fields(s ...googleapi.Field) *ProjectsLocationsImportJobsValidateCall { + 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 *ProjectsLocationsImportJobsValidateCall) Context(ctx context.Context) *ProjectsLocationsImportJobsValidateCall { + 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 *ProjectsLocationsImportJobsValidateCall) Header() http.Header { + if c.header_ == nil { + c.header_ = make(http.Header) + } + return c.header_ +} + +func (c *ProjectsLocationsImportJobsValidateCall) 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.validateimportjobrequest) + 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, "v1alpha1/{+name}:validate") + 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 "migrationcenter.projects.locations.importJobs.validate" call. +// Exactly one of *Operation or error will be non-nil. Any non-2xx +// status code is an error. Response headers are in either +// *Operation.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 *ProjectsLocationsImportJobsValidateCall) Do(opts ...googleapi.CallOption) (*Operation, 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 := &Operation{ + 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": "Validates an import job.", + // "flatPath": "v1alpha1/projects/{projectsId}/locations/{locationsId}/importJobs/{importJobsId}:validate", + // "httpMethod": "POST", + // "id": "migrationcenter.projects.locations.importJobs.validate", + // "parameterOrder": [ + // "name" + // ], + // "parameters": { + // "name": { + // "description": "Required. The name of the import job to validate.", + // "location": "path", + // "pattern": "^projects/[^/]+/locations/[^/]+/importJobs/[^/]+$", + // "required": true, + // "type": "string" + // } + // }, + // "path": "v1alpha1/{+name}:validate", + // "request": { + // "$ref": "ValidateImportJobRequest" + // }, + // "response": { + // "$ref": "Operation" + // }, + // "scopes": [ + // "https://www.googleapis.com/auth/cloud-platform" + // ] + // } + +} + +// method id "migrationcenter.projects.locations.operations.cancel": + +type ProjectsLocationsOperationsCancelCall struct { + s *Service + name string + canceloperationrequest *CancelOperationRequest + 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 *ProjectsLocationsOperationsService) Cancel(name string, canceloperationrequest *CancelOperationRequest) *ProjectsLocationsOperationsCancelCall { + c := &ProjectsLocationsOperationsCancelCall{s: r.s, urlParams_: make(gensupport.URLParams)} + c.name = name + c.canceloperationrequest = canceloperationrequest + 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 *ProjectsLocationsOperationsCancelCall) Fields(s ...googleapi.Field) *ProjectsLocationsOperationsCancelCall { + 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 *ProjectsLocationsOperationsCancelCall) Context(ctx context.Context) *ProjectsLocationsOperationsCancelCall { + 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 *ProjectsLocationsOperationsCancelCall) Header() http.Header { + if c.header_ == nil { + c.header_ = make(http.Header) + } + return c.header_ +} + +func (c *ProjectsLocationsOperationsCancelCall) 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.canceloperationrequest) + 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, "v1alpha1/{+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 "migrationcenter.projects.locations.operations.cancel" call. +// Exactly one of *Empty or error will be non-nil. Any non-2xx status +// code is an error. Response headers are in either +// *Empty.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 *ProjectsLocationsOperationsCancelCall) Do(opts ...googleapi.CallOption) (*Empty, 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 := &Empty{ + 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": "v1alpha1/projects/{projectsId}/locations/{locationsId}/operations/{operationsId}:cancel", + // "httpMethod": "POST", + // "id": "migrationcenter.projects.locations.operations.cancel", + // "parameterOrder": [ + // "name" + // ], + // "parameters": { + // "name": { + // "description": "The name of the operation resource to be cancelled.", + // "location": "path", + // "pattern": "^projects/[^/]+/locations/[^/]+/operations/[^/]+$", + // "required": true, + // "type": "string" + // } + // }, + // "path": "v1alpha1/{+name}:cancel", + // "request": { + // "$ref": "CancelOperationRequest" + // }, + // "response": { + // "$ref": "Empty" + // }, + // "scopes": [ + // "https://www.googleapis.com/auth/cloud-platform" + // ] + // } + +} + +// method id "migrationcenter.projects.locations.operations.delete": + +type ProjectsLocationsOperationsDeleteCall 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 *ProjectsLocationsOperationsService) Delete(name string) *ProjectsLocationsOperationsDeleteCall { + c := &ProjectsLocationsOperationsDeleteCall{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 *ProjectsLocationsOperationsDeleteCall) Fields(s ...googleapi.Field) *ProjectsLocationsOperationsDeleteCall { + 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 *ProjectsLocationsOperationsDeleteCall) Context(ctx context.Context) *ProjectsLocationsOperationsDeleteCall { + 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 *ProjectsLocationsOperationsDeleteCall) Header() http.Header { + if c.header_ == nil { + c.header_ = make(http.Header) + } + return c.header_ +} + +func (c *ProjectsLocationsOperationsDeleteCall) 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, "v1alpha1/{+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 "migrationcenter.projects.locations.operations.delete" call. +// Exactly one of *Empty or error will be non-nil. Any non-2xx status +// code is an error. Response headers are in either +// *Empty.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 *ProjectsLocationsOperationsDeleteCall) Do(opts ...googleapi.CallOption) (*Empty, 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 := &Empty{ + 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": "v1alpha1/projects/{projectsId}/locations/{locationsId}/operations/{operationsId}", + // "httpMethod": "DELETE", + // "id": "migrationcenter.projects.locations.operations.delete", + // "parameterOrder": [ + // "name" + // ], + // "parameters": { + // "name": { + // "description": "The name of the operation resource to be deleted.", + // "location": "path", + // "pattern": "^projects/[^/]+/locations/[^/]+/operations/[^/]+$", + // "required": true, + // "type": "string" + // } + // }, + // "path": "v1alpha1/{+name}", + // "response": { + // "$ref": "Empty" + // }, + // "scopes": [ + // "https://www.googleapis.com/auth/cloud-platform" + // ] + // } + +} + +// method id "migrationcenter.projects.locations.operations.get": + +type ProjectsLocationsOperationsGetCall 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 *ProjectsLocationsOperationsService) Get(name string) *ProjectsLocationsOperationsGetCall { + c := &ProjectsLocationsOperationsGetCall{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 *ProjectsLocationsOperationsGetCall) Fields(s ...googleapi.Field) *ProjectsLocationsOperationsGetCall { + 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 *ProjectsLocationsOperationsGetCall) IfNoneMatch(entityTag string) *ProjectsLocationsOperationsGetCall { + 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 *ProjectsLocationsOperationsGetCall) Context(ctx context.Context) *ProjectsLocationsOperationsGetCall { + 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 *ProjectsLocationsOperationsGetCall) Header() http.Header { + if c.header_ == nil { + c.header_ = make(http.Header) + } + return c.header_ +} + +func (c *ProjectsLocationsOperationsGetCall) 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, "v1alpha1/{+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 "migrationcenter.projects.locations.operations.get" call. +// Exactly one of *Operation or error will be non-nil. Any non-2xx +// status code is an error. Response headers are in either +// *Operation.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 *ProjectsLocationsOperationsGetCall) Do(opts ...googleapi.CallOption) (*Operation, 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 := &Operation{ + 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": "v1alpha1/projects/{projectsId}/locations/{locationsId}/operations/{operationsId}", + // "httpMethod": "GET", + // "id": "migrationcenter.projects.locations.operations.get", + // "parameterOrder": [ + // "name" + // ], + // "parameters": { + // "name": { + // "description": "The name of the operation resource.", + // "location": "path", + // "pattern": "^projects/[^/]+/locations/[^/]+/operations/[^/]+$", + // "required": true, + // "type": "string" + // } + // }, + // "path": "v1alpha1/{+name}", + // "response": { + // "$ref": "Operation" + // }, + // "scopes": [ + // "https://www.googleapis.com/auth/cloud-platform" + // ] + // } + +} + +// method id "migrationcenter.projects.locations.operations.list": + +type ProjectsLocationsOperationsListCall 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`. NOTE: the `name` binding allows API services to +// override the binding to use different resource name schemes, such as +// `users/*/operations`. To override the binding, API services can add a +// binding such as "/v1/{name=users/*}/operations" to their service +// configuration. For backwards compatibility, the default name includes +// the operations collection id, however overriding users must ensure +// the name binding is the parent resource, without the operations +// collection id. +// +// - name: The name of the operation's parent resource. +func (r *ProjectsLocationsOperationsService) List(name string) *ProjectsLocationsOperationsListCall { + c := &ProjectsLocationsOperationsListCall{s: r.s, urlParams_: make(gensupport.URLParams)} + c.name = name + return c +} + +// Filter sets the optional parameter "filter": The standard list +// filter. +func (c *ProjectsLocationsOperationsListCall) Filter(filter string) *ProjectsLocationsOperationsListCall { + c.urlParams_.Set("filter", filter) + return c +} + +// PageSize sets the optional parameter "pageSize": The standard list +// page size. +func (c *ProjectsLocationsOperationsListCall) PageSize(pageSize int64) *ProjectsLocationsOperationsListCall { + c.urlParams_.Set("pageSize", fmt.Sprint(pageSize)) + return c +} + +// PageToken sets the optional parameter "pageToken": The standard list +// page token. +func (c *ProjectsLocationsOperationsListCall) PageToken(pageToken string) *ProjectsLocationsOperationsListCall { + 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 *ProjectsLocationsOperationsListCall) Fields(s ...googleapi.Field) *ProjectsLocationsOperationsListCall { + 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 *ProjectsLocationsOperationsListCall) IfNoneMatch(entityTag string) *ProjectsLocationsOperationsListCall { + 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 *ProjectsLocationsOperationsListCall) Context(ctx context.Context) *ProjectsLocationsOperationsListCall { + 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 *ProjectsLocationsOperationsListCall) Header() http.Header { + if c.header_ == nil { + c.header_ = make(http.Header) + } + return c.header_ +} + +func (c *ProjectsLocationsOperationsListCall) 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, "v1alpha1/{+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 "migrationcenter.projects.locations.operations.list" call. +// Exactly one of *ListOperationsResponse or error will be non-nil. Any +// non-2xx status code is an error. Response headers are in either +// *ListOperationsResponse.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 *ProjectsLocationsOperationsListCall) Do(opts ...googleapi.CallOption) (*ListOperationsResponse, 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 := &ListOperationsResponse{ + 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`. NOTE: the `name` binding allows API services to override the binding to use different resource name schemes, such as `users/*/operations`. To override the binding, API services can add a binding such as `\"/v1/{name=users/*}/operations\"` to their service configuration. For backwards compatibility, the default name includes the operations collection id, however overriding users must ensure the name binding is the parent resource, without the operations collection id.", + // "flatPath": "v1alpha1/projects/{projectsId}/locations/{locationsId}/operations", + // "httpMethod": "GET", + // "id": "migrationcenter.projects.locations.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/[^/]+$", + // "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": "v1alpha1/{+name}/operations", + // "response": { + // "$ref": "ListOperationsResponse" + // }, + // "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 *ProjectsLocationsOperationsListCall) Pages(ctx context.Context, f func(*ListOperationsResponse) 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 "migrationcenter.projects.locations.sources.create": + +type ProjectsLocationsSourcesCreateCall struct { + s *Service + parent string + source *Source + urlParams_ gensupport.URLParams + ctx_ context.Context + header_ http.Header +} + +// Create: Creates a new source in a given project and location. +// +// - parent: Value for parent. +func (r *ProjectsLocationsSourcesService) Create(parent string, source *Source) *ProjectsLocationsSourcesCreateCall { + c := &ProjectsLocationsSourcesCreateCall{s: r.s, urlParams_: make(gensupport.URLParams)} + c.parent = parent + c.source = source + return c +} + +// RequestId sets the optional parameter "requestId": An optional +// request ID to identify requests. Specify a unique request ID so that +// if you must retry your request, the server will know to ignore the +// request if it has already been completed. The server will guarantee +// that for at least 60 minutes since the first request. For example, +// consider a situation where you make an initial request and the +// request times out. If you make the request again with the same +// request ID, the server can check if original operation with the same +// request ID was received, and if so, will ignore the second request. +// This prevents clients from accidentally creating duplicate +// commitments. The request ID must be a valid UUID with the exception +// that zero UUID is not supported +// (00000000-0000-0000-0000-000000000000). +func (c *ProjectsLocationsSourcesCreateCall) RequestId(requestId string) *ProjectsLocationsSourcesCreateCall { + c.urlParams_.Set("requestId", requestId) + return c +} + +// SourceId sets the optional parameter "sourceId": Required. User +// specified ID for the source. It will become the last component of the +// source name. The ID must be unique within the project, must conform +// with RFC-1034, is restricted to lower-cased letters, and has a +// maximum length of 63 characters. The ID must match the regular +// expression: `[a-z]([a-z0-9-]{0,61}[a-z0-9])?`. +func (c *ProjectsLocationsSourcesCreateCall) SourceId(sourceId string) *ProjectsLocationsSourcesCreateCall { + c.urlParams_.Set("sourceId", sourceId) + 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 *ProjectsLocationsSourcesCreateCall) Fields(s ...googleapi.Field) *ProjectsLocationsSourcesCreateCall { + 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 *ProjectsLocationsSourcesCreateCall) Context(ctx context.Context) *ProjectsLocationsSourcesCreateCall { + 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 *ProjectsLocationsSourcesCreateCall) Header() http.Header { + if c.header_ == nil { + c.header_ = make(http.Header) + } + return c.header_ +} + +func (c *ProjectsLocationsSourcesCreateCall) 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.source) + 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, "v1alpha1/{+parent}/sources") + 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{ + "parent": c.parent, + }) + return gensupport.SendRequest(c.ctx_, c.s.client, req) +} + +// Do executes the "migrationcenter.projects.locations.sources.create" call. +// Exactly one of *Operation or error will be non-nil. Any non-2xx +// status code is an error. Response headers are in either +// *Operation.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 *ProjectsLocationsSourcesCreateCall) Do(opts ...googleapi.CallOption) (*Operation, 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 := &Operation{ + 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": "Creates a new source in a given project and location.", + // "flatPath": "v1alpha1/projects/{projectsId}/locations/{locationsId}/sources", + // "httpMethod": "POST", + // "id": "migrationcenter.projects.locations.sources.create", + // "parameterOrder": [ + // "parent" + // ], + // "parameters": { + // "parent": { + // "description": "Required. Value for parent.", + // "location": "path", + // "pattern": "^projects/[^/]+/locations/[^/]+$", + // "required": true, + // "type": "string" + // }, + // "requestId": { + // "description": "Optional. An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. The server will guarantee that for at least 60 minutes since the first request. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000).", + // "location": "query", + // "type": "string" + // }, + // "sourceId": { + // "description": "Required. User specified ID for the source. It will become the last component of the source name. The ID must be unique within the project, must conform with RFC-1034, is restricted to lower-cased letters, and has a maximum length of 63 characters. The ID must match the regular expression: `[a-z]([a-z0-9-]{0,61}[a-z0-9])?`.", + // "location": "query", + // "type": "string" + // } + // }, + // "path": "v1alpha1/{+parent}/sources", + // "request": { + // "$ref": "Source" + // }, + // "response": { + // "$ref": "Operation" + // }, + // "scopes": [ + // "https://www.googleapis.com/auth/cloud-platform" + // ] + // } + +} + +// method id "migrationcenter.projects.locations.sources.delete": + +type ProjectsLocationsSourcesDeleteCall struct { + s *Service + name string + urlParams_ gensupport.URLParams + ctx_ context.Context + header_ http.Header +} + +// Delete: Deletes a source. +// +// - name: Name of the resource. +func (r *ProjectsLocationsSourcesService) Delete(name string) *ProjectsLocationsSourcesDeleteCall { + c := &ProjectsLocationsSourcesDeleteCall{s: r.s, urlParams_: make(gensupport.URLParams)} + c.name = name + return c +} + +// RequestId sets the optional parameter "requestId": An optional +// request ID to identify requests. Specify a unique request ID so that +// if you must retry your request, the server will know to ignore the +// request if it has already been completed. The server will guarantee +// that for at least 60 minutes after the first request. For example, +// consider a situation where you make an initial request and the +// request times out. If you make the request again with the same +// request ID, the server can check if original operation with the same +// request ID was received, and if so, will ignore the second request. +// This prevents clients from accidentally creating duplicate +// commitments. The request ID must be a valid UUID with the exception +// that zero UUID is not supported +// (00000000-0000-0000-0000-000000000000). +func (c *ProjectsLocationsSourcesDeleteCall) RequestId(requestId string) *ProjectsLocationsSourcesDeleteCall { + c.urlParams_.Set("requestId", requestId) + 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 *ProjectsLocationsSourcesDeleteCall) Fields(s ...googleapi.Field) *ProjectsLocationsSourcesDeleteCall { + 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 *ProjectsLocationsSourcesDeleteCall) Context(ctx context.Context) *ProjectsLocationsSourcesDeleteCall { + 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 *ProjectsLocationsSourcesDeleteCall) Header() http.Header { + if c.header_ == nil { + c.header_ = make(http.Header) + } + return c.header_ +} + +func (c *ProjectsLocationsSourcesDeleteCall) 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, "v1alpha1/{+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 "migrationcenter.projects.locations.sources.delete" call. +// Exactly one of *Operation or error will be non-nil. Any non-2xx +// status code is an error. Response headers are in either +// *Operation.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 *ProjectsLocationsSourcesDeleteCall) Do(opts ...googleapi.CallOption) (*Operation, 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 := &Operation{ + 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 source.", + // "flatPath": "v1alpha1/projects/{projectsId}/locations/{locationsId}/sources/{sourcesId}", + // "httpMethod": "DELETE", + // "id": "migrationcenter.projects.locations.sources.delete", + // "parameterOrder": [ + // "name" + // ], + // "parameters": { + // "name": { + // "description": "Required. Name of the resource.", + // "location": "path", + // "pattern": "^projects/[^/]+/locations/[^/]+/sources/[^/]+$", + // "required": true, + // "type": "string" + // }, + // "requestId": { + // "description": "Optional. An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. The server will guarantee that for at least 60 minutes after the first request. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000).", + // "location": "query", + // "type": "string" + // } + // }, + // "path": "v1alpha1/{+name}", + // "response": { + // "$ref": "Operation" + // }, + // "scopes": [ + // "https://www.googleapis.com/auth/cloud-platform" + // ] + // } + +} + +// method id "migrationcenter.projects.locations.sources.get": + +type ProjectsLocationsSourcesGetCall struct { + s *Service + name string + urlParams_ gensupport.URLParams + ifNoneMatch_ string + ctx_ context.Context + header_ http.Header +} + +// Get: Gets the details of a source. +// +// - name: Name of the resource. +func (r *ProjectsLocationsSourcesService) Get(name string) *ProjectsLocationsSourcesGetCall { + c := &ProjectsLocationsSourcesGetCall{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 *ProjectsLocationsSourcesGetCall) Fields(s ...googleapi.Field) *ProjectsLocationsSourcesGetCall { + 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 *ProjectsLocationsSourcesGetCall) IfNoneMatch(entityTag string) *ProjectsLocationsSourcesGetCall { + 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 *ProjectsLocationsSourcesGetCall) Context(ctx context.Context) *ProjectsLocationsSourcesGetCall { + 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 *ProjectsLocationsSourcesGetCall) Header() http.Header { + if c.header_ == nil { + c.header_ = make(http.Header) + } + return c.header_ +} + +func (c *ProjectsLocationsSourcesGetCall) 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, "v1alpha1/{+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 "migrationcenter.projects.locations.sources.get" call. +// Exactly one of *Source or error will be non-nil. Any non-2xx status +// code is an error. Response headers are in either +// *Source.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 *ProjectsLocationsSourcesGetCall) Do(opts ...googleapi.CallOption) (*Source, 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 := &Source{ + 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 details of a source.", + // "flatPath": "v1alpha1/projects/{projectsId}/locations/{locationsId}/sources/{sourcesId}", + // "httpMethod": "GET", + // "id": "migrationcenter.projects.locations.sources.get", + // "parameterOrder": [ + // "name" + // ], + // "parameters": { + // "name": { + // "description": "Required. Name of the resource.", + // "location": "path", + // "pattern": "^projects/[^/]+/locations/[^/]+/sources/[^/]+$", + // "required": true, + // "type": "string" + // } + // }, + // "path": "v1alpha1/{+name}", + // "response": { + // "$ref": "Source" + // }, + // "scopes": [ + // "https://www.googleapis.com/auth/cloud-platform" + // ] + // } + +} + +// method id "migrationcenter.projects.locations.sources.list": + +type ProjectsLocationsSourcesListCall struct { + s *Service + parent string + urlParams_ gensupport.URLParams + ifNoneMatch_ string + ctx_ context.Context + header_ http.Header +} + +// List: Lists all the sources in a given project and location. +// +// - parent: Parent value for `ListSourcesRequest`. +func (r *ProjectsLocationsSourcesService) List(parent string) *ProjectsLocationsSourcesListCall { + c := &ProjectsLocationsSourcesListCall{s: r.s, urlParams_: make(gensupport.URLParams)} + c.parent = parent + return c +} + +// Filter sets the optional parameter "filter": Filtering results. +func (c *ProjectsLocationsSourcesListCall) Filter(filter string) *ProjectsLocationsSourcesListCall { + c.urlParams_.Set("filter", filter) + return c +} + +// OrderBy sets the optional parameter "orderBy": Field to sort by. See +// https://google.aip.dev/132#ordering for more details. +func (c *ProjectsLocationsSourcesListCall) OrderBy(orderBy string) *ProjectsLocationsSourcesListCall { + c.urlParams_.Set("orderBy", orderBy) + return c +} + +// PageSize sets the optional parameter "pageSize": Requested page size. +// The server may return fewer items than requested. If unspecified, the +// server will pick an appropriate default value. +func (c *ProjectsLocationsSourcesListCall) PageSize(pageSize int64) *ProjectsLocationsSourcesListCall { + c.urlParams_.Set("pageSize", fmt.Sprint(pageSize)) + return c +} + +// PageToken sets the optional parameter "pageToken": A token +// identifying a page of results that the server should return. +func (c *ProjectsLocationsSourcesListCall) PageToken(pageToken string) *ProjectsLocationsSourcesListCall { + 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 *ProjectsLocationsSourcesListCall) Fields(s ...googleapi.Field) *ProjectsLocationsSourcesListCall { + 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 *ProjectsLocationsSourcesListCall) IfNoneMatch(entityTag string) *ProjectsLocationsSourcesListCall { + 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 *ProjectsLocationsSourcesListCall) Context(ctx context.Context) *ProjectsLocationsSourcesListCall { + 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 *ProjectsLocationsSourcesListCall) Header() http.Header { + if c.header_ == nil { + c.header_ = make(http.Header) + } + return c.header_ +} + +func (c *ProjectsLocationsSourcesListCall) 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, "v1alpha1/{+parent}/sources") + 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{ + "parent": c.parent, + }) + return gensupport.SendRequest(c.ctx_, c.s.client, req) +} + +// Do executes the "migrationcenter.projects.locations.sources.list" call. +// Exactly one of *ListSourcesResponse or error will be non-nil. Any +// non-2xx status code is an error. Response headers are in either +// *ListSourcesResponse.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 *ProjectsLocationsSourcesListCall) Do(opts ...googleapi.CallOption) (*ListSourcesResponse, 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 := &ListSourcesResponse{ + 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 all the sources in a given project and location.", + // "flatPath": "v1alpha1/projects/{projectsId}/locations/{locationsId}/sources", + // "httpMethod": "GET", + // "id": "migrationcenter.projects.locations.sources.list", + // "parameterOrder": [ + // "parent" + // ], + // "parameters": { + // "filter": { + // "description": "Filtering results.", + // "location": "query", + // "type": "string" + // }, + // "orderBy": { + // "description": "Field to sort by. See https://google.aip.dev/132#ordering for more details.", + // "location": "query", + // "type": "string" + // }, + // "pageSize": { + // "description": "Requested page size. The server may return fewer items than requested. If unspecified, the server will pick an appropriate default value.", + // "format": "int32", + // "location": "query", + // "type": "integer" + // }, + // "pageToken": { + // "description": "A token identifying a page of results that the server should return.", + // "location": "query", + // "type": "string" + // }, + // "parent": { + // "description": "Required. Parent value for `ListSourcesRequest`.", + // "location": "path", + // "pattern": "^projects/[^/]+/locations/[^/]+$", + // "required": true, + // "type": "string" + // } + // }, + // "path": "v1alpha1/{+parent}/sources", + // "response": { + // "$ref": "ListSourcesResponse" + // }, + // "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 *ProjectsLocationsSourcesListCall) Pages(ctx context.Context, f func(*ListSourcesResponse) 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 "migrationcenter.projects.locations.sources.patch": + +type ProjectsLocationsSourcesPatchCall struct { + s *Service + name string + source *Source + urlParams_ gensupport.URLParams + ctx_ context.Context + header_ http.Header +} + +// Patch: Updates the parameters of a source. +// +// - name: Output only. The full name of the source. +func (r *ProjectsLocationsSourcesService) Patch(name string, source *Source) *ProjectsLocationsSourcesPatchCall { + c := &ProjectsLocationsSourcesPatchCall{s: r.s, urlParams_: make(gensupport.URLParams)} + c.name = name + c.source = source + return c +} + +// RequestId sets the optional parameter "requestId": An optional +// request ID to identify requests. Specify a unique request ID so that +// if you must retry your request, the server will know to ignore the +// request if it has already been completed. The server will guarantee +// that for at least 60 minutes since the first request. For example, +// consider a situation where you make an initial request and the +// request times out. If you make the request again with the same +// request ID, the server can check if original operation with the same +// request ID was received, and if so, will ignore the second request. +// This prevents clients from accidentally creating duplicate +// commitments. The request ID must be a valid UUID with the exception +// that zero UUID is not supported +// (00000000-0000-0000-0000-000000000000). +func (c *ProjectsLocationsSourcesPatchCall) RequestId(requestId string) *ProjectsLocationsSourcesPatchCall { + c.urlParams_.Set("requestId", requestId) + return c +} + +// UpdateMask sets the optional parameter "updateMask": Required. Field +// mask is used to specify the fields to be overwritten in the `Source` +// resource by the update. The values specified in the `update_mask` +// field are relative to the resource, not the full request. A field +// will be overwritten if it is in the mask. A single * value in the +// mask lets you to overwrite all fields. +func (c *ProjectsLocationsSourcesPatchCall) UpdateMask(updateMask string) *ProjectsLocationsSourcesPatchCall { + c.urlParams_.Set("updateMask", updateMask) + 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 *ProjectsLocationsSourcesPatchCall) Fields(s ...googleapi.Field) *ProjectsLocationsSourcesPatchCall { + 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 *ProjectsLocationsSourcesPatchCall) Context(ctx context.Context) *ProjectsLocationsSourcesPatchCall { + 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 *ProjectsLocationsSourcesPatchCall) Header() http.Header { + if c.header_ == nil { + c.header_ = make(http.Header) + } + return c.header_ +} + +func (c *ProjectsLocationsSourcesPatchCall) 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.source) + 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, "v1alpha1/{+name}") + urls += "?" + c.urlParams_.Encode() + req, err := http.NewRequest("PATCH", 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 "migrationcenter.projects.locations.sources.patch" call. +// Exactly one of *Operation or error will be non-nil. Any non-2xx +// status code is an error. Response headers are in either +// *Operation.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 *ProjectsLocationsSourcesPatchCall) Do(opts ...googleapi.CallOption) (*Operation, 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 := &Operation{ + 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": "Updates the parameters of a source.", + // "flatPath": "v1alpha1/projects/{projectsId}/locations/{locationsId}/sources/{sourcesId}", + // "httpMethod": "PATCH", + // "id": "migrationcenter.projects.locations.sources.patch", + // "parameterOrder": [ + // "name" + // ], + // "parameters": { + // "name": { + // "description": "Output only. The full name of the source.", + // "location": "path", + // "pattern": "^projects/[^/]+/locations/[^/]+/sources/[^/]+$", + // "required": true, + // "type": "string" + // }, + // "requestId": { + // "description": "Optional. An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. The server will guarantee that for at least 60 minutes since the first request. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000).", + // "location": "query", + // "type": "string" + // }, + // "updateMask": { + // "description": "Required. Field mask is used to specify the fields to be overwritten in the `Source` resource by the update. The values specified in the `update_mask` field are relative to the resource, not the full request. A field will be overwritten if it is in the mask. A single * value in the mask lets you to overwrite all fields.", + // "format": "google-fieldmask", + // "location": "query", + // "type": "string" + // } + // }, + // "path": "v1alpha1/{+name}", + // "request": { + // "$ref": "Source" + // }, + // "response": { + // "$ref": "Operation" + // }, + // "scopes": [ + // "https://www.googleapis.com/auth/cloud-platform" + // ] + // } + +} diff --git a/networkmanagement/v1/networkmanagement-api.json b/networkmanagement/v1/networkmanagement-api.json index 2c643ea0807..52f6fad8af9 100644 --- a/networkmanagement/v1/networkmanagement-api.json +++ b/networkmanagement/v1/networkmanagement-api.json @@ -591,7 +591,7 @@ } } }, - "revision": "20230201", + "revision": "20230222", "rootUrl": "https://networkmanagement.googleapis.com/", "schemas": { "AbortInfo": { @@ -997,6 +997,7 @@ "DROPPED_INSIDE_GKE_SERVICE", "DROPPED_INSIDE_CLOUD_SQL_SERVICE", "GOOGLE_MANAGED_SERVICE_NO_PEERING", + "GKE_PSC_ENDPOINT_MISSING", "CLOUD_SQL_INSTANCE_NO_IP_ADDRESS", "GKE_CONTROL_PLANE_REGION_MISMATCH", "PUBLIC_GKE_CONTROL_PLANE_TO_PRIVATE_DESTINATION", @@ -1008,7 +1009,8 @@ "VPC_CONNECTOR_NOT_SET", "VPC_CONNECTOR_NOT_RUNNING", "PSC_CONNECTION_NOT_ACCEPTED", - "CLOUD_RUN_REVISION_NOT_READY" + "CLOUD_RUN_REVISION_NOT_READY", + "DROPPED_INSIDE_PSC_SERVICE_PRODUCER" ], "enumDescriptions": [ "Cause is unspecified.", @@ -1035,6 +1037,7 @@ "Packet was dropped inside Google Kubernetes Engine Service.", "Packet was dropped inside Cloud SQL Service.", "Packet was dropped because there is no peering between the originating network and the Google Managed Services Network.", + "Packet was dropped because the GKE cluster uses Private Service Connect (PSC), but the PSC endpoint is not found in the project.", "Packet was dropped because the Cloud SQL instance has neither a private nor a public IP address.", "Packet was dropped because a GKE cluster private endpoint is unreachable from a region different from the cluster's region.", "Packet sent from a public GKE cluster control plane to a private IP address.", @@ -1046,7 +1049,8 @@ "Packet could be dropped because no VPC connector is set.", "Packet could be dropped because the VPC connector is not in a running state.", "The Private Service Connect endpoint is in a project that is not approved to connect to the service.", - "Packet sent from a Cloud Run revision that is not ready." + "Packet sent from a Cloud Run revision that is not ready.", + "Packet was dropped inside Private Service Connect service producer." ], "type": "string" }, diff --git a/networkmanagement/v1/networkmanagement-gen.go b/networkmanagement/v1/networkmanagement-gen.go index b5b13fc4815..fce3c8eebd1 100644 --- a/networkmanagement/v1/networkmanagement-gen.go +++ b/networkmanagement/v1/networkmanagement-gen.go @@ -928,6 +928,9 @@ type DropInfo struct { // "GOOGLE_MANAGED_SERVICE_NO_PEERING" - Packet was dropped because // there is no peering between the originating network and the Google // Managed Services Network. + // "GKE_PSC_ENDPOINT_MISSING" - Packet was dropped because the GKE + // cluster uses Private Service Connect (PSC), but the PSC endpoint is + // not found in the project. // "CLOUD_SQL_INSTANCE_NO_IP_ADDRESS" - Packet was dropped because the // Cloud SQL instance has neither a private nor a public IP address. // "GKE_CONTROL_PLANE_REGION_MISMATCH" - Packet was dropped because a @@ -957,6 +960,8 @@ type DropInfo struct { // service. // "CLOUD_RUN_REVISION_NOT_READY" - Packet sent from a Cloud Run // revision that is not ready. + // "DROPPED_INSIDE_PSC_SERVICE_PRODUCER" - Packet was dropped inside + // Private Service Connect service producer. Cause string `json:"cause,omitempty"` // ResourceUri: URI of the resource that caused the drop. diff --git a/networkmanagement/v1beta1/networkmanagement-api.json b/networkmanagement/v1beta1/networkmanagement-api.json index df7d5ff5264..9759130ed8d 100644 --- a/networkmanagement/v1beta1/networkmanagement-api.json +++ b/networkmanagement/v1beta1/networkmanagement-api.json @@ -591,7 +591,7 @@ } } }, - "revision": "20230201", + "revision": "20230222", "rootUrl": "https://networkmanagement.googleapis.com/", "schemas": { "AbortInfo": { @@ -1020,7 +1020,8 @@ "VPC_CONNECTOR_NOT_SET", "VPC_CONNECTOR_NOT_RUNNING", "PSC_CONNECTION_NOT_ACCEPTED", - "CLOUD_RUN_REVISION_NOT_READY" + "CLOUD_RUN_REVISION_NOT_READY", + "DROPPED_INSIDE_PSC_SERVICE_PRODUCER" ], "enumDescriptions": [ "Cause is unspecified.", @@ -1059,7 +1060,8 @@ "Packet could be dropped because no VPC connector is set.", "Packet could be dropped because the VPC connector is not in a running state.", "The Private Service Connect endpoint is in a project that is not approved to connect to the service.", - "Packet sent from a Cloud Run revision that is not ready." + "Packet sent from a Cloud Run revision that is not ready.", + "Packet was dropped inside Private Service Connect service producer." ], "type": "string" }, diff --git a/networkmanagement/v1beta1/networkmanagement-gen.go b/networkmanagement/v1beta1/networkmanagement-gen.go index 946728a762d..8b11a8e4b03 100644 --- a/networkmanagement/v1beta1/networkmanagement-gen.go +++ b/networkmanagement/v1beta1/networkmanagement-gen.go @@ -970,6 +970,8 @@ type DropInfo struct { // service. // "CLOUD_RUN_REVISION_NOT_READY" - Packet sent from a Cloud Run // revision that is not ready. + // "DROPPED_INSIDE_PSC_SERVICE_PRODUCER" - Packet was dropped inside + // Private Service Connect service producer. Cause string `json:"cause,omitempty"` // ResourceUri: URI of the resource that caused the drop. diff --git a/orgpolicy/v2/orgpolicy-api.json b/orgpolicy/v2/orgpolicy-api.json index 0ee4948c309..5374d3374ea 100644 --- a/orgpolicy/v2/orgpolicy-api.json +++ b/orgpolicy/v2/orgpolicy-api.json @@ -915,7 +915,7 @@ } } }, - "revision": "20230209", + "revision": "20230306", "rootUrl": "https://orgpolicy.googleapis.com/", "schemas": { "GoogleCloudOrgpolicyV2AlternatePolicySpec": { @@ -970,6 +970,10 @@ "name": { "description": "Immutable. The resource name of the constraint. Must be in one of the following forms: * `projects/{project_number}/constraints/{constraint_name}` * `folders/{folder_id}/constraints/{constraint_name}` * `organizations/{organization_id}/constraints/{constraint_name}` For example, \"/projects/123/constraints/compute.disableSerialPortAccess\".", "type": "string" + }, + "supportsDryRun": { + "description": "Shows if dry run is supported for this constraint or not.", + "type": "boolean" } }, "type": "object" diff --git a/orgpolicy/v2/orgpolicy-gen.go b/orgpolicy/v2/orgpolicy-gen.go index ee340c91f06..c80d7298928 100644 --- a/orgpolicy/v2/orgpolicy-gen.go +++ b/orgpolicy/v2/orgpolicy-gen.go @@ -340,6 +340,10 @@ type GoogleCloudOrgpolicyV2Constraint struct { // example, "/projects/123/constraints/compute.disableSerialPortAccess". Name string `json:"name,omitempty"` + // SupportsDryRun: Shows if dry run is supported for this constraint or + // not. + SupportsDryRun bool `json:"supportsDryRun,omitempty"` + // ForceSendFields is a list of field names (e.g. "BooleanConstraint") // to unconditionally include in API requests. By default, fields with // empty or default values are omitted from API requests. However, any diff --git a/playdeveloperreporting/v1alpha1/playdeveloperreporting-api.json b/playdeveloperreporting/v1alpha1/playdeveloperreporting-api.json index b1d68bc4eba..e0898e05058 100644 --- a/playdeveloperreporting/v1alpha1/playdeveloperreporting-api.json +++ b/playdeveloperreporting/v1alpha1/playdeveloperreporting-api.json @@ -766,7 +766,7 @@ } } }, - "revision": "20230116", + "revision": "20230304", "rootUrl": "https://playdeveloperreporting.googleapis.com/", "schemas": { "GooglePlayDeveloperReportingV1alpha1Anomaly": { @@ -1094,6 +1094,22 @@ "timelineSpec": { "$ref": "GooglePlayDeveloperReportingV1alpha1TimelineSpec", "description": "Specification of the timeline aggregation parameters. **Supported aggregation periods:** * DAILY: metrics are aggregated in calendar date intervals. Due to historical constraints, the default and only supported timezone is `America/Los_Angeles`." + }, + "userCohort": { + "description": "User view to select. The output data will correspond to the selected view. **Supported values:** * `OS_PUBLIC` To select data from all publicly released Android versions. This is the default. Supports all the above dimensions. * `APP_TESTERS` To select data from users who have opted in to be testers. Supports all the above dimensions. * `OS_BETA` To select data from beta android versions only, excluding data from released android versions. Only the following dimensions are supported: * `versionCode` (int64): version of the app that was running on the user's device. * `osBuild` (string): OS build of the user's device, e.g., \"T1B2.220916.004\".", + "enum": [ + "USER_COHORT_UNSPECIFIED", + "OS_PUBLIC", + "OS_BETA", + "APP_TESTERS" + ], + "enumDescriptions": [ + "Unspecified User cohort. This will automatically choose the default value.", + "This is default view. Contains data from public released android versions only.", + "This is the view with just android beta data excluding released OS version data.", + "This is the view with data only from users who have opted in to be testers for a given app, excluding OS beta data." + ], + "type": "string" } }, "type": "object" @@ -1150,6 +1166,22 @@ "timelineSpec": { "$ref": "GooglePlayDeveloperReportingV1alpha1TimelineSpec", "description": "Specification of the timeline aggregation parameters. **Supported aggregation periods:** * DAILY: metrics are aggregated in calendar date intervals. Due to historical constraints, the default and only supported timezone is `America/Los_Angeles`." + }, + "userCohort": { + "description": "User view to select. The output data will correspond to the selected view. **Supported values:** * `OS_PUBLIC` To select data from all publicly released Android versions. This is the default. Supports all the above dimensions. * `APP_TESTERS` To select data from users who have opted in to be testers. Supports all the above dimensions. * `OS_BETA` To select data from beta android versions only, excluding data from released android versions. Only the following dimensions are supported: * `versionCode` (int64): version of the app that was running on the user's device. * `osBuild` (string): OS build of the user's device, e.g., \"T1B2.220916.004\".", + "enum": [ + "USER_COHORT_UNSPECIFIED", + "OS_PUBLIC", + "OS_BETA", + "APP_TESTERS" + ], + "enumDescriptions": [ + "Unspecified User cohort. This will automatically choose the default value.", + "This is default view. Contains data from public released android versions only.", + "This is the view with just android beta data excluding released OS version data.", + "This is the view with data only from users who have opted in to be testers for a given app, excluding OS beta data." + ], + "type": "string" } }, "type": "object" @@ -1262,6 +1294,22 @@ "timelineSpec": { "$ref": "GooglePlayDeveloperReportingV1alpha1TimelineSpec", "description": "Specification of the timeline aggregation parameters. **Supported aggregation periods:** * DAILY: metrics are aggregated in calendar date intervals. Due to historical constraints, the only supported timezone is `America/Los_Angeles`." + }, + "userCohort": { + "description": "User view to select. The output data will correspond to the selected view. **Supported values:** * `OS_PUBLIC` To select data from all publicly released Android versions. This is the default. Supports all the above dimensions. * `APP_TESTERS` To select data from users who have opted in to be testers. Supports all the above dimensions. * `OS_BETA` To select data from beta android versions only, excluding data from released android versions. Only the following dimensions are supported: * `versionCode` (int64): version of the app that was running on the user's device. * `osBuild` (string): OS build of the user's device, e.g., \"T1B2.220916.004\".", + "enum": [ + "USER_COHORT_UNSPECIFIED", + "OS_PUBLIC", + "OS_BETA", + "APP_TESTERS" + ], + "enumDescriptions": [ + "Unspecified User cohort. This will automatically choose the default value.", + "This is default view. Contains data from public released android versions only.", + "This is the view with just android beta data excluding released OS version data.", + "This is the view with data only from users who have opted in to be testers for a given app, excluding OS beta data." + ], + "type": "string" } }, "type": "object" @@ -1318,6 +1366,22 @@ "timelineSpec": { "$ref": "GooglePlayDeveloperReportingV1alpha1TimelineSpec", "description": "Specification of the timeline aggregation parameters. **Supported aggregation periods:** * DAILY: metrics are aggregated in calendar date intervals. Due to historical constraints, the only supported timezone is `America/Los_Angeles`." + }, + "userCohort": { + "description": "User view to select. The output data will correspond to the selected view. **Supported values:** * `OS_PUBLIC` To select data from all publicly released Android versions. This is the default. Supports all the above dimensions. * `APP_TESTERS` To select data from users who have opted in to be testers. Supports all the above dimensions. * `OS_BETA` To select data from beta android versions only, excluding data from released android versions. Only the following dimensions are supported: * `versionCode` (int64): version of the app that was running on the user's device. * `osBuild` (string): OS build of the user's device, e.g., \"T1B2.220916.004\".", + "enum": [ + "USER_COHORT_UNSPECIFIED", + "OS_PUBLIC", + "OS_BETA", + "APP_TESTERS" + ], + "enumDescriptions": [ + "Unspecified User cohort. This will automatically choose the default value.", + "This is default view. Contains data from public released android versions only.", + "This is the view with just android beta data excluding released OS version data.", + "This is the view with data only from users who have opted in to be testers for a given app, excluding OS beta data." + ], + "type": "string" } }, "type": "object" diff --git a/playdeveloperreporting/v1alpha1/playdeveloperreporting-gen.go b/playdeveloperreporting/v1alpha1/playdeveloperreporting-gen.go index fdc6cfe6f79..f76acb6fade 100644 --- a/playdeveloperreporting/v1alpha1/playdeveloperreporting-gen.go +++ b/playdeveloperreporting/v1alpha1/playdeveloperreporting-gen.go @@ -1104,6 +1104,28 @@ type GooglePlayDeveloperReportingV1alpha1QueryAnrRateMetricSetRequest struct { // and only supported timezone is `America/Los_Angeles`. TimelineSpec *GooglePlayDeveloperReportingV1alpha1TimelineSpec `json:"timelineSpec,omitempty"` + // UserCohort: User view to select. The output data will correspond to + // the selected view. **Supported values:** * `OS_PUBLIC` To select data + // from all publicly released Android versions. This is the default. + // Supports all the above dimensions. * `APP_TESTERS` To select data + // from users who have opted in to be testers. Supports all the above + // dimensions. * `OS_BETA` To select data from beta android versions + // only, excluding data from released android versions. Only the + // following dimensions are supported: * `versionCode` (int64): version + // of the app that was running on the user's device. * `osBuild` + // (string): OS build of the user's device, e.g., "T1B2.220916.004". + // + // Possible values: + // "USER_COHORT_UNSPECIFIED" - Unspecified User cohort. This will + // automatically choose the default value. + // "OS_PUBLIC" - This is default view. Contains data from public + // released android versions only. + // "OS_BETA" - This is the view with just android beta data excluding + // released OS version data. + // "APP_TESTERS" - This is the view with data only from users who have + // opted in to be testers for a given app, excluding OS beta data. + UserCohort string `json:"userCohort,omitempty"` + // ForceSendFields is a list of field names (e.g. "Dimensions") to // unconditionally include in API requests. By default, fields with // empty or default values are omitted from API requests. However, any @@ -1247,6 +1269,28 @@ type GooglePlayDeveloperReportingV1alpha1QueryCrashRateMetricSetRequest struct { // and only supported timezone is `America/Los_Angeles`. TimelineSpec *GooglePlayDeveloperReportingV1alpha1TimelineSpec `json:"timelineSpec,omitempty"` + // UserCohort: User view to select. The output data will correspond to + // the selected view. **Supported values:** * `OS_PUBLIC` To select data + // from all publicly released Android versions. This is the default. + // Supports all the above dimensions. * `APP_TESTERS` To select data + // from users who have opted in to be testers. Supports all the above + // dimensions. * `OS_BETA` To select data from beta android versions + // only, excluding data from released android versions. Only the + // following dimensions are supported: * `versionCode` (int64): version + // of the app that was running on the user's device. * `osBuild` + // (string): OS build of the user's device, e.g., "T1B2.220916.004". + // + // Possible values: + // "USER_COHORT_UNSPECIFIED" - Unspecified User cohort. This will + // automatically choose the default value. + // "OS_PUBLIC" - This is default view. Contains data from public + // released android versions only. + // "OS_BETA" - This is the view with just android beta data excluding + // released OS version data. + // "APP_TESTERS" - This is the view with data only from users who have + // opted in to be testers for a given app, excluding OS beta data. + UserCohort string `json:"userCohort,omitempty"` + // ForceSendFields is a list of field names (e.g. "Dimensions") to // unconditionally include in API requests. By default, fields with // empty or default values are omitted from API requests. However, any @@ -1499,6 +1543,28 @@ type GooglePlayDeveloperReportingV1alpha1QueryExcessiveWakeupRateMetricSetReques // supported timezone is `America/Los_Angeles`. TimelineSpec *GooglePlayDeveloperReportingV1alpha1TimelineSpec `json:"timelineSpec,omitempty"` + // UserCohort: User view to select. The output data will correspond to + // the selected view. **Supported values:** * `OS_PUBLIC` To select data + // from all publicly released Android versions. This is the default. + // Supports all the above dimensions. * `APP_TESTERS` To select data + // from users who have opted in to be testers. Supports all the above + // dimensions. * `OS_BETA` To select data from beta android versions + // only, excluding data from released android versions. Only the + // following dimensions are supported: * `versionCode` (int64): version + // of the app that was running on the user's device. * `osBuild` + // (string): OS build of the user's device, e.g., "T1B2.220916.004". + // + // Possible values: + // "USER_COHORT_UNSPECIFIED" - Unspecified User cohort. This will + // automatically choose the default value. + // "OS_PUBLIC" - This is default view. Contains data from public + // released android versions only. + // "OS_BETA" - This is the view with just android beta data excluding + // released OS version data. + // "APP_TESTERS" - This is the view with data only from users who have + // opted in to be testers for a given app, excluding OS beta data. + UserCohort string `json:"userCohort,omitempty"` + // ForceSendFields is a list of field names (e.g. "Dimensions") to // unconditionally include in API requests. By default, fields with // empty or default values are omitted from API requests. However, any @@ -1631,6 +1697,28 @@ type GooglePlayDeveloperReportingV1alpha1QueryStuckBackgroundWakelockRateMetricS // supported timezone is `America/Los_Angeles`. TimelineSpec *GooglePlayDeveloperReportingV1alpha1TimelineSpec `json:"timelineSpec,omitempty"` + // UserCohort: User view to select. The output data will correspond to + // the selected view. **Supported values:** * `OS_PUBLIC` To select data + // from all publicly released Android versions. This is the default. + // Supports all the above dimensions. * `APP_TESTERS` To select data + // from users who have opted in to be testers. Supports all the above + // dimensions. * `OS_BETA` To select data from beta android versions + // only, excluding data from released android versions. Only the + // following dimensions are supported: * `versionCode` (int64): version + // of the app that was running on the user's device. * `osBuild` + // (string): OS build of the user's device, e.g., "T1B2.220916.004". + // + // Possible values: + // "USER_COHORT_UNSPECIFIED" - Unspecified User cohort. This will + // automatically choose the default value. + // "OS_PUBLIC" - This is default view. Contains data from public + // released android versions only. + // "OS_BETA" - This is the view with just android beta data excluding + // released OS version data. + // "APP_TESTERS" - This is the view with data only from users who have + // opted in to be testers for a given app, excluding OS beta data. + UserCohort string `json:"userCohort,omitempty"` + // ForceSendFields is a list of field names (e.g. "Dimensions") to // unconditionally include in API requests. By default, fields with // empty or default values are omitted from API requests. However, any diff --git a/playdeveloperreporting/v1beta1/playdeveloperreporting-api.json b/playdeveloperreporting/v1beta1/playdeveloperreporting-api.json index 2a9c1a14f10..955b37fc371 100644 --- a/playdeveloperreporting/v1beta1/playdeveloperreporting-api.json +++ b/playdeveloperreporting/v1beta1/playdeveloperreporting-api.json @@ -383,7 +383,7 @@ } } }, - "revision": "20230116", + "revision": "20230304", "rootUrl": "https://playdeveloperreporting.googleapis.com/", "schemas": { "GooglePlayDeveloperReportingV1beta1Anomaly": { @@ -630,6 +630,22 @@ "timelineSpec": { "$ref": "GooglePlayDeveloperReportingV1beta1TimelineSpec", "description": "Specification of the timeline aggregation parameters. **Supported aggregation periods:** * DAILY: metrics are aggregated in calendar date intervals. Due to historical constraints, the default and only supported timezone is `America/Los_Angeles`." + }, + "userCohort": { + "description": "User view to select. The output data will correspond to the selected view. **Supported values:** * `OS_PUBLIC` To select data from all publicly released Android versions. This is the default. Supports all the above dimensions. * `APP_TESTERS` To select data from users who have opted in to be testers. Supports all the above dimensions. * `OS_BETA` To select data from beta android versions only, excluding data from released android versions. Only the following dimensions are supported: * `versionCode` (int64): version of the app that was running on the user's device. * `osBuild` (string): OS build of the user's device, e.g., \"T1B2.220916.004\".", + "enum": [ + "USER_COHORT_UNSPECIFIED", + "OS_PUBLIC", + "OS_BETA", + "APP_TESTERS" + ], + "enumDescriptions": [ + "Unspecified User cohort. This will automatically choose the default value.", + "This is default view. Contains data from public released android versions only.", + "This is the view with just android beta data excluding released OS version data.", + "This is the view with data only from users who have opted in to be testers for a given app, excluding OS beta data." + ], + "type": "string" } }, "type": "object" @@ -686,6 +702,22 @@ "timelineSpec": { "$ref": "GooglePlayDeveloperReportingV1beta1TimelineSpec", "description": "Specification of the timeline aggregation parameters. **Supported aggregation periods:** * DAILY: metrics are aggregated in calendar date intervals. Due to historical constraints, the default and only supported timezone is `America/Los_Angeles`." + }, + "userCohort": { + "description": "User view to select. The output data will correspond to the selected view. **Supported values:** * `OS_PUBLIC` To select data from all publicly released Android versions. This is the default. Supports all the above dimensions. * `APP_TESTERS` To select data from users who have opted in to be testers. Supports all the above dimensions. * `OS_BETA` To select data from beta android versions only, excluding data from released android versions. Only the following dimensions are supported: * `versionCode` (int64): version of the app that was running on the user's device. * `osBuild` (string): OS build of the user's device, e.g., \"T1B2.220916.004\".", + "enum": [ + "USER_COHORT_UNSPECIFIED", + "OS_PUBLIC", + "OS_BETA", + "APP_TESTERS" + ], + "enumDescriptions": [ + "Unspecified User cohort. This will automatically choose the default value.", + "This is default view. Contains data from public released android versions only.", + "This is the view with just android beta data excluding released OS version data.", + "This is the view with data only from users who have opted in to be testers for a given app, excluding OS beta data." + ], + "type": "string" } }, "type": "object" @@ -742,6 +774,22 @@ "timelineSpec": { "$ref": "GooglePlayDeveloperReportingV1beta1TimelineSpec", "description": "Specification of the timeline aggregation parameters. **Supported aggregation periods:** * DAILY: metrics are aggregated in calendar date intervals. Due to historical constraints, the only supported timezone is `America/Los_Angeles`." + }, + "userCohort": { + "description": "User view to select. The output data will correspond to the selected view. **Supported values:** * `OS_PUBLIC` To select data from all publicly released Android versions. This is the default. Supports all the above dimensions. * `APP_TESTERS` To select data from users who have opted in to be testers. Supports all the above dimensions. * `OS_BETA` To select data from beta android versions only, excluding data from released android versions. Only the following dimensions are supported: * `versionCode` (int64): version of the app that was running on the user's device. * `osBuild` (string): OS build of the user's device, e.g., \"T1B2.220916.004\".", + "enum": [ + "USER_COHORT_UNSPECIFIED", + "OS_PUBLIC", + "OS_BETA", + "APP_TESTERS" + ], + "enumDescriptions": [ + "Unspecified User cohort. This will automatically choose the default value.", + "This is default view. Contains data from public released android versions only.", + "This is the view with just android beta data excluding released OS version data.", + "This is the view with data only from users who have opted in to be testers for a given app, excluding OS beta data." + ], + "type": "string" } }, "type": "object" @@ -798,6 +846,22 @@ "timelineSpec": { "$ref": "GooglePlayDeveloperReportingV1beta1TimelineSpec", "description": "Specification of the timeline aggregation parameters. **Supported aggregation periods:** * DAILY: metrics are aggregated in calendar date intervals. Due to historical constraints, the only supported timezone is `America/Los_Angeles`." + }, + "userCohort": { + "description": "User view to select. The output data will correspond to the selected view. **Supported values:** * `OS_PUBLIC` To select data from all publicly released Android versions. This is the default. Supports all the above dimensions. * `APP_TESTERS` To select data from users who have opted in to be testers. Supports all the above dimensions. * `OS_BETA` To select data from beta android versions only, excluding data from released android versions. Only the following dimensions are supported: * `versionCode` (int64): version of the app that was running on the user's device. * `osBuild` (string): OS build of the user's device, e.g., \"T1B2.220916.004\".", + "enum": [ + "USER_COHORT_UNSPECIFIED", + "OS_PUBLIC", + "OS_BETA", + "APP_TESTERS" + ], + "enumDescriptions": [ + "Unspecified User cohort. This will automatically choose the default value.", + "This is default view. Contains data from public released android versions only.", + "This is the view with just android beta data excluding released OS version data.", + "This is the view with data only from users who have opted in to be testers for a given app, excluding OS beta data." + ], + "type": "string" } }, "type": "object" diff --git a/playdeveloperreporting/v1beta1/playdeveloperreporting-gen.go b/playdeveloperreporting/v1beta1/playdeveloperreporting-gen.go index cc374a5c5d5..ab727e1d26d 100644 --- a/playdeveloperreporting/v1beta1/playdeveloperreporting-gen.go +++ b/playdeveloperreporting/v1beta1/playdeveloperreporting-gen.go @@ -852,6 +852,28 @@ type GooglePlayDeveloperReportingV1beta1QueryAnrRateMetricSetRequest struct { // and only supported timezone is `America/Los_Angeles`. TimelineSpec *GooglePlayDeveloperReportingV1beta1TimelineSpec `json:"timelineSpec,omitempty"` + // UserCohort: User view to select. The output data will correspond to + // the selected view. **Supported values:** * `OS_PUBLIC` To select data + // from all publicly released Android versions. This is the default. + // Supports all the above dimensions. * `APP_TESTERS` To select data + // from users who have opted in to be testers. Supports all the above + // dimensions. * `OS_BETA` To select data from beta android versions + // only, excluding data from released android versions. Only the + // following dimensions are supported: * `versionCode` (int64): version + // of the app that was running on the user's device. * `osBuild` + // (string): OS build of the user's device, e.g., "T1B2.220916.004". + // + // Possible values: + // "USER_COHORT_UNSPECIFIED" - Unspecified User cohort. This will + // automatically choose the default value. + // "OS_PUBLIC" - This is default view. Contains data from public + // released android versions only. + // "OS_BETA" - This is the view with just android beta data excluding + // released OS version data. + // "APP_TESTERS" - This is the view with data only from users who have + // opted in to be testers for a given app, excluding OS beta data. + UserCohort string `json:"userCohort,omitempty"` + // ForceSendFields is a list of field names (e.g. "Dimensions") to // unconditionally include in API requests. By default, fields with // empty or default values are omitted from API requests. However, any @@ -995,6 +1017,28 @@ type GooglePlayDeveloperReportingV1beta1QueryCrashRateMetricSetRequest struct { // and only supported timezone is `America/Los_Angeles`. TimelineSpec *GooglePlayDeveloperReportingV1beta1TimelineSpec `json:"timelineSpec,omitempty"` + // UserCohort: User view to select. The output data will correspond to + // the selected view. **Supported values:** * `OS_PUBLIC` To select data + // from all publicly released Android versions. This is the default. + // Supports all the above dimensions. * `APP_TESTERS` To select data + // from users who have opted in to be testers. Supports all the above + // dimensions. * `OS_BETA` To select data from beta android versions + // only, excluding data from released android versions. Only the + // following dimensions are supported: * `versionCode` (int64): version + // of the app that was running on the user's device. * `osBuild` + // (string): OS build of the user's device, e.g., "T1B2.220916.004". + // + // Possible values: + // "USER_COHORT_UNSPECIFIED" - Unspecified User cohort. This will + // automatically choose the default value. + // "OS_PUBLIC" - This is default view. Contains data from public + // released android versions only. + // "OS_BETA" - This is the view with just android beta data excluding + // released OS version data. + // "APP_TESTERS" - This is the view with data only from users who have + // opted in to be testers for a given app, excluding OS beta data. + UserCohort string `json:"userCohort,omitempty"` + // ForceSendFields is a list of field names (e.g. "Dimensions") to // unconditionally include in API requests. By default, fields with // empty or default values are omitted from API requests. However, any @@ -1125,6 +1169,28 @@ type GooglePlayDeveloperReportingV1beta1QueryExcessiveWakeupRateMetricSetRequest // supported timezone is `America/Los_Angeles`. TimelineSpec *GooglePlayDeveloperReportingV1beta1TimelineSpec `json:"timelineSpec,omitempty"` + // UserCohort: User view to select. The output data will correspond to + // the selected view. **Supported values:** * `OS_PUBLIC` To select data + // from all publicly released Android versions. This is the default. + // Supports all the above dimensions. * `APP_TESTERS` To select data + // from users who have opted in to be testers. Supports all the above + // dimensions. * `OS_BETA` To select data from beta android versions + // only, excluding data from released android versions. Only the + // following dimensions are supported: * `versionCode` (int64): version + // of the app that was running on the user's device. * `osBuild` + // (string): OS build of the user's device, e.g., "T1B2.220916.004". + // + // Possible values: + // "USER_COHORT_UNSPECIFIED" - Unspecified User cohort. This will + // automatically choose the default value. + // "OS_PUBLIC" - This is default view. Contains data from public + // released android versions only. + // "OS_BETA" - This is the view with just android beta data excluding + // released OS version data. + // "APP_TESTERS" - This is the view with data only from users who have + // opted in to be testers for a given app, excluding OS beta data. + UserCohort string `json:"userCohort,omitempty"` + // ForceSendFields is a list of field names (e.g. "Dimensions") to // unconditionally include in API requests. By default, fields with // empty or default values are omitted from API requests. However, any @@ -1257,6 +1323,28 @@ type GooglePlayDeveloperReportingV1beta1QueryStuckBackgroundWakelockRateMetricSe // supported timezone is `America/Los_Angeles`. TimelineSpec *GooglePlayDeveloperReportingV1beta1TimelineSpec `json:"timelineSpec,omitempty"` + // UserCohort: User view to select. The output data will correspond to + // the selected view. **Supported values:** * `OS_PUBLIC` To select data + // from all publicly released Android versions. This is the default. + // Supports all the above dimensions. * `APP_TESTERS` To select data + // from users who have opted in to be testers. Supports all the above + // dimensions. * `OS_BETA` To select data from beta android versions + // only, excluding data from released android versions. Only the + // following dimensions are supported: * `versionCode` (int64): version + // of the app that was running on the user's device. * `osBuild` + // (string): OS build of the user's device, e.g., "T1B2.220916.004". + // + // Possible values: + // "USER_COHORT_UNSPECIFIED" - Unspecified User cohort. This will + // automatically choose the default value. + // "OS_PUBLIC" - This is default view. Contains data from public + // released android versions only. + // "OS_BETA" - This is the view with just android beta data excluding + // released OS version data. + // "APP_TESTERS" - This is the view with data only from users who have + // opted in to be testers for a given app, excluding OS beta data. + UserCohort string `json:"userCohort,omitempty"` + // ForceSendFields is a list of field names (e.g. "Dimensions") to // unconditionally include in API requests. By default, fields with // empty or default values are omitted from API requests. However, any diff --git a/securitycenter/v1/securitycenter-api.json b/securitycenter/v1/securitycenter-api.json index 5fe16e36706..11d58808445 100644 --- a/securitycenter/v1/securitycenter-api.json +++ b/securitycenter/v1/securitycenter-api.json @@ -1864,7 +1864,7 @@ ] }, "list": { - "description": "Lists operations that match the specified filter in the request. If the server doesn't support this method, it returns `UNIMPLEMENTED`. NOTE: the `name` binding allows API services to override the binding to use different resource name schemes, such as `users/*/operations`. To override the binding, API services can add a binding such as `\"/v1/{name=users/*}/operations\"` to their service configuration. For backwards compatibility, the default name includes the operations collection id, however overriding users must ensure the name binding is the parent resource, without the operations collection id.", + "description": "Lists operations that match the specified filter in the request. If the server doesn't support this method, it returns `UNIMPLEMENTED`.", "flatPath": "v1/organizations/{organizationsId}/operations", "httpMethod": "GET", "id": "securitycenter.organizations.operations.list", @@ -3372,7 +3372,7 @@ } } }, - "revision": "20230126", + "revision": "20230306", "rootUrl": "https://securitycenter.googleapis.com/", "schemas": { "Access": { diff --git a/securitycenter/v1/securitycenter-gen.go b/securitycenter/v1/securitycenter-gen.go index 7f96327eb84..b7c66236c67 100644 --- a/securitycenter/v1/securitycenter-gen.go +++ b/securitycenter/v1/securitycenter-gen.go @@ -14290,14 +14290,7 @@ type OrganizationsOperationsListCall struct { // List: Lists operations that match the specified filter in the // request. If the server doesn't support this method, it returns -// `UNIMPLEMENTED`. NOTE: the `name` binding allows API services to -// override the binding to use different resource name schemes, such as -// `users/*/operations`. To override the binding, API services can add a -// binding such as "/v1/{name=users/*}/operations" to their service -// configuration. For backwards compatibility, the default name includes -// the operations collection id, however overriding users must ensure -// the name binding is the parent resource, without the operations -// collection id. +// `UNIMPLEMENTED`. // // - name: The name of the operation's parent resource. func (r *OrganizationsOperationsService) List(name string) *OrganizationsOperationsListCall { @@ -14426,7 +14419,7 @@ func (c *OrganizationsOperationsListCall) Do(opts ...googleapi.CallOption) (*Lis } 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`. NOTE: the `name` binding allows API services to override the binding to use different resource name schemes, such as `users/*/operations`. To override the binding, API services can add a binding such as `\"/v1/{name=users/*}/operations\"` to their service configuration. For backwards compatibility, the default name includes the operations collection id, however overriding users must ensure the name binding is the parent resource, without the operations collection id.", + // "description": "Lists operations that match the specified filter in the request. If the server doesn't support this method, it returns `UNIMPLEMENTED`.", // "flatPath": "v1/organizations/{organizationsId}/operations", // "httpMethod": "GET", // "id": "securitycenter.organizations.operations.list", diff --git a/securitycenter/v1beta1/securitycenter-api.json b/securitycenter/v1beta1/securitycenter-api.json index c4d4f4e7ffe..2e25a9c3297 100644 --- a/securitycenter/v1beta1/securitycenter-api.json +++ b/securitycenter/v1beta1/securitycenter-api.json @@ -413,7 +413,7 @@ ] }, "list": { - "description": "Lists operations that match the specified filter in the request. If the server doesn't support this method, it returns `UNIMPLEMENTED`. NOTE: the `name` binding allows API services to override the binding to use different resource name schemes, such as `users/*/operations`. To override the binding, API services can add a binding such as `\"/v1/{name=users/*}/operations\"` to their service configuration. For backwards compatibility, the default name includes the operations collection id, however overriding users must ensure the name binding is the parent resource, without the operations collection id.", + "description": "Lists operations that match the specified filter in the request. If the server doesn't support this method, it returns `UNIMPLEMENTED`.", "flatPath": "v1beta1/organizations/{organizationsId}/operations", "httpMethod": "GET", "id": "securitycenter.organizations.operations.list", @@ -896,7 +896,7 @@ } } }, - "revision": "20230126", + "revision": "20230306", "rootUrl": "https://securitycenter.googleapis.com/", "schemas": { "Access": { diff --git a/securitycenter/v1beta1/securitycenter-gen.go b/securitycenter/v1beta1/securitycenter-gen.go index 40637f2ccc5..812a6c31bba 100644 --- a/securitycenter/v1beta1/securitycenter-gen.go +++ b/securitycenter/v1beta1/securitycenter-gen.go @@ -6273,14 +6273,7 @@ type OrganizationsOperationsListCall struct { // List: Lists operations that match the specified filter in the // request. If the server doesn't support this method, it returns -// `UNIMPLEMENTED`. NOTE: the `name` binding allows API services to -// override the binding to use different resource name schemes, such as -// `users/*/operations`. To override the binding, API services can add a -// binding such as "/v1/{name=users/*}/operations" to their service -// configuration. For backwards compatibility, the default name includes -// the operations collection id, however overriding users must ensure -// the name binding is the parent resource, without the operations -// collection id. +// `UNIMPLEMENTED`. // // - name: The name of the operation's parent resource. func (r *OrganizationsOperationsService) List(name string) *OrganizationsOperationsListCall { @@ -6409,7 +6402,7 @@ func (c *OrganizationsOperationsListCall) Do(opts ...googleapi.CallOption) (*Lis } 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`. NOTE: the `name` binding allows API services to override the binding to use different resource name schemes, such as `users/*/operations`. To override the binding, API services can add a binding such as `\"/v1/{name=users/*}/operations\"` to their service configuration. For backwards compatibility, the default name includes the operations collection id, however overriding users must ensure the name binding is the parent resource, without the operations collection id.", + // "description": "Lists operations that match the specified filter in the request. If the server doesn't support this method, it returns `UNIMPLEMENTED`.", // "flatPath": "v1beta1/organizations/{organizationsId}/operations", // "httpMethod": "GET", // "id": "securitycenter.organizations.operations.list", diff --git a/serviceconsumermanagement/v1/serviceconsumermanagement-api.json b/serviceconsumermanagement/v1/serviceconsumermanagement-api.json index 40eda707ac8..d995c5b34e1 100644 --- a/serviceconsumermanagement/v1/serviceconsumermanagement-api.json +++ b/serviceconsumermanagement/v1/serviceconsumermanagement-api.json @@ -186,7 +186,7 @@ ] }, "list": { - "description": "Lists operations that match the specified filter in the request. If the server doesn't support this method, it returns `UNIMPLEMENTED`. NOTE: the `name` binding allows API services to override the binding to use different resource name schemes, such as `users/*/operations`. To override the binding, API services can add a binding such as `\"/v1/{name=users/*}/operations\"` to their service configuration. For backwards compatibility, the default name includes the operations collection id, however overriding users must ensure the name binding is the parent resource, without the operations collection id.", + "description": "Lists operations that match the specified filter in the request. If the server doesn't support this method, it returns `UNIMPLEMENTED`.", "flatPath": "v1/operations", "httpMethod": "GET", "id": "serviceconsumermanagement.operations.list", @@ -542,7 +542,7 @@ } } }, - "revision": "20230301", + "revision": "20230304", "rootUrl": "https://serviceconsumermanagement.googleapis.com/", "schemas": { "AddTenantProjectRequest": { diff --git a/serviceconsumermanagement/v1/serviceconsumermanagement-gen.go b/serviceconsumermanagement/v1/serviceconsumermanagement-gen.go index 94b95d1c8e2..09fe668b9a5 100644 --- a/serviceconsumermanagement/v1/serviceconsumermanagement-gen.go +++ b/serviceconsumermanagement/v1/serviceconsumermanagement-gen.go @@ -5494,14 +5494,7 @@ type OperationsListCall struct { // List: Lists operations that match the specified filter in the // request. If the server doesn't support this method, it returns -// `UNIMPLEMENTED`. NOTE: the `name` binding allows API services to -// override the binding to use different resource name schemes, such as -// `users/*/operations`. To override the binding, API services can add a -// binding such as "/v1/{name=users/*}/operations" to their service -// configuration. For backwards compatibility, the default name includes -// the operations collection id, however overriding users must ensure -// the name binding is the parent resource, without the operations -// collection id. +// `UNIMPLEMENTED`. // // - name: The name of the operation's parent resource. func (r *OperationsService) List(name string) *OperationsListCall { @@ -5630,7 +5623,7 @@ func (c *OperationsListCall) Do(opts ...googleapi.CallOption) (*ListOperationsRe } 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`. NOTE: the `name` binding allows API services to override the binding to use different resource name schemes, such as `users/*/operations`. To override the binding, API services can add a binding such as `\"/v1/{name=users/*}/operations\"` to their service configuration. For backwards compatibility, the default name includes the operations collection id, however overriding users must ensure the name binding is the parent resource, without the operations collection id.", + // "description": "Lists operations that match the specified filter in the request. If the server doesn't support this method, it returns `UNIMPLEMENTED`.", // "flatPath": "v1/operations", // "httpMethod": "GET", // "id": "serviceconsumermanagement.operations.list", diff --git a/servicenetworking/v1/servicenetworking-api.json b/servicenetworking/v1/servicenetworking-api.json index ceccb501809..df015fddf4c 100644 --- a/servicenetworking/v1/servicenetworking-api.json +++ b/servicenetworking/v1/servicenetworking-api.json @@ -192,7 +192,7 @@ ] }, "list": { - "description": "Lists operations that match the specified filter in the request. If the server doesn't support this method, it returns `UNIMPLEMENTED`. NOTE: the `name` binding allows API services to override the binding to use different resource name schemes, such as `users/*/operations`. To override the binding, API services can add a binding such as `\"/v1/{name=users/*}/operations\"` to their service configuration. For backwards compatibility, the default name includes the operations collection id, however overriding users must ensure the name binding is the parent resource, without the operations collection id.", + "description": "Lists operations that match the specified filter in the request. If the server doesn't support this method, it returns `UNIMPLEMENTED`.", "flatPath": "v1/operations", "httpMethod": "GET", "id": "servicenetworking.operations.list", @@ -865,7 +865,7 @@ } } }, - "revision": "20230226", + "revision": "20230304", "rootUrl": "https://servicenetworking.googleapis.com/", "schemas": { "AddDnsRecordSetMetadata": { diff --git a/servicenetworking/v1/servicenetworking-gen.go b/servicenetworking/v1/servicenetworking-gen.go index 89d34914ef1..19b453d49d7 100644 --- a/servicenetworking/v1/servicenetworking-gen.go +++ b/servicenetworking/v1/servicenetworking-gen.go @@ -6063,14 +6063,7 @@ type OperationsListCall struct { // List: Lists operations that match the specified filter in the // request. If the server doesn't support this method, it returns -// `UNIMPLEMENTED`. NOTE: the `name` binding allows API services to -// override the binding to use different resource name schemes, such as -// `users/*/operations`. To override the binding, API services can add a -// binding such as "/v1/{name=users/*}/operations" to their service -// configuration. For backwards compatibility, the default name includes -// the operations collection id, however overriding users must ensure -// the name binding is the parent resource, without the operations -// collection id. +// `UNIMPLEMENTED`. // // - name: The name of the operation's parent resource. func (r *OperationsService) List(name string) *OperationsListCall { @@ -6199,7 +6192,7 @@ func (c *OperationsListCall) Do(opts ...googleapi.CallOption) (*ListOperationsRe } 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`. NOTE: the `name` binding allows API services to override the binding to use different resource name schemes, such as `users/*/operations`. To override the binding, API services can add a binding such as `\"/v1/{name=users/*}/operations\"` to their service configuration. For backwards compatibility, the default name includes the operations collection id, however overriding users must ensure the name binding is the parent resource, without the operations collection id.", + // "description": "Lists operations that match the specified filter in the request. If the server doesn't support this method, it returns `UNIMPLEMENTED`.", // "flatPath": "v1/operations", // "httpMethod": "GET", // "id": "servicenetworking.operations.list", diff --git a/serviceusage/v1/serviceusage-api.json b/serviceusage/v1/serviceusage-api.json index a216486def9..87817e6a04e 100644 --- a/serviceusage/v1/serviceusage-api.json +++ b/serviceusage/v1/serviceusage-api.json @@ -195,7 +195,7 @@ ] }, "list": { - "description": "Lists operations that match the specified filter in the request. If the server doesn't support this method, it returns `UNIMPLEMENTED`. NOTE: the `name` binding allows API services to override the binding to use different resource name schemes, such as `users/*/operations`. To override the binding, API services can add a binding such as `\"/v1/{name=users/*}/operations\"` to their service configuration. For backwards compatibility, the default name includes the operations collection id, however overriding users must ensure the name binding is the parent resource, without the operations collection id.", + "description": "Lists operations that match the specified filter in the request. If the server doesn't support this method, it returns `UNIMPLEMENTED`.", "flatPath": "v1/operations", "httpMethod": "GET", "id": "serviceusage.operations.list", @@ -426,7 +426,7 @@ } } }, - "revision": "20230301", + "revision": "20230304", "rootUrl": "https://serviceusage.googleapis.com/", "schemas": { "AdminQuotaPolicy": { diff --git a/serviceusage/v1/serviceusage-gen.go b/serviceusage/v1/serviceusage-gen.go index 0f1de576619..54f048eefb2 100644 --- a/serviceusage/v1/serviceusage-gen.go +++ b/serviceusage/v1/serviceusage-gen.go @@ -5272,14 +5272,7 @@ type OperationsListCall struct { // List: Lists operations that match the specified filter in the // request. If the server doesn't support this method, it returns -// `UNIMPLEMENTED`. NOTE: the `name` binding allows API services to -// override the binding to use different resource name schemes, such as -// `users/*/operations`. To override the binding, API services can add a -// binding such as "/v1/{name=users/*}/operations" to their service -// configuration. For backwards compatibility, the default name includes -// the operations collection id, however overriding users must ensure -// the name binding is the parent resource, without the operations -// collection id. +// `UNIMPLEMENTED`. func (r *OperationsService) List() *OperationsListCall { c := &OperationsListCall{s: r.s, urlParams_: make(gensupport.URLParams)} return c @@ -5409,7 +5402,7 @@ func (c *OperationsListCall) Do(opts ...googleapi.CallOption) (*ListOperationsRe } 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`. NOTE: the `name` binding allows API services to override the binding to use different resource name schemes, such as `users/*/operations`. To override the binding, API services can add a binding such as `\"/v1/{name=users/*}/operations\"` to their service configuration. For backwards compatibility, the default name includes the operations collection id, however overriding users must ensure the name binding is the parent resource, without the operations collection id.", + // "description": "Lists operations that match the specified filter in the request. If the server doesn't support this method, it returns `UNIMPLEMENTED`.", // "flatPath": "v1/operations", // "httpMethod": "GET", // "id": "serviceusage.operations.list", diff --git a/serviceusage/v1beta1/serviceusage-api.json b/serviceusage/v1beta1/serviceusage-api.json index 3cd270b3fa2..a07f7788e98 100644 --- a/serviceusage/v1beta1/serviceusage-api.json +++ b/serviceusage/v1beta1/serviceusage-api.json @@ -140,7 +140,7 @@ ] }, "list": { - "description": "Lists operations that match the specified filter in the request. If the server doesn't support this method, it returns `UNIMPLEMENTED`. NOTE: the `name` binding allows API services to override the binding to use different resource name schemes, such as `users/*/operations`. To override the binding, API services can add a binding such as `\"/v1/{name=users/*}/operations\"` to their service configuration. For backwards compatibility, the default name includes the operations collection id, however overriding users must ensure the name binding is the parent resource, without the operations collection id.", + "description": "Lists operations that match the specified filter in the request. If the server doesn't support this method, it returns `UNIMPLEMENTED`.", "flatPath": "v1beta1/operations", "httpMethod": "GET", "id": "serviceusage.operations.list", @@ -959,7 +959,7 @@ } } }, - "revision": "20230301", + "revision": "20230304", "rootUrl": "https://serviceusage.googleapis.com/", "schemas": { "AdminQuotaPolicy": { diff --git a/serviceusage/v1beta1/serviceusage-gen.go b/serviceusage/v1beta1/serviceusage-gen.go index fac1ad65212..4c4494efc76 100644 --- a/serviceusage/v1beta1/serviceusage-gen.go +++ b/serviceusage/v1beta1/serviceusage-gen.go @@ -5486,14 +5486,7 @@ type OperationsListCall struct { // List: Lists operations that match the specified filter in the // request. If the server doesn't support this method, it returns -// `UNIMPLEMENTED`. NOTE: the `name` binding allows API services to -// override the binding to use different resource name schemes, such as -// `users/*/operations`. To override the binding, API services can add a -// binding such as "/v1/{name=users/*}/operations" to their service -// configuration. For backwards compatibility, the default name includes -// the operations collection id, however overriding users must ensure -// the name binding is the parent resource, without the operations -// collection id. +// `UNIMPLEMENTED`. func (r *OperationsService) List() *OperationsListCall { c := &OperationsListCall{s: r.s, urlParams_: make(gensupport.URLParams)} return c @@ -5623,7 +5616,7 @@ func (c *OperationsListCall) Do(opts ...googleapi.CallOption) (*ListOperationsRe } 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`. NOTE: the `name` binding allows API services to override the binding to use different resource name schemes, such as `users/*/operations`. To override the binding, API services can add a binding such as `\"/v1/{name=users/*}/operations\"` to their service configuration. For backwards compatibility, the default name includes the operations collection id, however overriding users must ensure the name binding is the parent resource, without the operations collection id.", + // "description": "Lists operations that match the specified filter in the request. If the server doesn't support this method, it returns `UNIMPLEMENTED`.", // "flatPath": "v1beta1/operations", // "httpMethod": "GET", // "id": "serviceusage.operations.list", diff --git a/storage/v1/storage-api.json b/storage/v1/storage-api.json index bc1fca74391..edebc73ad4c 100644 --- a/storage/v1/storage-api.json +++ b/storage/v1/storage-api.json @@ -26,7 +26,7 @@ "description": "Stores and retrieves potentially large, immutable data objects.", "discoveryVersion": "v1", "documentationLink": "https://developers.google.com/storage/docs/json_api/", - "etag": "\"3134363638303431303535363634343235383633\"", + "etag": "\"34333739363230323936363635393736363430\"", "icons": { "x16": "https://www.google.com/images/icons/product/cloud_storage-16.png", "x32": "https://www.google.com/images/icons/product/cloud_storage-32.png" @@ -2141,6 +2141,11 @@ "location": "query", "type": "boolean" }, + "matchGlob": { + "description": "Filter results to objects and prefixes that match this glob pattern.", + "location": "query", + "type": "string" + }, "maxResults": { "default": "1000", "description": "Maximum number of items plus prefixes to return in a single page of responses. As duplicate prefixes are omitted, fewer total results may be returned than requested. The service will use this parameter or 1,000 items, whichever is smaller.", @@ -3005,7 +3010,7 @@ } } }, - "revision": "20220705", + "revision": "20230301", "rootUrl": "https://storage.googleapis.com/", "schemas": { "Bucket": { diff --git a/storage/v1/storage-gen.go b/storage/v1/storage-gen.go index 8527d3fb1ac..2f9ceefdcda 100644 --- a/storage/v1/storage-gen.go +++ b/storage/v1/storage-gen.go @@ -10216,6 +10216,13 @@ func (c *ObjectsListCall) IncludeTrailingDelimiter(includeTrailingDelimiter bool return c } +// MatchGlob sets the optional parameter "matchGlob": Filter results to +// objects and prefixes that match this glob pattern. +func (c *ObjectsListCall) MatchGlob(matchGlob string) *ObjectsListCall { + c.urlParams_.Set("matchGlob", matchGlob) + return c +} + // MaxResults sets the optional parameter "maxResults": Maximum number // of items plus prefixes to return in a single page of responses. As // duplicate prefixes are omitted, fewer total results may be returned @@ -10404,6 +10411,11 @@ func (c *ObjectsListCall) Do(opts ...googleapi.CallOption) (*Objects, error) { // "location": "query", // "type": "boolean" // }, + // "matchGlob": { + // "description": "Filter results to objects and prefixes that match this glob pattern.", + // "location": "query", + // "type": "string" + // }, // "maxResults": { // "default": "1000", // "description": "Maximum number of items plus prefixes to return in a single page of responses. As duplicate prefixes are omitted, fewer total results may be returned than requested. The service will use this parameter or 1,000 items, whichever is smaller.", diff --git a/webrisk/v1/webrisk-api.json b/webrisk/v1/webrisk-api.json index 3b23765721d..62d1be2f15e 100644 --- a/webrisk/v1/webrisk-api.json +++ b/webrisk/v1/webrisk-api.json @@ -228,7 +228,7 @@ ] }, "list": { - "description": "Lists operations that match the specified filter in the request. If the server doesn't support this method, it returns `UNIMPLEMENTED`. NOTE: the `name` binding allows API services to override the binding to use different resource name schemes, such as `users/*/operations`. To override the binding, API services can add a binding such as `\"/v1/{name=users/*}/operations\"` to their service configuration. For backwards compatibility, the default name includes the operations collection id, however overriding users must ensure the name binding is the parent resource, without the operations collection id.", + "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}/operations", "httpMethod": "GET", "id": "webrisk.projects.operations.list", @@ -298,38 +298,6 @@ ] } } - }, - "uris": { - "methods": { - "submit": { - "description": "Submits a URI suspected of containing malicious content to be reviewed. Returns a google.longrunning.Operation which, once the review is complete, is updated with its result. You can use the [Pub/Sub API] (https://cloud.google.com/pubsub) to receive notifications for the returned Operation. If the result verifies the existence of malicious content, the site will be added to the [Google's Social Engineering lists] (https://support.google.com/webmasters/answer/6350487/) in order to protect users that could get exposed to this threat in the future. Only allowlisted projects can use this method during Early Access. Please reach out to Sales or your customer engineer to obtain access.", - "flatPath": "v1/projects/{projectsId}/uris:submit", - "httpMethod": "POST", - "id": "webrisk.projects.uris.submit", - "parameterOrder": [ - "parent" - ], - "parameters": { - "parent": { - "description": "Required. The name of the project that is making the submission. This string is in the format \"projects/{project_number}\".", - "location": "path", - "pattern": "^projects/[^/]+$", - "required": true, - "type": "string" - } - }, - "path": "v1/{+parent}/uris:submit", - "request": { - "$ref": "GoogleCloudWebriskV1SubmitUriRequest" - }, - "response": { - "$ref": "GoogleLongrunningOperation" - }, - "scopes": [ - "https://www.googleapis.com/auth/cloud-platform" - ] - } - } } } }, @@ -452,7 +420,7 @@ } } }, - "revision": "20221016", + "revision": "20230304", "rootUrl": "https://webrisk.googleapis.com/", "schemas": { "GoogleCloudWebriskV1ComputeThreatListDiffResponse": { @@ -671,27 +639,6 @@ "description": "Wraps a URI that might be displaying malicious content.", "id": "GoogleCloudWebriskV1Submission", "properties": { - "threatTypes": { - "description": "ThreatTypes found to be associated with the submitted URI after reviewing it. This might be empty if the URI was not added to any list.", - "items": { - "enum": [ - "THREAT_TYPE_UNSPECIFIED", - "MALWARE", - "SOCIAL_ENGINEERING", - "UNWANTED_SOFTWARE", - "SOCIAL_ENGINEERING_EXTENDED_COVERAGE" - ], - "enumDescriptions": [ - "No entries should match this threat type. This threat type is unused.", - "Malware targeting any platform.", - "Social engineering targeting any platform.", - "Unwanted software targeting any platform.", - "A list of extended coverage social engineering URIs targeting any platform." - ], - "type": "string" - }, - "type": "array" - }, "uri": { "description": "Required. The URI that is being reported for malicious content to be analyzed.", "type": "string" @@ -699,54 +646,6 @@ }, "type": "object" }, - "GoogleCloudWebriskV1SubmitUriMetadata": { - "description": "Metadata for the Submit URI long-running operation.", - "id": "GoogleCloudWebriskV1SubmitUriMetadata", - "properties": { - "createTime": { - "description": "Creation time of the operation.", - "format": "google-datetime", - "type": "string" - }, - "state": { - "description": "The state of the operation.", - "enum": [ - "STATE_UNSPECIFIED", - "RUNNING", - "SUCCEEDED", - "CANCELLED", - "FAILED", - "CLOSED" - ], - "enumDescriptions": [ - "Default unspecified state.", - "The operation is currently running.", - "The operation finished with a success status.", - "The operation was cancelled.", - "The operation finished with a failure status.", - "The operation was closed with no action taken." - ], - "type": "string" - }, - "updateTime": { - "description": "Latest update time of the operation.", - "format": "google-datetime", - "type": "string" - } - }, - "type": "object" - }, - "GoogleCloudWebriskV1SubmitUriRequest": { - "description": "Request to send a potentially malicious URI to WebRisk.", - "id": "GoogleCloudWebriskV1SubmitUriRequest", - "properties": { - "submission": { - "$ref": "GoogleCloudWebriskV1Submission", - "description": "Required. The submission that contains the URI to be scanned." - } - }, - "type": "object" - }, "GoogleCloudWebriskV1ThreatEntryAdditions": { "description": "Contains the set of entries to add to a local database. May contain a combination of compressed and raw data in a single response.", "id": "GoogleCloudWebriskV1ThreatEntryAdditions", diff --git a/webrisk/v1/webrisk-gen.go b/webrisk/v1/webrisk-gen.go index c37e53cd833..a186c5baac6 100644 --- a/webrisk/v1/webrisk-gen.go +++ b/webrisk/v1/webrisk-gen.go @@ -159,7 +159,6 @@ func NewProjectsService(s *Service) *ProjectsService { rs := &ProjectsService{s: s} rs.Operations = NewProjectsOperationsService(s) rs.Submissions = NewProjectsSubmissionsService(s) - rs.Uris = NewProjectsUrisService(s) return rs } @@ -169,8 +168,6 @@ type ProjectsService struct { Operations *ProjectsOperationsService Submissions *ProjectsSubmissionsService - - Uris *ProjectsUrisService } func NewProjectsOperationsService(s *Service) *ProjectsOperationsService { @@ -191,15 +188,6 @@ type ProjectsSubmissionsService struct { s *Service } -func NewProjectsUrisService(s *Service) *ProjectsUrisService { - rs := &ProjectsUrisService{s: s} - return rs -} - -type ProjectsUrisService struct { - s *Service -} - func NewThreatListsService(s *Service) *ThreatListsService { rs := &ThreatListsService{s: s} return rs @@ -593,20 +581,6 @@ func (s *GoogleCloudWebriskV1SearchUrisResponseThreatUri) MarshalJSON() ([]byte, // GoogleCloudWebriskV1Submission: Wraps a URI that might be displaying // malicious content. type GoogleCloudWebriskV1Submission struct { - // ThreatTypes: ThreatTypes found to be associated with the submitted - // URI after reviewing it. This might be empty if the URI was not added - // to any list. - // - // Possible values: - // "THREAT_TYPE_UNSPECIFIED" - No entries should match this threat - // type. This threat type is unused. - // "MALWARE" - Malware targeting any platform. - // "SOCIAL_ENGINEERING" - Social engineering targeting any platform. - // "UNWANTED_SOFTWARE" - Unwanted software targeting any platform. - // "SOCIAL_ENGINEERING_EXTENDED_COVERAGE" - A list of extended - // coverage social engineering URIs targeting any platform. - ThreatTypes []string `json:"threatTypes,omitempty"` - // Uri: Required. The URI that is being reported for malicious content // to be analyzed. Uri string `json:"uri,omitempty"` @@ -615,80 +589,7 @@ type GoogleCloudWebriskV1Submission struct { // server. googleapi.ServerResponse `json:"-"` - // ForceSendFields is a list of field names (e.g. "ThreatTypes") 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. "ThreatTypes") 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 *GoogleCloudWebriskV1Submission) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudWebriskV1Submission - raw := NoMethod(*s) - return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) -} - -// GoogleCloudWebriskV1SubmitUriMetadata: Metadata for the Submit URI -// long-running operation. -type GoogleCloudWebriskV1SubmitUriMetadata struct { - // CreateTime: Creation time of the operation. - CreateTime string `json:"createTime,omitempty"` - - // State: The state of the operation. - // - // Possible values: - // "STATE_UNSPECIFIED" - Default unspecified state. - // "RUNNING" - The operation is currently running. - // "SUCCEEDED" - The operation finished with a success status. - // "CANCELLED" - The operation was cancelled. - // "FAILED" - The operation finished with a failure status. - // "CLOSED" - The operation was closed with no action taken. - State string `json:"state,omitempty"` - - // UpdateTime: Latest update time of the operation. - UpdateTime string `json:"updateTime,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 *GoogleCloudWebriskV1SubmitUriMetadata) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudWebriskV1SubmitUriMetadata - raw := NoMethod(*s) - return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) -} - -// GoogleCloudWebriskV1SubmitUriRequest: Request to send a potentially -// malicious URI to WebRisk. -type GoogleCloudWebriskV1SubmitUriRequest struct { - // Submission: Required. The submission that contains the URI to be - // scanned. - Submission *GoogleCloudWebriskV1Submission `json:"submission,omitempty"` - - // ForceSendFields is a list of field names (e.g. "Submission") to + // ForceSendFields is a list of field names (e.g. "Uri") 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 @@ -696,8 +597,8 @@ type GoogleCloudWebriskV1SubmitUriRequest struct { // This may be used to include empty fields in Patch requests. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "Submission") to include in - // API requests with the JSON null value. By default, fields with empty + // NullFields is a list of field names (e.g. "Uri") 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. @@ -705,8 +606,8 @@ type GoogleCloudWebriskV1SubmitUriRequest struct { NullFields []string `json:"-"` } -func (s *GoogleCloudWebriskV1SubmitUriRequest) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudWebriskV1SubmitUriRequest +func (s *GoogleCloudWebriskV1Submission) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudWebriskV1Submission raw := NoMethod(*s) return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } @@ -1569,14 +1470,7 @@ type ProjectsOperationsListCall struct { // List: Lists operations that match the specified filter in the // request. If the server doesn't support this method, it returns -// `UNIMPLEMENTED`. NOTE: the `name` binding allows API services to -// override the binding to use different resource name schemes, such as -// `users/*/operations`. To override the binding, API services can add a -// binding such as "/v1/{name=users/*}/operations" to their service -// configuration. For backwards compatibility, the default name includes -// the operations collection id, however overriding users must ensure -// the name binding is the parent resource, without the operations -// collection id. +// `UNIMPLEMENTED`. // // - name: The name of the operation's parent resource. func (r *ProjectsOperationsService) List(name string) *ProjectsOperationsListCall { @@ -1706,7 +1600,7 @@ func (c *ProjectsOperationsListCall) Do(opts ...googleapi.CallOption) (*GoogleLo } 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`. NOTE: the `name` binding allows API services to override the binding to use different resource name schemes, such as `users/*/operations`. To override the binding, API services can add a binding such as `\"/v1/{name=users/*}/operations\"` to their service configuration. For backwards compatibility, the default name includes the operations collection id, however overriding users must ensure the name binding is the parent resource, without the operations collection id.", + // "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}/operations", // "httpMethod": "GET", // "id": "webrisk.projects.operations.list", @@ -1917,159 +1811,6 @@ func (c *ProjectsSubmissionsCreateCall) Do(opts ...googleapi.CallOption) (*Googl } -// method id "webrisk.projects.uris.submit": - -type ProjectsUrisSubmitCall struct { - s *Service - parent string - googlecloudwebriskv1submiturirequest *GoogleCloudWebriskV1SubmitUriRequest - urlParams_ gensupport.URLParams - ctx_ context.Context - header_ http.Header -} - -// Submit: Submits a URI suspected of containing malicious content to be -// reviewed. Returns a google.longrunning.Operation which, once the -// review is complete, is updated with its result. You can use the -// [Pub/Sub API] (https://cloud.google.com/pubsub) to receive -// notifications for the returned Operation. If the result verifies the -// existence of malicious content, the site will be added to the -// [Google's Social Engineering lists] -// (https://support.google.com/webmasters/answer/6350487/) in order to -// protect users that could get exposed to this threat in the future. -// Only allowlisted projects can use this method during Early Access. -// Please reach out to Sales or your customer engineer to obtain access. -// -// - parent: The name of the project that is making the submission. This -// string is in the format "projects/{project_number}". -func (r *ProjectsUrisService) Submit(parent string, googlecloudwebriskv1submiturirequest *GoogleCloudWebriskV1SubmitUriRequest) *ProjectsUrisSubmitCall { - c := &ProjectsUrisSubmitCall{s: r.s, urlParams_: make(gensupport.URLParams)} - c.parent = parent - c.googlecloudwebriskv1submiturirequest = googlecloudwebriskv1submiturirequest - 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 *ProjectsUrisSubmitCall) Fields(s ...googleapi.Field) *ProjectsUrisSubmitCall { - 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 *ProjectsUrisSubmitCall) Context(ctx context.Context) *ProjectsUrisSubmitCall { - 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 *ProjectsUrisSubmitCall) Header() http.Header { - if c.header_ == nil { - c.header_ = make(http.Header) - } - return c.header_ -} - -func (c *ProjectsUrisSubmitCall) 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.googlecloudwebriskv1submiturirequest) - 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/{+parent}/uris:submit") - 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{ - "parent": c.parent, - }) - return gensupport.SendRequest(c.ctx_, c.s.client, req) -} - -// Do executes the "webrisk.projects.uris.submit" 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 *ProjectsUrisSubmitCall) 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": "Submits a URI suspected of containing malicious content to be reviewed. Returns a google.longrunning.Operation which, once the review is complete, is updated with its result. You can use the [Pub/Sub API] (https://cloud.google.com/pubsub) to receive notifications for the returned Operation. If the result verifies the existence of malicious content, the site will be added to the [Google's Social Engineering lists] (https://support.google.com/webmasters/answer/6350487/) in order to protect users that could get exposed to this threat in the future. Only allowlisted projects can use this method during Early Access. Please reach out to Sales or your customer engineer to obtain access.", - // "flatPath": "v1/projects/{projectsId}/uris:submit", - // "httpMethod": "POST", - // "id": "webrisk.projects.uris.submit", - // "parameterOrder": [ - // "parent" - // ], - // "parameters": { - // "parent": { - // "description": "Required. The name of the project that is making the submission. This string is in the format \"projects/{project_number}\".", - // "location": "path", - // "pattern": "^projects/[^/]+$", - // "required": true, - // "type": "string" - // } - // }, - // "path": "v1/{+parent}/uris:submit", - // "request": { - // "$ref": "GoogleCloudWebriskV1SubmitUriRequest" - // }, - // "response": { - // "$ref": "GoogleLongrunningOperation" - // }, - // "scopes": [ - // "https://www.googleapis.com/auth/cloud-platform" - // ] - // } - -} - // method id "webrisk.threatLists.computeDiff": type ThreatListsComputeDiffCall struct {