diff --git a/assuredworkloads/v1/assuredworkloads-api.json b/assuredworkloads/v1/assuredworkloads-api.json index f1335161391..7adaa0fe40d 100644 --- a/assuredworkloads/v1/assuredworkloads-api.json +++ b/assuredworkloads/v1/assuredworkloads-api.json @@ -519,7 +519,7 @@ } } }, - "revision": "20230623", + "revision": "20230630", "rootUrl": "https://assuredworkloads.googleapis.com/", "schemas": { "GoogleCloudAssuredworkloadsV1AcknowledgeViolationRequest": { @@ -798,14 +798,16 @@ "REMEDIATION_BOOLEAN_ORG_POLICY_VIOLATION", "REMEDIATION_LIST_ALLOWED_VALUES_ORG_POLICY_VIOLATION", "REMEDIATION_LIST_DENIED_VALUES_ORG_POLICY_VIOLATION", - "REMEDIATION_RESTRICT_CMEK_CRYPTO_KEY_PROJECTS_ORG_POLICY_VIOLATION" + "REMEDIATION_RESTRICT_CMEK_CRYPTO_KEY_PROJECTS_ORG_POLICY_VIOLATION", + "REMEDIATION_RESOURCE_VIOLATION" ], "enumDescriptions": [ "Unspecified remediation type", "Remediation type for boolean org policy", "Remediation type for list org policy which have allowed values in the monitoring rule", "Remediation type for list org policy which have denied values in the monitoring rule", - "Remediation type for gcp.restrictCmekCryptoKeyProjects" + "Remediation type for gcp.restrictCmekCryptoKeyProjects", + "Remediation type for resource violation." ], "readOnly": true, "type": "string" diff --git a/assuredworkloads/v1/assuredworkloads-gen.go b/assuredworkloads/v1/assuredworkloads-gen.go index 411fc629db3..290e5948635 100644 --- a/assuredworkloads/v1/assuredworkloads-gen.go +++ b/assuredworkloads/v1/assuredworkloads-gen.go @@ -596,6 +596,8 @@ type GoogleCloudAssuredworkloadsV1ViolationRemediation struct { // // "REMEDIATION_RESTRICT_CMEK_CRYPTO_KEY_PROJECTS_ORG_POLICY_VIOLATION" // - Remediation type for gcp.restrictCmekCryptoKeyProjects + // "REMEDIATION_RESOURCE_VIOLATION" - Remediation type for resource + // violation. RemediationType string `json:"remediationType,omitempty"` // ForceSendFields is a list of field names (e.g. "CompliantValues") to diff --git a/assuredworkloads/v1beta1/assuredworkloads-api.json b/assuredworkloads/v1beta1/assuredworkloads-api.json index b9b4c49ff31..3764e4b9c39 100644 --- a/assuredworkloads/v1beta1/assuredworkloads-api.json +++ b/assuredworkloads/v1beta1/assuredworkloads-api.json @@ -595,7 +595,7 @@ } } }, - "revision": "20230623", + "revision": "20230630", "rootUrl": "https://assuredworkloads.googleapis.com/", "schemas": { "GoogleCloudAssuredworkloadsV1beta1AcknowledgeViolationRequest": { @@ -875,14 +875,16 @@ "REMEDIATION_BOOLEAN_ORG_POLICY_VIOLATION", "REMEDIATION_LIST_ALLOWED_VALUES_ORG_POLICY_VIOLATION", "REMEDIATION_LIST_DENIED_VALUES_ORG_POLICY_VIOLATION", - "REMEDIATION_RESTRICT_CMEK_CRYPTO_KEY_PROJECTS_ORG_POLICY_VIOLATION" + "REMEDIATION_RESTRICT_CMEK_CRYPTO_KEY_PROJECTS_ORG_POLICY_VIOLATION", + "REMEDIATION_RESOURCE_VIOLATION" ], "enumDescriptions": [ "Unspecified remediation type", "Remediation type for boolean org policy", "Remediation type for list org policy which have allowed values in the monitoring rule", "Remediation type for list org policy which have denied values in the monitoring rule", - "Remediation type for gcp.restrictCmekCryptoKeyProjects" + "Remediation type for gcp.restrictCmekCryptoKeyProjects", + "Remediation type for resource violation." ], "readOnly": true, "type": "string" diff --git a/assuredworkloads/v1beta1/assuredworkloads-gen.go b/assuredworkloads/v1beta1/assuredworkloads-gen.go index 7b507df5d6a..d06a97d0970 100644 --- a/assuredworkloads/v1beta1/assuredworkloads-gen.go +++ b/assuredworkloads/v1beta1/assuredworkloads-gen.go @@ -684,6 +684,8 @@ type GoogleCloudAssuredworkloadsV1beta1ViolationRemediation struct { // // "REMEDIATION_RESTRICT_CMEK_CRYPTO_KEY_PROJECTS_ORG_POLICY_VIOLATION" // - Remediation type for gcp.restrictCmekCryptoKeyProjects + // "REMEDIATION_RESOURCE_VIOLATION" - Remediation type for resource + // violation. RemediationType string `json:"remediationType,omitempty"` // ForceSendFields is a list of field names (e.g. "CompliantValues") to diff --git a/chat/v1/chat-api.json b/chat/v1/chat-api.json index d4039274c64..cfab877cea1 100644 --- a/chat/v1/chat-api.json +++ b/chat/v1/chat-api.json @@ -954,7 +954,7 @@ } } }, - "revision": "20230622", + "revision": "20230704", "rootUrl": "https://chat.googleapis.com/", "schemas": { "ActionParameter": { @@ -2041,6 +2041,7 @@ }, "icon": { "$ref": "GoogleAppsCardV1Icon", + "deprecated": true, "description": "Deprecated in favor of `startIcon`." }, "onClick": { @@ -3029,6 +3030,7 @@ "type": "array" }, "cards": { + "deprecated": true, "description": "Deprecated: Use `cards_v2` instead. Rich, formatted, and interactive cards that you can use to display UI elements such as: formatted texts, buttons, and clickable images. Cards are normally displayed below the plain-text body of the message. `cards` and `cards_v2` can have a maximum size of 32 KB.", "items": { "$ref": "Card" @@ -3089,6 +3091,11 @@ "description": "Resource name in the form `spaces/*/messages/*`. Example: `spaces/AAAAAAAAAAA/messages/BBBBBBBBBBB.BBBBBBBBBBB`", "type": "string" }, + "quotedMessageMetadata": { + "$ref": "QuotedMessageMetadata", + "description": "Output only. Information about a message that's quoted by a Google Chat user in a space. Google Chat users can quote a message to reply to it.", + "readOnly": true + }, "sender": { "$ref": "User", "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`.", @@ -3145,6 +3152,24 @@ }, "type": "object" }, + "QuotedMessageMetadata": { + "description": "Information about a quoted message.", + "id": "QuotedMessageMetadata", + "properties": { + "lastUpdateTime": { + "description": "Output only. The timestamp when the quoted message was created or when the quoted message was last updated.", + "format": "google-datetime", + "readOnly": true, + "type": "string" + }, + "name": { + "description": "Output only. Resource name of the quoted message. Format: `spaces/{space}/messages/{message}`", + "readOnly": true, + "type": "string" + } + }, + "type": "object" + }, "Reaction": { "description": "A reaction to a message.", "id": "Reaction", @@ -3327,11 +3352,13 @@ "type": "string" }, "threaded": { + "deprecated": true, "description": "Output only. Deprecated: Use `spaceThreadingState` instead. Whether messages are threaded in this space.", "readOnly": true, "type": "boolean" }, "type": { + "deprecated": true, "description": "Output only. Deprecated: Use `space_type` instead. The type of a space.", "enum": [ "TYPE_UNSPECIFIED", diff --git a/chat/v1/chat-gen.go b/chat/v1/chat-gen.go index 9edc15d12cc..7f2737bce22 100644 --- a/chat/v1/chat-gen.go +++ b/chat/v1/chat-gen.go @@ -3929,6 +3929,11 @@ type Message struct { // `spaces/AAAAAAAAAAA/messages/BBBBBBBBBBB.BBBBBBBBBBB` Name string `json:"name,omitempty"` + // QuotedMessageMetadata: Output only. Information about a message + // that's quoted by a Google Chat user in a space. Google Chat users can + // quote a message to reply to it. + QuotedMessageMetadata *QuotedMessageMetadata `json:"quotedMessageMetadata,omitempty"` + // 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 @@ -4052,6 +4057,40 @@ func (s *OpenLink) MarshalJSON() ([]byte, error) { return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } +// QuotedMessageMetadata: Information about a quoted message. +type QuotedMessageMetadata struct { + // LastUpdateTime: Output only. The timestamp when the quoted message + // was created or when the quoted message was last updated. + LastUpdateTime string `json:"lastUpdateTime,omitempty"` + + // Name: Output only. Resource name of the quoted message. Format: + // `spaces/{space}/messages/{message}` + Name string `json:"name,omitempty"` + + // ForceSendFields is a list of field names (e.g. "LastUpdateTime") 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. "LastUpdateTime") 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 *QuotedMessageMetadata) MarshalJSON() ([]byte, error) { + type NoMethod QuotedMessageMetadata + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + // Reaction: A reaction to a message. type Reaction struct { // Emoji: The emoji used in the reaction. diff --git a/cloudscheduler/v1/cloudscheduler-api.json b/cloudscheduler/v1/cloudscheduler-api.json index d90afd5e9a3..d080a8cefed 100644 --- a/cloudscheduler/v1/cloudscheduler-api.json +++ b/cloudscheduler/v1/cloudscheduler-api.json @@ -418,7 +418,7 @@ } } }, - "revision": "20230421", + "revision": "20230630", "rootUrl": "https://cloudscheduler.googleapis.com/", "schemas": { "AppEngineHttpTarget": { @@ -580,6 +580,7 @@ "lastAttemptTime": { "description": "Output only. The time the last job attempt started.", "format": "google-datetime", + "readOnly": true, "type": "string" }, "name": { @@ -601,6 +602,7 @@ "scheduleTime": { "description": "Output only. The next time the job is scheduled. Note that this may be a retry of a previously failed attempt or the next execution time according to the schedule.", "format": "google-datetime", + "readOnly": true, "type": "string" }, "state": { @@ -619,11 +621,13 @@ "The job is disabled by the system due to error. The user cannot directly set a job to be disabled.", "The job state resulting from a failed CloudScheduler.UpdateJob operation. To recover a job from this state, retry CloudScheduler.UpdateJob until a successful response is received." ], + "readOnly": true, "type": "string" }, "status": { "$ref": "Status", - "description": "Output only. The response from the target for the last attempted execution." + "description": "Output only. The response from the target for the last attempted execution.", + "readOnly": true }, "timeZone": { "description": "Specifies the time zone to be used in interpreting schedule. The value of this field must be a time zone name from the [tz database](http://en.wikipedia.org/wiki/Tz_database). Note that some time zones include a provision for daylight savings time. The rules for daylight saving time are determined by the chosen tz. For UTC use the string \"utc\". If a time zone is not specified, the default will be in UTC (also known as GMT).", @@ -632,6 +636,7 @@ "userUpdateTime": { "description": "Output only. The creation time of the job.", "format": "google-datetime", + "readOnly": true, "type": "string" } }, @@ -751,24 +756,24 @@ "additionalProperties": { "type": "string" }, - "description": "Attributes for this message. If this field is empty, the message must contain non-empty data. This can be used to filter messages on the subscription.", + "description": "Optional. Attributes for this message. If this field is empty, the message must contain non-empty data. This can be used to filter messages on the subscription.", "type": "object" }, "data": { - "description": "The message data field. If this field is empty, the message must contain at least one attribute.", + "description": "Optional. The message data field. If this field is empty, the message must contain at least one attribute.", "format": "byte", "type": "string" }, "messageId": { - "description": "ID of this message, assigned by the server when the message is published. Guaranteed to be unique within the topic. This value may be read by a subscriber that receives a `PubsubMessage` via a `Pull` call or a push delivery. It must not be populated by the publisher in a `Publish` call.", + "description": "Optional. ID of this message, assigned by the server when the message is published. Guaranteed to be unique within the topic. This value may be read by a subscriber that receives a `PubsubMessage` via a `Pull` call or a push delivery. It must not be populated by the publisher in a `Publish` call.", "type": "string" }, "orderingKey": { - "description": "If non-empty, identifies related messages for which publish order should be respected. If a `Subscription` has `enable_message_ordering` set to `true`, messages published with the same non-empty `ordering_key` value will be delivered to subscribers in the order in which they are received by the Pub/Sub system. All `PubsubMessage`s published in a given `PublishRequest` must specify the same `ordering_key` value. For more information, see [ordering messages](https://cloud.google.com/pubsub/docs/ordering).", + "description": "Optional. If non-empty, identifies related messages for which publish order should be respected. If a `Subscription` has `enable_message_ordering` set to `true`, messages published with the same non-empty `ordering_key` value will be delivered to subscribers in the order in which they are received by the Pub/Sub system. All `PubsubMessage`s published in a given `PublishRequest` must specify the same `ordering_key` value. For more information, see [ordering messages](https://cloud.google.com/pubsub/docs/ordering).", "type": "string" }, "publishTime": { - "description": "The time at which the message was published, populated by the server when it receives the `Publish` call. It must not be populated by the publisher in a `Publish` call.", + "description": "Optional. The time at which the message was published, populated by the server when it receives the `Publish` call. It must not be populated by the publisher in a `Publish` call.", "format": "google-datetime", "type": "string" } diff --git a/cloudscheduler/v1/cloudscheduler-gen.go b/cloudscheduler/v1/cloudscheduler-gen.go index aa451bfbb92..43e182669ee 100644 --- a/cloudscheduler/v1/cloudscheduler-gen.go +++ b/cloudscheduler/v1/cloudscheduler-gen.go @@ -797,24 +797,24 @@ type PauseJobRequest struct { // (https://cloud.google.com/pubsub/quotas) for more information about // message limits. type PubsubMessage struct { - // Attributes: Attributes for this message. If this field is empty, the - // message must contain non-empty data. This can be used to filter - // messages on the subscription. + // Attributes: Optional. Attributes for this message. If this field is + // empty, the message must contain non-empty data. This can be used to + // filter messages on the subscription. Attributes map[string]string `json:"attributes,omitempty"` - // Data: The message data field. If this field is empty, the message - // must contain at least one attribute. + // Data: Optional. The message data field. If this field is empty, the + // message must contain at least one attribute. Data string `json:"data,omitempty"` - // MessageId: ID of this message, assigned by the server when the - // message is published. Guaranteed to be unique within the topic. This - // value may be read by a subscriber that receives a `PubsubMessage` via - // a `Pull` call or a push delivery. It must not be populated by the - // publisher in a `Publish` call. + // MessageId: Optional. ID of this message, assigned by the server when + // the message is published. Guaranteed to be unique within the topic. + // This value may be read by a subscriber that receives a + // `PubsubMessage` via a `Pull` call or a push delivery. It must not be + // populated by the publisher in a `Publish` call. MessageId string `json:"messageId,omitempty"` - // OrderingKey: If non-empty, identifies related messages for which - // publish order should be respected. If a `Subscription` has + // OrderingKey: Optional. If non-empty, identifies related messages for + // which publish order should be respected. If a `Subscription` has // `enable_message_ordering` set to `true`, messages published with the // same non-empty `ordering_key` value will be delivered to subscribers // in the order in which they are received by the Pub/Sub system. All @@ -823,9 +823,9 @@ type PubsubMessage struct { // messages (https://cloud.google.com/pubsub/docs/ordering). OrderingKey string `json:"orderingKey,omitempty"` - // PublishTime: The time at which the message was published, populated - // by the server when it receives the `Publish` call. It must not be - // populated by the publisher in a `Publish` call. + // PublishTime: Optional. The time at which the message was published, + // populated by the server when it receives the `Publish` call. It must + // not be populated by the publisher in a `Publish` call. PublishTime string `json:"publishTime,omitempty"` // ForceSendFields is a list of field names (e.g. "Attributes") to diff --git a/cloudscheduler/v1beta1/cloudscheduler-api.json b/cloudscheduler/v1beta1/cloudscheduler-api.json index df6dcf9379e..3cc5a842644 100644 --- a/cloudscheduler/v1beta1/cloudscheduler-api.json +++ b/cloudscheduler/v1beta1/cloudscheduler-api.json @@ -433,7 +433,7 @@ } } }, - "revision": "20230421", + "revision": "20230630", "rootUrl": "https://cloudscheduler.googleapis.com/", "schemas": { "AppEngineHttpTarget": { @@ -595,6 +595,7 @@ "lastAttemptTime": { "description": "Output only. The time the last job attempt started.", "format": "google-datetime", + "readOnly": true, "type": "string" }, "legacyAppEngineCron": { @@ -620,6 +621,7 @@ "scheduleTime": { "description": "Output only. The next time the job is scheduled. Note that this may be a retry of a previously failed attempt or the next execution time according to the schedule.", "format": "google-datetime", + "readOnly": true, "type": "string" }, "state": { @@ -638,11 +640,13 @@ "The job is disabled by the system due to error. The user cannot directly set a job to be disabled.", "The job state resulting from a failed CloudScheduler.UpdateJob operation. To recover a job from this state, retry CloudScheduler.UpdateJob until a successful response is received." ], + "readOnly": true, "type": "string" }, "status": { "$ref": "Status", - "description": "Output only. The response from the target for the last attempted execution." + "description": "Output only. The response from the target for the last attempted execution.", + "readOnly": true }, "timeZone": { "description": "Specifies the time zone to be used in interpreting schedule. The value of this field must be a time zone name from the [tz database](http://en.wikipedia.org/wiki/Tz_database). Note that some time zones include a provision for daylight savings time. The rules for daylight saving time are determined by the chosen tz. For UTC use the string \"utc\". If a time zone is not specified, the default will be in UTC (also known as GMT).", @@ -651,6 +655,7 @@ "userUpdateTime": { "description": "Output only. The creation time of the job.", "format": "google-datetime", + "readOnly": true, "type": "string" } }, @@ -770,24 +775,24 @@ "additionalProperties": { "type": "string" }, - "description": "Attributes for this message. If this field is empty, the message must contain non-empty data. This can be used to filter messages on the subscription.", + "description": "Optional. Attributes for this message. If this field is empty, the message must contain non-empty data. This can be used to filter messages on the subscription.", "type": "object" }, "data": { - "description": "The message data field. If this field is empty, the message must contain at least one attribute.", + "description": "Optional. The message data field. If this field is empty, the message must contain at least one attribute.", "format": "byte", "type": "string" }, "messageId": { - "description": "ID of this message, assigned by the server when the message is published. Guaranteed to be unique within the topic. This value may be read by a subscriber that receives a `PubsubMessage` via a `Pull` call or a push delivery. It must not be populated by the publisher in a `Publish` call.", + "description": "Optional. ID of this message, assigned by the server when the message is published. Guaranteed to be unique within the topic. This value may be read by a subscriber that receives a `PubsubMessage` via a `Pull` call or a push delivery. It must not be populated by the publisher in a `Publish` call.", "type": "string" }, "orderingKey": { - "description": "If non-empty, identifies related messages for which publish order should be respected. If a `Subscription` has `enable_message_ordering` set to `true`, messages published with the same non-empty `ordering_key` value will be delivered to subscribers in the order in which they are received by the Pub/Sub system. All `PubsubMessage`s published in a given `PublishRequest` must specify the same `ordering_key` value. For more information, see [ordering messages](https://cloud.google.com/pubsub/docs/ordering).", + "description": "Optional. If non-empty, identifies related messages for which publish order should be respected. If a `Subscription` has `enable_message_ordering` set to `true`, messages published with the same non-empty `ordering_key` value will be delivered to subscribers in the order in which they are received by the Pub/Sub system. All `PubsubMessage`s published in a given `PublishRequest` must specify the same `ordering_key` value. For more information, see [ordering messages](https://cloud.google.com/pubsub/docs/ordering).", "type": "string" }, "publishTime": { - "description": "The time at which the message was published, populated by the server when it receives the `Publish` call. It must not be populated by the publisher in a `Publish` call.", + "description": "Optional. The time at which the message was published, populated by the server when it receives the `Publish` call. It must not be populated by the publisher in a `Publish` call.", "format": "google-datetime", "type": "string" } diff --git a/cloudscheduler/v1beta1/cloudscheduler-gen.go b/cloudscheduler/v1beta1/cloudscheduler-gen.go index ffea4daf017..123d00a708f 100644 --- a/cloudscheduler/v1beta1/cloudscheduler-gen.go +++ b/cloudscheduler/v1beta1/cloudscheduler-gen.go @@ -804,24 +804,24 @@ type PauseJobRequest struct { // (https://cloud.google.com/pubsub/quotas) for more information about // message limits. type PubsubMessage struct { - // Attributes: Attributes for this message. If this field is empty, the - // message must contain non-empty data. This can be used to filter - // messages on the subscription. + // Attributes: Optional. Attributes for this message. If this field is + // empty, the message must contain non-empty data. This can be used to + // filter messages on the subscription. Attributes map[string]string `json:"attributes,omitempty"` - // Data: The message data field. If this field is empty, the message - // must contain at least one attribute. + // Data: Optional. The message data field. If this field is empty, the + // message must contain at least one attribute. Data string `json:"data,omitempty"` - // MessageId: ID of this message, assigned by the server when the - // message is published. Guaranteed to be unique within the topic. This - // value may be read by a subscriber that receives a `PubsubMessage` via - // a `Pull` call or a push delivery. It must not be populated by the - // publisher in a `Publish` call. + // MessageId: Optional. ID of this message, assigned by the server when + // the message is published. Guaranteed to be unique within the topic. + // This value may be read by a subscriber that receives a + // `PubsubMessage` via a `Pull` call or a push delivery. It must not be + // populated by the publisher in a `Publish` call. MessageId string `json:"messageId,omitempty"` - // OrderingKey: If non-empty, identifies related messages for which - // publish order should be respected. If a `Subscription` has + // OrderingKey: Optional. If non-empty, identifies related messages for + // which publish order should be respected. If a `Subscription` has // `enable_message_ordering` set to `true`, messages published with the // same non-empty `ordering_key` value will be delivered to subscribers // in the order in which they are received by the Pub/Sub system. All @@ -830,9 +830,9 @@ type PubsubMessage struct { // messages (https://cloud.google.com/pubsub/docs/ordering). OrderingKey string `json:"orderingKey,omitempty"` - // PublishTime: The time at which the message was published, populated - // by the server when it receives the `Publish` call. It must not be - // populated by the publisher in a `Publish` call. + // PublishTime: Optional. The time at which the message was published, + // populated by the server when it receives the `Publish` call. It must + // not be populated by the publisher in a `Publish` call. PublishTime string `json:"publishTime,omitempty"` // ForceSendFields is a list of field names (e.g. "Attributes") to diff --git a/connectors/v1/connectors-api.json b/connectors/v1/connectors-api.json index f3bff59df81..ea85f5d9041 100644 --- a/connectors/v1/connectors-api.json +++ b/connectors/v1/connectors-api.json @@ -453,6 +453,34 @@ "https://www.googleapis.com/auth/cloud-platform" ] }, + "repairEventing": { + "description": "RepaiEventing tries to repair eventing related event subscriptions.", + "flatPath": "v1/projects/{projectsId}/locations/{locationsId}/connections/{connectionsId}:repairEventing", + "httpMethod": "POST", + "id": "connectors.projects.locations.connections.repairEventing", + "parameterOrder": [ + "name" + ], + "parameters": { + "name": { + "description": "Required. Resource name of the form: `projects/*/locations/*/connections/*`", + "location": "path", + "pattern": "^projects/[^/]+/locations/[^/]+/connections/[^/]+$", + "required": true, + "type": "string" + } + }, + "path": "v1/{+name}:repairEventing", + "request": { + "$ref": "RepairEventingRequest" + }, + "response": { + "$ref": "Operation" + }, + "scopes": [ + "https://www.googleapis.com/auth/cloud-platform" + ] + }, "setIamPolicy": { "description": "Sets the access control policy on the specified resource. Replaces any existing policy. Can return `NOT_FOUND`, `INVALID_ARGUMENT`, and `PERMISSION_DENIED` errors.", "flatPath": "v1/projects/{projectsId}/locations/{locationsId}/connections/{connectionsId}:setIamPolicy", @@ -543,6 +571,201 @@ } } }, + "eventSubscriptions": { + "methods": { + "create": { + "description": "Creates a new EventSubscription in a given project,location and connection.", + "flatPath": "v1/projects/{projectsId}/locations/{locationsId}/connections/{connectionsId}/eventSubscriptions", + "httpMethod": "POST", + "id": "connectors.projects.locations.connections.eventSubscriptions.create", + "parameterOrder": [ + "parent" + ], + "parameters": { + "eventSubscriptionId": { + "description": "Required. Identifier to assign to the Event Subscription. Must be unique within scope of the parent resource.", + "location": "query", + "type": "string" + }, + "parent": { + "description": "Required. Parent resource of the EventSubscription, of the form: `projects/*/locations/*/connections/*`", + "location": "path", + "pattern": "^projects/[^/]+/locations/[^/]+/connections/[^/]+$", + "required": true, + "type": "string" + } + }, + "path": "v1/{+parent}/eventSubscriptions", + "request": { + "$ref": "EventSubscription" + }, + "response": { + "$ref": "Operation" + }, + "scopes": [ + "https://www.googleapis.com/auth/cloud-platform" + ] + }, + "delete": { + "description": "Deletes a single EventSubscription.", + "flatPath": "v1/projects/{projectsId}/locations/{locationsId}/connections/{connectionsId}/eventSubscriptions/{eventSubscriptionsId}", + "httpMethod": "DELETE", + "id": "connectors.projects.locations.connections.eventSubscriptions.delete", + "parameterOrder": [ + "name" + ], + "parameters": { + "name": { + "description": "Required. Resource name of the form: `projects/*/locations/*/connections/*/eventsubscriptions/*`", + "location": "path", + "pattern": "^projects/[^/]+/locations/[^/]+/connections/[^/]+/eventSubscriptions/[^/]+$", + "required": true, + "type": "string" + } + }, + "path": "v1/{+name}", + "response": { + "$ref": "Operation" + }, + "scopes": [ + "https://www.googleapis.com/auth/cloud-platform" + ] + }, + "get": { + "description": "Gets details of a single EventSubscription.", + "flatPath": "v1/projects/{projectsId}/locations/{locationsId}/connections/{connectionsId}/eventSubscriptions/{eventSubscriptionsId}", + "httpMethod": "GET", + "id": "connectors.projects.locations.connections.eventSubscriptions.get", + "parameterOrder": [ + "name" + ], + "parameters": { + "name": { + "description": "Required. Resource name of the form: `projects/*/locations/*/connections/*/eventSubscriptions/*`", + "location": "path", + "pattern": "^projects/[^/]+/locations/[^/]+/connections/[^/]+/eventSubscriptions/[^/]+$", + "required": true, + "type": "string" + } + }, + "path": "v1/{+name}", + "response": { + "$ref": "EventSubscription" + }, + "scopes": [ + "https://www.googleapis.com/auth/cloud-platform" + ] + }, + "list": { + "description": "List EventSubscriptions in a given project,location and connection.", + "flatPath": "v1/projects/{projectsId}/locations/{locationsId}/connections/{connectionsId}/eventSubscriptions", + "httpMethod": "GET", + "id": "connectors.projects.locations.connections.eventSubscriptions.list", + "parameterOrder": [ + "parent" + ], + "parameters": { + "filter": { + "description": "Filter. https://g3doc.corp.google.com/cloud/control2/g3doc/dev/apihosting/list_filtering.md#filtering.", + "location": "query", + "type": "string" + }, + "orderBy": { + "description": "Order by parameters.", + "location": "query", + "type": "string" + }, + "pageSize": { + "description": "Page size.", + "format": "int32", + "location": "query", + "type": "integer" + }, + "pageToken": { + "description": "Page token.", + "location": "query", + "type": "string" + }, + "parent": { + "description": "Required. Parent resource of the EventSubscription, of the form: `projects/*/locations/*/connections/*`", + "location": "path", + "pattern": "^projects/[^/]+/locations/[^/]+/connections/[^/]+$", + "required": true, + "type": "string" + } + }, + "path": "v1/{+parent}/eventSubscriptions", + "response": { + "$ref": "ListEventSubscriptionsResponse" + }, + "scopes": [ + "https://www.googleapis.com/auth/cloud-platform" + ] + }, + "patch": { + "description": "Updates the parameters of a single EventSubscription.", + "flatPath": "v1/projects/{projectsId}/locations/{locationsId}/connections/{connectionsId}/eventSubscriptions/{eventSubscriptionsId}", + "httpMethod": "PATCH", + "id": "connectors.projects.locations.connections.eventSubscriptions.patch", + "parameterOrder": [ + "name" + ], + "parameters": { + "name": { + "description": "Required. Resource name of the EventSubscription. Format: projects/{project}/locations/{location}/connections/{connection}/eventSubscriptions/{event_subscription}", + "location": "path", + "pattern": "^projects/[^/]+/locations/[^/]+/connections/[^/]+/eventSubscriptions/[^/]+$", + "required": true, + "type": "string" + }, + "updateMask": { + "description": "Required. The list of fields to update. Fields are specified relative to the Subscription. A field will be overwritten if it is in the mask. You can modify only the fields listed below. To update the EventSubscription details: * `serviceAccount`", + "format": "google-fieldmask", + "location": "query", + "type": "string" + } + }, + "path": "v1/{+name}", + "request": { + "$ref": "EventSubscription" + }, + "response": { + "$ref": "Operation" + }, + "scopes": [ + "https://www.googleapis.com/auth/cloud-platform" + ] + }, + "retry": { + "description": "RetryEventSubscription retries the registration of Subscription.", + "flatPath": "v1/projects/{projectsId}/locations/{locationsId}/connections/{connectionsId}/eventSubscriptions/{eventSubscriptionsId}:retry", + "httpMethod": "POST", + "id": "connectors.projects.locations.connections.eventSubscriptions.retry", + "parameterOrder": [ + "name" + ], + "parameters": { + "name": { + "description": "Required. Resource name of the form: `projects/*/locations/*/connections/*/eventSubscriptions/*`", + "location": "path", + "pattern": "^projects/[^/]+/locations/[^/]+/connections/[^/]+/eventSubscriptions/[^/]+$", + "required": true, + "type": "string" + } + }, + "path": "v1/{+name}:retry", + "request": { + "$ref": "RetryEventSubscriptionRequest" + }, + "response": { + "$ref": "Operation" + }, + "scopes": [ + "https://www.googleapis.com/auth/cloud-platform" + ] + } + } + }, "runtimeActionSchemas": { "methods": { "list": { @@ -828,6 +1051,40 @@ "scopes": [ "https://www.googleapis.com/auth/cloud-platform" ] + }, + "updateSettings": { + "description": "Update the global settings of a project.", + "flatPath": "v1/projects/{projectsId}/locations/global/settings", + "httpMethod": "PATCH", + "id": "connectors.projects.locations.global.updateSettings", + "parameterOrder": [ + "name" + ], + "parameters": { + "name": { + "description": "Output only. Resource name of the Connection. Format: projects/{project}/locations/global/settings}", + "location": "path", + "pattern": "^projects/[^/]+/locations/global/settings$", + "required": true, + "type": "string" + }, + "updateMask": { + "description": "Required. The list of fields to update.", + "format": "google-fieldmask", + "location": "query", + "type": "string" + } + }, + "path": "v1/{+name}", + "request": { + "$ref": "Settings" + }, + "response": { + "$ref": "Operation" + }, + "scopes": [ + "https://www.googleapis.com/auth/cloud-platform" + ] } }, "resources": { @@ -1438,6 +1695,73 @@ "https://www.googleapis.com/auth/cloud-platform" ] } + }, + "resources": { + "eventtypes": { + "methods": { + "get": { + "description": "Gets details of a single event type.", + "flatPath": "v1/projects/{projectsId}/locations/{locationsId}/providers/{providersId}/connectors/{connectorsId}/versions/{versionsId}/eventtypes/{eventtypesId}", + "httpMethod": "GET", + "id": "connectors.projects.locations.providers.connectors.versions.eventtypes.get", + "parameterOrder": [ + "name" + ], + "parameters": { + "name": { + "description": "Required. Resource name of the form: `projects/*/locations/*/providers/*/connectors/*/versions/*/eventtypes/*` Only global location is supported for EventType resource.", + "location": "path", + "pattern": "^projects/[^/]+/locations/[^/]+/providers/[^/]+/connectors/[^/]+/versions/[^/]+/eventtypes/[^/]+$", + "required": true, + "type": "string" + } + }, + "path": "v1/{+name}", + "response": { + "$ref": "EventType" + }, + "scopes": [ + "https://www.googleapis.com/auth/cloud-platform" + ] + }, + "list": { + "description": "Lists Event Types in a given Connector Version.", + "flatPath": "v1/projects/{projectsId}/locations/{locationsId}/providers/{providersId}/connectors/{connectorsId}/versions/{versionsId}/eventtypes", + "httpMethod": "GET", + "id": "connectors.projects.locations.providers.connectors.versions.eventtypes.list", + "parameterOrder": [ + "parent" + ], + "parameters": { + "pageSize": { + "description": "Page size.", + "format": "int32", + "location": "query", + "type": "integer" + }, + "pageToken": { + "description": "Page token.", + "location": "query", + "type": "string" + }, + "parent": { + "description": "Required. Parent resource of the connectors, of the form: `projects/*/locations/*/providers/*/connectors/*/versions/*` Only global location is supported for EventType resource.", + "location": "path", + "pattern": "^projects/[^/]+/locations/[^/]+/providers/[^/]+/connectors/[^/]+/versions/[^/]+$", + "required": true, + "type": "string" + } + }, + "path": "v1/{+parent}/eventtypes", + "response": { + "$ref": "ListEventTypesResponse" + }, + "scopes": [ + "https://www.googleapis.com/auth/cloud-platform" + ] + } + } + } } } } @@ -1449,7 +1773,7 @@ } } }, - "revision": "20230609", + "revision": "20230706", "rootUrl": "https://connectors.googleapis.com/", "schemas": { "AuditConfig": { @@ -1803,6 +2127,11 @@ "description": "Required. Connector version on which the connection is created. The format is: projects/*/locations/*/providers/*/connectors/*/versions/* Only global location is supported for ConnectorVersion resource.", "type": "string" }, + "connectorVersionInfraConfig": { + "$ref": "ConnectorVersionInfraConfig", + "description": "Output only. Infra configs supported by Connector Version.", + "readOnly": true + }, "connectorVersionLaunchStage": { "description": "Output only. Flag to mark the version indicating the launch stage.", "enum": [ @@ -1844,6 +2173,29 @@ "readOnly": true, "type": "string" }, + "eventingConfig": { + "$ref": "EventingConfig", + "description": "Optional. Eventing config of a connection" + }, + "eventingEnablementType": { + "description": "Optional. Eventing enablement type. Will be nil if eventing is not enabled.", + "enum": [ + "EVENTING_ENABLEMENT_TYPE_UNSPECIFIED", + "EVENTING_AND_CONNECTION", + "ONLY_EVENTING" + ], + "enumDescriptions": [ + "Eventing Enablement Type Unspecifeied.", + "Both connection and eventing.", + "Only Eventing." + ], + "type": "string" + }, + "eventingRuntimeData": { + "$ref": "EventingRuntimeData", + "description": "Output only. Eventing Runtime Data.", + "readOnly": true + }, "imageLocation": { "description": "Output only. GCR location where the runtime image is stored. formatted like: gcr.io/{bucketName}/{imageName}", "readOnly": true, @@ -2038,6 +2390,11 @@ "readOnly": true, "type": "string" }, + "eventingDetails": { + "$ref": "EventingDetails", + "description": "Output only. Eventing details. Will be null if eventing is not supported.", + "readOnly": true + }, "externalUri": { "description": "Output only. Link to external page.", "readOnly": true, @@ -2089,6 +2446,18 @@ }, "type": "object" }, + "ConnectorInfraConfig": { + "description": "This cofiguration provides infra configs like rate limit threshold which need to be configurable for every connector version", + "id": "ConnectorInfraConfig", + "properties": { + "ratelimitThreshold": { + "description": "Max QPS supported by the connector version before throttling of requests.", + "format": "int64", + "type": "string" + } + }, + "type": "object" + }, "ConnectorVersion": { "description": "ConnectorVersion indicates a specific version of a connector.", "id": "ConnectorVersion", @@ -2109,6 +2478,11 @@ "readOnly": true, "type": "array" }, + "connectorInfraConfig": { + "$ref": "ConnectorInfraConfig", + "description": "Output only. Infra configs supported by Connector.", + "readOnly": true + }, "createTime": { "description": "Output only. Created time.", "format": "google-datetime", @@ -2133,6 +2507,11 @@ "description": "Output only. Configuration for Egress Control.", "readOnly": true }, + "eventingConfigTemplate": { + "$ref": "EventingConfigTemplate", + "description": "Output only. Eventing configuration supported by the Connector.", + "readOnly": true + }, "labels": { "additionalProperties": { "type": "string" @@ -2202,6 +2581,19 @@ }, "type": "object" }, + "ConnectorVersionInfraConfig": { + "description": "This cofiguration provides infra configs like rate limit threshold which need to be configurable for every connector version", + "id": "ConnectorVersionInfraConfig", + "properties": { + "ratelimitThreshold": { + "description": "Output only. Max QPS supported by the connector version before throttling of requests.", + "format": "int64", + "readOnly": true, + "type": "string" + } + }, + "type": "object" + }, "ConnectorsLogConfig": { "description": "Log configuration for the connection.", "id": "ConnectorsLogConfig", @@ -2354,6 +2746,24 @@ }, "type": "object" }, + "EndPoint": { + "description": "Endpoint message includes details of the Destination endpoint.", + "id": "EndPoint", + "properties": { + "endpointUri": { + "description": "The URI of the Endpoint.", + "type": "string" + }, + "headers": { + "description": "List of Header to be added to the Endpoint.", + "items": { + "$ref": "Header" + }, + "type": "array" + } + }, + "type": "object" + }, "EndpointAttachment": { "description": "represents the Connector's Endpoint Attachment resource", "id": "EndpointAttachment", @@ -2413,9 +2823,339 @@ }, "type": "object" }, - "Expr": { - "description": "Represents a textual expression in the Common Expression Language (CEL) syntax. CEL is a C-like expression language. The syntax and semantics of CEL are documented at https://github.com/google/cel-spec. Example (Comparison): title: \"Summary size limit\" description: \"Determines if a summary is less than 100 chars\" expression: \"document.summary.size() \u003c 100\" Example (Equality): title: \"Requestor is owner\" description: \"Determines if requestor is the document owner\" expression: \"document.owner == request.auth.claims.email\" Example (Logic): title: \"Public documents\" description: \"Determine whether the document should be publicly visible\" expression: \"document.type != 'private' \u0026\u0026 document.type != 'internal'\" Example (Data Manipulation): title: \"Notification string\" description: \"Create a notification string with a timestamp.\" expression: \"'New message received at ' + string(document.create_time)\" The exact variables and functions that may be referenced within an expression are determined by the service that evaluates it. See the service documentation for additional information.", - "id": "Expr", + "EventSubscription": { + "description": "represents the Connector's EventSubscription resource", + "id": "EventSubscription", + "properties": { + "createTime": { + "description": "Output only. Created time.", + "format": "google-datetime", + "readOnly": true, + "type": "string" + }, + "destinations": { + "$ref": "EventSubscriptionDestination", + "description": "Optional. The destination to hit when we receive an event" + }, + "eventTypeId": { + "description": "Optional. Event type id of the event of current EventSubscription.", + "type": "string" + }, + "name": { + "description": "Required. Resource name of the EventSubscription. Format: projects/{project}/locations/{location}/connections/{connection}/eventSubscriptions/{event_subscription}", + "type": "string" + }, + "status": { + "$ref": "EventSubscriptionStatus", + "description": "Optional. Status indicates the status of the event subscription resource" + }, + "subscriber": { + "description": "Optional. name of the Subscriber for the current EventSubscription.", + "type": "string" + }, + "subscriberLink": { + "description": "Optional. Link for Subscriber of the current EventSubscription.", + "type": "string" + }, + "updateTime": { + "description": "Output only. Updated time.", + "format": "google-datetime", + "readOnly": true, + "type": "string" + } + }, + "type": "object" + }, + "EventSubscriptionDestination": { + "description": "Message for EventSubscription Destination to act on receiving an event", + "id": "EventSubscriptionDestination", + "properties": { + "endpoint": { + "$ref": "EndPoint", + "description": "OPTION 1: Hit an endpoint when we receive an event." + }, + "serviceAccount": { + "description": "Service account needed for runtime plane to trigger IP workflow.", + "type": "string" + }, + "type": { + "description": "type of the destination", + "enum": [ + "TYPE_UNSPECIFIED", + "ENDPOINT" + ], + "enumDescriptions": [ + "Default state.", + "Endpoint - Hit the value of endpoint when event is received" + ], + "type": "string" + } + }, + "type": "object" + }, + "EventSubscriptionStatus": { + "description": "EventSubscription Status denotes the status of the EventSubscription resource.", + "id": "EventSubscriptionStatus", + "properties": { + "description": { + "description": "Output only. Description of the state.", + "readOnly": true, + "type": "string" + }, + "state": { + "description": "Output only. State of Event Subscription resource.", + "enum": [ + "STATE_UNSPECIFIED", + "CREATING", + "UPDATING", + "ACTIVE", + "SUSPENDED", + "ERROR" + ], + "enumDescriptions": [ + "Default state.", + "EventSubscription creation is in progress.", + "EventSubscription is in Updating status.", + "EventSubscription is in Active state and is ready to receive events.", + "EventSubscription is currently suspended.", + "EventSubscription is in Error state." + ], + "readOnly": true, + "type": "string" + } + }, + "type": "object" + }, + "EventType": { + "description": "EventType includes fields.", + "id": "EventType", + "properties": { + "createTime": { + "description": "Output only. Created time.", + "format": "google-datetime", + "readOnly": true, + "type": "string" + }, + "enrichedEventPayloadSchema": { + "description": "Output only. Schema of the event payload after enriched. Will be null if read before send is not supported.", + "readOnly": true, + "type": "string" + }, + "entityType": { + "description": "Output only. Runtime entity type name. Will be null if entity type map is not available. Used for read before send feature.", + "readOnly": true, + "type": "string" + }, + "eventPayloadSchema": { + "description": "Output only. Schema of webhook event payload.", + "readOnly": true, + "type": "string" + }, + "eventTypeId": { + "description": "Output only. Event type id. Example: `ticket.created`.", + "readOnly": true, + "type": "string" + }, + "idPath": { + "description": "Output only. Id path denotes the path of id in webhook payload.", + "readOnly": true, + "type": "string" + }, + "name": { + "description": "Output only. Resource name of the eventtype. Format: projects/{project}/locations/{location}/providers/{provider}/connectors/{connector}/versions/{version}/eventtypes/{eventtype} Only global location is supported for Connector resource.", + "readOnly": true, + "type": "string" + }, + "updateTime": { + "description": "Output only. Updated time.", + "format": "google-datetime", + "readOnly": true, + "type": "string" + } + }, + "type": "object" + }, + "EventingConfig": { + "description": "Eventing Configuration of a connection", + "id": "EventingConfig", + "properties": { + "additionalVariables": { + "description": "Additional eventing related field values", + "items": { + "$ref": "ConfigVariable" + }, + "type": "array" + }, + "authConfig": { + "$ref": "AuthConfig", + "description": "Auth details for the webhook adapter." + }, + "encryptionKey": { + "$ref": "ConfigVariable", + "description": "Encryption key (can be either Google managed or CMEK)." + }, + "enrichmentEnabled": { + "description": "Enrichment Enabled.", + "type": "boolean" + }, + "registrationDestinationConfig": { + "$ref": "DestinationConfig", + "description": "Registration endpoint for auto regsitration." + } + }, + "type": "object" + }, + "EventingConfigTemplate": { + "description": "Eventing Config details of a connector version.", + "id": "EventingConfigTemplate", + "properties": { + "additionalVariables": { + "description": "Additional fields that need to be rendered.", + "items": { + "$ref": "ConfigVariableTemplate" + }, + "type": "array" + }, + "authConfigTemplates": { + "description": "AuthConfigTemplates represents the auth values for the webhook adapter.", + "items": { + "$ref": "AuthConfigTemplate" + }, + "type": "array" + }, + "autoRefresh": { + "description": "Auto refresh to extend webhook life.", + "type": "boolean" + }, + "autoRegistrationSupported": { + "description": "Auto Registration supported.", + "type": "boolean" + }, + "encryptionKeyTemplate": { + "$ref": "ConfigVariableTemplate", + "description": "Encryption key (can be either Google managed or CMEK)." + }, + "enrichmentSupported": { + "description": "Enrichment Supported.", + "type": "boolean" + }, + "isEventingSupported": { + "description": "Is Eventing Supported.", + "type": "boolean" + }, + "registrationDestinationConfig": { + "$ref": "DestinationConfigTemplate", + "description": "Registration host destination config template." + } + }, + "type": "object" + }, + "EventingDetails": { + "description": "Eventing Details message.", + "id": "EventingDetails", + "properties": { + "customEventTypes": { + "description": "Output only. Custom Event Types.", + "readOnly": true, + "type": "boolean" + }, + "description": { + "description": "Output only. Description.", + "readOnly": true, + "type": "string" + }, + "documentationLink": { + "description": "Output only. Link to public documentation.", + "readOnly": true, + "type": "string" + }, + "iconLocation": { + "description": "Output only. Cloud storage location of the icon.", + "readOnly": true, + "type": "string" + }, + "launchStage": { + "description": "Output only. Eventing Launch Stage.", + "enum": [ + "LAUNCH_STAGE_UNSPECIFIED", + "PREVIEW", + "GA", + "DEPRECATED", + "PRIVATE_PREVIEW" + ], + "enumDescriptions": [ + "LAUNCH_STAGE_UNSPECIFIED.", + "PREVIEW.", + "GA.", + "DEPRECATED.", + "PRIVATE_PREVIEW." + ], + "readOnly": true, + "type": "string" + }, + "name": { + "description": "Output only. Name of the Eventing trigger.", + "readOnly": true, + "type": "string" + }, + "searchTags": { + "description": "Output only. Array of search keywords.", + "items": { + "type": "string" + }, + "readOnly": true, + "type": "array" + } + }, + "type": "object" + }, + "EventingRuntimeData": { + "description": "Eventing runtime data has the details related to eventing managed by the system.", + "id": "EventingRuntimeData", + "properties": { + "eventsListenerEndpoint": { + "description": "Output only. Events listener endpoint. The value will populated after provisioning the events listener.", + "readOnly": true, + "type": "string" + }, + "status": { + "$ref": "EventingStatus", + "description": "Output only. Current status of eventing.", + "readOnly": true + } + }, + "type": "object" + }, + "EventingStatus": { + "description": "EventingStatus indicates the state of eventing.", + "id": "EventingStatus", + "properties": { + "description": { + "description": "Output only. Description of error if State is set to \"ERROR\".", + "readOnly": true, + "type": "string" + }, + "state": { + "description": "Output only. State.", + "enum": [ + "STATE_UNSPECIFIED", + "ACTIVE", + "ERROR" + ], + "enumDescriptions": [ + "Default state.", + "Eventing is enabled and ready to receive events.", + "Eventing is not active due to an error." + ], + "readOnly": true, + "type": "string" + } + }, + "type": "object" + }, + "Expr": { + "description": "Represents a textual expression in the Common Expression Language (CEL) syntax. CEL is a C-like expression language. The syntax and semantics of CEL are documented at https://github.com/google/cel-spec. Example (Comparison): title: \"Summary size limit\" description: \"Determines if a summary is less than 100 chars\" expression: \"document.summary.size() \u003c 100\" Example (Equality): title: \"Requestor is owner\" description: \"Determines if requestor is the document owner\" expression: \"document.owner == request.auth.claims.email\" Example (Logic): title: \"Public documents\" description: \"Determine whether the document should be publicly visible\" expression: \"document.type != 'private' \u0026\u0026 document.type != 'internal'\" Example (Data Manipulation): title: \"Notification string\" description: \"Create a notification string with a timestamp.\" expression: \"'New message received at ' + string(document.create_time)\" The exact variables and functions that may be referenced within an expression are determined by the service that evaluates it. See the service documentation for additional information.", + "id": "Expr", "properties": { "description": { "description": "Optional. Description of the expression. This is a longer text which describes the expression, e.g. when hovered over it in a UI.", @@ -2526,6 +3266,53 @@ "DATA_TYPE_TIME_WITH_TIMEZONE", "DATA_TYPE_TIMESTAMP_WITH_TIMEZONE" ], + "enumDeprecated": [ + false, + true, + false, + false, + false, + true, + false, + true, + true, + false, + false, + true, + false, + false, + false, + false, + false, + false, + false, + false, + false, + false, + false, + false, + false, + false, + false, + false, + false, + false, + false, + false, + false, + false, + false, + false, + false, + false, + false, + false, + false, + false, + false, + false, + false + ], "enumDescriptions": [ "Data type is not specified.", "DEPRECATED! Use DATA_TYPE_INTEGER.", @@ -2640,6 +3427,21 @@ }, "type": "object" }, + "Header": { + "description": "Header details for a given header to be added to Endpoint.", + "id": "Header", + "properties": { + "key": { + "description": "Key of Header.", + "type": "string" + }, + "value": { + "description": "Value of Header.", + "type": "string" + } + }, + "type": "object" + }, "InputParameter": { "description": "Metadata of an input parameter.", "id": "InputParameter", @@ -2693,6 +3495,53 @@ "DATA_TYPE_TIME_WITH_TIMEZONE", "DATA_TYPE_TIMESTAMP_WITH_TIMEZONE" ], + "enumDeprecated": [ + false, + true, + false, + false, + false, + true, + false, + true, + true, + false, + false, + true, + false, + false, + false, + false, + false, + false, + false, + false, + false, + false, + false, + false, + false, + false, + false, + false, + false, + false, + false, + false, + false, + false, + false, + false, + false, + false, + false, + false, + false, + false, + false, + false, + false + ], "enumDescriptions": [ "Data type is not specified.", "DEPRECATED! Use DATA_TYPE_INTEGER.", @@ -2880,6 +3729,49 @@ }, "type": "object" }, + "ListEventSubscriptionsResponse": { + "description": "Response message for ConnectorsService.ListEventSubscriptions", + "id": "ListEventSubscriptionsResponse", + "properties": { + "eventSubscriptions": { + "description": "Subscriptions.", + "items": { + "$ref": "EventSubscription" + }, + "type": "array" + }, + "nextPageToken": { + "description": "Next page token.", + "type": "string" + }, + "unreachable": { + "description": "Locations that could not be reached.", + "items": { + "type": "string" + }, + "type": "array" + } + }, + "type": "object" + }, + "ListEventTypesResponse": { + "description": "Response message for Connectors.ListEventTypes.", + "id": "ListEventTypesResponse", + "properties": { + "eventTypes": { + "description": "A list of connector versions.", + "items": { + "$ref": "EventType" + }, + "type": "array" + }, + "nextPageToken": { + "description": "Next page token.", + "type": "string" + } + }, + "type": "object" + }, "ListLocationsResponse": { "description": "The response message for Locations.ListLocations.", "id": "ListLocationsResponse", @@ -3407,6 +4299,12 @@ "properties": {}, "type": "object" }, + "RepairEventingRequest": { + "description": "Request message for ConnectorsService.RepairEventing", + "id": "RepairEventingRequest", + "properties": {}, + "type": "object" + }, "Resource": { "description": "Resource definition", "id": "Resource", @@ -3489,6 +4387,53 @@ "DATA_TYPE_TIME_WITH_TIMEZONE", "DATA_TYPE_TIMESTAMP_WITH_TIMEZONE" ], + "enumDeprecated": [ + false, + true, + false, + false, + false, + true, + false, + true, + true, + false, + false, + true, + false, + false, + false, + false, + false, + false, + false, + false, + false, + false, + false, + false, + false, + false, + false, + false, + false, + false, + false, + false, + false, + false, + false, + false, + false, + false, + false, + false, + false, + false, + false, + false, + false + ], "enumDescriptions": [ "Data type is not specified.", "DEPRECATED! Use DATA_TYPE_INTEGER.", @@ -3549,6 +4494,12 @@ }, "type": "object" }, + "RetryEventSubscriptionRequest": { + "description": "Request message for ConnectorsService.RefreshEventSubscription", + "id": "RetryEventSubscriptionRequest", + "properties": {}, + "type": "object" + }, "RoleGrant": { "description": "This configuration defines all the Cloud IAM roles that needs to be granted to a particular GCP resource for the selected principal like service account. These configurations will let UI display to customers what IAM roles need to be granted by them. Or these configurations can be used by the UI to render a 'grant' button to do the same on behalf of the user.", "id": "RoleGrant", @@ -3671,6 +4622,15 @@ "DELETING", "UPDATING" ], + "enumDeprecated": [ + false, + true, + true, + false, + false, + false, + false + ], "enumDescriptions": [ "STATE_UNSPECIFIED.", "INACTIVE.", diff --git a/connectors/v1/connectors-gen.go b/connectors/v1/connectors-gen.go index d1bfe41189d..b8e3a20c480 100644 --- a/connectors/v1/connectors-gen.go +++ b/connectors/v1/connectors-gen.go @@ -177,6 +177,7 @@ type ProjectsLocationsService struct { func NewProjectsLocationsConnectionsService(s *Service) *ProjectsLocationsConnectionsService { rs := &ProjectsLocationsConnectionsService{s: s} rs.ConnectionSchemaMetadata = NewProjectsLocationsConnectionsConnectionSchemaMetadataService(s) + rs.EventSubscriptions = NewProjectsLocationsConnectionsEventSubscriptionsService(s) rs.RuntimeActionSchemas = NewProjectsLocationsConnectionsRuntimeActionSchemasService(s) rs.RuntimeEntitySchemas = NewProjectsLocationsConnectionsRuntimeEntitySchemasService(s) return rs @@ -187,6 +188,8 @@ type ProjectsLocationsConnectionsService struct { ConnectionSchemaMetadata *ProjectsLocationsConnectionsConnectionSchemaMetadataService + EventSubscriptions *ProjectsLocationsConnectionsEventSubscriptionsService + RuntimeActionSchemas *ProjectsLocationsConnectionsRuntimeActionSchemasService RuntimeEntitySchemas *ProjectsLocationsConnectionsRuntimeEntitySchemasService @@ -201,6 +204,15 @@ type ProjectsLocationsConnectionsConnectionSchemaMetadataService struct { s *Service } +func NewProjectsLocationsConnectionsEventSubscriptionsService(s *Service) *ProjectsLocationsConnectionsEventSubscriptionsService { + rs := &ProjectsLocationsConnectionsEventSubscriptionsService{s: s} + return rs +} + +type ProjectsLocationsConnectionsEventSubscriptionsService struct { + s *Service +} + func NewProjectsLocationsConnectionsRuntimeActionSchemasService(s *Service) *ProjectsLocationsConnectionsRuntimeActionSchemasService { rs := &ProjectsLocationsConnectionsRuntimeActionSchemasService{s: s} return rs @@ -284,11 +296,23 @@ type ProjectsLocationsProvidersConnectorsService struct { func NewProjectsLocationsProvidersConnectorsVersionsService(s *Service) *ProjectsLocationsProvidersConnectorsVersionsService { rs := &ProjectsLocationsProvidersConnectorsVersionsService{s: s} + rs.Eventtypes = NewProjectsLocationsProvidersConnectorsVersionsEventtypesService(s) return rs } type ProjectsLocationsProvidersConnectorsVersionsService struct { s *Service + + Eventtypes *ProjectsLocationsProvidersConnectorsVersionsEventtypesService +} + +func NewProjectsLocationsProvidersConnectorsVersionsEventtypesService(s *Service) *ProjectsLocationsProvidersConnectorsVersionsEventtypesService { + rs := &ProjectsLocationsProvidersConnectorsVersionsEventtypesService{s: s} + return rs +} + +type ProjectsLocationsProvidersConnectorsVersionsEventtypesService struct { + s *Service } // AuditConfig: Specifies the audit configuration for a service. The @@ -775,6 +799,10 @@ type Connection struct { // global location is supported for ConnectorVersion resource. ConnectorVersion string `json:"connectorVersion,omitempty"` + // ConnectorVersionInfraConfig: Output only. Infra configs supported by + // Connector Version. + ConnectorVersionInfraConfig *ConnectorVersionInfraConfig `json:"connectorVersionInfraConfig,omitempty"` + // ConnectorVersionLaunchStage: Output only. Flag to mark the version // indicating the launch stage. // @@ -801,6 +829,22 @@ type Connection struct { // is stored. formatted like: gcr.io/{bucketName}/{imageName} EnvoyImageLocation string `json:"envoyImageLocation,omitempty"` + // EventingConfig: Optional. Eventing config of a connection + EventingConfig *EventingConfig `json:"eventingConfig,omitempty"` + + // EventingEnablementType: Optional. Eventing enablement type. Will be + // nil if eventing is not enabled. + // + // Possible values: + // "EVENTING_ENABLEMENT_TYPE_UNSPECIFIED" - Eventing Enablement Type + // Unspecifeied. + // "EVENTING_AND_CONNECTION" - Both connection and eventing. + // "ONLY_EVENTING" - Only Eventing. + EventingEnablementType string `json:"eventingEnablementType,omitempty"` + + // EventingRuntimeData: Output only. Eventing Runtime Data. + EventingRuntimeData *EventingRuntimeData `json:"eventingRuntimeData,omitempty"` + // ImageLocation: Output only. GCR location where the runtime image is // stored. formatted like: gcr.io/{bucketName}/{imageName} ImageLocation string `json:"imageLocation,omitempty"` @@ -1003,6 +1047,10 @@ type Connector struct { // DocumentationUri: Output only. Link to documentation page. DocumentationUri string `json:"documentationUri,omitempty"` + // EventingDetails: Output only. Eventing details. Will be null if + // eventing is not supported. + EventingDetails *EventingDetails `json:"eventingDetails,omitempty"` + // ExternalUri: Output only. Link to external page. ExternalUri string `json:"externalUri,omitempty"` @@ -1062,6 +1110,38 @@ func (s *Connector) MarshalJSON() ([]byte, error) { return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } +// ConnectorInfraConfig: This cofiguration provides infra configs like +// rate limit threshold which need to be configurable for every +// connector version +type ConnectorInfraConfig struct { + // RatelimitThreshold: Max QPS supported by the connector version before + // throttling of requests. + RatelimitThreshold int64 `json:"ratelimitThreshold,omitempty,string"` + + // ForceSendFields is a list of field names (e.g. "RatelimitThreshold") + // 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. "RatelimitThreshold") 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 *ConnectorInfraConfig) MarshalJSON() ([]byte, error) { + type NoMethod ConnectorInfraConfig + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + // ConnectorVersion: ConnectorVersion indicates a specific version of a // connector. type ConnectorVersion struct { @@ -1073,6 +1153,10 @@ type ConnectorVersion struct { // to create a connection. ConfigVariableTemplates []*ConfigVariableTemplate `json:"configVariableTemplates,omitempty"` + // ConnectorInfraConfig: Output only. Infra configs supported by + // Connector. + ConnectorInfraConfig *ConnectorInfraConfig `json:"connectorInfraConfig,omitempty"` + // CreateTime: Output only. Created time. CreateTime string `json:"createTime,omitempty"` @@ -1086,6 +1170,10 @@ type ConnectorVersion struct { // EgressControlConfig: Output only. Configuration for Egress Control. EgressControlConfig *EgressControlConfig `json:"egressControlConfig,omitempty"` + // EventingConfigTemplate: Output only. Eventing configuration supported + // by the Connector. + EventingConfigTemplate *EventingConfigTemplate `json:"eventingConfigTemplate,omitempty"` + // Labels: Output only. Resource labels to represent user-provided // metadata. Refer to cloud documentation on labels for more details. // https://cloud.google.com/compute/docs/labeling-resources @@ -1159,6 +1247,38 @@ func (s *ConnectorVersion) MarshalJSON() ([]byte, error) { return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } +// ConnectorVersionInfraConfig: This cofiguration provides infra configs +// like rate limit threshold which need to be configurable for every +// connector version +type ConnectorVersionInfraConfig struct { + // RatelimitThreshold: Output only. Max QPS supported by the connector + // version before throttling of requests. + RatelimitThreshold int64 `json:"ratelimitThreshold,omitempty,string"` + + // ForceSendFields is a list of field names (e.g. "RatelimitThreshold") + // 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. "RatelimitThreshold") 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 *ConnectorVersionInfraConfig) MarshalJSON() ([]byte, error) { + type NoMethod ConnectorVersionInfraConfig + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + // ConnectorsLogConfig: Log configuration for the connection. type ConnectorsLogConfig struct { // Enabled: Enabled represents whether logging is enabled or not for a @@ -1403,6 +1523,38 @@ func (s *EncryptionKey) MarshalJSON() ([]byte, error) { return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } +// EndPoint: Endpoint message includes details of the Destination +// endpoint. +type EndPoint struct { + // EndpointUri: The URI of the Endpoint. + EndpointUri string `json:"endpointUri,omitempty"` + + // Headers: List of Header to be added to the Endpoint. + Headers []*Header `json:"headers,omitempty"` + + // ForceSendFields is a list of field names (e.g. "EndpointUri") 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. "EndpointUri") 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 *EndPoint) MarshalJSON() ([]byte, error) { + type NoMethod EndPoint + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + // EndpointAttachment: represents the Connector's Endpoint Attachment // resource type EndpointAttachment struct { @@ -1490,42 +1642,125 @@ func (s *EnumOption) MarshalJSON() ([]byte, error) { return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } -// Expr: Represents a textual expression in the Common Expression -// Language (CEL) syntax. CEL is a C-like expression language. The -// syntax and semantics of CEL are documented at -// https://github.com/google/cel-spec. Example (Comparison): title: -// "Summary size limit" description: "Determines if a summary is less -// than 100 chars" expression: "document.summary.size() < 100" Example -// (Equality): title: "Requestor is owner" description: "Determines if -// requestor is the document owner" expression: "document.owner == -// request.auth.claims.email" Example (Logic): title: "Public documents" -// description: "Determine whether the document should be publicly -// visible" expression: "document.type != 'private' && document.type != -// 'internal'" Example (Data Manipulation): title: "Notification string" -// description: "Create a notification string with a timestamp." -// expression: "'New message received at ' + -// string(document.create_time)" The exact variables and functions that -// may be referenced within an expression are determined by the service -// that evaluates it. See the service documentation for additional -// information. -type Expr struct { - // Description: Optional. Description of the expression. This is a - // longer text which describes the expression, e.g. when hovered over it - // in a UI. - Description string `json:"description,omitempty"` +// EventSubscription: represents the Connector's EventSubscription +// resource +type EventSubscription struct { + // CreateTime: Output only. Created time. + CreateTime string `json:"createTime,omitempty"` - // Expression: Textual representation of an expression in Common - // Expression Language syntax. - Expression string `json:"expression,omitempty"` + // Destinations: Optional. The destination to hit when we receive an + // event + Destinations *EventSubscriptionDestination `json:"destinations,omitempty"` - // Location: Optional. String indicating the location of the expression - // for error reporting, e.g. a file name and a position in the file. - Location string `json:"location,omitempty"` + // EventTypeId: Optional. Event type id of the event of current + // EventSubscription. + EventTypeId string `json:"eventTypeId,omitempty"` - // Title: Optional. Title for the expression, i.e. a short string - // describing its purpose. This can be used e.g. in UIs which allow to - // enter the expression. - Title string `json:"title,omitempty"` + // Name: Required. Resource name of the EventSubscription. Format: + // projects/{project}/locations/{location}/connections/{connection}/event + // Subscriptions/{event_subscription} + Name string `json:"name,omitempty"` + + // Status: Optional. Status indicates the status of the event + // subscription resource + Status *EventSubscriptionStatus `json:"status,omitempty"` + + // Subscriber: Optional. name of the Subscriber for the current + // EventSubscription. + Subscriber string `json:"subscriber,omitempty"` + + // SubscriberLink: Optional. Link for Subscriber of the current + // EventSubscription. + SubscriberLink string `json:"subscriberLink,omitempty"` + + // UpdateTime: Output only. Updated time. + 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 *EventSubscription) MarshalJSON() ([]byte, error) { + type NoMethod EventSubscription + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + +// EventSubscriptionDestination: Message for EventSubscription +// Destination to act on receiving an event +type EventSubscriptionDestination struct { + // Endpoint: OPTION 1: Hit an endpoint when we receive an event. + Endpoint *EndPoint `json:"endpoint,omitempty"` + + // ServiceAccount: Service account needed for runtime plane to trigger + // IP workflow. + ServiceAccount string `json:"serviceAccount,omitempty"` + + // Type: type of the destination + // + // Possible values: + // "TYPE_UNSPECIFIED" - Default state. + // "ENDPOINT" - Endpoint - Hit the value of endpoint when event is + // received + Type string `json:"type,omitempty"` + + // ForceSendFields is a list of field names (e.g. "Endpoint") 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. "Endpoint") 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 *EventSubscriptionDestination) MarshalJSON() ([]byte, error) { + type NoMethod EventSubscriptionDestination + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + +// EventSubscriptionStatus: EventSubscription Status denotes the status +// of the EventSubscription resource. +type EventSubscriptionStatus struct { + // Description: Output only. Description of the state. + Description string `json:"description,omitempty"` + + // State: Output only. State of Event Subscription resource. + // + // Possible values: + // "STATE_UNSPECIFIED" - Default state. + // "CREATING" - EventSubscription creation is in progress. + // "UPDATING" - EventSubscription is in Updating status. + // "ACTIVE" - EventSubscription is in Active state and is ready to + // receive events. + // "SUSPENDED" - EventSubscription is currently suspended. + // "ERROR" - EventSubscription is in Error state. + State string `json:"state,omitempty"` // ForceSendFields is a list of field names (e.g. "Description") to // unconditionally include in API requests. By default, fields with @@ -1544,22 +1779,49 @@ type Expr struct { NullFields []string `json:"-"` } -func (s *Expr) MarshalJSON() ([]byte, error) { - type NoMethod Expr +func (s *EventSubscriptionStatus) MarshalJSON() ([]byte, error) { + type NoMethod EventSubscriptionStatus raw := NoMethod(*s) return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } -// ExtractionRule: Extraction Rule. -type ExtractionRule struct { - // ExtractionRegex: Regex used to extract backend details from source. - // If empty, whole source value will be used. - ExtractionRegex string `json:"extractionRegex,omitempty"` +// EventType: EventType includes fields. +type EventType struct { + // CreateTime: Output only. Created time. + CreateTime string `json:"createTime,omitempty"` - // Source: Source on which the rule is applied. - Source *Source `json:"source,omitempty"` + // EnrichedEventPayloadSchema: Output only. Schema of the event payload + // after enriched. Will be null if read before send is not supported. + EnrichedEventPayloadSchema string `json:"enrichedEventPayloadSchema,omitempty"` - // ForceSendFields is a list of field names (e.g. "ExtractionRegex") to + // EntityType: Output only. Runtime entity type name. Will be null if + // entity type map is not available. Used for read before send feature. + EntityType string `json:"entityType,omitempty"` + + // EventPayloadSchema: Output only. Schema of webhook event payload. + EventPayloadSchema string `json:"eventPayloadSchema,omitempty"` + + // EventTypeId: Output only. Event type id. Example: `ticket.created`. + EventTypeId string `json:"eventTypeId,omitempty"` + + // IdPath: Output only. Id path denotes the path of id in webhook + // payload. + IdPath string `json:"idPath,omitempty"` + + // Name: Output only. Resource name of the eventtype. Format: + // projects/{project}/locations/{location}/providers/{provider}/connector + // s/{connector}/versions/{version}/eventtypes/{eventtype} Only global + // location is supported for Connector resource. + Name string `json:"name,omitempty"` + + // UpdateTime: Output only. Updated time. + 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 @@ -1567,37 +1829,48 @@ type ExtractionRule struct { // This may be used to include empty fields in Patch requests. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "ExtractionRegex") to - // include in API requests with the JSON null value. By default, fields - // with empty values are omitted from API requests. However, any field - // with an empty value appearing in NullFields will be sent to the - // server as null. It is an error if a field in this list has a - // non-empty value. This may be used to include null fields in Patch - // requests. + // NullFields is a list of field names (e.g. "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 *ExtractionRule) MarshalJSON() ([]byte, error) { - type NoMethod ExtractionRule +func (s *EventType) MarshalJSON() ([]byte, error) { + type NoMethod EventType raw := NoMethod(*s) return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } -// ExtractionRules: Extraction Rules to identity the backends from -// customer provided configuration in Connection resource. -type ExtractionRules struct { - // ExtractionRule: Collection of Extraction Rule. - ExtractionRule []*ExtractionRule `json:"extractionRule,omitempty"` +// EventingConfig: Eventing Configuration of a connection +type EventingConfig struct { + // AdditionalVariables: Additional eventing related field values + AdditionalVariables []*ConfigVariable `json:"additionalVariables,omitempty"` - // ForceSendFields is a list of field names (e.g. "ExtractionRule") to - // unconditionally include in API requests. By default, fields with + // AuthConfig: Auth details for the webhook adapter. + AuthConfig *AuthConfig `json:"authConfig,omitempty"` + + // EncryptionKey: Encryption key (can be either Google managed or CMEK). + EncryptionKey *ConfigVariable `json:"encryptionKey,omitempty"` + + // EnrichmentEnabled: Enrichment Enabled. + EnrichmentEnabled bool `json:"enrichmentEnabled,omitempty"` + + // RegistrationDestinationConfig: Registration endpoint for auto + // regsitration. + RegistrationDestinationConfig *DestinationConfig `json:"registrationDestinationConfig,omitempty"` + + // ForceSendFields is a list of field names (e.g. "AdditionalVariables") + // 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. "ExtractionRule") to + // NullFields is a list of field names (e.g. "AdditionalVariables") 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 @@ -1607,18 +1880,321 @@ type ExtractionRules struct { NullFields []string `json:"-"` } -func (s *ExtractionRules) MarshalJSON() ([]byte, error) { - type NoMethod ExtractionRules +func (s *EventingConfig) MarshalJSON() ([]byte, error) { + type NoMethod EventingConfig raw := NoMethod(*s) return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } -// Field: Metadata of an entity field. -type Field struct { - // AdditionalDetails: The following map contains fields that are not - // explicitly mentioned above,this give connectors the flexibility to - // add new metadata fields. - AdditionalDetails googleapi.RawMessage `json:"additionalDetails,omitempty"` +// EventingConfigTemplate: Eventing Config details of a connector +// version. +type EventingConfigTemplate struct { + // AdditionalVariables: Additional fields that need to be rendered. + AdditionalVariables []*ConfigVariableTemplate `json:"additionalVariables,omitempty"` + + // AuthConfigTemplates: AuthConfigTemplates represents the auth values + // for the webhook adapter. + AuthConfigTemplates []*AuthConfigTemplate `json:"authConfigTemplates,omitempty"` + + // AutoRefresh: Auto refresh to extend webhook life. + AutoRefresh bool `json:"autoRefresh,omitempty"` + + // AutoRegistrationSupported: Auto Registration supported. + AutoRegistrationSupported bool `json:"autoRegistrationSupported,omitempty"` + + // EncryptionKeyTemplate: Encryption key (can be either Google managed + // or CMEK). + EncryptionKeyTemplate *ConfigVariableTemplate `json:"encryptionKeyTemplate,omitempty"` + + // EnrichmentSupported: Enrichment Supported. + EnrichmentSupported bool `json:"enrichmentSupported,omitempty"` + + // IsEventingSupported: Is Eventing Supported. + IsEventingSupported bool `json:"isEventingSupported,omitempty"` + + // RegistrationDestinationConfig: Registration host destination config + // template. + RegistrationDestinationConfig *DestinationConfigTemplate `json:"registrationDestinationConfig,omitempty"` + + // ForceSendFields is a list of field names (e.g. "AdditionalVariables") + // 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. "AdditionalVariables") 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 *EventingConfigTemplate) MarshalJSON() ([]byte, error) { + type NoMethod EventingConfigTemplate + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + +// EventingDetails: Eventing Details message. +type EventingDetails struct { + // CustomEventTypes: Output only. Custom Event Types. + CustomEventTypes bool `json:"customEventTypes,omitempty"` + + // Description: Output only. Description. + Description string `json:"description,omitempty"` + + // DocumentationLink: Output only. Link to public documentation. + DocumentationLink string `json:"documentationLink,omitempty"` + + // IconLocation: Output only. Cloud storage location of the icon. + IconLocation string `json:"iconLocation,omitempty"` + + // LaunchStage: Output only. Eventing Launch Stage. + // + // Possible values: + // "LAUNCH_STAGE_UNSPECIFIED" - LAUNCH_STAGE_UNSPECIFIED. + // "PREVIEW" - PREVIEW. + // "GA" - GA. + // "DEPRECATED" - DEPRECATED. + // "PRIVATE_PREVIEW" - PRIVATE_PREVIEW. + LaunchStage string `json:"launchStage,omitempty"` + + // Name: Output only. Name of the Eventing trigger. + Name string `json:"name,omitempty"` + + // SearchTags: Output only. Array of search keywords. + SearchTags []string `json:"searchTags,omitempty"` + + // ForceSendFields is a list of field names (e.g. "CustomEventTypes") 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. "CustomEventTypes") 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 *EventingDetails) MarshalJSON() ([]byte, error) { + type NoMethod EventingDetails + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + +// EventingRuntimeData: Eventing runtime data has the details related to +// eventing managed by the system. +type EventingRuntimeData struct { + // EventsListenerEndpoint: Output only. Events listener endpoint. The + // value will populated after provisioning the events listener. + EventsListenerEndpoint string `json:"eventsListenerEndpoint,omitempty"` + + // Status: Output only. Current status of eventing. + Status *EventingStatus `json:"status,omitempty"` + + // ForceSendFields is a list of field names (e.g. + // "EventsListenerEndpoint") 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. "EventsListenerEndpoint") + // 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 *EventingRuntimeData) MarshalJSON() ([]byte, error) { + type NoMethod EventingRuntimeData + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + +// EventingStatus: EventingStatus indicates the state of eventing. +type EventingStatus struct { + // Description: Output only. Description of error if State is set to + // "ERROR". + Description string `json:"description,omitempty"` + + // State: Output only. State. + // + // Possible values: + // "STATE_UNSPECIFIED" - Default state. + // "ACTIVE" - Eventing is enabled and ready to receive events. + // "ERROR" - Eventing is not active due to an error. + State string `json:"state,omitempty"` + + // ForceSendFields is a list of field names (e.g. "Description") 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. "Description") 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 *EventingStatus) MarshalJSON() ([]byte, error) { + type NoMethod EventingStatus + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + +// Expr: Represents a textual expression in the Common Expression +// Language (CEL) syntax. CEL is a C-like expression language. The +// syntax and semantics of CEL are documented at +// https://github.com/google/cel-spec. Example (Comparison): title: +// "Summary size limit" description: "Determines if a summary is less +// than 100 chars" expression: "document.summary.size() < 100" Example +// (Equality): title: "Requestor is owner" description: "Determines if +// requestor is the document owner" expression: "document.owner == +// request.auth.claims.email" Example (Logic): title: "Public documents" +// description: "Determine whether the document should be publicly +// visible" expression: "document.type != 'private' && document.type != +// 'internal'" Example (Data Manipulation): title: "Notification string" +// description: "Create a notification string with a timestamp." +// expression: "'New message received at ' + +// string(document.create_time)" The exact variables and functions that +// may be referenced within an expression are determined by the service +// that evaluates it. See the service documentation for additional +// information. +type Expr struct { + // Description: Optional. Description of the expression. This is a + // longer text which describes the expression, e.g. when hovered over it + // in a UI. + Description string `json:"description,omitempty"` + + // Expression: Textual representation of an expression in Common + // Expression Language syntax. + Expression string `json:"expression,omitempty"` + + // Location: Optional. String indicating the location of the expression + // for error reporting, e.g. a file name and a position in the file. + Location string `json:"location,omitempty"` + + // Title: Optional. Title for the expression, i.e. a short string + // describing its purpose. This can be used e.g. in UIs which allow to + // enter the expression. + Title string `json:"title,omitempty"` + + // ForceSendFields is a list of field names (e.g. "Description") 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. "Description") 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 *Expr) MarshalJSON() ([]byte, error) { + type NoMethod Expr + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + +// ExtractionRule: Extraction Rule. +type ExtractionRule struct { + // ExtractionRegex: Regex used to extract backend details from source. + // If empty, whole source value will be used. + ExtractionRegex string `json:"extractionRegex,omitempty"` + + // Source: Source on which the rule is applied. + Source *Source `json:"source,omitempty"` + + // ForceSendFields is a list of field names (e.g. "ExtractionRegex") 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. "ExtractionRegex") 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 *ExtractionRule) MarshalJSON() ([]byte, error) { + type NoMethod ExtractionRule + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + +// ExtractionRules: Extraction Rules to identity the backends from +// customer provided configuration in Connection resource. +type ExtractionRules struct { + // ExtractionRule: Collection of Extraction Rule. + ExtractionRule []*ExtractionRule `json:"extractionRule,omitempty"` + + // ForceSendFields is a list of field names (e.g. "ExtractionRule") 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. "ExtractionRule") 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 *ExtractionRules) MarshalJSON() ([]byte, error) { + type NoMethod ExtractionRules + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + +// Field: Metadata of an entity field. +type Field struct { + // AdditionalDetails: The following map contains fields that are not + // explicitly mentioned above,this give connectors the flexibility to + // add new metadata fields. + AdditionalDetails googleapi.RawMessage `json:"additionalDetails,omitempty"` // DataType: The data type of the Field. // @@ -1765,16 +2341,47 @@ func (s *FieldComparison) MarshalJSON() ([]byte, error) { return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } -// InputParameter: Metadata of an input parameter. -type InputParameter struct { - // DataType: The data type of the Parameter. - // - // Possible values: - // "DATA_TYPE_UNSPECIFIED" - Data type is not specified. - // "DATA_TYPE_INT" - DEPRECATED! Use DATA_TYPE_INTEGER. - // "DATA_TYPE_SMALLINT" - Short integer(int16) data type. - // "DATA_TYPE_DOUBLE" - Double data type. - // "DATA_TYPE_DATE" - Date data type. +// Header: Header details for a given header to be added to Endpoint. +type Header struct { + // Key: Key of Header. + Key string `json:"key,omitempty"` + + // Value: Value of Header. + Value string `json:"value,omitempty"` + + // ForceSendFields is a list of field names (e.g. "Key") 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. "Key") 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 *Header) MarshalJSON() ([]byte, error) { + type NoMethod Header + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + +// InputParameter: Metadata of an input parameter. +type InputParameter struct { + // DataType: The data type of the Parameter. + // + // Possible values: + // "DATA_TYPE_UNSPECIFIED" - Data type is not specified. + // "DATA_TYPE_INT" - DEPRECATED! Use DATA_TYPE_INTEGER. + // "DATA_TYPE_SMALLINT" - Short integer(int16) data type. + // "DATA_TYPE_DOUBLE" - Double data type. + // "DATA_TYPE_DATE" - Date data type. // "DATA_TYPE_DATETIME" - DEPRECATED! Use DATA_TYPE_TIMESTAMP. // "DATA_TYPE_TIME" - Time data type. // "DATA_TYPE_STRING" - DEPRECATED! Use DATA_TYPE_VARCHAR. @@ -2050,6 +2657,82 @@ func (s *ListEndpointAttachmentsResponse) MarshalJSON() ([]byte, error) { return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } +// ListEventSubscriptionsResponse: Response message for +// ConnectorsService.ListEventSubscriptions +type ListEventSubscriptionsResponse struct { + // EventSubscriptions: Subscriptions. + EventSubscriptions []*EventSubscription `json:"eventSubscriptions,omitempty"` + + // NextPageToken: Next page token. + 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. "EventSubscriptions") + // 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. "EventSubscriptions") 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 *ListEventSubscriptionsResponse) MarshalJSON() ([]byte, error) { + type NoMethod ListEventSubscriptionsResponse + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + +// ListEventTypesResponse: Response message for +// Connectors.ListEventTypes. +type ListEventTypesResponse struct { + // EventTypes: A list of connector versions. + EventTypes []*EventType `json:"eventTypes,omitempty"` + + // NextPageToken: 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. "EventTypes") 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. "EventTypes") 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 *ListEventTypesResponse) MarshalJSON() ([]byte, error) { + type NoMethod ListEventTypesResponse + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + // ListLocationsResponse: The response message for // Locations.ListLocations. type ListLocationsResponse struct { @@ -2906,6 +3589,11 @@ func (s *Provider) MarshalJSON() ([]byte, error) { type RefreshConnectionSchemaMetadataRequest struct { } +// RepairEventingRequest: Request message for +// ConnectorsService.RepairEventing +type RepairEventingRequest struct { +} + // Resource: Resource definition type Resource struct { // PathTemplate: Template to uniquely represent a GCP resource in a @@ -3033,6 +3721,11 @@ func (s *ResultMetadata) MarshalJSON() ([]byte, error) { return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } +// RetryEventSubscriptionRequest: Request message for +// ConnectorsService.RefreshEventSubscription +type RetryEventSubscriptionRequest struct { +} + // RoleGrant: This configuration defines all the Cloud IAM roles that // needs to be granted to a particular GCP resource for the selected // principal like service account. These configurations will let UI @@ -3715,92 +4408,1631 @@ type UserPassword struct { // This may be used to include empty fields in Patch requests. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "Password") 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:"-"` + // NullFields is a list of field names (e.g. "Password") 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 *UserPassword) MarshalJSON() ([]byte, error) { + type NoMethod UserPassword + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + +// method id "connectors.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, "v1/{+name}") + urls += "?" + c.urlParams_.Encode() + req, err := http.NewRequest("GET", urls, body) + if err != nil { + return nil, err + } + req.Header = reqHeaders + googleapi.Expand(req.URL, map[string]string{ + "name": c.name, + }) + return gensupport.SendRequest(c.ctx_, c.s.client, req) +} + +// Do executes the "connectors.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": "v1/projects/{projectsId}/locations/{locationsId}", + // "httpMethod": "GET", + // "id": "connectors.projects.locations.get", + // "parameterOrder": [ + // "name" + // ], + // "parameters": { + // "name": { + // "description": "Resource name for the location.", + // "location": "path", + // "pattern": "^projects/[^/]+/locations/[^/]+$", + // "required": true, + // "type": "string" + // } + // }, + // "path": "v1/{+name}", + // "response": { + // "$ref": "Location" + // }, + // "scopes": [ + // "https://www.googleapis.com/auth/cloud-platform" + // ] + // } + +} + +// method id "connectors.projects.locations.getRuntimeConfig": + +type ProjectsLocationsGetRuntimeConfigCall struct { + s *Service + name string + urlParams_ gensupport.URLParams + ifNoneMatch_ string + ctx_ context.Context + header_ http.Header +} + +// GetRuntimeConfig: Gets the runtimeConfig of a location. RuntimeConfig +// is a singleton resource for each location. +// +// - name: Resource name of the form: +// `projects/*/locations/*/runtimeConfig`. +func (r *ProjectsLocationsService) GetRuntimeConfig(name string) *ProjectsLocationsGetRuntimeConfigCall { + c := &ProjectsLocationsGetRuntimeConfigCall{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 *ProjectsLocationsGetRuntimeConfigCall) Fields(s ...googleapi.Field) *ProjectsLocationsGetRuntimeConfigCall { + 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 *ProjectsLocationsGetRuntimeConfigCall) IfNoneMatch(entityTag string) *ProjectsLocationsGetRuntimeConfigCall { + 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 *ProjectsLocationsGetRuntimeConfigCall) Context(ctx context.Context) *ProjectsLocationsGetRuntimeConfigCall { + 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 *ProjectsLocationsGetRuntimeConfigCall) Header() http.Header { + if c.header_ == nil { + c.header_ = make(http.Header) + } + return c.header_ +} + +func (c *ProjectsLocationsGetRuntimeConfigCall) doRequest(alt string) (*http.Response, error) { + reqHeaders := make(http.Header) + reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version) + for k, v := range c.header_ { + reqHeaders[k] = v + } + reqHeaders.Set("User-Agent", c.s.userAgent()) + if c.ifNoneMatch_ != "" { + reqHeaders.Set("If-None-Match", c.ifNoneMatch_) + } + var body io.Reader = nil + c.urlParams_.Set("alt", alt) + c.urlParams_.Set("prettyPrint", "false") + urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+name}") + urls += "?" + c.urlParams_.Encode() + req, err := http.NewRequest("GET", urls, body) + if err != nil { + return nil, err + } + req.Header = reqHeaders + googleapi.Expand(req.URL, map[string]string{ + "name": c.name, + }) + return gensupport.SendRequest(c.ctx_, c.s.client, req) +} + +// Do executes the "connectors.projects.locations.getRuntimeConfig" call. +// Exactly one of *RuntimeConfig or error will be non-nil. Any non-2xx +// status code is an error. Response headers are in either +// *RuntimeConfig.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 *ProjectsLocationsGetRuntimeConfigCall) Do(opts ...googleapi.CallOption) (*RuntimeConfig, 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 := &RuntimeConfig{ + 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 runtimeConfig of a location. RuntimeConfig is a singleton resource for each location.", + // "flatPath": "v1/projects/{projectsId}/locations/{locationsId}/runtimeConfig", + // "httpMethod": "GET", + // "id": "connectors.projects.locations.getRuntimeConfig", + // "parameterOrder": [ + // "name" + // ], + // "parameters": { + // "name": { + // "description": "Required. Resource name of the form: `projects/*/locations/*/runtimeConfig`", + // "location": "path", + // "pattern": "^projects/[^/]+/locations/[^/]+/runtimeConfig$", + // "required": true, + // "type": "string" + // } + // }, + // "path": "v1/{+name}", + // "response": { + // "$ref": "RuntimeConfig" + // }, + // "scopes": [ + // "https://www.googleapis.com/auth/cloud-platform" + // ] + // } + +} + +// method id "connectors.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, "v1/{+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 "connectors.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": "v1/projects/{projectsId}/locations", + // "httpMethod": "GET", + // "id": "connectors.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": "v1/{+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 "connectors.projects.locations.connections.create": + +type ProjectsLocationsConnectionsCreateCall struct { + s *Service + parent string + connection *Connection + urlParams_ gensupport.URLParams + ctx_ context.Context + header_ http.Header +} + +// Create: Creates a new Connection in a given project and location. +// +// - parent: Parent resource of the Connection, of the form: +// `projects/*/locations/*`. +func (r *ProjectsLocationsConnectionsService) Create(parent string, connection *Connection) *ProjectsLocationsConnectionsCreateCall { + c := &ProjectsLocationsConnectionsCreateCall{s: r.s, urlParams_: make(gensupport.URLParams)} + c.parent = parent + c.connection = connection + return c +} + +// ConnectionId sets the optional parameter "connectionId": Required. +// Identifier to assign to the Connection. Must be unique within scope +// of the parent resource. +func (c *ProjectsLocationsConnectionsCreateCall) ConnectionId(connectionId string) *ProjectsLocationsConnectionsCreateCall { + c.urlParams_.Set("connectionId", connectionId) + 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 *ProjectsLocationsConnectionsCreateCall) Fields(s ...googleapi.Field) *ProjectsLocationsConnectionsCreateCall { + 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 *ProjectsLocationsConnectionsCreateCall) Context(ctx context.Context) *ProjectsLocationsConnectionsCreateCall { + 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 *ProjectsLocationsConnectionsCreateCall) Header() http.Header { + if c.header_ == nil { + c.header_ = make(http.Header) + } + return c.header_ +} + +func (c *ProjectsLocationsConnectionsCreateCall) 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.connection) + 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}/connections") + 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 "connectors.projects.locations.connections.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 *ProjectsLocationsConnectionsCreateCall) 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 Connection in a given project and location.", + // "flatPath": "v1/projects/{projectsId}/locations/{locationsId}/connections", + // "httpMethod": "POST", + // "id": "connectors.projects.locations.connections.create", + // "parameterOrder": [ + // "parent" + // ], + // "parameters": { + // "connectionId": { + // "description": "Required. Identifier to assign to the Connection. Must be unique within scope of the parent resource.", + // "location": "query", + // "type": "string" + // }, + // "parent": { + // "description": "Required. Parent resource of the Connection, of the form: `projects/*/locations/*`", + // "location": "path", + // "pattern": "^projects/[^/]+/locations/[^/]+$", + // "required": true, + // "type": "string" + // } + // }, + // "path": "v1/{+parent}/connections", + // "request": { + // "$ref": "Connection" + // }, + // "response": { + // "$ref": "Operation" + // }, + // "scopes": [ + // "https://www.googleapis.com/auth/cloud-platform" + // ] + // } + +} + +// method id "connectors.projects.locations.connections.delete": + +type ProjectsLocationsConnectionsDeleteCall struct { + s *Service + name string + urlParams_ gensupport.URLParams + ctx_ context.Context + header_ http.Header +} + +// Delete: Deletes a single Connection. +// +// - name: Resource name of the form: +// `projects/*/locations/*/connections/*`. +func (r *ProjectsLocationsConnectionsService) Delete(name string) *ProjectsLocationsConnectionsDeleteCall { + c := &ProjectsLocationsConnectionsDeleteCall{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 *ProjectsLocationsConnectionsDeleteCall) Fields(s ...googleapi.Field) *ProjectsLocationsConnectionsDeleteCall { + 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 *ProjectsLocationsConnectionsDeleteCall) Context(ctx context.Context) *ProjectsLocationsConnectionsDeleteCall { + 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 *ProjectsLocationsConnectionsDeleteCall) Header() http.Header { + if c.header_ == nil { + c.header_ = make(http.Header) + } + return c.header_ +} + +func (c *ProjectsLocationsConnectionsDeleteCall) doRequest(alt string) (*http.Response, error) { + reqHeaders := make(http.Header) + reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version) + for k, v := range c.header_ { + reqHeaders[k] = v + } + reqHeaders.Set("User-Agent", c.s.userAgent()) + var body io.Reader = nil + c.urlParams_.Set("alt", alt) + c.urlParams_.Set("prettyPrint", "false") + urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+name}") + urls += "?" + c.urlParams_.Encode() + req, err := http.NewRequest("DELETE", urls, body) + if err != nil { + return nil, err + } + req.Header = reqHeaders + googleapi.Expand(req.URL, map[string]string{ + "name": c.name, + }) + return gensupport.SendRequest(c.ctx_, c.s.client, req) +} + +// Do executes the "connectors.projects.locations.connections.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 *ProjectsLocationsConnectionsDeleteCall) 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 single Connection.", + // "flatPath": "v1/projects/{projectsId}/locations/{locationsId}/connections/{connectionsId}", + // "httpMethod": "DELETE", + // "id": "connectors.projects.locations.connections.delete", + // "parameterOrder": [ + // "name" + // ], + // "parameters": { + // "name": { + // "description": "Required. Resource name of the form: `projects/*/locations/*/connections/*`", + // "location": "path", + // "pattern": "^projects/[^/]+/locations/[^/]+/connections/[^/]+$", + // "required": true, + // "type": "string" + // } + // }, + // "path": "v1/{+name}", + // "response": { + // "$ref": "Operation" + // }, + // "scopes": [ + // "https://www.googleapis.com/auth/cloud-platform" + // ] + // } + +} + +// method id "connectors.projects.locations.connections.get": + +type ProjectsLocationsConnectionsGetCall struct { + s *Service + name string + urlParams_ gensupport.URLParams + ifNoneMatch_ string + ctx_ context.Context + header_ http.Header +} + +// Get: Gets details of a single Connection. +// +// - name: Resource name of the form: +// `projects/*/locations/*/connections/*`. +func (r *ProjectsLocationsConnectionsService) Get(name string) *ProjectsLocationsConnectionsGetCall { + c := &ProjectsLocationsConnectionsGetCall{s: r.s, urlParams_: make(gensupport.URLParams)} + c.name = name + return c +} + +// View sets the optional parameter "view": Specifies which fields of +// the Connection are returned in the response. Defaults to `BASIC` +// view. +// +// Possible values: +// +// "CONNECTION_VIEW_UNSPECIFIED" - CONNECTION_UNSPECIFIED. +// "BASIC" - Do not include runtime required configs. +// "FULL" - Include runtime required configs. +func (c *ProjectsLocationsConnectionsGetCall) View(view string) *ProjectsLocationsConnectionsGetCall { + 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 *ProjectsLocationsConnectionsGetCall) Fields(s ...googleapi.Field) *ProjectsLocationsConnectionsGetCall { + 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 *ProjectsLocationsConnectionsGetCall) IfNoneMatch(entityTag string) *ProjectsLocationsConnectionsGetCall { + 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 *ProjectsLocationsConnectionsGetCall) Context(ctx context.Context) *ProjectsLocationsConnectionsGetCall { + 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 *ProjectsLocationsConnectionsGetCall) Header() http.Header { + if c.header_ == nil { + c.header_ = make(http.Header) + } + return c.header_ +} + +func (c *ProjectsLocationsConnectionsGetCall) doRequest(alt string) (*http.Response, error) { + reqHeaders := make(http.Header) + reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version) + for k, v := range c.header_ { + reqHeaders[k] = v + } + reqHeaders.Set("User-Agent", c.s.userAgent()) + if c.ifNoneMatch_ != "" { + reqHeaders.Set("If-None-Match", c.ifNoneMatch_) + } + var body io.Reader = nil + c.urlParams_.Set("alt", alt) + c.urlParams_.Set("prettyPrint", "false") + urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+name}") + urls += "?" + c.urlParams_.Encode() + req, err := http.NewRequest("GET", urls, body) + if err != nil { + return nil, err + } + req.Header = reqHeaders + googleapi.Expand(req.URL, map[string]string{ + "name": c.name, + }) + return gensupport.SendRequest(c.ctx_, c.s.client, req) +} + +// Do executes the "connectors.projects.locations.connections.get" call. +// Exactly one of *Connection or error will be non-nil. Any non-2xx +// status code is an error. Response headers are in either +// *Connection.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 *ProjectsLocationsConnectionsGetCall) Do(opts ...googleapi.CallOption) (*Connection, 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 := &Connection{ + 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 details of a single Connection.", + // "flatPath": "v1/projects/{projectsId}/locations/{locationsId}/connections/{connectionsId}", + // "httpMethod": "GET", + // "id": "connectors.projects.locations.connections.get", + // "parameterOrder": [ + // "name" + // ], + // "parameters": { + // "name": { + // "description": "Required. Resource name of the form: `projects/*/locations/*/connections/*`", + // "location": "path", + // "pattern": "^projects/[^/]+/locations/[^/]+/connections/[^/]+$", + // "required": true, + // "type": "string" + // }, + // "view": { + // "description": "Specifies which fields of the Connection are returned in the response. Defaults to `BASIC` view.", + // "enum": [ + // "CONNECTION_VIEW_UNSPECIFIED", + // "BASIC", + // "FULL" + // ], + // "enumDescriptions": [ + // "CONNECTION_UNSPECIFIED.", + // "Do not include runtime required configs.", + // "Include runtime required configs." + // ], + // "location": "query", + // "type": "string" + // } + // }, + // "path": "v1/{+name}", + // "response": { + // "$ref": "Connection" + // }, + // "scopes": [ + // "https://www.googleapis.com/auth/cloud-platform" + // ] + // } + +} + +// method id "connectors.projects.locations.connections.getConnectionSchemaMetadata": + +type ProjectsLocationsConnectionsGetConnectionSchemaMetadataCall struct { + s *Service + name string + urlParams_ gensupport.URLParams + ifNoneMatch_ string + ctx_ context.Context + header_ http.Header +} + +// GetConnectionSchemaMetadata: Gets schema metadata of a connection. +// SchemaMetadata is a singleton resource for each connection. +// +// - name: Connection name Format: +// projects/{project}/locations/{location}/connections/{connection}/con +// nectionSchemaMetadata. +func (r *ProjectsLocationsConnectionsService) GetConnectionSchemaMetadata(name string) *ProjectsLocationsConnectionsGetConnectionSchemaMetadataCall { + c := &ProjectsLocationsConnectionsGetConnectionSchemaMetadataCall{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 *ProjectsLocationsConnectionsGetConnectionSchemaMetadataCall) Fields(s ...googleapi.Field) *ProjectsLocationsConnectionsGetConnectionSchemaMetadataCall { + 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 *ProjectsLocationsConnectionsGetConnectionSchemaMetadataCall) IfNoneMatch(entityTag string) *ProjectsLocationsConnectionsGetConnectionSchemaMetadataCall { + 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 *ProjectsLocationsConnectionsGetConnectionSchemaMetadataCall) Context(ctx context.Context) *ProjectsLocationsConnectionsGetConnectionSchemaMetadataCall { + 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 *ProjectsLocationsConnectionsGetConnectionSchemaMetadataCall) Header() http.Header { + if c.header_ == nil { + c.header_ = make(http.Header) + } + return c.header_ +} + +func (c *ProjectsLocationsConnectionsGetConnectionSchemaMetadataCall) doRequest(alt string) (*http.Response, error) { + reqHeaders := make(http.Header) + reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version) + for k, v := range c.header_ { + reqHeaders[k] = v + } + reqHeaders.Set("User-Agent", c.s.userAgent()) + if c.ifNoneMatch_ != "" { + reqHeaders.Set("If-None-Match", c.ifNoneMatch_) + } + var body io.Reader = nil + c.urlParams_.Set("alt", alt) + c.urlParams_.Set("prettyPrint", "false") + urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+name}") + urls += "?" + c.urlParams_.Encode() + req, err := http.NewRequest("GET", urls, body) + if err != nil { + return nil, err + } + req.Header = reqHeaders + googleapi.Expand(req.URL, map[string]string{ + "name": c.name, + }) + return gensupport.SendRequest(c.ctx_, c.s.client, req) +} + +// Do executes the "connectors.projects.locations.connections.getConnectionSchemaMetadata" call. +// Exactly one of *ConnectionSchemaMetadata or error will be non-nil. +// Any non-2xx status code is an error. Response headers are in either +// *ConnectionSchemaMetadata.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 *ProjectsLocationsConnectionsGetConnectionSchemaMetadataCall) Do(opts ...googleapi.CallOption) (*ConnectionSchemaMetadata, 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 := &ConnectionSchemaMetadata{ + 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 schema metadata of a connection. SchemaMetadata is a singleton resource for each connection.", + // "flatPath": "v1/projects/{projectsId}/locations/{locationsId}/connections/{connectionsId}/connectionSchemaMetadata", + // "httpMethod": "GET", + // "id": "connectors.projects.locations.connections.getConnectionSchemaMetadata", + // "parameterOrder": [ + // "name" + // ], + // "parameters": { + // "name": { + // "description": "Required. Connection name Format: projects/{project}/locations/{location}/connections/{connection}/connectionSchemaMetadata", + // "location": "path", + // "pattern": "^projects/[^/]+/locations/[^/]+/connections/[^/]+/connectionSchemaMetadata$", + // "required": true, + // "type": "string" + // } + // }, + // "path": "v1/{+name}", + // "response": { + // "$ref": "ConnectionSchemaMetadata" + // }, + // "scopes": [ + // "https://www.googleapis.com/auth/cloud-platform" + // ] + // } + +} + +// method id "connectors.projects.locations.connections.getIamPolicy": + +type ProjectsLocationsConnectionsGetIamPolicyCall struct { + s *Service + resource string + urlParams_ gensupport.URLParams + ifNoneMatch_ string + ctx_ context.Context + header_ http.Header +} + +// GetIamPolicy: Gets the access control policy for a resource. Returns +// an empty policy if the resource exists and does not have a policy +// set. +// +// - resource: REQUIRED: The resource for which the policy is being +// requested. See Resource names +// (https://cloud.google.com/apis/design/resource_names) for the +// appropriate value for this field. +func (r *ProjectsLocationsConnectionsService) GetIamPolicy(resource string) *ProjectsLocationsConnectionsGetIamPolicyCall { + c := &ProjectsLocationsConnectionsGetIamPolicyCall{s: r.s, urlParams_: make(gensupport.URLParams)} + c.resource = resource + return c +} + +// OptionsRequestedPolicyVersion sets the optional parameter +// "options.requestedPolicyVersion": The maximum policy version that +// will be used to format the policy. Valid values are 0, 1, and 3. +// Requests specifying an invalid value will be rejected. Requests for +// policies with any conditional role bindings must specify version 3. +// Policies with no conditional role bindings may specify any valid +// value or leave the field unset. The policy in the response might use +// the policy version that you specified, or it might use a lower policy +// version. For example, if you specify version 3, but the policy has no +// conditional role bindings, the response uses version 1. To learn +// which resources support conditions in their IAM policies, see the IAM +// documentation +// (https://cloud.google.com/iam/help/conditions/resource-policies). +func (c *ProjectsLocationsConnectionsGetIamPolicyCall) OptionsRequestedPolicyVersion(optionsRequestedPolicyVersion int64) *ProjectsLocationsConnectionsGetIamPolicyCall { + c.urlParams_.Set("options.requestedPolicyVersion", fmt.Sprint(optionsRequestedPolicyVersion)) + 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 *ProjectsLocationsConnectionsGetIamPolicyCall) Fields(s ...googleapi.Field) *ProjectsLocationsConnectionsGetIamPolicyCall { + 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 *ProjectsLocationsConnectionsGetIamPolicyCall) IfNoneMatch(entityTag string) *ProjectsLocationsConnectionsGetIamPolicyCall { + 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 *ProjectsLocationsConnectionsGetIamPolicyCall) Context(ctx context.Context) *ProjectsLocationsConnectionsGetIamPolicyCall { + 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 *ProjectsLocationsConnectionsGetIamPolicyCall) Header() http.Header { + if c.header_ == nil { + c.header_ = make(http.Header) + } + return c.header_ +} + +func (c *ProjectsLocationsConnectionsGetIamPolicyCall) doRequest(alt string) (*http.Response, error) { + reqHeaders := make(http.Header) + reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version) + for k, v := range c.header_ { + reqHeaders[k] = v + } + reqHeaders.Set("User-Agent", c.s.userAgent()) + if c.ifNoneMatch_ != "" { + reqHeaders.Set("If-None-Match", c.ifNoneMatch_) + } + var body io.Reader = nil + c.urlParams_.Set("alt", alt) + c.urlParams_.Set("prettyPrint", "false") + urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+resource}:getIamPolicy") + 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{ + "resource": c.resource, + }) + return gensupport.SendRequest(c.ctx_, c.s.client, req) +} + +// Do executes the "connectors.projects.locations.connections.getIamPolicy" call. +// Exactly one of *Policy or error will be non-nil. Any non-2xx status +// code is an error. Response headers are in either +// *Policy.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 *ProjectsLocationsConnectionsGetIamPolicyCall) Do(opts ...googleapi.CallOption) (*Policy, 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 := &Policy{ + 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 access control policy for a resource. Returns an empty policy if the resource exists and does not have a policy set.", + // "flatPath": "v1/projects/{projectsId}/locations/{locationsId}/connections/{connectionsId}:getIamPolicy", + // "httpMethod": "GET", + // "id": "connectors.projects.locations.connections.getIamPolicy", + // "parameterOrder": [ + // "resource" + // ], + // "parameters": { + // "options.requestedPolicyVersion": { + // "description": "Optional. The maximum policy version that will be used to format the policy. Valid values are 0, 1, and 3. Requests specifying an invalid value will be rejected. Requests for policies with any conditional role bindings must specify version 3. Policies with no conditional role bindings may specify any valid value or leave the field unset. The policy in the response might use the policy version that you specified, or it might use a lower policy version. For example, if you specify version 3, but the policy has no conditional role bindings, the response uses version 1. To learn which resources support conditions in their IAM policies, see the [IAM documentation](https://cloud.google.com/iam/help/conditions/resource-policies).", + // "format": "int32", + // "location": "query", + // "type": "integer" + // }, + // "resource": { + // "description": "REQUIRED: The resource for which the policy is being requested. See [Resource names](https://cloud.google.com/apis/design/resource_names) for the appropriate value for this field.", + // "location": "path", + // "pattern": "^projects/[^/]+/locations/[^/]+/connections/[^/]+$", + // "required": true, + // "type": "string" + // } + // }, + // "path": "v1/{+resource}:getIamPolicy", + // "response": { + // "$ref": "Policy" + // }, + // "scopes": [ + // "https://www.googleapis.com/auth/cloud-platform" + // ] + // } + +} + +// method id "connectors.projects.locations.connections.list": + +type ProjectsLocationsConnectionsListCall struct { + s *Service + parent string + urlParams_ gensupport.URLParams + ifNoneMatch_ string + ctx_ context.Context + header_ http.Header +} + +// List: Lists Connections in a given project and location. +// +// - parent: Parent resource of the Connection, of the form: +// `projects/*/locations/*`. +func (r *ProjectsLocationsConnectionsService) List(parent string) *ProjectsLocationsConnectionsListCall { + c := &ProjectsLocationsConnectionsListCall{s: r.s, urlParams_: make(gensupport.URLParams)} + c.parent = parent + return c +} + +// Filter sets the optional parameter "filter": Filter. +func (c *ProjectsLocationsConnectionsListCall) Filter(filter string) *ProjectsLocationsConnectionsListCall { + c.urlParams_.Set("filter", filter) + return c +} + +// OrderBy sets the optional parameter "orderBy": Order by parameters. +func (c *ProjectsLocationsConnectionsListCall) OrderBy(orderBy string) *ProjectsLocationsConnectionsListCall { + c.urlParams_.Set("orderBy", orderBy) + return c +} + +// PageSize sets the optional parameter "pageSize": Page size. +func (c *ProjectsLocationsConnectionsListCall) PageSize(pageSize int64) *ProjectsLocationsConnectionsListCall { + c.urlParams_.Set("pageSize", fmt.Sprint(pageSize)) + return c +} + +// PageToken sets the optional parameter "pageToken": Page token. +func (c *ProjectsLocationsConnectionsListCall) PageToken(pageToken string) *ProjectsLocationsConnectionsListCall { + c.urlParams_.Set("pageToken", pageToken) + return c +} + +// View sets the optional parameter "view": Specifies which fields of +// the Connection are returned in the response. Defaults to `BASIC` +// view. +// +// Possible values: +// +// "CONNECTION_VIEW_UNSPECIFIED" - CONNECTION_UNSPECIFIED. +// "BASIC" - Do not include runtime required configs. +// "FULL" - Include runtime required configs. +func (c *ProjectsLocationsConnectionsListCall) View(view string) *ProjectsLocationsConnectionsListCall { + 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 *ProjectsLocationsConnectionsListCall) Fields(s ...googleapi.Field) *ProjectsLocationsConnectionsListCall { + 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 *ProjectsLocationsConnectionsListCall) IfNoneMatch(entityTag string) *ProjectsLocationsConnectionsListCall { + 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 *ProjectsLocationsConnectionsListCall) Context(ctx context.Context) *ProjectsLocationsConnectionsListCall { + 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 *ProjectsLocationsConnectionsListCall) Header() http.Header { + if c.header_ == nil { + c.header_ = make(http.Header) + } + return c.header_ +} + +func (c *ProjectsLocationsConnectionsListCall) doRequest(alt string) (*http.Response, error) { + reqHeaders := make(http.Header) + reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version) + for k, v := range c.header_ { + reqHeaders[k] = v + } + reqHeaders.Set("User-Agent", c.s.userAgent()) + if c.ifNoneMatch_ != "" { + reqHeaders.Set("If-None-Match", c.ifNoneMatch_) + } + var body io.Reader = nil + c.urlParams_.Set("alt", alt) + c.urlParams_.Set("prettyPrint", "false") + urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+parent}/connections") + 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 "connectors.projects.locations.connections.list" call. +// Exactly one of *ListConnectionsResponse or error will be non-nil. Any +// non-2xx status code is an error. Response headers are in either +// *ListConnectionsResponse.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 *ProjectsLocationsConnectionsListCall) Do(opts ...googleapi.CallOption) (*ListConnectionsResponse, 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 := &ListConnectionsResponse{ + 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 Connections in a given project and location.", + // "flatPath": "v1/projects/{projectsId}/locations/{locationsId}/connections", + // "httpMethod": "GET", + // "id": "connectors.projects.locations.connections.list", + // "parameterOrder": [ + // "parent" + // ], + // "parameters": { + // "filter": { + // "description": "Filter.", + // "location": "query", + // "type": "string" + // }, + // "orderBy": { + // "description": "Order by parameters.", + // "location": "query", + // "type": "string" + // }, + // "pageSize": { + // "description": "Page size.", + // "format": "int32", + // "location": "query", + // "type": "integer" + // }, + // "pageToken": { + // "description": "Page token.", + // "location": "query", + // "type": "string" + // }, + // "parent": { + // "description": "Required. Parent resource of the Connection, of the form: `projects/*/locations/*`", + // "location": "path", + // "pattern": "^projects/[^/]+/locations/[^/]+$", + // "required": true, + // "type": "string" + // }, + // "view": { + // "description": "Specifies which fields of the Connection are returned in the response. Defaults to `BASIC` view.", + // "enum": [ + // "CONNECTION_VIEW_UNSPECIFIED", + // "BASIC", + // "FULL" + // ], + // "enumDescriptions": [ + // "CONNECTION_UNSPECIFIED.", + // "Do not include runtime required configs.", + // "Include runtime required configs." + // ], + // "location": "query", + // "type": "string" + // } + // }, + // "path": "v1/{+parent}/connections", + // "response": { + // "$ref": "ListConnectionsResponse" + // }, + // "scopes": [ + // "https://www.googleapis.com/auth/cloud-platform" + // ] + // } + } -func (s *UserPassword) MarshalJSON() ([]byte, error) { - type NoMethod UserPassword - raw := NoMethod(*s) - return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +// 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 *ProjectsLocationsConnectionsListCall) Pages(ctx context.Context, f func(*ListConnectionsResponse) 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 "connectors.projects.locations.get": +// method id "connectors.projects.locations.connections.patch": -type ProjectsLocationsGetCall struct { - s *Service - name string - urlParams_ gensupport.URLParams - ifNoneMatch_ string - ctx_ context.Context - header_ http.Header +type ProjectsLocationsConnectionsPatchCall struct { + s *Service + name string + connection *Connection + urlParams_ gensupport.URLParams + ctx_ context.Context + header_ http.Header } -// Get: Gets information about a location. +// Patch: Updates the parameters of a single Connection. // -// - name: Resource name for the location. -func (r *ProjectsLocationsService) Get(name string) *ProjectsLocationsGetCall { - c := &ProjectsLocationsGetCall{s: r.s, urlParams_: make(gensupport.URLParams)} +// - name: Output only. Resource name of the Connection. Format: +// projects/{project}/locations/{location}/connections/{connection}. +func (r *ProjectsLocationsConnectionsService) Patch(name string, connection *Connection) *ProjectsLocationsConnectionsPatchCall { + c := &ProjectsLocationsConnectionsPatchCall{s: r.s, urlParams_: make(gensupport.URLParams)} c.name = name + c.connection = connection + return c +} + +// UpdateMask sets the optional parameter "updateMask": Required. You +// can modify only the fields listed below. To lock/unlock a connection: +// * `lock_config` To suspend/resume a connection: * `suspended` To +// update the connection details: * `description` * `labels` * +// `connector_version` * `config_variables` * `auth_config` * +// `destination_configs` * `node_config` +func (c *ProjectsLocationsConnectionsPatchCall) UpdateMask(updateMask string) *ProjectsLocationsConnectionsPatchCall { + 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 *ProjectsLocationsGetCall) Fields(s ...googleapi.Field) *ProjectsLocationsGetCall { +func (c *ProjectsLocationsConnectionsPatchCall) Fields(s ...googleapi.Field) *ProjectsLocationsConnectionsPatchCall { 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 { +func (c *ProjectsLocationsConnectionsPatchCall) Context(ctx context.Context) *ProjectsLocationsConnectionsPatchCall { 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 { +func (c *ProjectsLocationsConnectionsPatchCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) } return c.header_ } -func (c *ProjectsLocationsGetCall) doRequest(alt string) (*http.Response, error) { +func (c *ProjectsLocationsConnectionsPatchCall) 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.connection) + if err != nil { + return nil, err + } + reqHeaders.Set("Content-Type", "application/json") c.urlParams_.Set("alt", alt) c.urlParams_.Set("prettyPrint", "false") urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+name}") urls += "?" + c.urlParams_.Encode() - req, err := http.NewRequest("GET", urls, body) + req, err := http.NewRequest("PATCH", urls, body) if err != nil { return nil, err } @@ -3811,14 +6043,14 @@ func (c *ProjectsLocationsGetCall) doRequest(alt string) (*http.Response, error) return gensupport.SendRequest(c.ctx_, c.s.client, req) } -// Do executes the "connectors.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 +// Do executes the "connectors.projects.locations.connections.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 *ProjectsLocationsGetCall) Do(opts ...googleapi.CallOption) (*Location, error) { +func (c *ProjectsLocationsConnectionsPatchCall) Do(opts ...googleapi.CallOption) (*Operation, error) { gensupport.SetOptions(c.urlParams_, opts...) res, err := c.doRequest("json") if res != nil && res.StatusCode == http.StatusNotModified { @@ -3837,7 +6069,7 @@ func (c *ProjectsLocationsGetCall) Do(opts ...googleapi.CallOption) (*Location, if err := googleapi.CheckResponse(res); err != nil { return nil, gensupport.WrapError(err) } - ret := &Location{ + ret := &Operation{ ServerResponse: googleapi.ServerResponse{ Header: res.Header, HTTPStatusCode: res.StatusCode, @@ -3849,25 +6081,34 @@ func (c *ProjectsLocationsGetCall) Do(opts ...googleapi.CallOption) (*Location, } return ret, nil // { - // "description": "Gets information about a location.", - // "flatPath": "v1/projects/{projectsId}/locations/{locationsId}", - // "httpMethod": "GET", - // "id": "connectors.projects.locations.get", + // "description": "Updates the parameters of a single Connection.", + // "flatPath": "v1/projects/{projectsId}/locations/{locationsId}/connections/{connectionsId}", + // "httpMethod": "PATCH", + // "id": "connectors.projects.locations.connections.patch", // "parameterOrder": [ // "name" // ], // "parameters": { // "name": { - // "description": "Resource name for the location.", + // "description": "Output only. Resource name of the Connection. Format: projects/{project}/locations/{location}/connections/{connection}", // "location": "path", - // "pattern": "^projects/[^/]+/locations/[^/]+$", + // "pattern": "^projects/[^/]+/locations/[^/]+/connections/[^/]+$", // "required": true, // "type": "string" + // }, + // "updateMask": { + // "description": "Required. You can modify only the fields listed below. To lock/unlock a connection: * `lock_config` To suspend/resume a connection: * `suspended` To update the connection details: * `description` * `labels` * `connector_version` * `config_variables` * `auth_config` * `destination_configs` * `node_config`", + // "format": "google-fieldmask", + // "location": "query", + // "type": "string" // } // }, // "path": "v1/{+name}", + // "request": { + // "$ref": "Connection" + // }, // "response": { - // "$ref": "Location" + // "$ref": "Operation" // }, // "scopes": [ // "https://www.googleapis.com/auth/cloud-platform" @@ -3876,79 +6117,72 @@ func (c *ProjectsLocationsGetCall) Do(opts ...googleapi.CallOption) (*Location, } -// method id "connectors.projects.locations.getRuntimeConfig": +// method id "connectors.projects.locations.connections.repairEventing": -type ProjectsLocationsGetRuntimeConfigCall struct { - s *Service - name string - urlParams_ gensupport.URLParams - ifNoneMatch_ string - ctx_ context.Context - header_ http.Header +type ProjectsLocationsConnectionsRepairEventingCall struct { + s *Service + name string + repaireventingrequest *RepairEventingRequest + urlParams_ gensupport.URLParams + ctx_ context.Context + header_ http.Header } -// GetRuntimeConfig: Gets the runtimeConfig of a location. RuntimeConfig -// is a singleton resource for each location. +// RepairEventing: RepaiEventing tries to repair eventing related event +// subscriptions. // // - name: Resource name of the form: -// `projects/*/locations/*/runtimeConfig`. -func (r *ProjectsLocationsService) GetRuntimeConfig(name string) *ProjectsLocationsGetRuntimeConfigCall { - c := &ProjectsLocationsGetRuntimeConfigCall{s: r.s, urlParams_: make(gensupport.URLParams)} +// `projects/*/locations/*/connections/*`. +func (r *ProjectsLocationsConnectionsService) RepairEventing(name string, repaireventingrequest *RepairEventingRequest) *ProjectsLocationsConnectionsRepairEventingCall { + c := &ProjectsLocationsConnectionsRepairEventingCall{s: r.s, urlParams_: make(gensupport.URLParams)} c.name = name + c.repaireventingrequest = repaireventingrequest 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 *ProjectsLocationsGetRuntimeConfigCall) Fields(s ...googleapi.Field) *ProjectsLocationsGetRuntimeConfigCall { +func (c *ProjectsLocationsConnectionsRepairEventingCall) Fields(s ...googleapi.Field) *ProjectsLocationsConnectionsRepairEventingCall { 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 *ProjectsLocationsGetRuntimeConfigCall) IfNoneMatch(entityTag string) *ProjectsLocationsGetRuntimeConfigCall { - 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 *ProjectsLocationsGetRuntimeConfigCall) Context(ctx context.Context) *ProjectsLocationsGetRuntimeConfigCall { +func (c *ProjectsLocationsConnectionsRepairEventingCall) Context(ctx context.Context) *ProjectsLocationsConnectionsRepairEventingCall { 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 *ProjectsLocationsGetRuntimeConfigCall) Header() http.Header { +func (c *ProjectsLocationsConnectionsRepairEventingCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) } return c.header_ } -func (c *ProjectsLocationsGetRuntimeConfigCall) doRequest(alt string) (*http.Response, error) { +func (c *ProjectsLocationsConnectionsRepairEventingCall) 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.repaireventingrequest) + if err != nil { + return nil, err + } + reqHeaders.Set("Content-Type", "application/json") c.urlParams_.Set("alt", alt) c.urlParams_.Set("prettyPrint", "false") - urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+name}") + urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+name}:repairEventing") urls += "?" + c.urlParams_.Encode() - req, err := http.NewRequest("GET", urls, body) + req, err := http.NewRequest("POST", urls, body) if err != nil { return nil, err } @@ -3959,14 +6193,14 @@ func (c *ProjectsLocationsGetRuntimeConfigCall) doRequest(alt string) (*http.Res return gensupport.SendRequest(c.ctx_, c.s.client, req) } -// Do executes the "connectors.projects.locations.getRuntimeConfig" call. -// Exactly one of *RuntimeConfig or error will be non-nil. Any non-2xx +// Do executes the "connectors.projects.locations.connections.repairEventing" call. +// Exactly one of *Operation or error will be non-nil. Any non-2xx // status code is an error. Response headers are in either -// *RuntimeConfig.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 *ProjectsLocationsGetRuntimeConfigCall) Do(opts ...googleapi.CallOption) (*RuntimeConfig, error) { +// *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 *ProjectsLocationsConnectionsRepairEventingCall) Do(opts ...googleapi.CallOption) (*Operation, error) { gensupport.SetOptions(c.urlParams_, opts...) res, err := c.doRequest("json") if res != nil && res.StatusCode == http.StatusNotModified { @@ -3985,7 +6219,7 @@ func (c *ProjectsLocationsGetRuntimeConfigCall) Do(opts ...googleapi.CallOption) if err := googleapi.CheckResponse(res); err != nil { return nil, gensupport.WrapError(err) } - ret := &RuntimeConfig{ + ret := &Operation{ ServerResponse: googleapi.ServerResponse{ Header: res.Header, HTTPStatusCode: res.StatusCode, @@ -3997,25 +6231,28 @@ func (c *ProjectsLocationsGetRuntimeConfigCall) Do(opts ...googleapi.CallOption) } return ret, nil // { - // "description": "Gets the runtimeConfig of a location. RuntimeConfig is a singleton resource for each location.", - // "flatPath": "v1/projects/{projectsId}/locations/{locationsId}/runtimeConfig", - // "httpMethod": "GET", - // "id": "connectors.projects.locations.getRuntimeConfig", + // "description": "RepaiEventing tries to repair eventing related event subscriptions.", + // "flatPath": "v1/projects/{projectsId}/locations/{locationsId}/connections/{connectionsId}:repairEventing", + // "httpMethod": "POST", + // "id": "connectors.projects.locations.connections.repairEventing", // "parameterOrder": [ // "name" // ], // "parameters": { // "name": { - // "description": "Required. Resource name of the form: `projects/*/locations/*/runtimeConfig`", + // "description": "Required. Resource name of the form: `projects/*/locations/*/connections/*`", // "location": "path", - // "pattern": "^projects/[^/]+/locations/[^/]+/runtimeConfig$", + // "pattern": "^projects/[^/]+/locations/[^/]+/connections/[^/]+$", // "required": true, // "type": "string" // } // }, - // "path": "v1/{+name}", + // "path": "v1/{+name}:repairEventing", + // "request": { + // "$ref": "RepairEventingRequest" + // }, // "response": { - // "$ref": "RuntimeConfig" + // "$ref": "Operation" // }, // "scopes": [ // "https://www.googleapis.com/auth/cloud-platform" @@ -4024,121 +6261,93 @@ func (c *ProjectsLocationsGetRuntimeConfigCall) Do(opts ...googleapi.CallOption) } -// method id "connectors.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 -} +// method id "connectors.projects.locations.connections.setIamPolicy": -// 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 +type ProjectsLocationsConnectionsSetIamPolicyCall struct { + s *Service + resource string + setiampolicyrequest *SetIamPolicyRequest + urlParams_ gensupport.URLParams + ctx_ context.Context + header_ http.Header } -// 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) +// SetIamPolicy: Sets the access control policy on the specified +// resource. Replaces any existing policy. Can return `NOT_FOUND`, +// `INVALID_ARGUMENT`, and `PERMISSION_DENIED` errors. +// +// - resource: REQUIRED: The resource for which the policy is being +// specified. See Resource names +// (https://cloud.google.com/apis/design/resource_names) for the +// appropriate value for this field. +func (r *ProjectsLocationsConnectionsService) SetIamPolicy(resource string, setiampolicyrequest *SetIamPolicyRequest) *ProjectsLocationsConnectionsSetIamPolicyCall { + c := &ProjectsLocationsConnectionsSetIamPolicyCall{s: r.s, urlParams_: make(gensupport.URLParams)} + c.resource = resource + c.setiampolicyrequest = setiampolicyrequest 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 { +func (c *ProjectsLocationsConnectionsSetIamPolicyCall) Fields(s ...googleapi.Field) *ProjectsLocationsConnectionsSetIamPolicyCall { 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 { +func (c *ProjectsLocationsConnectionsSetIamPolicyCall) Context(ctx context.Context) *ProjectsLocationsConnectionsSetIamPolicyCall { 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 { +func (c *ProjectsLocationsConnectionsSetIamPolicyCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) } return c.header_ } -func (c *ProjectsLocationsListCall) doRequest(alt string) (*http.Response, error) { +func (c *ProjectsLocationsConnectionsSetIamPolicyCall) 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.setiampolicyrequest) + if err != nil { + return nil, err + } + reqHeaders.Set("Content-Type", "application/json") c.urlParams_.Set("alt", alt) c.urlParams_.Set("prettyPrint", "false") - urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+name}/locations") + urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+resource}:setIamPolicy") urls += "?" + c.urlParams_.Encode() - req, err := http.NewRequest("GET", urls, body) + 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, + "resource": c.resource, }) return gensupport.SendRequest(c.ctx_, c.s.client, req) } -// Do executes the "connectors.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) { +// Do executes the "connectors.projects.locations.connections.setIamPolicy" call. +// Exactly one of *Policy or error will be non-nil. Any non-2xx status +// code is an error. Response headers are in either +// *Policy.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 *ProjectsLocationsConnectionsSetIamPolicyCall) Do(opts ...googleapi.CallOption) (*Policy, error) { gensupport.SetOptions(c.urlParams_, opts...) res, err := c.doRequest("json") if res != nil && res.StatusCode == http.StatusNotModified { @@ -4157,7 +6366,7 @@ func (c *ProjectsLocationsListCall) Do(opts ...googleapi.CallOption) (*ListLocat if err := googleapi.CheckResponse(res); err != nil { return nil, gensupport.WrapError(err) } - ret := &ListLocationsResponse{ + ret := &Policy{ ServerResponse: googleapi.ServerResponse{ Header: res.Header, HTTPStatusCode: res.StatusCode, @@ -4169,41 +6378,28 @@ func (c *ProjectsLocationsListCall) Do(opts ...googleapi.CallOption) (*ListLocat } return ret, nil // { - // "description": "Lists information about the supported locations for this service.", - // "flatPath": "v1/projects/{projectsId}/locations", - // "httpMethod": "GET", - // "id": "connectors.projects.locations.list", + // "description": "Sets the access control policy on the specified resource. Replaces any existing policy. Can return `NOT_FOUND`, `INVALID_ARGUMENT`, and `PERMISSION_DENIED` errors.", + // "flatPath": "v1/projects/{projectsId}/locations/{locationsId}/connections/{connectionsId}:setIamPolicy", + // "httpMethod": "POST", + // "id": "connectors.projects.locations.connections.setIamPolicy", // "parameterOrder": [ - // "name" + // "resource" // ], // "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.", + // "resource": { + // "description": "REQUIRED: The resource for which the policy is being specified. See [Resource names](https://cloud.google.com/apis/design/resource_names) for the appropriate value for this field.", // "location": "path", - // "pattern": "^projects/[^/]+$", + // "pattern": "^projects/[^/]+/locations/[^/]+/connections/[^/]+$", // "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": "v1/{+name}/locations", + // "path": "v1/{+resource}:setIamPolicy", + // "request": { + // "$ref": "SetIamPolicyRequest" + // }, // "response": { - // "$ref": "ListLocationsResponse" + // "$ref": "Policy" // }, // "scopes": [ // "https://www.googleapis.com/auth/cloud-platform" @@ -4212,61 +6408,39 @@ func (c *ProjectsLocationsListCall) Do(opts ...googleapi.CallOption) (*ListLocat } -// 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 "connectors.projects.locations.connections.create": +// method id "connectors.projects.locations.connections.testIamPermissions": -type ProjectsLocationsConnectionsCreateCall struct { - s *Service - parent string - connection *Connection - urlParams_ gensupport.URLParams - ctx_ context.Context - header_ http.Header +type ProjectsLocationsConnectionsTestIamPermissionsCall struct { + s *Service + resource string + testiampermissionsrequest *TestIamPermissionsRequest + urlParams_ gensupport.URLParams + ctx_ context.Context + header_ http.Header } -// Create: Creates a new Connection in a given project and location. +// TestIamPermissions: Returns permissions that a caller has on the +// specified resource. If the resource does not exist, this will return +// an empty set of permissions, not a `NOT_FOUND` error. Note: This +// operation is designed to be used for building permission-aware UIs +// and command-line tools, not for authorization checking. This +// operation may "fail open" without warning. // -// - parent: Parent resource of the Connection, of the form: -// `projects/*/locations/*`. -func (r *ProjectsLocationsConnectionsService) Create(parent string, connection *Connection) *ProjectsLocationsConnectionsCreateCall { - c := &ProjectsLocationsConnectionsCreateCall{s: r.s, urlParams_: make(gensupport.URLParams)} - c.parent = parent - c.connection = connection - return c -} - -// ConnectionId sets the optional parameter "connectionId": Required. -// Identifier to assign to the Connection. Must be unique within scope -// of the parent resource. -func (c *ProjectsLocationsConnectionsCreateCall) ConnectionId(connectionId string) *ProjectsLocationsConnectionsCreateCall { - c.urlParams_.Set("connectionId", connectionId) +// - resource: REQUIRED: The resource for which the policy detail is +// being requested. See Resource names +// (https://cloud.google.com/apis/design/resource_names) for the +// appropriate value for this field. +func (r *ProjectsLocationsConnectionsService) TestIamPermissions(resource string, testiampermissionsrequest *TestIamPermissionsRequest) *ProjectsLocationsConnectionsTestIamPermissionsCall { + c := &ProjectsLocationsConnectionsTestIamPermissionsCall{s: r.s, urlParams_: make(gensupport.URLParams)} + c.resource = resource + c.testiampermissionsrequest = testiampermissionsrequest 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 *ProjectsLocationsConnectionsCreateCall) Fields(s ...googleapi.Field) *ProjectsLocationsConnectionsCreateCall { +func (c *ProjectsLocationsConnectionsTestIamPermissionsCall) Fields(s ...googleapi.Field) *ProjectsLocationsConnectionsTestIamPermissionsCall { c.urlParams_.Set("fields", googleapi.CombineFields(s)) return c } @@ -4274,21 +6448,21 @@ func (c *ProjectsLocationsConnectionsCreateCall) Fields(s ...googleapi.Field) *P // 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 *ProjectsLocationsConnectionsCreateCall) Context(ctx context.Context) *ProjectsLocationsConnectionsCreateCall { +func (c *ProjectsLocationsConnectionsTestIamPermissionsCall) Context(ctx context.Context) *ProjectsLocationsConnectionsTestIamPermissionsCall { 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 *ProjectsLocationsConnectionsCreateCall) Header() http.Header { +func (c *ProjectsLocationsConnectionsTestIamPermissionsCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) } return c.header_ } -func (c *ProjectsLocationsConnectionsCreateCall) doRequest(alt string) (*http.Response, error) { +func (c *ProjectsLocationsConnectionsTestIamPermissionsCall) 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_ { @@ -4296,14 +6470,14 @@ func (c *ProjectsLocationsConnectionsCreateCall) doRequest(alt string) (*http.Re } reqHeaders.Set("User-Agent", c.s.userAgent()) var body io.Reader = nil - body, err := googleapi.WithoutDataWrapper.JSONReader(c.connection) + body, err := googleapi.WithoutDataWrapper.JSONReader(c.testiampermissionsrequest) 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}/connections") + urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+resource}:testIamPermissions") urls += "?" + c.urlParams_.Encode() req, err := http.NewRequest("POST", urls, body) if err != nil { @@ -4311,19 +6485,19 @@ func (c *ProjectsLocationsConnectionsCreateCall) doRequest(alt string) (*http.Re } req.Header = reqHeaders googleapi.Expand(req.URL, map[string]string{ - "parent": c.parent, + "resource": c.resource, }) return gensupport.SendRequest(c.ctx_, c.s.client, req) } -// Do executes the "connectors.projects.locations.connections.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 *ProjectsLocationsConnectionsCreateCall) Do(opts ...googleapi.CallOption) (*Operation, error) { +// Do executes the "connectors.projects.locations.connections.testIamPermissions" call. +// Exactly one of *TestIamPermissionsResponse or error will be non-nil. +// Any non-2xx status code is an error. Response headers are in either +// *TestIamPermissionsResponse.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 *ProjectsLocationsConnectionsTestIamPermissionsCall) Do(opts ...googleapi.CallOption) (*TestIamPermissionsResponse, error) { gensupport.SetOptions(c.urlParams_, opts...) res, err := c.doRequest("json") if res != nil && res.StatusCode == http.StatusNotModified { @@ -4342,7 +6516,7 @@ func (c *ProjectsLocationsConnectionsCreateCall) Do(opts ...googleapi.CallOption if err := googleapi.CheckResponse(res); err != nil { return nil, gensupport.WrapError(err) } - ret := &Operation{ + ret := &TestIamPermissionsResponse{ ServerResponse: googleapi.ServerResponse{ Header: res.Header, HTTPStatusCode: res.StatusCode, @@ -4354,33 +6528,28 @@ func (c *ProjectsLocationsConnectionsCreateCall) Do(opts ...googleapi.CallOption } return ret, nil // { - // "description": "Creates a new Connection in a given project and location.", - // "flatPath": "v1/projects/{projectsId}/locations/{locationsId}/connections", + // "description": "Returns permissions that a caller has on the specified resource. If the resource does not exist, this will return an empty set of permissions, not a `NOT_FOUND` error. Note: This operation is designed to be used for building permission-aware UIs and command-line tools, not for authorization checking. This operation may \"fail open\" without warning.", + // "flatPath": "v1/projects/{projectsId}/locations/{locationsId}/connections/{connectionsId}:testIamPermissions", // "httpMethod": "POST", - // "id": "connectors.projects.locations.connections.create", + // "id": "connectors.projects.locations.connections.testIamPermissions", // "parameterOrder": [ - // "parent" + // "resource" // ], // "parameters": { - // "connectionId": { - // "description": "Required. Identifier to assign to the Connection. Must be unique within scope of the parent resource.", - // "location": "query", - // "type": "string" - // }, - // "parent": { - // "description": "Required. Parent resource of the Connection, of the form: `projects/*/locations/*`", + // "resource": { + // "description": "REQUIRED: The resource for which the policy detail is being requested. See [Resource names](https://cloud.google.com/apis/design/resource_names) for the appropriate value for this field.", // "location": "path", - // "pattern": "^projects/[^/]+/locations/[^/]+$", + // "pattern": "^projects/[^/]+/locations/[^/]+/connections/[^/]+$", // "required": true, // "type": "string" // } // }, - // "path": "v1/{+parent}/connections", + // "path": "v1/{+resource}:testIamPermissions", // "request": { - // "$ref": "Connection" + // "$ref": "TestIamPermissionsRequest" // }, // "response": { - // "$ref": "Operation" + // "$ref": "TestIamPermissionsResponse" // }, // "scopes": [ // "https://www.googleapis.com/auth/cloud-platform" @@ -4389,30 +6558,33 @@ func (c *ProjectsLocationsConnectionsCreateCall) Do(opts ...googleapi.CallOption } -// method id "connectors.projects.locations.connections.delete": +// method id "connectors.projects.locations.connections.connectionSchemaMetadata.refresh": -type ProjectsLocationsConnectionsDeleteCall struct { - s *Service - name string - urlParams_ gensupport.URLParams - ctx_ context.Context - header_ http.Header +type ProjectsLocationsConnectionsConnectionSchemaMetadataRefreshCall struct { + s *Service + name string + refreshconnectionschemametadatarequest *RefreshConnectionSchemaMetadataRequest + urlParams_ gensupport.URLParams + ctx_ context.Context + header_ http.Header } -// Delete: Deletes a single Connection. +// Refresh: Refresh runtime schema of a connection. // -// - name: Resource name of the form: -// `projects/*/locations/*/connections/*`. -func (r *ProjectsLocationsConnectionsService) Delete(name string) *ProjectsLocationsConnectionsDeleteCall { - c := &ProjectsLocationsConnectionsDeleteCall{s: r.s, urlParams_: make(gensupport.URLParams)} +// - name: Resource name. Format: +// projects/{project}/locations/{location}/connections/{connection}/con +// nectionSchemaMetadata. +func (r *ProjectsLocationsConnectionsConnectionSchemaMetadataService) Refresh(name string, refreshconnectionschemametadatarequest *RefreshConnectionSchemaMetadataRequest) *ProjectsLocationsConnectionsConnectionSchemaMetadataRefreshCall { + c := &ProjectsLocationsConnectionsConnectionSchemaMetadataRefreshCall{s: r.s, urlParams_: make(gensupport.URLParams)} c.name = name + c.refreshconnectionschemametadatarequest = refreshconnectionschemametadatarequest 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 *ProjectsLocationsConnectionsDeleteCall) Fields(s ...googleapi.Field) *ProjectsLocationsConnectionsDeleteCall { +func (c *ProjectsLocationsConnectionsConnectionSchemaMetadataRefreshCall) Fields(s ...googleapi.Field) *ProjectsLocationsConnectionsConnectionSchemaMetadataRefreshCall { c.urlParams_.Set("fields", googleapi.CombineFields(s)) return c } @@ -4420,21 +6592,21 @@ func (c *ProjectsLocationsConnectionsDeleteCall) Fields(s ...googleapi.Field) *P // 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 *ProjectsLocationsConnectionsDeleteCall) Context(ctx context.Context) *ProjectsLocationsConnectionsDeleteCall { +func (c *ProjectsLocationsConnectionsConnectionSchemaMetadataRefreshCall) Context(ctx context.Context) *ProjectsLocationsConnectionsConnectionSchemaMetadataRefreshCall { 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 *ProjectsLocationsConnectionsDeleteCall) Header() http.Header { +func (c *ProjectsLocationsConnectionsConnectionSchemaMetadataRefreshCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) } return c.header_ } -func (c *ProjectsLocationsConnectionsDeleteCall) doRequest(alt string) (*http.Response, error) { +func (c *ProjectsLocationsConnectionsConnectionSchemaMetadataRefreshCall) 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_ { @@ -4442,11 +6614,16 @@ func (c *ProjectsLocationsConnectionsDeleteCall) doRequest(alt string) (*http.Re } reqHeaders.Set("User-Agent", c.s.userAgent()) var body io.Reader = nil + body, err := googleapi.WithoutDataWrapper.JSONReader(c.refreshconnectionschemametadatarequest) + if err != nil { + return nil, err + } + reqHeaders.Set("Content-Type", "application/json") c.urlParams_.Set("alt", alt) c.urlParams_.Set("prettyPrint", "false") - urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+name}") + urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+name}:refresh") urls += "?" + c.urlParams_.Encode() - req, err := http.NewRequest("DELETE", urls, body) + req, err := http.NewRequest("POST", urls, body) if err != nil { return nil, err } @@ -4457,14 +6634,14 @@ func (c *ProjectsLocationsConnectionsDeleteCall) doRequest(alt string) (*http.Re return gensupport.SendRequest(c.ctx_, c.s.client, req) } -// Do executes the "connectors.projects.locations.connections.delete" call. +// Do executes the "connectors.projects.locations.connections.connectionSchemaMetadata.refresh" 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 *ProjectsLocationsConnectionsDeleteCall) Do(opts ...googleapi.CallOption) (*Operation, error) { +func (c *ProjectsLocationsConnectionsConnectionSchemaMetadataRefreshCall) Do(opts ...googleapi.CallOption) (*Operation, error) { gensupport.SetOptions(c.urlParams_, opts...) res, err := c.doRequest("json") if res != nil && res.StatusCode == http.StatusNotModified { @@ -4495,23 +6672,26 @@ func (c *ProjectsLocationsConnectionsDeleteCall) Do(opts ...googleapi.CallOption } return ret, nil // { - // "description": "Deletes a single Connection.", - // "flatPath": "v1/projects/{projectsId}/locations/{locationsId}/connections/{connectionsId}", - // "httpMethod": "DELETE", - // "id": "connectors.projects.locations.connections.delete", + // "description": "Refresh runtime schema of a connection.", + // "flatPath": "v1/projects/{projectsId}/locations/{locationsId}/connections/{connectionsId}/connectionSchemaMetadata:refresh", + // "httpMethod": "POST", + // "id": "connectors.projects.locations.connections.connectionSchemaMetadata.refresh", // "parameterOrder": [ // "name" // ], // "parameters": { // "name": { - // "description": "Required. Resource name of the form: `projects/*/locations/*/connections/*`", + // "description": "Required. Resource name. Format: projects/{project}/locations/{location}/connections/{connection}/connectionSchemaMetadata", // "location": "path", - // "pattern": "^projects/[^/]+/locations/[^/]+/connections/[^/]+$", + // "pattern": "^projects/[^/]+/locations/[^/]+/connections/[^/]+/connectionSchemaMetadata$", // "required": true, // "type": "string" // } // }, - // "path": "v1/{+name}", + // "path": "v1/{+name}:refresh", + // "request": { + // "$ref": "RefreshConnectionSchemaMetadataRequest" + // }, // "response": { // "$ref": "Operation" // }, @@ -4522,110 +6702,98 @@ func (c *ProjectsLocationsConnectionsDeleteCall) Do(opts ...googleapi.CallOption } -// method id "connectors.projects.locations.connections.get": +// method id "connectors.projects.locations.connections.eventSubscriptions.create": -type ProjectsLocationsConnectionsGetCall struct { - s *Service - name string - urlParams_ gensupport.URLParams - ifNoneMatch_ string - ctx_ context.Context - header_ http.Header +type ProjectsLocationsConnectionsEventSubscriptionsCreateCall struct { + s *Service + parent string + eventsubscription *EventSubscription + urlParams_ gensupport.URLParams + ctx_ context.Context + header_ http.Header } -// Get: Gets details of a single Connection. +// Create: Creates a new EventSubscription in a given project,location +// and connection. // -// - name: Resource name of the form: +// - parent: Parent resource of the EventSubscription, of the form: // `projects/*/locations/*/connections/*`. -func (r *ProjectsLocationsConnectionsService) Get(name string) *ProjectsLocationsConnectionsGetCall { - c := &ProjectsLocationsConnectionsGetCall{s: r.s, urlParams_: make(gensupport.URLParams)} - c.name = name +func (r *ProjectsLocationsConnectionsEventSubscriptionsService) Create(parent string, eventsubscription *EventSubscription) *ProjectsLocationsConnectionsEventSubscriptionsCreateCall { + c := &ProjectsLocationsConnectionsEventSubscriptionsCreateCall{s: r.s, urlParams_: make(gensupport.URLParams)} + c.parent = parent + c.eventsubscription = eventsubscription return c } -// View sets the optional parameter "view": Specifies which fields of -// the Connection are returned in the response. Defaults to `BASIC` -// view. -// -// Possible values: -// -// "CONNECTION_VIEW_UNSPECIFIED" - CONNECTION_UNSPECIFIED. -// "BASIC" - Do not include runtime required configs. -// "FULL" - Include runtime required configs. -func (c *ProjectsLocationsConnectionsGetCall) View(view string) *ProjectsLocationsConnectionsGetCall { - c.urlParams_.Set("view", view) +// EventSubscriptionId sets the optional parameter +// "eventSubscriptionId": Required. Identifier to assign to the Event +// Subscription. Must be unique within scope of the parent resource. +func (c *ProjectsLocationsConnectionsEventSubscriptionsCreateCall) EventSubscriptionId(eventSubscriptionId string) *ProjectsLocationsConnectionsEventSubscriptionsCreateCall { + c.urlParams_.Set("eventSubscriptionId", eventSubscriptionId) 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 *ProjectsLocationsConnectionsGetCall) Fields(s ...googleapi.Field) *ProjectsLocationsConnectionsGetCall { +func (c *ProjectsLocationsConnectionsEventSubscriptionsCreateCall) Fields(s ...googleapi.Field) *ProjectsLocationsConnectionsEventSubscriptionsCreateCall { 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 *ProjectsLocationsConnectionsGetCall) IfNoneMatch(entityTag string) *ProjectsLocationsConnectionsGetCall { - 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 *ProjectsLocationsConnectionsGetCall) Context(ctx context.Context) *ProjectsLocationsConnectionsGetCall { +func (c *ProjectsLocationsConnectionsEventSubscriptionsCreateCall) Context(ctx context.Context) *ProjectsLocationsConnectionsEventSubscriptionsCreateCall { 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 *ProjectsLocationsConnectionsGetCall) Header() http.Header { +func (c *ProjectsLocationsConnectionsEventSubscriptionsCreateCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) } return c.header_ } -func (c *ProjectsLocationsConnectionsGetCall) doRequest(alt string) (*http.Response, error) { +func (c *ProjectsLocationsConnectionsEventSubscriptionsCreateCall) 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.eventsubscription) + if err != nil { + return nil, err + } + reqHeaders.Set("Content-Type", "application/json") c.urlParams_.Set("alt", alt) c.urlParams_.Set("prettyPrint", "false") - urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+name}") + urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+parent}/eventSubscriptions") urls += "?" + c.urlParams_.Encode() - req, err := http.NewRequest("GET", urls, body) + 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, + "parent": c.parent, }) return gensupport.SendRequest(c.ctx_, c.s.client, req) } -// Do executes the "connectors.projects.locations.connections.get" call. -// Exactly one of *Connection or error will be non-nil. Any non-2xx +// Do executes the "connectors.projects.locations.connections.eventSubscriptions.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 -// *Connection.ServerResponse.Header or (if a response was returned at +// *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 *ProjectsLocationsConnectionsGetCall) Do(opts ...googleapi.CallOption) (*Connection, error) { +func (c *ProjectsLocationsConnectionsEventSubscriptionsCreateCall) Do(opts ...googleapi.CallOption) (*Operation, error) { gensupport.SetOptions(c.urlParams_, opts...) res, err := c.doRequest("json") if res != nil && res.StatusCode == http.StatusNotModified { @@ -4644,7 +6812,7 @@ func (c *ProjectsLocationsConnectionsGetCall) Do(opts ...googleapi.CallOption) ( if err := googleapi.CheckResponse(res); err != nil { return nil, gensupport.WrapError(err) } - ret := &Connection{ + ret := &Operation{ ServerResponse: googleapi.ServerResponse{ Header: res.Header, HTTPStatusCode: res.StatusCode, @@ -4656,40 +6824,33 @@ func (c *ProjectsLocationsConnectionsGetCall) Do(opts ...googleapi.CallOption) ( } return ret, nil // { - // "description": "Gets details of a single Connection.", - // "flatPath": "v1/projects/{projectsId}/locations/{locationsId}/connections/{connectionsId}", - // "httpMethod": "GET", - // "id": "connectors.projects.locations.connections.get", + // "description": "Creates a new EventSubscription in a given project,location and connection.", + // "flatPath": "v1/projects/{projectsId}/locations/{locationsId}/connections/{connectionsId}/eventSubscriptions", + // "httpMethod": "POST", + // "id": "connectors.projects.locations.connections.eventSubscriptions.create", // "parameterOrder": [ - // "name" + // "parent" // ], // "parameters": { - // "name": { - // "description": "Required. Resource name of the form: `projects/*/locations/*/connections/*`", + // "eventSubscriptionId": { + // "description": "Required. Identifier to assign to the Event Subscription. Must be unique within scope of the parent resource.", + // "location": "query", + // "type": "string" + // }, + // "parent": { + // "description": "Required. Parent resource of the EventSubscription, of the form: `projects/*/locations/*/connections/*`", // "location": "path", // "pattern": "^projects/[^/]+/locations/[^/]+/connections/[^/]+$", // "required": true, // "type": "string" - // }, - // "view": { - // "description": "Specifies which fields of the Connection are returned in the response. Defaults to `BASIC` view.", - // "enum": [ - // "CONNECTION_VIEW_UNSPECIFIED", - // "BASIC", - // "FULL" - // ], - // "enumDescriptions": [ - // "CONNECTION_UNSPECIFIED.", - // "Do not include runtime required configs.", - // "Include runtime required configs." - // ], - // "location": "query", - // "type": "string" // } // }, - // "path": "v1/{+name}", + // "path": "v1/{+parent}/eventSubscriptions", + // "request": { + // "$ref": "EventSubscription" + // }, // "response": { - // "$ref": "Connection" + // "$ref": "Operation" // }, // "scopes": [ // "https://www.googleapis.com/auth/cloud-platform" @@ -4698,25 +6859,22 @@ func (c *ProjectsLocationsConnectionsGetCall) Do(opts ...googleapi.CallOption) ( } -// method id "connectors.projects.locations.connections.getConnectionSchemaMetadata": +// method id "connectors.projects.locations.connections.eventSubscriptions.delete": -type ProjectsLocationsConnectionsGetConnectionSchemaMetadataCall struct { - s *Service - name string - urlParams_ gensupport.URLParams - ifNoneMatch_ string - ctx_ context.Context - header_ http.Header +type ProjectsLocationsConnectionsEventSubscriptionsDeleteCall struct { + s *Service + name string + urlParams_ gensupport.URLParams + ctx_ context.Context + header_ http.Header } -// GetConnectionSchemaMetadata: Gets schema metadata of a connection. -// SchemaMetadata is a singleton resource for each connection. +// Delete: Deletes a single EventSubscription. // -// - name: Connection name Format: -// projects/{project}/locations/{location}/connections/{connection}/con -// nectionSchemaMetadata. -func (r *ProjectsLocationsConnectionsService) GetConnectionSchemaMetadata(name string) *ProjectsLocationsConnectionsGetConnectionSchemaMetadataCall { - c := &ProjectsLocationsConnectionsGetConnectionSchemaMetadataCall{s: r.s, urlParams_: make(gensupport.URLParams)} +// - name: Resource name of the form: +// `projects/*/locations/*/connections/*/eventsubscriptions/*`. +func (r *ProjectsLocationsConnectionsEventSubscriptionsService) Delete(name string) *ProjectsLocationsConnectionsEventSubscriptionsDeleteCall { + c := &ProjectsLocationsConnectionsEventSubscriptionsDeleteCall{s: r.s, urlParams_: make(gensupport.URLParams)} c.name = name return c } @@ -4724,54 +6882,41 @@ func (r *ProjectsLocationsConnectionsService) GetConnectionSchemaMetadata(name s // Fields allows partial responses to be retrieved. See // https://developers.google.com/gdata/docs/2.0/basics#PartialResponse // for more information. -func (c *ProjectsLocationsConnectionsGetConnectionSchemaMetadataCall) Fields(s ...googleapi.Field) *ProjectsLocationsConnectionsGetConnectionSchemaMetadataCall { +func (c *ProjectsLocationsConnectionsEventSubscriptionsDeleteCall) Fields(s ...googleapi.Field) *ProjectsLocationsConnectionsEventSubscriptionsDeleteCall { 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 *ProjectsLocationsConnectionsGetConnectionSchemaMetadataCall) IfNoneMatch(entityTag string) *ProjectsLocationsConnectionsGetConnectionSchemaMetadataCall { - 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 *ProjectsLocationsConnectionsGetConnectionSchemaMetadataCall) Context(ctx context.Context) *ProjectsLocationsConnectionsGetConnectionSchemaMetadataCall { +func (c *ProjectsLocationsConnectionsEventSubscriptionsDeleteCall) Context(ctx context.Context) *ProjectsLocationsConnectionsEventSubscriptionsDeleteCall { 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 *ProjectsLocationsConnectionsGetConnectionSchemaMetadataCall) Header() http.Header { +func (c *ProjectsLocationsConnectionsEventSubscriptionsDeleteCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) } return c.header_ } -func (c *ProjectsLocationsConnectionsGetConnectionSchemaMetadataCall) doRequest(alt string) (*http.Response, error) { +func (c *ProjectsLocationsConnectionsEventSubscriptionsDeleteCall) doRequest(alt string) (*http.Response, error) { reqHeaders := make(http.Header) reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version) for k, v := range c.header_ { reqHeaders[k] = v } reqHeaders.Set("User-Agent", c.s.userAgent()) - if c.ifNoneMatch_ != "" { - reqHeaders.Set("If-None-Match", c.ifNoneMatch_) - } var body io.Reader = nil c.urlParams_.Set("alt", alt) c.urlParams_.Set("prettyPrint", "false") urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+name}") urls += "?" + c.urlParams_.Encode() - req, err := http.NewRequest("GET", urls, body) + req, err := http.NewRequest("DELETE", urls, body) if err != nil { return nil, err } @@ -4782,14 +6927,14 @@ func (c *ProjectsLocationsConnectionsGetConnectionSchemaMetadataCall) doRequest( return gensupport.SendRequest(c.ctx_, c.s.client, req) } -// Do executes the "connectors.projects.locations.connections.getConnectionSchemaMetadata" call. -// Exactly one of *ConnectionSchemaMetadata or error will be non-nil. -// Any non-2xx status code is an error. Response headers are in either -// *ConnectionSchemaMetadata.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 *ProjectsLocationsConnectionsGetConnectionSchemaMetadataCall) Do(opts ...googleapi.CallOption) (*ConnectionSchemaMetadata, error) { +// Do executes the "connectors.projects.locations.connections.eventSubscriptions.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 *ProjectsLocationsConnectionsEventSubscriptionsDeleteCall) Do(opts ...googleapi.CallOption) (*Operation, error) { gensupport.SetOptions(c.urlParams_, opts...) res, err := c.doRequest("json") if res != nil && res.StatusCode == http.StatusNotModified { @@ -4808,7 +6953,7 @@ func (c *ProjectsLocationsConnectionsGetConnectionSchemaMetadataCall) Do(opts .. if err := googleapi.CheckResponse(res); err != nil { return nil, gensupport.WrapError(err) } - ret := &ConnectionSchemaMetadata{ + ret := &Operation{ ServerResponse: googleapi.ServerResponse{ Header: res.Header, HTTPStatusCode: res.StatusCode, @@ -4820,25 +6965,25 @@ func (c *ProjectsLocationsConnectionsGetConnectionSchemaMetadataCall) Do(opts .. } return ret, nil // { - // "description": "Gets schema metadata of a connection. SchemaMetadata is a singleton resource for each connection.", - // "flatPath": "v1/projects/{projectsId}/locations/{locationsId}/connections/{connectionsId}/connectionSchemaMetadata", - // "httpMethod": "GET", - // "id": "connectors.projects.locations.connections.getConnectionSchemaMetadata", + // "description": "Deletes a single EventSubscription.", + // "flatPath": "v1/projects/{projectsId}/locations/{locationsId}/connections/{connectionsId}/eventSubscriptions/{eventSubscriptionsId}", + // "httpMethod": "DELETE", + // "id": "connectors.projects.locations.connections.eventSubscriptions.delete", // "parameterOrder": [ // "name" // ], // "parameters": { // "name": { - // "description": "Required. Connection name Format: projects/{project}/locations/{location}/connections/{connection}/connectionSchemaMetadata", + // "description": "Required. Resource name of the form: `projects/*/locations/*/connections/*/eventsubscriptions/*`", // "location": "path", - // "pattern": "^projects/[^/]+/locations/[^/]+/connections/[^/]+/connectionSchemaMetadata$", + // "pattern": "^projects/[^/]+/locations/[^/]+/connections/[^/]+/eventSubscriptions/[^/]+$", // "required": true, // "type": "string" // } // }, // "path": "v1/{+name}", // "response": { - // "$ref": "ConnectionSchemaMetadata" + // "$ref": "Operation" // }, // "scopes": [ // "https://www.googleapis.com/auth/cloud-platform" @@ -4847,53 +6992,31 @@ func (c *ProjectsLocationsConnectionsGetConnectionSchemaMetadataCall) Do(opts .. } -// method id "connectors.projects.locations.connections.getIamPolicy": +// method id "connectors.projects.locations.connections.eventSubscriptions.get": -type ProjectsLocationsConnectionsGetIamPolicyCall struct { +type ProjectsLocationsConnectionsEventSubscriptionsGetCall struct { s *Service - resource string + name string urlParams_ gensupport.URLParams ifNoneMatch_ string ctx_ context.Context header_ http.Header } -// GetIamPolicy: Gets the access control policy for a resource. Returns -// an empty policy if the resource exists and does not have a policy -// set. +// Get: Gets details of a single EventSubscription. // -// - resource: REQUIRED: The resource for which the policy is being -// requested. See Resource names -// (https://cloud.google.com/apis/design/resource_names) for the -// appropriate value for this field. -func (r *ProjectsLocationsConnectionsService) GetIamPolicy(resource string) *ProjectsLocationsConnectionsGetIamPolicyCall { - c := &ProjectsLocationsConnectionsGetIamPolicyCall{s: r.s, urlParams_: make(gensupport.URLParams)} - c.resource = resource - return c -} - -// OptionsRequestedPolicyVersion sets the optional parameter -// "options.requestedPolicyVersion": The maximum policy version that -// will be used to format the policy. Valid values are 0, 1, and 3. -// Requests specifying an invalid value will be rejected. Requests for -// policies with any conditional role bindings must specify version 3. -// Policies with no conditional role bindings may specify any valid -// value or leave the field unset. The policy in the response might use -// the policy version that you specified, or it might use a lower policy -// version. For example, if you specify version 3, but the policy has no -// conditional role bindings, the response uses version 1. To learn -// which resources support conditions in their IAM policies, see the IAM -// documentation -// (https://cloud.google.com/iam/help/conditions/resource-policies). -func (c *ProjectsLocationsConnectionsGetIamPolicyCall) OptionsRequestedPolicyVersion(optionsRequestedPolicyVersion int64) *ProjectsLocationsConnectionsGetIamPolicyCall { - c.urlParams_.Set("options.requestedPolicyVersion", fmt.Sprint(optionsRequestedPolicyVersion)) +// - name: Resource name of the form: +// `projects/*/locations/*/connections/*/eventSubscriptions/*`. +func (r *ProjectsLocationsConnectionsEventSubscriptionsService) Get(name string) *ProjectsLocationsConnectionsEventSubscriptionsGetCall { + c := &ProjectsLocationsConnectionsEventSubscriptionsGetCall{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 *ProjectsLocationsConnectionsGetIamPolicyCall) Fields(s ...googleapi.Field) *ProjectsLocationsConnectionsGetIamPolicyCall { +func (c *ProjectsLocationsConnectionsEventSubscriptionsGetCall) Fields(s ...googleapi.Field) *ProjectsLocationsConnectionsEventSubscriptionsGetCall { c.urlParams_.Set("fields", googleapi.CombineFields(s)) return c } @@ -4903,7 +7026,7 @@ func (c *ProjectsLocationsConnectionsGetIamPolicyCall) Fields(s ...googleapi.Fie // 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 *ProjectsLocationsConnectionsGetIamPolicyCall) IfNoneMatch(entityTag string) *ProjectsLocationsConnectionsGetIamPolicyCall { +func (c *ProjectsLocationsConnectionsEventSubscriptionsGetCall) IfNoneMatch(entityTag string) *ProjectsLocationsConnectionsEventSubscriptionsGetCall { c.ifNoneMatch_ = entityTag return c } @@ -4911,21 +7034,21 @@ func (c *ProjectsLocationsConnectionsGetIamPolicyCall) IfNoneMatch(entityTag str // 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 *ProjectsLocationsConnectionsGetIamPolicyCall) Context(ctx context.Context) *ProjectsLocationsConnectionsGetIamPolicyCall { +func (c *ProjectsLocationsConnectionsEventSubscriptionsGetCall) Context(ctx context.Context) *ProjectsLocationsConnectionsEventSubscriptionsGetCall { 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 *ProjectsLocationsConnectionsGetIamPolicyCall) Header() http.Header { +func (c *ProjectsLocationsConnectionsEventSubscriptionsGetCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) } return c.header_ } -func (c *ProjectsLocationsConnectionsGetIamPolicyCall) doRequest(alt string) (*http.Response, error) { +func (c *ProjectsLocationsConnectionsEventSubscriptionsGetCall) 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_ { @@ -4938,7 +7061,7 @@ func (c *ProjectsLocationsConnectionsGetIamPolicyCall) doRequest(alt string) (*h var body io.Reader = nil c.urlParams_.Set("alt", alt) c.urlParams_.Set("prettyPrint", "false") - urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+resource}:getIamPolicy") + urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+name}") urls += "?" + c.urlParams_.Encode() req, err := http.NewRequest("GET", urls, body) if err != nil { @@ -4946,19 +7069,19 @@ func (c *ProjectsLocationsConnectionsGetIamPolicyCall) doRequest(alt string) (*h } req.Header = reqHeaders googleapi.Expand(req.URL, map[string]string{ - "resource": c.resource, + "name": c.name, }) return gensupport.SendRequest(c.ctx_, c.s.client, req) } -// Do executes the "connectors.projects.locations.connections.getIamPolicy" call. -// Exactly one of *Policy or error will be non-nil. Any non-2xx status -// code is an error. Response headers are in either -// *Policy.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 *ProjectsLocationsConnectionsGetIamPolicyCall) Do(opts ...googleapi.CallOption) (*Policy, error) { +// Do executes the "connectors.projects.locations.connections.eventSubscriptions.get" call. +// Exactly one of *EventSubscription or error will be non-nil. Any +// non-2xx status code is an error. Response headers are in either +// *EventSubscription.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 *ProjectsLocationsConnectionsEventSubscriptionsGetCall) Do(opts ...googleapi.CallOption) (*EventSubscription, error) { gensupport.SetOptions(c.urlParams_, opts...) res, err := c.doRequest("json") if res != nil && res.StatusCode == http.StatusNotModified { @@ -4977,7 +7100,7 @@ func (c *ProjectsLocationsConnectionsGetIamPolicyCall) Do(opts ...googleapi.Call if err := googleapi.CheckResponse(res); err != nil { return nil, gensupport.WrapError(err) } - ret := &Policy{ + ret := &EventSubscription{ ServerResponse: googleapi.ServerResponse{ Header: res.Header, HTTPStatusCode: res.StatusCode, @@ -4989,31 +7112,25 @@ func (c *ProjectsLocationsConnectionsGetIamPolicyCall) Do(opts ...googleapi.Call } return ret, nil // { - // "description": "Gets the access control policy for a resource. Returns an empty policy if the resource exists and does not have a policy set.", - // "flatPath": "v1/projects/{projectsId}/locations/{locationsId}/connections/{connectionsId}:getIamPolicy", + // "description": "Gets details of a single EventSubscription.", + // "flatPath": "v1/projects/{projectsId}/locations/{locationsId}/connections/{connectionsId}/eventSubscriptions/{eventSubscriptionsId}", // "httpMethod": "GET", - // "id": "connectors.projects.locations.connections.getIamPolicy", + // "id": "connectors.projects.locations.connections.eventSubscriptions.get", // "parameterOrder": [ - // "resource" + // "name" // ], // "parameters": { - // "options.requestedPolicyVersion": { - // "description": "Optional. The maximum policy version that will be used to format the policy. Valid values are 0, 1, and 3. Requests specifying an invalid value will be rejected. Requests for policies with any conditional role bindings must specify version 3. Policies with no conditional role bindings may specify any valid value or leave the field unset. The policy in the response might use the policy version that you specified, or it might use a lower policy version. For example, if you specify version 3, but the policy has no conditional role bindings, the response uses version 1. To learn which resources support conditions in their IAM policies, see the [IAM documentation](https://cloud.google.com/iam/help/conditions/resource-policies).", - // "format": "int32", - // "location": "query", - // "type": "integer" - // }, - // "resource": { - // "description": "REQUIRED: The resource for which the policy is being requested. See [Resource names](https://cloud.google.com/apis/design/resource_names) for the appropriate value for this field.", + // "name": { + // "description": "Required. Resource name of the form: `projects/*/locations/*/connections/*/eventSubscriptions/*`", // "location": "path", - // "pattern": "^projects/[^/]+/locations/[^/]+/connections/[^/]+$", + // "pattern": "^projects/[^/]+/locations/[^/]+/connections/[^/]+/eventSubscriptions/[^/]+$", // "required": true, // "type": "string" // } // }, - // "path": "v1/{+resource}:getIamPolicy", + // "path": "v1/{+name}", // "response": { - // "$ref": "Policy" + // "$ref": "EventSubscription" // }, // "scopes": [ // "https://www.googleapis.com/auth/cloud-platform" @@ -5022,9 +7139,9 @@ func (c *ProjectsLocationsConnectionsGetIamPolicyCall) Do(opts ...googleapi.Call } -// method id "connectors.projects.locations.connections.list": +// method id "connectors.projects.locations.connections.eventSubscriptions.list": -type ProjectsLocationsConnectionsListCall struct { +type ProjectsLocationsConnectionsEventSubscriptionsListCall struct { s *Service parent string urlParams_ gensupport.URLParams @@ -5033,58 +7150,46 @@ type ProjectsLocationsConnectionsListCall struct { header_ http.Header } -// List: Lists Connections in a given project and location. +// List: List EventSubscriptions in a given project,location and +// connection. // -// - parent: Parent resource of the Connection, of the form: -// `projects/*/locations/*`. -func (r *ProjectsLocationsConnectionsService) List(parent string) *ProjectsLocationsConnectionsListCall { - c := &ProjectsLocationsConnectionsListCall{s: r.s, urlParams_: make(gensupport.URLParams)} +// - parent: Parent resource of the EventSubscription, of the form: +// `projects/*/locations/*/connections/*`. +func (r *ProjectsLocationsConnectionsEventSubscriptionsService) List(parent string) *ProjectsLocationsConnectionsEventSubscriptionsListCall { + c := &ProjectsLocationsConnectionsEventSubscriptionsListCall{s: r.s, urlParams_: make(gensupport.URLParams)} c.parent = parent return c } // Filter sets the optional parameter "filter": Filter. -func (c *ProjectsLocationsConnectionsListCall) Filter(filter string) *ProjectsLocationsConnectionsListCall { +// https://g3doc.corp.google.com/cloud/control2/g3doc/dev/apihosting/list_filtering.md#filtering. +func (c *ProjectsLocationsConnectionsEventSubscriptionsListCall) Filter(filter string) *ProjectsLocationsConnectionsEventSubscriptionsListCall { c.urlParams_.Set("filter", filter) return c } // OrderBy sets the optional parameter "orderBy": Order by parameters. -func (c *ProjectsLocationsConnectionsListCall) OrderBy(orderBy string) *ProjectsLocationsConnectionsListCall { +func (c *ProjectsLocationsConnectionsEventSubscriptionsListCall) OrderBy(orderBy string) *ProjectsLocationsConnectionsEventSubscriptionsListCall { c.urlParams_.Set("orderBy", orderBy) return c } // PageSize sets the optional parameter "pageSize": Page size. -func (c *ProjectsLocationsConnectionsListCall) PageSize(pageSize int64) *ProjectsLocationsConnectionsListCall { +func (c *ProjectsLocationsConnectionsEventSubscriptionsListCall) PageSize(pageSize int64) *ProjectsLocationsConnectionsEventSubscriptionsListCall { c.urlParams_.Set("pageSize", fmt.Sprint(pageSize)) return c } // PageToken sets the optional parameter "pageToken": Page token. -func (c *ProjectsLocationsConnectionsListCall) PageToken(pageToken string) *ProjectsLocationsConnectionsListCall { +func (c *ProjectsLocationsConnectionsEventSubscriptionsListCall) PageToken(pageToken string) *ProjectsLocationsConnectionsEventSubscriptionsListCall { c.urlParams_.Set("pageToken", pageToken) return c } -// View sets the optional parameter "view": Specifies which fields of -// the Connection are returned in the response. Defaults to `BASIC` -// view. -// -// Possible values: -// -// "CONNECTION_VIEW_UNSPECIFIED" - CONNECTION_UNSPECIFIED. -// "BASIC" - Do not include runtime required configs. -// "FULL" - Include runtime required configs. -func (c *ProjectsLocationsConnectionsListCall) View(view string) *ProjectsLocationsConnectionsListCall { - 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 *ProjectsLocationsConnectionsListCall) Fields(s ...googleapi.Field) *ProjectsLocationsConnectionsListCall { +func (c *ProjectsLocationsConnectionsEventSubscriptionsListCall) Fields(s ...googleapi.Field) *ProjectsLocationsConnectionsEventSubscriptionsListCall { c.urlParams_.Set("fields", googleapi.CombineFields(s)) return c } @@ -5094,7 +7199,7 @@ func (c *ProjectsLocationsConnectionsListCall) Fields(s ...googleapi.Field) *Pro // 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 *ProjectsLocationsConnectionsListCall) IfNoneMatch(entityTag string) *ProjectsLocationsConnectionsListCall { +func (c *ProjectsLocationsConnectionsEventSubscriptionsListCall) IfNoneMatch(entityTag string) *ProjectsLocationsConnectionsEventSubscriptionsListCall { c.ifNoneMatch_ = entityTag return c } @@ -5102,21 +7207,21 @@ func (c *ProjectsLocationsConnectionsListCall) IfNoneMatch(entityTag string) *Pr // 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 *ProjectsLocationsConnectionsListCall) Context(ctx context.Context) *ProjectsLocationsConnectionsListCall { +func (c *ProjectsLocationsConnectionsEventSubscriptionsListCall) Context(ctx context.Context) *ProjectsLocationsConnectionsEventSubscriptionsListCall { 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 *ProjectsLocationsConnectionsListCall) Header() http.Header { +func (c *ProjectsLocationsConnectionsEventSubscriptionsListCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) } return c.header_ } -func (c *ProjectsLocationsConnectionsListCall) doRequest(alt string) (*http.Response, error) { +func (c *ProjectsLocationsConnectionsEventSubscriptionsListCall) 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_ { @@ -5129,7 +7234,7 @@ func (c *ProjectsLocationsConnectionsListCall) doRequest(alt string) (*http.Resp var body io.Reader = nil c.urlParams_.Set("alt", alt) c.urlParams_.Set("prettyPrint", "false") - urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+parent}/connections") + urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+parent}/eventSubscriptions") urls += "?" + c.urlParams_.Encode() req, err := http.NewRequest("GET", urls, body) if err != nil { @@ -5142,14 +7247,14 @@ func (c *ProjectsLocationsConnectionsListCall) doRequest(alt string) (*http.Resp return gensupport.SendRequest(c.ctx_, c.s.client, req) } -// Do executes the "connectors.projects.locations.connections.list" call. -// Exactly one of *ListConnectionsResponse or error will be non-nil. Any -// non-2xx status code is an error. Response headers are in either -// *ListConnectionsResponse.ServerResponse.Header or (if a response was -// returned at all) in error.(*googleapi.Error).Header. Use +// Do executes the "connectors.projects.locations.connections.eventSubscriptions.list" call. +// Exactly one of *ListEventSubscriptionsResponse or error will be +// non-nil. Any non-2xx status code is an error. Response headers are in +// either *ListEventSubscriptionsResponse.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 *ProjectsLocationsConnectionsListCall) Do(opts ...googleapi.CallOption) (*ListConnectionsResponse, error) { +func (c *ProjectsLocationsConnectionsEventSubscriptionsListCall) Do(opts ...googleapi.CallOption) (*ListEventSubscriptionsResponse, error) { gensupport.SetOptions(c.urlParams_, opts...) res, err := c.doRequest("json") if res != nil && res.StatusCode == http.StatusNotModified { @@ -5168,7 +7273,7 @@ func (c *ProjectsLocationsConnectionsListCall) Do(opts ...googleapi.CallOption) if err := googleapi.CheckResponse(res); err != nil { return nil, gensupport.WrapError(err) } - ret := &ListConnectionsResponse{ + ret := &ListEventSubscriptionsResponse{ ServerResponse: googleapi.ServerResponse{ Header: res.Header, HTTPStatusCode: res.StatusCode, @@ -5180,16 +7285,16 @@ func (c *ProjectsLocationsConnectionsListCall) Do(opts ...googleapi.CallOption) } return ret, nil // { - // "description": "Lists Connections in a given project and location.", - // "flatPath": "v1/projects/{projectsId}/locations/{locationsId}/connections", + // "description": "List EventSubscriptions in a given project,location and connection.", + // "flatPath": "v1/projects/{projectsId}/locations/{locationsId}/connections/{connectionsId}/eventSubscriptions", // "httpMethod": "GET", - // "id": "connectors.projects.locations.connections.list", + // "id": "connectors.projects.locations.connections.eventSubscriptions.list", // "parameterOrder": [ // "parent" // ], // "parameters": { // "filter": { - // "description": "Filter.", + // "description": "Filter. https://g3doc.corp.google.com/cloud/control2/g3doc/dev/apihosting/list_filtering.md#filtering.", // "location": "query", // "type": "string" // }, @@ -5210,31 +7315,16 @@ func (c *ProjectsLocationsConnectionsListCall) Do(opts ...googleapi.CallOption) // "type": "string" // }, // "parent": { - // "description": "Required. Parent resource of the Connection, of the form: `projects/*/locations/*`", + // "description": "Required. Parent resource of the EventSubscription, of the form: `projects/*/locations/*/connections/*`", // "location": "path", - // "pattern": "^projects/[^/]+/locations/[^/]+$", + // "pattern": "^projects/[^/]+/locations/[^/]+/connections/[^/]+$", // "required": true, // "type": "string" - // }, - // "view": { - // "description": "Specifies which fields of the Connection are returned in the response. Defaults to `BASIC` view.", - // "enum": [ - // "CONNECTION_VIEW_UNSPECIFIED", - // "BASIC", - // "FULL" - // ], - // "enumDescriptions": [ - // "CONNECTION_UNSPECIFIED.", - // "Do not include runtime required configs.", - // "Include runtime required configs." - // ], - // "location": "query", - // "type": "string" // } // }, - // "path": "v1/{+parent}/connections", + // "path": "v1/{+parent}/eventSubscriptions", // "response": { - // "$ref": "ListConnectionsResponse" + // "$ref": "ListEventSubscriptionsResponse" // }, // "scopes": [ // "https://www.googleapis.com/auth/cloud-platform" @@ -5246,7 +7336,7 @@ func (c *ProjectsLocationsConnectionsListCall) Do(opts ...googleapi.CallOption) // 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 *ProjectsLocationsConnectionsListCall) Pages(ctx context.Context, f func(*ListConnectionsResponse) error) error { +func (c *ProjectsLocationsConnectionsEventSubscriptionsListCall) Pages(ctx context.Context, f func(*ListEventSubscriptionsResponse) error) error { c.ctx_ = ctx defer c.PageToken(c.urlParams_.Get("pageToken")) // reset paging to original point for { @@ -5264,35 +7354,35 @@ func (c *ProjectsLocationsConnectionsListCall) Pages(ctx context.Context, f func } } -// method id "connectors.projects.locations.connections.patch": +// method id "connectors.projects.locations.connections.eventSubscriptions.patch": -type ProjectsLocationsConnectionsPatchCall struct { - s *Service - name string - connection *Connection - urlParams_ gensupport.URLParams - ctx_ context.Context - header_ http.Header +type ProjectsLocationsConnectionsEventSubscriptionsPatchCall struct { + s *Service + name string + eventsubscription *EventSubscription + urlParams_ gensupport.URLParams + ctx_ context.Context + header_ http.Header } -// Patch: Updates the parameters of a single Connection. +// Patch: Updates the parameters of a single EventSubscription. // -// - name: Output only. Resource name of the Connection. Format: -// projects/{project}/locations/{location}/connections/{connection}. -func (r *ProjectsLocationsConnectionsService) Patch(name string, connection *Connection) *ProjectsLocationsConnectionsPatchCall { - c := &ProjectsLocationsConnectionsPatchCall{s: r.s, urlParams_: make(gensupport.URLParams)} +// - name: Resource name of the EventSubscription. Format: +// projects/{project}/locations/{location}/connections/{connection}/eve +// ntSubscriptions/{event_subscription}. +func (r *ProjectsLocationsConnectionsEventSubscriptionsService) Patch(name string, eventsubscription *EventSubscription) *ProjectsLocationsConnectionsEventSubscriptionsPatchCall { + c := &ProjectsLocationsConnectionsEventSubscriptionsPatchCall{s: r.s, urlParams_: make(gensupport.URLParams)} c.name = name - c.connection = connection + c.eventsubscription = eventsubscription return c } -// UpdateMask sets the optional parameter "updateMask": Required. You -// can modify only the fields listed below. To lock/unlock a connection: -// * `lock_config` To suspend/resume a connection: * `suspended` To -// update the connection details: * `description` * `labels` * -// `connector_version` * `config_variables` * `auth_config` * -// `destination_configs` * `node_config` -func (c *ProjectsLocationsConnectionsPatchCall) UpdateMask(updateMask string) *ProjectsLocationsConnectionsPatchCall { +// UpdateMask sets the optional parameter "updateMask": Required. The +// list of fields to update. Fields are specified relative to the +// Subscription. A field will be overwritten if it is in the mask. You +// can modify only the fields listed below. To update the +// EventSubscription details: * `serviceAccount` +func (c *ProjectsLocationsConnectionsEventSubscriptionsPatchCall) UpdateMask(updateMask string) *ProjectsLocationsConnectionsEventSubscriptionsPatchCall { c.urlParams_.Set("updateMask", updateMask) return c } @@ -5300,7 +7390,7 @@ func (c *ProjectsLocationsConnectionsPatchCall) UpdateMask(updateMask string) *P // Fields allows partial responses to be retrieved. See // https://developers.google.com/gdata/docs/2.0/basics#PartialResponse // for more information. -func (c *ProjectsLocationsConnectionsPatchCall) Fields(s ...googleapi.Field) *ProjectsLocationsConnectionsPatchCall { +func (c *ProjectsLocationsConnectionsEventSubscriptionsPatchCall) Fields(s ...googleapi.Field) *ProjectsLocationsConnectionsEventSubscriptionsPatchCall { c.urlParams_.Set("fields", googleapi.CombineFields(s)) return c } @@ -5308,21 +7398,21 @@ func (c *ProjectsLocationsConnectionsPatchCall) Fields(s ...googleapi.Field) *Pr // 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 *ProjectsLocationsConnectionsPatchCall) Context(ctx context.Context) *ProjectsLocationsConnectionsPatchCall { +func (c *ProjectsLocationsConnectionsEventSubscriptionsPatchCall) Context(ctx context.Context) *ProjectsLocationsConnectionsEventSubscriptionsPatchCall { 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 *ProjectsLocationsConnectionsPatchCall) Header() http.Header { +func (c *ProjectsLocationsConnectionsEventSubscriptionsPatchCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) } return c.header_ } -func (c *ProjectsLocationsConnectionsPatchCall) doRequest(alt string) (*http.Response, error) { +func (c *ProjectsLocationsConnectionsEventSubscriptionsPatchCall) 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_ { @@ -5330,7 +7420,7 @@ func (c *ProjectsLocationsConnectionsPatchCall) doRequest(alt string) (*http.Res } reqHeaders.Set("User-Agent", c.s.userAgent()) var body io.Reader = nil - body, err := googleapi.WithoutDataWrapper.JSONReader(c.connection) + body, err := googleapi.WithoutDataWrapper.JSONReader(c.eventsubscription) if err != nil { return nil, err } @@ -5350,14 +7440,14 @@ func (c *ProjectsLocationsConnectionsPatchCall) doRequest(alt string) (*http.Res return gensupport.SendRequest(c.ctx_, c.s.client, req) } -// Do executes the "connectors.projects.locations.connections.patch" call. +// Do executes the "connectors.projects.locations.connections.eventSubscriptions.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 *ProjectsLocationsConnectionsPatchCall) Do(opts ...googleapi.CallOption) (*Operation, error) { +func (c *ProjectsLocationsConnectionsEventSubscriptionsPatchCall) Do(opts ...googleapi.CallOption) (*Operation, error) { gensupport.SetOptions(c.urlParams_, opts...) res, err := c.doRequest("json") if res != nil && res.StatusCode == http.StatusNotModified { @@ -5388,23 +7478,23 @@ func (c *ProjectsLocationsConnectionsPatchCall) Do(opts ...googleapi.CallOption) } return ret, nil // { - // "description": "Updates the parameters of a single Connection.", - // "flatPath": "v1/projects/{projectsId}/locations/{locationsId}/connections/{connectionsId}", + // "description": "Updates the parameters of a single EventSubscription.", + // "flatPath": "v1/projects/{projectsId}/locations/{locationsId}/connections/{connectionsId}/eventSubscriptions/{eventSubscriptionsId}", // "httpMethod": "PATCH", - // "id": "connectors.projects.locations.connections.patch", + // "id": "connectors.projects.locations.connections.eventSubscriptions.patch", // "parameterOrder": [ // "name" // ], // "parameters": { // "name": { - // "description": "Output only. Resource name of the Connection. Format: projects/{project}/locations/{location}/connections/{connection}", + // "description": "Required. Resource name of the EventSubscription. Format: projects/{project}/locations/{location}/connections/{connection}/eventSubscriptions/{event_subscription}", // "location": "path", - // "pattern": "^projects/[^/]+/locations/[^/]+/connections/[^/]+$", + // "pattern": "^projects/[^/]+/locations/[^/]+/connections/[^/]+/eventSubscriptions/[^/]+$", // "required": true, // "type": "string" // }, // "updateMask": { - // "description": "Required. You can modify only the fields listed below. To lock/unlock a connection: * `lock_config` To suspend/resume a connection: * `suspended` To update the connection details: * `description` * `labels` * `connector_version` * `config_variables` * `auth_config` * `destination_configs` * `node_config`", + // "description": "Required. The list of fields to update. Fields are specified relative to the Subscription. A field will be overwritten if it is in the mask. You can modify only the fields listed below. To update the EventSubscription details: * `serviceAccount`", // "format": "google-fieldmask", // "location": "query", // "type": "string" @@ -5412,7 +7502,151 @@ func (c *ProjectsLocationsConnectionsPatchCall) Do(opts ...googleapi.CallOption) // }, // "path": "v1/{+name}", // "request": { - // "$ref": "Connection" + // "$ref": "EventSubscription" + // }, + // "response": { + // "$ref": "Operation" + // }, + // "scopes": [ + // "https://www.googleapis.com/auth/cloud-platform" + // ] + // } + +} + +// method id "connectors.projects.locations.connections.eventSubscriptions.retry": + +type ProjectsLocationsConnectionsEventSubscriptionsRetryCall struct { + s *Service + name string + retryeventsubscriptionrequest *RetryEventSubscriptionRequest + urlParams_ gensupport.URLParams + ctx_ context.Context + header_ http.Header +} + +// Retry: RetryEventSubscription retries the registration of +// Subscription. +// +// - name: Resource name of the form: +// `projects/*/locations/*/connections/*/eventSubscriptions/*`. +func (r *ProjectsLocationsConnectionsEventSubscriptionsService) Retry(name string, retryeventsubscriptionrequest *RetryEventSubscriptionRequest) *ProjectsLocationsConnectionsEventSubscriptionsRetryCall { + c := &ProjectsLocationsConnectionsEventSubscriptionsRetryCall{s: r.s, urlParams_: make(gensupport.URLParams)} + c.name = name + c.retryeventsubscriptionrequest = retryeventsubscriptionrequest + 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 *ProjectsLocationsConnectionsEventSubscriptionsRetryCall) Fields(s ...googleapi.Field) *ProjectsLocationsConnectionsEventSubscriptionsRetryCall { + 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 *ProjectsLocationsConnectionsEventSubscriptionsRetryCall) Context(ctx context.Context) *ProjectsLocationsConnectionsEventSubscriptionsRetryCall { + 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 *ProjectsLocationsConnectionsEventSubscriptionsRetryCall) Header() http.Header { + if c.header_ == nil { + c.header_ = make(http.Header) + } + return c.header_ +} + +func (c *ProjectsLocationsConnectionsEventSubscriptionsRetryCall) 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.retryeventsubscriptionrequest) + if err != nil { + return nil, err + } + reqHeaders.Set("Content-Type", "application/json") + c.urlParams_.Set("alt", alt) + c.urlParams_.Set("prettyPrint", "false") + urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+name}:retry") + 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 "connectors.projects.locations.connections.eventSubscriptions.retry" 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 *ProjectsLocationsConnectionsEventSubscriptionsRetryCall) 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": "RetryEventSubscription retries the registration of Subscription.", + // "flatPath": "v1/projects/{projectsId}/locations/{locationsId}/connections/{connectionsId}/eventSubscriptions/{eventSubscriptionsId}:retry", + // "httpMethod": "POST", + // "id": "connectors.projects.locations.connections.eventSubscriptions.retry", + // "parameterOrder": [ + // "name" + // ], + // "parameters": { + // "name": { + // "description": "Required. Resource name of the form: `projects/*/locations/*/connections/*/eventSubscriptions/*`", + // "location": "path", + // "pattern": "^projects/[^/]+/locations/[^/]+/connections/[^/]+/eventSubscriptions/[^/]+$", + // "required": true, + // "type": "string" + // } + // }, + // "path": "v1/{+name}:retry", + // "request": { + // "$ref": "RetryEventSubscriptionRequest" // }, // "response": { // "$ref": "Operation" @@ -5424,93 +7658,117 @@ func (c *ProjectsLocationsConnectionsPatchCall) Do(opts ...googleapi.CallOption) } -// method id "connectors.projects.locations.connections.setIamPolicy": +// method id "connectors.projects.locations.connections.runtimeActionSchemas.list": + +type ProjectsLocationsConnectionsRuntimeActionSchemasListCall struct { + s *Service + parent string + urlParams_ gensupport.URLParams + ifNoneMatch_ string + ctx_ context.Context + header_ http.Header +} + +// List: List schema of a runtime actions filtered by action name. +// +// - parent: Parent resource of RuntimeActionSchema Format: +// projects/{project}/locations/{location}/connections/{connection}. +func (r *ProjectsLocationsConnectionsRuntimeActionSchemasService) List(parent string) *ProjectsLocationsConnectionsRuntimeActionSchemasListCall { + c := &ProjectsLocationsConnectionsRuntimeActionSchemasListCall{s: r.s, urlParams_: make(gensupport.URLParams)} + c.parent = parent + return c +} + +// Filter sets the optional parameter "filter": Required. Filter Format: +// action="{actionId}" Only action field is supported with literal +// equality operator. Accepted filter example: action="CancelOrder" +// Wildcards are not supported in the filter currently. +func (c *ProjectsLocationsConnectionsRuntimeActionSchemasListCall) Filter(filter string) *ProjectsLocationsConnectionsRuntimeActionSchemasListCall { + c.urlParams_.Set("filter", filter) + return c +} -type ProjectsLocationsConnectionsSetIamPolicyCall struct { - s *Service - resource string - setiampolicyrequest *SetIamPolicyRequest - urlParams_ gensupport.URLParams - ctx_ context.Context - header_ http.Header +// PageSize sets the optional parameter "pageSize": Page size. +func (c *ProjectsLocationsConnectionsRuntimeActionSchemasListCall) PageSize(pageSize int64) *ProjectsLocationsConnectionsRuntimeActionSchemasListCall { + c.urlParams_.Set("pageSize", fmt.Sprint(pageSize)) + return c } -// SetIamPolicy: Sets the access control policy on the specified -// resource. Replaces any existing policy. Can return `NOT_FOUND`, -// `INVALID_ARGUMENT`, and `PERMISSION_DENIED` errors. -// -// - resource: REQUIRED: The resource for which the policy is being -// specified. See Resource names -// (https://cloud.google.com/apis/design/resource_names) for the -// appropriate value for this field. -func (r *ProjectsLocationsConnectionsService) SetIamPolicy(resource string, setiampolicyrequest *SetIamPolicyRequest) *ProjectsLocationsConnectionsSetIamPolicyCall { - c := &ProjectsLocationsConnectionsSetIamPolicyCall{s: r.s, urlParams_: make(gensupport.URLParams)} - c.resource = resource - c.setiampolicyrequest = setiampolicyrequest +// PageToken sets the optional parameter "pageToken": Page token. +func (c *ProjectsLocationsConnectionsRuntimeActionSchemasListCall) PageToken(pageToken string) *ProjectsLocationsConnectionsRuntimeActionSchemasListCall { + 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 *ProjectsLocationsConnectionsSetIamPolicyCall) Fields(s ...googleapi.Field) *ProjectsLocationsConnectionsSetIamPolicyCall { +func (c *ProjectsLocationsConnectionsRuntimeActionSchemasListCall) Fields(s ...googleapi.Field) *ProjectsLocationsConnectionsRuntimeActionSchemasListCall { 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 *ProjectsLocationsConnectionsRuntimeActionSchemasListCall) IfNoneMatch(entityTag string) *ProjectsLocationsConnectionsRuntimeActionSchemasListCall { + 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 *ProjectsLocationsConnectionsSetIamPolicyCall) Context(ctx context.Context) *ProjectsLocationsConnectionsSetIamPolicyCall { +func (c *ProjectsLocationsConnectionsRuntimeActionSchemasListCall) Context(ctx context.Context) *ProjectsLocationsConnectionsRuntimeActionSchemasListCall { 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 *ProjectsLocationsConnectionsSetIamPolicyCall) Header() http.Header { +func (c *ProjectsLocationsConnectionsRuntimeActionSchemasListCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) } return c.header_ } -func (c *ProjectsLocationsConnectionsSetIamPolicyCall) doRequest(alt string) (*http.Response, error) { +func (c *ProjectsLocationsConnectionsRuntimeActionSchemasListCall) 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.setiampolicyrequest) - 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, "v1/{+resource}:setIamPolicy") + urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+parent}/runtimeActionSchemas") 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{ - "resource": c.resource, + "parent": c.parent, }) return gensupport.SendRequest(c.ctx_, c.s.client, req) } -// Do executes the "connectors.projects.locations.connections.setIamPolicy" call. -// Exactly one of *Policy or error will be non-nil. Any non-2xx status -// code is an error. Response headers are in either -// *Policy.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 *ProjectsLocationsConnectionsSetIamPolicyCall) Do(opts ...googleapi.CallOption) (*Policy, error) { +// Do executes the "connectors.projects.locations.connections.runtimeActionSchemas.list" call. +// Exactly one of *ListRuntimeActionSchemasResponse or error will be +// non-nil. Any non-2xx status code is an error. Response headers are in +// either *ListRuntimeActionSchemasResponse.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 *ProjectsLocationsConnectionsRuntimeActionSchemasListCall) Do(opts ...googleapi.CallOption) (*ListRuntimeActionSchemasResponse, error) { gensupport.SetOptions(c.urlParams_, opts...) res, err := c.doRequest("json") if res != nil && res.StatusCode == http.StatusNotModified { @@ -5529,7 +7787,7 @@ func (c *ProjectsLocationsConnectionsSetIamPolicyCall) Do(opts ...googleapi.Call if err := googleapi.CheckResponse(res); err != nil { return nil, gensupport.WrapError(err) } - ret := &Policy{ + ret := &ListRuntimeActionSchemasResponse{ ServerResponse: googleapi.ServerResponse{ Header: res.Header, HTTPStatusCode: res.StatusCode, @@ -5541,28 +7799,41 @@ func (c *ProjectsLocationsConnectionsSetIamPolicyCall) Do(opts ...googleapi.Call } return ret, nil // { - // "description": "Sets the access control policy on the specified resource. Replaces any existing policy. Can return `NOT_FOUND`, `INVALID_ARGUMENT`, and `PERMISSION_DENIED` errors.", - // "flatPath": "v1/projects/{projectsId}/locations/{locationsId}/connections/{connectionsId}:setIamPolicy", - // "httpMethod": "POST", - // "id": "connectors.projects.locations.connections.setIamPolicy", + // "description": "List schema of a runtime actions filtered by action name.", + // "flatPath": "v1/projects/{projectsId}/locations/{locationsId}/connections/{connectionsId}/runtimeActionSchemas", + // "httpMethod": "GET", + // "id": "connectors.projects.locations.connections.runtimeActionSchemas.list", // "parameterOrder": [ - // "resource" + // "parent" // ], // "parameters": { - // "resource": { - // "description": "REQUIRED: The resource for which the policy is being specified. See [Resource names](https://cloud.google.com/apis/design/resource_names) for the appropriate value for this field.", + // "filter": { + // "description": "Required. Filter Format: action=\"{actionId}\" Only action field is supported with literal equality operator. Accepted filter example: action=\"CancelOrder\" Wildcards are not supported in the filter currently.", + // "location": "query", + // "type": "string" + // }, + // "pageSize": { + // "description": "Page size.", + // "format": "int32", + // "location": "query", + // "type": "integer" + // }, + // "pageToken": { + // "description": "Page token.", + // "location": "query", + // "type": "string" + // }, + // "parent": { + // "description": "Required. Parent resource of RuntimeActionSchema Format: projects/{project}/locations/{location}/connections/{connection}", // "location": "path", // "pattern": "^projects/[^/]+/locations/[^/]+/connections/[^/]+$", // "required": true, // "type": "string" // } // }, - // "path": "v1/{+resource}:setIamPolicy", - // "request": { - // "$ref": "SetIamPolicyRequest" - // }, + // "path": "v1/{+parent}/runtimeActionSchemas", // "response": { - // "$ref": "Policy" + // "$ref": "ListRuntimeActionSchemasResponse" // }, // "scopes": [ // "https://www.googleapis.com/auth/cloud-platform" @@ -5571,96 +7842,138 @@ func (c *ProjectsLocationsConnectionsSetIamPolicyCall) Do(opts ...googleapi.Call } -// method id "connectors.projects.locations.connections.testIamPermissions": +// 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 *ProjectsLocationsConnectionsRuntimeActionSchemasListCall) Pages(ctx context.Context, f func(*ListRuntimeActionSchemasResponse) 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 ProjectsLocationsConnectionsTestIamPermissionsCall struct { - s *Service - resource string - testiampermissionsrequest *TestIamPermissionsRequest - urlParams_ gensupport.URLParams - ctx_ context.Context - header_ http.Header +// method id "connectors.projects.locations.connections.runtimeEntitySchemas.list": + +type ProjectsLocationsConnectionsRuntimeEntitySchemasListCall struct { + s *Service + parent string + urlParams_ gensupport.URLParams + ifNoneMatch_ string + ctx_ context.Context + header_ http.Header } -// TestIamPermissions: Returns permissions that a caller has on the -// specified resource. If the resource does not exist, this will return -// an empty set of permissions, not a `NOT_FOUND` error. Note: This -// operation is designed to be used for building permission-aware UIs -// and command-line tools, not for authorization checking. This -// operation may "fail open" without warning. +// List: List schema of a runtime entities filtered by entity name. // -// - resource: REQUIRED: The resource for which the policy detail is -// being requested. See Resource names -// (https://cloud.google.com/apis/design/resource_names) for the -// appropriate value for this field. -func (r *ProjectsLocationsConnectionsService) TestIamPermissions(resource string, testiampermissionsrequest *TestIamPermissionsRequest) *ProjectsLocationsConnectionsTestIamPermissionsCall { - c := &ProjectsLocationsConnectionsTestIamPermissionsCall{s: r.s, urlParams_: make(gensupport.URLParams)} - c.resource = resource - c.testiampermissionsrequest = testiampermissionsrequest +// - parent: Parent resource of RuntimeEntitySchema Format: +// projects/{project}/locations/{location}/connections/{connection}. +func (r *ProjectsLocationsConnectionsRuntimeEntitySchemasService) List(parent string) *ProjectsLocationsConnectionsRuntimeEntitySchemasListCall { + c := &ProjectsLocationsConnectionsRuntimeEntitySchemasListCall{s: r.s, urlParams_: make(gensupport.URLParams)} + c.parent = parent + return c +} + +// Filter sets the optional parameter "filter": Required. Filter Format: +// entity="{entityId}" Only entity field is supported with literal +// equality operator. Accepted filter example: entity="Order" Wildcards +// are not supported in the filter currently. +func (c *ProjectsLocationsConnectionsRuntimeEntitySchemasListCall) Filter(filter string) *ProjectsLocationsConnectionsRuntimeEntitySchemasListCall { + c.urlParams_.Set("filter", filter) + return c +} + +// PageSize sets the optional parameter "pageSize": Page size. +func (c *ProjectsLocationsConnectionsRuntimeEntitySchemasListCall) PageSize(pageSize int64) *ProjectsLocationsConnectionsRuntimeEntitySchemasListCall { + c.urlParams_.Set("pageSize", fmt.Sprint(pageSize)) + return c +} + +// PageToken sets the optional parameter "pageToken": Page token. +func (c *ProjectsLocationsConnectionsRuntimeEntitySchemasListCall) PageToken(pageToken string) *ProjectsLocationsConnectionsRuntimeEntitySchemasListCall { + 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 *ProjectsLocationsConnectionsTestIamPermissionsCall) Fields(s ...googleapi.Field) *ProjectsLocationsConnectionsTestIamPermissionsCall { +func (c *ProjectsLocationsConnectionsRuntimeEntitySchemasListCall) Fields(s ...googleapi.Field) *ProjectsLocationsConnectionsRuntimeEntitySchemasListCall { 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 *ProjectsLocationsConnectionsRuntimeEntitySchemasListCall) IfNoneMatch(entityTag string) *ProjectsLocationsConnectionsRuntimeEntitySchemasListCall { + 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 *ProjectsLocationsConnectionsTestIamPermissionsCall) Context(ctx context.Context) *ProjectsLocationsConnectionsTestIamPermissionsCall { +func (c *ProjectsLocationsConnectionsRuntimeEntitySchemasListCall) Context(ctx context.Context) *ProjectsLocationsConnectionsRuntimeEntitySchemasListCall { 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 *ProjectsLocationsConnectionsTestIamPermissionsCall) Header() http.Header { +func (c *ProjectsLocationsConnectionsRuntimeEntitySchemasListCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) } return c.header_ } -func (c *ProjectsLocationsConnectionsTestIamPermissionsCall) doRequest(alt string) (*http.Response, error) { +func (c *ProjectsLocationsConnectionsRuntimeEntitySchemasListCall) 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.testiampermissionsrequest) - 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, "v1/{+resource}:testIamPermissions") + urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+parent}/runtimeEntitySchemas") 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{ - "resource": c.resource, + "parent": c.parent, }) return gensupport.SendRequest(c.ctx_, c.s.client, req) } -// Do executes the "connectors.projects.locations.connections.testIamPermissions" call. -// Exactly one of *TestIamPermissionsResponse or error will be non-nil. -// Any non-2xx status code is an error. Response headers are in either -// *TestIamPermissionsResponse.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 "connectors.projects.locations.connections.runtimeEntitySchemas.list" call. +// Exactly one of *ListRuntimeEntitySchemasResponse or error will be +// non-nil. Any non-2xx status code is an error. Response headers are in +// either *ListRuntimeEntitySchemasResponse.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 *ProjectsLocationsConnectionsTestIamPermissionsCall) Do(opts ...googleapi.CallOption) (*TestIamPermissionsResponse, error) { +func (c *ProjectsLocationsConnectionsRuntimeEntitySchemasListCall) Do(opts ...googleapi.CallOption) (*ListRuntimeEntitySchemasResponse, error) { gensupport.SetOptions(c.urlParams_, opts...) res, err := c.doRequest("json") if res != nil && res.StatusCode == http.StatusNotModified { @@ -5679,7 +7992,7 @@ func (c *ProjectsLocationsConnectionsTestIamPermissionsCall) Do(opts ...googleap if err := googleapi.CheckResponse(res); err != nil { return nil, gensupport.WrapError(err) } - ret := &TestIamPermissionsResponse{ + ret := &ListRuntimeEntitySchemasResponse{ ServerResponse: googleapi.ServerResponse{ Header: res.Header, HTTPStatusCode: res.StatusCode, @@ -5691,28 +8004,41 @@ func (c *ProjectsLocationsConnectionsTestIamPermissionsCall) Do(opts ...googleap } return ret, nil // { - // "description": "Returns permissions that a caller has on the specified resource. If the resource does not exist, this will return an empty set of permissions, not a `NOT_FOUND` error. Note: This operation is designed to be used for building permission-aware UIs and command-line tools, not for authorization checking. This operation may \"fail open\" without warning.", - // "flatPath": "v1/projects/{projectsId}/locations/{locationsId}/connections/{connectionsId}:testIamPermissions", - // "httpMethod": "POST", - // "id": "connectors.projects.locations.connections.testIamPermissions", + // "description": "List schema of a runtime entities filtered by entity name.", + // "flatPath": "v1/projects/{projectsId}/locations/{locationsId}/connections/{connectionsId}/runtimeEntitySchemas", + // "httpMethod": "GET", + // "id": "connectors.projects.locations.connections.runtimeEntitySchemas.list", // "parameterOrder": [ - // "resource" + // "parent" // ], // "parameters": { - // "resource": { - // "description": "REQUIRED: The resource for which the policy detail is being requested. See [Resource names](https://cloud.google.com/apis/design/resource_names) for the appropriate value for this field.", + // "filter": { + // "description": "Required. Filter Format: entity=\"{entityId}\" Only entity field is supported with literal equality operator. Accepted filter example: entity=\"Order\" Wildcards are not supported in the filter currently.", + // "location": "query", + // "type": "string" + // }, + // "pageSize": { + // "description": "Page size.", + // "format": "int32", + // "location": "query", + // "type": "integer" + // }, + // "pageToken": { + // "description": "Page token.", + // "location": "query", + // "type": "string" + // }, + // "parent": { + // "description": "Required. Parent resource of RuntimeEntitySchema Format: projects/{project}/locations/{location}/connections/{connection}", // "location": "path", // "pattern": "^projects/[^/]+/locations/[^/]+/connections/[^/]+$", // "required": true, // "type": "string" // } // }, - // "path": "v1/{+resource}:testIamPermissions", - // "request": { - // "$ref": "TestIamPermissionsRequest" - // }, + // "path": "v1/{+parent}/runtimeEntitySchemas", // "response": { - // "$ref": "TestIamPermissionsResponse" + // "$ref": "ListRuntimeEntitySchemasResponse" // }, // "scopes": [ // "https://www.googleapis.com/auth/cloud-platform" @@ -5721,33 +8047,63 @@ func (c *ProjectsLocationsConnectionsTestIamPermissionsCall) Do(opts ...googleap } -// method id "connectors.projects.locations.connections.connectionSchemaMetadata.refresh": +// 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 *ProjectsLocationsConnectionsRuntimeEntitySchemasListCall) Pages(ctx context.Context, f func(*ListRuntimeEntitySchemasResponse) 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 ProjectsLocationsConnectionsConnectionSchemaMetadataRefreshCall struct { - s *Service - name string - refreshconnectionschemametadatarequest *RefreshConnectionSchemaMetadataRequest - urlParams_ gensupport.URLParams - ctx_ context.Context - header_ http.Header +// method id "connectors.projects.locations.endpointAttachments.create": + +type ProjectsLocationsEndpointAttachmentsCreateCall struct { + s *Service + parent string + endpointattachment *EndpointAttachment + urlParams_ gensupport.URLParams + ctx_ context.Context + header_ http.Header } -// Refresh: Refresh runtime schema of a connection. +// Create: Creates a new EndpointAttachment in a given project and +// location. // -// - name: Resource name. Format: -// projects/{project}/locations/{location}/connections/{connection}/con -// nectionSchemaMetadata. -func (r *ProjectsLocationsConnectionsConnectionSchemaMetadataService) Refresh(name string, refreshconnectionschemametadatarequest *RefreshConnectionSchemaMetadataRequest) *ProjectsLocationsConnectionsConnectionSchemaMetadataRefreshCall { - c := &ProjectsLocationsConnectionsConnectionSchemaMetadataRefreshCall{s: r.s, urlParams_: make(gensupport.URLParams)} - c.name = name - c.refreshconnectionschemametadatarequest = refreshconnectionschemametadatarequest +// - parent: Parent resource of the EndpointAttachment, of the form: +// `projects/*/locations/*`. +func (r *ProjectsLocationsEndpointAttachmentsService) Create(parent string, endpointattachment *EndpointAttachment) *ProjectsLocationsEndpointAttachmentsCreateCall { + c := &ProjectsLocationsEndpointAttachmentsCreateCall{s: r.s, urlParams_: make(gensupport.URLParams)} + c.parent = parent + c.endpointattachment = endpointattachment + return c +} + +// EndpointAttachmentId sets the optional parameter +// "endpointAttachmentId": Required. Identifier to assign to the +// EndpointAttachment. Must be unique within scope of the parent +// resource. +func (c *ProjectsLocationsEndpointAttachmentsCreateCall) EndpointAttachmentId(endpointAttachmentId string) *ProjectsLocationsEndpointAttachmentsCreateCall { + c.urlParams_.Set("endpointAttachmentId", endpointAttachmentId) 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 *ProjectsLocationsConnectionsConnectionSchemaMetadataRefreshCall) Fields(s ...googleapi.Field) *ProjectsLocationsConnectionsConnectionSchemaMetadataRefreshCall { +func (c *ProjectsLocationsEndpointAttachmentsCreateCall) Fields(s ...googleapi.Field) *ProjectsLocationsEndpointAttachmentsCreateCall { c.urlParams_.Set("fields", googleapi.CombineFields(s)) return c } @@ -5755,21 +8111,21 @@ func (c *ProjectsLocationsConnectionsConnectionSchemaMetadataRefreshCall) Fields // 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 *ProjectsLocationsConnectionsConnectionSchemaMetadataRefreshCall) Context(ctx context.Context) *ProjectsLocationsConnectionsConnectionSchemaMetadataRefreshCall { +func (c *ProjectsLocationsEndpointAttachmentsCreateCall) Context(ctx context.Context) *ProjectsLocationsEndpointAttachmentsCreateCall { 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 *ProjectsLocationsConnectionsConnectionSchemaMetadataRefreshCall) Header() http.Header { +func (c *ProjectsLocationsEndpointAttachmentsCreateCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) } return c.header_ } -func (c *ProjectsLocationsConnectionsConnectionSchemaMetadataRefreshCall) doRequest(alt string) (*http.Response, error) { +func (c *ProjectsLocationsEndpointAttachmentsCreateCall) 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_ { @@ -5777,14 +8133,14 @@ func (c *ProjectsLocationsConnectionsConnectionSchemaMetadataRefreshCall) doRequ } reqHeaders.Set("User-Agent", c.s.userAgent()) var body io.Reader = nil - body, err := googleapi.WithoutDataWrapper.JSONReader(c.refreshconnectionschemametadatarequest) + body, err := googleapi.WithoutDataWrapper.JSONReader(c.endpointattachment) if err != nil { return nil, err } reqHeaders.Set("Content-Type", "application/json") c.urlParams_.Set("alt", alt) c.urlParams_.Set("prettyPrint", "false") - urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+name}:refresh") + urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+parent}/endpointAttachments") urls += "?" + c.urlParams_.Encode() req, err := http.NewRequest("POST", urls, body) if err != nil { @@ -5792,19 +8148,19 @@ func (c *ProjectsLocationsConnectionsConnectionSchemaMetadataRefreshCall) doRequ } req.Header = reqHeaders googleapi.Expand(req.URL, map[string]string{ - "name": c.name, + "parent": c.parent, }) return gensupport.SendRequest(c.ctx_, c.s.client, req) } -// Do executes the "connectors.projects.locations.connections.connectionSchemaMetadata.refresh" call. +// Do executes the "connectors.projects.locations.endpointAttachments.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 *ProjectsLocationsConnectionsConnectionSchemaMetadataRefreshCall) Do(opts ...googleapi.CallOption) (*Operation, error) { +func (c *ProjectsLocationsEndpointAttachmentsCreateCall) Do(opts ...googleapi.CallOption) (*Operation, error) { gensupport.SetOptions(c.urlParams_, opts...) res, err := c.doRequest("json") if res != nil && res.StatusCode == http.StatusNotModified { @@ -5835,25 +8191,30 @@ func (c *ProjectsLocationsConnectionsConnectionSchemaMetadataRefreshCall) Do(opt } return ret, nil // { - // "description": "Refresh runtime schema of a connection.", - // "flatPath": "v1/projects/{projectsId}/locations/{locationsId}/connections/{connectionsId}/connectionSchemaMetadata:refresh", + // "description": "Creates a new EndpointAttachment in a given project and location.", + // "flatPath": "v1/projects/{projectsId}/locations/{locationsId}/endpointAttachments", // "httpMethod": "POST", - // "id": "connectors.projects.locations.connections.connectionSchemaMetadata.refresh", + // "id": "connectors.projects.locations.endpointAttachments.create", // "parameterOrder": [ - // "name" + // "parent" // ], // "parameters": { - // "name": { - // "description": "Required. Resource name. Format: projects/{project}/locations/{location}/connections/{connection}/connectionSchemaMetadata", + // "endpointAttachmentId": { + // "description": "Required. Identifier to assign to the EndpointAttachment. Must be unique within scope of the parent resource.", + // "location": "query", + // "type": "string" + // }, + // "parent": { + // "description": "Required. Parent resource of the EndpointAttachment, of the form: `projects/*/locations/*`", // "location": "path", - // "pattern": "^projects/[^/]+/locations/[^/]+/connections/[^/]+/connectionSchemaMetadata$", + // "pattern": "^projects/[^/]+/locations/[^/]+$", // "required": true, // "type": "string" // } // }, - // "path": "v1/{+name}:refresh", + // "path": "v1/{+parent}/endpointAttachments", // "request": { - // "$ref": "RefreshConnectionSchemaMetadataRequest" + // "$ref": "EndpointAttachment" // }, // "response": { // "$ref": "Operation" @@ -5865,117 +8226,82 @@ func (c *ProjectsLocationsConnectionsConnectionSchemaMetadataRefreshCall) Do(opt } -// method id "connectors.projects.locations.connections.runtimeActionSchemas.list": +// method id "connectors.projects.locations.endpointAttachments.delete": -type ProjectsLocationsConnectionsRuntimeActionSchemasListCall struct { - s *Service - parent string - urlParams_ gensupport.URLParams - ifNoneMatch_ string - ctx_ context.Context - header_ http.Header +type ProjectsLocationsEndpointAttachmentsDeleteCall struct { + s *Service + name string + urlParams_ gensupport.URLParams + ctx_ context.Context + header_ http.Header } -// List: List schema of a runtime actions filtered by action name. +// Delete: Deletes a single EndpointAttachment. // -// - parent: Parent resource of RuntimeActionSchema Format: -// projects/{project}/locations/{location}/connections/{connection}. -func (r *ProjectsLocationsConnectionsRuntimeActionSchemasService) List(parent string) *ProjectsLocationsConnectionsRuntimeActionSchemasListCall { - c := &ProjectsLocationsConnectionsRuntimeActionSchemasListCall{s: r.s, urlParams_: make(gensupport.URLParams)} - c.parent = parent - return c -} - -// Filter sets the optional parameter "filter": Required. Filter Format: -// action="{actionId}" Only action field is supported with literal -// equality operator. Accepted filter example: action="CancelOrder" -// Wildcards are not supported in the filter currently. -func (c *ProjectsLocationsConnectionsRuntimeActionSchemasListCall) Filter(filter string) *ProjectsLocationsConnectionsRuntimeActionSchemasListCall { - c.urlParams_.Set("filter", filter) - return c -} - -// PageSize sets the optional parameter "pageSize": Page size. -func (c *ProjectsLocationsConnectionsRuntimeActionSchemasListCall) PageSize(pageSize int64) *ProjectsLocationsConnectionsRuntimeActionSchemasListCall { - c.urlParams_.Set("pageSize", fmt.Sprint(pageSize)) - return c -} - -// PageToken sets the optional parameter "pageToken": Page token. -func (c *ProjectsLocationsConnectionsRuntimeActionSchemasListCall) PageToken(pageToken string) *ProjectsLocationsConnectionsRuntimeActionSchemasListCall { - c.urlParams_.Set("pageToken", pageToken) +// - name: Resource name of the form: +// `projects/*/locations/*/endpointAttachments/*`. +func (r *ProjectsLocationsEndpointAttachmentsService) Delete(name string) *ProjectsLocationsEndpointAttachmentsDeleteCall { + c := &ProjectsLocationsEndpointAttachmentsDeleteCall{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 *ProjectsLocationsConnectionsRuntimeActionSchemasListCall) Fields(s ...googleapi.Field) *ProjectsLocationsConnectionsRuntimeActionSchemasListCall { +func (c *ProjectsLocationsEndpointAttachmentsDeleteCall) Fields(s ...googleapi.Field) *ProjectsLocationsEndpointAttachmentsDeleteCall { 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 *ProjectsLocationsConnectionsRuntimeActionSchemasListCall) IfNoneMatch(entityTag string) *ProjectsLocationsConnectionsRuntimeActionSchemasListCall { - 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 *ProjectsLocationsConnectionsRuntimeActionSchemasListCall) Context(ctx context.Context) *ProjectsLocationsConnectionsRuntimeActionSchemasListCall { +func (c *ProjectsLocationsEndpointAttachmentsDeleteCall) Context(ctx context.Context) *ProjectsLocationsEndpointAttachmentsDeleteCall { 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 *ProjectsLocationsConnectionsRuntimeActionSchemasListCall) Header() http.Header { +func (c *ProjectsLocationsEndpointAttachmentsDeleteCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) } return c.header_ } -func (c *ProjectsLocationsConnectionsRuntimeActionSchemasListCall) doRequest(alt string) (*http.Response, error) { +func (c *ProjectsLocationsEndpointAttachmentsDeleteCall) doRequest(alt string) (*http.Response, error) { reqHeaders := make(http.Header) reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version) for k, v := range c.header_ { reqHeaders[k] = v } reqHeaders.Set("User-Agent", c.s.userAgent()) - if c.ifNoneMatch_ != "" { - reqHeaders.Set("If-None-Match", c.ifNoneMatch_) - } var body io.Reader = nil c.urlParams_.Set("alt", alt) c.urlParams_.Set("prettyPrint", "false") - urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+parent}/runtimeActionSchemas") + urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+name}") urls += "?" + c.urlParams_.Encode() - req, err := http.NewRequest("GET", urls, body) + req, err := http.NewRequest("DELETE", 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 "connectors.projects.locations.connections.runtimeActionSchemas.list" call. -// Exactly one of *ListRuntimeActionSchemasResponse or error will be -// non-nil. Any non-2xx status code is an error. Response headers are in -// either *ListRuntimeActionSchemasResponse.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 *ProjectsLocationsConnectionsRuntimeActionSchemasListCall) Do(opts ...googleapi.CallOption) (*ListRuntimeActionSchemasResponse, error) { +// Do executes the "connectors.projects.locations.endpointAttachments.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 *ProjectsLocationsEndpointAttachmentsDeleteCall) Do(opts ...googleapi.CallOption) (*Operation, error) { gensupport.SetOptions(c.urlParams_, opts...) res, err := c.doRequest("json") if res != nil && res.StatusCode == http.StatusNotModified { @@ -5994,7 +8320,7 @@ func (c *ProjectsLocationsConnectionsRuntimeActionSchemasListCall) Do(opts ...go if err := googleapi.CheckResponse(res); err != nil { return nil, gensupport.WrapError(err) } - ret := &ListRuntimeActionSchemasResponse{ + ret := &Operation{ ServerResponse: googleapi.ServerResponse{ Header: res.Header, HTTPStatusCode: res.StatusCode, @@ -6003,44 +8329,28 @@ func (c *ProjectsLocationsConnectionsRuntimeActionSchemasListCall) Do(opts ...go target := &ret if err := gensupport.DecodeResponse(target, res); err != nil { return nil, err - } - return ret, nil - // { - // "description": "List schema of a runtime actions filtered by action name.", - // "flatPath": "v1/projects/{projectsId}/locations/{locationsId}/connections/{connectionsId}/runtimeActionSchemas", - // "httpMethod": "GET", - // "id": "connectors.projects.locations.connections.runtimeActionSchemas.list", - // "parameterOrder": [ - // "parent" - // ], - // "parameters": { - // "filter": { - // "description": "Required. Filter Format: action=\"{actionId}\" Only action field is supported with literal equality operator. Accepted filter example: action=\"CancelOrder\" Wildcards are not supported in the filter currently.", - // "location": "query", - // "type": "string" - // }, - // "pageSize": { - // "description": "Page size.", - // "format": "int32", - // "location": "query", - // "type": "integer" - // }, - // "pageToken": { - // "description": "Page token.", - // "location": "query", - // "type": "string" - // }, - // "parent": { - // "description": "Required. Parent resource of RuntimeActionSchema Format: projects/{project}/locations/{location}/connections/{connection}", + } + return ret, nil + // { + // "description": "Deletes a single EndpointAttachment.", + // "flatPath": "v1/projects/{projectsId}/locations/{locationsId}/endpointAttachments/{endpointAttachmentsId}", + // "httpMethod": "DELETE", + // "id": "connectors.projects.locations.endpointAttachments.delete", + // "parameterOrder": [ + // "name" + // ], + // "parameters": { + // "name": { + // "description": "Required. Resource name of the form: `projects/*/locations/*/endpointAttachments/*`", // "location": "path", - // "pattern": "^projects/[^/]+/locations/[^/]+/connections/[^/]+$", + // "pattern": "^projects/[^/]+/locations/[^/]+/endpointAttachments/[^/]+$", // "required": true, // "type": "string" // } // }, - // "path": "v1/{+parent}/runtimeActionSchemas", + // "path": "v1/{+name}", // "response": { - // "$ref": "ListRuntimeActionSchemasResponse" + // "$ref": "Operation" // }, // "scopes": [ // "https://www.googleapis.com/auth/cloud-platform" @@ -6049,73 +8359,31 @@ func (c *ProjectsLocationsConnectionsRuntimeActionSchemasListCall) Do(opts ...go } -// 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 *ProjectsLocationsConnectionsRuntimeActionSchemasListCall) Pages(ctx context.Context, f func(*ListRuntimeActionSchemasResponse) 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 "connectors.projects.locations.connections.runtimeEntitySchemas.list": +// method id "connectors.projects.locations.endpointAttachments.get": -type ProjectsLocationsConnectionsRuntimeEntitySchemasListCall struct { +type ProjectsLocationsEndpointAttachmentsGetCall struct { s *Service - parent string + name string urlParams_ gensupport.URLParams ifNoneMatch_ string ctx_ context.Context header_ http.Header } -// List: List schema of a runtime entities filtered by entity name. +// Get: Gets details of a single EndpointAttachment. // -// - parent: Parent resource of RuntimeEntitySchema Format: -// projects/{project}/locations/{location}/connections/{connection}. -func (r *ProjectsLocationsConnectionsRuntimeEntitySchemasService) List(parent string) *ProjectsLocationsConnectionsRuntimeEntitySchemasListCall { - c := &ProjectsLocationsConnectionsRuntimeEntitySchemasListCall{s: r.s, urlParams_: make(gensupport.URLParams)} - c.parent = parent - return c -} - -// Filter sets the optional parameter "filter": Required. Filter Format: -// entity="{entityId}" Only entity field is supported with literal -// equality operator. Accepted filter example: entity="Order" Wildcards -// are not supported in the filter currently. -func (c *ProjectsLocationsConnectionsRuntimeEntitySchemasListCall) Filter(filter string) *ProjectsLocationsConnectionsRuntimeEntitySchemasListCall { - c.urlParams_.Set("filter", filter) - return c -} - -// PageSize sets the optional parameter "pageSize": Page size. -func (c *ProjectsLocationsConnectionsRuntimeEntitySchemasListCall) PageSize(pageSize int64) *ProjectsLocationsConnectionsRuntimeEntitySchemasListCall { - c.urlParams_.Set("pageSize", fmt.Sprint(pageSize)) - return c -} - -// PageToken sets the optional parameter "pageToken": Page token. -func (c *ProjectsLocationsConnectionsRuntimeEntitySchemasListCall) PageToken(pageToken string) *ProjectsLocationsConnectionsRuntimeEntitySchemasListCall { - c.urlParams_.Set("pageToken", pageToken) +// - name: Resource name of the form: +// `projects/*/locations/*/endpointAttachments/*`. +func (r *ProjectsLocationsEndpointAttachmentsService) Get(name string) *ProjectsLocationsEndpointAttachmentsGetCall { + c := &ProjectsLocationsEndpointAttachmentsGetCall{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 *ProjectsLocationsConnectionsRuntimeEntitySchemasListCall) Fields(s ...googleapi.Field) *ProjectsLocationsConnectionsRuntimeEntitySchemasListCall { +func (c *ProjectsLocationsEndpointAttachmentsGetCall) Fields(s ...googleapi.Field) *ProjectsLocationsEndpointAttachmentsGetCall { c.urlParams_.Set("fields", googleapi.CombineFields(s)) return c } @@ -6125,7 +8393,7 @@ func (c *ProjectsLocationsConnectionsRuntimeEntitySchemasListCall) Fields(s ...g // 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 *ProjectsLocationsConnectionsRuntimeEntitySchemasListCall) IfNoneMatch(entityTag string) *ProjectsLocationsConnectionsRuntimeEntitySchemasListCall { +func (c *ProjectsLocationsEndpointAttachmentsGetCall) IfNoneMatch(entityTag string) *ProjectsLocationsEndpointAttachmentsGetCall { c.ifNoneMatch_ = entityTag return c } @@ -6133,21 +8401,21 @@ func (c *ProjectsLocationsConnectionsRuntimeEntitySchemasListCall) IfNoneMatch(e // 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 *ProjectsLocationsConnectionsRuntimeEntitySchemasListCall) Context(ctx context.Context) *ProjectsLocationsConnectionsRuntimeEntitySchemasListCall { +func (c *ProjectsLocationsEndpointAttachmentsGetCall) Context(ctx context.Context) *ProjectsLocationsEndpointAttachmentsGetCall { 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 *ProjectsLocationsConnectionsRuntimeEntitySchemasListCall) Header() http.Header { +func (c *ProjectsLocationsEndpointAttachmentsGetCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) } return c.header_ } -func (c *ProjectsLocationsConnectionsRuntimeEntitySchemasListCall) doRequest(alt string) (*http.Response, error) { +func (c *ProjectsLocationsEndpointAttachmentsGetCall) 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_ { @@ -6160,7 +8428,7 @@ func (c *ProjectsLocationsConnectionsRuntimeEntitySchemasListCall) doRequest(alt var body io.Reader = nil c.urlParams_.Set("alt", alt) c.urlParams_.Set("prettyPrint", "false") - urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+parent}/runtimeEntitySchemas") + urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+name}") urls += "?" + c.urlParams_.Encode() req, err := http.NewRequest("GET", urls, body) if err != nil { @@ -6168,19 +8436,19 @@ func (c *ProjectsLocationsConnectionsRuntimeEntitySchemasListCall) doRequest(alt } 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 "connectors.projects.locations.connections.runtimeEntitySchemas.list" call. -// Exactly one of *ListRuntimeEntitySchemasResponse or error will be -// non-nil. Any non-2xx status code is an error. Response headers are in -// either *ListRuntimeEntitySchemasResponse.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 "connectors.projects.locations.endpointAttachments.get" call. +// Exactly one of *EndpointAttachment or error will be non-nil. Any +// non-2xx status code is an error. Response headers are in either +// *EndpointAttachment.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 *ProjectsLocationsConnectionsRuntimeEntitySchemasListCall) Do(opts ...googleapi.CallOption) (*ListRuntimeEntitySchemasResponse, error) { +func (c *ProjectsLocationsEndpointAttachmentsGetCall) Do(opts ...googleapi.CallOption) (*EndpointAttachment, error) { gensupport.SetOptions(c.urlParams_, opts...) res, err := c.doRequest("json") if res != nil && res.StatusCode == http.StatusNotModified { @@ -6199,7 +8467,7 @@ func (c *ProjectsLocationsConnectionsRuntimeEntitySchemasListCall) Do(opts ...go if err := googleapi.CheckResponse(res); err != nil { return nil, gensupport.WrapError(err) } - ret := &ListRuntimeEntitySchemasResponse{ + ret := &EndpointAttachment{ ServerResponse: googleapi.ServerResponse{ Header: res.Header, HTTPStatusCode: res.StatusCode, @@ -6211,41 +8479,25 @@ func (c *ProjectsLocationsConnectionsRuntimeEntitySchemasListCall) Do(opts ...go } return ret, nil // { - // "description": "List schema of a runtime entities filtered by entity name.", - // "flatPath": "v1/projects/{projectsId}/locations/{locationsId}/connections/{connectionsId}/runtimeEntitySchemas", + // "description": "Gets details of a single EndpointAttachment.", + // "flatPath": "v1/projects/{projectsId}/locations/{locationsId}/endpointAttachments/{endpointAttachmentsId}", // "httpMethod": "GET", - // "id": "connectors.projects.locations.connections.runtimeEntitySchemas.list", + // "id": "connectors.projects.locations.endpointAttachments.get", // "parameterOrder": [ - // "parent" + // "name" // ], // "parameters": { - // "filter": { - // "description": "Required. Filter Format: entity=\"{entityId}\" Only entity field is supported with literal equality operator. Accepted filter example: entity=\"Order\" Wildcards are not supported in the filter currently.", - // "location": "query", - // "type": "string" - // }, - // "pageSize": { - // "description": "Page size.", - // "format": "int32", - // "location": "query", - // "type": "integer" - // }, - // "pageToken": { - // "description": "Page token.", - // "location": "query", - // "type": "string" - // }, - // "parent": { - // "description": "Required. Parent resource of RuntimeEntitySchema Format: projects/{project}/locations/{location}/connections/{connection}", + // "name": { + // "description": "Required. Resource name of the form: `projects/*/locations/*/endpointAttachments/*`", // "location": "path", - // "pattern": "^projects/[^/]+/locations/[^/]+/connections/[^/]+$", + // "pattern": "^projects/[^/]+/locations/[^/]+/endpointAttachments/[^/]+$", // "required": true, // "type": "string" // } // }, - // "path": "v1/{+parent}/runtimeEntitySchemas", + // "path": "v1/{+name}", // "response": { - // "$ref": "ListRuntimeEntitySchemasResponse" + // "$ref": "EndpointAttachment" // }, // "scopes": [ // "https://www.googleapis.com/auth/cloud-platform" @@ -6254,102 +8506,103 @@ func (c *ProjectsLocationsConnectionsRuntimeEntitySchemasListCall) Do(opts ...go } -// 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 *ProjectsLocationsConnectionsRuntimeEntitySchemasListCall) Pages(ctx context.Context, f func(*ListRuntimeEntitySchemasResponse) 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 "connectors.projects.locations.endpointAttachments.create": +// method id "connectors.projects.locations.endpointAttachments.list": -type ProjectsLocationsEndpointAttachmentsCreateCall struct { - s *Service - parent string - endpointattachment *EndpointAttachment - urlParams_ gensupport.URLParams - ctx_ context.Context - header_ http.Header +type ProjectsLocationsEndpointAttachmentsListCall struct { + s *Service + parent string + urlParams_ gensupport.URLParams + ifNoneMatch_ string + ctx_ context.Context + header_ http.Header } -// Create: Creates a new EndpointAttachment in a given project and -// location. +// List: List EndpointAttachments in a given project // -// - parent: Parent resource of the EndpointAttachment, of the form: +// - parent: Parent resource od the EndpointAttachment, of the form: // `projects/*/locations/*`. -func (r *ProjectsLocationsEndpointAttachmentsService) Create(parent string, endpointattachment *EndpointAttachment) *ProjectsLocationsEndpointAttachmentsCreateCall { - c := &ProjectsLocationsEndpointAttachmentsCreateCall{s: r.s, urlParams_: make(gensupport.URLParams)} +func (r *ProjectsLocationsEndpointAttachmentsService) List(parent string) *ProjectsLocationsEndpointAttachmentsListCall { + c := &ProjectsLocationsEndpointAttachmentsListCall{s: r.s, urlParams_: make(gensupport.URLParams)} c.parent = parent - c.endpointattachment = endpointattachment return c } -// EndpointAttachmentId sets the optional parameter -// "endpointAttachmentId": Required. Identifier to assign to the -// EndpointAttachment. Must be unique within scope of the parent -// resource. -func (c *ProjectsLocationsEndpointAttachmentsCreateCall) EndpointAttachmentId(endpointAttachmentId string) *ProjectsLocationsEndpointAttachmentsCreateCall { - c.urlParams_.Set("endpointAttachmentId", endpointAttachmentId) +// Filter sets the optional parameter "filter": Filter. +// https://g3doc.corp.google.com/cloud/control2/g3doc/dev/apihosting/list_filtering.md#filtering. +func (c *ProjectsLocationsEndpointAttachmentsListCall) Filter(filter string) *ProjectsLocationsEndpointAttachmentsListCall { + c.urlParams_.Set("filter", filter) + return c +} + +// OrderBy sets the optional parameter "orderBy": Order by parameters. +func (c *ProjectsLocationsEndpointAttachmentsListCall) OrderBy(orderBy string) *ProjectsLocationsEndpointAttachmentsListCall { + c.urlParams_.Set("orderBy", orderBy) + return c +} + +// PageSize sets the optional parameter "pageSize": Page size. +func (c *ProjectsLocationsEndpointAttachmentsListCall) PageSize(pageSize int64) *ProjectsLocationsEndpointAttachmentsListCall { + c.urlParams_.Set("pageSize", fmt.Sprint(pageSize)) + return c +} + +// PageToken sets the optional parameter "pageToken": Page token. +func (c *ProjectsLocationsEndpointAttachmentsListCall) PageToken(pageToken string) *ProjectsLocationsEndpointAttachmentsListCall { + 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 *ProjectsLocationsEndpointAttachmentsCreateCall) Fields(s ...googleapi.Field) *ProjectsLocationsEndpointAttachmentsCreateCall { +func (c *ProjectsLocationsEndpointAttachmentsListCall) Fields(s ...googleapi.Field) *ProjectsLocationsEndpointAttachmentsListCall { 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 *ProjectsLocationsEndpointAttachmentsListCall) IfNoneMatch(entityTag string) *ProjectsLocationsEndpointAttachmentsListCall { + 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 *ProjectsLocationsEndpointAttachmentsCreateCall) Context(ctx context.Context) *ProjectsLocationsEndpointAttachmentsCreateCall { +func (c *ProjectsLocationsEndpointAttachmentsListCall) Context(ctx context.Context) *ProjectsLocationsEndpointAttachmentsListCall { 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 *ProjectsLocationsEndpointAttachmentsCreateCall) Header() http.Header { +func (c *ProjectsLocationsEndpointAttachmentsListCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) } return c.header_ } -func (c *ProjectsLocationsEndpointAttachmentsCreateCall) doRequest(alt string) (*http.Response, error) { +func (c *ProjectsLocationsEndpointAttachmentsListCall) 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.endpointattachment) - 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, "v1/{+parent}/endpointAttachments") urls += "?" + c.urlParams_.Encode() - req, err := http.NewRequest("POST", urls, body) + req, err := http.NewRequest("GET", urls, body) if err != nil { return nil, err } @@ -6358,16 +8611,16 @@ func (c *ProjectsLocationsEndpointAttachmentsCreateCall) doRequest(alt string) ( "parent": c.parent, }) return gensupport.SendRequest(c.ctx_, c.s.client, req) -} - -// Do executes the "connectors.projects.locations.endpointAttachments.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 *ProjectsLocationsEndpointAttachmentsCreateCall) Do(opts ...googleapi.CallOption) (*Operation, error) { +} + +// Do executes the "connectors.projects.locations.endpointAttachments.list" call. +// Exactly one of *ListEndpointAttachmentsResponse or error will be +// non-nil. Any non-2xx status code is an error. Response headers are in +// either *ListEndpointAttachmentsResponse.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 *ProjectsLocationsEndpointAttachmentsListCall) Do(opts ...googleapi.CallOption) (*ListEndpointAttachmentsResponse, error) { gensupport.SetOptions(c.urlParams_, opts...) res, err := c.doRequest("json") if res != nil && res.StatusCode == http.StatusNotModified { @@ -6386,7 +8639,7 @@ func (c *ProjectsLocationsEndpointAttachmentsCreateCall) Do(opts ...googleapi.Ca if err := googleapi.CheckResponse(res); err != nil { return nil, gensupport.WrapError(err) } - ret := &Operation{ + ret := &ListEndpointAttachmentsResponse{ ServerResponse: googleapi.ServerResponse{ Header: res.Header, HTTPStatusCode: res.StatusCode, @@ -6398,21 +8651,37 @@ func (c *ProjectsLocationsEndpointAttachmentsCreateCall) Do(opts ...googleapi.Ca } return ret, nil // { - // "description": "Creates a new EndpointAttachment in a given project and location.", + // "description": "List EndpointAttachments in a given project", // "flatPath": "v1/projects/{projectsId}/locations/{locationsId}/endpointAttachments", - // "httpMethod": "POST", - // "id": "connectors.projects.locations.endpointAttachments.create", + // "httpMethod": "GET", + // "id": "connectors.projects.locations.endpointAttachments.list", // "parameterOrder": [ // "parent" // ], // "parameters": { - // "endpointAttachmentId": { - // "description": "Required. Identifier to assign to the EndpointAttachment. Must be unique within scope of the parent resource.", + // "filter": { + // "description": "Filter. https://g3doc.corp.google.com/cloud/control2/g3doc/dev/apihosting/list_filtering.md#filtering.", + // "location": "query", + // "type": "string" + // }, + // "orderBy": { + // "description": "Order by parameters.", + // "location": "query", + // "type": "string" + // }, + // "pageSize": { + // "description": "Page size.", + // "format": "int32", + // "location": "query", + // "type": "integer" + // }, + // "pageToken": { + // "description": "Page token.", // "location": "query", // "type": "string" // }, // "parent": { - // "description": "Required. Parent resource of the EndpointAttachment, of the form: `projects/*/locations/*`", + // "description": "Required. Parent resource od the EndpointAttachment, of the form: `projects/*/locations/*`", // "location": "path", // "pattern": "^projects/[^/]+/locations/[^/]+$", // "required": true, @@ -6420,11 +8689,8 @@ func (c *ProjectsLocationsEndpointAttachmentsCreateCall) Do(opts ...googleapi.Ca // } // }, // "path": "v1/{+parent}/endpointAttachments", - // "request": { - // "$ref": "EndpointAttachment" - // }, // "response": { - // "$ref": "Operation" + // "$ref": "ListEndpointAttachmentsResponse" // }, // "scopes": [ // "https://www.googleapis.com/auth/cloud-platform" @@ -6433,30 +8699,65 @@ func (c *ProjectsLocationsEndpointAttachmentsCreateCall) Do(opts ...googleapi.Ca } -// method id "connectors.projects.locations.endpointAttachments.delete": +// 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 *ProjectsLocationsEndpointAttachmentsListCall) Pages(ctx context.Context, f func(*ListEndpointAttachmentsResponse) 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 ProjectsLocationsEndpointAttachmentsDeleteCall struct { - s *Service - name string - urlParams_ gensupport.URLParams - ctx_ context.Context - header_ http.Header +// method id "connectors.projects.locations.endpointAttachments.patch": + +type ProjectsLocationsEndpointAttachmentsPatchCall struct { + s *Service + name string + endpointattachment *EndpointAttachment + urlParams_ gensupport.URLParams + ctx_ context.Context + header_ http.Header } -// Delete: Deletes a single EndpointAttachment. +// Patch: Updates the parameters of a single EndpointAttachment. // -// - name: Resource name of the form: -// `projects/*/locations/*/endpointAttachments/*`. -func (r *ProjectsLocationsEndpointAttachmentsService) Delete(name string) *ProjectsLocationsEndpointAttachmentsDeleteCall { - c := &ProjectsLocationsEndpointAttachmentsDeleteCall{s: r.s, urlParams_: make(gensupport.URLParams)} +// - name: Output only. Resource name of the Endpoint Attachment. +// Format: +// projects/{project}/locations/{location}/endpointAttachments/{endpoin +// t_attachment}. +func (r *ProjectsLocationsEndpointAttachmentsService) Patch(name string, endpointattachment *EndpointAttachment) *ProjectsLocationsEndpointAttachmentsPatchCall { + c := &ProjectsLocationsEndpointAttachmentsPatchCall{s: r.s, urlParams_: make(gensupport.URLParams)} c.name = name + c.endpointattachment = endpointattachment + return c +} + +// UpdateMask sets the optional parameter "updateMask": Required. The +// list of fields to update. Fields are specified relative to the +// endpointAttachment. A field will be overwritten if it is in the mask. +// You can modify only the fields listed below. To update the +// endpointAttachment details: * `description` * `labels` +func (c *ProjectsLocationsEndpointAttachmentsPatchCall) UpdateMask(updateMask string) *ProjectsLocationsEndpointAttachmentsPatchCall { + 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 *ProjectsLocationsEndpointAttachmentsDeleteCall) Fields(s ...googleapi.Field) *ProjectsLocationsEndpointAttachmentsDeleteCall { +func (c *ProjectsLocationsEndpointAttachmentsPatchCall) Fields(s ...googleapi.Field) *ProjectsLocationsEndpointAttachmentsPatchCall { c.urlParams_.Set("fields", googleapi.CombineFields(s)) return c } @@ -6464,21 +8765,21 @@ func (c *ProjectsLocationsEndpointAttachmentsDeleteCall) Fields(s ...googleapi.F // 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 *ProjectsLocationsEndpointAttachmentsDeleteCall) Context(ctx context.Context) *ProjectsLocationsEndpointAttachmentsDeleteCall { +func (c *ProjectsLocationsEndpointAttachmentsPatchCall) Context(ctx context.Context) *ProjectsLocationsEndpointAttachmentsPatchCall { 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 *ProjectsLocationsEndpointAttachmentsDeleteCall) Header() http.Header { +func (c *ProjectsLocationsEndpointAttachmentsPatchCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) } return c.header_ } -func (c *ProjectsLocationsEndpointAttachmentsDeleteCall) doRequest(alt string) (*http.Response, error) { +func (c *ProjectsLocationsEndpointAttachmentsPatchCall) 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_ { @@ -6486,11 +8787,16 @@ func (c *ProjectsLocationsEndpointAttachmentsDeleteCall) doRequest(alt string) ( } reqHeaders.Set("User-Agent", c.s.userAgent()) var body io.Reader = nil + body, err := googleapi.WithoutDataWrapper.JSONReader(c.endpointattachment) + if err != nil { + return nil, err + } + reqHeaders.Set("Content-Type", "application/json") c.urlParams_.Set("alt", alt) c.urlParams_.Set("prettyPrint", "false") urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+name}") urls += "?" + c.urlParams_.Encode() - req, err := http.NewRequest("DELETE", urls, body) + req, err := http.NewRequest("PATCH", urls, body) if err != nil { return nil, err } @@ -6501,14 +8807,14 @@ func (c *ProjectsLocationsEndpointAttachmentsDeleteCall) doRequest(alt string) ( return gensupport.SendRequest(c.ctx_, c.s.client, req) } -// Do executes the "connectors.projects.locations.endpointAttachments.delete" call. +// Do executes the "connectors.projects.locations.endpointAttachments.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 *ProjectsLocationsEndpointAttachmentsDeleteCall) Do(opts ...googleapi.CallOption) (*Operation, error) { +func (c *ProjectsLocationsEndpointAttachmentsPatchCall) Do(opts ...googleapi.CallOption) (*Operation, error) { gensupport.SetOptions(c.urlParams_, opts...) res, err := c.doRequest("json") if res != nil && res.StatusCode == http.StatusNotModified { @@ -6539,23 +8845,32 @@ func (c *ProjectsLocationsEndpointAttachmentsDeleteCall) Do(opts ...googleapi.Ca } return ret, nil // { - // "description": "Deletes a single EndpointAttachment.", + // "description": "Updates the parameters of a single EndpointAttachment.", // "flatPath": "v1/projects/{projectsId}/locations/{locationsId}/endpointAttachments/{endpointAttachmentsId}", - // "httpMethod": "DELETE", - // "id": "connectors.projects.locations.endpointAttachments.delete", + // "httpMethod": "PATCH", + // "id": "connectors.projects.locations.endpointAttachments.patch", // "parameterOrder": [ // "name" // ], // "parameters": { // "name": { - // "description": "Required. Resource name of the form: `projects/*/locations/*/endpointAttachments/*`", + // "description": "Output only. Resource name of the Endpoint Attachment. Format: projects/{project}/locations/{location}/endpointAttachments/{endpoint_attachment}", // "location": "path", // "pattern": "^projects/[^/]+/locations/[^/]+/endpointAttachments/[^/]+$", // "required": true, // "type": "string" + // }, + // "updateMask": { + // "description": "Required. The list of fields to update. Fields are specified relative to the endpointAttachment. A field will be overwritten if it is in the mask. You can modify only the fields listed below. To update the endpointAttachment details: * `description` * `labels`", + // "format": "google-fieldmask", + // "location": "query", + // "type": "string" // } // }, // "path": "v1/{+name}", + // "request": { + // "$ref": "EndpointAttachment" + // }, // "response": { // "$ref": "Operation" // }, @@ -6566,9 +8881,9 @@ func (c *ProjectsLocationsEndpointAttachmentsDeleteCall) Do(opts ...googleapi.Ca } -// method id "connectors.projects.locations.endpointAttachments.get": +// method id "connectors.projects.locations.global.getSettings": -type ProjectsLocationsEndpointAttachmentsGetCall struct { +type ProjectsLocationsGlobalGetSettingsCall struct { s *Service name string urlParams_ gensupport.URLParams @@ -6577,12 +8892,12 @@ type ProjectsLocationsEndpointAttachmentsGetCall struct { header_ http.Header } -// Get: Gets details of a single EndpointAttachment. +// GetSettings: GetGlobalSettings gets settings of a project. +// GlobalSettings is a singleton resource. // -// - name: Resource name of the form: -// `projects/*/locations/*/endpointAttachments/*`. -func (r *ProjectsLocationsEndpointAttachmentsService) Get(name string) *ProjectsLocationsEndpointAttachmentsGetCall { - c := &ProjectsLocationsEndpointAttachmentsGetCall{s: r.s, urlParams_: make(gensupport.URLParams)} +// - name: The resource name of the Settings. +func (r *ProjectsLocationsGlobalService) GetSettings(name string) *ProjectsLocationsGlobalGetSettingsCall { + c := &ProjectsLocationsGlobalGetSettingsCall{s: r.s, urlParams_: make(gensupport.URLParams)} c.name = name return c } @@ -6590,7 +8905,7 @@ func (r *ProjectsLocationsEndpointAttachmentsService) Get(name string) *Projects // Fields allows partial responses to be retrieved. See // https://developers.google.com/gdata/docs/2.0/basics#PartialResponse // for more information. -func (c *ProjectsLocationsEndpointAttachmentsGetCall) Fields(s ...googleapi.Field) *ProjectsLocationsEndpointAttachmentsGetCall { +func (c *ProjectsLocationsGlobalGetSettingsCall) Fields(s ...googleapi.Field) *ProjectsLocationsGlobalGetSettingsCall { c.urlParams_.Set("fields", googleapi.CombineFields(s)) return c } @@ -6600,7 +8915,7 @@ func (c *ProjectsLocationsEndpointAttachmentsGetCall) Fields(s ...googleapi.Fiel // 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 *ProjectsLocationsEndpointAttachmentsGetCall) IfNoneMatch(entityTag string) *ProjectsLocationsEndpointAttachmentsGetCall { +func (c *ProjectsLocationsGlobalGetSettingsCall) IfNoneMatch(entityTag string) *ProjectsLocationsGlobalGetSettingsCall { c.ifNoneMatch_ = entityTag return c } @@ -6608,21 +8923,21 @@ func (c *ProjectsLocationsEndpointAttachmentsGetCall) IfNoneMatch(entityTag stri // 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 *ProjectsLocationsEndpointAttachmentsGetCall) Context(ctx context.Context) *ProjectsLocationsEndpointAttachmentsGetCall { +func (c *ProjectsLocationsGlobalGetSettingsCall) Context(ctx context.Context) *ProjectsLocationsGlobalGetSettingsCall { 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 *ProjectsLocationsEndpointAttachmentsGetCall) Header() http.Header { +func (c *ProjectsLocationsGlobalGetSettingsCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) } return c.header_ } -func (c *ProjectsLocationsEndpointAttachmentsGetCall) doRequest(alt string) (*http.Response, error) { +func (c *ProjectsLocationsGlobalGetSettingsCall) 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_ { @@ -6648,14 +8963,14 @@ func (c *ProjectsLocationsEndpointAttachmentsGetCall) doRequest(alt string) (*ht return gensupport.SendRequest(c.ctx_, c.s.client, req) } -// Do executes the "connectors.projects.locations.endpointAttachments.get" call. -// Exactly one of *EndpointAttachment or error will be non-nil. Any -// non-2xx status code is an error. Response headers are in either -// *EndpointAttachment.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 *ProjectsLocationsEndpointAttachmentsGetCall) Do(opts ...googleapi.CallOption) (*EndpointAttachment, error) { +// Do executes the "connectors.projects.locations.global.getSettings" call. +// Exactly one of *Settings or error will be non-nil. Any non-2xx status +// code is an error. Response headers are in either +// *Settings.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 *ProjectsLocationsGlobalGetSettingsCall) Do(opts ...googleapi.CallOption) (*Settings, error) { gensupport.SetOptions(c.urlParams_, opts...) res, err := c.doRequest("json") if res != nil && res.StatusCode == http.StatusNotModified { @@ -6674,7 +8989,7 @@ func (c *ProjectsLocationsEndpointAttachmentsGetCall) Do(opts ...googleapi.CallO if err := googleapi.CheckResponse(res); err != nil { return nil, gensupport.WrapError(err) } - ret := &EndpointAttachment{ + ret := &Settings{ ServerResponse: googleapi.ServerResponse{ Header: res.Header, HTTPStatusCode: res.StatusCode, @@ -6686,25 +9001,25 @@ func (c *ProjectsLocationsEndpointAttachmentsGetCall) Do(opts ...googleapi.CallO } return ret, nil // { - // "description": "Gets details of a single EndpointAttachment.", - // "flatPath": "v1/projects/{projectsId}/locations/{locationsId}/endpointAttachments/{endpointAttachmentsId}", + // "description": "GetGlobalSettings gets settings of a project. GlobalSettings is a singleton resource.", + // "flatPath": "v1/projects/{projectsId}/locations/global/settings", // "httpMethod": "GET", - // "id": "connectors.projects.locations.endpointAttachments.get", + // "id": "connectors.projects.locations.global.getSettings", // "parameterOrder": [ // "name" // ], // "parameters": { // "name": { - // "description": "Required. Resource name of the form: `projects/*/locations/*/endpointAttachments/*`", + // "description": "Required. The resource name of the Settings.", // "location": "path", - // "pattern": "^projects/[^/]+/locations/[^/]+/endpointAttachments/[^/]+$", + // "pattern": "^projects/[^/]+/locations/global/settings$", // "required": true, // "type": "string" // } // }, // "path": "v1/{+name}", // "response": { - // "$ref": "EndpointAttachment" + // "$ref": "Settings" // }, // "scopes": [ // "https://www.googleapis.com/auth/cloud-platform" @@ -6713,121 +9028,96 @@ func (c *ProjectsLocationsEndpointAttachmentsGetCall) Do(opts ...googleapi.CallO } -// method id "connectors.projects.locations.endpointAttachments.list": +// method id "connectors.projects.locations.global.updateSettings": -type ProjectsLocationsEndpointAttachmentsListCall struct { - s *Service - parent string - urlParams_ gensupport.URLParams - ifNoneMatch_ string - ctx_ context.Context - header_ http.Header +type ProjectsLocationsGlobalUpdateSettingsCall struct { + s *Service + name string + settings *Settings + urlParams_ gensupport.URLParams + ctx_ context.Context + header_ http.Header } -// List: List EndpointAttachments in a given project +// UpdateSettings: Update the global settings of a project. // -// - parent: Parent resource od the EndpointAttachment, of the form: -// `projects/*/locations/*`. -func (r *ProjectsLocationsEndpointAttachmentsService) List(parent string) *ProjectsLocationsEndpointAttachmentsListCall { - c := &ProjectsLocationsEndpointAttachmentsListCall{s: r.s, urlParams_: make(gensupport.URLParams)} - c.parent = parent - return c -} - -// Filter sets the optional parameter "filter": Filter. -// https://g3doc.corp.google.com/cloud/control2/g3doc/dev/apihosting/list_filtering.md#filtering. -func (c *ProjectsLocationsEndpointAttachmentsListCall) Filter(filter string) *ProjectsLocationsEndpointAttachmentsListCall { - c.urlParams_.Set("filter", filter) - return c -} - -// OrderBy sets the optional parameter "orderBy": Order by parameters. -func (c *ProjectsLocationsEndpointAttachmentsListCall) OrderBy(orderBy string) *ProjectsLocationsEndpointAttachmentsListCall { - c.urlParams_.Set("orderBy", orderBy) - return c -} - -// PageSize sets the optional parameter "pageSize": Page size. -func (c *ProjectsLocationsEndpointAttachmentsListCall) PageSize(pageSize int64) *ProjectsLocationsEndpointAttachmentsListCall { - c.urlParams_.Set("pageSize", fmt.Sprint(pageSize)) +// - name: Output only. Resource name of the Connection. Format: +// projects/{project}/locations/global/settings}. +func (r *ProjectsLocationsGlobalService) UpdateSettings(name string, settings *Settings) *ProjectsLocationsGlobalUpdateSettingsCall { + c := &ProjectsLocationsGlobalUpdateSettingsCall{s: r.s, urlParams_: make(gensupport.URLParams)} + c.name = name + c.settings = settings return c } -// PageToken sets the optional parameter "pageToken": Page token. -func (c *ProjectsLocationsEndpointAttachmentsListCall) PageToken(pageToken string) *ProjectsLocationsEndpointAttachmentsListCall { - c.urlParams_.Set("pageToken", pageToken) +// UpdateMask sets the optional parameter "updateMask": Required. The +// list of fields to update. +func (c *ProjectsLocationsGlobalUpdateSettingsCall) UpdateMask(updateMask string) *ProjectsLocationsGlobalUpdateSettingsCall { + 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 *ProjectsLocationsEndpointAttachmentsListCall) Fields(s ...googleapi.Field) *ProjectsLocationsEndpointAttachmentsListCall { +func (c *ProjectsLocationsGlobalUpdateSettingsCall) Fields(s ...googleapi.Field) *ProjectsLocationsGlobalUpdateSettingsCall { 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 *ProjectsLocationsEndpointAttachmentsListCall) IfNoneMatch(entityTag string) *ProjectsLocationsEndpointAttachmentsListCall { - 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 *ProjectsLocationsEndpointAttachmentsListCall) Context(ctx context.Context) *ProjectsLocationsEndpointAttachmentsListCall { +func (c *ProjectsLocationsGlobalUpdateSettingsCall) Context(ctx context.Context) *ProjectsLocationsGlobalUpdateSettingsCall { 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 *ProjectsLocationsEndpointAttachmentsListCall) Header() http.Header { +func (c *ProjectsLocationsGlobalUpdateSettingsCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) } return c.header_ } -func (c *ProjectsLocationsEndpointAttachmentsListCall) doRequest(alt string) (*http.Response, error) { +func (c *ProjectsLocationsGlobalUpdateSettingsCall) 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.settings) + 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}/endpointAttachments") + urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+name}") urls += "?" + c.urlParams_.Encode() - req, err := http.NewRequest("GET", urls, body) + req, err := http.NewRequest("PATCH", 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 "connectors.projects.locations.endpointAttachments.list" call. -// Exactly one of *ListEndpointAttachmentsResponse or error will be -// non-nil. Any non-2xx status code is an error. Response headers are in -// either *ListEndpointAttachmentsResponse.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 *ProjectsLocationsEndpointAttachmentsListCall) Do(opts ...googleapi.CallOption) (*ListEndpointAttachmentsResponse, error) { +// Do executes the "connectors.projects.locations.global.updateSettings" 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 *ProjectsLocationsGlobalUpdateSettingsCall) Do(opts ...googleapi.CallOption) (*Operation, error) { gensupport.SetOptions(c.urlParams_, opts...) res, err := c.doRequest("json") if res != nil && res.StatusCode == http.StatusNotModified { @@ -6846,7 +9136,7 @@ func (c *ProjectsLocationsEndpointAttachmentsListCall) Do(opts ...googleapi.Call if err := googleapi.CheckResponse(res); err != nil { return nil, gensupport.WrapError(err) } - ret := &ListEndpointAttachmentsResponse{ + ret := &Operation{ ServerResponse: googleapi.ServerResponse{ Header: res.Header, HTTPStatusCode: res.StatusCode, @@ -6858,46 +9148,34 @@ func (c *ProjectsLocationsEndpointAttachmentsListCall) Do(opts ...googleapi.Call } return ret, nil // { - // "description": "List EndpointAttachments in a given project", - // "flatPath": "v1/projects/{projectsId}/locations/{locationsId}/endpointAttachments", - // "httpMethod": "GET", - // "id": "connectors.projects.locations.endpointAttachments.list", + // "description": "Update the global settings of a project.", + // "flatPath": "v1/projects/{projectsId}/locations/global/settings", + // "httpMethod": "PATCH", + // "id": "connectors.projects.locations.global.updateSettings", // "parameterOrder": [ - // "parent" + // "name" // ], // "parameters": { - // "filter": { - // "description": "Filter. https://g3doc.corp.google.com/cloud/control2/g3doc/dev/apihosting/list_filtering.md#filtering.", - // "location": "query", - // "type": "string" - // }, - // "orderBy": { - // "description": "Order by parameters.", - // "location": "query", + // "name": { + // "description": "Output only. Resource name of the Connection. Format: projects/{project}/locations/global/settings}", + // "location": "path", + // "pattern": "^projects/[^/]+/locations/global/settings$", + // "required": true, // "type": "string" // }, - // "pageSize": { - // "description": "Page size.", - // "format": "int32", - // "location": "query", - // "type": "integer" - // }, - // "pageToken": { - // "description": "Page token.", + // "updateMask": { + // "description": "Required. The list of fields to update.", + // "format": "google-fieldmask", // "location": "query", // "type": "string" - // }, - // "parent": { - // "description": "Required. Parent resource od the EndpointAttachment, of the form: `projects/*/locations/*`", - // "location": "path", - // "pattern": "^projects/[^/]+/locations/[^/]+$", - // "required": true, - // "type": "string" // } // }, - // "path": "v1/{+parent}/endpointAttachments", + // "path": "v1/{+name}", + // "request": { + // "$ref": "Settings" + // }, // "response": { - // "$ref": "ListEndpointAttachmentsResponse" + // "$ref": "Operation" // }, // "scopes": [ // "https://www.googleapis.com/auth/cloud-platform" @@ -6906,65 +9184,40 @@ func (c *ProjectsLocationsEndpointAttachmentsListCall) Do(opts ...googleapi.Call } -// 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 *ProjectsLocationsEndpointAttachmentsListCall) Pages(ctx context.Context, f func(*ListEndpointAttachmentsResponse) 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 "connectors.projects.locations.endpointAttachments.patch": +// method id "connectors.projects.locations.global.managedZones.create": -type ProjectsLocationsEndpointAttachmentsPatchCall struct { - s *Service - name string - endpointattachment *EndpointAttachment - urlParams_ gensupport.URLParams - ctx_ context.Context - header_ http.Header +type ProjectsLocationsGlobalManagedZonesCreateCall struct { + s *Service + parent string + managedzone *ManagedZone + urlParams_ gensupport.URLParams + ctx_ context.Context + header_ http.Header } -// Patch: Updates the parameters of a single EndpointAttachment. +// Create: Creates a new ManagedZone in a given project and location. // -// - name: Output only. Resource name of the Endpoint Attachment. -// Format: -// projects/{project}/locations/{location}/endpointAttachments/{endpoin -// t_attachment}. -func (r *ProjectsLocationsEndpointAttachmentsService) Patch(name string, endpointattachment *EndpointAttachment) *ProjectsLocationsEndpointAttachmentsPatchCall { - c := &ProjectsLocationsEndpointAttachmentsPatchCall{s: r.s, urlParams_: make(gensupport.URLParams)} - c.name = name - c.endpointattachment = endpointattachment +// - parent: Parent resource of the ManagedZone, of the form: +// `projects/*/locations/global`. +func (r *ProjectsLocationsGlobalManagedZonesService) Create(parent string, managedzone *ManagedZone) *ProjectsLocationsGlobalManagedZonesCreateCall { + c := &ProjectsLocationsGlobalManagedZonesCreateCall{s: r.s, urlParams_: make(gensupport.URLParams)} + c.parent = parent + c.managedzone = managedzone return c } -// UpdateMask sets the optional parameter "updateMask": Required. The -// list of fields to update. Fields are specified relative to the -// endpointAttachment. A field will be overwritten if it is in the mask. -// You can modify only the fields listed below. To update the -// endpointAttachment details: * `description` * `labels` -func (c *ProjectsLocationsEndpointAttachmentsPatchCall) UpdateMask(updateMask string) *ProjectsLocationsEndpointAttachmentsPatchCall { - c.urlParams_.Set("updateMask", updateMask) +// ManagedZoneId sets the optional parameter "managedZoneId": Required. +// Identifier to assign to the ManagedZone. Must be unique within scope +// of the parent resource. +func (c *ProjectsLocationsGlobalManagedZonesCreateCall) ManagedZoneId(managedZoneId string) *ProjectsLocationsGlobalManagedZonesCreateCall { + c.urlParams_.Set("managedZoneId", managedZoneId) 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 *ProjectsLocationsEndpointAttachmentsPatchCall) Fields(s ...googleapi.Field) *ProjectsLocationsEndpointAttachmentsPatchCall { +func (c *ProjectsLocationsGlobalManagedZonesCreateCall) Fields(s ...googleapi.Field) *ProjectsLocationsGlobalManagedZonesCreateCall { c.urlParams_.Set("fields", googleapi.CombineFields(s)) return c } @@ -6972,21 +9225,21 @@ func (c *ProjectsLocationsEndpointAttachmentsPatchCall) Fields(s ...googleapi.Fi // 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 *ProjectsLocationsEndpointAttachmentsPatchCall) Context(ctx context.Context) *ProjectsLocationsEndpointAttachmentsPatchCall { +func (c *ProjectsLocationsGlobalManagedZonesCreateCall) Context(ctx context.Context) *ProjectsLocationsGlobalManagedZonesCreateCall { 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 *ProjectsLocationsEndpointAttachmentsPatchCall) Header() http.Header { +func (c *ProjectsLocationsGlobalManagedZonesCreateCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) } return c.header_ } -func (c *ProjectsLocationsEndpointAttachmentsPatchCall) doRequest(alt string) (*http.Response, error) { +func (c *ProjectsLocationsGlobalManagedZonesCreateCall) 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_ { @@ -6994,34 +9247,34 @@ func (c *ProjectsLocationsEndpointAttachmentsPatchCall) doRequest(alt string) (* } reqHeaders.Set("User-Agent", c.s.userAgent()) var body io.Reader = nil - body, err := googleapi.WithoutDataWrapper.JSONReader(c.endpointattachment) + body, err := googleapi.WithoutDataWrapper.JSONReader(c.managedzone) if err != nil { return nil, err } reqHeaders.Set("Content-Type", "application/json") c.urlParams_.Set("alt", alt) c.urlParams_.Set("prettyPrint", "false") - urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+name}") + urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+parent}/managedZones") urls += "?" + c.urlParams_.Encode() - req, err := http.NewRequest("PATCH", urls, body) + 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, + "parent": c.parent, }) return gensupport.SendRequest(c.ctx_, c.s.client, req) } -// Do executes the "connectors.projects.locations.endpointAttachments.patch" call. +// Do executes the "connectors.projects.locations.global.managedZones.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 *ProjectsLocationsEndpointAttachmentsPatchCall) Do(opts ...googleapi.CallOption) (*Operation, error) { +func (c *ProjectsLocationsGlobalManagedZonesCreateCall) Do(opts ...googleapi.CallOption) (*Operation, error) { gensupport.SetOptions(c.urlParams_, opts...) res, err := c.doRequest("json") if res != nil && res.StatusCode == http.StatusNotModified { @@ -7052,31 +9305,30 @@ func (c *ProjectsLocationsEndpointAttachmentsPatchCall) Do(opts ...googleapi.Cal } return ret, nil // { - // "description": "Updates the parameters of a single EndpointAttachment.", - // "flatPath": "v1/projects/{projectsId}/locations/{locationsId}/endpointAttachments/{endpointAttachmentsId}", - // "httpMethod": "PATCH", - // "id": "connectors.projects.locations.endpointAttachments.patch", + // "description": "Creates a new ManagedZone in a given project and location.", + // "flatPath": "v1/projects/{projectsId}/locations/global/managedZones", + // "httpMethod": "POST", + // "id": "connectors.projects.locations.global.managedZones.create", // "parameterOrder": [ - // "name" + // "parent" // ], // "parameters": { - // "name": { - // "description": "Output only. Resource name of the Endpoint Attachment. Format: projects/{project}/locations/{location}/endpointAttachments/{endpoint_attachment}", - // "location": "path", - // "pattern": "^projects/[^/]+/locations/[^/]+/endpointAttachments/[^/]+$", - // "required": true, + // "managedZoneId": { + // "description": "Required. Identifier to assign to the ManagedZone. Must be unique within scope of the parent resource.", + // "location": "query", // "type": "string" // }, - // "updateMask": { - // "description": "Required. The list of fields to update. Fields are specified relative to the endpointAttachment. A field will be overwritten if it is in the mask. You can modify only the fields listed below. To update the endpointAttachment details: * `description` * `labels`", - // "format": "google-fieldmask", - // "location": "query", + // "parent": { + // "description": "Required. Parent resource of the ManagedZone, of the form: `projects/*/locations/global`", + // "location": "path", + // "pattern": "^projects/[^/]+/locations/global$", + // "required": true, // "type": "string" // } // }, - // "path": "v1/{+name}", + // "path": "v1/{+parent}/managedZones", // "request": { - // "$ref": "EndpointAttachment" + // "$ref": "ManagedZone" // }, // "response": { // "$ref": "Operation" @@ -7088,23 +9340,22 @@ func (c *ProjectsLocationsEndpointAttachmentsPatchCall) Do(opts ...googleapi.Cal } -// method id "connectors.projects.locations.global.getSettings": +// method id "connectors.projects.locations.global.managedZones.delete": -type ProjectsLocationsGlobalGetSettingsCall struct { - s *Service - name string - urlParams_ gensupport.URLParams - ifNoneMatch_ string - ctx_ context.Context - header_ http.Header +type ProjectsLocationsGlobalManagedZonesDeleteCall struct { + s *Service + name string + urlParams_ gensupport.URLParams + ctx_ context.Context + header_ http.Header } -// GetSettings: GetGlobalSettings gets settings of a project. -// GlobalSettings is a singleton resource. +// Delete: Deletes a single ManagedZone. // -// - name: The resource name of the Settings. -func (r *ProjectsLocationsGlobalService) GetSettings(name string) *ProjectsLocationsGlobalGetSettingsCall { - c := &ProjectsLocationsGlobalGetSettingsCall{s: r.s, urlParams_: make(gensupport.URLParams)} +// - name: Resource name of the form: +// `projects/*/locations/global/managedZones/*`. +func (r *ProjectsLocationsGlobalManagedZonesService) Delete(name string) *ProjectsLocationsGlobalManagedZonesDeleteCall { + c := &ProjectsLocationsGlobalManagedZonesDeleteCall{s: r.s, urlParams_: make(gensupport.URLParams)} c.name = name return c } @@ -7112,54 +9363,41 @@ func (r *ProjectsLocationsGlobalService) GetSettings(name string) *ProjectsLocat // Fields allows partial responses to be retrieved. See // https://developers.google.com/gdata/docs/2.0/basics#PartialResponse // for more information. -func (c *ProjectsLocationsGlobalGetSettingsCall) Fields(s ...googleapi.Field) *ProjectsLocationsGlobalGetSettingsCall { +func (c *ProjectsLocationsGlobalManagedZonesDeleteCall) Fields(s ...googleapi.Field) *ProjectsLocationsGlobalManagedZonesDeleteCall { 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 *ProjectsLocationsGlobalGetSettingsCall) IfNoneMatch(entityTag string) *ProjectsLocationsGlobalGetSettingsCall { - 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 *ProjectsLocationsGlobalGetSettingsCall) Context(ctx context.Context) *ProjectsLocationsGlobalGetSettingsCall { +func (c *ProjectsLocationsGlobalManagedZonesDeleteCall) Context(ctx context.Context) *ProjectsLocationsGlobalManagedZonesDeleteCall { 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 *ProjectsLocationsGlobalGetSettingsCall) Header() http.Header { +func (c *ProjectsLocationsGlobalManagedZonesDeleteCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) } return c.header_ } -func (c *ProjectsLocationsGlobalGetSettingsCall) doRequest(alt string) (*http.Response, error) { +func (c *ProjectsLocationsGlobalManagedZonesDeleteCall) doRequest(alt string) (*http.Response, error) { reqHeaders := make(http.Header) reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version) for k, v := range c.header_ { reqHeaders[k] = v } reqHeaders.Set("User-Agent", c.s.userAgent()) - if c.ifNoneMatch_ != "" { - reqHeaders.Set("If-None-Match", c.ifNoneMatch_) - } var body io.Reader = nil c.urlParams_.Set("alt", alt) c.urlParams_.Set("prettyPrint", "false") urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+name}") urls += "?" + c.urlParams_.Encode() - req, err := http.NewRequest("GET", urls, body) + req, err := http.NewRequest("DELETE", urls, body) if err != nil { return nil, err } @@ -7170,14 +9408,14 @@ func (c *ProjectsLocationsGlobalGetSettingsCall) doRequest(alt string) (*http.Re return gensupport.SendRequest(c.ctx_, c.s.client, req) } -// Do executes the "connectors.projects.locations.global.getSettings" call. -// Exactly one of *Settings or error will be non-nil. Any non-2xx status -// code is an error. Response headers are in either -// *Settings.ServerResponse.Header or (if a response was returned at +// Do executes the "connectors.projects.locations.global.managedZones.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 *ProjectsLocationsGlobalGetSettingsCall) Do(opts ...googleapi.CallOption) (*Settings, error) { +func (c *ProjectsLocationsGlobalManagedZonesDeleteCall) Do(opts ...googleapi.CallOption) (*Operation, error) { gensupport.SetOptions(c.urlParams_, opts...) res, err := c.doRequest("json") if res != nil && res.StatusCode == http.StatusNotModified { @@ -7196,7 +9434,7 @@ func (c *ProjectsLocationsGlobalGetSettingsCall) Do(opts ...googleapi.CallOption if err := googleapi.CheckResponse(res); err != nil { return nil, gensupport.WrapError(err) } - ret := &Settings{ + ret := &Operation{ ServerResponse: googleapi.ServerResponse{ Header: res.Header, HTTPStatusCode: res.StatusCode, @@ -7208,25 +9446,25 @@ func (c *ProjectsLocationsGlobalGetSettingsCall) Do(opts ...googleapi.CallOption } return ret, nil // { - // "description": "GetGlobalSettings gets settings of a project. GlobalSettings is a singleton resource.", - // "flatPath": "v1/projects/{projectsId}/locations/global/settings", - // "httpMethod": "GET", - // "id": "connectors.projects.locations.global.getSettings", + // "description": "Deletes a single ManagedZone.", + // "flatPath": "v1/projects/{projectsId}/locations/global/managedZones/{managedZonesId}", + // "httpMethod": "DELETE", + // "id": "connectors.projects.locations.global.managedZones.delete", // "parameterOrder": [ // "name" // ], // "parameters": { // "name": { - // "description": "Required. The resource name of the Settings.", + // "description": "Required. Resource name of the form: `projects/*/locations/global/managedZones/*`", // "location": "path", - // "pattern": "^projects/[^/]+/locations/global/settings$", + // "pattern": "^projects/[^/]+/locations/global/managedZones/[^/]+$", // "required": true, // "type": "string" // } // }, // "path": "v1/{+name}", // "response": { - // "$ref": "Settings" + // "$ref": "Operation" // }, // "scopes": [ // "https://www.googleapis.com/auth/cloud-platform" @@ -7235,97 +9473,96 @@ func (c *ProjectsLocationsGlobalGetSettingsCall) Do(opts ...googleapi.CallOption } -// method id "connectors.projects.locations.global.managedZones.create": +// method id "connectors.projects.locations.global.managedZones.get": -type ProjectsLocationsGlobalManagedZonesCreateCall struct { - s *Service - parent string - managedzone *ManagedZone - urlParams_ gensupport.URLParams - ctx_ context.Context - header_ http.Header +type ProjectsLocationsGlobalManagedZonesGetCall struct { + s *Service + name string + urlParams_ gensupport.URLParams + ifNoneMatch_ string + ctx_ context.Context + header_ http.Header } -// Create: Creates a new ManagedZone in a given project and location. +// Get: Gets details of a single ManagedZone. // -// - parent: Parent resource of the ManagedZone, of the form: -// `projects/*/locations/global`. -func (r *ProjectsLocationsGlobalManagedZonesService) Create(parent string, managedzone *ManagedZone) *ProjectsLocationsGlobalManagedZonesCreateCall { - c := &ProjectsLocationsGlobalManagedZonesCreateCall{s: r.s, urlParams_: make(gensupport.URLParams)} - c.parent = parent - c.managedzone = managedzone - return c -} - -// ManagedZoneId sets the optional parameter "managedZoneId": Required. -// Identifier to assign to the ManagedZone. Must be unique within scope -// of the parent resource. -func (c *ProjectsLocationsGlobalManagedZonesCreateCall) ManagedZoneId(managedZoneId string) *ProjectsLocationsGlobalManagedZonesCreateCall { - c.urlParams_.Set("managedZoneId", managedZoneId) +// - name: Resource name of the form: +// `projects/*/locations/global/managedZones/*`. +func (r *ProjectsLocationsGlobalManagedZonesService) Get(name string) *ProjectsLocationsGlobalManagedZonesGetCall { + c := &ProjectsLocationsGlobalManagedZonesGetCall{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 *ProjectsLocationsGlobalManagedZonesCreateCall) Fields(s ...googleapi.Field) *ProjectsLocationsGlobalManagedZonesCreateCall { +func (c *ProjectsLocationsGlobalManagedZonesGetCall) Fields(s ...googleapi.Field) *ProjectsLocationsGlobalManagedZonesGetCall { 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 *ProjectsLocationsGlobalManagedZonesGetCall) IfNoneMatch(entityTag string) *ProjectsLocationsGlobalManagedZonesGetCall { + 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 *ProjectsLocationsGlobalManagedZonesCreateCall) Context(ctx context.Context) *ProjectsLocationsGlobalManagedZonesCreateCall { +func (c *ProjectsLocationsGlobalManagedZonesGetCall) Context(ctx context.Context) *ProjectsLocationsGlobalManagedZonesGetCall { 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 *ProjectsLocationsGlobalManagedZonesCreateCall) Header() http.Header { +func (c *ProjectsLocationsGlobalManagedZonesGetCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) } return c.header_ } -func (c *ProjectsLocationsGlobalManagedZonesCreateCall) doRequest(alt string) (*http.Response, error) { +func (c *ProjectsLocationsGlobalManagedZonesGetCall) 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.managedzone) - 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, "v1/{+parent}/managedZones") + urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+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 "connectors.projects.locations.global.managedZones.create" call. -// Exactly one of *Operation or error will be non-nil. Any non-2xx +// Do executes the "connectors.projects.locations.global.managedZones.get" call. +// Exactly one of *ManagedZone 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 +// *ManagedZone.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 *ProjectsLocationsGlobalManagedZonesCreateCall) Do(opts ...googleapi.CallOption) (*Operation, error) { +func (c *ProjectsLocationsGlobalManagedZonesGetCall) Do(opts ...googleapi.CallOption) (*ManagedZone, error) { gensupport.SetOptions(c.urlParams_, opts...) res, err := c.doRequest("json") if res != nil && res.StatusCode == http.StatusNotModified { @@ -7344,7 +9581,7 @@ func (c *ProjectsLocationsGlobalManagedZonesCreateCall) Do(opts ...googleapi.Cal if err := googleapi.CheckResponse(res); err != nil { return nil, gensupport.WrapError(err) } - ret := &Operation{ + ret := &ManagedZone{ ServerResponse: googleapi.ServerResponse{ Header: res.Header, HTTPStatusCode: res.StatusCode, @@ -7356,33 +9593,25 @@ func (c *ProjectsLocationsGlobalManagedZonesCreateCall) Do(opts ...googleapi.Cal } return ret, nil // { - // "description": "Creates a new ManagedZone in a given project and location.", - // "flatPath": "v1/projects/{projectsId}/locations/global/managedZones", - // "httpMethod": "POST", - // "id": "connectors.projects.locations.global.managedZones.create", + // "description": "Gets details of a single ManagedZone.", + // "flatPath": "v1/projects/{projectsId}/locations/global/managedZones/{managedZonesId}", + // "httpMethod": "GET", + // "id": "connectors.projects.locations.global.managedZones.get", // "parameterOrder": [ - // "parent" + // "name" // ], // "parameters": { - // "managedZoneId": { - // "description": "Required. Identifier to assign to the ManagedZone. Must be unique within scope of the parent resource.", - // "location": "query", - // "type": "string" - // }, - // "parent": { - // "description": "Required. Parent resource of the ManagedZone, of the form: `projects/*/locations/global`", + // "name": { + // "description": "Required. Resource name of the form: `projects/*/locations/global/managedZones/*`", // "location": "path", - // "pattern": "^projects/[^/]+/locations/global$", + // "pattern": "^projects/[^/]+/locations/global/managedZones/[^/]+$", // "required": true, // "type": "string" // } // }, - // "path": "v1/{+parent}/managedZones", - // "request": { - // "$ref": "ManagedZone" - // }, + // "path": "v1/{+name}", // "response": { - // "$ref": "Operation" + // "$ref": "ManagedZone" // }, // "scopes": [ // "https://www.googleapis.com/auth/cloud-platform" @@ -7391,82 +9620,121 @@ func (c *ProjectsLocationsGlobalManagedZonesCreateCall) Do(opts ...googleapi.Cal } -// method id "connectors.projects.locations.global.managedZones.delete": +// method id "connectors.projects.locations.global.managedZones.list": -type ProjectsLocationsGlobalManagedZonesDeleteCall struct { - s *Service - name string - urlParams_ gensupport.URLParams - ctx_ context.Context - header_ http.Header +type ProjectsLocationsGlobalManagedZonesListCall struct { + s *Service + parent string + urlParams_ gensupport.URLParams + ifNoneMatch_ string + ctx_ context.Context + header_ http.Header } -// Delete: Deletes a single ManagedZone. +// List: List ManagedZones in a given project // -// - name: Resource name of the form: -// `projects/*/locations/global/managedZones/*`. -func (r *ProjectsLocationsGlobalManagedZonesService) Delete(name string) *ProjectsLocationsGlobalManagedZonesDeleteCall { - c := &ProjectsLocationsGlobalManagedZonesDeleteCall{s: r.s, urlParams_: make(gensupport.URLParams)} - c.name = name +// - parent: Parent resource of the Managed Zone, of the form: +// `projects/*/locations/global`. +func (r *ProjectsLocationsGlobalManagedZonesService) List(parent string) *ProjectsLocationsGlobalManagedZonesListCall { + c := &ProjectsLocationsGlobalManagedZonesListCall{s: r.s, urlParams_: make(gensupport.URLParams)} + c.parent = parent + return c +} + +// Filter sets the optional parameter "filter": Filter. +// https://g3doc.corp.google.com/cloud/control2/g3doc/dev/apihosting/list_filtering.md#filtering. +func (c *ProjectsLocationsGlobalManagedZonesListCall) Filter(filter string) *ProjectsLocationsGlobalManagedZonesListCall { + c.urlParams_.Set("filter", filter) + return c +} + +// OrderBy sets the optional parameter "orderBy": Order by parameters. +func (c *ProjectsLocationsGlobalManagedZonesListCall) OrderBy(orderBy string) *ProjectsLocationsGlobalManagedZonesListCall { + c.urlParams_.Set("orderBy", orderBy) + return c +} + +// PageSize sets the optional parameter "pageSize": Page size. +func (c *ProjectsLocationsGlobalManagedZonesListCall) PageSize(pageSize int64) *ProjectsLocationsGlobalManagedZonesListCall { + c.urlParams_.Set("pageSize", fmt.Sprint(pageSize)) + return c +} + +// PageToken sets the optional parameter "pageToken": Page token. +func (c *ProjectsLocationsGlobalManagedZonesListCall) PageToken(pageToken string) *ProjectsLocationsGlobalManagedZonesListCall { + 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 *ProjectsLocationsGlobalManagedZonesDeleteCall) Fields(s ...googleapi.Field) *ProjectsLocationsGlobalManagedZonesDeleteCall { +func (c *ProjectsLocationsGlobalManagedZonesListCall) Fields(s ...googleapi.Field) *ProjectsLocationsGlobalManagedZonesListCall { 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 *ProjectsLocationsGlobalManagedZonesListCall) IfNoneMatch(entityTag string) *ProjectsLocationsGlobalManagedZonesListCall { + 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 *ProjectsLocationsGlobalManagedZonesDeleteCall) Context(ctx context.Context) *ProjectsLocationsGlobalManagedZonesDeleteCall { +func (c *ProjectsLocationsGlobalManagedZonesListCall) Context(ctx context.Context) *ProjectsLocationsGlobalManagedZonesListCall { 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 *ProjectsLocationsGlobalManagedZonesDeleteCall) Header() http.Header { +func (c *ProjectsLocationsGlobalManagedZonesListCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) } return c.header_ } -func (c *ProjectsLocationsGlobalManagedZonesDeleteCall) doRequest(alt string) (*http.Response, error) { +func (c *ProjectsLocationsGlobalManagedZonesListCall) doRequest(alt string) (*http.Response, error) { reqHeaders := make(http.Header) reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version) for k, v := range c.header_ { reqHeaders[k] = v } reqHeaders.Set("User-Agent", c.s.userAgent()) + if c.ifNoneMatch_ != "" { + reqHeaders.Set("If-None-Match", c.ifNoneMatch_) + } var body io.Reader = nil c.urlParams_.Set("alt", alt) c.urlParams_.Set("prettyPrint", "false") - urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+name}") + urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+parent}/managedZones") urls += "?" + c.urlParams_.Encode() - req, err := http.NewRequest("DELETE", 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{ - "name": c.name, + "parent": c.parent, }) return gensupport.SendRequest(c.ctx_, c.s.client, req) } -// Do executes the "connectors.projects.locations.global.managedZones.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 *ProjectsLocationsGlobalManagedZonesDeleteCall) Do(opts ...googleapi.CallOption) (*Operation, error) { +// Do executes the "connectors.projects.locations.global.managedZones.list" call. +// Exactly one of *ListManagedZonesResponse or error will be non-nil. +// Any non-2xx status code is an error. Response headers are in either +// *ListManagedZonesResponse.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 *ProjectsLocationsGlobalManagedZonesListCall) Do(opts ...googleapi.CallOption) (*ListManagedZonesResponse, error) { gensupport.SetOptions(c.urlParams_, opts...) res, err := c.doRequest("json") if res != nil && res.StatusCode == http.StatusNotModified { @@ -7485,7 +9753,7 @@ func (c *ProjectsLocationsGlobalManagedZonesDeleteCall) Do(opts ...googleapi.Cal if err := googleapi.CheckResponse(res); err != nil { return nil, gensupport.WrapError(err) } - ret := &Operation{ + ret := &ListManagedZonesResponse{ ServerResponse: googleapi.ServerResponse{ Header: res.Header, HTTPStatusCode: res.StatusCode, @@ -7497,25 +9765,46 @@ func (c *ProjectsLocationsGlobalManagedZonesDeleteCall) Do(opts ...googleapi.Cal } return ret, nil // { - // "description": "Deletes a single ManagedZone.", - // "flatPath": "v1/projects/{projectsId}/locations/global/managedZones/{managedZonesId}", - // "httpMethod": "DELETE", - // "id": "connectors.projects.locations.global.managedZones.delete", + // "description": "List ManagedZones in a given project", + // "flatPath": "v1/projects/{projectsId}/locations/global/managedZones", + // "httpMethod": "GET", + // "id": "connectors.projects.locations.global.managedZones.list", // "parameterOrder": [ - // "name" + // "parent" // ], // "parameters": { - // "name": { - // "description": "Required. Resource name of the form: `projects/*/locations/global/managedZones/*`", + // "filter": { + // "description": "Filter. https://g3doc.corp.google.com/cloud/control2/g3doc/dev/apihosting/list_filtering.md#filtering.", + // "location": "query", + // "type": "string" + // }, + // "orderBy": { + // "description": "Order by parameters.", + // "location": "query", + // "type": "string" + // }, + // "pageSize": { + // "description": "Page size.", + // "format": "int32", + // "location": "query", + // "type": "integer" + // }, + // "pageToken": { + // "description": "Page token.", + // "location": "query", + // "type": "string" + // }, + // "parent": { + // "description": "Required. Parent resource of the Managed Zone, of the form: `projects/*/locations/global`", // "location": "path", - // "pattern": "^projects/[^/]+/locations/global/managedZones/[^/]+$", + // "pattern": "^projects/[^/]+/locations/global$", // "required": true, // "type": "string" // } // }, - // "path": "v1/{+name}", + // "path": "v1/{+parent}/managedZones", // "response": { - // "$ref": "Operation" + // "$ref": "ListManagedZonesResponse" // }, // "scopes": [ // "https://www.googleapis.com/auth/cloud-platform" @@ -7524,78 +9813,103 @@ func (c *ProjectsLocationsGlobalManagedZonesDeleteCall) Do(opts ...googleapi.Cal } -// method id "connectors.projects.locations.global.managedZones.get": +// 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 *ProjectsLocationsGlobalManagedZonesListCall) Pages(ctx context.Context, f func(*ListManagedZonesResponse) 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 "connectors.projects.locations.global.managedZones.patch": -type ProjectsLocationsGlobalManagedZonesGetCall struct { - s *Service - name string - urlParams_ gensupport.URLParams - ifNoneMatch_ string - ctx_ context.Context - header_ http.Header +type ProjectsLocationsGlobalManagedZonesPatchCall struct { + s *Service + name string + managedzone *ManagedZone + urlParams_ gensupport.URLParams + ctx_ context.Context + header_ http.Header } -// Get: Gets details of a single ManagedZone. +// Patch: Updates the parameters of a single ManagedZone. // -// - name: Resource name of the form: -// `projects/*/locations/global/managedZones/*`. -func (r *ProjectsLocationsGlobalManagedZonesService) Get(name string) *ProjectsLocationsGlobalManagedZonesGetCall { - c := &ProjectsLocationsGlobalManagedZonesGetCall{s: r.s, urlParams_: make(gensupport.URLParams)} +// - name: Output only. Resource name of the Managed Zone. Format: +// projects/{project}/locations/global/managedZones/{managed_zone}. +func (r *ProjectsLocationsGlobalManagedZonesService) Patch(name string, managedzone *ManagedZone) *ProjectsLocationsGlobalManagedZonesPatchCall { + c := &ProjectsLocationsGlobalManagedZonesPatchCall{s: r.s, urlParams_: make(gensupport.URLParams)} c.name = name + c.managedzone = managedzone + return c +} + +// UpdateMask sets the optional parameter "updateMask": Required. The +// list of fields to update. Fields are specified relative to the +// managedZone. A field will be overwritten if it is in the mask. You +// can modify only the fields listed below. To update the managedZone +// details: * `description` * `labels` * `target_project` * +// `target_network` +func (c *ProjectsLocationsGlobalManagedZonesPatchCall) UpdateMask(updateMask string) *ProjectsLocationsGlobalManagedZonesPatchCall { + 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 *ProjectsLocationsGlobalManagedZonesGetCall) Fields(s ...googleapi.Field) *ProjectsLocationsGlobalManagedZonesGetCall { +func (c *ProjectsLocationsGlobalManagedZonesPatchCall) Fields(s ...googleapi.Field) *ProjectsLocationsGlobalManagedZonesPatchCall { 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 *ProjectsLocationsGlobalManagedZonesGetCall) IfNoneMatch(entityTag string) *ProjectsLocationsGlobalManagedZonesGetCall { - 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 *ProjectsLocationsGlobalManagedZonesGetCall) Context(ctx context.Context) *ProjectsLocationsGlobalManagedZonesGetCall { +func (c *ProjectsLocationsGlobalManagedZonesPatchCall) Context(ctx context.Context) *ProjectsLocationsGlobalManagedZonesPatchCall { 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 *ProjectsLocationsGlobalManagedZonesGetCall) Header() http.Header { +func (c *ProjectsLocationsGlobalManagedZonesPatchCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) } return c.header_ } -func (c *ProjectsLocationsGlobalManagedZonesGetCall) doRequest(alt string) (*http.Response, error) { +func (c *ProjectsLocationsGlobalManagedZonesPatchCall) 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.managedzone) + if err != nil { + return nil, err + } + reqHeaders.Set("Content-Type", "application/json") c.urlParams_.Set("alt", alt) c.urlParams_.Set("prettyPrint", "false") urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+name}") urls += "?" + c.urlParams_.Encode() - req, err := http.NewRequest("GET", urls, body) + req, err := http.NewRequest("PATCH", urls, body) if err != nil { return nil, err } @@ -7606,14 +9920,14 @@ func (c *ProjectsLocationsGlobalManagedZonesGetCall) doRequest(alt string) (*htt return gensupport.SendRequest(c.ctx_, c.s.client, req) } -// Do executes the "connectors.projects.locations.global.managedZones.get" call. -// Exactly one of *ManagedZone or error will be non-nil. Any non-2xx +// Do executes the "connectors.projects.locations.global.managedZones.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 -// *ManagedZone.ServerResponse.Header or (if a response was returned at +// *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 *ProjectsLocationsGlobalManagedZonesGetCall) Do(opts ...googleapi.CallOption) (*ManagedZone, error) { +func (c *ProjectsLocationsGlobalManagedZonesPatchCall) Do(opts ...googleapi.CallOption) (*Operation, error) { gensupport.SetOptions(c.urlParams_, opts...) res, err := c.doRequest("json") if res != nil && res.StatusCode == http.StatusNotModified { @@ -7632,7 +9946,7 @@ func (c *ProjectsLocationsGlobalManagedZonesGetCall) Do(opts ...googleapi.CallOp if err := googleapi.CheckResponse(res); err != nil { return nil, gensupport.WrapError(err) } - ret := &ManagedZone{ + ret := &Operation{ ServerResponse: googleapi.ServerResponse{ Header: res.Header, HTTPStatusCode: res.StatusCode, @@ -7644,26 +9958,35 @@ func (c *ProjectsLocationsGlobalManagedZonesGetCall) Do(opts ...googleapi.CallOp } return ret, nil // { - // "description": "Gets details of a single ManagedZone.", + // "description": "Updates the parameters of a single ManagedZone.", // "flatPath": "v1/projects/{projectsId}/locations/global/managedZones/{managedZonesId}", - // "httpMethod": "GET", - // "id": "connectors.projects.locations.global.managedZones.get", + // "httpMethod": "PATCH", + // "id": "connectors.projects.locations.global.managedZones.patch", // "parameterOrder": [ // "name" // ], // "parameters": { // "name": { - // "description": "Required. Resource name of the form: `projects/*/locations/global/managedZones/*`", + // "description": "Output only. Resource name of the Managed Zone. Format: projects/{project}/locations/global/managedZones/{managed_zone}", // "location": "path", // "pattern": "^projects/[^/]+/locations/global/managedZones/[^/]+$", // "required": true, // "type": "string" + // }, + // "updateMask": { + // "description": "Required. The list of fields to update. Fields are specified relative to the managedZone. A field will be overwritten if it is in the mask. You can modify only the fields listed below. To update the managedZone details: * `description` * `labels` * `target_project` * `target_network`", + // "format": "google-fieldmask", + // "location": "query", + // "type": "string" // } // }, // "path": "v1/{+name}", - // "response": { + // "request": { // "$ref": "ManagedZone" // }, + // "response": { + // "$ref": "Operation" + // }, // "scopes": [ // "https://www.googleapis.com/auth/cloud-platform" // ] @@ -7671,121 +9994,97 @@ func (c *ProjectsLocationsGlobalManagedZonesGetCall) Do(opts ...googleapi.CallOp } -// method id "connectors.projects.locations.global.managedZones.list": +// method id "connectors.projects.locations.operations.cancel": -type ProjectsLocationsGlobalManagedZonesListCall struct { - s *Service - parent string - urlParams_ gensupport.URLParams - ifNoneMatch_ string - ctx_ context.Context - header_ http.Header +type ProjectsLocationsOperationsCancelCall struct { + s *Service + name string + canceloperationrequest *CancelOperationRequest + urlParams_ gensupport.URLParams + ctx_ context.Context + header_ http.Header } -// List: List ManagedZones in a given project +// 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`. // -// - parent: Parent resource of the Managed Zone, of the form: -// `projects/*/locations/global`. -func (r *ProjectsLocationsGlobalManagedZonesService) List(parent string) *ProjectsLocationsGlobalManagedZonesListCall { - c := &ProjectsLocationsGlobalManagedZonesListCall{s: r.s, urlParams_: make(gensupport.URLParams)} - c.parent = parent - return c -} - -// Filter sets the optional parameter "filter": Filter. -// https://g3doc.corp.google.com/cloud/control2/g3doc/dev/apihosting/list_filtering.md#filtering. -func (c *ProjectsLocationsGlobalManagedZonesListCall) Filter(filter string) *ProjectsLocationsGlobalManagedZonesListCall { - c.urlParams_.Set("filter", filter) - return c -} - -// OrderBy sets the optional parameter "orderBy": Order by parameters. -func (c *ProjectsLocationsGlobalManagedZonesListCall) OrderBy(orderBy string) *ProjectsLocationsGlobalManagedZonesListCall { - c.urlParams_.Set("orderBy", orderBy) - return c -} - -// PageSize sets the optional parameter "pageSize": Page size. -func (c *ProjectsLocationsGlobalManagedZonesListCall) PageSize(pageSize int64) *ProjectsLocationsGlobalManagedZonesListCall { - c.urlParams_.Set("pageSize", fmt.Sprint(pageSize)) - return c -} - -// PageToken sets the optional parameter "pageToken": Page token. -func (c *ProjectsLocationsGlobalManagedZonesListCall) PageToken(pageToken string) *ProjectsLocationsGlobalManagedZonesListCall { - c.urlParams_.Set("pageToken", pageToken) +// - 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 *ProjectsLocationsGlobalManagedZonesListCall) Fields(s ...googleapi.Field) *ProjectsLocationsGlobalManagedZonesListCall { +func (c *ProjectsLocationsOperationsCancelCall) Fields(s ...googleapi.Field) *ProjectsLocationsOperationsCancelCall { 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 *ProjectsLocationsGlobalManagedZonesListCall) IfNoneMatch(entityTag string) *ProjectsLocationsGlobalManagedZonesListCall { - 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 *ProjectsLocationsGlobalManagedZonesListCall) Context(ctx context.Context) *ProjectsLocationsGlobalManagedZonesListCall { +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 *ProjectsLocationsGlobalManagedZonesListCall) Header() http.Header { +func (c *ProjectsLocationsOperationsCancelCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) } return c.header_ } -func (c *ProjectsLocationsGlobalManagedZonesListCall) doRequest(alt string) (*http.Response, error) { +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()) - if c.ifNoneMatch_ != "" { - reqHeaders.Set("If-None-Match", c.ifNoneMatch_) - } 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, "v1/{+parent}/managedZones") + urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+name}:cancel") urls += "?" + c.urlParams_.Encode() - req, err := http.NewRequest("GET", urls, body) + 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, + "name": c.name, }) return gensupport.SendRequest(c.ctx_, c.s.client, req) } -// Do executes the "connectors.projects.locations.global.managedZones.list" call. -// Exactly one of *ListManagedZonesResponse or error will be non-nil. -// Any non-2xx status code is an error. Response headers are in either -// *ListManagedZonesResponse.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 *ProjectsLocationsGlobalManagedZonesListCall) Do(opts ...googleapi.CallOption) (*ListManagedZonesResponse, error) { +// Do executes the "connectors.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 { @@ -7804,7 +10103,7 @@ func (c *ProjectsLocationsGlobalManagedZonesListCall) Do(opts ...googleapi.CallO if err := googleapi.CheckResponse(res); err != nil { return nil, gensupport.WrapError(err) } - ret := &ListManagedZonesResponse{ + ret := &Empty{ ServerResponse: googleapi.ServerResponse{ Header: res.Header, HTTPStatusCode: res.StatusCode, @@ -7816,46 +10115,28 @@ func (c *ProjectsLocationsGlobalManagedZonesListCall) Do(opts ...googleapi.CallO } return ret, nil // { - // "description": "List ManagedZones in a given project", - // "flatPath": "v1/projects/{projectsId}/locations/global/managedZones", - // "httpMethod": "GET", - // "id": "connectors.projects.locations.global.managedZones.list", + // "description": "Starts asynchronous cancellation on a long-running operation. The server makes a best effort to cancel the operation, but success is not guaranteed. If the server doesn't support this method, it returns `google.rpc.Code.UNIMPLEMENTED`. Clients can use Operations.GetOperation or other methods to check whether the cancellation succeeded or whether the operation completed despite cancellation. On successful cancellation, the operation is not deleted; instead, it becomes an operation with an Operation.error value with a google.rpc.Status.code of 1, corresponding to `Code.CANCELLED`.", + // "flatPath": "v1/projects/{projectsId}/locations/{locationsId}/operations/{operationsId}:cancel", + // "httpMethod": "POST", + // "id": "connectors.projects.locations.operations.cancel", // "parameterOrder": [ - // "parent" - // ], - // "parameters": { - // "filter": { - // "description": "Filter. https://g3doc.corp.google.com/cloud/control2/g3doc/dev/apihosting/list_filtering.md#filtering.", - // "location": "query", - // "type": "string" - // }, - // "orderBy": { - // "description": "Order by parameters.", - // "location": "query", - // "type": "string" - // }, - // "pageSize": { - // "description": "Page size.", - // "format": "int32", - // "location": "query", - // "type": "integer" - // }, - // "pageToken": { - // "description": "Page token.", - // "location": "query", - // "type": "string" - // }, - // "parent": { - // "description": "Required. Parent resource of the Managed Zone, of the form: `projects/*/locations/global`", + // "name" + // ], + // "parameters": { + // "name": { + // "description": "The name of the operation resource to be cancelled.", // "location": "path", - // "pattern": "^projects/[^/]+/locations/global$", + // "pattern": "^projects/[^/]+/locations/[^/]+/operations/[^/]+$", // "required": true, // "type": "string" // } // }, - // "path": "v1/{+parent}/managedZones", + // "path": "v1/{+name}:cancel", + // "request": { + // "$ref": "CancelOperationRequest" + // }, // "response": { - // "$ref": "ListManagedZonesResponse" + // "$ref": "Empty" // }, // "scopes": [ // "https://www.googleapis.com/auth/cloud-platform" @@ -7864,64 +10145,32 @@ func (c *ProjectsLocationsGlobalManagedZonesListCall) Do(opts ...googleapi.CallO } -// 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 *ProjectsLocationsGlobalManagedZonesListCall) Pages(ctx context.Context, f func(*ListManagedZonesResponse) 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 "connectors.projects.locations.global.managedZones.patch": +// method id "connectors.projects.locations.operations.delete": -type ProjectsLocationsGlobalManagedZonesPatchCall struct { - s *Service - name string - managedzone *ManagedZone - urlParams_ gensupport.URLParams - ctx_ context.Context - header_ http.Header +type ProjectsLocationsOperationsDeleteCall struct { + s *Service + name string + urlParams_ gensupport.URLParams + ctx_ context.Context + header_ http.Header } -// Patch: Updates the parameters of a single ManagedZone. +// 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: Output only. Resource name of the Managed Zone. Format: -// projects/{project}/locations/global/managedZones/{managed_zone}. -func (r *ProjectsLocationsGlobalManagedZonesService) Patch(name string, managedzone *ManagedZone) *ProjectsLocationsGlobalManagedZonesPatchCall { - c := &ProjectsLocationsGlobalManagedZonesPatchCall{s: r.s, urlParams_: make(gensupport.URLParams)} +// - 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 - c.managedzone = managedzone - return c -} - -// UpdateMask sets the optional parameter "updateMask": Required. The -// list of fields to update. Fields are specified relative to the -// managedZone. A field will be overwritten if it is in the mask. You -// can modify only the fields listed below. To update the managedZone -// details: * `description` * `labels` * `target_project` * -// `target_network` -func (c *ProjectsLocationsGlobalManagedZonesPatchCall) UpdateMask(updateMask string) *ProjectsLocationsGlobalManagedZonesPatchCall { - 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 *ProjectsLocationsGlobalManagedZonesPatchCall) Fields(s ...googleapi.Field) *ProjectsLocationsGlobalManagedZonesPatchCall { +func (c *ProjectsLocationsOperationsDeleteCall) Fields(s ...googleapi.Field) *ProjectsLocationsOperationsDeleteCall { c.urlParams_.Set("fields", googleapi.CombineFields(s)) return c } @@ -7929,21 +10178,21 @@ func (c *ProjectsLocationsGlobalManagedZonesPatchCall) Fields(s ...googleapi.Fie // 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 *ProjectsLocationsGlobalManagedZonesPatchCall) Context(ctx context.Context) *ProjectsLocationsGlobalManagedZonesPatchCall { +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 *ProjectsLocationsGlobalManagedZonesPatchCall) Header() http.Header { +func (c *ProjectsLocationsOperationsDeleteCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) } return c.header_ } -func (c *ProjectsLocationsGlobalManagedZonesPatchCall) doRequest(alt string) (*http.Response, error) { +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_ { @@ -7951,16 +10200,11 @@ func (c *ProjectsLocationsGlobalManagedZonesPatchCall) doRequest(alt string) (*h } reqHeaders.Set("User-Agent", c.s.userAgent()) var body io.Reader = nil - body, err := googleapi.WithoutDataWrapper.JSONReader(c.managedzone) - if err != nil { - return nil, err - } - reqHeaders.Set("Content-Type", "application/json") c.urlParams_.Set("alt", alt) c.urlParams_.Set("prettyPrint", "false") urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+name}") urls += "?" + c.urlParams_.Encode() - req, err := http.NewRequest("PATCH", urls, body) + req, err := http.NewRequest("DELETE", urls, body) if err != nil { return nil, err } @@ -7971,14 +10215,14 @@ func (c *ProjectsLocationsGlobalManagedZonesPatchCall) doRequest(alt string) (*h return gensupport.SendRequest(c.ctx_, c.s.client, req) } -// Do executes the "connectors.projects.locations.global.managedZones.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 *ProjectsLocationsGlobalManagedZonesPatchCall) Do(opts ...googleapi.CallOption) (*Operation, error) { +// Do executes the "connectors.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 { @@ -7997,7 +10241,7 @@ func (c *ProjectsLocationsGlobalManagedZonesPatchCall) Do(opts ...googleapi.Call if err := googleapi.CheckResponse(res); err != nil { return nil, gensupport.WrapError(err) } - ret := &Operation{ + ret := &Empty{ ServerResponse: googleapi.ServerResponse{ Header: res.Header, HTTPStatusCode: res.StatusCode, @@ -8009,34 +10253,25 @@ func (c *ProjectsLocationsGlobalManagedZonesPatchCall) Do(opts ...googleapi.Call } return ret, nil // { - // "description": "Updates the parameters of a single ManagedZone.", - // "flatPath": "v1/projects/{projectsId}/locations/global/managedZones/{managedZonesId}", - // "httpMethod": "PATCH", - // "id": "connectors.projects.locations.global.managedZones.patch", + // "description": "Deletes a long-running operation. This method indicates that the client is no longer interested in the operation result. It does not cancel the operation. If the server doesn't support this method, it returns `google.rpc.Code.UNIMPLEMENTED`.", + // "flatPath": "v1/projects/{projectsId}/locations/{locationsId}/operations/{operationsId}", + // "httpMethod": "DELETE", + // "id": "connectors.projects.locations.operations.delete", // "parameterOrder": [ // "name" // ], // "parameters": { // "name": { - // "description": "Output only. Resource name of the Managed Zone. Format: projects/{project}/locations/global/managedZones/{managed_zone}", + // "description": "The name of the operation resource to be deleted.", // "location": "path", - // "pattern": "^projects/[^/]+/locations/global/managedZones/[^/]+$", + // "pattern": "^projects/[^/]+/locations/[^/]+/operations/[^/]+$", // "required": true, // "type": "string" - // }, - // "updateMask": { - // "description": "Required. The list of fields to update. Fields are specified relative to the managedZone. A field will be overwritten if it is in the mask. You can modify only the fields listed below. To update the managedZone details: * `description` * `labels` * `target_project` * `target_network`", - // "format": "google-fieldmask", - // "location": "query", - // "type": "string" // } // }, // "path": "v1/{+name}", - // "request": { - // "$ref": "ManagedZone" - // }, // "response": { - // "$ref": "Operation" + // "$ref": "Empty" // }, // "scopes": [ // "https://www.googleapis.com/auth/cloud-platform" @@ -8045,79 +10280,79 @@ func (c *ProjectsLocationsGlobalManagedZonesPatchCall) Do(opts ...googleapi.Call } -// method id "connectors.projects.locations.operations.cancel": +// method id "connectors.projects.locations.operations.get": -type ProjectsLocationsOperationsCancelCall struct { - s *Service - name string - canceloperationrequest *CancelOperationRequest - urlParams_ gensupport.URLParams - ctx_ context.Context - header_ http.Header +type ProjectsLocationsOperationsGetCall struct { + s *Service + name string + urlParams_ gensupport.URLParams + ifNoneMatch_ string + 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`. +// 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 to be cancelled. -func (r *ProjectsLocationsOperationsService) Cancel(name string, canceloperationrequest *CancelOperationRequest) *ProjectsLocationsOperationsCancelCall { - c := &ProjectsLocationsOperationsCancelCall{s: r.s, urlParams_: make(gensupport.URLParams)} +// - 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 - 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 { +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 *ProjectsLocationsOperationsCancelCall) Context(ctx context.Context) *ProjectsLocationsOperationsCancelCall { +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 *ProjectsLocationsOperationsCancelCall) Header() http.Header { +func (c *ProjectsLocationsOperationsGetCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) } return c.header_ } -func (c *ProjectsLocationsOperationsCancelCall) doRequest(alt string) (*http.Response, error) { +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()) - var body io.Reader = nil - body, err := googleapi.WithoutDataWrapper.JSONReader(c.canceloperationrequest) - 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, "v1/{+name}:cancel") + urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+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 } @@ -8128,14 +10363,14 @@ func (c *ProjectsLocationsOperationsCancelCall) doRequest(alt string) (*http.Res return gensupport.SendRequest(c.ctx_, c.s.client, req) } -// Do executes the "connectors.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) { +// Do executes the "connectors.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 { @@ -8154,7 +10389,7 @@ func (c *ProjectsLocationsOperationsCancelCall) Do(opts ...googleapi.CallOption) if err := googleapi.CheckResponse(res); err != nil { return nil, gensupport.WrapError(err) } - ret := &Empty{ + ret := &Operation{ ServerResponse: googleapi.ServerResponse{ Header: res.Header, HTTPStatusCode: res.StatusCode, @@ -8166,28 +10401,25 @@ func (c *ProjectsLocationsOperationsCancelCall) Do(opts ...googleapi.CallOption) } return ret, nil // { - // "description": "Starts asynchronous cancellation on a long-running operation. The server makes a best effort to cancel the operation, but success is not guaranteed. If the server doesn't support this method, it returns `google.rpc.Code.UNIMPLEMENTED`. Clients can use Operations.GetOperation or other methods to check whether the cancellation succeeded or whether the operation completed despite cancellation. On successful cancellation, the operation is not deleted; instead, it becomes an operation with an Operation.error value with a google.rpc.Status.code of 1, corresponding to `Code.CANCELLED`.", - // "flatPath": "v1/projects/{projectsId}/locations/{locationsId}/operations/{operationsId}:cancel", - // "httpMethod": "POST", - // "id": "connectors.projects.locations.operations.cancel", + // "description": "Gets the latest state of a long-running operation. Clients can use this method to poll the operation result at intervals as recommended by the API service.", + // "flatPath": "v1/projects/{projectsId}/locations/{locationsId}/operations/{operationsId}", + // "httpMethod": "GET", + // "id": "connectors.projects.locations.operations.get", // "parameterOrder": [ // "name" // ], // "parameters": { // "name": { - // "description": "The name of the operation resource to be cancelled.", + // "description": "The name of the operation resource.", // "location": "path", // "pattern": "^projects/[^/]+/locations/[^/]+/operations/[^/]+$", // "required": true, // "type": "string" // } // }, - // "path": "v1/{+name}:cancel", - // "request": { - // "$ref": "CancelOperationRequest" - // }, + // "path": "v1/{+name}", // "response": { - // "$ref": "Empty" + // "$ref": "Operation" // }, // "scopes": [ // "https://www.googleapis.com/auth/cloud-platform" @@ -8196,66 +10428,100 @@ func (c *ProjectsLocationsOperationsCancelCall) Do(opts ...googleapi.CallOption) } -// method id "connectors.projects.locations.operations.delete": - -type ProjectsLocationsOperationsDeleteCall struct { - s *Service - name string - urlParams_ gensupport.URLParams - ctx_ context.Context - header_ http.Header +// method id "connectors.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`. +// +// - 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 } -// 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 +// 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 *ProjectsLocationsOperationsDeleteCall) Fields(s ...googleapi.Field) *ProjectsLocationsOperationsDeleteCall { +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 *ProjectsLocationsOperationsDeleteCall) Context(ctx context.Context) *ProjectsLocationsOperationsDeleteCall { +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 *ProjectsLocationsOperationsDeleteCall) Header() http.Header { +func (c *ProjectsLocationsOperationsListCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) } return c.header_ } -func (c *ProjectsLocationsOperationsDeleteCall) doRequest(alt string) (*http.Response, error) { +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, "v1/{+name}") + urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+name}/operations") urls += "?" + c.urlParams_.Encode() - req, err := http.NewRequest("DELETE", urls, body) + req, err := http.NewRequest("GET", urls, body) if err != nil { return nil, err } @@ -8266,14 +10532,14 @@ func (c *ProjectsLocationsOperationsDeleteCall) doRequest(alt string) (*http.Res return gensupport.SendRequest(c.ctx_, c.s.client, req) } -// Do executes the "connectors.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) { +// Do executes the "connectors.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 { @@ -8292,7 +10558,7 @@ func (c *ProjectsLocationsOperationsDeleteCall) Do(opts ...googleapi.CallOption) if err := googleapi.CheckResponse(res); err != nil { return nil, gensupport.WrapError(err) } - ret := &Empty{ + ret := &ListOperationsResponse{ ServerResponse: googleapi.ServerResponse{ Header: res.Header, HTTPStatusCode: res.StatusCode, @@ -8304,25 +10570,41 @@ func (c *ProjectsLocationsOperationsDeleteCall) Do(opts ...googleapi.CallOption) } return ret, nil // { - // "description": "Deletes a long-running operation. This method indicates that the client is no longer interested in the operation result. It does not cancel the operation. If the server doesn't support this method, it returns `google.rpc.Code.UNIMPLEMENTED`.", - // "flatPath": "v1/projects/{projectsId}/locations/{locationsId}/operations/{operationsId}", - // "httpMethod": "DELETE", - // "id": "connectors.projects.locations.operations.delete", + // "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": "connectors.projects.locations.operations.list", // "parameterOrder": [ // "name" // ], // "parameters": { + // "filter": { + // "description": "The standard list filter.", + // "location": "query", + // "type": "string" + // }, // "name": { - // "description": "The name of the operation resource to be deleted.", + // "description": "The name of the operation's parent resource.", // "location": "path", - // "pattern": "^projects/[^/]+/locations/[^/]+/operations/[^/]+$", + // "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": "v1/{+name}", + // "path": "v1/{+name}/operations", // "response": { - // "$ref": "Empty" + // "$ref": "ListOperationsResponse" // }, // "scopes": [ // "https://www.googleapis.com/auth/cloud-platform" @@ -8331,9 +10613,30 @@ func (c *ProjectsLocationsOperationsDeleteCall) Do(opts ...googleapi.CallOption) } -// method id "connectors.projects.locations.operations.get": +// 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) + } +} -type ProjectsLocationsOperationsGetCall struct { +// method id "connectors.projects.locations.providers.get": + +type ProjectsLocationsProvidersGetCall struct { s *Service name string urlParams_ gensupport.URLParams @@ -8342,13 +10645,13 @@ type ProjectsLocationsOperationsGetCall struct { header_ http.Header } -// Get: Gets the latest state of a long-running operation. Clients can -// use this method to poll the operation result at intervals as -// recommended by the API service. +// Get: Gets details of a provider. // -// - name: The name of the operation resource. -func (r *ProjectsLocationsOperationsService) Get(name string) *ProjectsLocationsOperationsGetCall { - c := &ProjectsLocationsOperationsGetCall{s: r.s, urlParams_: make(gensupport.URLParams)} +// - name: Resource name of the form: +// `projects/*/locations/*/providers/*` Only global location is +// supported for Provider resource. +func (r *ProjectsLocationsProvidersService) Get(name string) *ProjectsLocationsProvidersGetCall { + c := &ProjectsLocationsProvidersGetCall{s: r.s, urlParams_: make(gensupport.URLParams)} c.name = name return c } @@ -8356,7 +10659,7 @@ func (r *ProjectsLocationsOperationsService) Get(name string) *ProjectsLocations // 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 { +func (c *ProjectsLocationsProvidersGetCall) Fields(s ...googleapi.Field) *ProjectsLocationsProvidersGetCall { c.urlParams_.Set("fields", googleapi.CombineFields(s)) return c } @@ -8366,7 +10669,7 @@ func (c *ProjectsLocationsOperationsGetCall) Fields(s ...googleapi.Field) *Proje // 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 { +func (c *ProjectsLocationsProvidersGetCall) IfNoneMatch(entityTag string) *ProjectsLocationsProvidersGetCall { c.ifNoneMatch_ = entityTag return c } @@ -8374,21 +10677,21 @@ func (c *ProjectsLocationsOperationsGetCall) IfNoneMatch(entityTag string) *Proj // 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 { +func (c *ProjectsLocationsProvidersGetCall) Context(ctx context.Context) *ProjectsLocationsProvidersGetCall { 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 { +func (c *ProjectsLocationsProvidersGetCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) } return c.header_ } -func (c *ProjectsLocationsOperationsGetCall) doRequest(alt string) (*http.Response, error) { +func (c *ProjectsLocationsProvidersGetCall) 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_ { @@ -8414,14 +10717,14 @@ func (c *ProjectsLocationsOperationsGetCall) doRequest(alt string) (*http.Respon return gensupport.SendRequest(c.ctx_, c.s.client, req) } -// Do executes the "connectors.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 +// Do executes the "connectors.projects.locations.providers.get" call. +// Exactly one of *Provider or error will be non-nil. Any non-2xx status +// code is an error. Response headers are in either +// *Provider.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) { +func (c *ProjectsLocationsProvidersGetCall) Do(opts ...googleapi.CallOption) (*Provider, error) { gensupport.SetOptions(c.urlParams_, opts...) res, err := c.doRequest("json") if res != nil && res.StatusCode == http.StatusNotModified { @@ -8440,7 +10743,7 @@ func (c *ProjectsLocationsOperationsGetCall) Do(opts ...googleapi.CallOption) (* if err := googleapi.CheckResponse(res); err != nil { return nil, gensupport.WrapError(err) } - ret := &Operation{ + ret := &Provider{ ServerResponse: googleapi.ServerResponse{ Header: res.Header, HTTPStatusCode: res.StatusCode, @@ -8452,25 +10755,25 @@ func (c *ProjectsLocationsOperationsGetCall) Do(opts ...googleapi.CallOption) (* } return ret, nil // { - // "description": "Gets the latest state of a long-running operation. Clients can use this method to poll the operation result at intervals as recommended by the API service.", - // "flatPath": "v1/projects/{projectsId}/locations/{locationsId}/operations/{operationsId}", + // "description": "Gets details of a provider.", + // "flatPath": "v1/projects/{projectsId}/locations/{locationsId}/providers/{providersId}", // "httpMethod": "GET", - // "id": "connectors.projects.locations.operations.get", + // "id": "connectors.projects.locations.providers.get", // "parameterOrder": [ // "name" // ], // "parameters": { // "name": { - // "description": "The name of the operation resource.", + // "description": "Required. Resource name of the form: `projects/*/locations/*/providers/*` Only global location is supported for Provider resource.", // "location": "path", - // "pattern": "^projects/[^/]+/locations/[^/]+/operations/[^/]+$", + // "pattern": "^projects/[^/]+/locations/[^/]+/providers/[^/]+$", // "required": true, // "type": "string" // } // }, // "path": "v1/{+name}", // "response": { - // "$ref": "Operation" + // "$ref": "Provider" // }, // "scopes": [ // "https://www.googleapis.com/auth/cloud-platform" @@ -8479,53 +10782,53 @@ func (c *ProjectsLocationsOperationsGetCall) Do(opts ...googleapi.CallOption) (* } -// method id "connectors.projects.locations.operations.list": +// method id "connectors.projects.locations.providers.getIamPolicy": -type ProjectsLocationsOperationsListCall struct { +type ProjectsLocationsProvidersGetIamPolicyCall struct { s *Service - name string + resource 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`. +// GetIamPolicy: Gets the access control policy for a resource. Returns +// an empty policy if the resource exists and does not have a policy +// set. // -// - 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)) +// - resource: REQUIRED: The resource for which the policy is being +// requested. See Resource names +// (https://cloud.google.com/apis/design/resource_names) for the +// appropriate value for this field. +func (r *ProjectsLocationsProvidersService) GetIamPolicy(resource string) *ProjectsLocationsProvidersGetIamPolicyCall { + c := &ProjectsLocationsProvidersGetIamPolicyCall{s: r.s, urlParams_: make(gensupport.URLParams)} + c.resource = resource 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) +// OptionsRequestedPolicyVersion sets the optional parameter +// "options.requestedPolicyVersion": The maximum policy version that +// will be used to format the policy. Valid values are 0, 1, and 3. +// Requests specifying an invalid value will be rejected. Requests for +// policies with any conditional role bindings must specify version 3. +// Policies with no conditional role bindings may specify any valid +// value or leave the field unset. The policy in the response might use +// the policy version that you specified, or it might use a lower policy +// version. For example, if you specify version 3, but the policy has no +// conditional role bindings, the response uses version 1. To learn +// which resources support conditions in their IAM policies, see the IAM +// documentation +// (https://cloud.google.com/iam/help/conditions/resource-policies). +func (c *ProjectsLocationsProvidersGetIamPolicyCall) OptionsRequestedPolicyVersion(optionsRequestedPolicyVersion int64) *ProjectsLocationsProvidersGetIamPolicyCall { + c.urlParams_.Set("options.requestedPolicyVersion", fmt.Sprint(optionsRequestedPolicyVersion)) 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 { +func (c *ProjectsLocationsProvidersGetIamPolicyCall) Fields(s ...googleapi.Field) *ProjectsLocationsProvidersGetIamPolicyCall { c.urlParams_.Set("fields", googleapi.CombineFields(s)) return c } @@ -8535,7 +10838,7 @@ func (c *ProjectsLocationsOperationsListCall) Fields(s ...googleapi.Field) *Proj // 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 { +func (c *ProjectsLocationsProvidersGetIamPolicyCall) IfNoneMatch(entityTag string) *ProjectsLocationsProvidersGetIamPolicyCall { c.ifNoneMatch_ = entityTag return c } @@ -8543,21 +10846,21 @@ func (c *ProjectsLocationsOperationsListCall) IfNoneMatch(entityTag string) *Pro // 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 { +func (c *ProjectsLocationsProvidersGetIamPolicyCall) Context(ctx context.Context) *ProjectsLocationsProvidersGetIamPolicyCall { 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 { +func (c *ProjectsLocationsProvidersGetIamPolicyCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) } return c.header_ } -func (c *ProjectsLocationsOperationsListCall) doRequest(alt string) (*http.Response, error) { +func (c *ProjectsLocationsProvidersGetIamPolicyCall) 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_ { @@ -8570,7 +10873,7 @@ func (c *ProjectsLocationsOperationsListCall) doRequest(alt string) (*http.Respo var body io.Reader = nil c.urlParams_.Set("alt", alt) c.urlParams_.Set("prettyPrint", "false") - urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+name}/operations") + urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+resource}:getIamPolicy") urls += "?" + c.urlParams_.Encode() req, err := http.NewRequest("GET", urls, body) if err != nil { @@ -8578,19 +10881,19 @@ func (c *ProjectsLocationsOperationsListCall) doRequest(alt string) (*http.Respo } req.Header = reqHeaders googleapi.Expand(req.URL, map[string]string{ - "name": c.name, + "resource": c.resource, }) - return gensupport.SendRequest(c.ctx_, c.s.client, req) -} - -// Do executes the "connectors.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) { + return gensupport.SendRequest(c.ctx_, c.s.client, req) +} + +// Do executes the "connectors.projects.locations.providers.getIamPolicy" call. +// Exactly one of *Policy or error will be non-nil. Any non-2xx status +// code is an error. Response headers are in either +// *Policy.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 *ProjectsLocationsProvidersGetIamPolicyCall) Do(opts ...googleapi.CallOption) (*Policy, error) { gensupport.SetOptions(c.urlParams_, opts...) res, err := c.doRequest("json") if res != nil && res.StatusCode == http.StatusNotModified { @@ -8609,7 +10912,7 @@ func (c *ProjectsLocationsOperationsListCall) Do(opts ...googleapi.CallOption) ( if err := googleapi.CheckResponse(res); err != nil { return nil, gensupport.WrapError(err) } - ret := &ListOperationsResponse{ + ret := &Policy{ ServerResponse: googleapi.ServerResponse{ Header: res.Header, HTTPStatusCode: res.StatusCode, @@ -8621,41 +10924,31 @@ 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`.", - // "flatPath": "v1/projects/{projectsId}/locations/{locationsId}/operations", + // "description": "Gets the access control policy for a resource. Returns an empty policy if the resource exists and does not have a policy set.", + // "flatPath": "v1/projects/{projectsId}/locations/{locationsId}/providers/{providersId}:getIamPolicy", // "httpMethod": "GET", - // "id": "connectors.projects.locations.operations.list", + // "id": "connectors.projects.locations.providers.getIamPolicy", // "parameterOrder": [ - // "name" + // "resource" // ], // "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.", + // "options.requestedPolicyVersion": { + // "description": "Optional. The maximum policy version that will be used to format the policy. Valid values are 0, 1, and 3. Requests specifying an invalid value will be rejected. Requests for policies with any conditional role bindings must specify version 3. Policies with no conditional role bindings may specify any valid value or leave the field unset. The policy in the response might use the policy version that you specified, or it might use a lower policy version. For example, if you specify version 3, but the policy has no conditional role bindings, the response uses version 1. To learn which resources support conditions in their IAM policies, see the [IAM documentation](https://cloud.google.com/iam/help/conditions/resource-policies).", // "format": "int32", // "location": "query", // "type": "integer" // }, - // "pageToken": { - // "description": "The standard list page token.", - // "location": "query", + // "resource": { + // "description": "REQUIRED: The resource for which the policy is being requested. See [Resource names](https://cloud.google.com/apis/design/resource_names) for the appropriate value for this field.", + // "location": "path", + // "pattern": "^projects/[^/]+/locations/[^/]+/providers/[^/]+$", + // "required": true, // "type": "string" // } // }, - // "path": "v1/{+name}/operations", + // "path": "v1/{+resource}:getIamPolicy", // "response": { - // "$ref": "ListOperationsResponse" + // "$ref": "Policy" // }, // "scopes": [ // "https://www.googleapis.com/auth/cloud-platform" @@ -8664,53 +10957,44 @@ func (c *ProjectsLocationsOperationsListCall) Do(opts ...googleapi.CallOption) ( } -// 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 "connectors.projects.locations.providers.get": +// method id "connectors.projects.locations.providers.list": -type ProjectsLocationsProvidersGetCall struct { +type ProjectsLocationsProvidersListCall struct { s *Service - name string + parent string urlParams_ gensupport.URLParams ifNoneMatch_ string ctx_ context.Context header_ http.Header } -// Get: Gets details of a provider. +// List: Lists Providers in a given project and location. // -// - name: Resource name of the form: -// `projects/*/locations/*/providers/*` Only global location is -// supported for Provider resource. -func (r *ProjectsLocationsProvidersService) Get(name string) *ProjectsLocationsProvidersGetCall { - c := &ProjectsLocationsProvidersGetCall{s: r.s, urlParams_: make(gensupport.URLParams)} - c.name = name +// - parent: Parent resource of the API, of the form: +// `projects/*/locations/*` Only global location is supported for +// Provider resource. +func (r *ProjectsLocationsProvidersService) List(parent string) *ProjectsLocationsProvidersListCall { + c := &ProjectsLocationsProvidersListCall{s: r.s, urlParams_: make(gensupport.URLParams)} + c.parent = parent + return c +} + +// PageSize sets the optional parameter "pageSize": Page size. +func (c *ProjectsLocationsProvidersListCall) PageSize(pageSize int64) *ProjectsLocationsProvidersListCall { + c.urlParams_.Set("pageSize", fmt.Sprint(pageSize)) + return c +} + +// PageToken sets the optional parameter "pageToken": Page token. +func (c *ProjectsLocationsProvidersListCall) PageToken(pageToken string) *ProjectsLocationsProvidersListCall { + 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 *ProjectsLocationsProvidersGetCall) Fields(s ...googleapi.Field) *ProjectsLocationsProvidersGetCall { +func (c *ProjectsLocationsProvidersListCall) Fields(s ...googleapi.Field) *ProjectsLocationsProvidersListCall { c.urlParams_.Set("fields", googleapi.CombineFields(s)) return c } @@ -8720,7 +11004,7 @@ func (c *ProjectsLocationsProvidersGetCall) Fields(s ...googleapi.Field) *Projec // 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 *ProjectsLocationsProvidersGetCall) IfNoneMatch(entityTag string) *ProjectsLocationsProvidersGetCall { +func (c *ProjectsLocationsProvidersListCall) IfNoneMatch(entityTag string) *ProjectsLocationsProvidersListCall { c.ifNoneMatch_ = entityTag return c } @@ -8728,21 +11012,21 @@ func (c *ProjectsLocationsProvidersGetCall) IfNoneMatch(entityTag string) *Proje // 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 *ProjectsLocationsProvidersGetCall) Context(ctx context.Context) *ProjectsLocationsProvidersGetCall { +func (c *ProjectsLocationsProvidersListCall) Context(ctx context.Context) *ProjectsLocationsProvidersListCall { 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 *ProjectsLocationsProvidersGetCall) Header() http.Header { +func (c *ProjectsLocationsProvidersListCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) } return c.header_ } -func (c *ProjectsLocationsProvidersGetCall) doRequest(alt string) (*http.Response, error) { +func (c *ProjectsLocationsProvidersListCall) 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_ { @@ -8755,7 +11039,7 @@ func (c *ProjectsLocationsProvidersGetCall) doRequest(alt string) (*http.Respons var body io.Reader = nil c.urlParams_.Set("alt", alt) c.urlParams_.Set("prettyPrint", "false") - urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+name}") + urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+parent}/providers") urls += "?" + c.urlParams_.Encode() req, err := http.NewRequest("GET", urls, body) if err != nil { @@ -8763,19 +11047,19 @@ func (c *ProjectsLocationsProvidersGetCall) doRequest(alt string) (*http.Respons } req.Header = reqHeaders googleapi.Expand(req.URL, map[string]string{ - "name": c.name, + "parent": c.parent, }) return gensupport.SendRequest(c.ctx_, c.s.client, req) } -// Do executes the "connectors.projects.locations.providers.get" call. -// Exactly one of *Provider or error will be non-nil. Any non-2xx status -// code is an error. Response headers are in either -// *Provider.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 *ProjectsLocationsProvidersGetCall) Do(opts ...googleapi.CallOption) (*Provider, error) { +// Do executes the "connectors.projects.locations.providers.list" call. +// Exactly one of *ListProvidersResponse or error will be non-nil. Any +// non-2xx status code is an error. Response headers are in either +// *ListProvidersResponse.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 *ProjectsLocationsProvidersListCall) Do(opts ...googleapi.CallOption) (*ListProvidersResponse, error) { gensupport.SetOptions(c.urlParams_, opts...) res, err := c.doRequest("json") if res != nil && res.StatusCode == http.StatusNotModified { @@ -8794,7 +11078,7 @@ func (c *ProjectsLocationsProvidersGetCall) Do(opts ...googleapi.CallOption) (*P if err := googleapi.CheckResponse(res); err != nil { return nil, gensupport.WrapError(err) } - ret := &Provider{ + ret := &ListProvidersResponse{ ServerResponse: googleapi.ServerResponse{ Header: res.Header, HTTPStatusCode: res.StatusCode, @@ -8806,25 +11090,36 @@ func (c *ProjectsLocationsProvidersGetCall) Do(opts ...googleapi.CallOption) (*P } return ret, nil // { - // "description": "Gets details of a provider.", - // "flatPath": "v1/projects/{projectsId}/locations/{locationsId}/providers/{providersId}", + // "description": "Lists Providers in a given project and location.", + // "flatPath": "v1/projects/{projectsId}/locations/{locationsId}/providers", // "httpMethod": "GET", - // "id": "connectors.projects.locations.providers.get", + // "id": "connectors.projects.locations.providers.list", // "parameterOrder": [ - // "name" + // "parent" // ], // "parameters": { - // "name": { - // "description": "Required. Resource name of the form: `projects/*/locations/*/providers/*` Only global location is supported for Provider resource.", + // "pageSize": { + // "description": "Page size.", + // "format": "int32", + // "location": "query", + // "type": "integer" + // }, + // "pageToken": { + // "description": "Page token.", + // "location": "query", + // "type": "string" + // }, + // "parent": { + // "description": "Required. Parent resource of the API, of the form: `projects/*/locations/*` Only global location is supported for Provider resource.", // "location": "path", - // "pattern": "^projects/[^/]+/locations/[^/]+/providers/[^/]+$", + // "pattern": "^projects/[^/]+/locations/[^/]+$", // "required": true, // "type": "string" // } // }, - // "path": "v1/{+name}", + // "path": "v1/{+parent}/providers", // "response": { - // "$ref": "Provider" + // "$ref": "ListProvidersResponse" // }, // "scopes": [ // "https://www.googleapis.com/auth/cloud-platform" @@ -8833,100 +11128,96 @@ func (c *ProjectsLocationsProvidersGetCall) Do(opts ...googleapi.CallOption) (*P } -// method id "connectors.projects.locations.providers.getIamPolicy": +// 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 *ProjectsLocationsProvidersListCall) Pages(ctx context.Context, f func(*ListProvidersResponse) 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 ProjectsLocationsProvidersGetIamPolicyCall struct { - s *Service - resource string - urlParams_ gensupport.URLParams - ifNoneMatch_ string - ctx_ context.Context - header_ http.Header +// method id "connectors.projects.locations.providers.setIamPolicy": + +type ProjectsLocationsProvidersSetIamPolicyCall struct { + s *Service + resource string + setiampolicyrequest *SetIamPolicyRequest + urlParams_ gensupport.URLParams + ctx_ context.Context + header_ http.Header } -// GetIamPolicy: Gets the access control policy for a resource. Returns -// an empty policy if the resource exists and does not have a policy -// set. +// SetIamPolicy: Sets the access control policy on the specified +// resource. Replaces any existing policy. Can return `NOT_FOUND`, +// `INVALID_ARGUMENT`, and `PERMISSION_DENIED` errors. // // - resource: REQUIRED: The resource for which the policy is being -// requested. See Resource names +// specified. See Resource names // (https://cloud.google.com/apis/design/resource_names) for the // appropriate value for this field. -func (r *ProjectsLocationsProvidersService) GetIamPolicy(resource string) *ProjectsLocationsProvidersGetIamPolicyCall { - c := &ProjectsLocationsProvidersGetIamPolicyCall{s: r.s, urlParams_: make(gensupport.URLParams)} +func (r *ProjectsLocationsProvidersService) SetIamPolicy(resource string, setiampolicyrequest *SetIamPolicyRequest) *ProjectsLocationsProvidersSetIamPolicyCall { + c := &ProjectsLocationsProvidersSetIamPolicyCall{s: r.s, urlParams_: make(gensupport.URLParams)} c.resource = resource - return c -} - -// OptionsRequestedPolicyVersion sets the optional parameter -// "options.requestedPolicyVersion": The maximum policy version that -// will be used to format the policy. Valid values are 0, 1, and 3. -// Requests specifying an invalid value will be rejected. Requests for -// policies with any conditional role bindings must specify version 3. -// Policies with no conditional role bindings may specify any valid -// value or leave the field unset. The policy in the response might use -// the policy version that you specified, or it might use a lower policy -// version. For example, if you specify version 3, but the policy has no -// conditional role bindings, the response uses version 1. To learn -// which resources support conditions in their IAM policies, see the IAM -// documentation -// (https://cloud.google.com/iam/help/conditions/resource-policies). -func (c *ProjectsLocationsProvidersGetIamPolicyCall) OptionsRequestedPolicyVersion(optionsRequestedPolicyVersion int64) *ProjectsLocationsProvidersGetIamPolicyCall { - c.urlParams_.Set("options.requestedPolicyVersion", fmt.Sprint(optionsRequestedPolicyVersion)) + c.setiampolicyrequest = setiampolicyrequest 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 *ProjectsLocationsProvidersGetIamPolicyCall) Fields(s ...googleapi.Field) *ProjectsLocationsProvidersGetIamPolicyCall { +func (c *ProjectsLocationsProvidersSetIamPolicyCall) Fields(s ...googleapi.Field) *ProjectsLocationsProvidersSetIamPolicyCall { 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 *ProjectsLocationsProvidersGetIamPolicyCall) IfNoneMatch(entityTag string) *ProjectsLocationsProvidersGetIamPolicyCall { - 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 *ProjectsLocationsProvidersGetIamPolicyCall) Context(ctx context.Context) *ProjectsLocationsProvidersGetIamPolicyCall { +func (c *ProjectsLocationsProvidersSetIamPolicyCall) Context(ctx context.Context) *ProjectsLocationsProvidersSetIamPolicyCall { 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 *ProjectsLocationsProvidersGetIamPolicyCall) Header() http.Header { +func (c *ProjectsLocationsProvidersSetIamPolicyCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) } return c.header_ } -func (c *ProjectsLocationsProvidersGetIamPolicyCall) doRequest(alt string) (*http.Response, error) { +func (c *ProjectsLocationsProvidersSetIamPolicyCall) 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.setiampolicyrequest) + 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/{+resource}:getIamPolicy") + urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+resource}:setIamPolicy") urls += "?" + c.urlParams_.Encode() - req, err := http.NewRequest("GET", urls, body) + req, err := http.NewRequest("POST", urls, body) if err != nil { return nil, err } @@ -8937,14 +11228,14 @@ func (c *ProjectsLocationsProvidersGetIamPolicyCall) doRequest(alt string) (*htt return gensupport.SendRequest(c.ctx_, c.s.client, req) } -// Do executes the "connectors.projects.locations.providers.getIamPolicy" call. +// Do executes the "connectors.projects.locations.providers.setIamPolicy" call. // Exactly one of *Policy or error will be non-nil. Any non-2xx status // code is an error. Response headers are in either // *Policy.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 *ProjectsLocationsProvidersGetIamPolicyCall) Do(opts ...googleapi.CallOption) (*Policy, error) { +func (c *ProjectsLocationsProvidersSetIamPolicyCall) Do(opts ...googleapi.CallOption) (*Policy, error) { gensupport.SetOptions(c.urlParams_, opts...) res, err := c.doRequest("json") if res != nil && res.StatusCode == http.StatusNotModified { @@ -8975,29 +11266,26 @@ func (c *ProjectsLocationsProvidersGetIamPolicyCall) Do(opts ...googleapi.CallOp } return ret, nil // { - // "description": "Gets the access control policy for a resource. Returns an empty policy if the resource exists and does not have a policy set.", - // "flatPath": "v1/projects/{projectsId}/locations/{locationsId}/providers/{providersId}:getIamPolicy", - // "httpMethod": "GET", - // "id": "connectors.projects.locations.providers.getIamPolicy", + // "description": "Sets the access control policy on the specified resource. Replaces any existing policy. Can return `NOT_FOUND`, `INVALID_ARGUMENT`, and `PERMISSION_DENIED` errors.", + // "flatPath": "v1/projects/{projectsId}/locations/{locationsId}/providers/{providersId}:setIamPolicy", + // "httpMethod": "POST", + // "id": "connectors.projects.locations.providers.setIamPolicy", // "parameterOrder": [ // "resource" // ], // "parameters": { - // "options.requestedPolicyVersion": { - // "description": "Optional. The maximum policy version that will be used to format the policy. Valid values are 0, 1, and 3. Requests specifying an invalid value will be rejected. Requests for policies with any conditional role bindings must specify version 3. Policies with no conditional role bindings may specify any valid value or leave the field unset. The policy in the response might use the policy version that you specified, or it might use a lower policy version. For example, if you specify version 3, but the policy has no conditional role bindings, the response uses version 1. To learn which resources support conditions in their IAM policies, see the [IAM documentation](https://cloud.google.com/iam/help/conditions/resource-policies).", - // "format": "int32", - // "location": "query", - // "type": "integer" - // }, // "resource": { - // "description": "REQUIRED: The resource for which the policy is being requested. See [Resource names](https://cloud.google.com/apis/design/resource_names) for the appropriate value for this field.", + // "description": "REQUIRED: The resource for which the policy is being specified. See [Resource names](https://cloud.google.com/apis/design/resource_names) for the appropriate value for this field.", // "location": "path", // "pattern": "^projects/[^/]+/locations/[^/]+/providers/[^/]+$", // "required": true, // "type": "string" // } // }, - // "path": "v1/{+resource}:getIamPolicy", + // "path": "v1/{+resource}:setIamPolicy", + // "request": { + // "$ref": "SetIamPolicyRequest" + // }, // "response": { // "$ref": "Policy" // }, @@ -9008,109 +11296,96 @@ func (c *ProjectsLocationsProvidersGetIamPolicyCall) Do(opts ...googleapi.CallOp } -// method id "connectors.projects.locations.providers.list": +// method id "connectors.projects.locations.providers.testIamPermissions": -type ProjectsLocationsProvidersListCall struct { - s *Service - parent string - urlParams_ gensupport.URLParams - ifNoneMatch_ string - ctx_ context.Context - header_ http.Header +type ProjectsLocationsProvidersTestIamPermissionsCall struct { + s *Service + resource string + testiampermissionsrequest *TestIamPermissionsRequest + urlParams_ gensupport.URLParams + ctx_ context.Context + header_ http.Header } -// List: Lists Providers in a given project and location. +// TestIamPermissions: Returns permissions that a caller has on the +// specified resource. If the resource does not exist, this will return +// an empty set of permissions, not a `NOT_FOUND` error. Note: This +// operation is designed to be used for building permission-aware UIs +// and command-line tools, not for authorization checking. This +// operation may "fail open" without warning. // -// - parent: Parent resource of the API, of the form: -// `projects/*/locations/*` Only global location is supported for -// Provider resource. -func (r *ProjectsLocationsProvidersService) List(parent string) *ProjectsLocationsProvidersListCall { - c := &ProjectsLocationsProvidersListCall{s: r.s, urlParams_: make(gensupport.URLParams)} - c.parent = parent - return c -} - -// PageSize sets the optional parameter "pageSize": Page size. -func (c *ProjectsLocationsProvidersListCall) PageSize(pageSize int64) *ProjectsLocationsProvidersListCall { - c.urlParams_.Set("pageSize", fmt.Sprint(pageSize)) - return c -} - -// PageToken sets the optional parameter "pageToken": Page token. -func (c *ProjectsLocationsProvidersListCall) PageToken(pageToken string) *ProjectsLocationsProvidersListCall { - c.urlParams_.Set("pageToken", pageToken) +// - resource: REQUIRED: The resource for which the policy detail is +// being requested. See Resource names +// (https://cloud.google.com/apis/design/resource_names) for the +// appropriate value for this field. +func (r *ProjectsLocationsProvidersService) TestIamPermissions(resource string, testiampermissionsrequest *TestIamPermissionsRequest) *ProjectsLocationsProvidersTestIamPermissionsCall { + c := &ProjectsLocationsProvidersTestIamPermissionsCall{s: r.s, urlParams_: make(gensupport.URLParams)} + c.resource = resource + c.testiampermissionsrequest = testiampermissionsrequest 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 *ProjectsLocationsProvidersListCall) Fields(s ...googleapi.Field) *ProjectsLocationsProvidersListCall { +func (c *ProjectsLocationsProvidersTestIamPermissionsCall) Fields(s ...googleapi.Field) *ProjectsLocationsProvidersTestIamPermissionsCall { 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 *ProjectsLocationsProvidersListCall) IfNoneMatch(entityTag string) *ProjectsLocationsProvidersListCall { - 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 *ProjectsLocationsProvidersListCall) Context(ctx context.Context) *ProjectsLocationsProvidersListCall { +func (c *ProjectsLocationsProvidersTestIamPermissionsCall) Context(ctx context.Context) *ProjectsLocationsProvidersTestIamPermissionsCall { 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 *ProjectsLocationsProvidersListCall) Header() http.Header { +func (c *ProjectsLocationsProvidersTestIamPermissionsCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) } return c.header_ } -func (c *ProjectsLocationsProvidersListCall) doRequest(alt string) (*http.Response, error) { +func (c *ProjectsLocationsProvidersTestIamPermissionsCall) 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.testiampermissionsrequest) + 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}/providers") + urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+resource}:testIamPermissions") urls += "?" + c.urlParams_.Encode() - req, err := http.NewRequest("GET", urls, body) + 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, + "resource": c.resource, }) return gensupport.SendRequest(c.ctx_, c.s.client, req) } -// Do executes the "connectors.projects.locations.providers.list" call. -// Exactly one of *ListProvidersResponse or error will be non-nil. Any -// non-2xx status code is an error. Response headers are in either -// *ListProvidersResponse.ServerResponse.Header or (if a response was -// returned at all) in error.(*googleapi.Error).Header. Use +// Do executes the "connectors.projects.locations.providers.testIamPermissions" call. +// Exactly one of *TestIamPermissionsResponse or error will be non-nil. +// Any non-2xx status code is an error. Response headers are in either +// *TestIamPermissionsResponse.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 *ProjectsLocationsProvidersListCall) Do(opts ...googleapi.CallOption) (*ListProvidersResponse, error) { +func (c *ProjectsLocationsProvidersTestIamPermissionsCall) Do(opts ...googleapi.CallOption) (*TestIamPermissionsResponse, error) { gensupport.SetOptions(c.urlParams_, opts...) res, err := c.doRequest("json") if res != nil && res.StatusCode == http.StatusNotModified { @@ -9129,7 +11404,7 @@ func (c *ProjectsLocationsProvidersListCall) Do(opts ...googleapi.CallOption) (* if err := googleapi.CheckResponse(res); err != nil { return nil, gensupport.WrapError(err) } - ret := &ListProvidersResponse{ + ret := &TestIamPermissionsResponse{ ServerResponse: googleapi.ServerResponse{ Header: res.Header, HTTPStatusCode: res.StatusCode, @@ -9141,36 +11416,28 @@ func (c *ProjectsLocationsProvidersListCall) Do(opts ...googleapi.CallOption) (* } return ret, nil // { - // "description": "Lists Providers in a given project and location.", - // "flatPath": "v1/projects/{projectsId}/locations/{locationsId}/providers", - // "httpMethod": "GET", - // "id": "connectors.projects.locations.providers.list", + // "description": "Returns permissions that a caller has on the specified resource. If the resource does not exist, this will return an empty set of permissions, not a `NOT_FOUND` error. Note: This operation is designed to be used for building permission-aware UIs and command-line tools, not for authorization checking. This operation may \"fail open\" without warning.", + // "flatPath": "v1/projects/{projectsId}/locations/{locationsId}/providers/{providersId}:testIamPermissions", + // "httpMethod": "POST", + // "id": "connectors.projects.locations.providers.testIamPermissions", // "parameterOrder": [ - // "parent" + // "resource" // ], // "parameters": { - // "pageSize": { - // "description": "Page size.", - // "format": "int32", - // "location": "query", - // "type": "integer" - // }, - // "pageToken": { - // "description": "Page token.", - // "location": "query", - // "type": "string" - // }, - // "parent": { - // "description": "Required. Parent resource of the API, of the form: `projects/*/locations/*` Only global location is supported for Provider resource.", + // "resource": { + // "description": "REQUIRED: The resource for which the policy detail is being requested. See [Resource names](https://cloud.google.com/apis/design/resource_names) for the appropriate value for this field.", // "location": "path", - // "pattern": "^projects/[^/]+/locations/[^/]+$", + // "pattern": "^projects/[^/]+/locations/[^/]+/providers/[^/]+$", // "required": true, // "type": "string" // } // }, - // "path": "v1/{+parent}/providers", + // "path": "v1/{+resource}:testIamPermissions", + // "request": { + // "$ref": "TestIamPermissionsRequest" + // }, // "response": { - // "$ref": "ListProvidersResponse" + // "$ref": "TestIamPermissionsResponse" // }, // "scopes": [ // "https://www.googleapis.com/auth/cloud-platform" @@ -9179,114 +11446,97 @@ func (c *ProjectsLocationsProvidersListCall) Do(opts ...googleapi.CallOption) (* } -// 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 *ProjectsLocationsProvidersListCall) Pages(ctx context.Context, f func(*ListProvidersResponse) 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 "connectors.projects.locations.providers.setIamPolicy": +// method id "connectors.projects.locations.providers.connectors.get": -type ProjectsLocationsProvidersSetIamPolicyCall struct { - s *Service - resource string - setiampolicyrequest *SetIamPolicyRequest - urlParams_ gensupport.URLParams - ctx_ context.Context - header_ http.Header +type ProjectsLocationsProvidersConnectorsGetCall struct { + s *Service + name string + urlParams_ gensupport.URLParams + ifNoneMatch_ string + ctx_ context.Context + header_ http.Header } -// SetIamPolicy: Sets the access control policy on the specified -// resource. Replaces any existing policy. Can return `NOT_FOUND`, -// `INVALID_ARGUMENT`, and `PERMISSION_DENIED` errors. +// Get: Gets details of a single Connector. // -// - resource: REQUIRED: The resource for which the policy is being -// specified. See Resource names -// (https://cloud.google.com/apis/design/resource_names) for the -// appropriate value for this field. -func (r *ProjectsLocationsProvidersService) SetIamPolicy(resource string, setiampolicyrequest *SetIamPolicyRequest) *ProjectsLocationsProvidersSetIamPolicyCall { - c := &ProjectsLocationsProvidersSetIamPolicyCall{s: r.s, urlParams_: make(gensupport.URLParams)} - c.resource = resource - c.setiampolicyrequest = setiampolicyrequest +// - name: Resource name of the form: +// `projects/*/locations/*/providers/*/connectors/*` Only global +// location is supported for Connector resource. +func (r *ProjectsLocationsProvidersConnectorsService) Get(name string) *ProjectsLocationsProvidersConnectorsGetCall { + c := &ProjectsLocationsProvidersConnectorsGetCall{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 *ProjectsLocationsProvidersSetIamPolicyCall) Fields(s ...googleapi.Field) *ProjectsLocationsProvidersSetIamPolicyCall { +func (c *ProjectsLocationsProvidersConnectorsGetCall) Fields(s ...googleapi.Field) *ProjectsLocationsProvidersConnectorsGetCall { 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 *ProjectsLocationsProvidersConnectorsGetCall) IfNoneMatch(entityTag string) *ProjectsLocationsProvidersConnectorsGetCall { + 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 *ProjectsLocationsProvidersSetIamPolicyCall) Context(ctx context.Context) *ProjectsLocationsProvidersSetIamPolicyCall { +func (c *ProjectsLocationsProvidersConnectorsGetCall) Context(ctx context.Context) *ProjectsLocationsProvidersConnectorsGetCall { 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 *ProjectsLocationsProvidersSetIamPolicyCall) Header() http.Header { +func (c *ProjectsLocationsProvidersConnectorsGetCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) } return c.header_ } -func (c *ProjectsLocationsProvidersSetIamPolicyCall) doRequest(alt string) (*http.Response, error) { +func (c *ProjectsLocationsProvidersConnectorsGetCall) 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.setiampolicyrequest) - 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, "v1/{+resource}:setIamPolicy") + urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+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{ - "resource": c.resource, + "name": c.name, }) return gensupport.SendRequest(c.ctx_, c.s.client, req) -} - -// Do executes the "connectors.projects.locations.providers.setIamPolicy" call. -// Exactly one of *Policy or error will be non-nil. Any non-2xx status -// code is an error. Response headers are in either -// *Policy.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 *ProjectsLocationsProvidersSetIamPolicyCall) Do(opts ...googleapi.CallOption) (*Policy, error) { +} + +// Do executes the "connectors.projects.locations.providers.connectors.get" call. +// Exactly one of *Connector or error will be non-nil. Any non-2xx +// status code is an error. Response headers are in either +// *Connector.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 *ProjectsLocationsProvidersConnectorsGetCall) Do(opts ...googleapi.CallOption) (*Connector, error) { gensupport.SetOptions(c.urlParams_, opts...) res, err := c.doRequest("json") if res != nil && res.StatusCode == http.StatusNotModified { @@ -9305,7 +11555,7 @@ func (c *ProjectsLocationsProvidersSetIamPolicyCall) Do(opts ...googleapi.CallOp if err := googleapi.CheckResponse(res); err != nil { return nil, gensupport.WrapError(err) } - ret := &Policy{ + ret := &Connector{ ServerResponse: googleapi.ServerResponse{ Header: res.Header, HTTPStatusCode: res.StatusCode, @@ -9317,28 +11567,25 @@ func (c *ProjectsLocationsProvidersSetIamPolicyCall) Do(opts ...googleapi.CallOp } return ret, nil // { - // "description": "Sets the access control policy on the specified resource. Replaces any existing policy. Can return `NOT_FOUND`, `INVALID_ARGUMENT`, and `PERMISSION_DENIED` errors.", - // "flatPath": "v1/projects/{projectsId}/locations/{locationsId}/providers/{providersId}:setIamPolicy", - // "httpMethod": "POST", - // "id": "connectors.projects.locations.providers.setIamPolicy", + // "description": "Gets details of a single Connector.", + // "flatPath": "v1/projects/{projectsId}/locations/{locationsId}/providers/{providersId}/connectors/{connectorsId}", + // "httpMethod": "GET", + // "id": "connectors.projects.locations.providers.connectors.get", // "parameterOrder": [ - // "resource" + // "name" // ], // "parameters": { - // "resource": { - // "description": "REQUIRED: The resource for which the policy is being specified. See [Resource names](https://cloud.google.com/apis/design/resource_names) for the appropriate value for this field.", + // "name": { + // "description": "Required. Resource name of the form: `projects/*/locations/*/providers/*/connectors/*` Only global location is supported for Connector resource.", // "location": "path", - // "pattern": "^projects/[^/]+/locations/[^/]+/providers/[^/]+$", + // "pattern": "^projects/[^/]+/locations/[^/]+/providers/[^/]+/connectors/[^/]+$", // "required": true, // "type": "string" // } // }, - // "path": "v1/{+resource}:setIamPolicy", - // "request": { - // "$ref": "SetIamPolicyRequest" - // }, + // "path": "v1/{+name}", // "response": { - // "$ref": "Policy" + // "$ref": "Connector" // }, // "scopes": [ // "https://www.googleapis.com/auth/cloud-platform" @@ -9347,96 +11594,115 @@ func (c *ProjectsLocationsProvidersSetIamPolicyCall) Do(opts ...googleapi.CallOp } -// method id "connectors.projects.locations.providers.testIamPermissions": +// method id "connectors.projects.locations.providers.connectors.list": -type ProjectsLocationsProvidersTestIamPermissionsCall struct { - s *Service - resource string - testiampermissionsrequest *TestIamPermissionsRequest - urlParams_ gensupport.URLParams - ctx_ context.Context - header_ http.Header +type ProjectsLocationsProvidersConnectorsListCall struct { + s *Service + parent string + urlParams_ gensupport.URLParams + ifNoneMatch_ string + ctx_ context.Context + header_ http.Header } -// TestIamPermissions: Returns permissions that a caller has on the -// specified resource. If the resource does not exist, this will return -// an empty set of permissions, not a `NOT_FOUND` error. Note: This -// operation is designed to be used for building permission-aware UIs -// and command-line tools, not for authorization checking. This -// operation may "fail open" without warning. +// List: Lists Connectors in a given project and location. // -// - resource: REQUIRED: The resource for which the policy detail is -// being requested. See Resource names -// (https://cloud.google.com/apis/design/resource_names) for the -// appropriate value for this field. -func (r *ProjectsLocationsProvidersService) TestIamPermissions(resource string, testiampermissionsrequest *TestIamPermissionsRequest) *ProjectsLocationsProvidersTestIamPermissionsCall { - c := &ProjectsLocationsProvidersTestIamPermissionsCall{s: r.s, urlParams_: make(gensupport.URLParams)} - c.resource = resource - c.testiampermissionsrequest = testiampermissionsrequest +// - parent: Parent resource of the connectors, of the form: +// `projects/*/locations/*/providers/*` Only global location is +// supported for Connector resource. +func (r *ProjectsLocationsProvidersConnectorsService) List(parent string) *ProjectsLocationsProvidersConnectorsListCall { + c := &ProjectsLocationsProvidersConnectorsListCall{s: r.s, urlParams_: make(gensupport.URLParams)} + c.parent = parent + return c +} + +// Filter sets the optional parameter "filter": Filter string. +func (c *ProjectsLocationsProvidersConnectorsListCall) Filter(filter string) *ProjectsLocationsProvidersConnectorsListCall { + c.urlParams_.Set("filter", filter) + return c +} + +// PageSize sets the optional parameter "pageSize": Page size. +func (c *ProjectsLocationsProvidersConnectorsListCall) PageSize(pageSize int64) *ProjectsLocationsProvidersConnectorsListCall { + c.urlParams_.Set("pageSize", fmt.Sprint(pageSize)) + return c +} + +// PageToken sets the optional parameter "pageToken": Page token. +func (c *ProjectsLocationsProvidersConnectorsListCall) PageToken(pageToken string) *ProjectsLocationsProvidersConnectorsListCall { + 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 *ProjectsLocationsProvidersTestIamPermissionsCall) Fields(s ...googleapi.Field) *ProjectsLocationsProvidersTestIamPermissionsCall { +func (c *ProjectsLocationsProvidersConnectorsListCall) Fields(s ...googleapi.Field) *ProjectsLocationsProvidersConnectorsListCall { 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 *ProjectsLocationsProvidersConnectorsListCall) IfNoneMatch(entityTag string) *ProjectsLocationsProvidersConnectorsListCall { + 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 *ProjectsLocationsProvidersTestIamPermissionsCall) Context(ctx context.Context) *ProjectsLocationsProvidersTestIamPermissionsCall { +func (c *ProjectsLocationsProvidersConnectorsListCall) Context(ctx context.Context) *ProjectsLocationsProvidersConnectorsListCall { 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 *ProjectsLocationsProvidersTestIamPermissionsCall) Header() http.Header { +func (c *ProjectsLocationsProvidersConnectorsListCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) } return c.header_ } -func (c *ProjectsLocationsProvidersTestIamPermissionsCall) doRequest(alt string) (*http.Response, error) { +func (c *ProjectsLocationsProvidersConnectorsListCall) 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.testiampermissionsrequest) - 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, "v1/{+resource}:testIamPermissions") + urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+parent}/connectors") 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{ - "resource": c.resource, + "parent": c.parent, }) return gensupport.SendRequest(c.ctx_, c.s.client, req) } -// Do executes the "connectors.projects.locations.providers.testIamPermissions" call. -// Exactly one of *TestIamPermissionsResponse or error will be non-nil. -// Any non-2xx status code is an error. Response headers are in either -// *TestIamPermissionsResponse.ServerResponse.Header or (if a response -// was returned at all) in error.(*googleapi.Error).Header. Use +// Do executes the "connectors.projects.locations.providers.connectors.list" call. +// Exactly one of *ListConnectorsResponse or error will be non-nil. Any +// non-2xx status code is an error. Response headers are in either +// *ListConnectorsResponse.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 *ProjectsLocationsProvidersTestIamPermissionsCall) Do(opts ...googleapi.CallOption) (*TestIamPermissionsResponse, error) { +func (c *ProjectsLocationsProvidersConnectorsListCall) Do(opts ...googleapi.CallOption) (*ListConnectorsResponse, error) { gensupport.SetOptions(c.urlParams_, opts...) res, err := c.doRequest("json") if res != nil && res.StatusCode == http.StatusNotModified { @@ -9455,7 +11721,7 @@ func (c *ProjectsLocationsProvidersTestIamPermissionsCall) Do(opts ...googleapi. if err := googleapi.CheckResponse(res); err != nil { return nil, gensupport.WrapError(err) } - ret := &TestIamPermissionsResponse{ + ret := &ListConnectorsResponse{ ServerResponse: googleapi.ServerResponse{ Header: res.Header, HTTPStatusCode: res.StatusCode, @@ -9467,28 +11733,41 @@ func (c *ProjectsLocationsProvidersTestIamPermissionsCall) Do(opts ...googleapi. } return ret, nil // { - // "description": "Returns permissions that a caller has on the specified resource. If the resource does not exist, this will return an empty set of permissions, not a `NOT_FOUND` error. Note: This operation is designed to be used for building permission-aware UIs and command-line tools, not for authorization checking. This operation may \"fail open\" without warning.", - // "flatPath": "v1/projects/{projectsId}/locations/{locationsId}/providers/{providersId}:testIamPermissions", - // "httpMethod": "POST", - // "id": "connectors.projects.locations.providers.testIamPermissions", + // "description": "Lists Connectors in a given project and location.", + // "flatPath": "v1/projects/{projectsId}/locations/{locationsId}/providers/{providersId}/connectors", + // "httpMethod": "GET", + // "id": "connectors.projects.locations.providers.connectors.list", // "parameterOrder": [ - // "resource" + // "parent" // ], // "parameters": { - // "resource": { - // "description": "REQUIRED: The resource for which the policy detail is being requested. See [Resource names](https://cloud.google.com/apis/design/resource_names) for the appropriate value for this field.", + // "filter": { + // "description": "Filter string.", + // "location": "query", + // "type": "string" + // }, + // "pageSize": { + // "description": "Page size.", + // "format": "int32", + // "location": "query", + // "type": "integer" + // }, + // "pageToken": { + // "description": "Page token.", + // "location": "query", + // "type": "string" + // }, + // "parent": { + // "description": "Required. Parent resource of the connectors, of the form: `projects/*/locations/*/providers/*` Only global location is supported for Connector resource.", // "location": "path", // "pattern": "^projects/[^/]+/locations/[^/]+/providers/[^/]+$", // "required": true, // "type": "string" // } // }, - // "path": "v1/{+resource}:testIamPermissions", - // "request": { - // "$ref": "TestIamPermissionsRequest" - // }, + // "path": "v1/{+parent}/connectors", // "response": { - // "$ref": "TestIamPermissionsResponse" + // "$ref": "ListConnectorsResponse" // }, // "scopes": [ // "https://www.googleapis.com/auth/cloud-platform" @@ -9497,9 +11776,30 @@ func (c *ProjectsLocationsProvidersTestIamPermissionsCall) Do(opts ...googleapi. } -// method id "connectors.projects.locations.providers.connectors.get": +// 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 *ProjectsLocationsProvidersConnectorsListCall) Pages(ctx context.Context, f func(*ListConnectorsResponse) 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 ProjectsLocationsProvidersConnectorsGetCall struct { +// method id "connectors.projects.locations.providers.connectors.versions.get": + +type ProjectsLocationsProvidersConnectorsVersionsGetCall struct { s *Service name string urlParams_ gensupport.URLParams @@ -9508,21 +11808,38 @@ type ProjectsLocationsProvidersConnectorsGetCall struct { header_ http.Header } -// Get: Gets details of a single Connector. +// Get: Gets details of a single connector version. // // - name: Resource name of the form: -// `projects/*/locations/*/providers/*/connectors/*` Only global -// location is supported for Connector resource. -func (r *ProjectsLocationsProvidersConnectorsService) Get(name string) *ProjectsLocationsProvidersConnectorsGetCall { - c := &ProjectsLocationsProvidersConnectorsGetCall{s: r.s, urlParams_: make(gensupport.URLParams)} +// `projects/*/locations/*/providers/*/connectors/*/versions/*` Only +// global location is supported for ConnectorVersion resource. +func (r *ProjectsLocationsProvidersConnectorsVersionsService) Get(name string) *ProjectsLocationsProvidersConnectorsVersionsGetCall { + c := &ProjectsLocationsProvidersConnectorsVersionsGetCall{s: r.s, urlParams_: make(gensupport.URLParams)} c.name = name return c } +// View sets the optional parameter "view": Specifies which fields of +// the ConnectorVersion are returned in the response. Defaults to +// `CUSTOMER` view. +// +// Possible values: +// +// "CONNECTOR_VERSION_VIEW_UNSPECIFIED" - +// +// CONNECTOR_VERSION_VIEW_UNSPECIFIED. +// +// "CONNECTOR_VERSION_VIEW_BASIC" - Do not include role grant configs. +// "CONNECTOR_VERSION_VIEW_FULL" - Include role grant configs. +func (c *ProjectsLocationsProvidersConnectorsVersionsGetCall) View(view string) *ProjectsLocationsProvidersConnectorsVersionsGetCall { + 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 *ProjectsLocationsProvidersConnectorsGetCall) Fields(s ...googleapi.Field) *ProjectsLocationsProvidersConnectorsGetCall { +func (c *ProjectsLocationsProvidersConnectorsVersionsGetCall) Fields(s ...googleapi.Field) *ProjectsLocationsProvidersConnectorsVersionsGetCall { c.urlParams_.Set("fields", googleapi.CombineFields(s)) return c } @@ -9532,7 +11849,7 @@ func (c *ProjectsLocationsProvidersConnectorsGetCall) Fields(s ...googleapi.Fiel // 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 *ProjectsLocationsProvidersConnectorsGetCall) IfNoneMatch(entityTag string) *ProjectsLocationsProvidersConnectorsGetCall { +func (c *ProjectsLocationsProvidersConnectorsVersionsGetCall) IfNoneMatch(entityTag string) *ProjectsLocationsProvidersConnectorsVersionsGetCall { c.ifNoneMatch_ = entityTag return c } @@ -9540,21 +11857,21 @@ func (c *ProjectsLocationsProvidersConnectorsGetCall) IfNoneMatch(entityTag stri // 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 *ProjectsLocationsProvidersConnectorsGetCall) Context(ctx context.Context) *ProjectsLocationsProvidersConnectorsGetCall { +func (c *ProjectsLocationsProvidersConnectorsVersionsGetCall) Context(ctx context.Context) *ProjectsLocationsProvidersConnectorsVersionsGetCall { 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 *ProjectsLocationsProvidersConnectorsGetCall) Header() http.Header { +func (c *ProjectsLocationsProvidersConnectorsVersionsGetCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) } return c.header_ } -func (c *ProjectsLocationsProvidersConnectorsGetCall) doRequest(alt string) (*http.Response, error) { +func (c *ProjectsLocationsProvidersConnectorsVersionsGetCall) 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_ { @@ -9580,14 +11897,14 @@ func (c *ProjectsLocationsProvidersConnectorsGetCall) doRequest(alt string) (*ht return gensupport.SendRequest(c.ctx_, c.s.client, req) } -// Do executes the "connectors.projects.locations.providers.connectors.get" call. -// Exactly one of *Connector or error will be non-nil. Any non-2xx -// status code is an error. Response headers are in either -// *Connector.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 *ProjectsLocationsProvidersConnectorsGetCall) Do(opts ...googleapi.CallOption) (*Connector, error) { +// Do executes the "connectors.projects.locations.providers.connectors.versions.get" call. +// Exactly one of *ConnectorVersion or error will be non-nil. Any +// non-2xx status code is an error. Response headers are in either +// *ConnectorVersion.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 *ProjectsLocationsProvidersConnectorsVersionsGetCall) Do(opts ...googleapi.CallOption) (*ConnectorVersion, error) { gensupport.SetOptions(c.urlParams_, opts...) res, err := c.doRequest("json") if res != nil && res.StatusCode == http.StatusNotModified { @@ -9606,7 +11923,7 @@ func (c *ProjectsLocationsProvidersConnectorsGetCall) Do(opts ...googleapi.CallO if err := googleapi.CheckResponse(res); err != nil { return nil, gensupport.WrapError(err) } - ret := &Connector{ + ret := &ConnectorVersion{ ServerResponse: googleapi.ServerResponse{ Header: res.Header, HTTPStatusCode: res.StatusCode, @@ -9618,25 +11935,40 @@ func (c *ProjectsLocationsProvidersConnectorsGetCall) Do(opts ...googleapi.CallO } return ret, nil // { - // "description": "Gets details of a single Connector.", - // "flatPath": "v1/projects/{projectsId}/locations/{locationsId}/providers/{providersId}/connectors/{connectorsId}", + // "description": "Gets details of a single connector version.", + // "flatPath": "v1/projects/{projectsId}/locations/{locationsId}/providers/{providersId}/connectors/{connectorsId}/versions/{versionsId}", // "httpMethod": "GET", - // "id": "connectors.projects.locations.providers.connectors.get", + // "id": "connectors.projects.locations.providers.connectors.versions.get", // "parameterOrder": [ // "name" // ], // "parameters": { // "name": { - // "description": "Required. Resource name of the form: `projects/*/locations/*/providers/*/connectors/*` Only global location is supported for Connector resource.", + // "description": "Required. Resource name of the form: `projects/*/locations/*/providers/*/connectors/*/versions/*` Only global location is supported for ConnectorVersion resource.", // "location": "path", - // "pattern": "^projects/[^/]+/locations/[^/]+/providers/[^/]+/connectors/[^/]+$", + // "pattern": "^projects/[^/]+/locations/[^/]+/providers/[^/]+/connectors/[^/]+/versions/[^/]+$", // "required": true, // "type": "string" + // }, + // "view": { + // "description": "Specifies which fields of the ConnectorVersion are returned in the response. Defaults to `CUSTOMER` view.", + // "enum": [ + // "CONNECTOR_VERSION_VIEW_UNSPECIFIED", + // "CONNECTOR_VERSION_VIEW_BASIC", + // "CONNECTOR_VERSION_VIEW_FULL" + // ], + // "enumDescriptions": [ + // "CONNECTOR_VERSION_VIEW_UNSPECIFIED.", + // "Do not include role grant configs.", + // "Include role grant configs." + // ], + // "location": "query", + // "type": "string" // } // }, // "path": "v1/{+name}", // "response": { - // "$ref": "Connector" + // "$ref": "ConnectorVersion" // }, // "scopes": [ // "https://www.googleapis.com/auth/cloud-platform" @@ -9645,9 +11977,9 @@ func (c *ProjectsLocationsProvidersConnectorsGetCall) Do(opts ...googleapi.CallO } -// method id "connectors.projects.locations.providers.connectors.list": +// method id "connectors.projects.locations.providers.connectors.versions.list": -type ProjectsLocationsProvidersConnectorsListCall struct { +type ProjectsLocationsProvidersConnectorsVersionsListCall struct { s *Service parent string urlParams_ gensupport.URLParams @@ -9656,39 +11988,50 @@ type ProjectsLocationsProvidersConnectorsListCall struct { header_ http.Header } -// List: Lists Connectors in a given project and location. +// List: Lists Connector Versions in a given project and location. // // - parent: Parent resource of the connectors, of the form: -// `projects/*/locations/*/providers/*` Only global location is -// supported for Connector resource. -func (r *ProjectsLocationsProvidersConnectorsService) List(parent string) *ProjectsLocationsProvidersConnectorsListCall { - c := &ProjectsLocationsProvidersConnectorsListCall{s: r.s, urlParams_: make(gensupport.URLParams)} +// `projects/*/locations/*/providers/*/connectors/*` Only global +// location is supported for ConnectorVersion resource. +func (r *ProjectsLocationsProvidersConnectorsVersionsService) List(parent string) *ProjectsLocationsProvidersConnectorsVersionsListCall { + c := &ProjectsLocationsProvidersConnectorsVersionsListCall{s: r.s, urlParams_: make(gensupport.URLParams)} c.parent = parent return c } -// Filter sets the optional parameter "filter": Filter string. -func (c *ProjectsLocationsProvidersConnectorsListCall) Filter(filter string) *ProjectsLocationsProvidersConnectorsListCall { - c.urlParams_.Set("filter", filter) - return c -} - // PageSize sets the optional parameter "pageSize": Page size. -func (c *ProjectsLocationsProvidersConnectorsListCall) PageSize(pageSize int64) *ProjectsLocationsProvidersConnectorsListCall { +func (c *ProjectsLocationsProvidersConnectorsVersionsListCall) PageSize(pageSize int64) *ProjectsLocationsProvidersConnectorsVersionsListCall { c.urlParams_.Set("pageSize", fmt.Sprint(pageSize)) return c } // PageToken sets the optional parameter "pageToken": Page token. -func (c *ProjectsLocationsProvidersConnectorsListCall) PageToken(pageToken string) *ProjectsLocationsProvidersConnectorsListCall { +func (c *ProjectsLocationsProvidersConnectorsVersionsListCall) PageToken(pageToken string) *ProjectsLocationsProvidersConnectorsVersionsListCall { c.urlParams_.Set("pageToken", pageToken) return c } +// View sets the optional parameter "view": Specifies which fields of +// the ConnectorVersion are returned in the response. Defaults to +// `BASIC` view. +// +// Possible values: +// +// "CONNECTOR_VERSION_VIEW_UNSPECIFIED" - +// +// CONNECTOR_VERSION_VIEW_UNSPECIFIED. +// +// "CONNECTOR_VERSION_VIEW_BASIC" - Do not include role grant configs. +// "CONNECTOR_VERSION_VIEW_FULL" - Include role grant configs. +func (c *ProjectsLocationsProvidersConnectorsVersionsListCall) View(view string) *ProjectsLocationsProvidersConnectorsVersionsListCall { + 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 *ProjectsLocationsProvidersConnectorsListCall) Fields(s ...googleapi.Field) *ProjectsLocationsProvidersConnectorsListCall { +func (c *ProjectsLocationsProvidersConnectorsVersionsListCall) Fields(s ...googleapi.Field) *ProjectsLocationsProvidersConnectorsVersionsListCall { c.urlParams_.Set("fields", googleapi.CombineFields(s)) return c } @@ -9698,7 +12041,7 @@ func (c *ProjectsLocationsProvidersConnectorsListCall) Fields(s ...googleapi.Fie // 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 *ProjectsLocationsProvidersConnectorsListCall) IfNoneMatch(entityTag string) *ProjectsLocationsProvidersConnectorsListCall { +func (c *ProjectsLocationsProvidersConnectorsVersionsListCall) IfNoneMatch(entityTag string) *ProjectsLocationsProvidersConnectorsVersionsListCall { c.ifNoneMatch_ = entityTag return c } @@ -9706,21 +12049,21 @@ func (c *ProjectsLocationsProvidersConnectorsListCall) IfNoneMatch(entityTag str // 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 *ProjectsLocationsProvidersConnectorsListCall) Context(ctx context.Context) *ProjectsLocationsProvidersConnectorsListCall { +func (c *ProjectsLocationsProvidersConnectorsVersionsListCall) Context(ctx context.Context) *ProjectsLocationsProvidersConnectorsVersionsListCall { 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 *ProjectsLocationsProvidersConnectorsListCall) Header() http.Header { +func (c *ProjectsLocationsProvidersConnectorsVersionsListCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) } return c.header_ } -func (c *ProjectsLocationsProvidersConnectorsListCall) doRequest(alt string) (*http.Response, error) { +func (c *ProjectsLocationsProvidersConnectorsVersionsListCall) 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_ { @@ -9733,7 +12076,7 @@ func (c *ProjectsLocationsProvidersConnectorsListCall) doRequest(alt string) (*h var body io.Reader = nil c.urlParams_.Set("alt", alt) c.urlParams_.Set("prettyPrint", "false") - urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+parent}/connectors") + urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+parent}/versions") urls += "?" + c.urlParams_.Encode() req, err := http.NewRequest("GET", urls, body) if err != nil { @@ -9746,14 +12089,14 @@ func (c *ProjectsLocationsProvidersConnectorsListCall) doRequest(alt string) (*h return gensupport.SendRequest(c.ctx_, c.s.client, req) } -// Do executes the "connectors.projects.locations.providers.connectors.list" call. -// Exactly one of *ListConnectorsResponse or error will be non-nil. Any -// non-2xx status code is an error. Response headers are in either -// *ListConnectorsResponse.ServerResponse.Header or (if a response was -// returned at all) in error.(*googleapi.Error).Header. Use +// Do executes the "connectors.projects.locations.providers.connectors.versions.list" call. +// Exactly one of *ListConnectorVersionsResponse or error will be +// non-nil. Any non-2xx status code is an error. Response headers are in +// either *ListConnectorVersionsResponse.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 *ProjectsLocationsProvidersConnectorsListCall) Do(opts ...googleapi.CallOption) (*ListConnectorsResponse, error) { +func (c *ProjectsLocationsProvidersConnectorsVersionsListCall) Do(opts ...googleapi.CallOption) (*ListConnectorVersionsResponse, error) { gensupport.SetOptions(c.urlParams_, opts...) res, err := c.doRequest("json") if res != nil && res.StatusCode == http.StatusNotModified { @@ -9772,7 +12115,7 @@ func (c *ProjectsLocationsProvidersConnectorsListCall) Do(opts ...googleapi.Call if err := googleapi.CheckResponse(res); err != nil { return nil, gensupport.WrapError(err) } - ret := &ListConnectorsResponse{ + ret := &ListConnectorVersionsResponse{ ServerResponse: googleapi.ServerResponse{ Header: res.Header, HTTPStatusCode: res.StatusCode, @@ -9784,19 +12127,14 @@ func (c *ProjectsLocationsProvidersConnectorsListCall) Do(opts ...googleapi.Call } return ret, nil // { - // "description": "Lists Connectors in a given project and location.", - // "flatPath": "v1/projects/{projectsId}/locations/{locationsId}/providers/{providersId}/connectors", + // "description": "Lists Connector Versions in a given project and location.", + // "flatPath": "v1/projects/{projectsId}/locations/{locationsId}/providers/{providersId}/connectors/{connectorsId}/versions", // "httpMethod": "GET", - // "id": "connectors.projects.locations.providers.connectors.list", + // "id": "connectors.projects.locations.providers.connectors.versions.list", // "parameterOrder": [ // "parent" // ], // "parameters": { - // "filter": { - // "description": "Filter string.", - // "location": "query", - // "type": "string" - // }, // "pageSize": { // "description": "Page size.", // "format": "int32", @@ -9809,16 +12147,31 @@ func (c *ProjectsLocationsProvidersConnectorsListCall) Do(opts ...googleapi.Call // "type": "string" // }, // "parent": { - // "description": "Required. Parent resource of the connectors, of the form: `projects/*/locations/*/providers/*` Only global location is supported for Connector resource.", + // "description": "Required. Parent resource of the connectors, of the form: `projects/*/locations/*/providers/*/connectors/*` Only global location is supported for ConnectorVersion resource.", // "location": "path", - // "pattern": "^projects/[^/]+/locations/[^/]+/providers/[^/]+$", + // "pattern": "^projects/[^/]+/locations/[^/]+/providers/[^/]+/connectors/[^/]+$", // "required": true, // "type": "string" + // }, + // "view": { + // "description": "Specifies which fields of the ConnectorVersion are returned in the response. Defaults to `BASIC` view.", + // "enum": [ + // "CONNECTOR_VERSION_VIEW_UNSPECIFIED", + // "CONNECTOR_VERSION_VIEW_BASIC", + // "CONNECTOR_VERSION_VIEW_FULL" + // ], + // "enumDescriptions": [ + // "CONNECTOR_VERSION_VIEW_UNSPECIFIED.", + // "Do not include role grant configs.", + // "Include role grant configs." + // ], + // "location": "query", + // "type": "string" // } // }, - // "path": "v1/{+parent}/connectors", + // "path": "v1/{+parent}/versions", // "response": { - // "$ref": "ListConnectorsResponse" + // "$ref": "ListConnectorVersionsResponse" // }, // "scopes": [ // "https://www.googleapis.com/auth/cloud-platform" @@ -9830,7 +12183,7 @@ func (c *ProjectsLocationsProvidersConnectorsListCall) Do(opts ...googleapi.Call // 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 *ProjectsLocationsProvidersConnectorsListCall) Pages(ctx context.Context, f func(*ListConnectorsResponse) error) error { +func (c *ProjectsLocationsProvidersConnectorsVersionsListCall) Pages(ctx context.Context, f func(*ListConnectorVersionsResponse) error) error { c.ctx_ = ctx defer c.PageToken(c.urlParams_.Get("pageToken")) // reset paging to original point for { @@ -9848,9 +12201,9 @@ func (c *ProjectsLocationsProvidersConnectorsListCall) Pages(ctx context.Context } } -// method id "connectors.projects.locations.providers.connectors.versions.get": +// method id "connectors.projects.locations.providers.connectors.versions.eventtypes.get": -type ProjectsLocationsProvidersConnectorsVersionsGetCall struct { +type ProjectsLocationsProvidersConnectorsVersionsEventtypesGetCall struct { s *Service name string urlParams_ gensupport.URLParams @@ -9859,38 +12212,21 @@ type ProjectsLocationsProvidersConnectorsVersionsGetCall struct { header_ http.Header } -// Get: Gets details of a single connector version. +// Get: Gets details of a single event type. // // - name: Resource name of the form: -// `projects/*/locations/*/providers/*/connectors/*/versions/*` Only -// global location is supported for ConnectorVersion resource. -func (r *ProjectsLocationsProvidersConnectorsVersionsService) Get(name string) *ProjectsLocationsProvidersConnectorsVersionsGetCall { - c := &ProjectsLocationsProvidersConnectorsVersionsGetCall{s: r.s, urlParams_: make(gensupport.URLParams)} +// `projects/*/locations/*/providers/*/connectors/*/versions/*/eventtyp +// es/*` Only global location is supported for EventType resource. +func (r *ProjectsLocationsProvidersConnectorsVersionsEventtypesService) Get(name string) *ProjectsLocationsProvidersConnectorsVersionsEventtypesGetCall { + c := &ProjectsLocationsProvidersConnectorsVersionsEventtypesGetCall{s: r.s, urlParams_: make(gensupport.URLParams)} c.name = name return c } -// View sets the optional parameter "view": Specifies which fields of -// the ConnectorVersion are returned in the response. Defaults to -// `CUSTOMER` view. -// -// Possible values: -// -// "CONNECTOR_VERSION_VIEW_UNSPECIFIED" - -// -// CONNECTOR_VERSION_VIEW_UNSPECIFIED. -// -// "CONNECTOR_VERSION_VIEW_BASIC" - Do not include role grant configs. -// "CONNECTOR_VERSION_VIEW_FULL" - Include role grant configs. -func (c *ProjectsLocationsProvidersConnectorsVersionsGetCall) View(view string) *ProjectsLocationsProvidersConnectorsVersionsGetCall { - 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 *ProjectsLocationsProvidersConnectorsVersionsGetCall) Fields(s ...googleapi.Field) *ProjectsLocationsProvidersConnectorsVersionsGetCall { +func (c *ProjectsLocationsProvidersConnectorsVersionsEventtypesGetCall) Fields(s ...googleapi.Field) *ProjectsLocationsProvidersConnectorsVersionsEventtypesGetCall { c.urlParams_.Set("fields", googleapi.CombineFields(s)) return c } @@ -9900,7 +12236,7 @@ func (c *ProjectsLocationsProvidersConnectorsVersionsGetCall) Fields(s ...google // getting updates only after the object has changed since the last // request. Use googleapi.IsNotModified to check whether the response // error from Do is the result of In-None-Match. -func (c *ProjectsLocationsProvidersConnectorsVersionsGetCall) IfNoneMatch(entityTag string) *ProjectsLocationsProvidersConnectorsVersionsGetCall { +func (c *ProjectsLocationsProvidersConnectorsVersionsEventtypesGetCall) IfNoneMatch(entityTag string) *ProjectsLocationsProvidersConnectorsVersionsEventtypesGetCall { c.ifNoneMatch_ = entityTag return c } @@ -9908,21 +12244,21 @@ func (c *ProjectsLocationsProvidersConnectorsVersionsGetCall) IfNoneMatch(entity // Context sets the context to be used in this call's Do method. Any // pending HTTP request will be aborted if the provided context is // canceled. -func (c *ProjectsLocationsProvidersConnectorsVersionsGetCall) Context(ctx context.Context) *ProjectsLocationsProvidersConnectorsVersionsGetCall { +func (c *ProjectsLocationsProvidersConnectorsVersionsEventtypesGetCall) Context(ctx context.Context) *ProjectsLocationsProvidersConnectorsVersionsEventtypesGetCall { 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 *ProjectsLocationsProvidersConnectorsVersionsGetCall) Header() http.Header { +func (c *ProjectsLocationsProvidersConnectorsVersionsEventtypesGetCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) } return c.header_ } -func (c *ProjectsLocationsProvidersConnectorsVersionsGetCall) doRequest(alt string) (*http.Response, error) { +func (c *ProjectsLocationsProvidersConnectorsVersionsEventtypesGetCall) 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_ { @@ -9948,14 +12284,14 @@ func (c *ProjectsLocationsProvidersConnectorsVersionsGetCall) doRequest(alt stri return gensupport.SendRequest(c.ctx_, c.s.client, req) } -// Do executes the "connectors.projects.locations.providers.connectors.versions.get" call. -// Exactly one of *ConnectorVersion or error will be non-nil. Any -// non-2xx status code is an error. Response headers are in either -// *ConnectorVersion.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 *ProjectsLocationsProvidersConnectorsVersionsGetCall) Do(opts ...googleapi.CallOption) (*ConnectorVersion, error) { +// Do executes the "connectors.projects.locations.providers.connectors.versions.eventtypes.get" call. +// Exactly one of *EventType or error will be non-nil. Any non-2xx +// status code is an error. Response headers are in either +// *EventType.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 *ProjectsLocationsProvidersConnectorsVersionsEventtypesGetCall) Do(opts ...googleapi.CallOption) (*EventType, error) { gensupport.SetOptions(c.urlParams_, opts...) res, err := c.doRequest("json") if res != nil && res.StatusCode == http.StatusNotModified { @@ -9974,7 +12310,7 @@ func (c *ProjectsLocationsProvidersConnectorsVersionsGetCall) Do(opts ...googlea if err := googleapi.CheckResponse(res); err != nil { return nil, gensupport.WrapError(err) } - ret := &ConnectorVersion{ + ret := &EventType{ ServerResponse: googleapi.ServerResponse{ Header: res.Header, HTTPStatusCode: res.StatusCode, @@ -9986,40 +12322,25 @@ func (c *ProjectsLocationsProvidersConnectorsVersionsGetCall) Do(opts ...googlea } return ret, nil // { - // "description": "Gets details of a single connector version.", - // "flatPath": "v1/projects/{projectsId}/locations/{locationsId}/providers/{providersId}/connectors/{connectorsId}/versions/{versionsId}", + // "description": "Gets details of a single event type.", + // "flatPath": "v1/projects/{projectsId}/locations/{locationsId}/providers/{providersId}/connectors/{connectorsId}/versions/{versionsId}/eventtypes/{eventtypesId}", // "httpMethod": "GET", - // "id": "connectors.projects.locations.providers.connectors.versions.get", + // "id": "connectors.projects.locations.providers.connectors.versions.eventtypes.get", // "parameterOrder": [ // "name" // ], // "parameters": { // "name": { - // "description": "Required. Resource name of the form: `projects/*/locations/*/providers/*/connectors/*/versions/*` Only global location is supported for ConnectorVersion resource.", + // "description": "Required. Resource name of the form: `projects/*/locations/*/providers/*/connectors/*/versions/*/eventtypes/*` Only global location is supported for EventType resource.", // "location": "path", - // "pattern": "^projects/[^/]+/locations/[^/]+/providers/[^/]+/connectors/[^/]+/versions/[^/]+$", + // "pattern": "^projects/[^/]+/locations/[^/]+/providers/[^/]+/connectors/[^/]+/versions/[^/]+/eventtypes/[^/]+$", // "required": true, // "type": "string" - // }, - // "view": { - // "description": "Specifies which fields of the ConnectorVersion are returned in the response. Defaults to `CUSTOMER` view.", - // "enum": [ - // "CONNECTOR_VERSION_VIEW_UNSPECIFIED", - // "CONNECTOR_VERSION_VIEW_BASIC", - // "CONNECTOR_VERSION_VIEW_FULL" - // ], - // "enumDescriptions": [ - // "CONNECTOR_VERSION_VIEW_UNSPECIFIED.", - // "Do not include role grant configs.", - // "Include role grant configs." - // ], - // "location": "query", - // "type": "string" // } // }, // "path": "v1/{+name}", // "response": { - // "$ref": "ConnectorVersion" + // "$ref": "EventType" // }, // "scopes": [ // "https://www.googleapis.com/auth/cloud-platform" @@ -10028,9 +12349,9 @@ func (c *ProjectsLocationsProvidersConnectorsVersionsGetCall) Do(opts ...googlea } -// method id "connectors.projects.locations.providers.connectors.versions.list": +// method id "connectors.projects.locations.providers.connectors.versions.eventtypes.list": -type ProjectsLocationsProvidersConnectorsVersionsListCall struct { +type ProjectsLocationsProvidersConnectorsVersionsEventtypesListCall struct { s *Service parent string urlParams_ gensupport.URLParams @@ -10039,50 +12360,33 @@ type ProjectsLocationsProvidersConnectorsVersionsListCall struct { header_ http.Header } -// List: Lists Connector Versions in a given project and location. +// List: Lists Event Types in a given Connector Version. // // - parent: Parent resource of the connectors, of the form: -// `projects/*/locations/*/providers/*/connectors/*` Only global -// location is supported for ConnectorVersion resource. -func (r *ProjectsLocationsProvidersConnectorsVersionsService) List(parent string) *ProjectsLocationsProvidersConnectorsVersionsListCall { - c := &ProjectsLocationsProvidersConnectorsVersionsListCall{s: r.s, urlParams_: make(gensupport.URLParams)} +// `projects/*/locations/*/providers/*/connectors/*/versions/*` Only +// global location is supported for EventType resource. +func (r *ProjectsLocationsProvidersConnectorsVersionsEventtypesService) List(parent string) *ProjectsLocationsProvidersConnectorsVersionsEventtypesListCall { + c := &ProjectsLocationsProvidersConnectorsVersionsEventtypesListCall{s: r.s, urlParams_: make(gensupport.URLParams)} c.parent = parent return c } // PageSize sets the optional parameter "pageSize": Page size. -func (c *ProjectsLocationsProvidersConnectorsVersionsListCall) PageSize(pageSize int64) *ProjectsLocationsProvidersConnectorsVersionsListCall { +func (c *ProjectsLocationsProvidersConnectorsVersionsEventtypesListCall) PageSize(pageSize int64) *ProjectsLocationsProvidersConnectorsVersionsEventtypesListCall { c.urlParams_.Set("pageSize", fmt.Sprint(pageSize)) return c } // PageToken sets the optional parameter "pageToken": Page token. -func (c *ProjectsLocationsProvidersConnectorsVersionsListCall) PageToken(pageToken string) *ProjectsLocationsProvidersConnectorsVersionsListCall { +func (c *ProjectsLocationsProvidersConnectorsVersionsEventtypesListCall) PageToken(pageToken string) *ProjectsLocationsProvidersConnectorsVersionsEventtypesListCall { c.urlParams_.Set("pageToken", pageToken) return c } -// View sets the optional parameter "view": Specifies which fields of -// the ConnectorVersion are returned in the response. Defaults to -// `BASIC` view. -// -// Possible values: -// -// "CONNECTOR_VERSION_VIEW_UNSPECIFIED" - -// -// CONNECTOR_VERSION_VIEW_UNSPECIFIED. -// -// "CONNECTOR_VERSION_VIEW_BASIC" - Do not include role grant configs. -// "CONNECTOR_VERSION_VIEW_FULL" - Include role grant configs. -func (c *ProjectsLocationsProvidersConnectorsVersionsListCall) View(view string) *ProjectsLocationsProvidersConnectorsVersionsListCall { - 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 *ProjectsLocationsProvidersConnectorsVersionsListCall) Fields(s ...googleapi.Field) *ProjectsLocationsProvidersConnectorsVersionsListCall { +func (c *ProjectsLocationsProvidersConnectorsVersionsEventtypesListCall) Fields(s ...googleapi.Field) *ProjectsLocationsProvidersConnectorsVersionsEventtypesListCall { c.urlParams_.Set("fields", googleapi.CombineFields(s)) return c } @@ -10092,7 +12396,7 @@ func (c *ProjectsLocationsProvidersConnectorsVersionsListCall) Fields(s ...googl // getting updates only after the object has changed since the last // request. Use googleapi.IsNotModified to check whether the response // error from Do is the result of In-None-Match. -func (c *ProjectsLocationsProvidersConnectorsVersionsListCall) IfNoneMatch(entityTag string) *ProjectsLocationsProvidersConnectorsVersionsListCall { +func (c *ProjectsLocationsProvidersConnectorsVersionsEventtypesListCall) IfNoneMatch(entityTag string) *ProjectsLocationsProvidersConnectorsVersionsEventtypesListCall { c.ifNoneMatch_ = entityTag return c } @@ -10100,21 +12404,21 @@ func (c *ProjectsLocationsProvidersConnectorsVersionsListCall) IfNoneMatch(entit // Context sets the context to be used in this call's Do method. Any // pending HTTP request will be aborted if the provided context is // canceled. -func (c *ProjectsLocationsProvidersConnectorsVersionsListCall) Context(ctx context.Context) *ProjectsLocationsProvidersConnectorsVersionsListCall { +func (c *ProjectsLocationsProvidersConnectorsVersionsEventtypesListCall) Context(ctx context.Context) *ProjectsLocationsProvidersConnectorsVersionsEventtypesListCall { 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 *ProjectsLocationsProvidersConnectorsVersionsListCall) Header() http.Header { +func (c *ProjectsLocationsProvidersConnectorsVersionsEventtypesListCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) } return c.header_ } -func (c *ProjectsLocationsProvidersConnectorsVersionsListCall) doRequest(alt string) (*http.Response, error) { +func (c *ProjectsLocationsProvidersConnectorsVersionsEventtypesListCall) 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_ { @@ -10127,7 +12431,7 @@ func (c *ProjectsLocationsProvidersConnectorsVersionsListCall) doRequest(alt str var body io.Reader = nil c.urlParams_.Set("alt", alt) c.urlParams_.Set("prettyPrint", "false") - urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+parent}/versions") + urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+parent}/eventtypes") urls += "?" + c.urlParams_.Encode() req, err := http.NewRequest("GET", urls, body) if err != nil { @@ -10140,14 +12444,14 @@ func (c *ProjectsLocationsProvidersConnectorsVersionsListCall) doRequest(alt str return gensupport.SendRequest(c.ctx_, c.s.client, req) } -// Do executes the "connectors.projects.locations.providers.connectors.versions.list" call. -// Exactly one of *ListConnectorVersionsResponse or error will be -// non-nil. Any non-2xx status code is an error. Response headers are in -// either *ListConnectorVersionsResponse.ServerResponse.Header or (if a -// response was returned at all) in error.(*googleapi.Error).Header. Use +// Do executes the "connectors.projects.locations.providers.connectors.versions.eventtypes.list" call. +// Exactly one of *ListEventTypesResponse or error will be non-nil. Any +// non-2xx status code is an error. Response headers are in either +// *ListEventTypesResponse.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 *ProjectsLocationsProvidersConnectorsVersionsListCall) Do(opts ...googleapi.CallOption) (*ListConnectorVersionsResponse, error) { +func (c *ProjectsLocationsProvidersConnectorsVersionsEventtypesListCall) Do(opts ...googleapi.CallOption) (*ListEventTypesResponse, error) { gensupport.SetOptions(c.urlParams_, opts...) res, err := c.doRequest("json") if res != nil && res.StatusCode == http.StatusNotModified { @@ -10166,7 +12470,7 @@ func (c *ProjectsLocationsProvidersConnectorsVersionsListCall) Do(opts ...google if err := googleapi.CheckResponse(res); err != nil { return nil, gensupport.WrapError(err) } - ret := &ListConnectorVersionsResponse{ + ret := &ListEventTypesResponse{ ServerResponse: googleapi.ServerResponse{ Header: res.Header, HTTPStatusCode: res.StatusCode, @@ -10178,10 +12482,10 @@ func (c *ProjectsLocationsProvidersConnectorsVersionsListCall) Do(opts ...google } return ret, nil // { - // "description": "Lists Connector Versions in a given project and location.", - // "flatPath": "v1/projects/{projectsId}/locations/{locationsId}/providers/{providersId}/connectors/{connectorsId}/versions", + // "description": "Lists Event Types in a given Connector Version.", + // "flatPath": "v1/projects/{projectsId}/locations/{locationsId}/providers/{providersId}/connectors/{connectorsId}/versions/{versionsId}/eventtypes", // "httpMethod": "GET", - // "id": "connectors.projects.locations.providers.connectors.versions.list", + // "id": "connectors.projects.locations.providers.connectors.versions.eventtypes.list", // "parameterOrder": [ // "parent" // ], @@ -10198,31 +12502,16 @@ func (c *ProjectsLocationsProvidersConnectorsVersionsListCall) Do(opts ...google // "type": "string" // }, // "parent": { - // "description": "Required. Parent resource of the connectors, of the form: `projects/*/locations/*/providers/*/connectors/*` Only global location is supported for ConnectorVersion resource.", + // "description": "Required. Parent resource of the connectors, of the form: `projects/*/locations/*/providers/*/connectors/*/versions/*` Only global location is supported for EventType resource.", // "location": "path", - // "pattern": "^projects/[^/]+/locations/[^/]+/providers/[^/]+/connectors/[^/]+$", + // "pattern": "^projects/[^/]+/locations/[^/]+/providers/[^/]+/connectors/[^/]+/versions/[^/]+$", // "required": true, // "type": "string" - // }, - // "view": { - // "description": "Specifies which fields of the ConnectorVersion are returned in the response. Defaults to `BASIC` view.", - // "enum": [ - // "CONNECTOR_VERSION_VIEW_UNSPECIFIED", - // "CONNECTOR_VERSION_VIEW_BASIC", - // "CONNECTOR_VERSION_VIEW_FULL" - // ], - // "enumDescriptions": [ - // "CONNECTOR_VERSION_VIEW_UNSPECIFIED.", - // "Do not include role grant configs.", - // "Include role grant configs." - // ], - // "location": "query", - // "type": "string" // } // }, - // "path": "v1/{+parent}/versions", + // "path": "v1/{+parent}/eventtypes", // "response": { - // "$ref": "ListConnectorVersionsResponse" + // "$ref": "ListEventTypesResponse" // }, // "scopes": [ // "https://www.googleapis.com/auth/cloud-platform" @@ -10234,7 +12523,7 @@ func (c *ProjectsLocationsProvidersConnectorsVersionsListCall) Do(opts ...google // Pages invokes f for each page of results. // A non-nil error returned from f will halt the iteration. // The provided context supersedes any context provided to the Context method. -func (c *ProjectsLocationsProvidersConnectorsVersionsListCall) Pages(ctx context.Context, f func(*ListConnectorVersionsResponse) error) error { +func (c *ProjectsLocationsProvidersConnectorsVersionsEventtypesListCall) Pages(ctx context.Context, f func(*ListEventTypesResponse) error) error { c.ctx_ = ctx defer c.PageToken(c.urlParams_.Get("pageToken")) // reset paging to original point for { diff --git a/container/v1/container-api.json b/container/v1/container-api.json index 45d258e3f98..02ea8820f4e 100644 --- a/container/v1/container-api.json +++ b/container/v1/container-api.json @@ -2540,7 +2540,7 @@ } } }, - "revision": "20230620", + "revision": "20230626", "rootUrl": "https://container.googleapis.com/", "schemas": { "AcceleratorConfig": { @@ -2644,6 +2644,33 @@ }, "type": "object" }, + "AdvancedDatapathObservabilityConfig": { + "description": "AdvancedDatapathObservabilityConfig specifies configuration of observability features of advanced datapath.", + "id": "AdvancedDatapathObservabilityConfig", + "properties": { + "enableMetrics": { + "description": "Expose flow metrics on nodes", + "type": "boolean" + }, + "relayMode": { + "description": "Method used to make Relay available", + "enum": [ + "RELAY_MODE_UNSPECIFIED", + "DISABLED", + "INTERNAL_VPC_LB", + "EXTERNAL_LB" + ], + "enumDescriptions": [ + "Default value. This shouldn't be used.", + "disabled", + "exposed via internal load balancer", + "exposed via external load balancer" + ], + "type": "string" + } + }, + "type": "object" + }, "AdvancedMachineFeatures": { "description": "Specifies options for controlling advanced machine features.", "id": "AdvancedMachineFeatures", @@ -3763,7 +3790,7 @@ "Default value", "Use GKE default DNS provider(kube-dns) for DNS resolution.", "Use CloudDNS for DNS resolution.", - "Use KubeDNS for DNS resolution" + "Use KubeDNS for DNS resolution." ], "type": "string" }, @@ -4200,7 +4227,7 @@ "type": "boolean" }, "defaultPodIpv4RangeUtilization": { - "description": "Output only. [Output only] The utilization of the cluster default IPv4 range for pod. The ratio is Usage/[Total number of IPs in the secondary range], Usage=numNodes*numZones*podIPsPerNode.", + "description": "Output only. [Output only] The utilization of the cluster default IPv4 range for the pod. The ratio is Usage/[Total number of IPs in the secondary range], Usage=numNodes*numZones*podIPsPerNode.", "format": "double", "readOnly": true, "type": "number" @@ -4765,6 +4792,10 @@ "description": "MonitoringConfig is cluster monitoring configuration.", "id": "MonitoringConfig", "properties": { + "advancedDatapathObservabilityConfig": { + "$ref": "AdvancedDatapathObservabilityConfig", + "description": "Configuration of Advanced Datapath Observability features." + }, "componentConfig": { "$ref": "MonitoringComponentConfig", "description": "Monitoring components configuration" @@ -5219,7 +5250,7 @@ "type": "string" }, "podIpv4RangeUtilization": { - "description": "Output only. [Output only] The utilization of the IPv4 range for pod. The ratio is Usage/[Total number of IPs in the secondary range], Usage=numNodes*numZones*podIPsPerNode.", + "description": "Output only. [Output only] The utilization of the IPv4 range for the pod. The ratio is Usage/[Total number of IPs in the secondary range], Usage=numNodes*numZones*podIPsPerNode.", "format": "double", "readOnly": true, "type": "number" diff --git a/container/v1/container-gen.go b/container/v1/container-gen.go index a6368a67be7..a6c9b20c87f 100644 --- a/container/v1/container-gen.go +++ b/container/v1/container-gen.go @@ -441,6 +441,45 @@ func (s *AddonsConfig) MarshalJSON() ([]byte, error) { return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } +// AdvancedDatapathObservabilityConfig: +// AdvancedDatapathObservabilityConfig specifies configuration of +// observability features of advanced datapath. +type AdvancedDatapathObservabilityConfig struct { + // EnableMetrics: Expose flow metrics on nodes + EnableMetrics bool `json:"enableMetrics,omitempty"` + + // RelayMode: Method used to make Relay available + // + // Possible values: + // "RELAY_MODE_UNSPECIFIED" - Default value. This shouldn't be used. + // "DISABLED" - disabled + // "INTERNAL_VPC_LB" - exposed via internal load balancer + // "EXTERNAL_LB" - exposed via external load balancer + RelayMode string `json:"relayMode,omitempty"` + + // ForceSendFields is a list of field names (e.g. "EnableMetrics") 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. "EnableMetrics") 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 *AdvancedDatapathObservabilityConfig) MarshalJSON() ([]byte, error) { + type NoMethod AdvancedDatapathObservabilityConfig + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + // AdvancedMachineFeatures: Specifies options for controlling advanced // machine features. type AdvancedMachineFeatures struct { @@ -2135,7 +2174,7 @@ type DNSConfig struct { // "PLATFORM_DEFAULT" - Use GKE default DNS provider(kube-dns) for DNS // resolution. // "CLOUD_DNS" - Use CloudDNS for DNS resolution. - // "KUBE_DNS" - Use KubeDNS for DNS resolution + // "KUBE_DNS" - Use KubeDNS for DNS resolution. ClusterDns string `json:"clusterDns,omitempty"` // ClusterDnsDomain: cluster_dns_domain is the suffix used for all @@ -2988,8 +3027,8 @@ type IPAllocationPolicy struct { CreateSubnetwork bool `json:"createSubnetwork,omitempty"` // DefaultPodIpv4RangeUtilization: Output only. [Output only] The - // utilization of the cluster default IPv4 range for pod. The ratio is - // Usage/[Total number of IPs in the secondary range], + // utilization of the cluster default IPv4 range for the pod. The ratio + // is Usage/[Total number of IPs in the secondary range], // Usage=numNodes*numZones*podIPsPerNode. DefaultPodIpv4RangeUtilization float64 `json:"defaultPodIpv4RangeUtilization,omitempty"` @@ -4082,6 +4121,10 @@ func (s *MonitoringComponentConfig) MarshalJSON() ([]byte, error) { // MonitoringConfig: MonitoringConfig is cluster monitoring // configuration. type MonitoringConfig struct { + // AdvancedDatapathObservabilityConfig: Configuration of Advanced + // Datapath Observability features. + AdvancedDatapathObservabilityConfig *AdvancedDatapathObservabilityConfig `json:"advancedDatapathObservabilityConfig,omitempty"` + // ComponentConfig: Monitoring components configuration ComponentConfig *MonitoringComponentConfig `json:"componentConfig,omitempty"` @@ -4089,21 +4132,22 @@ type MonitoringConfig struct { // Prometheus in the cluster. ManagedPrometheusConfig *ManagedPrometheusConfig `json:"managedPrometheusConfig,omitempty"` - // ForceSendFields is a list of field names (e.g. "ComponentConfig") 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 is a list of field names (e.g. + // "AdvancedDatapathObservabilityConfig") 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. "ComponentConfig") to - // include in API requests with the JSON null value. By default, fields - // with empty values are omitted from API requests. However, any field - // with an empty value appearing in NullFields will be sent to the - // server as null. It is an error if a field in this list has a - // non-empty value. This may be used to include null fields in Patch - // requests. + // NullFields is a list of field names (e.g. + // "AdvancedDatapathObservabilityConfig") 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:"-"` } @@ -4803,8 +4847,8 @@ type NodeNetworkConfig struct { PodIpv4CidrBlock string `json:"podIpv4CidrBlock,omitempty"` // PodIpv4RangeUtilization: Output only. [Output only] The utilization - // of the IPv4 range for pod. The ratio is Usage/[Total number of IPs in - // the secondary range], Usage=numNodes*numZones*podIPsPerNode. + // of the IPv4 range for the pod. The ratio is Usage/[Total number of + // IPs in the secondary range], Usage=numNodes*numZones*podIPsPerNode. PodIpv4RangeUtilization float64 `json:"podIpv4RangeUtilization,omitempty"` // PodRange: The ID of the secondary range for pod IPs. If diff --git a/dataplex/v1/dataplex-api.json b/dataplex/v1/dataplex-api.json index ea12b034286..f2dc6ea75f5 100644 --- a/dataplex/v1/dataplex-api.json +++ b/dataplex/v1/dataplex-api.json @@ -4269,7 +4269,7 @@ } } }, - "revision": "20230626", + "revision": "20230628", "rootUrl": "https://dataplex.googleapis.com/", "schemas": { "Empty": { @@ -5629,6 +5629,107 @@ "properties": {}, "type": "object" }, + "GoogleCloudDataplexV1DataQualityScanRuleResult": { + "description": "Information about the result of a data quality rule for data quality scan. The monitored resource is 'DataScan'.", + "id": "GoogleCloudDataplexV1DataQualityScanRuleResult", + "properties": { + "column": { + "description": "The column which this rule is evaluated against.", + "type": "string" + }, + "dataSource": { + "description": "The data source of the data scan (e.g. BigQuery table name).", + "type": "string" + }, + "evaluatedRowCount": { + "description": "The number of rows evaluated against the data quality rule. This field is only valid for rules of PER_ROW evaluation type.", + "format": "int64", + "type": "string" + }, + "evalutionType": { + "description": "The evaluation type of the data quality rule.", + "enum": [ + "EVALUATION_TYPE_UNSPECIFIED", + "PER_ROW", + "AGGREGATE" + ], + "enumDescriptions": [ + "An unspecified evaluation type.", + "The rule evaluation is done at per row level.", + "The rule evaluation is done for an aggregate of rows." + ], + "type": "string" + }, + "jobId": { + "description": "Identifier of the specific data scan job this log entry is for.", + "type": "string" + }, + "nullRowCount": { + "description": "The number of rows with null values in the specified column.", + "format": "int64", + "type": "string" + }, + "passedRowCount": { + "description": "The number of rows which passed a rule evaluation. This field is only valid for rules of PER_ROW evaluation type.", + "format": "int64", + "type": "string" + }, + "result": { + "description": "The result of the data quality rule.", + "enum": [ + "RESULT_UNSPECIFIED", + "PASSED", + "FAILED" + ], + "enumDescriptions": [ + "An unspecified result.", + "The data quality rule passed.", + "The data quality rule failed." + ], + "type": "string" + }, + "ruleDimension": { + "description": "The dimension of the data quality rule.", + "type": "string" + }, + "ruleName": { + "description": "The name of the data quality rule.", + "type": "string" + }, + "ruleType": { + "description": "The type of the data quality rule.", + "enum": [ + "RULE_TYPE_UNSPECIFIED", + "NON_NULL_EXPECTATION", + "RANGE_EXPECTATION", + "REGEX_EXPECTATION", + "ROW_CONDITION_EXPECTATION", + "SET_EXPECTATION", + "STATISTIC_RANGE_EXPECTATION", + "TABLE_CONDITION_EXPECTATION", + "UNIQUENESS_EXPECTATION" + ], + "enumDescriptions": [ + "An unspecified rule type.", + "Please see https://cloud.google.com/dataplex/docs/reference/rest/v1/DataQualityRule#nonnullexpectation.", + "Please see https://cloud.google.com/dataplex/docs/reference/rest/v1/DataQualityRule#rangeexpectation.", + "Please see https://cloud.google.com/dataplex/docs/reference/rest/v1/DataQualityRule#regexexpectation.", + "Please see https://cloud.google.com/dataplex/docs/reference/rest/v1/DataQualityRule#rowconditionexpectation.", + "Please see https://cloud.google.com/dataplex/docs/reference/rest/v1/DataQualityRule#setexpectation.", + "Please see https://cloud.google.com/dataplex/docs/reference/rest/v1/DataQualityRule#statisticrangeexpectation.", + "Please see https://cloud.google.com/dataplex/docs/reference/rest/v1/DataQualityRule#tableconditionexpectation.", + "Please see https://cloud.google.com/dataplex/docs/reference/rest/v1/DataQualityRule#uniquenessexpectation." + ], + "type": "string" + }, + "thresholdPercent": { + "description": "The passing threshold (0.0, 100.0) of the data quality rule.", + "format": "double", + "type": "number" + } + }, + "type": "object" + }, "GoogleCloudDataplexV1DataQualitySpec": { "description": "DataQualityScan related setting.", "id": "GoogleCloudDataplexV1DataQualitySpec", @@ -6472,7 +6573,7 @@ "type": "object" }, "GoogleCloudDataplexV1Environment": { - "description": "Environment represents a user-visible compute infrastructure for analytics within a lake. LINT.IfChange", + "description": "Environment represents a user-visible compute infrastructure for analytics within a lake.", "id": "GoogleCloudDataplexV1Environment", "properties": { "createTime": { diff --git a/dataplex/v1/dataplex-gen.go b/dataplex/v1/dataplex-gen.go index 367747b6865..9488250d262 100644 --- a/dataplex/v1/dataplex-gen.go +++ b/dataplex/v1/dataplex-gen.go @@ -2617,6 +2617,119 @@ func (s *GoogleCloudDataplexV1DataQualityRuleTableConditionExpectation) MarshalJ type GoogleCloudDataplexV1DataQualityRuleUniquenessExpectation struct { } +// GoogleCloudDataplexV1DataQualityScanRuleResult: Information about the +// result of a data quality rule for data quality scan. The monitored +// resource is 'DataScan'. +type GoogleCloudDataplexV1DataQualityScanRuleResult struct { + // Column: The column which this rule is evaluated against. + Column string `json:"column,omitempty"` + + // DataSource: The data source of the data scan (e.g. BigQuery table + // name). + DataSource string `json:"dataSource,omitempty"` + + // EvaluatedRowCount: The number of rows evaluated against the data + // quality rule. This field is only valid for rules of PER_ROW + // evaluation type. + EvaluatedRowCount int64 `json:"evaluatedRowCount,omitempty,string"` + + // EvalutionType: The evaluation type of the data quality rule. + // + // Possible values: + // "EVALUATION_TYPE_UNSPECIFIED" - An unspecified evaluation type. + // "PER_ROW" - The rule evaluation is done at per row level. + // "AGGREGATE" - The rule evaluation is done for an aggregate of rows. + EvalutionType string `json:"evalutionType,omitempty"` + + // JobId: Identifier of the specific data scan job this log entry is + // for. + JobId string `json:"jobId,omitempty"` + + // NullRowCount: The number of rows with null values in the specified + // column. + NullRowCount int64 `json:"nullRowCount,omitempty,string"` + + // PassedRowCount: The number of rows which passed a rule evaluation. + // This field is only valid for rules of PER_ROW evaluation type. + PassedRowCount int64 `json:"passedRowCount,omitempty,string"` + + // Result: The result of the data quality rule. + // + // Possible values: + // "RESULT_UNSPECIFIED" - An unspecified result. + // "PASSED" - The data quality rule passed. + // "FAILED" - The data quality rule failed. + Result string `json:"result,omitempty"` + + // RuleDimension: The dimension of the data quality rule. + RuleDimension string `json:"ruleDimension,omitempty"` + + // RuleName: The name of the data quality rule. + RuleName string `json:"ruleName,omitempty"` + + // RuleType: The type of the data quality rule. + // + // Possible values: + // "RULE_TYPE_UNSPECIFIED" - An unspecified rule type. + // "NON_NULL_EXPECTATION" - Please see + // https://cloud.google.com/dataplex/docs/reference/rest/v1/DataQualityRule#nonnullexpectation. + // "RANGE_EXPECTATION" - Please see + // https://cloud.google.com/dataplex/docs/reference/rest/v1/DataQualityRule#rangeexpectation. + // "REGEX_EXPECTATION" - Please see + // https://cloud.google.com/dataplex/docs/reference/rest/v1/DataQualityRule#regexexpectation. + // "ROW_CONDITION_EXPECTATION" - Please see + // https://cloud.google.com/dataplex/docs/reference/rest/v1/DataQualityRule#rowconditionexpectation. + // "SET_EXPECTATION" - Please see + // https://cloud.google.com/dataplex/docs/reference/rest/v1/DataQualityRule#setexpectation. + // "STATISTIC_RANGE_EXPECTATION" - Please see + // https://cloud.google.com/dataplex/docs/reference/rest/v1/DataQualityRule#statisticrangeexpectation. + // "TABLE_CONDITION_EXPECTATION" - Please see + // https://cloud.google.com/dataplex/docs/reference/rest/v1/DataQualityRule#tableconditionexpectation. + // "UNIQUENESS_EXPECTATION" - Please see + // https://cloud.google.com/dataplex/docs/reference/rest/v1/DataQualityRule#uniquenessexpectation. + RuleType string `json:"ruleType,omitempty"` + + // ThresholdPercent: The passing threshold (0.0, 100.0) of the data + // quality rule. + ThresholdPercent float64 `json:"thresholdPercent,omitempty"` + + // ForceSendFields is a list of field names (e.g. "Column") 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. "Column") 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 *GoogleCloudDataplexV1DataQualityScanRuleResult) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDataplexV1DataQualityScanRuleResult + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + +func (s *GoogleCloudDataplexV1DataQualityScanRuleResult) UnmarshalJSON(data []byte) error { + type NoMethod GoogleCloudDataplexV1DataQualityScanRuleResult + var s1 struct { + ThresholdPercent gensupport.JSONFloat64 `json:"thresholdPercent"` + *NoMethod + } + s1.NoMethod = (*NoMethod)(s) + if err := json.Unmarshal(data, &s1); err != nil { + return err + } + s.ThresholdPercent = float64(s1.ThresholdPercent) + return nil +} + // GoogleCloudDataplexV1DataQualitySpec: DataQualityScan related // setting. type GoogleCloudDataplexV1DataQualitySpec struct { @@ -3787,7 +3900,6 @@ func (s *GoogleCloudDataplexV1EntityCompatibilityStatusCompatibility) MarshalJSO // GoogleCloudDataplexV1Environment: Environment represents a // user-visible compute infrastructure for analytics within a lake. -// LINT.IfChange type GoogleCloudDataplexV1Environment struct { // CreateTime: Output only. Environment creation time. CreateTime string `json:"createTime,omitempty"` diff --git a/deploymentmanager/v2/deploymentmanager-api.json b/deploymentmanager/v2/deploymentmanager-api.json index 6a14230d6e9..ba60dfcfdbc 100644 --- a/deploymentmanager/v2/deploymentmanager-api.json +++ b/deploymentmanager/v2/deploymentmanager-api.json @@ -988,7 +988,7 @@ } } }, - "revision": "20230518", + "revision": "20230703", "rootUrl": "https://deploymentmanager.googleapis.com/", "schemas": { "AuditConfig": { @@ -1514,6 +1514,36 @@ "INVALID_HEALTH_CHECK_FOR_DYNAMIC_WIEGHTED_LB", "LIST_OVERHEAD_QUOTA_EXCEED" ], + "enumDeprecated": [ + false, + false, + false, + false, + false, + false, + false, + false, + false, + false, + false, + false, + false, + false, + false, + true, + false, + false, + false, + false, + false, + false, + false, + false, + false, + false, + false, + false + ], "enumDescriptions": [ "A link to a deprecated resource was created.", "No results are present on a particular list page.", @@ -1711,6 +1741,36 @@ "INVALID_HEALTH_CHECK_FOR_DYNAMIC_WIEGHTED_LB", "LIST_OVERHEAD_QUOTA_EXCEED" ], + "enumDeprecated": [ + false, + false, + false, + false, + false, + false, + false, + false, + false, + false, + false, + false, + false, + false, + false, + true, + false, + false, + false, + false, + false, + false, + false, + false, + false, + false, + false, + false + ], "enumDescriptions": [ "A link to a deprecated resource was created.", "No results are present on a particular list page.", @@ -1903,6 +1963,36 @@ "INVALID_HEALTH_CHECK_FOR_DYNAMIC_WIEGHTED_LB", "LIST_OVERHEAD_QUOTA_EXCEED" ], + "enumDeprecated": [ + false, + false, + false, + false, + false, + false, + false, + false, + false, + false, + false, + false, + false, + false, + false, + true, + false, + false, + false, + false, + false, + false, + false, + false, + false, + false, + false, + false + ], "enumDescriptions": [ "A link to a deprecated resource was created.", "No results are present on a particular list page.", diff --git a/dialogflow/v2/dialogflow-api.json b/dialogflow/v2/dialogflow-api.json index e4cf93408b4..a47414ff8f6 100644 --- a/dialogflow/v2/dialogflow-api.json +++ b/dialogflow/v2/dialogflow-api.json @@ -8211,7 +8211,7 @@ } } }, - "revision": "20230621", + "revision": "20230705", "rootUrl": "https://dialogflow.googleapis.com/", "schemas": { "GoogleCloudDialogflowCxV3AudioInput": { @@ -8606,13 +8606,17 @@ "id": "GoogleCloudDialogflowCxV3ExportAgentResponse", "properties": { "agentContent": { - "description": "Uncompressed raw byte content for agent.", + "description": "Uncompressed raw byte content for agent. This field is populated if none of `agent_uri` and `git_destination` are specified in ExportAgentRequest.", "format": "byte", "type": "string" }, "agentUri": { "description": "The URI to a file containing the exported agent. This field is populated if `agent_uri` is specified in ExportAgentRequest.", "type": "string" + }, + "commitSha": { + "description": "Commit SHA of the git push. This field is populated if `git_destination` are specified in ExportAgentRequest.", + "type": "string" } }, "type": "object" @@ -9883,6 +9887,7 @@ "type": "object" }, "password": { + "deprecated": true, "description": "The password for HTTP Basic authentication.", "type": "string" }, @@ -9902,6 +9907,7 @@ "type": "string" }, "username": { + "deprecated": true, "description": "The user name for HTTP Basic authentication.", "type": "string" }, @@ -10532,13 +10538,17 @@ "id": "GoogleCloudDialogflowCxV3beta1ExportAgentResponse", "properties": { "agentContent": { - "description": "Uncompressed raw byte content for agent.", + "description": "Uncompressed raw byte content for agent. This field is populated if none of `agent_uri` and `git_destination` are specified in ExportAgentRequest.", "format": "byte", "type": "string" }, "agentUri": { "description": "The URI to a file containing the exported agent. This field is populated if `agent_uri` is specified in ExportAgentRequest.", "type": "string" + }, + "commitSha": { + "description": "Commit SHA of the git push. This field is populated if `git_destination` are specified in ExportAgentRequest.", + "type": "string" } }, "type": "object" @@ -11809,6 +11819,7 @@ "type": "object" }, "password": { + "deprecated": true, "description": "The password for HTTP Basic authentication.", "type": "string" }, @@ -11828,6 +11839,7 @@ "type": "string" }, "username": { + "deprecated": true, "description": "The user name for HTTP Basic authentication.", "type": "string" }, @@ -12112,6 +12124,7 @@ "type": "boolean" }, "matchMode": { + "deprecated": true, "description": "Optional. Determines how intents are detected from user queries.", "enum": [ "MATCH_MODE_UNSPECIFIED", @@ -12144,6 +12157,12 @@ "TIER_ENTERPRISE", "TIER_ENTERPRISE_PLUS" ], + "enumDeprecated": [ + false, + false, + false, + true + ], "enumDescriptions": [ "Not specified. This value should never be used.", "Trial Edition, previously known as Standard Edition.", @@ -13885,6 +13904,7 @@ "id": "GoogleCloudDialogflowV2FulfillmentGenericWebService", "properties": { "isCloudFunction": { + "deprecated": true, "description": "Optional. Indicates if generic web service is created through Cloud Functions integration. Defaults to false. is_cloud_function is deprecated. Cloud functions can be configured by its uri as a regular web service now.", "type": "boolean" }, @@ -14505,6 +14525,7 @@ "type": "string" }, "phraseHints": { + "deprecated": true, "description": "A list of strings containing words and phrases that the speech recognizer should recognize with higher likelihood. See [the Cloud Speech documentation](https://cloud.google.com/speech-to-text/docs/basics#phrase-hints) for more details. This field is deprecated. Please use [speech_contexts]() instead. If you specify both [phrase_hints]() and [speech_contexts](), Dialogflow will treat the [phrase_hints]() as a single additional [SpeechContext]().", "items": { "type": "string" @@ -15443,6 +15464,11 @@ "EXAMPLE", "TEMPLATE" ], + "enumDeprecated": [ + false, + false, + true + ], "enumDescriptions": [ "Not specified. This value should never be used.", "Examples do not contain @-prefixed entity type names, but example parts can be annotated with entity types.", @@ -17596,6 +17622,7 @@ "type": "boolean" }, "mlEnabled": { + "deprecated": true, "description": "Optional. Indicates whether Machine Learning is enabled for the intent. Note: If `ml_enabled` setting is set to false, then this intent is not taken into account during inference in `ML ONLY` match mode. Also, auto-markup in the UI is turned off. DEPRECATED! Please use `ml_disabled` field instead. NOTE: If both `ml_enabled` and `ml_disabled` are either not set or false, then the default value is determined as follows: - Before April 15th, 2018 the default is: ml_enabled = false / ml_disabled = true. - After April 15th, 2018 the default is: ml_enabled = true / ml_disabled = false.", "type": "boolean" }, @@ -18697,6 +18724,11 @@ "EXAMPLE", "TEMPLATE" ], + "enumDeprecated": [ + false, + false, + true + ], "enumDescriptions": [ "Not specified. This value should never be used.", "Examples do not contain @-prefixed entity type names, but example parts can be annotated with entity types.", diff --git a/dialogflow/v2/dialogflow-gen.go b/dialogflow/v2/dialogflow-gen.go index a0d747fe5d2..4c250582310 100644 --- a/dialogflow/v2/dialogflow-gen.go +++ b/dialogflow/v2/dialogflow-gen.go @@ -1603,13 +1603,19 @@ func (s *GoogleCloudDialogflowCxV3EventInput) MarshalJSON() ([]byte, error) { // GoogleCloudDialogflowCxV3ExportAgentResponse: The response message // for Agents.ExportAgent. type GoogleCloudDialogflowCxV3ExportAgentResponse struct { - // AgentContent: Uncompressed raw byte content for agent. + // AgentContent: Uncompressed raw byte content for agent. This field is + // populated if none of `agent_uri` and `git_destination` are specified + // in ExportAgentRequest. AgentContent string `json:"agentContent,omitempty"` // AgentUri: The URI to a file containing the exported agent. This field // is populated if `agent_uri` is specified in ExportAgentRequest. AgentUri string `json:"agentUri,omitempty"` + // CommitSha: Commit SHA of the git push. This field is populated if + // `git_destination` are specified in ExportAgentRequest. + CommitSha string `json:"commitSha,omitempty"` + // ForceSendFields is a list of field names (e.g. "AgentContent") to // unconditionally include in API requests. By default, fields with // empty or default values are omitted from API requests. However, any @@ -5174,13 +5180,19 @@ func (s *GoogleCloudDialogflowCxV3beta1EventInput) MarshalJSON() ([]byte, error) // GoogleCloudDialogflowCxV3beta1ExportAgentResponse: The response // message for Agents.ExportAgent. type GoogleCloudDialogflowCxV3beta1ExportAgentResponse struct { - // AgentContent: Uncompressed raw byte content for agent. + // AgentContent: Uncompressed raw byte content for agent. This field is + // populated if none of `agent_uri` and `git_destination` are specified + // in ExportAgentRequest. AgentContent string `json:"agentContent,omitempty"` // AgentUri: The URI to a file containing the exported agent. This field // is populated if `agent_uri` is specified in ExportAgentRequest. AgentUri string `json:"agentUri,omitempty"` + // CommitSha: Commit SHA of the git push. This field is populated if + // `git_destination` are specified in ExportAgentRequest. + CommitSha string `json:"commitSha,omitempty"` + // ForceSendFields is a list of field names (e.g. "AgentContent") to // unconditionally include in API requests. By default, fields with // empty or default values are omitted from API requests. However, any diff --git a/dialogflow/v2beta1/dialogflow-api.json b/dialogflow/v2beta1/dialogflow-api.json index 4a619421fd0..e7e1bbe3d0a 100644 --- a/dialogflow/v2beta1/dialogflow-api.json +++ b/dialogflow/v2beta1/dialogflow-api.json @@ -7579,7 +7579,7 @@ } } }, - "revision": "20230626", + "revision": "20230705", "rootUrl": "https://dialogflow.googleapis.com/", "schemas": { "GoogleCloudDialogflowCxV3AudioInput": { @@ -7974,13 +7974,17 @@ "id": "GoogleCloudDialogflowCxV3ExportAgentResponse", "properties": { "agentContent": { - "description": "Uncompressed raw byte content for agent.", + "description": "Uncompressed raw byte content for agent. This field is populated if none of `agent_uri` and `git_destination` are specified in ExportAgentRequest.", "format": "byte", "type": "string" }, "agentUri": { "description": "The URI to a file containing the exported agent. This field is populated if `agent_uri` is specified in ExportAgentRequest.", "type": "string" + }, + "commitSha": { + "description": "Commit SHA of the git push. This field is populated if `git_destination` are specified in ExportAgentRequest.", + "type": "string" } }, "type": "object" @@ -9251,6 +9255,7 @@ "type": "object" }, "password": { + "deprecated": true, "description": "The password for HTTP Basic authentication.", "type": "string" }, @@ -9270,6 +9275,7 @@ "type": "string" }, "username": { + "deprecated": true, "description": "The user name for HTTP Basic authentication.", "type": "string" }, @@ -9900,13 +9906,17 @@ "id": "GoogleCloudDialogflowCxV3beta1ExportAgentResponse", "properties": { "agentContent": { - "description": "Uncompressed raw byte content for agent.", + "description": "Uncompressed raw byte content for agent. This field is populated if none of `agent_uri` and `git_destination` are specified in ExportAgentRequest.", "format": "byte", "type": "string" }, "agentUri": { "description": "The URI to a file containing the exported agent. This field is populated if `agent_uri` is specified in ExportAgentRequest.", "type": "string" + }, + "commitSha": { + "description": "Commit SHA of the git push. This field is populated if `git_destination` are specified in ExportAgentRequest.", + "type": "string" } }, "type": "object" @@ -11177,6 +11187,7 @@ "type": "object" }, "password": { + "deprecated": true, "description": "The password for HTTP Basic authentication.", "type": "string" }, @@ -11196,6 +11207,7 @@ "type": "string" }, "username": { + "deprecated": true, "description": "The user name for HTTP Basic authentication.", "type": "string" }, @@ -12976,6 +12988,11 @@ "EXAMPLE", "TEMPLATE" ], + "enumDeprecated": [ + false, + false, + true + ], "enumDescriptions": [ "Not specified. This value should never be used.", "Examples do not contain @-prefixed entity type names, but example parts can be annotated with entity types.", @@ -13610,6 +13627,7 @@ "type": "boolean" }, "matchMode": { + "deprecated": true, "description": "Optional. Determines how intents are detected from user queries.", "enum": [ "MATCH_MODE_UNSPECIFIED", @@ -13642,6 +13660,12 @@ "TIER_ENTERPRISE", "TIER_ENTERPRISE_PLUS" ], + "enumDeprecated": [ + false, + false, + false, + true + ], "enumDescriptions": [ "Not specified. This value should never be used.", "Trial Edition, previously known as Standard Edition.", @@ -14043,6 +14067,7 @@ "description": "Properties of the object.", "type": "any" }, + "deprecated": true, "description": "The collection of current Dialogflow CX agent session parameters at the time of this response. Deprecated: Use `parameters` instead.", "type": "object" }, @@ -14397,6 +14422,7 @@ "type": "object" }, "GoogleCloudDialogflowV2beta1CompileSuggestionRequest": { + "deprecated": true, "description": "The request message for Participants.CompileSuggestion.", "id": "GoogleCloudDialogflowV2beta1CompileSuggestionRequest", "properties": { @@ -14413,6 +14439,7 @@ "type": "object" }, "GoogleCloudDialogflowV2beta1CompileSuggestionResponse": { + "deprecated": true, "description": "The response message for Participants.CompileSuggestion.", "id": "GoogleCloudDialogflowV2beta1CompileSuggestionResponse", "properties": { @@ -14749,6 +14776,7 @@ "id": "GoogleCloudDialogflowV2beta1Document", "properties": { "content": { + "deprecated": true, "description": "The raw content of the document. This field is only permitted for EXTRACTIVE_QA and FAQ knowledge types. Note: This field is in the process of being deprecated, please use raw_content instead.", "type": "string" }, @@ -15195,6 +15223,7 @@ "id": "GoogleCloudDialogflowV2beta1FulfillmentGenericWebService", "properties": { "isCloudFunction": { + "deprecated": true, "description": "Optional. Indicates if generic web service is created through Cloud Functions integration. Defaults to false. is_cloud_function is deprecated. Cloud functions can be configured by its uri as a regular web service now.", "type": "boolean" }, @@ -15797,6 +15826,7 @@ "type": "string" }, "phraseHints": { + "deprecated": true, "description": "A list of strings containing words and phrases that the speech recognizer should recognize with higher likelihood. See [the Cloud Speech documentation](https://cloud.google.com/speech-to-text/docs/basics#phrase-hints) for more details. This field is deprecated. Please use [speech_contexts]() instead. If you specify both [phrase_hints]() and [speech_contexts](), Dialogflow will treat the [phrase_hints]() as a single additional [SpeechContext]().", "items": { "type": "string" @@ -15913,6 +15943,7 @@ "type": "boolean" }, "mlEnabled": { + "deprecated": true, "description": "Optional. Indicates whether Machine Learning is enabled for the intent. Note: If `ml_enabled` setting is set to false, then this intent is not taken into account during inference in `ML ONLY` match mode. Also, auto-markup in the UI is turned off. DEPRECATED! Please use `ml_disabled` field instead. NOTE: If both `ml_enabled` and `ml_disabled` are either not set or false, then the default value is determined as follows: - Before April 15th, 2018 the default is: ml_enabled = false / ml_disabled = true. - After April 15th, 2018 the default is: ml_enabled = true / ml_disabled = false.", "type": "boolean" }, @@ -17043,6 +17074,11 @@ "EXAMPLE", "TEMPLATE" ], + "enumDeprecated": [ + false, + false, + true + ], "enumDescriptions": [ "Not specified. This value should never be used.", "Examples do not contain @-prefixed entity type names, but example parts can be annotated with entity types.", @@ -17398,6 +17434,7 @@ "type": "object" }, "GoogleCloudDialogflowV2beta1ListSuggestionsResponse": { + "deprecated": true, "description": "The response message for Participants.ListSuggestions.", "id": "GoogleCloudDialogflowV2beta1ListSuggestionsResponse", "properties": { @@ -18460,6 +18497,7 @@ "type": "object" }, "GoogleCloudDialogflowV2beta1Suggestion": { + "deprecated": true, "description": "Represents a suggestion for a human agent.", "id": "GoogleCloudDialogflowV2beta1Suggestion", "properties": { diff --git a/dialogflow/v2beta1/dialogflow-gen.go b/dialogflow/v2beta1/dialogflow-gen.go index 0d82bb2b89a..728e66a185d 100644 --- a/dialogflow/v2beta1/dialogflow-gen.go +++ b/dialogflow/v2beta1/dialogflow-gen.go @@ -1531,13 +1531,19 @@ func (s *GoogleCloudDialogflowCxV3EventInput) MarshalJSON() ([]byte, error) { // GoogleCloudDialogflowCxV3ExportAgentResponse: The response message // for Agents.ExportAgent. type GoogleCloudDialogflowCxV3ExportAgentResponse struct { - // AgentContent: Uncompressed raw byte content for agent. + // AgentContent: Uncompressed raw byte content for agent. This field is + // populated if none of `agent_uri` and `git_destination` are specified + // in ExportAgentRequest. AgentContent string `json:"agentContent,omitempty"` // AgentUri: The URI to a file containing the exported agent. This field // is populated if `agent_uri` is specified in ExportAgentRequest. AgentUri string `json:"agentUri,omitempty"` + // CommitSha: Commit SHA of the git push. This field is populated if + // `git_destination` are specified in ExportAgentRequest. + CommitSha string `json:"commitSha,omitempty"` + // ForceSendFields is a list of field names (e.g. "AgentContent") to // unconditionally include in API requests. By default, fields with // empty or default values are omitted from API requests. However, any @@ -5102,13 +5108,19 @@ func (s *GoogleCloudDialogflowCxV3beta1EventInput) MarshalJSON() ([]byte, error) // GoogleCloudDialogflowCxV3beta1ExportAgentResponse: The response // message for Agents.ExportAgent. type GoogleCloudDialogflowCxV3beta1ExportAgentResponse struct { - // AgentContent: Uncompressed raw byte content for agent. + // AgentContent: Uncompressed raw byte content for agent. This field is + // populated if none of `agent_uri` and `git_destination` are specified + // in ExportAgentRequest. AgentContent string `json:"agentContent,omitempty"` // AgentUri: The URI to a file containing the exported agent. This field // is populated if `agent_uri` is specified in ExportAgentRequest. AgentUri string `json:"agentUri,omitempty"` + // CommitSha: Commit SHA of the git push. This field is populated if + // `git_destination` are specified in ExportAgentRequest. + CommitSha string `json:"commitSha,omitempty"` + // ForceSendFields is a list of field names (e.g. "AgentContent") to // unconditionally include in API requests. By default, fields with // empty or default values are omitted from API requests. However, any diff --git a/dialogflow/v3/dialogflow-api.json b/dialogflow/v3/dialogflow-api.json index a60a9630322..0fee9a4b3d1 100644 --- a/dialogflow/v3/dialogflow-api.json +++ b/dialogflow/v3/dialogflow-api.json @@ -3820,7 +3820,7 @@ } } }, - "revision": "20230626", + "revision": "20230705", "rootUrl": "https://dialogflow.googleapis.com/", "schemas": { "GoogleCloudDialogflowCxV3AdvancedSettings": { @@ -3882,9 +3882,14 @@ "type": "boolean" }, "enableStackdriverLogging": { + "deprecated": true, "description": "Indicates if stackdriver logging is enabled for the agent. Please use agent.advanced_settings instead.", "type": "boolean" }, + "gitIntegrationSettings": { + "$ref": "GoogleCloudDialogflowCxV3AgentGitIntegrationSettings", + "description": "Git integration settings for this agent." + }, "locked": { "description": "Indicates whether the agent is locked for changes. If the agent is locked, modifications to the agent will be rejected except for RestoreAgent.", "type": "boolean" @@ -3923,6 +3928,47 @@ }, "type": "object" }, + "GoogleCloudDialogflowCxV3AgentGitIntegrationSettings": { + "description": "Settings for connecting to Git repository for an agent.", + "id": "GoogleCloudDialogflowCxV3AgentGitIntegrationSettings", + "properties": { + "githubSettings": { + "$ref": "GoogleCloudDialogflowCxV3AgentGitIntegrationSettingsGithubSettings", + "description": "GitHub settings." + } + }, + "type": "object" + }, + "GoogleCloudDialogflowCxV3AgentGitIntegrationSettingsGithubSettings": { + "description": "Settings of integration with GitHub.", + "id": "GoogleCloudDialogflowCxV3AgentGitIntegrationSettingsGithubSettings", + "properties": { + "accessToken": { + "description": "The access token used to authenticate the access to the GitHub repository.", + "type": "string" + }, + "branches": { + "description": "A list of branches configured to be used from Dialogflow.", + "items": { + "type": "string" + }, + "type": "array" + }, + "displayName": { + "description": "The unique repository display name for the GitHub repository.", + "type": "string" + }, + "repositoryUri": { + "description": "The GitHub repository URI related to the agent.", + "type": "string" + }, + "trackingBranch": { + "description": "The branch of GitHub repository tracked for this agent.", + "type": "string" + } + }, + "type": "object" + }, "GoogleCloudDialogflowCxV3AgentValidationResult": { "description": "The response message for Agents.GetAgentValidationResult.", "id": "GoogleCloudDialogflowCxV3AgentValidationResult", @@ -4939,6 +4985,10 @@ "description": "Optional. Environment name. If not set, draft environment is assumed. Format: `projects//locations//agents//environments/`.", "type": "string" }, + "gitDestination": { + "$ref": "GoogleCloudDialogflowCxV3ExportAgentRequestGitDestination", + "description": "Optional. The Git branch to export the agent to." + }, "includeBigqueryExportSettings": { "description": "Optional. Whether to include BigQuery Export setting.", "type": "boolean" @@ -4946,18 +4996,37 @@ }, "type": "object" }, + "GoogleCloudDialogflowCxV3ExportAgentRequestGitDestination": { + "description": "Settings for exporting to a git branch.", + "id": "GoogleCloudDialogflowCxV3ExportAgentRequestGitDestination", + "properties": { + "commitMessage": { + "description": "Commit message for the git push.", + "type": "string" + }, + "trackingBranch": { + "description": "Tracking branch for the git push.", + "type": "string" + } + }, + "type": "object" + }, "GoogleCloudDialogflowCxV3ExportAgentResponse": { "description": "The response message for Agents.ExportAgent.", "id": "GoogleCloudDialogflowCxV3ExportAgentResponse", "properties": { "agentContent": { - "description": "Uncompressed raw byte content for agent.", + "description": "Uncompressed raw byte content for agent. This field is populated if none of `agent_uri` and `git_destination` are specified in ExportAgentRequest.", "format": "byte", "type": "string" }, "agentUri": { "description": "The URI to a file containing the exported agent. This field is populated if `agent_uri` is specified in ExportAgentRequest.", "type": "string" + }, + "commitSha": { + "description": "Commit SHA of the git push. This field is populated if `git_destination` are specified in ExportAgentRequest.", + "type": "string" } }, "type": "object" @@ -6454,9 +6523,11 @@ }, "intent": { "$ref": "GoogleCloudDialogflowCxV3Intent", + "deprecated": true, "description": "The Intent that matched the conversational query. Some, not all fields are filled in this message, including but not limited to: `name` and `display_name`. This field is deprecated, please use QueryResult.match instead." }, "intentDetectionConfidence": { + "deprecated": true, "description": "The intent detection confidence. Values range from 0.0 (completely uncertain) to 1.0 (completely certain). This value is for informational purpose only and is only used to help match the best intent within the classification threshold. This value may change for the same end-user expression at any time due to a model retraining or change in implementation. This field is deprecated, please use QueryResult.match instead.", "format": "float", "type": "number" @@ -6754,6 +6825,10 @@ "description": "The [Google Cloud Storage](https://cloud.google.com/storage/docs/) URI to restore agent from. The format of this URI must be `gs:///`. Dialogflow performs a read operation for the Cloud Storage object on the caller's behalf, so your request authentication must have read permissions for the object. For more information, see [Dialogflow access control](https://cloud.google.com/dialogflow/cx/docs/concept/access-control#storage).", "type": "string" }, + "gitSource": { + "$ref": "GoogleCloudDialogflowCxV3RestoreAgentRequestGitSource", + "description": "Setting for restoring from a git branch" + }, "restoreOption": { "description": "Agent restore mode. If not specified, `KEEP` is assumed.", "enum": [ @@ -6771,6 +6846,17 @@ }, "type": "object" }, + "GoogleCloudDialogflowCxV3RestoreAgentRequestGitSource": { + "description": "Settings for restoring from a git branch", + "id": "GoogleCloudDialogflowCxV3RestoreAgentRequestGitSource", + "properties": { + "trackingBranch": { + "description": "tracking branch for the git pull", + "type": "string" + } + }, + "type": "object" + }, "GoogleCloudDialogflowCxV3RolloutConfig": { "description": "The configuration for auto rollout.", "id": "GoogleCloudDialogflowCxV3RolloutConfig", @@ -7672,6 +7758,7 @@ "type": "string" }, "resources": { + "deprecated": true, "description": "The names of the resources where the message is found.", "items": { "type": "string" @@ -7897,6 +7984,7 @@ "type": "object" }, "password": { + "deprecated": true, "description": "The password for HTTP Basic authentication.", "type": "string" }, @@ -7916,6 +8004,7 @@ "type": "string" }, "username": { + "deprecated": true, "description": "The user name for HTTP Basic authentication.", "type": "string" }, @@ -8546,13 +8635,17 @@ "id": "GoogleCloudDialogflowCxV3beta1ExportAgentResponse", "properties": { "agentContent": { - "description": "Uncompressed raw byte content for agent.", + "description": "Uncompressed raw byte content for agent. This field is populated if none of `agent_uri` and `git_destination` are specified in ExportAgentRequest.", "format": "byte", "type": "string" }, "agentUri": { "description": "The URI to a file containing the exported agent. This field is populated if `agent_uri` is specified in ExportAgentRequest.", "type": "string" + }, + "commitSha": { + "description": "Commit SHA of the git push. This field is populated if `git_destination` are specified in ExportAgentRequest.", + "type": "string" } }, "type": "object" @@ -9823,6 +9916,7 @@ "type": "object" }, "password": { + "deprecated": true, "description": "The password for HTTP Basic authentication.", "type": "string" }, @@ -9842,6 +9936,7 @@ "type": "string" }, "username": { + "deprecated": true, "description": "The user name for HTTP Basic authentication.", "type": "string" }, @@ -11622,6 +11717,11 @@ "EXAMPLE", "TEMPLATE" ], + "enumDeprecated": [ + false, + false, + true + ], "enumDescriptions": [ "Not specified. This value should never be used.", "Examples do not contain @-prefixed entity type names, but example parts can be annotated with entity types.", @@ -12719,6 +12819,7 @@ "type": "boolean" }, "mlEnabled": { + "deprecated": true, "description": "Optional. Indicates whether Machine Learning is enabled for the intent. Note: If `ml_enabled` setting is set to false, then this intent is not taken into account during inference in `ML ONLY` match mode. Also, auto-markup in the UI is turned off. DEPRECATED! Please use `ml_disabled` field instead. NOTE: If both `ml_enabled` and `ml_disabled` are either not set or false, then the default value is determined as follows: - Before April 15th, 2018 the default is: ml_enabled = false / ml_disabled = true. - After April 15th, 2018 the default is: ml_enabled = true / ml_disabled = false.", "type": "boolean" }, @@ -13820,6 +13921,11 @@ "EXAMPLE", "TEMPLATE" ], + "enumDeprecated": [ + false, + false, + true + ], "enumDescriptions": [ "Not specified. This value should never be used.", "Examples do not contain @-prefixed entity type names, but example parts can be annotated with entity types.", diff --git a/dialogflow/v3/dialogflow-gen.go b/dialogflow/v3/dialogflow-gen.go index be0a76c75e3..44e64fcc0b2 100644 --- a/dialogflow/v3/dialogflow-gen.go +++ b/dialogflow/v3/dialogflow-gen.go @@ -557,6 +557,9 @@ type GoogleCloudDialogflowCxV3Agent struct { // for the agent. Please use agent.advanced_settings instead. EnableStackdriverLogging bool `json:"enableStackdriverLogging,omitempty"` + // GitIntegrationSettings: Git integration settings for this agent. + GitIntegrationSettings *GoogleCloudDialogflowCxV3AgentGitIntegrationSettings `json:"gitIntegrationSettings,omitempty"` + // Locked: Indicates whether the agent is locked for changes. If the // agent is locked, modifications to the agent will be rejected except // for RestoreAgent. @@ -621,6 +624,80 @@ func (s *GoogleCloudDialogflowCxV3Agent) MarshalJSON() ([]byte, error) { return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } +// GoogleCloudDialogflowCxV3AgentGitIntegrationSettings: Settings for +// connecting to Git repository for an agent. +type GoogleCloudDialogflowCxV3AgentGitIntegrationSettings struct { + // GithubSettings: GitHub settings. + GithubSettings *GoogleCloudDialogflowCxV3AgentGitIntegrationSettingsGithubSettings `json:"githubSettings,omitempty"` + + // ForceSendFields is a list of field names (e.g. "GithubSettings") 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. "GithubSettings") 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 *GoogleCloudDialogflowCxV3AgentGitIntegrationSettings) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDialogflowCxV3AgentGitIntegrationSettings + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + +// GoogleCloudDialogflowCxV3AgentGitIntegrationSettingsGithubSettings: +// Settings of integration with GitHub. +type GoogleCloudDialogflowCxV3AgentGitIntegrationSettingsGithubSettings struct { + // AccessToken: The access token used to authenticate the access to the + // GitHub repository. + AccessToken string `json:"accessToken,omitempty"` + + // Branches: A list of branches configured to be used from Dialogflow. + Branches []string `json:"branches,omitempty"` + + // DisplayName: The unique repository display name for the GitHub + // repository. + DisplayName string `json:"displayName,omitempty"` + + // RepositoryUri: The GitHub repository URI related to the agent. + RepositoryUri string `json:"repositoryUri,omitempty"` + + // TrackingBranch: The branch of GitHub repository tracked for this + // agent. + TrackingBranch string `json:"trackingBranch,omitempty"` + + // ForceSendFields is a list of field names (e.g. "AccessToken") 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. "AccessToken") 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 *GoogleCloudDialogflowCxV3AgentGitIntegrationSettingsGithubSettings) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDialogflowCxV3AgentGitIntegrationSettingsGithubSettings + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + // GoogleCloudDialogflowCxV3AgentValidationResult: The response message // for Agents.GetAgentValidationResult. type GoogleCloudDialogflowCxV3AgentValidationResult struct { @@ -2424,6 +2501,9 @@ type GoogleCloudDialogflowCxV3ExportAgentRequest struct { // `projects//locations//agents//environments/`. Environment string `json:"environment,omitempty"` + // GitDestination: Optional. The Git branch to export the agent to. + GitDestination *GoogleCloudDialogflowCxV3ExportAgentRequestGitDestination `json:"gitDestination,omitempty"` + // IncludeBigqueryExportSettings: Optional. Whether to include BigQuery // Export setting. IncludeBigqueryExportSettings bool `json:"includeBigqueryExportSettings,omitempty"` @@ -2451,16 +2531,54 @@ func (s *GoogleCloudDialogflowCxV3ExportAgentRequest) MarshalJSON() ([]byte, err return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } +// GoogleCloudDialogflowCxV3ExportAgentRequestGitDestination: Settings +// for exporting to a git branch. +type GoogleCloudDialogflowCxV3ExportAgentRequestGitDestination struct { + // CommitMessage: Commit message for the git push. + CommitMessage string `json:"commitMessage,omitempty"` + + // TrackingBranch: Tracking branch for the git push. + TrackingBranch string `json:"trackingBranch,omitempty"` + + // ForceSendFields is a list of field names (e.g. "CommitMessage") 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. "CommitMessage") 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 *GoogleCloudDialogflowCxV3ExportAgentRequestGitDestination) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDialogflowCxV3ExportAgentRequestGitDestination + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + // GoogleCloudDialogflowCxV3ExportAgentResponse: The response message // for Agents.ExportAgent. type GoogleCloudDialogflowCxV3ExportAgentResponse struct { - // AgentContent: Uncompressed raw byte content for agent. + // AgentContent: Uncompressed raw byte content for agent. This field is + // populated if none of `agent_uri` and `git_destination` are specified + // in ExportAgentRequest. AgentContent string `json:"agentContent,omitempty"` // AgentUri: The URI to a file containing the exported agent. This field // is populated if `agent_uri` is specified in ExportAgentRequest. AgentUri string `json:"agentUri,omitempty"` + // CommitSha: Commit SHA of the git push. This field is populated if + // `git_destination` are specified in ExportAgentRequest. + CommitSha string `json:"commitSha,omitempty"` + // ForceSendFields is a list of field names (e.g. "AgentContent") to // unconditionally include in API requests. By default, fields with // empty or default values are omitted from API requests. However, any @@ -5997,6 +6115,9 @@ type GoogleCloudDialogflowCxV3RestoreAgentRequest struct { // (https://cloud.google.com/dialogflow/cx/docs/concept/access-control#storage). AgentUri string `json:"agentUri,omitempty"` + // GitSource: Setting for restoring from a git branch + GitSource *GoogleCloudDialogflowCxV3RestoreAgentRequestGitSource `json:"gitSource,omitempty"` + // RestoreOption: Agent restore mode. If not specified, `KEEP` is // assumed. // @@ -6032,6 +6153,36 @@ func (s *GoogleCloudDialogflowCxV3RestoreAgentRequest) MarshalJSON() ([]byte, er return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } +// GoogleCloudDialogflowCxV3RestoreAgentRequestGitSource: Settings for +// restoring from a git branch +type GoogleCloudDialogflowCxV3RestoreAgentRequestGitSource struct { + // TrackingBranch: tracking branch for the git pull + TrackingBranch string `json:"trackingBranch,omitempty"` + + // ForceSendFields is a list of field names (e.g. "TrackingBranch") 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. "TrackingBranch") 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 *GoogleCloudDialogflowCxV3RestoreAgentRequestGitSource) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDialogflowCxV3RestoreAgentRequestGitSource + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + // GoogleCloudDialogflowCxV3RolloutConfig: The configuration for auto // rollout. type GoogleCloudDialogflowCxV3RolloutConfig struct { @@ -9221,13 +9372,19 @@ func (s *GoogleCloudDialogflowCxV3beta1EventInput) MarshalJSON() ([]byte, error) // GoogleCloudDialogflowCxV3beta1ExportAgentResponse: The response // message for Agents.ExportAgent. type GoogleCloudDialogflowCxV3beta1ExportAgentResponse struct { - // AgentContent: Uncompressed raw byte content for agent. + // AgentContent: Uncompressed raw byte content for agent. This field is + // populated if none of `agent_uri` and `git_destination` are specified + // in ExportAgentRequest. AgentContent string `json:"agentContent,omitempty"` // AgentUri: The URI to a file containing the exported agent. This field // is populated if `agent_uri` is specified in ExportAgentRequest. AgentUri string `json:"agentUri,omitempty"` + // CommitSha: Commit SHA of the git push. This field is populated if + // `git_destination` are specified in ExportAgentRequest. + CommitSha string `json:"commitSha,omitempty"` + // ForceSendFields is a list of field names (e.g. "AgentContent") to // unconditionally include in API requests. By default, fields with // empty or default values are omitted from API requests. However, any diff --git a/dialogflow/v3beta1/dialogflow-api.json b/dialogflow/v3beta1/dialogflow-api.json index b9cd210bba5..40f602e617f 100644 --- a/dialogflow/v3beta1/dialogflow-api.json +++ b/dialogflow/v3beta1/dialogflow-api.json @@ -3820,7 +3820,7 @@ } } }, - "revision": "20230626", + "revision": "20230705", "rootUrl": "https://dialogflow.googleapis.com/", "schemas": { "GoogleCloudDialogflowCxV3AudioInput": { @@ -4215,13 +4215,17 @@ "id": "GoogleCloudDialogflowCxV3ExportAgentResponse", "properties": { "agentContent": { - "description": "Uncompressed raw byte content for agent.", + "description": "Uncompressed raw byte content for agent. This field is populated if none of `agent_uri` and `git_destination` are specified in ExportAgentRequest.", "format": "byte", "type": "string" }, "agentUri": { "description": "The URI to a file containing the exported agent. This field is populated if `agent_uri` is specified in ExportAgentRequest.", "type": "string" + }, + "commitSha": { + "description": "Commit SHA of the git push. This field is populated if `git_destination` are specified in ExportAgentRequest.", + "type": "string" } }, "type": "object" @@ -5492,6 +5496,7 @@ "type": "object" }, "password": { + "deprecated": true, "description": "The password for HTTP Basic authentication.", "type": "string" }, @@ -5511,6 +5516,7 @@ "type": "string" }, "username": { + "deprecated": true, "description": "The user name for HTTP Basic authentication.", "type": "string" }, @@ -5808,9 +5814,14 @@ "type": "boolean" }, "enableStackdriverLogging": { + "deprecated": true, "description": "Indicates if stackdriver logging is enabled for the agent. Please use agent.advanced_settings instead.", "type": "boolean" }, + "gitIntegrationSettings": { + "$ref": "GoogleCloudDialogflowCxV3beta1AgentGitIntegrationSettings", + "description": "Git integration settings for this agent." + }, "locked": { "description": "Indicates whether the agent is locked for changes. If the agent is locked, modifications to the agent will be rejected except for RestoreAgent.", "type": "boolean" @@ -5849,6 +5860,47 @@ }, "type": "object" }, + "GoogleCloudDialogflowCxV3beta1AgentGitIntegrationSettings": { + "description": "Settings for connecting to Git repository for an agent.", + "id": "GoogleCloudDialogflowCxV3beta1AgentGitIntegrationSettings", + "properties": { + "githubSettings": { + "$ref": "GoogleCloudDialogflowCxV3beta1AgentGitIntegrationSettingsGithubSettings", + "description": "GitHub settings." + } + }, + "type": "object" + }, + "GoogleCloudDialogflowCxV3beta1AgentGitIntegrationSettingsGithubSettings": { + "description": "Settings of integration with GitHub.", + "id": "GoogleCloudDialogflowCxV3beta1AgentGitIntegrationSettingsGithubSettings", + "properties": { + "accessToken": { + "description": "The access token used to authenticate the access to the GitHub repository.", + "type": "string" + }, + "branches": { + "description": "A list of branches configured to be used from Dialogflow.", + "items": { + "type": "string" + }, + "type": "array" + }, + "displayName": { + "description": "The unique repository display name for the GitHub repository.", + "type": "string" + }, + "repositoryUri": { + "description": "The GitHub repository URI related to the agent.", + "type": "string" + }, + "trackingBranch": { + "description": "The branch of GitHub repository tracked for this agent.", + "type": "string" + } + }, + "type": "object" + }, "GoogleCloudDialogflowCxV3beta1AgentValidationResult": { "description": "The response message for Agents.GetAgentValidationResult.", "id": "GoogleCloudDialogflowCxV3beta1AgentValidationResult", @@ -6865,6 +6917,10 @@ "description": "Optional. Environment name. If not set, draft environment is assumed. Format: `projects//locations//agents//environments/`.", "type": "string" }, + "gitDestination": { + "$ref": "GoogleCloudDialogflowCxV3beta1ExportAgentRequestGitDestination", + "description": "Optional. The Git branch to export the agent to." + }, "includeBigqueryExportSettings": { "description": "Optional. Whether to include BigQuery Export setting.", "type": "boolean" @@ -6872,18 +6928,37 @@ }, "type": "object" }, + "GoogleCloudDialogflowCxV3beta1ExportAgentRequestGitDestination": { + "description": "Settings for exporting to a git branch.", + "id": "GoogleCloudDialogflowCxV3beta1ExportAgentRequestGitDestination", + "properties": { + "commitMessage": { + "description": "Commit message for the git push.", + "type": "string" + }, + "trackingBranch": { + "description": "Tracking branch for the git push.", + "type": "string" + } + }, + "type": "object" + }, "GoogleCloudDialogflowCxV3beta1ExportAgentResponse": { "description": "The response message for Agents.ExportAgent.", "id": "GoogleCloudDialogflowCxV3beta1ExportAgentResponse", "properties": { "agentContent": { - "description": "Uncompressed raw byte content for agent.", + "description": "Uncompressed raw byte content for agent. This field is populated if none of `agent_uri` and `git_destination` are specified in ExportAgentRequest.", "format": "byte", "type": "string" }, "agentUri": { "description": "The URI to a file containing the exported agent. This field is populated if `agent_uri` is specified in ExportAgentRequest.", "type": "string" + }, + "commitSha": { + "description": "Commit SHA of the git push. This field is populated if `git_destination` are specified in ExportAgentRequest.", + "type": "string" } }, "type": "object" @@ -8380,9 +8455,11 @@ }, "intent": { "$ref": "GoogleCloudDialogflowCxV3beta1Intent", + "deprecated": true, "description": "The Intent that matched the conversational query. Some, not all fields are filled in this message, including but not limited to: `name` and `display_name`. This field is deprecated, please use QueryResult.match instead." }, "intentDetectionConfidence": { + "deprecated": true, "description": "The intent detection confidence. Values range from 0.0 (completely uncertain) to 1.0 (completely certain). This value is for informational purpose only and is only used to help match the best intent within the classification threshold. This value may change for the same end-user expression at any time due to a model retraining or change in implementation. This field is deprecated, please use QueryResult.match instead.", "format": "float", "type": "number" @@ -8680,6 +8757,10 @@ "description": "The [Google Cloud Storage](https://cloud.google.com/storage/docs/) URI to restore agent from. The format of this URI must be `gs:///`. Dialogflow performs a read operation for the Cloud Storage object on the caller's behalf, so your request authentication must have read permissions for the object. For more information, see [Dialogflow access control](https://cloud.google.com/dialogflow/cx/docs/concept/access-control#storage).", "type": "string" }, + "gitSource": { + "$ref": "GoogleCloudDialogflowCxV3beta1RestoreAgentRequestGitSource", + "description": "Setting for restoring from a git branch" + }, "restoreOption": { "description": "Agent restore mode. If not specified, `KEEP` is assumed.", "enum": [ @@ -8697,6 +8778,17 @@ }, "type": "object" }, + "GoogleCloudDialogflowCxV3beta1RestoreAgentRequestGitSource": { + "description": "Settings for restoring from a git branch", + "id": "GoogleCloudDialogflowCxV3beta1RestoreAgentRequestGitSource", + "properties": { + "trackingBranch": { + "description": "tracking branch for the git pull", + "type": "string" + } + }, + "type": "object" + }, "GoogleCloudDialogflowCxV3beta1RolloutConfig": { "description": "The configuration for auto rollout.", "id": "GoogleCloudDialogflowCxV3beta1RolloutConfig", @@ -9598,6 +9690,7 @@ "type": "string" }, "resources": { + "deprecated": true, "description": "The names of the resources where the message is found.", "items": { "type": "string" @@ -9823,6 +9916,7 @@ "type": "object" }, "password": { + "deprecated": true, "description": "The password for HTTP Basic authentication.", "type": "string" }, @@ -9842,6 +9936,7 @@ "type": "string" }, "username": { + "deprecated": true, "description": "The user name for HTTP Basic authentication.", "type": "string" }, @@ -11622,6 +11717,11 @@ "EXAMPLE", "TEMPLATE" ], + "enumDeprecated": [ + false, + false, + true + ], "enumDescriptions": [ "Not specified. This value should never be used.", "Examples do not contain @-prefixed entity type names, but example parts can be annotated with entity types.", @@ -12719,6 +12819,7 @@ "type": "boolean" }, "mlEnabled": { + "deprecated": true, "description": "Optional. Indicates whether Machine Learning is enabled for the intent. Note: If `ml_enabled` setting is set to false, then this intent is not taken into account during inference in `ML ONLY` match mode. Also, auto-markup in the UI is turned off. DEPRECATED! Please use `ml_disabled` field instead. NOTE: If both `ml_enabled` and `ml_disabled` are either not set or false, then the default value is determined as follows: - Before April 15th, 2018 the default is: ml_enabled = false / ml_disabled = true. - After April 15th, 2018 the default is: ml_enabled = true / ml_disabled = false.", "type": "boolean" }, @@ -13820,6 +13921,11 @@ "EXAMPLE", "TEMPLATE" ], + "enumDeprecated": [ + false, + false, + true + ], "enumDescriptions": [ "Not specified. This value should never be used.", "Examples do not contain @-prefixed entity type names, but example parts can be annotated with entity types.", diff --git a/dialogflow/v3beta1/dialogflow-gen.go b/dialogflow/v3beta1/dialogflow-gen.go index 7cd3e62b0ae..bc799b41ab1 100644 --- a/dialogflow/v3beta1/dialogflow-gen.go +++ b/dialogflow/v3beta1/dialogflow-gen.go @@ -1171,13 +1171,19 @@ func (s *GoogleCloudDialogflowCxV3EventInput) MarshalJSON() ([]byte, error) { // GoogleCloudDialogflowCxV3ExportAgentResponse: The response message // for Agents.ExportAgent. type GoogleCloudDialogflowCxV3ExportAgentResponse struct { - // AgentContent: Uncompressed raw byte content for agent. + // AgentContent: Uncompressed raw byte content for agent. This field is + // populated if none of `agent_uri` and `git_destination` are specified + // in ExportAgentRequest. AgentContent string `json:"agentContent,omitempty"` // AgentUri: The URI to a file containing the exported agent. This field // is populated if `agent_uri` is specified in ExportAgentRequest. AgentUri string `json:"agentUri,omitempty"` + // CommitSha: Commit SHA of the git push. This field is populated if + // `git_destination` are specified in ExportAgentRequest. + CommitSha string `json:"commitSha,omitempty"` + // ForceSendFields is a list of field names (e.g. "AgentContent") to // unconditionally include in API requests. By default, fields with // empty or default values are omitted from API requests. However, any @@ -4127,6 +4133,9 @@ type GoogleCloudDialogflowCxV3beta1Agent struct { // for the agent. Please use agent.advanced_settings instead. EnableStackdriverLogging bool `json:"enableStackdriverLogging,omitempty"` + // GitIntegrationSettings: Git integration settings for this agent. + GitIntegrationSettings *GoogleCloudDialogflowCxV3beta1AgentGitIntegrationSettings `json:"gitIntegrationSettings,omitempty"` + // Locked: Indicates whether the agent is locked for changes. If the // agent is locked, modifications to the agent will be rejected except // for RestoreAgent. @@ -4191,6 +4200,80 @@ func (s *GoogleCloudDialogflowCxV3beta1Agent) MarshalJSON() ([]byte, error) { return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } +// GoogleCloudDialogflowCxV3beta1AgentGitIntegrationSettings: Settings +// for connecting to Git repository for an agent. +type GoogleCloudDialogflowCxV3beta1AgentGitIntegrationSettings struct { + // GithubSettings: GitHub settings. + GithubSettings *GoogleCloudDialogflowCxV3beta1AgentGitIntegrationSettingsGithubSettings `json:"githubSettings,omitempty"` + + // ForceSendFields is a list of field names (e.g. "GithubSettings") 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. "GithubSettings") 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 *GoogleCloudDialogflowCxV3beta1AgentGitIntegrationSettings) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDialogflowCxV3beta1AgentGitIntegrationSettings + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + +// GoogleCloudDialogflowCxV3beta1AgentGitIntegrationSettingsGithubSetting +// s: Settings of integration with GitHub. +type GoogleCloudDialogflowCxV3beta1AgentGitIntegrationSettingsGithubSettings struct { + // AccessToken: The access token used to authenticate the access to the + // GitHub repository. + AccessToken string `json:"accessToken,omitempty"` + + // Branches: A list of branches configured to be used from Dialogflow. + Branches []string `json:"branches,omitempty"` + + // DisplayName: The unique repository display name for the GitHub + // repository. + DisplayName string `json:"displayName,omitempty"` + + // RepositoryUri: The GitHub repository URI related to the agent. + RepositoryUri string `json:"repositoryUri,omitempty"` + + // TrackingBranch: The branch of GitHub repository tracked for this + // agent. + TrackingBranch string `json:"trackingBranch,omitempty"` + + // ForceSendFields is a list of field names (e.g. "AccessToken") 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. "AccessToken") 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 *GoogleCloudDialogflowCxV3beta1AgentGitIntegrationSettingsGithubSettings) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDialogflowCxV3beta1AgentGitIntegrationSettingsGithubSettings + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + // GoogleCloudDialogflowCxV3beta1AgentValidationResult: The response // message for Agents.GetAgentValidationResult. type GoogleCloudDialogflowCxV3beta1AgentValidationResult struct { @@ -5997,6 +6080,9 @@ type GoogleCloudDialogflowCxV3beta1ExportAgentRequest struct { // `projects//locations//agents//environments/`. Environment string `json:"environment,omitempty"` + // GitDestination: Optional. The Git branch to export the agent to. + GitDestination *GoogleCloudDialogflowCxV3beta1ExportAgentRequestGitDestination `json:"gitDestination,omitempty"` + // IncludeBigqueryExportSettings: Optional. Whether to include BigQuery // Export setting. IncludeBigqueryExportSettings bool `json:"includeBigqueryExportSettings,omitempty"` @@ -6024,16 +6110,54 @@ func (s *GoogleCloudDialogflowCxV3beta1ExportAgentRequest) MarshalJSON() ([]byte return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } +// GoogleCloudDialogflowCxV3beta1ExportAgentRequestGitDestination: +// Settings for exporting to a git branch. +type GoogleCloudDialogflowCxV3beta1ExportAgentRequestGitDestination struct { + // CommitMessage: Commit message for the git push. + CommitMessage string `json:"commitMessage,omitempty"` + + // TrackingBranch: Tracking branch for the git push. + TrackingBranch string `json:"trackingBranch,omitempty"` + + // ForceSendFields is a list of field names (e.g. "CommitMessage") 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. "CommitMessage") 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 *GoogleCloudDialogflowCxV3beta1ExportAgentRequestGitDestination) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDialogflowCxV3beta1ExportAgentRequestGitDestination + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + // GoogleCloudDialogflowCxV3beta1ExportAgentResponse: The response // message for Agents.ExportAgent. type GoogleCloudDialogflowCxV3beta1ExportAgentResponse struct { - // AgentContent: Uncompressed raw byte content for agent. + // AgentContent: Uncompressed raw byte content for agent. This field is + // populated if none of `agent_uri` and `git_destination` are specified + // in ExportAgentRequest. AgentContent string `json:"agentContent,omitempty"` // AgentUri: The URI to a file containing the exported agent. This field // is populated if `agent_uri` is specified in ExportAgentRequest. AgentUri string `json:"agentUri,omitempty"` + // CommitSha: Commit SHA of the git push. This field is populated if + // `git_destination` are specified in ExportAgentRequest. + CommitSha string `json:"commitSha,omitempty"` + // ForceSendFields is a list of field names (e.g. "AgentContent") to // unconditionally include in API requests. By default, fields with // empty or default values are omitted from API requests. However, any @@ -9575,6 +9699,9 @@ type GoogleCloudDialogflowCxV3beta1RestoreAgentRequest struct { // (https://cloud.google.com/dialogflow/cx/docs/concept/access-control#storage). AgentUri string `json:"agentUri,omitempty"` + // GitSource: Setting for restoring from a git branch + GitSource *GoogleCloudDialogflowCxV3beta1RestoreAgentRequestGitSource `json:"gitSource,omitempty"` + // RestoreOption: Agent restore mode. If not specified, `KEEP` is // assumed. // @@ -9610,6 +9737,36 @@ func (s *GoogleCloudDialogflowCxV3beta1RestoreAgentRequest) MarshalJSON() ([]byt return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } +// GoogleCloudDialogflowCxV3beta1RestoreAgentRequestGitSource: Settings +// for restoring from a git branch +type GoogleCloudDialogflowCxV3beta1RestoreAgentRequestGitSource struct { + // TrackingBranch: tracking branch for the git pull + TrackingBranch string `json:"trackingBranch,omitempty"` + + // ForceSendFields is a list of field names (e.g. "TrackingBranch") 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. "TrackingBranch") 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 *GoogleCloudDialogflowCxV3beta1RestoreAgentRequestGitSource) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDialogflowCxV3beta1RestoreAgentRequestGitSource + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + // GoogleCloudDialogflowCxV3beta1RolloutConfig: The configuration for // auto rollout. type GoogleCloudDialogflowCxV3beta1RolloutConfig struct { diff --git a/dlp/v2/dlp-api.json b/dlp/v2/dlp-api.json index 5dd3b2eedde..c4c52c86a02 100644 --- a/dlp/v2/dlp-api.json +++ b/dlp/v2/dlp-api.json @@ -3412,7 +3412,7 @@ } } }, - "revision": "20230625", + "revision": "20230702", "rootUrl": "https://dlp.googleapis.com/", "schemas": { "GooglePrivacyDlpV2Action": { @@ -6037,6 +6037,7 @@ "id": "GooglePrivacyDlpV2InfoTypeSummary", "properties": { "estimatedPrevalence": { + "deprecated": true, "description": "Not populated for predicted infotypes.", "format": "int32", "type": "integer" diff --git a/driveactivity/v2/driveactivity-api.json b/driveactivity/v2/driveactivity-api.json index cbd66b7bf83..f930128df6e 100644 --- a/driveactivity/v2/driveactivity-api.json +++ b/driveactivity/v2/driveactivity-api.json @@ -132,7 +132,7 @@ } } }, - "revision": "20230207", + "revision": "20230704", "rootUrl": "https://driveactivity.googleapis.com/", "schemas": { "Action": { @@ -625,10 +625,12 @@ }, "file": { "$ref": "File", + "deprecated": true, "description": "This field is deprecated; please use the `driveFile` field instead." }, "folder": { "$ref": "Folder", + "deprecated": true, "description": "This field is deprecated; please use the `driveFolder` field instead." }, "mimeType": { @@ -664,10 +666,12 @@ }, "file": { "$ref": "File", + "deprecated": true, "description": "This field is deprecated; please use the `driveFile` field instead." }, "folder": { "$ref": "Folder", + "deprecated": true, "description": "This field is deprecated; please use the `driveFolder` field instead." }, "name": { @@ -765,6 +769,7 @@ "type": "object" }, "File": { + "deprecated": true, "description": "This item is deprecated; please see `DriveFile` instead.", "id": "File", "properties": {}, @@ -794,6 +799,7 @@ "type": "object" }, "Folder": { + "deprecated": true, "description": "This item is deprecated; please see `DriveFolder` instead.", "id": "Folder", "properties": { @@ -922,6 +928,7 @@ }, "teamDrive": { "$ref": "TeamDriveReference", + "deprecated": true, "description": "This field is deprecated; please use the `drive` field instead." }, "user": { @@ -1283,6 +1290,7 @@ }, "teamDrive": { "$ref": "TeamDrive", + "deprecated": true, "description": "This field is deprecated; please use the `drive` field instead." } }, @@ -1302,12 +1310,14 @@ }, "teamDrive": { "$ref": "TeamDriveReference", + "deprecated": true, "description": "This field is deprecated; please use the `drive` field instead." } }, "type": "object" }, "TeamDrive": { + "deprecated": true, "description": "This item is deprecated; please see `Drive` instead.", "id": "TeamDrive", "properties": { @@ -1327,6 +1337,7 @@ "type": "object" }, "TeamDriveReference": { + "deprecated": true, "description": "This item is deprecated; please see `DriveReference` instead.", "id": "TeamDriveReference", "properties": { diff --git a/migrationcenter/v1alpha1/migrationcenter-api.json b/migrationcenter/v1alpha1/migrationcenter-api.json index ef9f5a743b3..df00579a9e9 100644 --- a/migrationcenter/v1alpha1/migrationcenter-api.json +++ b/migrationcenter/v1alpha1/migrationcenter-api.json @@ -2102,7 +2102,7 @@ } } }, - "revision": "20230619", + "revision": "20230630", "rootUrl": "https://migrationcenter.googleapis.com/", "schemas": { "AddAssetsToGroupRequest": { @@ -3038,6 +3038,7 @@ "type": "integer" }, "jobErrors": { + "deprecated": true, "description": "List of job-level errors. Deprecated, use the job errors under execution_errors instead.", "items": { "$ref": "ImportError" @@ -3195,6 +3196,15 @@ "IMPORT_JOB_FORMAT_EXPORTED_AZURE_CSV", "IMPORT_JOB_FORMAT_MANUAL_CSV" ], + "enumDeprecated": [ + false, + true, + false, + false, + false, + false, + false + ], "enumDescriptions": [ "Default value.", "Configuration management DB format.", @@ -3448,6 +3458,15 @@ "IMPORT_JOB_FORMAT_EXPORTED_AZURE_CSV", "IMPORT_JOB_FORMAT_MANUAL_CSV" ], + "enumDeprecated": [ + false, + true, + false, + false, + false, + false, + false + ], "enumDescriptions": [ "Default value.", "Configuration management DB format.", @@ -3544,6 +3563,7 @@ }, "gcsPayload": { "$ref": "GCSPayloadInfo", + "deprecated": true, "description": "The payload is in Google Cloud Storage." }, "inlinePayload": { @@ -3613,6 +3633,7 @@ "type": "array" }, "rowNumber": { + "deprecated": true, "description": "The row number where the error was detected.", "format": "int32", "type": "integer" @@ -3643,6 +3664,15 @@ "IMPORT_JOB_FORMAT_EXPORTED_AZURE_CSV", "IMPORT_JOB_FORMAT_MANUAL_CSV" ], + "enumDeprecated": [ + false, + true, + false, + false, + false, + false, + false + ], "enumDescriptions": [ "Default value.", "Configuration management DB format.", @@ -4681,6 +4711,7 @@ "properties": { "assetAge": { "$ref": "ReportSummaryChartData", + "deprecated": true, "description": "Count of assets grouped by age." }, "coreCountHistogram": { @@ -4693,6 +4724,7 @@ }, "memoryUtilization": { "$ref": "ReportSummaryChartData", + "deprecated": true, "description": "Total memory split into Used/Free buckets." }, "memoryUtilizationChart": { @@ -4709,6 +4741,7 @@ }, "storageUtilization": { "$ref": "ReportSummaryChartData", + "deprecated": true, "description": "Total storage split into Used/Free buckets." }, "storageUtilizationChart": { @@ -4844,10 +4877,12 @@ "description": "Total monthly cost for this preference set." }, "preferredRegion": { + "deprecated": true, "description": "Target region for this Preference Set", "type": "string" }, "pricingTrack": { + "deprecated": true, "description": "Text describing the pricing track specified for this Preference Set", "type": "string" }, @@ -4856,6 +4891,7 @@ "description": "A set of findings that applies to Stole-Tenant machines in the input." }, "topPriority": { + "deprecated": true, "description": "Text describing the business priority specified for this Preference Set", "type": "string" }, diff --git a/monitoring/v1/monitoring-api.json b/monitoring/v1/monitoring-api.json index dd4c63df872..7bf286c6dd2 100644 --- a/monitoring/v1/monitoring-api.json +++ b/monitoring/v1/monitoring-api.json @@ -806,7 +806,7 @@ } } }, - "revision": "20230326", + "revision": "20230703", "rootUrl": "https://monitoring.googleapis.com/", "schemas": { "Aggregation": { @@ -1949,6 +1949,7 @@ "id": "TableDisplayOptions", "properties": { "shownColumns": { + "deprecated": true, "description": "Optional. This field is unused and has been replaced by TimeSeriesTable.column_settings", "items": { "type": "string" @@ -2094,6 +2095,7 @@ }, "statisticalTimeSeriesFilter": { "$ref": "StatisticalTimeSeriesFilter", + "deprecated": true, "description": "Statistics based time series filter. Note: This field is deprecated and completely ignored by the API." } }, @@ -2121,6 +2123,7 @@ }, "statisticalTimeSeriesFilter": { "$ref": "StatisticalTimeSeriesFilter", + "deprecated": true, "description": "Statistics based time series filter. Note: This field is deprecated and completely ignored by the API." } }, diff --git a/monitoring/v3/monitoring-api.json b/monitoring/v3/monitoring-api.json index 6a1aab9daf8..f10a7fef98b 100644 --- a/monitoring/v3/monitoring-api.json +++ b/monitoring/v3/monitoring-api.json @@ -2714,7 +2714,7 @@ } } }, - "revision": "20230531", + "revision": "20230703", "rootUrl": "https://monitoring.googleapis.com/", "schemas": { "Aggregation": { @@ -3206,6 +3206,10 @@ "$ref": "MonitoringQueryLanguageCondition", "description": "A condition that uses the Monitoring Query Language to define alerts." }, + "conditionPrometheusQueryLanguage": { + "$ref": "PrometheusQueryLanguageCondition", + "description": "A condition that uses the Prometheus query language to define alerts." + }, "conditionThreshold": { "$ref": "MetricThreshold", "description": "A condition that compares a time series against a threshold." @@ -3427,6 +3431,10 @@ "mimeType": { "description": "The format of the content field. Presently, only the value \"text/markdown\" is supported. See Markdown (https://en.wikipedia.org/wiki/Markdown) for more information.", "type": "string" + }, + "subject": { + "description": "Optional. The subject line of the notification. The subject line may not exceed 10,240 bytes. In notifications generated by this policy, the contents of the subject line after variable expansion will be truncated to 255 bytes or shorter at the latest UTF-8 character boundary. The 255-byte limit is recommended by this thread (https://stackoverflow.com/questions/1592291/what-is-the-email-subject-length-limit). It is both the limit imposed by some third-party ticketing products and it is common to define textual fields in databases as VARCHAR(255).The contents of the subject line can be templatized by using variables (https://cloud.google.com/monitoring/alerts/doc-variables). If this field is missing or empty, a default subject line will be generated.", + "type": "string" } }, "type": "object" @@ -3894,6 +3902,7 @@ "type": "object" }, "InternalChecker": { + "deprecated": true, "description": "An internal checker allows Uptime checks to run on private/internal GCP resources.", "id": "InternalChecker", "properties": { @@ -4525,6 +4534,7 @@ "type": "string" }, "launchStage": { + "deprecated": true, "description": "Deprecated. Must use the MetricDescriptor.launch_stage instead.", "enum": [ "LAUNCH_STAGE_UNSPECIFIED", @@ -4916,6 +4926,7 @@ "type": "string" }, "supportedTiers": { + "deprecated": true, "description": "The tiers that support this notification channel; the project service tier must be one of the supported_tiers.", "items": { "enum": [ @@ -5089,6 +5100,42 @@ }, "type": "object" }, + "PrometheusQueryLanguageCondition": { + "description": "A condition type that allows alert policies to be defined using Prometheus Query Language (PromQL) (https://prometheus.io/docs/prometheus/latest/querying/basics/).The PrometheusQueryLanguageCondition message contains information from a Prometheus alerting rule and its associated rule group.A Prometheus alerting rule is described here (https://prometheus.io/docs/prometheus/latest/configuration/alerting_rules/). The semantics of a Prometheus alerting rule is described here (https://prometheus.io/docs/prometheus/latest/configuration/recording_rules/#rule).A Prometheus rule group is described here (https://prometheus.io/docs/prometheus/latest/configuration/recording_rules/). The semantics of a Prometheus rule group is described here (https://prometheus.io/docs/prometheus/latest/configuration/recording_rules/#rule_group).Because Cloud Alerting has no representation of a Prometheus rule group resource, we must embed the information of the parent rule group inside each of the conditions that refer to it. We must also update the contents of all Prometheus alerts in case the information of their rule group changes.The PrometheusQueryLanguageCondition protocol buffer combines the information of the corresponding rule group and alerting rule. The structure of the PrometheusQueryLanguageCondition protocol buffer does NOT mimic the structure of the Prometheus rule group and alerting rule YAML declarations. The PrometheusQueryLanguageCondition protocol buffer may change in the future to support future rule group and/or alerting rule features. There are no new such features at the present time (2023-06-26).", + "id": "PrometheusQueryLanguageCondition", + "properties": { + "alertRule": { + "description": "Optional. The alerting rule name of this alert in the corresponding Prometheus configuration file.Some external tools may require this field to be populated correctly in order to refer to the original Prometheus configuration file. The rule group name and the alert name are necessary to update the relevant AlertPolicies in case the definition of the rule group changes in the future.This field is optional. If this field is not empty, then it must be a valid Prometheus label name (https://prometheus.io/docs/concepts/data_model/#metric-names-and-labels).", + "type": "string" + }, + "duration": { + "description": "Optional. Alerts are considered firing once their PromQL expression was evaluated to be \"true\" for this long. Alerts whose PromQL expression was not evaluated to be \"true\" for long enough are considered pending. The default value is zero. Must be zero or positive.", + "format": "google-duration", + "type": "string" + }, + "evaluationInterval": { + "description": "Required. How often this rule should be evaluated. Must be a positive multiple of 30 seconds or missing. The default value is 30 seconds. If this PrometheusQueryLanguageCondition was generated from a Prometheus alerting rule, then this value should be taken from the enclosing rule group.", + "format": "google-duration", + "type": "string" + }, + "labels": { + "additionalProperties": { + "type": "string" + }, + "description": "Optional. Labels to add to or overwrite in the PromQL query result. Label names must be valid (https://prometheus.io/docs/concepts/data_model/#metric-names-and-labels). Label values can be templatized by using variables (https://cloud.google.com/monitoring/alerts/doc-variables). The only available variable names are the names of the labels in the PromQL result, including \"__name__\" and \"value\". \"labels\" may be empty.", + "type": "object" + }, + "query": { + "description": "Required. The PromQL expression to evaluate. Every evaluation cycle this expression is evaluated at the current time, and all resultant time series become pending/firing alerts. This field must not be empty.", + "type": "string" + }, + "ruleGroup": { + "description": "Optional. The rule group name of this alert in the corresponding Prometheus configuration file.Some external tools may require this field to be populated correctly in order to refer to the original Prometheus configuration file. The rule group name and the alert name are necessary to update the relevant AlertPolicies in case the definition of the rule group changes in the future.This field is optional. If this field is not empty, then it must be a valid Prometheus label name (https://prometheus.io/docs/concepts/data_model/#metric-names-and-labels).", + "type": "string" + } + }, + "type": "object" + }, "QueryTimeSeriesRequest": { "description": "The QueryTimeSeries request.", "id": "QueryTimeSeriesRequest", @@ -5763,6 +5810,7 @@ "description": "Contains information needed to make an HTTP or HTTPS check." }, "internalCheckers": { + "deprecated": true, "description": "The internal checkers that this check will egress from. If is_internal is true and this list is empty, the check will egress from all the InternalCheckers configured for the project that owns this UptimeCheckConfig.", "items": { "$ref": "InternalChecker" @@ -5770,6 +5818,7 @@ "type": "array" }, "isInternal": { + "deprecated": true, "description": "If this is true, then checks are made only from the 'internal_checkers'. If it is false, then checks are made only from the 'selected_regions'. It is an error to provide 'selected_regions' when is_internal is true, or to provide 'internal_checkers' when is_internal is false.", "type": "boolean" }, diff --git a/monitoring/v3/monitoring-gen.go b/monitoring/v3/monitoring-gen.go index 0c5038567a4..243f415aab4 100644 --- a/monitoring/v3/monitoring-gen.go +++ b/monitoring/v3/monitoring-gen.go @@ -1355,6 +1355,10 @@ type Condition struct { // Monitoring Query Language to define alerts. ConditionMonitoringQueryLanguage *MonitoringQueryLanguageCondition `json:"conditionMonitoringQueryLanguage,omitempty"` + // ConditionPrometheusQueryLanguage: A condition that uses the + // Prometheus query language to define alerts. + ConditionPrometheusQueryLanguage *PrometheusQueryLanguageCondition `json:"conditionPrometheusQueryLanguage,omitempty"` + // ConditionThreshold: A condition that compares a time series against a // threshold. ConditionThreshold *MetricThreshold `json:"conditionThreshold,omitempty"` @@ -1815,6 +1819,20 @@ type Documentation struct { // (https://en.wikipedia.org/wiki/Markdown) for more information. MimeType string `json:"mimeType,omitempty"` + // Subject: Optional. The subject line of the notification. The subject + // line may not exceed 10,240 bytes. In notifications generated by this + // policy, the contents of the subject line after variable expansion + // will be truncated to 255 bytes or shorter at the latest UTF-8 + // character boundary. The 255-byte limit is recommended by this thread + // (https://stackoverflow.com/questions/1592291/what-is-the-email-subject-length-limit). + // It is both the limit imposed by some third-party ticketing products + // and it is common to define textual fields in databases as + // VARCHAR(255).The contents of the subject line can be templatized by + // using variables + // (https://cloud.google.com/monitoring/alerts/doc-variables). If this + // field is missing or empty, a default subject line will be generated. + Subject string `json:"subject,omitempty"` + // ForceSendFields is a list of field names (e.g. "Content") to // unconditionally include in API requests. By default, fields with // empty or default values are omitted from API requests. However, any @@ -5016,6 +5034,107 @@ func (s *PointData) MarshalJSON() ([]byte, error) { return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } +// PrometheusQueryLanguageCondition: A condition type that allows alert +// policies to be defined using Prometheus Query Language (PromQL) +// (https://prometheus.io/docs/prometheus/latest/querying/basics/).The +// PrometheusQueryLanguageCondition message contains information from a +// Prometheus alerting rule and its associated rule group.A Prometheus +// alerting rule is described here +// (https://prometheus.io/docs/prometheus/latest/configuration/alerting_rules/). +// The semantics of a Prometheus alerting rule is described here +// (https://prometheus.io/docs/prometheus/latest/configuration/recording_rules/#rule).A +// Prometheus rule group is described here +// (https://prometheus.io/docs/prometheus/latest/configuration/recording_rules/). +// The semantics of a Prometheus rule group is described here +// (https://prometheus.io/docs/prometheus/latest/configuration/recording_rules/#rule_group).Because +// Cloud Alerting has no representation of a Prometheus rule group +// resource, we must embed the information of the parent rule group +// inside each of the conditions that refer to it. We must also update +// the contents of all Prometheus alerts in case the information of +// their rule group changes.The PrometheusQueryLanguageCondition +// protocol buffer combines the information of the corresponding rule +// group and alerting rule. The structure of the +// PrometheusQueryLanguageCondition protocol buffer does NOT mimic the +// structure of the Prometheus rule group and alerting rule YAML +// declarations. The PrometheusQueryLanguageCondition protocol buffer +// may change in the future to support future rule group and/or alerting +// rule features. There are no new such features at the present time +// (2023-06-26). +type PrometheusQueryLanguageCondition struct { + // AlertRule: Optional. The alerting rule name of this alert in the + // corresponding Prometheus configuration file.Some external tools may + // require this field to be populated correctly in order to refer to the + // original Prometheus configuration file. The rule group name and the + // alert name are necessary to update the relevant AlertPolicies in case + // the definition of the rule group changes in the future.This field is + // optional. If this field is not empty, then it must be a valid + // Prometheus label name + // (https://prometheus.io/docs/concepts/data_model/#metric-names-and-labels). + AlertRule string `json:"alertRule,omitempty"` + + // Duration: Optional. Alerts are considered firing once their PromQL + // expression was evaluated to be "true" for this long. Alerts whose + // PromQL expression was not evaluated to be "true" for long enough are + // considered pending. The default value is zero. Must be zero or + // positive. + Duration string `json:"duration,omitempty"` + + // EvaluationInterval: Required. How often this rule should be + // evaluated. Must be a positive multiple of 30 seconds or missing. The + // default value is 30 seconds. If this PrometheusQueryLanguageCondition + // was generated from a Prometheus alerting rule, then this value should + // be taken from the enclosing rule group. + EvaluationInterval string `json:"evaluationInterval,omitempty"` + + // Labels: Optional. Labels to add to or overwrite in the PromQL query + // result. Label names must be valid + // (https://prometheus.io/docs/concepts/data_model/#metric-names-and-labels). + // Label values can be templatized by using variables + // (https://cloud.google.com/monitoring/alerts/doc-variables). The only + // available variable names are the names of the labels in the PromQL + // result, including "__name__" and "value". "labels" may be empty. + Labels map[string]string `json:"labels,omitempty"` + + // Query: Required. The PromQL expression to evaluate. Every evaluation + // cycle this expression is evaluated at the current time, and all + // resultant time series become pending/firing alerts. This field must + // not be empty. + Query string `json:"query,omitempty"` + + // RuleGroup: Optional. The rule group name of this alert in the + // corresponding Prometheus configuration file.Some external tools may + // require this field to be populated correctly in order to refer to the + // original Prometheus configuration file. The rule group name and the + // alert name are necessary to update the relevant AlertPolicies in case + // the definition of the rule group changes in the future.This field is + // optional. If this field is not empty, then it must be a valid + // Prometheus label name + // (https://prometheus.io/docs/concepts/data_model/#metric-names-and-labels). + RuleGroup string `json:"ruleGroup,omitempty"` + + // ForceSendFields is a list of field names (e.g. "AlertRule") 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. "AlertRule") 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 *PrometheusQueryLanguageCondition) MarshalJSON() ([]byte, error) { + type NoMethod PrometheusQueryLanguageCondition + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + // QueryTimeSeriesRequest: The QueryTimeSeries request. type QueryTimeSeriesRequest struct { // PageSize: A positive number that is the maximum number of diff --git a/networkmanagement/v1beta1/networkmanagement-api.json b/networkmanagement/v1beta1/networkmanagement-api.json index 2363c653263..dfaac47fd0e 100644 --- a/networkmanagement/v1beta1/networkmanagement-api.json +++ b/networkmanagement/v1beta1/networkmanagement-api.json @@ -591,7 +591,7 @@ } } }, - "revision": "20230531", + "revision": "20230621", "rootUrl": "https://networkmanagement.googleapis.com/", "schemas": { "AbortInfo": { @@ -827,6 +827,7 @@ "type": "string" }, "serviceName": { + "deprecated": true, "description": "ID of Cloud Run Service this revision belongs to.", "type": "string" }, @@ -1502,6 +1503,7 @@ "type": "string" }, "serviceAccount": { + "deprecated": true, "description": "Service account authorized for the instance.", "type": "string" }, diff --git a/pagespeedonline/v5/pagespeedonline-api.json b/pagespeedonline/v5/pagespeedonline-api.json index a51c3196f3f..229a7217d25 100644 --- a/pagespeedonline/v5/pagespeedonline-api.json +++ b/pagespeedonline/v5/pagespeedonline-api.json @@ -193,7 +193,7 @@ } } }, - "revision": "20230316", + "revision": "20230705", "rootUrl": "https://pagespeedonline.googleapis.com/", "schemas": { "AuditRefs": { @@ -300,6 +300,7 @@ "type": "string" }, "emulatedFormFactor": { + "deprecated": true, "description": "The form factor the emulation should use. This field is deprecated, form_factor should be used instead.", "type": "string" }, diff --git a/pubsub/v1/pubsub-api.json b/pubsub/v1/pubsub-api.json index 62204b156ee..615355588f8 100644 --- a/pubsub/v1/pubsub-api.json +++ b/pubsub/v1/pubsub-api.json @@ -1566,7 +1566,7 @@ } } }, - "revision": "20230620", + "revision": "20230627", "rootUrl": "https://pubsub.googleapis.com/", "schemas": { "AcknowledgeRequest": { @@ -1675,7 +1675,7 @@ "type": "string" }, "filenameSuffix": { - "description": "Optional. User-provided suffix for Cloud Storage filename. See the [object naming requirements](https://cloud.google.com/storage/docs/objects#naming).", + "description": "Optional. User-provided suffix for Cloud Storage filename. See the [object naming requirements](https://cloud.google.com/storage/docs/objects#naming). Must not end in \"/\".", "type": "string" }, "maxBytes": { diff --git a/pubsub/v1/pubsub-gen.go b/pubsub/v1/pubsub-gen.go index a0bc0b01132..a7ea2203bb6 100644 --- a/pubsub/v1/pubsub-gen.go +++ b/pubsub/v1/pubsub-gen.go @@ -458,7 +458,8 @@ type CloudStorageConfig struct { // FilenameSuffix: Optional. User-provided suffix for Cloud Storage // filename. See the object naming requirements - // (https://cloud.google.com/storage/docs/objects#naming). + // (https://cloud.google.com/storage/docs/objects#naming). Must not end + // in "/". FilenameSuffix string `json:"filenameSuffix,omitempty"` // MaxBytes: Optional. The maximum bytes that can be written to a Cloud diff --git a/retail/v2/retail-api.json b/retail/v2/retail-api.json index 532cdf094ed..f0b95342e87 100644 --- a/retail/v2/retail-api.json +++ b/retail/v2/retail-api.json @@ -2059,7 +2059,7 @@ } } }, - "revision": "20230622", + "revision": "20230629", "rootUrl": "https://retail.googleapis.com/", "schemas": { "GoogleApiHttpBody": { @@ -5334,6 +5334,47 @@ }, "type": "object" }, + "GoogleCloudRetailV2alphaEnrollSolutionMetadata": { + "description": "Metadata related to the EnrollSolution method. This will be returned by the google.longrunning.Operation.metadata field.", + "id": "GoogleCloudRetailV2alphaEnrollSolutionMetadata", + "properties": {}, + "type": "object" + }, + "GoogleCloudRetailV2alphaEnrollSolutionResponse": { + "description": "Response for EnrollSolution method.", + "id": "GoogleCloudRetailV2alphaEnrollSolutionResponse", + "properties": { + "enrolledSolution": { + "description": "Retail API solution that the project has enrolled.", + "enum": [ + "SOLUTION_TYPE_UNSPECIFIED", + "SOLUTION_TYPE_RECOMMENDATION", + "SOLUTION_TYPE_SEARCH" + ], + "enumDescriptions": [ + "Default value.", + "Used for Recommendations AI.", + "Used for Retail Search." + ], + "type": "string" + }, + "searchSolutionUseCase": { + "description": "Search solution use case that the project has enrolled.", + "enum": [ + "SEARCH_SOLUTION_USE_CASE_UNSPECIFIED", + "SEARCH_SOLUTION_USE_CASE_SEARCH", + "SEARCH_SOLUTION_USE_CASE_BROWSE" + ], + "enumDescriptions": [ + "The value when it's unspecified. In this case, server behavior defaults to SEARCH_SOLUTION_USE_CASE_SEARCH.", + "Search use case. Expects the traffic has a non-empty query.", + "Browse use case. Expects the traffic has an empty query." + ], + "type": "string" + } + }, + "type": "object" + }, "GoogleCloudRetailV2alphaExportErrorsConfig": { "description": "Configuration of destination for Export related errors.", "id": "GoogleCloudRetailV2alphaExportErrorsConfig", diff --git a/retail/v2/retail-gen.go b/retail/v2/retail-gen.go index f72488c2d2b..c1924a991bf 100644 --- a/retail/v2/retail-gen.go +++ b/retail/v2/retail-gen.go @@ -6695,6 +6695,60 @@ func (s *GoogleCloudRetailV2alphaCreateModelMetadata) MarshalJSON() ([]byte, err return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } +// GoogleCloudRetailV2alphaEnrollSolutionMetadata: Metadata related to +// the EnrollSolution method. This will be returned by the +// google.longrunning.Operation.metadata field. +type GoogleCloudRetailV2alphaEnrollSolutionMetadata struct { +} + +// GoogleCloudRetailV2alphaEnrollSolutionResponse: Response for +// EnrollSolution method. +type GoogleCloudRetailV2alphaEnrollSolutionResponse struct { + // EnrolledSolution: Retail API solution that the project has enrolled. + // + // Possible values: + // "SOLUTION_TYPE_UNSPECIFIED" - Default value. + // "SOLUTION_TYPE_RECOMMENDATION" - Used for Recommendations AI. + // "SOLUTION_TYPE_SEARCH" - Used for Retail Search. + EnrolledSolution string `json:"enrolledSolution,omitempty"` + + // SearchSolutionUseCase: Search solution use case that the project has + // enrolled. + // + // Possible values: + // "SEARCH_SOLUTION_USE_CASE_UNSPECIFIED" - The value when it's + // unspecified. In this case, server behavior defaults to + // SEARCH_SOLUTION_USE_CASE_SEARCH. + // "SEARCH_SOLUTION_USE_CASE_SEARCH" - Search use case. Expects the + // traffic has a non-empty query. + // "SEARCH_SOLUTION_USE_CASE_BROWSE" - Browse use case. Expects the + // traffic has an empty query. + SearchSolutionUseCase string `json:"searchSolutionUseCase,omitempty"` + + // ForceSendFields is a list of field names (e.g. "EnrolledSolution") 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. "EnrolledSolution") 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 *GoogleCloudRetailV2alphaEnrollSolutionResponse) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudRetailV2alphaEnrollSolutionResponse + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + // GoogleCloudRetailV2alphaExportErrorsConfig: Configuration of // destination for Export related errors. type GoogleCloudRetailV2alphaExportErrorsConfig struct { diff --git a/retail/v2alpha/retail-api.json b/retail/v2alpha/retail-api.json index f63ae75e8fb..43b3d20731c 100644 --- a/retail/v2alpha/retail-api.json +++ b/retail/v2alpha/retail-api.json @@ -106,6 +106,86 @@ "protocol": "rest", "resources": { "projects": { + "methods": { + "enrollSolution": { + "description": "Enrolls retail API solution for the project. Recommendation solution is enrolled by default when your project enables Retail API. You don't need to call this API for the recommendation solution.", + "flatPath": "v2alpha/projects/{projectsId}:enrollSolution", + "httpMethod": "POST", + "id": "retail.projects.enrollSolution", + "parameterOrder": [ + "project" + ], + "parameters": { + "project": { + "description": "Required. Full resource name of parent. Format: `projects/{project_number_or_id}`", + "location": "path", + "pattern": "^projects/[^/]+$", + "required": true, + "type": "string" + } + }, + "path": "v2alpha/{+project}:enrollSolution", + "request": { + "$ref": "GoogleCloudRetailV2alphaEnrollSolutionRequest" + }, + "response": { + "$ref": "GoogleLongrunningOperation" + }, + "scopes": [ + "https://www.googleapis.com/auth/cloud-platform" + ] + }, + "getRetailProject": { + "description": "Gets the project. Throws NOT_FOUND if the project wasn't initialized for Retail API Service.", + "flatPath": "v2alpha/projects/{projectsId}/retailProject", + "httpMethod": "GET", + "id": "retail.projects.getRetailProject", + "parameterOrder": [ + "name" + ], + "parameters": { + "name": { + "description": "Required. Full resource name of the project. Format: `projects/{project_number_or_id}/retailProject`", + "location": "path", + "pattern": "^projects/[^/]+/retailProject$", + "required": true, + "type": "string" + } + }, + "path": "v2alpha/{+name}", + "response": { + "$ref": "GoogleCloudRetailV2alphaProject" + }, + "scopes": [ + "https://www.googleapis.com/auth/cloud-platform" + ] + }, + "listEnrolledSolutions": { + "description": "Lists all the retail API solutions the project has enrolled.", + "flatPath": "v2alpha/projects/{projectsId}:enrolledSolutions", + "httpMethod": "GET", + "id": "retail.projects.listEnrolledSolutions", + "parameterOrder": [ + "parent" + ], + "parameters": { + "parent": { + "description": "Required. Full resource name of parent. Format: `projects/{project_number_or_id}`", + "location": "path", + "pattern": "^projects/[^/]+$", + "required": true, + "type": "string" + } + }, + "path": "v2alpha/{+parent}:enrolledSolutions", + "response": { + "$ref": "GoogleCloudRetailV2alphaListEnrolledSolutionsResponse" + }, + "scopes": [ + "https://www.googleapis.com/auth/cloud-platform" + ] + } + }, "resources": { "locations": { "resources": { @@ -2213,11 +2293,43 @@ ] } } + }, + "retailProject": { + "methods": { + "acceptTerms": { + "description": "Accepts service terms for this project. By making requests to this API, you agree to the terms of service linked below. https://cloud.google.com/retail/data-use-terms", + "flatPath": "v2alpha/projects/{projectsId}/retailProject:acceptTerms", + "httpMethod": "POST", + "id": "retail.projects.retailProject.acceptTerms", + "parameterOrder": [ + "project" + ], + "parameters": { + "project": { + "description": "Required. Full resource name of the project. Format: `projects/{project_number_or_id}/retailProject`", + "location": "path", + "pattern": "^projects/[^/]+/retailProject$", + "required": true, + "type": "string" + } + }, + "path": "v2alpha/{+project}:acceptTerms", + "request": { + "$ref": "GoogleCloudRetailV2alphaAcceptTermsRequest" + }, + "response": { + "$ref": "GoogleCloudRetailV2alphaProject" + }, + "scopes": [ + "https://www.googleapis.com/auth/cloud-platform" + ] + } + } } } } }, - "revision": "20230622", + "revision": "20230629", "rootUrl": "https://retail.googleapis.com/", "schemas": { "GoogleApiHttpBody": { @@ -2837,6 +2949,12 @@ }, "type": "object" }, + "GoogleCloudRetailV2alphaAcceptTermsRequest": { + "description": "Request for AcceptTerms method.", + "id": "GoogleCloudRetailV2alphaAcceptTermsRequest", + "properties": {}, + "type": "object" + }, "GoogleCloudRetailV2alphaAddCatalogAttributeRequest": { "description": "Request for CatalogService.AddCatalogAttribute method.", "id": "GoogleCloudRetailV2alphaAddCatalogAttributeRequest", @@ -3585,6 +3703,82 @@ }, "type": "object" }, + "GoogleCloudRetailV2alphaEnrollSolutionMetadata": { + "description": "Metadata related to the EnrollSolution method. This will be returned by the google.longrunning.Operation.metadata field.", + "id": "GoogleCloudRetailV2alphaEnrollSolutionMetadata", + "properties": {}, + "type": "object" + }, + "GoogleCloudRetailV2alphaEnrollSolutionRequest": { + "description": "Request for EnrollSolution method.", + "id": "GoogleCloudRetailV2alphaEnrollSolutionRequest", + "properties": { + "searchSolutionUseCase": { + "description": "Solution use case to enroll. Currently settable for Browse to enroll. It should be only set when [solution] is set as SolutionType.SOLUTION_TYPE_SEARCH or an INVALID_ARGUMENT error is thrown.", + "enum": [ + "SEARCH_SOLUTION_USE_CASE_UNSPECIFIED", + "SEARCH_SOLUTION_USE_CASE_SEARCH", + "SEARCH_SOLUTION_USE_CASE_BROWSE" + ], + "enumDescriptions": [ + "The value when it's unspecified. In this case, server behavior defaults to SEARCH_SOLUTION_USE_CASE_SEARCH.", + "Search use case. Expects the traffic has a non-empty query.", + "Browse use case. Expects the traffic has an empty query." + ], + "type": "string" + }, + "solution": { + "description": "Required. Solution to enroll.", + "enum": [ + "SOLUTION_TYPE_UNSPECIFIED", + "SOLUTION_TYPE_RECOMMENDATION", + "SOLUTION_TYPE_SEARCH" + ], + "enumDescriptions": [ + "Default value.", + "Used for Recommendations AI.", + "Used for Retail Search." + ], + "type": "string" + } + }, + "type": "object" + }, + "GoogleCloudRetailV2alphaEnrollSolutionResponse": { + "description": "Response for EnrollSolution method.", + "id": "GoogleCloudRetailV2alphaEnrollSolutionResponse", + "properties": { + "enrolledSolution": { + "description": "Retail API solution that the project has enrolled.", + "enum": [ + "SOLUTION_TYPE_UNSPECIFIED", + "SOLUTION_TYPE_RECOMMENDATION", + "SOLUTION_TYPE_SEARCH" + ], + "enumDescriptions": [ + "Default value.", + "Used for Recommendations AI.", + "Used for Retail Search." + ], + "type": "string" + }, + "searchSolutionUseCase": { + "description": "Search solution use case that the project has enrolled.", + "enum": [ + "SEARCH_SOLUTION_USE_CASE_UNSPECIFIED", + "SEARCH_SOLUTION_USE_CASE_SEARCH", + "SEARCH_SOLUTION_USE_CASE_BROWSE" + ], + "enumDescriptions": [ + "The value when it's unspecified. In this case, server behavior defaults to SEARCH_SOLUTION_USE_CASE_SEARCH.", + "Search use case. Expects the traffic has a non-empty query.", + "Browse use case. Expects the traffic has an empty query." + ], + "type": "string" + } + }, + "type": "object" + }, "GoogleCloudRetailV2alphaExperimentInfo": { "description": "Metadata for active A/B testing Experiment.", "id": "GoogleCloudRetailV2alphaExperimentInfo", @@ -4018,6 +4212,30 @@ }, "type": "object" }, + "GoogleCloudRetailV2alphaListEnrolledSolutionsResponse": { + "description": "Response for ListEnrolledSolutions method.", + "id": "GoogleCloudRetailV2alphaListEnrolledSolutionsResponse", + "properties": { + "enrolledSolutions": { + "description": "Retail API solutions that the project has enrolled.", + "items": { + "enum": [ + "SOLUTION_TYPE_UNSPECIFIED", + "SOLUTION_TYPE_RECOMMENDATION", + "SOLUTION_TYPE_SEARCH" + ], + "enumDescriptions": [ + "Default value.", + "Used for Recommendations AI.", + "Used for Retail Search." + ], + "type": "string" + }, + "type": "array" + } + }, + "type": "object" + }, "GoogleCloudRetailV2alphaListMerchantCenterAccountLinksResponse": { "description": "Response for MerchantCenterAccountLinkService.ListMerchantCenterAccountLinks method.", "id": "GoogleCloudRetailV2alphaListMerchantCenterAccountLinksResponse", @@ -4979,6 +5197,36 @@ }, "type": "object" }, + "GoogleCloudRetailV2alphaProject": { + "description": "Metadata that describes a Cloud Retail Project.", + "id": "GoogleCloudRetailV2alphaProject", + "properties": { + "enrolledSolutions": { + "description": "Output only. Retail API solutions that the project has enrolled.", + "items": { + "enum": [ + "SOLUTION_TYPE_UNSPECIFIED", + "SOLUTION_TYPE_RECOMMENDATION", + "SOLUTION_TYPE_SEARCH" + ], + "enumDescriptions": [ + "Default value.", + "Used for Recommendations AI.", + "Used for Retail Search." + ], + "type": "string" + }, + "readOnly": true, + "type": "array" + }, + "name": { + "description": "Output only. Full resource name of the retail project, such as `projects/{project_id_or_number}/retailProject`.", + "readOnly": true, + "type": "string" + } + }, + "type": "object" + }, "GoogleCloudRetailV2alphaPromotion": { "description": "Promotion specification.", "id": "GoogleCloudRetailV2alphaPromotion", diff --git a/retail/v2alpha/retail-gen.go b/retail/v2alpha/retail-gen.go index 7aae457a6b1..b0a0db5b85d 100644 --- a/retail/v2alpha/retail-gen.go +++ b/retail/v2alpha/retail-gen.go @@ -142,6 +142,7 @@ func NewProjectsService(s *Service) *ProjectsService { rs := &ProjectsService{s: s} rs.Locations = NewProjectsLocationsService(s) rs.Operations = NewProjectsOperationsService(s) + rs.RetailProject = NewProjectsRetailProjectService(s) return rs } @@ -151,6 +152,8 @@ type ProjectsService struct { Locations *ProjectsLocationsService Operations *ProjectsOperationsService + + RetailProject *ProjectsRetailProjectService } func NewProjectsLocationsService(s *Service) *ProjectsLocationsService { @@ -363,6 +366,15 @@ type ProjectsOperationsService struct { s *Service } +func NewProjectsRetailProjectService(s *Service) *ProjectsRetailProjectService { + rs := &ProjectsRetailProjectService{s: s} + return rs +} + +type ProjectsRetailProjectService struct { + s *Service +} + // GoogleApiHttpBody: Message that represents an arbitrary HTTP body. It // should only be used for payload formats that can't be represented as // JSON, such as raw binary or an HTML page. This message can be used @@ -1450,6 +1462,11 @@ func (s *GoogleCloudRetailV2UserEventImportSummary) MarshalJSON() ([]byte, error return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } +// GoogleCloudRetailV2alphaAcceptTermsRequest: Request for AcceptTerms +// method. +type GoogleCloudRetailV2alphaAcceptTermsRequest struct { +} + // GoogleCloudRetailV2alphaAddCatalogAttributeRequest: Request for // CatalogService.AddCatalogAttribute method. type GoogleCloudRetailV2alphaAddCatalogAttributeRequest struct { @@ -2849,6 +2866,111 @@ func (s *GoogleCloudRetailV2alphaCustomAttribute) UnmarshalJSON(data []byte) err return nil } +// GoogleCloudRetailV2alphaEnrollSolutionMetadata: Metadata related to +// the EnrollSolution method. This will be returned by the +// google.longrunning.Operation.metadata field. +type GoogleCloudRetailV2alphaEnrollSolutionMetadata struct { +} + +// GoogleCloudRetailV2alphaEnrollSolutionRequest: Request for +// EnrollSolution method. +type GoogleCloudRetailV2alphaEnrollSolutionRequest struct { + // SearchSolutionUseCase: Solution use case to enroll. Currently + // settable for Browse to enroll. It should be only set when [solution] + // is set as SolutionType.SOLUTION_TYPE_SEARCH or an INVALID_ARGUMENT + // error is thrown. + // + // Possible values: + // "SEARCH_SOLUTION_USE_CASE_UNSPECIFIED" - The value when it's + // unspecified. In this case, server behavior defaults to + // SEARCH_SOLUTION_USE_CASE_SEARCH. + // "SEARCH_SOLUTION_USE_CASE_SEARCH" - Search use case. Expects the + // traffic has a non-empty query. + // "SEARCH_SOLUTION_USE_CASE_BROWSE" - Browse use case. Expects the + // traffic has an empty query. + SearchSolutionUseCase string `json:"searchSolutionUseCase,omitempty"` + + // Solution: Required. Solution to enroll. + // + // Possible values: + // "SOLUTION_TYPE_UNSPECIFIED" - Default value. + // "SOLUTION_TYPE_RECOMMENDATION" - Used for Recommendations AI. + // "SOLUTION_TYPE_SEARCH" - Used for Retail Search. + Solution string `json:"solution,omitempty"` + + // ForceSendFields is a list of field names (e.g. + // "SearchSolutionUseCase") 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. "SearchSolutionUseCase") 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 *GoogleCloudRetailV2alphaEnrollSolutionRequest) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudRetailV2alphaEnrollSolutionRequest + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + +// GoogleCloudRetailV2alphaEnrollSolutionResponse: Response for +// EnrollSolution method. +type GoogleCloudRetailV2alphaEnrollSolutionResponse struct { + // EnrolledSolution: Retail API solution that the project has enrolled. + // + // Possible values: + // "SOLUTION_TYPE_UNSPECIFIED" - Default value. + // "SOLUTION_TYPE_RECOMMENDATION" - Used for Recommendations AI. + // "SOLUTION_TYPE_SEARCH" - Used for Retail Search. + EnrolledSolution string `json:"enrolledSolution,omitempty"` + + // SearchSolutionUseCase: Search solution use case that the project has + // enrolled. + // + // Possible values: + // "SEARCH_SOLUTION_USE_CASE_UNSPECIFIED" - The value when it's + // unspecified. In this case, server behavior defaults to + // SEARCH_SOLUTION_USE_CASE_SEARCH. + // "SEARCH_SOLUTION_USE_CASE_SEARCH" - Search use case. Expects the + // traffic has a non-empty query. + // "SEARCH_SOLUTION_USE_CASE_BROWSE" - Browse use case. Expects the + // traffic has an empty query. + SearchSolutionUseCase string `json:"searchSolutionUseCase,omitempty"` + + // ForceSendFields is a list of field names (e.g. "EnrolledSolution") 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. "EnrolledSolution") 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 *GoogleCloudRetailV2alphaEnrollSolutionResponse) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudRetailV2alphaEnrollSolutionResponse + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + // GoogleCloudRetailV2alphaExperimentInfo: Metadata for active A/B // testing Experiment. type GoogleCloudRetailV2alphaExperimentInfo struct { @@ -3749,6 +3871,46 @@ func (s *GoogleCloudRetailV2alphaListControlsResponse) MarshalJSON() ([]byte, er return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } +// GoogleCloudRetailV2alphaListEnrolledSolutionsResponse: Response for +// ListEnrolledSolutions method. +type GoogleCloudRetailV2alphaListEnrolledSolutionsResponse struct { + // EnrolledSolutions: Retail API solutions that the project has + // enrolled. + // + // Possible values: + // "SOLUTION_TYPE_UNSPECIFIED" - Default value. + // "SOLUTION_TYPE_RECOMMENDATION" - Used for Recommendations AI. + // "SOLUTION_TYPE_SEARCH" - Used for Retail Search. + EnrolledSolutions []string `json:"enrolledSolutions,omitempty"` + + // ServerResponse contains the HTTP response code and headers from the + // server. + googleapi.ServerResponse `json:"-"` + + // ForceSendFields is a list of field names (e.g. "EnrolledSolutions") + // 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. "EnrolledSolutions") 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 *GoogleCloudRetailV2alphaListEnrolledSolutionsResponse) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudRetailV2alphaListEnrolledSolutionsResponse + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + // GoogleCloudRetailV2alphaListMerchantCenterAccountLinksResponse: // Response for // MerchantCenterAccountLinkService.ListMerchantCenterAccountLinks @@ -5580,6 +5742,50 @@ func (s *GoogleCloudRetailV2alphaProductLevelConfig) MarshalJSON() ([]byte, erro return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } +// GoogleCloudRetailV2alphaProject: Metadata that describes a Cloud +// Retail Project. +type GoogleCloudRetailV2alphaProject struct { + // EnrolledSolutions: Output only. Retail API solutions that the project + // has enrolled. + // + // Possible values: + // "SOLUTION_TYPE_UNSPECIFIED" - Default value. + // "SOLUTION_TYPE_RECOMMENDATION" - Used for Recommendations AI. + // "SOLUTION_TYPE_SEARCH" - Used for Retail Search. + EnrolledSolutions []string `json:"enrolledSolutions,omitempty"` + + // Name: Output only. Full resource name of the retail project, such as + // `projects/{project_id_or_number}/retailProject`. + 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. "EnrolledSolutions") + // 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. "EnrolledSolutions") 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 *GoogleCloudRetailV2alphaProject) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudRetailV2alphaProject + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + // GoogleCloudRetailV2alphaPromotion: Promotion specification. type GoogleCloudRetailV2alphaPromotion struct { // PromotionId: Promotion identifier, which is the final component of @@ -9715,57 +9921,501 @@ type GoogleRpcStatus struct { NullFields []string `json:"-"` } -func (s *GoogleRpcStatus) MarshalJSON() ([]byte, error) { - type NoMethod GoogleRpcStatus - raw := NoMethod(*s) - return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +func (s *GoogleRpcStatus) MarshalJSON() ([]byte, error) { + type NoMethod GoogleRpcStatus + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + +// GoogleTypeDate: 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 GoogleTypeDate 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 *GoogleTypeDate) MarshalJSON() ([]byte, error) { + type NoMethod GoogleTypeDate + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + +// method id "retail.projects.enrollSolution": + +type ProjectsEnrollSolutionCall struct { + s *Service + project string + googlecloudretailv2alphaenrollsolutionrequest *GoogleCloudRetailV2alphaEnrollSolutionRequest + urlParams_ gensupport.URLParams + ctx_ context.Context + header_ http.Header +} + +// EnrollSolution: Enrolls retail API solution for the project. +// Recommendation solution is enrolled by default when your project +// enables Retail API. You don't need to call this API for the +// recommendation solution. +// +// - project: Full resource name of parent. Format: +// `projects/{project_number_or_id}`. +func (r *ProjectsService) EnrollSolution(project string, googlecloudretailv2alphaenrollsolutionrequest *GoogleCloudRetailV2alphaEnrollSolutionRequest) *ProjectsEnrollSolutionCall { + c := &ProjectsEnrollSolutionCall{s: r.s, urlParams_: make(gensupport.URLParams)} + c.project = project + c.googlecloudretailv2alphaenrollsolutionrequest = googlecloudretailv2alphaenrollsolutionrequest + 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 *ProjectsEnrollSolutionCall) Fields(s ...googleapi.Field) *ProjectsEnrollSolutionCall { + 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 *ProjectsEnrollSolutionCall) Context(ctx context.Context) *ProjectsEnrollSolutionCall { + 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 *ProjectsEnrollSolutionCall) Header() http.Header { + if c.header_ == nil { + c.header_ = make(http.Header) + } + return c.header_ +} + +func (c *ProjectsEnrollSolutionCall) 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.googlecloudretailv2alphaenrollsolutionrequest) + 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, "v2alpha/{+project}:enrollSolution") + 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{ + "project": c.project, + }) + return gensupport.SendRequest(c.ctx_, c.s.client, req) +} + +// Do executes the "retail.projects.enrollSolution" 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 *ProjectsEnrollSolutionCall) 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": "Enrolls retail API solution for the project. Recommendation solution is enrolled by default when your project enables Retail API. You don't need to call this API for the recommendation solution.", + // "flatPath": "v2alpha/projects/{projectsId}:enrollSolution", + // "httpMethod": "POST", + // "id": "retail.projects.enrollSolution", + // "parameterOrder": [ + // "project" + // ], + // "parameters": { + // "project": { + // "description": "Required. Full resource name of parent. Format: `projects/{project_number_or_id}`", + // "location": "path", + // "pattern": "^projects/[^/]+$", + // "required": true, + // "type": "string" + // } + // }, + // "path": "v2alpha/{+project}:enrollSolution", + // "request": { + // "$ref": "GoogleCloudRetailV2alphaEnrollSolutionRequest" + // }, + // "response": { + // "$ref": "GoogleLongrunningOperation" + // }, + // "scopes": [ + // "https://www.googleapis.com/auth/cloud-platform" + // ] + // } + +} + +// method id "retail.projects.getRetailProject": + +type ProjectsGetRetailProjectCall struct { + s *Service + name string + urlParams_ gensupport.URLParams + ifNoneMatch_ string + ctx_ context.Context + header_ http.Header +} + +// GetRetailProject: Gets the project. Throws NOT_FOUND if the project +// wasn't initialized for Retail API Service. +// +// - name: Full resource name of the project. Format: +// `projects/{project_number_or_id}/retailProject`. +func (r *ProjectsService) GetRetailProject(name string) *ProjectsGetRetailProjectCall { + c := &ProjectsGetRetailProjectCall{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 *ProjectsGetRetailProjectCall) Fields(s ...googleapi.Field) *ProjectsGetRetailProjectCall { + 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 *ProjectsGetRetailProjectCall) IfNoneMatch(entityTag string) *ProjectsGetRetailProjectCall { + 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 *ProjectsGetRetailProjectCall) Context(ctx context.Context) *ProjectsGetRetailProjectCall { + 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 *ProjectsGetRetailProjectCall) Header() http.Header { + if c.header_ == nil { + c.header_ = make(http.Header) + } + return c.header_ +} + +func (c *ProjectsGetRetailProjectCall) 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, "v2alpha/{+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 "retail.projects.getRetailProject" call. +// Exactly one of *GoogleCloudRetailV2alphaProject or error will be +// non-nil. Any non-2xx status code is an error. Response headers are in +// either *GoogleCloudRetailV2alphaProject.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 *ProjectsGetRetailProjectCall) Do(opts ...googleapi.CallOption) (*GoogleCloudRetailV2alphaProject, 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 := &GoogleCloudRetailV2alphaProject{ + 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 project. Throws NOT_FOUND if the project wasn't initialized for Retail API Service.", + // "flatPath": "v2alpha/projects/{projectsId}/retailProject", + // "httpMethod": "GET", + // "id": "retail.projects.getRetailProject", + // "parameterOrder": [ + // "name" + // ], + // "parameters": { + // "name": { + // "description": "Required. Full resource name of the project. Format: `projects/{project_number_or_id}/retailProject`", + // "location": "path", + // "pattern": "^projects/[^/]+/retailProject$", + // "required": true, + // "type": "string" + // } + // }, + // "path": "v2alpha/{+name}", + // "response": { + // "$ref": "GoogleCloudRetailV2alphaProject" + // }, + // "scopes": [ + // "https://www.googleapis.com/auth/cloud-platform" + // ] + // } + +} + +// method id "retail.projects.listEnrolledSolutions": + +type ProjectsListEnrolledSolutionsCall struct { + s *Service + parent string + urlParams_ gensupport.URLParams + ifNoneMatch_ string + ctx_ context.Context + header_ http.Header +} + +// ListEnrolledSolutions: Lists all the retail API solutions the project +// has enrolled. +// +// - parent: Full resource name of parent. Format: +// `projects/{project_number_or_id}`. +func (r *ProjectsService) ListEnrolledSolutions(parent string) *ProjectsListEnrolledSolutionsCall { + c := &ProjectsListEnrolledSolutionsCall{s: r.s, urlParams_: make(gensupport.URLParams)} + c.parent = parent + 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 *ProjectsListEnrolledSolutionsCall) Fields(s ...googleapi.Field) *ProjectsListEnrolledSolutionsCall { + c.urlParams_.Set("fields", googleapi.CombineFields(s)) + return c } -// GoogleTypeDate: 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 GoogleTypeDate 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"` +// 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 *ProjectsListEnrolledSolutionsCall) IfNoneMatch(entityTag string) *ProjectsListEnrolledSolutionsCall { + c.ifNoneMatch_ = entityTag + return c +} - // 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"` +// 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 *ProjectsListEnrolledSolutionsCall) Context(ctx context.Context) *ProjectsListEnrolledSolutionsCall { + c.ctx_ = ctx + return c +} - // 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:"-"` +// Header returns an http.Header that can be modified by the caller to +// add HTTP headers to the request. +func (c *ProjectsListEnrolledSolutionsCall) Header() http.Header { + if c.header_ == nil { + c.header_ = make(http.Header) + } + return c.header_ +} - // 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 (c *ProjectsListEnrolledSolutionsCall) 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, "v2alpha/{+parent}:enrolledSolutions") + 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) } -func (s *GoogleTypeDate) MarshalJSON() ([]byte, error) { - type NoMethod GoogleTypeDate - raw := NoMethod(*s) - return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +// Do executes the "retail.projects.listEnrolledSolutions" call. +// Exactly one of *GoogleCloudRetailV2alphaListEnrolledSolutionsResponse +// or error will be non-nil. Any non-2xx status code is an error. +// Response headers are in either +// *GoogleCloudRetailV2alphaListEnrolledSolutionsResponse.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 *ProjectsListEnrolledSolutionsCall) Do(opts ...googleapi.CallOption) (*GoogleCloudRetailV2alphaListEnrolledSolutionsResponse, 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 := &GoogleCloudRetailV2alphaListEnrolledSolutionsResponse{ + 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 retail API solutions the project has enrolled.", + // "flatPath": "v2alpha/projects/{projectsId}:enrolledSolutions", + // "httpMethod": "GET", + // "id": "retail.projects.listEnrolledSolutions", + // "parameterOrder": [ + // "parent" + // ], + // "parameters": { + // "parent": { + // "description": "Required. Full resource name of parent. Format: `projects/{project_number_or_id}`", + // "location": "path", + // "pattern": "^projects/[^/]+$", + // "required": true, + // "type": "string" + // } + // }, + // "path": "v2alpha/{+parent}:enrolledSolutions", + // "response": { + // "$ref": "GoogleCloudRetailV2alphaListEnrolledSolutionsResponse" + // }, + // "scopes": [ + // "https://www.googleapis.com/auth/cloud-platform" + // ] + // } + } // method id "retail.projects.locations.catalogs.completeQuery": @@ -20525,3 +21175,148 @@ func (c *ProjectsOperationsListCall) Pages(ctx context.Context, f func(*GoogleLo c.PageToken(x.NextPageToken) } } + +// method id "retail.projects.retailProject.acceptTerms": + +type ProjectsRetailProjectAcceptTermsCall struct { + s *Service + project string + googlecloudretailv2alphaaccepttermsrequest *GoogleCloudRetailV2alphaAcceptTermsRequest + urlParams_ gensupport.URLParams + ctx_ context.Context + header_ http.Header +} + +// AcceptTerms: Accepts service terms for this project. By making +// requests to this API, you agree to the terms of service linked below. +// https://cloud.google.com/retail/data-use-terms +// +// - project: Full resource name of the project. Format: +// `projects/{project_number_or_id}/retailProject`. +func (r *ProjectsRetailProjectService) AcceptTerms(project string, googlecloudretailv2alphaaccepttermsrequest *GoogleCloudRetailV2alphaAcceptTermsRequest) *ProjectsRetailProjectAcceptTermsCall { + c := &ProjectsRetailProjectAcceptTermsCall{s: r.s, urlParams_: make(gensupport.URLParams)} + c.project = project + c.googlecloudretailv2alphaaccepttermsrequest = googlecloudretailv2alphaaccepttermsrequest + 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 *ProjectsRetailProjectAcceptTermsCall) Fields(s ...googleapi.Field) *ProjectsRetailProjectAcceptTermsCall { + 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 *ProjectsRetailProjectAcceptTermsCall) Context(ctx context.Context) *ProjectsRetailProjectAcceptTermsCall { + 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 *ProjectsRetailProjectAcceptTermsCall) Header() http.Header { + if c.header_ == nil { + c.header_ = make(http.Header) + } + return c.header_ +} + +func (c *ProjectsRetailProjectAcceptTermsCall) 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.googlecloudretailv2alphaaccepttermsrequest) + 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, "v2alpha/{+project}:acceptTerms") + 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{ + "project": c.project, + }) + return gensupport.SendRequest(c.ctx_, c.s.client, req) +} + +// Do executes the "retail.projects.retailProject.acceptTerms" call. +// Exactly one of *GoogleCloudRetailV2alphaProject or error will be +// non-nil. Any non-2xx status code is an error. Response headers are in +// either *GoogleCloudRetailV2alphaProject.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 *ProjectsRetailProjectAcceptTermsCall) Do(opts ...googleapi.CallOption) (*GoogleCloudRetailV2alphaProject, 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 := &GoogleCloudRetailV2alphaProject{ + 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": "Accepts service terms for this project. By making requests to this API, you agree to the terms of service linked below. https://cloud.google.com/retail/data-use-terms", + // "flatPath": "v2alpha/projects/{projectsId}/retailProject:acceptTerms", + // "httpMethod": "POST", + // "id": "retail.projects.retailProject.acceptTerms", + // "parameterOrder": [ + // "project" + // ], + // "parameters": { + // "project": { + // "description": "Required. Full resource name of the project. Format: `projects/{project_number_or_id}/retailProject`", + // "location": "path", + // "pattern": "^projects/[^/]+/retailProject$", + // "required": true, + // "type": "string" + // } + // }, + // "path": "v2alpha/{+project}:acceptTerms", + // "request": { + // "$ref": "GoogleCloudRetailV2alphaAcceptTermsRequest" + // }, + // "response": { + // "$ref": "GoogleCloudRetailV2alphaProject" + // }, + // "scopes": [ + // "https://www.googleapis.com/auth/cloud-platform" + // ] + // } + +} diff --git a/retail/v2beta/retail-api.json b/retail/v2beta/retail-api.json index b82cf76af9c..5fe0ca14c4a 100644 --- a/retail/v2beta/retail-api.json +++ b/retail/v2beta/retail-api.json @@ -2087,7 +2087,7 @@ } } }, - "revision": "20230622", + "revision": "20230629", "rootUrl": "https://retail.googleapis.com/", "schemas": { "GoogleApiHttpBody": { @@ -2774,6 +2774,47 @@ }, "type": "object" }, + "GoogleCloudRetailV2alphaEnrollSolutionMetadata": { + "description": "Metadata related to the EnrollSolution method. This will be returned by the google.longrunning.Operation.metadata field.", + "id": "GoogleCloudRetailV2alphaEnrollSolutionMetadata", + "properties": {}, + "type": "object" + }, + "GoogleCloudRetailV2alphaEnrollSolutionResponse": { + "description": "Response for EnrollSolution method.", + "id": "GoogleCloudRetailV2alphaEnrollSolutionResponse", + "properties": { + "enrolledSolution": { + "description": "Retail API solution that the project has enrolled.", + "enum": [ + "SOLUTION_TYPE_UNSPECIFIED", + "SOLUTION_TYPE_RECOMMENDATION", + "SOLUTION_TYPE_SEARCH" + ], + "enumDescriptions": [ + "Default value.", + "Used for Recommendations AI.", + "Used for Retail Search." + ], + "type": "string" + }, + "searchSolutionUseCase": { + "description": "Search solution use case that the project has enrolled.", + "enum": [ + "SEARCH_SOLUTION_USE_CASE_UNSPECIFIED", + "SEARCH_SOLUTION_USE_CASE_SEARCH", + "SEARCH_SOLUTION_USE_CASE_BROWSE" + ], + "enumDescriptions": [ + "The value when it's unspecified. In this case, server behavior defaults to SEARCH_SOLUTION_USE_CASE_SEARCH.", + "Search use case. Expects the traffic has a non-empty query.", + "Browse use case. Expects the traffic has an empty query." + ], + "type": "string" + } + }, + "type": "object" + }, "GoogleCloudRetailV2alphaExportErrorsConfig": { "description": "Configuration of destination for Export related errors.", "id": "GoogleCloudRetailV2alphaExportErrorsConfig", diff --git a/retail/v2beta/retail-gen.go b/retail/v2beta/retail-gen.go index 1a291bdfa95..a275f1e3d75 100644 --- a/retail/v2beta/retail-gen.go +++ b/retail/v2beta/retail-gen.go @@ -1539,6 +1539,60 @@ func (s *GoogleCloudRetailV2alphaCreateModelMetadata) MarshalJSON() ([]byte, err return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } +// GoogleCloudRetailV2alphaEnrollSolutionMetadata: Metadata related to +// the EnrollSolution method. This will be returned by the +// google.longrunning.Operation.metadata field. +type GoogleCloudRetailV2alphaEnrollSolutionMetadata struct { +} + +// GoogleCloudRetailV2alphaEnrollSolutionResponse: Response for +// EnrollSolution method. +type GoogleCloudRetailV2alphaEnrollSolutionResponse struct { + // EnrolledSolution: Retail API solution that the project has enrolled. + // + // Possible values: + // "SOLUTION_TYPE_UNSPECIFIED" - Default value. + // "SOLUTION_TYPE_RECOMMENDATION" - Used for Recommendations AI. + // "SOLUTION_TYPE_SEARCH" - Used for Retail Search. + EnrolledSolution string `json:"enrolledSolution,omitempty"` + + // SearchSolutionUseCase: Search solution use case that the project has + // enrolled. + // + // Possible values: + // "SEARCH_SOLUTION_USE_CASE_UNSPECIFIED" - The value when it's + // unspecified. In this case, server behavior defaults to + // SEARCH_SOLUTION_USE_CASE_SEARCH. + // "SEARCH_SOLUTION_USE_CASE_SEARCH" - Search use case. Expects the + // traffic has a non-empty query. + // "SEARCH_SOLUTION_USE_CASE_BROWSE" - Browse use case. Expects the + // traffic has an empty query. + SearchSolutionUseCase string `json:"searchSolutionUseCase,omitempty"` + + // ForceSendFields is a list of field names (e.g. "EnrolledSolution") 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. "EnrolledSolution") 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 *GoogleCloudRetailV2alphaEnrollSolutionResponse) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudRetailV2alphaEnrollSolutionResponse + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + // GoogleCloudRetailV2alphaExportErrorsConfig: Configuration of // destination for Export related errors. type GoogleCloudRetailV2alphaExportErrorsConfig struct { diff --git a/run/v2/run-api.json b/run/v2/run-api.json index 2bd30332af9..46c8a9d0b77 100644 --- a/run/v2/run-api.json +++ b/run/v2/run-api.json @@ -1087,7 +1087,7 @@ } } }, - "revision": "20230618", + "revision": "20230702", "rootUrl": "https://run.googleapis.com/", "schemas": { "GoogleCloudRunV2BinaryAuthorization": { @@ -2405,7 +2405,7 @@ "type": "string" }, "customAudiences": { - "description": "Custom audiences that can be used in the audience field of ID token for authenticated requests.", + "description": "One or more custom audiences that you want this service to support. Specify each custom audience as the full URL in a string. The custom audiences are encoded in the token and used to authenticate requests. For more information, see https://cloud.google.com/run/docs/configuring/custom-audiences.", "items": { "type": "string" }, diff --git a/run/v2/run-gen.go b/run/v2/run-gen.go index 882da887dd8..a1eba5379c3 100644 --- a/run/v2/run-gen.go +++ b/run/v2/run-gen.go @@ -2083,8 +2083,11 @@ type GoogleCloudRunV2Service struct { // Creator: Output only. Email address of the authenticated creator. Creator string `json:"creator,omitempty"` - // CustomAudiences: Custom audiences that can be used in the audience - // field of ID token for authenticated requests. + // CustomAudiences: One or more custom audiences that you want this + // service to support. Specify each custom audience as the full URL in a + // string. The custom audiences are encoded in the token and used to + // authenticate requests. For more information, see + // https://cloud.google.com/run/docs/configuring/custom-audiences. CustomAudiences []string `json:"customAudiences,omitempty"` // DeleteTime: Output only. The deletion time. diff --git a/spanner/v1/spanner-api.json b/spanner/v1/spanner-api.json index aecb4cfc6e8..9795ba02109 100644 --- a/spanner/v1/spanner-api.json +++ b/spanner/v1/spanner-api.json @@ -2565,7 +2565,7 @@ } } }, - "revision": "20230614", + "revision": "20230705", "rootUrl": "https://spanner.googleapis.com/", "schemas": { "Backup": { @@ -3408,7 +3408,7 @@ "id": "ExecuteSqlRequest", "properties": { "dataBoostEnabled": { - "description": "If this is for a partitioned query and this field is set to `true`, the request will be executed via Spanner independent compute resources. If the field is set to `true` but the request does not set `partition_token`, the API will return an `INVALID_ARGUMENT` error.", + "description": "If this is for a partitioned query and this field is set to `true`, the request is executed with Spanner Data Boost independent compute resources. If the field is set to `true` but the request does not set `partition_token`, the API returns an `INVALID_ARGUMENT` error.", "type": "boolean" }, "paramTypes": { @@ -4731,7 +4731,7 @@ "type": "array" }, "dataBoostEnabled": { - "description": "If this is for a partitioned read and this field is set to `true`, the request will be executed via Spanner independent compute resources. If the field is set to `true` but the request does not set `partition_token`, the API will return an `INVALID_ARGUMENT` error.", + "description": "If this is for a partitioned read and this field is set to `true`, the request is executed with Spanner Data Boost independent compute resources. If the field is set to `true` but the request does not set `partition_token`, the API returns an `INVALID_ARGUMENT` error.", "type": "boolean" }, "index": { diff --git a/spanner/v1/spanner-gen.go b/spanner/v1/spanner-gen.go index e7a9cc4eccc..e05f0dbb7c5 100644 --- a/spanner/v1/spanner-gen.go +++ b/spanner/v1/spanner-gen.go @@ -1900,9 +1900,9 @@ func (s *ExecuteBatchDmlResponse) MarshalJSON() ([]byte, error) { // ExecuteStreamingSql. type ExecuteSqlRequest struct { // DataBoostEnabled: If this is for a partitioned query and this field - // is set to `true`, the request will be executed via Spanner + // is set to `true`, the request is executed with Spanner Data Boost // independent compute resources. If the field is set to `true` but the - // request does not set `partition_token`, the API will return an + // request does not set `partition_token`, the API returns an // `INVALID_ARGUMENT` error. DataBoostEnabled bool `json:"dataBoostEnabled,omitempty"` @@ -4388,10 +4388,10 @@ type ReadRequest struct { Columns []string `json:"columns,omitempty"` // DataBoostEnabled: If this is for a partitioned read and this field is - // set to `true`, the request will be executed via Spanner independent - // compute resources. If the field is set to `true` but the request does - // not set `partition_token`, the API will return an `INVALID_ARGUMENT` - // error. + // set to `true`, the request is executed with Spanner Data Boost + // independent compute resources. If the field is set to `true` but the + // request does not set `partition_token`, the API returns an + // `INVALID_ARGUMENT` error. DataBoostEnabled bool `json:"dataBoostEnabled,omitempty"` // Index: If non-empty, the name of an index on table. This index is diff --git a/tagmanager/v1/tagmanager-api.json b/tagmanager/v1/tagmanager-api.json index 43d90949547..09f0106cb9c 100644 --- a/tagmanager/v1/tagmanager-api.json +++ b/tagmanager/v1/tagmanager-api.json @@ -1932,7 +1932,7 @@ } } }, - "revision": "20200826", + "revision": "20230705", "rootUrl": "https://tagmanager.googleapis.com/", "schemas": { "Account": { @@ -2430,6 +2430,7 @@ "type": "array" }, "macro": { + "deprecated": true, "description": "The macros in the container that this version was taken from.", "items": { "$ref": "Macro" @@ -2445,6 +2446,7 @@ "type": "string" }, "rule": { + "deprecated": true, "description": "The rules in the container that this version was taken from.", "items": { "$ref": "Rule" @@ -2500,10 +2502,12 @@ "type": "string" }, "numMacros": { + "deprecated": true, "description": "Number of macros in the container version.", "type": "string" }, "numRules": { + "deprecated": true, "description": "Number of rules in the container version.", "type": "string" }, @@ -3030,6 +3034,7 @@ "type": "string" }, "blockingRuleId": { + "deprecated": true, "description": "Blocking rule IDs. If any of the listed rules evaluate to true, the tag will not fire. @mutable tagmanager.accounts.containers.tags.create @mutable tagmanager.accounts.containers.tags.update", "items": { "type": "string" @@ -3052,6 +3057,7 @@ "type": "string" }, "firingRuleId": { + "deprecated": true, "description": "Firing rule IDs. A tag will fire when any of the listed rules are true and all of its blockingRuleIds (if any specified) are false. @mutable tagmanager.accounts.containers.tags.create @mutable tagmanager.accounts.containers.tags.update", "items": { "type": "string" diff --git a/tagmanager/v2/tagmanager-api.json b/tagmanager/v2/tagmanager-api.json index efc724a4e63..aac9369d02e 100644 --- a/tagmanager/v2/tagmanager-api.json +++ b/tagmanager/v2/tagmanager-api.json @@ -3890,7 +3890,7 @@ } } }, - "revision": "20230614", + "revision": "20230705", "rootUrl": "https://tagmanager.googleapis.com/", "schemas": { "Account": { @@ -4710,10 +4710,12 @@ "type": "string" }, "numMacros": { + "deprecated": true, "description": "Number of macros in the container version.", "type": "string" }, "numRules": { + "deprecated": true, "description": "Number of rules in the container version.", "type": "string" }, @@ -5773,6 +5775,7 @@ "type": "string" }, "blockingRuleId": { + "deprecated": true, "description": "Blocking rule IDs. If any of the listed rules evaluate to true, the tag will not fire. @mutable tagmanager.accounts.containers.workspaces.tags.create @mutable tagmanager.accounts.containers.workspaces.tags.update", "items": { "type": "string" @@ -5799,6 +5802,7 @@ "type": "string" }, "firingRuleId": { + "deprecated": true, "description": "Firing rule IDs. A tag will fire when any of the listed rules are true and all of its blockingRuleIds (if any specified) are false. @mutable tagmanager.accounts.containers.workspaces.tags.create @mutable tagmanager.accounts.containers.workspaces.tags.update", "items": { "type": "string" diff --git a/testing/v1/testing-api.json b/testing/v1/testing-api.json index ff9378d6290..a02fc9b8928 100644 --- a/testing/v1/testing-api.json +++ b/testing/v1/testing-api.json @@ -282,7 +282,7 @@ } } }, - "revision": "20230526", + "revision": "20230704", "rootUrl": "https://testing.googleapis.com/", "schemas": { "Account": { @@ -580,11 +580,13 @@ "type": "string" }, "maxDepth": { + "deprecated": true, "description": "The max depth of the traversal stack Robo can explore. Needs to be at least 2 to make Robo explore the app beyond the first activity. Default is 50.", "format": "int32", "type": "integer" }, "maxSteps": { + "deprecated": true, "description": "The max number of steps Robo can execute. Default is no limit.", "format": "int32", "type": "integer" @@ -1610,6 +1612,7 @@ "type": "string" }, "orchestratorVersion": { + "deprecated": true, "description": "Deprecated: Use AndroidX Test Orchestrator going forward. A string representing the current version of Android Test Orchestrator that is used in the environment. The package is available at https://maven.google.com/web/index.html#com.android.support.test:orchestrator.", "type": "string" } @@ -1814,6 +1817,7 @@ "id": "SystraceSetup", "properties": { "durationSeconds": { + "deprecated": true, "description": "Systrace duration in seconds. Should be between 1 and 30 seconds. 0 disables systrace.", "format": "int32", "type": "integer" @@ -2004,6 +2008,47 @@ "SERVICE_NOT_ACTIVATED", "UNKNOWN_PERMISSION_ERROR" ], + "enumDeprecated": [ + false, + false, + false, + false, + false, + false, + false, + false, + false, + false, + false, + false, + false, + false, + false, + false, + false, + false, + false, + false, + false, + false, + false, + false, + false, + false, + false, + false, + true, + false, + false, + false, + false, + false, + false, + false, + false, + false, + false + ], "enumDescriptions": [ "Do not use. For proto versioning only.", "The matrix is INVALID, but there are no further details available.", @@ -2172,6 +2217,7 @@ }, "systrace": { "$ref": "SystraceSetup", + "deprecated": true, "description": "Systrace configuration for the run. Deprecated: Systrace used Python 2 which was sunsetted on 2020-01-01. Systrace is no longer supported in the Cloud Testing API, and no Systrace file will be provided in the results." } }, diff --git a/toolresults/v1beta3/toolresults-api.json b/toolresults/v1beta3/toolresults-api.json index 97595ee663e..0d9459b2811 100644 --- a/toolresults/v1beta3/toolresults-api.json +++ b/toolresults/v1beta3/toolresults-api.json @@ -1463,7 +1463,7 @@ } } }, - "revision": "20230703", + "revision": "20230706", "rootUrl": "https://toolresults.googleapis.com/", "schemas": { "ANR": { @@ -1905,7 +1905,7 @@ "type": "object" }, "Execution": { - "description": "An Execution represents a collection of Steps. For instance, it could represent: - a mobile test executed across a range of device configurations - a jenkins job with a build step followed by a test step The maximum size of an execution message is 1 MiB. An Execution can be updated until its state is set to COMPLETE at which point it becomes immutable. Next tag: 17", + "description": "An Execution represents a collection of Steps. For instance, it could represent: - a mobile test executed across a range of device configurations - a jenkins job with a build step followed by a test step The maximum size of an execution message is 1 MiB. An Execution can be updated until its state is set to COMPLETE at which point it becomes immutable.", "id": "Execution", "properties": { "completionTime": { @@ -3219,7 +3219,7 @@ "type": "object" }, "Step": { - "description": "A Step represents a single operation performed as part of Execution. A step can be used to represent the execution of a tool ( for example a test runner execution or an execution of a compiler). Steps can overlap (for instance two steps might have the same start time if some operations are done in parallel). Here is an example, let's consider that we have a continuous build is executing a test runner for each iteration. The workflow would look like: - user creates a Execution with id 1 - user creates a TestExecutionStep with id 100 for Execution 1 - user update TestExecutionStep with id 100 to add a raw xml log + the service parses the xml logs and returns a TestExecutionStep with updated TestResult(s). - user update the status of TestExecutionStep with id 100 to COMPLETE A Step can be updated until its state is set to COMPLETE at which points it becomes immutable. Next tag: 27", + "description": "A Step represents a single operation performed as part of Execution. A step can be used to represent the execution of a tool ( for example a test runner execution or an execution of a compiler). Steps can overlap (for instance two steps might have the same start time if some operations are done in parallel). Here is an example, let's consider that we have a continuous build is executing a test runner for each iteration. The workflow would look like: - user creates a Execution with id 1 - user creates a TestExecutionStep with id 100 for Execution 1 - user update TestExecutionStep with id 100 to add a raw xml log + the service parses the xml logs and returns a TestExecutionStep with updated TestResult(s). - user update the status of TestExecutionStep with id 100 to COMPLETE A Step can be updated until its state is set to COMPLETE at which points it becomes immutable.", "id": "Step", "properties": { "completionTime": { diff --git a/toolresults/v1beta3/toolresults-gen.go b/toolresults/v1beta3/toolresults-gen.go index d90ed16bfac..58e41600016 100644 --- a/toolresults/v1beta3/toolresults-gen.go +++ b/toolresults/v1beta3/toolresults-gen.go @@ -1045,7 +1045,7 @@ func (s *EnvironmentDimensionValueEntry) MarshalJSON() ([]byte, error) { // of device configurations - a jenkins job with a build step followed // by a test step The maximum size of an execution message is 1 MiB. An // Execution can be updated until its state is set to COMPLETE at which -// point it becomes immutable. Next tag: 17 +// point it becomes immutable. type Execution struct { // CompletionTime: The time when the Execution status transitioned to // COMPLETE. This value will be set automatically when state transitions @@ -3381,7 +3381,7 @@ func (s *Status) MarshalJSON() ([]byte, error) { // TestExecutionStep with updated TestResult(s). - user update the // status of TestExecutionStep with id 100 to COMPLETE A Step can be // updated until its state is set to COMPLETE at which points it becomes -// immutable. Next tag: 27 +// immutable. type Step struct { // CompletionTime: The time when the step status was set to complete. // This value will be set automatically when state transitions to