diff --git a/bigqueryconnection/v1beta1/bigqueryconnection-api.json b/bigqueryconnection/v1beta1/bigqueryconnection-api.json index 489589405b0..bad546fecc0 100644 --- a/bigqueryconnection/v1beta1/bigqueryconnection-api.json +++ b/bigqueryconnection/v1beta1/bigqueryconnection-api.json @@ -395,7 +395,7 @@ } } }, - "revision": "20220319", + "revision": "20220415", "rootUrl": "https://bigqueryconnection.googleapis.com/", "schemas": { "AuditConfig": { @@ -455,7 +455,7 @@ "description": "The condition that is associated with this binding. If the condition evaluates to `true`, then this binding applies to the current request. If the condition evaluates to `false`, then this binding does not apply to the current request. However, a different role binding might grant the same role to one or more of the principals in this binding. To learn which resources support conditions in their IAM policies, see the [IAM documentation](https://cloud.google.com/iam/help/conditions/resource-policies)." }, "members": { - "description": "Specifies the principals requesting access for a Cloud Platform resource. `members` can have the following values: * `allUsers`: A special identifier that represents anyone who is on the internet; with or without a Google account. * `allAuthenticatedUsers`: A special identifier that represents anyone who is authenticated with a Google account or a service account. * `user:{emailid}`: An email address that represents a specific Google account. For example, `alice@example.com` . * `serviceAccount:{emailid}`: An email address that represents a service account. For example, `my-other-app@appspot.gserviceaccount.com`. * `group:{emailid}`: An email address that represents a Google group. For example, `admins@example.com`. * `deleted:user:{emailid}?uid={uniqueid}`: An email address (plus unique identifier) representing a user that has been recently deleted. For example, `alice@example.com?uid=123456789012345678901`. If the user is recovered, this value reverts to `user:{emailid}` and the recovered user retains the role in the binding. * `deleted:serviceAccount:{emailid}?uid={uniqueid}`: An email address (plus unique identifier) representing a service account that has been recently deleted. For example, `my-other-app@appspot.gserviceaccount.com?uid=123456789012345678901`. If the service account is undeleted, this value reverts to `serviceAccount:{emailid}` and the undeleted service account retains the role in the binding. * `deleted:group:{emailid}?uid={uniqueid}`: An email address (plus unique identifier) representing a Google group that has been recently deleted. For example, `admins@example.com?uid=123456789012345678901`. If the group is recovered, this value reverts to `group:{emailid}` and the recovered group retains the role in the binding. * `domain:{domain}`: The G Suite domain (primary) that represents all the users of that domain. For example, `google.com` or `example.com`. ", + "description": "Specifies the principals requesting access for a Google Cloud resource. `members` can have the following values: * `allUsers`: A special identifier that represents anyone who is on the internet; with or without a Google account. * `allAuthenticatedUsers`: A special identifier that represents anyone who is authenticated with a Google account or a service account. * `user:{emailid}`: An email address that represents a specific Google account. For example, `alice@example.com` . * `serviceAccount:{emailid}`: An email address that represents a service account. For example, `my-other-app@appspot.gserviceaccount.com`. * `group:{emailid}`: An email address that represents a Google group. For example, `admins@example.com`. * `deleted:user:{emailid}?uid={uniqueid}`: An email address (plus unique identifier) representing a user that has been recently deleted. For example, `alice@example.com?uid=123456789012345678901`. If the user is recovered, this value reverts to `user:{emailid}` and the recovered user retains the role in the binding. * `deleted:serviceAccount:{emailid}?uid={uniqueid}`: An email address (plus unique identifier) representing a service account that has been recently deleted. For example, `my-other-app@appspot.gserviceaccount.com?uid=123456789012345678901`. If the service account is undeleted, this value reverts to `serviceAccount:{emailid}` and the undeleted service account retains the role in the binding. * `deleted:group:{emailid}?uid={uniqueid}`: An email address (plus unique identifier) representing a Google group that has been recently deleted. For example, `admins@example.com?uid=123456789012345678901`. If the group is recovered, this value reverts to `group:{emailid}` and the recovered group retains the role in the binding. * `domain:{domain}`: The G Suite domain (primary) that represents all the users of that domain. For example, `google.com` or `example.com`. ", "items": { "type": "string" }, @@ -674,7 +674,7 @@ "properties": { "policy": { "$ref": "Policy", - "description": "REQUIRED: The complete policy to be applied to the `resource`. The size of the policy is limited to a few 10s of KB. An empty policy is a valid policy but certain Cloud Platform services (such as Projects) might reject them." + "description": "REQUIRED: The complete policy to be applied to the `resource`. The size of the policy is limited to a few 10s of KB. An empty policy is a valid policy but certain Google Cloud services (such as Projects) might reject them." }, "updateMask": { "description": "OPTIONAL: A FieldMask specifying which fields of the policy to modify. Only the fields in the mask will be modified. If no mask is provided, the following default mask is used: `paths: \"bindings, etag\"`", @@ -689,7 +689,7 @@ "id": "TestIamPermissionsRequest", "properties": { "permissions": { - "description": "The set of permissions to check for the `resource`. Permissions with wildcards (such as '*' or 'storage.*') are not allowed. For more information see [IAM Overview](https://cloud.google.com/iam/docs/overview#permissions).", + "description": "The set of permissions to check for the `resource`. Permissions with wildcards (such as `*` or `storage.*`) are not allowed. For more information see [IAM Overview](https://cloud.google.com/iam/docs/overview#permissions).", "items": { "type": "string" }, diff --git a/bigqueryconnection/v1beta1/bigqueryconnection-gen.go b/bigqueryconnection/v1beta1/bigqueryconnection-gen.go index 359e4c478ee..18d1f6dab65 100644 --- a/bigqueryconnection/v1beta1/bigqueryconnection-gen.go +++ b/bigqueryconnection/v1beta1/bigqueryconnection-gen.go @@ -288,8 +288,8 @@ type Binding struct { // (https://cloud.google.com/iam/help/conditions/resource-policies). Condition *Expr `json:"condition,omitempty"` - // Members: Specifies the principals requesting access for a Cloud - // Platform resource. `members` can have the following values: * + // Members: Specifies the principals requesting access for a Google + // Cloud resource. `members` can have the following values: * // `allUsers`: A special identifier that represents anyone who is on the // internet; with or without a Google account. * // `allAuthenticatedUsers`: A special identifier that represents anyone @@ -797,7 +797,7 @@ func (s *Policy) MarshalJSON() ([]byte, error) { type SetIamPolicyRequest struct { // Policy: REQUIRED: The complete policy to be applied to the // `resource`. The size of the policy is limited to a few 10s of KB. An - // empty policy is a valid policy but certain Cloud Platform services + // empty policy is a valid policy but certain Google Cloud services // (such as Projects) might reject them. Policy *Policy `json:"policy,omitempty"` @@ -834,7 +834,7 @@ func (s *SetIamPolicyRequest) MarshalJSON() ([]byte, error) { // method. type TestIamPermissionsRequest struct { // Permissions: The set of permissions to check for the `resource`. - // Permissions with wildcards (such as '*' or 'storage.*') are not + // Permissions with wildcards (such as `*` or `storage.*`) are not // allowed. For more information see IAM Overview // (https://cloud.google.com/iam/docs/overview#permissions). Permissions []string `json:"permissions,omitempty"` diff --git a/bigqueryreservation/v1/bigqueryreservation-api.json b/bigqueryreservation/v1/bigqueryreservation-api.json index 425fa5fb671..64d7564d305 100644 --- a/bigqueryreservation/v1/bigqueryreservation-api.json +++ b/bigqueryreservation/v1/bigqueryreservation-api.json @@ -433,7 +433,7 @@ ], "parameters": { "name": { - "description": "Output only. The resource name of the capacity commitment, e.g., `projects/myproject/locations/US/capacityCommitments/123` For the commitment id, it must only contain lower case alphanumeric characters or dashes.It must start with a letter and must not end with a dash. Its maximum length is 64 characters.", + "description": "Output only. The resource name of the capacity commitment, e.g., `projects/myproject/locations/US/capacityCommitments/123` The commitment_id must only contain lower case alphanumeric characters or dashes. It must start with a letter and must not end with a dash. Its maximum length is 64 characters.", "location": "path", "pattern": "^projects/[^/]+/locations/[^/]+/capacityCommitments/[^/]+$", "required": true, @@ -459,7 +459,7 @@ ] }, "split": { - "description": "Splits capacity commitment to two commitments of the same plan and `commitment_end_time`. A common use case is to enable downgrading commitments. For example, in order to downgrade from 10000 slots to 8000, you might split a 10000 capacity commitment into commitments of 2000 and 8000. Then, you would change the plan of the first one to `FLEX` and then delete it.", + "description": "Splits capacity commitment to two commitments of the same plan and `commitment_end_time`. A common use case is to enable downgrading commitments. For example, in order to downgrade from 10000 slots to 8000, you might split a 10000 capacity commitment into commitments of 2000 and 8000. Then, you delete the first one after the commitment end time passes.", "flatPath": "v1/projects/{projectsId}/locations/{locationsId}/capacityCommitments/{capacityCommitmentsId}:split", "httpMethod": "POST", "id": "bigqueryreservation.projects.locations.capacityCommitments.split", @@ -508,7 +508,7 @@ "type": "string" }, "reservationId": { - "description": "The reservation ID. It must only contain lower case alphanumeric characters or dashes.It must start with a letter and must not end with a dash. Its maximum length is 64 characters.", + "description": "The reservation ID. It must only contain lower case alphanumeric characters or dashes. It must start with a letter and must not end with a dash. Its maximum length is 64 characters.", "location": "query", "type": "string" } @@ -624,7 +624,7 @@ ], "parameters": { "name": { - "description": "The resource name of the reservation, e.g., `projects/*/locations/*/reservations/team1-prod`. For the reservation id, it must only contain lower case alphanumeric characters or dashes.It must start with a letter and must not end with a dash. Its maximum length is 64 characters.", + "description": "The resource name of the reservation, e.g., `projects/*/locations/*/reservations/team1-prod`. The reservation_id must only contain lower case alphanumeric characters or dashes. It must start with a letter and must not end with a dash. Its maximum length is 64 characters.", "location": "path", "pattern": "^projects/[^/]+/locations/[^/]+/reservations/[^/]+$", "required": true, @@ -778,6 +778,41 @@ "https://www.googleapis.com/auth/bigquery", "https://www.googleapis.com/auth/cloud-platform" ] + }, + "patch": { + "description": "Updates an existing assignment. Only the `priority` field can be updated.", + "flatPath": "v1/projects/{projectsId}/locations/{locationsId}/reservations/{reservationsId}/assignments/{assignmentsId}", + "httpMethod": "PATCH", + "id": "bigqueryreservation.projects.locations.reservations.assignments.patch", + "parameterOrder": [ + "name" + ], + "parameters": { + "name": { + "description": "Output only. Name of the resource. E.g.: `projects/myproject/locations/US/reservations/team1-prod/assignments/123`. The assignment_id must only contain lower case alphanumeric characters or dashes and the max length is 64 characters.", + "location": "path", + "pattern": "^projects/[^/]+/locations/[^/]+/reservations/[^/]+/assignments/[^/]+$", + "required": true, + "type": "string" + }, + "updateMask": { + "description": "Standard field mask for the set of fields to be updated.", + "format": "google-fieldmask", + "location": "query", + "type": "string" + } + }, + "path": "v1/{+name}", + "request": { + "$ref": "Assignment" + }, + "response": { + "$ref": "Assignment" + }, + "scopes": [ + "https://www.googleapis.com/auth/bigquery", + "https://www.googleapis.com/auth/cloud-platform" + ] } } } @@ -788,7 +823,7 @@ } } }, - "revision": "20220331", + "revision": "20220415", "rootUrl": "https://bigqueryreservation.googleapis.com/", "schemas": { "Assignment": { @@ -816,7 +851,7 @@ "type": "string" }, "name": { - "description": "Output only. Name of the resource. E.g.: `projects/myproject/locations/US/reservations/team1-prod/assignments/123`. For the assignment id, it must only contain lower case alphanumeric characters or dashes and the max length is 64 characters.", + "description": "Output only. Name of the resource. E.g.: `projects/myproject/locations/US/reservations/team1-prod/assignments/123`. The assignment_id must only contain lower case alphanumeric characters or dashes and the max length is 64 characters.", "readOnly": true, "type": "string" }, @@ -846,6 +881,13 @@ "description": "The resource name of the singleton BI reservation. Reservation names have the form `projects/{project_id}/locations/{location_id}/biReservation`.", "type": "string" }, + "preferredTables": { + "description": "Preferred tables to use BI capacity for.", + "items": { + "$ref": "TableReference" + }, + "type": "array" + }, "size": { "description": "Size of a reservation, in bytes.", "format": "int64", @@ -886,7 +928,7 @@ "type": "boolean" }, "name": { - "description": "Output only. The resource name of the capacity commitment, e.g., `projects/myproject/locations/US/capacityCommitments/123` For the commitment id, it must only contain lower case alphanumeric characters or dashes.It must start with a letter and must not end with a dash. Its maximum length is 64 characters.", + "description": "Output only. The resource name of the capacity commitment, e.g., `projects/myproject/locations/US/capacityCommitments/123` The commitment_id must only contain lower case alphanumeric characters or dashes. It must start with a letter and must not end with a dash. Its maximum length is 64 characters.", "readOnly": true, "type": "string" }, @@ -1060,11 +1102,11 @@ "type": "boolean" }, "name": { - "description": "The resource name of the reservation, e.g., `projects/*/locations/*/reservations/team1-prod`. For the reservation id, it must only contain lower case alphanumeric characters or dashes.It must start with a letter and must not end with a dash. Its maximum length is 64 characters.", + "description": "The resource name of the reservation, e.g., `projects/*/locations/*/reservations/team1-prod`. The reservation_id must only contain lower case alphanumeric characters or dashes. It must start with a letter and must not end with a dash. Its maximum length is 64 characters.", "type": "string" }, "slotCapacity": { - "description": "Minimum slots available to this reservation. A slot is a unit of computational power in BigQuery, and serves as the unit of parallelism. Queries using this reservation might use more slots during runtime if ignore_idle_slots is set to false. If the new reservation's slot capacity exceed the project's slot capacity or if total slot capacity of the new reservation and its siblings exceeds the project's slot capacity, the request will fail with `google.rpc.Code.RESOURCE_EXHAUSTED`. NOTE: for reservations in US or EU multi-regions slot capacity constraints are checked separately for default and auxiliary regions. See multi_region_auxiliary flag for more details.", + "description": "Minimum slots available to this reservation. A slot is a unit of computational power in BigQuery, and serves as the unit of parallelism. Queries using this reservation might use more slots during runtime if ignore_idle_slots is set to false. If the new reservation's slot capacity exceeds the project's slot capacity or if total slot capacity of the new reservation and its siblings exceeds the project's slot capacity, the request will fail with `google.rpc.Code.RESOURCE_EXHAUSTED`. NOTE: for reservations in US or EU multi-regions, slot capacity constraints are checked separately for default and auxiliary regions. See multi_region_auxiliary flag for more details.", "format": "int64", "type": "string" }, @@ -1166,6 +1208,25 @@ } }, "type": "object" + }, + "TableReference": { + "description": "Fully qualified reference to BigQuery table. Internally stored as google.cloud.bi.v1.BqTableReference.", + "id": "TableReference", + "properties": { + "datasetId": { + "description": "The ID of the dataset in the above project.", + "type": "string" + }, + "projectId": { + "description": "The assigned project ID of the project.", + "type": "string" + }, + "tableId": { + "description": "The ID of the table in the above dataset.", + "type": "string" + } + }, + "type": "object" } }, "servicePath": "", diff --git a/bigqueryreservation/v1/bigqueryreservation-gen.go b/bigqueryreservation/v1/bigqueryreservation-gen.go index 4cf7405ba37..56887b81664 100644 --- a/bigqueryreservation/v1/bigqueryreservation-gen.go +++ b/bigqueryreservation/v1/bigqueryreservation-gen.go @@ -225,9 +225,8 @@ type Assignment struct { // Name: Output only. Name of the resource. E.g.: // `projects/myproject/locations/US/reservations/team1-prod/assignments/1 - // 23`. For the assignment id, it must only contain lower case - // alphanumeric characters or dashes and the max length is 64 - // characters. + // 23`. The assignment_id must only contain lower case alphanumeric + // characters or dashes and the max length is 64 characters. Name string `json:"name,omitempty"` // State: Output only. State of the assignment. @@ -273,6 +272,9 @@ type BiReservation struct { // `projects/{project_id}/locations/{location_id}/biReservation`. Name string `json:"name,omitempty"` + // PreferredTables: Preferred tables to use BI capacity for. + PreferredTables []*TableReference `json:"preferredTables,omitempty"` + // Size: Size of a reservation, in bytes. Size int64 `json:"size,omitempty,string"` @@ -334,10 +336,10 @@ type CapacityCommitment struct { MultiRegionAuxiliary bool `json:"multiRegionAuxiliary,omitempty"` // Name: Output only. The resource name of the capacity commitment, - // e.g., `projects/myproject/locations/US/capacityCommitments/123` For - // the commitment id, it must only contain lower case alphanumeric - // characters or dashes.It must start with a letter and must not end - // with a dash. Its maximum length is 64 characters. + // e.g., `projects/myproject/locations/US/capacityCommitments/123` The + // commitment_id must only contain lower case alphanumeric characters or + // dashes. It must start with a letter and must not end with a dash. Its + // maximum length is 64 characters. Name string `json:"name,omitempty"` // Plan: Capacity commitment commitment plan. @@ -653,23 +655,23 @@ type Reservation struct { MultiRegionAuxiliary bool `json:"multiRegionAuxiliary,omitempty"` // Name: The resource name of the reservation, e.g., - // `projects/*/locations/*/reservations/team1-prod`. For the reservation - // id, it must only contain lower case alphanumeric characters or - // dashes.It must start with a letter and must not end with a dash. Its - // maximum length is 64 characters. + // `projects/*/locations/*/reservations/team1-prod`. The reservation_id + // must only contain lower case alphanumeric characters or dashes. It + // must start with a letter and must not end with a dash. Its maximum + // length is 64 characters. Name string `json:"name,omitempty"` // SlotCapacity: Minimum slots available to this reservation. A slot is // a unit of computational power in BigQuery, and serves as the unit of // parallelism. Queries using this reservation might use more slots // during runtime if ignore_idle_slots is set to false. If the new - // reservation's slot capacity exceed the project's slot capacity or if + // reservation's slot capacity exceeds the project's slot capacity or if // total slot capacity of the new reservation and its siblings exceeds // the project's slot capacity, the request will fail with // `google.rpc.Code.RESOURCE_EXHAUSTED`. NOTE: for reservations in US or - // EU multi-regions slot capacity constraints are checked separately for - // default and auxiliary regions. See multi_region_auxiliary flag for - // more details. + // EU multi-regions, slot capacity constraints are checked separately + // for default and auxiliary regions. See multi_region_auxiliary flag + // for more details. SlotCapacity int64 `json:"slotCapacity,omitempty,string"` // UpdateTime: Output only. Last update time of the reservation. @@ -886,6 +888,41 @@ func (s *Status) MarshalJSON() ([]byte, error) { return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } +// TableReference: Fully qualified reference to BigQuery table. +// Internally stored as google.cloud.bi.v1.BqTableReference. +type TableReference struct { + // DatasetId: The ID of the dataset in the above project. + DatasetId string `json:"datasetId,omitempty"` + + // ProjectId: The assigned project ID of the project. + ProjectId string `json:"projectId,omitempty"` + + // TableId: The ID of the table in the above dataset. + TableId string `json:"tableId,omitempty"` + + // ForceSendFields is a list of field names (e.g. "DatasetId") 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. "DatasetId") 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 *TableReference) MarshalJSON() ([]byte, error) { + type NoMethod TableReference + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + // method id "bigqueryreservation.projects.locations.getBiReservation": type ProjectsLocationsGetBiReservationCall struct { @@ -2469,10 +2506,10 @@ type ProjectsLocationsCapacityCommitmentsPatchCall struct { // `google.rpc.Code.FAILED_PRECONDITION`. // // - name: Output only. The resource name of the capacity commitment, -// e.g., `projects/myproject/locations/US/capacityCommitments/123` For -// the commitment id, it must only contain lower case alphanumeric -// characters or dashes.It must start with a letter and must not end -// with a dash. Its maximum length is 64 characters. +// e.g., `projects/myproject/locations/US/capacityCommitments/123` The +// commitment_id must only contain lower case alphanumeric characters +// or dashes. It must start with a letter and must not end with a +// dash. Its maximum length is 64 characters. func (r *ProjectsLocationsCapacityCommitmentsService) Patch(name string, capacitycommitment *CapacityCommitment) *ProjectsLocationsCapacityCommitmentsPatchCall { c := &ProjectsLocationsCapacityCommitmentsPatchCall{s: r.s, urlParams_: make(gensupport.URLParams)} c.name = name @@ -2587,7 +2624,7 @@ func (c *ProjectsLocationsCapacityCommitmentsPatchCall) Do(opts ...googleapi.Cal // ], // "parameters": { // "name": { - // "description": "Output only. The resource name of the capacity commitment, e.g., `projects/myproject/locations/US/capacityCommitments/123` For the commitment id, it must only contain lower case alphanumeric characters or dashes.It must start with a letter and must not end with a dash. Its maximum length is 64 characters.", + // "description": "Output only. The resource name of the capacity commitment, e.g., `projects/myproject/locations/US/capacityCommitments/123` The commitment_id must only contain lower case alphanumeric characters or dashes. It must start with a letter and must not end with a dash. Its maximum length is 64 characters.", // "location": "path", // "pattern": "^projects/[^/]+/locations/[^/]+/capacityCommitments/[^/]+$", // "required": true, @@ -2630,8 +2667,8 @@ type ProjectsLocationsCapacityCommitmentsSplitCall struct { // and `commitment_end_time`. A common use case is to enable downgrading // commitments. For example, in order to downgrade from 10000 slots to // 8000, you might split a 10000 capacity commitment into commitments of -// 2000 and 8000. Then, you would change the plan of the first one to -// `FLEX` and then delete it. +// 2000 and 8000. Then, you delete the first one after the commitment +// end time passes. // // - name: The resource name e.g.,: // `projects/myproject/locations/US/capacityCommitments/123`. @@ -2733,7 +2770,7 @@ func (c *ProjectsLocationsCapacityCommitmentsSplitCall) Do(opts ...googleapi.Cal } return ret, nil // { - // "description": "Splits capacity commitment to two commitments of the same plan and `commitment_end_time`. A common use case is to enable downgrading commitments. For example, in order to downgrade from 10000 slots to 8000, you might split a 10000 capacity commitment into commitments of 2000 and 8000. Then, you would change the plan of the first one to `FLEX` and then delete it.", + // "description": "Splits capacity commitment to two commitments of the same plan and `commitment_end_time`. A common use case is to enable downgrading commitments. For example, in order to downgrade from 10000 slots to 8000, you might split a 10000 capacity commitment into commitments of 2000 and 8000. Then, you delete the first one after the commitment end time passes.", // "flatPath": "v1/projects/{projectsId}/locations/{locationsId}/capacityCommitments/{capacityCommitmentsId}:split", // "httpMethod": "POST", // "id": "bigqueryreservation.projects.locations.capacityCommitments.split", @@ -2787,7 +2824,7 @@ func (r *ProjectsLocationsReservationsService) Create(parent string, reservation // ReservationId sets the optional parameter "reservationId": The // reservation ID. It must only contain lower case alphanumeric -// characters or dashes.It must start with a letter and must not end +// characters or dashes. It must start with a letter and must not end // with a dash. Its maximum length is 64 characters. func (c *ProjectsLocationsReservationsCreateCall) ReservationId(reservationId string) *ProjectsLocationsReservationsCreateCall { c.urlParams_.Set("reservationId", reservationId) @@ -2901,7 +2938,7 @@ func (c *ProjectsLocationsReservationsCreateCall) Do(opts ...googleapi.CallOptio // "type": "string" // }, // "reservationId": { - // "description": "The reservation ID. It must only contain lower case alphanumeric characters or dashes.It must start with a letter and must not end with a dash. Its maximum length is 64 characters.", + // "description": "The reservation ID. It must only contain lower case alphanumeric characters or dashes. It must start with a letter and must not end with a dash. Its maximum length is 64 characters.", // "location": "query", // "type": "string" // } @@ -3414,10 +3451,10 @@ type ProjectsLocationsReservationsPatchCall struct { // Patch: Updates an existing reservation resource. // // - name: The resource name of the reservation, e.g., -// `projects/*/locations/*/reservations/team1-prod`. For the -// reservation id, it must only contain lower case alphanumeric -// characters or dashes.It must start with a letter and must not end -// with a dash. Its maximum length is 64 characters. +// `projects/*/locations/*/reservations/team1-prod`. The +// reservation_id must only contain lower case alphanumeric characters +// or dashes. It must start with a letter and must not end with a +// dash. Its maximum length is 64 characters. func (r *ProjectsLocationsReservationsService) Patch(name string, reservation *Reservation) *ProjectsLocationsReservationsPatchCall { c := &ProjectsLocationsReservationsPatchCall{s: r.s, urlParams_: make(gensupport.URLParams)} c.name = name @@ -3532,7 +3569,7 @@ func (c *ProjectsLocationsReservationsPatchCall) Do(opts ...googleapi.CallOption // ], // "parameters": { // "name": { - // "description": "The resource name of the reservation, e.g., `projects/*/locations/*/reservations/team1-prod`. For the reservation id, it must only contain lower case alphanumeric characters or dashes.It must start with a letter and must not end with a dash. Its maximum length is 64 characters.", + // "description": "The resource name of the reservation, e.g., `projects/*/locations/*/reservations/team1-prod`. The reservation_id must only contain lower case alphanumeric characters or dashes. It must start with a letter and must not end with a dash. Its maximum length is 64 characters.", // "location": "path", // "pattern": "^projects/[^/]+/locations/[^/]+/reservations/[^/]+$", // "required": true, @@ -4236,3 +4273,163 @@ func (c *ProjectsLocationsReservationsAssignmentsMoveCall) Do(opts ...googleapi. // } } + +// method id "bigqueryreservation.projects.locations.reservations.assignments.patch": + +type ProjectsLocationsReservationsAssignmentsPatchCall struct { + s *Service + name string + assignment *Assignment + urlParams_ gensupport.URLParams + ctx_ context.Context + header_ http.Header +} + +// Patch: Updates an existing assignment. Only the `priority` field can +// be updated. +// +// - name: Output only. Name of the resource. E.g.: +// `projects/myproject/locations/US/reservations/team1-prod/assignments +// /123`. The assignment_id must only contain lower case alphanumeric +// characters or dashes and the max length is 64 characters. +func (r *ProjectsLocationsReservationsAssignmentsService) Patch(name string, assignment *Assignment) *ProjectsLocationsReservationsAssignmentsPatchCall { + c := &ProjectsLocationsReservationsAssignmentsPatchCall{s: r.s, urlParams_: make(gensupport.URLParams)} + c.name = name + c.assignment = assignment + return c +} + +// UpdateMask sets the optional parameter "updateMask": Standard field +// mask for the set of fields to be updated. +func (c *ProjectsLocationsReservationsAssignmentsPatchCall) UpdateMask(updateMask string) *ProjectsLocationsReservationsAssignmentsPatchCall { + c.urlParams_.Set("updateMask", updateMask) + return c +} + +// Fields allows partial responses to be retrieved. See +// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse +// for more information. +func (c *ProjectsLocationsReservationsAssignmentsPatchCall) Fields(s ...googleapi.Field) *ProjectsLocationsReservationsAssignmentsPatchCall { + 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 *ProjectsLocationsReservationsAssignmentsPatchCall) Context(ctx context.Context) *ProjectsLocationsReservationsAssignmentsPatchCall { + 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 *ProjectsLocationsReservationsAssignmentsPatchCall) Header() http.Header { + if c.header_ == nil { + c.header_ = make(http.Header) + } + return c.header_ +} + +func (c *ProjectsLocationsReservationsAssignmentsPatchCall) 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.assignment) + if err != nil { + return nil, err + } + reqHeaders.Set("Content-Type", "application/json") + c.urlParams_.Set("alt", alt) + c.urlParams_.Set("prettyPrint", "false") + urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+name}") + urls += "?" + c.urlParams_.Encode() + req, err := http.NewRequest("PATCH", urls, body) + 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 "bigqueryreservation.projects.locations.reservations.assignments.patch" call. +// Exactly one of *Assignment or error will be non-nil. Any non-2xx +// status code is an error. Response headers are in either +// *Assignment.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 *ProjectsLocationsReservationsAssignmentsPatchCall) Do(opts ...googleapi.CallOption) (*Assignment, 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, &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, err + } + ret := &Assignment{ + ServerResponse: googleapi.ServerResponse{ + Header: res.Header, + HTTPStatusCode: res.StatusCode, + }, + } + target := &ret + if err := gensupport.DecodeResponse(target, res); err != nil { + return nil, err + } + return ret, nil + // { + // "description": "Updates an existing assignment. Only the `priority` field can be updated.", + // "flatPath": "v1/projects/{projectsId}/locations/{locationsId}/reservations/{reservationsId}/assignments/{assignmentsId}", + // "httpMethod": "PATCH", + // "id": "bigqueryreservation.projects.locations.reservations.assignments.patch", + // "parameterOrder": [ + // "name" + // ], + // "parameters": { + // "name": { + // "description": "Output only. Name of the resource. E.g.: `projects/myproject/locations/US/reservations/team1-prod/assignments/123`. The assignment_id must only contain lower case alphanumeric characters or dashes and the max length is 64 characters.", + // "location": "path", + // "pattern": "^projects/[^/]+/locations/[^/]+/reservations/[^/]+/assignments/[^/]+$", + // "required": true, + // "type": "string" + // }, + // "updateMask": { + // "description": "Standard field mask for the set of fields to be updated.", + // "format": "google-fieldmask", + // "location": "query", + // "type": "string" + // } + // }, + // "path": "v1/{+name}", + // "request": { + // "$ref": "Assignment" + // }, + // "response": { + // "$ref": "Assignment" + // }, + // "scopes": [ + // "https://www.googleapis.com/auth/bigquery", + // "https://www.googleapis.com/auth/cloud-platform" + // ] + // } + +} diff --git a/bigqueryreservation/v1beta1/bigqueryreservation-api.json b/bigqueryreservation/v1beta1/bigqueryreservation-api.json index 505ac6635ea..69782e80489 100644 --- a/bigqueryreservation/v1beta1/bigqueryreservation-api.json +++ b/bigqueryreservation/v1beta1/bigqueryreservation-api.json @@ -391,7 +391,7 @@ ], "parameters": { "name": { - "description": "Output only. The resource name of the capacity commitment, e.g., `projects/myproject/locations/US/capacityCommitments/123` For the commitment id, it must only contain lower case alphanumeric characters or dashes.It must start with a letter and must not end with a dash. Its maximum length is 64 characters.", + "description": "Output only. The resource name of the capacity commitment, e.g., `projects/myproject/locations/US/capacityCommitments/123` The commitment_id must only contain lower case alphanumeric characters or dashes. It must start with a letter and must not end with a dash. Its maximum length is 64 characters.", "location": "path", "pattern": "^projects/[^/]+/locations/[^/]+/capacityCommitments/[^/]+$", "required": true, @@ -417,7 +417,7 @@ ] }, "split": { - "description": "Splits capacity commitment to two commitments of the same plan and `commitment_end_time`. A common use case is to enable downgrading commitments. For example, in order to downgrade from 10000 slots to 8000, you might split a 10000 capacity commitment into commitments of 2000 and 8000. Then, you would change the plan of the first one to `FLEX` and then delete it.", + "description": "Splits capacity commitment to two commitments of the same plan and `commitment_end_time`. A common use case is to enable downgrading commitments. For example, in order to downgrade from 10000 slots to 8000, you might split a 10000 capacity commitment into commitments of 2000 and 8000. Then, you delete the first one after the commitment end time passes.", "flatPath": "v1beta1/projects/{projectsId}/locations/{locationsId}/capacityCommitments/{capacityCommitmentsId}:split", "httpMethod": "POST", "id": "bigqueryreservation.projects.locations.capacityCommitments.split", @@ -466,7 +466,7 @@ "type": "string" }, "reservationId": { - "description": "The reservation ID. It must only contain lower case alphanumeric characters or dashes.It must start with a letter and must not end with a dash. Its maximum length is 64 characters.", + "description": "The reservation ID. It must only contain lower case alphanumeric characters or dashes. It must start with a letter and must not end with a dash. Its maximum length is 64 characters.", "location": "query", "type": "string" } @@ -587,7 +587,7 @@ ], "parameters": { "name": { - "description": "The resource name of the reservation, e.g., `projects/*/locations/*/reservations/team1-prod`. For the reservation id, it must only contain lower case alphanumeric characters or dashes.It must start with a letter and must not end with a dash. Its maximum length is 64 characters.", + "description": "The resource name of the reservation, e.g., `projects/*/locations/*/reservations/team1-prod`. The reservation_id must only contain lower case alphanumeric characters or dashes. It must start with a letter and must not end with a dash. Its maximum length is 64 characters.", "location": "path", "pattern": "^projects/[^/]+/locations/[^/]+/reservations/[^/]+$", "required": true, @@ -752,7 +752,7 @@ ], "parameters": { "name": { - "description": "Output only. Name of the resource. E.g.: `projects/myproject/locations/US/reservations/team1-prod/assignments/123`. For the assignment id, it must only contain lower case alphanumeric characters or dashes and the max length is 64 characters.", + "description": "Output only. Name of the resource. E.g.: `projects/myproject/locations/US/reservations/team1-prod/assignments/123`. The assignment_id must only contain lower case alphanumeric characters or dashes and the max length is 64 characters.", "location": "path", "pattern": "^projects/[^/]+/locations/[^/]+/reservations/[^/]+/assignments/[^/]+$", "required": true, @@ -786,7 +786,7 @@ } } }, - "revision": "20220319", + "revision": "20220415", "rootUrl": "https://bigqueryreservation.googleapis.com/", "schemas": { "Assignment": { @@ -814,7 +814,7 @@ "type": "string" }, "name": { - "description": "Output only. Name of the resource. E.g.: `projects/myproject/locations/US/reservations/team1-prod/assignments/123`. For the assignment id, it must only contain lower case alphanumeric characters or dashes and the max length is 64 characters.", + "description": "Output only. Name of the resource. E.g.: `projects/myproject/locations/US/reservations/team1-prod/assignments/123`. The assignment_id must only contain lower case alphanumeric characters or dashes and the max length is 64 characters.", "readOnly": true, "type": "string" }, @@ -844,6 +844,13 @@ "description": "The resource name of the singleton BI reservation. Reservation names have the form `projects/{project_id}/locations/{location_id}/biReservation`.", "type": "string" }, + "preferredTables": { + "description": "Preferred tables to use BI capacity for.", + "items": { + "$ref": "TableReference" + }, + "type": "array" + }, "size": { "description": "Size of a reservation, in bytes.", "format": "int64", @@ -884,7 +891,7 @@ "type": "boolean" }, "name": { - "description": "Output only. The resource name of the capacity commitment, e.g., `projects/myproject/locations/US/capacityCommitments/123` For the commitment id, it must only contain lower case alphanumeric characters or dashes.It must start with a letter and must not end with a dash. Its maximum length is 64 characters.", + "description": "Output only. The resource name of the capacity commitment, e.g., `projects/myproject/locations/US/capacityCommitments/123` The commitment_id must only contain lower case alphanumeric characters or dashes. It must start with a letter and must not end with a dash. Its maximum length is 64 characters.", "readOnly": true, "type": "string" }, @@ -1058,11 +1065,11 @@ "type": "boolean" }, "name": { - "description": "The resource name of the reservation, e.g., `projects/*/locations/*/reservations/team1-prod`. For the reservation id, it must only contain lower case alphanumeric characters or dashes.It must start with a letter and must not end with a dash. Its maximum length is 64 characters.", + "description": "The resource name of the reservation, e.g., `projects/*/locations/*/reservations/team1-prod`. The reservation_id must only contain lower case alphanumeric characters or dashes. It must start with a letter and must not end with a dash. Its maximum length is 64 characters.", "type": "string" }, "slotCapacity": { - "description": "Minimum slots available to this reservation. A slot is a unit of computational power in BigQuery, and serves as the unit of parallelism. Queries using this reservation might use more slots during runtime if ignore_idle_slots is set to false. If the new reservation's slot capacity exceed the project's slot capacity or if total slot capacity of the new reservation and its siblings exceeds the project's slot capacity, the request will fail with `google.rpc.Code.RESOURCE_EXHAUSTED`. NOTE: for reservations in US or EU multi-regions slot capacity constraints are checked separately for default and auxiliary regions. See multi_region_auxiliary flag for more details.", + "description": "Minimum slots available to this reservation. A slot is a unit of computational power in BigQuery, and serves as the unit of parallelism. Queries using this reservation might use more slots during runtime if ignore_idle_slots is set to false. If the new reservation's slot capacity exceeds the project's slot capacity or if total slot capacity of the new reservation and its siblings exceeds the project's slot capacity, the request will fail with `google.rpc.Code.RESOURCE_EXHAUSTED`. NOTE: for reservations in US or EU multi-regions, slot capacity constraints are checked separately for default and auxiliary regions. See multi_region_auxiliary flag for more details.", "format": "int64", "type": "string" }, @@ -1146,6 +1153,25 @@ } }, "type": "object" + }, + "TableReference": { + "description": "Fully qualified reference to BigQuery table. Internally stored as google.cloud.bi.v1.BqTableReference.", + "id": "TableReference", + "properties": { + "datasetId": { + "description": "The ID of the dataset in the above project.", + "type": "string" + }, + "projectId": { + "description": "The assigned project ID of the project.", + "type": "string" + }, + "tableId": { + "description": "The ID of the table in the above dataset.", + "type": "string" + } + }, + "type": "object" } }, "servicePath": "", diff --git a/bigqueryreservation/v1beta1/bigqueryreservation-gen.go b/bigqueryreservation/v1beta1/bigqueryreservation-gen.go index 639e59e9ba8..5a5cdd75cc7 100644 --- a/bigqueryreservation/v1beta1/bigqueryreservation-gen.go +++ b/bigqueryreservation/v1beta1/bigqueryreservation-gen.go @@ -225,9 +225,8 @@ type Assignment struct { // Name: Output only. Name of the resource. E.g.: // `projects/myproject/locations/US/reservations/team1-prod/assignments/1 - // 23`. For the assignment id, it must only contain lower case - // alphanumeric characters or dashes and the max length is 64 - // characters. + // 23`. The assignment_id must only contain lower case alphanumeric + // characters or dashes and the max length is 64 characters. Name string `json:"name,omitempty"` // State: Output only. State of the assignment. @@ -273,6 +272,9 @@ type BiReservation struct { // `projects/{project_id}/locations/{location_id}/biReservation`. Name string `json:"name,omitempty"` + // PreferredTables: Preferred tables to use BI capacity for. + PreferredTables []*TableReference `json:"preferredTables,omitempty"` + // Size: Size of a reservation, in bytes. Size int64 `json:"size,omitempty,string"` @@ -334,10 +336,10 @@ type CapacityCommitment struct { MultiRegionAuxiliary bool `json:"multiRegionAuxiliary,omitempty"` // Name: Output only. The resource name of the capacity commitment, - // e.g., `projects/myproject/locations/US/capacityCommitments/123` For - // the commitment id, it must only contain lower case alphanumeric - // characters or dashes.It must start with a letter and must not end - // with a dash. Its maximum length is 64 characters. + // e.g., `projects/myproject/locations/US/capacityCommitments/123` The + // commitment_id must only contain lower case alphanumeric characters or + // dashes. It must start with a letter and must not end with a dash. Its + // maximum length is 64 characters. Name string `json:"name,omitempty"` // Plan: Capacity commitment commitment plan. @@ -653,23 +655,23 @@ type Reservation struct { MultiRegionAuxiliary bool `json:"multiRegionAuxiliary,omitempty"` // Name: The resource name of the reservation, e.g., - // `projects/*/locations/*/reservations/team1-prod`. For the reservation - // id, it must only contain lower case alphanumeric characters or - // dashes.It must start with a letter and must not end with a dash. Its - // maximum length is 64 characters. + // `projects/*/locations/*/reservations/team1-prod`. The reservation_id + // must only contain lower case alphanumeric characters or dashes. It + // must start with a letter and must not end with a dash. Its maximum + // length is 64 characters. Name string `json:"name,omitempty"` // SlotCapacity: Minimum slots available to this reservation. A slot is // a unit of computational power in BigQuery, and serves as the unit of // parallelism. Queries using this reservation might use more slots // during runtime if ignore_idle_slots is set to false. If the new - // reservation's slot capacity exceed the project's slot capacity or if + // reservation's slot capacity exceeds the project's slot capacity or if // total slot capacity of the new reservation and its siblings exceeds // the project's slot capacity, the request will fail with // `google.rpc.Code.RESOURCE_EXHAUSTED`. NOTE: for reservations in US or - // EU multi-regions slot capacity constraints are checked separately for - // default and auxiliary regions. See multi_region_auxiliary flag for - // more details. + // EU multi-regions, slot capacity constraints are checked separately + // for default and auxiliary regions. See multi_region_auxiliary flag + // for more details. SlotCapacity int64 `json:"slotCapacity,omitempty,string"` // UpdateTime: Output only. Last update time of the reservation. @@ -849,6 +851,41 @@ func (s *Status) MarshalJSON() ([]byte, error) { return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } +// TableReference: Fully qualified reference to BigQuery table. +// Internally stored as google.cloud.bi.v1.BqTableReference. +type TableReference struct { + // DatasetId: The ID of the dataset in the above project. + DatasetId string `json:"datasetId,omitempty"` + + // ProjectId: The assigned project ID of the project. + ProjectId string `json:"projectId,omitempty"` + + // TableId: The ID of the table in the above dataset. + TableId string `json:"tableId,omitempty"` + + // ForceSendFields is a list of field names (e.g. "DatasetId") 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. "DatasetId") 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 *TableReference) MarshalJSON() ([]byte, error) { + type NoMethod TableReference + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + // method id "bigqueryreservation.projects.locations.getBiReservation": type ProjectsLocationsGetBiReservationCall struct { @@ -2212,10 +2249,10 @@ type ProjectsLocationsCapacityCommitmentsPatchCall struct { // `google.rpc.Code.FAILED_PRECONDITION`. // // - name: Output only. The resource name of the capacity commitment, -// e.g., `projects/myproject/locations/US/capacityCommitments/123` For -// the commitment id, it must only contain lower case alphanumeric -// characters or dashes.It must start with a letter and must not end -// with a dash. Its maximum length is 64 characters. +// e.g., `projects/myproject/locations/US/capacityCommitments/123` The +// commitment_id must only contain lower case alphanumeric characters +// or dashes. It must start with a letter and must not end with a +// dash. Its maximum length is 64 characters. func (r *ProjectsLocationsCapacityCommitmentsService) Patch(name string, capacitycommitment *CapacityCommitment) *ProjectsLocationsCapacityCommitmentsPatchCall { c := &ProjectsLocationsCapacityCommitmentsPatchCall{s: r.s, urlParams_: make(gensupport.URLParams)} c.name = name @@ -2330,7 +2367,7 @@ func (c *ProjectsLocationsCapacityCommitmentsPatchCall) Do(opts ...googleapi.Cal // ], // "parameters": { // "name": { - // "description": "Output only. The resource name of the capacity commitment, e.g., `projects/myproject/locations/US/capacityCommitments/123` For the commitment id, it must only contain lower case alphanumeric characters or dashes.It must start with a letter and must not end with a dash. Its maximum length is 64 characters.", + // "description": "Output only. The resource name of the capacity commitment, e.g., `projects/myproject/locations/US/capacityCommitments/123` The commitment_id must only contain lower case alphanumeric characters or dashes. It must start with a letter and must not end with a dash. Its maximum length is 64 characters.", // "location": "path", // "pattern": "^projects/[^/]+/locations/[^/]+/capacityCommitments/[^/]+$", // "required": true, @@ -2373,8 +2410,8 @@ type ProjectsLocationsCapacityCommitmentsSplitCall struct { // and `commitment_end_time`. A common use case is to enable downgrading // commitments. For example, in order to downgrade from 10000 slots to // 8000, you might split a 10000 capacity commitment into commitments of -// 2000 and 8000. Then, you would change the plan of the first one to -// `FLEX` and then delete it. +// 2000 and 8000. Then, you delete the first one after the commitment +// end time passes. // // - name: The resource name e.g.,: // `projects/myproject/locations/US/capacityCommitments/123`. @@ -2476,7 +2513,7 @@ func (c *ProjectsLocationsCapacityCommitmentsSplitCall) Do(opts ...googleapi.Cal } return ret, nil // { - // "description": "Splits capacity commitment to two commitments of the same plan and `commitment_end_time`. A common use case is to enable downgrading commitments. For example, in order to downgrade from 10000 slots to 8000, you might split a 10000 capacity commitment into commitments of 2000 and 8000. Then, you would change the plan of the first one to `FLEX` and then delete it.", + // "description": "Splits capacity commitment to two commitments of the same plan and `commitment_end_time`. A common use case is to enable downgrading commitments. For example, in order to downgrade from 10000 slots to 8000, you might split a 10000 capacity commitment into commitments of 2000 and 8000. Then, you delete the first one after the commitment end time passes.", // "flatPath": "v1beta1/projects/{projectsId}/locations/{locationsId}/capacityCommitments/{capacityCommitmentsId}:split", // "httpMethod": "POST", // "id": "bigqueryreservation.projects.locations.capacityCommitments.split", @@ -2530,7 +2567,7 @@ func (r *ProjectsLocationsReservationsService) Create(parent string, reservation // ReservationId sets the optional parameter "reservationId": The // reservation ID. It must only contain lower case alphanumeric -// characters or dashes.It must start with a letter and must not end +// characters or dashes. It must start with a letter and must not end // with a dash. Its maximum length is 64 characters. func (c *ProjectsLocationsReservationsCreateCall) ReservationId(reservationId string) *ProjectsLocationsReservationsCreateCall { c.urlParams_.Set("reservationId", reservationId) @@ -2644,7 +2681,7 @@ func (c *ProjectsLocationsReservationsCreateCall) Do(opts ...googleapi.CallOptio // "type": "string" // }, // "reservationId": { - // "description": "The reservation ID. It must only contain lower case alphanumeric characters or dashes.It must start with a letter and must not end with a dash. Its maximum length is 64 characters.", + // "description": "The reservation ID. It must only contain lower case alphanumeric characters or dashes. It must start with a letter and must not end with a dash. Its maximum length is 64 characters.", // "location": "query", // "type": "string" // } @@ -3172,10 +3209,10 @@ type ProjectsLocationsReservationsPatchCall struct { // Patch: Updates an existing reservation resource. // // - name: The resource name of the reservation, e.g., -// `projects/*/locations/*/reservations/team1-prod`. For the -// reservation id, it must only contain lower case alphanumeric -// characters or dashes.It must start with a letter and must not end -// with a dash. Its maximum length is 64 characters. +// `projects/*/locations/*/reservations/team1-prod`. The +// reservation_id must only contain lower case alphanumeric characters +// or dashes. It must start with a letter and must not end with a +// dash. Its maximum length is 64 characters. func (r *ProjectsLocationsReservationsService) Patch(name string, reservation *Reservation) *ProjectsLocationsReservationsPatchCall { c := &ProjectsLocationsReservationsPatchCall{s: r.s, urlParams_: make(gensupport.URLParams)} c.name = name @@ -3290,7 +3327,7 @@ func (c *ProjectsLocationsReservationsPatchCall) Do(opts ...googleapi.CallOption // ], // "parameters": { // "name": { - // "description": "The resource name of the reservation, e.g., `projects/*/locations/*/reservations/team1-prod`. For the reservation id, it must only contain lower case alphanumeric characters or dashes.It must start with a letter and must not end with a dash. Its maximum length is 64 characters.", + // "description": "The resource name of the reservation, e.g., `projects/*/locations/*/reservations/team1-prod`. The reservation_id must only contain lower case alphanumeric characters or dashes. It must start with a letter and must not end with a dash. Its maximum length is 64 characters.", // "location": "path", // "pattern": "^projects/[^/]+/locations/[^/]+/reservations/[^/]+$", // "required": true, @@ -4011,9 +4048,8 @@ type ProjectsLocationsReservationsAssignmentsPatchCall struct { // // - name: Output only. Name of the resource. E.g.: // `projects/myproject/locations/US/reservations/team1-prod/assignments -// /123`. For the assignment id, it must only contain lower case -// alphanumeric characters or dashes and the max length is 64 -// characters. +// /123`. The assignment_id must only contain lower case alphanumeric +// characters or dashes and the max length is 64 characters. func (r *ProjectsLocationsReservationsAssignmentsService) Patch(name string, assignment *Assignment) *ProjectsLocationsReservationsAssignmentsPatchCall { c := &ProjectsLocationsReservationsAssignmentsPatchCall{s: r.s, urlParams_: make(gensupport.URLParams)} c.name = name @@ -4128,7 +4164,7 @@ func (c *ProjectsLocationsReservationsAssignmentsPatchCall) Do(opts ...googleapi // ], // "parameters": { // "name": { - // "description": "Output only. Name of the resource. E.g.: `projects/myproject/locations/US/reservations/team1-prod/assignments/123`. For the assignment id, it must only contain lower case alphanumeric characters or dashes and the max length is 64 characters.", + // "description": "Output only. Name of the resource. E.g.: `projects/myproject/locations/US/reservations/team1-prod/assignments/123`. The assignment_id must only contain lower case alphanumeric characters or dashes and the max length is 64 characters.", // "location": "path", // "pattern": "^projects/[^/]+/locations/[^/]+/reservations/[^/]+/assignments/[^/]+$", // "required": true, diff --git a/chat/v1/chat-api.json b/chat/v1/chat-api.json index 8599a86289a..addbf9451f1 100644 --- a/chat/v1/chat-api.json +++ b/chat/v1/chat-api.json @@ -120,7 +120,7 @@ "type": "string" }, "threadKey": { - "description": "Optional. Opaque thread identifier string that can be specified to group messages into a single thread. If this is the first message with a given thread identifier, a new thread is created. Subsequent messages with the same thread identifier will be posted into the same thread. This relieves Chat apps and webhooks from having to store the Google Chat thread ID of a thread (created earlier by them) to post further updates to it. Has no effect if thread field, corresponding to an existing thread, is set in message.", + "description": "Optional. Opaque thread identifier. To start or add to a thread, create a message and specify a `threadKey` instead of thread.name. (Setting thread.name has no effect.) The first message with a given `threadKey` starts a new thread. Subsequent messages with the same `threadKey` post into the same thread.", "location": "query", "type": "string" } @@ -155,7 +155,7 @@ "type": "string" }, "threadKey": { - "description": "Optional. Opaque thread identifier string that can be specified to group messages into a single thread. If this is the first message with a given thread identifier, a new thread is created. Subsequent messages with the same thread identifier will be posted into the same thread. This relieves Chat apps and webhooks from having to store the Google Chat thread ID of a thread (created earlier by them) to post further updates to it. Has no effect if thread field, corresponding to an existing thread, is set in message.", + "description": "Optional. Opaque thread identifier. To start or add to a thread, create a message and specify a `threadKey` instead of thread.name. (Setting thread.name has no effect.) The first message with a given `threadKey` starts a new thread. Subsequent messages with the same `threadKey` post into the same thread.", "location": "query", "type": "string" } @@ -194,7 +194,7 @@ "type": "string" }, "threadKey": { - "description": "Optional. Opaque thread identifier string that can be specified to group messages into a single thread. If this is the first message with a given thread identifier, a new thread is created. Subsequent messages with the same thread identifier will be posted into the same thread. This relieves Chat apps and webhooks from having to store the Google Chat thread ID of a thread (created earlier by them) to post further updates to it. Has no effect if thread field, corresponding to an existing thread, is set in message.", + "description": "Optional. Opaque thread identifier. To start or add to a thread, create a message and specify a `threadKey` instead of thread.name. (Setting thread.name has no effect.) The first message with a given `threadKey` starts a new thread. Subsequent messages with the same `threadKey` post into the same thread.", "location": "query", "type": "string" } @@ -262,7 +262,7 @@ "type": "string" }, "threadKey": { - "description": "Optional. Opaque thread identifier string that can be specified to group messages into a single thread. If this is the first message with a given thread identifier, a new thread is created. Subsequent messages with the same thread identifier will be posted into the same thread. This relieves Chat apps and webhooks from having to store the Google Chat thread ID of a thread (created earlier by them) to post further updates to it. Has no effect if thread field, corresponding to an existing thread, is set in message.", + "description": "Optional. Opaque thread identifier. To start or add to a thread, create a message and specify a `threadKey` instead of thread.name. (Setting thread.name has no effect.) The first message with a given `threadKey` starts a new thread. Subsequent messages with the same `threadKey` post into the same thread.", "location": "query", "type": "string" } @@ -297,7 +297,7 @@ "type": "string" }, "threadKey": { - "description": "Optional. Opaque thread identifier string that can be specified to group messages into a single thread. If this is the first message with a given thread identifier, a new thread is created. Subsequent messages with the same thread identifier will be posted into the same thread. This relieves Chat apps and webhooks from having to store the Google Chat thread ID of a thread (created earlier by them) to post further updates to it. Has no effect if thread field, corresponding to an existing thread, is set in message.", + "description": "Optional. Opaque thread identifier. To start or add to a thread, create a message and specify a `threadKey` instead of thread.name. (Setting thread.name has no effect.) The first message with a given `threadKey` starts a new thread. Subsequent messages with the same `threadKey` post into the same thread.", "location": "query", "type": "string" } @@ -336,7 +336,7 @@ "type": "string" }, "threadKey": { - "description": "Optional. Opaque thread identifier string that can be specified to group messages into a single thread. If this is the first message with a given thread identifier, a new thread is created. Subsequent messages with the same thread identifier will be posted into the same thread. This relieves Chat apps and webhooks from having to store the Google Chat thread ID of a thread (created earlier by them) to post further updates to it. Has no effect if thread field, corresponding to an existing thread, is set in message.", + "description": "Optional. Opaque thread identifier. To start or add to a thread, create a message and specify a `threadKey` instead of thread.name. (Setting thread.name has no effect.) The first message with a given `threadKey` starts a new thread. Subsequent messages with the same `threadKey` post into the same thread.", "location": "query", "type": "string" } @@ -423,7 +423,7 @@ "type": "string" }, "threadKey": { - "description": "Optional. Opaque thread identifier string that can be specified to group messages into a single thread. If this is the first message with a given thread identifier, a new thread is created. Subsequent messages with the same thread identifier will be posted into the same thread. This relieves Chat apps and webhooks from having to store the Google Chat thread ID of a thread (created earlier by them) to post further updates to it. Has no effect if thread field, corresponding to an existing thread, is set in message.", + "description": "Optional. Opaque thread identifier. To start or add to a thread, create a message and specify a `threadKey` instead of thread.name. (Setting thread.name has no effect.) The first message with a given `threadKey` starts a new thread. Subsequent messages with the same `threadKey` post into the same thread.", "location": "query", "type": "string" } @@ -521,7 +521,7 @@ "type": "string" }, "threadKey": { - "description": "Optional. Opaque thread identifier string that can be specified to group messages into a single thread. If this is the first message with a given thread identifier, a new thread is created. Subsequent messages with the same thread identifier will be posted into the same thread. This relieves Chat apps and webhooks from having to store the Google Chat thread ID of a thread (created earlier by them) to post further updates to it. Has no effect if thread field, corresponding to an existing thread, is set in message.", + "description": "Optional. Opaque thread identifier. To start or add to a thread, create a message and specify a `threadKey` instead of thread.name. (Setting thread.name has no effect.) The first message with a given `threadKey` starts a new thread. Subsequent messages with the same `threadKey` post into the same thread.", "location": "query", "type": "string" } @@ -642,7 +642,7 @@ } } }, - "revision": "20220405", + "revision": "20220415", "rootUrl": "https://chat.googleapis.com/", "schemas": { "ActionParameter": { @@ -940,6 +940,25 @@ }, "type": "object" }, + "ChatAppLogEntry": { + "description": "JSON payload of error messages. If the Cloud Logging API is enabled, these error messages are logged to [Google Cloud Logging](https://cloud.google.com/logging/docs).", + "id": "ChatAppLogEntry", + "properties": { + "deployment": { + "description": "The deployment that caused the error. For Chat bots built in Apps Script, this is the deployment ID defined by Apps Script.", + "type": "string" + }, + "deploymentFunction": { + "description": "The unencrypted `callback_method` name that was running when the error was encountered.", + "type": "string" + }, + "error": { + "$ref": "Status", + "description": "The error code and message." + } + }, + "type": "object" + }, "Color": { "description": "Represents a color in the RGBA color space. This representation is designed for simplicity of conversion to/from color representations in various languages over compactness. For example, the fields of this representation can be trivially provided to the constructor of `java.awt.Color` in Java; it can also be trivially provided to UIColor's `+colorWithRed:green:blue:alpha` method in iOS; and, with just a little work, it can be easily formatted into a CSS `rgba()` string in JavaScript. This reference page doesn't carry information about the absolute color space that should be used to interpret the RGB value (e.g. sRGB, Adobe RGB, DCI-P3, BT.2020, etc.). By default, applications should assume the sRGB color space. When color equality needs to be decided, implementations, unless documented otherwise, treat two colors as equal if all their red, green, blue, and alpha values each differ by at most 1e-5. Example (Java): import com.google.type.Color; // ... public static java.awt.Color fromProto(Color protocolor) { float alpha = protocolor.hasAlpha() ? protocolor.getAlpha().getValue() : 1.0; return new java.awt.Color( protocolor.getRed(), protocolor.getGreen(), protocolor.getBlue(), alpha); } public static Color toProto(java.awt.Color color) { float red = (float) color.getRed(); float green = (float) color.getGreen(); float blue = (float) color.getBlue(); float denominator = 255.0; Color.Builder resultBuilder = Color .newBuilder() .setRed(red / denominator) .setGreen(green / denominator) .setBlue(blue / denominator); int alpha = color.getAlpha(); if (alpha != 255) { result.setAlpha( FloatValue .newBuilder() .setValue(((float) alpha) / denominator) .build()); } return resultBuilder.build(); } // ... Example (iOS / Obj-C): // ... static UIColor* fromProto(Color* protocolor) { float red = [protocolor red]; float green = [protocolor green]; float blue = [protocolor blue]; FloatValue* alpha_wrapper = [protocolor alpha]; float alpha = 1.0; if (alpha_wrapper != nil) { alpha = [alpha_wrapper value]; } return [UIColor colorWithRed:red green:green blue:blue alpha:alpha]; } static Color* toProto(UIColor* color) { CGFloat red, green, blue, alpha; if (![color getRed:\u0026red green:\u0026green blue:\u0026blue alpha:\u0026alpha]) { return nil; } Color* result = [[Color alloc] init]; [result setRed:red]; [result setGreen:green]; [result setBlue:blue]; if (alpha \u003c= 0.9999) { [result setAlpha:floatWrapperWithValue(alpha)]; } [result autorelease]; return result; } // ... Example (JavaScript): // ... var protoToCssColor = function(rgb_color) { var redFrac = rgb_color.red || 0.0; var greenFrac = rgb_color.green || 0.0; var blueFrac = rgb_color.blue || 0.0; var red = Math.floor(redFrac * 255); var green = Math.floor(greenFrac * 255); var blue = Math.floor(blueFrac * 255); if (!('alpha' in rgb_color)) { return rgbToCssColor(red, green, blue); } var alphaFrac = rgb_color.alpha.value || 0.0; var rgbParams = [red, green, blue].join(','); return ['rgba(', rgbParams, ',', alphaFrac, ')'].join(''); }; var rgbToCssColor = function(red, green, blue) { var rgbNumber = new Number((red \u003c\u003c 16) | (green \u003c\u003c 8) | blue); var hexString = rgbNumber.toString(16); var missingZeros = 6 - hexString.length; var resultBuilder = ['#']; for (var i = 0; i \u003c missingZeros; i++) { resultBuilder.push('0'); } resultBuilder.push(hexString); return resultBuilder.join(''); }; // ...", "id": "Color", @@ -1195,25 +1214,6 @@ }, "type": "object" }, - "DynamiteIntegrationLogEntry": { - "description": "JSON payload of error messages. If the Cloud Logging API is enabled, these error messages are logged to [Google Cloud Logging](https://cloud.google.com/logging/docs).", - "id": "DynamiteIntegrationLogEntry", - "properties": { - "deployment": { - "description": "The deployment that caused the error. For Chat bots built in Apps Script, this is the deployment ID defined by Apps Script.", - "type": "string" - }, - "deploymentFunction": { - "description": "The unencrypted `callback_method` name that was running when the error was encountered.", - "type": "string" - }, - "error": { - "$ref": "Status", - "description": "The error code and message." - } - }, - "type": "object" - }, "Empty": { "description": "A generic empty message that you can re-use to avoid defining duplicated empty messages in your APIs. A typical example is to use it as the request or the response type of an API method. For instance: service Foo { rpc Bar(google.protobuf.Empty) returns (google.protobuf.Empty); }", "id": "Empty", @@ -2604,7 +2604,7 @@ "type": "string" }, "name": { - "description": "Optional. Resource name of the space, in the form \"spaces/*\". Example: spaces/AAAAAAAAAAAA", + "description": "Resource name of the space, in the form \"spaces/*\". Example: spaces/AAAAAAAAAAAA", "type": "string" }, "singleUserBotDm": { diff --git a/chat/v1/chat-gen.go b/chat/v1/chat-gen.go index 63862671e11..e2057c3246e 100644 --- a/chat/v1/chat-gen.go +++ b/chat/v1/chat-gen.go @@ -737,6 +737,44 @@ func (s *CardHeader) MarshalJSON() ([]byte, error) { return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } +// ChatAppLogEntry: JSON payload of error messages. If the Cloud Logging +// API is enabled, these error messages are logged to Google Cloud +// Logging (https://cloud.google.com/logging/docs). +type ChatAppLogEntry struct { + // Deployment: The deployment that caused the error. For Chat bots built + // in Apps Script, this is the deployment ID defined by Apps Script. + Deployment string `json:"deployment,omitempty"` + + // DeploymentFunction: The unencrypted `callback_method` name that was + // running when the error was encountered. + DeploymentFunction string `json:"deploymentFunction,omitempty"` + + // Error: The error code and message. + Error *Status `json:"error,omitempty"` + + // ForceSendFields is a list of field names (e.g. "Deployment") 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. "Deployment") 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 *ChatAppLogEntry) MarshalJSON() ([]byte, error) { + type NoMethod ChatAppLogEntry + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + // Color: Represents a color in the RGBA color space. This // representation is designed for simplicity of conversion to/from color // representations in various languages over compactness. For example, @@ -1201,44 +1239,6 @@ func (s *DriveDataRef) MarshalJSON() ([]byte, error) { return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } -// DynamiteIntegrationLogEntry: JSON payload of error messages. If the -// Cloud Logging API is enabled, these error messages are logged to -// Google Cloud Logging (https://cloud.google.com/logging/docs). -type DynamiteIntegrationLogEntry struct { - // Deployment: The deployment that caused the error. For Chat bots built - // in Apps Script, this is the deployment ID defined by Apps Script. - Deployment string `json:"deployment,omitempty"` - - // DeploymentFunction: The unencrypted `callback_method` name that was - // running when the error was encountered. - DeploymentFunction string `json:"deploymentFunction,omitempty"` - - // Error: The error code and message. - Error *Status `json:"error,omitempty"` - - // ForceSendFields is a list of field names (e.g. "Deployment") 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. "Deployment") 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 *DynamiteIntegrationLogEntry) MarshalJSON() ([]byte, error) { - type NoMethod DynamiteIntegrationLogEntry - raw := NoMethod(*s) - return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) -} - // Empty: A generic empty message that you can re-use to avoid defining // duplicated empty messages in your APIs. A typical example is to use // it as the request or the response type of an API method. For @@ -3328,8 +3328,8 @@ type Space struct { // humans, this field might be empty. DisplayName string `json:"displayName,omitempty"` - // Name: Optional. Resource name of the space, in the form "spaces/*". - // Example: spaces/AAAAAAAAAAAA + // Name: Resource name of the space, in the form "spaces/*". Example: + // spaces/AAAAAAAAAAAA Name string `json:"name,omitempty"` // SingleUserBotDm: Output only. Whether the space is a DM between a @@ -3762,14 +3762,11 @@ func (c *DmsMessagesCall) RequestId(requestId string) *DmsMessagesCall { } // ThreadKey sets the optional parameter "threadKey": Opaque thread -// identifier string that can be specified to group messages into a -// single thread. If this is the first message with a given thread -// identifier, a new thread is created. Subsequent messages with the -// same thread identifier will be posted into the same thread. This -// relieves Chat apps and webhooks from having to store the Google Chat -// thread ID of a thread (created earlier by them) to post further -// updates to it. Has no effect if thread field, corresponding to an -// existing thread, is set in message. +// identifier. To start or add to a thread, create a message and specify +// a `threadKey` instead of thread.name. (Setting thread.name has no +// effect.) The first message with a given `threadKey` starts a new +// thread. Subsequent messages with the same `threadKey` post into the +// same thread. func (c *DmsMessagesCall) ThreadKey(threadKey string) *DmsMessagesCall { c.urlParams_.Set("threadKey", threadKey) return c @@ -3887,7 +3884,7 @@ func (c *DmsMessagesCall) Do(opts ...googleapi.CallOption) (*Message, error) { // "type": "string" // }, // "threadKey": { - // "description": "Optional. Opaque thread identifier string that can be specified to group messages into a single thread. If this is the first message with a given thread identifier, a new thread is created. Subsequent messages with the same thread identifier will be posted into the same thread. This relieves Chat apps and webhooks from having to store the Google Chat thread ID of a thread (created earlier by them) to post further updates to it. Has no effect if thread field, corresponding to an existing thread, is set in message.", + // "description": "Optional. Opaque thread identifier. To start or add to a thread, create a message and specify a `threadKey` instead of thread.name. (Setting thread.name has no effect.) The first message with a given `threadKey` starts a new thread. Subsequent messages with the same `threadKey` post into the same thread.", // "location": "query", // "type": "string" // } @@ -3935,14 +3932,11 @@ func (c *DmsWebhooksCall) RequestId(requestId string) *DmsWebhooksCall { } // ThreadKey sets the optional parameter "threadKey": Opaque thread -// identifier string that can be specified to group messages into a -// single thread. If this is the first message with a given thread -// identifier, a new thread is created. Subsequent messages with the -// same thread identifier will be posted into the same thread. This -// relieves Chat apps and webhooks from having to store the Google Chat -// thread ID of a thread (created earlier by them) to post further -// updates to it. Has no effect if thread field, corresponding to an -// existing thread, is set in message. +// identifier. To start or add to a thread, create a message and specify +// a `threadKey` instead of thread.name. (Setting thread.name has no +// effect.) The first message with a given `threadKey` starts a new +// thread. Subsequent messages with the same `threadKey` post into the +// same thread. func (c *DmsWebhooksCall) ThreadKey(threadKey string) *DmsWebhooksCall { c.urlParams_.Set("threadKey", threadKey) return c @@ -4060,7 +4054,7 @@ func (c *DmsWebhooksCall) Do(opts ...googleapi.CallOption) (*Message, error) { // "type": "string" // }, // "threadKey": { - // "description": "Optional. Opaque thread identifier string that can be specified to group messages into a single thread. If this is the first message with a given thread identifier, a new thread is created. Subsequent messages with the same thread identifier will be posted into the same thread. This relieves Chat apps and webhooks from having to store the Google Chat thread ID of a thread (created earlier by them) to post further updates to it. Has no effect if thread field, corresponding to an existing thread, is set in message.", + // "description": "Optional. Opaque thread identifier. To start or add to a thread, create a message and specify a `threadKey` instead of thread.name. (Setting thread.name has no effect.) The first message with a given `threadKey` starts a new thread. Subsequent messages with the same `threadKey` post into the same thread.", // "location": "query", // "type": "string" // } @@ -4108,14 +4102,11 @@ func (c *DmsConversationsMessagesCall) RequestId(requestId string) *DmsConversat } // ThreadKey sets the optional parameter "threadKey": Opaque thread -// identifier string that can be specified to group messages into a -// single thread. If this is the first message with a given thread -// identifier, a new thread is created. Subsequent messages with the -// same thread identifier will be posted into the same thread. This -// relieves Chat apps and webhooks from having to store the Google Chat -// thread ID of a thread (created earlier by them) to post further -// updates to it. Has no effect if thread field, corresponding to an -// existing thread, is set in message. +// identifier. To start or add to a thread, create a message and specify +// a `threadKey` instead of thread.name. (Setting thread.name has no +// effect.) The first message with a given `threadKey` starts a new +// thread. Subsequent messages with the same `threadKey` post into the +// same thread. func (c *DmsConversationsMessagesCall) ThreadKey(threadKey string) *DmsConversationsMessagesCall { c.urlParams_.Set("threadKey", threadKey) return c @@ -4233,7 +4224,7 @@ func (c *DmsConversationsMessagesCall) Do(opts ...googleapi.CallOption) (*Messag // "type": "string" // }, // "threadKey": { - // "description": "Optional. Opaque thread identifier string that can be specified to group messages into a single thread. If this is the first message with a given thread identifier, a new thread is created. Subsequent messages with the same thread identifier will be posted into the same thread. This relieves Chat apps and webhooks from having to store the Google Chat thread ID of a thread (created earlier by them) to post further updates to it. Has no effect if thread field, corresponding to an existing thread, is set in message.", + // "description": "Optional. Opaque thread identifier. To start or add to a thread, create a message and specify a `threadKey` instead of thread.name. (Setting thread.name has no effect.) The first message with a given `threadKey` starts a new thread. Subsequent messages with the same `threadKey` post into the same thread.", // "location": "query", // "type": "string" // } @@ -4443,14 +4434,11 @@ func (c *RoomsMessagesCall) RequestId(requestId string) *RoomsMessagesCall { } // ThreadKey sets the optional parameter "threadKey": Opaque thread -// identifier string that can be specified to group messages into a -// single thread. If this is the first message with a given thread -// identifier, a new thread is created. Subsequent messages with the -// same thread identifier will be posted into the same thread. This -// relieves Chat apps and webhooks from having to store the Google Chat -// thread ID of a thread (created earlier by them) to post further -// updates to it. Has no effect if thread field, corresponding to an -// existing thread, is set in message. +// identifier. To start or add to a thread, create a message and specify +// a `threadKey` instead of thread.name. (Setting thread.name has no +// effect.) The first message with a given `threadKey` starts a new +// thread. Subsequent messages with the same `threadKey` post into the +// same thread. func (c *RoomsMessagesCall) ThreadKey(threadKey string) *RoomsMessagesCall { c.urlParams_.Set("threadKey", threadKey) return c @@ -4568,7 +4556,7 @@ func (c *RoomsMessagesCall) Do(opts ...googleapi.CallOption) (*Message, error) { // "type": "string" // }, // "threadKey": { - // "description": "Optional. Opaque thread identifier string that can be specified to group messages into a single thread. If this is the first message with a given thread identifier, a new thread is created. Subsequent messages with the same thread identifier will be posted into the same thread. This relieves Chat apps and webhooks from having to store the Google Chat thread ID of a thread (created earlier by them) to post further updates to it. Has no effect if thread field, corresponding to an existing thread, is set in message.", + // "description": "Optional. Opaque thread identifier. To start or add to a thread, create a message and specify a `threadKey` instead of thread.name. (Setting thread.name has no effect.) The first message with a given `threadKey` starts a new thread. Subsequent messages with the same `threadKey` post into the same thread.", // "location": "query", // "type": "string" // } @@ -4616,14 +4604,11 @@ func (c *RoomsWebhooksCall) RequestId(requestId string) *RoomsWebhooksCall { } // ThreadKey sets the optional parameter "threadKey": Opaque thread -// identifier string that can be specified to group messages into a -// single thread. If this is the first message with a given thread -// identifier, a new thread is created. Subsequent messages with the -// same thread identifier will be posted into the same thread. This -// relieves Chat apps and webhooks from having to store the Google Chat -// thread ID of a thread (created earlier by them) to post further -// updates to it. Has no effect if thread field, corresponding to an -// existing thread, is set in message. +// identifier. To start or add to a thread, create a message and specify +// a `threadKey` instead of thread.name. (Setting thread.name has no +// effect.) The first message with a given `threadKey` starts a new +// thread. Subsequent messages with the same `threadKey` post into the +// same thread. func (c *RoomsWebhooksCall) ThreadKey(threadKey string) *RoomsWebhooksCall { c.urlParams_.Set("threadKey", threadKey) return c @@ -4741,7 +4726,7 @@ func (c *RoomsWebhooksCall) Do(opts ...googleapi.CallOption) (*Message, error) { // "type": "string" // }, // "threadKey": { - // "description": "Optional. Opaque thread identifier string that can be specified to group messages into a single thread. If this is the first message with a given thread identifier, a new thread is created. Subsequent messages with the same thread identifier will be posted into the same thread. This relieves Chat apps and webhooks from having to store the Google Chat thread ID of a thread (created earlier by them) to post further updates to it. Has no effect if thread field, corresponding to an existing thread, is set in message.", + // "description": "Optional. Opaque thread identifier. To start or add to a thread, create a message and specify a `threadKey` instead of thread.name. (Setting thread.name has no effect.) The first message with a given `threadKey` starts a new thread. Subsequent messages with the same `threadKey` post into the same thread.", // "location": "query", // "type": "string" // } @@ -4789,14 +4774,11 @@ func (c *RoomsConversationsMessagesCall) RequestId(requestId string) *RoomsConve } // ThreadKey sets the optional parameter "threadKey": Opaque thread -// identifier string that can be specified to group messages into a -// single thread. If this is the first message with a given thread -// identifier, a new thread is created. Subsequent messages with the -// same thread identifier will be posted into the same thread. This -// relieves Chat apps and webhooks from having to store the Google Chat -// thread ID of a thread (created earlier by them) to post further -// updates to it. Has no effect if thread field, corresponding to an -// existing thread, is set in message. +// identifier. To start or add to a thread, create a message and specify +// a `threadKey` instead of thread.name. (Setting thread.name has no +// effect.) The first message with a given `threadKey` starts a new +// thread. Subsequent messages with the same `threadKey` post into the +// same thread. func (c *RoomsConversationsMessagesCall) ThreadKey(threadKey string) *RoomsConversationsMessagesCall { c.urlParams_.Set("threadKey", threadKey) return c @@ -4914,7 +4896,7 @@ func (c *RoomsConversationsMessagesCall) Do(opts ...googleapi.CallOption) (*Mess // "type": "string" // }, // "threadKey": { - // "description": "Optional. Opaque thread identifier string that can be specified to group messages into a single thread. If this is the first message with a given thread identifier, a new thread is created. Subsequent messages with the same thread identifier will be posted into the same thread. This relieves Chat apps and webhooks from having to store the Google Chat thread ID of a thread (created earlier by them) to post further updates to it. Has no effect if thread field, corresponding to an existing thread, is set in message.", + // "description": "Optional. Opaque thread identifier. To start or add to a thread, create a message and specify a `threadKey` instead of thread.name. (Setting thread.name has no effect.) The first message with a given `threadKey` starts a new thread. Subsequent messages with the same `threadKey` post into the same thread.", // "location": "query", // "type": "string" // } @@ -5283,14 +5265,11 @@ func (c *SpacesWebhooksCall) RequestId(requestId string) *SpacesWebhooksCall { } // ThreadKey sets the optional parameter "threadKey": Opaque thread -// identifier string that can be specified to group messages into a -// single thread. If this is the first message with a given thread -// identifier, a new thread is created. Subsequent messages with the -// same thread identifier will be posted into the same thread. This -// relieves Chat apps and webhooks from having to store the Google Chat -// thread ID of a thread (created earlier by them) to post further -// updates to it. Has no effect if thread field, corresponding to an -// existing thread, is set in message. +// identifier. To start or add to a thread, create a message and specify +// a `threadKey` instead of thread.name. (Setting thread.name has no +// effect.) The first message with a given `threadKey` starts a new +// thread. Subsequent messages with the same `threadKey` post into the +// same thread. func (c *SpacesWebhooksCall) ThreadKey(threadKey string) *SpacesWebhooksCall { c.urlParams_.Set("threadKey", threadKey) return c @@ -5408,7 +5387,7 @@ func (c *SpacesWebhooksCall) Do(opts ...googleapi.CallOption) (*Message, error) // "type": "string" // }, // "threadKey": { - // "description": "Optional. Opaque thread identifier string that can be specified to group messages into a single thread. If this is the first message with a given thread identifier, a new thread is created. Subsequent messages with the same thread identifier will be posted into the same thread. This relieves Chat apps and webhooks from having to store the Google Chat thread ID of a thread (created earlier by them) to post further updates to it. Has no effect if thread field, corresponding to an existing thread, is set in message.", + // "description": "Optional. Opaque thread identifier. To start or add to a thread, create a message and specify a `threadKey` instead of thread.name. (Setting thread.name has no effect.) The first message with a given `threadKey` starts a new thread. Subsequent messages with the same `threadKey` post into the same thread.", // "location": "query", // "type": "string" // } @@ -5795,14 +5774,11 @@ func (c *SpacesMessagesCreateCall) RequestId(requestId string) *SpacesMessagesCr } // ThreadKey sets the optional parameter "threadKey": Opaque thread -// identifier string that can be specified to group messages into a -// single thread. If this is the first message with a given thread -// identifier, a new thread is created. Subsequent messages with the -// same thread identifier will be posted into the same thread. This -// relieves Chat apps and webhooks from having to store the Google Chat -// thread ID of a thread (created earlier by them) to post further -// updates to it. Has no effect if thread field, corresponding to an -// existing thread, is set in message. +// identifier. To start or add to a thread, create a message and specify +// a `threadKey` instead of thread.name. (Setting thread.name has no +// effect.) The first message with a given `threadKey` starts a new +// thread. Subsequent messages with the same `threadKey` post into the +// same thread. func (c *SpacesMessagesCreateCall) ThreadKey(threadKey string) *SpacesMessagesCreateCall { c.urlParams_.Set("threadKey", threadKey) return c @@ -5920,7 +5896,7 @@ func (c *SpacesMessagesCreateCall) Do(opts ...googleapi.CallOption) (*Message, e // "type": "string" // }, // "threadKey": { - // "description": "Optional. Opaque thread identifier string that can be specified to group messages into a single thread. If this is the first message with a given thread identifier, a new thread is created. Subsequent messages with the same thread identifier will be posted into the same thread. This relieves Chat apps and webhooks from having to store the Google Chat thread ID of a thread (created earlier by them) to post further updates to it. Has no effect if thread field, corresponding to an existing thread, is set in message.", + // "description": "Optional. Opaque thread identifier. To start or add to a thread, create a message and specify a `threadKey` instead of thread.name. (Setting thread.name has no effect.) The first message with a given `threadKey` starts a new thread. Subsequent messages with the same `threadKey` post into the same thread.", // "location": "query", // "type": "string" // } diff --git a/cloudsearch/v1/cloudsearch-api.json b/cloudsearch/v1/cloudsearch-api.json index c1590ae7580..17e4989bc86 100644 --- a/cloudsearch/v1/cloudsearch-api.json +++ b/cloudsearch/v1/cloudsearch-api.json @@ -1994,7 +1994,7 @@ } } }, - "revision": "20220404", + "revision": "20220411", "rootUrl": "https://cloudsearch.googleapis.com/", "schemas": { "AclInfo": { @@ -5501,6 +5501,10 @@ "groupId": { "$ref": "GroupId" }, + "inviterEmail": { + "description": "The email address of the user that invited the calling user to the room, if available. This field will only be populated for direct invites, it will be empty if the user was indirectly invited to the group.", + "type": "string" + }, "isExternal": { "description": "Whether this is a space that enables guest access", "type": "boolean" diff --git a/cloudsearch/v1/cloudsearch-gen.go b/cloudsearch/v1/cloudsearch-gen.go index 9e25b00d0c5..0d969f34309 100644 --- a/cloudsearch/v1/cloudsearch-gen.go +++ b/cloudsearch/v1/cloudsearch-gen.go @@ -6702,6 +6702,12 @@ type SpaceInfo struct { GroupId *GroupId `json:"groupId,omitempty"` + // InviterEmail: The email address of the user that invited the calling + // user to the room, if available. This field will only be populated for + // direct invites, it will be empty if the user was indirectly invited + // to the group. + InviterEmail string `json:"inviterEmail,omitempty"` + // IsExternal: Whether this is a space that enables guest access IsExternal bool `json:"isExternal,omitempty"` diff --git a/iam/v1/iam-api.json b/iam/v1/iam-api.json index 24824d069fc..0331fc94342 100644 --- a/iam/v1/iam-api.json +++ b/iam/v1/iam-api.json @@ -1921,7 +1921,7 @@ } } }, - "revision": "20220331", + "revision": "20220413", "rootUrl": "https://iam.googleapis.com/", "schemas": { "AdminAuditData": { @@ -2025,7 +2025,7 @@ "description": "The condition that is associated with this binding. If the condition evaluates to `true`, then this binding applies to the current request. If the condition evaluates to `false`, then this binding does not apply to the current request. However, a different role binding might grant the same role to one or more of the principals in this binding. To learn which resources support conditions in their IAM policies, see the [IAM documentation](https://cloud.google.com/iam/help/conditions/resource-policies)." }, "members": { - "description": "Specifies the principals requesting access for a Cloud Platform resource. `members` can have the following values: * `allUsers`: A special identifier that represents anyone who is on the internet; with or without a Google account. * `allAuthenticatedUsers`: A special identifier that represents anyone who is authenticated with a Google account or a service account. * `user:{emailid}`: An email address that represents a specific Google account. For example, `alice@example.com` . * `serviceAccount:{emailid}`: An email address that represents a service account. For example, `my-other-app@appspot.gserviceaccount.com`. * `group:{emailid}`: An email address that represents a Google group. For example, `admins@example.com`. * `deleted:user:{emailid}?uid={uniqueid}`: An email address (plus unique identifier) representing a user that has been recently deleted. For example, `alice@example.com?uid=123456789012345678901`. If the user is recovered, this value reverts to `user:{emailid}` and the recovered user retains the role in the binding. * `deleted:serviceAccount:{emailid}?uid={uniqueid}`: An email address (plus unique identifier) representing a service account that has been recently deleted. For example, `my-other-app@appspot.gserviceaccount.com?uid=123456789012345678901`. If the service account is undeleted, this value reverts to `serviceAccount:{emailid}` and the undeleted service account retains the role in the binding. * `deleted:group:{emailid}?uid={uniqueid}`: An email address (plus unique identifier) representing a Google group that has been recently deleted. For example, `admins@example.com?uid=123456789012345678901`. If the group is recovered, this value reverts to `group:{emailid}` and the recovered group retains the role in the binding. * `domain:{domain}`: The G Suite domain (primary) that represents all the users of that domain. For example, `google.com` or `example.com`. ", + "description": "Specifies the principals requesting access for a Google Cloud resource. `members` can have the following values: * `allUsers`: A special identifier that represents anyone who is on the internet; with or without a Google account. * `allAuthenticatedUsers`: A special identifier that represents anyone who is authenticated with a Google account or a service account. * `user:{emailid}`: An email address that represents a specific Google account. For example, `alice@example.com` . * `serviceAccount:{emailid}`: An email address that represents a service account. For example, `my-other-app@appspot.gserviceaccount.com`. * `group:{emailid}`: An email address that represents a Google group. For example, `admins@example.com`. * `deleted:user:{emailid}?uid={uniqueid}`: An email address (plus unique identifier) representing a user that has been recently deleted. For example, `alice@example.com?uid=123456789012345678901`. If the user is recovered, this value reverts to `user:{emailid}` and the recovered user retains the role in the binding. * `deleted:serviceAccount:{emailid}?uid={uniqueid}`: An email address (plus unique identifier) representing a service account that has been recently deleted. For example, `my-other-app@appspot.gserviceaccount.com?uid=123456789012345678901`. If the service account is undeleted, this value reverts to `serviceAccount:{emailid}` and the undeleted service account retains the role in the binding. * `deleted:group:{emailid}?uid={uniqueid}`: An email address (plus unique identifier) representing a Google group that has been recently deleted. For example, `admins@example.com?uid=123456789012345678901`. If the group is recovered, this value reverts to `group:{emailid}` and the recovered group retains the role in the binding. * `domain:{domain}`: The G Suite domain (primary) that represents all the users of that domain. For example, `google.com` or `example.com`. ", "items": { "type": "string" }, @@ -2061,7 +2061,7 @@ "description": "The condition that is associated with this binding." }, "member": { - "description": "A single identity requesting access for a Cloud Platform resource. Follows the same format of Binding.members. Required", + "description": "A single identity requesting access for a Google Cloud resource. Follows the same format of Binding.members. Required", "type": "string" }, "role": { @@ -2866,7 +2866,7 @@ "properties": { "policy": { "$ref": "Policy", - "description": "REQUIRED: The complete policy to be applied to the `resource`. The size of the policy is limited to a few 10s of KB. An empty policy is a valid policy but certain Cloud Platform services (such as Projects) might reject them." + "description": "REQUIRED: The complete policy to be applied to the `resource`. The size of the policy is limited to a few 10s of KB. An empty policy is a valid policy but certain Google Cloud services (such as Projects) might reject them." }, "updateMask": { "description": "OPTIONAL: A FieldMask specifying which fields of the policy to modify. Only the fields in the mask will be modified. If no mask is provided, the following default mask is used: `paths: \"bindings, etag\"`", @@ -2962,7 +2962,7 @@ "id": "TestIamPermissionsRequest", "properties": { "permissions": { - "description": "The set of permissions to check for the `resource`. Permissions with wildcards (such as '*' or 'storage.*') are not allowed. For more information see [IAM Overview](https://cloud.google.com/iam/docs/overview#permissions).", + "description": "The set of permissions to check for the `resource`. Permissions with wildcards (such as `*` or `storage.*`) are not allowed. For more information see [IAM Overview](https://cloud.google.com/iam/docs/overview#permissions).", "items": { "type": "string" }, diff --git a/iam/v1/iam-gen.go b/iam/v1/iam-gen.go index c4185d5feb7..52e7949b3c0 100644 --- a/iam/v1/iam-gen.go +++ b/iam/v1/iam-gen.go @@ -663,8 +663,8 @@ type Binding struct { // (https://cloud.google.com/iam/help/conditions/resource-policies). Condition *Expr `json:"condition,omitempty"` - // Members: Specifies the principals requesting access for a Cloud - // Platform resource. `members` can have the following values: * + // Members: Specifies the principals requesting access for a Google + // Cloud resource. `members` can have the following values: * // `allUsers`: A special identifier that represents anyone who is on the // internet; with or without a Google account. * // `allAuthenticatedUsers`: A special identifier that represents anyone @@ -739,7 +739,7 @@ type BindingDelta struct { // Condition: The condition that is associated with this binding. Condition *Expr `json:"condition,omitempty"` - // Member: A single identity requesting access for a Cloud Platform + // Member: A single identity requesting access for a Google Cloud // resource. Follows the same format of Binding.members. Required Member string `json:"member,omitempty"` @@ -2194,7 +2194,7 @@ func (s *ServiceAccountKey) MarshalJSON() ([]byte, error) { type SetIamPolicyRequest struct { // Policy: REQUIRED: The complete policy to be applied to the // `resource`. The size of the policy is limited to a few 10s of KB. An - // empty policy is a valid policy but certain Cloud Platform services + // empty policy is a valid policy but certain Google Cloud services // (such as Projects) might reject them. Policy *Policy `json:"policy,omitempty"` @@ -2428,7 +2428,7 @@ func (s *Status) MarshalJSON() ([]byte, error) { // method. type TestIamPermissionsRequest struct { // Permissions: The set of permissions to check for the `resource`. - // Permissions with wildcards (such as '*' or 'storage.*') are not + // Permissions with wildcards (such as `*` or `storage.*`) are not // allowed. For more information see IAM Overview // (https://cloud.google.com/iam/docs/overview#permissions). Permissions []string `json:"permissions,omitempty"` diff --git a/iam/v2beta/iam-api.json b/iam/v2beta/iam-api.json index 3bdf4b287f8..5d2a79ab9ad 100644 --- a/iam/v2beta/iam-api.json +++ b/iam/v2beta/iam-api.json @@ -293,7 +293,7 @@ } } }, - "revision": "20220331", + "revision": "20220413", "rootUrl": "https://iam.googleapis.com/", "schemas": { "GoogleIamAdminV1AuditData": { @@ -351,7 +351,7 @@ "description": "The condition that is associated with this binding." }, "member": { - "description": "A single identity requesting access for a Cloud Platform resource. Follows the same format of Binding.members. Required", + "description": "A single identity requesting access for a Google Cloud resource. Follows the same format of Binding.members. Required", "type": "string" }, "role": { diff --git a/iam/v2beta/iam-gen.go b/iam/v2beta/iam-gen.go index 266455bfa40..a5e99ccdb39 100644 --- a/iam/v2beta/iam-gen.go +++ b/iam/v2beta/iam-gen.go @@ -239,7 +239,7 @@ type GoogleIamV1BindingDelta struct { // Condition: The condition that is associated with this binding. Condition *GoogleTypeExpr `json:"condition,omitempty"` - // Member: A single identity requesting access for a Cloud Platform + // Member: A single identity requesting access for a Google Cloud // resource. Follows the same format of Binding.members. Required Member string `json:"member,omitempty"` diff --git a/monitoring/v1/monitoring-api.json b/monitoring/v1/monitoring-api.json index e148c807f4f..353f16fddde 100644 --- a/monitoring/v1/monitoring-api.json +++ b/monitoring/v1/monitoring-api.json @@ -679,7 +679,7 @@ } } }, - "revision": "20220327", + "revision": "20220418", "rootUrl": "https://monitoring.googleapis.com/", "schemas": { "Aggregation": { @@ -1920,7 +1920,7 @@ "description": "Parameters to fetch a ratio between two time series filters." }, "timeSeriesQueryLanguage": { - "description": "A query used to fetch time series.", + "description": "A query used to fetch time series with MQL.", "type": "string" }, "unitOverride": { diff --git a/monitoring/v1/monitoring-gen.go b/monitoring/v1/monitoring-gen.go index 82fde520751..7ed211450ea 100644 --- a/monitoring/v1/monitoring-gen.go +++ b/monitoring/v1/monitoring-gen.go @@ -2520,7 +2520,7 @@ type TimeSeriesQuery struct { // series filters. TimeSeriesFilterRatio *TimeSeriesFilterRatio `json:"timeSeriesFilterRatio,omitempty"` - // TimeSeriesQueryLanguage: A query used to fetch time series. + // TimeSeriesQueryLanguage: A query used to fetch time series with MQL. TimeSeriesQueryLanguage string `json:"timeSeriesQueryLanguage,omitempty"` // UnitOverride: The unit of data contained in fetched time series. If diff --git a/mybusinessverifications/v1/mybusinessverifications-api.json b/mybusinessverifications/v1/mybusinessverifications-api.json index e7f83a9bf1e..e72f0acdedc 100644 --- a/mybusinessverifications/v1/mybusinessverifications-api.json +++ b/mybusinessverifications/v1/mybusinessverifications-api.json @@ -256,7 +256,7 @@ } } }, - "revision": "20220307", + "revision": "20220420", "rootUrl": "https://mybusinessverifications.googleapis.com/", "schemas": { "AddressVerificationData": { @@ -423,7 +423,7 @@ "type": "string" }, "primaryCategoryId": { - "description": "Required. Id of the category that best describes the core business this location engages in.", + "description": "Required. Id of the category that best describes the core business this location engages in. e.g. gcid:bakery.", "type": "string" }, "primaryPhone": { diff --git a/mybusinessverifications/v1/mybusinessverifications-gen.go b/mybusinessverifications/v1/mybusinessverifications-gen.go index 5c707752239..1ebd009acc3 100644 --- a/mybusinessverifications/v1/mybusinessverifications-gen.go +++ b/mybusinessverifications/v1/mybusinessverifications-gen.go @@ -533,7 +533,7 @@ type Location struct { Name string `json:"name,omitempty"` // PrimaryCategoryId: Required. Id of the category that best describes - // the core business this location engages in. + // the core business this location engages in. e.g. gcid:bakery. PrimaryCategoryId string `json:"primaryCategoryId,omitempty"` // PrimaryPhone: Optional. A phone number that connects to your diff --git a/people/v1/people-api.json b/people/v1/people-api.json index 90f7c322856..b2bd54c7e72 100644 --- a/people/v1/people-api.json +++ b/people/v1/people-api.json @@ -424,7 +424,7 @@ "type": "boolean" }, "sources": { - "description": "Optional. A mask of what source types to return. Defaults to READ_SOURCE_TYPE_CONTACT if not set.", + "description": "Optional. A mask of what source types to return. Defaults to READ_SOURCE_TYPE_CONTACT if not set. Possible values for this field are: * READ_SOURCE_TYPE_CONTACT * READ_SOURCE_TYPE_CONTACT,READ_SOURCE_TYPE_PROFILE Specifying READ_SOURCE_TYPE_PROFILE without specifying READ_SOURCE_TYPE_CONTACT is not permitted.", "enum": [ "READ_SOURCE_TYPE_UNSPECIFIED", "READ_SOURCE_TYPE_PROFILE", @@ -1172,7 +1172,7 @@ } } }, - "revision": "20220321", + "revision": "20220420", "rootUrl": "https://people.googleapis.com/", "schemas": { "Address": { diff --git a/people/v1/people-gen.go b/people/v1/people-gen.go index 6b0c08d78b0..6f1567241f6 100644 --- a/people/v1/people-gen.go +++ b/people/v1/people-gen.go @@ -4759,6 +4759,10 @@ func (c *OtherContactsListCall) RequestSyncToken(requestSyncToken bool) *OtherCo // Sources sets the optional parameter "sources": A mask of what source // types to return. Defaults to READ_SOURCE_TYPE_CONTACT if not set. +// Possible values for this field are: * READ_SOURCE_TYPE_CONTACT * +// READ_SOURCE_TYPE_CONTACT,READ_SOURCE_TYPE_PROFILE Specifying +// READ_SOURCE_TYPE_PROFILE without specifying READ_SOURCE_TYPE_CONTACT +// is not permitted. // // Possible values: // "READ_SOURCE_TYPE_UNSPECIFIED" - Unspecified. @@ -4908,7 +4912,7 @@ func (c *OtherContactsListCall) Do(opts ...googleapi.CallOption) (*ListOtherCont // "type": "boolean" // }, // "sources": { - // "description": "Optional. A mask of what source types to return. Defaults to READ_SOURCE_TYPE_CONTACT if not set.", + // "description": "Optional. A mask of what source types to return. Defaults to READ_SOURCE_TYPE_CONTACT if not set. Possible values for this field are: * READ_SOURCE_TYPE_CONTACT * READ_SOURCE_TYPE_CONTACT,READ_SOURCE_TYPE_PROFILE Specifying READ_SOURCE_TYPE_PROFILE without specifying READ_SOURCE_TYPE_CONTACT is not permitted.", // "enum": [ // "READ_SOURCE_TYPE_UNSPECIFIED", // "READ_SOURCE_TYPE_PROFILE", diff --git a/retail/v2/retail-api.json b/retail/v2/retail-api.json index cad82ac8528..a863f3e2ee3 100644 --- a/retail/v2/retail-api.json +++ b/retail/v2/retail-api.json @@ -781,7 +781,7 @@ ], "parameters": { "placement": { - "description": "Required. Full resource name of the format: {name=projects/*/locations/global/catalogs/default_catalog/servingConfigs/*} or {name=projects/*/locations/global/catalogs/default_catalog/placements/*}. We recommend using the `servingConfigs` resource. `placements` is a legacy resource. The ID of the Recommendations AI serving config or placement. Before you can request predictions from your model, you must create at least one serving config or placement for it. For more information, see [Managing serving configurations]. (https://cloud.google.com/retail/docs/manage-configs). The full list of available serving configs can be seen at https://console.cloud.google.com/ai/retail/catalogs/default_catalog/configs", + "description": "Required. Full resource name of the format: {name=projects/*/locations/global/catalogs/default_catalog/servingConfigs/*} or {name=projects/*/locations/global/catalogs/default_catalog/placements/*}. We recommend using the `servingConfigs` resource. `placements` is a legacy resource. The ID of the Recommendations AI serving config or placement. Before you can request predictions from your model, you must create at least one serving config or placement for it. For more information, see [Managing serving configurations] (https://cloud.google.com/retail/docs/manage-configs). The full list of available serving configs can be seen at https://console.cloud.google.com/ai/retail/catalogs/default_catalog/configs", "location": "path", "pattern": "^projects/[^/]+/locations/[^/]+/catalogs/[^/]+/placements/[^/]+$", "required": true, @@ -841,7 +841,7 @@ ], "parameters": { "placement": { - "description": "Required. Full resource name of the format: {name=projects/*/locations/global/catalogs/default_catalog/servingConfigs/*} or {name=projects/*/locations/global/catalogs/default_catalog/placements/*}. We recommend using the `servingConfigs` resource. `placements` is a legacy resource. The ID of the Recommendations AI serving config or placement. Before you can request predictions from your model, you must create at least one serving config or placement for it. For more information, see [Managing serving configurations]. (https://cloud.google.com/retail/docs/manage-configs). The full list of available serving configs can be seen at https://console.cloud.google.com/ai/retail/catalogs/default_catalog/configs", + "description": "Required. Full resource name of the format: {name=projects/*/locations/global/catalogs/default_catalog/servingConfigs/*} or {name=projects/*/locations/global/catalogs/default_catalog/placements/*}. We recommend using the `servingConfigs` resource. `placements` is a legacy resource. The ID of the Recommendations AI serving config or placement. Before you can request predictions from your model, you must create at least one serving config or placement for it. For more information, see [Managing serving configurations] (https://cloud.google.com/retail/docs/manage-configs). The full list of available serving configs can be seen at https://console.cloud.google.com/ai/retail/catalogs/default_catalog/configs", "location": "path", "pattern": "^projects/[^/]+/locations/[^/]+/catalogs/[^/]+/servingConfigs/[^/]+$", "required": true, @@ -1193,7 +1193,7 @@ } } }, - "revision": "20220408", + "revision": "20220414", "rootUrl": "https://retail.googleapis.com/", "schemas": { "GoogleApiHttpBody": { @@ -1797,7 +1797,7 @@ "description": "Required. The desired input location of the data." }, "notificationPubsubTopic": { - "description": "Pub/Sub topic for receiving notification. If this field is set, when the import is finished, a notification will be sent to specified Pub/Sub topic. The message data will be JSON string of a Operation. Format of the Pub/Sub topic is `projects/{project}/topics/{topic}`. Only supported when ImportProductsRequest.reconciliation_mode is set to `FULL`.", + "description": "Full Pub/Sub topic name for receiving notification. If this field is set, when the import is finished, a notification will be sent to specified Pub/Sub topic. The message data will be JSON string of a Operation. Format of the Pub/Sub topic is `projects/{project}/topics/{topic}`. It has to be within the same project as ImportProductsRequest.parent. Make sure that both `cloud-retail-customer-data-access@system.gserviceaccount.com` and `service-@gcp-sa-retail.iam.gserviceaccount.com` have the `pubsub.topics.publish` IAM permission on the topic. Only supported when ImportProductsRequest.reconciliation_mode is set to `FULL`.", "type": "string" }, "reconciliationMode": { @@ -2076,7 +2076,7 @@ "type": "string" }, "originalPrice": { - "description": "Price of the product without any discount. If zero, by default set to be the price.", + "description": "Price of the product without any discount. If zero, by default set to be the price. If set, original_price should be greater than or equal to price, otherwise an INVALID_ARGUMENT error is thrown.", "format": "float", "type": "number" }, @@ -2636,6 +2636,13 @@ "description": "The filter syntax consists of an expression language for constructing a predicate from one or more fields of the products being filtered. Filter expression is case-sensitive. See more details at this [user guide](https://cloud.google.com/retail/docs/filter-and-order#filter). If this field is unrecognizable, an INVALID_ARGUMENT is returned.", "type": "string" }, + "labels": { + "additionalProperties": { + "type": "string" + }, + "description": "The labels applied to a resource must meet the following requirements: * Each resource can have multiple labels, up to a maximum of 64. * Each label must be a key-value pair. * Keys have a minimum length of 1 character and a maximum length of 63 characters, and cannot be empty. Values can be empty, and have a maximum length of 63 characters. * Keys and values can contain only lowercase letters, numeric characters, underscores, and dashes. All characters must use UTF-8 encoding, and international characters are allowed. * The key portion of a label must be unique. However, you can use the same key with multiple resources. * Keys must start with a lowercase letter or international character. See [Google Cloud Document](https://cloud.google.com/resource-manager/docs/creating-managing-labels#requirements) for more details.", + "type": "object" + }, "offset": { "description": "A 0-indexed integer that specifies the current offset (that is, starting result location, amongst the Products deemed by the API as relevant) in search results. This field is only considered if page_token is unset. If this field is negative, an INVALID_ARGUMENT is returned.", "format": "int32", diff --git a/retail/v2/retail-gen.go b/retail/v2/retail-gen.go index e4f1eae89ba..e14e1213a0b 100644 --- a/retail/v2/retail-gen.go +++ b/retail/v2/retail-gen.go @@ -1515,12 +1515,16 @@ type GoogleCloudRetailV2ImportProductsRequest struct { // InputConfig: Required. The desired input location of the data. InputConfig *GoogleCloudRetailV2ProductInputConfig `json:"inputConfig,omitempty"` - // NotificationPubsubTopic: Pub/Sub topic for receiving notification. If - // this field is set, when the import is finished, a notification will - // be sent to specified Pub/Sub topic. The message data will be JSON - // string of a Operation. Format of the Pub/Sub topic is - // `projects/{project}/topics/{topic}`. Only supported when - // ImportProductsRequest.reconciliation_mode is set to `FULL`. + // NotificationPubsubTopic: Full Pub/Sub topic name for receiving + // notification. If this field is set, when the import is finished, a + // notification will be sent to specified Pub/Sub topic. The message + // data will be JSON string of a Operation. Format of the Pub/Sub topic + // is `projects/{project}/topics/{topic}`. It has to be within the same + // project as ImportProductsRequest.parent. Make sure that both + // `cloud-retail-customer-data-access@system.gserviceaccount.com` and + // `service-@gcp-sa-retail.iam.gserviceaccount.com` have the + // `pubsub.topics.publish` IAM permission on the topic. Only supported + // when ImportProductsRequest.reconciliation_mode is set to `FULL`. NotificationPubsubTopic string `json:"notificationPubsubTopic,omitempty"` // ReconciliationMode: The mode of reconciliation between existing @@ -2084,7 +2088,9 @@ type GoogleCloudRetailV2PriceInfo struct { CurrencyCode string `json:"currencyCode,omitempty"` // OriginalPrice: Price of the product without any discount. If zero, by - // default set to be the price. + // default set to be the price. If set, original_price should be greater + // than or equal to price, otherwise an INVALID_ARGUMENT error is + // thrown. OriginalPrice float64 `json:"originalPrice,omitempty"` // Price: Price of the product. Google Merchant Center property price @@ -3197,6 +3203,21 @@ type GoogleCloudRetailV2SearchRequest struct { // this field is unrecognizable, an INVALID_ARGUMENT is returned. Filter string `json:"filter,omitempty"` + // Labels: The labels applied to a resource must meet the following + // requirements: * Each resource can have multiple labels, up to a + // maximum of 64. * Each label must be a key-value pair. * Keys have a + // minimum length of 1 character and a maximum length of 63 characters, + // and cannot be empty. Values can be empty, and have a maximum length + // of 63 characters. * Keys and values can contain only lowercase + // letters, numeric characters, underscores, and dashes. All characters + // must use UTF-8 encoding, and international characters are allowed. * + // The key portion of a label must be unique. However, you can use the + // same key with multiple resources. * Keys must start with a lowercase + // letter or international character. See Google Cloud Document + // (https://cloud.google.com/resource-manager/docs/creating-managing-labels#requirements) + // for more details. + Labels map[string]string `json:"labels,omitempty"` + // Offset: A 0-indexed integer that specifies the current offset (that // is, starting result location, amongst the Products deemed by the API // as relevant) in search results. This field is only considered if @@ -9183,7 +9204,7 @@ type ProjectsLocationsCatalogsPlacementsPredictCall struct { // serving config or placement. Before you can request predictions // from your model, you must create at least one serving config or // placement for it. For more information, see [Managing serving -// configurations]. +// configurations] // (https://cloud.google.com/retail/docs/manage-configs). The full // list of available serving configs can be seen at // https://console.cloud.google.com/ai/retail/catalogs/default_catalog/configs. @@ -9295,7 +9316,7 @@ func (c *ProjectsLocationsCatalogsPlacementsPredictCall) Do(opts ...googleapi.Ca // ], // "parameters": { // "placement": { - // "description": "Required. Full resource name of the format: {name=projects/*/locations/global/catalogs/default_catalog/servingConfigs/*} or {name=projects/*/locations/global/catalogs/default_catalog/placements/*}. We recommend using the `servingConfigs` resource. `placements` is a legacy resource. The ID of the Recommendations AI serving config or placement. Before you can request predictions from your model, you must create at least one serving config or placement for it. For more information, see [Managing serving configurations]. (https://cloud.google.com/retail/docs/manage-configs). The full list of available serving configs can be seen at https://console.cloud.google.com/ai/retail/catalogs/default_catalog/configs", + // "description": "Required. Full resource name of the format: {name=projects/*/locations/global/catalogs/default_catalog/servingConfigs/*} or {name=projects/*/locations/global/catalogs/default_catalog/placements/*}. We recommend using the `servingConfigs` resource. `placements` is a legacy resource. The ID of the Recommendations AI serving config or placement. Before you can request predictions from your model, you must create at least one serving config or placement for it. For more information, see [Managing serving configurations] (https://cloud.google.com/retail/docs/manage-configs). The full list of available serving configs can be seen at https://console.cloud.google.com/ai/retail/catalogs/default_catalog/configs", // "location": "path", // "pattern": "^projects/[^/]+/locations/[^/]+/catalogs/[^/]+/placements/[^/]+$", // "required": true, @@ -9512,7 +9533,7 @@ type ProjectsLocationsCatalogsServingConfigsPredictCall struct { // serving config or placement. Before you can request predictions // from your model, you must create at least one serving config or // placement for it. For more information, see [Managing serving -// configurations]. +// configurations] // (https://cloud.google.com/retail/docs/manage-configs). The full // list of available serving configs can be seen at // https://console.cloud.google.com/ai/retail/catalogs/default_catalog/configs. @@ -9624,7 +9645,7 @@ func (c *ProjectsLocationsCatalogsServingConfigsPredictCall) Do(opts ...googleap // ], // "parameters": { // "placement": { - // "description": "Required. Full resource name of the format: {name=projects/*/locations/global/catalogs/default_catalog/servingConfigs/*} or {name=projects/*/locations/global/catalogs/default_catalog/placements/*}. We recommend using the `servingConfigs` resource. `placements` is a legacy resource. The ID of the Recommendations AI serving config or placement. Before you can request predictions from your model, you must create at least one serving config or placement for it. For more information, see [Managing serving configurations]. (https://cloud.google.com/retail/docs/manage-configs). The full list of available serving configs can be seen at https://console.cloud.google.com/ai/retail/catalogs/default_catalog/configs", + // "description": "Required. Full resource name of the format: {name=projects/*/locations/global/catalogs/default_catalog/servingConfigs/*} or {name=projects/*/locations/global/catalogs/default_catalog/placements/*}. We recommend using the `servingConfigs` resource. `placements` is a legacy resource. The ID of the Recommendations AI serving config or placement. Before you can request predictions from your model, you must create at least one serving config or placement for it. For more information, see [Managing serving configurations] (https://cloud.google.com/retail/docs/manage-configs). The full list of available serving configs can be seen at https://console.cloud.google.com/ai/retail/catalogs/default_catalog/configs", // "location": "path", // "pattern": "^projects/[^/]+/locations/[^/]+/catalogs/[^/]+/servingConfigs/[^/]+$", // "required": true, diff --git a/retail/v2alpha/retail-api.json b/retail/v2alpha/retail-api.json index 790e1db12cf..c9d2117faad 100644 --- a/retail/v2alpha/retail-api.json +++ b/retail/v2alpha/retail-api.json @@ -1182,7 +1182,7 @@ ], "parameters": { "placement": { - "description": "Required. Full resource name of the format: {name=projects/*/locations/global/catalogs/default_catalog/servingConfigs/*} or {name=projects/*/locations/global/catalogs/default_catalog/placements/*}. We recommend using the `servingConfigs` resource. `placements` is a legacy resource. The ID of the Recommendations AI serving config or placement. Before you can request predictions from your model, you must create at least one serving config or placement for it. For more information, see [Managing serving configurations]. (https://cloud.google.com/retail/docs/manage-configs). The full list of available serving configs can be seen at https://console.cloud.google.com/ai/retail/catalogs/default_catalog/configs", + "description": "Required. Full resource name of the format: {name=projects/*/locations/global/catalogs/default_catalog/servingConfigs/*} or {name=projects/*/locations/global/catalogs/default_catalog/placements/*}. We recommend using the `servingConfigs` resource. `placements` is a legacy resource. The ID of the Recommendations AI serving config or placement. Before you can request predictions from your model, you must create at least one serving config or placement for it. For more information, see [Managing serving configurations] (https://cloud.google.com/retail/docs/manage-configs). The full list of available serving configs can be seen at https://console.cloud.google.com/ai/retail/catalogs/default_catalog/configs", "location": "path", "pattern": "^projects/[^/]+/locations/[^/]+/catalogs/[^/]+/placements/[^/]+$", "required": true, @@ -1423,7 +1423,7 @@ ], "parameters": { "placement": { - "description": "Required. Full resource name of the format: {name=projects/*/locations/global/catalogs/default_catalog/servingConfigs/*} or {name=projects/*/locations/global/catalogs/default_catalog/placements/*}. We recommend using the `servingConfigs` resource. `placements` is a legacy resource. The ID of the Recommendations AI serving config or placement. Before you can request predictions from your model, you must create at least one serving config or placement for it. For more information, see [Managing serving configurations]. (https://cloud.google.com/retail/docs/manage-configs). The full list of available serving configs can be seen at https://console.cloud.google.com/ai/retail/catalogs/default_catalog/configs", + "description": "Required. Full resource name of the format: {name=projects/*/locations/global/catalogs/default_catalog/servingConfigs/*} or {name=projects/*/locations/global/catalogs/default_catalog/placements/*}. We recommend using the `servingConfigs` resource. `placements` is a legacy resource. The ID of the Recommendations AI serving config or placement. Before you can request predictions from your model, you must create at least one serving config or placement for it. For more information, see [Managing serving configurations] (https://cloud.google.com/retail/docs/manage-configs). The full list of available serving configs can be seen at https://console.cloud.google.com/ai/retail/catalogs/default_catalog/configs", "location": "path", "pattern": "^projects/[^/]+/locations/[^/]+/catalogs/[^/]+/servingConfigs/[^/]+$", "required": true, @@ -1803,7 +1803,7 @@ } } }, - "revision": "20220408", + "revision": "20220414", "rootUrl": "https://retail.googleapis.com/", "schemas": { "GoogleApiHttpBody": { @@ -2976,7 +2976,7 @@ "description": "Required. The desired input location of the data." }, "notificationPubsubTopic": { - "description": "Pub/Sub topic for receiving notification. If this field is set, when the import is finished, a notification will be sent to specified Pub/Sub topic. The message data will be JSON string of a Operation. Format of the Pub/Sub topic is `projects/{project}/topics/{topic}`. Only supported when ImportProductsRequest.reconciliation_mode is set to `FULL`.", + "description": "Full Pub/Sub topic name for receiving notification. If this field is set, when the import is finished, a notification will be sent to specified Pub/Sub topic. The message data will be JSON string of a Operation. Format of the Pub/Sub topic is `projects/{project}/topics/{topic}`. It has to be within the same project as ImportProductsRequest.parent. Make sure that both `cloud-retail-customer-data-access@system.gserviceaccount.com` and `service-@gcp-sa-retail.iam.gserviceaccount.com` have the `pubsub.topics.publish` IAM permission on the topic. Only supported when ImportProductsRequest.reconciliation_mode is set to `FULL`.", "type": "string" }, "reconciliationMode": { @@ -2997,6 +2997,10 @@ "description": "Deprecated. This field has no effect.", "type": "string" }, + "skipDefaultBranchProtection": { + "description": "If true, will perform the FULL import even if it would delete a large proportion of the products in the default branch, which could potentially cause outages if you have live predict/search traffic. Only supported when ImportProductsRequest.reconciliation_mode is set to `FULL`.", + "type": "boolean" + }, "updateMask": { "description": "Indicates which fields in the provided imported 'products' to update. If not set, will by default update all fields.", "format": "google-fieldmask", @@ -3341,7 +3345,7 @@ "type": "string" }, "originalPrice": { - "description": "Price of the product without any discount. If zero, by default set to be the price.", + "description": "Price of the product without any discount. If zero, by default set to be the price. If set, original_price should be greater than or equal to price, otherwise an INVALID_ARGUMENT error is thrown.", "format": "float", "type": "number" }, @@ -4187,6 +4191,13 @@ "description": "The filter syntax consists of an expression language for constructing a predicate from one or more fields of the products being filtered. Filter expression is case-sensitive. See more details at this [user guide](https://cloud.google.com/retail/docs/filter-and-order#filter). If this field is unrecognizable, an INVALID_ARGUMENT is returned.", "type": "string" }, + "labels": { + "additionalProperties": { + "type": "string" + }, + "description": "The labels applied to a resource must meet the following requirements: * Each resource can have multiple labels, up to a maximum of 64. * Each label must be a key-value pair. * Keys have a minimum length of 1 character and a maximum length of 63 characters, and cannot be empty. Values can be empty, and have a maximum length of 63 characters. * Keys and values can contain only lowercase letters, numeric characters, underscores, and dashes. All characters must use UTF-8 encoding, and international characters are allowed. * The key portion of a label must be unique. However, you can use the same key with multiple resources. * Keys must start with a lowercase letter or international character. See [Google Cloud Document](https://cloud.google.com/resource-manager/docs/creating-managing-labels#requirements) for more details.", + "type": "object" + }, "offset": { "description": "A 0-indexed integer that specifies the current offset (that is, starting result location, amongst the Products deemed by the API as relevant) in search results. This field is only considered if page_token is unset. If this field is negative, an INVALID_ARGUMENT is returned.", "format": "int32", diff --git a/retail/v2alpha/retail-gen.go b/retail/v2alpha/retail-gen.go index 2f25c777ab4..80e93c4a9df 100644 --- a/retail/v2alpha/retail-gen.go +++ b/retail/v2alpha/retail-gen.go @@ -2545,12 +2545,16 @@ type GoogleCloudRetailV2alphaImportProductsRequest struct { // InputConfig: Required. The desired input location of the data. InputConfig *GoogleCloudRetailV2alphaProductInputConfig `json:"inputConfig,omitempty"` - // NotificationPubsubTopic: Pub/Sub topic for receiving notification. If - // this field is set, when the import is finished, a notification will - // be sent to specified Pub/Sub topic. The message data will be JSON - // string of a Operation. Format of the Pub/Sub topic is - // `projects/{project}/topics/{topic}`. Only supported when - // ImportProductsRequest.reconciliation_mode is set to `FULL`. + // NotificationPubsubTopic: Full Pub/Sub topic name for receiving + // notification. If this field is set, when the import is finished, a + // notification will be sent to specified Pub/Sub topic. The message + // data will be JSON string of a Operation. Format of the Pub/Sub topic + // is `projects/{project}/topics/{topic}`. It has to be within the same + // project as ImportProductsRequest.parent. Make sure that both + // `cloud-retail-customer-data-access@system.gserviceaccount.com` and + // `service-@gcp-sa-retail.iam.gserviceaccount.com` have the + // `pubsub.topics.publish` IAM permission on the topic. Only supported + // when ImportProductsRequest.reconciliation_mode is set to `FULL`. NotificationPubsubTopic string `json:"notificationPubsubTopic,omitempty"` // ReconciliationMode: The mode of reconciliation between existing @@ -2573,6 +2577,13 @@ type GoogleCloudRetailV2alphaImportProductsRequest struct { // RequestId: Deprecated. This field has no effect. RequestId string `json:"requestId,omitempty"` + // SkipDefaultBranchProtection: If true, will perform the FULL import + // even if it would delete a large proportion of the products in the + // default branch, which could potentially cause outages if you have + // live predict/search traffic. Only supported when + // ImportProductsRequest.reconciliation_mode is set to `FULL`. + SkipDefaultBranchProtection bool `json:"skipDefaultBranchProtection,omitempty"` + // UpdateMask: Indicates which fields in the provided imported // 'products' to update. If not set, will by default update all fields. UpdateMask string `json:"updateMask,omitempty"` @@ -3291,7 +3302,9 @@ type GoogleCloudRetailV2alphaPriceInfo struct { CurrencyCode string `json:"currencyCode,omitempty"` // OriginalPrice: Price of the product without any discount. If zero, by - // default set to be the price. + // default set to be the price. If set, original_price should be greater + // than or equal to price, otherwise an INVALID_ARGUMENT error is + // thrown. OriginalPrice float64 `json:"originalPrice,omitempty"` // Price: Price of the product. Google Merchant Center property price @@ -5003,6 +5016,21 @@ type GoogleCloudRetailV2alphaSearchRequest struct { // this field is unrecognizable, an INVALID_ARGUMENT is returned. Filter string `json:"filter,omitempty"` + // Labels: The labels applied to a resource must meet the following + // requirements: * Each resource can have multiple labels, up to a + // maximum of 64. * Each label must be a key-value pair. * Keys have a + // minimum length of 1 character and a maximum length of 63 characters, + // and cannot be empty. Values can be empty, and have a maximum length + // of 63 characters. * Keys and values can contain only lowercase + // letters, numeric characters, underscores, and dashes. All characters + // must use UTF-8 encoding, and international characters are allowed. * + // The key portion of a label must be unique. However, you can use the + // same key with multiple resources. * Keys must start with a lowercase + // letter or international character. See Google Cloud Document + // (https://cloud.google.com/resource-manager/docs/creating-managing-labels#requirements) + // for more details. + Labels map[string]string `json:"labels,omitempty"` + // Offset: A 0-indexed integer that specifies the current offset (that // is, starting result location, amongst the Products deemed by the API // as relevant) in search results. This field is only considered if @@ -12640,7 +12668,7 @@ type ProjectsLocationsCatalogsPlacementsPredictCall struct { // serving config or placement. Before you can request predictions // from your model, you must create at least one serving config or // placement for it. For more information, see [Managing serving -// configurations]. +// configurations] // (https://cloud.google.com/retail/docs/manage-configs). The full // list of available serving configs can be seen at // https://console.cloud.google.com/ai/retail/catalogs/default_catalog/configs. @@ -12752,7 +12780,7 @@ func (c *ProjectsLocationsCatalogsPlacementsPredictCall) Do(opts ...googleapi.Ca // ], // "parameters": { // "placement": { - // "description": "Required. Full resource name of the format: {name=projects/*/locations/global/catalogs/default_catalog/servingConfigs/*} or {name=projects/*/locations/global/catalogs/default_catalog/placements/*}. We recommend using the `servingConfigs` resource. `placements` is a legacy resource. The ID of the Recommendations AI serving config or placement. Before you can request predictions from your model, you must create at least one serving config or placement for it. For more information, see [Managing serving configurations]. (https://cloud.google.com/retail/docs/manage-configs). The full list of available serving configs can be seen at https://console.cloud.google.com/ai/retail/catalogs/default_catalog/configs", + // "description": "Required. Full resource name of the format: {name=projects/*/locations/global/catalogs/default_catalog/servingConfigs/*} or {name=projects/*/locations/global/catalogs/default_catalog/placements/*}. We recommend using the `servingConfigs` resource. `placements` is a legacy resource. The ID of the Recommendations AI serving config or placement. Before you can request predictions from your model, you must create at least one serving config or placement for it. For more information, see [Managing serving configurations] (https://cloud.google.com/retail/docs/manage-configs). The full list of available serving configs can be seen at https://console.cloud.google.com/ai/retail/catalogs/default_catalog/configs", // "location": "path", // "pattern": "^projects/[^/]+/locations/[^/]+/catalogs/[^/]+/placements/[^/]+$", // "required": true, @@ -13923,7 +13951,7 @@ type ProjectsLocationsCatalogsServingConfigsPredictCall struct { // serving config or placement. Before you can request predictions // from your model, you must create at least one serving config or // placement for it. For more information, see [Managing serving -// configurations]. +// configurations] // (https://cloud.google.com/retail/docs/manage-configs). The full // list of available serving configs can be seen at // https://console.cloud.google.com/ai/retail/catalogs/default_catalog/configs. @@ -14035,7 +14063,7 @@ func (c *ProjectsLocationsCatalogsServingConfigsPredictCall) Do(opts ...googleap // ], // "parameters": { // "placement": { - // "description": "Required. Full resource name of the format: {name=projects/*/locations/global/catalogs/default_catalog/servingConfigs/*} or {name=projects/*/locations/global/catalogs/default_catalog/placements/*}. We recommend using the `servingConfigs` resource. `placements` is a legacy resource. The ID of the Recommendations AI serving config or placement. Before you can request predictions from your model, you must create at least one serving config or placement for it. For more information, see [Managing serving configurations]. (https://cloud.google.com/retail/docs/manage-configs). The full list of available serving configs can be seen at https://console.cloud.google.com/ai/retail/catalogs/default_catalog/configs", + // "description": "Required. Full resource name of the format: {name=projects/*/locations/global/catalogs/default_catalog/servingConfigs/*} or {name=projects/*/locations/global/catalogs/default_catalog/placements/*}. We recommend using the `servingConfigs` resource. `placements` is a legacy resource. The ID of the Recommendations AI serving config or placement. Before you can request predictions from your model, you must create at least one serving config or placement for it. For more information, see [Managing serving configurations] (https://cloud.google.com/retail/docs/manage-configs). The full list of available serving configs can be seen at https://console.cloud.google.com/ai/retail/catalogs/default_catalog/configs", // "location": "path", // "pattern": "^projects/[^/]+/locations/[^/]+/catalogs/[^/]+/servingConfigs/[^/]+$", // "required": true, diff --git a/retail/v2beta/retail-api.json b/retail/v2beta/retail-api.json index 9a472412cd3..17145e07c91 100644 --- a/retail/v2beta/retail-api.json +++ b/retail/v2beta/retail-api.json @@ -1149,7 +1149,7 @@ ], "parameters": { "placement": { - "description": "Required. Full resource name of the format: {name=projects/*/locations/global/catalogs/default_catalog/servingConfigs/*} or {name=projects/*/locations/global/catalogs/default_catalog/placements/*}. We recommend using the `servingConfigs` resource. `placements` is a legacy resource. The ID of the Recommendations AI serving config or placement. Before you can request predictions from your model, you must create at least one serving config or placement for it. For more information, see [Managing serving configurations]. (https://cloud.google.com/retail/docs/manage-configs). The full list of available serving configs can be seen at https://console.cloud.google.com/ai/retail/catalogs/default_catalog/configs", + "description": "Required. Full resource name of the format: {name=projects/*/locations/global/catalogs/default_catalog/servingConfigs/*} or {name=projects/*/locations/global/catalogs/default_catalog/placements/*}. We recommend using the `servingConfigs` resource. `placements` is a legacy resource. The ID of the Recommendations AI serving config or placement. Before you can request predictions from your model, you must create at least one serving config or placement for it. For more information, see [Managing serving configurations] (https://cloud.google.com/retail/docs/manage-configs). The full list of available serving configs can be seen at https://console.cloud.google.com/ai/retail/catalogs/default_catalog/configs", "location": "path", "pattern": "^projects/[^/]+/locations/[^/]+/catalogs/[^/]+/placements/[^/]+$", "required": true, @@ -1390,7 +1390,7 @@ ], "parameters": { "placement": { - "description": "Required. Full resource name of the format: {name=projects/*/locations/global/catalogs/default_catalog/servingConfigs/*} or {name=projects/*/locations/global/catalogs/default_catalog/placements/*}. We recommend using the `servingConfigs` resource. `placements` is a legacy resource. The ID of the Recommendations AI serving config or placement. Before you can request predictions from your model, you must create at least one serving config or placement for it. For more information, see [Managing serving configurations]. (https://cloud.google.com/retail/docs/manage-configs). The full list of available serving configs can be seen at https://console.cloud.google.com/ai/retail/catalogs/default_catalog/configs", + "description": "Required. Full resource name of the format: {name=projects/*/locations/global/catalogs/default_catalog/servingConfigs/*} or {name=projects/*/locations/global/catalogs/default_catalog/placements/*}. We recommend using the `servingConfigs` resource. `placements` is a legacy resource. The ID of the Recommendations AI serving config or placement. Before you can request predictions from your model, you must create at least one serving config or placement for it. For more information, see [Managing serving configurations] (https://cloud.google.com/retail/docs/manage-configs). The full list of available serving configs can be seen at https://console.cloud.google.com/ai/retail/catalogs/default_catalog/configs", "location": "path", "pattern": "^projects/[^/]+/locations/[^/]+/catalogs/[^/]+/servingConfigs/[^/]+$", "required": true, @@ -1770,7 +1770,7 @@ } } }, - "revision": "20220408", + "revision": "20220414", "rootUrl": "https://retail.googleapis.com/", "schemas": { "GoogleApiHttpBody": { @@ -3266,7 +3266,7 @@ "description": "Required. The desired input location of the data." }, "notificationPubsubTopic": { - "description": "Pub/Sub topic for receiving notification. If this field is set, when the import is finished, a notification will be sent to specified Pub/Sub topic. The message data will be JSON string of a Operation. Format of the Pub/Sub topic is `projects/{project}/topics/{topic}`. Only supported when ImportProductsRequest.reconciliation_mode is set to `FULL`.", + "description": "Full Pub/Sub topic name for receiving notification. If this field is set, when the import is finished, a notification will be sent to specified Pub/Sub topic. The message data will be JSON string of a Operation. Format of the Pub/Sub topic is `projects/{project}/topics/{topic}`. It has to be within the same project as ImportProductsRequest.parent. Make sure that both `cloud-retail-customer-data-access@system.gserviceaccount.com` and `service-@gcp-sa-retail.iam.gserviceaccount.com` have the `pubsub.topics.publish` IAM permission on the topic. Only supported when ImportProductsRequest.reconciliation_mode is set to `FULL`.", "type": "string" }, "reconciliationMode": { @@ -3626,7 +3626,7 @@ "type": "string" }, "originalPrice": { - "description": "Price of the product without any discount. If zero, by default set to be the price.", + "description": "Price of the product without any discount. If zero, by default set to be the price. If set, original_price should be greater than or equal to price, otherwise an INVALID_ARGUMENT error is thrown.", "format": "float", "type": "number" }, @@ -4411,6 +4411,13 @@ "description": "The filter syntax consists of an expression language for constructing a predicate from one or more fields of the products being filtered. Filter expression is case-sensitive. See more details at this [user guide](https://cloud.google.com/retail/docs/filter-and-order#filter). If this field is unrecognizable, an INVALID_ARGUMENT is returned.", "type": "string" }, + "labels": { + "additionalProperties": { + "type": "string" + }, + "description": "The labels applied to a resource must meet the following requirements: * Each resource can have multiple labels, up to a maximum of 64. * Each label must be a key-value pair. * Keys have a minimum length of 1 character and a maximum length of 63 characters, and cannot be empty. Values can be empty, and have a maximum length of 63 characters. * Keys and values can contain only lowercase letters, numeric characters, underscores, and dashes. All characters must use UTF-8 encoding, and international characters are allowed. * The key portion of a label must be unique. However, you can use the same key with multiple resources. * Keys must start with a lowercase letter or international character. See [Google Cloud Document](https://cloud.google.com/resource-manager/docs/creating-managing-labels#requirements) for more details.", + "type": "object" + }, "offset": { "description": "A 0-indexed integer that specifies the current offset (that is, starting result location, amongst the Products deemed by the API as relevant) in search results. This field is only considered if page_token is unset. If this field is negative, an INVALID_ARGUMENT is returned.", "format": "int32", diff --git a/retail/v2beta/retail-gen.go b/retail/v2beta/retail-gen.go index 5c526fce7f2..3dd2459acca 100644 --- a/retail/v2beta/retail-gen.go +++ b/retail/v2beta/retail-gen.go @@ -3132,12 +3132,16 @@ type GoogleCloudRetailV2betaImportProductsRequest struct { // InputConfig: Required. The desired input location of the data. InputConfig *GoogleCloudRetailV2betaProductInputConfig `json:"inputConfig,omitempty"` - // NotificationPubsubTopic: Pub/Sub topic for receiving notification. If - // this field is set, when the import is finished, a notification will - // be sent to specified Pub/Sub topic. The message data will be JSON - // string of a Operation. Format of the Pub/Sub topic is - // `projects/{project}/topics/{topic}`. Only supported when - // ImportProductsRequest.reconciliation_mode is set to `FULL`. + // NotificationPubsubTopic: Full Pub/Sub topic name for receiving + // notification. If this field is set, when the import is finished, a + // notification will be sent to specified Pub/Sub topic. The message + // data will be JSON string of a Operation. Format of the Pub/Sub topic + // is `projects/{project}/topics/{topic}`. It has to be within the same + // project as ImportProductsRequest.parent. Make sure that both + // `cloud-retail-customer-data-access@system.gserviceaccount.com` and + // `service-@gcp-sa-retail.iam.gserviceaccount.com` have the + // `pubsub.topics.publish` IAM permission on the topic. Only supported + // when ImportProductsRequest.reconciliation_mode is set to `FULL`. NotificationPubsubTopic string `json:"notificationPubsubTopic,omitempty"` // ReconciliationMode: The mode of reconciliation between existing @@ -3870,7 +3874,9 @@ type GoogleCloudRetailV2betaPriceInfo struct { CurrencyCode string `json:"currencyCode,omitempty"` // OriginalPrice: Price of the product without any discount. If zero, by - // default set to be the price. + // default set to be the price. If set, original_price should be greater + // than or equal to price, otherwise an INVALID_ARGUMENT error is + // thrown. OriginalPrice float64 `json:"originalPrice,omitempty"` // Price: Price of the product. Google Merchant Center property price @@ -5454,6 +5460,21 @@ type GoogleCloudRetailV2betaSearchRequest struct { // this field is unrecognizable, an INVALID_ARGUMENT is returned. Filter string `json:"filter,omitempty"` + // Labels: The labels applied to a resource must meet the following + // requirements: * Each resource can have multiple labels, up to a + // maximum of 64. * Each label must be a key-value pair. * Keys have a + // minimum length of 1 character and a maximum length of 63 characters, + // and cannot be empty. Values can be empty, and have a maximum length + // of 63 characters. * Keys and values can contain only lowercase + // letters, numeric characters, underscores, and dashes. All characters + // must use UTF-8 encoding, and international characters are allowed. * + // The key portion of a label must be unique. However, you can use the + // same key with multiple resources. * Keys must start with a lowercase + // letter or international character. See Google Cloud Document + // (https://cloud.google.com/resource-manager/docs/creating-managing-labels#requirements) + // for more details. + Labels map[string]string `json:"labels,omitempty"` + // Offset: A 0-indexed integer that specifies the current offset (that // is, starting result location, amongst the Products deemed by the API // as relevant) in search results. This field is only considered if @@ -12392,7 +12413,7 @@ type ProjectsLocationsCatalogsPlacementsPredictCall struct { // serving config or placement. Before you can request predictions // from your model, you must create at least one serving config or // placement for it. For more information, see [Managing serving -// configurations]. +// configurations] // (https://cloud.google.com/retail/docs/manage-configs). The full // list of available serving configs can be seen at // https://console.cloud.google.com/ai/retail/catalogs/default_catalog/configs. @@ -12504,7 +12525,7 @@ func (c *ProjectsLocationsCatalogsPlacementsPredictCall) Do(opts ...googleapi.Ca // ], // "parameters": { // "placement": { - // "description": "Required. Full resource name of the format: {name=projects/*/locations/global/catalogs/default_catalog/servingConfigs/*} or {name=projects/*/locations/global/catalogs/default_catalog/placements/*}. We recommend using the `servingConfigs` resource. `placements` is a legacy resource. The ID of the Recommendations AI serving config or placement. Before you can request predictions from your model, you must create at least one serving config or placement for it. For more information, see [Managing serving configurations]. (https://cloud.google.com/retail/docs/manage-configs). The full list of available serving configs can be seen at https://console.cloud.google.com/ai/retail/catalogs/default_catalog/configs", + // "description": "Required. Full resource name of the format: {name=projects/*/locations/global/catalogs/default_catalog/servingConfigs/*} or {name=projects/*/locations/global/catalogs/default_catalog/placements/*}. We recommend using the `servingConfigs` resource. `placements` is a legacy resource. The ID of the Recommendations AI serving config or placement. Before you can request predictions from your model, you must create at least one serving config or placement for it. For more information, see [Managing serving configurations] (https://cloud.google.com/retail/docs/manage-configs). The full list of available serving configs can be seen at https://console.cloud.google.com/ai/retail/catalogs/default_catalog/configs", // "location": "path", // "pattern": "^projects/[^/]+/locations/[^/]+/catalogs/[^/]+/placements/[^/]+$", // "required": true, @@ -13675,7 +13696,7 @@ type ProjectsLocationsCatalogsServingConfigsPredictCall struct { // serving config or placement. Before you can request predictions // from your model, you must create at least one serving config or // placement for it. For more information, see [Managing serving -// configurations]. +// configurations] // (https://cloud.google.com/retail/docs/manage-configs). The full // list of available serving configs can be seen at // https://console.cloud.google.com/ai/retail/catalogs/default_catalog/configs. @@ -13787,7 +13808,7 @@ func (c *ProjectsLocationsCatalogsServingConfigsPredictCall) Do(opts ...googleap // ], // "parameters": { // "placement": { - // "description": "Required. Full resource name of the format: {name=projects/*/locations/global/catalogs/default_catalog/servingConfigs/*} or {name=projects/*/locations/global/catalogs/default_catalog/placements/*}. We recommend using the `servingConfigs` resource. `placements` is a legacy resource. The ID of the Recommendations AI serving config or placement. Before you can request predictions from your model, you must create at least one serving config or placement for it. For more information, see [Managing serving configurations]. (https://cloud.google.com/retail/docs/manage-configs). The full list of available serving configs can be seen at https://console.cloud.google.com/ai/retail/catalogs/default_catalog/configs", + // "description": "Required. Full resource name of the format: {name=projects/*/locations/global/catalogs/default_catalog/servingConfigs/*} or {name=projects/*/locations/global/catalogs/default_catalog/placements/*}. We recommend using the `servingConfigs` resource. `placements` is a legacy resource. The ID of the Recommendations AI serving config or placement. Before you can request predictions from your model, you must create at least one serving config or placement for it. For more information, see [Managing serving configurations] (https://cloud.google.com/retail/docs/manage-configs). The full list of available serving configs can be seen at https://console.cloud.google.com/ai/retail/catalogs/default_catalog/configs", // "location": "path", // "pattern": "^projects/[^/]+/locations/[^/]+/catalogs/[^/]+/servingConfigs/[^/]+$", // "required": true, diff --git a/run/v2/run-api.json b/run/v2/run-api.json index 6a778d2b932..6ba9dc2cace 100644 --- a/run/v2/run-api.json +++ b/run/v2/run-api.json @@ -109,133 +109,38 @@ "resources": { "locations": { "resources": { - "operations": { - "methods": { - "delete": { - "description": "Deletes a long-running operation. This method indicates that the client is no longer interested in the operation result. It does not cancel the operation. If the server doesn't support this method, it returns `google.rpc.Code.UNIMPLEMENTED`.", - "flatPath": "v2/projects/{projectsId}/locations/{locationsId}/operations/{operationsId}", - "httpMethod": "DELETE", - "id": "run.projects.locations.operations.delete", - "parameterOrder": [ - "name" - ], - "parameters": { - "name": { - "description": "The name of the operation resource to be deleted.", - "location": "path", - "pattern": "^projects/[^/]+/locations/[^/]+/operations/[^/]+$", - "required": true, - "type": "string" - } - }, - "path": "v2/{+name}", - "response": { - "$ref": "GoogleProtobufEmpty" - }, - "scopes": [ - "https://www.googleapis.com/auth/cloud-platform" - ] - }, - "get": { - "description": "Gets the latest state of a long-running operation. Clients can use this method to poll the operation result at intervals as recommended by the API service.", - "flatPath": "v2/projects/{projectsId}/locations/{locationsId}/operations/{operationsId}", - "httpMethod": "GET", - "id": "run.projects.locations.operations.get", - "parameterOrder": [ - "name" - ], - "parameters": { - "name": { - "description": "The name of the operation resource.", - "location": "path", - "pattern": "^projects/[^/]+/locations/[^/]+/operations/[^/]+$", - "required": true, - "type": "string" - } - }, - "path": "v2/{+name}", - "response": { - "$ref": "GoogleLongrunningOperation" - }, - "scopes": [ - "https://www.googleapis.com/auth/cloud-platform" - ] - }, - "list": { - "description": "Lists operations that match the specified filter in the request. If the server doesn't support this method, it returns `UNIMPLEMENTED`. NOTE: the `name` binding allows API services to override the binding to use different resource name schemes, such as `users/*/operations`. To override the binding, API services can add a binding such as `\"/v1/{name=users/*}/operations\"` to their service configuration. For backwards compatibility, the default name includes the operations collection id, however overriding users must ensure the name binding is the parent resource, without the operations collection id.", - "flatPath": "v2/projects/{projectsId}/locations/{locationsId}/operations", - "httpMethod": "GET", - "id": "run.projects.locations.operations.list", - "parameterOrder": [ - "name" - ], - "parameters": { - "filter": { - "description": "Optional. A filter for matching the completed or in-progress operations. The supported formats of *filter* are: To query for only completed operations: done:true To query for only ongoing operations: done:false Must be empty to query for all of the latest operations for the given parent project.", - "location": "query", - "type": "string" - }, - "name": { - "description": "Required. To query for all of the operations for a project.", - "location": "path", - "pattern": "^projects/[^/]+/locations/[^/]+$", - "required": true, - "type": "string" - }, - "pageSize": { - "description": "The maximum number of records that should be returned. Requested page size cannot exceed 100. If not set or set to less than or equal to 0, the default page size is 100. .", - "format": "int32", - "location": "query", - "type": "integer" - }, - "pageToken": { - "description": "Token identifying which result to start with, which is returned by a previous list call.", - "location": "query", - "type": "string" - } - }, - "path": "v2/{+name}/operations", - "response": { - "$ref": "GoogleLongrunningListOperationsResponse" - }, - "scopes": [ - "https://www.googleapis.com/auth/cloud-platform" - ] - } - } - }, - "services": { + "jobs": { "methods": { "create": { - "description": "Creates a new Service in a given project and location.", - "flatPath": "v2/projects/{projectsId}/locations/{locationsId}/services", + "description": "Create a Job.", + "flatPath": "v2/projects/{projectsId}/locations/{locationsId}/jobs", "httpMethod": "POST", - "id": "run.projects.locations.services.create", + "id": "run.projects.locations.jobs.create", "parameterOrder": [ "parent" ], "parameters": { + "jobId": { + "description": "Required. The unique identifier for the Job. The name of the job becomes {parent}/jobs/{job_id}.", + "location": "query", + "type": "string" + }, "parent": { - "description": "Required. The location and project in which this service should be created. Format: projects/{projectnumber}/locations/{location}", + "description": "Required. The location and project in which this Job should be created. Format: projects/{projectnumber}/locations/{location}", "location": "path", "pattern": "^projects/[^/]+/locations/[^/]+$", "required": true, "type": "string" }, - "serviceId": { - "description": "Required. The unique identifier for the Service. The name of the service becomes {parent}/services/{service_id}.", - "location": "query", - "type": "string" - }, "validateOnly": { "description": "Indicates that the request should be validated and default values populated, without persisting the request or creating any resources.", "location": "query", "type": "boolean" } }, - "path": "v2/{+parent}/services", + "path": "v2/{+parent}/jobs", "request": { - "$ref": "GoogleCloudRunV2Service" + "$ref": "GoogleCloudRunV2Job" }, "response": { "$ref": "GoogleLongrunningOperation" @@ -245,10 +150,10 @@ ] }, "delete": { - "description": "Deletes a Service. This will cause the Service to stop serving traffic and will delete all revisions.", - "flatPath": "v2/projects/{projectsId}/locations/{locationsId}/services/{servicesId}", + "description": "Deletes a Job.", + "flatPath": "v2/projects/{projectsId}/locations/{locationsId}/jobs/{jobsId}", "httpMethod": "DELETE", - "id": "run.projects.locations.services.delete", + "id": "run.projects.locations.jobs.delete", "parameterOrder": [ "name" ], @@ -258,10 +163,15 @@ "location": "query", "type": "string" }, + "force": { + "description": "If set to true, the Job and its Executions will be deleted no matter whether any Executions are still running or not. If set to false or unset, the Job and its Executions can only be deleted if there are no running Executions. Any running Execution will fail the deletion.", + "location": "query", + "type": "boolean" + }, "name": { - "description": "Required. The full name of the Service. Format: projects/{projectnumber}/locations/{location}/services/{service}", + "description": "Required. The full name of the Job. Format: projects/{projectnumber}/locations/{location}/jobs/{job}", "location": "path", - "pattern": "^projects/[^/]+/locations/[^/]+/services/[^/]+$", + "pattern": "^projects/[^/]+/locations/[^/]+/jobs/[^/]+$", "required": true, "type": "string" }, @@ -280,35 +190,35 @@ ] }, "get": { - "description": "Gets information about a Service.", - "flatPath": "v2/projects/{projectsId}/locations/{locationsId}/services/{servicesId}", + "description": "Gets information about a Job.", + "flatPath": "v2/projects/{projectsId}/locations/{locationsId}/jobs/{jobsId}", "httpMethod": "GET", - "id": "run.projects.locations.services.get", + "id": "run.projects.locations.jobs.get", "parameterOrder": [ "name" ], "parameters": { "name": { - "description": "Required. The full name of the Service. Format: projects/{projectnumber}/locations/{location}/services/{service}", + "description": "Required. The full name of the Job. Format: projects/{projectnumber}/locations/{location}/jobs/{job}", "location": "path", - "pattern": "^projects/[^/]+/locations/[^/]+/services/[^/]+$", + "pattern": "^projects/[^/]+/locations/[^/]+/jobs/[^/]+$", "required": true, "type": "string" } }, "path": "v2/{+name}", "response": { - "$ref": "GoogleCloudRunV2Service" + "$ref": "GoogleCloudRunV2Job" }, "scopes": [ "https://www.googleapis.com/auth/cloud-platform" ] }, "getIamPolicy": { - "description": "Get the IAM Access Control policy currently in effect for the given Cloud Run Service. This result does not include any inherited policies.", - "flatPath": "v2/projects/{projectsId}/locations/{locationsId}/services/{servicesId}:getIamPolicy", + "description": "Get the IAM Access Control policy currently in effect for the given Job. This result does not include any inherited policies.", + "flatPath": "v2/projects/{projectsId}/locations/{locationsId}/jobs/{jobsId}:getIamPolicy", "httpMethod": "GET", - "id": "run.projects.locations.services.getIamPolicy", + "id": "run.projects.locations.jobs.getIamPolicy", "parameterOrder": [ "resource" ], @@ -322,7 +232,7 @@ "resource": { "description": "REQUIRED: The resource for which the policy is being requested. See the operation documentation for the appropriate value for this field.", "location": "path", - "pattern": "^projects/[^/]+/locations/[^/]+/services/[^/]+$", + "pattern": "^projects/[^/]+/locations/[^/]+/jobs/[^/]+$", "required": true, "type": "string" } @@ -336,27 +246,27 @@ ] }, "list": { - "description": "List Services.", - "flatPath": "v2/projects/{projectsId}/locations/{locationsId}/services", + "description": "List Jobs.", + "flatPath": "v2/projects/{projectsId}/locations/{locationsId}/jobs", "httpMethod": "GET", - "id": "run.projects.locations.services.list", + "id": "run.projects.locations.jobs.list", "parameterOrder": [ "parent" ], "parameters": { "pageSize": { - "description": "Maximum number of Services to return in this call.", + "description": "Maximum number of Jobs to return in this call.", "format": "int32", "location": "query", "type": "integer" }, "pageToken": { - "description": "A page token received from a previous call to ListServices. All other parameters must match.", + "description": "A page token received from a previous call to ListJobs. All other parameters must match.", "location": "query", "type": "string" }, "parent": { - "description": "Required. The location and project to list resources on. Location must be a valid GCP region, and may not be the \"-\" wildcard. Format: projects/{projectnumber}/locations/{location}", + "description": "Required. The location and project to list resources on. Format: projects/{projectnumber}/locations/{location}", "location": "path", "pattern": "^projects/[^/]+/locations/[^/]+$", "required": true, @@ -368,32 +278,32 @@ "type": "boolean" } }, - "path": "v2/{+parent}/services", + "path": "v2/{+parent}/jobs", "response": { - "$ref": "GoogleCloudRunV2ListServicesResponse" + "$ref": "GoogleCloudRunV2ListJobsResponse" }, "scopes": [ "https://www.googleapis.com/auth/cloud-platform" ] }, "patch": { - "description": "Updates a Service.", - "flatPath": "v2/projects/{projectsId}/locations/{locationsId}/services/{servicesId}", + "description": "Updates a Job.", + "flatPath": "v2/projects/{projectsId}/locations/{locationsId}/jobs/{jobsId}", "httpMethod": "PATCH", - "id": "run.projects.locations.services.patch", + "id": "run.projects.locations.jobs.patch", "parameterOrder": [ "name" ], "parameters": { "allowMissing": { - "description": "If set to true, and if the Service does not exist, it will create a new one. Caller must have both create and update permissions for this call if this is set to true.", + "description": "If set to true, and if the Job does not exist, it will create a new one. Caller must have both create and update permissions for this call if this is set to true.", "location": "query", "type": "boolean" }, "name": { - "description": "The fully qualified name of this Service. In CreateServiceRequest, this field is ignored, and instead composed from CreateServiceRequest.parent and CreateServiceRequest.service_id. Format: projects/{project}/locations/{location}/services/{service_id}", + "description": "The fully qualified name of this Job. Format: projects/{project}/locations/{location}/jobs/{job}", "location": "path", - "pattern": "^projects/[^/]+/locations/[^/]+/services/[^/]+$", + "pattern": "^projects/[^/]+/locations/[^/]+/jobs/[^/]+$", "required": true, "type": "string" }, @@ -411,7 +321,35 @@ }, "path": "v2/{+name}", "request": { - "$ref": "GoogleCloudRunV2Service" + "$ref": "GoogleCloudRunV2Job" + }, + "response": { + "$ref": "GoogleLongrunningOperation" + }, + "scopes": [ + "https://www.googleapis.com/auth/cloud-platform" + ] + }, + "run": { + "description": "Triggers creation of a new Execution of this Job.", + "flatPath": "v2/projects/{projectsId}/locations/{locationsId}/jobs/{jobsId}:run", + "httpMethod": "POST", + "id": "run.projects.locations.jobs.run", + "parameterOrder": [ + "name" + ], + "parameters": { + "name": { + "description": "Required. The full name of the Job. Format: projects/{projectnumber}/locations/{location}/jobs/{job}", + "location": "path", + "pattern": "^projects/[^/]+/locations/[^/]+/jobs/[^/]+$", + "required": true, + "type": "string" + } + }, + "path": "v2/{+name}:run", + "request": { + "$ref": "GoogleCloudRunV2RunJobRequest" }, "response": { "$ref": "GoogleLongrunningOperation" @@ -421,10 +359,10 @@ ] }, "setIamPolicy": { - "description": "Sets the IAM Access control policy for the specified Service. Overwrites any existing policy.", - "flatPath": "v2/projects/{projectsId}/locations/{locationsId}/services/{servicesId}:setIamPolicy", + "description": "Sets the IAM Access control policy for the specified Job. Overwrites any existing policy.", + "flatPath": "v2/projects/{projectsId}/locations/{locationsId}/jobs/{jobsId}:setIamPolicy", "httpMethod": "POST", - "id": "run.projects.locations.services.setIamPolicy", + "id": "run.projects.locations.jobs.setIamPolicy", "parameterOrder": [ "resource" ], @@ -432,7 +370,7 @@ "resource": { "description": "REQUIRED: The resource for which the policy is being specified. See the operation documentation for the appropriate value for this field.", "location": "path", - "pattern": "^projects/[^/]+/locations/[^/]+/services/[^/]+$", + "pattern": "^projects/[^/]+/locations/[^/]+/jobs/[^/]+$", "required": true, "type": "string" } @@ -450,9 +388,9 @@ }, "testIamPermissions": { "description": "Returns permissions that a caller has on the specified Project. There are no permissions required for making this API call.", - "flatPath": "v2/projects/{projectsId}/locations/{locationsId}/services/{servicesId}:testIamPermissions", + "flatPath": "v2/projects/{projectsId}/locations/{locationsId}/jobs/{jobsId}:testIamPermissions", "httpMethod": "POST", - "id": "run.projects.locations.services.testIamPermissions", + "id": "run.projects.locations.jobs.testIamPermissions", "parameterOrder": [ "resource" ], @@ -460,7 +398,7 @@ "resource": { "description": "REQUIRED: The resource for which the policy detail is being requested. See the operation documentation for the appropriate value for this field.", "location": "path", - "pattern": "^projects/[^/]+/locations/[^/]+/services/[^/]+$", + "pattern": "^projects/[^/]+/locations/[^/]+/jobs/[^/]+$", "required": true, "type": "string" } @@ -478,13 +416,13 @@ } }, "resources": { - "revisions": { + "executions": { "methods": { "delete": { - "description": "Delete a Revision.", - "flatPath": "v2/projects/{projectsId}/locations/{locationsId}/services/{servicesId}/revisions/{revisionsId}", + "description": "Delete an Execution.", + "flatPath": "v2/projects/{projectsId}/locations/{locationsId}/jobs/{jobsId}/executions/{executionsId}", "httpMethod": "DELETE", - "id": "run.projects.locations.services.revisions.delete", + "id": "run.projects.locations.jobs.executions.delete", "parameterOrder": [ "name" ], @@ -495,9 +433,9 @@ "type": "string" }, "name": { - "description": "Required. The name of the Revision to delete. Format: projects/{project}/locations/{location}/services/{service}/revisions/{revision}", + "description": "Required. The name of the Execution to delete. Format: projects/{project}/locations/{location}/jobs/{job}/executions/{execution}", "location": "path", - "pattern": "^projects/[^/]+/locations/[^/]+/services/[^/]+/revisions/[^/]+$", + "pattern": "^projects/[^/]+/locations/[^/]+/jobs/[^/]+/executions/[^/]+$", "required": true, "type": "string" }, @@ -516,54 +454,54 @@ ] }, "get": { - "description": "Gets information about a Revision.", - "flatPath": "v2/projects/{projectsId}/locations/{locationsId}/services/{servicesId}/revisions/{revisionsId}", + "description": "Gets information about a Execution.", + "flatPath": "v2/projects/{projectsId}/locations/{locationsId}/jobs/{jobsId}/executions/{executionsId}", "httpMethod": "GET", - "id": "run.projects.locations.services.revisions.get", + "id": "run.projects.locations.jobs.executions.get", "parameterOrder": [ "name" ], "parameters": { "name": { - "description": "Required. The full name of the Revision. Format: projects/{project}/locations/{location}/services/{service}/revisions/{revision}", + "description": "Required. The full name of the Execution. Format: projects/{project}/locations/{location}/jobs/{job}/executions/{execution}", "location": "path", - "pattern": "^projects/[^/]+/locations/[^/]+/services/[^/]+/revisions/[^/]+$", + "pattern": "^projects/[^/]+/locations/[^/]+/jobs/[^/]+/executions/[^/]+$", "required": true, "type": "string" } }, "path": "v2/{+name}", "response": { - "$ref": "GoogleCloudRunV2Revision" + "$ref": "GoogleCloudRunV2Execution" }, "scopes": [ "https://www.googleapis.com/auth/cloud-platform" ] }, "list": { - "description": "List Revisions from a given Service, or from a given location.", - "flatPath": "v2/projects/{projectsId}/locations/{locationsId}/services/{servicesId}/revisions", + "description": "List Executions from a Job.", + "flatPath": "v2/projects/{projectsId}/locations/{locationsId}/jobs/{jobsId}/executions", "httpMethod": "GET", - "id": "run.projects.locations.services.revisions.list", + "id": "run.projects.locations.jobs.executions.list", "parameterOrder": [ "parent" ], "parameters": { "pageSize": { - "description": "Maximum number of revisions to return in this call.", + "description": "Maximum number of Executions to return in this call.", "format": "int32", "location": "query", "type": "integer" }, "pageToken": { - "description": "A page token received from a previous call to ListRevisions. All other parameters must match.", + "description": "A page token received from a previous call to ListExecutions. All other parameters must match.", "location": "query", "type": "string" }, "parent": { - "description": "Required. The Service from which the Revisions should be listed. To list all Revisions across Services, use \"-\" instead of Service name. Format: projects/{project}/locations/{location}/services/{service}", + "description": "Required. The Execution from which the Executions should be listed. To list all Executions across Jobs, use \"-\" instead of Job name. Format: projects/{project}/locations/{location}/jobs/{job}", "location": "path", - "pattern": "^projects/[^/]+/locations/[^/]+/services/[^/]+$", + "pattern": "^projects/[^/]+/locations/[^/]+/jobs/[^/]+$", "required": true, "type": "string" }, @@ -573,341 +511,1310 @@ "type": "boolean" } }, - "path": "v2/{+parent}/revisions", + "path": "v2/{+parent}/executions", "response": { - "$ref": "GoogleCloudRunV2ListRevisionsResponse" + "$ref": "GoogleCloudRunV2ListExecutionsResponse" }, "scopes": [ "https://www.googleapis.com/auth/cloud-platform" ] } + }, + "resources": { + "tasks": { + "methods": { + "get": { + "description": "Gets information about a Task.", + "flatPath": "v2/projects/{projectsId}/locations/{locationsId}/jobs/{jobsId}/executions/{executionsId}/tasks/{tasksId}", + "httpMethod": "GET", + "id": "run.projects.locations.jobs.executions.tasks.get", + "parameterOrder": [ + "name" + ], + "parameters": { + "name": { + "description": "Required. The full name of the Task. Format: projects/{project}/locations/{location}/jobs/{job}/executions/{execution}/tasks/{task}", + "location": "path", + "pattern": "^projects/[^/]+/locations/[^/]+/jobs/[^/]+/executions/[^/]+/tasks/[^/]+$", + "required": true, + "type": "string" + } + }, + "path": "v2/{+name}", + "response": { + "$ref": "GoogleCloudRunV2Task" + }, + "scopes": [ + "https://www.googleapis.com/auth/cloud-platform" + ] + }, + "list": { + "description": "List Tasks from an Execution of a Job.", + "flatPath": "v2/projects/{projectsId}/locations/{locationsId}/jobs/{jobsId}/executions/{executionsId}/tasks", + "httpMethod": "GET", + "id": "run.projects.locations.jobs.executions.tasks.list", + "parameterOrder": [ + "parent" + ], + "parameters": { + "pageSize": { + "description": "Maximum number of Tasks to return in this call.", + "format": "int32", + "location": "query", + "type": "integer" + }, + "pageToken": { + "description": "A page token received from a previous call to ListTasks. All other parameters must match.", + "location": "query", + "type": "string" + }, + "parent": { + "description": "Required. The Execution from which the Tasks should be listed. To list all Tasks across Executions of a Job, use \"-\" instead of Execution name. To list all Tasks across Jobs, use \"-\" instead of Job name. Format: projects/{project}/locations/{location}/jobs/{job}/executions/{execution}", + "location": "path", + "pattern": "^projects/[^/]+/locations/[^/]+/jobs/[^/]+/executions/[^/]+$", + "required": true, + "type": "string" + }, + "showDeleted": { + "description": "If true, returns deleted (but unexpired) resources along with active ones.", + "location": "query", + "type": "boolean" + } + }, + "path": "v2/{+parent}/tasks", + "response": { + "$ref": "GoogleCloudRunV2ListTasksResponse" + }, + "scopes": [ + "https://www.googleapis.com/auth/cloud-platform" + ] + } + } + } } } } - } - } - } - } - } - }, - "revision": "20220408", - "rootUrl": "https://run.googleapis.com/", - "schemas": { - "GoogleCloudRunV2BinaryAuthorization": { - "description": "Settings for Binary Authorization feature.", - "id": "GoogleCloudRunV2BinaryAuthorization", - "properties": { - "breakglassJustification": { - "description": "If present, indicates to use Breakglass using this justification. If use_default is False, then it must be empty. For more information on breakglass, see https://cloud.google.com/binary-authorization/docs/using-breakglass", - "type": "string" - }, - "policy": { - "description": "The path to a binary authorization policy. Format: projects/{project}/platforms/cloudRun/{policy-name}", - "type": "string" - }, - "useDefault": { - "description": "If True, indicates to use the default project's binary authorization policy. If False, binary authorization will be disabled.", - "type": "boolean" - } - }, - "type": "object" - }, - "GoogleCloudRunV2CloudSqlInstance": { - "description": "Represents a specific Cloud SQL instance.", - "id": "GoogleCloudRunV2CloudSqlInstance", - "properties": { - "instances": { - "description": "The Cloud SQL instance connection names, as can be found in https://console.cloud.google.com/sql/instances. Visit https://cloud.google.com/sql/docs/mysql/connect-run for more information on how to connect Cloud SQL and Cloud Run. Format: {project}:{location}:{instance}", - "items": { - "type": "string" - }, - "type": "array" - } - }, - "type": "object" - }, - "GoogleCloudRunV2Condition": { - "description": "Defines a status condition for a resource.", - "id": "GoogleCloudRunV2Condition", - "properties": { - "domainMappingReason": { - "description": "A reason for the domain mapping condition.", - "enum": [ - "DOMAIN_MAPPING_REASON_UNDEFINED", - "ROUTE_NOT_READY", - "PERMISSION_DENIED", - "CERTIFICATE_ALREADY_EXISTS", - "MAPPING_ALREADY_EXISTS", - "CERTIFICATE_PENDING", - "CERTIFICATE_FAILED" - ], - "enumDescriptions": [ - "Default value.", - "Internal route is not yet ready.", - "Insufficient permissions.", - "Certificate already exists.", + }, + "operations": { + "methods": { + "delete": { + "description": "Deletes a long-running operation. This method indicates that the client is no longer interested in the operation result. It does not cancel the operation. If the server doesn't support this method, it returns `google.rpc.Code.UNIMPLEMENTED`.", + "flatPath": "v2/projects/{projectsId}/locations/{locationsId}/operations/{operationsId}", + "httpMethod": "DELETE", + "id": "run.projects.locations.operations.delete", + "parameterOrder": [ + "name" + ], + "parameters": { + "name": { + "description": "The name of the operation resource to be deleted.", + "location": "path", + "pattern": "^projects/[^/]+/locations/[^/]+/operations/[^/]+$", + "required": true, + "type": "string" + } + }, + "path": "v2/{+name}", + "response": { + "$ref": "GoogleProtobufEmpty" + }, + "scopes": [ + "https://www.googleapis.com/auth/cloud-platform" + ] + }, + "get": { + "description": "Gets the latest state of a long-running operation. Clients can use this method to poll the operation result at intervals as recommended by the API service.", + "flatPath": "v2/projects/{projectsId}/locations/{locationsId}/operations/{operationsId}", + "httpMethod": "GET", + "id": "run.projects.locations.operations.get", + "parameterOrder": [ + "name" + ], + "parameters": { + "name": { + "description": "The name of the operation resource.", + "location": "path", + "pattern": "^projects/[^/]+/locations/[^/]+/operations/[^/]+$", + "required": true, + "type": "string" + } + }, + "path": "v2/{+name}", + "response": { + "$ref": "GoogleLongrunningOperation" + }, + "scopes": [ + "https://www.googleapis.com/auth/cloud-platform" + ] + }, + "list": { + "description": "Lists operations that match the specified filter in the request. If the server doesn't support this method, it returns `UNIMPLEMENTED`. NOTE: the `name` binding allows API services to override the binding to use different resource name schemes, such as `users/*/operations`. To override the binding, API services can add a binding such as `\"/v1/{name=users/*}/operations\"` to their service configuration. For backwards compatibility, the default name includes the operations collection id, however overriding users must ensure the name binding is the parent resource, without the operations collection id.", + "flatPath": "v2/projects/{projectsId}/locations/{locationsId}/operations", + "httpMethod": "GET", + "id": "run.projects.locations.operations.list", + "parameterOrder": [ + "name" + ], + "parameters": { + "filter": { + "description": "Optional. A filter for matching the completed or in-progress operations. The supported formats of *filter* are: To query for only completed operations: done:true To query for only ongoing operations: done:false Must be empty to query for all of the latest operations for the given parent project.", + "location": "query", + "type": "string" + }, + "name": { + "description": "Required. To query for all of the operations for a project.", + "location": "path", + "pattern": "^projects/[^/]+/locations/[^/]+$", + "required": true, + "type": "string" + }, + "pageSize": { + "description": "The maximum number of records that should be returned. Requested page size cannot exceed 100. If not set or set to less than or equal to 0, the default page size is 100. .", + "format": "int32", + "location": "query", + "type": "integer" + }, + "pageToken": { + "description": "Token identifying which result to start with, which is returned by a previous list call.", + "location": "query", + "type": "string" + } + }, + "path": "v2/{+name}/operations", + "response": { + "$ref": "GoogleLongrunningListOperationsResponse" + }, + "scopes": [ + "https://www.googleapis.com/auth/cloud-platform" + ] + } + } + }, + "services": { + "methods": { + "create": { + "description": "Creates a new Service in a given project and location.", + "flatPath": "v2/projects/{projectsId}/locations/{locationsId}/services", + "httpMethod": "POST", + "id": "run.projects.locations.services.create", + "parameterOrder": [ + "parent" + ], + "parameters": { + "parent": { + "description": "Required. The location and project in which this service should be created. Format: projects/{projectnumber}/locations/{location}", + "location": "path", + "pattern": "^projects/[^/]+/locations/[^/]+$", + "required": true, + "type": "string" + }, + "serviceId": { + "description": "Required. The unique identifier for the Service. The name of the service becomes {parent}/services/{service_id}.", + "location": "query", + "type": "string" + }, + "validateOnly": { + "description": "Indicates that the request should be validated and default values populated, without persisting the request or creating any resources.", + "location": "query", + "type": "boolean" + } + }, + "path": "v2/{+parent}/services", + "request": { + "$ref": "GoogleCloudRunV2Service" + }, + "response": { + "$ref": "GoogleLongrunningOperation" + }, + "scopes": [ + "https://www.googleapis.com/auth/cloud-platform" + ] + }, + "delete": { + "description": "Deletes a Service. This will cause the Service to stop serving traffic and will delete all revisions.", + "flatPath": "v2/projects/{projectsId}/locations/{locationsId}/services/{servicesId}", + "httpMethod": "DELETE", + "id": "run.projects.locations.services.delete", + "parameterOrder": [ + "name" + ], + "parameters": { + "etag": { + "description": "A system-generated fingerprint for this version of the resource. May be used to detect modification conflict during updates.", + "location": "query", + "type": "string" + }, + "name": { + "description": "Required. The full name of the Service. Format: projects/{projectnumber}/locations/{location}/services/{service}", + "location": "path", + "pattern": "^projects/[^/]+/locations/[^/]+/services/[^/]+$", + "required": true, + "type": "string" + }, + "validateOnly": { + "description": "Indicates that the request should be validated without actually deleting any resources.", + "location": "query", + "type": "boolean" + } + }, + "path": "v2/{+name}", + "response": { + "$ref": "GoogleLongrunningOperation" + }, + "scopes": [ + "https://www.googleapis.com/auth/cloud-platform" + ] + }, + "get": { + "description": "Gets information about a Service.", + "flatPath": "v2/projects/{projectsId}/locations/{locationsId}/services/{servicesId}", + "httpMethod": "GET", + "id": "run.projects.locations.services.get", + "parameterOrder": [ + "name" + ], + "parameters": { + "name": { + "description": "Required. The full name of the Service. Format: projects/{projectnumber}/locations/{location}/services/{service}", + "location": "path", + "pattern": "^projects/[^/]+/locations/[^/]+/services/[^/]+$", + "required": true, + "type": "string" + } + }, + "path": "v2/{+name}", + "response": { + "$ref": "GoogleCloudRunV2Service" + }, + "scopes": [ + "https://www.googleapis.com/auth/cloud-platform" + ] + }, + "getIamPolicy": { + "description": "Get the IAM Access Control policy currently in effect for the given Cloud Run Service. This result does not include any inherited policies.", + "flatPath": "v2/projects/{projectsId}/locations/{locationsId}/services/{servicesId}:getIamPolicy", + "httpMethod": "GET", + "id": "run.projects.locations.services.getIamPolicy", + "parameterOrder": [ + "resource" + ], + "parameters": { + "options.requestedPolicyVersion": { + "description": "Optional. The maximum policy version that will be used to format the policy. Valid values are 0, 1, and 3. Requests specifying an invalid value will be rejected. Requests for policies with any conditional role bindings must specify version 3. Policies with no conditional role bindings may specify any valid value or leave the field unset. The policy in the response might use the policy version that you specified, or it might use a lower policy version. For example, if you specify version 3, but the policy has no conditional role bindings, the response uses version 1. To learn which resources support conditions in their IAM policies, see the [IAM documentation](https://cloud.google.com/iam/help/conditions/resource-policies).", + "format": "int32", + "location": "query", + "type": "integer" + }, + "resource": { + "description": "REQUIRED: The resource for which the policy is being requested. See the operation documentation for the appropriate value for this field.", + "location": "path", + "pattern": "^projects/[^/]+/locations/[^/]+/services/[^/]+$", + "required": true, + "type": "string" + } + }, + "path": "v2/{+resource}:getIamPolicy", + "response": { + "$ref": "GoogleIamV1Policy" + }, + "scopes": [ + "https://www.googleapis.com/auth/cloud-platform" + ] + }, + "list": { + "description": "List Services.", + "flatPath": "v2/projects/{projectsId}/locations/{locationsId}/services", + "httpMethod": "GET", + "id": "run.projects.locations.services.list", + "parameterOrder": [ + "parent" + ], + "parameters": { + "pageSize": { + "description": "Maximum number of Services to return in this call.", + "format": "int32", + "location": "query", + "type": "integer" + }, + "pageToken": { + "description": "A page token received from a previous call to ListServices. All other parameters must match.", + "location": "query", + "type": "string" + }, + "parent": { + "description": "Required. The location and project to list resources on. Location must be a valid GCP region, and may not be the \"-\" wildcard. Format: projects/{projectnumber}/locations/{location}", + "location": "path", + "pattern": "^projects/[^/]+/locations/[^/]+$", + "required": true, + "type": "string" + }, + "showDeleted": { + "description": "If true, returns deleted (but unexpired) resources along with active ones.", + "location": "query", + "type": "boolean" + } + }, + "path": "v2/{+parent}/services", + "response": { + "$ref": "GoogleCloudRunV2ListServicesResponse" + }, + "scopes": [ + "https://www.googleapis.com/auth/cloud-platform" + ] + }, + "patch": { + "description": "Updates a Service.", + "flatPath": "v2/projects/{projectsId}/locations/{locationsId}/services/{servicesId}", + "httpMethod": "PATCH", + "id": "run.projects.locations.services.patch", + "parameterOrder": [ + "name" + ], + "parameters": { + "allowMissing": { + "description": "If set to true, and if the Service does not exist, it will create a new one. Caller must have both create and update permissions for this call if this is set to true.", + "location": "query", + "type": "boolean" + }, + "name": { + "description": "The fully qualified name of this Service. In CreateServiceRequest, this field is ignored, and instead composed from CreateServiceRequest.parent and CreateServiceRequest.service_id. Format: projects/{project}/locations/{location}/services/{service_id}", + "location": "path", + "pattern": "^projects/[^/]+/locations/[^/]+/services/[^/]+$", + "required": true, + "type": "string" + }, + "updateMask": { + "description": "The list of fields to be updated.", + "format": "google-fieldmask", + "location": "query", + "type": "string" + }, + "validateOnly": { + "description": "Indicates that the request should be validated and default values populated, without persisting the request or updating any resources.", + "location": "query", + "type": "boolean" + } + }, + "path": "v2/{+name}", + "request": { + "$ref": "GoogleCloudRunV2Service" + }, + "response": { + "$ref": "GoogleLongrunningOperation" + }, + "scopes": [ + "https://www.googleapis.com/auth/cloud-platform" + ] + }, + "setIamPolicy": { + "description": "Sets the IAM Access control policy for the specified Service. Overwrites any existing policy.", + "flatPath": "v2/projects/{projectsId}/locations/{locationsId}/services/{servicesId}:setIamPolicy", + "httpMethod": "POST", + "id": "run.projects.locations.services.setIamPolicy", + "parameterOrder": [ + "resource" + ], + "parameters": { + "resource": { + "description": "REQUIRED: The resource for which the policy is being specified. See the operation documentation for the appropriate value for this field.", + "location": "path", + "pattern": "^projects/[^/]+/locations/[^/]+/services/[^/]+$", + "required": true, + "type": "string" + } + }, + "path": "v2/{+resource}:setIamPolicy", + "request": { + "$ref": "GoogleIamV1SetIamPolicyRequest" + }, + "response": { + "$ref": "GoogleIamV1Policy" + }, + "scopes": [ + "https://www.googleapis.com/auth/cloud-platform" + ] + }, + "testIamPermissions": { + "description": "Returns permissions that a caller has on the specified Project. There are no permissions required for making this API call.", + "flatPath": "v2/projects/{projectsId}/locations/{locationsId}/services/{servicesId}:testIamPermissions", + "httpMethod": "POST", + "id": "run.projects.locations.services.testIamPermissions", + "parameterOrder": [ + "resource" + ], + "parameters": { + "resource": { + "description": "REQUIRED: The resource for which the policy detail is being requested. See the operation documentation for the appropriate value for this field.", + "location": "path", + "pattern": "^projects/[^/]+/locations/[^/]+/services/[^/]+$", + "required": true, + "type": "string" + } + }, + "path": "v2/{+resource}:testIamPermissions", + "request": { + "$ref": "GoogleIamV1TestIamPermissionsRequest" + }, + "response": { + "$ref": "GoogleIamV1TestIamPermissionsResponse" + }, + "scopes": [ + "https://www.googleapis.com/auth/cloud-platform" + ] + } + }, + "resources": { + "revisions": { + "methods": { + "delete": { + "description": "Delete a Revision.", + "flatPath": "v2/projects/{projectsId}/locations/{locationsId}/services/{servicesId}/revisions/{revisionsId}", + "httpMethod": "DELETE", + "id": "run.projects.locations.services.revisions.delete", + "parameterOrder": [ + "name" + ], + "parameters": { + "etag": { + "description": "A system-generated fingerprint for this version of the resource. This may be used to detect modification conflict during updates.", + "location": "query", + "type": "string" + }, + "name": { + "description": "Required. The name of the Revision to delete. Format: projects/{project}/locations/{location}/services/{service}/revisions/{revision}", + "location": "path", + "pattern": "^projects/[^/]+/locations/[^/]+/services/[^/]+/revisions/[^/]+$", + "required": true, + "type": "string" + }, + "validateOnly": { + "description": "Indicates that the request should be validated without actually deleting any resources.", + "location": "query", + "type": "boolean" + } + }, + "path": "v2/{+name}", + "response": { + "$ref": "GoogleLongrunningOperation" + }, + "scopes": [ + "https://www.googleapis.com/auth/cloud-platform" + ] + }, + "get": { + "description": "Gets information about a Revision.", + "flatPath": "v2/projects/{projectsId}/locations/{locationsId}/services/{servicesId}/revisions/{revisionsId}", + "httpMethod": "GET", + "id": "run.projects.locations.services.revisions.get", + "parameterOrder": [ + "name" + ], + "parameters": { + "name": { + "description": "Required. The full name of the Revision. Format: projects/{project}/locations/{location}/services/{service}/revisions/{revision}", + "location": "path", + "pattern": "^projects/[^/]+/locations/[^/]+/services/[^/]+/revisions/[^/]+$", + "required": true, + "type": "string" + } + }, + "path": "v2/{+name}", + "response": { + "$ref": "GoogleCloudRunV2Revision" + }, + "scopes": [ + "https://www.googleapis.com/auth/cloud-platform" + ] + }, + "list": { + "description": "List Revisions from a given Service, or from a given location.", + "flatPath": "v2/projects/{projectsId}/locations/{locationsId}/services/{servicesId}/revisions", + "httpMethod": "GET", + "id": "run.projects.locations.services.revisions.list", + "parameterOrder": [ + "parent" + ], + "parameters": { + "pageSize": { + "description": "Maximum number of revisions to return in this call.", + "format": "int32", + "location": "query", + "type": "integer" + }, + "pageToken": { + "description": "A page token received from a previous call to ListRevisions. All other parameters must match.", + "location": "query", + "type": "string" + }, + "parent": { + "description": "Required. The Service from which the Revisions should be listed. To list all Revisions across Services, use \"-\" instead of Service name. Format: projects/{project}/locations/{location}/services/{service}", + "location": "path", + "pattern": "^projects/[^/]+/locations/[^/]+/services/[^/]+$", + "required": true, + "type": "string" + }, + "showDeleted": { + "description": "If true, returns deleted (but unexpired) resources along with active ones.", + "location": "query", + "type": "boolean" + } + }, + "path": "v2/{+parent}/revisions", + "response": { + "$ref": "GoogleCloudRunV2ListRevisionsResponse" + }, + "scopes": [ + "https://www.googleapis.com/auth/cloud-platform" + ] + } + } + } + } + } + } + } + } + } + }, + "revision": "20220415", + "rootUrl": "https://run.googleapis.com/", + "schemas": { + "GoogleCloudRunV2BinaryAuthorization": { + "description": "Settings for Binary Authorization feature.", + "id": "GoogleCloudRunV2BinaryAuthorization", + "properties": { + "breakglassJustification": { + "description": "If present, indicates to use Breakglass using this justification. If use_default is False, then it must be empty. For more information on breakglass, see https://cloud.google.com/binary-authorization/docs/using-breakglass", + "type": "string" + }, + "policy": { + "description": "The path to a binary authorization policy. Format: projects/{project}/platforms/cloudRun/{policy-name}", + "type": "string" + }, + "useDefault": { + "description": "If True, indicates to use the default project's binary authorization policy. If False, binary authorization will be disabled.", + "type": "boolean" + } + }, + "type": "object" + }, + "GoogleCloudRunV2CloudSqlInstance": { + "description": "Represents a specific Cloud SQL instance.", + "id": "GoogleCloudRunV2CloudSqlInstance", + "properties": { + "instances": { + "description": "The Cloud SQL instance connection names, as can be found in https://console.cloud.google.com/sql/instances. Visit https://cloud.google.com/sql/docs/mysql/connect-run for more information on how to connect Cloud SQL and Cloud Run. Format: {project}:{location}:{instance}", + "items": { + "type": "string" + }, + "type": "array" + } + }, + "type": "object" + }, + "GoogleCloudRunV2Condition": { + "description": "Defines a status condition for a resource.", + "id": "GoogleCloudRunV2Condition", + "properties": { + "domainMappingReason": { + "description": "A reason for the domain mapping condition.", + "enum": [ + "DOMAIN_MAPPING_REASON_UNDEFINED", + "ROUTE_NOT_READY", + "PERMISSION_DENIED", + "CERTIFICATE_ALREADY_EXISTS", + "MAPPING_ALREADY_EXISTS", + "CERTIFICATE_PENDING", + "CERTIFICATE_FAILED" + ], + "enumDescriptions": [ + "Default value.", + "Internal route is not yet ready.", + "Insufficient permissions.", + "Certificate already exists.", "Mapping already exists.", "Certificate issuance pending.", "Certificate issuance failed." ], "type": "string" }, - "executionReason": { - "description": "A reason for the execution condition.", - "enum": [ - "EXECUTION_REASON_UNDEFINED", - "JOB_STATUS_SERVICE_POLLING_ERROR", - "NON_ZERO_EXIT_CODE" - ], - "enumDescriptions": [ - "Default value.", - "Internal system error getting execution status. System will retry.", - "A task reached its retry limit and the last attempt failed due to the user container exiting with a non-zero exit code." - ], + "executionReason": { + "description": "A reason for the execution condition.", + "enum": [ + "EXECUTION_REASON_UNDEFINED", + "JOB_STATUS_SERVICE_POLLING_ERROR", + "NON_ZERO_EXIT_CODE" + ], + "enumDescriptions": [ + "Default value.", + "Internal system error getting execution status. System will retry.", + "A task reached its retry limit and the last attempt failed due to the user container exiting with a non-zero exit code." + ], + "type": "string" + }, + "internalReason": { + "description": "A reason for the internal condition.", + "enum": [ + "INTERNAL_REASON_UNDEFINED", + "CONFLICTING_REVISION_NAME", + "REVISION_MISSING", + "CONFIGURATION_MISSING", + "ASSIGNING_TRAFFIC", + "UPDATING_INGRESS_TRAFFIC_ALLOWED", + "REVISION_ORG_POLICY_VIOLATION", + "UPDATING_GCFV2_URI_DATA" + ], + "enumDescriptions": [ + "Default value.", + "The revision name provided conflicts with an existing one.", + "Revision is missing; this is usually a transient reason.", + "Internal configuration is missing; this is usually a transient reason.", + "Assigning traffic; this is a transient reason.", + "Updating ingress traffic settings; this is a transient reason.", + "The revision can't be created because it violates an org policy setting.", + "Updating GCFv2 URI data; this is a transient reason." + ], + "type": "string" + }, + "lastTransitionTime": { + "description": "Last time the condition transitioned from one status to another.", + "format": "google-datetime", + "type": "string" + }, + "message": { + "description": "Human readable message indicating details about the current status.", + "type": "string" + }, + "reason": { + "description": "A common (service-level) reason for this condition.", + "enum": [ + "COMMON_REASON_UNDEFINED", + "UNKNOWN", + "ROUTE_MISSING", + "REVISION_FAILED", + "PROGRESS_DEADLINE_EXCEEDED", + "BUILD_STEP_FAILED", + "CONTAINER_MISSING", + "CONTAINER_PERMISSION_DENIED", + "CONTAINER_IMAGE_UNAUTHORIZED", + "CONTAINER_IMAGE_AUTHORIZATION_CHECK_FAILED", + "ENCRYPTION_KEY_PERMISSION_DENIED", + "ENCRYPTION_KEY_CHECK_FAILED", + "SECRETS_ACCESS_CHECK_FAILED", + "WAITING_FOR_OPERATION", + "IMMEDIATE_RETRY", + "POSTPONED_RETRY" + ], + "enumDescriptions": [ + "Default value.", + "Reason unknown. Further details will be in message.", + "The internal route is missing.", + "Revision creation process failed.", + "Timed out waiting for completion.", + "There was a build error.", + "The container image path is incorrect.", + "Insufficient permissions on the container image.", + "Container image is not authorized by policy.", + "Container image policy authorization check failed.", + "Insufficient permissions on encryption key.", + "Permission check on encryption key failed.", + "At least one Access check on secrets failed.", + "Waiting for operation to complete.", + "System will retry immediately.", + "System will retry later; current attempt failed." + ], + "type": "string" + }, + "revisionReason": { + "description": "A reason for the revision condition.", + "enum": [ + "REVISION_REASON_UNDEFINED", + "PENDING", + "RESERVE", + "RETIRED", + "RETIRING", + "RECREATING", + "HEALTH_CHECK_CONTAINER_ERROR", + "CUSTOMIZED_PATH_RESPONSE_PENDING", + "MIN_INSTANCES_NOT_PROVISIONED", + "ACTIVE_REVISION_LIMIT_REACHED", + "NO_DEPLOYMENT", + "HEALTH_CHECK_SKIPPED" + ], + "enumDescriptions": [ + "Default value.", + "Revision in Pending state.", + "Revision is in Reserve state.", + "Revision is Retired.", + "Revision is being retired.", + "Revision is being recreated.", + "There was a health check error.", + "Health check failed due to user error from customized path of the container. System will retry.", + "A revision with min_instance_count \u003e 0 was created and is reserved, but it was not configured to serve traffic, so it's not live. This can also happen momentarily during traffic migration.", + "The maximum allowed number of active revisions has been reached.", + "There was no deployment defined. This value is no longer used, but Services created in older versions of the API might contain this value.", + "A revision's container has no port specified since the revision is of a manually scaled service with 0 instance count" + ], + "type": "string" + }, + "severity": { + "description": "How to interpret failures of this condition, one of Error, Warning, Info", + "enum": [ + "SEVERITY_UNSPECIFIED", + "ERROR", + "WARNING", + "INFO" + ], + "enumDescriptions": [ + "Unspecified severity", + "Error severity.", + "Warning severity.", + "Info severity." + ], + "type": "string" + }, + "state": { + "description": "State of the condition.", + "enum": [ + "STATE_UNSPECIFIED", + "CONDITION_PENDING", + "CONDITION_RECONCILING", + "CONDITION_FAILED", + "CONDITION_SUCCEEDED" + ], + "enumDescriptions": [ + "The default value. This value is used if the state is omitted.", + "Transient state: Reconciliation has not started yet.", + "Transient state: reconciliation is still in progress.", + "Terminal state: Reconciliation did not succeed.", + "Terminal state: Reconciliation completed successfully." + ], + "type": "string" + }, + "type": { + "description": "type is used to communicate the status of the reconciliation process. See also: https://github.com/knative/serving/blob/main/docs/spec/errors.md#error-conditions-and-reporting Types common to all resources include: * \"Ready\": True when the Resource is ready.", + "type": "string" + } + }, + "type": "object" + }, + "GoogleCloudRunV2Container": { + "description": "A single application container. This specifies both the container to run, the command to run in the container and the arguments to supply to it. Note that additional arguments may be supplied by the system to the container at runtime.", + "id": "GoogleCloudRunV2Container", + "properties": { + "args": { + "description": "Arguments to the entrypoint. The docker image's CMD is used if this is not provided. Variable references $(VAR_NAME) are expanded using the container's environment. If a variable cannot be resolved, the reference in the input string will be unchanged. The $(VAR_NAME) syntax can be escaped with a double $$, ie: $$(VAR_NAME). Escaped references will never be expanded, regardless of whether the variable exists or not. More info: https://kubernetes.io/docs/tasks/inject-data-application/define-command-argument-container/#running-a-command-in-a-shell", + "items": { + "type": "string" + }, + "type": "array" + }, + "command": { + "description": "Entrypoint array. Not executed within a shell. The docker image's ENTRYPOINT is used if this is not provided. Variable references $(VAR_NAME) are expanded using the container's environment. If a variable cannot be resolved, the reference in the input string will be unchanged. The $(VAR_NAME) syntax can be escaped with a double $$, ie: $$(VAR_NAME). Escaped references will never be expanded, regardless of whether the variable exists or not. More info: https://kubernetes.io/docs/tasks/inject-data-application/define-command-argument-container/#running-a-command-in-a-shell", + "items": { + "type": "string" + }, + "type": "array" + }, + "env": { + "description": "List of environment variables to set in the container.", + "items": { + "$ref": "GoogleCloudRunV2EnvVar" + }, + "type": "array" + }, + "image": { + "description": "Required. URL of the Container image in Google Container Registry or Docker More info: https://kubernetes.io/docs/concepts/containers/images", + "type": "string" + }, + "name": { + "description": "Name of the container specified as a DNS_LABEL.", + "type": "string" + }, + "ports": { + "description": "List of ports to expose from the container. Only a single port can be specified. The specified ports must be listening on all interfaces (0.0.0.0) within the container to be accessible. If omitted, a port number will be chosen and passed to the container through the PORT environment variable for the container to listen on.", + "items": { + "$ref": "GoogleCloudRunV2ContainerPort" + }, + "type": "array" + }, + "resources": { + "$ref": "GoogleCloudRunV2ResourceRequirements", + "description": "Compute Resource requirements by this container. More info: https://kubernetes.io/docs/concepts/storage/persistent-volumes#resources" + }, + "volumeMounts": { + "description": "Volume to mount into the container's filesystem.", + "items": { + "$ref": "GoogleCloudRunV2VolumeMount" + }, + "type": "array" + } + }, + "type": "object" + }, + "GoogleCloudRunV2ContainerPort": { + "description": "ContainerPort represents a network port in a single container.", + "id": "GoogleCloudRunV2ContainerPort", + "properties": { + "containerPort": { + "description": "Port number the container listens on. This must be a valid TCP port number, 0 \u003c container_port \u003c 65536.", + "format": "int32", + "type": "integer" + }, + "name": { + "description": "If specified, used to specify which protocol to use. Allowed values are \"http1\" and \"h2c\".", + "type": "string" + } + }, + "type": "object" + }, + "GoogleCloudRunV2ContainerStatus": { + "description": "ContainerStatus holds the information of container name and image digest value.", + "id": "GoogleCloudRunV2ContainerStatus", + "properties": { + "imageDigest": { + "description": "ImageDigest holds the resolved digest for the image specified, regardless of whether a tag or digest was originally specified in the Container object.", + "type": "string" + }, + "name": { + "description": "The name of the container, if specified.", + "type": "string" + } + }, + "type": "object" + }, + "GoogleCloudRunV2EnvVar": { + "description": "EnvVar represents an environment variable present in a Container.", + "id": "GoogleCloudRunV2EnvVar", + "properties": { + "name": { + "description": "Required. Name of the environment variable. Must be a C_IDENTIFIER, and mnay not exceed 32768 characters.", "type": "string" }, - "internalReason": { - "description": "A reason for the internal condition.", - "enum": [ - "INTERNAL_REASON_UNDEFINED", - "CONFLICTING_REVISION_NAME", - "REVISION_MISSING", - "CONFIGURATION_MISSING", - "ASSIGNING_TRAFFIC", - "UPDATING_INGRESS_TRAFFIC_ALLOWED", - "REVISION_ORG_POLICY_VIOLATION", - "UPDATING_GCFV2_URI_DATA" - ], - "enumDescriptions": [ - "Default value.", - "The revision name provided conflicts with an existing one.", - "Revision is missing; this is usually a transient reason.", - "Internal configuration is missing; this is usually a transient reason.", - "Assigning traffic; this is a transient reason.", - "Updating ingress traffic settings; this is a transient reason.", - "The revision can't be created because it violates an org policy setting.", - "Updating GCFv2 URI data; this is a transient reason." - ], + "value": { + "description": "Variable references $(VAR_NAME) are expanded using the previous defined environment variables in the container and any route environment variables. If a variable cannot be resolved, the reference in the input string will be unchanged. The $(VAR_NAME) syntax can be escaped with a double $$, ie: $$(VAR_NAME). Escaped references will never be expanded, regardless of whether the variable exists or not. Defaults to \"\", and the maximum length is 32768 bytes.", "type": "string" }, - "lastTransitionTime": { - "description": "Last time the condition transitioned from one status to another.", + "valueSource": { + "$ref": "GoogleCloudRunV2EnvVarSource", + "description": "Source for the environment variable's value." + } + }, + "type": "object" + }, + "GoogleCloudRunV2EnvVarSource": { + "description": "EnvVarSource represents a source for the value of an EnvVar.", + "id": "GoogleCloudRunV2EnvVarSource", + "properties": { + "secretKeyRef": { + "$ref": "GoogleCloudRunV2SecretKeySelector", + "description": "Selects a secret and a specific version from Cloud Secret Manager." + } + }, + "type": "object" + }, + "GoogleCloudRunV2Execution": { + "description": "Execution represents the configuration of a single execution. A execution an immutable resource that references a container image which is run to completion.", + "id": "GoogleCloudRunV2Execution", + "properties": { + "annotations": { + "additionalProperties": { + "type": "string" + }, + "description": "KRM-style annotations for the resource.", + "type": "object" + }, + "completionTime": { + "description": "Output only. Represents time when the execution was completed. It is not guaranteed to be set in happens-before order across separate operations.", "format": "google-datetime", + "readOnly": true, "type": "string" }, - "message": { - "description": "Human readable message indicating details about the current status.", + "conditions": { + "description": "Output only. The Condition of this Execution, containing its readiness status, and detailed error information in case it did not reach the desired state.", + "items": { + "$ref": "GoogleCloudRunV2Condition" + }, + "readOnly": true, + "type": "array" + }, + "createTime": { + "description": "Output only. Represents time when the execution was acknowledged by the execution controller. It is not guaranteed to be set in happens-before order across separate operations.", + "format": "google-datetime", + "readOnly": true, "type": "string" }, - "reason": { - "description": "A common (service-level) reason for this condition.", - "enum": [ - "COMMON_REASON_UNDEFINED", - "UNKNOWN", - "ROUTE_MISSING", - "REVISION_FAILED", - "PROGRESS_DEADLINE_EXCEEDED", - "BUILD_STEP_FAILED", - "CONTAINER_MISSING", - "CONTAINER_PERMISSION_DENIED", - "CONTAINER_IMAGE_UNAUTHORIZED", - "CONTAINER_IMAGE_AUTHORIZATION_CHECK_FAILED", - "ENCRYPTION_KEY_PERMISSION_DENIED", - "ENCRYPTION_KEY_CHECK_FAILED", - "SECRETS_ACCESS_CHECK_FAILED", - "WAITING_FOR_OPERATION", - "IMMEDIATE_RETRY", - "POSTPONED_RETRY" - ], - "enumDescriptions": [ - "Default value.", - "Reason unknown. Further details will be in message.", - "The internal route is missing.", - "Revision creation process failed.", - "Timed out waiting for completion.", - "There was a build error.", - "The container image path is incorrect.", - "Insufficient permissions on the container image.", - "Container image is not authorized by policy.", - "Container image policy authorization check failed.", - "Insufficient permissions on encryption key.", - "Permission check on encryption key failed.", - "At least one Access check on secrets failed.", - "Waiting for operation to complete.", - "System will retry immediately.", - "System will retry later; current attempt failed." - ], + "deleteTime": { + "description": "Output only. For a deleted resource, the deletion time. It is only populated as a response to a Delete request.", + "format": "google-datetime", + "readOnly": true, "type": "string" }, - "revisionReason": { - "description": "A reason for the revision condition.", + "etag": { + "description": "Output only. A system-generated fingerprint for this version of the resource. May be used to detect modification conflict during updates.", + "readOnly": true, + "type": "string" + }, + "expireTime": { + "description": "Output only. For a deleted resource, the time after which it will be permamently deleted. It is only populated as a response to a Delete request.", + "format": "google-datetime", + "readOnly": true, + "type": "string" + }, + "failedCount": { + "description": "Output only. The number of tasks which reached phase Failed.", + "format": "int32", + "readOnly": true, + "type": "integer" + }, + "generation": { + "description": "Output only. A number that monotonically increases every time the user modifies the desired state.", + "format": "int64", + "readOnly": true, + "type": "string" + }, + "job": { + "description": "Output only. The name of the parent Job.", + "readOnly": true, + "type": "string" + }, + "labels": { + "additionalProperties": { + "type": "string" + }, + "description": "KRM-style labels for the resource. User-provided labels are shared with Google's billing system, so they can be used to filter, or break down billing charges by team, component, environment, state, etc. For more information, visit https://cloud.google.com/resource-manager/docs/creating-managing-labels or https://cloud.google.com/run/docs/configuring/labels Cloud Run will populate some labels with 'run.googleapis.com' or 'serving.knative.dev' namespaces. Those labels are read-only, and user changes will not be preserved.", + "type": "object" + }, + "launchStage": { + "description": "Set the launch stage to a preview stage on write to allow use of preview features in that stage. On read, describes whether the resource uses preview features. Launch Stages are defined at [Google Cloud Platform Launch Stages](https://cloud.google.com/terms/launch-stages).", "enum": [ - "REVISION_REASON_UNDEFINED", - "PENDING", - "RESERVE", - "RETIRED", - "RETIRING", - "RECREATING", - "HEALTH_CHECK_CONTAINER_ERROR", - "CUSTOMIZED_PATH_RESPONSE_PENDING", - "MIN_INSTANCES_NOT_PROVISIONED", - "ACTIVE_REVISION_LIMIT_REACHED", - "NO_DEPLOYMENT", - "HEALTH_CHECK_SKIPPED" + "LAUNCH_STAGE_UNSPECIFIED", + "UNIMPLEMENTED", + "PRELAUNCH", + "EARLY_ACCESS", + "ALPHA", + "BETA", + "GA", + "DEPRECATED" ], "enumDescriptions": [ - "Default value.", - "Revision in Pending state.", - "Revision is in Reserve state.", - "Revision is Retired.", - "Revision is being retired.", - "Revision is being recreated.", - "There was a health check error.", - "Health check failed due to user error from customized path of the container. System will retry.", - "A revision with min_instance_count \u003e 0 was created and is reserved, but it was not configured to serve traffic, so it's not live. This can also happen momentarily during traffic migration.", - "The maximum allowed number of active revisions has been reached.", - "There was no deployment defined. This value is no longer used, but Services created in older versions of the API might contain this value.", - "A revision's container has no port specified since the revision is of a manually scaled service with 0 instance count" + "Do not use this default value.", + "The feature is not yet implemented. Users can not use it.", + "Prelaunch features are hidden from users and are only visible internally.", + "Early Access features are limited to a closed group of testers. To use these features, you must sign up in advance and sign a Trusted Tester agreement (which includes confidentiality provisions). These features may be unstable, changed in backward-incompatible ways, and are not guaranteed to be released.", + "Alpha is a limited availability test for releases before they are cleared for widespread use. By Alpha, all significant design issues are resolved and we are in the process of verifying functionality. Alpha customers need to apply for access, agree to applicable terms, and have their projects allowlisted. Alpha releases don't have to be feature complete, no SLAs are provided, and there are no technical support obligations, but they will be far enough along that customers can actually use them in test environments or for limited-use tests -- just like they would in normal production cases.", + "Beta is the point at which we are ready to open a release for any customer to use. There are no SLA or technical support obligations in a Beta release. Products will be complete from a feature perspective, but may have some open outstanding issues. Beta releases are suitable for limited production use cases.", + "GA features are open to all developers and are considered stable and fully qualified for production use.", + "Deprecated features are scheduled to be shut down and removed. For more information, see the \"Deprecation Policy\" section of our [Terms of Service](https://cloud.google.com/terms/) and the [Google Cloud Platform Subject to the Deprecation Policy](https://cloud.google.com/terms/deprecation) documentation." ], "type": "string" }, - "severity": { - "description": "How to interpret failures of this condition, one of Error, Warning, Info", - "enum": [ - "SEVERITY_UNSPECIFIED", - "ERROR", - "WARNING", - "INFO" - ], - "enumDescriptions": [ - "Unspecified severity", - "Error severity.", - "Warning severity.", - "Info severity." - ], + "name": { + "description": "Output only. The unique name of this Execution.", + "readOnly": true, + "type": "string" + }, + "observedGeneration": { + "description": "Output only. The generation of this Execution. See comments in `reconciling` for additional information on reconciliation process in Cloud Run.", + "format": "int64", + "readOnly": true, + "type": "string" + }, + "parallelism": { + "description": "Output only. Specifies the maximum desired number of tasks the execution should run at any given time. Must be \u003c= task_count. The actual number of tasks running in steady state will be less than this number when ((.spec.task_count - .status.successful) \u003c .spec.parallelism), i.e. when the work left to do is less than max parallelism. More info: https://kubernetes.io/docs/concepts/workloads/controllers/jobs-run-to-completion/", + "format": "int32", + "readOnly": true, + "type": "integer" + }, + "reconciling": { + "description": "Output only. Indicates whether the resource's reconciliation is still in progress. See comments in `Job.reconciling` for additional information on reconciliation process in Cloud Run.", + "readOnly": true, + "type": "boolean" + }, + "runningCount": { + "description": "Output only. The number of actively running tasks.", + "format": "int32", + "readOnly": true, + "type": "integer" + }, + "startTime": { + "description": "Output only. Represents time when the execution started to run. It is not guaranteed to be set in happens-before order across separate operations.", + "format": "google-datetime", + "readOnly": true, + "type": "string" + }, + "succeededCount": { + "description": "Output only. The number of tasks which reached phase Succeeded.", + "format": "int32", + "readOnly": true, + "type": "integer" + }, + "taskCount": { + "description": "Output only. Specifies the desired number of tasks the execution should run. Setting to 1 means that parallelism is limited to 1 and the success of that task signals the success of the execution. More info: https://kubernetes.io/docs/concepts/workloads/controllers/jobs-run-to-completion/", + "format": "int32", + "readOnly": true, + "type": "integer" + }, + "template": { + "$ref": "GoogleCloudRunV2TaskTemplate", + "description": "Output only. Describes the task(s) that will be created when executing an execution.", + "readOnly": true + }, + "uid": { + "description": "Output only. Server assigned unique identifier for the Execution. The value is a UUID4 string and guaranteed to remain unchanged until the resource is deleted.", + "readOnly": true, "type": "string" }, - "state": { - "description": "State of the condition.", - "enum": [ - "STATE_UNSPECIFIED", - "CONDITION_PENDING", - "CONDITION_RECONCILING", - "CONDITION_FAILED", - "CONDITION_SUCCEEDED" - ], - "enumDescriptions": [ - "The default value. This value is used if the state is omitted.", - "Transient state: Reconciliation has not started yet.", - "Transient state: reconciliation is still in progress.", - "Terminal state: Reconciliation did not succeed.", - "Terminal state: Reconciliation completed successfully." - ], + "updateTime": { + "description": "Output only. The last-modified time.", + "format": "google-datetime", + "readOnly": true, + "type": "string" + } + }, + "type": "object" + }, + "GoogleCloudRunV2ExecutionReference": { + "description": "Reference to an Execution. Use /Executions.GetExecution with the given name to get full execution including the latest status.", + "id": "GoogleCloudRunV2ExecutionReference", + "properties": { + "createTime": { + "description": "Creation timestamp of the execution.", + "format": "google-datetime", "type": "string" }, - "type": { - "description": "type is used to communicate the status of the reconciliation process. See also: https://github.com/knative/serving/blob/main/docs/spec/errors.md#error-conditions-and-reporting Types common to all resources include: * \"Ready\": True when the Resource is ready.", + "name": { + "description": "Name of the execution.", "type": "string" } }, "type": "object" }, - "GoogleCloudRunV2Container": { - "description": "A single application container. This specifies both the container to run, the command to run in the container and the arguments to supply to it. Note that additional arguments may be supplied by the system to the container at runtime.", - "id": "GoogleCloudRunV2Container", + "GoogleCloudRunV2ExecutionTemplate": { + "description": "ExecutionTemplate describes the data an execution should have when created from a template.", + "id": "GoogleCloudRunV2ExecutionTemplate", "properties": { - "args": { - "description": "Arguments to the entrypoint. The docker image's CMD is used if this is not provided. Variable references $(VAR_NAME) are expanded using the container's environment. If a variable cannot be resolved, the reference in the input string will be unchanged. The $(VAR_NAME) syntax can be escaped with a double $$, ie: $$(VAR_NAME). Escaped references will never be expanded, regardless of whether the variable exists or not. More info: https://kubernetes.io/docs/tasks/inject-data-application/define-command-argument-container/#running-a-command-in-a-shell", - "items": { + "annotations": { + "additionalProperties": { "type": "string" }, - "type": "array" + "description": "KRM-style annotations for the resource.", + "type": "object" }, - "command": { - "description": "Entrypoint array. Not executed within a shell. The docker image's ENTRYPOINT is used if this is not provided. Variable references $(VAR_NAME) are expanded using the container's environment. If a variable cannot be resolved, the reference in the input string will be unchanged. The $(VAR_NAME) syntax can be escaped with a double $$, ie: $$(VAR_NAME). Escaped references will never be expanded, regardless of whether the variable exists or not. More info: https://kubernetes.io/docs/tasks/inject-data-application/define-command-argument-container/#running-a-command-in-a-shell", - "items": { + "labels": { + "additionalProperties": { "type": "string" }, - "type": "array" + "description": "KRM-style labels for the resource.", + "type": "object" }, - "env": { - "description": "List of environment variables to set in the container.", - "items": { - "$ref": "GoogleCloudRunV2EnvVar" + "parallelism": { + "description": "Specifies the maximum desired number of tasks the execution should run at given time. Must be \u003c= task_count. When the job is run, if this field is 0 or unset, the maximum possible value will be used for that execution. The actual number of tasks running in steady state will be less than this number when there are fewer tasks waiting to be completed remaining, i.e. when the work left to do is less than max parallelism.", + "format": "int32", + "type": "integer" + }, + "taskCount": { + "description": "Specifies the desired number of tasks the execution should run. Setting to 1 means that parallelism is limited to 1 and the success of that task signals the success of the execution. More info: https://kubernetes.io/docs/concepts/workloads/controllers/jobs-run-to-completion/", + "format": "int32", + "type": "integer" + }, + "template": { + "$ref": "GoogleCloudRunV2TaskTemplate", + "description": "Required. Describes the task(s) that will be created when executing an execution." + } + }, + "type": "object" + }, + "GoogleCloudRunV2Job": { + "description": "Job represents the configuration of a single job. A job an immutable resource that references a container image which is run to completion.", + "id": "GoogleCloudRunV2Job", + "properties": { + "annotations": { + "additionalProperties": { + "type": "string" }, - "type": "array" + "description": "KRM-style annotations for the resource. Unstructured key value map that may be set by external tools to store and arbitrary metadata. They are not queryable and should be preserved when modifying objects. Cloud Run will populate some annotations using 'run.googleapis.com' or 'serving.knative.dev' namespaces. This field follows Kubernetes annotations' namespacing, limits, and rules. More info: https://kubernetes.io/docs/user-guide/annotations", + "type": "object" }, - "image": { - "description": "Required. URL of the Container image in Google Container Registry or Docker More info: https://kubernetes.io/docs/concepts/containers/images", + "binaryAuthorization": { + "$ref": "GoogleCloudRunV2BinaryAuthorization", + "description": "Settings for the Binary Authorization feature." + }, + "client": { + "description": "Arbitrary identifier for the API client.", "type": "string" }, - "name": { - "description": "Name of the container specified as a DNS_LABEL.", + "clientVersion": { + "description": "Arbitrary version identifier for the API client.", "type": "string" }, - "ports": { - "description": "List of ports to expose from the container. Only a single port can be specified. The specified ports must be listening on all interfaces (0.0.0.0) within the container to be accessible. If omitted, a port number will be chosen and passed to the container through the PORT environment variable for the container to listen on.", + "conditions": { + "description": "Output only. The Conditions of all other associated sub-resources. They contain additional diagnostics information in case the Job does not reach its desired state. See comments in `reconciling` for additional information on reconciliation process in Cloud Run.", "items": { - "$ref": "GoogleCloudRunV2ContainerPort" + "$ref": "GoogleCloudRunV2Condition" }, + "readOnly": true, "type": "array" }, - "resources": { - "$ref": "GoogleCloudRunV2ResourceRequirements", - "description": "Compute Resource requirements by this container. More info: https://kubernetes.io/docs/concepts/storage/persistent-volumes#resources" - }, - "volumeMounts": { - "description": "Volume to mount into the container's filesystem.", + "containerStatuses": { + "description": "Output only. Status information for each of the containers specified.", "items": { - "$ref": "GoogleCloudRunV2VolumeMount" + "$ref": "GoogleCloudRunV2ContainerStatus" }, + "readOnly": true, "type": "array" - } - }, - "type": "object" - }, - "GoogleCloudRunV2ContainerPort": { - "description": "ContainerPort represents a network port in a single container.", - "id": "GoogleCloudRunV2ContainerPort", - "properties": { - "containerPort": { - "description": "Port number the container listens on. This must be a valid TCP port number, 0 \u003c container_port \u003c 65536.", + }, + "createTime": { + "description": "Output only. The creation time.", + "format": "google-datetime", + "readOnly": true, + "type": "string" + }, + "creator": { + "description": "Output only. Email address of the authenticated creator.", + "readOnly": true, + "type": "string" + }, + "deleteTime": { + "description": "Output only. The deletion time.", + "format": "google-datetime", + "readOnly": true, + "type": "string" + }, + "etag": { + "description": "Output only. A system-generated fingerprint for this version of the resource. May be used to detect modification conflict during updates.", + "readOnly": true, + "type": "string" + }, + "executionCount": { + "description": "Output only. Number of executions created for this job.", "format": "int32", + "readOnly": true, "type": "integer" }, + "expireTime": { + "description": "Output only. For a deleted resource, the time after which it will be permamently deleted.", + "format": "google-datetime", + "readOnly": true, + "type": "string" + }, + "generation": { + "description": "Output only. A number that monotonically increases every time the user modifies the desired state.", + "format": "int64", + "readOnly": true, + "type": "string" + }, + "labels": { + "additionalProperties": { + "type": "string" + }, + "description": "KRM-style labels for the resource. User-provided labels are shared with Google's billing system, so they can be used to filter, or break down billing charges by team, component, environment, state, etc. For more information, visit https://cloud.google.com/resource-manager/docs/creating-managing-labels or https://cloud.google.com/run/docs/configuring/labels Cloud Run will populate some labels with 'run.googleapis.com' or 'serving.knative.dev' namespaces. Those labels are read-only, and user changes will not be preserved.", + "type": "object" + }, + "lastModifier": { + "description": "Output only. Email address of the last authenticated modifier.", + "readOnly": true, + "type": "string" + }, + "latestCreatedExecution": { + "$ref": "GoogleCloudRunV2ExecutionReference", + "description": "Output only. Name of the last created execution.", + "readOnly": true + }, + "launchStage": { + "description": "The launch stage as defined by [Google Cloud Platform Launch Stages](https://cloud.google.com/terms/launch-stages). Cloud Run supports `ALPHA`, `BETA`, and `GA`. If no value is specified, GA is assumed.", + "enum": [ + "LAUNCH_STAGE_UNSPECIFIED", + "UNIMPLEMENTED", + "PRELAUNCH", + "EARLY_ACCESS", + "ALPHA", + "BETA", + "GA", + "DEPRECATED" + ], + "enumDescriptions": [ + "Do not use this default value.", + "The feature is not yet implemented. Users can not use it.", + "Prelaunch features are hidden from users and are only visible internally.", + "Early Access features are limited to a closed group of testers. To use these features, you must sign up in advance and sign a Trusted Tester agreement (which includes confidentiality provisions). These features may be unstable, changed in backward-incompatible ways, and are not guaranteed to be released.", + "Alpha is a limited availability test for releases before they are cleared for widespread use. By Alpha, all significant design issues are resolved and we are in the process of verifying functionality. Alpha customers need to apply for access, agree to applicable terms, and have their projects allowlisted. Alpha releases don't have to be feature complete, no SLAs are provided, and there are no technical support obligations, but they will be far enough along that customers can actually use them in test environments or for limited-use tests -- just like they would in normal production cases.", + "Beta is the point at which we are ready to open a release for any customer to use. There are no SLA or technical support obligations in a Beta release. Products will be complete from a feature perspective, but may have some open outstanding issues. Beta releases are suitable for limited production use cases.", + "GA features are open to all developers and are considered stable and fully qualified for production use.", + "Deprecated features are scheduled to be shut down and removed. For more information, see the \"Deprecation Policy\" section of our [Terms of Service](https://cloud.google.com/terms/) and the [Google Cloud Platform Subject to the Deprecation Policy](https://cloud.google.com/terms/deprecation) documentation." + ], + "type": "string" + }, "name": { - "description": "If specified, used to specify which protocol to use. Allowed values are \"http1\" and \"h2c\".", + "description": "The fully qualified name of this Job. Format: projects/{project}/locations/{location}/jobs/{job}", + "type": "string" + }, + "observedGeneration": { + "description": "Output only. The generation of this Job. See comments in `reconciling` for additional information on reconciliation process in Cloud Run.", + "format": "int64", + "readOnly": true, + "type": "string" + }, + "reconciling": { + "description": "Output only. Returns true if the Job is currently being acted upon by the system to bring it into the desired state. When a new Job is created, or an existing one is updated, Cloud Run will asynchronously perform all necessary steps to bring the Job to the desired state. This process is called reconciliation. While reconciliation is in process, `observed_generation` and `latest_succeeded_execution`, will have transient values that might mismatch the intended state: Once reconciliation is over (and this field is false), there are two possible outcomes: reconciliation succeeded and the state matches the Job, or there was an error, and reconciliation failed. This state can be found in `terminal_condition.state`. If reconciliation succeeded, the following fields will match: `observed_generation` and `generation`, `latest_succeeded_execution` and `latest_created_execution`. If reconciliation failed, `observed_generation` and `latest_succeeded_execution` will have the state of the last succeeded execution or empty for newly created Job. Additional information on the failure can be found in `terminal_condition` and `conditions`.", + "readOnly": true, + "type": "boolean" + }, + "template": { + "$ref": "GoogleCloudRunV2ExecutionTemplate", + "description": "Required. The template used to create executions for this Job." + }, + "terminalCondition": { + "$ref": "GoogleCloudRunV2Condition", + "description": "Output only. The Condition of this Job, containing its readiness status, and detailed error information in case it did not reach the desired state.", + "readOnly": true + }, + "uid": { + "description": "Output only. Server assigned unique identifier for the Execution. The value is a UUID4 string and guaranteed to remain unchanged until the resource is deleted.", + "readOnly": true, + "type": "string" + }, + "updateTime": { + "description": "Output only. The last-modified time.", + "format": "google-datetime", + "readOnly": true, "type": "string" } }, "type": "object" }, - "GoogleCloudRunV2EnvVar": { - "description": "EnvVar represents an environment variable present in a Container.", - "id": "GoogleCloudRunV2EnvVar", + "GoogleCloudRunV2ListExecutionsResponse": { + "description": "Response message containing a list of Executions.", + "id": "GoogleCloudRunV2ListExecutionsResponse", "properties": { - "name": { - "description": "Required. Name of the environment variable. Must be a C_IDENTIFIER, and mnay not exceed 32768 characters.", - "type": "string" + "executions": { + "description": "The resulting list of Executions.", + "items": { + "$ref": "GoogleCloudRunV2Execution" + }, + "type": "array" }, - "value": { - "description": "Variable references $(VAR_NAME) are expanded using the previous defined environment variables in the container and any route environment variables. If a variable cannot be resolved, the reference in the input string will be unchanged. The $(VAR_NAME) syntax can be escaped with a double $$, ie: $$(VAR_NAME). Escaped references will never be expanded, regardless of whether the variable exists or not. Defaults to \"\", and the maximum length is 32768 bytes.", + "nextPageToken": { + "description": "A token indicating there are more items than page_size. Use it in the next ListExecutions request to continue.", "type": "string" - }, - "valueSource": { - "$ref": "GoogleCloudRunV2EnvVarSource", - "description": "Source for the environment variable's value." } }, "type": "object" - }, - "GoogleCloudRunV2EnvVarSource": { - "description": "EnvVarSource represents a source for the value of an EnvVar.", - "id": "GoogleCloudRunV2EnvVarSource", + }, + "GoogleCloudRunV2ListJobsResponse": { + "description": "Response message containing a list of Jobs.", + "id": "GoogleCloudRunV2ListJobsResponse", "properties": { - "secretKeyRef": { - "$ref": "GoogleCloudRunV2SecretKeySelector", - "description": "Selects a secret and a specific version from Cloud Secret Manager." + "jobs": { + "description": "The resulting list of Jobs.", + "items": { + "$ref": "GoogleCloudRunV2Job" + }, + "type": "array" + }, + "nextPageToken": { + "description": "A token indicating there are more items than page_size. Use it in the next ListJobs request to continue.", + "type": "string" } }, "type": "object" @@ -948,6 +1855,24 @@ }, "type": "object" }, + "GoogleCloudRunV2ListTasksResponse": { + "description": "Response message containing a list of Tasks.", + "id": "GoogleCloudRunV2ListTasksResponse", + "properties": { + "nextPageToken": { + "description": "A token indicating there are more items than page_size. Use it in the next ListTasks request to continue.", + "type": "string" + }, + "tasks": { + "description": "The resulting list of Tasks.", + "items": { + "$ref": "GoogleCloudRunV2Task" + }, + "type": "array" + } + }, + "type": "object" + }, "GoogleCloudRunV2ResourceRequirements": { "description": "ResourceRequirements describes the compute resource requirements.", "id": "GoogleCloudRunV2ResourceRequirements", @@ -1243,6 +2168,21 @@ }, "type": "object" }, + "GoogleCloudRunV2RunJobRequest": { + "description": "Request message to create a new Execution of a Job.", + "id": "GoogleCloudRunV2RunJobRequest", + "properties": { + "etag": { + "description": "A system-generated fingerprint for this version of the resource. May be used to detect modification conflict during updates.", + "type": "string" + }, + "validateOnly": { + "description": "Indicates that the request should be validated without actually deleting any resources.", + "type": "boolean" + } + }, + "type": "object" + }, "GoogleCloudRunV2SecretKeySelector": { "description": "SecretEnvVarSource represents a source for the value of an EnvVar.", "id": "GoogleCloudRunV2SecretKeySelector", @@ -1470,6 +2410,281 @@ }, "type": "object" }, + "GoogleCloudRunV2Task": { + "description": "Task represents a single run of a container to completion.", + "id": "GoogleCloudRunV2Task", + "properties": { + "annotations": { + "additionalProperties": { + "type": "string" + }, + "description": "KRM-style annotations for the resource.", + "type": "object" + }, + "completionTime": { + "description": "Output only. Represents time when the Task was completed. It is not guaranteed to be set in happens-before order across separate operations.", + "format": "google-datetime", + "readOnly": true, + "type": "string" + }, + "conditions": { + "description": "Output only. The Condition of this Task, containing its readiness status, and detailed error information in case it did not reach the desired state.", + "items": { + "$ref": "GoogleCloudRunV2Condition" + }, + "readOnly": true, + "type": "array" + }, + "containers": { + "description": "Holds the single container that defines the unit of execution for this task.", + "items": { + "$ref": "GoogleCloudRunV2Container" + }, + "type": "array" + }, + "createTime": { + "description": "Output only. Represents time when the task was created by the job controller. It is not guaranteed to be set in happens-before order across separate operations.", + "format": "google-datetime", + "readOnly": true, + "type": "string" + }, + "deleteTime": { + "description": "Output only. For a deleted resource, the deletion time. It is only populated as a response to a Delete request.", + "format": "google-datetime", + "readOnly": true, + "type": "string" + }, + "encryptionKey": { + "description": "Output only. A reference to a customer managed encryption key (CMEK) to use to encrypt this container image. For more information, go to https://cloud.google.com/run/docs/securing/using-cmek", + "readOnly": true, + "type": "string" + }, + "etag": { + "description": "Output only. A system-generated fingerprint for this version of the resource. May be used to detect modification conflict during updates.", + "readOnly": true, + "type": "string" + }, + "execution": { + "description": "Output only. The name of the parent Execution.", + "readOnly": true, + "type": "string" + }, + "executionEnvironment": { + "description": "The execution environment being used to host this Task.", + "enum": [ + "EXECUTION_ENVIRONMENT_UNSPECIFIED", + "EXECUTION_ENVIRONMENT_GEN1", + "EXECUTION_ENVIRONMENT_GEN2" + ], + "enumDescriptions": [ + "Unspecified", + "Uses the First Generation environment.", + "Uses Second Generation environment." + ], + "type": "string" + }, + "expireTime": { + "description": "Output only. For a deleted resource, the time after which it will be permamently deleted. It is only populated as a response to a Delete request.", + "format": "google-datetime", + "readOnly": true, + "type": "string" + }, + "generation": { + "description": "Output only. A number that monotonically increases every time the user modifies the desired state.", + "format": "int64", + "readOnly": true, + "type": "string" + }, + "index": { + "description": "Output only. Index of the Task, unique per execution, and beginning at 0.", + "format": "int32", + "readOnly": true, + "type": "integer" + }, + "job": { + "description": "Output only. The name of the parent Job.", + "readOnly": true, + "type": "string" + }, + "labels": { + "additionalProperties": { + "type": "string" + }, + "description": "KRM-style labels for the resource. User-provided labels are shared with Google's billing system, so they can be used to filter, or break down billing charges by team, component, environment, state, etc. For more information, visit https://cloud.google.com/resource-manager/docs/creating-managing-labels or https://cloud.google.com/run/docs/configuring/labels Cloud Run will populate some labels with 'run.googleapis.com' or 'serving.knative.dev' namespaces. Those labels are read-only, and user changes will not be preserved.", + "type": "object" + }, + "lastAttemptResult": { + "$ref": "GoogleCloudRunV2TaskAttemptResult", + "description": "Output only. Result of the last attempt of this Task.", + "readOnly": true + }, + "launchStage": { + "description": "Set the launch stage to a preview stage on write to allow use of preview features in that stage. On read, describes whether the resource uses preview features. Launch Stages are defined at [Google Cloud Platform Launch Stages](https://cloud.google.com/terms/launch-stages).", + "enum": [ + "LAUNCH_STAGE_UNSPECIFIED", + "UNIMPLEMENTED", + "PRELAUNCH", + "EARLY_ACCESS", + "ALPHA", + "BETA", + "GA", + "DEPRECATED" + ], + "enumDescriptions": [ + "Do not use this default value.", + "The feature is not yet implemented. Users can not use it.", + "Prelaunch features are hidden from users and are only visible internally.", + "Early Access features are limited to a closed group of testers. To use these features, you must sign up in advance and sign a Trusted Tester agreement (which includes confidentiality provisions). These features may be unstable, changed in backward-incompatible ways, and are not guaranteed to be released.", + "Alpha is a limited availability test for releases before they are cleared for widespread use. By Alpha, all significant design issues are resolved and we are in the process of verifying functionality. Alpha customers need to apply for access, agree to applicable terms, and have their projects allowlisted. Alpha releases don't have to be feature complete, no SLAs are provided, and there are no technical support obligations, but they will be far enough along that customers can actually use them in test environments or for limited-use tests -- just like they would in normal production cases.", + "Beta is the point at which we are ready to open a release for any customer to use. There are no SLA or technical support obligations in a Beta release. Products will be complete from a feature perspective, but may have some open outstanding issues. Beta releases are suitable for limited production use cases.", + "GA features are open to all developers and are considered stable and fully qualified for production use.", + "Deprecated features are scheduled to be shut down and removed. For more information, see the \"Deprecation Policy\" section of our [Terms of Service](https://cloud.google.com/terms/) and the [Google Cloud Platform Subject to the Deprecation Policy](https://cloud.google.com/terms/deprecation) documentation." + ], + "type": "string" + }, + "maxRetries": { + "description": "Number of retries allowed per Task, before marking this Task failed.", + "format": "int32", + "type": "integer" + }, + "name": { + "description": "Output only. The unique name of this Task.", + "readOnly": true, + "type": "string" + }, + "observedGeneration": { + "description": "Output only. The generation of this Task. See comments in `Job.reconciling` for additional information on reconciliation process in Cloud Run.", + "format": "int64", + "readOnly": true, + "type": "string" + }, + "reconciling": { + "description": "Output only. Indicates whether the resource's reconciliation is still in progress. See comments in `Job.reconciling` for additional information on reconciliation process in Cloud Run.", + "readOnly": true, + "type": "boolean" + }, + "retried": { + "description": "Output only. The number of times this Task was retried. Tasks are retried when they fail up to the maxRetries limit.", + "format": "int32", + "readOnly": true, + "type": "integer" + }, + "serviceAccount": { + "description": "Email address of the IAM service account associated with the Task of a Job. The service account represents the identity of the running task, and determines what permissions the task has. If not provided, the task will use the project's default service account.", + "type": "string" + }, + "startTime": { + "description": "Output only. Represents time when the task started to run. It is not guaranteed to be set in happens-before order across separate operations.", + "format": "google-datetime", + "readOnly": true, + "type": "string" + }, + "timeout": { + "description": "Max allowed time duration the Task may be active before the system will actively try to mark it failed and kill associated containers. This applies per attempt of a task, meaning each retry can run for the full timeout.", + "format": "google-duration", + "type": "string" + }, + "uid": { + "description": "Output only. Server assigned unique identifier for the Task. The value is a UUID4 string and guaranteed to remain unchanged until the resource is deleted.", + "readOnly": true, + "type": "string" + }, + "updateTime": { + "description": "Output only. The last-modified time.", + "format": "google-datetime", + "readOnly": true, + "type": "string" + }, + "volumes": { + "description": "A list of Volumes to make available to containers.", + "items": { + "$ref": "GoogleCloudRunV2Volume" + }, + "type": "array" + }, + "vpcAccess": { + "$ref": "GoogleCloudRunV2VpcAccess", + "description": "Output only. VPC Access configuration to use for this Task. For more information, visit https://cloud.google.com/run/docs/configuring/connecting-vpc.", + "readOnly": true + } + }, + "type": "object" + }, + "GoogleCloudRunV2TaskAttemptResult": { + "description": "Result of a task attempt.", + "id": "GoogleCloudRunV2TaskAttemptResult", + "properties": { + "exitCode": { + "description": "Output only. The exit code of this attempt. This may be unset if the container was unable to exit cleanly with a code due to some other failure. See status field for possible failure details.", + "format": "int32", + "readOnly": true, + "type": "integer" + }, + "status": { + "$ref": "GoogleRpcStatus", + "description": "Output only. The status of this attempt. If the status code is OK, then the attempt succeeded.", + "readOnly": true + } + }, + "type": "object" + }, + "GoogleCloudRunV2TaskTemplate": { + "description": "TaskTemplate describes the data a task should have when created from a template.", + "id": "GoogleCloudRunV2TaskTemplate", + "properties": { + "containers": { + "description": "Holds the single container that defines the unit of execution for this task.", + "items": { + "$ref": "GoogleCloudRunV2Container" + }, + "type": "array" + }, + "encryptionKey": { + "description": "A reference to a customer managed encryption key (CMEK) to use to encrypt this container image. For more information, go to https://cloud.google.com/run/docs/securing/using-cmek", + "type": "string" + }, + "executionEnvironment": { + "description": "The execution environment being used to host this Task.", + "enum": [ + "EXECUTION_ENVIRONMENT_UNSPECIFIED", + "EXECUTION_ENVIRONMENT_GEN1", + "EXECUTION_ENVIRONMENT_GEN2" + ], + "enumDescriptions": [ + "Unspecified", + "Uses the First Generation environment.", + "Uses Second Generation environment." + ], + "type": "string" + }, + "maxRetries": { + "description": "Number of retries allowed per Task, before marking this Task failed.", + "format": "int32", + "type": "integer" + }, + "serviceAccount": { + "description": "Email address of the IAM service account associated with the Task of a Job. The service account represents the identity of the running task, and determines what permissions the task has. If not provided, the task will use the project's default service account.", + "type": "string" + }, + "timeout": { + "description": "Max allowed time duration the Task may be active before the system will actively try to mark it failed and kill associated containers. This applies per attempt of a task, meaning each retry can run for the full timeout.", + "format": "google-duration", + "type": "string" + }, + "volumes": { + "description": "A list of Volumes to make available to containers.", + "items": { + "$ref": "GoogleCloudRunV2Volume" + }, + "type": "array" + }, + "vpcAccess": { + "$ref": "GoogleCloudRunV2VpcAccess", + "description": "VPC Access configuration to use for this Task. For more information, visit https://cloud.google.com/run/docs/configuring/connecting-vpc." + } + }, + "type": "object" + }, "GoogleCloudRunV2TrafficTarget": { "description": "Holds a single traffic routing entry for the Service. Allocations can be done to a specific Revision name, or pointing to the latest Ready Revision.", "id": "GoogleCloudRunV2TrafficTarget", diff --git a/run/v2/run-gen.go b/run/v2/run-gen.go index b7e98ab40c8..80a1471a0bb 100644 --- a/run/v2/run-gen.go +++ b/run/v2/run-gen.go @@ -151,6 +151,7 @@ type ProjectsService struct { func NewProjectsLocationsService(s *Service) *ProjectsLocationsService { rs := &ProjectsLocationsService{s: s} + rs.Jobs = NewProjectsLocationsJobsService(s) rs.Operations = NewProjectsLocationsOperationsService(s) rs.Services = NewProjectsLocationsServicesService(s) return rs @@ -159,11 +160,46 @@ func NewProjectsLocationsService(s *Service) *ProjectsLocationsService { type ProjectsLocationsService struct { s *Service + Jobs *ProjectsLocationsJobsService + Operations *ProjectsLocationsOperationsService Services *ProjectsLocationsServicesService } +func NewProjectsLocationsJobsService(s *Service) *ProjectsLocationsJobsService { + rs := &ProjectsLocationsJobsService{s: s} + rs.Executions = NewProjectsLocationsJobsExecutionsService(s) + return rs +} + +type ProjectsLocationsJobsService struct { + s *Service + + Executions *ProjectsLocationsJobsExecutionsService +} + +func NewProjectsLocationsJobsExecutionsService(s *Service) *ProjectsLocationsJobsExecutionsService { + rs := &ProjectsLocationsJobsExecutionsService{s: s} + rs.Tasks = NewProjectsLocationsJobsExecutionsTasksService(s) + return rs +} + +type ProjectsLocationsJobsExecutionsService struct { + s *Service + + Tasks *ProjectsLocationsJobsExecutionsTasksService +} + +func NewProjectsLocationsJobsExecutionsTasksService(s *Service) *ProjectsLocationsJobsExecutionsTasksService { + rs := &ProjectsLocationsJobsExecutionsTasksService{s: s} + return rs +} + +type ProjectsLocationsJobsExecutionsTasksService struct { + s *Service +} + func NewProjectsLocationsOperationsService(s *Service) *ProjectsLocationsOperationsService { rs := &ProjectsLocationsOperationsService{s: s} return rs @@ -542,6 +578,40 @@ func (s *GoogleCloudRunV2ContainerPort) MarshalJSON() ([]byte, error) { return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } +// GoogleCloudRunV2ContainerStatus: ContainerStatus holds the +// information of container name and image digest value. +type GoogleCloudRunV2ContainerStatus struct { + // ImageDigest: ImageDigest holds the resolved digest for the image + // specified, regardless of whether a tag or digest was originally + // specified in the Container object. + ImageDigest string `json:"imageDigest,omitempty"` + + // Name: The name of the container, if specified. + Name string `json:"name,omitempty"` + + // ForceSendFields is a list of field names (e.g. "ImageDigest") 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. "ImageDigest") 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 *GoogleCloudRunV2ContainerStatus) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudRunV2ContainerStatus + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + // GoogleCloudRunV2EnvVar: EnvVar represents an environment variable // present in a Container. type GoogleCloudRunV2EnvVar struct { @@ -614,177 +684,53 @@ func (s *GoogleCloudRunV2EnvVarSource) MarshalJSON() ([]byte, error) { return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } -// GoogleCloudRunV2ListRevisionsResponse: Response message containing a -// list of Revisions. -type GoogleCloudRunV2ListRevisionsResponse struct { - // NextPageToken: A token indicating there are more items than - // page_size. Use it in the next ListRevisions request to continue. - NextPageToken string `json:"nextPageToken,omitempty"` - - // Revisions: The resulting list of Revisions. - Revisions []*GoogleCloudRunV2Revision `json:"revisions,omitempty"` - - // ServerResponse contains the HTTP response code and headers from the - // server. - googleapi.ServerResponse `json:"-"` - - // ForceSendFields is a list of field names (e.g. "NextPageToken") to - // unconditionally include in API requests. By default, fields with - // empty or default values are omitted from API requests. However, any - // non-pointer, non-interface field appearing in ForceSendFields will be - // sent to the server regardless of whether the field is empty or not. - // This may be used to include empty fields in Patch requests. - ForceSendFields []string `json:"-"` - - // NullFields is a list of field names (e.g. "NextPageToken") to include - // in API requests with the JSON null value. By default, fields with - // empty values are omitted from API requests. However, any field with - // an empty value appearing in NullFields will be sent to the server as - // null. It is an error if a field in this list has a non-empty value. - // This may be used to include null fields in Patch requests. - NullFields []string `json:"-"` -} - -func (s *GoogleCloudRunV2ListRevisionsResponse) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudRunV2ListRevisionsResponse - raw := NoMethod(*s) - return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) -} - -// GoogleCloudRunV2ListServicesResponse: Response message containing a -// list of Services. -type GoogleCloudRunV2ListServicesResponse struct { - // NextPageToken: A token indicating there are more items than - // page_size. Use it in the next ListServices request to continue. - NextPageToken string `json:"nextPageToken,omitempty"` - - // Services: The resulting list of Services. - Services []*GoogleCloudRunV2Service `json:"services,omitempty"` - - // ServerResponse contains the HTTP response code and headers from the - // server. - googleapi.ServerResponse `json:"-"` - - // ForceSendFields is a list of field names (e.g. "NextPageToken") to - // unconditionally include in API requests. By default, fields with - // empty or default values are omitted from API requests. However, any - // non-pointer, non-interface field appearing in ForceSendFields will be - // sent to the server regardless of whether the field is empty or not. - // This may be used to include empty fields in Patch requests. - ForceSendFields []string `json:"-"` - - // NullFields is a list of field names (e.g. "NextPageToken") to include - // in API requests with the JSON null value. By default, fields with - // empty values are omitted from API requests. However, any field with - // an empty value appearing in NullFields will be sent to the server as - // null. It is an error if a field in this list has a non-empty value. - // This may be used to include null fields in Patch requests. - NullFields []string `json:"-"` -} - -func (s *GoogleCloudRunV2ListServicesResponse) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudRunV2ListServicesResponse - raw := NoMethod(*s) - return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) -} - -// GoogleCloudRunV2ResourceRequirements: ResourceRequirements describes -// the compute resource requirements. -type GoogleCloudRunV2ResourceRequirements struct { - // CpuIdle: Determines whether CPU should be throttled or not outside of - // requests. - CpuIdle bool `json:"cpuIdle,omitempty"` - - // Limits: Only memory and CPU are supported. Note: The only supported - // values for CPU are '1', '2', and '4'. Setting 4 CPU requires at least - // 2Gi of memory. The values of the map is string form of the 'quantity' - // k8s type: - // https://github.com/kubernetes/kubernetes/blob/master/staging/src/k8s.io/apimachinery/pkg/api/resource/quantity.go - Limits map[string]string `json:"limits,omitempty"` - - // ForceSendFields is a list of field names (e.g. "CpuIdle") 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. "CpuIdle") 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 *GoogleCloudRunV2ResourceRequirements) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudRunV2ResourceRequirements - raw := NoMethod(*s) - return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) -} - -// GoogleCloudRunV2Revision: A Revision is an immutable snapshot of code -// and configuration. A Revision references a container image. Revisions -// are only created by updates to its parent Service. -type GoogleCloudRunV2Revision struct { +// GoogleCloudRunV2Execution: Execution represents the configuration of +// a single execution. A execution an immutable resource that references +// a container image which is run to completion. +type GoogleCloudRunV2Execution struct { // Annotations: KRM-style annotations for the resource. Annotations map[string]string `json:"annotations,omitempty"` - // Conditions: Output only. The Condition of this Revision, containing + // CompletionTime: Output only. Represents time when the execution was + // completed. It is not guaranteed to be set in happens-before order + // across separate operations. + CompletionTime string `json:"completionTime,omitempty"` + + // Conditions: Output only. The Condition of this Execution, containing // its readiness status, and detailed error information in case it did - // not reach a serving state. + // not reach the desired state. Conditions []*GoogleCloudRunV2Condition `json:"conditions,omitempty"` - // Confidential: Indicates whether Confidential Cloud Run is enabled in - // this Revision. - Confidential bool `json:"confidential,omitempty"` - - // ContainerConcurrency: Sets the maximum number of requests that each - // serving instance can receive. - ContainerConcurrency int64 `json:"containerConcurrency,omitempty"` - - // Containers: Holds the single container that defines the unit of - // execution for this Revision. - Containers []*GoogleCloudRunV2Container `json:"containers,omitempty"` - - // CreateTime: Output only. The creation time. + // CreateTime: Output only. Represents time when the execution was + // acknowledged by the execution controller. It is not guaranteed to be + // set in happens-before order across separate operations. CreateTime string `json:"createTime,omitempty"` // DeleteTime: Output only. For a deleted resource, the deletion time. // It is only populated as a response to a Delete request. DeleteTime string `json:"deleteTime,omitempty"` - // EncryptionKey: A reference to a customer managed encryption key - // (CMEK) to use to encrypt this container image. For more information, - // go to https://cloud.google.com/run/docs/securing/using-cmek - EncryptionKey string `json:"encryptionKey,omitempty"` - // Etag: Output only. A system-generated fingerprint for this version of // the resource. May be used to detect modification conflict during // updates. Etag string `json:"etag,omitempty"` - // ExecutionEnvironment: The execution environment being used to host - // this Revision. - // - // Possible values: - // "EXECUTION_ENVIRONMENT_UNSPECIFIED" - Unspecified - // "EXECUTION_ENVIRONMENT_GEN1" - Uses the First Generation - // environment. - // "EXECUTION_ENVIRONMENT_GEN2" - Uses Second Generation environment. - ExecutionEnvironment string `json:"executionEnvironment,omitempty"` - // ExpireTime: Output only. For a deleted resource, the time after which // it will be permamently deleted. It is only populated as a response to // a Delete request. ExpireTime string `json:"expireTime,omitempty"` + // FailedCount: Output only. The number of tasks which reached phase + // Failed. + FailedCount int64 `json:"failedCount,omitempty"` + // Generation: Output only. A number that monotonically increases every // time the user modifies the desired state. Generation int64 `json:"generation,omitempty,string"` + // Job: Output only. The name of the parent Job. + Job string `json:"job,omitempty"` + // Labels: KRM-style labels for the resource. User-provided labels are // shared with Google's billing system, so they can be used to filter, // or break down billing charges by team, component, environment, state, @@ -837,55 +783,60 @@ type GoogleCloudRunV2Revision struct { // Policy](https://cloud.google.com/terms/deprecation) documentation. LaunchStage string `json:"launchStage,omitempty"` - // LogUri: Output only. The Google Console URI to obtain logs for the - // Revision. - LogUri string `json:"logUri,omitempty"` - - // Name: Output only. The unique name of this Revision. + // Name: Output only. The unique name of this Execution. Name string `json:"name,omitempty"` - // ObservedGeneration: Output only. The generation of this Revision - // currently serving traffic. See comments in `reconciling` for - // additional information on reconciliation process in Cloud Run. + // ObservedGeneration: Output only. The generation of this Execution. + // See comments in `reconciling` for additional information on + // reconciliation process in Cloud Run. ObservedGeneration int64 `json:"observedGeneration,omitempty,string"` + // Parallelism: Output only. Specifies the maximum desired number of + // tasks the execution should run at any given time. Must be <= + // task_count. The actual number of tasks running in steady state will + // be less than this number when ((.spec.task_count - + // .status.successful) < .spec.parallelism), i.e. when the work left to + // do is less than max parallelism. More info: + // https://kubernetes.io/docs/concepts/workloads/controllers/jobs-run-to-completion/ + Parallelism int64 `json:"parallelism,omitempty"` + // Reconciling: Output only. Indicates whether the resource's // reconciliation is still in progress. See comments in - // `Service.reconciling` for additional information on reconciliation + // `Job.reconciling` for additional information on reconciliation // process in Cloud Run. Reconciling bool `json:"reconciling,omitempty"` - // Scaling: Scaling settings for this revision. - Scaling *GoogleCloudRunV2RevisionScaling `json:"scaling,omitempty"` + // RunningCount: Output only. The number of actively running tasks. + RunningCount int64 `json:"runningCount,omitempty"` - // Service: Output only. The name of the parent service. - Service string `json:"service,omitempty"` + // StartTime: Output only. Represents time when the execution started to + // run. It is not guaranteed to be set in happens-before order across + // separate operations. + StartTime string `json:"startTime,omitempty"` - // ServiceAccount: Email address of the IAM service account associated - // with the revision of the service. The service account represents the - // identity of the running revision, and determines what permissions the - // revision has. - ServiceAccount string `json:"serviceAccount,omitempty"` + // SucceededCount: Output only. The number of tasks which reached phase + // Succeeded. + SucceededCount int64 `json:"succeededCount,omitempty"` - // Timeout: Max allowed time for an instance to respond to a request. - Timeout string `json:"timeout,omitempty"` + // TaskCount: Output only. Specifies the desired number of tasks the + // execution should run. Setting to 1 means that parallelism is limited + // to 1 and the success of that task signals the success of the + // execution. More info: + // https://kubernetes.io/docs/concepts/workloads/controllers/jobs-run-to-completion/ + TaskCount int64 `json:"taskCount,omitempty"` - // Uid: Output only. Server assigned unique identifier for the Revision. - // The value is a UUID4 string and guaranteed to remain unchanged until - // the resource is deleted. + // Template: Output only. Describes the task(s) that will be created + // when executing an execution. + Template *GoogleCloudRunV2TaskTemplate `json:"template,omitempty"` + + // Uid: Output only. Server assigned unique identifier for the + // Execution. The value is a UUID4 string and guaranteed to remain + // unchanged until the resource is deleted. Uid string `json:"uid,omitempty"` // UpdateTime: Output only. The last-modified time. UpdateTime string `json:"updateTime,omitempty"` - // Volumes: A list of Volumes to make available to containers. - Volumes []*GoogleCloudRunV2Volume `json:"volumes,omitempty"` - - // VpcAccess: VPC Access configuration for this Revision. For more - // information, visit - // https://cloud.google.com/run/docs/configuring/connecting-vpc. - VpcAccess *GoogleCloudRunV2VpcAccess `json:"vpcAccess,omitempty"` - // ServerResponse contains the HTTP response code and headers from the // server. googleapi.ServerResponse `json:"-"` @@ -907,24 +858,23 @@ type GoogleCloudRunV2Revision struct { NullFields []string `json:"-"` } -func (s *GoogleCloudRunV2Revision) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudRunV2Revision +func (s *GoogleCloudRunV2Execution) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudRunV2Execution raw := NoMethod(*s) return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } -// GoogleCloudRunV2RevisionScaling: Settings for revision-level scaling -// settings. -type GoogleCloudRunV2RevisionScaling struct { - // MaxInstanceCount: Maximum number of serving instances that this - // resource should have. - MaxInstanceCount int64 `json:"maxInstanceCount,omitempty"` +// GoogleCloudRunV2ExecutionReference: Reference to an Execution. Use +// /Executions.GetExecution with the given name to get full execution +// including the latest status. +type GoogleCloudRunV2ExecutionReference struct { + // CreateTime: Creation timestamp of the execution. + CreateTime string `json:"createTime,omitempty"` - // MinInstanceCount: Minimum number of serving instances that this - // resource should have. - MinInstanceCount int64 `json:"minInstanceCount,omitempty"` + // Name: Name of the execution. + Name string `json:"name,omitempty"` - // ForceSendFields is a list of field names (e.g. "MaxInstanceCount") to + // ForceSendFields is a list of field names (e.g. "CreateTime") to // unconditionally include in API requests. By default, fields with // empty or default values are omitted from API requests. However, any // non-pointer, non-interface field appearing in ForceSendFields will be @@ -932,81 +882,48 @@ type GoogleCloudRunV2RevisionScaling struct { // This may be used to include empty fields in Patch requests. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "MaxInstanceCount") to - // include in API requests with the JSON null value. By default, fields - // with empty values are omitted from API requests. However, any field - // with an empty value appearing in NullFields will be sent to the - // server as null. It is an error if a field in this list has a - // non-empty value. This may be used to include null fields in Patch - // requests. + // NullFields is a list of field names (e.g. "CreateTime") to include in + // API requests with the JSON null value. By default, fields with empty + // values are omitted from API requests. However, any field with an + // empty value appearing in NullFields will be sent to the server as + // null. It is an error if a field in this list has a non-empty value. + // This may be used to include null fields in Patch requests. NullFields []string `json:"-"` } -func (s *GoogleCloudRunV2RevisionScaling) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudRunV2RevisionScaling +func (s *GoogleCloudRunV2ExecutionReference) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudRunV2ExecutionReference raw := NoMethod(*s) return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } -// GoogleCloudRunV2RevisionTemplate: RevisionTemplate describes the data -// a revision should have when created from a template. -type GoogleCloudRunV2RevisionTemplate struct { +// GoogleCloudRunV2ExecutionTemplate: ExecutionTemplate describes the +// data an execution should have when created from a template. +type GoogleCloudRunV2ExecutionTemplate struct { // Annotations: KRM-style annotations for the resource. Annotations map[string]string `json:"annotations,omitempty"` - // Confidential: Enables Confidential Cloud Run in Revisions created - // using this template. - Confidential bool `json:"confidential,omitempty"` - - // ContainerConcurrency: Sets the maximum number of requests that each - // serving instance can receive. - ContainerConcurrency int64 `json:"containerConcurrency,omitempty"` - - // Containers: Holds the single container that defines the unit of - // execution for this Revision. - Containers []*GoogleCloudRunV2Container `json:"containers,omitempty"` - - // EncryptionKey: A reference to a customer managed encryption key - // (CMEK) to use to encrypt this container image. For more information, - // go to https://cloud.google.com/run/docs/securing/using-cmek - EncryptionKey string `json:"encryptionKey,omitempty"` - - // ExecutionEnvironment: The sandbox environment to host this Revision. - // - // Possible values: - // "EXECUTION_ENVIRONMENT_UNSPECIFIED" - Unspecified - // "EXECUTION_ENVIRONMENT_GEN1" - Uses the First Generation - // environment. - // "EXECUTION_ENVIRONMENT_GEN2" - Uses Second Generation environment. - ExecutionEnvironment string `json:"executionEnvironment,omitempty"` - // Labels: KRM-style labels for the resource. Labels map[string]string `json:"labels,omitempty"` - // Revision: The unique name for the revision. If this field is omitted, - // it will be automatically generated based on the Service name. - Revision string `json:"revision,omitempty"` - - // Scaling: Scaling settings for this Revision. - Scaling *GoogleCloudRunV2RevisionScaling `json:"scaling,omitempty"` - - // ServiceAccount: Email address of the IAM service account associated - // with the revision of the service. The service account represents the - // identity of the running revision, and determines what permissions the - // revision has. If not provided, the revision will use the project's - // default service account. - ServiceAccount string `json:"serviceAccount,omitempty"` - - // Timeout: Max allowed time for an instance to respond to a request. - Timeout string `json:"timeout,omitempty"` - - // Volumes: A list of Volumes to make available to containers. - Volumes []*GoogleCloudRunV2Volume `json:"volumes,omitempty"` - - // VpcAccess: VPC Access configuration to use for this Revision. For - // more information, visit - // https://cloud.google.com/run/docs/configuring/connecting-vpc. - VpcAccess *GoogleCloudRunV2VpcAccess `json:"vpcAccess,omitempty"` + // Parallelism: Specifies the maximum desired number of tasks the + // execution should run at given time. Must be <= task_count. When the + // job is run, if this field is 0 or unset, the maximum possible value + // will be used for that execution. The actual number of tasks running + // in steady state will be less than this number when there are fewer + // tasks waiting to be completed remaining, i.e. when the work left to + // do is less than max parallelism. + Parallelism int64 `json:"parallelism,omitempty"` + + // TaskCount: Specifies the desired number of tasks the execution should + // run. Setting to 1 means that parallelism is limited to 1 and the + // success of that task signals the success of the execution. More info: + // https://kubernetes.io/docs/concepts/workloads/controllers/jobs-run-to-completion/ + TaskCount int64 `json:"taskCount,omitempty"` + + // Template: Required. Describes the task(s) that will be created when + // executing an execution. + Template *GoogleCloudRunV2TaskTemplate `json:"template,omitempty"` // ForceSendFields is a list of field names (e.g. "Annotations") to // unconditionally include in API requests. By default, fields with @@ -1025,118 +942,23 @@ type GoogleCloudRunV2RevisionTemplate struct { NullFields []string `json:"-"` } -func (s *GoogleCloudRunV2RevisionTemplate) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudRunV2RevisionTemplate - raw := NoMethod(*s) - return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) -} - -// GoogleCloudRunV2SecretKeySelector: SecretEnvVarSource represents a -// source for the value of an EnvVar. -type GoogleCloudRunV2SecretKeySelector struct { - // Secret: Required. The name of the secret in Cloud Secret Manager. - // Format: {secret_name} if the secret is in the same project. - // projects/{project}/secrets/{secret_name} if the secret is in a - // different project. - Secret string `json:"secret,omitempty"` - - // Version: The Cloud Secret Manager secret version. Can be 'latest' for - // the latest value or an integer for a specific version. - Version string `json:"version,omitempty"` - - // ForceSendFields is a list of field names (e.g. "Secret") 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. "Secret") 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 *GoogleCloudRunV2SecretKeySelector) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudRunV2SecretKeySelector - raw := NoMethod(*s) - return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) -} - -// GoogleCloudRunV2SecretVolumeSource: The secret's value will be -// presented as the content of a file whose name is defined in the item -// path. If no items are defined, the name of the file is the secret. -type GoogleCloudRunV2SecretVolumeSource struct { - // DefaultMode: Integer representation of mode bits to use on created - // files by default. Must be a value between 0000 and 0777 (octal), - // defaulting to 0644. Directories within the path are not affected by - // this setting. Notes * Internally, a umask of 0222 will be applied to - // any non-zero value. * This is an integer representation of the mode - // bits. So, the octal integer value should look exactly as the chmod - // numeric notation with a leading zero. Some examples: for chmod 777 - // (a=rwx), set to 0777 (octal) or 511 (base-10). For chmod 640 - // (u=rw,g=r), set to 0640 (octal) or 416 (base-10). For chmod 755 - // (u=rwx,g=rx,o=rx), set to 0755 (octal) or 493 (base-10). * This might - // be in conflict with other options that affect the file mode, like - // fsGroup, and the result can be other mode bits set. This might be in - // conflict with other options that affect the file mode, like fsGroup, - // and as a result, other mode bits could be set. - DefaultMode int64 `json:"defaultMode,omitempty"` - - // Items: If unspecified, the volume will expose a file whose name is - // the secret, relative to VolumeMount.mount_path. If specified, the key - // will be used as the version to fetch from Cloud Secret Manager and - // the path will be the name of the file exposed in the volume. When - // items are defined, they must specify a path and a version. - Items []*GoogleCloudRunV2VersionToPath `json:"items,omitempty"` - - // Secret: Required. The name of the secret in Cloud Secret Manager. - // Format: {secret} if the secret is in the same project. - // projects/{project}/secrets/{secret} if the secret is in a different - // project. - Secret string `json:"secret,omitempty"` - - // ForceSendFields is a list of field names (e.g. "DefaultMode") 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. "DefaultMode") 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 *GoogleCloudRunV2SecretVolumeSource) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudRunV2SecretVolumeSource +func (s *GoogleCloudRunV2ExecutionTemplate) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudRunV2ExecutionTemplate raw := NoMethod(*s) return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } -// GoogleCloudRunV2Service: Service acts as a top-level container that -// manages a set of configurations and revision templates which -// implement a network service. Service exists to provide a singular -// abstraction which can be access controlled, reasoned about, and which -// encapsulates software lifecycle decisions such as rollout policy and -// team resource ownership. -type GoogleCloudRunV2Service struct { - // Annotations: Unstructured key value map that may be set by external - // tools to store and arbitrary metadata. They are not queryable and - // should be preserved when modifying objects. Cloud Run will populate - // some annotations using 'run.googleapis.com' or 'serving.knative.dev' - // namespaces. This field follows Kubernetes annotations' namespacing, - // limits, and rules. More info: - // https://kubernetes.io/docs/user-guide/annotations +// GoogleCloudRunV2Job: Job represents the configuration of a single +// job. A job an immutable resource that references a container image +// which is run to completion. +type GoogleCloudRunV2Job struct { + // Annotations: KRM-style annotations for the resource. Unstructured key + // value map that may be set by external tools to store and arbitrary + // metadata. They are not queryable and should be preserved when + // modifying objects. Cloud Run will populate some annotations using + // 'run.googleapis.com' or 'serving.knative.dev' namespaces. This field + // follows Kubernetes annotations' namespacing, limits, and rules. More + // info: https://kubernetes.io/docs/user-guide/annotations Annotations map[string]string `json:"annotations,omitempty"` // BinaryAuthorization: Settings for the Binary Authorization feature. @@ -1150,11 +972,15 @@ type GoogleCloudRunV2Service struct { // Conditions: Output only. The Conditions of all other associated // sub-resources. They contain additional diagnostics information in - // case the Service does not reach its Serving state. See comments in + // case the Job does not reach its desired state. See comments in // `reconciling` for additional information on reconciliation process in // Cloud Run. Conditions []*GoogleCloudRunV2Condition `json:"conditions,omitempty"` + // ContainerStatuses: Output only. Status information for each of the + // containers specified. + ContainerStatuses []*GoogleCloudRunV2ContainerStatus `json:"containerStatuses,omitempty"` + // CreateTime: Output only. The creation time. CreateTime string `json:"createTime,omitempty"` @@ -1164,15 +990,15 @@ type GoogleCloudRunV2Service struct { // DeleteTime: Output only. The deletion time. DeleteTime string `json:"deleteTime,omitempty"` - // Description: User-provided description of the Service. This field - // currently has a 512-character limit. - Description string `json:"description,omitempty"` - // Etag: Output only. A system-generated fingerprint for this version of // the resource. May be used to detect modification conflict during // updates. Etag string `json:"etag,omitempty"` + // ExecutionCount: Output only. Number of executions created for this + // job. + ExecutionCount int64 `json:"executionCount,omitempty"` + // ExpireTime: Output only. For a deleted resource, the time after which // it will be permamently deleted. ExpireTime string `json:"expireTime,omitempty"` @@ -1181,23 +1007,10 @@ type GoogleCloudRunV2Service struct { // time the user modifies the desired state. Generation int64 `json:"generation,omitempty,string"` - // Ingress: Provides the ingress settings for this Service. On output, - // returns the currently observed ingress settings, or - // INGRESS_TRAFFIC_UNSPECIFIED if no revision is active. - // - // Possible values: - // "INGRESS_TRAFFIC_UNSPECIFIED" - Unspecified - // "INGRESS_TRAFFIC_ALL" - All inbound traffic is allowed. - // "INGRESS_TRAFFIC_INTERNAL_ONLY" - Only internal traffic is allowed. - // "INGRESS_TRAFFIC_INTERNAL_LOAD_BALANCER" - Both internal and Google - // Cloud Load Balancer traffic is allowed. - Ingress string `json:"ingress,omitempty"` - - // Labels: Map of string keys and values that can be used to organize - // and categorize objects. User-provided labels are shared with Google's - // billing system, so they can be used to filter, or break down billing - // charges by team, component, environment, state, etc. For more - // information, visit + // Labels: KRM-style labels for the resource. User-provided labels are + // shared with Google's billing system, so they can be used to filter, + // or break down billing charges by team, component, environment, state, + // etc. For more information, visit // https://cloud.google.com/resource-manager/docs/creating-managing-labels // or https://cloud.google.com/run/docs/configuring/labels Cloud Run // will populate some labels with 'run.googleapis.com' or @@ -1209,15 +1022,9 @@ type GoogleCloudRunV2Service struct { // modifier. LastModifier string `json:"lastModifier,omitempty"` - // LatestCreatedRevision: Output only. Name of the last created - // revision. See comments in `reconciling` for additional information on - // reconciliation process in Cloud Run. - LatestCreatedRevision string `json:"latestCreatedRevision,omitempty"` - - // LatestReadyRevision: Output only. Name of the latest revision that is - // serving traffic. See comments in `reconciling` for additional - // information on reconciliation process in Cloud Run. - LatestReadyRevision string `json:"latestReadyRevision,omitempty"` + // LatestCreatedExecution: Output only. Name of the last created + // execution. + LatestCreatedExecution *GoogleCloudRunV2ExecutionReference `json:"latestCreatedExecution,omitempty"` // LaunchStage: The launch stage as defined by Google Cloud Platform // Launch Stages (https://cloud.google.com/terms/launch-stages). Cloud @@ -1259,70 +1066,53 @@ type GoogleCloudRunV2Service struct { // Policy](https://cloud.google.com/terms/deprecation) documentation. LaunchStage string `json:"launchStage,omitempty"` - // Name: The fully qualified name of this Service. In - // CreateServiceRequest, this field is ignored, and instead composed - // from CreateServiceRequest.parent and CreateServiceRequest.service_id. - // Format: projects/{project}/locations/{location}/services/{service_id} + // Name: The fully qualified name of this Job. Format: + // projects/{project}/locations/{location}/jobs/{job} Name string `json:"name,omitempty"` - // ObservedGeneration: Output only. The generation of this Service - // currently serving traffic. See comments in `reconciling` for - // additional information on reconciliation process in Cloud Run. + // ObservedGeneration: Output only. The generation of this Job. See + // comments in `reconciling` for additional information on + // reconciliation process in Cloud Run. ObservedGeneration int64 `json:"observedGeneration,omitempty,string"` - // Reconciling: Output only. Returns true if the Service is currently - // being acted upon by the system to bring it into the desired state. - // When a new Service is created, or an existing one is updated, Cloud - // Run will asynchronously perform all necessary steps to bring the - // Service to the desired serving state. This process is called - // reconciliation. While reconciliation is in process, - // `observed_generation`, `latest_ready_revison`, `traffic_statuses`, - // and `uri` will have transient values that might mismatch the intended - // state: Once reconciliation is over (and this field is false), there - // are two possible outcomes: reconciliation succeeded and the serving - // state matches the Service, or there was an error, and reconciliation - // failed. This state can be found in `terminal_condition.state`. If - // reconciliation succeeded, the following fields will match: `traffic` - // and `traffic_statuses`, `observed_generation` and `generation`, - // `latest_ready_revision` and `latest_created_revision`. If - // reconciliation failed, `traffic_statuses`, `observed_generation`, and - // `latest_ready_revision` will have the state of the last serving - // revision, or empty for newly created Services. Additional information - // on the failure can be found in `terminal_condition` and `conditions`. + // Reconciling: Output only. Returns true if the Job is currently being + // acted upon by the system to bring it into the desired state. When a + // new Job is created, or an existing one is updated, Cloud Run will + // asynchronously perform all necessary steps to bring the Job to the + // desired state. This process is called reconciliation. While + // reconciliation is in process, `observed_generation` and + // `latest_succeeded_execution`, will have transient values that might + // mismatch the intended state: Once reconciliation is over (and this + // field is false), there are two possible outcomes: reconciliation + // succeeded and the state matches the Job, or there was an error, and + // reconciliation failed. This state can be found in + // `terminal_condition.state`. If reconciliation succeeded, the + // following fields will match: `observed_generation` and `generation`, + // `latest_succeeded_execution` and `latest_created_execution`. If + // reconciliation failed, `observed_generation` and + // `latest_succeeded_execution` will have the state of the last + // succeeded execution or empty for newly created Job. Additional + // information on the failure can be found in `terminal_condition` and + // `conditions`. Reconciling bool `json:"reconciling,omitempty"` - // Template: Required. The template used to create revisions for this - // Service. - Template *GoogleCloudRunV2RevisionTemplate `json:"template,omitempty"` + // Template: Required. The template used to create executions for this + // Job. + Template *GoogleCloudRunV2ExecutionTemplate `json:"template,omitempty"` - // TerminalCondition: Output only. The Condition of this Service, - // containing its readiness status, and detailed error information in - // case it did not reach a serving state. See comments in `reconciling` - // for additional information on reconciliation process in Cloud Run. + // TerminalCondition: Output only. The Condition of this Job, containing + // its readiness status, and detailed error information in case it did + // not reach the desired state. TerminalCondition *GoogleCloudRunV2Condition `json:"terminalCondition,omitempty"` - // Traffic: Specifies how to distribute traffic over a collection of - // Revisions belonging to the Service. If traffic is empty or not - // provided, defaults to 100% traffic to the latest `Ready` Revision. - Traffic []*GoogleCloudRunV2TrafficTarget `json:"traffic,omitempty"` - - // TrafficStatuses: Output only. Detailed status information for - // corresponding traffic targets. See comments in `reconciling` for - // additional information on reconciliation process in Cloud Run. - TrafficStatuses []*GoogleCloudRunV2TrafficTargetStatus `json:"trafficStatuses,omitempty"` - - // Uid: Output only. Server assigned unique identifier for the trigger. - // The value is a UUID4 string and guaranteed to remain unchanged until - // the resource is deleted. + // Uid: Output only. Server assigned unique identifier for the + // Execution. The value is a UUID4 string and guaranteed to remain + // unchanged until the resource is deleted. Uid string `json:"uid,omitempty"` // UpdateTime: Output only. The last-modified time. UpdateTime string `json:"updateTime,omitempty"` - // Uri: Output only. The main URI in which this Service is serving - // traffic. - Uri string `json:"uri,omitempty"` - // ServerResponse contains the HTTP response code and headers from the // server. googleapi.ServerResponse `json:"-"` @@ -1344,40 +1134,27 @@ type GoogleCloudRunV2Service struct { NullFields []string `json:"-"` } -func (s *GoogleCloudRunV2Service) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudRunV2Service +func (s *GoogleCloudRunV2Job) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudRunV2Job raw := NoMethod(*s) return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } -// GoogleCloudRunV2TrafficTarget: Holds a single traffic routing entry -// for the Service. Allocations can be done to a specific Revision name, -// or pointing to the latest Ready Revision. -type GoogleCloudRunV2TrafficTarget struct { - // Percent: Specifies percent of the traffic to this Revision. This - // defaults to zero if unspecified. - Percent int64 `json:"percent,omitempty"` +// GoogleCloudRunV2ListExecutionsResponse: Response message containing a +// list of Executions. +type GoogleCloudRunV2ListExecutionsResponse struct { + // Executions: The resulting list of Executions. + Executions []*GoogleCloudRunV2Execution `json:"executions,omitempty"` - // Revision: Revision to which to send this portion of traffic, if - // traffic allocation is by revision. - Revision string `json:"revision,omitempty"` - - // Tag: Indicates a string to be part of the URI to exclusively - // reference this target. - Tag string `json:"tag,omitempty"` + // NextPageToken: A token indicating there are more items than + // page_size. Use it in the next ListExecutions request to continue. + NextPageToken string `json:"nextPageToken,omitempty"` - // Type: The allocation type for this traffic target. - // - // Possible values: - // "TRAFFIC_TARGET_ALLOCATION_TYPE_UNSPECIFIED" - Unspecified instance - // allocation type. - // "TRAFFIC_TARGET_ALLOCATION_TYPE_LATEST" - Allocates instances to - // the Service's latest ready Revision. - // "TRAFFIC_TARGET_ALLOCATION_TYPE_REVISION" - Allocates instances to - // a Revision by name. - Type string `json:"type,omitempty"` + // ServerResponse contains the HTTP response code and headers from the + // server. + googleapi.ServerResponse `json:"-"` - // ForceSendFields is a list of field names (e.g. "Percent") to + // ForceSendFields is a list of field names (e.g. "Executions") 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 @@ -1385,7 +1162,7 @@ type GoogleCloudRunV2TrafficTarget struct { // This may be used to include empty fields in Patch requests. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "Percent") to include in + // NullFields is a list of field names (e.g. "Executions") 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 @@ -1394,40 +1171,27 @@ type GoogleCloudRunV2TrafficTarget struct { NullFields []string `json:"-"` } -func (s *GoogleCloudRunV2TrafficTarget) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudRunV2TrafficTarget +func (s *GoogleCloudRunV2ListExecutionsResponse) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudRunV2ListExecutionsResponse raw := NoMethod(*s) return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } -// GoogleCloudRunV2TrafficTargetStatus: Represents the observed state of -// a single `TrafficTarget` entry. -type GoogleCloudRunV2TrafficTargetStatus struct { - // Percent: Specifies percent of the traffic to this Revision. - Percent int64 `json:"percent,omitempty"` - - // Revision: Revision to which this traffic is sent. - Revision string `json:"revision,omitempty"` - - // Tag: Indicates the string used in the URI to exclusively reference - // this target. - Tag string `json:"tag,omitempty"` +// GoogleCloudRunV2ListJobsResponse: Response message containing a list +// of Jobs. +type GoogleCloudRunV2ListJobsResponse struct { + // Jobs: The resulting list of Jobs. + Jobs []*GoogleCloudRunV2Job `json:"jobs,omitempty"` - // Type: The allocation type for this traffic target. - // - // Possible values: - // "TRAFFIC_TARGET_ALLOCATION_TYPE_UNSPECIFIED" - Unspecified instance - // allocation type. - // "TRAFFIC_TARGET_ALLOCATION_TYPE_LATEST" - Allocates instances to - // the Service's latest ready Revision. - // "TRAFFIC_TARGET_ALLOCATION_TYPE_REVISION" - Allocates instances to - // a Revision by name. - Type string `json:"type,omitempty"` + // NextPageToken: A token indicating there are more items than + // page_size. Use it in the next ListJobs request to continue. + NextPageToken string `json:"nextPageToken,omitempty"` - // Uri: Displays the target URI. - Uri string `json:"uri,omitempty"` + // ServerResponse contains the HTTP response code and headers from the + // server. + googleapi.ServerResponse `json:"-"` - // ForceSendFields is a list of field names (e.g. "Percent") to + // ForceSendFields is a list of field names (e.g. "Jobs") 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 @@ -1435,8 +1199,8 @@ type GoogleCloudRunV2TrafficTargetStatus struct { // This may be used to include empty fields in Patch requests. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "Percent") to include in - // API requests with the JSON null value. By default, fields with empty + // NullFields is a list of field names (e.g. "Jobs") 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. @@ -1444,37 +1208,27 @@ type GoogleCloudRunV2TrafficTargetStatus struct { NullFields []string `json:"-"` } -func (s *GoogleCloudRunV2TrafficTargetStatus) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudRunV2TrafficTargetStatus +func (s *GoogleCloudRunV2ListJobsResponse) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudRunV2ListJobsResponse raw := NoMethod(*s) return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } -// GoogleCloudRunV2VersionToPath: VersionToPath maps a specific version -// of a secret to a relative file to mount to, relative to VolumeMount's -// mount_path. -type GoogleCloudRunV2VersionToPath struct { - // Mode: Integer octal mode bits to use on this file, must be a value - // between 01 and 0777 (octal). If 0 or not set, the Volume's default - // mode will be used. Notes * Internally, a umask of 0222 will be - // applied to any non-zero value. * This is an integer representation of - // the mode bits. So, the octal integer value should look exactly as the - // chmod numeric notation with a leading zero. Some examples: for chmod - // 777 (a=rwx), set to 0777 (octal) or 511 (base-10). For chmod 640 - // (u=rw,g=r), set to 0640 (octal) or 416 (base-10). For chmod 755 - // (u=rwx,g=rx,o=rx), set to 0755 (octal) or 493 (base-10). * This might - // be in conflict with other options that affect the file mode, like - // fsGroup, and the result can be other mode bits set. - Mode int64 `json:"mode,omitempty"` +// GoogleCloudRunV2ListRevisionsResponse: Response message containing a +// list of Revisions. +type GoogleCloudRunV2ListRevisionsResponse struct { + // NextPageToken: A token indicating there are more items than + // page_size. Use it in the next ListRevisions request to continue. + NextPageToken string `json:"nextPageToken,omitempty"` - // Path: Required. The relative path of the secret in the container. - Path string `json:"path,omitempty"` + // Revisions: The resulting list of Revisions. + Revisions []*GoogleCloudRunV2Revision `json:"revisions,omitempty"` - // Version: The Cloud Secret Manager secret version. Can be 'latest' for - // the latest value or an integer for a specific version. - Version string `json:"version,omitempty"` + // ServerResponse contains the HTTP response code and headers from the + // server. + googleapi.ServerResponse `json:"-"` - // ForceSendFields is a list of field names (e.g. "Mode") to + // ForceSendFields is a list of field names (e.g. "NextPageToken") to // unconditionally include in API requests. By default, fields with // empty or default values are omitted from API requests. However, any // non-pointer, non-interface field appearing in ForceSendFields will be @@ -1482,38 +1236,36 @@ type GoogleCloudRunV2VersionToPath struct { // This may be used to include empty fields in Patch requests. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "Mode") 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 + // NullFields is a list of field names (e.g. "NextPageToken") to include + // in API requests with the JSON null value. By default, fields with + // empty values are omitted from API requests. However, any field with + // an empty value appearing in NullFields will be sent to the server as // null. It is an error if a field in this list has a non-empty value. // This may be used to include null fields in Patch requests. NullFields []string `json:"-"` } -func (s *GoogleCloudRunV2VersionToPath) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudRunV2VersionToPath +func (s *GoogleCloudRunV2ListRevisionsResponse) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudRunV2ListRevisionsResponse raw := NoMethod(*s) return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } -// GoogleCloudRunV2Volume: Volume represents a named volume in a -// container. -type GoogleCloudRunV2Volume struct { - // CloudSqlInstance: For Cloud SQL volumes, contains the specific - // instances that should be mounted. Visit - // https://cloud.google.com/sql/docs/mysql/connect-run for more - // information on how to connect Cloud SQL and Cloud Run. - CloudSqlInstance *GoogleCloudRunV2CloudSqlInstance `json:"cloudSqlInstance,omitempty"` +// GoogleCloudRunV2ListServicesResponse: Response message containing a +// list of Services. +type GoogleCloudRunV2ListServicesResponse struct { + // NextPageToken: A token indicating there are more items than + // page_size. Use it in the next ListServices request to continue. + NextPageToken string `json:"nextPageToken,omitempty"` - // Name: Required. Volume's name. - Name string `json:"name,omitempty"` + // Services: The resulting list of Services. + Services []*GoogleCloudRunV2Service `json:"services,omitempty"` - // Secret: Secret represents a secret that should populate this volume. - // More info: https://kubernetes.io/docs/concepts/storage/volumes#secret - Secret *GoogleCloudRunV2SecretVolumeSource `json:"secret,omitempty"` + // ServerResponse contains the HTTP response code and headers from the + // server. + googleapi.ServerResponse `json:"-"` - // ForceSendFields is a list of field names (e.g. "CloudSqlInstance") to + // ForceSendFields is a list of field names (e.g. "NextPageToken") to // unconditionally include in API requests. By default, fields with // empty or default values are omitted from API requests. However, any // non-pointer, non-interface field appearing in ForceSendFields will be @@ -1521,37 +1273,36 @@ type GoogleCloudRunV2Volume struct { // This may be used to include empty fields in Patch requests. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "CloudSqlInstance") to - // include in API requests with the JSON null value. By default, fields - // with empty values are omitted from API requests. However, any field - // with an empty value appearing in NullFields will be sent to the - // server as null. It is an error if a field in this list has a - // non-empty value. This may be used to include null fields in Patch - // requests. + // NullFields is a list of field names (e.g. "NextPageToken") to include + // in API requests with the JSON null value. By default, fields with + // empty values are omitted from API requests. However, any field with + // an empty value appearing in NullFields will be sent to the server as + // null. It is an error if a field in this list has a non-empty value. + // This may be used to include null fields in Patch requests. NullFields []string `json:"-"` } -func (s *GoogleCloudRunV2Volume) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudRunV2Volume +func (s *GoogleCloudRunV2ListServicesResponse) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudRunV2ListServicesResponse raw := NoMethod(*s) return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } -// GoogleCloudRunV2VolumeMount: VolumeMount describes a mounting of a -// Volume within a container. -type GoogleCloudRunV2VolumeMount struct { - // MountPath: Required. Path within the container at which the volume - // should be mounted. Must not contain ':'. For Cloud SQL volumes, it - // can be left empty, or must otherwise be `/cloudsql`. All instances - // defined in the Volume will be available as `/cloudsql/[instance]`. - // For more information on Cloud SQL volumes, visit - // https://cloud.google.com/sql/docs/mysql/connect-run - MountPath string `json:"mountPath,omitempty"` +// GoogleCloudRunV2ListTasksResponse: Response message containing a list +// of Tasks. +type GoogleCloudRunV2ListTasksResponse struct { + // NextPageToken: A token indicating there are more items than + // page_size. Use it in the next ListTasks request to continue. + NextPageToken string `json:"nextPageToken,omitempty"` - // Name: Required. This must match the Name of a Volume. - Name string `json:"name,omitempty"` + // Tasks: The resulting list of Tasks. + Tasks []*GoogleCloudRunV2Task `json:"tasks,omitempty"` - // ForceSendFields is a list of field names (e.g. "MountPath") to + // ServerResponse contains the HTTP response code and headers from the + // server. + googleapi.ServerResponse `json:"-"` + + // ForceSendFields is a list of field names (e.g. "NextPageToken") to // unconditionally include in API requests. By default, fields with // empty or default values are omitted from API requests. However, any // non-pointer, non-interface field appearing in ForceSendFields will be @@ -1559,43 +1310,36 @@ type GoogleCloudRunV2VolumeMount struct { // This may be used to include empty fields in Patch requests. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "MountPath") 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 + // NullFields is a list of field names (e.g. "NextPageToken") to include + // in API requests with the JSON null value. By default, fields with + // empty values are omitted from API requests. However, any field with + // an empty value appearing in NullFields will be sent to the server as // null. It is an error if a field in this list has a non-empty value. // This may be used to include null fields in Patch requests. NullFields []string `json:"-"` } -func (s *GoogleCloudRunV2VolumeMount) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudRunV2VolumeMount +func (s *GoogleCloudRunV2ListTasksResponse) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudRunV2ListTasksResponse raw := NoMethod(*s) return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } -// GoogleCloudRunV2VpcAccess: VPC Access settings. For more information -// on creating a VPC Connector, visit -// https://cloud.google.com/vpc/docs/configure-serverless-vpc-access For -// information on how to configure Cloud Run with an existing VPC -// Connector, visit -// https://cloud.google.com/run/docs/configuring/connecting-vpc -type GoogleCloudRunV2VpcAccess struct { - // Connector: VPC Access connector name. Format: - // projects/{project}/locations/{location}/connectors/{connector} - Connector string `json:"connector,omitempty"` +// GoogleCloudRunV2ResourceRequirements: ResourceRequirements describes +// the compute resource requirements. +type GoogleCloudRunV2ResourceRequirements struct { + // CpuIdle: Determines whether CPU should be throttled or not outside of + // requests. + CpuIdle bool `json:"cpuIdle,omitempty"` - // Egress: Traffic VPC egress settings. - // - // Possible values: - // "VPC_EGRESS_UNSPECIFIED" - Unspecified - // "ALL_TRAFFIC" - All outbound traffic is routed through the VPC - // connector. - // "PRIVATE_RANGES_ONLY" - Only private IP ranges are routed through - // the VPC connector. - Egress string `json:"egress,omitempty"` + // Limits: Only memory and CPU are supported. Note: The only supported + // values for CPU are '1', '2', and '4'. Setting 4 CPU requires at least + // 2Gi of memory. The values of the map is string form of the 'quantity' + // k8s type: + // https://github.com/kubernetes/kubernetes/blob/master/staging/src/k8s.io/apimachinery/pkg/api/resource/quantity.go + Limits map[string]string `json:"limits,omitempty"` - // ForceSendFields is a list of field names (e.g. "Connector") to + // ForceSendFields is a list of field names (e.g. "CpuIdle") 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 @@ -1603,7 +1347,7 @@ type GoogleCloudRunV2VpcAccess struct { // This may be used to include empty fields in Patch requests. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "Connector") to include in + // NullFields is a list of field names (e.g. "CpuIdle") 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 @@ -1612,41 +1356,178 @@ type GoogleCloudRunV2VpcAccess struct { NullFields []string `json:"-"` } -func (s *GoogleCloudRunV2VpcAccess) MarshalJSON() ([]byte, error) { - type NoMethod GoogleCloudRunV2VpcAccess +func (s *GoogleCloudRunV2ResourceRequirements) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudRunV2ResourceRequirements 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 -// 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. -type GoogleIamV1AuditConfig struct { - // AuditLogConfigs: The configuration for logging of each type of - // permission. - AuditLogConfigs []*GoogleIamV1AuditLogConfig `json:"auditLogConfigs,omitempty"` +// GoogleCloudRunV2Revision: A Revision is an immutable snapshot of code +// and configuration. A Revision references a container image. Revisions +// are only created by updates to its parent Service. +type GoogleCloudRunV2Revision struct { + // Annotations: KRM-style annotations for the resource. + Annotations map[string]string `json:"annotations,omitempty"` - // Service: Specifies a service that will be enabled for audit logging. - // For example, `storage.googleapis.com`, `cloudsql.googleapis.com`. - // `allServices` is a special value that covers all services. - Service string `json:"service,omitempty"` + // Conditions: Output only. The Condition of this Revision, containing + // its readiness status, and detailed error information in case it did + // not reach a serving state. + Conditions []*GoogleCloudRunV2Condition `json:"conditions,omitempty"` - // ForceSendFields is a list of field names (e.g. "AuditLogConfigs") to + // Confidential: Indicates whether Confidential Cloud Run is enabled in + // this Revision. + Confidential bool `json:"confidential,omitempty"` + + // ContainerConcurrency: Sets the maximum number of requests that each + // serving instance can receive. + ContainerConcurrency int64 `json:"containerConcurrency,omitempty"` + + // Containers: Holds the single container that defines the unit of + // execution for this Revision. + Containers []*GoogleCloudRunV2Container `json:"containers,omitempty"` + + // CreateTime: Output only. The creation time. + CreateTime string `json:"createTime,omitempty"` + + // DeleteTime: Output only. For a deleted resource, the deletion time. + // It is only populated as a response to a Delete request. + DeleteTime string `json:"deleteTime,omitempty"` + + // EncryptionKey: A reference to a customer managed encryption key + // (CMEK) to use to encrypt this container image. For more information, + // go to https://cloud.google.com/run/docs/securing/using-cmek + EncryptionKey string `json:"encryptionKey,omitempty"` + + // Etag: Output only. A system-generated fingerprint for this version of + // the resource. May be used to detect modification conflict during + // updates. + Etag string `json:"etag,omitempty"` + + // ExecutionEnvironment: The execution environment being used to host + // this Revision. + // + // Possible values: + // "EXECUTION_ENVIRONMENT_UNSPECIFIED" - Unspecified + // "EXECUTION_ENVIRONMENT_GEN1" - Uses the First Generation + // environment. + // "EXECUTION_ENVIRONMENT_GEN2" - Uses Second Generation environment. + ExecutionEnvironment string `json:"executionEnvironment,omitempty"` + + // ExpireTime: Output only. For a deleted resource, the time after which + // it will be permamently deleted. It is only populated as a response to + // a Delete request. + ExpireTime string `json:"expireTime,omitempty"` + + // Generation: Output only. A number that monotonically increases every + // time the user modifies the desired state. + Generation int64 `json:"generation,omitempty,string"` + + // Labels: KRM-style labels for the resource. User-provided labels are + // shared with Google's billing system, so they can be used to filter, + // or break down billing charges by team, component, environment, state, + // etc. For more information, visit + // https://cloud.google.com/resource-manager/docs/creating-managing-labels + // or https://cloud.google.com/run/docs/configuring/labels Cloud Run + // will populate some labels with 'run.googleapis.com' or + // 'serving.knative.dev' namespaces. Those labels are read-only, and + // user changes will not be preserved. + Labels map[string]string `json:"labels,omitempty"` + + // LaunchStage: Set the launch stage to a preview stage on write to + // allow use of preview features in that stage. On read, describes + // whether the resource uses preview features. Launch Stages are defined + // at Google Cloud Platform Launch Stages + // (https://cloud.google.com/terms/launch-stages). + // + // Possible values: + // "LAUNCH_STAGE_UNSPECIFIED" - Do not use this default value. + // "UNIMPLEMENTED" - The feature is not yet implemented. Users can not + // use it. + // "PRELAUNCH" - Prelaunch features are hidden from users and are only + // visible internally. + // "EARLY_ACCESS" - Early Access features are limited to a closed + // group of testers. To use these features, you must sign up in advance + // and sign a Trusted Tester agreement (which includes confidentiality + // provisions). These features may be unstable, changed in + // backward-incompatible ways, and are not guaranteed to be released. + // "ALPHA" - Alpha is a limited availability test for releases before + // they are cleared for widespread use. By Alpha, all significant design + // issues are resolved and we are in the process of verifying + // functionality. Alpha customers need to apply for access, agree to + // applicable terms, and have their projects allowlisted. Alpha releases + // don't have to be feature complete, no SLAs are provided, and there + // are no technical support obligations, but they will be far enough + // along that customers can actually use them in test environments or + // for limited-use tests -- just like they would in normal production + // cases. + // "BETA" - Beta is the point at which we are ready to open a release + // for any customer to use. There are no SLA or technical support + // obligations in a Beta release. Products will be complete from a + // feature perspective, but may have some open outstanding issues. Beta + // releases are suitable for limited production use cases. + // "GA" - GA features are open to all developers and are considered + // stable and fully qualified for production use. + // "DEPRECATED" - Deprecated features are scheduled to be shut down + // and removed. For more information, see the "Deprecation Policy" + // section of our [Terms of Service](https://cloud.google.com/terms/) + // and the [Google Cloud Platform Subject to the Deprecation + // Policy](https://cloud.google.com/terms/deprecation) documentation. + LaunchStage string `json:"launchStage,omitempty"` + + // LogUri: Output only. The Google Console URI to obtain logs for the + // Revision. + LogUri string `json:"logUri,omitempty"` + + // Name: Output only. The unique name of this Revision. + Name string `json:"name,omitempty"` + + // ObservedGeneration: Output only. The generation of this Revision + // currently serving traffic. See comments in `reconciling` for + // additional information on reconciliation process in Cloud Run. + ObservedGeneration int64 `json:"observedGeneration,omitempty,string"` + + // Reconciling: Output only. Indicates whether the resource's + // reconciliation is still in progress. See comments in + // `Service.reconciling` for additional information on reconciliation + // process in Cloud Run. + Reconciling bool `json:"reconciling,omitempty"` + + // Scaling: Scaling settings for this revision. + Scaling *GoogleCloudRunV2RevisionScaling `json:"scaling,omitempty"` + + // Service: Output only. The name of the parent service. + Service string `json:"service,omitempty"` + + // ServiceAccount: Email address of the IAM service account associated + // with the revision of the service. The service account represents the + // identity of the running revision, and determines what permissions the + // revision has. + ServiceAccount string `json:"serviceAccount,omitempty"` + + // Timeout: Max allowed time for an instance to respond to a request. + Timeout string `json:"timeout,omitempty"` + + // Uid: Output only. Server assigned unique identifier for the Revision. + // The value is a UUID4 string and guaranteed to remain unchanged until + // the resource is deleted. + Uid string `json:"uid,omitempty"` + + // UpdateTime: Output only. The last-modified time. + UpdateTime string `json:"updateTime,omitempty"` + + // Volumes: A list of Volumes to make available to containers. + Volumes []*GoogleCloudRunV2Volume `json:"volumes,omitempty"` + + // VpcAccess: VPC Access configuration for this Revision. For more + // information, visit + // https://cloud.google.com/run/docs/configuring/connecting-vpc. + VpcAccess *GoogleCloudRunV2VpcAccess `json:"vpcAccess,omitempty"` + + // ServerResponse contains the HTTP response code and headers from the + // server. + googleapi.ServerResponse `json:"-"` + + // ForceSendFields is a list of field names (e.g. "Annotations") 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 @@ -1654,44 +1535,33 @@ type GoogleIamV1AuditConfig struct { // This may be used to include empty fields in Patch requests. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "AuditLogConfigs") to - // include in API requests with the JSON null value. By default, fields - // with empty values are omitted from API requests. However, any field - // with an empty value appearing in NullFields will be sent to the - // server as null. It is an error if a field in this list has a - // non-empty value. This may be used to include null fields in Patch - // requests. + // NullFields is a list of field names (e.g. "Annotations") 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 *GoogleIamV1AuditConfig) MarshalJSON() ([]byte, error) { - type NoMethod GoogleIamV1AuditConfig +func (s *GoogleCloudRunV2Revision) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudRunV2Revision raw := NoMethod(*s) return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } -// GoogleIamV1AuditLogConfig: Provides the configuration for logging a -// type of permissions. Example: { "audit_log_configs": [ { "log_type": -// "DATA_READ", "exempted_members": [ "user:jose@example.com" ] }, { -// "log_type": "DATA_WRITE" } ] } This enables 'DATA_READ' and -// 'DATA_WRITE' logging, while exempting jose@example.com from DATA_READ -// logging. -type GoogleIamV1AuditLogConfig struct { - // ExemptedMembers: Specifies the identities that do not cause logging - // for this type of permission. Follows the same format of - // Binding.members. - ExemptedMembers []string `json:"exemptedMembers,omitempty"` +// GoogleCloudRunV2RevisionScaling: Settings for revision-level scaling +// settings. +type GoogleCloudRunV2RevisionScaling struct { + // MaxInstanceCount: Maximum number of serving instances that this + // resource should have. + MaxInstanceCount int64 `json:"maxInstanceCount,omitempty"` - // LogType: The log type that this config enables. - // - // Possible values: - // "LOG_TYPE_UNSPECIFIED" - Default case. Should never be this. - // "ADMIN_READ" - Admin reads. Example: CloudIAM getIamPolicy - // "DATA_WRITE" - Data writes. Example: CloudSQL Users create - // "DATA_READ" - Data reads. Example: CloudSQL Users list - LogType string `json:"logType,omitempty"` + // MinInstanceCount: Minimum number of serving instances that this + // resource should have. + MinInstanceCount int64 `json:"minInstanceCount,omitempty"` - // ForceSendFields is a list of field names (e.g. "ExemptedMembers") to + // ForceSendFields is a list of field names (e.g. "MaxInstanceCount") 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 @@ -1699,7 +1569,7 @@ type GoogleIamV1AuditLogConfig struct { // This may be used to include empty fields in Patch requests. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "ExemptedMembers") to + // NullFields is a list of field names (e.g. "MaxInstanceCount") 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 @@ -1709,174 +1579,73 @@ type GoogleIamV1AuditLogConfig struct { NullFields []string `json:"-"` } -func (s *GoogleIamV1AuditLogConfig) MarshalJSON() ([]byte, error) { - type NoMethod GoogleIamV1AuditLogConfig +func (s *GoogleCloudRunV2RevisionScaling) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudRunV2RevisionScaling raw := NoMethod(*s) return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } -// GoogleIamV1Binding: Associates `members`, or principals, with a -// `role`. -type GoogleIamV1Binding struct { - // Condition: The condition that is associated with this binding. If the - // condition evaluates to `true`, then this binding applies to the - // current request. If the condition evaluates to `false`, then this - // binding does not apply to the current request. However, a different - // role binding might grant the same role to one or more of the - // principals in this binding. To learn which resources support - // conditions in their IAM policies, see the IAM documentation - // (https://cloud.google.com/iam/help/conditions/resource-policies). - Condition *GoogleTypeExpr `json:"condition,omitempty"` +// GoogleCloudRunV2RevisionTemplate: RevisionTemplate describes the data +// a revision should have when created from a template. +type GoogleCloudRunV2RevisionTemplate struct { + // Annotations: KRM-style annotations for the resource. + Annotations map[string]string `json:"annotations,omitempty"` - // Members: Specifies the principals requesting access for a Google - // Cloud resource. `members` can have the following values: * - // `allUsers`: A special identifier that represents anyone who is on the - // internet; with or without a Google account. * - // `allAuthenticatedUsers`: A special identifier that represents anyone - // who is authenticated with a Google account or a service account. * - // `user:{emailid}`: An email address that represents a specific Google - // account. For example, `alice@example.com` . * - // `serviceAccount:{emailid}`: An email address that represents a - // service account. For example, - // `my-other-app@appspot.gserviceaccount.com`. * `group:{emailid}`: An - // email address that represents a Google group. For example, - // `admins@example.com`. * `deleted:user:{emailid}?uid={uniqueid}`: An - // email address (plus unique identifier) representing a user that has - // been recently deleted. For example, - // `alice@example.com?uid=123456789012345678901`. If the user is - // recovered, this value reverts to `user:{emailid}` and the recovered - // user retains the role in the binding. * - // `deleted:serviceAccount:{emailid}?uid={uniqueid}`: An email address - // (plus unique identifier) representing a service account that has been - // recently deleted. For example, - // `my-other-app@appspot.gserviceaccount.com?uid=123456789012345678901`. - // If the service account is undeleted, this value reverts to - // `serviceAccount:{emailid}` and the undeleted service account retains - // the role in the binding. * `deleted:group:{emailid}?uid={uniqueid}`: - // An email address (plus unique identifier) representing a Google group - // that has been recently deleted. For example, - // `admins@example.com?uid=123456789012345678901`. If the group is - // recovered, this value reverts to `group:{emailid}` and the recovered - // group retains the role in the binding. * `domain:{domain}`: The G - // Suite domain (primary) that represents all the users of that domain. - // For example, `google.com` or `example.com`. - Members []string `json:"members,omitempty"` + // Confidential: Enables Confidential Cloud Run in Revisions created + // using this template. + Confidential bool `json:"confidential,omitempty"` - // Role: Role that is assigned to the list of `members`, or principals. - // For example, `roles/viewer`, `roles/editor`, or `roles/owner`. - Role string `json:"role,omitempty"` + // ContainerConcurrency: Sets the maximum number of requests that each + // serving instance can receive. + ContainerConcurrency int64 `json:"containerConcurrency,omitempty"` - // ForceSendFields is a list of field names (e.g. "Condition") 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:"-"` + // Containers: Holds the single container that defines the unit of + // execution for this Revision. + Containers []*GoogleCloudRunV2Container `json:"containers,omitempty"` - // NullFields is a list of field names (e.g. "Condition") 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:"-"` -} + // EncryptionKey: A reference to a customer managed encryption key + // (CMEK) to use to encrypt this container image. For more information, + // go to https://cloud.google.com/run/docs/securing/using-cmek + EncryptionKey string `json:"encryptionKey,omitempty"` -func (s *GoogleIamV1Binding) MarshalJSON() ([]byte, error) { - type NoMethod GoogleIamV1Binding - raw := NoMethod(*s) - return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) -} + // ExecutionEnvironment: The sandbox environment to host this Revision. + // + // Possible values: + // "EXECUTION_ENVIRONMENT_UNSPECIFIED" - Unspecified + // "EXECUTION_ENVIRONMENT_GEN1" - Uses the First Generation + // environment. + // "EXECUTION_ENVIRONMENT_GEN2" - Uses Second Generation environment. + ExecutionEnvironment string `json:"executionEnvironment,omitempty"` -// GoogleIamV1Policy: An Identity and Access Management (IAM) policy, -// which specifies access controls for Google Cloud resources. A -// `Policy` is a collection of `bindings`. A `binding` binds one or more -// `members`, or principals, to a single `role`. Principals can be user -// accounts, service accounts, Google groups, and domains (such as G -// Suite). A `role` is a named list of permissions; each `role` can be -// an IAM predefined role or a user-created custom role. For some types -// of Google Cloud resources, a `binding` can also specify a -// `condition`, which is a logical expression that allows access to a -// resource only if the expression evaluates to `true`. A condition can -// add constraints based on attributes of the request, the resource, or -// both. To learn which resources support conditions in their IAM -// policies, see the IAM documentation -// (https://cloud.google.com/iam/help/conditions/resource-policies). -// **JSON example:** { "bindings": [ { "role": -// "roles/resourcemanager.organizationAdmin", "members": [ -// "user:mike@example.com", "group:admins@example.com", -// "domain:google.com", -// "serviceAccount:my-project-id@appspot.gserviceaccount.com" ] }, { -// "role": "roles/resourcemanager.organizationViewer", "members": [ -// "user:eve@example.com" ], "condition": { "title": "expirable access", -// "description": "Does not grant access after Sep 2020", "expression": -// "request.time < timestamp('2020-10-01T00:00:00.000Z')", } } ], -// "etag": "BwWWja0YfJA=", "version": 3 } **YAML example:** bindings: - -// members: - user:mike@example.com - group:admins@example.com - -// domain:google.com - -// serviceAccount:my-project-id@appspot.gserviceaccount.com role: -// roles/resourcemanager.organizationAdmin - members: - -// user:eve@example.com role: roles/resourcemanager.organizationViewer -// condition: title: expirable access description: Does not grant access -// after Sep 2020 expression: request.time < -// timestamp('2020-10-01T00:00:00.000Z') etag: BwWWja0YfJA= version: 3 -// For a description of IAM and its features, see the IAM documentation -// (https://cloud.google.com/iam/docs/). -type GoogleIamV1Policy struct { - // AuditConfigs: Specifies cloud audit logging configuration for this - // policy. - AuditConfigs []*GoogleIamV1AuditConfig `json:"auditConfigs,omitempty"` + // Labels: KRM-style labels for the resource. + Labels map[string]string `json:"labels,omitempty"` - // Bindings: Associates a list of `members`, or principals, with a - // `role`. Optionally, may specify a `condition` that determines how and - // when the `bindings` are applied. Each of the `bindings` must contain - // at least one principal. The `bindings` in a `Policy` can refer to up - // to 1,500 principals; up to 250 of these principals can be Google - // groups. Each occurrence of a principal counts towards these limits. - // For example, if the `bindings` grant 50 different roles to - // `user:alice@example.com`, and not to any other principal, then you - // can add another 1,450 principals to the `bindings` in the `Policy`. - Bindings []*GoogleIamV1Binding `json:"bindings,omitempty"` + // Revision: The unique name for the revision. If this field is omitted, + // it will be automatically generated based on the Service name. + Revision string `json:"revision,omitempty"` - // Etag: `etag` is used for optimistic concurrency control as a way to - // help prevent simultaneous updates of a policy from overwriting each - // other. It is strongly suggested that systems make use of the `etag` - // in the read-modify-write cycle to perform policy updates in order to - // avoid race conditions: An `etag` is returned in the response to - // `getIamPolicy`, and systems are expected to put that etag in the - // request to `setIamPolicy` to ensure that their change will be applied - // to the same version of the policy. **Important:** If you use IAM - // Conditions, you must include the `etag` field whenever you call - // `setIamPolicy`. If you omit this field, then IAM allows you to - // overwrite a version `3` policy with a version `1` policy, and all of - // the conditions in the version `3` policy are lost. - Etag string `json:"etag,omitempty"` + // Scaling: Scaling settings for this Revision. + Scaling *GoogleCloudRunV2RevisionScaling `json:"scaling,omitempty"` - // Version: Specifies the format of the policy. Valid values are `0`, - // `1`, and `3`. Requests that specify an invalid value are rejected. - // Any operation that affects conditional role bindings must specify - // version `3`. This requirement applies to the following operations: * - // Getting a policy that includes a conditional role binding * Adding a - // conditional role binding to a policy * Changing a conditional role - // binding in a policy * Removing any role binding, with or without a - // condition, from a policy that includes conditions **Important:** If - // you use IAM Conditions, you must include the `etag` field whenever - // you call `setIamPolicy`. If you omit this field, then IAM allows you - // to overwrite a version `3` policy with a version `1` policy, and all - // of the conditions in the version `3` policy are lost. If a policy - // does not include any conditions, operations on that policy may - // specify any valid version or leave the field unset. To learn which - // resources support conditions in their IAM policies, see the IAM - // documentation - // (https://cloud.google.com/iam/help/conditions/resource-policies). - Version int64 `json:"version,omitempty"` + // ServiceAccount: Email address of the IAM service account associated + // with the revision of the service. The service account represents the + // identity of the running revision, and determines what permissions the + // revision has. If not provided, the revision will use the project's + // default service account. + ServiceAccount string `json:"serviceAccount,omitempty"` - // ServerResponse contains the HTTP response code and headers from the - // server. - googleapi.ServerResponse `json:"-"` + // Timeout: Max allowed time for an instance to respond to a request. + Timeout string `json:"timeout,omitempty"` - // ForceSendFields is a list of field names (e.g. "AuditConfigs") to + // Volumes: A list of Volumes to make available to containers. + Volumes []*GoogleCloudRunV2Volume `json:"volumes,omitempty"` + + // VpcAccess: VPC Access configuration to use for this Revision. For + // more information, visit + // https://cloud.google.com/run/docs/configuring/connecting-vpc. + VpcAccess *GoogleCloudRunV2VpcAccess `json:"vpcAccess,omitempty"` + + // ForceSendFields is a list of field names (e.g. "Annotations") 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 @@ -1884,7 +1653,7 @@ type GoogleIamV1Policy struct { // This may be used to include empty fields in Patch requests. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "AuditConfigs") to include + // NullFields is a list of field names (e.g. "Annotations") 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 @@ -1893,28 +1662,24 @@ type GoogleIamV1Policy struct { NullFields []string `json:"-"` } -func (s *GoogleIamV1Policy) MarshalJSON() ([]byte, error) { - type NoMethod GoogleIamV1Policy +func (s *GoogleCloudRunV2RevisionTemplate) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudRunV2RevisionTemplate raw := NoMethod(*s) return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } -// GoogleIamV1SetIamPolicyRequest: Request message for `SetIamPolicy` -// method. -type GoogleIamV1SetIamPolicyRequest struct { - // Policy: REQUIRED: The complete policy to be applied to the - // `resource`. The size of the policy is limited to a few 10s of KB. An - // empty policy is a valid policy but certain Google Cloud services - // (such as Projects) might reject them. - Policy *GoogleIamV1Policy `json:"policy,omitempty"` +// GoogleCloudRunV2RunJobRequest: Request message to create a new +// Execution of a Job. +type GoogleCloudRunV2RunJobRequest struct { + // Etag: A system-generated fingerprint for this version of the + // resource. May be used to detect modification conflict during updates. + Etag string `json:"etag,omitempty"` - // UpdateMask: OPTIONAL: A FieldMask specifying which fields of the - // policy to modify. Only the fields in the mask will be modified. If no - // mask is provided, the following default mask is used: `paths: - // "bindings, etag" - UpdateMask string `json:"updateMask,omitempty"` + // ValidateOnly: Indicates that the request should be validated without + // actually deleting any resources. + ValidateOnly bool `json:"validateOnly,omitempty"` - // ForceSendFields is a list of field names (e.g. "Policy") to + // ForceSendFields is a list of field names (e.g. "Etag") 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 @@ -1922,7 +1687,7 @@ type GoogleIamV1SetIamPolicyRequest struct { // This may be used to include empty fields in Patch requests. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "Policy") to include in API + // NullFields is a list of field names (e.g. "Etag") 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 @@ -1931,22 +1696,26 @@ type GoogleIamV1SetIamPolicyRequest struct { NullFields []string `json:"-"` } -func (s *GoogleIamV1SetIamPolicyRequest) MarshalJSON() ([]byte, error) { - type NoMethod GoogleIamV1SetIamPolicyRequest +func (s *GoogleCloudRunV2RunJobRequest) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudRunV2RunJobRequest raw := NoMethod(*s) return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } -// GoogleIamV1TestIamPermissionsRequest: Request message for -// `TestIamPermissions` method. -type GoogleIamV1TestIamPermissionsRequest struct { - // Permissions: The set of permissions to check for the `resource`. - // Permissions with wildcards (such as `*` or `storage.*`) are not - // allowed. For more information see IAM Overview - // (https://cloud.google.com/iam/docs/overview#permissions). - Permissions []string `json:"permissions,omitempty"` +// GoogleCloudRunV2SecretKeySelector: SecretEnvVarSource represents a +// source for the value of an EnvVar. +type GoogleCloudRunV2SecretKeySelector struct { + // Secret: Required. The name of the secret in Cloud Secret Manager. + // Format: {secret_name} if the secret is in the same project. + // projects/{project}/secrets/{secret_name} if the secret is in a + // different project. + Secret string `json:"secret,omitempty"` - // ForceSendFields is a list of field names (e.g. "Permissions") to + // Version: The Cloud Secret Manager secret version. Can be 'latest' for + // the latest value or an integer for a specific version. + Version string `json:"version,omitempty"` + + // ForceSendFields is a list of field names (e.g. "Secret") 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 @@ -1954,33 +1723,55 @@ type GoogleIamV1TestIamPermissionsRequest struct { // This may be used to include empty fields in Patch requests. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "Permissions") 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 + // NullFields is a list of field names (e.g. "Secret") 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 *GoogleIamV1TestIamPermissionsRequest) MarshalJSON() ([]byte, error) { - type NoMethod GoogleIamV1TestIamPermissionsRequest +func (s *GoogleCloudRunV2SecretKeySelector) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudRunV2SecretKeySelector raw := NoMethod(*s) return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } -// GoogleIamV1TestIamPermissionsResponse: Response message for -// `TestIamPermissions` method. -type GoogleIamV1TestIamPermissionsResponse struct { - // Permissions: A subset of `TestPermissionsRequest.permissions` that - // the caller is allowed. - Permissions []string `json:"permissions,omitempty"` +// GoogleCloudRunV2SecretVolumeSource: The secret's value will be +// presented as the content of a file whose name is defined in the item +// path. If no items are defined, the name of the file is the secret. +type GoogleCloudRunV2SecretVolumeSource struct { + // DefaultMode: Integer representation of mode bits to use on created + // files by default. Must be a value between 0000 and 0777 (octal), + // defaulting to 0644. Directories within the path are not affected by + // this setting. Notes * Internally, a umask of 0222 will be applied to + // any non-zero value. * This is an integer representation of the mode + // bits. So, the octal integer value should look exactly as the chmod + // numeric notation with a leading zero. Some examples: for chmod 777 + // (a=rwx), set to 0777 (octal) or 511 (base-10). For chmod 640 + // (u=rw,g=r), set to 0640 (octal) or 416 (base-10). For chmod 755 + // (u=rwx,g=rx,o=rx), set to 0755 (octal) or 493 (base-10). * This might + // be in conflict with other options that affect the file mode, like + // fsGroup, and the result can be other mode bits set. This might be in + // conflict with other options that affect the file mode, like fsGroup, + // and as a result, other mode bits could be set. + DefaultMode int64 `json:"defaultMode,omitempty"` - // ServerResponse contains the HTTP response code and headers from the - // server. - googleapi.ServerResponse `json:"-"` + // Items: If unspecified, the volume will expose a file whose name is + // the secret, relative to VolumeMount.mount_path. If specified, the key + // will be used as the version to fetch from Cloud Secret Manager and + // the path will be the name of the file exposed in the volume. When + // items are defined, they must specify a path and a version. + Items []*GoogleCloudRunV2VersionToPath `json:"items,omitempty"` - // ForceSendFields is a list of field names (e.g. "Permissions") to + // Secret: Required. The name of the secret in Cloud Secret Manager. + // Format: {secret} if the secret is in the same project. + // projects/{project}/secrets/{secret} if the secret is in a different + // project. + Secret string `json:"secret,omitempty"` + + // ForceSendFields is a list of field names (e.g. "DefaultMode") 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 @@ -1988,7 +1779,7 @@ type GoogleIamV1TestIamPermissionsResponse struct { // This may be used to include empty fields in Patch requests. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "Permissions") to include + // NullFields is a list of field names (e.g. "DefaultMode") 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 @@ -1997,27 +1788,217 @@ type GoogleIamV1TestIamPermissionsResponse struct { NullFields []string `json:"-"` } -func (s *GoogleIamV1TestIamPermissionsResponse) MarshalJSON() ([]byte, error) { - type NoMethod GoogleIamV1TestIamPermissionsResponse +func (s *GoogleCloudRunV2SecretVolumeSource) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudRunV2SecretVolumeSource raw := NoMethod(*s) return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } -// GoogleLongrunningListOperationsResponse: The response message for -// Operations.ListOperations. -type GoogleLongrunningListOperationsResponse struct { - // NextPageToken: The standard List next-page token. - NextPageToken string `json:"nextPageToken,omitempty"` +// GoogleCloudRunV2Service: Service acts as a top-level container that +// manages a set of configurations and revision templates which +// implement a network service. Service exists to provide a singular +// abstraction which can be access controlled, reasoned about, and which +// encapsulates software lifecycle decisions such as rollout policy and +// team resource ownership. +type GoogleCloudRunV2Service struct { + // Annotations: Unstructured key value map that may be set by external + // tools to store and arbitrary metadata. They are not queryable and + // should be preserved when modifying objects. Cloud Run will populate + // some annotations using 'run.googleapis.com' or 'serving.knative.dev' + // namespaces. This field follows Kubernetes annotations' namespacing, + // limits, and rules. More info: + // https://kubernetes.io/docs/user-guide/annotations + Annotations map[string]string `json:"annotations,omitempty"` - // Operations: A list of operations that matches the specified filter in - // the request. - Operations []*GoogleLongrunningOperation `json:"operations,omitempty"` + // BinaryAuthorization: Settings for the Binary Authorization feature. + BinaryAuthorization *GoogleCloudRunV2BinaryAuthorization `json:"binaryAuthorization,omitempty"` + + // Client: Arbitrary identifier for the API client. + Client string `json:"client,omitempty"` + + // ClientVersion: Arbitrary version identifier for the API client. + ClientVersion string `json:"clientVersion,omitempty"` + + // Conditions: Output only. The Conditions of all other associated + // sub-resources. They contain additional diagnostics information in + // case the Service does not reach its Serving state. See comments in + // `reconciling` for additional information on reconciliation process in + // Cloud Run. + Conditions []*GoogleCloudRunV2Condition `json:"conditions,omitempty"` + + // CreateTime: Output only. The creation time. + CreateTime string `json:"createTime,omitempty"` + + // Creator: Output only. Email address of the authenticated creator. + Creator string `json:"creator,omitempty"` + + // DeleteTime: Output only. The deletion time. + DeleteTime string `json:"deleteTime,omitempty"` + + // Description: User-provided description of the Service. This field + // currently has a 512-character limit. + Description string `json:"description,omitempty"` + + // Etag: Output only. A system-generated fingerprint for this version of + // the resource. May be used to detect modification conflict during + // updates. + Etag string `json:"etag,omitempty"` + + // ExpireTime: Output only. For a deleted resource, the time after which + // it will be permamently deleted. + ExpireTime string `json:"expireTime,omitempty"` + + // Generation: Output only. A number that monotonically increases every + // time the user modifies the desired state. + Generation int64 `json:"generation,omitempty,string"` + + // Ingress: Provides the ingress settings for this Service. On output, + // returns the currently observed ingress settings, or + // INGRESS_TRAFFIC_UNSPECIFIED if no revision is active. + // + // Possible values: + // "INGRESS_TRAFFIC_UNSPECIFIED" - Unspecified + // "INGRESS_TRAFFIC_ALL" - All inbound traffic is allowed. + // "INGRESS_TRAFFIC_INTERNAL_ONLY" - Only internal traffic is allowed. + // "INGRESS_TRAFFIC_INTERNAL_LOAD_BALANCER" - Both internal and Google + // Cloud Load Balancer traffic is allowed. + Ingress string `json:"ingress,omitempty"` + + // Labels: Map of string keys and values that can be used to organize + // and categorize objects. User-provided labels are shared with Google's + // billing system, so they can be used to filter, or break down billing + // charges by team, component, environment, state, etc. For more + // information, visit + // https://cloud.google.com/resource-manager/docs/creating-managing-labels + // or https://cloud.google.com/run/docs/configuring/labels Cloud Run + // will populate some labels with 'run.googleapis.com' or + // 'serving.knative.dev' namespaces. Those labels are read-only, and + // user changes will not be preserved. + Labels map[string]string `json:"labels,omitempty"` + + // LastModifier: Output only. Email address of the last authenticated + // modifier. + LastModifier string `json:"lastModifier,omitempty"` + + // LatestCreatedRevision: Output only. Name of the last created + // revision. See comments in `reconciling` for additional information on + // reconciliation process in Cloud Run. + LatestCreatedRevision string `json:"latestCreatedRevision,omitempty"` + + // LatestReadyRevision: Output only. Name of the latest revision that is + // serving traffic. See comments in `reconciling` for additional + // information on reconciliation process in Cloud Run. + LatestReadyRevision string `json:"latestReadyRevision,omitempty"` + + // LaunchStage: The launch stage as defined by Google Cloud Platform + // Launch Stages (https://cloud.google.com/terms/launch-stages). Cloud + // Run supports `ALPHA`, `BETA`, and `GA`. If no value is specified, GA + // is assumed. + // + // Possible values: + // "LAUNCH_STAGE_UNSPECIFIED" - Do not use this default value. + // "UNIMPLEMENTED" - The feature is not yet implemented. Users can not + // use it. + // "PRELAUNCH" - Prelaunch features are hidden from users and are only + // visible internally. + // "EARLY_ACCESS" - Early Access features are limited to a closed + // group of testers. To use these features, you must sign up in advance + // and sign a Trusted Tester agreement (which includes confidentiality + // provisions). These features may be unstable, changed in + // backward-incompatible ways, and are not guaranteed to be released. + // "ALPHA" - Alpha is a limited availability test for releases before + // they are cleared for widespread use. By Alpha, all significant design + // issues are resolved and we are in the process of verifying + // functionality. Alpha customers need to apply for access, agree to + // applicable terms, and have their projects allowlisted. Alpha releases + // don't have to be feature complete, no SLAs are provided, and there + // are no technical support obligations, but they will be far enough + // along that customers can actually use them in test environments or + // for limited-use tests -- just like they would in normal production + // cases. + // "BETA" - Beta is the point at which we are ready to open a release + // for any customer to use. There are no SLA or technical support + // obligations in a Beta release. Products will be complete from a + // feature perspective, but may have some open outstanding issues. Beta + // releases are suitable for limited production use cases. + // "GA" - GA features are open to all developers and are considered + // stable and fully qualified for production use. + // "DEPRECATED" - Deprecated features are scheduled to be shut down + // and removed. For more information, see the "Deprecation Policy" + // section of our [Terms of Service](https://cloud.google.com/terms/) + // and the [Google Cloud Platform Subject to the Deprecation + // Policy](https://cloud.google.com/terms/deprecation) documentation. + LaunchStage string `json:"launchStage,omitempty"` + + // Name: The fully qualified name of this Service. In + // CreateServiceRequest, this field is ignored, and instead composed + // from CreateServiceRequest.parent and CreateServiceRequest.service_id. + // Format: projects/{project}/locations/{location}/services/{service_id} + Name string `json:"name,omitempty"` + + // ObservedGeneration: Output only. The generation of this Service + // currently serving traffic. See comments in `reconciling` for + // additional information on reconciliation process in Cloud Run. + ObservedGeneration int64 `json:"observedGeneration,omitempty,string"` + + // Reconciling: Output only. Returns true if the Service is currently + // being acted upon by the system to bring it into the desired state. + // When a new Service is created, or an existing one is updated, Cloud + // Run will asynchronously perform all necessary steps to bring the + // Service to the desired serving state. This process is called + // reconciliation. While reconciliation is in process, + // `observed_generation`, `latest_ready_revison`, `traffic_statuses`, + // and `uri` will have transient values that might mismatch the intended + // state: Once reconciliation is over (and this field is false), there + // are two possible outcomes: reconciliation succeeded and the serving + // state matches the Service, or there was an error, and reconciliation + // failed. This state can be found in `terminal_condition.state`. If + // reconciliation succeeded, the following fields will match: `traffic` + // and `traffic_statuses`, `observed_generation` and `generation`, + // `latest_ready_revision` and `latest_created_revision`. If + // reconciliation failed, `traffic_statuses`, `observed_generation`, and + // `latest_ready_revision` will have the state of the last serving + // revision, or empty for newly created Services. Additional information + // on the failure can be found in `terminal_condition` and `conditions`. + Reconciling bool `json:"reconciling,omitempty"` + + // Template: Required. The template used to create revisions for this + // Service. + Template *GoogleCloudRunV2RevisionTemplate `json:"template,omitempty"` + + // TerminalCondition: Output only. The Condition of this Service, + // containing its readiness status, and detailed error information in + // case it did not reach a serving state. See comments in `reconciling` + // for additional information on reconciliation process in Cloud Run. + TerminalCondition *GoogleCloudRunV2Condition `json:"terminalCondition,omitempty"` + + // Traffic: Specifies how to distribute traffic over a collection of + // Revisions belonging to the Service. If traffic is empty or not + // provided, defaults to 100% traffic to the latest `Ready` Revision. + Traffic []*GoogleCloudRunV2TrafficTarget `json:"traffic,omitempty"` + + // TrafficStatuses: Output only. Detailed status information for + // corresponding traffic targets. See comments in `reconciling` for + // additional information on reconciliation process in Cloud Run. + TrafficStatuses []*GoogleCloudRunV2TrafficTargetStatus `json:"trafficStatuses,omitempty"` + + // Uid: Output only. Server assigned unique identifier for the trigger. + // The value is a UUID4 string and guaranteed to remain unchanged until + // the resource is deleted. + Uid string `json:"uid,omitempty"` + + // UpdateTime: Output only. The last-modified time. + UpdateTime string `json:"updateTime,omitempty"` + + // Uri: Output only. The main URI in which this Service is serving + // traffic. + Uri string `json:"uri,omitempty"` // ServerResponse contains the HTTP response code and headers from the // server. googleapi.ServerResponse `json:"-"` - // ForceSendFields is a list of field names (e.g. "NextPageToken") to + // ForceSendFields is a list of field names (e.g. "Annotations") 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 @@ -2025,7 +2006,7 @@ type GoogleLongrunningListOperationsResponse struct { // This may be used to include empty fields in Patch requests. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "NextPageToken") to include + // NullFields is a list of field names (e.g. "Annotations") 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 @@ -2034,52 +2015,198 @@ type GoogleLongrunningListOperationsResponse struct { NullFields []string `json:"-"` } -func (s *GoogleLongrunningListOperationsResponse) MarshalJSON() ([]byte, error) { - type NoMethod GoogleLongrunningListOperationsResponse +func (s *GoogleCloudRunV2Service) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudRunV2Service raw := NoMethod(*s) return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } -// GoogleLongrunningOperation: This resource represents a long-running -// operation that is the result of a network API call. -type GoogleLongrunningOperation struct { - // Done: If the value is `false`, it means the operation is still in - // progress. If `true`, the operation is completed, and either `error` - // or `response` is available. - Done bool `json:"done,omitempty"` - - // Error: The error result of the operation in case of failure or - // cancellation. - Error *GoogleRpcStatus `json:"error,omitempty"` +// GoogleCloudRunV2Task: Task represents a single run of a container to +// completion. +type GoogleCloudRunV2Task struct { + // Annotations: KRM-style annotations for the resource. + Annotations map[string]string `json:"annotations,omitempty"` - // Metadata: Service-specific metadata associated with the operation. It - // typically contains progress information and common metadata such as - // create time. Some services might not provide such metadata. Any - // method that returns a long-running operation should document the - // metadata type, if any. - Metadata googleapi.RawMessage `json:"metadata,omitempty"` + // CompletionTime: Output only. Represents time when the Task was + // completed. It is not guaranteed to be set in happens-before order + // across separate operations. + CompletionTime string `json:"completionTime,omitempty"` - // Name: The server-assigned name, which is only unique within the same - // service that originally returns it. If you use the default HTTP - // mapping, the `name` should be a resource name ending with - // `operations/{unique_id}`. - Name string `json:"name,omitempty"` + // Conditions: Output only. The Condition of this Task, containing its + // readiness status, and detailed error information in case it did not + // reach the desired state. + Conditions []*GoogleCloudRunV2Condition `json:"conditions,omitempty"` - // Response: The normal response of the operation in case of success. If - // the original method returns no data on success, such as `Delete`, the - // response is `google.protobuf.Empty`. If the original method is - // standard `Get`/`Create`/`Update`, the response should be the - // resource. For other methods, the response should have the type - // `XxxResponse`, where `Xxx` is the original method name. For example, - // if the original method name is `TakeSnapshot()`, the inferred - // response type is `TakeSnapshotResponse`. - Response googleapi.RawMessage `json:"response,omitempty"` + // Containers: Holds the single container that defines the unit of + // execution for this task. + Containers []*GoogleCloudRunV2Container `json:"containers,omitempty"` - // ServerResponse contains the HTTP response code and headers from the - // server. - googleapi.ServerResponse `json:"-"` + // CreateTime: Output only. Represents time when the task was created by + // the job controller. It is not guaranteed to be set in happens-before + // order across separate operations. + CreateTime string `json:"createTime,omitempty"` - // ForceSendFields is a list of field names (e.g. "Done") to + // DeleteTime: Output only. For a deleted resource, the deletion time. + // It is only populated as a response to a Delete request. + DeleteTime string `json:"deleteTime,omitempty"` + + // EncryptionKey: Output only. A reference to a customer managed + // encryption key (CMEK) to use to encrypt this container image. For + // more information, go to + // https://cloud.google.com/run/docs/securing/using-cmek + EncryptionKey string `json:"encryptionKey,omitempty"` + + // Etag: Output only. A system-generated fingerprint for this version of + // the resource. May be used to detect modification conflict during + // updates. + Etag string `json:"etag,omitempty"` + + // Execution: Output only. The name of the parent Execution. + Execution string `json:"execution,omitempty"` + + // ExecutionEnvironment: The execution environment being used to host + // this Task. + // + // Possible values: + // "EXECUTION_ENVIRONMENT_UNSPECIFIED" - Unspecified + // "EXECUTION_ENVIRONMENT_GEN1" - Uses the First Generation + // environment. + // "EXECUTION_ENVIRONMENT_GEN2" - Uses Second Generation environment. + ExecutionEnvironment string `json:"executionEnvironment,omitempty"` + + // ExpireTime: Output only. For a deleted resource, the time after which + // it will be permamently deleted. It is only populated as a response to + // a Delete request. + ExpireTime string `json:"expireTime,omitempty"` + + // Generation: Output only. A number that monotonically increases every + // time the user modifies the desired state. + Generation int64 `json:"generation,omitempty,string"` + + // Index: Output only. Index of the Task, unique per execution, and + // beginning at 0. + Index int64 `json:"index,omitempty"` + + // Job: Output only. The name of the parent Job. + Job string `json:"job,omitempty"` + + // Labels: KRM-style labels for the resource. User-provided labels are + // shared with Google's billing system, so they can be used to filter, + // or break down billing charges by team, component, environment, state, + // etc. For more information, visit + // https://cloud.google.com/resource-manager/docs/creating-managing-labels + // or https://cloud.google.com/run/docs/configuring/labels Cloud Run + // will populate some labels with 'run.googleapis.com' or + // 'serving.knative.dev' namespaces. Those labels are read-only, and + // user changes will not be preserved. + Labels map[string]string `json:"labels,omitempty"` + + // LastAttemptResult: Output only. Result of the last attempt of this + // Task. + LastAttemptResult *GoogleCloudRunV2TaskAttemptResult `json:"lastAttemptResult,omitempty"` + + // LaunchStage: Set the launch stage to a preview stage on write to + // allow use of preview features in that stage. On read, describes + // whether the resource uses preview features. Launch Stages are defined + // at Google Cloud Platform Launch Stages + // (https://cloud.google.com/terms/launch-stages). + // + // Possible values: + // "LAUNCH_STAGE_UNSPECIFIED" - Do not use this default value. + // "UNIMPLEMENTED" - The feature is not yet implemented. Users can not + // use it. + // "PRELAUNCH" - Prelaunch features are hidden from users and are only + // visible internally. + // "EARLY_ACCESS" - Early Access features are limited to a closed + // group of testers. To use these features, you must sign up in advance + // and sign a Trusted Tester agreement (which includes confidentiality + // provisions). These features may be unstable, changed in + // backward-incompatible ways, and are not guaranteed to be released. + // "ALPHA" - Alpha is a limited availability test for releases before + // they are cleared for widespread use. By Alpha, all significant design + // issues are resolved and we are in the process of verifying + // functionality. Alpha customers need to apply for access, agree to + // applicable terms, and have their projects allowlisted. Alpha releases + // don't have to be feature complete, no SLAs are provided, and there + // are no technical support obligations, but they will be far enough + // along that customers can actually use them in test environments or + // for limited-use tests -- just like they would in normal production + // cases. + // "BETA" - Beta is the point at which we are ready to open a release + // for any customer to use. There are no SLA or technical support + // obligations in a Beta release. Products will be complete from a + // feature perspective, but may have some open outstanding issues. Beta + // releases are suitable for limited production use cases. + // "GA" - GA features are open to all developers and are considered + // stable and fully qualified for production use. + // "DEPRECATED" - Deprecated features are scheduled to be shut down + // and removed. For more information, see the "Deprecation Policy" + // section of our [Terms of Service](https://cloud.google.com/terms/) + // and the [Google Cloud Platform Subject to the Deprecation + // Policy](https://cloud.google.com/terms/deprecation) documentation. + LaunchStage string `json:"launchStage,omitempty"` + + // MaxRetries: Number of retries allowed per Task, before marking this + // Task failed. + MaxRetries int64 `json:"maxRetries,omitempty"` + + // Name: Output only. The unique name of this Task. + Name string `json:"name,omitempty"` + + // ObservedGeneration: Output only. The generation of this Task. See + // comments in `Job.reconciling` for additional information on + // reconciliation process in Cloud Run. + ObservedGeneration int64 `json:"observedGeneration,omitempty,string"` + + // Reconciling: Output only. Indicates whether the resource's + // reconciliation is still in progress. See comments in + // `Job.reconciling` for additional information on reconciliation + // process in Cloud Run. + Reconciling bool `json:"reconciling,omitempty"` + + // Retried: Output only. The number of times this Task was retried. + // Tasks are retried when they fail up to the maxRetries limit. + Retried int64 `json:"retried,omitempty"` + + // ServiceAccount: Email address of the IAM service account associated + // with the Task of a Job. The service account represents the identity + // of the running task, and determines what permissions the task has. If + // not provided, the task will use the project's default service + // account. + ServiceAccount string `json:"serviceAccount,omitempty"` + + // StartTime: Output only. Represents time when the task started to run. + // It is not guaranteed to be set in happens-before order across + // separate operations. + StartTime string `json:"startTime,omitempty"` + + // Timeout: Max allowed time duration the Task may be active before the + // system will actively try to mark it failed and kill associated + // containers. This applies per attempt of a task, meaning each retry + // can run for the full timeout. + Timeout string `json:"timeout,omitempty"` + + // Uid: Output only. Server assigned unique identifier for the Task. The + // value is a UUID4 string and guaranteed to remain unchanged until the + // resource is deleted. + Uid string `json:"uid,omitempty"` + + // UpdateTime: Output only. The last-modified time. + UpdateTime string `json:"updateTime,omitempty"` + + // Volumes: A list of Volumes to make available to containers. + Volumes []*GoogleCloudRunV2Volume `json:"volumes,omitempty"` + + // VpcAccess: Output only. VPC Access configuration to use for this + // Task. For more information, visit + // https://cloud.google.com/run/docs/configuring/connecting-vpc. + VpcAccess *GoogleCloudRunV2VpcAccess `json:"vpcAccess,omitempty"` + + // ServerResponse contains the HTTP response code and headers from the + // server. + googleapi.ServerResponse `json:"-"` + + // ForceSendFields is a list of field names (e.g. "Annotations") 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 @@ -2087,54 +2214,33 @@ type GoogleLongrunningOperation struct { // This may be used to include empty fields in Patch requests. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "Done") to include in API - // requests with the JSON null value. By default, fields with empty - // values are omitted from API requests. However, any field with an - // empty value appearing in NullFields will be sent to the server as + // NullFields is a list of field names (e.g. "Annotations") 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 *GoogleLongrunningOperation) MarshalJSON() ([]byte, error) { - type NoMethod GoogleLongrunningOperation +func (s *GoogleCloudRunV2Task) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudRunV2Task raw := NoMethod(*s) return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } -// GoogleProtobufEmpty: A generic empty message that you can re-use to -// avoid defining duplicated empty messages in your APIs. A typical -// example is to use it as the request or the response type of an API -// method. For instance: service Foo { rpc Bar(google.protobuf.Empty) -// returns (google.protobuf.Empty); } -type GoogleProtobufEmpty struct { - // ServerResponse contains the HTTP response code and headers from the - // server. - googleapi.ServerResponse `json:"-"` -} - -// GoogleRpcStatus: The `Status` type defines a logical error model that -// is suitable for different programming environments, including REST -// APIs and RPC APIs. It is used by gRPC (https://github.com/grpc). Each -// `Status` message contains three pieces of data: error code, error -// message, and error details. You can find out more about this error -// model and how to work with it in the API Design Guide -// (https://cloud.google.com/apis/design/errors). -type GoogleRpcStatus struct { - // Code: The status code, which should be an enum value of - // google.rpc.Code. - Code int64 `json:"code,omitempty"` - - // Details: A list of messages that carry the error details. There is a - // common set of message types for APIs to use. - Details []googleapi.RawMessage `json:"details,omitempty"` +// GoogleCloudRunV2TaskAttemptResult: Result of a task attempt. +type GoogleCloudRunV2TaskAttemptResult struct { + // ExitCode: Output only. The exit code of this attempt. This may be + // unset if the container was unable to exit cleanly with a code due to + // some other failure. See status field for possible failure details. + ExitCode int64 `json:"exitCode,omitempty"` - // Message: A developer-facing error message, which should be in - // English. Any user-facing error message should be localized and sent - // in the google.rpc.Status.details field, or localized by the client. - Message string `json:"message,omitempty"` + // Status: Output only. The status of this attempt. If the status code + // is OK, then the attempt succeeded. + Status *GoogleRpcStatus `json:"status,omitempty"` - // ForceSendFields is a list of field names (e.g. "Code") to + // ForceSendFields is a list of field names (e.g. "ExitCode") 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 @@ -2142,8 +2248,8 @@ type GoogleRpcStatus struct { // This may be used to include empty fields in Patch requests. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "Code") to include in API - // requests with the JSON null value. By default, fields with empty + // NullFields is a list of field names (e.g. "ExitCode") 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. @@ -2151,50 +2257,60 @@ type GoogleRpcStatus struct { NullFields []string `json:"-"` } -func (s *GoogleRpcStatus) MarshalJSON() ([]byte, error) { - type NoMethod GoogleRpcStatus +func (s *GoogleCloudRunV2TaskAttemptResult) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudRunV2TaskAttemptResult raw := NoMethod(*s) return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } -// GoogleTypeExpr: Represents a textual expression in the Common -// Expression Language (CEL) syntax. CEL is a C-like expression -// language. The syntax and semantics of CEL are documented at -// https://github.com/google/cel-spec. Example (Comparison): title: -// "Summary size limit" description: "Determines if a summary is less -// than 100 chars" expression: "document.summary.size() < 100" Example -// (Equality): title: "Requestor is owner" description: "Determines if -// requestor is the document owner" expression: "document.owner == -// request.auth.claims.email" Example (Logic): title: "Public documents" -// description: "Determine whether the document should be publicly -// visible" expression: "document.type != 'private' && document.type != -// 'internal'" Example (Data Manipulation): title: "Notification string" -// description: "Create a notification string with a timestamp." -// expression: "'New message received at ' + -// string(document.create_time)" The exact variables and functions that -// may be referenced within an expression are determined by the service -// that evaluates it. See the service documentation for additional -// information. -type GoogleTypeExpr struct { - // Description: Optional. Description of the expression. This is a - // longer text which describes the expression, e.g. when hovered over it - // in a UI. - Description string `json:"description,omitempty"` +// GoogleCloudRunV2TaskTemplate: TaskTemplate describes the data a task +// should have when created from a template. +type GoogleCloudRunV2TaskTemplate struct { + // Containers: Holds the single container that defines the unit of + // execution for this task. + Containers []*GoogleCloudRunV2Container `json:"containers,omitempty"` - // Expression: Textual representation of an expression in Common - // Expression Language syntax. - Expression string `json:"expression,omitempty"` + // EncryptionKey: A reference to a customer managed encryption key + // (CMEK) to use to encrypt this container image. For more information, + // go to https://cloud.google.com/run/docs/securing/using-cmek + EncryptionKey string `json:"encryptionKey,omitempty"` - // Location: Optional. String indicating the location of the expression - // for error reporting, e.g. a file name and a position in the file. - Location string `json:"location,omitempty"` + // ExecutionEnvironment: The execution environment being used to host + // this Task. + // + // Possible values: + // "EXECUTION_ENVIRONMENT_UNSPECIFIED" - Unspecified + // "EXECUTION_ENVIRONMENT_GEN1" - Uses the First Generation + // environment. + // "EXECUTION_ENVIRONMENT_GEN2" - Uses Second Generation environment. + ExecutionEnvironment string `json:"executionEnvironment,omitempty"` - // Title: Optional. Title for the expression, i.e. a short string - // describing its purpose. This can be used e.g. in UIs which allow to - // enter the expression. - Title string `json:"title,omitempty"` + // MaxRetries: Number of retries allowed per Task, before marking this + // Task failed. + MaxRetries int64 `json:"maxRetries,omitempty"` - // ForceSendFields is a list of field names (e.g. "Description") to + // ServiceAccount: Email address of the IAM service account associated + // with the Task of a Job. The service account represents the identity + // of the running task, and determines what permissions the task has. If + // not provided, the task will use the project's default service + // account. + ServiceAccount string `json:"serviceAccount,omitempty"` + + // Timeout: Max allowed time duration the Task may be active before the + // system will actively try to mark it failed and kill associated + // containers. This applies per attempt of a task, meaning each retry + // can run for the full timeout. + Timeout string `json:"timeout,omitempty"` + + // Volumes: A list of Volumes to make available to containers. + Volumes []*GoogleCloudRunV2Volume `json:"volumes,omitempty"` + + // VpcAccess: VPC Access configuration to use for this Task. For more + // information, visit + // https://cloud.google.com/run/docs/configuring/connecting-vpc. + VpcAccess *GoogleCloudRunV2VpcAccess `json:"vpcAccess,omitempty"` + + // ForceSendFields is a list of field names (e.g. "Containers") 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 @@ -2202,21 +2318,3251 @@ type GoogleTypeExpr struct { // 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 + // NullFields is a list of field names (e.g. "Containers") 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 *GoogleTypeExpr) MarshalJSON() ([]byte, error) { - type NoMethod GoogleTypeExpr +func (s *GoogleCloudRunV2TaskTemplate) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudRunV2TaskTemplate raw := NoMethod(*s) return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } +// GoogleCloudRunV2TrafficTarget: Holds a single traffic routing entry +// for the Service. Allocations can be done to a specific Revision name, +// or pointing to the latest Ready Revision. +type GoogleCloudRunV2TrafficTarget struct { + // Percent: Specifies percent of the traffic to this Revision. This + // defaults to zero if unspecified. + Percent int64 `json:"percent,omitempty"` + + // Revision: Revision to which to send this portion of traffic, if + // traffic allocation is by revision. + Revision string `json:"revision,omitempty"` + + // Tag: Indicates a string to be part of the URI to exclusively + // reference this target. + Tag string `json:"tag,omitempty"` + + // Type: The allocation type for this traffic target. + // + // Possible values: + // "TRAFFIC_TARGET_ALLOCATION_TYPE_UNSPECIFIED" - Unspecified instance + // allocation type. + // "TRAFFIC_TARGET_ALLOCATION_TYPE_LATEST" - Allocates instances to + // the Service's latest ready Revision. + // "TRAFFIC_TARGET_ALLOCATION_TYPE_REVISION" - Allocates instances to + // a Revision by name. + Type string `json:"type,omitempty"` + + // ForceSendFields is a list of field names (e.g. "Percent") 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. "Percent") 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 *GoogleCloudRunV2TrafficTarget) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudRunV2TrafficTarget + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + +// GoogleCloudRunV2TrafficTargetStatus: Represents the observed state of +// a single `TrafficTarget` entry. +type GoogleCloudRunV2TrafficTargetStatus struct { + // Percent: Specifies percent of the traffic to this Revision. + Percent int64 `json:"percent,omitempty"` + + // Revision: Revision to which this traffic is sent. + Revision string `json:"revision,omitempty"` + + // Tag: Indicates the string used in the URI to exclusively reference + // this target. + Tag string `json:"tag,omitempty"` + + // Type: The allocation type for this traffic target. + // + // Possible values: + // "TRAFFIC_TARGET_ALLOCATION_TYPE_UNSPECIFIED" - Unspecified instance + // allocation type. + // "TRAFFIC_TARGET_ALLOCATION_TYPE_LATEST" - Allocates instances to + // the Service's latest ready Revision. + // "TRAFFIC_TARGET_ALLOCATION_TYPE_REVISION" - Allocates instances to + // a Revision by name. + Type string `json:"type,omitempty"` + + // Uri: Displays the target URI. + Uri string `json:"uri,omitempty"` + + // ForceSendFields is a list of field names (e.g. "Percent") 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. "Percent") 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 *GoogleCloudRunV2TrafficTargetStatus) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudRunV2TrafficTargetStatus + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + +// GoogleCloudRunV2VersionToPath: VersionToPath maps a specific version +// of a secret to a relative file to mount to, relative to VolumeMount's +// mount_path. +type GoogleCloudRunV2VersionToPath struct { + // Mode: Integer octal mode bits to use on this file, must be a value + // between 01 and 0777 (octal). If 0 or not set, the Volume's default + // mode will be used. Notes * Internally, a umask of 0222 will be + // applied to any non-zero value. * This is an integer representation of + // the mode bits. So, the octal integer value should look exactly as the + // chmod numeric notation with a leading zero. Some examples: for chmod + // 777 (a=rwx), set to 0777 (octal) or 511 (base-10). For chmod 640 + // (u=rw,g=r), set to 0640 (octal) or 416 (base-10). For chmod 755 + // (u=rwx,g=rx,o=rx), set to 0755 (octal) or 493 (base-10). * This might + // be in conflict with other options that affect the file mode, like + // fsGroup, and the result can be other mode bits set. + Mode int64 `json:"mode,omitempty"` + + // Path: Required. The relative path of the secret in the container. + Path string `json:"path,omitempty"` + + // Version: The Cloud Secret Manager secret version. Can be 'latest' for + // the latest value or an integer for a specific version. + Version string `json:"version,omitempty"` + + // ForceSendFields is a list of field names (e.g. "Mode") 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. "Mode") 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 *GoogleCloudRunV2VersionToPath) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudRunV2VersionToPath + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + +// GoogleCloudRunV2Volume: Volume represents a named volume in a +// container. +type GoogleCloudRunV2Volume struct { + // CloudSqlInstance: For Cloud SQL volumes, contains the specific + // instances that should be mounted. Visit + // https://cloud.google.com/sql/docs/mysql/connect-run for more + // information on how to connect Cloud SQL and Cloud Run. + CloudSqlInstance *GoogleCloudRunV2CloudSqlInstance `json:"cloudSqlInstance,omitempty"` + + // Name: Required. Volume's name. + Name string `json:"name,omitempty"` + + // Secret: Secret represents a secret that should populate this volume. + // More info: https://kubernetes.io/docs/concepts/storage/volumes#secret + Secret *GoogleCloudRunV2SecretVolumeSource `json:"secret,omitempty"` + + // ForceSendFields is a list of field names (e.g. "CloudSqlInstance") 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. "CloudSqlInstance") 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 *GoogleCloudRunV2Volume) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudRunV2Volume + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + +// GoogleCloudRunV2VolumeMount: VolumeMount describes a mounting of a +// Volume within a container. +type GoogleCloudRunV2VolumeMount struct { + // MountPath: Required. Path within the container at which the volume + // should be mounted. Must not contain ':'. For Cloud SQL volumes, it + // can be left empty, or must otherwise be `/cloudsql`. All instances + // defined in the Volume will be available as `/cloudsql/[instance]`. + // For more information on Cloud SQL volumes, visit + // https://cloud.google.com/sql/docs/mysql/connect-run + MountPath string `json:"mountPath,omitempty"` + + // Name: Required. This must match the Name of a Volume. + Name string `json:"name,omitempty"` + + // ForceSendFields is a list of field names (e.g. "MountPath") 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. "MountPath") 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 *GoogleCloudRunV2VolumeMount) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudRunV2VolumeMount + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + +// GoogleCloudRunV2VpcAccess: VPC Access settings. For more information +// on creating a VPC Connector, visit +// https://cloud.google.com/vpc/docs/configure-serverless-vpc-access For +// information on how to configure Cloud Run with an existing VPC +// Connector, visit +// https://cloud.google.com/run/docs/configuring/connecting-vpc +type GoogleCloudRunV2VpcAccess struct { + // Connector: VPC Access connector name. Format: + // projects/{project}/locations/{location}/connectors/{connector} + Connector string `json:"connector,omitempty"` + + // Egress: Traffic VPC egress settings. + // + // Possible values: + // "VPC_EGRESS_UNSPECIFIED" - Unspecified + // "ALL_TRAFFIC" - All outbound traffic is routed through the VPC + // connector. + // "PRIVATE_RANGES_ONLY" - Only private IP ranges are routed through + // the VPC connector. + Egress string `json:"egress,omitempty"` + + // ForceSendFields is a list of field names (e.g. "Connector") 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. "Connector") 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 *GoogleCloudRunV2VpcAccess) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudRunV2VpcAccess + 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 +// 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. +type GoogleIamV1AuditConfig struct { + // AuditLogConfigs: The configuration for logging of each type of + // permission. + AuditLogConfigs []*GoogleIamV1AuditLogConfig `json:"auditLogConfigs,omitempty"` + + // Service: Specifies a service that will be enabled for audit logging. + // For example, `storage.googleapis.com`, `cloudsql.googleapis.com`. + // `allServices` is a special value that covers all services. + Service string `json:"service,omitempty"` + + // ForceSendFields is a list of field names (e.g. "AuditLogConfigs") 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. "AuditLogConfigs") 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 *GoogleIamV1AuditConfig) MarshalJSON() ([]byte, error) { + type NoMethod GoogleIamV1AuditConfig + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + +// GoogleIamV1AuditLogConfig: Provides the configuration for logging a +// type of permissions. Example: { "audit_log_configs": [ { "log_type": +// "DATA_READ", "exempted_members": [ "user:jose@example.com" ] }, { +// "log_type": "DATA_WRITE" } ] } This enables 'DATA_READ' and +// 'DATA_WRITE' logging, while exempting jose@example.com from DATA_READ +// logging. +type GoogleIamV1AuditLogConfig struct { + // ExemptedMembers: Specifies the identities that do not cause logging + // for this type of permission. Follows the same format of + // Binding.members. + ExemptedMembers []string `json:"exemptedMembers,omitempty"` + + // LogType: The log type that this config enables. + // + // Possible values: + // "LOG_TYPE_UNSPECIFIED" - Default case. Should never be this. + // "ADMIN_READ" - Admin reads. Example: CloudIAM getIamPolicy + // "DATA_WRITE" - Data writes. Example: CloudSQL Users create + // "DATA_READ" - Data reads. Example: CloudSQL Users list + LogType string `json:"logType,omitempty"` + + // ForceSendFields is a list of field names (e.g. "ExemptedMembers") 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. "ExemptedMembers") 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 *GoogleIamV1AuditLogConfig) MarshalJSON() ([]byte, error) { + type NoMethod GoogleIamV1AuditLogConfig + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + +// GoogleIamV1Binding: Associates `members`, or principals, with a +// `role`. +type GoogleIamV1Binding struct { + // Condition: The condition that is associated with this binding. If the + // condition evaluates to `true`, then this binding applies to the + // current request. If the condition evaluates to `false`, then this + // binding does not apply to the current request. However, a different + // role binding might grant the same role to one or more of the + // principals in this binding. To learn which resources support + // conditions in their IAM policies, see the IAM documentation + // (https://cloud.google.com/iam/help/conditions/resource-policies). + Condition *GoogleTypeExpr `json:"condition,omitempty"` + + // Members: Specifies the principals requesting access for a Google + // Cloud resource. `members` can have the following values: * + // `allUsers`: A special identifier that represents anyone who is on the + // internet; with or without a Google account. * + // `allAuthenticatedUsers`: A special identifier that represents anyone + // who is authenticated with a Google account or a service account. * + // `user:{emailid}`: An email address that represents a specific Google + // account. For example, `alice@example.com` . * + // `serviceAccount:{emailid}`: An email address that represents a + // service account. For example, + // `my-other-app@appspot.gserviceaccount.com`. * `group:{emailid}`: An + // email address that represents a Google group. For example, + // `admins@example.com`. * `deleted:user:{emailid}?uid={uniqueid}`: An + // email address (plus unique identifier) representing a user that has + // been recently deleted. For example, + // `alice@example.com?uid=123456789012345678901`. If the user is + // recovered, this value reverts to `user:{emailid}` and the recovered + // user retains the role in the binding. * + // `deleted:serviceAccount:{emailid}?uid={uniqueid}`: An email address + // (plus unique identifier) representing a service account that has been + // recently deleted. For example, + // `my-other-app@appspot.gserviceaccount.com?uid=123456789012345678901`. + // If the service account is undeleted, this value reverts to + // `serviceAccount:{emailid}` and the undeleted service account retains + // the role in the binding. * `deleted:group:{emailid}?uid={uniqueid}`: + // An email address (plus unique identifier) representing a Google group + // that has been recently deleted. For example, + // `admins@example.com?uid=123456789012345678901`. If the group is + // recovered, this value reverts to `group:{emailid}` and the recovered + // group retains the role in the binding. * `domain:{domain}`: The G + // Suite domain (primary) that represents all the users of that domain. + // For example, `google.com` or `example.com`. + Members []string `json:"members,omitempty"` + + // Role: Role that is assigned to the list of `members`, or principals. + // For example, `roles/viewer`, `roles/editor`, or `roles/owner`. + Role string `json:"role,omitempty"` + + // ForceSendFields is a list of field names (e.g. "Condition") 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. "Condition") 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 *GoogleIamV1Binding) MarshalJSON() ([]byte, error) { + type NoMethod GoogleIamV1Binding + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + +// GoogleIamV1Policy: An Identity and Access Management (IAM) policy, +// which specifies access controls for Google Cloud resources. A +// `Policy` is a collection of `bindings`. A `binding` binds one or more +// `members`, or principals, to a single `role`. Principals can be user +// accounts, service accounts, Google groups, and domains (such as G +// Suite). A `role` is a named list of permissions; each `role` can be +// an IAM predefined role or a user-created custom role. For some types +// of Google Cloud resources, a `binding` can also specify a +// `condition`, which is a logical expression that allows access to a +// resource only if the expression evaluates to `true`. A condition can +// add constraints based on attributes of the request, the resource, or +// both. To learn which resources support conditions in their IAM +// policies, see the IAM documentation +// (https://cloud.google.com/iam/help/conditions/resource-policies). +// **JSON example:** { "bindings": [ { "role": +// "roles/resourcemanager.organizationAdmin", "members": [ +// "user:mike@example.com", "group:admins@example.com", +// "domain:google.com", +// "serviceAccount:my-project-id@appspot.gserviceaccount.com" ] }, { +// "role": "roles/resourcemanager.organizationViewer", "members": [ +// "user:eve@example.com" ], "condition": { "title": "expirable access", +// "description": "Does not grant access after Sep 2020", "expression": +// "request.time < timestamp('2020-10-01T00:00:00.000Z')", } } ], +// "etag": "BwWWja0YfJA=", "version": 3 } **YAML example:** bindings: - +// members: - user:mike@example.com - group:admins@example.com - +// domain:google.com - +// serviceAccount:my-project-id@appspot.gserviceaccount.com role: +// roles/resourcemanager.organizationAdmin - members: - +// user:eve@example.com role: roles/resourcemanager.organizationViewer +// condition: title: expirable access description: Does not grant access +// after Sep 2020 expression: request.time < +// timestamp('2020-10-01T00:00:00.000Z') etag: BwWWja0YfJA= version: 3 +// For a description of IAM and its features, see the IAM documentation +// (https://cloud.google.com/iam/docs/). +type GoogleIamV1Policy struct { + // AuditConfigs: Specifies cloud audit logging configuration for this + // policy. + AuditConfigs []*GoogleIamV1AuditConfig `json:"auditConfigs,omitempty"` + + // Bindings: Associates a list of `members`, or principals, with a + // `role`. Optionally, may specify a `condition` that determines how and + // when the `bindings` are applied. Each of the `bindings` must contain + // at least one principal. The `bindings` in a `Policy` can refer to up + // to 1,500 principals; up to 250 of these principals can be Google + // groups. Each occurrence of a principal counts towards these limits. + // For example, if the `bindings` grant 50 different roles to + // `user:alice@example.com`, and not to any other principal, then you + // can add another 1,450 principals to the `bindings` in the `Policy`. + Bindings []*GoogleIamV1Binding `json:"bindings,omitempty"` + + // Etag: `etag` is used for optimistic concurrency control as a way to + // help prevent simultaneous updates of a policy from overwriting each + // other. It is strongly suggested that systems make use of the `etag` + // in the read-modify-write cycle to perform policy updates in order to + // avoid race conditions: An `etag` is returned in the response to + // `getIamPolicy`, and systems are expected to put that etag in the + // request to `setIamPolicy` to ensure that their change will be applied + // to the same version of the policy. **Important:** If you use IAM + // Conditions, you must include the `etag` field whenever you call + // `setIamPolicy`. If you omit this field, then IAM allows you to + // overwrite a version `3` policy with a version `1` policy, and all of + // the conditions in the version `3` policy are lost. + Etag string `json:"etag,omitempty"` + + // Version: Specifies the format of the policy. Valid values are `0`, + // `1`, and `3`. Requests that specify an invalid value are rejected. + // Any operation that affects conditional role bindings must specify + // version `3`. This requirement applies to the following operations: * + // Getting a policy that includes a conditional role binding * Adding a + // conditional role binding to a policy * Changing a conditional role + // binding in a policy * Removing any role binding, with or without a + // condition, from a policy that includes conditions **Important:** If + // you use IAM Conditions, you must include the `etag` field whenever + // you call `setIamPolicy`. If you omit this field, then IAM allows you + // to overwrite a version `3` policy with a version `1` policy, and all + // of the conditions in the version `3` policy are lost. If a policy + // does not include any conditions, operations on that policy may + // specify any valid version or leave the field unset. To learn which + // resources support conditions in their IAM policies, see the IAM + // documentation + // (https://cloud.google.com/iam/help/conditions/resource-policies). + Version int64 `json:"version,omitempty"` + + // ServerResponse contains the HTTP response code and headers from the + // server. + googleapi.ServerResponse `json:"-"` + + // ForceSendFields is a list of field names (e.g. "AuditConfigs") 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. "AuditConfigs") 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 *GoogleIamV1Policy) MarshalJSON() ([]byte, error) { + type NoMethod GoogleIamV1Policy + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + +// GoogleIamV1SetIamPolicyRequest: Request message for `SetIamPolicy` +// method. +type GoogleIamV1SetIamPolicyRequest struct { + // Policy: REQUIRED: The complete policy to be applied to the + // `resource`. The size of the policy is limited to a few 10s of KB. An + // empty policy is a valid policy but certain Google Cloud services + // (such as Projects) might reject them. + Policy *GoogleIamV1Policy `json:"policy,omitempty"` + + // UpdateMask: OPTIONAL: A FieldMask specifying which fields of the + // policy to modify. Only the fields in the mask will be modified. If no + // mask is provided, the following default mask is used: `paths: + // "bindings, etag" + UpdateMask string `json:"updateMask,omitempty"` + + // ForceSendFields is a list of field names (e.g. "Policy") 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. "Policy") 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 *GoogleIamV1SetIamPolicyRequest) MarshalJSON() ([]byte, error) { + type NoMethod GoogleIamV1SetIamPolicyRequest + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + +// GoogleIamV1TestIamPermissionsRequest: Request message for +// `TestIamPermissions` method. +type GoogleIamV1TestIamPermissionsRequest struct { + // Permissions: The set of permissions to check for the `resource`. + // Permissions with wildcards (such as `*` or `storage.*`) are not + // allowed. For more information see IAM Overview + // (https://cloud.google.com/iam/docs/overview#permissions). + Permissions []string `json:"permissions,omitempty"` + + // ForceSendFields is a list of field names (e.g. "Permissions") 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. "Permissions") 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 *GoogleIamV1TestIamPermissionsRequest) MarshalJSON() ([]byte, error) { + type NoMethod GoogleIamV1TestIamPermissionsRequest + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + +// GoogleIamV1TestIamPermissionsResponse: Response message for +// `TestIamPermissions` method. +type GoogleIamV1TestIamPermissionsResponse struct { + // Permissions: A subset of `TestPermissionsRequest.permissions` that + // the caller is allowed. + Permissions []string `json:"permissions,omitempty"` + + // ServerResponse contains the HTTP response code and headers from the + // server. + googleapi.ServerResponse `json:"-"` + + // ForceSendFields is a list of field names (e.g. "Permissions") 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. "Permissions") 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 *GoogleIamV1TestIamPermissionsResponse) MarshalJSON() ([]byte, error) { + type NoMethod GoogleIamV1TestIamPermissionsResponse + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + +// GoogleLongrunningListOperationsResponse: The response message for +// Operations.ListOperations. +type GoogleLongrunningListOperationsResponse struct { + // NextPageToken: The standard List next-page token. + NextPageToken string `json:"nextPageToken,omitempty"` + + // Operations: A list of operations that matches the specified filter in + // the request. + Operations []*GoogleLongrunningOperation `json:"operations,omitempty"` + + // ServerResponse contains the HTTP response code and headers from the + // server. + googleapi.ServerResponse `json:"-"` + + // ForceSendFields is a list of field names (e.g. "NextPageToken") to + // unconditionally include in API requests. By default, fields with + // empty or default values are omitted from API requests. However, any + // non-pointer, non-interface field appearing in ForceSendFields will be + // sent to the server regardless of whether the field is empty or not. + // This may be used to include empty fields in Patch requests. + ForceSendFields []string `json:"-"` + + // NullFields is a list of field names (e.g. "NextPageToken") to include + // in API requests with the JSON null value. By default, fields with + // empty values are omitted from API requests. However, any field with + // an empty value appearing in NullFields will be sent to the server as + // null. It is an error if a field in this list has a non-empty value. + // This may be used to include null fields in Patch requests. + NullFields []string `json:"-"` +} + +func (s *GoogleLongrunningListOperationsResponse) MarshalJSON() ([]byte, error) { + type NoMethod GoogleLongrunningListOperationsResponse + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + +// GoogleLongrunningOperation: This resource represents a long-running +// operation that is the result of a network API call. +type GoogleLongrunningOperation struct { + // Done: If the value is `false`, it means the operation is still in + // progress. If `true`, the operation is completed, and either `error` + // or `response` is available. + Done bool `json:"done,omitempty"` + + // Error: The error result of the operation in case of failure or + // cancellation. + Error *GoogleRpcStatus `json:"error,omitempty"` + + // Metadata: Service-specific metadata associated with the operation. It + // typically contains progress information and common metadata such as + // create time. Some services might not provide such metadata. Any + // method that returns a long-running operation should document the + // metadata type, if any. + Metadata googleapi.RawMessage `json:"metadata,omitempty"` + + // Name: The server-assigned name, which is only unique within the same + // service that originally returns it. If you use the default HTTP + // mapping, the `name` should be a resource name ending with + // `operations/{unique_id}`. + Name string `json:"name,omitempty"` + + // Response: The normal response of the operation in case of success. If + // the original method returns no data on success, such as `Delete`, the + // response is `google.protobuf.Empty`. If the original method is + // standard `Get`/`Create`/`Update`, the response should be the + // resource. For other methods, the response should have the type + // `XxxResponse`, where `Xxx` is the original method name. For example, + // if the original method name is `TakeSnapshot()`, the inferred + // response type is `TakeSnapshotResponse`. + Response googleapi.RawMessage `json:"response,omitempty"` + + // ServerResponse contains the HTTP response code and headers from the + // server. + googleapi.ServerResponse `json:"-"` + + // ForceSendFields is a list of field names (e.g. "Done") to + // unconditionally include in API requests. By default, fields with + // empty or default values are omitted from API requests. However, any + // non-pointer, non-interface field appearing in ForceSendFields will be + // sent to the server regardless of whether the field is empty or not. + // This may be used to include empty fields in Patch requests. + ForceSendFields []string `json:"-"` + + // NullFields is a list of field names (e.g. "Done") to include in API + // requests with the JSON null value. By default, fields with empty + // values are omitted from API requests. However, any field with an + // empty value appearing in NullFields will be sent to the server as + // null. It is an error if a field in this list has a non-empty value. + // This may be used to include null fields in Patch requests. + NullFields []string `json:"-"` +} + +func (s *GoogleLongrunningOperation) MarshalJSON() ([]byte, error) { + type NoMethod GoogleLongrunningOperation + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + +// GoogleProtobufEmpty: A generic empty message that you can re-use to +// avoid defining duplicated empty messages in your APIs. A typical +// example is to use it as the request or the response type of an API +// method. For instance: service Foo { rpc Bar(google.protobuf.Empty) +// returns (google.protobuf.Empty); } +type GoogleProtobufEmpty struct { + // ServerResponse contains the HTTP response code and headers from the + // server. + googleapi.ServerResponse `json:"-"` +} + +// GoogleRpcStatus: The `Status` type defines a logical error model that +// is suitable for different programming environments, including REST +// APIs and RPC APIs. It is used by gRPC (https://github.com/grpc). Each +// `Status` message contains three pieces of data: error code, error +// message, and error details. You can find out more about this error +// model and how to work with it in the API Design Guide +// (https://cloud.google.com/apis/design/errors). +type GoogleRpcStatus struct { + // Code: The status code, which should be an enum value of + // google.rpc.Code. + Code int64 `json:"code,omitempty"` + + // Details: A list of messages that carry the error details. There is a + // common set of message types for APIs to use. + Details []googleapi.RawMessage `json:"details,omitempty"` + + // Message: A developer-facing error message, which should be in + // English. Any user-facing error message should be localized and sent + // in the google.rpc.Status.details field, or localized by the client. + Message string `json:"message,omitempty"` + + // ForceSendFields is a list of field names (e.g. "Code") to + // unconditionally include in API requests. By default, fields with + // empty or default values are omitted from API requests. However, any + // non-pointer, non-interface field appearing in ForceSendFields will be + // sent to the server regardless of whether the field is empty or not. + // This may be used to include empty fields in Patch requests. + ForceSendFields []string `json:"-"` + + // NullFields is a list of field names (e.g. "Code") to include in API + // requests with the JSON null value. By default, fields with empty + // values are omitted from API requests. However, any field with an + // empty value appearing in NullFields will be sent to the server as + // null. It is an error if a field in this list has a non-empty value. + // This may be used to include null fields in Patch requests. + NullFields []string `json:"-"` +} + +func (s *GoogleRpcStatus) MarshalJSON() ([]byte, error) { + type NoMethod GoogleRpcStatus + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + +// GoogleTypeExpr: Represents a textual expression in the Common +// Expression Language (CEL) syntax. CEL is a C-like expression +// language. The syntax and semantics of CEL are documented at +// https://github.com/google/cel-spec. Example (Comparison): title: +// "Summary size limit" description: "Determines if a summary is less +// than 100 chars" expression: "document.summary.size() < 100" Example +// (Equality): title: "Requestor is owner" description: "Determines if +// requestor is the document owner" expression: "document.owner == +// request.auth.claims.email" Example (Logic): title: "Public documents" +// description: "Determine whether the document should be publicly +// visible" expression: "document.type != 'private' && document.type != +// 'internal'" Example (Data Manipulation): title: "Notification string" +// description: "Create a notification string with a timestamp." +// expression: "'New message received at ' + +// string(document.create_time)" The exact variables and functions that +// may be referenced within an expression are determined by the service +// that evaluates it. See the service documentation for additional +// information. +type GoogleTypeExpr struct { + // Description: Optional. Description of the expression. This is a + // longer text which describes the expression, e.g. when hovered over it + // in a UI. + Description string `json:"description,omitempty"` + + // Expression: Textual representation of an expression in Common + // Expression Language syntax. + Expression string `json:"expression,omitempty"` + + // Location: Optional. String indicating the location of the expression + // for error reporting, e.g. a file name and a position in the file. + Location string `json:"location,omitempty"` + + // Title: Optional. Title for the expression, i.e. a short string + // describing its purpose. This can be used e.g. in UIs which allow to + // enter the expression. + Title string `json:"title,omitempty"` + + // ForceSendFields is a list of field names (e.g. "Description") to + // unconditionally include in API requests. By default, fields with + // empty or default values are omitted from API requests. However, any + // non-pointer, non-interface field appearing in ForceSendFields will be + // sent to the server regardless of whether the field is empty or not. + // This may be used to include empty fields in Patch requests. + ForceSendFields []string `json:"-"` + + // NullFields is a list of field names (e.g. "Description") to include + // in API requests with the JSON null value. By default, fields with + // empty values are omitted from API requests. However, any field with + // an empty value appearing in NullFields will be sent to the server as + // null. It is an error if a field in this list has a non-empty value. + // This may be used to include null fields in Patch requests. + NullFields []string `json:"-"` +} + +func (s *GoogleTypeExpr) MarshalJSON() ([]byte, error) { + type NoMethod GoogleTypeExpr + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + +// method id "run.projects.locations.jobs.create": + +type ProjectsLocationsJobsCreateCall struct { + s *Service + parent string + googlecloudrunv2job *GoogleCloudRunV2Job + urlParams_ gensupport.URLParams + ctx_ context.Context + header_ http.Header +} + +// Create: Create a Job. +// +// - parent: The location and project in which this Job should be +// created. Format: projects/{projectnumber}/locations/{location}. +func (r *ProjectsLocationsJobsService) Create(parent string, googlecloudrunv2job *GoogleCloudRunV2Job) *ProjectsLocationsJobsCreateCall { + c := &ProjectsLocationsJobsCreateCall{s: r.s, urlParams_: make(gensupport.URLParams)} + c.parent = parent + c.googlecloudrunv2job = googlecloudrunv2job + return c +} + +// JobId sets the optional parameter "jobId": Required. The unique +// identifier for the Job. The name of the job becomes +// {parent}/jobs/{job_id}. +func (c *ProjectsLocationsJobsCreateCall) JobId(jobId string) *ProjectsLocationsJobsCreateCall { + c.urlParams_.Set("jobId", jobId) + return c +} + +// ValidateOnly sets the optional parameter "validateOnly": Indicates +// that the request should be validated and default values populated, +// without persisting the request or creating any resources. +func (c *ProjectsLocationsJobsCreateCall) ValidateOnly(validateOnly bool) *ProjectsLocationsJobsCreateCall { + c.urlParams_.Set("validateOnly", fmt.Sprint(validateOnly)) + 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 *ProjectsLocationsJobsCreateCall) Fields(s ...googleapi.Field) *ProjectsLocationsJobsCreateCall { + 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 *ProjectsLocationsJobsCreateCall) Context(ctx context.Context) *ProjectsLocationsJobsCreateCall { + 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 *ProjectsLocationsJobsCreateCall) Header() http.Header { + if c.header_ == nil { + c.header_ = make(http.Header) + } + return c.header_ +} + +func (c *ProjectsLocationsJobsCreateCall) 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.googlecloudrunv2job) + 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, "v2/{+parent}/jobs") + urls += "?" + c.urlParams_.Encode() + req, err := http.NewRequest("POST", urls, body) + if err != nil { + return nil, err + } + req.Header = reqHeaders + googleapi.Expand(req.URL, map[string]string{ + "parent": c.parent, + }) + return gensupport.SendRequest(c.ctx_, c.s.client, req) +} + +// Do executes the "run.projects.locations.jobs.create" call. +// Exactly one of *GoogleLongrunningOperation or error will be non-nil. +// Any non-2xx status code is an error. Response headers are in either +// *GoogleLongrunningOperation.ServerResponse.Header or (if a response +// was returned at all) in error.(*googleapi.Error).Header. Use +// googleapi.IsNotModified to check whether the returned error was +// because http.StatusNotModified was returned. +func (c *ProjectsLocationsJobsCreateCall) Do(opts ...googleapi.CallOption) (*GoogleLongrunningOperation, error) { + gensupport.SetOptions(c.urlParams_, opts...) + res, err := c.doRequest("json") + if res != nil && res.StatusCode == http.StatusNotModified { + if res.Body != nil { + res.Body.Close() + } + return nil, &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, err + } + ret := &GoogleLongrunningOperation{ + ServerResponse: googleapi.ServerResponse{ + Header: res.Header, + HTTPStatusCode: res.StatusCode, + }, + } + target := &ret + if err := gensupport.DecodeResponse(target, res); err != nil { + return nil, err + } + return ret, nil + // { + // "description": "Create a Job.", + // "flatPath": "v2/projects/{projectsId}/locations/{locationsId}/jobs", + // "httpMethod": "POST", + // "id": "run.projects.locations.jobs.create", + // "parameterOrder": [ + // "parent" + // ], + // "parameters": { + // "jobId": { + // "description": "Required. The unique identifier for the Job. The name of the job becomes {parent}/jobs/{job_id}.", + // "location": "query", + // "type": "string" + // }, + // "parent": { + // "description": "Required. The location and project in which this Job should be created. Format: projects/{projectnumber}/locations/{location}", + // "location": "path", + // "pattern": "^projects/[^/]+/locations/[^/]+$", + // "required": true, + // "type": "string" + // }, + // "validateOnly": { + // "description": "Indicates that the request should be validated and default values populated, without persisting the request or creating any resources.", + // "location": "query", + // "type": "boolean" + // } + // }, + // "path": "v2/{+parent}/jobs", + // "request": { + // "$ref": "GoogleCloudRunV2Job" + // }, + // "response": { + // "$ref": "GoogleLongrunningOperation" + // }, + // "scopes": [ + // "https://www.googleapis.com/auth/cloud-platform" + // ] + // } + +} + +// method id "run.projects.locations.jobs.delete": + +type ProjectsLocationsJobsDeleteCall struct { + s *Service + name string + urlParams_ gensupport.URLParams + ctx_ context.Context + header_ http.Header +} + +// Delete: Deletes a Job. +// +// - name: The full name of the Job. Format: +// projects/{projectnumber}/locations/{location}/jobs/{job}. +func (r *ProjectsLocationsJobsService) Delete(name string) *ProjectsLocationsJobsDeleteCall { + c := &ProjectsLocationsJobsDeleteCall{s: r.s, urlParams_: make(gensupport.URLParams)} + c.name = name + return c +} + +// Etag sets the optional parameter "etag": A system-generated +// fingerprint for this version of the resource. May be used to detect +// modification conflict during updates. +func (c *ProjectsLocationsJobsDeleteCall) Etag(etag string) *ProjectsLocationsJobsDeleteCall { + c.urlParams_.Set("etag", etag) + return c +} + +// Force sets the optional parameter "force": If set to true, the Job +// and its Executions will be deleted no matter whether any Executions +// are still running or not. If set to false or unset, the Job and its +// Executions can only be deleted if there are no running Executions. +// Any running Execution will fail the deletion. +func (c *ProjectsLocationsJobsDeleteCall) Force(force bool) *ProjectsLocationsJobsDeleteCall { + c.urlParams_.Set("force", fmt.Sprint(force)) + return c +} + +// ValidateOnly sets the optional parameter "validateOnly": Indicates +// that the request should be validated without actually deleting any +// resources. +func (c *ProjectsLocationsJobsDeleteCall) ValidateOnly(validateOnly bool) *ProjectsLocationsJobsDeleteCall { + c.urlParams_.Set("validateOnly", fmt.Sprint(validateOnly)) + 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 *ProjectsLocationsJobsDeleteCall) Fields(s ...googleapi.Field) *ProjectsLocationsJobsDeleteCall { + 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 *ProjectsLocationsJobsDeleteCall) Context(ctx context.Context) *ProjectsLocationsJobsDeleteCall { + 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 *ProjectsLocationsJobsDeleteCall) Header() http.Header { + if c.header_ == nil { + c.header_ = make(http.Header) + } + return c.header_ +} + +func (c *ProjectsLocationsJobsDeleteCall) doRequest(alt string) (*http.Response, error) { + reqHeaders := make(http.Header) + reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version) + for k, v := range c.header_ { + reqHeaders[k] = v + } + reqHeaders.Set("User-Agent", c.s.userAgent()) + var body io.Reader = nil + c.urlParams_.Set("alt", alt) + c.urlParams_.Set("prettyPrint", "false") + urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+name}") + urls += "?" + c.urlParams_.Encode() + req, err := http.NewRequest("DELETE", urls, body) + if err != nil { + return nil, err + } + req.Header = reqHeaders + googleapi.Expand(req.URL, map[string]string{ + "name": c.name, + }) + return gensupport.SendRequest(c.ctx_, c.s.client, req) +} + +// Do executes the "run.projects.locations.jobs.delete" call. +// Exactly one of *GoogleLongrunningOperation or error will be non-nil. +// Any non-2xx status code is an error. Response headers are in either +// *GoogleLongrunningOperation.ServerResponse.Header or (if a response +// was returned at all) in error.(*googleapi.Error).Header. Use +// googleapi.IsNotModified to check whether the returned error was +// because http.StatusNotModified was returned. +func (c *ProjectsLocationsJobsDeleteCall) Do(opts ...googleapi.CallOption) (*GoogleLongrunningOperation, error) { + gensupport.SetOptions(c.urlParams_, opts...) + res, err := c.doRequest("json") + if res != nil && res.StatusCode == http.StatusNotModified { + if res.Body != nil { + res.Body.Close() + } + return nil, &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, err + } + ret := &GoogleLongrunningOperation{ + ServerResponse: googleapi.ServerResponse{ + Header: res.Header, + HTTPStatusCode: res.StatusCode, + }, + } + target := &ret + if err := gensupport.DecodeResponse(target, res); err != nil { + return nil, err + } + return ret, nil + // { + // "description": "Deletes a Job.", + // "flatPath": "v2/projects/{projectsId}/locations/{locationsId}/jobs/{jobsId}", + // "httpMethod": "DELETE", + // "id": "run.projects.locations.jobs.delete", + // "parameterOrder": [ + // "name" + // ], + // "parameters": { + // "etag": { + // "description": "A system-generated fingerprint for this version of the resource. May be used to detect modification conflict during updates.", + // "location": "query", + // "type": "string" + // }, + // "force": { + // "description": "If set to true, the Job and its Executions will be deleted no matter whether any Executions are still running or not. If set to false or unset, the Job and its Executions can only be deleted if there are no running Executions. Any running Execution will fail the deletion.", + // "location": "query", + // "type": "boolean" + // }, + // "name": { + // "description": "Required. The full name of the Job. Format: projects/{projectnumber}/locations/{location}/jobs/{job}", + // "location": "path", + // "pattern": "^projects/[^/]+/locations/[^/]+/jobs/[^/]+$", + // "required": true, + // "type": "string" + // }, + // "validateOnly": { + // "description": "Indicates that the request should be validated without actually deleting any resources.", + // "location": "query", + // "type": "boolean" + // } + // }, + // "path": "v2/{+name}", + // "response": { + // "$ref": "GoogleLongrunningOperation" + // }, + // "scopes": [ + // "https://www.googleapis.com/auth/cloud-platform" + // ] + // } + +} + +// method id "run.projects.locations.jobs.get": + +type ProjectsLocationsJobsGetCall struct { + s *Service + name string + urlParams_ gensupport.URLParams + ifNoneMatch_ string + ctx_ context.Context + header_ http.Header +} + +// Get: Gets information about a Job. +// +// - name: The full name of the Job. Format: +// projects/{projectnumber}/locations/{location}/jobs/{job}. +func (r *ProjectsLocationsJobsService) Get(name string) *ProjectsLocationsJobsGetCall { + c := &ProjectsLocationsJobsGetCall{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 *ProjectsLocationsJobsGetCall) Fields(s ...googleapi.Field) *ProjectsLocationsJobsGetCall { + 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 *ProjectsLocationsJobsGetCall) IfNoneMatch(entityTag string) *ProjectsLocationsJobsGetCall { + 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 *ProjectsLocationsJobsGetCall) Context(ctx context.Context) *ProjectsLocationsJobsGetCall { + 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 *ProjectsLocationsJobsGetCall) Header() http.Header { + if c.header_ == nil { + c.header_ = make(http.Header) + } + return c.header_ +} + +func (c *ProjectsLocationsJobsGetCall) 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, "v2/{+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 "run.projects.locations.jobs.get" call. +// Exactly one of *GoogleCloudRunV2Job or error will be non-nil. Any +// non-2xx status code is an error. Response headers are in either +// *GoogleCloudRunV2Job.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 *ProjectsLocationsJobsGetCall) Do(opts ...googleapi.CallOption) (*GoogleCloudRunV2Job, 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, &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, err + } + ret := &GoogleCloudRunV2Job{ + ServerResponse: googleapi.ServerResponse{ + Header: res.Header, + HTTPStatusCode: res.StatusCode, + }, + } + target := &ret + if err := gensupport.DecodeResponse(target, res); err != nil { + return nil, err + } + return ret, nil + // { + // "description": "Gets information about a Job.", + // "flatPath": "v2/projects/{projectsId}/locations/{locationsId}/jobs/{jobsId}", + // "httpMethod": "GET", + // "id": "run.projects.locations.jobs.get", + // "parameterOrder": [ + // "name" + // ], + // "parameters": { + // "name": { + // "description": "Required. The full name of the Job. Format: projects/{projectnumber}/locations/{location}/jobs/{job}", + // "location": "path", + // "pattern": "^projects/[^/]+/locations/[^/]+/jobs/[^/]+$", + // "required": true, + // "type": "string" + // } + // }, + // "path": "v2/{+name}", + // "response": { + // "$ref": "GoogleCloudRunV2Job" + // }, + // "scopes": [ + // "https://www.googleapis.com/auth/cloud-platform" + // ] + // } + +} + +// method id "run.projects.locations.jobs.getIamPolicy": + +type ProjectsLocationsJobsGetIamPolicyCall struct { + s *Service + resource string + urlParams_ gensupport.URLParams + ifNoneMatch_ string + ctx_ context.Context + header_ http.Header +} + +// GetIamPolicy: Get the IAM Access Control policy currently in effect +// for the given Job. This result does not include any inherited +// policies. +// +// - resource: REQUIRED: The resource for which the policy is being +// requested. See the operation documentation for the appropriate +// value for this field. +func (r *ProjectsLocationsJobsService) GetIamPolicy(resource string) *ProjectsLocationsJobsGetIamPolicyCall { + c := &ProjectsLocationsJobsGetIamPolicyCall{s: r.s, urlParams_: make(gensupport.URLParams)} + c.resource = resource + return c +} + +// OptionsRequestedPolicyVersion sets the optional parameter +// "options.requestedPolicyVersion": The maximum policy version that +// will be used to format the policy. Valid values are 0, 1, and 3. +// Requests specifying an invalid value will be rejected. Requests for +// policies with any conditional role bindings must specify version 3. +// Policies with no conditional role bindings may specify any valid +// value or leave the field unset. The policy in the response might use +// the policy version that you specified, or it might use a lower policy +// version. For example, if you specify version 3, but the policy has no +// conditional role bindings, the response uses version 1. To learn +// which resources support conditions in their IAM policies, see the IAM +// documentation +// (https://cloud.google.com/iam/help/conditions/resource-policies). +func (c *ProjectsLocationsJobsGetIamPolicyCall) OptionsRequestedPolicyVersion(optionsRequestedPolicyVersion int64) *ProjectsLocationsJobsGetIamPolicyCall { + c.urlParams_.Set("options.requestedPolicyVersion", fmt.Sprint(optionsRequestedPolicyVersion)) + return c +} + +// Fields allows partial responses to be retrieved. See +// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse +// for more information. +func (c *ProjectsLocationsJobsGetIamPolicyCall) Fields(s ...googleapi.Field) *ProjectsLocationsJobsGetIamPolicyCall { + 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 *ProjectsLocationsJobsGetIamPolicyCall) IfNoneMatch(entityTag string) *ProjectsLocationsJobsGetIamPolicyCall { + 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 *ProjectsLocationsJobsGetIamPolicyCall) Context(ctx context.Context) *ProjectsLocationsJobsGetIamPolicyCall { + 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 *ProjectsLocationsJobsGetIamPolicyCall) Header() http.Header { + if c.header_ == nil { + c.header_ = make(http.Header) + } + return c.header_ +} + +func (c *ProjectsLocationsJobsGetIamPolicyCall) 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, "v2/{+resource}:getIamPolicy") + urls += "?" + c.urlParams_.Encode() + req, err := http.NewRequest("GET", urls, body) + if err != nil { + return nil, err + } + req.Header = reqHeaders + googleapi.Expand(req.URL, map[string]string{ + "resource": c.resource, + }) + return gensupport.SendRequest(c.ctx_, c.s.client, req) +} + +// Do executes the "run.projects.locations.jobs.getIamPolicy" call. +// Exactly one of *GoogleIamV1Policy or error will be non-nil. Any +// non-2xx status code is an error. Response headers are in either +// *GoogleIamV1Policy.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 *ProjectsLocationsJobsGetIamPolicyCall) Do(opts ...googleapi.CallOption) (*GoogleIamV1Policy, 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, &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, err + } + ret := &GoogleIamV1Policy{ + 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": "Get the IAM Access Control policy currently in effect for the given Job. This result does not include any inherited policies.", + // "flatPath": "v2/projects/{projectsId}/locations/{locationsId}/jobs/{jobsId}:getIamPolicy", + // "httpMethod": "GET", + // "id": "run.projects.locations.jobs.getIamPolicy", + // "parameterOrder": [ + // "resource" + // ], + // "parameters": { + // "options.requestedPolicyVersion": { + // "description": "Optional. The maximum policy version that will be used to format the policy. Valid values are 0, 1, and 3. Requests specifying an invalid value will be rejected. Requests for policies with any conditional role bindings must specify version 3. Policies with no conditional role bindings may specify any valid value or leave the field unset. The policy in the response might use the policy version that you specified, or it might use a lower policy version. For example, if you specify version 3, but the policy has no conditional role bindings, the response uses version 1. To learn which resources support conditions in their IAM policies, see the [IAM documentation](https://cloud.google.com/iam/help/conditions/resource-policies).", + // "format": "int32", + // "location": "query", + // "type": "integer" + // }, + // "resource": { + // "description": "REQUIRED: The resource for which the policy is being requested. See the operation documentation for the appropriate value for this field.", + // "location": "path", + // "pattern": "^projects/[^/]+/locations/[^/]+/jobs/[^/]+$", + // "required": true, + // "type": "string" + // } + // }, + // "path": "v2/{+resource}:getIamPolicy", + // "response": { + // "$ref": "GoogleIamV1Policy" + // }, + // "scopes": [ + // "https://www.googleapis.com/auth/cloud-platform" + // ] + // } + +} + +// method id "run.projects.locations.jobs.list": + +type ProjectsLocationsJobsListCall struct { + s *Service + parent string + urlParams_ gensupport.URLParams + ifNoneMatch_ string + ctx_ context.Context + header_ http.Header +} + +// List: List Jobs. +// +// - parent: The location and project to list resources on. Format: +// projects/{projectnumber}/locations/{location}. +func (r *ProjectsLocationsJobsService) List(parent string) *ProjectsLocationsJobsListCall { + c := &ProjectsLocationsJobsListCall{s: r.s, urlParams_: make(gensupport.URLParams)} + c.parent = parent + return c +} + +// PageSize sets the optional parameter "pageSize": Maximum number of +// Jobs to return in this call. +func (c *ProjectsLocationsJobsListCall) PageSize(pageSize int64) *ProjectsLocationsJobsListCall { + c.urlParams_.Set("pageSize", fmt.Sprint(pageSize)) + return c +} + +// PageToken sets the optional parameter "pageToken": A page token +// received from a previous call to ListJobs. All other parameters must +// match. +func (c *ProjectsLocationsJobsListCall) PageToken(pageToken string) *ProjectsLocationsJobsListCall { + c.urlParams_.Set("pageToken", pageToken) + return c +} + +// ShowDeleted sets the optional parameter "showDeleted": If true, +// returns deleted (but unexpired) resources along with active ones. +func (c *ProjectsLocationsJobsListCall) ShowDeleted(showDeleted bool) *ProjectsLocationsJobsListCall { + c.urlParams_.Set("showDeleted", fmt.Sprint(showDeleted)) + 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 *ProjectsLocationsJobsListCall) Fields(s ...googleapi.Field) *ProjectsLocationsJobsListCall { + 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 *ProjectsLocationsJobsListCall) IfNoneMatch(entityTag string) *ProjectsLocationsJobsListCall { + 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 *ProjectsLocationsJobsListCall) Context(ctx context.Context) *ProjectsLocationsJobsListCall { + 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 *ProjectsLocationsJobsListCall) Header() http.Header { + if c.header_ == nil { + c.header_ = make(http.Header) + } + return c.header_ +} + +func (c *ProjectsLocationsJobsListCall) 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, "v2/{+parent}/jobs") + 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 "run.projects.locations.jobs.list" call. +// Exactly one of *GoogleCloudRunV2ListJobsResponse or error will be +// non-nil. Any non-2xx status code is an error. Response headers are in +// either *GoogleCloudRunV2ListJobsResponse.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 *ProjectsLocationsJobsListCall) Do(opts ...googleapi.CallOption) (*GoogleCloudRunV2ListJobsResponse, 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, &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, err + } + ret := &GoogleCloudRunV2ListJobsResponse{ + 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": "List Jobs.", + // "flatPath": "v2/projects/{projectsId}/locations/{locationsId}/jobs", + // "httpMethod": "GET", + // "id": "run.projects.locations.jobs.list", + // "parameterOrder": [ + // "parent" + // ], + // "parameters": { + // "pageSize": { + // "description": "Maximum number of Jobs to return in this call.", + // "format": "int32", + // "location": "query", + // "type": "integer" + // }, + // "pageToken": { + // "description": "A page token received from a previous call to ListJobs. All other parameters must match.", + // "location": "query", + // "type": "string" + // }, + // "parent": { + // "description": "Required. The location and project to list resources on. Format: projects/{projectnumber}/locations/{location}", + // "location": "path", + // "pattern": "^projects/[^/]+/locations/[^/]+$", + // "required": true, + // "type": "string" + // }, + // "showDeleted": { + // "description": "If true, returns deleted (but unexpired) resources along with active ones.", + // "location": "query", + // "type": "boolean" + // } + // }, + // "path": "v2/{+parent}/jobs", + // "response": { + // "$ref": "GoogleCloudRunV2ListJobsResponse" + // }, + // "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 *ProjectsLocationsJobsListCall) Pages(ctx context.Context, f func(*GoogleCloudRunV2ListJobsResponse) 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 "run.projects.locations.jobs.patch": + +type ProjectsLocationsJobsPatchCall struct { + s *Service + name string + googlecloudrunv2job *GoogleCloudRunV2Job + urlParams_ gensupport.URLParams + ctx_ context.Context + header_ http.Header +} + +// Patch: Updates a Job. +// +// - name: The fully qualified name of this Job. Format: +// projects/{project}/locations/{location}/jobs/{job}. +func (r *ProjectsLocationsJobsService) Patch(name string, googlecloudrunv2job *GoogleCloudRunV2Job) *ProjectsLocationsJobsPatchCall { + c := &ProjectsLocationsJobsPatchCall{s: r.s, urlParams_: make(gensupport.URLParams)} + c.name = name + c.googlecloudrunv2job = googlecloudrunv2job + return c +} + +// AllowMissing sets the optional parameter "allowMissing": If set to +// true, and if the Job does not exist, it will create a new one. Caller +// must have both create and update permissions for this call if this is +// set to true. +func (c *ProjectsLocationsJobsPatchCall) AllowMissing(allowMissing bool) *ProjectsLocationsJobsPatchCall { + c.urlParams_.Set("allowMissing", fmt.Sprint(allowMissing)) + return c +} + +// UpdateMask sets the optional parameter "updateMask": The list of +// fields to be updated. +func (c *ProjectsLocationsJobsPatchCall) UpdateMask(updateMask string) *ProjectsLocationsJobsPatchCall { + c.urlParams_.Set("updateMask", updateMask) + return c +} + +// ValidateOnly sets the optional parameter "validateOnly": Indicates +// that the request should be validated and default values populated, +// without persisting the request or updating any resources. +func (c *ProjectsLocationsJobsPatchCall) ValidateOnly(validateOnly bool) *ProjectsLocationsJobsPatchCall { + c.urlParams_.Set("validateOnly", fmt.Sprint(validateOnly)) + 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 *ProjectsLocationsJobsPatchCall) Fields(s ...googleapi.Field) *ProjectsLocationsJobsPatchCall { + 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 *ProjectsLocationsJobsPatchCall) Context(ctx context.Context) *ProjectsLocationsJobsPatchCall { + 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 *ProjectsLocationsJobsPatchCall) Header() http.Header { + if c.header_ == nil { + c.header_ = make(http.Header) + } + return c.header_ +} + +func (c *ProjectsLocationsJobsPatchCall) 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.googlecloudrunv2job) + 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, "v2/{+name}") + urls += "?" + c.urlParams_.Encode() + req, err := http.NewRequest("PATCH", urls, body) + if err != nil { + return nil, err + } + req.Header = reqHeaders + googleapi.Expand(req.URL, map[string]string{ + "name": c.name, + }) + return gensupport.SendRequest(c.ctx_, c.s.client, req) +} + +// Do executes the "run.projects.locations.jobs.patch" call. +// Exactly one of *GoogleLongrunningOperation or error will be non-nil. +// Any non-2xx status code is an error. Response headers are in either +// *GoogleLongrunningOperation.ServerResponse.Header or (if a response +// was returned at all) in error.(*googleapi.Error).Header. Use +// googleapi.IsNotModified to check whether the returned error was +// because http.StatusNotModified was returned. +func (c *ProjectsLocationsJobsPatchCall) Do(opts ...googleapi.CallOption) (*GoogleLongrunningOperation, error) { + gensupport.SetOptions(c.urlParams_, opts...) + res, err := c.doRequest("json") + if res != nil && res.StatusCode == http.StatusNotModified { + if res.Body != nil { + res.Body.Close() + } + return nil, &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, err + } + ret := &GoogleLongrunningOperation{ + ServerResponse: googleapi.ServerResponse{ + Header: res.Header, + HTTPStatusCode: res.StatusCode, + }, + } + target := &ret + if err := gensupport.DecodeResponse(target, res); err != nil { + return nil, err + } + return ret, nil + // { + // "description": "Updates a Job.", + // "flatPath": "v2/projects/{projectsId}/locations/{locationsId}/jobs/{jobsId}", + // "httpMethod": "PATCH", + // "id": "run.projects.locations.jobs.patch", + // "parameterOrder": [ + // "name" + // ], + // "parameters": { + // "allowMissing": { + // "description": "If set to true, and if the Job does not exist, it will create a new one. Caller must have both create and update permissions for this call if this is set to true.", + // "location": "query", + // "type": "boolean" + // }, + // "name": { + // "description": "The fully qualified name of this Job. Format: projects/{project}/locations/{location}/jobs/{job}", + // "location": "path", + // "pattern": "^projects/[^/]+/locations/[^/]+/jobs/[^/]+$", + // "required": true, + // "type": "string" + // }, + // "updateMask": { + // "description": "The list of fields to be updated.", + // "format": "google-fieldmask", + // "location": "query", + // "type": "string" + // }, + // "validateOnly": { + // "description": "Indicates that the request should be validated and default values populated, without persisting the request or updating any resources.", + // "location": "query", + // "type": "boolean" + // } + // }, + // "path": "v2/{+name}", + // "request": { + // "$ref": "GoogleCloudRunV2Job" + // }, + // "response": { + // "$ref": "GoogleLongrunningOperation" + // }, + // "scopes": [ + // "https://www.googleapis.com/auth/cloud-platform" + // ] + // } + +} + +// method id "run.projects.locations.jobs.run": + +type ProjectsLocationsJobsRunCall struct { + s *Service + name string + googlecloudrunv2runjobrequest *GoogleCloudRunV2RunJobRequest + urlParams_ gensupport.URLParams + ctx_ context.Context + header_ http.Header +} + +// Run: Triggers creation of a new Execution of this Job. +// +// - name: The full name of the Job. Format: +// projects/{projectnumber}/locations/{location}/jobs/{job}. +func (r *ProjectsLocationsJobsService) Run(name string, googlecloudrunv2runjobrequest *GoogleCloudRunV2RunJobRequest) *ProjectsLocationsJobsRunCall { + c := &ProjectsLocationsJobsRunCall{s: r.s, urlParams_: make(gensupport.URLParams)} + c.name = name + c.googlecloudrunv2runjobrequest = googlecloudrunv2runjobrequest + 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 *ProjectsLocationsJobsRunCall) Fields(s ...googleapi.Field) *ProjectsLocationsJobsRunCall { + 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 *ProjectsLocationsJobsRunCall) Context(ctx context.Context) *ProjectsLocationsJobsRunCall { + 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 *ProjectsLocationsJobsRunCall) Header() http.Header { + if c.header_ == nil { + c.header_ = make(http.Header) + } + return c.header_ +} + +func (c *ProjectsLocationsJobsRunCall) 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.googlecloudrunv2runjobrequest) + 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, "v2/{+name}:run") + urls += "?" + c.urlParams_.Encode() + req, err := http.NewRequest("POST", urls, body) + if err != nil { + return nil, err + } + req.Header = reqHeaders + googleapi.Expand(req.URL, map[string]string{ + "name": c.name, + }) + return gensupport.SendRequest(c.ctx_, c.s.client, req) +} + +// Do executes the "run.projects.locations.jobs.run" call. +// Exactly one of *GoogleLongrunningOperation or error will be non-nil. +// Any non-2xx status code is an error. Response headers are in either +// *GoogleLongrunningOperation.ServerResponse.Header or (if a response +// was returned at all) in error.(*googleapi.Error).Header. Use +// googleapi.IsNotModified to check whether the returned error was +// because http.StatusNotModified was returned. +func (c *ProjectsLocationsJobsRunCall) Do(opts ...googleapi.CallOption) (*GoogleLongrunningOperation, error) { + gensupport.SetOptions(c.urlParams_, opts...) + res, err := c.doRequest("json") + if res != nil && res.StatusCode == http.StatusNotModified { + if res.Body != nil { + res.Body.Close() + } + return nil, &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, err + } + ret := &GoogleLongrunningOperation{ + ServerResponse: googleapi.ServerResponse{ + Header: res.Header, + HTTPStatusCode: res.StatusCode, + }, + } + target := &ret + if err := gensupport.DecodeResponse(target, res); err != nil { + return nil, err + } + return ret, nil + // { + // "description": "Triggers creation of a new Execution of this Job.", + // "flatPath": "v2/projects/{projectsId}/locations/{locationsId}/jobs/{jobsId}:run", + // "httpMethod": "POST", + // "id": "run.projects.locations.jobs.run", + // "parameterOrder": [ + // "name" + // ], + // "parameters": { + // "name": { + // "description": "Required. The full name of the Job. Format: projects/{projectnumber}/locations/{location}/jobs/{job}", + // "location": "path", + // "pattern": "^projects/[^/]+/locations/[^/]+/jobs/[^/]+$", + // "required": true, + // "type": "string" + // } + // }, + // "path": "v2/{+name}:run", + // "request": { + // "$ref": "GoogleCloudRunV2RunJobRequest" + // }, + // "response": { + // "$ref": "GoogleLongrunningOperation" + // }, + // "scopes": [ + // "https://www.googleapis.com/auth/cloud-platform" + // ] + // } + +} + +// method id "run.projects.locations.jobs.setIamPolicy": + +type ProjectsLocationsJobsSetIamPolicyCall struct { + s *Service + resource string + googleiamv1setiampolicyrequest *GoogleIamV1SetIamPolicyRequest + urlParams_ gensupport.URLParams + ctx_ context.Context + header_ http.Header +} + +// SetIamPolicy: Sets the IAM Access control policy for the specified +// Job. Overwrites any existing policy. +// +// - resource: REQUIRED: The resource for which the policy is being +// specified. See the operation documentation for the appropriate +// value for this field. +func (r *ProjectsLocationsJobsService) SetIamPolicy(resource string, googleiamv1setiampolicyrequest *GoogleIamV1SetIamPolicyRequest) *ProjectsLocationsJobsSetIamPolicyCall { + c := &ProjectsLocationsJobsSetIamPolicyCall{s: r.s, urlParams_: make(gensupport.URLParams)} + c.resource = resource + c.googleiamv1setiampolicyrequest = googleiamv1setiampolicyrequest + 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 *ProjectsLocationsJobsSetIamPolicyCall) Fields(s ...googleapi.Field) *ProjectsLocationsJobsSetIamPolicyCall { + 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 *ProjectsLocationsJobsSetIamPolicyCall) Context(ctx context.Context) *ProjectsLocationsJobsSetIamPolicyCall { + 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 *ProjectsLocationsJobsSetIamPolicyCall) Header() http.Header { + if c.header_ == nil { + c.header_ = make(http.Header) + } + return c.header_ +} + +func (c *ProjectsLocationsJobsSetIamPolicyCall) 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.googleiamv1setiampolicyrequest) + 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, "v2/{+resource}:setIamPolicy") + 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{ + "resource": c.resource, + }) + return gensupport.SendRequest(c.ctx_, c.s.client, req) +} + +// Do executes the "run.projects.locations.jobs.setIamPolicy" call. +// Exactly one of *GoogleIamV1Policy or error will be non-nil. Any +// non-2xx status code is an error. Response headers are in either +// *GoogleIamV1Policy.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 *ProjectsLocationsJobsSetIamPolicyCall) Do(opts ...googleapi.CallOption) (*GoogleIamV1Policy, 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, &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, err + } + ret := &GoogleIamV1Policy{ + 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": "Sets the IAM Access control policy for the specified Job. Overwrites any existing policy.", + // "flatPath": "v2/projects/{projectsId}/locations/{locationsId}/jobs/{jobsId}:setIamPolicy", + // "httpMethod": "POST", + // "id": "run.projects.locations.jobs.setIamPolicy", + // "parameterOrder": [ + // "resource" + // ], + // "parameters": { + // "resource": { + // "description": "REQUIRED: The resource for which the policy is being specified. See the operation documentation for the appropriate value for this field.", + // "location": "path", + // "pattern": "^projects/[^/]+/locations/[^/]+/jobs/[^/]+$", + // "required": true, + // "type": "string" + // } + // }, + // "path": "v2/{+resource}:setIamPolicy", + // "request": { + // "$ref": "GoogleIamV1SetIamPolicyRequest" + // }, + // "response": { + // "$ref": "GoogleIamV1Policy" + // }, + // "scopes": [ + // "https://www.googleapis.com/auth/cloud-platform" + // ] + // } + +} + +// method id "run.projects.locations.jobs.testIamPermissions": + +type ProjectsLocationsJobsTestIamPermissionsCall struct { + s *Service + resource string + googleiamv1testiampermissionsrequest *GoogleIamV1TestIamPermissionsRequest + urlParams_ gensupport.URLParams + ctx_ context.Context + header_ http.Header +} + +// TestIamPermissions: Returns permissions that a caller has on the +// specified Project. There are no permissions required for making this +// API call. +// +// - resource: REQUIRED: The resource for which the policy detail is +// being requested. See the operation documentation for the +// appropriate value for this field. +func (r *ProjectsLocationsJobsService) TestIamPermissions(resource string, googleiamv1testiampermissionsrequest *GoogleIamV1TestIamPermissionsRequest) *ProjectsLocationsJobsTestIamPermissionsCall { + c := &ProjectsLocationsJobsTestIamPermissionsCall{s: r.s, urlParams_: make(gensupport.URLParams)} + c.resource = resource + c.googleiamv1testiampermissionsrequest = googleiamv1testiampermissionsrequest + 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 *ProjectsLocationsJobsTestIamPermissionsCall) Fields(s ...googleapi.Field) *ProjectsLocationsJobsTestIamPermissionsCall { + 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 *ProjectsLocationsJobsTestIamPermissionsCall) Context(ctx context.Context) *ProjectsLocationsJobsTestIamPermissionsCall { + 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 *ProjectsLocationsJobsTestIamPermissionsCall) Header() http.Header { + if c.header_ == nil { + c.header_ = make(http.Header) + } + return c.header_ +} + +func (c *ProjectsLocationsJobsTestIamPermissionsCall) 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.googleiamv1testiampermissionsrequest) + 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, "v2/{+resource}:testIamPermissions") + 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{ + "resource": c.resource, + }) + return gensupport.SendRequest(c.ctx_, c.s.client, req) +} + +// Do executes the "run.projects.locations.jobs.testIamPermissions" call. +// Exactly one of *GoogleIamV1TestIamPermissionsResponse or error will +// be non-nil. Any non-2xx status code is an error. Response headers are +// in either +// *GoogleIamV1TestIamPermissionsResponse.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 *ProjectsLocationsJobsTestIamPermissionsCall) Do(opts ...googleapi.CallOption) (*GoogleIamV1TestIamPermissionsResponse, 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, &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, err + } + ret := &GoogleIamV1TestIamPermissionsResponse{ + ServerResponse: googleapi.ServerResponse{ + Header: res.Header, + HTTPStatusCode: res.StatusCode, + }, + } + target := &ret + if err := gensupport.DecodeResponse(target, res); err != nil { + return nil, err + } + return ret, nil + // { + // "description": "Returns permissions that a caller has on the specified Project. There are no permissions required for making this API call.", + // "flatPath": "v2/projects/{projectsId}/locations/{locationsId}/jobs/{jobsId}:testIamPermissions", + // "httpMethod": "POST", + // "id": "run.projects.locations.jobs.testIamPermissions", + // "parameterOrder": [ + // "resource" + // ], + // "parameters": { + // "resource": { + // "description": "REQUIRED: The resource for which the policy detail is being requested. See the operation documentation for the appropriate value for this field.", + // "location": "path", + // "pattern": "^projects/[^/]+/locations/[^/]+/jobs/[^/]+$", + // "required": true, + // "type": "string" + // } + // }, + // "path": "v2/{+resource}:testIamPermissions", + // "request": { + // "$ref": "GoogleIamV1TestIamPermissionsRequest" + // }, + // "response": { + // "$ref": "GoogleIamV1TestIamPermissionsResponse" + // }, + // "scopes": [ + // "https://www.googleapis.com/auth/cloud-platform" + // ] + // } + +} + +// method id "run.projects.locations.jobs.executions.delete": + +type ProjectsLocationsJobsExecutionsDeleteCall struct { + s *Service + name string + urlParams_ gensupport.URLParams + ctx_ context.Context + header_ http.Header +} + +// Delete: Delete an Execution. +// +// - name: The name of the Execution to delete. Format: +// projects/{project}/locations/{location}/jobs/{job}/executions/{execu +// tion}. +func (r *ProjectsLocationsJobsExecutionsService) Delete(name string) *ProjectsLocationsJobsExecutionsDeleteCall { + c := &ProjectsLocationsJobsExecutionsDeleteCall{s: r.s, urlParams_: make(gensupport.URLParams)} + c.name = name + return c +} + +// Etag sets the optional parameter "etag": A system-generated +// fingerprint for this version of the resource. This may be used to +// detect modification conflict during updates. +func (c *ProjectsLocationsJobsExecutionsDeleteCall) Etag(etag string) *ProjectsLocationsJobsExecutionsDeleteCall { + c.urlParams_.Set("etag", etag) + return c +} + +// ValidateOnly sets the optional parameter "validateOnly": Indicates +// that the request should be validated without actually deleting any +// resources. +func (c *ProjectsLocationsJobsExecutionsDeleteCall) ValidateOnly(validateOnly bool) *ProjectsLocationsJobsExecutionsDeleteCall { + c.urlParams_.Set("validateOnly", fmt.Sprint(validateOnly)) + 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 *ProjectsLocationsJobsExecutionsDeleteCall) Fields(s ...googleapi.Field) *ProjectsLocationsJobsExecutionsDeleteCall { + 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 *ProjectsLocationsJobsExecutionsDeleteCall) Context(ctx context.Context) *ProjectsLocationsJobsExecutionsDeleteCall { + 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 *ProjectsLocationsJobsExecutionsDeleteCall) Header() http.Header { + if c.header_ == nil { + c.header_ = make(http.Header) + } + return c.header_ +} + +func (c *ProjectsLocationsJobsExecutionsDeleteCall) doRequest(alt string) (*http.Response, error) { + reqHeaders := make(http.Header) + reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version) + for k, v := range c.header_ { + reqHeaders[k] = v + } + reqHeaders.Set("User-Agent", c.s.userAgent()) + var body io.Reader = nil + c.urlParams_.Set("alt", alt) + c.urlParams_.Set("prettyPrint", "false") + urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+name}") + urls += "?" + c.urlParams_.Encode() + req, err := http.NewRequest("DELETE", urls, body) + if err != nil { + return nil, err + } + req.Header = reqHeaders + googleapi.Expand(req.URL, map[string]string{ + "name": c.name, + }) + return gensupport.SendRequest(c.ctx_, c.s.client, req) +} + +// Do executes the "run.projects.locations.jobs.executions.delete" call. +// Exactly one of *GoogleLongrunningOperation or error will be non-nil. +// Any non-2xx status code is an error. Response headers are in either +// *GoogleLongrunningOperation.ServerResponse.Header or (if a response +// was returned at all) in error.(*googleapi.Error).Header. Use +// googleapi.IsNotModified to check whether the returned error was +// because http.StatusNotModified was returned. +func (c *ProjectsLocationsJobsExecutionsDeleteCall) Do(opts ...googleapi.CallOption) (*GoogleLongrunningOperation, error) { + gensupport.SetOptions(c.urlParams_, opts...) + res, err := c.doRequest("json") + if res != nil && res.StatusCode == http.StatusNotModified { + if res.Body != nil { + res.Body.Close() + } + return nil, &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, err + } + ret := &GoogleLongrunningOperation{ + ServerResponse: googleapi.ServerResponse{ + Header: res.Header, + HTTPStatusCode: res.StatusCode, + }, + } + target := &ret + if err := gensupport.DecodeResponse(target, res); err != nil { + return nil, err + } + return ret, nil + // { + // "description": "Delete an Execution.", + // "flatPath": "v2/projects/{projectsId}/locations/{locationsId}/jobs/{jobsId}/executions/{executionsId}", + // "httpMethod": "DELETE", + // "id": "run.projects.locations.jobs.executions.delete", + // "parameterOrder": [ + // "name" + // ], + // "parameters": { + // "etag": { + // "description": "A system-generated fingerprint for this version of the resource. This may be used to detect modification conflict during updates.", + // "location": "query", + // "type": "string" + // }, + // "name": { + // "description": "Required. The name of the Execution to delete. Format: projects/{project}/locations/{location}/jobs/{job}/executions/{execution}", + // "location": "path", + // "pattern": "^projects/[^/]+/locations/[^/]+/jobs/[^/]+/executions/[^/]+$", + // "required": true, + // "type": "string" + // }, + // "validateOnly": { + // "description": "Indicates that the request should be validated without actually deleting any resources.", + // "location": "query", + // "type": "boolean" + // } + // }, + // "path": "v2/{+name}", + // "response": { + // "$ref": "GoogleLongrunningOperation" + // }, + // "scopes": [ + // "https://www.googleapis.com/auth/cloud-platform" + // ] + // } + +} + +// method id "run.projects.locations.jobs.executions.get": + +type ProjectsLocationsJobsExecutionsGetCall struct { + s *Service + name string + urlParams_ gensupport.URLParams + ifNoneMatch_ string + ctx_ context.Context + header_ http.Header +} + +// Get: Gets information about a Execution. +// +// - name: The full name of the Execution. Format: +// projects/{project}/locations/{location}/jobs/{job}/executions/{execu +// tion}. +func (r *ProjectsLocationsJobsExecutionsService) Get(name string) *ProjectsLocationsJobsExecutionsGetCall { + c := &ProjectsLocationsJobsExecutionsGetCall{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 *ProjectsLocationsJobsExecutionsGetCall) Fields(s ...googleapi.Field) *ProjectsLocationsJobsExecutionsGetCall { + 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 *ProjectsLocationsJobsExecutionsGetCall) IfNoneMatch(entityTag string) *ProjectsLocationsJobsExecutionsGetCall { + 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 *ProjectsLocationsJobsExecutionsGetCall) Context(ctx context.Context) *ProjectsLocationsJobsExecutionsGetCall { + 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 *ProjectsLocationsJobsExecutionsGetCall) Header() http.Header { + if c.header_ == nil { + c.header_ = make(http.Header) + } + return c.header_ +} + +func (c *ProjectsLocationsJobsExecutionsGetCall) 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, "v2/{+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 "run.projects.locations.jobs.executions.get" call. +// Exactly one of *GoogleCloudRunV2Execution or error will be non-nil. +// Any non-2xx status code is an error. Response headers are in either +// *GoogleCloudRunV2Execution.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 *ProjectsLocationsJobsExecutionsGetCall) Do(opts ...googleapi.CallOption) (*GoogleCloudRunV2Execution, 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, &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, err + } + ret := &GoogleCloudRunV2Execution{ + ServerResponse: googleapi.ServerResponse{ + Header: res.Header, + HTTPStatusCode: res.StatusCode, + }, + } + target := &ret + if err := gensupport.DecodeResponse(target, res); err != nil { + return nil, err + } + return ret, nil + // { + // "description": "Gets information about a Execution.", + // "flatPath": "v2/projects/{projectsId}/locations/{locationsId}/jobs/{jobsId}/executions/{executionsId}", + // "httpMethod": "GET", + // "id": "run.projects.locations.jobs.executions.get", + // "parameterOrder": [ + // "name" + // ], + // "parameters": { + // "name": { + // "description": "Required. The full name of the Execution. Format: projects/{project}/locations/{location}/jobs/{job}/executions/{execution}", + // "location": "path", + // "pattern": "^projects/[^/]+/locations/[^/]+/jobs/[^/]+/executions/[^/]+$", + // "required": true, + // "type": "string" + // } + // }, + // "path": "v2/{+name}", + // "response": { + // "$ref": "GoogleCloudRunV2Execution" + // }, + // "scopes": [ + // "https://www.googleapis.com/auth/cloud-platform" + // ] + // } + +} + +// method id "run.projects.locations.jobs.executions.list": + +type ProjectsLocationsJobsExecutionsListCall struct { + s *Service + parent string + urlParams_ gensupport.URLParams + ifNoneMatch_ string + ctx_ context.Context + header_ http.Header +} + +// List: List Executions from a Job. +// +// - parent: The Execution from which the Executions should be listed. +// To list all Executions across Jobs, use "-" instead of Job name. +// Format: projects/{project}/locations/{location}/jobs/{job}. +func (r *ProjectsLocationsJobsExecutionsService) List(parent string) *ProjectsLocationsJobsExecutionsListCall { + c := &ProjectsLocationsJobsExecutionsListCall{s: r.s, urlParams_: make(gensupport.URLParams)} + c.parent = parent + return c +} + +// PageSize sets the optional parameter "pageSize": Maximum number of +// Executions to return in this call. +func (c *ProjectsLocationsJobsExecutionsListCall) PageSize(pageSize int64) *ProjectsLocationsJobsExecutionsListCall { + c.urlParams_.Set("pageSize", fmt.Sprint(pageSize)) + return c +} + +// PageToken sets the optional parameter "pageToken": A page token +// received from a previous call to ListExecutions. All other parameters +// must match. +func (c *ProjectsLocationsJobsExecutionsListCall) PageToken(pageToken string) *ProjectsLocationsJobsExecutionsListCall { + c.urlParams_.Set("pageToken", pageToken) + return c +} + +// ShowDeleted sets the optional parameter "showDeleted": If true, +// returns deleted (but unexpired) resources along with active ones. +func (c *ProjectsLocationsJobsExecutionsListCall) ShowDeleted(showDeleted bool) *ProjectsLocationsJobsExecutionsListCall { + c.urlParams_.Set("showDeleted", fmt.Sprint(showDeleted)) + 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 *ProjectsLocationsJobsExecutionsListCall) Fields(s ...googleapi.Field) *ProjectsLocationsJobsExecutionsListCall { + 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 *ProjectsLocationsJobsExecutionsListCall) IfNoneMatch(entityTag string) *ProjectsLocationsJobsExecutionsListCall { + 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 *ProjectsLocationsJobsExecutionsListCall) Context(ctx context.Context) *ProjectsLocationsJobsExecutionsListCall { + 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 *ProjectsLocationsJobsExecutionsListCall) Header() http.Header { + if c.header_ == nil { + c.header_ = make(http.Header) + } + return c.header_ +} + +func (c *ProjectsLocationsJobsExecutionsListCall) 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, "v2/{+parent}/executions") + 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 "run.projects.locations.jobs.executions.list" call. +// Exactly one of *GoogleCloudRunV2ListExecutionsResponse or error will +// be non-nil. Any non-2xx status code is an error. Response headers are +// in either +// *GoogleCloudRunV2ListExecutionsResponse.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 *ProjectsLocationsJobsExecutionsListCall) Do(opts ...googleapi.CallOption) (*GoogleCloudRunV2ListExecutionsResponse, 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, &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, err + } + ret := &GoogleCloudRunV2ListExecutionsResponse{ + 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": "List Executions from a Job.", + // "flatPath": "v2/projects/{projectsId}/locations/{locationsId}/jobs/{jobsId}/executions", + // "httpMethod": "GET", + // "id": "run.projects.locations.jobs.executions.list", + // "parameterOrder": [ + // "parent" + // ], + // "parameters": { + // "pageSize": { + // "description": "Maximum number of Executions to return in this call.", + // "format": "int32", + // "location": "query", + // "type": "integer" + // }, + // "pageToken": { + // "description": "A page token received from a previous call to ListExecutions. All other parameters must match.", + // "location": "query", + // "type": "string" + // }, + // "parent": { + // "description": "Required. The Execution from which the Executions should be listed. To list all Executions across Jobs, use \"-\" instead of Job name. Format: projects/{project}/locations/{location}/jobs/{job}", + // "location": "path", + // "pattern": "^projects/[^/]+/locations/[^/]+/jobs/[^/]+$", + // "required": true, + // "type": "string" + // }, + // "showDeleted": { + // "description": "If true, returns deleted (but unexpired) resources along with active ones.", + // "location": "query", + // "type": "boolean" + // } + // }, + // "path": "v2/{+parent}/executions", + // "response": { + // "$ref": "GoogleCloudRunV2ListExecutionsResponse" + // }, + // "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 *ProjectsLocationsJobsExecutionsListCall) Pages(ctx context.Context, f func(*GoogleCloudRunV2ListExecutionsResponse) 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 "run.projects.locations.jobs.executions.tasks.get": + +type ProjectsLocationsJobsExecutionsTasksGetCall struct { + s *Service + name string + urlParams_ gensupport.URLParams + ifNoneMatch_ string + ctx_ context.Context + header_ http.Header +} + +// Get: Gets information about a Task. +// +// - name: The full name of the Task. Format: +// projects/{project}/locations/{location}/jobs/{job}/executions/{execu +// tion}/tasks/{task}. +func (r *ProjectsLocationsJobsExecutionsTasksService) Get(name string) *ProjectsLocationsJobsExecutionsTasksGetCall { + c := &ProjectsLocationsJobsExecutionsTasksGetCall{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 *ProjectsLocationsJobsExecutionsTasksGetCall) Fields(s ...googleapi.Field) *ProjectsLocationsJobsExecutionsTasksGetCall { + 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 *ProjectsLocationsJobsExecutionsTasksGetCall) IfNoneMatch(entityTag string) *ProjectsLocationsJobsExecutionsTasksGetCall { + 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 *ProjectsLocationsJobsExecutionsTasksGetCall) Context(ctx context.Context) *ProjectsLocationsJobsExecutionsTasksGetCall { + 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 *ProjectsLocationsJobsExecutionsTasksGetCall) Header() http.Header { + if c.header_ == nil { + c.header_ = make(http.Header) + } + return c.header_ +} + +func (c *ProjectsLocationsJobsExecutionsTasksGetCall) 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, "v2/{+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 "run.projects.locations.jobs.executions.tasks.get" call. +// Exactly one of *GoogleCloudRunV2Task or error will be non-nil. Any +// non-2xx status code is an error. Response headers are in either +// *GoogleCloudRunV2Task.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 *ProjectsLocationsJobsExecutionsTasksGetCall) Do(opts ...googleapi.CallOption) (*GoogleCloudRunV2Task, 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, &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, err + } + ret := &GoogleCloudRunV2Task{ + ServerResponse: googleapi.ServerResponse{ + Header: res.Header, + HTTPStatusCode: res.StatusCode, + }, + } + target := &ret + if err := gensupport.DecodeResponse(target, res); err != nil { + return nil, err + } + return ret, nil + // { + // "description": "Gets information about a Task.", + // "flatPath": "v2/projects/{projectsId}/locations/{locationsId}/jobs/{jobsId}/executions/{executionsId}/tasks/{tasksId}", + // "httpMethod": "GET", + // "id": "run.projects.locations.jobs.executions.tasks.get", + // "parameterOrder": [ + // "name" + // ], + // "parameters": { + // "name": { + // "description": "Required. The full name of the Task. Format: projects/{project}/locations/{location}/jobs/{job}/executions/{execution}/tasks/{task}", + // "location": "path", + // "pattern": "^projects/[^/]+/locations/[^/]+/jobs/[^/]+/executions/[^/]+/tasks/[^/]+$", + // "required": true, + // "type": "string" + // } + // }, + // "path": "v2/{+name}", + // "response": { + // "$ref": "GoogleCloudRunV2Task" + // }, + // "scopes": [ + // "https://www.googleapis.com/auth/cloud-platform" + // ] + // } + +} + +// method id "run.projects.locations.jobs.executions.tasks.list": + +type ProjectsLocationsJobsExecutionsTasksListCall struct { + s *Service + parent string + urlParams_ gensupport.URLParams + ifNoneMatch_ string + ctx_ context.Context + header_ http.Header +} + +// List: List Tasks from an Execution of a Job. +// +// - parent: The Execution from which the Tasks should be listed. To +// list all Tasks across Executions of a Job, use "-" instead of +// Execution name. To list all Tasks across Jobs, use "-" instead of +// Job name. Format: +// projects/{project}/locations/{location}/jobs/{job}/executions/{execu +// tion}. +func (r *ProjectsLocationsJobsExecutionsTasksService) List(parent string) *ProjectsLocationsJobsExecutionsTasksListCall { + c := &ProjectsLocationsJobsExecutionsTasksListCall{s: r.s, urlParams_: make(gensupport.URLParams)} + c.parent = parent + return c +} + +// PageSize sets the optional parameter "pageSize": Maximum number of +// Tasks to return in this call. +func (c *ProjectsLocationsJobsExecutionsTasksListCall) PageSize(pageSize int64) *ProjectsLocationsJobsExecutionsTasksListCall { + c.urlParams_.Set("pageSize", fmt.Sprint(pageSize)) + return c +} + +// PageToken sets the optional parameter "pageToken": A page token +// received from a previous call to ListTasks. All other parameters must +// match. +func (c *ProjectsLocationsJobsExecutionsTasksListCall) PageToken(pageToken string) *ProjectsLocationsJobsExecutionsTasksListCall { + c.urlParams_.Set("pageToken", pageToken) + return c +} + +// ShowDeleted sets the optional parameter "showDeleted": If true, +// returns deleted (but unexpired) resources along with active ones. +func (c *ProjectsLocationsJobsExecutionsTasksListCall) ShowDeleted(showDeleted bool) *ProjectsLocationsJobsExecutionsTasksListCall { + c.urlParams_.Set("showDeleted", fmt.Sprint(showDeleted)) + 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 *ProjectsLocationsJobsExecutionsTasksListCall) Fields(s ...googleapi.Field) *ProjectsLocationsJobsExecutionsTasksListCall { + 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 *ProjectsLocationsJobsExecutionsTasksListCall) IfNoneMatch(entityTag string) *ProjectsLocationsJobsExecutionsTasksListCall { + 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 *ProjectsLocationsJobsExecutionsTasksListCall) Context(ctx context.Context) *ProjectsLocationsJobsExecutionsTasksListCall { + 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 *ProjectsLocationsJobsExecutionsTasksListCall) Header() http.Header { + if c.header_ == nil { + c.header_ = make(http.Header) + } + return c.header_ +} + +func (c *ProjectsLocationsJobsExecutionsTasksListCall) 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, "v2/{+parent}/tasks") + 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 "run.projects.locations.jobs.executions.tasks.list" call. +// Exactly one of *GoogleCloudRunV2ListTasksResponse or error will be +// non-nil. Any non-2xx status code is an error. Response headers are in +// either *GoogleCloudRunV2ListTasksResponse.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 *ProjectsLocationsJobsExecutionsTasksListCall) Do(opts ...googleapi.CallOption) (*GoogleCloudRunV2ListTasksResponse, 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, &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, err + } + ret := &GoogleCloudRunV2ListTasksResponse{ + 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": "List Tasks from an Execution of a Job.", + // "flatPath": "v2/projects/{projectsId}/locations/{locationsId}/jobs/{jobsId}/executions/{executionsId}/tasks", + // "httpMethod": "GET", + // "id": "run.projects.locations.jobs.executions.tasks.list", + // "parameterOrder": [ + // "parent" + // ], + // "parameters": { + // "pageSize": { + // "description": "Maximum number of Tasks to return in this call.", + // "format": "int32", + // "location": "query", + // "type": "integer" + // }, + // "pageToken": { + // "description": "A page token received from a previous call to ListTasks. All other parameters must match.", + // "location": "query", + // "type": "string" + // }, + // "parent": { + // "description": "Required. The Execution from which the Tasks should be listed. To list all Tasks across Executions of a Job, use \"-\" instead of Execution name. To list all Tasks across Jobs, use \"-\" instead of Job name. Format: projects/{project}/locations/{location}/jobs/{job}/executions/{execution}", + // "location": "path", + // "pattern": "^projects/[^/]+/locations/[^/]+/jobs/[^/]+/executions/[^/]+$", + // "required": true, + // "type": "string" + // }, + // "showDeleted": { + // "description": "If true, returns deleted (but unexpired) resources along with active ones.", + // "location": "query", + // "type": "boolean" + // } + // }, + // "path": "v2/{+parent}/tasks", + // "response": { + // "$ref": "GoogleCloudRunV2ListTasksResponse" + // }, + // "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 *ProjectsLocationsJobsExecutionsTasksListCall) Pages(ctx context.Context, f func(*GoogleCloudRunV2ListTasksResponse) 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 "run.projects.locations.operations.delete": type ProjectsLocationsOperationsDeleteCall struct { diff --git a/workflowexecutions/v1/workflowexecutions-api.json b/workflowexecutions/v1/workflowexecutions-api.json index f34e725c05c..6e363f0d0d4 100644 --- a/workflowexecutions/v1/workflowexecutions-api.json +++ b/workflowexecutions/v1/workflowexecutions-api.json @@ -299,7 +299,7 @@ } } }, - "revision": "20220315", + "revision": "20220412", "rootUrl": "https://workflowexecutions.googleapis.com/", "schemas": { "CancelExecutionRequest": { @@ -464,7 +464,7 @@ "type": "string" }, "orderingKey": { - "description": "If non-empty, identifies related messages for which publish order should be respected. If a `Subscription` has `enable_message_ordering` set to `true`, messages published with the same non-empty `ordering_key` value will be delivered to subscribers in the order in which they are received by the Pub/Sub system. All `PubsubMessage`s published in a given `PublishRequest` must specify the same `ordering_key` value.", + "description": "If non-empty, identifies related messages for which publish order should be respected. If a `Subscription` has `enable_message_ordering` set to `true`, messages published with the same non-empty `ordering_key` value will be delivered to subscribers in the order in which they are received by the Pub/Sub system. All `PubsubMessage`s published in a given `PublishRequest` must specify the same `ordering_key` value. For more information, see [ordering messages](https://cloud.google.com/pubsub/docs/ordering).", "type": "string" }, "publishTime": { diff --git a/workflowexecutions/v1/workflowexecutions-gen.go b/workflowexecutions/v1/workflowexecutions-gen.go index c449ee187b3..d1481f6de2a 100644 --- a/workflowexecutions/v1/workflowexecutions-gen.go +++ b/workflowexecutions/v1/workflowexecutions-gen.go @@ -412,7 +412,8 @@ type PubsubMessage struct { // same non-empty `ordering_key` value will be delivered to subscribers // in the order in which they are received by the Pub/Sub system. All // `PubsubMessage`s published in a given `PublishRequest` must specify - // the same `ordering_key` value. + // the same `ordering_key` value. For more information, see ordering + // messages (https://cloud.google.com/pubsub/docs/ordering). OrderingKey string `json:"orderingKey,omitempty"` // PublishTime: The time at which the message was published, populated