From fb2b816b756c5b8bc80f5485ad93d710fdfdb6ea Mon Sep 17 00:00:00 2001 From: Yoshi Automation Bot Date: Fri, 8 Mar 2024 00:20:16 -0800 Subject: [PATCH] feat(all): auto-regenerate discovery clients (#2458) --- androidpublisher/v3/androidpublisher-api.json | 6 +- androidpublisher/v3/androidpublisher-gen.go | 4 +- chat/v1/chat-api.json | 4 +- chat/v1/chat-gen.go | 4 +- cloudbuild/v1/cloudbuild-api.json | 33 +- cloudbuild/v1/cloudbuild-gen.go | 57 - cloudbuild/v2/cloudbuild-api.json | 116 +- cloudbuild/v2/cloudbuild-gen.go | 127 ++ .../v1/containeranalysis-api.json | 291 ++- containeranalysis/v1/containeranalysis-gen.go | 1423 +++++++++++++ .../v1alpha1/containeranalysis-api.json | 14 +- .../v1alpha1/containeranalysis-gen.go | 3 + .../v1beta1/containeranalysis-api.json | 316 ++- .../v1beta1/containeranalysis-gen.go | 1566 ++++++++++++++ dialogflow/v2beta1/dialogflow-api.json | 66 +- dialogflow/v2beta1/dialogflow-gen.go | 100 + dialogflow/v3/dialogflow-api.json | 89 +- dialogflow/v3/dialogflow-gen.go | 149 +- dialogflow/v3beta1/dialogflow-api.json | 89 +- dialogflow/v3beta1/dialogflow-gen.go | 148 +- displayvideo/v2/displayvideo-api.json | 16 +- displayvideo/v2/displayvideo-gen.go | 10 +- displayvideo/v3/displayvideo-api.json | 16 +- displayvideo/v3/displayvideo-gen.go | 10 +- .../v1alpha1/playdeveloperreporting-api.json | 18 +- .../v1alpha1/playdeveloperreporting-gen.go | 26 +- .../v1beta1/playdeveloperreporting-api.json | 18 +- .../v1beta1/playdeveloperreporting-gen.go | 26 +- run/v2/run-api.json | 1276 +++++++++++- run/v2/run-gen.go | 1821 ++++++++++++++++- workspaceevents/v1/workspaceevents-api.json | 36 +- workspaceevents/v1/workspaceevents-gen.go | 39 +- 32 files changed, 7757 insertions(+), 160 deletions(-) diff --git a/androidpublisher/v3/androidpublisher-api.json b/androidpublisher/v3/androidpublisher-api.json index 9e696eef7f8..e07c78b88bc 100644 --- a/androidpublisher/v3/androidpublisher-api.json +++ b/androidpublisher/v3/androidpublisher-api.json @@ -4726,7 +4726,7 @@ } } }, - "revision": "20240222", + "revision": "20240306", "rootUrl": "https://androidpublisher.googleapis.com/", "schemas": { "Abi": { @@ -7745,12 +7745,12 @@ "enum": [ "EXTERNAL_TRANSACTION_PROGRAM_UNSPECIFIED", "USER_CHOICE_BILLING", - "ALTERTNATIVE_BILLING_ONLY" + "ALTERNATIVE_BILLING_ONLY" ], "enumDescriptions": [ "Unspecified transaction program. Not used.", "User choice billing, where a user may choose between Google Play Billing developer-managed billing.", - "Alternatively billing only, where users may only use developer-manager billing." + "Alternative billing only, where users may only use developer-manager billing." ], "type": "string" } diff --git a/androidpublisher/v3/androidpublisher-gen.go b/androidpublisher/v3/androidpublisher-gen.go index 1b5364f2ee8..d959b92d040 100644 --- a/androidpublisher/v3/androidpublisher-gen.go +++ b/androidpublisher/v3/androidpublisher-gen.go @@ -5842,8 +5842,8 @@ type RecurringExternalTransaction struct { // transaction program. Not used. // "USER_CHOICE_BILLING" - User choice billing, where a user may // choose between Google Play Billing developer-managed billing. - // "ALTERTNATIVE_BILLING_ONLY" - Alternatively billing only, where - // users may only use developer-manager billing. + // "ALTERNATIVE_BILLING_ONLY" - Alternative billing only, where users + // may only use developer-manager billing. MigratedTransactionProgram string `json:"migratedTransactionProgram,omitempty"` // ForceSendFields is a list of field names (e.g. diff --git a/chat/v1/chat-api.json b/chat/v1/chat-api.json index d5b3c04ca62..372ad6fc405 100644 --- a/chat/v1/chat-api.json +++ b/chat/v1/chat-api.json @@ -990,7 +990,7 @@ } } }, - "revision": "20240303", + "revision": "20240305", "rootUrl": "https://chat.googleapis.com/", "schemas": { "ActionParameter": { @@ -3250,7 +3250,7 @@ "type": "string" }, "formattedText": { - "description": "Output only. Contains the message `text` with markups added to communicate formatting. This field might not capture all formatting visible in the UI, but includes the following: * [Markup syntax](https://developers.google.com/chat/format-messages) for bold, italic, strikethrough, monospace, and monospace block. * [User mentions](https://developers.google.com/chat/format-messages#messages-@mention) using the format ``. * Custom hyperlinks using the format `\u003c{url}|{rendered_text}\u003e` where the first string is the URL and the second is the rendered text—for example, ``. * Custom emoji using the format `:{emoji_name}:`—for example, `:smile:`. This doesn't apply to Unicode emoji, such as `U+1F600` for a grinning face emoji. For more information, see [View text formatting sent in a message](https://developers.google.com/chat/format-messages#view_text_formatting_sent_in_a_message)", + "description": "Output only. Contains the message `text` with markups added to communicate formatting. This field might not capture all formatting visible in the UI, but includes the following: * [Markup syntax](https://developers.google.com/chat/format-messages) for bold, italic, strikethrough, monospace, monospace block, and bulleted list. * [User mentions](https://developers.google.com/chat/format-messages#messages-@mention) using the format ``. * Custom hyperlinks using the format `\u003c{url}|{rendered_text}\u003e` where the first string is the URL and the second is the rendered text—for example, ``. * Custom emoji using the format `:{emoji_name}:`—for example, `:smile:`. This doesn't apply to Unicode emoji, such as `U+1F600` for a grinning face emoji. For more information, see [View text formatting sent in a message](https://developers.google.com/chat/format-messages#view_text_formatting_sent_in_a_message)", "readOnly": true, "type": "string" }, diff --git a/chat/v1/chat-gen.go b/chat/v1/chat-gen.go index 72e5a7c7d4e..1518e7c6f03 100644 --- a/chat/v1/chat-gen.go +++ b/chat/v1/chat-gen.go @@ -4296,8 +4296,8 @@ type Message struct { // added to communicate formatting. This field might not capture all // formatting visible in the UI, but includes the following: * Markup // syntax (https://developers.google.com/chat/format-messages) for bold, - // italic, strikethrough, monospace, and monospace block. * User - // mentions + // italic, strikethrough, monospace, monospace block, and bulleted list. + // * User mentions // (https://developers.google.com/chat/format-messages#messages-@mention) // using the format ``. * Custom hyperlinks using the format // `<{url}|{rendered_text}>` where the first string is the URL and the diff --git a/cloudbuild/v1/cloudbuild-api.json b/cloudbuild/v1/cloudbuild-api.json index 62fbdb0fe4f..fa5c2b70a4f 100644 --- a/cloudbuild/v1/cloudbuild-api.json +++ b/cloudbuild/v1/cloudbuild-api.json @@ -2346,7 +2346,7 @@ } } }, - "revision": "20240223", + "revision": "20240305", "rootUrl": "https://cloudbuild.googleapis.com/", "schemas": { "ApprovalConfig": { @@ -3089,6 +3089,14 @@ "E2_HIGHCPU_32", "E2_MEDIUM" ], + "enumDeprecated": [ + false, + true, + true, + false, + false, + false + ], "enumDescriptions": [ "Standard machine type.", "Highcpu machine with 8 CPUs.", @@ -4576,10 +4584,6 @@ "$ref": "NetworkConfig", "description": "Network configuration for the pool." }, - "privateServiceConnect": { - "$ref": "PrivateServiceConnect", - "description": "Immutable. Private Service Connect(PSC) Network configuration for the pool." - }, "workerConfig": { "$ref": "WorkerConfig", "description": "Machine configuration for the workers in the pool." @@ -4587,25 +4591,6 @@ }, "type": "object" }, - "PrivateServiceConnect": { - "description": "Defines the Private Service Connect network configuration for the pool.", - "id": "PrivateServiceConnect", - "properties": { - "networkAttachment": { - "description": "Required. Immutable. The network attachment that the worker network interface is peered to. Must be in the format `projects/{project}/regions/{region}/networkAttachments/{networkAttachment}`. The region of network attachment must be the same as the worker pool. See [Network Attachments](https://cloud.google.com/vpc/docs/about-network-attachments)", - "type": "string" - }, - "publicIpAddressDisabled": { - "description": "Required. Immutable. Disable public IP on the primary network interface. If true, workers are created without any public address, which prevents network egress to public IPs unless a network proxy is configured. If false, workers are created with a public address which allows for public internet egress. The public address only applies to traffic through the primary network interface. If `route_all_traffic` is set to true, all traffic will go through the non-primary network interface, this boolean has no effect.", - "type": "boolean" - }, - "routeAllTraffic": { - "description": "Immutable. Route all traffic through PSC interface. Enable this if you want full control of traffic in the private pool. Configure Cloud NAT for the subnet of network attachment if you need to access public Internet. If false, Only route private IPs, e.g. 10.0.0.0/8, 172.16.0.0/12, and 192.168.0.0/16 through PSC interface.", - "type": "boolean" - } - }, - "type": "object" - }, "ProcessAppManifestCallbackOperationMetadata": { "description": "Metadata for `ProcessAppManifestCallback` operation.", "id": "ProcessAppManifestCallbackOperationMetadata", diff --git a/cloudbuild/v1/cloudbuild-gen.go b/cloudbuild/v1/cloudbuild-gen.go index 49ef963c75c..15209c4711c 100644 --- a/cloudbuild/v1/cloudbuild-gen.go +++ b/cloudbuild/v1/cloudbuild-gen.go @@ -3889,10 +3889,6 @@ type PrivatePoolV1Config struct { // NetworkConfig: Network configuration for the pool. NetworkConfig *NetworkConfig `json:"networkConfig,omitempty"` - // PrivateServiceConnect: Immutable. Private Service Connect(PSC) - // Network configuration for the pool. - PrivateServiceConnect *PrivateServiceConnect `json:"privateServiceConnect,omitempty"` - // WorkerConfig: Machine configuration for the workers in the pool. WorkerConfig *WorkerConfig `json:"workerConfig,omitempty"` @@ -3919,59 +3915,6 @@ func (s *PrivatePoolV1Config) MarshalJSON() ([]byte, error) { return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } -// PrivateServiceConnect: Defines the Private Service Connect network -// configuration for the pool. -type PrivateServiceConnect struct { - // NetworkAttachment: Required. Immutable. The network attachment that - // the worker network interface is peered to. Must be in the format - // `projects/{project}/regions/{region}/networkAttachments/{networkAttach - // ment}`. The region of network attachment must be the same as the - // worker pool. See Network Attachments - // (https://cloud.google.com/vpc/docs/about-network-attachments) - NetworkAttachment string `json:"networkAttachment,omitempty"` - - // PublicIpAddressDisabled: Required. Immutable. Disable public IP on - // the primary network interface. If true, workers are created without - // any public address, which prevents network egress to public IPs - // unless a network proxy is configured. If false, workers are created - // with a public address which allows for public internet egress. The - // public address only applies to traffic through the primary network - // interface. If `route_all_traffic` is set to true, all traffic will go - // through the non-primary network interface, this boolean has no - // effect. - PublicIpAddressDisabled bool `json:"publicIpAddressDisabled,omitempty"` - - // RouteAllTraffic: Immutable. Route all traffic through PSC interface. - // Enable this if you want full control of traffic in the private pool. - // Configure Cloud NAT for the subnet of network attachment if you need - // to access public Internet. If false, Only route private IPs, e.g. - // 10.0.0.0/8, 172.16.0.0/12, and 192.168.0.0/16 through PSC interface. - RouteAllTraffic bool `json:"routeAllTraffic,omitempty"` - - // ForceSendFields is a list of field names (e.g. "NetworkAttachment") - // 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. "NetworkAttachment") 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 *PrivateServiceConnect) MarshalJSON() ([]byte, error) { - type NoMethod PrivateServiceConnect - raw := NoMethod(*s) - return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) -} - // ProcessAppManifestCallbackOperationMetadata: Metadata for // `ProcessAppManifestCallback` operation. type ProcessAppManifestCallbackOperationMetadata struct { diff --git a/cloudbuild/v2/cloudbuild-api.json b/cloudbuild/v2/cloudbuild-api.json index 7d7d9c501dd..982d5a2310e 100644 --- a/cloudbuild/v2/cloudbuild-api.json +++ b/cloudbuild/v2/cloudbuild-api.json @@ -844,7 +844,7 @@ } } }, - "revision": "20240223", + "revision": "20240305", "rootUrl": "https://cloudbuild.googleapis.com/", "schemas": { "AuditConfig": { @@ -1885,6 +1885,45 @@ }, "type": "object" }, + "PipelineResult": { + "description": "A value produced by a Pipeline.", + "id": "PipelineResult", + "properties": { + "description": { + "description": "Output only. Description of the result.", + "readOnly": true, + "type": "string" + }, + "name": { + "description": "Output only. Name of the result.", + "readOnly": true, + "type": "string" + }, + "type": { + "description": "Output only. The type of data that the result holds.", + "enum": [ + "TYPE_UNSPECIFIED", + "STRING", + "ARRAY", + "OBJECT" + ], + "enumDescriptions": [ + "Default enum type; should not be used.", + "Default", + "Array type", + "Object type" + ], + "readOnly": true, + "type": "string" + }, + "value": { + "$ref": "ResultValue", + "description": "Output only. Value of the result.", + "readOnly": true + } + }, + "type": "object" + }, "PipelineRun": { "description": "Message describing PipelineRun object", "id": "PipelineRun", @@ -1988,6 +2027,14 @@ "description": "Output only. The exact PipelineSpec used to instantiate the run.", "readOnly": true }, + "results": { + "description": "Optional. Output only. List of results written out by the pipeline's containers", + "items": { + "$ref": "PipelineRunResult" + }, + "readOnly": true, + "type": "array" + }, "security": { "$ref": "Security", "description": "Optional. Security configuration." @@ -2049,6 +2096,23 @@ }, "type": "object" }, + "PipelineRunResult": { + "description": "PipelineRunResult used to describe the results of a pipeline", + "id": "PipelineRunResult", + "properties": { + "name": { + "description": "Output only. Name of the TaskRun", + "readOnly": true, + "type": "string" + }, + "value": { + "$ref": "ResultValue", + "description": "Output only. Value of the result.", + "readOnly": true + } + }, + "type": "object" + }, "PipelineSpec": { "description": "PipelineSpec defines the desired state of Pipeline.", "id": "PipelineSpec", @@ -2072,6 +2136,14 @@ }, "type": "array" }, + "results": { + "description": "Optional. Output only. List of results written out by the pipeline's containers", + "items": { + "$ref": "PipelineResult" + }, + "readOnly": true, + "type": "array" + }, "tasks": { "description": "List of Tasks that execute when this Pipeline is run.", "items": { @@ -2325,6 +2397,48 @@ }, "type": "object" }, + "ResultValue": { + "description": "ResultValue holds different types of data for a single result.", + "id": "ResultValue", + "properties": { + "arrayVal": { + "description": "Value of the result if type is array.", + "items": { + "type": "string" + }, + "type": "array" + }, + "objectVal": { + "additionalProperties": { + "type": "string" + }, + "description": "Value of the result if type is object.", + "type": "object" + }, + "stringVal": { + "description": "Value of the result if type is string.", + "type": "string" + }, + "type": { + "description": "Output only. The type of data that the result holds.", + "enum": [ + "TYPE_UNSPECIFIED", + "STRING", + "ARRAY", + "OBJECT" + ], + "enumDescriptions": [ + "Default enum type; should not be used.", + "Default", + "Array type", + "Object type" + ], + "readOnly": true, + "type": "string" + } + }, + "type": "object" + }, "RunWorkflowCustomOperationMetadata": { "description": "Represents the custom metadata of the RunWorkflow long-running operation.", "id": "RunWorkflowCustomOperationMetadata", diff --git a/cloudbuild/v2/cloudbuild-gen.go b/cloudbuild/v2/cloudbuild-gen.go index 939f9589abb..67a492d8b7a 100644 --- a/cloudbuild/v2/cloudbuild-gen.go +++ b/cloudbuild/v2/cloudbuild-gen.go @@ -1999,6 +1999,49 @@ func (s *PipelineRef) MarshalJSON() ([]byte, error) { return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } +// PipelineResult: A value produced by a Pipeline. +type PipelineResult struct { + // Description: Output only. Description of the result. + Description string `json:"description,omitempty"` + + // Name: Output only. Name of the result. + Name string `json:"name,omitempty"` + + // Type: Output only. The type of data that the result holds. + // + // Possible values: + // "TYPE_UNSPECIFIED" - Default enum type; should not be used. + // "STRING" - Default + // "ARRAY" - Array type + // "OBJECT" - Object type + Type string `json:"type,omitempty"` + + // Value: Output only. Value of the result. + Value *ResultValue `json:"value,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 *PipelineResult) MarshalJSON() ([]byte, error) { + type NoMethod PipelineResult + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + // PipelineRun: Message describing PipelineRun object type PipelineRun struct { // Annotations: User annotations. See @@ -2065,6 +2108,10 @@ type PipelineRun struct { // instantiate the run. ResolvedPipelineSpec *PipelineSpec `json:"resolvedPipelineSpec,omitempty"` + // Results: Optional. Output only. List of results written out by the + // pipeline's containers + Results []*PipelineRunResult `json:"results,omitempty"` + // Security: Optional. Security configuration. Security *Security `json:"security,omitempty"` @@ -2126,6 +2173,38 @@ func (s *PipelineRun) MarshalJSON() ([]byte, error) { return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } +// PipelineRunResult: PipelineRunResult used to describe the results of +// a pipeline +type PipelineRunResult struct { + // Name: Output only. Name of the TaskRun + Name string `json:"name,omitempty"` + + // Value: Output only. Value of the result. + Value *ResultValue `json:"value,omitempty"` + + // ForceSendFields is a list of field names (e.g. "Name") to + // unconditionally include in API requests. By default, fields with + // empty or default values are omitted from API requests. However, any + // non-pointer, non-interface field appearing in ForceSendFields will be + // sent to the server regardless of whether the field is empty or not. + // This may be used to include empty fields in Patch requests. + ForceSendFields []string `json:"-"` + + // NullFields is a list of field names (e.g. "Name") to include in API + // requests with the JSON null value. By default, fields with empty + // values are omitted from API requests. However, any field with an + // empty value appearing in NullFields will be sent to the server as + // null. It is an error if a field in this list has a non-empty value. + // This may be used to include null fields in Patch requests. + NullFields []string `json:"-"` +} + +func (s *PipelineRunResult) MarshalJSON() ([]byte, error) { + type NoMethod PipelineRunResult + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + // PipelineSpec: PipelineSpec defines the desired state of Pipeline. type PipelineSpec struct { // FinallyTasks: List of Tasks that execute just before leaving the @@ -2142,6 +2221,10 @@ type PipelineSpec struct { // Params: List of parameters. Params []*ParamSpec `json:"params,omitempty"` + // Results: Optional. Output only. List of results written out by the + // pipeline's containers + Results []*PipelineResult `json:"results,omitempty"` + // Tasks: List of Tasks that execute when this Pipeline is run. Tasks []*PipelineTask `json:"tasks,omitempty"` @@ -2557,6 +2640,50 @@ func (s *Repository) MarshalJSON() ([]byte, error) { return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } +// ResultValue: ResultValue holds different types of data for a single +// result. +type ResultValue struct { + // ArrayVal: Value of the result if type is array. + ArrayVal []string `json:"arrayVal,omitempty"` + + // ObjectVal: Value of the result if type is object. + ObjectVal map[string]string `json:"objectVal,omitempty"` + + // StringVal: Value of the result if type is string. + StringVal string `json:"stringVal,omitempty"` + + // Type: Output only. The type of data that the result holds. + // + // Possible values: + // "TYPE_UNSPECIFIED" - Default enum type; should not be used. + // "STRING" - Default + // "ARRAY" - Array type + // "OBJECT" - Object type + Type string `json:"type,omitempty"` + + // ForceSendFields is a list of field names (e.g. "ArrayVal") 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. "ArrayVal") 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 *ResultValue) MarshalJSON() ([]byte, error) { + type NoMethod ResultValue + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + // RunWorkflowCustomOperationMetadata: Represents the custom metadata of // the RunWorkflow long-running operation. type RunWorkflowCustomOperationMetadata struct { diff --git a/containeranalysis/v1/containeranalysis-api.json b/containeranalysis/v1/containeranalysis-api.json index f4d9856ce26..7603c7f3b3b 100644 --- a/containeranalysis/v1/containeranalysis-api.json +++ b/containeranalysis/v1/containeranalysis-api.json @@ -107,6 +107,284 @@ "resources": { "projects": { "resources": { + "locations": { + "resources": { + "notes": { + "methods": { + "get": { + "description": "Gets the specified note.", + "flatPath": "v1/projects/{projectsId}/locations/{locationsId}/notes/{notesId}", + "httpMethod": "GET", + "id": "containeranalysis.projects.locations.notes.get", + "parameterOrder": [ + "name" + ], + "parameters": { + "name": { + "description": "Required. The name of the note in the form of `projects/[PROVIDER_ID]/notes/[NOTE_ID]`.", + "location": "path", + "pattern": "^projects/[^/]+/locations/[^/]+/notes/[^/]+$", + "required": true, + "type": "string" + } + }, + "path": "v1/{+name}", + "response": { + "$ref": "Note" + }, + "scopes": [ + "https://www.googleapis.com/auth/cloud-platform" + ] + }, + "list": { + "description": "Lists notes for the specified project.", + "flatPath": "v1/projects/{projectsId}/locations/{locationsId}/notes", + "httpMethod": "GET", + "id": "containeranalysis.projects.locations.notes.list", + "parameterOrder": [ + "parent" + ], + "parameters": { + "filter": { + "description": "The filter expression.", + "location": "query", + "type": "string" + }, + "pageSize": { + "description": "Number of notes to return in the list. Must be positive. Max allowed page size is 1000. If not specified, page size defaults to 20.", + "format": "int32", + "location": "query", + "type": "integer" + }, + "pageToken": { + "description": "Token to provide to skip to a particular spot in the list.", + "location": "query", + "type": "string" + }, + "parent": { + "description": "Required. The name of the project to list notes for in the form of `projects/[PROJECT_ID]`.", + "location": "path", + "pattern": "^projects/[^/]+/locations/[^/]+$", + "required": true, + "type": "string" + } + }, + "path": "v1/{+parent}/notes", + "response": { + "$ref": "ListNotesResponse" + }, + "scopes": [ + "https://www.googleapis.com/auth/cloud-platform" + ] + } + }, + "resources": { + "occurrences": { + "methods": { + "list": { + "description": "Lists occurrences referencing the specified note. Provider projects can use this method to get all occurrences across consumer projects referencing the specified note.", + "flatPath": "v1/projects/{projectsId}/locations/{locationsId}/notes/{notesId}/occurrences", + "httpMethod": "GET", + "id": "containeranalysis.projects.locations.notes.occurrences.list", + "parameterOrder": [ + "name" + ], + "parameters": { + "filter": { + "description": "The filter expression.", + "location": "query", + "type": "string" + }, + "name": { + "description": "Required. The name of the note to list occurrences for in the form of `projects/[PROVIDER_ID]/notes/[NOTE_ID]`.", + "location": "path", + "pattern": "^projects/[^/]+/locations/[^/]+/notes/[^/]+$", + "required": true, + "type": "string" + }, + "pageSize": { + "description": "Number of occurrences to return in the list.", + "format": "int32", + "location": "query", + "type": "integer" + }, + "pageToken": { + "description": "Token to provide to skip to a particular spot in the list.", + "location": "query", + "type": "string" + } + }, + "path": "v1/{+name}/occurrences", + "response": { + "$ref": "ListNoteOccurrencesResponse" + }, + "scopes": [ + "https://www.googleapis.com/auth/cloud-platform" + ] + } + } + } + } + }, + "occurrences": { + "methods": { + "get": { + "description": "Gets the specified occurrence.", + "flatPath": "v1/projects/{projectsId}/locations/{locationsId}/occurrences/{occurrencesId}", + "httpMethod": "GET", + "id": "containeranalysis.projects.locations.occurrences.get", + "parameterOrder": [ + "name" + ], + "parameters": { + "name": { + "description": "Required. The name of the occurrence in the form of `projects/[PROJECT_ID]/occurrences/[OCCURRENCE_ID]`.", + "location": "path", + "pattern": "^projects/[^/]+/locations/[^/]+/occurrences/[^/]+$", + "required": true, + "type": "string" + } + }, + "path": "v1/{+name}", + "response": { + "$ref": "Occurrence" + }, + "scopes": [ + "https://www.googleapis.com/auth/cloud-platform" + ] + }, + "getNotes": { + "description": "Gets the note attached to the specified occurrence. Consumer projects can use this method to get a note that belongs to a provider project.", + "flatPath": "v1/projects/{projectsId}/locations/{locationsId}/occurrences/{occurrencesId}/notes", + "httpMethod": "GET", + "id": "containeranalysis.projects.locations.occurrences.getNotes", + "parameterOrder": [ + "name" + ], + "parameters": { + "name": { + "description": "Required. The name of the occurrence in the form of `projects/[PROJECT_ID]/occurrences/[OCCURRENCE_ID]`.", + "location": "path", + "pattern": "^projects/[^/]+/locations/[^/]+/occurrences/[^/]+$", + "required": true, + "type": "string" + } + }, + "path": "v1/{+name}/notes", + "response": { + "$ref": "Note" + }, + "scopes": [ + "https://www.googleapis.com/auth/cloud-platform" + ] + }, + "getVulnerabilitySummary": { + "description": "Gets a summary of the number and severity of occurrences.", + "flatPath": "v1/projects/{projectsId}/locations/{locationsId}/occurrences:vulnerabilitySummary", + "httpMethod": "GET", + "id": "containeranalysis.projects.locations.occurrences.getVulnerabilitySummary", + "parameterOrder": [ + "parent" + ], + "parameters": { + "filter": { + "description": "The filter expression.", + "location": "query", + "type": "string" + }, + "parent": { + "description": "Required. The name of the project to get a vulnerability summary for in the form of `projects/[PROJECT_ID]`.", + "location": "path", + "pattern": "^projects/[^/]+/locations/[^/]+$", + "required": true, + "type": "string" + } + }, + "path": "v1/{+parent}/occurrences:vulnerabilitySummary", + "response": { + "$ref": "VulnerabilityOccurrencesSummary" + }, + "scopes": [ + "https://www.googleapis.com/auth/cloud-platform" + ] + }, + "list": { + "description": "Lists occurrences for the specified project.", + "flatPath": "v1/projects/{projectsId}/locations/{locationsId}/occurrences", + "httpMethod": "GET", + "id": "containeranalysis.projects.locations.occurrences.list", + "parameterOrder": [ + "parent" + ], + "parameters": { + "filter": { + "description": "The filter expression.", + "location": "query", + "type": "string" + }, + "pageSize": { + "description": "Number of occurrences to return in the list. Must be positive. Max allowed page size is 1000. If not specified, page size defaults to 20.", + "format": "int32", + "location": "query", + "type": "integer" + }, + "pageToken": { + "description": "Token to provide to skip to a particular spot in the list.", + "location": "query", + "type": "string" + }, + "parent": { + "description": "Required. The name of the project to list occurrences for in the form of `projects/[PROJECT_ID]`.", + "location": "path", + "pattern": "^projects/[^/]+/locations/[^/]+$", + "required": true, + "type": "string" + } + }, + "path": "v1/{+parent}/occurrences", + "response": { + "$ref": "ListOccurrencesResponse" + }, + "scopes": [ + "https://www.googleapis.com/auth/cloud-platform" + ] + } + } + }, + "resources": { + "methods": { + "exportSBOM": { + "description": "Generates an SBOM for the given resource.", + "flatPath": "v1/projects/{projectsId}/locations/{locationsId}/resources/{resourcesId}:exportSBOM", + "httpMethod": "POST", + "id": "containeranalysis.projects.locations.resources.exportSBOM", + "parameterOrder": [ + "name" + ], + "parameters": { + "name": { + "description": "Required. The name of the resource in the form of `projects/[PROJECT_ID]/resources/[RESOURCE_URL]`.", + "location": "path", + "pattern": "^projects/[^/]+/locations/[^/]+/resources/.*$", + "required": true, + "type": "string" + } + }, + "path": "v1/{+name}:exportSBOM", + "request": { + "$ref": "ExportSBOMRequest" + }, + "response": { + "$ref": "ExportSBOMResponse" + }, + "scopes": [ + "https://www.googleapis.com/auth/cloud-platform" + ] + } + } + } + } + }, "notes": { "methods": { "batchCreate": { @@ -787,7 +1065,7 @@ } } }, - "revision": "20240209", + "revision": "20240301", "rootUrl": "https://containeranalysis.googleapis.com/", "schemas": { "AliasContext": { @@ -1766,6 +2044,9 @@ "description": "A description about this compliance check.", "type": "string" }, + "impact": { + "type": "string" + }, "rationale": { "description": "A rationale for the existence of this compliance check.", "type": "string" @@ -2347,6 +2628,14 @@ "E2_HIGHCPU_32", "E2_MEDIUM" ], + "enumDeprecated": [ + false, + true, + true, + false, + false, + false + ], "enumDescriptions": [ "Standard machine type.", "Highcpu machine with 8 CPUs.", diff --git a/containeranalysis/v1/containeranalysis-gen.go b/containeranalysis/v1/containeranalysis-gen.go index 2f41b492df3..977cb7fa52f 100644 --- a/containeranalysis/v1/containeranalysis-gen.go +++ b/containeranalysis/v1/containeranalysis-gen.go @@ -157,6 +157,7 @@ func (s *Service) userAgent() string { func NewProjectsService(s *Service) *ProjectsService { rs := &ProjectsService{s: s} + rs.Locations = NewProjectsLocationsService(s) rs.Notes = NewProjectsNotesService(s) rs.Occurrences = NewProjectsOccurrencesService(s) rs.Resources = NewProjectsResourcesService(s) @@ -166,6 +167,8 @@ func NewProjectsService(s *Service) *ProjectsService { type ProjectsService struct { s *Service + Locations *ProjectsLocationsService + Notes *ProjectsNotesService Occurrences *ProjectsOccurrencesService @@ -173,6 +176,63 @@ type ProjectsService struct { Resources *ProjectsResourcesService } +func NewProjectsLocationsService(s *Service) *ProjectsLocationsService { + rs := &ProjectsLocationsService{s: s} + rs.Notes = NewProjectsLocationsNotesService(s) + rs.Occurrences = NewProjectsLocationsOccurrencesService(s) + rs.Resources = NewProjectsLocationsResourcesService(s) + return rs +} + +type ProjectsLocationsService struct { + s *Service + + Notes *ProjectsLocationsNotesService + + Occurrences *ProjectsLocationsOccurrencesService + + Resources *ProjectsLocationsResourcesService +} + +func NewProjectsLocationsNotesService(s *Service) *ProjectsLocationsNotesService { + rs := &ProjectsLocationsNotesService{s: s} + rs.Occurrences = NewProjectsLocationsNotesOccurrencesService(s) + return rs +} + +type ProjectsLocationsNotesService struct { + s *Service + + Occurrences *ProjectsLocationsNotesOccurrencesService +} + +func NewProjectsLocationsNotesOccurrencesService(s *Service) *ProjectsLocationsNotesOccurrencesService { + rs := &ProjectsLocationsNotesOccurrencesService{s: s} + return rs +} + +type ProjectsLocationsNotesOccurrencesService struct { + s *Service +} + +func NewProjectsLocationsOccurrencesService(s *Service) *ProjectsLocationsOccurrencesService { + rs := &ProjectsLocationsOccurrencesService{s: s} + return rs +} + +type ProjectsLocationsOccurrencesService struct { + s *Service +} + +func NewProjectsLocationsResourcesService(s *Service) *ProjectsLocationsResourcesService { + rs := &ProjectsLocationsResourcesService{s: s} + return rs +} + +type ProjectsLocationsResourcesService struct { + s *Service +} + func NewProjectsNotesService(s *Service) *ProjectsNotesService { rs := &ProjectsNotesService{s: s} rs.Occurrences = NewProjectsNotesOccurrencesService(s) @@ -1550,6 +1610,8 @@ type ComplianceNote struct { // Description: A description about this compliance check. Description string `json:"description,omitempty"` + Impact string `json:"impact,omitempty"` + // Rationale: A rationale for the existence of this compliance check. Rationale string `json:"rationale,omitempty"` @@ -7845,6 +7907,1367 @@ func (s *WindowsUpdate) MarshalJSON() ([]byte, error) { return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } +// method id "containeranalysis.projects.locations.notes.get": + +type ProjectsLocationsNotesGetCall struct { + s *Service + name string + urlParams_ gensupport.URLParams + ifNoneMatch_ string + ctx_ context.Context + header_ http.Header +} + +// Get: Gets the specified note. +// +// - name: The name of the note in the form of +// `projects/[PROVIDER_ID]/notes/[NOTE_ID]`. +func (r *ProjectsLocationsNotesService) Get(name string) *ProjectsLocationsNotesGetCall { + c := &ProjectsLocationsNotesGetCall{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 *ProjectsLocationsNotesGetCall) Fields(s ...googleapi.Field) *ProjectsLocationsNotesGetCall { + 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 *ProjectsLocationsNotesGetCall) IfNoneMatch(entityTag string) *ProjectsLocationsNotesGetCall { + 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 *ProjectsLocationsNotesGetCall) Context(ctx context.Context) *ProjectsLocationsNotesGetCall { + 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 *ProjectsLocationsNotesGetCall) Header() http.Header { + if c.header_ == nil { + c.header_ = make(http.Header) + } + return c.header_ +} + +func (c *ProjectsLocationsNotesGetCall) 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 "containeranalysis.projects.locations.notes.get" call. +// Exactly one of *Note or error will be non-nil. Any non-2xx status +// code is an error. Response headers are in either +// *Note.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 *ProjectsLocationsNotesGetCall) Do(opts ...googleapi.CallOption) (*Note, 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 := &Note{ + 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 specified note.", + // "flatPath": "v1/projects/{projectsId}/locations/{locationsId}/notes/{notesId}", + // "httpMethod": "GET", + // "id": "containeranalysis.projects.locations.notes.get", + // "parameterOrder": [ + // "name" + // ], + // "parameters": { + // "name": { + // "description": "Required. The name of the note in the form of `projects/[PROVIDER_ID]/notes/[NOTE_ID]`.", + // "location": "path", + // "pattern": "^projects/[^/]+/locations/[^/]+/notes/[^/]+$", + // "required": true, + // "type": "string" + // } + // }, + // "path": "v1/{+name}", + // "response": { + // "$ref": "Note" + // }, + // "scopes": [ + // "https://www.googleapis.com/auth/cloud-platform" + // ] + // } + +} + +// method id "containeranalysis.projects.locations.notes.list": + +type ProjectsLocationsNotesListCall struct { + s *Service + parent string + urlParams_ gensupport.URLParams + ifNoneMatch_ string + ctx_ context.Context + header_ http.Header +} + +// List: Lists notes for the specified project. +// +// - parent: The name of the project to list notes for in the form of +// `projects/[PROJECT_ID]`. +func (r *ProjectsLocationsNotesService) List(parent string) *ProjectsLocationsNotesListCall { + c := &ProjectsLocationsNotesListCall{s: r.s, urlParams_: make(gensupport.URLParams)} + c.parent = parent + return c +} + +// Filter sets the optional parameter "filter": The filter expression. +func (c *ProjectsLocationsNotesListCall) Filter(filter string) *ProjectsLocationsNotesListCall { + c.urlParams_.Set("filter", filter) + return c +} + +// PageSize sets the optional parameter "pageSize": Number of notes to +// return in the list. Must be positive. Max allowed page size is 1000. +// If not specified, page size defaults to 20. +func (c *ProjectsLocationsNotesListCall) PageSize(pageSize int64) *ProjectsLocationsNotesListCall { + c.urlParams_.Set("pageSize", fmt.Sprint(pageSize)) + return c +} + +// PageToken sets the optional parameter "pageToken": Token to provide +// to skip to a particular spot in the list. +func (c *ProjectsLocationsNotesListCall) PageToken(pageToken string) *ProjectsLocationsNotesListCall { + 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 *ProjectsLocationsNotesListCall) Fields(s ...googleapi.Field) *ProjectsLocationsNotesListCall { + 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 *ProjectsLocationsNotesListCall) IfNoneMatch(entityTag string) *ProjectsLocationsNotesListCall { + 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 *ProjectsLocationsNotesListCall) Context(ctx context.Context) *ProjectsLocationsNotesListCall { + 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 *ProjectsLocationsNotesListCall) Header() http.Header { + if c.header_ == nil { + c.header_ = make(http.Header) + } + return c.header_ +} + +func (c *ProjectsLocationsNotesListCall) 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}/notes") + 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 "containeranalysis.projects.locations.notes.list" call. +// Exactly one of *ListNotesResponse or error will be non-nil. Any +// non-2xx status code is an error. Response headers are in either +// *ListNotesResponse.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 *ProjectsLocationsNotesListCall) Do(opts ...googleapi.CallOption) (*ListNotesResponse, 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 := &ListNotesResponse{ + 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 notes for the specified project.", + // "flatPath": "v1/projects/{projectsId}/locations/{locationsId}/notes", + // "httpMethod": "GET", + // "id": "containeranalysis.projects.locations.notes.list", + // "parameterOrder": [ + // "parent" + // ], + // "parameters": { + // "filter": { + // "description": "The filter expression.", + // "location": "query", + // "type": "string" + // }, + // "pageSize": { + // "description": "Number of notes to return in the list. Must be positive. Max allowed page size is 1000. If not specified, page size defaults to 20.", + // "format": "int32", + // "location": "query", + // "type": "integer" + // }, + // "pageToken": { + // "description": "Token to provide to skip to a particular spot in the list.", + // "location": "query", + // "type": "string" + // }, + // "parent": { + // "description": "Required. The name of the project to list notes for in the form of `projects/[PROJECT_ID]`.", + // "location": "path", + // "pattern": "^projects/[^/]+/locations/[^/]+$", + // "required": true, + // "type": "string" + // } + // }, + // "path": "v1/{+parent}/notes", + // "response": { + // "$ref": "ListNotesResponse" + // }, + // "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 *ProjectsLocationsNotesListCall) Pages(ctx context.Context, f func(*ListNotesResponse) 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 "containeranalysis.projects.locations.notes.occurrences.list": + +type ProjectsLocationsNotesOccurrencesListCall struct { + s *Service + name string + urlParams_ gensupport.URLParams + ifNoneMatch_ string + ctx_ context.Context + header_ http.Header +} + +// List: Lists occurrences referencing the specified note. Provider +// projects can use this method to get all occurrences across consumer +// projects referencing the specified note. +// +// - name: The name of the note to list occurrences for in the form of +// `projects/[PROVIDER_ID]/notes/[NOTE_ID]`. +func (r *ProjectsLocationsNotesOccurrencesService) List(name string) *ProjectsLocationsNotesOccurrencesListCall { + c := &ProjectsLocationsNotesOccurrencesListCall{s: r.s, urlParams_: make(gensupport.URLParams)} + c.name = name + return c +} + +// Filter sets the optional parameter "filter": The filter expression. +func (c *ProjectsLocationsNotesOccurrencesListCall) Filter(filter string) *ProjectsLocationsNotesOccurrencesListCall { + c.urlParams_.Set("filter", filter) + return c +} + +// PageSize sets the optional parameter "pageSize": Number of +// occurrences to return in the list. +func (c *ProjectsLocationsNotesOccurrencesListCall) PageSize(pageSize int64) *ProjectsLocationsNotesOccurrencesListCall { + c.urlParams_.Set("pageSize", fmt.Sprint(pageSize)) + return c +} + +// PageToken sets the optional parameter "pageToken": Token to provide +// to skip to a particular spot in the list. +func (c *ProjectsLocationsNotesOccurrencesListCall) PageToken(pageToken string) *ProjectsLocationsNotesOccurrencesListCall { + 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 *ProjectsLocationsNotesOccurrencesListCall) Fields(s ...googleapi.Field) *ProjectsLocationsNotesOccurrencesListCall { + 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 *ProjectsLocationsNotesOccurrencesListCall) IfNoneMatch(entityTag string) *ProjectsLocationsNotesOccurrencesListCall { + 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 *ProjectsLocationsNotesOccurrencesListCall) Context(ctx context.Context) *ProjectsLocationsNotesOccurrencesListCall { + 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 *ProjectsLocationsNotesOccurrencesListCall) Header() http.Header { + if c.header_ == nil { + c.header_ = make(http.Header) + } + return c.header_ +} + +func (c *ProjectsLocationsNotesOccurrencesListCall) 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}/occurrences") + 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 "containeranalysis.projects.locations.notes.occurrences.list" call. +// Exactly one of *ListNoteOccurrencesResponse or error will be non-nil. +// Any non-2xx status code is an error. Response headers are in either +// *ListNoteOccurrencesResponse.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 *ProjectsLocationsNotesOccurrencesListCall) Do(opts ...googleapi.CallOption) (*ListNoteOccurrencesResponse, 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 := &ListNoteOccurrencesResponse{ + 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 occurrences referencing the specified note. Provider projects can use this method to get all occurrences across consumer projects referencing the specified note.", + // "flatPath": "v1/projects/{projectsId}/locations/{locationsId}/notes/{notesId}/occurrences", + // "httpMethod": "GET", + // "id": "containeranalysis.projects.locations.notes.occurrences.list", + // "parameterOrder": [ + // "name" + // ], + // "parameters": { + // "filter": { + // "description": "The filter expression.", + // "location": "query", + // "type": "string" + // }, + // "name": { + // "description": "Required. The name of the note to list occurrences for in the form of `projects/[PROVIDER_ID]/notes/[NOTE_ID]`.", + // "location": "path", + // "pattern": "^projects/[^/]+/locations/[^/]+/notes/[^/]+$", + // "required": true, + // "type": "string" + // }, + // "pageSize": { + // "description": "Number of occurrences to return in the list.", + // "format": "int32", + // "location": "query", + // "type": "integer" + // }, + // "pageToken": { + // "description": "Token to provide to skip to a particular spot in the list.", + // "location": "query", + // "type": "string" + // } + // }, + // "path": "v1/{+name}/occurrences", + // "response": { + // "$ref": "ListNoteOccurrencesResponse" + // }, + // "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 *ProjectsLocationsNotesOccurrencesListCall) Pages(ctx context.Context, f func(*ListNoteOccurrencesResponse) 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 "containeranalysis.projects.locations.occurrences.get": + +type ProjectsLocationsOccurrencesGetCall struct { + s *Service + name string + urlParams_ gensupport.URLParams + ifNoneMatch_ string + ctx_ context.Context + header_ http.Header +} + +// Get: Gets the specified occurrence. +// +// - name: The name of the occurrence in the form of +// `projects/[PROJECT_ID]/occurrences/[OCCURRENCE_ID]`. +func (r *ProjectsLocationsOccurrencesService) Get(name string) *ProjectsLocationsOccurrencesGetCall { + c := &ProjectsLocationsOccurrencesGetCall{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 *ProjectsLocationsOccurrencesGetCall) Fields(s ...googleapi.Field) *ProjectsLocationsOccurrencesGetCall { + 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 *ProjectsLocationsOccurrencesGetCall) IfNoneMatch(entityTag string) *ProjectsLocationsOccurrencesGetCall { + 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 *ProjectsLocationsOccurrencesGetCall) Context(ctx context.Context) *ProjectsLocationsOccurrencesGetCall { + 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 *ProjectsLocationsOccurrencesGetCall) Header() http.Header { + if c.header_ == nil { + c.header_ = make(http.Header) + } + return c.header_ +} + +func (c *ProjectsLocationsOccurrencesGetCall) 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 "containeranalysis.projects.locations.occurrences.get" call. +// Exactly one of *Occurrence or error will be non-nil. Any non-2xx +// status code is an error. Response headers are in either +// *Occurrence.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 *ProjectsLocationsOccurrencesGetCall) Do(opts ...googleapi.CallOption) (*Occurrence, 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 := &Occurrence{ + 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 specified occurrence.", + // "flatPath": "v1/projects/{projectsId}/locations/{locationsId}/occurrences/{occurrencesId}", + // "httpMethod": "GET", + // "id": "containeranalysis.projects.locations.occurrences.get", + // "parameterOrder": [ + // "name" + // ], + // "parameters": { + // "name": { + // "description": "Required. The name of the occurrence in the form of `projects/[PROJECT_ID]/occurrences/[OCCURRENCE_ID]`.", + // "location": "path", + // "pattern": "^projects/[^/]+/locations/[^/]+/occurrences/[^/]+$", + // "required": true, + // "type": "string" + // } + // }, + // "path": "v1/{+name}", + // "response": { + // "$ref": "Occurrence" + // }, + // "scopes": [ + // "https://www.googleapis.com/auth/cloud-platform" + // ] + // } + +} + +// method id "containeranalysis.projects.locations.occurrences.getNotes": + +type ProjectsLocationsOccurrencesGetNotesCall struct { + s *Service + name string + urlParams_ gensupport.URLParams + ifNoneMatch_ string + ctx_ context.Context + header_ http.Header +} + +// GetNotes: Gets the note attached to the specified occurrence. +// Consumer projects can use this method to get a note that belongs to a +// provider project. +// +// - name: The name of the occurrence in the form of +// `projects/[PROJECT_ID]/occurrences/[OCCURRENCE_ID]`. +func (r *ProjectsLocationsOccurrencesService) GetNotes(name string) *ProjectsLocationsOccurrencesGetNotesCall { + c := &ProjectsLocationsOccurrencesGetNotesCall{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 *ProjectsLocationsOccurrencesGetNotesCall) Fields(s ...googleapi.Field) *ProjectsLocationsOccurrencesGetNotesCall { + 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 *ProjectsLocationsOccurrencesGetNotesCall) IfNoneMatch(entityTag string) *ProjectsLocationsOccurrencesGetNotesCall { + 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 *ProjectsLocationsOccurrencesGetNotesCall) Context(ctx context.Context) *ProjectsLocationsOccurrencesGetNotesCall { + 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 *ProjectsLocationsOccurrencesGetNotesCall) Header() http.Header { + if c.header_ == nil { + c.header_ = make(http.Header) + } + return c.header_ +} + +func (c *ProjectsLocationsOccurrencesGetNotesCall) 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}/notes") + 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 "containeranalysis.projects.locations.occurrences.getNotes" call. +// Exactly one of *Note or error will be non-nil. Any non-2xx status +// code is an error. Response headers are in either +// *Note.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 *ProjectsLocationsOccurrencesGetNotesCall) Do(opts ...googleapi.CallOption) (*Note, 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 := &Note{ + 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 note attached to the specified occurrence. Consumer projects can use this method to get a note that belongs to a provider project.", + // "flatPath": "v1/projects/{projectsId}/locations/{locationsId}/occurrences/{occurrencesId}/notes", + // "httpMethod": "GET", + // "id": "containeranalysis.projects.locations.occurrences.getNotes", + // "parameterOrder": [ + // "name" + // ], + // "parameters": { + // "name": { + // "description": "Required. The name of the occurrence in the form of `projects/[PROJECT_ID]/occurrences/[OCCURRENCE_ID]`.", + // "location": "path", + // "pattern": "^projects/[^/]+/locations/[^/]+/occurrences/[^/]+$", + // "required": true, + // "type": "string" + // } + // }, + // "path": "v1/{+name}/notes", + // "response": { + // "$ref": "Note" + // }, + // "scopes": [ + // "https://www.googleapis.com/auth/cloud-platform" + // ] + // } + +} + +// method id "containeranalysis.projects.locations.occurrences.getVulnerabilitySummary": + +type ProjectsLocationsOccurrencesGetVulnerabilitySummaryCall struct { + s *Service + parent string + urlParams_ gensupport.URLParams + ifNoneMatch_ string + ctx_ context.Context + header_ http.Header +} + +// GetVulnerabilitySummary: Gets a summary of the number and severity of +// occurrences. +// +// - parent: The name of the project to get a vulnerability summary for +// in the form of `projects/[PROJECT_ID]`. +func (r *ProjectsLocationsOccurrencesService) GetVulnerabilitySummary(parent string) *ProjectsLocationsOccurrencesGetVulnerabilitySummaryCall { + c := &ProjectsLocationsOccurrencesGetVulnerabilitySummaryCall{s: r.s, urlParams_: make(gensupport.URLParams)} + c.parent = parent + return c +} + +// Filter sets the optional parameter "filter": The filter expression. +func (c *ProjectsLocationsOccurrencesGetVulnerabilitySummaryCall) Filter(filter string) *ProjectsLocationsOccurrencesGetVulnerabilitySummaryCall { + c.urlParams_.Set("filter", filter) + 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 *ProjectsLocationsOccurrencesGetVulnerabilitySummaryCall) Fields(s ...googleapi.Field) *ProjectsLocationsOccurrencesGetVulnerabilitySummaryCall { + 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 *ProjectsLocationsOccurrencesGetVulnerabilitySummaryCall) IfNoneMatch(entityTag string) *ProjectsLocationsOccurrencesGetVulnerabilitySummaryCall { + 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 *ProjectsLocationsOccurrencesGetVulnerabilitySummaryCall) Context(ctx context.Context) *ProjectsLocationsOccurrencesGetVulnerabilitySummaryCall { + 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 *ProjectsLocationsOccurrencesGetVulnerabilitySummaryCall) Header() http.Header { + if c.header_ == nil { + c.header_ = make(http.Header) + } + return c.header_ +} + +func (c *ProjectsLocationsOccurrencesGetVulnerabilitySummaryCall) 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}/occurrences:vulnerabilitySummary") + 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 "containeranalysis.projects.locations.occurrences.getVulnerabilitySummary" call. +// Exactly one of *VulnerabilityOccurrencesSummary or error will be +// non-nil. Any non-2xx status code is an error. Response headers are in +// either *VulnerabilityOccurrencesSummary.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 *ProjectsLocationsOccurrencesGetVulnerabilitySummaryCall) Do(opts ...googleapi.CallOption) (*VulnerabilityOccurrencesSummary, 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 := &VulnerabilityOccurrencesSummary{ + 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 a summary of the number and severity of occurrences.", + // "flatPath": "v1/projects/{projectsId}/locations/{locationsId}/occurrences:vulnerabilitySummary", + // "httpMethod": "GET", + // "id": "containeranalysis.projects.locations.occurrences.getVulnerabilitySummary", + // "parameterOrder": [ + // "parent" + // ], + // "parameters": { + // "filter": { + // "description": "The filter expression.", + // "location": "query", + // "type": "string" + // }, + // "parent": { + // "description": "Required. The name of the project to get a vulnerability summary for in the form of `projects/[PROJECT_ID]`.", + // "location": "path", + // "pattern": "^projects/[^/]+/locations/[^/]+$", + // "required": true, + // "type": "string" + // } + // }, + // "path": "v1/{+parent}/occurrences:vulnerabilitySummary", + // "response": { + // "$ref": "VulnerabilityOccurrencesSummary" + // }, + // "scopes": [ + // "https://www.googleapis.com/auth/cloud-platform" + // ] + // } + +} + +// method id "containeranalysis.projects.locations.occurrences.list": + +type ProjectsLocationsOccurrencesListCall struct { + s *Service + parent string + urlParams_ gensupport.URLParams + ifNoneMatch_ string + ctx_ context.Context + header_ http.Header +} + +// List: Lists occurrences for the specified project. +// +// - parent: The name of the project to list occurrences for in the form +// of `projects/[PROJECT_ID]`. +func (r *ProjectsLocationsOccurrencesService) List(parent string) *ProjectsLocationsOccurrencesListCall { + c := &ProjectsLocationsOccurrencesListCall{s: r.s, urlParams_: make(gensupport.URLParams)} + c.parent = parent + return c +} + +// Filter sets the optional parameter "filter": The filter expression. +func (c *ProjectsLocationsOccurrencesListCall) Filter(filter string) *ProjectsLocationsOccurrencesListCall { + c.urlParams_.Set("filter", filter) + return c +} + +// PageSize sets the optional parameter "pageSize": Number of +// occurrences to return in the list. Must be positive. Max allowed page +// size is 1000. If not specified, page size defaults to 20. +func (c *ProjectsLocationsOccurrencesListCall) PageSize(pageSize int64) *ProjectsLocationsOccurrencesListCall { + c.urlParams_.Set("pageSize", fmt.Sprint(pageSize)) + return c +} + +// PageToken sets the optional parameter "pageToken": Token to provide +// to skip to a particular spot in the list. +func (c *ProjectsLocationsOccurrencesListCall) PageToken(pageToken string) *ProjectsLocationsOccurrencesListCall { + 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 *ProjectsLocationsOccurrencesListCall) Fields(s ...googleapi.Field) *ProjectsLocationsOccurrencesListCall { + 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 *ProjectsLocationsOccurrencesListCall) IfNoneMatch(entityTag string) *ProjectsLocationsOccurrencesListCall { + 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 *ProjectsLocationsOccurrencesListCall) Context(ctx context.Context) *ProjectsLocationsOccurrencesListCall { + 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 *ProjectsLocationsOccurrencesListCall) Header() http.Header { + if c.header_ == nil { + c.header_ = make(http.Header) + } + return c.header_ +} + +func (c *ProjectsLocationsOccurrencesListCall) 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}/occurrences") + 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 "containeranalysis.projects.locations.occurrences.list" call. +// Exactly one of *ListOccurrencesResponse or error will be non-nil. Any +// non-2xx status code is an error. Response headers are in either +// *ListOccurrencesResponse.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 *ProjectsLocationsOccurrencesListCall) Do(opts ...googleapi.CallOption) (*ListOccurrencesResponse, 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 := &ListOccurrencesResponse{ + 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 occurrences for the specified project.", + // "flatPath": "v1/projects/{projectsId}/locations/{locationsId}/occurrences", + // "httpMethod": "GET", + // "id": "containeranalysis.projects.locations.occurrences.list", + // "parameterOrder": [ + // "parent" + // ], + // "parameters": { + // "filter": { + // "description": "The filter expression.", + // "location": "query", + // "type": "string" + // }, + // "pageSize": { + // "description": "Number of occurrences to return in the list. Must be positive. Max allowed page size is 1000. If not specified, page size defaults to 20.", + // "format": "int32", + // "location": "query", + // "type": "integer" + // }, + // "pageToken": { + // "description": "Token to provide to skip to a particular spot in the list.", + // "location": "query", + // "type": "string" + // }, + // "parent": { + // "description": "Required. The name of the project to list occurrences for in the form of `projects/[PROJECT_ID]`.", + // "location": "path", + // "pattern": "^projects/[^/]+/locations/[^/]+$", + // "required": true, + // "type": "string" + // } + // }, + // "path": "v1/{+parent}/occurrences", + // "response": { + // "$ref": "ListOccurrencesResponse" + // }, + // "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 *ProjectsLocationsOccurrencesListCall) Pages(ctx context.Context, f func(*ListOccurrencesResponse) 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 "containeranalysis.projects.locations.resources.exportSBOM": + +type ProjectsLocationsResourcesExportSBOMCall struct { + s *Service + name string + exportsbomrequest *ExportSBOMRequest + urlParams_ gensupport.URLParams + ctx_ context.Context + header_ http.Header +} + +// ExportSBOM: Generates an SBOM for the given resource. +// +// - name: The name of the resource in the form of +// `projects/[PROJECT_ID]/resources/[RESOURCE_URL]`. +func (r *ProjectsLocationsResourcesService) ExportSBOM(name string, exportsbomrequest *ExportSBOMRequest) *ProjectsLocationsResourcesExportSBOMCall { + c := &ProjectsLocationsResourcesExportSBOMCall{s: r.s, urlParams_: make(gensupport.URLParams)} + c.name = name + c.exportsbomrequest = exportsbomrequest + 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 *ProjectsLocationsResourcesExportSBOMCall) Fields(s ...googleapi.Field) *ProjectsLocationsResourcesExportSBOMCall { + 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 *ProjectsLocationsResourcesExportSBOMCall) Context(ctx context.Context) *ProjectsLocationsResourcesExportSBOMCall { + 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 *ProjectsLocationsResourcesExportSBOMCall) Header() http.Header { + if c.header_ == nil { + c.header_ = make(http.Header) + } + return c.header_ +} + +func (c *ProjectsLocationsResourcesExportSBOMCall) 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.exportsbomrequest) + 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}:exportSBOM") + 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 "containeranalysis.projects.locations.resources.exportSBOM" call. +// Exactly one of *ExportSBOMResponse or error will be non-nil. Any +// non-2xx status code is an error. Response headers are in either +// *ExportSBOMResponse.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 *ProjectsLocationsResourcesExportSBOMCall) Do(opts ...googleapi.CallOption) (*ExportSBOMResponse, 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 := &ExportSBOMResponse{ + 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": "Generates an SBOM for the given resource.", + // "flatPath": "v1/projects/{projectsId}/locations/{locationsId}/resources/{resourcesId}:exportSBOM", + // "httpMethod": "POST", + // "id": "containeranalysis.projects.locations.resources.exportSBOM", + // "parameterOrder": [ + // "name" + // ], + // "parameters": { + // "name": { + // "description": "Required. The name of the resource in the form of `projects/[PROJECT_ID]/resources/[RESOURCE_URL]`.", + // "location": "path", + // "pattern": "^projects/[^/]+/locations/[^/]+/resources/.*$", + // "required": true, + // "type": "string" + // } + // }, + // "path": "v1/{+name}:exportSBOM", + // "request": { + // "$ref": "ExportSBOMRequest" + // }, + // "response": { + // "$ref": "ExportSBOMResponse" + // }, + // "scopes": [ + // "https://www.googleapis.com/auth/cloud-platform" + // ] + // } + +} + // method id "containeranalysis.projects.notes.batchCreate": type ProjectsNotesBatchCreateCall struct { diff --git a/containeranalysis/v1alpha1/containeranalysis-api.json b/containeranalysis/v1alpha1/containeranalysis-api.json index 32ae3d71a86..22ad2b7134c 100644 --- a/containeranalysis/v1alpha1/containeranalysis-api.json +++ b/containeranalysis/v1alpha1/containeranalysis-api.json @@ -1233,7 +1233,7 @@ } } }, - "revision": "20240209", + "revision": "20240301", "rootUrl": "https://containeranalysis.googleapis.com/", "schemas": { "AnalysisCompleted": { @@ -2015,6 +2015,10 @@ "description": "A description about this compliance check.", "type": "string" }, + "impact": { + "description": "Potential impact of the suggested remediation", + "type": "string" + }, "rationale": { "description": "A rationale for the existence of this compliance check.", "type": "string" @@ -2598,6 +2602,14 @@ "E2_HIGHCPU_32", "E2_MEDIUM" ], + "enumDeprecated": [ + false, + true, + true, + false, + false, + false + ], "enumDescriptions": [ "Standard machine type.", "Highcpu machine with 8 CPUs.", diff --git a/containeranalysis/v1alpha1/containeranalysis-gen.go b/containeranalysis/v1alpha1/containeranalysis-gen.go index 8e8f807c028..7edfc56a928 100644 --- a/containeranalysis/v1alpha1/containeranalysis-gen.go +++ b/containeranalysis/v1alpha1/containeranalysis-gen.go @@ -1405,6 +1405,9 @@ type ComplianceNote struct { // Description: A description about this compliance check. Description string `json:"description,omitempty"` + // Impact: Potential impact of the suggested remediation + Impact string `json:"impact,omitempty"` + // Rationale: A rationale for the existence of this compliance check. Rationale string `json:"rationale,omitempty"` diff --git a/containeranalysis/v1beta1/containeranalysis-api.json b/containeranalysis/v1beta1/containeranalysis-api.json index 426f2f2f083..c224b964205 100644 --- a/containeranalysis/v1beta1/containeranalysis-api.json +++ b/containeranalysis/v1beta1/containeranalysis-api.json @@ -107,6 +107,312 @@ "resources": { "projects": { "resources": { + "locations": { + "resources": { + "notes": { + "methods": { + "get": { + "description": "Gets the specified note.", + "flatPath": "v1beta1/projects/{projectsId}/locations/{locationsId}/notes/{notesId}", + "httpMethod": "GET", + "id": "containeranalysis.projects.locations.notes.get", + "parameterOrder": [ + "name" + ], + "parameters": { + "name": { + "description": "Required. The name of the note in the form of `projects/[PROVIDER_ID]/notes/[NOTE_ID]`.", + "location": "path", + "pattern": "^projects/[^/]+/locations/[^/]+/notes/[^/]+$", + "required": true, + "type": "string" + } + }, + "path": "v1beta1/{+name}", + "response": { + "$ref": "Note" + }, + "scopes": [ + "https://www.googleapis.com/auth/cloud-platform" + ] + }, + "list": { + "description": "Lists notes for the specified project.", + "flatPath": "v1beta1/projects/{projectsId}/locations/{locationsId}/notes", + "httpMethod": "GET", + "id": "containeranalysis.projects.locations.notes.list", + "parameterOrder": [ + "parent" + ], + "parameters": { + "filter": { + "description": "The filter expression.", + "location": "query", + "type": "string" + }, + "pageSize": { + "description": "Number of notes to return in the list. Must be positive. Max allowed page size is 1000. If not specified, page size defaults to 20.", + "format": "int32", + "location": "query", + "type": "integer" + }, + "pageToken": { + "description": "Token to provide to skip to a particular spot in the list.", + "location": "query", + "type": "string" + }, + "parent": { + "description": "Required. The name of the project to list notes for in the form of `projects/[PROJECT_ID]`.", + "location": "path", + "pattern": "^projects/[^/]+/locations/[^/]+$", + "required": true, + "type": "string" + } + }, + "path": "v1beta1/{+parent}/notes", + "response": { + "$ref": "ListNotesResponse" + }, + "scopes": [ + "https://www.googleapis.com/auth/cloud-platform" + ] + } + }, + "resources": { + "occurrences": { + "methods": { + "list": { + "description": "Lists occurrences referencing the specified note. Provider projects can use this method to get all occurrences across consumer projects referencing the specified note.", + "flatPath": "v1beta1/projects/{projectsId}/locations/{locationsId}/notes/{notesId}/occurrences", + "httpMethod": "GET", + "id": "containeranalysis.projects.locations.notes.occurrences.list", + "parameterOrder": [ + "name" + ], + "parameters": { + "filter": { + "description": "The filter expression.", + "location": "query", + "type": "string" + }, + "name": { + "description": "Required. The name of the note to list occurrences for in the form of `projects/[PROVIDER_ID]/notes/[NOTE_ID]`.", + "location": "path", + "pattern": "^projects/[^/]+/locations/[^/]+/notes/[^/]+$", + "required": true, + "type": "string" + }, + "pageSize": { + "description": "Number of occurrences to return in the list.", + "format": "int32", + "location": "query", + "type": "integer" + }, + "pageToken": { + "description": "Token to provide to skip to a particular spot in the list.", + "location": "query", + "type": "string" + } + }, + "path": "v1beta1/{+name}/occurrences", + "response": { + "$ref": "ListNoteOccurrencesResponse" + }, + "scopes": [ + "https://www.googleapis.com/auth/cloud-platform" + ] + } + } + } + } + }, + "occurrences": { + "methods": { + "get": { + "description": "Gets the specified occurrence.", + "flatPath": "v1beta1/projects/{projectsId}/locations/{locationsId}/occurrences/{occurrencesId}", + "httpMethod": "GET", + "id": "containeranalysis.projects.locations.occurrences.get", + "parameterOrder": [ + "name" + ], + "parameters": { + "name": { + "description": "Required. The name of the occurrence in the form of `projects/[PROJECT_ID]/occurrences/[OCCURRENCE_ID]`.", + "location": "path", + "pattern": "^projects/[^/]+/locations/[^/]+/occurrences/[^/]+$", + "required": true, + "type": "string" + } + }, + "path": "v1beta1/{+name}", + "response": { + "$ref": "Occurrence" + }, + "scopes": [ + "https://www.googleapis.com/auth/cloud-platform" + ] + }, + "getNotes": { + "description": "Gets the note attached to the specified occurrence. Consumer projects can use this method to get a note that belongs to a provider project.", + "flatPath": "v1beta1/projects/{projectsId}/locations/{locationsId}/occurrences/{occurrencesId}/notes", + "httpMethod": "GET", + "id": "containeranalysis.projects.locations.occurrences.getNotes", + "parameterOrder": [ + "name" + ], + "parameters": { + "name": { + "description": "Required. The name of the occurrence in the form of `projects/[PROJECT_ID]/occurrences/[OCCURRENCE_ID]`.", + "location": "path", + "pattern": "^projects/[^/]+/locations/[^/]+/occurrences/[^/]+$", + "required": true, + "type": "string" + } + }, + "path": "v1beta1/{+name}/notes", + "response": { + "$ref": "Note" + }, + "scopes": [ + "https://www.googleapis.com/auth/cloud-platform" + ] + }, + "getVulnerabilitySummary": { + "description": "Gets a summary of the number and severity of occurrences.", + "flatPath": "v1beta1/projects/{projectsId}/locations/{locationsId}/occurrences:vulnerabilitySummary", + "httpMethod": "GET", + "id": "containeranalysis.projects.locations.occurrences.getVulnerabilitySummary", + "parameterOrder": [ + "parent" + ], + "parameters": { + "filter": { + "description": "The filter expression.", + "location": "query", + "type": "string" + }, + "parent": { + "description": "Required. The name of the project to get a vulnerability summary for in the form of `projects/[PROJECT_ID]`.", + "location": "path", + "pattern": "^projects/[^/]+/locations/[^/]+$", + "required": true, + "type": "string" + } + }, + "path": "v1beta1/{+parent}/occurrences:vulnerabilitySummary", + "response": { + "$ref": "VulnerabilityOccurrencesSummary" + }, + "scopes": [ + "https://www.googleapis.com/auth/cloud-platform" + ] + }, + "list": { + "description": "Lists occurrences for the specified project.", + "flatPath": "v1beta1/projects/{projectsId}/locations/{locationsId}/occurrences", + "httpMethod": "GET", + "id": "containeranalysis.projects.locations.occurrences.list", + "parameterOrder": [ + "parent" + ], + "parameters": { + "filter": { + "description": "The filter expression.", + "location": "query", + "type": "string" + }, + "pageSize": { + "description": "Number of occurrences to return in the list. Must be positive. Max allowed page size is 1000. If not specified, page size defaults to 20.", + "format": "int32", + "location": "query", + "type": "integer" + }, + "pageToken": { + "description": "Token to provide to skip to a particular spot in the list.", + "location": "query", + "type": "string" + }, + "parent": { + "description": "Required. The name of the project to list occurrences for in the form of `projects/[PROJECT_ID]`.", + "location": "path", + "pattern": "^projects/[^/]+/locations/[^/]+$", + "required": true, + "type": "string" + } + }, + "path": "v1beta1/{+parent}/occurrences", + "response": { + "$ref": "ListOccurrencesResponse" + }, + "scopes": [ + "https://www.googleapis.com/auth/cloud-platform" + ] + } + } + }, + "resources": { + "methods": { + "exportSBOM": { + "description": "Generates an SBOM and other dependency information for the given resource.", + "flatPath": "v1beta1/projects/{projectsId}/locations/{locationsId}/resources/{resourcesId}:exportSBOM", + "httpMethod": "POST", + "id": "containeranalysis.projects.locations.resources.exportSBOM", + "parameterOrder": [ + "name" + ], + "parameters": { + "name": { + "description": "Required. The name of the resource in the form of `projects/[PROJECT_ID]/resources/[RESOURCE_URL]`.", + "location": "path", + "pattern": "^projects/[^/]+/locations/[^/]+/resources/.*$", + "required": true, + "type": "string" + } + }, + "path": "v1beta1/{+name}:exportSBOM", + "request": { + "$ref": "ExportSBOMRequest" + }, + "response": { + "$ref": "ExportSBOMResponse" + }, + "scopes": [ + "https://www.googleapis.com/auth/cloud-platform" + ] + }, + "generatePackagesSummary": { + "description": "Gets a summary of the packages within a given resource.", + "flatPath": "v1beta1/projects/{projectsId}/locations/{locationsId}/resources/{resourcesId}:generatePackagesSummary", + "httpMethod": "POST", + "id": "containeranalysis.projects.locations.resources.generatePackagesSummary", + "parameterOrder": [ + "name" + ], + "parameters": { + "name": { + "description": "Required. The name of the resource to get a packages summary for in the form of `projects/[PROJECT_ID]/resources/[RESOURCE_URL]`.", + "location": "path", + "pattern": "^projects/[^/]+/locations/[^/]+/resources/.*$", + "required": true, + "type": "string" + } + }, + "path": "v1beta1/{+name}:generatePackagesSummary", + "request": { + "$ref": "GeneratePackagesSummaryRequest" + }, + "response": { + "$ref": "PackagesSummaryResponse" + }, + "scopes": [ + "https://www.googleapis.com/auth/cloud-platform" + ] + } + } + } + } + }, "notes": { "methods": { "batchCreate": { @@ -815,7 +1121,7 @@ } } }, - "revision": "20240209", + "revision": "20240301", "rootUrl": "https://containeranalysis.googleapis.com/", "schemas": { "AliasContext": { @@ -2282,6 +2588,14 @@ "E2_HIGHCPU_32", "E2_MEDIUM" ], + "enumDeprecated": [ + false, + true, + true, + false, + false, + false + ], "enumDescriptions": [ "Standard machine type.", "Highcpu machine with 8 CPUs.", diff --git a/containeranalysis/v1beta1/containeranalysis-gen.go b/containeranalysis/v1beta1/containeranalysis-gen.go index 33982e45893..f7c786dac41 100644 --- a/containeranalysis/v1beta1/containeranalysis-gen.go +++ b/containeranalysis/v1beta1/containeranalysis-gen.go @@ -157,6 +157,7 @@ func (s *Service) userAgent() string { func NewProjectsService(s *Service) *ProjectsService { rs := &ProjectsService{s: s} + rs.Locations = NewProjectsLocationsService(s) rs.Notes = NewProjectsNotesService(s) rs.Occurrences = NewProjectsOccurrencesService(s) rs.Resources = NewProjectsResourcesService(s) @@ -166,6 +167,8 @@ func NewProjectsService(s *Service) *ProjectsService { type ProjectsService struct { s *Service + Locations *ProjectsLocationsService + Notes *ProjectsNotesService Occurrences *ProjectsOccurrencesService @@ -173,6 +176,63 @@ type ProjectsService struct { Resources *ProjectsResourcesService } +func NewProjectsLocationsService(s *Service) *ProjectsLocationsService { + rs := &ProjectsLocationsService{s: s} + rs.Notes = NewProjectsLocationsNotesService(s) + rs.Occurrences = NewProjectsLocationsOccurrencesService(s) + rs.Resources = NewProjectsLocationsResourcesService(s) + return rs +} + +type ProjectsLocationsService struct { + s *Service + + Notes *ProjectsLocationsNotesService + + Occurrences *ProjectsLocationsOccurrencesService + + Resources *ProjectsLocationsResourcesService +} + +func NewProjectsLocationsNotesService(s *Service) *ProjectsLocationsNotesService { + rs := &ProjectsLocationsNotesService{s: s} + rs.Occurrences = NewProjectsLocationsNotesOccurrencesService(s) + return rs +} + +type ProjectsLocationsNotesService struct { + s *Service + + Occurrences *ProjectsLocationsNotesOccurrencesService +} + +func NewProjectsLocationsNotesOccurrencesService(s *Service) *ProjectsLocationsNotesOccurrencesService { + rs := &ProjectsLocationsNotesOccurrencesService{s: s} + return rs +} + +type ProjectsLocationsNotesOccurrencesService struct { + s *Service +} + +func NewProjectsLocationsOccurrencesService(s *Service) *ProjectsLocationsOccurrencesService { + rs := &ProjectsLocationsOccurrencesService{s: s} + return rs +} + +type ProjectsLocationsOccurrencesService struct { + s *Service +} + +func NewProjectsLocationsResourcesService(s *Service) *ProjectsLocationsResourcesService { + rs := &ProjectsLocationsResourcesService{s: s} + return rs +} + +type ProjectsLocationsResourcesService struct { + s *Service +} + func NewProjectsNotesService(s *Service) *ProjectsNotesService { rs := &ProjectsNotesService{s: s} rs.Occurrences = NewProjectsNotesOccurrencesService(s) @@ -8010,6 +8070,1512 @@ func (s *WindowsDetail) MarshalJSON() ([]byte, error) { return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } +// method id "containeranalysis.projects.locations.notes.get": + +type ProjectsLocationsNotesGetCall struct { + s *Service + name string + urlParams_ gensupport.URLParams + ifNoneMatch_ string + ctx_ context.Context + header_ http.Header +} + +// Get: Gets the specified note. +// +// - name: The name of the note in the form of +// `projects/[PROVIDER_ID]/notes/[NOTE_ID]`. +func (r *ProjectsLocationsNotesService) Get(name string) *ProjectsLocationsNotesGetCall { + c := &ProjectsLocationsNotesGetCall{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 *ProjectsLocationsNotesGetCall) Fields(s ...googleapi.Field) *ProjectsLocationsNotesGetCall { + 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 *ProjectsLocationsNotesGetCall) IfNoneMatch(entityTag string) *ProjectsLocationsNotesGetCall { + 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 *ProjectsLocationsNotesGetCall) Context(ctx context.Context) *ProjectsLocationsNotesGetCall { + 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 *ProjectsLocationsNotesGetCall) Header() http.Header { + if c.header_ == nil { + c.header_ = make(http.Header) + } + return c.header_ +} + +func (c *ProjectsLocationsNotesGetCall) doRequest(alt string) (*http.Response, error) { + reqHeaders := make(http.Header) + reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version) + for k, v := range c.header_ { + reqHeaders[k] = v + } + reqHeaders.Set("User-Agent", c.s.userAgent()) + if c.ifNoneMatch_ != "" { + reqHeaders.Set("If-None-Match", c.ifNoneMatch_) + } + var body io.Reader = nil + c.urlParams_.Set("alt", alt) + c.urlParams_.Set("prettyPrint", "false") + urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta1/{+name}") + urls += "?" + c.urlParams_.Encode() + req, err := http.NewRequest("GET", urls, body) + if err != nil { + return nil, err + } + req.Header = reqHeaders + googleapi.Expand(req.URL, map[string]string{ + "name": c.name, + }) + return gensupport.SendRequest(c.ctx_, c.s.client, req) +} + +// Do executes the "containeranalysis.projects.locations.notes.get" call. +// Exactly one of *Note or error will be non-nil. Any non-2xx status +// code is an error. Response headers are in either +// *Note.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 *ProjectsLocationsNotesGetCall) Do(opts ...googleapi.CallOption) (*Note, 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 := &Note{ + 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 specified note.", + // "flatPath": "v1beta1/projects/{projectsId}/locations/{locationsId}/notes/{notesId}", + // "httpMethod": "GET", + // "id": "containeranalysis.projects.locations.notes.get", + // "parameterOrder": [ + // "name" + // ], + // "parameters": { + // "name": { + // "description": "Required. The name of the note in the form of `projects/[PROVIDER_ID]/notes/[NOTE_ID]`.", + // "location": "path", + // "pattern": "^projects/[^/]+/locations/[^/]+/notes/[^/]+$", + // "required": true, + // "type": "string" + // } + // }, + // "path": "v1beta1/{+name}", + // "response": { + // "$ref": "Note" + // }, + // "scopes": [ + // "https://www.googleapis.com/auth/cloud-platform" + // ] + // } + +} + +// method id "containeranalysis.projects.locations.notes.list": + +type ProjectsLocationsNotesListCall struct { + s *Service + parent string + urlParams_ gensupport.URLParams + ifNoneMatch_ string + ctx_ context.Context + header_ http.Header +} + +// List: Lists notes for the specified project. +// +// - parent: The name of the project to list notes for in the form of +// `projects/[PROJECT_ID]`. +func (r *ProjectsLocationsNotesService) List(parent string) *ProjectsLocationsNotesListCall { + c := &ProjectsLocationsNotesListCall{s: r.s, urlParams_: make(gensupport.URLParams)} + c.parent = parent + return c +} + +// Filter sets the optional parameter "filter": The filter expression. +func (c *ProjectsLocationsNotesListCall) Filter(filter string) *ProjectsLocationsNotesListCall { + c.urlParams_.Set("filter", filter) + return c +} + +// PageSize sets the optional parameter "pageSize": Number of notes to +// return in the list. Must be positive. Max allowed page size is 1000. +// If not specified, page size defaults to 20. +func (c *ProjectsLocationsNotesListCall) PageSize(pageSize int64) *ProjectsLocationsNotesListCall { + c.urlParams_.Set("pageSize", fmt.Sprint(pageSize)) + return c +} + +// PageToken sets the optional parameter "pageToken": Token to provide +// to skip to a particular spot in the list. +func (c *ProjectsLocationsNotesListCall) PageToken(pageToken string) *ProjectsLocationsNotesListCall { + 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 *ProjectsLocationsNotesListCall) Fields(s ...googleapi.Field) *ProjectsLocationsNotesListCall { + 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 *ProjectsLocationsNotesListCall) IfNoneMatch(entityTag string) *ProjectsLocationsNotesListCall { + 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 *ProjectsLocationsNotesListCall) Context(ctx context.Context) *ProjectsLocationsNotesListCall { + 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 *ProjectsLocationsNotesListCall) Header() http.Header { + if c.header_ == nil { + c.header_ = make(http.Header) + } + return c.header_ +} + +func (c *ProjectsLocationsNotesListCall) doRequest(alt string) (*http.Response, error) { + reqHeaders := make(http.Header) + reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version) + for k, v := range c.header_ { + reqHeaders[k] = v + } + reqHeaders.Set("User-Agent", c.s.userAgent()) + if c.ifNoneMatch_ != "" { + reqHeaders.Set("If-None-Match", c.ifNoneMatch_) + } + var body io.Reader = nil + c.urlParams_.Set("alt", alt) + c.urlParams_.Set("prettyPrint", "false") + urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta1/{+parent}/notes") + 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 "containeranalysis.projects.locations.notes.list" call. +// Exactly one of *ListNotesResponse or error will be non-nil. Any +// non-2xx status code is an error. Response headers are in either +// *ListNotesResponse.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 *ProjectsLocationsNotesListCall) Do(opts ...googleapi.CallOption) (*ListNotesResponse, 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 := &ListNotesResponse{ + 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 notes for the specified project.", + // "flatPath": "v1beta1/projects/{projectsId}/locations/{locationsId}/notes", + // "httpMethod": "GET", + // "id": "containeranalysis.projects.locations.notes.list", + // "parameterOrder": [ + // "parent" + // ], + // "parameters": { + // "filter": { + // "description": "The filter expression.", + // "location": "query", + // "type": "string" + // }, + // "pageSize": { + // "description": "Number of notes to return in the list. Must be positive. Max allowed page size is 1000. If not specified, page size defaults to 20.", + // "format": "int32", + // "location": "query", + // "type": "integer" + // }, + // "pageToken": { + // "description": "Token to provide to skip to a particular spot in the list.", + // "location": "query", + // "type": "string" + // }, + // "parent": { + // "description": "Required. The name of the project to list notes for in the form of `projects/[PROJECT_ID]`.", + // "location": "path", + // "pattern": "^projects/[^/]+/locations/[^/]+$", + // "required": true, + // "type": "string" + // } + // }, + // "path": "v1beta1/{+parent}/notes", + // "response": { + // "$ref": "ListNotesResponse" + // }, + // "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 *ProjectsLocationsNotesListCall) Pages(ctx context.Context, f func(*ListNotesResponse) 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 "containeranalysis.projects.locations.notes.occurrences.list": + +type ProjectsLocationsNotesOccurrencesListCall struct { + s *Service + name string + urlParams_ gensupport.URLParams + ifNoneMatch_ string + ctx_ context.Context + header_ http.Header +} + +// List: Lists occurrences referencing the specified note. Provider +// projects can use this method to get all occurrences across consumer +// projects referencing the specified note. +// +// - name: The name of the note to list occurrences for in the form of +// `projects/[PROVIDER_ID]/notes/[NOTE_ID]`. +func (r *ProjectsLocationsNotesOccurrencesService) List(name string) *ProjectsLocationsNotesOccurrencesListCall { + c := &ProjectsLocationsNotesOccurrencesListCall{s: r.s, urlParams_: make(gensupport.URLParams)} + c.name = name + return c +} + +// Filter sets the optional parameter "filter": The filter expression. +func (c *ProjectsLocationsNotesOccurrencesListCall) Filter(filter string) *ProjectsLocationsNotesOccurrencesListCall { + c.urlParams_.Set("filter", filter) + return c +} + +// PageSize sets the optional parameter "pageSize": Number of +// occurrences to return in the list. +func (c *ProjectsLocationsNotesOccurrencesListCall) PageSize(pageSize int64) *ProjectsLocationsNotesOccurrencesListCall { + c.urlParams_.Set("pageSize", fmt.Sprint(pageSize)) + return c +} + +// PageToken sets the optional parameter "pageToken": Token to provide +// to skip to a particular spot in the list. +func (c *ProjectsLocationsNotesOccurrencesListCall) PageToken(pageToken string) *ProjectsLocationsNotesOccurrencesListCall { + 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 *ProjectsLocationsNotesOccurrencesListCall) Fields(s ...googleapi.Field) *ProjectsLocationsNotesOccurrencesListCall { + 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 *ProjectsLocationsNotesOccurrencesListCall) IfNoneMatch(entityTag string) *ProjectsLocationsNotesOccurrencesListCall { + 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 *ProjectsLocationsNotesOccurrencesListCall) Context(ctx context.Context) *ProjectsLocationsNotesOccurrencesListCall { + 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 *ProjectsLocationsNotesOccurrencesListCall) Header() http.Header { + if c.header_ == nil { + c.header_ = make(http.Header) + } + return c.header_ +} + +func (c *ProjectsLocationsNotesOccurrencesListCall) doRequest(alt string) (*http.Response, error) { + reqHeaders := make(http.Header) + reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version) + for k, v := range c.header_ { + reqHeaders[k] = v + } + reqHeaders.Set("User-Agent", c.s.userAgent()) + if c.ifNoneMatch_ != "" { + reqHeaders.Set("If-None-Match", c.ifNoneMatch_) + } + var body io.Reader = nil + c.urlParams_.Set("alt", alt) + c.urlParams_.Set("prettyPrint", "false") + urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta1/{+name}/occurrences") + 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 "containeranalysis.projects.locations.notes.occurrences.list" call. +// Exactly one of *ListNoteOccurrencesResponse or error will be non-nil. +// Any non-2xx status code is an error. Response headers are in either +// *ListNoteOccurrencesResponse.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 *ProjectsLocationsNotesOccurrencesListCall) Do(opts ...googleapi.CallOption) (*ListNoteOccurrencesResponse, 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 := &ListNoteOccurrencesResponse{ + 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 occurrences referencing the specified note. Provider projects can use this method to get all occurrences across consumer projects referencing the specified note.", + // "flatPath": "v1beta1/projects/{projectsId}/locations/{locationsId}/notes/{notesId}/occurrences", + // "httpMethod": "GET", + // "id": "containeranalysis.projects.locations.notes.occurrences.list", + // "parameterOrder": [ + // "name" + // ], + // "parameters": { + // "filter": { + // "description": "The filter expression.", + // "location": "query", + // "type": "string" + // }, + // "name": { + // "description": "Required. The name of the note to list occurrences for in the form of `projects/[PROVIDER_ID]/notes/[NOTE_ID]`.", + // "location": "path", + // "pattern": "^projects/[^/]+/locations/[^/]+/notes/[^/]+$", + // "required": true, + // "type": "string" + // }, + // "pageSize": { + // "description": "Number of occurrences to return in the list.", + // "format": "int32", + // "location": "query", + // "type": "integer" + // }, + // "pageToken": { + // "description": "Token to provide to skip to a particular spot in the list.", + // "location": "query", + // "type": "string" + // } + // }, + // "path": "v1beta1/{+name}/occurrences", + // "response": { + // "$ref": "ListNoteOccurrencesResponse" + // }, + // "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 *ProjectsLocationsNotesOccurrencesListCall) Pages(ctx context.Context, f func(*ListNoteOccurrencesResponse) 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 "containeranalysis.projects.locations.occurrences.get": + +type ProjectsLocationsOccurrencesGetCall struct { + s *Service + name string + urlParams_ gensupport.URLParams + ifNoneMatch_ string + ctx_ context.Context + header_ http.Header +} + +// Get: Gets the specified occurrence. +// +// - name: The name of the occurrence in the form of +// `projects/[PROJECT_ID]/occurrences/[OCCURRENCE_ID]`. +func (r *ProjectsLocationsOccurrencesService) Get(name string) *ProjectsLocationsOccurrencesGetCall { + c := &ProjectsLocationsOccurrencesGetCall{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 *ProjectsLocationsOccurrencesGetCall) Fields(s ...googleapi.Field) *ProjectsLocationsOccurrencesGetCall { + 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 *ProjectsLocationsOccurrencesGetCall) IfNoneMatch(entityTag string) *ProjectsLocationsOccurrencesGetCall { + 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 *ProjectsLocationsOccurrencesGetCall) Context(ctx context.Context) *ProjectsLocationsOccurrencesGetCall { + 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 *ProjectsLocationsOccurrencesGetCall) Header() http.Header { + if c.header_ == nil { + c.header_ = make(http.Header) + } + return c.header_ +} + +func (c *ProjectsLocationsOccurrencesGetCall) doRequest(alt string) (*http.Response, error) { + reqHeaders := make(http.Header) + reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version) + for k, v := range c.header_ { + reqHeaders[k] = v + } + reqHeaders.Set("User-Agent", c.s.userAgent()) + if c.ifNoneMatch_ != "" { + reqHeaders.Set("If-None-Match", c.ifNoneMatch_) + } + var body io.Reader = nil + c.urlParams_.Set("alt", alt) + c.urlParams_.Set("prettyPrint", "false") + urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta1/{+name}") + urls += "?" + c.urlParams_.Encode() + req, err := http.NewRequest("GET", urls, body) + if err != nil { + return nil, err + } + req.Header = reqHeaders + googleapi.Expand(req.URL, map[string]string{ + "name": c.name, + }) + return gensupport.SendRequest(c.ctx_, c.s.client, req) +} + +// Do executes the "containeranalysis.projects.locations.occurrences.get" call. +// Exactly one of *Occurrence or error will be non-nil. Any non-2xx +// status code is an error. Response headers are in either +// *Occurrence.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 *ProjectsLocationsOccurrencesGetCall) Do(opts ...googleapi.CallOption) (*Occurrence, 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 := &Occurrence{ + 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 specified occurrence.", + // "flatPath": "v1beta1/projects/{projectsId}/locations/{locationsId}/occurrences/{occurrencesId}", + // "httpMethod": "GET", + // "id": "containeranalysis.projects.locations.occurrences.get", + // "parameterOrder": [ + // "name" + // ], + // "parameters": { + // "name": { + // "description": "Required. The name of the occurrence in the form of `projects/[PROJECT_ID]/occurrences/[OCCURRENCE_ID]`.", + // "location": "path", + // "pattern": "^projects/[^/]+/locations/[^/]+/occurrences/[^/]+$", + // "required": true, + // "type": "string" + // } + // }, + // "path": "v1beta1/{+name}", + // "response": { + // "$ref": "Occurrence" + // }, + // "scopes": [ + // "https://www.googleapis.com/auth/cloud-platform" + // ] + // } + +} + +// method id "containeranalysis.projects.locations.occurrences.getNotes": + +type ProjectsLocationsOccurrencesGetNotesCall struct { + s *Service + name string + urlParams_ gensupport.URLParams + ifNoneMatch_ string + ctx_ context.Context + header_ http.Header +} + +// GetNotes: Gets the note attached to the specified occurrence. +// Consumer projects can use this method to get a note that belongs to a +// provider project. +// +// - name: The name of the occurrence in the form of +// `projects/[PROJECT_ID]/occurrences/[OCCURRENCE_ID]`. +func (r *ProjectsLocationsOccurrencesService) GetNotes(name string) *ProjectsLocationsOccurrencesGetNotesCall { + c := &ProjectsLocationsOccurrencesGetNotesCall{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 *ProjectsLocationsOccurrencesGetNotesCall) Fields(s ...googleapi.Field) *ProjectsLocationsOccurrencesGetNotesCall { + 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 *ProjectsLocationsOccurrencesGetNotesCall) IfNoneMatch(entityTag string) *ProjectsLocationsOccurrencesGetNotesCall { + 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 *ProjectsLocationsOccurrencesGetNotesCall) Context(ctx context.Context) *ProjectsLocationsOccurrencesGetNotesCall { + 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 *ProjectsLocationsOccurrencesGetNotesCall) Header() http.Header { + if c.header_ == nil { + c.header_ = make(http.Header) + } + return c.header_ +} + +func (c *ProjectsLocationsOccurrencesGetNotesCall) doRequest(alt string) (*http.Response, error) { + reqHeaders := make(http.Header) + reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version) + for k, v := range c.header_ { + reqHeaders[k] = v + } + reqHeaders.Set("User-Agent", c.s.userAgent()) + if c.ifNoneMatch_ != "" { + reqHeaders.Set("If-None-Match", c.ifNoneMatch_) + } + var body io.Reader = nil + c.urlParams_.Set("alt", alt) + c.urlParams_.Set("prettyPrint", "false") + urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta1/{+name}/notes") + 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 "containeranalysis.projects.locations.occurrences.getNotes" call. +// Exactly one of *Note or error will be non-nil. Any non-2xx status +// code is an error. Response headers are in either +// *Note.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 *ProjectsLocationsOccurrencesGetNotesCall) Do(opts ...googleapi.CallOption) (*Note, 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 := &Note{ + 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 note attached to the specified occurrence. Consumer projects can use this method to get a note that belongs to a provider project.", + // "flatPath": "v1beta1/projects/{projectsId}/locations/{locationsId}/occurrences/{occurrencesId}/notes", + // "httpMethod": "GET", + // "id": "containeranalysis.projects.locations.occurrences.getNotes", + // "parameterOrder": [ + // "name" + // ], + // "parameters": { + // "name": { + // "description": "Required. The name of the occurrence in the form of `projects/[PROJECT_ID]/occurrences/[OCCURRENCE_ID]`.", + // "location": "path", + // "pattern": "^projects/[^/]+/locations/[^/]+/occurrences/[^/]+$", + // "required": true, + // "type": "string" + // } + // }, + // "path": "v1beta1/{+name}/notes", + // "response": { + // "$ref": "Note" + // }, + // "scopes": [ + // "https://www.googleapis.com/auth/cloud-platform" + // ] + // } + +} + +// method id "containeranalysis.projects.locations.occurrences.getVulnerabilitySummary": + +type ProjectsLocationsOccurrencesGetVulnerabilitySummaryCall struct { + s *Service + parent string + urlParams_ gensupport.URLParams + ifNoneMatch_ string + ctx_ context.Context + header_ http.Header +} + +// GetVulnerabilitySummary: Gets a summary of the number and severity of +// occurrences. +// +// - parent: The name of the project to get a vulnerability summary for +// in the form of `projects/[PROJECT_ID]`. +func (r *ProjectsLocationsOccurrencesService) GetVulnerabilitySummary(parent string) *ProjectsLocationsOccurrencesGetVulnerabilitySummaryCall { + c := &ProjectsLocationsOccurrencesGetVulnerabilitySummaryCall{s: r.s, urlParams_: make(gensupport.URLParams)} + c.parent = parent + return c +} + +// Filter sets the optional parameter "filter": The filter expression. +func (c *ProjectsLocationsOccurrencesGetVulnerabilitySummaryCall) Filter(filter string) *ProjectsLocationsOccurrencesGetVulnerabilitySummaryCall { + c.urlParams_.Set("filter", filter) + 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 *ProjectsLocationsOccurrencesGetVulnerabilitySummaryCall) Fields(s ...googleapi.Field) *ProjectsLocationsOccurrencesGetVulnerabilitySummaryCall { + 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 *ProjectsLocationsOccurrencesGetVulnerabilitySummaryCall) IfNoneMatch(entityTag string) *ProjectsLocationsOccurrencesGetVulnerabilitySummaryCall { + 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 *ProjectsLocationsOccurrencesGetVulnerabilitySummaryCall) Context(ctx context.Context) *ProjectsLocationsOccurrencesGetVulnerabilitySummaryCall { + 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 *ProjectsLocationsOccurrencesGetVulnerabilitySummaryCall) Header() http.Header { + if c.header_ == nil { + c.header_ = make(http.Header) + } + return c.header_ +} + +func (c *ProjectsLocationsOccurrencesGetVulnerabilitySummaryCall) doRequest(alt string) (*http.Response, error) { + reqHeaders := make(http.Header) + reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version) + for k, v := range c.header_ { + reqHeaders[k] = v + } + reqHeaders.Set("User-Agent", c.s.userAgent()) + if c.ifNoneMatch_ != "" { + reqHeaders.Set("If-None-Match", c.ifNoneMatch_) + } + var body io.Reader = nil + c.urlParams_.Set("alt", alt) + c.urlParams_.Set("prettyPrint", "false") + urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta1/{+parent}/occurrences:vulnerabilitySummary") + 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 "containeranalysis.projects.locations.occurrences.getVulnerabilitySummary" call. +// Exactly one of *VulnerabilityOccurrencesSummary or error will be +// non-nil. Any non-2xx status code is an error. Response headers are in +// either *VulnerabilityOccurrencesSummary.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 *ProjectsLocationsOccurrencesGetVulnerabilitySummaryCall) Do(opts ...googleapi.CallOption) (*VulnerabilityOccurrencesSummary, 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 := &VulnerabilityOccurrencesSummary{ + 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 a summary of the number and severity of occurrences.", + // "flatPath": "v1beta1/projects/{projectsId}/locations/{locationsId}/occurrences:vulnerabilitySummary", + // "httpMethod": "GET", + // "id": "containeranalysis.projects.locations.occurrences.getVulnerabilitySummary", + // "parameterOrder": [ + // "parent" + // ], + // "parameters": { + // "filter": { + // "description": "The filter expression.", + // "location": "query", + // "type": "string" + // }, + // "parent": { + // "description": "Required. The name of the project to get a vulnerability summary for in the form of `projects/[PROJECT_ID]`.", + // "location": "path", + // "pattern": "^projects/[^/]+/locations/[^/]+$", + // "required": true, + // "type": "string" + // } + // }, + // "path": "v1beta1/{+parent}/occurrences:vulnerabilitySummary", + // "response": { + // "$ref": "VulnerabilityOccurrencesSummary" + // }, + // "scopes": [ + // "https://www.googleapis.com/auth/cloud-platform" + // ] + // } + +} + +// method id "containeranalysis.projects.locations.occurrences.list": + +type ProjectsLocationsOccurrencesListCall struct { + s *Service + parent string + urlParams_ gensupport.URLParams + ifNoneMatch_ string + ctx_ context.Context + header_ http.Header +} + +// List: Lists occurrences for the specified project. +// +// - parent: The name of the project to list occurrences for in the form +// of `projects/[PROJECT_ID]`. +func (r *ProjectsLocationsOccurrencesService) List(parent string) *ProjectsLocationsOccurrencesListCall { + c := &ProjectsLocationsOccurrencesListCall{s: r.s, urlParams_: make(gensupport.URLParams)} + c.parent = parent + return c +} + +// Filter sets the optional parameter "filter": The filter expression. +func (c *ProjectsLocationsOccurrencesListCall) Filter(filter string) *ProjectsLocationsOccurrencesListCall { + c.urlParams_.Set("filter", filter) + return c +} + +// PageSize sets the optional parameter "pageSize": Number of +// occurrences to return in the list. Must be positive. Max allowed page +// size is 1000. If not specified, page size defaults to 20. +func (c *ProjectsLocationsOccurrencesListCall) PageSize(pageSize int64) *ProjectsLocationsOccurrencesListCall { + c.urlParams_.Set("pageSize", fmt.Sprint(pageSize)) + return c +} + +// PageToken sets the optional parameter "pageToken": Token to provide +// to skip to a particular spot in the list. +func (c *ProjectsLocationsOccurrencesListCall) PageToken(pageToken string) *ProjectsLocationsOccurrencesListCall { + 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 *ProjectsLocationsOccurrencesListCall) Fields(s ...googleapi.Field) *ProjectsLocationsOccurrencesListCall { + 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 *ProjectsLocationsOccurrencesListCall) IfNoneMatch(entityTag string) *ProjectsLocationsOccurrencesListCall { + 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 *ProjectsLocationsOccurrencesListCall) Context(ctx context.Context) *ProjectsLocationsOccurrencesListCall { + 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 *ProjectsLocationsOccurrencesListCall) Header() http.Header { + if c.header_ == nil { + c.header_ = make(http.Header) + } + return c.header_ +} + +func (c *ProjectsLocationsOccurrencesListCall) doRequest(alt string) (*http.Response, error) { + reqHeaders := make(http.Header) + reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version) + for k, v := range c.header_ { + reqHeaders[k] = v + } + reqHeaders.Set("User-Agent", c.s.userAgent()) + if c.ifNoneMatch_ != "" { + reqHeaders.Set("If-None-Match", c.ifNoneMatch_) + } + var body io.Reader = nil + c.urlParams_.Set("alt", alt) + c.urlParams_.Set("prettyPrint", "false") + urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta1/{+parent}/occurrences") + 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 "containeranalysis.projects.locations.occurrences.list" call. +// Exactly one of *ListOccurrencesResponse or error will be non-nil. Any +// non-2xx status code is an error. Response headers are in either +// *ListOccurrencesResponse.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 *ProjectsLocationsOccurrencesListCall) Do(opts ...googleapi.CallOption) (*ListOccurrencesResponse, 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 := &ListOccurrencesResponse{ + 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 occurrences for the specified project.", + // "flatPath": "v1beta1/projects/{projectsId}/locations/{locationsId}/occurrences", + // "httpMethod": "GET", + // "id": "containeranalysis.projects.locations.occurrences.list", + // "parameterOrder": [ + // "parent" + // ], + // "parameters": { + // "filter": { + // "description": "The filter expression.", + // "location": "query", + // "type": "string" + // }, + // "pageSize": { + // "description": "Number of occurrences to return in the list. Must be positive. Max allowed page size is 1000. If not specified, page size defaults to 20.", + // "format": "int32", + // "location": "query", + // "type": "integer" + // }, + // "pageToken": { + // "description": "Token to provide to skip to a particular spot in the list.", + // "location": "query", + // "type": "string" + // }, + // "parent": { + // "description": "Required. The name of the project to list occurrences for in the form of `projects/[PROJECT_ID]`.", + // "location": "path", + // "pattern": "^projects/[^/]+/locations/[^/]+$", + // "required": true, + // "type": "string" + // } + // }, + // "path": "v1beta1/{+parent}/occurrences", + // "response": { + // "$ref": "ListOccurrencesResponse" + // }, + // "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 *ProjectsLocationsOccurrencesListCall) Pages(ctx context.Context, f func(*ListOccurrencesResponse) 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 "containeranalysis.projects.locations.resources.exportSBOM": + +type ProjectsLocationsResourcesExportSBOMCall struct { + s *Service + name string + exportsbomrequest *ExportSBOMRequest + urlParams_ gensupport.URLParams + ctx_ context.Context + header_ http.Header +} + +// ExportSBOM: Generates an SBOM and other dependency information for +// the given resource. +// +// - name: The name of the resource in the form of +// `projects/[PROJECT_ID]/resources/[RESOURCE_URL]`. +func (r *ProjectsLocationsResourcesService) ExportSBOM(name string, exportsbomrequest *ExportSBOMRequest) *ProjectsLocationsResourcesExportSBOMCall { + c := &ProjectsLocationsResourcesExportSBOMCall{s: r.s, urlParams_: make(gensupport.URLParams)} + c.name = name + c.exportsbomrequest = exportsbomrequest + 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 *ProjectsLocationsResourcesExportSBOMCall) Fields(s ...googleapi.Field) *ProjectsLocationsResourcesExportSBOMCall { + 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 *ProjectsLocationsResourcesExportSBOMCall) Context(ctx context.Context) *ProjectsLocationsResourcesExportSBOMCall { + 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 *ProjectsLocationsResourcesExportSBOMCall) Header() http.Header { + if c.header_ == nil { + c.header_ = make(http.Header) + } + return c.header_ +} + +func (c *ProjectsLocationsResourcesExportSBOMCall) 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.exportsbomrequest) + if err != nil { + return nil, err + } + reqHeaders.Set("Content-Type", "application/json") + c.urlParams_.Set("alt", alt) + c.urlParams_.Set("prettyPrint", "false") + urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta1/{+name}:exportSBOM") + 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 "containeranalysis.projects.locations.resources.exportSBOM" call. +// Exactly one of *ExportSBOMResponse or error will be non-nil. Any +// non-2xx status code is an error. Response headers are in either +// *ExportSBOMResponse.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 *ProjectsLocationsResourcesExportSBOMCall) Do(opts ...googleapi.CallOption) (*ExportSBOMResponse, 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 := &ExportSBOMResponse{ + 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": "Generates an SBOM and other dependency information for the given resource.", + // "flatPath": "v1beta1/projects/{projectsId}/locations/{locationsId}/resources/{resourcesId}:exportSBOM", + // "httpMethod": "POST", + // "id": "containeranalysis.projects.locations.resources.exportSBOM", + // "parameterOrder": [ + // "name" + // ], + // "parameters": { + // "name": { + // "description": "Required. The name of the resource in the form of `projects/[PROJECT_ID]/resources/[RESOURCE_URL]`.", + // "location": "path", + // "pattern": "^projects/[^/]+/locations/[^/]+/resources/.*$", + // "required": true, + // "type": "string" + // } + // }, + // "path": "v1beta1/{+name}:exportSBOM", + // "request": { + // "$ref": "ExportSBOMRequest" + // }, + // "response": { + // "$ref": "ExportSBOMResponse" + // }, + // "scopes": [ + // "https://www.googleapis.com/auth/cloud-platform" + // ] + // } + +} + +// method id "containeranalysis.projects.locations.resources.generatePackagesSummary": + +type ProjectsLocationsResourcesGeneratePackagesSummaryCall struct { + s *Service + name string + generatepackagessummaryrequest *GeneratePackagesSummaryRequest + urlParams_ gensupport.URLParams + ctx_ context.Context + header_ http.Header +} + +// GeneratePackagesSummary: Gets a summary of the packages within a +// given resource. +// +// - name: The name of the resource to get a packages summary for in the +// form of `projects/[PROJECT_ID]/resources/[RESOURCE_URL]`. +func (r *ProjectsLocationsResourcesService) GeneratePackagesSummary(name string, generatepackagessummaryrequest *GeneratePackagesSummaryRequest) *ProjectsLocationsResourcesGeneratePackagesSummaryCall { + c := &ProjectsLocationsResourcesGeneratePackagesSummaryCall{s: r.s, urlParams_: make(gensupport.URLParams)} + c.name = name + c.generatepackagessummaryrequest = generatepackagessummaryrequest + 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 *ProjectsLocationsResourcesGeneratePackagesSummaryCall) Fields(s ...googleapi.Field) *ProjectsLocationsResourcesGeneratePackagesSummaryCall { + 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 *ProjectsLocationsResourcesGeneratePackagesSummaryCall) Context(ctx context.Context) *ProjectsLocationsResourcesGeneratePackagesSummaryCall { + 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 *ProjectsLocationsResourcesGeneratePackagesSummaryCall) Header() http.Header { + if c.header_ == nil { + c.header_ = make(http.Header) + } + return c.header_ +} + +func (c *ProjectsLocationsResourcesGeneratePackagesSummaryCall) 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.generatepackagessummaryrequest) + if err != nil { + return nil, err + } + reqHeaders.Set("Content-Type", "application/json") + c.urlParams_.Set("alt", alt) + c.urlParams_.Set("prettyPrint", "false") + urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta1/{+name}:generatePackagesSummary") + 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 "containeranalysis.projects.locations.resources.generatePackagesSummary" call. +// Exactly one of *PackagesSummaryResponse or error will be non-nil. Any +// non-2xx status code is an error. Response headers are in either +// *PackagesSummaryResponse.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 *ProjectsLocationsResourcesGeneratePackagesSummaryCall) Do(opts ...googleapi.CallOption) (*PackagesSummaryResponse, 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 := &PackagesSummaryResponse{ + 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 a summary of the packages within a given resource.", + // "flatPath": "v1beta1/projects/{projectsId}/locations/{locationsId}/resources/{resourcesId}:generatePackagesSummary", + // "httpMethod": "POST", + // "id": "containeranalysis.projects.locations.resources.generatePackagesSummary", + // "parameterOrder": [ + // "name" + // ], + // "parameters": { + // "name": { + // "description": "Required. The name of the resource to get a packages summary for in the form of `projects/[PROJECT_ID]/resources/[RESOURCE_URL]`.", + // "location": "path", + // "pattern": "^projects/[^/]+/locations/[^/]+/resources/.*$", + // "required": true, + // "type": "string" + // } + // }, + // "path": "v1beta1/{+name}:generatePackagesSummary", + // "request": { + // "$ref": "GeneratePackagesSummaryRequest" + // }, + // "response": { + // "$ref": "PackagesSummaryResponse" + // }, + // "scopes": [ + // "https://www.googleapis.com/auth/cloud-platform" + // ] + // } + +} + // method id "containeranalysis.projects.notes.batchCreate": type ProjectsNotesBatchCreateCall struct { diff --git a/dialogflow/v2beta1/dialogflow-api.json b/dialogflow/v2beta1/dialogflow-api.json index 99cc0fc6045..9db02c96917 100644 --- a/dialogflow/v2beta1/dialogflow-api.json +++ b/dialogflow/v2beta1/dialogflow-api.json @@ -7695,7 +7695,7 @@ } } }, - "revision": "20240219", + "revision": "20240305", "rootUrl": "https://dialogflow.googleapis.com/", "schemas": { "GoogleCloudDialogflowCxV3AdvancedSettings": { @@ -7713,6 +7713,10 @@ "loggingSettings": { "$ref": "GoogleCloudDialogflowCxV3AdvancedSettingsLoggingSettings", "description": "Settings for logging. Settings for Dialogflow History, Contact Center messages, StackDriver logs, and speech logging. Exposed at the following levels: - Agent level." + }, + "speechSettings": { + "$ref": "GoogleCloudDialogflowCxV3AdvancedSettingsSpeechSettings", + "description": "Settings for speech to text detection. Exposed at the following levels: - Agent level - Flow level - Page level - Parameter level" } }, "type": "object" @@ -7752,6 +7756,34 @@ }, "type": "object" }, + "GoogleCloudDialogflowCxV3AdvancedSettingsSpeechSettings": { + "description": "Define behaviors of speech to text detection.", + "id": "GoogleCloudDialogflowCxV3AdvancedSettingsSpeechSettings", + "properties": { + "endpointerSensitivity": { + "description": "Sensitivity of the speech model that detects the end of speech. Scale from 0 to 100.", + "format": "int32", + "type": "integer" + }, + "models": { + "additionalProperties": { + "type": "string" + }, + "description": "Mapping from language to Speech-to-Text model. The mapped Speech-to-Text model will be selected for requests from its corresponding language. For more information, see [Speech models](https://cloud.google.com/dialogflow/cx/docs/concept/speech-models).", + "type": "object" + }, + "noSpeechTimeout": { + "description": "Timeout before detecting no speech.", + "format": "google-duration", + "type": "string" + }, + "useTimeoutBasedEndpointing": { + "description": "Use timeout based endpointing, interpreting endpointer sensitivy as seconds of timeout value.", + "type": "boolean" + } + }, + "type": "object" + }, "GoogleCloudDialogflowCxV3AudioInput": { "description": "Represents the natural speech audio to be processed.", "id": "GoogleCloudDialogflowCxV3AudioInput", @@ -9991,6 +10023,10 @@ "loggingSettings": { "$ref": "GoogleCloudDialogflowCxV3beta1AdvancedSettingsLoggingSettings", "description": "Settings for logging. Settings for Dialogflow History, Contact Center messages, StackDriver logs, and speech logging. Exposed at the following levels: - Agent level." + }, + "speechSettings": { + "$ref": "GoogleCloudDialogflowCxV3beta1AdvancedSettingsSpeechSettings", + "description": "Settings for speech to text detection. Exposed at the following levels: - Agent level - Flow level - Page level - Parameter level" } }, "type": "object" @@ -10030,6 +10066,34 @@ }, "type": "object" }, + "GoogleCloudDialogflowCxV3beta1AdvancedSettingsSpeechSettings": { + "description": "Define behaviors of speech to text detection.", + "id": "GoogleCloudDialogflowCxV3beta1AdvancedSettingsSpeechSettings", + "properties": { + "endpointerSensitivity": { + "description": "Sensitivity of the speech model that detects the end of speech. Scale from 0 to 100.", + "format": "int32", + "type": "integer" + }, + "models": { + "additionalProperties": { + "type": "string" + }, + "description": "Mapping from language to Speech-to-Text model. The mapped Speech-to-Text model will be selected for requests from its corresponding language. For more information, see [Speech models](https://cloud.google.com/dialogflow/cx/docs/concept/speech-models).", + "type": "object" + }, + "noSpeechTimeout": { + "description": "Timeout before detecting no speech.", + "format": "google-duration", + "type": "string" + }, + "useTimeoutBasedEndpointing": { + "description": "Use timeout based endpointing, interpreting endpointer sensitivy as seconds of timeout value.", + "type": "boolean" + } + }, + "type": "object" + }, "GoogleCloudDialogflowCxV3beta1AudioInput": { "description": "Represents the natural speech audio to be processed.", "id": "GoogleCloudDialogflowCxV3beta1AudioInput", diff --git a/dialogflow/v2beta1/dialogflow-gen.go b/dialogflow/v2beta1/dialogflow-gen.go index 9a2e65b29b4..e7fd3021ae0 100644 --- a/dialogflow/v2beta1/dialogflow-gen.go +++ b/dialogflow/v2beta1/dialogflow-gen.go @@ -836,6 +836,11 @@ type GoogleCloudDialogflowCxV3AdvancedSettings struct { // logging. Exposed at the following levels: - Agent level. LoggingSettings *GoogleCloudDialogflowCxV3AdvancedSettingsLoggingSettings `json:"loggingSettings,omitempty"` + // SpeechSettings: Settings for speech to text detection. Exposed at the + // following levels: - Agent level - Flow level - Page level - Parameter + // level + SpeechSettings *GoogleCloudDialogflowCxV3AdvancedSettingsSpeechSettings `json:"speechSettings,omitempty"` + // ForceSendFields is a list of field names (e.g. // "AudioExportGcsDestination") to unconditionally include in API // requests. By default, fields with empty or default values are omitted @@ -937,6 +942,51 @@ func (s *GoogleCloudDialogflowCxV3AdvancedSettingsLoggingSettings) MarshalJSON() return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } +// GoogleCloudDialogflowCxV3AdvancedSettingsSpeechSettings: Define +// behaviors of speech to text detection. +type GoogleCloudDialogflowCxV3AdvancedSettingsSpeechSettings struct { + // EndpointerSensitivity: Sensitivity of the speech model that detects + // the end of speech. Scale from 0 to 100. + EndpointerSensitivity int64 `json:"endpointerSensitivity,omitempty"` + + // Models: Mapping from language to Speech-to-Text model. The mapped + // Speech-to-Text model will be selected for requests from its + // corresponding language. For more information, see Speech models + // (https://cloud.google.com/dialogflow/cx/docs/concept/speech-models). + Models map[string]string `json:"models,omitempty"` + + // NoSpeechTimeout: Timeout before detecting no speech. + NoSpeechTimeout string `json:"noSpeechTimeout,omitempty"` + + // UseTimeoutBasedEndpointing: Use timeout based endpointing, + // interpreting endpointer sensitivy as seconds of timeout value. + UseTimeoutBasedEndpointing bool `json:"useTimeoutBasedEndpointing,omitempty"` + + // ForceSendFields is a list of field names (e.g. + // "EndpointerSensitivity") 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. "EndpointerSensitivity") 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 *GoogleCloudDialogflowCxV3AdvancedSettingsSpeechSettings) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDialogflowCxV3AdvancedSettingsSpeechSettings + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + // GoogleCloudDialogflowCxV3AudioInput: Represents the natural speech // audio to be processed. type GoogleCloudDialogflowCxV3AudioInput struct { @@ -5043,6 +5093,11 @@ type GoogleCloudDialogflowCxV3beta1AdvancedSettings struct { // logging. Exposed at the following levels: - Agent level. LoggingSettings *GoogleCloudDialogflowCxV3beta1AdvancedSettingsLoggingSettings `json:"loggingSettings,omitempty"` + // SpeechSettings: Settings for speech to text detection. Exposed at the + // following levels: - Agent level - Flow level - Page level - Parameter + // level + SpeechSettings *GoogleCloudDialogflowCxV3beta1AdvancedSettingsSpeechSettings `json:"speechSettings,omitempty"` + // ForceSendFields is a list of field names (e.g. // "AudioExportGcsDestination") to unconditionally include in API // requests. By default, fields with empty or default values are omitted @@ -5144,6 +5199,51 @@ func (s *GoogleCloudDialogflowCxV3beta1AdvancedSettingsLoggingSettings) MarshalJ return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } +// GoogleCloudDialogflowCxV3beta1AdvancedSettingsSpeechSettings: Define +// behaviors of speech to text detection. +type GoogleCloudDialogflowCxV3beta1AdvancedSettingsSpeechSettings struct { + // EndpointerSensitivity: Sensitivity of the speech model that detects + // the end of speech. Scale from 0 to 100. + EndpointerSensitivity int64 `json:"endpointerSensitivity,omitempty"` + + // Models: Mapping from language to Speech-to-Text model. The mapped + // Speech-to-Text model will be selected for requests from its + // corresponding language. For more information, see Speech models + // (https://cloud.google.com/dialogflow/cx/docs/concept/speech-models). + Models map[string]string `json:"models,omitempty"` + + // NoSpeechTimeout: Timeout before detecting no speech. + NoSpeechTimeout string `json:"noSpeechTimeout,omitempty"` + + // UseTimeoutBasedEndpointing: Use timeout based endpointing, + // interpreting endpointer sensitivy as seconds of timeout value. + UseTimeoutBasedEndpointing bool `json:"useTimeoutBasedEndpointing,omitempty"` + + // ForceSendFields is a list of field names (e.g. + // "EndpointerSensitivity") 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. "EndpointerSensitivity") 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 *GoogleCloudDialogflowCxV3beta1AdvancedSettingsSpeechSettings) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDialogflowCxV3beta1AdvancedSettingsSpeechSettings + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + // GoogleCloudDialogflowCxV3beta1AudioInput: Represents the natural // speech audio to be processed. type GoogleCloudDialogflowCxV3beta1AudioInput struct { diff --git a/dialogflow/v3/dialogflow-api.json b/dialogflow/v3/dialogflow-api.json index 2c5f50f06d2..44cf7c85370 100644 --- a/dialogflow/v3/dialogflow-api.json +++ b/dialogflow/v3/dialogflow-api.json @@ -4453,7 +4453,7 @@ } } }, - "revision": "20240219", + "revision": "20240305", "rootUrl": "https://dialogflow.googleapis.com/", "schemas": { "GoogleCloudDialogflowCxV3AdvancedSettings": { @@ -4471,6 +4471,10 @@ "loggingSettings": { "$ref": "GoogleCloudDialogflowCxV3AdvancedSettingsLoggingSettings", "description": "Settings for logging. Settings for Dialogflow History, Contact Center messages, StackDriver logs, and speech logging. Exposed at the following levels: - Agent level." + }, + "speechSettings": { + "$ref": "GoogleCloudDialogflowCxV3AdvancedSettingsSpeechSettings", + "description": "Settings for speech to text detection. Exposed at the following levels: - Agent level - Flow level - Page level - Parameter level" } }, "type": "object" @@ -4510,6 +4514,34 @@ }, "type": "object" }, + "GoogleCloudDialogflowCxV3AdvancedSettingsSpeechSettings": { + "description": "Define behaviors of speech to text detection.", + "id": "GoogleCloudDialogflowCxV3AdvancedSettingsSpeechSettings", + "properties": { + "endpointerSensitivity": { + "description": "Sensitivity of the speech model that detects the end of speech. Scale from 0 to 100.", + "format": "int32", + "type": "integer" + }, + "models": { + "additionalProperties": { + "type": "string" + }, + "description": "Mapping from language to Speech-to-Text model. The mapped Speech-to-Text model will be selected for requests from its corresponding language. For more information, see [Speech models](https://cloud.google.com/dialogflow/cx/docs/concept/speech-models).", + "type": "object" + }, + "noSpeechTimeout": { + "description": "Timeout before detecting no speech.", + "format": "google-duration", + "type": "string" + }, + "useTimeoutBasedEndpointing": { + "description": "Use timeout based endpointing, interpreting endpointer sensitivy as seconds of timeout value.", + "type": "boolean" + } + }, + "type": "object" + }, "GoogleCloudDialogflowCxV3Agent": { "description": "Agents are best described as Natural Language Understanding (NLU) modules that transform user requests into actionable data. You can include agents in your app, product, or service to determine user intent and respond to the user in a natural way. After you create an agent, you can add Intents, Entity Types, Flows, Fulfillments, Webhooks, TransitionRouteGroups and so on to manage the conversation flows.", "id": "GoogleCloudDialogflowCxV3Agent", @@ -4563,6 +4595,10 @@ "description": "The unique identifier of the agent. Required for the Agents.UpdateAgent method. Agents.CreateAgent populates the name automatically. Format: `projects//locations//agents/`.", "type": "string" }, + "personalizationSettings": { + "$ref": "GoogleCloudDialogflowCxV3AgentPersonalizationSettings", + "description": "Optional. Settings for end user personalization." + }, "securitySettings": { "description": "Name of the SecuritySettings reference for the agent. Format: `projects//locations//securitySettings/`.", "type": "string" @@ -4656,6 +4692,21 @@ }, "type": "object" }, + "GoogleCloudDialogflowCxV3AgentPersonalizationSettings": { + "description": "Settings for end user personalization.", + "id": "GoogleCloudDialogflowCxV3AgentPersonalizationSettings", + "properties": { + "defaultEndUserMetadata": { + "additionalProperties": { + "description": "Properties of the object.", + "type": "any" + }, + "description": "Optional. Default end user metadata, used when processing DetectIntent requests. Recommended to be filled as a template instead of hard-coded value, for example { \"age\": \"$session.params.age\" }. The data will be merged with the QueryParameters.end_user_metadata in DetectIntentRequest.query_params during query processing.", + "type": "object" + } + }, + "type": "object" + }, "GoogleCloudDialogflowCxV3AgentValidationResult": { "description": "The response message for Agents.GetAgentValidationResult.", "id": "GoogleCloudDialogflowCxV3AgentValidationResult", @@ -8593,7 +8644,7 @@ "type": "string" }, "retentionWindowDays": { - "description": "Retains the data for the specified number of days. User must set a value lower than Dialogflow's default 365d TTL (30 days for Agent Assist traffic), higher value will be ignored and use default. Setting a value higher than that has no effect. A missing value or setting to 0 also means we use default TTL.", + "description": "Retains the data for the specified number of days. User must set a value lower than Dialogflow's default 365d TTL (30 days for Agent Assist traffic), higher value will be ignored and use default. Setting a value higher than that has no effect. A missing value or setting to 0 also means we use default TTL. When data retention configuration is changed, it only applies to the data created after the change; the TTL of existing data created before the change stays intact.", "format": "int32", "type": "integer" } @@ -8625,7 +8676,7 @@ "type": "string" }, "enableAudioRedaction": { - "description": "Enable audio redaction if it is true.", + "description": "Enable audio redaction if it is true. Note that this only redacts end-user audio data; Synthesised audio from the virtual agent is not redacted.", "type": "boolean" }, "gcsBucket": { @@ -9829,6 +9880,10 @@ "loggingSettings": { "$ref": "GoogleCloudDialogflowCxV3beta1AdvancedSettingsLoggingSettings", "description": "Settings for logging. Settings for Dialogflow History, Contact Center messages, StackDriver logs, and speech logging. Exposed at the following levels: - Agent level." + }, + "speechSettings": { + "$ref": "GoogleCloudDialogflowCxV3beta1AdvancedSettingsSpeechSettings", + "description": "Settings for speech to text detection. Exposed at the following levels: - Agent level - Flow level - Page level - Parameter level" } }, "type": "object" @@ -9868,6 +9923,34 @@ }, "type": "object" }, + "GoogleCloudDialogflowCxV3beta1AdvancedSettingsSpeechSettings": { + "description": "Define behaviors of speech to text detection.", + "id": "GoogleCloudDialogflowCxV3beta1AdvancedSettingsSpeechSettings", + "properties": { + "endpointerSensitivity": { + "description": "Sensitivity of the speech model that detects the end of speech. Scale from 0 to 100.", + "format": "int32", + "type": "integer" + }, + "models": { + "additionalProperties": { + "type": "string" + }, + "description": "Mapping from language to Speech-to-Text model. The mapped Speech-to-Text model will be selected for requests from its corresponding language. For more information, see [Speech models](https://cloud.google.com/dialogflow/cx/docs/concept/speech-models).", + "type": "object" + }, + "noSpeechTimeout": { + "description": "Timeout before detecting no speech.", + "format": "google-duration", + "type": "string" + }, + "useTimeoutBasedEndpointing": { + "description": "Use timeout based endpointing, interpreting endpointer sensitivy as seconds of timeout value.", + "type": "boolean" + } + }, + "type": "object" + }, "GoogleCloudDialogflowCxV3beta1AudioInput": { "description": "Represents the natural speech audio to be processed.", "id": "GoogleCloudDialogflowCxV3beta1AudioInput", diff --git a/dialogflow/v3/dialogflow-gen.go b/dialogflow/v3/dialogflow-gen.go index b8c73e6f040..1e8f6913361 100644 --- a/dialogflow/v3/dialogflow-gen.go +++ b/dialogflow/v3/dialogflow-gen.go @@ -500,6 +500,11 @@ type GoogleCloudDialogflowCxV3AdvancedSettings struct { // logging. Exposed at the following levels: - Agent level. LoggingSettings *GoogleCloudDialogflowCxV3AdvancedSettingsLoggingSettings `json:"loggingSettings,omitempty"` + // SpeechSettings: Settings for speech to text detection. Exposed at the + // following levels: - Agent level - Flow level - Page level - Parameter + // level + SpeechSettings *GoogleCloudDialogflowCxV3AdvancedSettingsSpeechSettings `json:"speechSettings,omitempty"` + // ForceSendFields is a list of field names (e.g. // "AudioExportGcsDestination") to unconditionally include in API // requests. By default, fields with empty or default values are omitted @@ -601,6 +606,51 @@ func (s *GoogleCloudDialogflowCxV3AdvancedSettingsLoggingSettings) MarshalJSON() return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } +// GoogleCloudDialogflowCxV3AdvancedSettingsSpeechSettings: Define +// behaviors of speech to text detection. +type GoogleCloudDialogflowCxV3AdvancedSettingsSpeechSettings struct { + // EndpointerSensitivity: Sensitivity of the speech model that detects + // the end of speech. Scale from 0 to 100. + EndpointerSensitivity int64 `json:"endpointerSensitivity,omitempty"` + + // Models: Mapping from language to Speech-to-Text model. The mapped + // Speech-to-Text model will be selected for requests from its + // corresponding language. For more information, see Speech models + // (https://cloud.google.com/dialogflow/cx/docs/concept/speech-models). + Models map[string]string `json:"models,omitempty"` + + // NoSpeechTimeout: Timeout before detecting no speech. + NoSpeechTimeout string `json:"noSpeechTimeout,omitempty"` + + // UseTimeoutBasedEndpointing: Use timeout based endpointing, + // interpreting endpointer sensitivy as seconds of timeout value. + UseTimeoutBasedEndpointing bool `json:"useTimeoutBasedEndpointing,omitempty"` + + // ForceSendFields is a list of field names (e.g. + // "EndpointerSensitivity") 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. "EndpointerSensitivity") 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 *GoogleCloudDialogflowCxV3AdvancedSettingsSpeechSettings) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDialogflowCxV3AdvancedSettingsSpeechSettings + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + // GoogleCloudDialogflowCxV3Agent: Agents are best described as Natural // Language Understanding (NLU) modules that transform user requests // into actionable data. You can include agents in your app, product, or @@ -663,6 +713,10 @@ type GoogleCloudDialogflowCxV3Agent struct { // automatically. Format: `projects//locations//agents/`. Name string `json:"name,omitempty"` + // PersonalizationSettings: Optional. Settings for end user + // personalization. + PersonalizationSettings *GoogleCloudDialogflowCxV3AgentPersonalizationSettings `json:"personalizationSettings,omitempty"` + // SecuritySettings: Name of the SecuritySettings reference for the // agent. Format: `projects//locations//securitySettings/`. SecuritySettings string `json:"securitySettings,omitempty"` @@ -856,6 +910,42 @@ func (s *GoogleCloudDialogflowCxV3AgentGitIntegrationSettingsGithubSettings) Mar return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } +// GoogleCloudDialogflowCxV3AgentPersonalizationSettings: Settings for +// end user personalization. +type GoogleCloudDialogflowCxV3AgentPersonalizationSettings struct { + // DefaultEndUserMetadata: Optional. Default end user metadata, used + // when processing DetectIntent requests. Recommended to be filled as a + // template instead of hard-coded value, for example { "age": + // "$session.params.age" }. The data will be merged with the + // QueryParameters.end_user_metadata in DetectIntentRequest.query_params + // during query processing. + DefaultEndUserMetadata googleapi.RawMessage `json:"defaultEndUserMetadata,omitempty"` + + // ForceSendFields is a list of field names (e.g. + // "DefaultEndUserMetadata") 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. "DefaultEndUserMetadata") + // 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 *GoogleCloudDialogflowCxV3AgentPersonalizationSettings) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDialogflowCxV3AgentPersonalizationSettings + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + // GoogleCloudDialogflowCxV3AgentValidationResult: The response message // for Agents.GetAgentValidationResult. type GoogleCloudDialogflowCxV3AgentValidationResult struct { @@ -8205,7 +8295,10 @@ type GoogleCloudDialogflowCxV3SecuritySettings struct { // days. User must set a value lower than Dialogflow's default 365d TTL // (30 days for Agent Assist traffic), higher value will be ignored and // use default. Setting a value higher than that has no effect. A - // missing value or setting to 0 also means we use default TTL. + // missing value or setting to 0 also means we use default TTL. When + // data retention configuration is changed, it only applies to the data + // created after the change; the TTL of existing data created before the + // change stays intact. RetentionWindowDays int64 `json:"retentionWindowDays,omitempty"` // ServerResponse contains the HTTP response code and headers from the @@ -8252,7 +8345,9 @@ type GoogleCloudDialogflowCxV3SecuritySettingsAudioExportSettings struct { // "OGG" - OGG Vorbis. AudioFormat string `json:"audioFormat,omitempty"` - // EnableAudioRedaction: Enable audio redaction if it is true. + // EnableAudioRedaction: Enable audio redaction if it is true. Note that + // this only redacts end-user audio data; Synthesised audio from the + // virtual agent is not redacted. EnableAudioRedaction bool `json:"enableAudioRedaction,omitempty"` // GcsBucket: Cloud Storage bucket to export audio record to. Setting @@ -10380,6 +10475,11 @@ type GoogleCloudDialogflowCxV3beta1AdvancedSettings struct { // logging. Exposed at the following levels: - Agent level. LoggingSettings *GoogleCloudDialogflowCxV3beta1AdvancedSettingsLoggingSettings `json:"loggingSettings,omitempty"` + // SpeechSettings: Settings for speech to text detection. Exposed at the + // following levels: - Agent level - Flow level - Page level - Parameter + // level + SpeechSettings *GoogleCloudDialogflowCxV3beta1AdvancedSettingsSpeechSettings `json:"speechSettings,omitempty"` + // ForceSendFields is a list of field names (e.g. // "AudioExportGcsDestination") to unconditionally include in API // requests. By default, fields with empty or default values are omitted @@ -10481,6 +10581,51 @@ func (s *GoogleCloudDialogflowCxV3beta1AdvancedSettingsLoggingSettings) MarshalJ return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } +// GoogleCloudDialogflowCxV3beta1AdvancedSettingsSpeechSettings: Define +// behaviors of speech to text detection. +type GoogleCloudDialogflowCxV3beta1AdvancedSettingsSpeechSettings struct { + // EndpointerSensitivity: Sensitivity of the speech model that detects + // the end of speech. Scale from 0 to 100. + EndpointerSensitivity int64 `json:"endpointerSensitivity,omitempty"` + + // Models: Mapping from language to Speech-to-Text model. The mapped + // Speech-to-Text model will be selected for requests from its + // corresponding language. For more information, see Speech models + // (https://cloud.google.com/dialogflow/cx/docs/concept/speech-models). + Models map[string]string `json:"models,omitempty"` + + // NoSpeechTimeout: Timeout before detecting no speech. + NoSpeechTimeout string `json:"noSpeechTimeout,omitempty"` + + // UseTimeoutBasedEndpointing: Use timeout based endpointing, + // interpreting endpointer sensitivy as seconds of timeout value. + UseTimeoutBasedEndpointing bool `json:"useTimeoutBasedEndpointing,omitempty"` + + // ForceSendFields is a list of field names (e.g. + // "EndpointerSensitivity") 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. "EndpointerSensitivity") 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 *GoogleCloudDialogflowCxV3beta1AdvancedSettingsSpeechSettings) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDialogflowCxV3beta1AdvancedSettingsSpeechSettings + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + // GoogleCloudDialogflowCxV3beta1AudioInput: Represents the natural // speech audio to be processed. type GoogleCloudDialogflowCxV3beta1AudioInput struct { diff --git a/dialogflow/v3beta1/dialogflow-api.json b/dialogflow/v3beta1/dialogflow-api.json index 0477d073cb2..778b9131bb4 100644 --- a/dialogflow/v3beta1/dialogflow-api.json +++ b/dialogflow/v3beta1/dialogflow-api.json @@ -4453,7 +4453,7 @@ } } }, - "revision": "20240219", + "revision": "20240305", "rootUrl": "https://dialogflow.googleapis.com/", "schemas": { "GoogleCloudDialogflowCxV3AdvancedSettings": { @@ -4471,6 +4471,10 @@ "loggingSettings": { "$ref": "GoogleCloudDialogflowCxV3AdvancedSettingsLoggingSettings", "description": "Settings for logging. Settings for Dialogflow History, Contact Center messages, StackDriver logs, and speech logging. Exposed at the following levels: - Agent level." + }, + "speechSettings": { + "$ref": "GoogleCloudDialogflowCxV3AdvancedSettingsSpeechSettings", + "description": "Settings for speech to text detection. Exposed at the following levels: - Agent level - Flow level - Page level - Parameter level" } }, "type": "object" @@ -4510,6 +4514,34 @@ }, "type": "object" }, + "GoogleCloudDialogflowCxV3AdvancedSettingsSpeechSettings": { + "description": "Define behaviors of speech to text detection.", + "id": "GoogleCloudDialogflowCxV3AdvancedSettingsSpeechSettings", + "properties": { + "endpointerSensitivity": { + "description": "Sensitivity of the speech model that detects the end of speech. Scale from 0 to 100.", + "format": "int32", + "type": "integer" + }, + "models": { + "additionalProperties": { + "type": "string" + }, + "description": "Mapping from language to Speech-to-Text model. The mapped Speech-to-Text model will be selected for requests from its corresponding language. For more information, see [Speech models](https://cloud.google.com/dialogflow/cx/docs/concept/speech-models).", + "type": "object" + }, + "noSpeechTimeout": { + "description": "Timeout before detecting no speech.", + "format": "google-duration", + "type": "string" + }, + "useTimeoutBasedEndpointing": { + "description": "Use timeout based endpointing, interpreting endpointer sensitivy as seconds of timeout value.", + "type": "boolean" + } + }, + "type": "object" + }, "GoogleCloudDialogflowCxV3AudioInput": { "description": "Represents the natural speech audio to be processed.", "id": "GoogleCloudDialogflowCxV3AudioInput", @@ -6749,6 +6781,10 @@ "loggingSettings": { "$ref": "GoogleCloudDialogflowCxV3beta1AdvancedSettingsLoggingSettings", "description": "Settings for logging. Settings for Dialogflow History, Contact Center messages, StackDriver logs, and speech logging. Exposed at the following levels: - Agent level." + }, + "speechSettings": { + "$ref": "GoogleCloudDialogflowCxV3beta1AdvancedSettingsSpeechSettings", + "description": "Settings for speech to text detection. Exposed at the following levels: - Agent level - Flow level - Page level - Parameter level" } }, "type": "object" @@ -6788,6 +6824,34 @@ }, "type": "object" }, + "GoogleCloudDialogflowCxV3beta1AdvancedSettingsSpeechSettings": { + "description": "Define behaviors of speech to text detection.", + "id": "GoogleCloudDialogflowCxV3beta1AdvancedSettingsSpeechSettings", + "properties": { + "endpointerSensitivity": { + "description": "Sensitivity of the speech model that detects the end of speech. Scale from 0 to 100.", + "format": "int32", + "type": "integer" + }, + "models": { + "additionalProperties": { + "type": "string" + }, + "description": "Mapping from language to Speech-to-Text model. The mapped Speech-to-Text model will be selected for requests from its corresponding language. For more information, see [Speech models](https://cloud.google.com/dialogflow/cx/docs/concept/speech-models).", + "type": "object" + }, + "noSpeechTimeout": { + "description": "Timeout before detecting no speech.", + "format": "google-duration", + "type": "string" + }, + "useTimeoutBasedEndpointing": { + "description": "Use timeout based endpointing, interpreting endpointer sensitivy as seconds of timeout value.", + "type": "boolean" + } + }, + "type": "object" + }, "GoogleCloudDialogflowCxV3beta1Agent": { "description": "Agents are best described as Natural Language Understanding (NLU) modules that transform user requests into actionable data. You can include agents in your app, product, or service to determine user intent and respond to the user in a natural way. After you create an agent, you can add Intents, Entity Types, Flows, Fulfillments, Webhooks, TransitionRouteGroups and so on to manage the conversation flows.", "id": "GoogleCloudDialogflowCxV3beta1Agent", @@ -6841,6 +6905,10 @@ "description": "The unique identifier of the agent. Required for the Agents.UpdateAgent method. Agents.CreateAgent populates the name automatically. Format: `projects//locations//agents/`.", "type": "string" }, + "personalizationSettings": { + "$ref": "GoogleCloudDialogflowCxV3beta1AgentPersonalizationSettings", + "description": "Optional. Settings for end user personalization." + }, "securitySettings": { "description": "Name of the SecuritySettings reference for the agent. Format: `projects//locations//securitySettings/`.", "type": "string" @@ -6934,6 +7002,21 @@ }, "type": "object" }, + "GoogleCloudDialogflowCxV3beta1AgentPersonalizationSettings": { + "description": "Settings for end user personalization.", + "id": "GoogleCloudDialogflowCxV3beta1AgentPersonalizationSettings", + "properties": { + "defaultEndUserMetadata": { + "additionalProperties": { + "description": "Properties of the object.", + "type": "any" + }, + "description": "Optional. Default end user metadata, used when processing DetectIntent requests. Recommended to be filled as a template instead of hard-coded value, for example { \"age\": \"$session.params.age\" }. The data will be merged with the QueryParameters.end_user_metadata in DetectIntentRequest.query_params during query processing.", + "type": "object" + } + }, + "type": "object" + }, "GoogleCloudDialogflowCxV3beta1AgentValidationResult": { "description": "The response message for Agents.GetAgentValidationResult.", "id": "GoogleCloudDialogflowCxV3beta1AgentValidationResult", @@ -10884,7 +10967,7 @@ "type": "string" }, "retentionWindowDays": { - "description": "Retains data in interaction logging for the specified number of days. This does not apply to Cloud logging, which is owned by the user - not Dialogflow. User must set a value lower than Dialogflow's default 365d TTL (30 days for Agent Assist traffic), higher value will be ignored and use default. Setting a value higher than that has no effect. A missing value or setting to 0 also means we use default TTL.", + "description": "Retains data in interaction logging for the specified number of days. This does not apply to Cloud logging, which is owned by the user - not Dialogflow. User must set a value lower than Dialogflow's default 365d TTL (30 days for Agent Assist traffic), higher value will be ignored and use default. Setting a value higher than that has no effect. A missing value or setting to 0 also means we use default TTL. When data retention configuration is changed, it only applies to the data created after the change; the TTL of existing data created before the change stays intact.", "format": "int32", "type": "integer" } @@ -10916,7 +10999,7 @@ "type": "string" }, "enableAudioRedaction": { - "description": "Enable audio redaction if it is true.", + "description": "Enable audio redaction if it is true. Note that this only redacts end-user audio data; Synthesised audio from the virtual agent is not redacted.", "type": "boolean" }, "gcsBucket": { diff --git a/dialogflow/v3beta1/dialogflow-gen.go b/dialogflow/v3beta1/dialogflow-gen.go index f4c58572c5e..5d85d743a34 100644 --- a/dialogflow/v3beta1/dialogflow-gen.go +++ b/dialogflow/v3beta1/dialogflow-gen.go @@ -500,6 +500,11 @@ type GoogleCloudDialogflowCxV3AdvancedSettings struct { // logging. Exposed at the following levels: - Agent level. LoggingSettings *GoogleCloudDialogflowCxV3AdvancedSettingsLoggingSettings `json:"loggingSettings,omitempty"` + // SpeechSettings: Settings for speech to text detection. Exposed at the + // following levels: - Agent level - Flow level - Page level - Parameter + // level + SpeechSettings *GoogleCloudDialogflowCxV3AdvancedSettingsSpeechSettings `json:"speechSettings,omitempty"` + // ForceSendFields is a list of field names (e.g. // "AudioExportGcsDestination") to unconditionally include in API // requests. By default, fields with empty or default values are omitted @@ -601,6 +606,51 @@ func (s *GoogleCloudDialogflowCxV3AdvancedSettingsLoggingSettings) MarshalJSON() return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } +// GoogleCloudDialogflowCxV3AdvancedSettingsSpeechSettings: Define +// behaviors of speech to text detection. +type GoogleCloudDialogflowCxV3AdvancedSettingsSpeechSettings struct { + // EndpointerSensitivity: Sensitivity of the speech model that detects + // the end of speech. Scale from 0 to 100. + EndpointerSensitivity int64 `json:"endpointerSensitivity,omitempty"` + + // Models: Mapping from language to Speech-to-Text model. The mapped + // Speech-to-Text model will be selected for requests from its + // corresponding language. For more information, see Speech models + // (https://cloud.google.com/dialogflow/cx/docs/concept/speech-models). + Models map[string]string `json:"models,omitempty"` + + // NoSpeechTimeout: Timeout before detecting no speech. + NoSpeechTimeout string `json:"noSpeechTimeout,omitempty"` + + // UseTimeoutBasedEndpointing: Use timeout based endpointing, + // interpreting endpointer sensitivy as seconds of timeout value. + UseTimeoutBasedEndpointing bool `json:"useTimeoutBasedEndpointing,omitempty"` + + // ForceSendFields is a list of field names (e.g. + // "EndpointerSensitivity") 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. "EndpointerSensitivity") 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 *GoogleCloudDialogflowCxV3AdvancedSettingsSpeechSettings) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDialogflowCxV3AdvancedSettingsSpeechSettings + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + // GoogleCloudDialogflowCxV3AudioInput: Represents the natural speech // audio to be processed. type GoogleCloudDialogflowCxV3AudioInput struct { @@ -4707,6 +4757,11 @@ type GoogleCloudDialogflowCxV3beta1AdvancedSettings struct { // logging. Exposed at the following levels: - Agent level. LoggingSettings *GoogleCloudDialogflowCxV3beta1AdvancedSettingsLoggingSettings `json:"loggingSettings,omitempty"` + // SpeechSettings: Settings for speech to text detection. Exposed at the + // following levels: - Agent level - Flow level - Page level - Parameter + // level + SpeechSettings *GoogleCloudDialogflowCxV3beta1AdvancedSettingsSpeechSettings `json:"speechSettings,omitempty"` + // ForceSendFields is a list of field names (e.g. // "AudioExportGcsDestination") to unconditionally include in API // requests. By default, fields with empty or default values are omitted @@ -4808,6 +4863,51 @@ func (s *GoogleCloudDialogflowCxV3beta1AdvancedSettingsLoggingSettings) MarshalJ return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } +// GoogleCloudDialogflowCxV3beta1AdvancedSettingsSpeechSettings: Define +// behaviors of speech to text detection. +type GoogleCloudDialogflowCxV3beta1AdvancedSettingsSpeechSettings struct { + // EndpointerSensitivity: Sensitivity of the speech model that detects + // the end of speech. Scale from 0 to 100. + EndpointerSensitivity int64 `json:"endpointerSensitivity,omitempty"` + + // Models: Mapping from language to Speech-to-Text model. The mapped + // Speech-to-Text model will be selected for requests from its + // corresponding language. For more information, see Speech models + // (https://cloud.google.com/dialogflow/cx/docs/concept/speech-models). + Models map[string]string `json:"models,omitempty"` + + // NoSpeechTimeout: Timeout before detecting no speech. + NoSpeechTimeout string `json:"noSpeechTimeout,omitempty"` + + // UseTimeoutBasedEndpointing: Use timeout based endpointing, + // interpreting endpointer sensitivy as seconds of timeout value. + UseTimeoutBasedEndpointing bool `json:"useTimeoutBasedEndpointing,omitempty"` + + // ForceSendFields is a list of field names (e.g. + // "EndpointerSensitivity") 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. "EndpointerSensitivity") 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 *GoogleCloudDialogflowCxV3beta1AdvancedSettingsSpeechSettings) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDialogflowCxV3beta1AdvancedSettingsSpeechSettings + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + // GoogleCloudDialogflowCxV3beta1Agent: Agents are best described as // Natural Language Understanding (NLU) modules that transform user // requests into actionable data. You can include agents in your app, @@ -4870,6 +4970,10 @@ type GoogleCloudDialogflowCxV3beta1Agent struct { // automatically. Format: `projects//locations//agents/`. Name string `json:"name,omitempty"` + // PersonalizationSettings: Optional. Settings for end user + // personalization. + PersonalizationSettings *GoogleCloudDialogflowCxV3beta1AgentPersonalizationSettings `json:"personalizationSettings,omitempty"` + // SecuritySettings: Name of the SecuritySettings reference for the // agent. Format: `projects//locations//securitySettings/`. SecuritySettings string `json:"securitySettings,omitempty"` @@ -5063,6 +5167,42 @@ func (s *GoogleCloudDialogflowCxV3beta1AgentGitIntegrationSettingsGithubSettings return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } +// GoogleCloudDialogflowCxV3beta1AgentPersonalizationSettings: Settings +// for end user personalization. +type GoogleCloudDialogflowCxV3beta1AgentPersonalizationSettings struct { + // DefaultEndUserMetadata: Optional. Default end user metadata, used + // when processing DetectIntent requests. Recommended to be filled as a + // template instead of hard-coded value, for example { "age": + // "$session.params.age" }. The data will be merged with the + // QueryParameters.end_user_metadata in DetectIntentRequest.query_params + // during query processing. + DefaultEndUserMetadata googleapi.RawMessage `json:"defaultEndUserMetadata,omitempty"` + + // ForceSendFields is a list of field names (e.g. + // "DefaultEndUserMetadata") 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. "DefaultEndUserMetadata") + // 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 *GoogleCloudDialogflowCxV3beta1AgentPersonalizationSettings) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDialogflowCxV3beta1AgentPersonalizationSettings + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + // GoogleCloudDialogflowCxV3beta1AgentValidationResult: The response // message for Agents.GetAgentValidationResult. type GoogleCloudDialogflowCxV3beta1AgentValidationResult struct { @@ -12429,7 +12569,9 @@ type GoogleCloudDialogflowCxV3beta1SecuritySettings struct { // than Dialogflow's default 365d TTL (30 days for Agent Assist // traffic), higher value will be ignored and use default. Setting a // value higher than that has no effect. A missing value or setting to 0 - // also means we use default TTL. + // also means we use default TTL. When data retention configuration is + // changed, it only applies to the data created after the change; the + // TTL of existing data created before the change stays intact. RetentionWindowDays int64 `json:"retentionWindowDays,omitempty"` // ServerResponse contains the HTTP response code and headers from the @@ -12476,7 +12618,9 @@ type GoogleCloudDialogflowCxV3beta1SecuritySettingsAudioExportSettings struct { // "OGG" - OGG Vorbis. AudioFormat string `json:"audioFormat,omitempty"` - // EnableAudioRedaction: Enable audio redaction if it is true. + // EnableAudioRedaction: Enable audio redaction if it is true. Note that + // this only redacts end-user audio data; Synthesised audio from the + // virtual agent is not redacted. EnableAudioRedaction bool `json:"enableAudioRedaction,omitempty"` // GcsBucket: Cloud Storage bucket to export audio record to. Setting diff --git a/displayvideo/v2/displayvideo-api.json b/displayvideo/v2/displayvideo-api.json index e02f71cf1bb..593bfce9ddb 100644 --- a/displayvideo/v2/displayvideo-api.json +++ b/displayvideo/v2/displayvideo-api.json @@ -9267,7 +9267,7 @@ } } }, - "revision": "20240222", + "revision": "20240307", "rootUrl": "https://displayvideo.googleapis.com/", "schemas": { "ActivateManualTriggerRequest": { @@ -12339,7 +12339,7 @@ true, true, true, - false, + true, false, false, false @@ -12357,7 +12357,7 @@ "SDF version 5.4", "SDF version 5.5", "SDF version 6", - "SDF version 7. Read the [v7 migration guide](/display-video/api/structured-data-file/v7-migration-guide) before migrating to this version. Currently in beta. Only available for use by a subset of users." + "SDF version 7. Read the [v7 migration guide](/display-video/api/structured-data-file/v7-migration-guide) before migrating to this version." ], "type": "string" } @@ -19822,7 +19822,7 @@ true, true, true, - false, + true, false, false, false @@ -19840,7 +19840,7 @@ "SDF version 5.4", "SDF version 5.5", "SDF version 6", - "SDF version 7. Read the [v7 migration guide](/display-video/api/structured-data-file/v7-migration-guide) before migrating to this version. Currently in beta. Only available for use by a subset of users." + "SDF version 7. Read the [v7 migration guide](/display-video/api/structured-data-file/v7-migration-guide) before migrating to this version." ], "type": "string" } @@ -19899,7 +19899,7 @@ true, true, true, - false, + true, false, false, false @@ -19917,7 +19917,7 @@ "SDF version 5.4", "SDF version 5.5", "SDF version 6", - "SDF version 7. Read the [v7 migration guide](/display-video/api/structured-data-file/v7-migration-guide) before migrating to this version. Currently in beta. Only available for use by a subset of users." + "SDF version 7. Read the [v7 migration guide](/display-video/api/structured-data-file/v7-migration-guide) before migrating to this version." ], "type": "string" } @@ -21428,7 +21428,7 @@ "type": "string" }, "value": { - "description": "The value used by the bidding strategy. When the bidding strategy is assigned at the line item level, this field is only applicable for the following strategy types: * `YOUTUBE_AND_PARTNERS_BIDDING_STRATEGY_TYPE_TARGET_CPA` * `YOUTUBE_AND_PARTNERS_BIDDING_STRATEGY_TYPE_TARGET_ROAS` When the bidding strategy is assigned at the ad group level, this field is only applicable for the following strategy types: * `YOUTUBE_AND_PARTNERS_BIDDING_STRATEGY_TYPE_MANUAL_CPM` * `YOUTUBE_AND_PARTNERS_BIDDING_STRATEGY_TYPE_MANUAL_CPV` * `YOUTUBE_AND_PARTNERS_BIDDING_STRATEGY_TYPE_TARGET_CPA` * `YOUTUBE_AND_PARTNERS_BIDDING_STRATEGY_TYPE_TARGET_CPM` * `YOUTUBE_AND_PARTNERS_BIDDING_STRATEGY_TYPE_TARGET_ROAS` If not using an applicable strategy, the value of this field will be 0.", + "description": "The value used by the bidding strategy. When the bidding strategy is assigned at the line item level, this field is only applicable for the following strategy types: * `YOUTUBE_AND_PARTNERS_BIDDING_STRATEGY_TYPE_TARGET_CPA` * `YOUTUBE_AND_PARTNERS_BIDDING_STRATEGY_TYPE_TARGET_ROAS` When the bidding strategy is assigned at the ad group level, this field is only applicable for the following strategy types: * `YOUTUBE_AND_PARTNERS_BIDDING_STRATEGY_TYPE_MANUAL_CPM` * `YOUTUBE_AND_PARTNERS_BIDDING_STRATEGY_TYPE_MANUAL_CPV` * `YOUTUBE_AND_PARTNERS_BIDDING_STRATEGY_TYPE_TARGET_CPA` * `YOUTUBE_AND_PARTNERS_BIDDING_STRATEGY_TYPE_TARGET_CPM` * `YOUTUBE_AND_PARTNERS_BIDDING_STRATEGY_TYPE_RESERVE_CPM` * `YOUTUBE_AND_PARTNERS_BIDDING_STRATEGY_TYPE_TARGET_ROAS` If not using an applicable strategy, the value of this field will be 0.", "format": "int64", "type": "string" } diff --git a/displayvideo/v2/displayvideo-gen.go b/displayvideo/v2/displayvideo-gen.go index 74e18e20fa0..baf48afdbd0 100644 --- a/displayvideo/v2/displayvideo-gen.go +++ b/displayvideo/v2/displayvideo-gen.go @@ -5824,8 +5824,7 @@ type CreateSdfDownloadTaskRequest struct { // "SDF_VERSION_6" - SDF version 6 // "SDF_VERSION_7" - SDF version 7. Read the [v7 migration // guide](/display-video/api/structured-data-file/v7-migration-guide) - // before migrating to this version. Currently in beta. Only available - // for use by a subset of users. + // before migrating to this version. Version string `json:"version,omitempty"` // ForceSendFields is a list of field names (e.g. "AdvertiserId") to @@ -16166,8 +16165,7 @@ type SdfConfig struct { // "SDF_VERSION_6" - SDF version 6 // "SDF_VERSION_7" - SDF version 7. Read the [v7 migration // guide](/display-video/api/structured-data-file/v7-migration-guide) - // before migrating to this version. Currently in beta. Only available - // for use by a subset of users. + // before migrating to this version. Version string `json:"version,omitempty"` // ForceSendFields is a list of field names (e.g. "AdminEmail") to @@ -16253,8 +16251,7 @@ type SdfDownloadTaskMetadata struct { // "SDF_VERSION_6" - SDF version 6 // "SDF_VERSION_7" - SDF version 7. Read the [v7 migration // guide](/display-video/api/structured-data-file/v7-migration-guide) - // before migrating to this version. Currently in beta. Only available - // for use by a subset of users. + // before migrating to this version. Version string `json:"version,omitempty"` // ForceSendFields is a list of field names (e.g. "CreateTime") to @@ -18419,6 +18416,7 @@ type YoutubeAndPartnersBiddingStrategy struct { // `YOUTUBE_AND_PARTNERS_BIDDING_STRATEGY_TYPE_MANUAL_CPV` * // `YOUTUBE_AND_PARTNERS_BIDDING_STRATEGY_TYPE_TARGET_CPA` * // `YOUTUBE_AND_PARTNERS_BIDDING_STRATEGY_TYPE_TARGET_CPM` * + // `YOUTUBE_AND_PARTNERS_BIDDING_STRATEGY_TYPE_RESERVE_CPM` * // `YOUTUBE_AND_PARTNERS_BIDDING_STRATEGY_TYPE_TARGET_ROAS` If not using // an applicable strategy, the value of this field will be 0. Value int64 `json:"value,omitempty,string"` diff --git a/displayvideo/v3/displayvideo-api.json b/displayvideo/v3/displayvideo-api.json index 81c7dc5933a..7be0011867e 100644 --- a/displayvideo/v3/displayvideo-api.json +++ b/displayvideo/v3/displayvideo-api.json @@ -9222,7 +9222,7 @@ } } }, - "revision": "20240222", + "revision": "20240307", "rootUrl": "https://displayvideo.googleapis.com/", "schemas": { "ActiveViewVideoViewabilityMetricConfig": { @@ -12910,7 +12910,7 @@ true, true, true, - false, + true, false, false, false @@ -12928,7 +12928,7 @@ "SDF version 5.4", "SDF version 5.5", "SDF version 6", - "SDF version 7. Read the [v7 migration guide](/display-video/api/structured-data-file/v7-migration-guide) before migrating to this version. Currently in beta. Only available for use by a subset of users." + "SDF version 7. Read the [v7 migration guide](/display-video/api/structured-data-file/v7-migration-guide) before migrating to this version." ], "type": "string" } @@ -20532,7 +20532,7 @@ true, true, true, - false, + true, false, false, false @@ -20550,7 +20550,7 @@ "SDF version 5.4", "SDF version 5.5", "SDF version 6", - "SDF version 7. Read the [v7 migration guide](/display-video/api/structured-data-file/v7-migration-guide) before migrating to this version. Currently in beta. Only available for use by a subset of users." + "SDF version 7. Read the [v7 migration guide](/display-video/api/structured-data-file/v7-migration-guide) before migrating to this version." ], "type": "string" } @@ -20609,7 +20609,7 @@ true, true, true, - false, + true, false, false, false @@ -20627,7 +20627,7 @@ "SDF version 5.4", "SDF version 5.5", "SDF version 6", - "SDF version 7. Read the [v7 migration guide](/display-video/api/structured-data-file/v7-migration-guide) before migrating to this version. Currently in beta. Only available for use by a subset of users." + "SDF version 7. Read the [v7 migration guide](/display-video/api/structured-data-file/v7-migration-guide) before migrating to this version." ], "type": "string" } @@ -21964,7 +21964,7 @@ "type": "string" }, "value": { - "description": "The value used by the bidding strategy. When the bidding strategy is assigned at the line item level, this field is only applicable for the following strategy types: * `YOUTUBE_AND_PARTNERS_BIDDING_STRATEGY_TYPE_TARGET_CPA` * `YOUTUBE_AND_PARTNERS_BIDDING_STRATEGY_TYPE_TARGET_ROAS` When the bidding strategy is assigned at the ad group level, this field is only applicable for the following strategy types: * `YOUTUBE_AND_PARTNERS_BIDDING_STRATEGY_TYPE_MANUAL_CPM` * `YOUTUBE_AND_PARTNERS_BIDDING_STRATEGY_TYPE_MANUAL_CPV` * `YOUTUBE_AND_PARTNERS_BIDDING_STRATEGY_TYPE_TARGET_CPA` * `YOUTUBE_AND_PARTNERS_BIDDING_STRATEGY_TYPE_TARGET_CPM` * `YOUTUBE_AND_PARTNERS_BIDDING_STRATEGY_TYPE_TARGET_ROAS` If not using an applicable strategy, the value of this field will be 0.", + "description": "The value used by the bidding strategy. When the bidding strategy is assigned at the line item level, this field is only applicable for the following strategy types: * `YOUTUBE_AND_PARTNERS_BIDDING_STRATEGY_TYPE_TARGET_CPA` * `YOUTUBE_AND_PARTNERS_BIDDING_STRATEGY_TYPE_TARGET_ROAS` When the bidding strategy is assigned at the ad group level, this field is only applicable for the following strategy types: * `YOUTUBE_AND_PARTNERS_BIDDING_STRATEGY_TYPE_MANUAL_CPM` * `YOUTUBE_AND_PARTNERS_BIDDING_STRATEGY_TYPE_MANUAL_CPV` * `YOUTUBE_AND_PARTNERS_BIDDING_STRATEGY_TYPE_TARGET_CPA` * `YOUTUBE_AND_PARTNERS_BIDDING_STRATEGY_TYPE_TARGET_CPM` * `YOUTUBE_AND_PARTNERS_BIDDING_STRATEGY_TYPE_RESERVE_CPM` * `YOUTUBE_AND_PARTNERS_BIDDING_STRATEGY_TYPE_TARGET_ROAS` If not using an applicable strategy, the value of this field will be 0.", "format": "int64", "type": "string" } diff --git a/displayvideo/v3/displayvideo-gen.go b/displayvideo/v3/displayvideo-gen.go index c64fd971d40..958217467d6 100644 --- a/displayvideo/v3/displayvideo-gen.go +++ b/displayvideo/v3/displayvideo-gen.go @@ -6562,8 +6562,7 @@ type CreateSdfDownloadTaskRequest struct { // "SDF_VERSION_6" - SDF version 6 // "SDF_VERSION_7" - SDF version 7. Read the [v7 migration // guide](/display-video/api/structured-data-file/v7-migration-guide) - // before migrating to this version. Currently in beta. Only available - // for use by a subset of users. + // before migrating to this version. Version string `json:"version,omitempty"` // ForceSendFields is a list of field names (e.g. "AdvertiserId") to @@ -17123,8 +17122,7 @@ type SdfConfig struct { // "SDF_VERSION_6" - SDF version 6 // "SDF_VERSION_7" - SDF version 7. Read the [v7 migration // guide](/display-video/api/structured-data-file/v7-migration-guide) - // before migrating to this version. Currently in beta. Only available - // for use by a subset of users. + // before migrating to this version. Version string `json:"version,omitempty"` // ForceSendFields is a list of field names (e.g. "AdminEmail") to @@ -17210,8 +17208,7 @@ type SdfDownloadTaskMetadata struct { // "SDF_VERSION_6" - SDF version 6 // "SDF_VERSION_7" - SDF version 7. Read the [v7 migration // guide](/display-video/api/structured-data-file/v7-migration-guide) - // before migrating to this version. Currently in beta. Only available - // for use by a subset of users. + // before migrating to this version. Version string `json:"version,omitempty"` // ForceSendFields is a list of field names (e.g. "CreateTime") to @@ -19170,6 +19167,7 @@ type YoutubeAndPartnersBiddingStrategy struct { // `YOUTUBE_AND_PARTNERS_BIDDING_STRATEGY_TYPE_MANUAL_CPV` * // `YOUTUBE_AND_PARTNERS_BIDDING_STRATEGY_TYPE_TARGET_CPA` * // `YOUTUBE_AND_PARTNERS_BIDDING_STRATEGY_TYPE_TARGET_CPM` * + // `YOUTUBE_AND_PARTNERS_BIDDING_STRATEGY_TYPE_RESERVE_CPM` * // `YOUTUBE_AND_PARTNERS_BIDDING_STRATEGY_TYPE_TARGET_ROAS` If not using // an applicable strategy, the value of this field will be 0. Value int64 `json:"value,omitempty,string"` diff --git a/playdeveloperreporting/v1alpha1/playdeveloperreporting-api.json b/playdeveloperreporting/v1alpha1/playdeveloperreporting-api.json index 325e48c1bf0..a08b38ff939 100644 --- a/playdeveloperreporting/v1alpha1/playdeveloperreporting-api.json +++ b/playdeveloperreporting/v1alpha1/playdeveloperreporting-api.json @@ -535,6 +535,12 @@ "pattern": "^apps/[^/]+$", "required": true, "type": "string" + }, + "sampleErrorReportLimit": { + "description": "Optional. Number of sample error reports to return per ErrorIssue. If unspecified, 0 will be used. *Note:* currently only 0 and 1 are supported.", + "format": "int32", + "location": "query", + "type": "integer" } }, "path": "v1alpha1/{+parent}/errorIssues:search", @@ -559,7 +565,7 @@ ], "parameters": { "filter": { - "description": "A selection predicate to retrieve only a subset of the reports. For filtering basics, please check [AIP-160](https://google.aip.dev/160). ** Supported field names:** * `apiLevel`: Matches error reports that occurred in the requested Android versions (specified as the numeric API level) only. Example: `apiLevel = 28 OR apiLevel = 29`. * `versionCode`: Matches error reports that occurred in the requested app version codes only. Example: `versionCode = 123 OR versionCode = 456`. * `deviceModel`: Matches error issues that occurred in the requested devices. Example: `deviceModel = \"google/walleye\" OR deviceModel = \"google/marlin\"`. * `deviceBrand`: Matches error issues that occurred in the requested device brands. Example: `deviceBrand = \"Google\". * `deviceType`: Matches error reports that occurred in the requested device types. Example: `deviceType = \"PHONE\"`. * `errorIssueType`: Matches error reports of the requested types only. Valid candidates: `JAVA_CRASH`, `NATIVE_CRASH`, `ANR`. Example: `errorIssueType = JAVA_CRASH OR errorIssueType = NATIVE_CRASH`. * `errorIssueId`: Matches error reports belonging to the requested error issue ids only. Example: `errorIssueId = 1234 OR errorIssueId = 4567`. * `appProcessState`: Matches error reports on the process state of an app, indicating whether an app runs in the foreground (user-visible) or background. Valid candidates: `FOREGROUND`, `BACKGROUND`. Example: `appProcessState = FOREGROUND`. * `isUserPerceived`: Matches error reports that are user-perceived. It is not accompanied by any operators. Example: `isUserPerceived`. ** Supported operators:** * Comparison operators: The only supported comparison operator is equality. The filtered field must appear on the left hand side of the comparison. * Logical Operators: Logical operators `AND` and `OR` can be used to build complex filters following a conjunctive normal form (CNF), i.e., conjunctions of disjunctions. The `OR` operator takes precedence over `AND` so the use of parenthesis is not necessary when building CNF. The `OR` operator is only supported to build disjunctions that apply to the same field, e.g., `versionCode = 123 OR versionCode = ANR`. The filter expression `versionCode = 123 OR errorIssueType = ANR` is not valid. ** Examples ** Some valid filtering expressions: * `versionCode = 123 AND errorIssueType = ANR` * `versionCode = 123 AND errorIssueType = OR errorIssueType = CRASH` * `versionCode = 123 AND (errorIssueType = OR errorIssueType = CRASH)`", + "description": "A selection predicate to retrieve only a subset of the reports. For filtering basics, please check [AIP-160](https://google.aip.dev/160). ** Supported field names:** * `apiLevel`: Matches error reports that occurred in the requested Android versions (specified as the numeric API level) only. Example: `apiLevel = 28 OR apiLevel = 29`. * `versionCode`: Matches error reports that occurred in the requested app version codes only. Example: `versionCode = 123 OR versionCode = 456`. * `deviceModel`: Matches error issues that occurred in the requested devices. Example: `deviceModel = \"google/walleye\" OR deviceModel = \"google/marlin\"`. * `deviceBrand`: Matches error issues that occurred in the requested device brands. Example: `deviceBrand = \"Google\". * `deviceType`: Matches error reports that occurred in the requested device types. Example: `deviceType = \"PHONE\"`. * `errorIssueType`: Matches error reports of the requested types only. Valid candidates: `JAVA_CRASH`, `NATIVE_CRASH`, `ANR`. Example: `errorIssueType = JAVA_CRASH OR errorIssueType = NATIVE_CRASH`. * `errorIssueId`: Matches error reports belonging to the requested error issue ids only. Example: `errorIssueId = 1234 OR errorIssueId = 4567`. * `errorReportId`: Matches error reports with the requested error report id. Example: `errorReportId = 1234 OR errorReportId = 4567`. * `appProcessState`: Matches error reports on the process state of an app, indicating whether an app runs in the foreground (user-visible) or background. Valid candidates: `FOREGROUND`, `BACKGROUND`. Example: `appProcessState = FOREGROUND`. * `isUserPerceived`: Matches error reports that are user-perceived. It is not accompanied by any operators. Example: `isUserPerceived`. ** Supported operators:** * Comparison operators: The only supported comparison operator is equality. The filtered field must appear on the left hand side of the comparison. * Logical Operators: Logical operators `AND` and `OR` can be used to build complex filters following a conjunctive normal form (CNF), i.e., conjunctions of disjunctions. The `OR` operator takes precedence over `AND` so the use of parenthesis is not necessary when building CNF. The `OR` operator is only supported to build disjunctions that apply to the same field, e.g., `versionCode = 123 OR versionCode = ANR`. The filter expression `versionCode = 123 OR errorIssueType = ANR` is not valid. ** Examples ** Some valid filtering expressions: * `versionCode = 123 AND errorIssueType = ANR` * `versionCode = 123 AND errorIssueType = OR errorIssueType = CRASH` * `versionCode = 123 AND (errorIssueType = OR errorIssueType = CRASH)`", "location": "query", "type": "string" }, @@ -941,7 +947,7 @@ } } }, - "revision": "20240201", + "revision": "20240306", "rootUrl": "https://playdeveloperreporting.googleapis.com/", "schemas": { "GooglePlayDeveloperReportingV1alpha1Anomaly": { @@ -1178,6 +1184,14 @@ "description": "Identifier. The resource name of the issue. Format: apps/{app}/{issue}", "type": "string" }, + "sampleErrorReports": { + "description": "Output only. Sample error reports which belong to this ErrorIssue. *Note:* currently a maximum of 1 per ErrorIssue is supported. Format: \"apps/{app}/{report}\"", + "items": { + "type": "string" + }, + "readOnly": true, + "type": "array" + }, "type": { "description": "Type of the errors grouped in this issue.", "enum": [ diff --git a/playdeveloperreporting/v1alpha1/playdeveloperreporting-gen.go b/playdeveloperreporting/v1alpha1/playdeveloperreporting-gen.go index ffa7218c436..da04e28b85a 100644 --- a/playdeveloperreporting/v1alpha1/playdeveloperreporting-gen.go +++ b/playdeveloperreporting/v1alpha1/playdeveloperreporting-gen.go @@ -942,6 +942,11 @@ type GooglePlayDeveloperReportingV1alpha1ErrorIssue struct { // apps/{app}/{issue} Name string `json:"name,omitempty"` + // SampleErrorReports: Output only. Sample error reports which belong to + // this ErrorIssue. *Note:* currently a maximum of 1 per ErrorIssue is + // supported. Format: "apps/{app}/{report}" + SampleErrorReports []string `json:"sampleErrorReports,omitempty"` + // Type: Type of the errors grouped in this issue. // // Possible values: @@ -5001,6 +5006,15 @@ func (c *VitalsErrorsIssuesSearchCall) PageToken(pageToken string) *VitalsErrors return c } +// SampleErrorReportLimit sets the optional parameter +// "sampleErrorReportLimit": Number of sample error reports to return +// per ErrorIssue. If unspecified, 0 will be used. *Note:* currently +// only 0 and 1 are supported. +func (c *VitalsErrorsIssuesSearchCall) SampleErrorReportLimit(sampleErrorReportLimit int64) *VitalsErrorsIssuesSearchCall { + c.urlParams_.Set("sampleErrorReportLimit", fmt.Sprint(sampleErrorReportLimit)) + return c +} + // Fields allows partial responses to be retrieved. See // https://developers.google.com/gdata/docs/2.0/basics#PartialResponse // for more information. @@ -5254,6 +5268,12 @@ func (c *VitalsErrorsIssuesSearchCall) Do(opts ...googleapi.CallOption) (*Google // "pattern": "^apps/[^/]+$", // "required": true, // "type": "string" + // }, + // "sampleErrorReportLimit": { + // "description": "Optional. Number of sample error reports to return per ErrorIssue. If unspecified, 0 will be used. *Note:* currently only 0 and 1 are supported.", + // "format": "int32", + // "location": "query", + // "type": "integer" // } // }, // "path": "v1alpha1/{+parent}/errorIssues:search", @@ -5327,7 +5347,9 @@ func (r *VitalsErrorsReportsService) Search(parent string) *VitalsErrorsReportsS // `NATIVE_CRASH`, `ANR`. Example: `errorIssueType = JAVA_CRASH OR // errorIssueType = NATIVE_CRASH`. * `errorIssueId`: Matches error // reports belonging to the requested error issue ids only. Example: -// `errorIssueId = 1234 OR errorIssueId = 4567`. * `appProcessState`: +// `errorIssueId = 1234 OR errorIssueId = 4567`. * `errorReportId`: +// Matches error reports with the requested error report id. Example: +// `errorReportId = 1234 OR errorReportId = 4567`. * `appProcessState`: // Matches error reports on the process state of an app, indicating // whether an app runs in the foreground (user-visible) or background. // Valid candidates: `FOREGROUND`, `BACKGROUND`. Example: @@ -5650,7 +5672,7 @@ func (c *VitalsErrorsReportsSearchCall) Do(opts ...googleapi.CallOption) (*Googl // ], // "parameters": { // "filter": { - // "description": "A selection predicate to retrieve only a subset of the reports. For filtering basics, please check [AIP-160](https://google.aip.dev/160). ** Supported field names:** * `apiLevel`: Matches error reports that occurred in the requested Android versions (specified as the numeric API level) only. Example: `apiLevel = 28 OR apiLevel = 29`. * `versionCode`: Matches error reports that occurred in the requested app version codes only. Example: `versionCode = 123 OR versionCode = 456`. * `deviceModel`: Matches error issues that occurred in the requested devices. Example: `deviceModel = \"google/walleye\" OR deviceModel = \"google/marlin\"`. * `deviceBrand`: Matches error issues that occurred in the requested device brands. Example: `deviceBrand = \"Google\". * `deviceType`: Matches error reports that occurred in the requested device types. Example: `deviceType = \"PHONE\"`. * `errorIssueType`: Matches error reports of the requested types only. Valid candidates: `JAVA_CRASH`, `NATIVE_CRASH`, `ANR`. Example: `errorIssueType = JAVA_CRASH OR errorIssueType = NATIVE_CRASH`. * `errorIssueId`: Matches error reports belonging to the requested error issue ids only. Example: `errorIssueId = 1234 OR errorIssueId = 4567`. * `appProcessState`: Matches error reports on the process state of an app, indicating whether an app runs in the foreground (user-visible) or background. Valid candidates: `FOREGROUND`, `BACKGROUND`. Example: `appProcessState = FOREGROUND`. * `isUserPerceived`: Matches error reports that are user-perceived. It is not accompanied by any operators. Example: `isUserPerceived`. ** Supported operators:** * Comparison operators: The only supported comparison operator is equality. The filtered field must appear on the left hand side of the comparison. * Logical Operators: Logical operators `AND` and `OR` can be used to build complex filters following a conjunctive normal form (CNF), i.e., conjunctions of disjunctions. The `OR` operator takes precedence over `AND` so the use of parenthesis is not necessary when building CNF. The `OR` operator is only supported to build disjunctions that apply to the same field, e.g., `versionCode = 123 OR versionCode = ANR`. The filter expression `versionCode = 123 OR errorIssueType = ANR` is not valid. ** Examples ** Some valid filtering expressions: * `versionCode = 123 AND errorIssueType = ANR` * `versionCode = 123 AND errorIssueType = OR errorIssueType = CRASH` * `versionCode = 123 AND (errorIssueType = OR errorIssueType = CRASH)`", + // "description": "A selection predicate to retrieve only a subset of the reports. For filtering basics, please check [AIP-160](https://google.aip.dev/160). ** Supported field names:** * `apiLevel`: Matches error reports that occurred in the requested Android versions (specified as the numeric API level) only. Example: `apiLevel = 28 OR apiLevel = 29`. * `versionCode`: Matches error reports that occurred in the requested app version codes only. Example: `versionCode = 123 OR versionCode = 456`. * `deviceModel`: Matches error issues that occurred in the requested devices. Example: `deviceModel = \"google/walleye\" OR deviceModel = \"google/marlin\"`. * `deviceBrand`: Matches error issues that occurred in the requested device brands. Example: `deviceBrand = \"Google\". * `deviceType`: Matches error reports that occurred in the requested device types. Example: `deviceType = \"PHONE\"`. * `errorIssueType`: Matches error reports of the requested types only. Valid candidates: `JAVA_CRASH`, `NATIVE_CRASH`, `ANR`. Example: `errorIssueType = JAVA_CRASH OR errorIssueType = NATIVE_CRASH`. * `errorIssueId`: Matches error reports belonging to the requested error issue ids only. Example: `errorIssueId = 1234 OR errorIssueId = 4567`. * `errorReportId`: Matches error reports with the requested error report id. Example: `errorReportId = 1234 OR errorReportId = 4567`. * `appProcessState`: Matches error reports on the process state of an app, indicating whether an app runs in the foreground (user-visible) or background. Valid candidates: `FOREGROUND`, `BACKGROUND`. Example: `appProcessState = FOREGROUND`. * `isUserPerceived`: Matches error reports that are user-perceived. It is not accompanied by any operators. Example: `isUserPerceived`. ** Supported operators:** * Comparison operators: The only supported comparison operator is equality. The filtered field must appear on the left hand side of the comparison. * Logical Operators: Logical operators `AND` and `OR` can be used to build complex filters following a conjunctive normal form (CNF), i.e., conjunctions of disjunctions. The `OR` operator takes precedence over `AND` so the use of parenthesis is not necessary when building CNF. The `OR` operator is only supported to build disjunctions that apply to the same field, e.g., `versionCode = 123 OR versionCode = ANR`. The filter expression `versionCode = 123 OR errorIssueType = ANR` is not valid. ** Examples ** Some valid filtering expressions: * `versionCode = 123 AND errorIssueType = ANR` * `versionCode = 123 AND errorIssueType = OR errorIssueType = CRASH` * `versionCode = 123 AND (errorIssueType = OR errorIssueType = CRASH)`", // "location": "query", // "type": "string" // }, diff --git a/playdeveloperreporting/v1beta1/playdeveloperreporting-api.json b/playdeveloperreporting/v1beta1/playdeveloperreporting-api.json index 62d651d9e6a..9d349e573fd 100644 --- a/playdeveloperreporting/v1beta1/playdeveloperreporting-api.json +++ b/playdeveloperreporting/v1beta1/playdeveloperreporting-api.json @@ -535,6 +535,12 @@ "pattern": "^apps/[^/]+$", "required": true, "type": "string" + }, + "sampleErrorReportLimit": { + "description": "Optional. Number of sample error reports to return per ErrorIssue. If unspecified, 0 will be used. *Note:* currently only 0 and 1 are supported.", + "format": "int32", + "location": "query", + "type": "integer" } }, "path": "v1beta1/{+parent}/errorIssues:search", @@ -559,7 +565,7 @@ ], "parameters": { "filter": { - "description": "A selection predicate to retrieve only a subset of the reports. For filtering basics, please check [AIP-160](https://google.aip.dev/160). ** Supported field names:** * `apiLevel`: Matches error reports that occurred in the requested Android versions (specified as the numeric API level) only. Example: `apiLevel = 28 OR apiLevel = 29`. * `versionCode`: Matches error reports that occurred in the requested app version codes only. Example: `versionCode = 123 OR versionCode = 456`. * `deviceModel`: Matches error issues that occurred in the requested devices. Example: `deviceModel = \"google/walleye\" OR deviceModel = \"google/marlin\"`. * `deviceBrand`: Matches error issues that occurred in the requested device brands. Example: `deviceBrand = \"Google\". * `deviceType`: Matches error reports that occurred in the requested device types. Example: `deviceType = \"PHONE\"`. * `errorIssueType`: Matches error reports of the requested types only. Valid candidates: `JAVA_CRASH`, `NATIVE_CRASH`, `ANR`. Example: `errorIssueType = JAVA_CRASH OR errorIssueType = NATIVE_CRASH`. * `errorIssueId`: Matches error reports belonging to the requested error issue ids only. Example: `errorIssueId = 1234 OR errorIssueId = 4567`. * `appProcessState`: Matches error reports on the process state of an app, indicating whether an app runs in the foreground (user-visible) or background. Valid candidates: `FOREGROUND`, `BACKGROUND`. Example: `appProcessState = FOREGROUND`. * `isUserPerceived`: Matches error reports that are user-perceived. It is not accompanied by any operators. Example: `isUserPerceived`. ** Supported operators:** * Comparison operators: The only supported comparison operator is equality. The filtered field must appear on the left hand side of the comparison. * Logical Operators: Logical operators `AND` and `OR` can be used to build complex filters following a conjunctive normal form (CNF), i.e., conjunctions of disjunctions. The `OR` operator takes precedence over `AND` so the use of parenthesis is not necessary when building CNF. The `OR` operator is only supported to build disjunctions that apply to the same field, e.g., `versionCode = 123 OR versionCode = ANR`. The filter expression `versionCode = 123 OR errorIssueType = ANR` is not valid. ** Examples ** Some valid filtering expressions: * `versionCode = 123 AND errorIssueType = ANR` * `versionCode = 123 AND errorIssueType = OR errorIssueType = CRASH` * `versionCode = 123 AND (errorIssueType = OR errorIssueType = CRASH)`", + "description": "A selection predicate to retrieve only a subset of the reports. For filtering basics, please check [AIP-160](https://google.aip.dev/160). ** Supported field names:** * `apiLevel`: Matches error reports that occurred in the requested Android versions (specified as the numeric API level) only. Example: `apiLevel = 28 OR apiLevel = 29`. * `versionCode`: Matches error reports that occurred in the requested app version codes only. Example: `versionCode = 123 OR versionCode = 456`. * `deviceModel`: Matches error issues that occurred in the requested devices. Example: `deviceModel = \"google/walleye\" OR deviceModel = \"google/marlin\"`. * `deviceBrand`: Matches error issues that occurred in the requested device brands. Example: `deviceBrand = \"Google\". * `deviceType`: Matches error reports that occurred in the requested device types. Example: `deviceType = \"PHONE\"`. * `errorIssueType`: Matches error reports of the requested types only. Valid candidates: `JAVA_CRASH`, `NATIVE_CRASH`, `ANR`. Example: `errorIssueType = JAVA_CRASH OR errorIssueType = NATIVE_CRASH`. * `errorIssueId`: Matches error reports belonging to the requested error issue ids only. Example: `errorIssueId = 1234 OR errorIssueId = 4567`. * `errorReportId`: Matches error reports with the requested error report id. Example: `errorReportId = 1234 OR errorReportId = 4567`. * `appProcessState`: Matches error reports on the process state of an app, indicating whether an app runs in the foreground (user-visible) or background. Valid candidates: `FOREGROUND`, `BACKGROUND`. Example: `appProcessState = FOREGROUND`. * `isUserPerceived`: Matches error reports that are user-perceived. It is not accompanied by any operators. Example: `isUserPerceived`. ** Supported operators:** * Comparison operators: The only supported comparison operator is equality. The filtered field must appear on the left hand side of the comparison. * Logical Operators: Logical operators `AND` and `OR` can be used to build complex filters following a conjunctive normal form (CNF), i.e., conjunctions of disjunctions. The `OR` operator takes precedence over `AND` so the use of parenthesis is not necessary when building CNF. The `OR` operator is only supported to build disjunctions that apply to the same field, e.g., `versionCode = 123 OR versionCode = ANR`. The filter expression `versionCode = 123 OR errorIssueType = ANR` is not valid. ** Examples ** Some valid filtering expressions: * `versionCode = 123 AND errorIssueType = ANR` * `versionCode = 123 AND errorIssueType = OR errorIssueType = CRASH` * `versionCode = 123 AND (errorIssueType = OR errorIssueType = CRASH)`", "location": "query", "type": "string" }, @@ -941,7 +947,7 @@ } } }, - "revision": "20240201", + "revision": "20240306", "rootUrl": "https://playdeveloperreporting.googleapis.com/", "schemas": { "GooglePlayDeveloperReportingV1beta1Anomaly": { @@ -1178,6 +1184,14 @@ "description": "Identifier. The resource name of the issue. Format: apps/{app}/{issue}", "type": "string" }, + "sampleErrorReports": { + "description": "Output only. Sample error reports which belong to this ErrorIssue. *Note:* currently a maximum of 1 per ErrorIssue is supported. Format: \"apps/{app}/{report}\"", + "items": { + "type": "string" + }, + "readOnly": true, + "type": "array" + }, "type": { "description": "Type of the errors grouped in this issue.", "enum": [ diff --git a/playdeveloperreporting/v1beta1/playdeveloperreporting-gen.go b/playdeveloperreporting/v1beta1/playdeveloperreporting-gen.go index b4501a7eba3..10885a1fe59 100644 --- a/playdeveloperreporting/v1beta1/playdeveloperreporting-gen.go +++ b/playdeveloperreporting/v1beta1/playdeveloperreporting-gen.go @@ -942,6 +942,11 @@ type GooglePlayDeveloperReportingV1beta1ErrorIssue struct { // apps/{app}/{issue} Name string `json:"name,omitempty"` + // SampleErrorReports: Output only. Sample error reports which belong to + // this ErrorIssue. *Note:* currently a maximum of 1 per ErrorIssue is + // supported. Format: "apps/{app}/{report}" + SampleErrorReports []string `json:"sampleErrorReports,omitempty"` + // Type: Type of the errors grouped in this issue. // // Possible values: @@ -5001,6 +5006,15 @@ func (c *VitalsErrorsIssuesSearchCall) PageToken(pageToken string) *VitalsErrors return c } +// SampleErrorReportLimit sets the optional parameter +// "sampleErrorReportLimit": Number of sample error reports to return +// per ErrorIssue. If unspecified, 0 will be used. *Note:* currently +// only 0 and 1 are supported. +func (c *VitalsErrorsIssuesSearchCall) SampleErrorReportLimit(sampleErrorReportLimit int64) *VitalsErrorsIssuesSearchCall { + c.urlParams_.Set("sampleErrorReportLimit", fmt.Sprint(sampleErrorReportLimit)) + return c +} + // Fields allows partial responses to be retrieved. See // https://developers.google.com/gdata/docs/2.0/basics#PartialResponse // for more information. @@ -5254,6 +5268,12 @@ func (c *VitalsErrorsIssuesSearchCall) Do(opts ...googleapi.CallOption) (*Google // "pattern": "^apps/[^/]+$", // "required": true, // "type": "string" + // }, + // "sampleErrorReportLimit": { + // "description": "Optional. Number of sample error reports to return per ErrorIssue. If unspecified, 0 will be used. *Note:* currently only 0 and 1 are supported.", + // "format": "int32", + // "location": "query", + // "type": "integer" // } // }, // "path": "v1beta1/{+parent}/errorIssues:search", @@ -5327,7 +5347,9 @@ func (r *VitalsErrorsReportsService) Search(parent string) *VitalsErrorsReportsS // `NATIVE_CRASH`, `ANR`. Example: `errorIssueType = JAVA_CRASH OR // errorIssueType = NATIVE_CRASH`. * `errorIssueId`: Matches error // reports belonging to the requested error issue ids only. Example: -// `errorIssueId = 1234 OR errorIssueId = 4567`. * `appProcessState`: +// `errorIssueId = 1234 OR errorIssueId = 4567`. * `errorReportId`: +// Matches error reports with the requested error report id. Example: +// `errorReportId = 1234 OR errorReportId = 4567`. * `appProcessState`: // Matches error reports on the process state of an app, indicating // whether an app runs in the foreground (user-visible) or background. // Valid candidates: `FOREGROUND`, `BACKGROUND`. Example: @@ -5650,7 +5672,7 @@ func (c *VitalsErrorsReportsSearchCall) Do(opts ...googleapi.CallOption) (*Googl // ], // "parameters": { // "filter": { - // "description": "A selection predicate to retrieve only a subset of the reports. For filtering basics, please check [AIP-160](https://google.aip.dev/160). ** Supported field names:** * `apiLevel`: Matches error reports that occurred in the requested Android versions (specified as the numeric API level) only. Example: `apiLevel = 28 OR apiLevel = 29`. * `versionCode`: Matches error reports that occurred in the requested app version codes only. Example: `versionCode = 123 OR versionCode = 456`. * `deviceModel`: Matches error issues that occurred in the requested devices. Example: `deviceModel = \"google/walleye\" OR deviceModel = \"google/marlin\"`. * `deviceBrand`: Matches error issues that occurred in the requested device brands. Example: `deviceBrand = \"Google\". * `deviceType`: Matches error reports that occurred in the requested device types. Example: `deviceType = \"PHONE\"`. * `errorIssueType`: Matches error reports of the requested types only. Valid candidates: `JAVA_CRASH`, `NATIVE_CRASH`, `ANR`. Example: `errorIssueType = JAVA_CRASH OR errorIssueType = NATIVE_CRASH`. * `errorIssueId`: Matches error reports belonging to the requested error issue ids only. Example: `errorIssueId = 1234 OR errorIssueId = 4567`. * `appProcessState`: Matches error reports on the process state of an app, indicating whether an app runs in the foreground (user-visible) or background. Valid candidates: `FOREGROUND`, `BACKGROUND`. Example: `appProcessState = FOREGROUND`. * `isUserPerceived`: Matches error reports that are user-perceived. It is not accompanied by any operators. Example: `isUserPerceived`. ** Supported operators:** * Comparison operators: The only supported comparison operator is equality. The filtered field must appear on the left hand side of the comparison. * Logical Operators: Logical operators `AND` and `OR` can be used to build complex filters following a conjunctive normal form (CNF), i.e., conjunctions of disjunctions. The `OR` operator takes precedence over `AND` so the use of parenthesis is not necessary when building CNF. The `OR` operator is only supported to build disjunctions that apply to the same field, e.g., `versionCode = 123 OR versionCode = ANR`. The filter expression `versionCode = 123 OR errorIssueType = ANR` is not valid. ** Examples ** Some valid filtering expressions: * `versionCode = 123 AND errorIssueType = ANR` * `versionCode = 123 AND errorIssueType = OR errorIssueType = CRASH` * `versionCode = 123 AND (errorIssueType = OR errorIssueType = CRASH)`", + // "description": "A selection predicate to retrieve only a subset of the reports. For filtering basics, please check [AIP-160](https://google.aip.dev/160). ** Supported field names:** * `apiLevel`: Matches error reports that occurred in the requested Android versions (specified as the numeric API level) only. Example: `apiLevel = 28 OR apiLevel = 29`. * `versionCode`: Matches error reports that occurred in the requested app version codes only. Example: `versionCode = 123 OR versionCode = 456`. * `deviceModel`: Matches error issues that occurred in the requested devices. Example: `deviceModel = \"google/walleye\" OR deviceModel = \"google/marlin\"`. * `deviceBrand`: Matches error issues that occurred in the requested device brands. Example: `deviceBrand = \"Google\". * `deviceType`: Matches error reports that occurred in the requested device types. Example: `deviceType = \"PHONE\"`. * `errorIssueType`: Matches error reports of the requested types only. Valid candidates: `JAVA_CRASH`, `NATIVE_CRASH`, `ANR`. Example: `errorIssueType = JAVA_CRASH OR errorIssueType = NATIVE_CRASH`. * `errorIssueId`: Matches error reports belonging to the requested error issue ids only. Example: `errorIssueId = 1234 OR errorIssueId = 4567`. * `errorReportId`: Matches error reports with the requested error report id. Example: `errorReportId = 1234 OR errorReportId = 4567`. * `appProcessState`: Matches error reports on the process state of an app, indicating whether an app runs in the foreground (user-visible) or background. Valid candidates: `FOREGROUND`, `BACKGROUND`. Example: `appProcessState = FOREGROUND`. * `isUserPerceived`: Matches error reports that are user-perceived. It is not accompanied by any operators. Example: `isUserPerceived`. ** Supported operators:** * Comparison operators: The only supported comparison operator is equality. The filtered field must appear on the left hand side of the comparison. * Logical Operators: Logical operators `AND` and `OR` can be used to build complex filters following a conjunctive normal form (CNF), i.e., conjunctions of disjunctions. The `OR` operator takes precedence over `AND` so the use of parenthesis is not necessary when building CNF. The `OR` operator is only supported to build disjunctions that apply to the same field, e.g., `versionCode = 123 OR versionCode = ANR`. The filter expression `versionCode = 123 OR errorIssueType = ANR` is not valid. ** Examples ** Some valid filtering expressions: * `versionCode = 123 AND errorIssueType = ANR` * `versionCode = 123 AND errorIssueType = OR errorIssueType = CRASH` * `versionCode = 123 AND (errorIssueType = OR errorIssueType = CRASH)`", // "location": "query", // "type": "string" // }, diff --git a/run/v2/run-api.json b/run/v2/run-api.json index 8f27eb5628a..32cd45037e9 100644 --- a/run/v2/run-api.json +++ b/run/v2/run-api.json @@ -1317,7 +1317,7 @@ } } }, - "revision": "20240211", + "revision": "20240303", "rootUrl": "https://run.googleapis.com/", "schemas": { "GoogleCloudRunV2BinaryAuthorization": { @@ -2957,7 +2957,7 @@ "id": "GoogleCloudRunV2ServiceScaling", "properties": { "minInstanceCount": { - "description": "total min instances for the service. This number of instances is divided among all revisions with specified traffic based on the percent of traffic they are receiving. (ALPHA)", + "description": "total min instances for the service. This number of instances is divided among all revisions with specified traffic based on the percent of traffic they are receiving. (BETA)", "format": "int32", "type": "integer" } @@ -3415,6 +3415,1278 @@ }, "type": "object" }, + "GoogleDevtoolsCloudbuildV1ApprovalConfig": { + "description": "ApprovalConfig describes configuration for manual approval of a build.", + "id": "GoogleDevtoolsCloudbuildV1ApprovalConfig", + "properties": { + "approvalRequired": { + "description": "Whether or not approval is needed. If this is set on a build, it will become pending when created, and will need to be explicitly approved to start.", + "type": "boolean" + } + }, + "type": "object" + }, + "GoogleDevtoolsCloudbuildV1ApprovalResult": { + "description": "ApprovalResult describes the decision and associated metadata of a manual approval of a build.", + "id": "GoogleDevtoolsCloudbuildV1ApprovalResult", + "properties": { + "approvalTime": { + "description": "Output only. The time when the approval decision was made.", + "format": "google-datetime", + "readOnly": true, + "type": "string" + }, + "approverAccount": { + "description": "Output only. Email of the user that called the ApproveBuild API to approve or reject a build at the time that the API was called.", + "readOnly": true, + "type": "string" + }, + "comment": { + "description": "Optional. An optional comment for this manual approval result.", + "type": "string" + }, + "decision": { + "description": "Required. The decision of this manual approval.", + "enum": [ + "DECISION_UNSPECIFIED", + "APPROVED", + "REJECTED" + ], + "enumDescriptions": [ + "Default enum type. This should not be used.", + "Build is approved.", + "Build is rejected." + ], + "type": "string" + }, + "url": { + "description": "Optional. An optional URL tied to this manual approval result. This field is essentially the same as comment, except that it will be rendered by the UI differently. An example use case is a link to an external job that approved this Build.", + "type": "string" + } + }, + "type": "object" + }, + "GoogleDevtoolsCloudbuildV1ArtifactObjects": { + "description": "Files in the workspace to upload to Cloud Storage upon successful completion of all build steps.", + "id": "GoogleDevtoolsCloudbuildV1ArtifactObjects", + "properties": { + "location": { + "description": "Cloud Storage bucket and optional object path, in the form \"gs://bucket/path/to/somewhere/\". (see [Bucket Name Requirements](https://cloud.google.com/storage/docs/bucket-naming#requirements)). Files in the workspace matching any path pattern will be uploaded to Cloud Storage with this location as a prefix.", + "type": "string" + }, + "paths": { + "description": "Path globs used to match files in the build's workspace.", + "items": { + "type": "string" + }, + "type": "array" + }, + "timing": { + "$ref": "GoogleDevtoolsCloudbuildV1TimeSpan", + "description": "Output only. Stores timing information for pushing all artifact objects.", + "readOnly": true + } + }, + "type": "object" + }, + "GoogleDevtoolsCloudbuildV1Artifacts": { + "description": "Artifacts produced by a build that should be uploaded upon successful completion of all build steps.", + "id": "GoogleDevtoolsCloudbuildV1Artifacts", + "properties": { + "images": { + "description": "A list of images to be pushed upon the successful completion of all build steps. The images will be pushed using the builder service account's credentials. The digests of the pushed images will be stored in the Build resource's results field. If any of the images fail to be pushed, the build is marked FAILURE.", + "items": { + "type": "string" + }, + "type": "array" + }, + "mavenArtifacts": { + "description": "A list of Maven artifacts to be uploaded to Artifact Registry upon successful completion of all build steps. Artifacts in the workspace matching specified paths globs will be uploaded to the specified Artifact Registry repository using the builder service account's credentials. If any artifacts fail to be pushed, the build is marked FAILURE.", + "items": { + "$ref": "GoogleDevtoolsCloudbuildV1MavenArtifact" + }, + "type": "array" + }, + "npmPackages": { + "description": "A list of npm packages to be uploaded to Artifact Registry upon successful completion of all build steps. Npm packages in the specified paths will be uploaded to the specified Artifact Registry repository using the builder service account's credentials. If any packages fail to be pushed, the build is marked FAILURE.", + "items": { + "$ref": "GoogleDevtoolsCloudbuildV1NpmPackage" + }, + "type": "array" + }, + "objects": { + "$ref": "GoogleDevtoolsCloudbuildV1ArtifactObjects", + "description": "A list of objects to be uploaded to Cloud Storage upon successful completion of all build steps. Files in the workspace matching specified paths globs will be uploaded to the specified Cloud Storage location using the builder service account's credentials. The location and generation of the uploaded objects will be stored in the Build resource's results field. If any objects fail to be pushed, the build is marked FAILURE." + }, + "pythonPackages": { + "description": "A list of Python packages to be uploaded to Artifact Registry upon successful completion of all build steps. The build service account credentials will be used to perform the upload. If any objects fail to be pushed, the build is marked FAILURE.", + "items": { + "$ref": "GoogleDevtoolsCloudbuildV1PythonPackage" + }, + "type": "array" + } + }, + "type": "object" + }, + "GoogleDevtoolsCloudbuildV1Build": { + "description": "A build resource in the Cloud Build API. At a high level, a `Build` describes where to find source code, how to build it (for example, the builder image to run on the source), and where to store the built artifacts. Fields can include the following variables, which will be expanded when the build is created: - $PROJECT_ID: the project ID of the build. - $PROJECT_NUMBER: the project number of the build. - $LOCATION: the location/region of the build. - $BUILD_ID: the autogenerated ID of the build. - $REPO_NAME: the source repository name specified by RepoSource. - $BRANCH_NAME: the branch name specified by RepoSource. - $TAG_NAME: the tag name specified by RepoSource. - $REVISION_ID or $COMMIT_SHA: the commit SHA specified by RepoSource or resolved from the specified branch or tag. - $SHORT_SHA: first 7 characters of $REVISION_ID or $COMMIT_SHA.", + "id": "GoogleDevtoolsCloudbuildV1Build", + "properties": { + "approval": { + "$ref": "GoogleDevtoolsCloudbuildV1BuildApproval", + "description": "Output only. Describes this build's approval configuration, status, and result.", + "readOnly": true + }, + "artifacts": { + "$ref": "GoogleDevtoolsCloudbuildV1Artifacts", + "description": "Artifacts produced by the build that should be uploaded upon successful completion of all build steps." + }, + "availableSecrets": { + "$ref": "GoogleDevtoolsCloudbuildV1Secrets", + "description": "Secrets and secret environment variables." + }, + "buildTriggerId": { + "description": "Output only. The ID of the `BuildTrigger` that triggered this build, if it was triggered automatically.", + "readOnly": true, + "type": "string" + }, + "createTime": { + "description": "Output only. Time at which the request to create the build was received.", + "format": "google-datetime", + "readOnly": true, + "type": "string" + }, + "failureInfo": { + "$ref": "GoogleDevtoolsCloudbuildV1FailureInfo", + "description": "Output only. Contains information about the build when status=FAILURE.", + "readOnly": true + }, + "finishTime": { + "description": "Output only. Time at which execution of the build was finished. The difference between finish_time and start_time is the duration of the build's execution.", + "format": "google-datetime", + "readOnly": true, + "type": "string" + }, + "id": { + "description": "Output only. Unique identifier of the build.", + "readOnly": true, + "type": "string" + }, + "images": { + "description": "A list of images to be pushed upon the successful completion of all build steps. The images are pushed using the builder service account's credentials. The digests of the pushed images will be stored in the `Build` resource's results field. If any of the images fail to be pushed, the build status is marked `FAILURE`.", + "items": { + "type": "string" + }, + "type": "array" + }, + "logUrl": { + "description": "Output only. URL to logs for this build in Google Cloud Console.", + "readOnly": true, + "type": "string" + }, + "logsBucket": { + "description": "Cloud Storage bucket where logs should be written (see [Bucket Name Requirements](https://cloud.google.com/storage/docs/bucket-naming#requirements)). Logs file names will be of the format `${logs_bucket}/log-${build_id}.txt`.", + "type": "string" + }, + "name": { + "description": "Output only. The 'Build' name with format: `projects/{project}/locations/{location}/builds/{build}`, where {build} is a unique identifier generated by the service.", + "readOnly": true, + "type": "string" + }, + "options": { + "$ref": "GoogleDevtoolsCloudbuildV1BuildOptions", + "description": "Special options for this build." + }, + "projectId": { + "description": "Output only. ID of the project.", + "readOnly": true, + "type": "string" + }, + "queueTtl": { + "description": "TTL in queue for this build. If provided and the build is enqueued longer than this value, the build will expire and the build status will be `EXPIRED`. The TTL starts ticking from create_time.", + "format": "google-duration", + "type": "string" + }, + "results": { + "$ref": "GoogleDevtoolsCloudbuildV1Results", + "description": "Output only. Results of the build.", + "readOnly": true + }, + "secrets": { + "description": "Secrets to decrypt using Cloud Key Management Service. Note: Secret Manager is the recommended technique for managing sensitive data with Cloud Build. Use `available_secrets` to configure builds to access secrets from Secret Manager. For instructions, see: https://cloud.google.com/cloud-build/docs/securing-builds/use-secrets", + "items": { + "$ref": "GoogleDevtoolsCloudbuildV1Secret" + }, + "type": "array" + }, + "serviceAccount": { + "description": "IAM service account whose credentials will be used at build runtime. Must be of the format `projects/{PROJECT_ID}/serviceAccounts/{ACCOUNT}`. ACCOUNT can be email address or uniqueId of the service account. ", + "type": "string" + }, + "source": { + "$ref": "GoogleDevtoolsCloudbuildV1Source", + "description": "The location of the source files to build." + }, + "sourceProvenance": { + "$ref": "GoogleDevtoolsCloudbuildV1SourceProvenance", + "description": "Output only. A permanent fixed identifier for source.", + "readOnly": true + }, + "startTime": { + "description": "Output only. Time at which execution of the build was started.", + "format": "google-datetime", + "readOnly": true, + "type": "string" + }, + "status": { + "description": "Output only. Status of the build.", + "enum": [ + "STATUS_UNKNOWN", + "PENDING", + "QUEUED", + "WORKING", + "SUCCESS", + "FAILURE", + "INTERNAL_ERROR", + "TIMEOUT", + "CANCELLED", + "EXPIRED" + ], + "enumDescriptions": [ + "Status of the build is unknown.", + "Build has been created and is pending execution and queuing. It has not been queued.", + "Build or step is queued; work has not yet begun.", + "Build or step is being executed.", + "Build or step finished successfully.", + "Build or step failed to complete successfully.", + "Build or step failed due to an internal cause.", + "Build or step took longer than was allowed.", + "Build or step was canceled by a user.", + "Build was enqueued for longer than the value of `queue_ttl`." + ], + "readOnly": true, + "type": "string" + }, + "statusDetail": { + "description": "Output only. Customer-readable message about the current status.", + "readOnly": true, + "type": "string" + }, + "steps": { + "description": "Required. The operations to be performed on the workspace.", + "items": { + "$ref": "GoogleDevtoolsCloudbuildV1BuildStep" + }, + "type": "array" + }, + "substitutions": { + "additionalProperties": { + "type": "string" + }, + "description": "Substitutions data for `Build` resource.", + "type": "object" + }, + "tags": { + "description": "Tags for annotation of a `Build`. These are not docker tags.", + "items": { + "type": "string" + }, + "type": "array" + }, + "timeout": { + "description": "Amount of time that this build should be allowed to run, to second granularity. If this amount of time elapses, work on the build will cease and the build status will be `TIMEOUT`. `timeout` starts ticking from `startTime`. Default time is 60 minutes.", + "format": "google-duration", + "type": "string" + }, + "timing": { + "additionalProperties": { + "$ref": "GoogleDevtoolsCloudbuildV1TimeSpan" + }, + "description": "Output only. Stores timing information for phases of the build. Valid keys are: * BUILD: time to execute all build steps. * PUSH: time to push all artifacts including docker images and non docker artifacts. * FETCHSOURCE: time to fetch source. * SETUPBUILD: time to set up build. If the build does not specify source or images, these keys will not be included.", + "readOnly": true, + "type": "object" + }, + "warnings": { + "description": "Output only. Non-fatal problems encountered during the execution of the build.", + "items": { + "$ref": "GoogleDevtoolsCloudbuildV1Warning" + }, + "readOnly": true, + "type": "array" + } + }, + "type": "object" + }, + "GoogleDevtoolsCloudbuildV1BuildApproval": { + "description": "BuildApproval describes a build's approval configuration, state, and result.", + "id": "GoogleDevtoolsCloudbuildV1BuildApproval", + "properties": { + "config": { + "$ref": "GoogleDevtoolsCloudbuildV1ApprovalConfig", + "description": "Output only. Configuration for manual approval of this build.", + "readOnly": true + }, + "result": { + "$ref": "GoogleDevtoolsCloudbuildV1ApprovalResult", + "description": "Output only. Result of manual approval for this Build.", + "readOnly": true + }, + "state": { + "description": "Output only. The state of this build's approval.", + "enum": [ + "STATE_UNSPECIFIED", + "PENDING", + "APPROVED", + "REJECTED", + "CANCELLED" + ], + "enumDescriptions": [ + "Default enum type. This should not be used.", + "Build approval is pending.", + "Build approval has been approved.", + "Build approval has been rejected.", + "Build was cancelled while it was still pending approval." + ], + "readOnly": true, + "type": "string" + } + }, + "type": "object" + }, + "GoogleDevtoolsCloudbuildV1BuildOperationMetadata": { + "description": "Metadata for build operations.", + "id": "GoogleDevtoolsCloudbuildV1BuildOperationMetadata", + "properties": { + "build": { + "$ref": "GoogleDevtoolsCloudbuildV1Build", + "description": "The build that the operation is tracking." + } + }, + "type": "object" + }, + "GoogleDevtoolsCloudbuildV1BuildOptions": { + "description": "Optional arguments to enable specific features of builds.", + "id": "GoogleDevtoolsCloudbuildV1BuildOptions", + "properties": { + "automapSubstitutions": { + "description": "Option to include built-in and custom substitutions as env variables for all build steps.", + "type": "boolean" + }, + "defaultLogsBucketBehavior": { + "description": "Optional. Option to specify how default logs buckets are setup.", + "enum": [ + "DEFAULT_LOGS_BUCKET_BEHAVIOR_UNSPECIFIED", + "REGIONAL_USER_OWNED_BUCKET" + ], + "enumDescriptions": [ + "Unspecified.", + "Bucket is located in user-owned project in the same region as the build. The builder service account must have access to create and write to Cloud Storage buckets in the build project." + ], + "type": "string" + }, + "diskSizeGb": { + "description": "Requested disk size for the VM that runs the build. Note that this is *NOT* \"disk free\"; some of the space will be used by the operating system and build utilities. Also note that this is the minimum disk size that will be allocated for the build -- the build may run with a larger disk than requested. At present, the maximum disk size is 2000GB; builds that request more than the maximum are rejected with an error.", + "format": "int64", + "type": "string" + }, + "dynamicSubstitutions": { + "description": "Option to specify whether or not to apply bash style string operations to the substitutions. NOTE: this is always enabled for triggered builds and cannot be overridden in the build configuration file.", + "type": "boolean" + }, + "env": { + "description": "A list of global environment variable definitions that will exist for all build steps in this build. If a variable is defined in both globally and in a build step, the variable will use the build step value. The elements are of the form \"KEY=VALUE\" for the environment variable \"KEY\" being given the value \"VALUE\".", + "items": { + "type": "string" + }, + "type": "array" + }, + "logStreamingOption": { + "description": "Option to define build log streaming behavior to Cloud Storage.", + "enum": [ + "STREAM_DEFAULT", + "STREAM_ON", + "STREAM_OFF" + ], + "enumDescriptions": [ + "Service may automatically determine build log streaming behavior.", + "Build logs should be streamed to Cloud Storage.", + "Build logs should not be streamed to Cloud Storage; they will be written when the build is completed." + ], + "type": "string" + }, + "logging": { + "description": "Option to specify the logging mode, which determines if and where build logs are stored.", + "enum": [ + "LOGGING_UNSPECIFIED", + "LEGACY", + "GCS_ONLY", + "STACKDRIVER_ONLY", + "CLOUD_LOGGING_ONLY", + "NONE" + ], + "enumDeprecated": [ + false, + false, + false, + true, + false, + false + ], + "enumDescriptions": [ + "The service determines the logging mode. The default is `LEGACY`. Do not rely on the default logging behavior as it may change in the future.", + "Build logs are stored in Cloud Logging and Cloud Storage.", + "Build logs are stored in Cloud Storage.", + "This option is the same as CLOUD_LOGGING_ONLY.", + "Build logs are stored in Cloud Logging. Selecting this option will not allow [logs streaming](https://cloud.google.com/sdk/gcloud/reference/builds/log).", + "Turn off all logging. No build logs will be captured." + ], + "type": "string" + }, + "machineType": { + "description": "Compute Engine machine type on which to run the build.", + "enum": [ + "UNSPECIFIED", + "N1_HIGHCPU_8", + "N1_HIGHCPU_32", + "E2_HIGHCPU_8", + "E2_HIGHCPU_32", + "E2_MEDIUM" + ], + "enumDeprecated": [ + false, + true, + true, + false, + false, + false + ], + "enumDescriptions": [ + "Standard machine type.", + "Highcpu machine with 8 CPUs.", + "Highcpu machine with 32 CPUs.", + "Highcpu e2 machine with 8 CPUs.", + "Highcpu e2 machine with 32 CPUs.", + "E2 machine with 1 CPU." + ], + "type": "string" + }, + "pool": { + "$ref": "GoogleDevtoolsCloudbuildV1PoolOption", + "description": "Optional. Specification for execution on a `WorkerPool`. See [running builds in a private pool](https://cloud.google.com/build/docs/private-pools/run-builds-in-private-pool) for more information." + }, + "requestedVerifyOption": { + "description": "Requested verifiability options.", + "enum": [ + "NOT_VERIFIED", + "VERIFIED" + ], + "enumDescriptions": [ + "Not a verifiable build (the default).", + "Build must be verified." + ], + "type": "string" + }, + "secretEnv": { + "description": "A list of global environment variables, which are encrypted using a Cloud Key Management Service crypto key. These values must be specified in the build's `Secret`. These variables will be available to all build steps in this build.", + "items": { + "type": "string" + }, + "type": "array" + }, + "sourceProvenanceHash": { + "description": "Requested hash for SourceProvenance.", + "items": { + "enum": [ + "NONE", + "SHA256", + "MD5", + "SHA512" + ], + "enumDescriptions": [ + "No hash requested.", + "Use a sha256 hash.", + "Use a md5 hash.", + "Use a sha512 hash." + ], + "type": "string" + }, + "type": "array" + }, + "substitutionOption": { + "description": "Option to specify behavior when there is an error in the substitution checks. NOTE: this is always set to ALLOW_LOOSE for triggered builds and cannot be overridden in the build configuration file.", + "enum": [ + "MUST_MATCH", + "ALLOW_LOOSE" + ], + "enumDescriptions": [ + "Fails the build if error in substitutions checks, like missing a substitution in the template or in the map.", + "Do not fail the build if error in substitutions checks." + ], + "type": "string" + }, + "volumes": { + "description": "Global list of volumes to mount for ALL build steps Each volume is created as an empty volume prior to starting the build process. Upon completion of the build, volumes and their contents are discarded. Global volume names and paths cannot conflict with the volumes defined a build step. Using a global volume in a build with only one step is not valid as it is indicative of a build request with an incorrect configuration.", + "items": { + "$ref": "GoogleDevtoolsCloudbuildV1Volume" + }, + "type": "array" + }, + "workerPool": { + "deprecated": true, + "description": "This field deprecated; please use `pool.name` instead.", + "type": "string" + } + }, + "type": "object" + }, + "GoogleDevtoolsCloudbuildV1BuildStep": { + "description": "A step in the build pipeline.", + "id": "GoogleDevtoolsCloudbuildV1BuildStep", + "properties": { + "allowExitCodes": { + "description": "Allow this build step to fail without failing the entire build if and only if the exit code is one of the specified codes. If allow_failure is also specified, this field will take precedence.", + "items": { + "format": "int32", + "type": "integer" + }, + "type": "array" + }, + "allowFailure": { + "description": "Allow this build step to fail without failing the entire build. If false, the entire build will fail if this step fails. Otherwise, the build will succeed, but this step will still have a failure status. Error information will be reported in the failure_detail field.", + "type": "boolean" + }, + "args": { + "description": "A list of arguments that will be presented to the step when it is started. If the image used to run the step's container has an entrypoint, the `args` are used as arguments to that entrypoint. If the image does not define an entrypoint, the first element in args is used as the entrypoint, and the remainder will be used as arguments.", + "items": { + "type": "string" + }, + "type": "array" + }, + "automapSubstitutions": { + "description": "Option to include built-in and custom substitutions as env variables for this build step. This option will override the global option in BuildOption.", + "type": "boolean" + }, + "dir": { + "description": "Working directory to use when running this step's container. If this value is a relative path, it is relative to the build's working directory. If this value is absolute, it may be outside the build's working directory, in which case the contents of the path may not be persisted across build step executions, unless a `volume` for that path is specified. If the build specifies a `RepoSource` with `dir` and a step with a `dir`, which specifies an absolute path, the `RepoSource` `dir` is ignored for the step's execution.", + "type": "string" + }, + "entrypoint": { + "description": "Entrypoint to be used instead of the build step image's default entrypoint. If unset, the image's default entrypoint is used.", + "type": "string" + }, + "env": { + "description": "A list of environment variable definitions to be used when running a step. The elements are of the form \"KEY=VALUE\" for the environment variable \"KEY\" being given the value \"VALUE\".", + "items": { + "type": "string" + }, + "type": "array" + }, + "exitCode": { + "description": "Output only. Return code from running the step.", + "format": "int32", + "readOnly": true, + "type": "integer" + }, + "id": { + "description": "Unique identifier for this build step, used in `wait_for` to reference this build step as a dependency.", + "type": "string" + }, + "name": { + "description": "Required. The name of the container image that will run this particular build step. If the image is available in the host's Docker daemon's cache, it will be run directly. If not, the host will attempt to pull the image first, using the builder service account's credentials if necessary. The Docker daemon's cache will already have the latest versions of all of the officially supported build steps ([https://github.com/GoogleCloudPlatform/cloud-builders](https://github.com/GoogleCloudPlatform/cloud-builders)). The Docker daemon will also have cached many of the layers for some popular images, like \"ubuntu\", \"debian\", but they will be refreshed at the time you attempt to use them. If you built an image in a previous build step, it will be stored in the host's Docker daemon's cache and is available to use as the name for a later build step.", + "type": "string" + }, + "pullTiming": { + "$ref": "GoogleDevtoolsCloudbuildV1TimeSpan", + "description": "Output only. Stores timing information for pulling this build step's builder image only.", + "readOnly": true + }, + "script": { + "description": "A shell script to be executed in the step. When script is provided, the user cannot specify the entrypoint or args.", + "type": "string" + }, + "secretEnv": { + "description": "A list of environment variables which are encrypted using a Cloud Key Management Service crypto key. These values must be specified in the build's `Secret`.", + "items": { + "type": "string" + }, + "type": "array" + }, + "status": { + "description": "Output only. Status of the build step. At this time, build step status is only updated on build completion; step status is not updated in real-time as the build progresses.", + "enum": [ + "STATUS_UNKNOWN", + "PENDING", + "QUEUED", + "WORKING", + "SUCCESS", + "FAILURE", + "INTERNAL_ERROR", + "TIMEOUT", + "CANCELLED", + "EXPIRED" + ], + "enumDescriptions": [ + "Status of the build is unknown.", + "Build has been created and is pending execution and queuing. It has not been queued.", + "Build or step is queued; work has not yet begun.", + "Build or step is being executed.", + "Build or step finished successfully.", + "Build or step failed to complete successfully.", + "Build or step failed due to an internal cause.", + "Build or step took longer than was allowed.", + "Build or step was canceled by a user.", + "Build was enqueued for longer than the value of `queue_ttl`." + ], + "readOnly": true, + "type": "string" + }, + "timeout": { + "description": "Time limit for executing this build step. If not defined, the step has no time limit and will be allowed to continue to run until either it completes or the build itself times out.", + "format": "google-duration", + "type": "string" + }, + "timing": { + "$ref": "GoogleDevtoolsCloudbuildV1TimeSpan", + "description": "Output only. Stores timing information for executing this build step.", + "readOnly": true + }, + "volumes": { + "description": "List of volumes to mount into the build step. Each volume is created as an empty volume prior to execution of the build step. Upon completion of the build, volumes and their contents are discarded. Using a named volume in only one step is not valid as it is indicative of a build request with an incorrect configuration.", + "items": { + "$ref": "GoogleDevtoolsCloudbuildV1Volume" + }, + "type": "array" + }, + "waitFor": { + "description": "The ID(s) of the step(s) that this build step depends on. This build step will not start until all the build steps in `wait_for` have completed successfully. If `wait_for` is empty, this build step will start when all previous build steps in the `Build.Steps` list have completed successfully.", + "items": { + "type": "string" + }, + "type": "array" + } + }, + "type": "object" + }, + "GoogleDevtoolsCloudbuildV1BuiltImage": { + "description": "An image built by the pipeline.", + "id": "GoogleDevtoolsCloudbuildV1BuiltImage", + "properties": { + "digest": { + "description": "Docker Registry 2.0 digest.", + "type": "string" + }, + "name": { + "description": "Name used to push the container image to Google Container Registry, as presented to `docker push`.", + "type": "string" + }, + "pushTiming": { + "$ref": "GoogleDevtoolsCloudbuildV1TimeSpan", + "description": "Output only. Stores timing information for pushing the specified image.", + "readOnly": true + } + }, + "type": "object" + }, + "GoogleDevtoolsCloudbuildV1ConnectedRepository": { + "description": "Location of the source in a 2nd-gen Google Cloud Build repository resource.", + "id": "GoogleDevtoolsCloudbuildV1ConnectedRepository", + "properties": { + "dir": { + "description": "Directory, relative to the source root, in which to run the build.", + "type": "string" + }, + "repository": { + "description": "Required. Name of the Google Cloud Build repository, formatted as `projects/*/locations/*/connections/*/repositories/*`.", + "type": "string" + }, + "revision": { + "description": "The revision to fetch from the Git repository such as a branch, a tag, a commit SHA, or any Git ref.", + "type": "string" + } + }, + "type": "object" + }, + "GoogleDevtoolsCloudbuildV1FailureInfo": { + "description": "A fatal problem encountered during the execution of the build.", + "id": "GoogleDevtoolsCloudbuildV1FailureInfo", + "properties": { + "detail": { + "description": "Explains the failure issue in more detail using hard-coded text.", + "type": "string" + }, + "type": { + "description": "The name of the failure.", + "enum": [ + "FAILURE_TYPE_UNSPECIFIED", + "PUSH_FAILED", + "PUSH_IMAGE_NOT_FOUND", + "PUSH_NOT_AUTHORIZED", + "LOGGING_FAILURE", + "USER_BUILD_STEP", + "FETCH_SOURCE_FAILED" + ], + "enumDescriptions": [ + "Type unspecified", + "Unable to push the image to the repository.", + "Final image not found.", + "Unauthorized push of the final image.", + "Backend logging failures. Should retry.", + "A build step has failed.", + "The source fetching has failed." + ], + "type": "string" + } + }, + "type": "object" + }, + "GoogleDevtoolsCloudbuildV1FileHashes": { + "description": "Container message for hashes of byte content of files, used in SourceProvenance messages to verify integrity of source input to the build.", + "id": "GoogleDevtoolsCloudbuildV1FileHashes", + "properties": { + "fileHash": { + "description": "Collection of file hashes.", + "items": { + "$ref": "GoogleDevtoolsCloudbuildV1Hash" + }, + "type": "array" + } + }, + "type": "object" + }, + "GoogleDevtoolsCloudbuildV1GitSource": { + "description": "Location of the source in any accessible Git repository.", + "id": "GoogleDevtoolsCloudbuildV1GitSource", + "properties": { + "dir": { + "description": "Directory, relative to the source root, in which to run the build. This must be a relative path. If a step's `dir` is specified and is an absolute path, this value is ignored for that step's execution.", + "type": "string" + }, + "revision": { + "description": "The revision to fetch from the Git repository such as a branch, a tag, a commit SHA, or any Git ref. Cloud Build uses `git fetch` to fetch the revision from the Git repository; therefore make sure that the string you provide for `revision` is parsable by the command. For information on string values accepted by `git fetch`, see https://git-scm.com/docs/gitrevisions#_specifying_revisions. For information on `git fetch`, see https://git-scm.com/docs/git-fetch.", + "type": "string" + }, + "url": { + "description": "Location of the Git repo to build. This will be used as a `git remote`, see https://git-scm.com/docs/git-remote.", + "type": "string" + } + }, + "type": "object" + }, + "GoogleDevtoolsCloudbuildV1Hash": { + "description": "Container message for hash values.", + "id": "GoogleDevtoolsCloudbuildV1Hash", + "properties": { + "type": { + "description": "The type of hash that was performed.", + "enum": [ + "NONE", + "SHA256", + "MD5", + "SHA512" + ], + "enumDescriptions": [ + "No hash requested.", + "Use a sha256 hash.", + "Use a md5 hash.", + "Use a sha512 hash." + ], + "type": "string" + }, + "value": { + "description": "The hash value.", + "format": "byte", + "type": "string" + } + }, + "type": "object" + }, + "GoogleDevtoolsCloudbuildV1InlineSecret": { + "description": "Pairs a set of secret environment variables mapped to encrypted values with the Cloud KMS key to use to decrypt the value.", + "id": "GoogleDevtoolsCloudbuildV1InlineSecret", + "properties": { + "envMap": { + "additionalProperties": { + "format": "byte", + "type": "string" + }, + "description": "Map of environment variable name to its encrypted value. Secret environment variables must be unique across all of a build's secrets, and must be used by at least one build step. Values can be at most 64 KB in size. There can be at most 100 secret values across all of a build's secrets.", + "type": "object" + }, + "kmsKeyName": { + "description": "Resource name of Cloud KMS crypto key to decrypt the encrypted value. In format: projects/*/locations/*/keyRings/*/cryptoKeys/*", + "type": "string" + } + }, + "type": "object" + }, + "GoogleDevtoolsCloudbuildV1MavenArtifact": { + "description": "A Maven artifact to upload to Artifact Registry upon successful completion of all build steps.", + "id": "GoogleDevtoolsCloudbuildV1MavenArtifact", + "properties": { + "artifactId": { + "description": "Maven `artifactId` value used when uploading the artifact to Artifact Registry.", + "type": "string" + }, + "groupId": { + "description": "Maven `groupId` value used when uploading the artifact to Artifact Registry.", + "type": "string" + }, + "path": { + "description": "Path to an artifact in the build's workspace to be uploaded to Artifact Registry. This can be either an absolute path, e.g. /workspace/my-app/target/my-app-1.0.SNAPSHOT.jar or a relative path from /workspace, e.g. my-app/target/my-app-1.0.SNAPSHOT.jar.", + "type": "string" + }, + "repository": { + "description": "Artifact Registry repository, in the form \"https://$REGION-maven.pkg.dev/$PROJECT/$REPOSITORY\" Artifact in the workspace specified by path will be uploaded to Artifact Registry with this location as a prefix.", + "type": "string" + }, + "version": { + "description": "Maven `version` value used when uploading the artifact to Artifact Registry.", + "type": "string" + } + }, + "type": "object" + }, + "GoogleDevtoolsCloudbuildV1NpmPackage": { + "description": "Npm package to upload to Artifact Registry upon successful completion of all build steps.", + "id": "GoogleDevtoolsCloudbuildV1NpmPackage", + "properties": { + "packagePath": { + "description": "Path to the package.json. e.g. workspace/path/to/package", + "type": "string" + }, + "repository": { + "description": "Artifact Registry repository, in the form \"https://$REGION-npm.pkg.dev/$PROJECT/$REPOSITORY\" Npm package in the workspace specified by path will be zipped and uploaded to Artifact Registry with this location as a prefix.", + "type": "string" + } + }, + "type": "object" + }, + "GoogleDevtoolsCloudbuildV1PoolOption": { + "description": "Details about how a build should be executed on a `WorkerPool`. See [running builds in a private pool](https://cloud.google.com/build/docs/private-pools/run-builds-in-private-pool) for more information.", + "id": "GoogleDevtoolsCloudbuildV1PoolOption", + "properties": { + "name": { + "description": "The `WorkerPool` resource to execute the build on. You must have `cloudbuild.workerpools.use` on the project hosting the WorkerPool. Format projects/{project}/locations/{location}/workerPools/{workerPoolId}", + "type": "string" + } + }, + "type": "object" + }, + "GoogleDevtoolsCloudbuildV1PythonPackage": { + "description": "Python package to upload to Artifact Registry upon successful completion of all build steps. A package can encapsulate multiple objects to be uploaded to a single repository.", + "id": "GoogleDevtoolsCloudbuildV1PythonPackage", + "properties": { + "paths": { + "description": "Path globs used to match files in the build's workspace. For Python/ Twine, this is usually `dist/*`, and sometimes additionally an `.asc` file.", + "items": { + "type": "string" + }, + "type": "array" + }, + "repository": { + "description": "Artifact Registry repository, in the form \"https://$REGION-python.pkg.dev/$PROJECT/$REPOSITORY\" Files in the workspace matching any path pattern will be uploaded to Artifact Registry with this location as a prefix.", + "type": "string" + } + }, + "type": "object" + }, + "GoogleDevtoolsCloudbuildV1RepoSource": { + "description": "Location of the source in a Google Cloud Source Repository.", + "id": "GoogleDevtoolsCloudbuildV1RepoSource", + "properties": { + "branchName": { + "description": "Regex matching branches to build. The syntax of the regular expressions accepted is the syntax accepted by RE2 and described at https://github.com/google/re2/wiki/Syntax", + "type": "string" + }, + "commitSha": { + "description": "Explicit commit SHA to build.", + "type": "string" + }, + "dir": { + "description": "Directory, relative to the source root, in which to run the build. This must be a relative path. If a step's `dir` is specified and is an absolute path, this value is ignored for that step's execution.", + "type": "string" + }, + "invertRegex": { + "description": "Only trigger a build if the revision regex does NOT match the revision regex.", + "type": "boolean" + }, + "projectId": { + "description": "ID of the project that owns the Cloud Source Repository. If omitted, the project ID requesting the build is assumed.", + "type": "string" + }, + "repoName": { + "description": "Name of the Cloud Source Repository.", + "type": "string" + }, + "substitutions": { + "additionalProperties": { + "type": "string" + }, + "description": "Substitutions to use in a triggered build. Should only be used with RunBuildTrigger", + "type": "object" + }, + "tagName": { + "description": "Regex matching tags to build. The syntax of the regular expressions accepted is the syntax accepted by RE2 and described at https://github.com/google/re2/wiki/Syntax", + "type": "string" + } + }, + "type": "object" + }, + "GoogleDevtoolsCloudbuildV1Results": { + "description": "Artifacts created by the build pipeline.", + "id": "GoogleDevtoolsCloudbuildV1Results", + "properties": { + "artifactManifest": { + "description": "Path to the artifact manifest for non-container artifacts uploaded to Cloud Storage. Only populated when artifacts are uploaded to Cloud Storage.", + "type": "string" + }, + "artifactTiming": { + "$ref": "GoogleDevtoolsCloudbuildV1TimeSpan", + "description": "Time to push all non-container artifacts to Cloud Storage." + }, + "buildStepImages": { + "description": "List of build step digests, in the order corresponding to build step indices.", + "items": { + "type": "string" + }, + "type": "array" + }, + "buildStepOutputs": { + "description": "List of build step outputs, produced by builder images, in the order corresponding to build step indices. [Cloud Builders](https://cloud.google.com/cloud-build/docs/cloud-builders) can produce this output by writing to `$BUILDER_OUTPUT/output`. Only the first 50KB of data is stored.", + "items": { + "format": "byte", + "type": "string" + }, + "type": "array" + }, + "images": { + "description": "Container images that were built as a part of the build.", + "items": { + "$ref": "GoogleDevtoolsCloudbuildV1BuiltImage" + }, + "type": "array" + }, + "mavenArtifacts": { + "description": "Maven artifacts uploaded to Artifact Registry at the end of the build.", + "items": { + "$ref": "GoogleDevtoolsCloudbuildV1UploadedMavenArtifact" + }, + "type": "array" + }, + "npmPackages": { + "description": "Npm packages uploaded to Artifact Registry at the end of the build.", + "items": { + "$ref": "GoogleDevtoolsCloudbuildV1UploadedNpmPackage" + }, + "type": "array" + }, + "numArtifacts": { + "description": "Number of non-container artifacts uploaded to Cloud Storage. Only populated when artifacts are uploaded to Cloud Storage.", + "format": "int64", + "type": "string" + }, + "pythonPackages": { + "description": "Python artifacts uploaded to Artifact Registry at the end of the build.", + "items": { + "$ref": "GoogleDevtoolsCloudbuildV1UploadedPythonPackage" + }, + "type": "array" + } + }, + "type": "object" + }, + "GoogleDevtoolsCloudbuildV1Secret": { + "description": "Pairs a set of secret environment variables containing encrypted values with the Cloud KMS key to use to decrypt the value. Note: Use `kmsKeyName` with `available_secrets` instead of using `kmsKeyName` with `secret`. For instructions see: https://cloud.google.com/cloud-build/docs/securing-builds/use-encrypted-credentials.", + "id": "GoogleDevtoolsCloudbuildV1Secret", + "properties": { + "kmsKeyName": { + "description": "Cloud KMS key name to use to decrypt these envs.", + "type": "string" + }, + "secretEnv": { + "additionalProperties": { + "format": "byte", + "type": "string" + }, + "description": "Map of environment variable name to its encrypted value. Secret environment variables must be unique across all of a build's secrets, and must be used by at least one build step. Values can be at most 64 KB in size. There can be at most 100 secret values across all of a build's secrets.", + "type": "object" + } + }, + "type": "object" + }, + "GoogleDevtoolsCloudbuildV1SecretManagerSecret": { + "description": "Pairs a secret environment variable with a SecretVersion in Secret Manager.", + "id": "GoogleDevtoolsCloudbuildV1SecretManagerSecret", + "properties": { + "env": { + "description": "Environment variable name to associate with the secret. Secret environment variables must be unique across all of a build's secrets, and must be used by at least one build step.", + "type": "string" + }, + "versionName": { + "description": "Resource name of the SecretVersion. In format: projects/*/secrets/*/versions/*", + "type": "string" + } + }, + "type": "object" + }, + "GoogleDevtoolsCloudbuildV1Secrets": { + "description": "Secrets and secret environment variables.", + "id": "GoogleDevtoolsCloudbuildV1Secrets", + "properties": { + "inline": { + "description": "Secrets encrypted with KMS key and the associated secret environment variable.", + "items": { + "$ref": "GoogleDevtoolsCloudbuildV1InlineSecret" + }, + "type": "array" + }, + "secretManager": { + "description": "Secrets in Secret Manager and associated secret environment variable.", + "items": { + "$ref": "GoogleDevtoolsCloudbuildV1SecretManagerSecret" + }, + "type": "array" + } + }, + "type": "object" + }, + "GoogleDevtoolsCloudbuildV1Source": { + "description": "Location of the source in a supported storage service.", + "id": "GoogleDevtoolsCloudbuildV1Source", + "properties": { + "connectedRepository": { + "$ref": "GoogleDevtoolsCloudbuildV1ConnectedRepository", + "description": "Optional. If provided, get the source from this 2nd-gen Google Cloud Build repository resource." + }, + "gitSource": { + "$ref": "GoogleDevtoolsCloudbuildV1GitSource", + "description": "If provided, get the source from this Git repository." + }, + "repoSource": { + "$ref": "GoogleDevtoolsCloudbuildV1RepoSource", + "description": "If provided, get the source from this location in a Cloud Source Repository." + }, + "storageSource": { + "$ref": "GoogleDevtoolsCloudbuildV1StorageSource", + "description": "If provided, get the source from this location in Cloud Storage." + }, + "storageSourceManifest": { + "$ref": "GoogleDevtoolsCloudbuildV1StorageSourceManifest", + "description": "If provided, get the source from this manifest in Cloud Storage. This feature is in Preview; see description [here](https://github.com/GoogleCloudPlatform/cloud-builders/tree/master/gcs-fetcher)." + } + }, + "type": "object" + }, + "GoogleDevtoolsCloudbuildV1SourceProvenance": { + "description": "Provenance of the source. Ways to find the original source, or verify that some source was used for this build.", + "id": "GoogleDevtoolsCloudbuildV1SourceProvenance", + "properties": { + "fileHashes": { + "additionalProperties": { + "$ref": "GoogleDevtoolsCloudbuildV1FileHashes" + }, + "description": "Output only. Hash(es) of the build source, which can be used to verify that the original source integrity was maintained in the build. Note that `FileHashes` will only be populated if `BuildOptions` has requested a `SourceProvenanceHash`. The keys to this map are file paths used as build source and the values contain the hash values for those files. If the build source came in a single package such as a gzipped tarfile (`.tar.gz`), the `FileHash` will be for the single path to that file.", + "readOnly": true, + "type": "object" + }, + "resolvedConnectedRepository": { + "$ref": "GoogleDevtoolsCloudbuildV1ConnectedRepository", + "description": "Output only. A copy of the build's `source.connected_repository`, if exists, with any revisions resolved.", + "readOnly": true + }, + "resolvedGitSource": { + "$ref": "GoogleDevtoolsCloudbuildV1GitSource", + "description": "Output only. A copy of the build's `source.git_source`, if exists, with any revisions resolved.", + "readOnly": true + }, + "resolvedRepoSource": { + "$ref": "GoogleDevtoolsCloudbuildV1RepoSource", + "description": "A copy of the build's `source.repo_source`, if exists, with any revisions resolved." + }, + "resolvedStorageSource": { + "$ref": "GoogleDevtoolsCloudbuildV1StorageSource", + "description": "A copy of the build's `source.storage_source`, if exists, with any generations resolved." + }, + "resolvedStorageSourceManifest": { + "$ref": "GoogleDevtoolsCloudbuildV1StorageSourceManifest", + "description": "A copy of the build's `source.storage_source_manifest`, if exists, with any revisions resolved. This feature is in Preview." + } + }, + "type": "object" + }, + "GoogleDevtoolsCloudbuildV1StorageSource": { + "description": "Location of the source in an archive file in Cloud Storage.", + "id": "GoogleDevtoolsCloudbuildV1StorageSource", + "properties": { + "bucket": { + "description": "Cloud Storage bucket containing the source (see [Bucket Name Requirements](https://cloud.google.com/storage/docs/bucket-naming#requirements)).", + "type": "string" + }, + "generation": { + "description": "Cloud Storage generation for the object. If the generation is omitted, the latest generation will be used.", + "format": "int64", + "type": "string" + }, + "object": { + "description": "Cloud Storage object containing the source. This object must be a zipped (`.zip`) or gzipped archive file (`.tar.gz`) containing source to build.", + "type": "string" + }, + "sourceFetcher": { + "description": "Optional. Option to specify the tool to fetch the source file for the build.", + "enum": [ + "SOURCE_FETCHER_UNSPECIFIED", + "GSUTIL", + "GCS_FETCHER" + ], + "enumDescriptions": [ + "Unspecified defaults to GSUTIL.", + "Use the \"gsutil\" tool to download the source file.", + "Use the Cloud Storage Fetcher tool to download the source file." + ], + "type": "string" + } + }, + "type": "object" + }, + "GoogleDevtoolsCloudbuildV1StorageSourceManifest": { + "description": "Location of the source manifest in Cloud Storage. This feature is in Preview; see description [here](https://github.com/GoogleCloudPlatform/cloud-builders/tree/master/gcs-fetcher).", + "id": "GoogleDevtoolsCloudbuildV1StorageSourceManifest", + "properties": { + "bucket": { + "description": "Cloud Storage bucket containing the source manifest (see [Bucket Name Requirements](https://cloud.google.com/storage/docs/bucket-naming#requirements)).", + "type": "string" + }, + "generation": { + "description": "Cloud Storage generation for the object. If the generation is omitted, the latest generation will be used.", + "format": "int64", + "type": "string" + }, + "object": { + "description": "Cloud Storage object containing the source manifest. This object must be a JSON file.", + "type": "string" + } + }, + "type": "object" + }, + "GoogleDevtoolsCloudbuildV1TimeSpan": { + "description": "Start and end times for a build execution phase.", + "id": "GoogleDevtoolsCloudbuildV1TimeSpan", + "properties": { + "endTime": { + "description": "End of time span.", + "format": "google-datetime", + "type": "string" + }, + "startTime": { + "description": "Start of time span.", + "format": "google-datetime", + "type": "string" + } + }, + "type": "object" + }, + "GoogleDevtoolsCloudbuildV1UploadedMavenArtifact": { + "description": "A Maven artifact uploaded using the MavenArtifact directive.", + "id": "GoogleDevtoolsCloudbuildV1UploadedMavenArtifact", + "properties": { + "fileHashes": { + "$ref": "GoogleDevtoolsCloudbuildV1FileHashes", + "description": "Hash types and values of the Maven Artifact." + }, + "pushTiming": { + "$ref": "GoogleDevtoolsCloudbuildV1TimeSpan", + "description": "Output only. Stores timing information for pushing the specified artifact.", + "readOnly": true + }, + "uri": { + "description": "URI of the uploaded artifact.", + "type": "string" + } + }, + "type": "object" + }, + "GoogleDevtoolsCloudbuildV1UploadedNpmPackage": { + "description": "An npm package uploaded to Artifact Registry using the NpmPackage directive.", + "id": "GoogleDevtoolsCloudbuildV1UploadedNpmPackage", + "properties": { + "fileHashes": { + "$ref": "GoogleDevtoolsCloudbuildV1FileHashes", + "description": "Hash types and values of the npm package." + }, + "pushTiming": { + "$ref": "GoogleDevtoolsCloudbuildV1TimeSpan", + "description": "Output only. Stores timing information for pushing the specified artifact.", + "readOnly": true + }, + "uri": { + "description": "URI of the uploaded npm package.", + "type": "string" + } + }, + "type": "object" + }, + "GoogleDevtoolsCloudbuildV1UploadedPythonPackage": { + "description": "Artifact uploaded using the PythonPackage directive.", + "id": "GoogleDevtoolsCloudbuildV1UploadedPythonPackage", + "properties": { + "fileHashes": { + "$ref": "GoogleDevtoolsCloudbuildV1FileHashes", + "description": "Hash types and values of the Python Artifact." + }, + "pushTiming": { + "$ref": "GoogleDevtoolsCloudbuildV1TimeSpan", + "description": "Output only. Stores timing information for pushing the specified artifact.", + "readOnly": true + }, + "uri": { + "description": "URI of the uploaded artifact.", + "type": "string" + } + }, + "type": "object" + }, + "GoogleDevtoolsCloudbuildV1Volume": { + "description": "Volume describes a Docker container volume which is mounted into build steps in order to persist files across build step execution.", + "id": "GoogleDevtoolsCloudbuildV1Volume", + "properties": { + "name": { + "description": "Name of the volume to mount. Volume names must be unique per build step and must be valid names for Docker volumes. Each named volume must be used by at least two build steps.", + "type": "string" + }, + "path": { + "description": "Path at which to mount the volume. Paths must be absolute and cannot conflict with other volume paths on the same build step or with certain reserved volume paths.", + "type": "string" + } + }, + "type": "object" + }, + "GoogleDevtoolsCloudbuildV1Warning": { + "description": "A non-fatal problem encountered during the execution of the build.", + "id": "GoogleDevtoolsCloudbuildV1Warning", + "properties": { + "priority": { + "description": "The priority for this warning.", + "enum": [ + "PRIORITY_UNSPECIFIED", + "INFO", + "WARNING", + "ALERT" + ], + "enumDescriptions": [ + "Should not be used.", + "e.g. deprecation warnings and alternative feature highlights.", + "e.g. automated detection of possible issues with the build.", + "e.g. alerts that a feature used in the build is pending removal" + ], + "type": "string" + }, + "text": { + "description": "Explanation of the warning generated.", + "type": "string" + } + }, + "type": "object" + }, "GoogleIamV1AuditConfig": { "description": "Specifies the audit configuration for a service. The configuration determines which permission types are logged, and what identities, if any, are exempted from logging. An AuditConfig must have one or more AuditLogConfigs. If there are AuditConfigs for both `allServices` and a specific service, the union of the two AuditConfigs is used for that service: the log_types specified in each AuditConfig are enabled, and the exempted_members in each AuditLogConfig are exempted. Example Policy with multiple AuditConfigs: { \"audit_configs\": [ { \"service\": \"allServices\", \"audit_log_configs\": [ { \"log_type\": \"DATA_READ\", \"exempted_members\": [ \"user:jose@example.com\" ] }, { \"log_type\": \"DATA_WRITE\" }, { \"log_type\": \"ADMIN_READ\" } ] }, { \"service\": \"sampleservice.googleapis.com\", \"audit_log_configs\": [ { \"log_type\": \"DATA_READ\" }, { \"log_type\": \"DATA_WRITE\", \"exempted_members\": [ \"user:aliya@example.com\" ] } ] } ] } For sampleservice, this policy enables DATA_READ, DATA_WRITE and ADMIN_READ logging. It also exempts `jose@example.com` from DATA_READ logging, and `aliya@example.com` from DATA_WRITE logging.", "id": "GoogleIamV1AuditConfig", diff --git a/run/v2/run-gen.go b/run/v2/run-gen.go index 16cbfb407ba..148b912347a 100644 --- a/run/v2/run-gen.go +++ b/run/v2/run-gen.go @@ -2592,7 +2592,7 @@ func (s *GoogleCloudRunV2Service) MarshalJSON() ([]byte, error) { type GoogleCloudRunV2ServiceScaling struct { // MinInstanceCount: total min instances for the service. This number of // instances is divided among all revisions with specified traffic based - // on the percent of traffic they are receiving. (ALPHA) + // on the percent of traffic they are receiving. (BETA) MinInstanceCount int64 `json:"minInstanceCount,omitempty"` // ForceSendFields is a list of field names (e.g. "MinInstanceCount") to @@ -3215,6 +3215,1825 @@ func (s *GoogleCloudRunV2VpcAccess) MarshalJSON() ([]byte, error) { return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } +// GoogleDevtoolsCloudbuildV1ApprovalConfig: ApprovalConfig describes +// configuration for manual approval of a build. +type GoogleDevtoolsCloudbuildV1ApprovalConfig struct { + // ApprovalRequired: Whether or not approval is needed. If this is set + // on a build, it will become pending when created, and will need to be + // explicitly approved to start. + ApprovalRequired bool `json:"approvalRequired,omitempty"` + + // ForceSendFields is a list of field names (e.g. "ApprovalRequired") 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. "ApprovalRequired") 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 *GoogleDevtoolsCloudbuildV1ApprovalConfig) MarshalJSON() ([]byte, error) { + type NoMethod GoogleDevtoolsCloudbuildV1ApprovalConfig + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + +// GoogleDevtoolsCloudbuildV1ApprovalResult: ApprovalResult describes +// the decision and associated metadata of a manual approval of a build. +type GoogleDevtoolsCloudbuildV1ApprovalResult struct { + // ApprovalTime: Output only. The time when the approval decision was + // made. + ApprovalTime string `json:"approvalTime,omitempty"` + + // ApproverAccount: Output only. Email of the user that called the + // ApproveBuild API to approve or reject a build at the time that the + // API was called. + ApproverAccount string `json:"approverAccount,omitempty"` + + // Comment: Optional. An optional comment for this manual approval + // result. + Comment string `json:"comment,omitempty"` + + // Decision: Required. The decision of this manual approval. + // + // Possible values: + // "DECISION_UNSPECIFIED" - Default enum type. This should not be + // used. + // "APPROVED" - Build is approved. + // "REJECTED" - Build is rejected. + Decision string `json:"decision,omitempty"` + + // Url: Optional. An optional URL tied to this manual approval result. + // This field is essentially the same as comment, except that it will be + // rendered by the UI differently. An example use case is a link to an + // external job that approved this Build. + Url string `json:"url,omitempty"` + + // ForceSendFields is a list of field names (e.g. "ApprovalTime") 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. "ApprovalTime") 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 *GoogleDevtoolsCloudbuildV1ApprovalResult) MarshalJSON() ([]byte, error) { + type NoMethod GoogleDevtoolsCloudbuildV1ApprovalResult + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + +// GoogleDevtoolsCloudbuildV1ArtifactObjects: Files in the workspace to +// upload to Cloud Storage upon successful completion of all build +// steps. +type GoogleDevtoolsCloudbuildV1ArtifactObjects struct { + // Location: Cloud Storage bucket and optional object path, in the form + // "gs://bucket/path/to/somewhere/". (see Bucket Name Requirements + // (https://cloud.google.com/storage/docs/bucket-naming#requirements)). + // Files in the workspace matching any path pattern will be uploaded to + // Cloud Storage with this location as a prefix. + Location string `json:"location,omitempty"` + + // Paths: Path globs used to match files in the build's workspace. + Paths []string `json:"paths,omitempty"` + + // Timing: Output only. Stores timing information for pushing all + // artifact objects. + Timing *GoogleDevtoolsCloudbuildV1TimeSpan `json:"timing,omitempty"` + + // ForceSendFields is a list of field names (e.g. "Location") 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. "Location") 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 *GoogleDevtoolsCloudbuildV1ArtifactObjects) MarshalJSON() ([]byte, error) { + type NoMethod GoogleDevtoolsCloudbuildV1ArtifactObjects + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + +// GoogleDevtoolsCloudbuildV1Artifacts: Artifacts produced by a build +// that should be uploaded upon successful completion of all build +// steps. +type GoogleDevtoolsCloudbuildV1Artifacts struct { + // Images: A list of images to be pushed upon the successful completion + // of all build steps. The images will be pushed using the builder + // service account's credentials. The digests of the pushed images will + // be stored in the Build resource's results field. If any of the images + // fail to be pushed, the build is marked FAILURE. + Images []string `json:"images,omitempty"` + + // MavenArtifacts: A list of Maven artifacts to be uploaded to Artifact + // Registry upon successful completion of all build steps. Artifacts in + // the workspace matching specified paths globs will be uploaded to the + // specified Artifact Registry repository using the builder service + // account's credentials. If any artifacts fail to be pushed, the build + // is marked FAILURE. + MavenArtifacts []*GoogleDevtoolsCloudbuildV1MavenArtifact `json:"mavenArtifacts,omitempty"` + + // NpmPackages: A list of npm packages to be uploaded to Artifact + // Registry upon successful completion of all build steps. Npm packages + // in the specified paths will be uploaded to the specified Artifact + // Registry repository using the builder service account's credentials. + // If any packages fail to be pushed, the build is marked FAILURE. + NpmPackages []*GoogleDevtoolsCloudbuildV1NpmPackage `json:"npmPackages,omitempty"` + + // Objects: A list of objects to be uploaded to Cloud Storage upon + // successful completion of all build steps. Files in the workspace + // matching specified paths globs will be uploaded to the specified + // Cloud Storage location using the builder service account's + // credentials. The location and generation of the uploaded objects will + // be stored in the Build resource's results field. If any objects fail + // to be pushed, the build is marked FAILURE. + Objects *GoogleDevtoolsCloudbuildV1ArtifactObjects `json:"objects,omitempty"` + + // PythonPackages: A list of Python packages to be uploaded to Artifact + // Registry upon successful completion of all build steps. The build + // service account credentials will be used to perform the upload. If + // any objects fail to be pushed, the build is marked FAILURE. + PythonPackages []*GoogleDevtoolsCloudbuildV1PythonPackage `json:"pythonPackages,omitempty"` + + // ForceSendFields is a list of field names (e.g. "Images") 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. "Images") 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 *GoogleDevtoolsCloudbuildV1Artifacts) MarshalJSON() ([]byte, error) { + type NoMethod GoogleDevtoolsCloudbuildV1Artifacts + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + +// GoogleDevtoolsCloudbuildV1Build: A build resource in the Cloud Build +// API. At a high level, a `Build` describes where to find source code, +// how to build it (for example, the builder image to run on the +// source), and where to store the built artifacts. Fields can include +// the following variables, which will be expanded when the build is +// created: - $PROJECT_ID: the project ID of the build. - +// $PROJECT_NUMBER: the project number of the build. - $LOCATION: the +// location/region of the build. - $BUILD_ID: the autogenerated ID of +// the build. - $REPO_NAME: the source repository name specified by +// RepoSource. - $BRANCH_NAME: the branch name specified by RepoSource. +// - $TAG_NAME: the tag name specified by RepoSource. - $REVISION_ID or +// $COMMIT_SHA: the commit SHA specified by RepoSource or resolved from +// the specified branch or tag. - $SHORT_SHA: first 7 characters of +// $REVISION_ID or $COMMIT_SHA. +type GoogleDevtoolsCloudbuildV1Build struct { + // Approval: Output only. Describes this build's approval configuration, + // status, and result. + Approval *GoogleDevtoolsCloudbuildV1BuildApproval `json:"approval,omitempty"` + + // Artifacts: Artifacts produced by the build that should be uploaded + // upon successful completion of all build steps. + Artifacts *GoogleDevtoolsCloudbuildV1Artifacts `json:"artifacts,omitempty"` + + // AvailableSecrets: Secrets and secret environment variables. + AvailableSecrets *GoogleDevtoolsCloudbuildV1Secrets `json:"availableSecrets,omitempty"` + + // BuildTriggerId: Output only. The ID of the `BuildTrigger` that + // triggered this build, if it was triggered automatically. + BuildTriggerId string `json:"buildTriggerId,omitempty"` + + // CreateTime: Output only. Time at which the request to create the + // build was received. + CreateTime string `json:"createTime,omitempty"` + + // FailureInfo: Output only. Contains information about the build when + // status=FAILURE. + FailureInfo *GoogleDevtoolsCloudbuildV1FailureInfo `json:"failureInfo,omitempty"` + + // FinishTime: Output only. Time at which execution of the build was + // finished. The difference between finish_time and start_time is the + // duration of the build's execution. + FinishTime string `json:"finishTime,omitempty"` + + // Id: Output only. Unique identifier of the build. + Id string `json:"id,omitempty"` + + // Images: A list of images to be pushed upon the successful completion + // of all build steps. The images are pushed using the builder service + // account's credentials. The digests of the pushed images will be + // stored in the `Build` resource's results field. If any of the images + // fail to be pushed, the build status is marked `FAILURE`. + Images []string `json:"images,omitempty"` + + // LogUrl: Output only. URL to logs for this build in Google Cloud + // Console. + LogUrl string `json:"logUrl,omitempty"` + + // LogsBucket: Cloud Storage bucket where logs should be written (see + // Bucket Name Requirements + // (https://cloud.google.com/storage/docs/bucket-naming#requirements)). + // Logs file names will be of the format + // `${logs_bucket}/log-${build_id}.txt`. + LogsBucket string `json:"logsBucket,omitempty"` + + // Name: Output only. The 'Build' name with format: + // `projects/{project}/locations/{location}/builds/{build}`, where + // {build} is a unique identifier generated by the service. + Name string `json:"name,omitempty"` + + // Options: Special options for this build. + Options *GoogleDevtoolsCloudbuildV1BuildOptions `json:"options,omitempty"` + + // ProjectId: Output only. ID of the project. + ProjectId string `json:"projectId,omitempty"` + + // QueueTtl: TTL in queue for this build. If provided and the build is + // enqueued longer than this value, the build will expire and the build + // status will be `EXPIRED`. The TTL starts ticking from create_time. + QueueTtl string `json:"queueTtl,omitempty"` + + // Results: Output only. Results of the build. + Results *GoogleDevtoolsCloudbuildV1Results `json:"results,omitempty"` + + // Secrets: Secrets to decrypt using Cloud Key Management Service. Note: + // Secret Manager is the recommended technique for managing sensitive + // data with Cloud Build. Use `available_secrets` to configure builds to + // access secrets from Secret Manager. For instructions, see: + // https://cloud.google.com/cloud-build/docs/securing-builds/use-secrets + Secrets []*GoogleDevtoolsCloudbuildV1Secret `json:"secrets,omitempty"` + + // ServiceAccount: IAM service account whose credentials will be used at + // build runtime. Must be of the format + // `projects/{PROJECT_ID}/serviceAccounts/{ACCOUNT}`. ACCOUNT can be + // email address or uniqueId of the service account. + ServiceAccount string `json:"serviceAccount,omitempty"` + + // Source: The location of the source files to build. + Source *GoogleDevtoolsCloudbuildV1Source `json:"source,omitempty"` + + // SourceProvenance: Output only. A permanent fixed identifier for + // source. + SourceProvenance *GoogleDevtoolsCloudbuildV1SourceProvenance `json:"sourceProvenance,omitempty"` + + // StartTime: Output only. Time at which execution of the build was + // started. + StartTime string `json:"startTime,omitempty"` + + // Status: Output only. Status of the build. + // + // Possible values: + // "STATUS_UNKNOWN" - Status of the build is unknown. + // "PENDING" - Build has been created and is pending execution and + // queuing. It has not been queued. + // "QUEUED" - Build or step is queued; work has not yet begun. + // "WORKING" - Build or step is being executed. + // "SUCCESS" - Build or step finished successfully. + // "FAILURE" - Build or step failed to complete successfully. + // "INTERNAL_ERROR" - Build or step failed due to an internal cause. + // "TIMEOUT" - Build or step took longer than was allowed. + // "CANCELLED" - Build or step was canceled by a user. + // "EXPIRED" - Build was enqueued for longer than the value of + // `queue_ttl`. + Status string `json:"status,omitempty"` + + // StatusDetail: Output only. Customer-readable message about the + // current status. + StatusDetail string `json:"statusDetail,omitempty"` + + // Steps: Required. The operations to be performed on the workspace. + Steps []*GoogleDevtoolsCloudbuildV1BuildStep `json:"steps,omitempty"` + + // Substitutions: Substitutions data for `Build` resource. + Substitutions map[string]string `json:"substitutions,omitempty"` + + // Tags: Tags for annotation of a `Build`. These are not docker tags. + Tags []string `json:"tags,omitempty"` + + // Timeout: Amount of time that this build should be allowed to run, to + // second granularity. If this amount of time elapses, work on the build + // will cease and the build status will be `TIMEOUT`. `timeout` starts + // ticking from `startTime`. Default time is 60 minutes. + Timeout string `json:"timeout,omitempty"` + + // Timing: Output only. Stores timing information for phases of the + // build. Valid keys are: * BUILD: time to execute all build steps. * + // PUSH: time to push all artifacts including docker images and non + // docker artifacts. * FETCHSOURCE: time to fetch source. * SETUPBUILD: + // time to set up build. If the build does not specify source or images, + // these keys will not be included. + Timing map[string]GoogleDevtoolsCloudbuildV1TimeSpan `json:"timing,omitempty"` + + // Warnings: Output only. Non-fatal problems encountered during the + // execution of the build. + Warnings []*GoogleDevtoolsCloudbuildV1Warning `json:"warnings,omitempty"` + + // ForceSendFields is a list of field names (e.g. "Approval") 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. "Approval") 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 *GoogleDevtoolsCloudbuildV1Build) MarshalJSON() ([]byte, error) { + type NoMethod GoogleDevtoolsCloudbuildV1Build + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + +// GoogleDevtoolsCloudbuildV1BuildApproval: BuildApproval describes a +// build's approval configuration, state, and result. +type GoogleDevtoolsCloudbuildV1BuildApproval struct { + // Config: Output only. Configuration for manual approval of this build. + Config *GoogleDevtoolsCloudbuildV1ApprovalConfig `json:"config,omitempty"` + + // Result: Output only. Result of manual approval for this Build. + Result *GoogleDevtoolsCloudbuildV1ApprovalResult `json:"result,omitempty"` + + // State: Output only. The state of this build's approval. + // + // Possible values: + // "STATE_UNSPECIFIED" - Default enum type. This should not be used. + // "PENDING" - Build approval is pending. + // "APPROVED" - Build approval has been approved. + // "REJECTED" - Build approval has been rejected. + // "CANCELLED" - Build was cancelled while it was still pending + // approval. + State string `json:"state,omitempty"` + + // ForceSendFields is a list of field names (e.g. "Config") to + // unconditionally include in API requests. By default, fields with + // empty or default values are omitted from API requests. However, any + // non-pointer, non-interface field appearing in ForceSendFields will be + // sent to the server regardless of whether the field is empty or not. + // This may be used to include empty fields in Patch requests. + ForceSendFields []string `json:"-"` + + // NullFields is a list of field names (e.g. "Config") to include in API + // requests with the JSON null value. By default, fields with empty + // values are omitted from API requests. However, any field with an + // empty value appearing in NullFields will be sent to the server as + // null. It is an error if a field in this list has a non-empty value. + // This may be used to include null fields in Patch requests. + NullFields []string `json:"-"` +} + +func (s *GoogleDevtoolsCloudbuildV1BuildApproval) MarshalJSON() ([]byte, error) { + type NoMethod GoogleDevtoolsCloudbuildV1BuildApproval + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + +// GoogleDevtoolsCloudbuildV1BuildOperationMetadata: Metadata for build +// operations. +type GoogleDevtoolsCloudbuildV1BuildOperationMetadata struct { + // Build: The build that the operation is tracking. + Build *GoogleDevtoolsCloudbuildV1Build `json:"build,omitempty"` + + // ForceSendFields is a list of field names (e.g. "Build") 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. "Build") 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 *GoogleDevtoolsCloudbuildV1BuildOperationMetadata) MarshalJSON() ([]byte, error) { + type NoMethod GoogleDevtoolsCloudbuildV1BuildOperationMetadata + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + +// GoogleDevtoolsCloudbuildV1BuildOptions: Optional arguments to enable +// specific features of builds. +type GoogleDevtoolsCloudbuildV1BuildOptions struct { + // AutomapSubstitutions: Option to include built-in and custom + // substitutions as env variables for all build steps. + AutomapSubstitutions bool `json:"automapSubstitutions,omitempty"` + + // DefaultLogsBucketBehavior: Optional. Option to specify how default + // logs buckets are setup. + // + // Possible values: + // "DEFAULT_LOGS_BUCKET_BEHAVIOR_UNSPECIFIED" - Unspecified. + // "REGIONAL_USER_OWNED_BUCKET" - Bucket is located in user-owned + // project in the same region as the build. The builder service account + // must have access to create and write to Cloud Storage buckets in the + // build project. + DefaultLogsBucketBehavior string `json:"defaultLogsBucketBehavior,omitempty"` + + // DiskSizeGb: Requested disk size for the VM that runs the build. Note + // that this is *NOT* "disk free"; some of the space will be used by the + // operating system and build utilities. Also note that this is the + // minimum disk size that will be allocated for the build -- the build + // may run with a larger disk than requested. At present, the maximum + // disk size is 2000GB; builds that request more than the maximum are + // rejected with an error. + DiskSizeGb int64 `json:"diskSizeGb,omitempty,string"` + + // DynamicSubstitutions: Option to specify whether or not to apply bash + // style string operations to the substitutions. NOTE: this is always + // enabled for triggered builds and cannot be overridden in the build + // configuration file. + DynamicSubstitutions bool `json:"dynamicSubstitutions,omitempty"` + + // Env: A list of global environment variable definitions that will + // exist for all build steps in this build. If a variable is defined in + // both globally and in a build step, the variable will use the build + // step value. The elements are of the form "KEY=VALUE" for the + // environment variable "KEY" being given the value "VALUE". + Env []string `json:"env,omitempty"` + + // LogStreamingOption: Option to define build log streaming behavior to + // Cloud Storage. + // + // Possible values: + // "STREAM_DEFAULT" - Service may automatically determine build log + // streaming behavior. + // "STREAM_ON" - Build logs should be streamed to Cloud Storage. + // "STREAM_OFF" - Build logs should not be streamed to Cloud Storage; + // they will be written when the build is completed. + LogStreamingOption string `json:"logStreamingOption,omitempty"` + + // Logging: Option to specify the logging mode, which determines if and + // where build logs are stored. + // + // Possible values: + // "LOGGING_UNSPECIFIED" - The service determines the logging mode. + // The default is `LEGACY`. Do not rely on the default logging behavior + // as it may change in the future. + // "LEGACY" - Build logs are stored in Cloud Logging and Cloud + // Storage. + // "GCS_ONLY" - Build logs are stored in Cloud Storage. + // "STACKDRIVER_ONLY" - This option is the same as CLOUD_LOGGING_ONLY. + // "CLOUD_LOGGING_ONLY" - Build logs are stored in Cloud Logging. + // Selecting this option will not allow [logs + // streaming](https://cloud.google.com/sdk/gcloud/reference/builds/log). + // "NONE" - Turn off all logging. No build logs will be captured. + Logging string `json:"logging,omitempty"` + + // MachineType: Compute Engine machine type on which to run the build. + // + // Possible values: + // "UNSPECIFIED" - Standard machine type. + // "N1_HIGHCPU_8" - Highcpu machine with 8 CPUs. + // "N1_HIGHCPU_32" - Highcpu machine with 32 CPUs. + // "E2_HIGHCPU_8" - Highcpu e2 machine with 8 CPUs. + // "E2_HIGHCPU_32" - Highcpu e2 machine with 32 CPUs. + // "E2_MEDIUM" - E2 machine with 1 CPU. + MachineType string `json:"machineType,omitempty"` + + // Pool: Optional. Specification for execution on a `WorkerPool`. See + // running builds in a private pool + // (https://cloud.google.com/build/docs/private-pools/run-builds-in-private-pool) + // for more information. + Pool *GoogleDevtoolsCloudbuildV1PoolOption `json:"pool,omitempty"` + + // RequestedVerifyOption: Requested verifiability options. + // + // Possible values: + // "NOT_VERIFIED" - Not a verifiable build (the default). + // "VERIFIED" - Build must be verified. + RequestedVerifyOption string `json:"requestedVerifyOption,omitempty"` + + // SecretEnv: A list of global environment variables, which are + // encrypted using a Cloud Key Management Service crypto key. These + // values must be specified in the build's `Secret`. These variables + // will be available to all build steps in this build. + SecretEnv []string `json:"secretEnv,omitempty"` + + // SourceProvenanceHash: Requested hash for SourceProvenance. + // + // Possible values: + // "NONE" - No hash requested. + // "SHA256" - Use a sha256 hash. + // "MD5" - Use a md5 hash. + // "SHA512" - Use a sha512 hash. + SourceProvenanceHash []string `json:"sourceProvenanceHash,omitempty"` + + // SubstitutionOption: Option to specify behavior when there is an error + // in the substitution checks. NOTE: this is always set to ALLOW_LOOSE + // for triggered builds and cannot be overridden in the build + // configuration file. + // + // Possible values: + // "MUST_MATCH" - Fails the build if error in substitutions checks, + // like missing a substitution in the template or in the map. + // "ALLOW_LOOSE" - Do not fail the build if error in substitutions + // checks. + SubstitutionOption string `json:"substitutionOption,omitempty"` + + // Volumes: Global list of volumes to mount for ALL build steps Each + // volume is created as an empty volume prior to starting the build + // process. Upon completion of the build, volumes and their contents are + // discarded. Global volume names and paths cannot conflict with the + // volumes defined a build step. Using a global volume in a build with + // only one step is not valid as it is indicative of a build request + // with an incorrect configuration. + Volumes []*GoogleDevtoolsCloudbuildV1Volume `json:"volumes,omitempty"` + + // WorkerPool: This field deprecated; please use `pool.name` instead. + WorkerPool string `json:"workerPool,omitempty"` + + // ForceSendFields is a list of field names (e.g. + // "AutomapSubstitutions") 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. "AutomapSubstitutions") 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 *GoogleDevtoolsCloudbuildV1BuildOptions) MarshalJSON() ([]byte, error) { + type NoMethod GoogleDevtoolsCloudbuildV1BuildOptions + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + +// GoogleDevtoolsCloudbuildV1BuildStep: A step in the build pipeline. +type GoogleDevtoolsCloudbuildV1BuildStep struct { + // AllowExitCodes: Allow this build step to fail without failing the + // entire build if and only if the exit code is one of the specified + // codes. If allow_failure is also specified, this field will take + // precedence. + AllowExitCodes []int64 `json:"allowExitCodes,omitempty"` + + // AllowFailure: Allow this build step to fail without failing the + // entire build. If false, the entire build will fail if this step + // fails. Otherwise, the build will succeed, but this step will still + // have a failure status. Error information will be reported in the + // failure_detail field. + AllowFailure bool `json:"allowFailure,omitempty"` + + // Args: A list of arguments that will be presented to the step when it + // is started. If the image used to run the step's container has an + // entrypoint, the `args` are used as arguments to that entrypoint. If + // the image does not define an entrypoint, the first element in args is + // used as the entrypoint, and the remainder will be used as arguments. + Args []string `json:"args,omitempty"` + + // AutomapSubstitutions: Option to include built-in and custom + // substitutions as env variables for this build step. This option will + // override the global option in BuildOption. + AutomapSubstitutions bool `json:"automapSubstitutions,omitempty"` + + // Dir: Working directory to use when running this step's container. If + // this value is a relative path, it is relative to the build's working + // directory. If this value is absolute, it may be outside the build's + // working directory, in which case the contents of the path may not be + // persisted across build step executions, unless a `volume` for that + // path is specified. If the build specifies a `RepoSource` with `dir` + // and a step with a `dir`, which specifies an absolute path, the + // `RepoSource` `dir` is ignored for the step's execution. + Dir string `json:"dir,omitempty"` + + // Entrypoint: Entrypoint to be used instead of the build step image's + // default entrypoint. If unset, the image's default entrypoint is used. + Entrypoint string `json:"entrypoint,omitempty"` + + // Env: A list of environment variable definitions to be used when + // running a step. The elements are of the form "KEY=VALUE" for the + // environment variable "KEY" being given the value "VALUE". + Env []string `json:"env,omitempty"` + + // ExitCode: Output only. Return code from running the step. + ExitCode int64 `json:"exitCode,omitempty"` + + // Id: Unique identifier for this build step, used in `wait_for` to + // reference this build step as a dependency. + Id string `json:"id,omitempty"` + + // Name: Required. The name of the container image that will run this + // particular build step. If the image is available in the host's Docker + // daemon's cache, it will be run directly. If not, the host will + // attempt to pull the image first, using the builder service account's + // credentials if necessary. The Docker daemon's cache will already have + // the latest versions of all of the officially supported build steps + // (https://github.com/GoogleCloudPlatform/cloud-builders + // (https://github.com/GoogleCloudPlatform/cloud-builders)). The Docker + // daemon will also have cached many of the layers for some popular + // images, like "ubuntu", "debian", but they will be refreshed at the + // time you attempt to use them. If you built an image in a previous + // build step, it will be stored in the host's Docker daemon's cache and + // is available to use as the name for a later build step. + Name string `json:"name,omitempty"` + + // PullTiming: Output only. Stores timing information for pulling this + // build step's builder image only. + PullTiming *GoogleDevtoolsCloudbuildV1TimeSpan `json:"pullTiming,omitempty"` + + // Script: A shell script to be executed in the step. When script is + // provided, the user cannot specify the entrypoint or args. + Script string `json:"script,omitempty"` + + // SecretEnv: A list of environment variables which are encrypted using + // a Cloud Key Management Service crypto key. These values must be + // specified in the build's `Secret`. + SecretEnv []string `json:"secretEnv,omitempty"` + + // Status: Output only. Status of the build step. At this time, build + // step status is only updated on build completion; step status is not + // updated in real-time as the build progresses. + // + // Possible values: + // "STATUS_UNKNOWN" - Status of the build is unknown. + // "PENDING" - Build has been created and is pending execution and + // queuing. It has not been queued. + // "QUEUED" - Build or step is queued; work has not yet begun. + // "WORKING" - Build or step is being executed. + // "SUCCESS" - Build or step finished successfully. + // "FAILURE" - Build or step failed to complete successfully. + // "INTERNAL_ERROR" - Build or step failed due to an internal cause. + // "TIMEOUT" - Build or step took longer than was allowed. + // "CANCELLED" - Build or step was canceled by a user. + // "EXPIRED" - Build was enqueued for longer than the value of + // `queue_ttl`. + Status string `json:"status,omitempty"` + + // Timeout: Time limit for executing this build step. If not defined, + // the step has no time limit and will be allowed to continue to run + // until either it completes or the build itself times out. + Timeout string `json:"timeout,omitempty"` + + // Timing: Output only. Stores timing information for executing this + // build step. + Timing *GoogleDevtoolsCloudbuildV1TimeSpan `json:"timing,omitempty"` + + // Volumes: List of volumes to mount into the build step. Each volume is + // created as an empty volume prior to execution of the build step. Upon + // completion of the build, volumes and their contents are discarded. + // Using a named volume in only one step is not valid as it is + // indicative of a build request with an incorrect configuration. + Volumes []*GoogleDevtoolsCloudbuildV1Volume `json:"volumes,omitempty"` + + // WaitFor: The ID(s) of the step(s) that this build step depends on. + // This build step will not start until all the build steps in + // `wait_for` have completed successfully. If `wait_for` is empty, this + // build step will start when all previous build steps in the + // `Build.Steps` list have completed successfully. + WaitFor []string `json:"waitFor,omitempty"` + + // ForceSendFields is a list of field names (e.g. "AllowExitCodes") 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. "AllowExitCodes") 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 *GoogleDevtoolsCloudbuildV1BuildStep) MarshalJSON() ([]byte, error) { + type NoMethod GoogleDevtoolsCloudbuildV1BuildStep + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + +// GoogleDevtoolsCloudbuildV1BuiltImage: An image built by the pipeline. +type GoogleDevtoolsCloudbuildV1BuiltImage struct { + // Digest: Docker Registry 2.0 digest. + Digest string `json:"digest,omitempty"` + + // Name: Name used to push the container image to Google Container + // Registry, as presented to `docker push`. + Name string `json:"name,omitempty"` + + // PushTiming: Output only. Stores timing information for pushing the + // specified image. + PushTiming *GoogleDevtoolsCloudbuildV1TimeSpan `json:"pushTiming,omitempty"` + + // ForceSendFields is a list of field names (e.g. "Digest") 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. "Digest") 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 *GoogleDevtoolsCloudbuildV1BuiltImage) MarshalJSON() ([]byte, error) { + type NoMethod GoogleDevtoolsCloudbuildV1BuiltImage + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + +// GoogleDevtoolsCloudbuildV1ConnectedRepository: Location of the source +// in a 2nd-gen Google Cloud Build repository resource. +type GoogleDevtoolsCloudbuildV1ConnectedRepository struct { + // Dir: Directory, relative to the source root, in which to run the + // build. + Dir string `json:"dir,omitempty"` + + // Repository: Required. Name of the Google Cloud Build repository, + // formatted as `projects/*/locations/*/connections/*/repositories/*`. + Repository string `json:"repository,omitempty"` + + // Revision: The revision to fetch from the Git repository such as a + // branch, a tag, a commit SHA, or any Git ref. + Revision string `json:"revision,omitempty"` + + // ForceSendFields is a list of field names (e.g. "Dir") 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. "Dir") 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 *GoogleDevtoolsCloudbuildV1ConnectedRepository) MarshalJSON() ([]byte, error) { + type NoMethod GoogleDevtoolsCloudbuildV1ConnectedRepository + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + +// GoogleDevtoolsCloudbuildV1FailureInfo: A fatal problem encountered +// during the execution of the build. +type GoogleDevtoolsCloudbuildV1FailureInfo struct { + // Detail: Explains the failure issue in more detail using hard-coded + // text. + Detail string `json:"detail,omitempty"` + + // Type: The name of the failure. + // + // Possible values: + // "FAILURE_TYPE_UNSPECIFIED" - Type unspecified + // "PUSH_FAILED" - Unable to push the image to the repository. + // "PUSH_IMAGE_NOT_FOUND" - Final image not found. + // "PUSH_NOT_AUTHORIZED" - Unauthorized push of the final image. + // "LOGGING_FAILURE" - Backend logging failures. Should retry. + // "USER_BUILD_STEP" - A build step has failed. + // "FETCH_SOURCE_FAILED" - The source fetching has failed. + Type string `json:"type,omitempty"` + + // ForceSendFields is a list of field names (e.g. "Detail") 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. "Detail") 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 *GoogleDevtoolsCloudbuildV1FailureInfo) MarshalJSON() ([]byte, error) { + type NoMethod GoogleDevtoolsCloudbuildV1FailureInfo + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + +// GoogleDevtoolsCloudbuildV1FileHashes: Container message for hashes of +// byte content of files, used in SourceProvenance messages to verify +// integrity of source input to the build. +type GoogleDevtoolsCloudbuildV1FileHashes struct { + // FileHash: Collection of file hashes. + FileHash []*GoogleDevtoolsCloudbuildV1Hash `json:"fileHash,omitempty"` + + // ForceSendFields is a list of field names (e.g. "FileHash") 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. "FileHash") 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 *GoogleDevtoolsCloudbuildV1FileHashes) MarshalJSON() ([]byte, error) { + type NoMethod GoogleDevtoolsCloudbuildV1FileHashes + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + +// GoogleDevtoolsCloudbuildV1GitSource: Location of the source in any +// accessible Git repository. +type GoogleDevtoolsCloudbuildV1GitSource struct { + // Dir: Directory, relative to the source root, in which to run the + // build. This must be a relative path. If a step's `dir` is specified + // and is an absolute path, this value is ignored for that step's + // execution. + Dir string `json:"dir,omitempty"` + + // Revision: The revision to fetch from the Git repository such as a + // branch, a tag, a commit SHA, or any Git ref. Cloud Build uses `git + // fetch` to fetch the revision from the Git repository; therefore make + // sure that the string you provide for `revision` is parsable by the + // command. For information on string values accepted by `git fetch`, + // see https://git-scm.com/docs/gitrevisions#_specifying_revisions. For + // information on `git fetch`, see https://git-scm.com/docs/git-fetch. + Revision string `json:"revision,omitempty"` + + // Url: Location of the Git repo to build. This will be used as a `git + // remote`, see https://git-scm.com/docs/git-remote. + Url string `json:"url,omitempty"` + + // ForceSendFields is a list of field names (e.g. "Dir") 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. "Dir") 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 *GoogleDevtoolsCloudbuildV1GitSource) MarshalJSON() ([]byte, error) { + type NoMethod GoogleDevtoolsCloudbuildV1GitSource + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + +// GoogleDevtoolsCloudbuildV1Hash: Container message for hash values. +type GoogleDevtoolsCloudbuildV1Hash struct { + // Type: The type of hash that was performed. + // + // Possible values: + // "NONE" - No hash requested. + // "SHA256" - Use a sha256 hash. + // "MD5" - Use a md5 hash. + // "SHA512" - Use a sha512 hash. + Type string `json:"type,omitempty"` + + // Value: The hash value. + Value string `json:"value,omitempty"` + + // ForceSendFields is a list of field names (e.g. "Type") 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. "Type") 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 *GoogleDevtoolsCloudbuildV1Hash) MarshalJSON() ([]byte, error) { + type NoMethod GoogleDevtoolsCloudbuildV1Hash + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + +// GoogleDevtoolsCloudbuildV1InlineSecret: Pairs a set of secret +// environment variables mapped to encrypted values with the Cloud KMS +// key to use to decrypt the value. +type GoogleDevtoolsCloudbuildV1InlineSecret struct { + // EnvMap: Map of environment variable name to its encrypted value. + // Secret environment variables must be unique across all of a build's + // secrets, and must be used by at least one build step. Values can be + // at most 64 KB in size. There can be at most 100 secret values across + // all of a build's secrets. + EnvMap map[string]string `json:"envMap,omitempty"` + + // KmsKeyName: Resource name of Cloud KMS crypto key to decrypt the + // encrypted value. In format: + // projects/*/locations/*/keyRings/*/cryptoKeys/* + KmsKeyName string `json:"kmsKeyName,omitempty"` + + // ForceSendFields is a list of field names (e.g. "EnvMap") 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. "EnvMap") 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 *GoogleDevtoolsCloudbuildV1InlineSecret) MarshalJSON() ([]byte, error) { + type NoMethod GoogleDevtoolsCloudbuildV1InlineSecret + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + +// GoogleDevtoolsCloudbuildV1MavenArtifact: A Maven artifact to upload +// to Artifact Registry upon successful completion of all build steps. +type GoogleDevtoolsCloudbuildV1MavenArtifact struct { + // ArtifactId: Maven `artifactId` value used when uploading the artifact + // to Artifact Registry. + ArtifactId string `json:"artifactId,omitempty"` + + // GroupId: Maven `groupId` value used when uploading the artifact to + // Artifact Registry. + GroupId string `json:"groupId,omitempty"` + + // Path: Path to an artifact in the build's workspace to be uploaded to + // Artifact Registry. This can be either an absolute path, e.g. + // /workspace/my-app/target/my-app-1.0.SNAPSHOT.jar or a relative path + // from /workspace, e.g. my-app/target/my-app-1.0.SNAPSHOT.jar. + Path string `json:"path,omitempty"` + + // Repository: Artifact Registry repository, in the form + // "https://$REGION-maven.pkg.dev/$PROJECT/$REPOSITORY" Artifact in the + // workspace specified by path will be uploaded to Artifact Registry + // with this location as a prefix. + Repository string `json:"repository,omitempty"` + + // Version: Maven `version` value used when uploading the artifact to + // Artifact Registry. + Version string `json:"version,omitempty"` + + // ForceSendFields is a list of field names (e.g. "ArtifactId") 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. "ArtifactId") 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 *GoogleDevtoolsCloudbuildV1MavenArtifact) MarshalJSON() ([]byte, error) { + type NoMethod GoogleDevtoolsCloudbuildV1MavenArtifact + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + +// GoogleDevtoolsCloudbuildV1NpmPackage: Npm package to upload to +// Artifact Registry upon successful completion of all build steps. +type GoogleDevtoolsCloudbuildV1NpmPackage struct { + // PackagePath: Path to the package.json. e.g. workspace/path/to/package + PackagePath string `json:"packagePath,omitempty"` + + // Repository: Artifact Registry repository, in the form + // "https://$REGION-npm.pkg.dev/$PROJECT/$REPOSITORY" Npm package in the + // workspace specified by path will be zipped and uploaded to Artifact + // Registry with this location as a prefix. + Repository string `json:"repository,omitempty"` + + // ForceSendFields is a list of field names (e.g. "PackagePath") 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. "PackagePath") 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 *GoogleDevtoolsCloudbuildV1NpmPackage) MarshalJSON() ([]byte, error) { + type NoMethod GoogleDevtoolsCloudbuildV1NpmPackage + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + +// GoogleDevtoolsCloudbuildV1PoolOption: Details about how a build +// should be executed on a `WorkerPool`. See running builds in a private +// pool +// (https://cloud.google.com/build/docs/private-pools/run-builds-in-private-pool) +// for more information. +type GoogleDevtoolsCloudbuildV1PoolOption struct { + // Name: The `WorkerPool` resource to execute the build on. You must + // have `cloudbuild.workerpools.use` on the project hosting the + // WorkerPool. Format + // projects/{project}/locations/{location}/workerPools/{workerPoolId} + Name string `json:"name,omitempty"` + + // ForceSendFields is a list of field names (e.g. "Name") to + // unconditionally include in API requests. By default, fields with + // empty or default values are omitted from API requests. However, any + // non-pointer, non-interface field appearing in ForceSendFields will be + // sent to the server regardless of whether the field is empty or not. + // This may be used to include empty fields in Patch requests. + ForceSendFields []string `json:"-"` + + // NullFields is a list of field names (e.g. "Name") to include in API + // requests with the JSON null value. By default, fields with empty + // values are omitted from API requests. However, any field with an + // empty value appearing in NullFields will be sent to the server as + // null. It is an error if a field in this list has a non-empty value. + // This may be used to include null fields in Patch requests. + NullFields []string `json:"-"` +} + +func (s *GoogleDevtoolsCloudbuildV1PoolOption) MarshalJSON() ([]byte, error) { + type NoMethod GoogleDevtoolsCloudbuildV1PoolOption + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + +// GoogleDevtoolsCloudbuildV1PythonPackage: Python package to upload to +// Artifact Registry upon successful completion of all build steps. A +// package can encapsulate multiple objects to be uploaded to a single +// repository. +type GoogleDevtoolsCloudbuildV1PythonPackage struct { + // Paths: Path globs used to match files in the build's workspace. For + // Python/ Twine, this is usually `dist/*`, and sometimes additionally + // an `.asc` file. + Paths []string `json:"paths,omitempty"` + + // Repository: Artifact Registry repository, in the form + // "https://$REGION-python.pkg.dev/$PROJECT/$REPOSITORY" Files in the + // workspace matching any path pattern will be uploaded to Artifact + // Registry with this location as a prefix. + Repository string `json:"repository,omitempty"` + + // ForceSendFields is a list of field names (e.g. "Paths") 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. "Paths") 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 *GoogleDevtoolsCloudbuildV1PythonPackage) MarshalJSON() ([]byte, error) { + type NoMethod GoogleDevtoolsCloudbuildV1PythonPackage + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + +// GoogleDevtoolsCloudbuildV1RepoSource: Location of the source in a +// Google Cloud Source Repository. +type GoogleDevtoolsCloudbuildV1RepoSource struct { + // BranchName: Regex matching branches to build. The syntax of the + // regular expressions accepted is the syntax accepted by RE2 and + // described at https://github.com/google/re2/wiki/Syntax + BranchName string `json:"branchName,omitempty"` + + // CommitSha: Explicit commit SHA to build. + CommitSha string `json:"commitSha,omitempty"` + + // Dir: Directory, relative to the source root, in which to run the + // build. This must be a relative path. If a step's `dir` is specified + // and is an absolute path, this value is ignored for that step's + // execution. + Dir string `json:"dir,omitempty"` + + // InvertRegex: Only trigger a build if the revision regex does NOT + // match the revision regex. + InvertRegex bool `json:"invertRegex,omitempty"` + + // ProjectId: ID of the project that owns the Cloud Source Repository. + // If omitted, the project ID requesting the build is assumed. + ProjectId string `json:"projectId,omitempty"` + + // RepoName: Name of the Cloud Source Repository. + RepoName string `json:"repoName,omitempty"` + + // Substitutions: Substitutions to use in a triggered build. Should only + // be used with RunBuildTrigger + Substitutions map[string]string `json:"substitutions,omitempty"` + + // TagName: Regex matching tags to build. The syntax of the regular + // expressions accepted is the syntax accepted by RE2 and described at + // https://github.com/google/re2/wiki/Syntax + TagName string `json:"tagName,omitempty"` + + // ForceSendFields is a list of field names (e.g. "BranchName") 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. "BranchName") 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 *GoogleDevtoolsCloudbuildV1RepoSource) MarshalJSON() ([]byte, error) { + type NoMethod GoogleDevtoolsCloudbuildV1RepoSource + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + +// GoogleDevtoolsCloudbuildV1Results: Artifacts created by the build +// pipeline. +type GoogleDevtoolsCloudbuildV1Results struct { + // ArtifactManifest: Path to the artifact manifest for non-container + // artifacts uploaded to Cloud Storage. Only populated when artifacts + // are uploaded to Cloud Storage. + ArtifactManifest string `json:"artifactManifest,omitempty"` + + // ArtifactTiming: Time to push all non-container artifacts to Cloud + // Storage. + ArtifactTiming *GoogleDevtoolsCloudbuildV1TimeSpan `json:"artifactTiming,omitempty"` + + // BuildStepImages: List of build step digests, in the order + // corresponding to build step indices. + BuildStepImages []string `json:"buildStepImages,omitempty"` + + // BuildStepOutputs: List of build step outputs, produced by builder + // images, in the order corresponding to build step indices. Cloud + // Builders (https://cloud.google.com/cloud-build/docs/cloud-builders) + // can produce this output by writing to `$BUILDER_OUTPUT/output`. Only + // the first 50KB of data is stored. + BuildStepOutputs []string `json:"buildStepOutputs,omitempty"` + + // Images: Container images that were built as a part of the build. + Images []*GoogleDevtoolsCloudbuildV1BuiltImage `json:"images,omitempty"` + + // MavenArtifacts: Maven artifacts uploaded to Artifact Registry at the + // end of the build. + MavenArtifacts []*GoogleDevtoolsCloudbuildV1UploadedMavenArtifact `json:"mavenArtifacts,omitempty"` + + // NpmPackages: Npm packages uploaded to Artifact Registry at the end of + // the build. + NpmPackages []*GoogleDevtoolsCloudbuildV1UploadedNpmPackage `json:"npmPackages,omitempty"` + + // NumArtifacts: Number of non-container artifacts uploaded to Cloud + // Storage. Only populated when artifacts are uploaded to Cloud Storage. + NumArtifacts int64 `json:"numArtifacts,omitempty,string"` + + // PythonPackages: Python artifacts uploaded to Artifact Registry at the + // end of the build. + PythonPackages []*GoogleDevtoolsCloudbuildV1UploadedPythonPackage `json:"pythonPackages,omitempty"` + + // ForceSendFields is a list of field names (e.g. "ArtifactManifest") 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. "ArtifactManifest") 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 *GoogleDevtoolsCloudbuildV1Results) MarshalJSON() ([]byte, error) { + type NoMethod GoogleDevtoolsCloudbuildV1Results + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + +// GoogleDevtoolsCloudbuildV1Secret: Pairs a set of secret environment +// variables containing encrypted values with the Cloud KMS key to use +// to decrypt the value. Note: Use `kmsKeyName` with `available_secrets` +// instead of using `kmsKeyName` with `secret`. For instructions see: +// https://cloud.google.com/cloud-build/docs/securing-builds/use-encrypted-credentials. +type GoogleDevtoolsCloudbuildV1Secret struct { + // KmsKeyName: Cloud KMS key name to use to decrypt these envs. + KmsKeyName string `json:"kmsKeyName,omitempty"` + + // SecretEnv: Map of environment variable name to its encrypted value. + // Secret environment variables must be unique across all of a build's + // secrets, and must be used by at least one build step. Values can be + // at most 64 KB in size. There can be at most 100 secret values across + // all of a build's secrets. + SecretEnv map[string]string `json:"secretEnv,omitempty"` + + // ForceSendFields is a list of field names (e.g. "KmsKeyName") 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. "KmsKeyName") 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 *GoogleDevtoolsCloudbuildV1Secret) MarshalJSON() ([]byte, error) { + type NoMethod GoogleDevtoolsCloudbuildV1Secret + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + +// GoogleDevtoolsCloudbuildV1SecretManagerSecret: Pairs a secret +// environment variable with a SecretVersion in Secret Manager. +type GoogleDevtoolsCloudbuildV1SecretManagerSecret struct { + // Env: Environment variable name to associate with the secret. Secret + // environment variables must be unique across all of a build's secrets, + // and must be used by at least one build step. + Env string `json:"env,omitempty"` + + // VersionName: Resource name of the SecretVersion. In format: + // projects/*/secrets/*/versions/* + VersionName string `json:"versionName,omitempty"` + + // ForceSendFields is a list of field names (e.g. "Env") 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. "Env") 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 *GoogleDevtoolsCloudbuildV1SecretManagerSecret) MarshalJSON() ([]byte, error) { + type NoMethod GoogleDevtoolsCloudbuildV1SecretManagerSecret + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + +// GoogleDevtoolsCloudbuildV1Secrets: Secrets and secret environment +// variables. +type GoogleDevtoolsCloudbuildV1Secrets struct { + // Inline: Secrets encrypted with KMS key and the associated secret + // environment variable. + Inline []*GoogleDevtoolsCloudbuildV1InlineSecret `json:"inline,omitempty"` + + // SecretManager: Secrets in Secret Manager and associated secret + // environment variable. + SecretManager []*GoogleDevtoolsCloudbuildV1SecretManagerSecret `json:"secretManager,omitempty"` + + // ForceSendFields is a list of field names (e.g. "Inline") 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. "Inline") 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 *GoogleDevtoolsCloudbuildV1Secrets) MarshalJSON() ([]byte, error) { + type NoMethod GoogleDevtoolsCloudbuildV1Secrets + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + +// GoogleDevtoolsCloudbuildV1Source: Location of the source in a +// supported storage service. +type GoogleDevtoolsCloudbuildV1Source struct { + // ConnectedRepository: Optional. If provided, get the source from this + // 2nd-gen Google Cloud Build repository resource. + ConnectedRepository *GoogleDevtoolsCloudbuildV1ConnectedRepository `json:"connectedRepository,omitempty"` + + // GitSource: If provided, get the source from this Git repository. + GitSource *GoogleDevtoolsCloudbuildV1GitSource `json:"gitSource,omitempty"` + + // RepoSource: If provided, get the source from this location in a Cloud + // Source Repository. + RepoSource *GoogleDevtoolsCloudbuildV1RepoSource `json:"repoSource,omitempty"` + + // StorageSource: If provided, get the source from this location in + // Cloud Storage. + StorageSource *GoogleDevtoolsCloudbuildV1StorageSource `json:"storageSource,omitempty"` + + // StorageSourceManifest: If provided, get the source from this manifest + // in Cloud Storage. This feature is in Preview; see description here + // (https://github.com/GoogleCloudPlatform/cloud-builders/tree/master/gcs-fetcher). + StorageSourceManifest *GoogleDevtoolsCloudbuildV1StorageSourceManifest `json:"storageSourceManifest,omitempty"` + + // ForceSendFields is a list of field names (e.g. "ConnectedRepository") + // 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. "ConnectedRepository") 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 *GoogleDevtoolsCloudbuildV1Source) MarshalJSON() ([]byte, error) { + type NoMethod GoogleDevtoolsCloudbuildV1Source + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + +// GoogleDevtoolsCloudbuildV1SourceProvenance: Provenance of the source. +// Ways to find the original source, or verify that some source was used +// for this build. +type GoogleDevtoolsCloudbuildV1SourceProvenance struct { + // FileHashes: Output only. Hash(es) of the build source, which can be + // used to verify that the original source integrity was maintained in + // the build. Note that `FileHashes` will only be populated if + // `BuildOptions` has requested a `SourceProvenanceHash`. The keys to + // this map are file paths used as build source and the values contain + // the hash values for those files. If the build source came in a single + // package such as a gzipped tarfile (`.tar.gz`), the `FileHash` will be + // for the single path to that file. + FileHashes map[string]GoogleDevtoolsCloudbuildV1FileHashes `json:"fileHashes,omitempty"` + + // ResolvedConnectedRepository: Output only. A copy of the build's + // `source.connected_repository`, if exists, with any revisions + // resolved. + ResolvedConnectedRepository *GoogleDevtoolsCloudbuildV1ConnectedRepository `json:"resolvedConnectedRepository,omitempty"` + + // ResolvedGitSource: Output only. A copy of the build's + // `source.git_source`, if exists, with any revisions resolved. + ResolvedGitSource *GoogleDevtoolsCloudbuildV1GitSource `json:"resolvedGitSource,omitempty"` + + // ResolvedRepoSource: A copy of the build's `source.repo_source`, if + // exists, with any revisions resolved. + ResolvedRepoSource *GoogleDevtoolsCloudbuildV1RepoSource `json:"resolvedRepoSource,omitempty"` + + // ResolvedStorageSource: A copy of the build's `source.storage_source`, + // if exists, with any generations resolved. + ResolvedStorageSource *GoogleDevtoolsCloudbuildV1StorageSource `json:"resolvedStorageSource,omitempty"` + + // ResolvedStorageSourceManifest: A copy of the build's + // `source.storage_source_manifest`, if exists, with any revisions + // resolved. This feature is in Preview. + ResolvedStorageSourceManifest *GoogleDevtoolsCloudbuildV1StorageSourceManifest `json:"resolvedStorageSourceManifest,omitempty"` + + // ForceSendFields is a list of field names (e.g. "FileHashes") 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. "FileHashes") 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 *GoogleDevtoolsCloudbuildV1SourceProvenance) MarshalJSON() ([]byte, error) { + type NoMethod GoogleDevtoolsCloudbuildV1SourceProvenance + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + +// GoogleDevtoolsCloudbuildV1StorageSource: Location of the source in an +// archive file in Cloud Storage. +type GoogleDevtoolsCloudbuildV1StorageSource struct { + // Bucket: Cloud Storage bucket containing the source (see Bucket Name + // Requirements + // (https://cloud.google.com/storage/docs/bucket-naming#requirements)). + Bucket string `json:"bucket,omitempty"` + + // Generation: Cloud Storage generation for the object. If the + // generation is omitted, the latest generation will be used. + Generation int64 `json:"generation,omitempty,string"` + + // Object: Cloud Storage object containing the source. This object must + // be a zipped (`.zip`) or gzipped archive file (`.tar.gz`) containing + // source to build. + Object string `json:"object,omitempty"` + + // SourceFetcher: Optional. Option to specify the tool to fetch the + // source file for the build. + // + // Possible values: + // "SOURCE_FETCHER_UNSPECIFIED" - Unspecified defaults to GSUTIL. + // "GSUTIL" - Use the "gsutil" tool to download the source file. + // "GCS_FETCHER" - Use the Cloud Storage Fetcher tool to download the + // source file. + SourceFetcher string `json:"sourceFetcher,omitempty"` + + // ForceSendFields is a list of field names (e.g. "Bucket") 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. "Bucket") 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 *GoogleDevtoolsCloudbuildV1StorageSource) MarshalJSON() ([]byte, error) { + type NoMethod GoogleDevtoolsCloudbuildV1StorageSource + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + +// GoogleDevtoolsCloudbuildV1StorageSourceManifest: Location of the +// source manifest in Cloud Storage. This feature is in Preview; see +// description here +// (https://github.com/GoogleCloudPlatform/cloud-builders/tree/master/gcs-fetcher). +type GoogleDevtoolsCloudbuildV1StorageSourceManifest struct { + // Bucket: Cloud Storage bucket containing the source manifest (see + // Bucket Name Requirements + // (https://cloud.google.com/storage/docs/bucket-naming#requirements)). + Bucket string `json:"bucket,omitempty"` + + // Generation: Cloud Storage generation for the object. If the + // generation is omitted, the latest generation will be used. + Generation int64 `json:"generation,omitempty,string"` + + // Object: Cloud Storage object containing the source manifest. This + // object must be a JSON file. + Object string `json:"object,omitempty"` + + // ForceSendFields is a list of field names (e.g. "Bucket") 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. "Bucket") 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 *GoogleDevtoolsCloudbuildV1StorageSourceManifest) MarshalJSON() ([]byte, error) { + type NoMethod GoogleDevtoolsCloudbuildV1StorageSourceManifest + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + +// GoogleDevtoolsCloudbuildV1TimeSpan: Start and end times for a build +// execution phase. +type GoogleDevtoolsCloudbuildV1TimeSpan struct { + // EndTime: End of time span. + EndTime string `json:"endTime,omitempty"` + + // StartTime: Start of time span. + StartTime string `json:"startTime,omitempty"` + + // ForceSendFields is a list of field names (e.g. "EndTime") to + // unconditionally include in API requests. By default, fields with + // empty or default values are omitted from API requests. However, any + // non-pointer, non-interface field appearing in ForceSendFields will be + // sent to the server regardless of whether the field is empty or not. + // This may be used to include empty fields in Patch requests. + ForceSendFields []string `json:"-"` + + // NullFields is a list of field names (e.g. "EndTime") to include in + // API requests with the JSON null value. By default, fields with empty + // values are omitted from API requests. However, any field with an + // empty value appearing in NullFields will be sent to the server as + // null. It is an error if a field in this list has a non-empty value. + // This may be used to include null fields in Patch requests. + NullFields []string `json:"-"` +} + +func (s *GoogleDevtoolsCloudbuildV1TimeSpan) MarshalJSON() ([]byte, error) { + type NoMethod GoogleDevtoolsCloudbuildV1TimeSpan + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + +// GoogleDevtoolsCloudbuildV1UploadedMavenArtifact: A Maven artifact +// uploaded using the MavenArtifact directive. +type GoogleDevtoolsCloudbuildV1UploadedMavenArtifact struct { + // FileHashes: Hash types and values of the Maven Artifact. + FileHashes *GoogleDevtoolsCloudbuildV1FileHashes `json:"fileHashes,omitempty"` + + // PushTiming: Output only. Stores timing information for pushing the + // specified artifact. + PushTiming *GoogleDevtoolsCloudbuildV1TimeSpan `json:"pushTiming,omitempty"` + + // Uri: URI of the uploaded artifact. + Uri string `json:"uri,omitempty"` + + // ForceSendFields is a list of field names (e.g. "FileHashes") 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. "FileHashes") 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 *GoogleDevtoolsCloudbuildV1UploadedMavenArtifact) MarshalJSON() ([]byte, error) { + type NoMethod GoogleDevtoolsCloudbuildV1UploadedMavenArtifact + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + +// GoogleDevtoolsCloudbuildV1UploadedNpmPackage: An npm package uploaded +// to Artifact Registry using the NpmPackage directive. +type GoogleDevtoolsCloudbuildV1UploadedNpmPackage struct { + // FileHashes: Hash types and values of the npm package. + FileHashes *GoogleDevtoolsCloudbuildV1FileHashes `json:"fileHashes,omitempty"` + + // PushTiming: Output only. Stores timing information for pushing the + // specified artifact. + PushTiming *GoogleDevtoolsCloudbuildV1TimeSpan `json:"pushTiming,omitempty"` + + // Uri: URI of the uploaded npm package. + Uri string `json:"uri,omitempty"` + + // ForceSendFields is a list of field names (e.g. "FileHashes") 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. "FileHashes") 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 *GoogleDevtoolsCloudbuildV1UploadedNpmPackage) MarshalJSON() ([]byte, error) { + type NoMethod GoogleDevtoolsCloudbuildV1UploadedNpmPackage + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + +// GoogleDevtoolsCloudbuildV1UploadedPythonPackage: Artifact uploaded +// using the PythonPackage directive. +type GoogleDevtoolsCloudbuildV1UploadedPythonPackage struct { + // FileHashes: Hash types and values of the Python Artifact. + FileHashes *GoogleDevtoolsCloudbuildV1FileHashes `json:"fileHashes,omitempty"` + + // PushTiming: Output only. Stores timing information for pushing the + // specified artifact. + PushTiming *GoogleDevtoolsCloudbuildV1TimeSpan `json:"pushTiming,omitempty"` + + // Uri: URI of the uploaded artifact. + Uri string `json:"uri,omitempty"` + + // ForceSendFields is a list of field names (e.g. "FileHashes") 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. "FileHashes") 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 *GoogleDevtoolsCloudbuildV1UploadedPythonPackage) MarshalJSON() ([]byte, error) { + type NoMethod GoogleDevtoolsCloudbuildV1UploadedPythonPackage + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + +// GoogleDevtoolsCloudbuildV1Volume: Volume describes a Docker container +// volume which is mounted into build steps in order to persist files +// across build step execution. +type GoogleDevtoolsCloudbuildV1Volume struct { + // Name: Name of the volume to mount. Volume names must be unique per + // build step and must be valid names for Docker volumes. Each named + // volume must be used by at least two build steps. + Name string `json:"name,omitempty"` + + // Path: Path at which to mount the volume. Paths must be absolute and + // cannot conflict with other volume paths on the same build step or + // with certain reserved volume paths. + Path string `json:"path,omitempty"` + + // ForceSendFields is a list of field names (e.g. "Name") to + // unconditionally include in API requests. By default, fields with + // empty or default values are omitted from API requests. However, any + // non-pointer, non-interface field appearing in ForceSendFields will be + // sent to the server regardless of whether the field is empty or not. + // This may be used to include empty fields in Patch requests. + ForceSendFields []string `json:"-"` + + // NullFields is a list of field names (e.g. "Name") to include in API + // requests with the JSON null value. By default, fields with empty + // values are omitted from API requests. However, any field with an + // empty value appearing in NullFields will be sent to the server as + // null. It is an error if a field in this list has a non-empty value. + // This may be used to include null fields in Patch requests. + NullFields []string `json:"-"` +} + +func (s *GoogleDevtoolsCloudbuildV1Volume) MarshalJSON() ([]byte, error) { + type NoMethod GoogleDevtoolsCloudbuildV1Volume + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + +// GoogleDevtoolsCloudbuildV1Warning: A non-fatal problem encountered +// during the execution of the build. +type GoogleDevtoolsCloudbuildV1Warning struct { + // Priority: The priority for this warning. + // + // Possible values: + // "PRIORITY_UNSPECIFIED" - Should not be used. + // "INFO" - e.g. deprecation warnings and alternative feature + // highlights. + // "WARNING" - e.g. automated detection of possible issues with the + // build. + // "ALERT" - e.g. alerts that a feature used in the build is pending + // removal + Priority string `json:"priority,omitempty"` + + // Text: Explanation of the warning generated. + Text string `json:"text,omitempty"` + + // ForceSendFields is a list of field names (e.g. "Priority") 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. "Priority") 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 *GoogleDevtoolsCloudbuildV1Warning) MarshalJSON() ([]byte, error) { + type NoMethod GoogleDevtoolsCloudbuildV1Warning + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + // GoogleIamV1AuditConfig: Specifies the audit configuration for a // service. The configuration determines which permission types are // logged, and what identities, if any, are exempted from logging. An diff --git a/workspaceevents/v1/workspaceevents-api.json b/workspaceevents/v1/workspaceevents-api.json index 152110ebd5c..06b71aef42d 100644 --- a/workspaceevents/v1/workspaceevents-api.json +++ b/workspaceevents/v1/workspaceevents-api.json @@ -28,6 +28,12 @@ }, "https://www.googleapis.com/auth/chat.spaces.readonly": { "description": "View chat and spaces in Google Chat" + }, + "https://www.googleapis.com/auth/meetings.space.created": { + "description": "Create, edit, and see information about your Google Meet conferences created by the app." + }, + "https://www.googleapis.com/auth/meetings.space.readonly": { + "description": "Read information about any of your Google Meet conferences" } } } @@ -161,7 +167,9 @@ "https://www.googleapis.com/auth/chat.messages.reactions.readonly", "https://www.googleapis.com/auth/chat.messages.readonly", "https://www.googleapis.com/auth/chat.spaces", - "https://www.googleapis.com/auth/chat.spaces.readonly" + "https://www.googleapis.com/auth/chat.spaces.readonly", + "https://www.googleapis.com/auth/meetings.space.created", + "https://www.googleapis.com/auth/meetings.space.readonly" ] } } @@ -196,7 +204,9 @@ "https://www.googleapis.com/auth/chat.messages.reactions.readonly", "https://www.googleapis.com/auth/chat.messages.readonly", "https://www.googleapis.com/auth/chat.spaces", - "https://www.googleapis.com/auth/chat.spaces.readonly" + "https://www.googleapis.com/auth/chat.spaces.readonly", + "https://www.googleapis.com/auth/meetings.space.created", + "https://www.googleapis.com/auth/meetings.space.readonly" ] }, "delete": { @@ -244,7 +254,9 @@ "https://www.googleapis.com/auth/chat.messages.reactions.readonly", "https://www.googleapis.com/auth/chat.messages.readonly", "https://www.googleapis.com/auth/chat.spaces", - "https://www.googleapis.com/auth/chat.spaces.readonly" + "https://www.googleapis.com/auth/chat.spaces.readonly", + "https://www.googleapis.com/auth/meetings.space.created", + "https://www.googleapis.com/auth/meetings.space.readonly" ] }, "get": { @@ -277,7 +289,9 @@ "https://www.googleapis.com/auth/chat.messages.reactions.readonly", "https://www.googleapis.com/auth/chat.messages.readonly", "https://www.googleapis.com/auth/chat.spaces", - "https://www.googleapis.com/auth/chat.spaces.readonly" + "https://www.googleapis.com/auth/chat.spaces.readonly", + "https://www.googleapis.com/auth/meetings.space.created", + "https://www.googleapis.com/auth/meetings.space.readonly" ] }, "list": { @@ -317,7 +331,9 @@ "https://www.googleapis.com/auth/chat.messages.reactions.readonly", "https://www.googleapis.com/auth/chat.messages.readonly", "https://www.googleapis.com/auth/chat.spaces", - "https://www.googleapis.com/auth/chat.spaces.readonly" + "https://www.googleapis.com/auth/chat.spaces.readonly", + "https://www.googleapis.com/auth/meetings.space.created", + "https://www.googleapis.com/auth/meetings.space.readonly" ] }, "patch": { @@ -363,7 +379,9 @@ "https://www.googleapis.com/auth/chat.messages.reactions.readonly", "https://www.googleapis.com/auth/chat.messages.readonly", "https://www.googleapis.com/auth/chat.spaces", - "https://www.googleapis.com/auth/chat.spaces.readonly" + "https://www.googleapis.com/auth/chat.spaces.readonly", + "https://www.googleapis.com/auth/meetings.space.created", + "https://www.googleapis.com/auth/meetings.space.readonly" ] }, "reactivate": { @@ -398,13 +416,15 @@ "https://www.googleapis.com/auth/chat.messages.reactions.readonly", "https://www.googleapis.com/auth/chat.messages.readonly", "https://www.googleapis.com/auth/chat.spaces", - "https://www.googleapis.com/auth/chat.spaces.readonly" + "https://www.googleapis.com/auth/chat.spaces.readonly", + "https://www.googleapis.com/auth/meetings.space.created", + "https://www.googleapis.com/auth/meetings.space.readonly" ] } } } }, - "revision": "20240218", + "revision": "20240305", "rootUrl": "https://workspaceevents.googleapis.com/", "schemas": { "ListSubscriptionsResponse": { diff --git a/workspaceevents/v1/workspaceevents-gen.go b/workspaceevents/v1/workspaceevents-gen.go index 2235a9d1999..8374814995a 100644 --- a/workspaceevents/v1/workspaceevents-gen.go +++ b/workspaceevents/v1/workspaceevents-gen.go @@ -37,7 +37,7 @@ // By default, all available scopes (see "Constants") are used to authenticate. // To restrict scopes, use [google.golang.org/api/option.WithScopes]: // -// workspaceeventsService, err := workspaceevents.NewService(ctx, option.WithScopes(workspaceevents.ChatSpacesReadonlyScope)) +// workspaceeventsService, err := workspaceevents.NewService(ctx, option.WithScopes(workspaceevents.MeetingsSpaceReadonlyScope)) // // To use an API key for authentication (note: some APIs do not support API // keys), use [google.golang.org/api/option.WithAPIKey]: @@ -129,6 +129,13 @@ const ( // View chat and spaces in Google Chat ChatSpacesReadonlyScope = "https://www.googleapis.com/auth/chat.spaces.readonly" + + // Create, edit, and see information about your Google Meet conferences + // created by the app. + MeetingsSpaceCreatedScope = "https://www.googleapis.com/auth/meetings.space.created" + + // Read information about any of your Google Meet conferences + MeetingsSpaceReadonlyScope = "https://www.googleapis.com/auth/meetings.space.readonly" ) // NewService creates a new Service. @@ -143,6 +150,8 @@ func NewService(ctx context.Context, opts ...option.ClientOption) (*Service, err "https://www.googleapis.com/auth/chat.messages.readonly", "https://www.googleapis.com/auth/chat.spaces", "https://www.googleapis.com/auth/chat.spaces.readonly", + "https://www.googleapis.com/auth/meetings.space.created", + "https://www.googleapis.com/auth/meetings.space.readonly", ) // NOTE: prepend, so we don't override user-specified scopes. opts = append([]option.ClientOption{scopesOption}, opts...) @@ -742,7 +751,9 @@ func (c *OperationsGetCall) Do(opts ...googleapi.CallOption) (*Operation, error) // "https://www.googleapis.com/auth/chat.messages.reactions.readonly", // "https://www.googleapis.com/auth/chat.messages.readonly", // "https://www.googleapis.com/auth/chat.spaces", - // "https://www.googleapis.com/auth/chat.spaces.readonly" + // "https://www.googleapis.com/auth/chat.spaces.readonly", + // "https://www.googleapis.com/auth/meetings.space.created", + // "https://www.googleapis.com/auth/meetings.space.readonly" // ] // } @@ -892,7 +903,9 @@ func (c *SubscriptionsCreateCall) Do(opts ...googleapi.CallOption) (*Operation, // "https://www.googleapis.com/auth/chat.messages.reactions.readonly", // "https://www.googleapis.com/auth/chat.messages.readonly", // "https://www.googleapis.com/auth/chat.spaces", - // "https://www.googleapis.com/auth/chat.spaces.readonly" + // "https://www.googleapis.com/auth/chat.spaces.readonly", + // "https://www.googleapis.com/auth/meetings.space.created", + // "https://www.googleapis.com/auth/meetings.space.readonly" // ] // } @@ -1076,7 +1089,9 @@ func (c *SubscriptionsDeleteCall) Do(opts ...googleapi.CallOption) (*Operation, // "https://www.googleapis.com/auth/chat.messages.reactions.readonly", // "https://www.googleapis.com/auth/chat.messages.readonly", // "https://www.googleapis.com/auth/chat.spaces", - // "https://www.googleapis.com/auth/chat.spaces.readonly" + // "https://www.googleapis.com/auth/chat.spaces.readonly", + // "https://www.googleapis.com/auth/meetings.space.created", + // "https://www.googleapis.com/auth/meetings.space.readonly" // ] // } @@ -1235,7 +1250,9 @@ func (c *SubscriptionsGetCall) Do(opts ...googleapi.CallOption) (*Subscription, // "https://www.googleapis.com/auth/chat.messages.reactions.readonly", // "https://www.googleapis.com/auth/chat.messages.readonly", // "https://www.googleapis.com/auth/chat.spaces", - // "https://www.googleapis.com/auth/chat.spaces.readonly" + // "https://www.googleapis.com/auth/chat.spaces.readonly", + // "https://www.googleapis.com/auth/meetings.space.created", + // "https://www.googleapis.com/auth/meetings.space.readonly" // ] // } @@ -1434,7 +1451,9 @@ func (c *SubscriptionsListCall) Do(opts ...googleapi.CallOption) (*ListSubscript // "https://www.googleapis.com/auth/chat.messages.reactions.readonly", // "https://www.googleapis.com/auth/chat.messages.readonly", // "https://www.googleapis.com/auth/chat.spaces", - // "https://www.googleapis.com/auth/chat.spaces.readonly" + // "https://www.googleapis.com/auth/chat.spaces.readonly", + // "https://www.googleapis.com/auth/meetings.space.created", + // "https://www.googleapis.com/auth/meetings.space.readonly" // ] // } @@ -1638,7 +1657,9 @@ func (c *SubscriptionsPatchCall) Do(opts ...googleapi.CallOption) (*Operation, e // "https://www.googleapis.com/auth/chat.messages.reactions.readonly", // "https://www.googleapis.com/auth/chat.messages.readonly", // "https://www.googleapis.com/auth/chat.spaces", - // "https://www.googleapis.com/auth/chat.spaces.readonly" + // "https://www.googleapis.com/auth/chat.spaces.readonly", + // "https://www.googleapis.com/auth/meetings.space.created", + // "https://www.googleapis.com/auth/meetings.space.readonly" // ] // } @@ -1794,7 +1815,9 @@ func (c *SubscriptionsReactivateCall) Do(opts ...googleapi.CallOption) (*Operati // "https://www.googleapis.com/auth/chat.messages.reactions.readonly", // "https://www.googleapis.com/auth/chat.messages.readonly", // "https://www.googleapis.com/auth/chat.spaces", - // "https://www.googleapis.com/auth/chat.spaces.readonly" + // "https://www.googleapis.com/auth/chat.spaces.readonly", + // "https://www.googleapis.com/auth/meetings.space.created", + // "https://www.googleapis.com/auth/meetings.space.readonly" // ] // }