From 5f21214e2284f5162d89383f528326325091796c Mon Sep 17 00:00:00 2001 From: Yoshi Automation Bot Date: Sat, 1 Jun 2024 00:22:16 -0700 Subject: [PATCH] feat(all): auto-regenerate discovery clients (#2616) --- .../v1alpha/analyticsadmin-api.json | 45 +- analyticsadmin/v1alpha/analyticsadmin-gen.go | 140 ++ analyticsadmin/v1beta/analyticsadmin-api.json | 45 +- analyticsadmin/v1beta/analyticsadmin-gen.go | 140 ++ calendar/v3/calendar-api.json | 10 +- calendar/v3/calendar-gen.go | 7 +- cloudbuild/v2/cloudbuild-api.json | 4 +- cloudbuild/v2/cloudbuild-gen.go | 2 +- compute/v0.beta/compute-api.json | 54 +- compute/v0.beta/compute-gen.go | 90 +- compute/v0.beta/compute2-gen.go | 2 +- compute/v1/compute-api.json | 34 +- compute/v1/compute-gen.go | 71 +- compute/v1/compute2-gen.go | 2 +- .../v1alpha1/contactcenteraiplatform-api.json | 9 +- .../v1alpha1/contactcenteraiplatform-gen.go | 16 +- .../v1/containeranalysis-api.json | 4 +- containeranalysis/v1/containeranalysis-gen.go | 2 +- .../v1alpha1/containeranalysis-api.json | 4 +- .../v1alpha1/containeranalysis-gen.go | 2 +- .../v1beta1/containeranalysis-api.json | 4 +- .../v1beta1/containeranalysis-gen.go | 2 +- dialogflow/v2/dialogflow-api.json | 623 ++++++- dialogflow/v2/dialogflow-gen.go | 1451 ++++++++++++++++ dialogflow/v2beta1/dialogflow-api.json | 628 ++++++- dialogflow/v2beta1/dialogflow-gen.go | 1455 +++++++++++++++++ displayvideo/v2/displayvideo-api.json | 25 +- displayvideo/v2/displayvideo-gen.go | 13 + displayvideo/v3/displayvideo-api.json | 25 +- displayvideo/v3/displayvideo-gen.go | 13 + dlp/v2/dlp-api.json | 4 +- dlp/v2/dlp-gen.go | 1 + iap/v1/iap-api.json | 4 +- iap/v1/iap-gen.go | 3 +- .../v1alpha/marketingplatformadmin-api.json | 4 +- .../v1/recaptchaenterprise-api.json | 8 +- .../v1/recaptchaenterprise-gen.go | 8 +- run/v1/run-api.json | 54 +- run/v1/run-gen.go | 91 +- run/v2/run-api.json | 46 +- run/v2/run-gen.go | 82 +- secretmanager/v1/secretmanager-api.json | 57 +- secretmanager/v1beta1/secretmanager-api.json | 57 +- secretmanager/v1beta2/secretmanager-api.json | 57 +- .../v1/servicenetworking-api.json | 4 +- servicenetworking/v1/servicenetworking-gen.go | 124 +- .../v1beta/servicenetworking-api.json | 4 +- .../v1beta/servicenetworking-gen.go | 124 +- versionhistory/v1/versionhistory-api.json | 6 +- versionhistory/v1/versionhistory-gen.go | 2 + 50 files changed, 5279 insertions(+), 383 deletions(-) diff --git a/analyticsadmin/v1alpha/analyticsadmin-api.json b/analyticsadmin/v1alpha/analyticsadmin-api.json index f1e2394197b..e432d863c04 100644 --- a/analyticsadmin/v1alpha/analyticsadmin-api.json +++ b/analyticsadmin/v1alpha/analyticsadmin-api.json @@ -3016,6 +3016,35 @@ } } }, + "eventEditRules": { + "methods": { + "reorder": { + "description": "Changes the processing order of event edit rules on the specified stream.", + "flatPath": "v1alpha/properties/{propertiesId}/dataStreams/{dataStreamsId}/eventEditRules:reorder", + "httpMethod": "POST", + "id": "analyticsadmin.properties.dataStreams.eventEditRules.reorder", + "parameterOrder": [ + "parent" + ], + "parameters": { + "parent": { + "description": "Required. Example format: properties/123/dataStreams/456", + "location": "path", + "pattern": "^properties/[^/]+/dataStreams/[^/]+$", + "required": true, + "type": "string" + } + }, + "path": "v1alpha/{+parent}/eventEditRules:reorder", + "request": { + "$ref": "GoogleAnalyticsAdminV1alphaReorderEventEditRulesRequest" + }, + "response": { + "$ref": "GoogleProtobufEmpty" + } + } + } + }, "measurementProtocolSecrets": { "methods": { "create": { @@ -4617,7 +4646,7 @@ } } }, - "revision": "20240517", + "revision": "20240529", "rootUrl": "https://analyticsadmin.googleapis.com/", "schemas": { "GoogleAnalyticsAdminV1alphaAccessBetweenFilter": { @@ -8206,6 +8235,20 @@ }, "type": "object" }, + "GoogleAnalyticsAdminV1alphaReorderEventEditRulesRequest": { + "description": "Request message for ReorderEventEditRules RPC.", + "id": "GoogleAnalyticsAdminV1alphaReorderEventEditRulesRequest", + "properties": { + "eventEditRules": { + "description": "Required. EventEditRule resource names for the specified data stream, in the needed processing order. All EventEditRules for the stream must be present in the list.", + "items": { + "type": "string" + }, + "type": "array" + } + }, + "type": "object" + }, "GoogleAnalyticsAdminV1alphaRollupPropertySourceLink": { "description": "A link that references a source property under the parent rollup property.", "id": "GoogleAnalyticsAdminV1alphaRollupPropertySourceLink", diff --git a/analyticsadmin/v1alpha/analyticsadmin-gen.go b/analyticsadmin/v1alpha/analyticsadmin-gen.go index 91636078053..89ea203b350 100644 --- a/analyticsadmin/v1alpha/analyticsadmin-gen.go +++ b/analyticsadmin/v1alpha/analyticsadmin-gen.go @@ -356,6 +356,7 @@ type PropertiesCustomMetricsService struct { func NewPropertiesDataStreamsService(s *Service) *PropertiesDataStreamsService { rs := &PropertiesDataStreamsService{s: s} rs.EventCreateRules = NewPropertiesDataStreamsEventCreateRulesService(s) + rs.EventEditRules = NewPropertiesDataStreamsEventEditRulesService(s) rs.MeasurementProtocolSecrets = NewPropertiesDataStreamsMeasurementProtocolSecretsService(s) rs.SKAdNetworkConversionValueSchema = NewPropertiesDataStreamsSKAdNetworkConversionValueSchemaService(s) return rs @@ -366,6 +367,8 @@ type PropertiesDataStreamsService struct { EventCreateRules *PropertiesDataStreamsEventCreateRulesService + EventEditRules *PropertiesDataStreamsEventEditRulesService + MeasurementProtocolSecrets *PropertiesDataStreamsMeasurementProtocolSecretsService SKAdNetworkConversionValueSchema *PropertiesDataStreamsSKAdNetworkConversionValueSchemaService @@ -380,6 +383,15 @@ type PropertiesDataStreamsEventCreateRulesService struct { s *Service } +func NewPropertiesDataStreamsEventEditRulesService(s *Service) *PropertiesDataStreamsEventEditRulesService { + rs := &PropertiesDataStreamsEventEditRulesService{s: s} + return rs +} + +type PropertiesDataStreamsEventEditRulesService struct { + s *Service +} + func NewPropertiesDataStreamsMeasurementProtocolSecretsService(s *Service) *PropertiesDataStreamsMeasurementProtocolSecretsService { rs := &PropertiesDataStreamsMeasurementProtocolSecretsService{s: s} return rs @@ -5437,6 +5449,31 @@ func (s *GoogleAnalyticsAdminV1alphaProvisionAccountTicketResponse) MarshalJSON( return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) } +// GoogleAnalyticsAdminV1alphaReorderEventEditRulesRequest: Request message for +// ReorderEventEditRules RPC. +type GoogleAnalyticsAdminV1alphaReorderEventEditRulesRequest struct { + // EventEditRules: Required. EventEditRule resource names for the specified + // data stream, in the needed processing order. All EventEditRules for the + // stream must be present in the list. + EventEditRules []string `json:"eventEditRules,omitempty"` + // ForceSendFields is a list of field names (e.g. "EventEditRules") to + // unconditionally include in API requests. By default, fields with empty or + // default values are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. + ForceSendFields []string `json:"-"` + // NullFields is a list of field names (e.g. "EventEditRules") to include in + // API requests with the JSON null value. By default, fields with empty values + // are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. + NullFields []string `json:"-"` +} + +func (s *GoogleAnalyticsAdminV1alphaReorderEventEditRulesRequest) MarshalJSON() ([]byte, error) { + type NoMethod GoogleAnalyticsAdminV1alphaReorderEventEditRulesRequest + return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) +} + // GoogleAnalyticsAdminV1alphaRollupPropertySourceLink: A link that references // a source property under the parent rollup property. type GoogleAnalyticsAdminV1alphaRollupPropertySourceLink struct { @@ -17263,6 +17300,109 @@ func (c *PropertiesDataStreamsEventCreateRulesPatchCall) Do(opts ...googleapi.Ca return ret, nil } +type PropertiesDataStreamsEventEditRulesReorderCall struct { + s *Service + parent string + googleanalyticsadminv1alphareordereventeditrulesrequest *GoogleAnalyticsAdminV1alphaReorderEventEditRulesRequest + urlParams_ gensupport.URLParams + ctx_ context.Context + header_ http.Header +} + +// Reorder: Changes the processing order of event edit rules on the specified +// stream. +// +// - parent: Example format: properties/123/dataStreams/456. +func (r *PropertiesDataStreamsEventEditRulesService) Reorder(parent string, googleanalyticsadminv1alphareordereventeditrulesrequest *GoogleAnalyticsAdminV1alphaReorderEventEditRulesRequest) *PropertiesDataStreamsEventEditRulesReorderCall { + c := &PropertiesDataStreamsEventEditRulesReorderCall{s: r.s, urlParams_: make(gensupport.URLParams)} + c.parent = parent + c.googleanalyticsadminv1alphareordereventeditrulesrequest = googleanalyticsadminv1alphareordereventeditrulesrequest + return c +} + +// Fields allows partial responses to be retrieved. See +// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more +// details. +func (c *PropertiesDataStreamsEventEditRulesReorderCall) Fields(s ...googleapi.Field) *PropertiesDataStreamsEventEditRulesReorderCall { + c.urlParams_.Set("fields", googleapi.CombineFields(s)) + return c +} + +// Context sets the context to be used in this call's Do method. +func (c *PropertiesDataStreamsEventEditRulesReorderCall) Context(ctx context.Context) *PropertiesDataStreamsEventEditRulesReorderCall { + c.ctx_ = ctx + return c +} + +// Header returns a http.Header that can be modified by the caller to add +// headers to the request. +func (c *PropertiesDataStreamsEventEditRulesReorderCall) Header() http.Header { + if c.header_ == nil { + c.header_ = make(http.Header) + } + return c.header_ +} + +func (c *PropertiesDataStreamsEventEditRulesReorderCall) doRequest(alt string) (*http.Response, error) { + reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "application/json", c.header_) + var body io.Reader = nil + body, err := googleapi.WithoutDataWrapper.JSONReader(c.googleanalyticsadminv1alphareordereventeditrulesrequest) + if err != nil { + return nil, err + } + c.urlParams_.Set("alt", alt) + c.urlParams_.Set("prettyPrint", "false") + urls := googleapi.ResolveRelative(c.s.BasePath, "v1alpha/{+parent}/eventEditRules:reorder") + 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 "analyticsadmin.properties.dataStreams.eventEditRules.reorder" call. +// Any non-2xx status code is an error. Response headers are in either +// *GoogleProtobufEmpty.ServerResponse.Header or (if a response was returned at +// all) in error.(*googleapi.Error).Header. Use googleapi.IsNotModified to +// check whether the returned error was because http.StatusNotModified was +// returned. +func (c *PropertiesDataStreamsEventEditRulesReorderCall) Do(opts ...googleapi.CallOption) (*GoogleProtobufEmpty, error) { + gensupport.SetOptions(c.urlParams_, opts...) + res, err := c.doRequest("json") + if res != nil && res.StatusCode == http.StatusNotModified { + if res.Body != nil { + res.Body.Close() + } + return nil, gensupport.WrapError(&googleapi.Error{ + Code: res.StatusCode, + Header: res.Header, + }) + } + if err != nil { + return nil, err + } + defer googleapi.CloseBody(res) + if err := googleapi.CheckResponse(res); err != nil { + return nil, gensupport.WrapError(err) + } + ret := &GoogleProtobufEmpty{ + ServerResponse: googleapi.ServerResponse{ + Header: res.Header, + HTTPStatusCode: res.StatusCode, + }, + } + target := &ret + if err := gensupport.DecodeResponse(target, res); err != nil { + return nil, err + } + return ret, nil +} + type PropertiesDataStreamsMeasurementProtocolSecretsCreateCall struct { s *Service parent string diff --git a/analyticsadmin/v1beta/analyticsadmin-api.json b/analyticsadmin/v1beta/analyticsadmin-api.json index 1aabeb7a321..3a11a33dc20 100644 --- a/analyticsadmin/v1beta/analyticsadmin-api.json +++ b/analyticsadmin/v1beta/analyticsadmin-api.json @@ -1253,6 +1253,35 @@ } }, "resources": { + "eventEditRules": { + "methods": { + "reorder": { + "description": "Changes the processing order of event edit rules on the specified stream.", + "flatPath": "v1beta/properties/{propertiesId}/dataStreams/{dataStreamsId}/eventEditRules:reorder", + "httpMethod": "POST", + "id": "analyticsadmin.properties.dataStreams.eventEditRules.reorder", + "parameterOrder": [ + "parent" + ], + "parameters": { + "parent": { + "description": "Required. Example format: properties/123/dataStreams/456", + "location": "path", + "pattern": "^properties/[^/]+/dataStreams/[^/]+$", + "required": true, + "type": "string" + } + }, + "path": "v1beta/{+parent}/eventEditRules:reorder", + "request": { + "$ref": "GoogleAnalyticsAdminV1betaReorderEventEditRulesRequest" + }, + "response": { + "$ref": "GoogleProtobufEmpty" + } + } + } + }, "measurementProtocolSecrets": { "methods": { "create": { @@ -1788,7 +1817,7 @@ } } }, - "revision": "20240402", + "revision": "20240529", "rootUrl": "https://analyticsadmin.googleapis.com/", "schemas": { "GoogleAnalyticsAdminV1betaAccessBetweenFilter": { @@ -3323,6 +3352,20 @@ }, "type": "object" }, + "GoogleAnalyticsAdminV1betaReorderEventEditRulesRequest": { + "description": "Request message for ReorderEventEditRules RPC.", + "id": "GoogleAnalyticsAdminV1betaReorderEventEditRulesRequest", + "properties": { + "eventEditRules": { + "description": "Required. EventEditRule resource names for the specified data stream, in the needed processing order. All EventEditRules for the stream must be present in the list.", + "items": { + "type": "string" + }, + "type": "array" + } + }, + "type": "object" + }, "GoogleAnalyticsAdminV1betaRunAccessReportRequest": { "description": "The request for a Data Access Record Report.", "id": "GoogleAnalyticsAdminV1betaRunAccessReportRequest", diff --git a/analyticsadmin/v1beta/analyticsadmin-gen.go b/analyticsadmin/v1beta/analyticsadmin-gen.go index 1550c16bd2f..00867fbc062 100644 --- a/analyticsadmin/v1beta/analyticsadmin-gen.go +++ b/analyticsadmin/v1beta/analyticsadmin-gen.go @@ -245,6 +245,7 @@ type PropertiesCustomMetricsService struct { func NewPropertiesDataStreamsService(s *Service) *PropertiesDataStreamsService { rs := &PropertiesDataStreamsService{s: s} + rs.EventEditRules = NewPropertiesDataStreamsEventEditRulesService(s) rs.MeasurementProtocolSecrets = NewPropertiesDataStreamsMeasurementProtocolSecretsService(s) return rs } @@ -252,9 +253,20 @@ func NewPropertiesDataStreamsService(s *Service) *PropertiesDataStreamsService { type PropertiesDataStreamsService struct { s *Service + EventEditRules *PropertiesDataStreamsEventEditRulesService + MeasurementProtocolSecrets *PropertiesDataStreamsMeasurementProtocolSecretsService } +func NewPropertiesDataStreamsEventEditRulesService(s *Service) *PropertiesDataStreamsEventEditRulesService { + rs := &PropertiesDataStreamsEventEditRulesService{s: s} + return rs +} + +type PropertiesDataStreamsEventEditRulesService struct { + s *Service +} + func NewPropertiesDataStreamsMeasurementProtocolSecretsService(s *Service) *PropertiesDataStreamsMeasurementProtocolSecretsService { rs := &PropertiesDataStreamsMeasurementProtocolSecretsService{s: s} return rs @@ -2334,6 +2346,31 @@ func (s *GoogleAnalyticsAdminV1betaProvisionAccountTicketResponse) MarshalJSON() return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) } +// GoogleAnalyticsAdminV1betaReorderEventEditRulesRequest: Request message for +// ReorderEventEditRules RPC. +type GoogleAnalyticsAdminV1betaReorderEventEditRulesRequest struct { + // EventEditRules: Required. EventEditRule resource names for the specified + // data stream, in the needed processing order. All EventEditRules for the + // stream must be present in the list. + EventEditRules []string `json:"eventEditRules,omitempty"` + // ForceSendFields is a list of field names (e.g. "EventEditRules") to + // unconditionally include in API requests. By default, fields with empty or + // default values are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. + ForceSendFields []string `json:"-"` + // NullFields is a list of field names (e.g. "EventEditRules") to include in + // API requests with the JSON null value. By default, fields with empty values + // are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. + NullFields []string `json:"-"` +} + +func (s *GoogleAnalyticsAdminV1betaReorderEventEditRulesRequest) MarshalJSON() ([]byte, error) { + type NoMethod GoogleAnalyticsAdminV1betaReorderEventEditRulesRequest + return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) +} + // GoogleAnalyticsAdminV1betaRunAccessReportRequest: The request for a Data // Access Record Report. type GoogleAnalyticsAdminV1betaRunAccessReportRequest struct { @@ -6964,6 +7001,109 @@ func (c *PropertiesDataStreamsPatchCall) Do(opts ...googleapi.CallOption) (*Goog return ret, nil } +type PropertiesDataStreamsEventEditRulesReorderCall struct { + s *Service + parent string + googleanalyticsadminv1betareordereventeditrulesrequest *GoogleAnalyticsAdminV1betaReorderEventEditRulesRequest + urlParams_ gensupport.URLParams + ctx_ context.Context + header_ http.Header +} + +// Reorder: Changes the processing order of event edit rules on the specified +// stream. +// +// - parent: Example format: properties/123/dataStreams/456. +func (r *PropertiesDataStreamsEventEditRulesService) Reorder(parent string, googleanalyticsadminv1betareordereventeditrulesrequest *GoogleAnalyticsAdminV1betaReorderEventEditRulesRequest) *PropertiesDataStreamsEventEditRulesReorderCall { + c := &PropertiesDataStreamsEventEditRulesReorderCall{s: r.s, urlParams_: make(gensupport.URLParams)} + c.parent = parent + c.googleanalyticsadminv1betareordereventeditrulesrequest = googleanalyticsadminv1betareordereventeditrulesrequest + return c +} + +// Fields allows partial responses to be retrieved. See +// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more +// details. +func (c *PropertiesDataStreamsEventEditRulesReorderCall) Fields(s ...googleapi.Field) *PropertiesDataStreamsEventEditRulesReorderCall { + c.urlParams_.Set("fields", googleapi.CombineFields(s)) + return c +} + +// Context sets the context to be used in this call's Do method. +func (c *PropertiesDataStreamsEventEditRulesReorderCall) Context(ctx context.Context) *PropertiesDataStreamsEventEditRulesReorderCall { + c.ctx_ = ctx + return c +} + +// Header returns a http.Header that can be modified by the caller to add +// headers to the request. +func (c *PropertiesDataStreamsEventEditRulesReorderCall) Header() http.Header { + if c.header_ == nil { + c.header_ = make(http.Header) + } + return c.header_ +} + +func (c *PropertiesDataStreamsEventEditRulesReorderCall) doRequest(alt string) (*http.Response, error) { + reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "application/json", c.header_) + var body io.Reader = nil + body, err := googleapi.WithoutDataWrapper.JSONReader(c.googleanalyticsadminv1betareordereventeditrulesrequest) + if err != nil { + return nil, err + } + c.urlParams_.Set("alt", alt) + c.urlParams_.Set("prettyPrint", "false") + urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta/{+parent}/eventEditRules:reorder") + 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 "analyticsadmin.properties.dataStreams.eventEditRules.reorder" call. +// Any non-2xx status code is an error. Response headers are in either +// *GoogleProtobufEmpty.ServerResponse.Header or (if a response was returned at +// all) in error.(*googleapi.Error).Header. Use googleapi.IsNotModified to +// check whether the returned error was because http.StatusNotModified was +// returned. +func (c *PropertiesDataStreamsEventEditRulesReorderCall) Do(opts ...googleapi.CallOption) (*GoogleProtobufEmpty, error) { + gensupport.SetOptions(c.urlParams_, opts...) + res, err := c.doRequest("json") + if res != nil && res.StatusCode == http.StatusNotModified { + if res.Body != nil { + res.Body.Close() + } + return nil, gensupport.WrapError(&googleapi.Error{ + Code: res.StatusCode, + Header: res.Header, + }) + } + if err != nil { + return nil, err + } + defer googleapi.CloseBody(res) + if err := googleapi.CheckResponse(res); err != nil { + return nil, gensupport.WrapError(err) + } + ret := &GoogleProtobufEmpty{ + ServerResponse: googleapi.ServerResponse{ + Header: res.Header, + HTTPStatusCode: res.StatusCode, + }, + } + target := &ret + if err := gensupport.DecodeResponse(target, res); err != nil { + return nil, err + } + return ret, nil +} + type PropertiesDataStreamsMeasurementProtocolSecretsCreateCall struct { s *Service parent string diff --git a/calendar/v3/calendar-api.json b/calendar/v3/calendar-api.json index 246c70bbb0f..c51dc20f383 100644 --- a/calendar/v3/calendar-api.json +++ b/calendar/v3/calendar-api.json @@ -1092,12 +1092,14 @@ "enum": [ "default", "focusTime", + "fromGmail", "outOfOffice", "workingLocation" ], "enumDescriptions": [ "Regular events.", "Focus time events.", + "Events from Gmail.", "Out of office events.", "Working location events." ], @@ -1217,7 +1219,7 @@ "supportsSubscription": true }, "move": { - "description": "Moves an event to another calendar, i.e. changes an event's organizer. Note that only default events can be moved; outOfOffice, focusTime and workingLocation events cannot be moved.", + "description": "Moves an event to another calendar, i.e. changes an event's organizer. Note that only default events can be moved; outOfOffice, focusTime, workingLocation and fromGmail events cannot be moved.", "httpMethod": "POST", "id": "calendar.events.move", "parameterOrder": [ @@ -1507,12 +1509,14 @@ "enum": [ "default", "focusTime", + "fromGmail", "outOfOffice", "workingLocation" ], "enumDescriptions": [ "Regular events.", "Focus time events.", + "Events from Gmail.", "Out of office events.", "Working location events." ], @@ -1759,7 +1763,7 @@ } } }, - "revision": "20240419", + "revision": "20240523", "rootUrl": "https://www.googleapis.com/", "schemas": { "Acl": { @@ -2416,7 +2420,7 @@ }, "eventType": { "default": "default", - "description": "Specific type of the event. This cannot be modified after the event is created. Possible values are: \n- \"default\" - A regular event or not further specified. \n- \"outOfOffice\" - An out-of-office event. \n- \"focusTime\" - A focus-time event. \n- \"workingLocation\" - A working location event.", + "description": "Specific type of the event. This cannot be modified after the event is created. Possible values are: \n- \"default\" - A regular event or not further specified. \n- \"outOfOffice\" - An out-of-office event. \n- \"focusTime\" - A focus-time event. \n- \"workingLocation\" - A working location event. \n- \"fromGmail\" - An event from Gmail. This type of event cannot be created.", "type": "string" }, "extendedProperties": { diff --git a/calendar/v3/calendar-gen.go b/calendar/v3/calendar-gen.go index 921dbe9dafd..a5e1e29f4b3 100644 --- a/calendar/v3/calendar-gen.go +++ b/calendar/v3/calendar-gen.go @@ -1121,6 +1121,7 @@ type Event struct { // - "outOfOffice" - An out-of-office event. // - "focusTime" - A focus-time event. // - "workingLocation" - A working location event. + // - "fromGmail" - An event from Gmail. This type of event cannot be created. EventType string `json:"eventType,omitempty"` // ExtendedProperties: Extended properties of the event. ExtendedProperties *EventExtendedProperties `json:"extendedProperties,omitempty"` @@ -5285,6 +5286,7 @@ func (c *EventsListCall) AlwaysIncludeEmail(alwaysIncludeEmail bool) *EventsList // // "default" - Regular events. // "focusTime" - Focus time events. +// "fromGmail" - Events from Gmail. // "outOfOffice" - Out of office events. // "workingLocation" - Working location events. func (c *EventsListCall) EventTypes(eventTypes ...string) *EventsListCall { @@ -5601,8 +5603,8 @@ type EventsMoveCall struct { } // Move: Moves an event to another calendar, i.e. changes an event's organizer. -// Note that only default events can be moved; outOfOffice, focusTime and -// workingLocation events cannot be moved. +// Note that only default events can be moved; outOfOffice, focusTime, +// workingLocation and fromGmail events cannot be moved. // // - calendarId: Calendar identifier of the source calendar where the event // currently is on. @@ -6235,6 +6237,7 @@ func (c *EventsWatchCall) AlwaysIncludeEmail(alwaysIncludeEmail bool) *EventsWat // // "default" - Regular events. // "focusTime" - Focus time events. +// "fromGmail" - Events from Gmail. // "outOfOffice" - Out of office events. // "workingLocation" - Working location events. func (c *EventsWatchCall) EventTypes(eventTypes ...string) *EventsWatchCall { diff --git a/cloudbuild/v2/cloudbuild-api.json b/cloudbuild/v2/cloudbuild-api.json index b3c26362e50..bae79739ac2 100644 --- a/cloudbuild/v2/cloudbuild-api.json +++ b/cloudbuild/v2/cloudbuild-api.json @@ -844,7 +844,7 @@ } } }, - "revision": "20240519", + "revision": "20240528", "rootUrl": "https://cloudbuild.googleapis.com/", "schemas": { "AuditConfig": { @@ -977,7 +977,7 @@ "description": "Required. A http access token with the `REPO_ADMIN` scope access." }, "hostUri": { - "description": "Optional. The URI of the Bitbucket Data Center instance or cluster this connection is for.", + "description": "Required. The URI of the Bitbucket Data Center instance or cluster this connection is for.", "type": "string" }, "readAuthorizerCredential": { diff --git a/cloudbuild/v2/cloudbuild-gen.go b/cloudbuild/v2/cloudbuild-gen.go index 1a2696cb4c0..a3167b10261 100644 --- a/cloudbuild/v2/cloudbuild-gen.go +++ b/cloudbuild/v2/cloudbuild-gen.go @@ -475,7 +475,7 @@ type BitbucketDataCenterConfig struct { // AuthorizerCredential: Required. A http access token with the `REPO_ADMIN` // scope access. AuthorizerCredential *UserCredential `json:"authorizerCredential,omitempty"` - // HostUri: Optional. The URI of the Bitbucket Data Center instance or cluster + // HostUri: Required. The URI of the Bitbucket Data Center instance or cluster // this connection is for. HostUri string `json:"hostUri,omitempty"` // ReadAuthorizerCredential: Required. A http access token with the `REPO_READ` diff --git a/compute/v0.beta/compute-api.json b/compute/v0.beta/compute-api.json index 5245aaab005..fc48228646b 100644 --- a/compute/v0.beta/compute-api.json +++ b/compute/v0.beta/compute-api.json @@ -18152,7 +18152,7 @@ ] }, "patch": { - "description": "Patches the specified network with the data included in the request. Only the following fields can be modified: routingConfig.routingMode.", + "description": "Patches the specified network with the data included in the request. Only routingConfig can be modified.", "flatPath": "projects/{project}/global/networks/{network}", "httpMethod": "PATCH", "id": "compute.networks.patch", @@ -41579,7 +41579,7 @@ } } }, - "revision": "20240519", + "revision": "20240526", "rootUrl": "https://compute.googleapis.com/", "schemas": { "AWSV4Signature": { @@ -43157,7 +43157,7 @@ "description": "[Output Only] shielded vm initial state stored on disk" }, "source": { - "description": "Specifies a valid partial or full URL to an existing Persistent Disk resource. When creating a new instance, one of initializeParams.sourceImage or initializeParams.sourceSnapshot or disks.source is required except for local SSD. If desired, you can also attach existing non-root persistent disks using this property. This field is only applicable for persistent disks. Note that for InstanceTemplate, specify the disk name for zonal disk, and the URL for regional disk.", + "description": "Specifies a valid partial or full URL to an existing Persistent Disk resource. When creating a new instance boot disk, one of initializeParams.sourceImage or initializeParams.sourceSnapshot or disks.source is required. If desired, you can also attach existing non-root persistent disks using this property. This field is only applicable for persistent disks. Note that for InstanceTemplate, specify the disk name for zonal disk, and the URL for regional disk.", "type": "string" }, "type": { @@ -43292,7 +43292,7 @@ "type": "array" }, "sourceImage": { - "description": "The source image to create this disk. When creating a new instance, one of initializeParams.sourceImage or initializeParams.sourceSnapshot or disks.source is required except for local SSD. To create a disk with one of the public operating system images, specify the image by its family name. For example, specify family/debian-9 to use the latest Debian 9 image: projects/debian-cloud/global/images/family/debian-9 Alternatively, use a specific version of a public operating system image: projects/debian-cloud/global/images/debian-9-stretch-vYYYYMMDD To create a disk with a custom image that you created, specify the image name in the following format: global/images/my-custom-image You can also specify a custom image by its image family, which returns the latest version of the image in that family. Replace the image name with family/family-name: global/images/family/my-image-family If the source image is deleted later, this field will not be set.", + "description": "The source image to create this disk. When creating a new instance boot disk, one of initializeParams.sourceImage or initializeParams.sourceSnapshot or disks.source is required. To create a disk with one of the public operating system images, specify the image by its family name. For example, specify family/debian-9 to use the latest Debian 9 image: projects/debian-cloud/global/images/family/debian-9 Alternatively, use a specific version of a public operating system image: projects/debian-cloud/global/images/debian-9-stretch-vYYYYMMDD To create a disk with a custom image that you created, specify the image name in the following format: global/images/my-custom-image You can also specify a custom image by its image family, which returns the latest version of the image in that family. Replace the image name with family/family-name: global/images/family/my-image-family If the source image is deleted later, this field will not be set.", "type": "string" }, "sourceImageEncryptionKey": { @@ -43300,11 +43300,11 @@ "description": "The customer-supplied encryption key of the source image. Required if the source image is protected by a customer-supplied encryption key. InstanceTemplate and InstancePropertiesPatch do not store customer-supplied encryption keys, so you cannot create disks for instances in a managed instance group if the source images are encrypted with your own keys." }, "sourceInstantSnapshot": { - "description": "The source instant-snapshot to create this disk. When creating a new instance, one of initializeParams.sourceSnapshot or initializeParams.sourceInstantSnapshot initializeParams.sourceImage or disks.source is required except for local SSD. To create a disk with a snapshot that you created, specify the snapshot name in the following format: us-central1-a/instantSnapshots/my-backup If the source instant-snapshot is deleted later, this field will not be set.", + "description": "The source instant-snapshot to create this disk. When creating a new instance boot disk, one of initializeParams.sourceSnapshot or initializeParams.sourceInstantSnapshot initializeParams.sourceImage or disks.source is required. To create a disk with a snapshot that you created, specify the snapshot name in the following format: us-central1-a/instantSnapshots/my-backup If the source instant-snapshot is deleted later, this field will not be set.", "type": "string" }, "sourceSnapshot": { - "description": "The source snapshot to create this disk. When creating a new instance, one of initializeParams.sourceSnapshot or initializeParams.sourceImage or disks.source is required except for local SSD. To create a disk with a snapshot that you created, specify the snapshot name in the following format: global/snapshots/my-backup If the source snapshot is deleted later, this field will not be set.", + "description": "The source snapshot to create this disk. When creating a new instance boot disk, one of initializeParams.sourceSnapshot or initializeParams.sourceImage or disks.source is required. To create a disk with a snapshot that you created, specify the snapshot name in the following format: global/snapshots/my-backup If the source snapshot is deleted later, this field will not be set.", "type": "string" }, "sourceSnapshotEncryptionKey": { @@ -55415,6 +55415,14 @@ "description": "[Output Only] The URL of the region where the managed instance group resides (for regional resources).", "type": "string" }, + "satisfiesPzi": { + "description": "[Output Only] Reserved for future use.", + "type": "boolean" + }, + "satisfiesPzs": { + "description": "[Output Only] Reserved for future use.", + "type": "boolean" + }, "selfLink": { "description": "[Output Only] The URL for this managed instance group. The server defines this URL.", "type": "string" @@ -55752,6 +55760,10 @@ }, "description": "Named instance selections configuring properties that the group will use when creating new VMs.", "type": "object" + }, + "provisioningModelMix": { + "$ref": "InstanceGroupManagerInstanceFlexibilityPolicyProvisioningModelMix", + "description": "Provisioning model configuration used by this managed instance group to create instances." } }, "type": "object" @@ -55774,6 +55786,22 @@ }, "type": "object" }, + "InstanceGroupManagerInstanceFlexibilityPolicyProvisioningModelMix": { + "id": "InstanceGroupManagerInstanceFlexibilityPolicyProvisioningModelMix", + "properties": { + "standardCapacityBase": { + "description": "The base capacity that will always use Standard VMs to avoid risk of more preemption than the minimum capacity user needs. MIG will create only Standard VMs until it reaches standard_capacity_base and only then will start using standard_capacity_percent_above_base to mix Spot with Standard VMs.", + "format": "int32", + "type": "integer" + }, + "standardCapacityPercentAboveBase": { + "description": "The percentage of target capacity that should use Standard VM. The remaining percentage will use Spot VMs. The percentage applies only to the capacity above standard_capacity_base.", + "format": "int32", + "type": "integer" + } + }, + "type": "object" + }, "InstanceGroupManagerInstanceLifecyclePolicy": { "id": "InstanceGroupManagerInstanceLifecyclePolicy", "properties": { @@ -63357,6 +63385,18 @@ "machineType": { "description": "The machine type to be used for this instance.", "type": "string" + }, + "provisioningModel": { + "description": "The provisioning model to be used for this instance.", + "enum": [ + "SPOT", + "STANDARD" + ], + "enumDescriptions": [ + "Heavily discounted, no guaranteed runtime.", + "Standard provisioning with user controlled runtime, no discounts." + ], + "type": "string" } }, "type": "object" @@ -91013,7 +91053,7 @@ "type": "object" }, "Zone": { - "description": "Represents a Zone resource. A zone is a deployment area. These deployment areas are subsets of a region. For example the zone us-east1-a is located in the us-east1 region. For more information, read Regions and Zones.", + "description": "Represents a Zone resource. A zone is a deployment area. These deployment areas are subsets of a region. For example the zone us-east1-b is located in the us-east1 region. For more information, read Regions and Zones.", "id": "Zone", "properties": { "availableCpuPlatforms": { diff --git a/compute/v0.beta/compute-gen.go b/compute/v0.beta/compute-gen.go index 673494914e8..75769462506 100644 --- a/compute/v0.beta/compute-gen.go +++ b/compute/v0.beta/compute-gen.go @@ -3108,12 +3108,12 @@ type AttachedDisk struct { // on disk ShieldedInstanceInitialState *InitialStateConfig `json:"shieldedInstanceInitialState,omitempty"` // Source: Specifies a valid partial or full URL to an existing Persistent Disk - // resource. When creating a new instance, one of initializeParams.sourceImage - // or initializeParams.sourceSnapshot or disks.source is required except for - // local SSD. If desired, you can also attach existing non-root persistent - // disks using this property. This field is only applicable for persistent - // disks. Note that for InstanceTemplate, specify the disk name for zonal disk, - // and the URL for regional disk. + // resource. When creating a new instance boot disk, one of + // initializeParams.sourceImage or initializeParams.sourceSnapshot or + // disks.source is required. If desired, you can also attach existing non-root + // persistent disks using this property. This field is only applicable for + // persistent disks. Note that for InstanceTemplate, specify the disk name for + // zonal disk, and the URL for regional disk. Source string `json:"source,omitempty"` // Type: Specifies the type of the disk, either SCRATCH or PERSISTENT. If not // specified, the default is PERSISTENT. @@ -3235,13 +3235,12 @@ type AttachedDiskInitializeParams struct { // template, specify only the resource policy name. ResourcePolicies []string `json:"resourcePolicies,omitempty"` // SourceImage: The source image to create this disk. When creating a new - // instance, one of initializeParams.sourceImage or - // initializeParams.sourceSnapshot or disks.source is required except for local - // SSD. To create a disk with one of the public operating system images, - // specify the image by its family name. For example, specify family/debian-9 - // to use the latest Debian 9 image: - // projects/debian-cloud/global/images/family/debian-9 Alternatively, use a - // specific version of a public operating system image: + // instance boot disk, one of initializeParams.sourceImage or + // initializeParams.sourceSnapshot or disks.source is required. To create a + // disk with one of the public operating system images, specify the image by + // its family name. For example, specify family/debian-9 to use the latest + // Debian 9 image: projects/debian-cloud/global/images/family/debian-9 + // Alternatively, use a specific version of a public operating system image: // projects/debian-cloud/global/images/debian-9-stretch-vYYYYMMDD To create a // disk with a custom image that you created, specify the image name in the // following format: global/images/my-custom-image You can also specify a @@ -3258,19 +3257,19 @@ type AttachedDiskInitializeParams struct { // keys. SourceImageEncryptionKey *CustomerEncryptionKey `json:"sourceImageEncryptionKey,omitempty"` // SourceInstantSnapshot: The source instant-snapshot to create this disk. When - // creating a new instance, one of initializeParams.sourceSnapshot or + // creating a new instance boot disk, one of initializeParams.sourceSnapshot or // initializeParams.sourceInstantSnapshot initializeParams.sourceImage or - // disks.source is required except for local SSD. To create a disk with a - // snapshot that you created, specify the snapshot name in the following - // format: us-central1-a/instantSnapshots/my-backup If the source - // instant-snapshot is deleted later, this field will not be set. + // disks.source is required. To create a disk with a snapshot that you created, + // specify the snapshot name in the following format: + // us-central1-a/instantSnapshots/my-backup If the source instant-snapshot is + // deleted later, this field will not be set. SourceInstantSnapshot string `json:"sourceInstantSnapshot,omitempty"` // SourceSnapshot: The source snapshot to create this disk. When creating a new - // instance, one of initializeParams.sourceSnapshot or - // initializeParams.sourceImage or disks.source is required except for local - // SSD. To create a disk with a snapshot that you created, specify the snapshot - // name in the following format: global/snapshots/my-backup If the source - // snapshot is deleted later, this field will not be set. + // instance boot disk, one of initializeParams.sourceSnapshot or + // initializeParams.sourceImage or disks.source is required. To create a disk + // with a snapshot that you created, specify the snapshot name in the following + // format: global/snapshots/my-backup If the source snapshot is deleted later, + // this field will not be set. SourceSnapshot string `json:"sourceSnapshot,omitempty"` // SourceSnapshotEncryptionKey: The customer-supplied encryption key of the // source snapshot. @@ -17422,6 +17421,10 @@ type InstanceGroupManager struct { // Region: [Output Only] The URL of the region where the managed instance group // resides (for regional resources). Region string `json:"region,omitempty"` + // SatisfiesPzi: [Output Only] Reserved for future use. + SatisfiesPzi bool `json:"satisfiesPzi,omitempty"` + // SatisfiesPzs: [Output Only] Reserved for future use. + SatisfiesPzs bool `json:"satisfiesPzs,omitempty"` // SelfLink: [Output Only] The URL for this managed instance group. The server // defines this URL. SelfLink string `json:"selfLink,omitempty"` @@ -17782,6 +17785,9 @@ type InstanceGroupManagerInstanceFlexibilityPolicy struct { // InstanceSelections: Named instance selections configuring properties that // the group will use when creating new VMs. InstanceSelections map[string]InstanceGroupManagerInstanceFlexibilityPolicyInstanceSelection `json:"instanceSelections,omitempty"` + // ProvisioningModelMix: Provisioning model configuration used by this managed + // instance group to create instances. + ProvisioningModelMix *InstanceGroupManagerInstanceFlexibilityPolicyProvisioningModelMix `json:"provisioningModelMix,omitempty"` // ForceSendFields is a list of field names (e.g. "InstanceSelectionLists") to // unconditionally include in API requests. By default, fields with empty or // default values are omitted from API requests. See @@ -17826,6 +17832,35 @@ func (s *InstanceGroupManagerInstanceFlexibilityPolicyInstanceSelection) Marshal return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) } +type InstanceGroupManagerInstanceFlexibilityPolicyProvisioningModelMix struct { + // StandardCapacityBase: The base capacity that will always use Standard VMs to + // avoid risk of more preemption than the minimum capacity user needs. MIG will + // create only Standard VMs until it reaches standard_capacity_base and only + // then will start using standard_capacity_percent_above_base to mix Spot with + // Standard VMs. + StandardCapacityBase int64 `json:"standardCapacityBase,omitempty"` + // StandardCapacityPercentAboveBase: The percentage of target capacity that + // should use Standard VM. The remaining percentage will use Spot VMs. The + // percentage applies only to the capacity above standard_capacity_base. + StandardCapacityPercentAboveBase int64 `json:"standardCapacityPercentAboveBase,omitempty"` + // ForceSendFields is a list of field names (e.g. "StandardCapacityBase") to + // unconditionally include in API requests. By default, fields with empty or + // default values are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. + ForceSendFields []string `json:"-"` + // NullFields is a list of field names (e.g. "StandardCapacityBase") to include + // in API requests with the JSON null value. By default, fields with empty + // values are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. + NullFields []string `json:"-"` +} + +func (s *InstanceGroupManagerInstanceFlexibilityPolicyProvisioningModelMix) MarshalJSON() ([]byte, error) { + type NoMethod InstanceGroupManagerInstanceFlexibilityPolicyProvisioningModelMix + return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) +} + type InstanceGroupManagerInstanceLifecyclePolicy struct { // DefaultActionOnFailure: The action that a MIG performs on a failed or an // unhealthy VM. A VM is marked as unhealthy when the application running on @@ -26571,6 +26606,13 @@ func (s *ManagedInstanceLastAttemptErrorsErrorsErrorDetails) MarshalJSON() ([]by type ManagedInstancePropertiesFromFlexibilityPolicy struct { // MachineType: The machine type to be used for this instance. MachineType string `json:"machineType,omitempty"` + // ProvisioningModel: The provisioning model to be used for this instance. + // + // Possible values: + // "SPOT" - Heavily discounted, no guaranteed runtime. + // "STANDARD" - Standard provisioning with user controlled runtime, no + // discounts. + ProvisioningModel string `json:"provisioningModel,omitempty"` // ForceSendFields is a list of field names (e.g. "MachineType") to // unconditionally include in API requests. By default, fields with empty or // default values are omitted from API requests. See @@ -56705,7 +56747,7 @@ func (s *XpnResourceId) MarshalJSON() ([]byte, error) { } // Zone: Represents a Zone resource. A zone is a deployment area. These -// deployment areas are subsets of a region. For example the zone us-east1-a is +// deployment areas are subsets of a region. For example the zone us-east1-b is // located in the us-east1 region. For more information, read Regions and // Zones. type Zone struct { diff --git a/compute/v0.beta/compute2-gen.go b/compute/v0.beta/compute2-gen.go index dee95b18c8a..fb3ef16a907 100644 --- a/compute/v0.beta/compute2-gen.go +++ b/compute/v0.beta/compute2-gen.go @@ -52511,7 +52511,7 @@ type NetworksPatchCall struct { } // Patch: Patches the specified network with the data included in the request. -// Only the following fields can be modified: routingConfig.routingMode. +// Only routingConfig can be modified. // // - network: Name of the network to update. // - project: Project ID for this request. diff --git a/compute/v1/compute-api.json b/compute/v1/compute-api.json index 4a6b808bf06..eecc2788dc7 100644 --- a/compute/v1/compute-api.json +++ b/compute/v1/compute-api.json @@ -16605,7 +16605,7 @@ ] }, "patch": { - "description": "Patches the specified network with the data included in the request. Only the following fields can be modified: routingConfig.routingMode.", + "description": "Patches the specified network with the data included in the request. Only routingConfig can be modified.", "flatPath": "projects/{project}/global/networks/{network}", "httpMethod": "PATCH", "id": "compute.networks.patch", @@ -37421,7 +37421,7 @@ } } }, - "revision": "20240519", + "revision": "20240526", "rootUrl": "https://compute.googleapis.com/", "schemas": { "AWSV4Signature": { @@ -38976,7 +38976,7 @@ "description": "[Output Only] shielded vm initial state stored on disk" }, "source": { - "description": "Specifies a valid partial or full URL to an existing Persistent Disk resource. When creating a new instance, one of initializeParams.sourceImage or initializeParams.sourceSnapshot or disks.source is required except for local SSD. If desired, you can also attach existing non-root persistent disks using this property. This field is only applicable for persistent disks. Note that for InstanceTemplate, specify the disk name for zonal disk, and the URL for regional disk.", + "description": "Specifies a valid partial or full URL to an existing Persistent Disk resource. When creating a new instance boot disk, one of initializeParams.sourceImage or initializeParams.sourceSnapshot or disks.source is required. If desired, you can also attach existing non-root persistent disks using this property. This field is only applicable for persistent disks. Note that for InstanceTemplate, specify the disk name for zonal disk, and the URL for regional disk.", "type": "string" }, "type": { @@ -39093,7 +39093,7 @@ "type": "array" }, "sourceImage": { - "description": "The source image to create this disk. When creating a new instance, one of initializeParams.sourceImage or initializeParams.sourceSnapshot or disks.source is required except for local SSD. To create a disk with one of the public operating system images, specify the image by its family name. For example, specify family/debian-9 to use the latest Debian 9 image: projects/debian-cloud/global/images/family/debian-9 Alternatively, use a specific version of a public operating system image: projects/debian-cloud/global/images/debian-9-stretch-vYYYYMMDD To create a disk with a custom image that you created, specify the image name in the following format: global/images/my-custom-image You can also specify a custom image by its image family, which returns the latest version of the image in that family. Replace the image name with family/family-name: global/images/family/my-image-family If the source image is deleted later, this field will not be set.", + "description": "The source image to create this disk. When creating a new instance boot disk, one of initializeParams.sourceImage or initializeParams.sourceSnapshot or disks.source is required. To create a disk with one of the public operating system images, specify the image by its family name. For example, specify family/debian-9 to use the latest Debian 9 image: projects/debian-cloud/global/images/family/debian-9 Alternatively, use a specific version of a public operating system image: projects/debian-cloud/global/images/debian-9-stretch-vYYYYMMDD To create a disk with a custom image that you created, specify the image name in the following format: global/images/my-custom-image You can also specify a custom image by its image family, which returns the latest version of the image in that family. Replace the image name with family/family-name: global/images/family/my-image-family If the source image is deleted later, this field will not be set.", "type": "string" }, "sourceImageEncryptionKey": { @@ -39101,7 +39101,7 @@ "description": "The customer-supplied encryption key of the source image. Required if the source image is protected by a customer-supplied encryption key. InstanceTemplate and InstancePropertiesPatch do not store customer-supplied encryption keys, so you cannot create disks for instances in a managed instance group if the source images are encrypted with your own keys." }, "sourceSnapshot": { - "description": "The source snapshot to create this disk. When creating a new instance, one of initializeParams.sourceSnapshot or initializeParams.sourceImage or disks.source is required except for local SSD. To create a disk with a snapshot that you created, specify the snapshot name in the following format: global/snapshots/my-backup If the source snapshot is deleted later, this field will not be set.", + "description": "The source snapshot to create this disk. When creating a new instance boot disk, one of initializeParams.sourceSnapshot or initializeParams.sourceImage or disks.source is required. To create a disk with a snapshot that you created, specify the snapshot name in the following format: global/snapshots/my-backup If the source snapshot is deleted later, this field will not be set.", "type": "string" }, "sourceSnapshotEncryptionKey": { @@ -50045,6 +50045,14 @@ "description": "[Output Only] The URL of the region where the managed instance group resides (for regional resources).", "type": "string" }, + "satisfiesPzi": { + "description": "[Output Only] Reserved for future use.", + "type": "boolean" + }, + "satisfiesPzs": { + "description": "[Output Only] Reserved for future use.", + "type": "boolean" + }, "selfLink": { "description": "[Output Only] The URL for this managed instance group. The server defines this URL.", "type": "string" @@ -78322,6 +78330,20 @@ "description": "URL of SslPolicy resource that will be associated with the TargetHttpsProxy resource. If not set, the TargetHttpsProxy resource has no SSL policy configured.", "type": "string" }, + "tlsEarlyData": { + "description": " Specifies whether TLS 1.3 0-RTT Data (\"Early Data\") should be accepted for this service. Early Data allows a TLS resumption handshake to include the initial application payload (a HTTP request) alongside the handshake, reducing the effective round trips to \"zero\". This applies to TLS 1.3 connections over TCP (HTTP/2) as well as over UDP (QUIC/h3). This can improve application performance, especially on networks where interruptions may be common, such as on mobile. Requests with Early Data will have the \"Early-Data\" HTTP header set on the request, with a value of \"1\", to allow the backend to determine whether Early Data was included. Note: TLS Early Data may allow requests to be replayed, as the data is sent to the backend before the handshake has fully completed. Applications that allow idempotent HTTP methods to make non-idempotent changes, such as a GET request updating a database, should not accept Early Data on those requests, and reject requests with the \"Early-Data: 1\" HTTP header by returning a HTTP 425 (Too Early) status code, in order to remain RFC compliant. The default value is DISABLED.", + "enum": [ + "DISABLED", + "PERMISSIVE", + "STRICT" + ], + "enumDescriptions": [ + "TLS 1.3 Early Data is not advertised, and any (invalid) attempts to send Early Data will be rejected by closing the connection.", + "This enables TLS 1.3 0-RTT, and only allows Early Data to be included on requests with safe HTTP methods (GET, HEAD, OPTIONS, TRACE). This mode does not enforce any other limitations for requests with Early Data. The application owner should validate that Early Data is acceptable for a given request path.", + "This enables TLS 1.3 0-RTT, and only allows Early Data to be included on requests with safe HTTP methods (GET, HEAD, OPTIONS, TRACE) without query parameters. Requests that send Early Data with non-idempotent HTTP methods or with query parameters will be rejected with a HTTP 425." + ], + "type": "string" + }, "urlMap": { "description": "A fully-qualified or valid partial URL to the UrlMap resource that defines the mapping from URL to the BackendService. For example, the following are all valid URLs for specifying a URL map: - https://www.googleapis.compute/v1/projects/project/global/urlMaps/ url-map - projects/project/global/urlMaps/url-map - global/urlMaps/url-map ", "type": "string" @@ -83923,7 +83945,7 @@ "type": "object" }, "Zone": { - "description": "Represents a Zone resource. A zone is a deployment area. These deployment areas are subsets of a region. For example the zone us-east1-a is located in the us-east1 region. For more information, read Regions and Zones.", + "description": "Represents a Zone resource. A zone is a deployment area. These deployment areas are subsets of a region. For example the zone us-east1-b is located in the us-east1 region. For more information, read Regions and Zones.", "id": "Zone", "properties": { "availableCpuPlatforms": { diff --git a/compute/v1/compute-gen.go b/compute/v1/compute-gen.go index 5e70e4d6677..2274778b3af 100644 --- a/compute/v1/compute-gen.go +++ b/compute/v1/compute-gen.go @@ -3053,12 +3053,12 @@ type AttachedDisk struct { // on disk ShieldedInstanceInitialState *InitialStateConfig `json:"shieldedInstanceInitialState,omitempty"` // Source: Specifies a valid partial or full URL to an existing Persistent Disk - // resource. When creating a new instance, one of initializeParams.sourceImage - // or initializeParams.sourceSnapshot or disks.source is required except for - // local SSD. If desired, you can also attach existing non-root persistent - // disks using this property. This field is only applicable for persistent - // disks. Note that for InstanceTemplate, specify the disk name for zonal disk, - // and the URL for regional disk. + // resource. When creating a new instance boot disk, one of + // initializeParams.sourceImage or initializeParams.sourceSnapshot or + // disks.source is required. If desired, you can also attach existing non-root + // persistent disks using this property. This field is only applicable for + // persistent disks. Note that for InstanceTemplate, specify the disk name for + // zonal disk, and the URL for regional disk. Source string `json:"source,omitempty"` // Type: Specifies the type of the disk, either SCRATCH or PERSISTENT. If not // specified, the default is PERSISTENT. @@ -3168,13 +3168,12 @@ type AttachedDiskInitializeParams struct { // template, specify only the resource policy name. ResourcePolicies []string `json:"resourcePolicies,omitempty"` // SourceImage: The source image to create this disk. When creating a new - // instance, one of initializeParams.sourceImage or - // initializeParams.sourceSnapshot or disks.source is required except for local - // SSD. To create a disk with one of the public operating system images, - // specify the image by its family name. For example, specify family/debian-9 - // to use the latest Debian 9 image: - // projects/debian-cloud/global/images/family/debian-9 Alternatively, use a - // specific version of a public operating system image: + // instance boot disk, one of initializeParams.sourceImage or + // initializeParams.sourceSnapshot or disks.source is required. To create a + // disk with one of the public operating system images, specify the image by + // its family name. For example, specify family/debian-9 to use the latest + // Debian 9 image: projects/debian-cloud/global/images/family/debian-9 + // Alternatively, use a specific version of a public operating system image: // projects/debian-cloud/global/images/debian-9-stretch-vYYYYMMDD To create a // disk with a custom image that you created, specify the image name in the // following format: global/images/my-custom-image You can also specify a @@ -3191,11 +3190,11 @@ type AttachedDiskInitializeParams struct { // keys. SourceImageEncryptionKey *CustomerEncryptionKey `json:"sourceImageEncryptionKey,omitempty"` // SourceSnapshot: The source snapshot to create this disk. When creating a new - // instance, one of initializeParams.sourceSnapshot or - // initializeParams.sourceImage or disks.source is required except for local - // SSD. To create a disk with a snapshot that you created, specify the snapshot - // name in the following format: global/snapshots/my-backup If the source - // snapshot is deleted later, this field will not be set. + // instance boot disk, one of initializeParams.sourceSnapshot or + // initializeParams.sourceImage or disks.source is required. To create a disk + // with a snapshot that you created, specify the snapshot name in the following + // format: global/snapshots/my-backup If the source snapshot is deleted later, + // this field will not be set. SourceSnapshot string `json:"sourceSnapshot,omitempty"` // SourceSnapshotEncryptionKey: The customer-supplied encryption key of the // source snapshot. @@ -16032,6 +16031,10 @@ type InstanceGroupManager struct { // Region: [Output Only] The URL of the region where the managed instance group // resides (for regional resources). Region string `json:"region,omitempty"` + // SatisfiesPzi: [Output Only] Reserved for future use. + SatisfiesPzi bool `json:"satisfiesPzi,omitempty"` + // SatisfiesPzs: [Output Only] Reserved for future use. + SatisfiesPzs bool `json:"satisfiesPzs,omitempty"` // SelfLink: [Output Only] The URL for this managed instance group. The server // defines this URL. SelfLink string `json:"selfLink,omitempty"` @@ -47034,6 +47037,36 @@ type TargetHttpsProxy struct { // TargetHttpsProxy resource. If not set, the TargetHttpsProxy resource has no // SSL policy configured. SslPolicy string `json:"sslPolicy,omitempty"` + // TlsEarlyData: Specifies whether TLS 1.3 0-RTT Data ("Early Data") should be + // accepted for this service. Early Data allows a TLS resumption handshake to + // include the initial application payload (a HTTP request) alongside the + // handshake, reducing the effective round trips to "zero". This applies to TLS + // 1.3 connections over TCP (HTTP/2) as well as over UDP (QUIC/h3). This can + // improve application performance, especially on networks where interruptions + // may be common, such as on mobile. Requests with Early Data will have the + // "Early-Data" HTTP header set on the request, with a value of "1", to allow + // the backend to determine whether Early Data was included. Note: TLS Early + // Data may allow requests to be replayed, as the data is sent to the backend + // before the handshake has fully completed. Applications that allow idempotent + // HTTP methods to make non-idempotent changes, such as a GET request updating + // a database, should not accept Early Data on those requests, and reject + // requests with the "Early-Data: 1" HTTP header by returning a HTTP 425 (Too + // Early) status code, in order to remain RFC compliant. The default value is + // DISABLED. + // + // Possible values: + // "DISABLED" - TLS 1.3 Early Data is not advertised, and any (invalid) + // attempts to send Early Data will be rejected by closing the connection. + // "PERMISSIVE" - This enables TLS 1.3 0-RTT, and only allows Early Data to + // be included on requests with safe HTTP methods (GET, HEAD, OPTIONS, TRACE). + // This mode does not enforce any other limitations for requests with Early + // Data. The application owner should validate that Early Data is acceptable + // for a given request path. + // "STRICT" - This enables TLS 1.3 0-RTT, and only allows Early Data to be + // included on requests with safe HTTP methods (GET, HEAD, OPTIONS, TRACE) + // without query parameters. Requests that send Early Data with non-idempotent + // HTTP methods or with query parameters will be rejected with a HTTP 425. + TlsEarlyData string `json:"tlsEarlyData,omitempty"` // UrlMap: A fully-qualified or valid partial URL to the UrlMap resource that // defines the mapping from URL to the BackendService. For example, the // following are all valid URLs for specifying a URL map: - @@ -53178,7 +53211,7 @@ func (s *XpnResourceId) MarshalJSON() ([]byte, error) { } // Zone: Represents a Zone resource. A zone is a deployment area. These -// deployment areas are subsets of a region. For example the zone us-east1-a is +// deployment areas are subsets of a region. For example the zone us-east1-b is // located in the us-east1 region. For more information, read Regions and // Zones. type Zone struct { diff --git a/compute/v1/compute2-gen.go b/compute/v1/compute2-gen.go index 17970765314..424c7e15f91 100644 --- a/compute/v1/compute2-gen.go +++ b/compute/v1/compute2-gen.go @@ -48414,7 +48414,7 @@ type NetworksPatchCall struct { } // Patch: Patches the specified network with the data included in the request. -// Only the following fields can be modified: routingConfig.routingMode. +// Only routingConfig can be modified. // // - network: Name of the network to update. // - project: Project ID for this request. diff --git a/contactcenteraiplatform/v1alpha1/contactcenteraiplatform-api.json b/contactcenteraiplatform/v1alpha1/contactcenteraiplatform-api.json index 61ea0ee7798..6043ee9513e 100644 --- a/contactcenteraiplatform/v1alpha1/contactcenteraiplatform-api.json +++ b/contactcenteraiplatform/v1alpha1/contactcenteraiplatform-api.json @@ -512,7 +512,7 @@ } } }, - "revision": "20240524", + "revision": "20240528", "rootUrl": "https://contactcenteraiplatform.googleapis.com/", "schemas": { "AdminUser": { @@ -1166,6 +1166,13 @@ "description": "Container for the VPC-SC networking configurations.", "id": "ServiceAttachment", "properties": { + "allowedProjectIds": { + "description": "The list of project ids that are allowed to send traffic to the service attachment. This field should be filled only for the ingress service attachments.", + "items": { + "type": "string" + }, + "type": "array" + }, "name": { "description": "The service attachment name that will be used for sending private traffic to the CCAIP tenant project. Example: \"projects/${TENANT_PROJECT_ID}/regions/${REGION}/serviceAttachments/ingress-default\".", "type": "string" diff --git a/contactcenteraiplatform/v1alpha1/contactcenteraiplatform-gen.go b/contactcenteraiplatform/v1alpha1/contactcenteraiplatform-gen.go index 3ad45490cc1..ba8b3734e2b 100644 --- a/contactcenteraiplatform/v1alpha1/contactcenteraiplatform-gen.go +++ b/contactcenteraiplatform/v1alpha1/contactcenteraiplatform-gen.go @@ -899,20 +899,24 @@ func (s *SAMLParams) MarshalJSON() ([]byte, error) { // ServiceAttachment: Container for the VPC-SC networking configurations. type ServiceAttachment struct { + // AllowedProjectIds: The list of project ids that are allowed to send traffic + // to the service attachment. This field should be filled only for the ingress + // service attachments. + AllowedProjectIds []string `json:"allowedProjectIds,omitempty"` // Name: The service attachment name that will be used for sending private // traffic to the CCAIP tenant project. Example: // "projects/${TENANT_PROJECT_ID}/regions/${REGION}/serviceAttachments/ingress-d // efault". Name string `json:"name,omitempty"` - // ForceSendFields is a list of field names (e.g. "Name") to unconditionally - // include in API requests. By default, fields with empty or default values are - // omitted from API requests. See + // ForceSendFields is a list of field names (e.g. "AllowedProjectIds") to + // unconditionally include in API requests. By default, fields with empty or + // default values are omitted from API requests. See // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more // details. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "Name") to include in API requests - // with the JSON null value. By default, fields with empty values are omitted - // from API requests. See + // NullFields is a list of field names (e.g. "AllowedProjectIds") to include in + // API requests with the JSON null value. By default, fields with empty values + // are omitted from API requests. See // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. NullFields []string `json:"-"` } diff --git a/containeranalysis/v1/containeranalysis-api.json b/containeranalysis/v1/containeranalysis-api.json index e5aaeec2daa..b5a9c08049b 100644 --- a/containeranalysis/v1/containeranalysis-api.json +++ b/containeranalysis/v1/containeranalysis-api.json @@ -1065,7 +1065,7 @@ } } }, - "revision": "20240516", + "revision": "20240524", "rootUrl": "https://containeranalysis.googleapis.com/", "schemas": { "AliasContext": { @@ -2569,7 +2569,7 @@ "type": "string" }, "diskSizeGb": { - "description": "Requested disk size for the VM that runs the build. Note that this is *NOT* \"disk free\"; some of the space will be used by the operating system and build utilities. Also note that this is the minimum disk size that will be allocated for the build -- the build may run with a larger disk than requested. At present, the maximum disk size is 2000GB; builds that request more than the maximum are rejected with an error.", + "description": "Requested disk size for the VM that runs the build. Note that this is *NOT* \"disk free\"; some of the space will be used by the operating system and build utilities. Also note that this is the minimum disk size that will be allocated for the build -- the build may run with a larger disk than requested. At present, the maximum disk size is 4000GB; builds that request more than the maximum are rejected with an error.", "format": "int64", "type": "string" }, diff --git a/containeranalysis/v1/containeranalysis-gen.go b/containeranalysis/v1/containeranalysis-gen.go index 2407bded506..6322a42c2a7 100644 --- a/containeranalysis/v1/containeranalysis-gen.go +++ b/containeranalysis/v1/containeranalysis-gen.go @@ -1908,7 +1908,7 @@ type ContaineranalysisGoogleDevtoolsCloudbuildV1BuildOptions struct { // this is *NOT* "disk free"; some of the space will be used by the operating // system and build utilities. Also note that this is the minimum disk size // that will be allocated for the build -- the build may run with a larger disk - // than requested. At present, the maximum disk size is 2000GB; builds that + // than requested. At present, the maximum disk size is 4000GB; builds that // request more than the maximum are rejected with an error. DiskSizeGb int64 `json:"diskSizeGb,omitempty,string"` // DynamicSubstitutions: Option to specify whether or not to apply bash style diff --git a/containeranalysis/v1alpha1/containeranalysis-api.json b/containeranalysis/v1alpha1/containeranalysis-api.json index ebe0ff103ba..37976226c14 100644 --- a/containeranalysis/v1alpha1/containeranalysis-api.json +++ b/containeranalysis/v1alpha1/containeranalysis-api.json @@ -1233,7 +1233,7 @@ } } }, - "revision": "20240516", + "revision": "20240524", "rootUrl": "https://containeranalysis.googleapis.com/", "schemas": { "AnalysisCompleted": { @@ -2543,7 +2543,7 @@ "type": "string" }, "diskSizeGb": { - "description": "Requested disk size for the VM that runs the build. Note that this is *NOT* \"disk free\"; some of the space will be used by the operating system and build utilities. Also note that this is the minimum disk size that will be allocated for the build -- the build may run with a larger disk than requested. At present, the maximum disk size is 2000GB; builds that request more than the maximum are rejected with an error.", + "description": "Requested disk size for the VM that runs the build. Note that this is *NOT* \"disk free\"; some of the space will be used by the operating system and build utilities. Also note that this is the minimum disk size that will be allocated for the build -- the build may run with a larger disk than requested. At present, the maximum disk size is 4000GB; builds that request more than the maximum are rejected with an error.", "format": "int64", "type": "string" }, diff --git a/containeranalysis/v1alpha1/containeranalysis-gen.go b/containeranalysis/v1alpha1/containeranalysis-gen.go index d35c76ee59f..c63880ad16c 100644 --- a/containeranalysis/v1alpha1/containeranalysis-gen.go +++ b/containeranalysis/v1alpha1/containeranalysis-gen.go @@ -1745,7 +1745,7 @@ type ContaineranalysisGoogleDevtoolsCloudbuildV1BuildOptions struct { // this is *NOT* "disk free"; some of the space will be used by the operating // system and build utilities. Also note that this is the minimum disk size // that will be allocated for the build -- the build may run with a larger disk - // than requested. At present, the maximum disk size is 2000GB; builds that + // than requested. At present, the maximum disk size is 4000GB; builds that // request more than the maximum are rejected with an error. DiskSizeGb int64 `json:"diskSizeGb,omitempty,string"` // DynamicSubstitutions: Option to specify whether or not to apply bash style diff --git a/containeranalysis/v1beta1/containeranalysis-api.json b/containeranalysis/v1beta1/containeranalysis-api.json index 146e607100e..866c57f60d9 100644 --- a/containeranalysis/v1beta1/containeranalysis-api.json +++ b/containeranalysis/v1beta1/containeranalysis-api.json @@ -1121,7 +1121,7 @@ } } }, - "revision": "20240516", + "revision": "20240524", "rootUrl": "https://containeranalysis.googleapis.com/", "schemas": { "AliasContext": { @@ -2525,7 +2525,7 @@ "type": "string" }, "diskSizeGb": { - "description": "Requested disk size for the VM that runs the build. Note that this is *NOT* \"disk free\"; some of the space will be used by the operating system and build utilities. Also note that this is the minimum disk size that will be allocated for the build -- the build may run with a larger disk than requested. At present, the maximum disk size is 2000GB; builds that request more than the maximum are rejected with an error.", + "description": "Requested disk size for the VM that runs the build. Note that this is *NOT* \"disk free\"; some of the space will be used by the operating system and build utilities. Also note that this is the minimum disk size that will be allocated for the build -- the build may run with a larger disk than requested. At present, the maximum disk size is 4000GB; builds that request more than the maximum are rejected with an error.", "format": "int64", "type": "string" }, diff --git a/containeranalysis/v1beta1/containeranalysis-gen.go b/containeranalysis/v1beta1/containeranalysis-gen.go index cd34497f97f..ddbd4a8c049 100644 --- a/containeranalysis/v1beta1/containeranalysis-gen.go +++ b/containeranalysis/v1beta1/containeranalysis-gen.go @@ -1811,7 +1811,7 @@ type ContaineranalysisGoogleDevtoolsCloudbuildV1BuildOptions struct { // this is *NOT* "disk free"; some of the space will be used by the operating // system and build utilities. Also note that this is the minimum disk size // that will be allocated for the build -- the build may run with a larger disk - // than requested. At present, the maximum disk size is 2000GB; builds that + // than requested. At present, the maximum disk size is 4000GB; builds that // request more than the maximum are rejected with an error. DiskSizeGb int64 `json:"diskSizeGb,omitempty,string"` // DynamicSubstitutions: Option to specify whether or not to apply bash style diff --git a/dialogflow/v2/dialogflow-api.json b/dialogflow/v2/dialogflow-api.json index c18635731f5..54b1c36a6a6 100644 --- a/dialogflow/v2/dialogflow-api.json +++ b/dialogflow/v2/dialogflow-api.json @@ -3741,6 +3741,81 @@ } } }, + "generators": { + "methods": { + "create": { + "description": "Creates a generator.", + "flatPath": "v2/projects/{projectsId}/generators", + "httpMethod": "POST", + "id": "dialogflow.projects.generators.create", + "parameterOrder": [ + "parent" + ], + "parameters": { + "generatorId": { + "description": "Optional. The ID to use for the generator, which will become the final component of the generator's resource name. The generator ID must be compliant with the regression fomula `a-zA-Z*` with the characters length in range of [3,64]. If the field is not provided, an Id will be auto-generated. If the field is provided, the caller is resposible for 1. the uniqueness of the ID, otherwise the request will be rejected. 2. the consistency for whether to use custom ID or not under a project to better ensure uniqueness.", + "location": "query", + "type": "string" + }, + "parent": { + "description": "Required. The project/location to create generator for. Format: `projects//locations/`", + "location": "path", + "pattern": "^projects/[^/]+$", + "required": true, + "type": "string" + } + }, + "path": "v2/{+parent}/generators", + "request": { + "$ref": "GoogleCloudDialogflowV2Generator" + }, + "response": { + "$ref": "GoogleCloudDialogflowV2Generator" + }, + "scopes": [ + "https://www.googleapis.com/auth/cloud-platform", + "https://www.googleapis.com/auth/dialogflow" + ] + }, + "list": { + "description": "Lists generators.", + "flatPath": "v2/projects/{projectsId}/generators", + "httpMethod": "GET", + "id": "dialogflow.projects.generators.list", + "parameterOrder": [ + "parent" + ], + "parameters": { + "pageSize": { + "description": "Optional. Maximum number of conversation models to return in a single page. Default to 10.", + "format": "int32", + "location": "query", + "type": "integer" + }, + "pageToken": { + "description": "Optional. The next_page_token value returned from a previous list request.", + "location": "query", + "type": "string" + }, + "parent": { + "description": "Required. The project/location to list generators for. Format: `projects//locations/`", + "location": "path", + "pattern": "^projects/[^/]+$", + "required": true, + "type": "string" + } + }, + "path": "v2/{+parent}/generators", + "response": { + "$ref": "GoogleCloudDialogflowV2ListGeneratorsResponse" + }, + "scopes": [ + "https://www.googleapis.com/auth/cloud-platform", + "https://www.googleapis.com/auth/dialogflow" + ] + } + } + }, "knowledgeBases": { "methods": { "create": { @@ -7584,6 +7659,168 @@ } } }, + "generators": { + "methods": { + "create": { + "description": "Creates a generator.", + "flatPath": "v2/projects/{projectsId}/locations/{locationsId}/generators", + "httpMethod": "POST", + "id": "dialogflow.projects.locations.generators.create", + "parameterOrder": [ + "parent" + ], + "parameters": { + "generatorId": { + "description": "Optional. The ID to use for the generator, which will become the final component of the generator's resource name. The generator ID must be compliant with the regression fomula `a-zA-Z*` with the characters length in range of [3,64]. If the field is not provided, an Id will be auto-generated. If the field is provided, the caller is resposible for 1. the uniqueness of the ID, otherwise the request will be rejected. 2. the consistency for whether to use custom ID or not under a project to better ensure uniqueness.", + "location": "query", + "type": "string" + }, + "parent": { + "description": "Required. The project/location to create generator for. Format: `projects//locations/`", + "location": "path", + "pattern": "^projects/[^/]+/locations/[^/]+$", + "required": true, + "type": "string" + } + }, + "path": "v2/{+parent}/generators", + "request": { + "$ref": "GoogleCloudDialogflowV2Generator" + }, + "response": { + "$ref": "GoogleCloudDialogflowV2Generator" + }, + "scopes": [ + "https://www.googleapis.com/auth/cloud-platform", + "https://www.googleapis.com/auth/dialogflow" + ] + }, + "delete": { + "description": "Deletes a generator.", + "flatPath": "v2/projects/{projectsId}/locations/{locationsId}/generators/{generatorsId}", + "httpMethod": "DELETE", + "id": "dialogflow.projects.locations.generators.delete", + "parameterOrder": [ + "name" + ], + "parameters": { + "name": { + "description": "Required. The generator resource name to delete. Format: `projects//locations//generators/`", + "location": "path", + "pattern": "^projects/[^/]+/locations/[^/]+/generators/[^/]+$", + "required": true, + "type": "string" + } + }, + "path": "v2/{+name}", + "response": { + "$ref": "GoogleProtobufEmpty" + }, + "scopes": [ + "https://www.googleapis.com/auth/cloud-platform", + "https://www.googleapis.com/auth/dialogflow" + ] + }, + "get": { + "description": "Retrieves a generator.", + "flatPath": "v2/projects/{projectsId}/locations/{locationsId}/generators/{generatorsId}", + "httpMethod": "GET", + "id": "dialogflow.projects.locations.generators.get", + "parameterOrder": [ + "name" + ], + "parameters": { + "name": { + "description": "Required. The generator resource name to retrieve. Format: `projects//locations/`/generators/`", + "location": "path", + "pattern": "^projects/[^/]+/locations/[^/]+/generators/[^/]+$", + "required": true, + "type": "string" + } + }, + "path": "v2/{+name}", + "response": { + "$ref": "GoogleCloudDialogflowV2Generator" + }, + "scopes": [ + "https://www.googleapis.com/auth/cloud-platform", + "https://www.googleapis.com/auth/dialogflow" + ] + }, + "list": { + "description": "Lists generators.", + "flatPath": "v2/projects/{projectsId}/locations/{locationsId}/generators", + "httpMethod": "GET", + "id": "dialogflow.projects.locations.generators.list", + "parameterOrder": [ + "parent" + ], + "parameters": { + "pageSize": { + "description": "Optional. Maximum number of conversation models to return in a single page. Default to 10.", + "format": "int32", + "location": "query", + "type": "integer" + }, + "pageToken": { + "description": "Optional. The next_page_token value returned from a previous list request.", + "location": "query", + "type": "string" + }, + "parent": { + "description": "Required. The project/location to list generators for. Format: `projects//locations/`", + "location": "path", + "pattern": "^projects/[^/]+/locations/[^/]+$", + "required": true, + "type": "string" + } + }, + "path": "v2/{+parent}/generators", + "response": { + "$ref": "GoogleCloudDialogflowV2ListGeneratorsResponse" + }, + "scopes": [ + "https://www.googleapis.com/auth/cloud-platform", + "https://www.googleapis.com/auth/dialogflow" + ] + }, + "patch": { + "description": "Updates a generator.", + "flatPath": "v2/projects/{projectsId}/locations/{locationsId}/generators/{generatorsId}", + "httpMethod": "PATCH", + "id": "dialogflow.projects.locations.generators.patch", + "parameterOrder": [ + "name" + ], + "parameters": { + "name": { + "description": "Output only. Identifier. The resource name of the generator. Format: `projects//locations//generators/`", + "location": "path", + "pattern": "^projects/[^/]+/locations/[^/]+/generators/[^/]+$", + "required": true, + "type": "string" + }, + "updateMask": { + "description": "Optional. The list of fields to update.", + "format": "google-fieldmask", + "location": "query", + "type": "string" + } + }, + "path": "v2/{+name}", + "request": { + "$ref": "GoogleCloudDialogflowV2Generator" + }, + "response": { + "$ref": "GoogleCloudDialogflowV2Generator" + }, + "scopes": [ + "https://www.googleapis.com/auth/cloud-platform", + "https://www.googleapis.com/auth/dialogflow" + ] + } + } + }, "knowledgeBases": { "methods": { "create": { @@ -8100,6 +8337,39 @@ } } }, + "statelessSuggestion": { + "methods": { + "generate": { + "description": "Generates and returns a suggestion for a conversation that does not have a resource created for it.", + "flatPath": "v2/projects/{projectsId}/locations/{locationsId}/statelessSuggestion:generate", + "httpMethod": "POST", + "id": "dialogflow.projects.locations.statelessSuggestion.generate", + "parameterOrder": [ + "parent" + ], + "parameters": { + "parent": { + "description": "Required. The parent resource to charge for the Suggestion's generation. Format: `projects//locations/`.", + "location": "path", + "pattern": "^projects/[^/]+/locations/[^/]+$", + "required": true, + "type": "string" + } + }, + "path": "v2/{+parent}/statelessSuggestion:generate", + "request": { + "$ref": "GoogleCloudDialogflowV2GenerateStatelessSuggestionRequest" + }, + "response": { + "$ref": "GoogleCloudDialogflowV2GenerateStatelessSuggestionResponse" + }, + "scopes": [ + "https://www.googleapis.com/auth/cloud-platform", + "https://www.googleapis.com/auth/dialogflow" + ] + } + } + }, "suggestions": { "methods": { "generateStatelessSummary": { @@ -8327,7 +8597,7 @@ } } }, - "revision": "20240507", + "revision": "20240523", "rootUrl": "https://dialogflow.googleapis.com/", "schemas": { "GoogleCloudDialogflowCxV3AdvancedSettings": { @@ -13966,6 +14236,20 @@ }, "type": "object" }, + "GoogleCloudDialogflowV2ConversationContext": { + "description": "Context of the conversation, including transcripts.", + "id": "GoogleCloudDialogflowV2ConversationContext", + "properties": { + "messageEntries": { + "description": "Optional. List of message transcripts in the conversation.", + "items": { + "$ref": "GoogleCloudDialogflowV2MessageEntry" + }, + "type": "array" + } + }, + "type": "object" + }, "GoogleCloudDialogflowV2ConversationDataset": { "description": "Represents a conversation dataset that a user imports raw data into. The data inside ConversationDataset can not be changed after ImportConversationData finishes (and calling ImportConversationData on a dataset that already has data is not allowed).", "id": "GoogleCloudDialogflowV2ConversationDataset", @@ -14927,6 +15211,32 @@ }, "type": "object" }, + "GoogleCloudDialogflowV2FewShotExample": { + "description": "Providing examples in the generator (i.e. building a few-shot generator) helps convey the desired format of the LLM response. NEXT_ID: 10", + "id": "GoogleCloudDialogflowV2FewShotExample", + "properties": { + "conversationContext": { + "$ref": "GoogleCloudDialogflowV2ConversationContext", + "description": "Optional. Conversation transcripts." + }, + "extraInfo": { + "additionalProperties": { + "type": "string" + }, + "description": "Optional. Key is the placeholder field name in input, value is the value of the placeholder. E.g. instruction contains \"@price\", and ingested data has \u003c\"price\", \"10\"\u003e", + "type": "object" + }, + "output": { + "$ref": "GoogleCloudDialogflowV2GeneratorSuggestion", + "description": "Required. Example output of the model." + }, + "summarizationSectionList": { + "$ref": "GoogleCloudDialogflowV2SummarizationSectionList", + "description": "Summarization sections." + } + }, + "type": "object" + }, "GoogleCloudDialogflowV2Fulfillment": { "description": "By default, your agent responds to a matched intent with a static response. As an alternative, you can provide a more dynamic response by using fulfillment. When you enable fulfillment for an intent, Dialogflow responds to that intent by calling a service that you define. For example, if an end-user wants to schedule a haircut on Friday, your service can check your database and respond to the end-user with availability information for Friday. For more information, see the [fulfillment guide](https://cloud.google.com/dialogflow/docs/fulfillment-overview).", "id": "GoogleCloudDialogflowV2Fulfillment", @@ -15032,6 +15342,53 @@ }, "type": "object" }, + "GoogleCloudDialogflowV2GenerateStatelessSuggestionRequest": { + "description": "The request message for Conversations.GenerateStatelessSuggestion.", + "id": "GoogleCloudDialogflowV2GenerateStatelessSuggestionRequest", + "properties": { + "conversationContext": { + "$ref": "GoogleCloudDialogflowV2ConversationContext", + "description": "Optional. Context of the conversation, including transcripts." + }, + "generator": { + "$ref": "GoogleCloudDialogflowV2Generator", + "description": "Uncreated generator. It should be a complete generator that includes all information about the generator." + }, + "generatorName": { + "description": "The resource name of the existing created generator. Format: `projects//locations//generators/`", + "type": "string" + }, + "triggerEvents": { + "description": "Optional. A list of trigger events. Generator will be triggered only if it's trigger event is included here.", + "items": { + "enum": [ + "TRIGGER_EVENT_UNSPECIFIED", + "END_OF_UTTERANCE", + "MANUAL_CALL" + ], + "enumDescriptions": [ + "Default value for TriggerEvent.", + "Triggers when each chat message or voice utterance ends.", + "Triggers on the conversation manually by API calls, such as Conversations.GenerateStatelessSuggestion and Conversations.GenerateSuggestions." + ], + "type": "string" + }, + "type": "array" + } + }, + "type": "object" + }, + "GoogleCloudDialogflowV2GenerateStatelessSuggestionResponse": { + "description": "The response message for Conversations.GenerateStatelessSuggestion.", + "id": "GoogleCloudDialogflowV2GenerateStatelessSuggestionResponse", + "properties": { + "generatorSuggestion": { + "$ref": "GoogleCloudDialogflowV2GeneratorSuggestion", + "description": "Required. Generated suggestion for a conversation." + } + }, + "type": "object" + }, "GoogleCloudDialogflowV2GenerateStatelessSummaryRequest": { "description": "The request message for Conversations.GenerateStatelessSummary.", "id": "GoogleCloudDialogflowV2GenerateStatelessSummaryRequest", @@ -15112,6 +15469,67 @@ }, "type": "object" }, + "GoogleCloudDialogflowV2Generator": { + "description": "LLM generator.", + "id": "GoogleCloudDialogflowV2Generator", + "properties": { + "createTime": { + "description": "Output only. Creation time of this generator.", + "format": "google-datetime", + "readOnly": true, + "type": "string" + }, + "description": { + "description": "Optional. Human readable description of the generator.", + "type": "string" + }, + "inferenceParameter": { + "$ref": "GoogleCloudDialogflowV2InferenceParameter", + "description": "Optional. Inference parameters for this generator." + }, + "name": { + "description": "Output only. Identifier. The resource name of the generator. Format: `projects//locations//generators/`", + "readOnly": true, + "type": "string" + }, + "summarizationContext": { + "$ref": "GoogleCloudDialogflowV2SummarizationContext", + "description": "Input of prebuilt Summarization feature." + }, + "triggerEvent": { + "description": "Optional. The trigger event of the generator. It defines when the generator is triggered in a conversation.", + "enum": [ + "TRIGGER_EVENT_UNSPECIFIED", + "END_OF_UTTERANCE", + "MANUAL_CALL" + ], + "enumDescriptions": [ + "Default value for TriggerEvent.", + "Triggers when each chat message or voice utterance ends.", + "Triggers on the conversation manually by API calls, such as Conversations.GenerateStatelessSuggestion and Conversations.GenerateSuggestions." + ], + "type": "string" + }, + "updateTime": { + "description": "Output only. Update time of this generator.", + "format": "google-datetime", + "readOnly": true, + "type": "string" + } + }, + "type": "object" + }, + "GoogleCloudDialogflowV2GeneratorSuggestion": { + "description": "Suggestion generated using a Generator.", + "id": "GoogleCloudDialogflowV2GeneratorSuggestion", + "properties": { + "summarySuggestion": { + "$ref": "GoogleCloudDialogflowV2SummarySuggestion", + "description": "Optional. Suggested summary." + } + }, + "type": "object" + }, "GoogleCloudDialogflowV2HumanAgentAssistantConfig": { "description": "Defines the Human Agent Assist to connect to a conversation.", "id": "GoogleCloudDialogflowV2HumanAgentAssistantConfig", @@ -15188,6 +15606,13 @@ }, "type": "array" }, + "generators": { + "description": "Optional. List of various generator resource names used in the conversation profile.", + "items": { + "type": "string" + }, + "type": "array" + }, "groupSuggestionResponses": { "description": "If `group_suggestion_responses` is false, and there are multiple `feature_configs` in `event based suggestion` or StreamingAnalyzeContent, we will try to deliver suggestions to customers as soon as we get new suggestion. Different type of suggestions based on the same context will be in separate Pub/Sub event or `StreamingAnalyzeContentResponse`. If `group_suggestion_responses` set to true. All the suggestions to the same participant based on the same context will be grouped into a single Pub/Sub event or StreamingAnalyzeContentResponse.", "type": "boolean" @@ -15419,7 +15844,7 @@ "properties": { "livePersonConfig": { "$ref": "GoogleCloudDialogflowV2HumanAgentHandoffConfigLivePersonConfig", - "description": "Uses LivePerson (https://www.liveperson.com)." + "description": "Uses [LivePerson](https://www.liveperson.com)." }, "salesforceLiveAgentConfig": { "$ref": "GoogleCloudDialogflowV2HumanAgentHandoffConfigSalesforceLiveAgentConfig", @@ -15429,7 +15854,7 @@ "type": "object" }, "GoogleCloudDialogflowV2HumanAgentHandoffConfigLivePersonConfig": { - "description": "Configuration specific to LivePerson (https://www.liveperson.com).", + "description": "Configuration specific to [LivePerson](https://www.liveperson.com).", "id": "GoogleCloudDialogflowV2HumanAgentHandoffConfigLivePersonConfig", "properties": { "accountNumber": { @@ -15600,6 +16025,33 @@ }, "type": "object" }, + "GoogleCloudDialogflowV2InferenceParameter": { + "description": "The parameters of inference.", + "id": "GoogleCloudDialogflowV2InferenceParameter", + "properties": { + "maxOutputTokens": { + "description": "Optional. Maximum number of the output tokens for the generator.", + "format": "int32", + "type": "integer" + }, + "temperature": { + "description": "Optional. Controls the randomness of LLM predictions. Low temperature = less random. High temperature = more random. If unset (or 0), uses a default value of 0.", + "format": "double", + "type": "number" + }, + "topK": { + "description": "Optional. Top-k changes how the model selects tokens for output. A top-k of 1 means the selected token is the most probable among all tokens in the model's vocabulary (also called greedy decoding), while a top-k of 3 means that the next token is selected from among the 3 most probable tokens (using temperature). For each token selection step, the top K tokens with the highest probabilities are sampled. Then tokens are further filtered based on topP with the final token selected using temperature sampling. Specify a lower value for less random responses and a higher value for more random responses. Acceptable value is [1, 40], default to 40.", + "format": "int32", + "type": "integer" + }, + "topP": { + "description": "Optional. Top-p changes how the model selects tokens for output. Tokens are selected from most K (see topK parameter) probable to least until the sum of their probabilities equals the top-p value. For example, if tokens A, B, and C have a probability of 0.3, 0.2, and 0.1 and the top-p value is 0.5, then the model will select either A or B as the next token (using temperature) and doesn't consider C. The default top-p value is 0.95. Specify a lower value for less random responses and a higher value for more random responses. Acceptable value is [0.0, 1.0], default to 0.95.", + "format": "double", + "type": "number" + } + }, + "type": "object" + }, "GoogleCloudDialogflowV2InputAudioConfig": { "description": "Instructs the speech recognizer how to process the audio content.", "id": "GoogleCloudDialogflowV2InputAudioConfig", @@ -16896,6 +17348,24 @@ }, "type": "object" }, + "GoogleCloudDialogflowV2ListGeneratorsResponse": { + "description": "Response of ListGenerators.", + "id": "GoogleCloudDialogflowV2ListGeneratorsResponse", + "properties": { + "generators": { + "description": "List of generators retrieved.", + "items": { + "$ref": "GoogleCloudDialogflowV2Generator" + }, + "type": "array" + }, + "nextPageToken": { + "description": "Token to retrieve the next page of results, or empty if there are no more results in the list.", + "type": "string" + } + }, + "type": "object" + }, "GoogleCloudDialogflowV2ListIntentsResponse": { "description": "The response message for Intents.ListIntents.", "id": "GoogleCloudDialogflowV2ListIntentsResponse", @@ -17095,6 +17565,42 @@ }, "type": "object" }, + "GoogleCloudDialogflowV2MessageEntry": { + "description": "Represents a message entry of a conversation.", + "id": "GoogleCloudDialogflowV2MessageEntry", + "properties": { + "createTime": { + "description": "Optional. Create time of the message entry.", + "format": "google-datetime", + "type": "string" + }, + "languageCode": { + "description": "Optional. The language of the text. See [Language Support](https://cloud.google.com/dialogflow/docs/reference/language) for a list of the currently supported language codes.", + "type": "string" + }, + "role": { + "description": "Optional. Participant role of the message.", + "enum": [ + "ROLE_UNSPECIFIED", + "HUMAN_AGENT", + "AUTOMATED_AGENT", + "END_USER" + ], + "enumDescriptions": [ + "Participant role not set.", + "Participant is a human agent.", + "Participant is an automated agent, such as a Dialogflow agent.", + "Participant is an end user that has called or chatted with Dialogflow services." + ], + "type": "string" + }, + "text": { + "description": "Optional. Transcript content of the message.", + "type": "string" + } + }, + "type": "object" + }, "GoogleCloudDialogflowV2NotificationConfig": { "description": "Defines notification behavior.", "id": "GoogleCloudDialogflowV2NotificationConfig", @@ -18097,6 +18603,117 @@ }, "type": "object" }, + "GoogleCloudDialogflowV2SummarizationContext": { + "description": "Summarization context that customer can configure.", + "id": "GoogleCloudDialogflowV2SummarizationContext", + "properties": { + "fewShotExamples": { + "description": "Optional. List of few shot examples.", + "items": { + "$ref": "GoogleCloudDialogflowV2FewShotExample" + }, + "type": "array" + }, + "outputLanguageCode": { + "description": "Optional. The target language of the generated summary. The language code for conversation will be used if this field is empty. Supported 2.0 and later versions.", + "type": "string" + }, + "summarizationSections": { + "description": "Optional. List of sections. Note it contains both predefined section sand customer defined sections.", + "items": { + "$ref": "GoogleCloudDialogflowV2SummarizationSection" + }, + "type": "array" + }, + "version": { + "description": "Optional. Version of the feature. If not set, default to latest version. Current candidates are [\"1.0\"].", + "type": "string" + } + }, + "type": "object" + }, + "GoogleCloudDialogflowV2SummarizationSection": { + "description": "Represents the section of summarization.", + "id": "GoogleCloudDialogflowV2SummarizationSection", + "properties": { + "definition": { + "description": "Optional. Definition of the section, for example, \"what the customer needs help with or has question about.\"", + "type": "string" + }, + "key": { + "description": "Optional. Name of the section, for example, \"situation\".", + "type": "string" + }, + "type": { + "description": "Optional. Type of the summarization section.", + "enum": [ + "TYPE_UNSPECIFIED", + "SITUATION", + "ACTION", + "RESOLUTION", + "REASON_FOR_CANCELLATION", + "CUSTOMER_SATISFACTION", + "ENTITIES", + "CUSTOMER_DEFINED" + ], + "enumDescriptions": [ + "Undefined section type, does not return anything.", + "What the customer needs help with or has question about. Section name: \"situation\".", + "What the agent does to help the customer. Section name: \"action\".", + "Result of the customer service. A single word describing the result of the conversation. Section name: \"resolution\".", + "Reason for cancellation if the customer requests for a cancellation. \"N/A\" otherwise. Section name: \"reason_for_cancellation\".", + "\"Unsatisfied\" or \"Satisfied\" depending on the customer's feelings at the end of the conversation. Section name: \"customer_satisfaction\".", + "Key entities extracted from the conversation, such as ticket number, order number, dollar amount, etc. Section names are prefixed by \"entities/\".", + "Customer defined sections." + ], + "type": "string" + } + }, + "type": "object" + }, + "GoogleCloudDialogflowV2SummarizationSectionList": { + "description": "List of summarization sections.", + "id": "GoogleCloudDialogflowV2SummarizationSectionList", + "properties": { + "summarizationSections": { + "description": "Optional. Summarization sections.", + "items": { + "$ref": "GoogleCloudDialogflowV2SummarizationSection" + }, + "type": "array" + } + }, + "type": "object" + }, + "GoogleCloudDialogflowV2SummarySuggestion": { + "description": "Suggested summary of the conversation.", + "id": "GoogleCloudDialogflowV2SummarySuggestion", + "properties": { + "summarySections": { + "description": "Required. All the parts of generated summary.", + "items": { + "$ref": "GoogleCloudDialogflowV2SummarySuggestionSummarySection" + }, + "type": "array" + } + }, + "type": "object" + }, + "GoogleCloudDialogflowV2SummarySuggestionSummarySection": { + "description": "A component of the generated summary.", + "id": "GoogleCloudDialogflowV2SummarySuggestionSummarySection", + "properties": { + "section": { + "description": "Required. Name of the section.", + "type": "string" + }, + "summary": { + "description": "Required. Summary text for the section.", + "type": "string" + } + }, + "type": "object" + }, "GoogleCloudDialogflowV2SynthesizeSpeechConfig": { "description": "Configuration of how speech should be synthesized.", "id": "GoogleCloudDialogflowV2SynthesizeSpeechConfig", diff --git a/dialogflow/v2/dialogflow-gen.go b/dialogflow/v2/dialogflow-gen.go index 1ba4b81db62..242165417b8 100644 --- a/dialogflow/v2/dialogflow-gen.go +++ b/dialogflow/v2/dialogflow-gen.go @@ -173,6 +173,7 @@ func NewProjectsService(s *Service) *ProjectsService { rs.ConversationModels = NewProjectsConversationModelsService(s) rs.ConversationProfiles = NewProjectsConversationProfilesService(s) rs.Conversations = NewProjectsConversationsService(s) + rs.Generators = NewProjectsGeneratorsService(s) rs.KnowledgeBases = NewProjectsKnowledgeBasesService(s) rs.Locations = NewProjectsLocationsService(s) rs.Operations = NewProjectsOperationsService(s) @@ -195,6 +196,8 @@ type ProjectsService struct { Conversations *ProjectsConversationsService + Generators *ProjectsGeneratorsService + KnowledgeBases *ProjectsKnowledgeBasesService Locations *ProjectsLocationsService @@ -498,6 +501,15 @@ type ProjectsConversationsSuggestionsService struct { s *Service } +func NewProjectsGeneratorsService(s *Service) *ProjectsGeneratorsService { + rs := &ProjectsGeneratorsService{s: s} + return rs +} + +type ProjectsGeneratorsService struct { + s *Service +} + func NewProjectsKnowledgeBasesService(s *Service) *ProjectsKnowledgeBasesService { rs := &ProjectsKnowledgeBasesService{s: s} rs.Documents = NewProjectsKnowledgeBasesDocumentsService(s) @@ -527,8 +539,10 @@ func NewProjectsLocationsService(s *Service) *ProjectsLocationsService { rs.ConversationModels = NewProjectsLocationsConversationModelsService(s) rs.ConversationProfiles = NewProjectsLocationsConversationProfilesService(s) rs.Conversations = NewProjectsLocationsConversationsService(s) + rs.Generators = NewProjectsLocationsGeneratorsService(s) rs.KnowledgeBases = NewProjectsLocationsKnowledgeBasesService(s) rs.Operations = NewProjectsLocationsOperationsService(s) + rs.StatelessSuggestion = NewProjectsLocationsStatelessSuggestionService(s) rs.Suggestions = NewProjectsLocationsSuggestionsService(s) return rs } @@ -548,10 +562,14 @@ type ProjectsLocationsService struct { Conversations *ProjectsLocationsConversationsService + Generators *ProjectsLocationsGeneratorsService + KnowledgeBases *ProjectsLocationsKnowledgeBasesService Operations *ProjectsLocationsOperationsService + StatelessSuggestion *ProjectsLocationsStatelessSuggestionService + Suggestions *ProjectsLocationsSuggestionsService } @@ -825,6 +843,15 @@ type ProjectsLocationsConversationsSuggestionsService struct { s *Service } +func NewProjectsLocationsGeneratorsService(s *Service) *ProjectsLocationsGeneratorsService { + rs := &ProjectsLocationsGeneratorsService{s: s} + return rs +} + +type ProjectsLocationsGeneratorsService struct { + s *Service +} + func NewProjectsLocationsKnowledgeBasesService(s *Service) *ProjectsLocationsKnowledgeBasesService { rs := &ProjectsLocationsKnowledgeBasesService{s: s} rs.Documents = NewProjectsLocationsKnowledgeBasesDocumentsService(s) @@ -855,6 +882,15 @@ type ProjectsLocationsOperationsService struct { s *Service } +func NewProjectsLocationsStatelessSuggestionService(s *Service) *ProjectsLocationsStatelessSuggestionService { + rs := &ProjectsLocationsStatelessSuggestionService{s: s} + return rs +} + +type ProjectsLocationsStatelessSuggestionService struct { + s *Service +} + func NewProjectsLocationsSuggestionsService(s *Service) *ProjectsLocationsSuggestionsService { rs := &ProjectsLocationsSuggestionsService{s: s} return rs @@ -8897,6 +8933,29 @@ func (s *GoogleCloudDialogflowV2Conversation) MarshalJSON() ([]byte, error) { return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) } +// GoogleCloudDialogflowV2ConversationContext: Context of the conversation, +// including transcripts. +type GoogleCloudDialogflowV2ConversationContext struct { + // MessageEntries: Optional. List of message transcripts in the conversation. + MessageEntries []*GoogleCloudDialogflowV2MessageEntry `json:"messageEntries,omitempty"` + // ForceSendFields is a list of field names (e.g. "MessageEntries") to + // unconditionally include in API requests. By default, fields with empty or + // default values are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. + ForceSendFields []string `json:"-"` + // NullFields is a list of field names (e.g. "MessageEntries") to include in + // API requests with the JSON null value. By default, fields with empty values + // are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. + NullFields []string `json:"-"` +} + +func (s *GoogleCloudDialogflowV2ConversationContext) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDialogflowV2ConversationContext + return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) +} + // GoogleCloudDialogflowV2ConversationDataset: Represents a conversation // dataset that a user imports raw data into. The data inside // ConversationDataset can not be changed after ImportConversationData finishes @@ -10206,6 +10265,38 @@ func (s *GoogleCloudDialogflowV2FaqAnswer) UnmarshalJSON(data []byte) error { return nil } +// GoogleCloudDialogflowV2FewShotExample: Providing examples in the generator +// (i.e. building a few-shot generator) helps convey the desired format of the +// LLM response. NEXT_ID: 10 +type GoogleCloudDialogflowV2FewShotExample struct { + // ConversationContext: Optional. Conversation transcripts. + ConversationContext *GoogleCloudDialogflowV2ConversationContext `json:"conversationContext,omitempty"` + // ExtraInfo: Optional. Key is the placeholder field name in input, value is + // the value of the placeholder. E.g. instruction contains "@price", and + // ingested data has <"price", "10"> + ExtraInfo map[string]string `json:"extraInfo,omitempty"` + // Output: Required. Example output of the model. + Output *GoogleCloudDialogflowV2GeneratorSuggestion `json:"output,omitempty"` + // SummarizationSectionList: Summarization sections. + SummarizationSectionList *GoogleCloudDialogflowV2SummarizationSectionList `json:"summarizationSectionList,omitempty"` + // ForceSendFields is a list of field names (e.g. "ConversationContext") to + // unconditionally include in API requests. By default, fields with empty or + // default values are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. + ForceSendFields []string `json:"-"` + // NullFields is a list of field names (e.g. "ConversationContext") to include + // in API requests with the JSON null value. By default, fields with empty + // values are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. + NullFields []string `json:"-"` +} + +func (s *GoogleCloudDialogflowV2FewShotExample) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDialogflowV2FewShotExample + return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) +} + // GoogleCloudDialogflowV2Fulfillment: By default, your agent responds to a // matched intent with a static response. As an alternative, you can provide a // more dynamic response by using fulfillment. When you enable fulfillment for @@ -10369,6 +10460,73 @@ func (s *GoogleCloudDialogflowV2GcsSources) MarshalJSON() ([]byte, error) { return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) } +// GoogleCloudDialogflowV2GenerateStatelessSuggestionRequest: The request +// message for Conversations.GenerateStatelessSuggestion. +type GoogleCloudDialogflowV2GenerateStatelessSuggestionRequest struct { + // ConversationContext: Optional. Context of the conversation, including + // transcripts. + ConversationContext *GoogleCloudDialogflowV2ConversationContext `json:"conversationContext,omitempty"` + // Generator: Uncreated generator. It should be a complete generator that + // includes all information about the generator. + Generator *GoogleCloudDialogflowV2Generator `json:"generator,omitempty"` + // GeneratorName: The resource name of the existing created generator. Format: + // `projects//locations//generators/` + GeneratorName string `json:"generatorName,omitempty"` + // TriggerEvents: Optional. A list of trigger events. Generator will be + // triggered only if it's trigger event is included here. + // + // Possible values: + // "TRIGGER_EVENT_UNSPECIFIED" - Default value for TriggerEvent. + // "END_OF_UTTERANCE" - Triggers when each chat message or voice utterance + // ends. + // "MANUAL_CALL" - Triggers on the conversation manually by API calls, such + // as Conversations.GenerateStatelessSuggestion and + // Conversations.GenerateSuggestions. + TriggerEvents []string `json:"triggerEvents,omitempty"` + // ForceSendFields is a list of field names (e.g. "ConversationContext") to + // unconditionally include in API requests. By default, fields with empty or + // default values are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. + ForceSendFields []string `json:"-"` + // NullFields is a list of field names (e.g. "ConversationContext") to include + // in API requests with the JSON null value. By default, fields with empty + // values are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. + NullFields []string `json:"-"` +} + +func (s *GoogleCloudDialogflowV2GenerateStatelessSuggestionRequest) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDialogflowV2GenerateStatelessSuggestionRequest + return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) +} + +// GoogleCloudDialogflowV2GenerateStatelessSuggestionResponse: The response +// message for Conversations.GenerateStatelessSuggestion. +type GoogleCloudDialogflowV2GenerateStatelessSuggestionResponse struct { + // GeneratorSuggestion: Required. Generated suggestion for a conversation. + GeneratorSuggestion *GoogleCloudDialogflowV2GeneratorSuggestion `json:"generatorSuggestion,omitempty"` + + // ServerResponse contains the HTTP response code and headers from the server. + googleapi.ServerResponse `json:"-"` + // ForceSendFields is a list of field names (e.g. "GeneratorSuggestion") to + // unconditionally include in API requests. By default, fields with empty or + // default values are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. + ForceSendFields []string `json:"-"` + // NullFields is a list of field names (e.g. "GeneratorSuggestion") to include + // in API requests with the JSON null value. By default, fields with empty + // values are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. + NullFields []string `json:"-"` +} + +func (s *GoogleCloudDialogflowV2GenerateStatelessSuggestionResponse) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDialogflowV2GenerateStatelessSuggestionResponse + return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) +} + // GoogleCloudDialogflowV2GenerateStatelessSummaryRequest: The request message // for Conversations.GenerateStatelessSummary. type GoogleCloudDialogflowV2GenerateStatelessSummaryRequest struct { @@ -10499,6 +10657,76 @@ func (s *GoogleCloudDialogflowV2GenerateStatelessSummaryResponseSummary) Marshal return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) } +// GoogleCloudDialogflowV2Generator: LLM generator. +type GoogleCloudDialogflowV2Generator struct { + // CreateTime: Output only. Creation time of this generator. + CreateTime string `json:"createTime,omitempty"` + // Description: Optional. Human readable description of the generator. + Description string `json:"description,omitempty"` + // InferenceParameter: Optional. Inference parameters for this generator. + InferenceParameter *GoogleCloudDialogflowV2InferenceParameter `json:"inferenceParameter,omitempty"` + // Name: Output only. Identifier. The resource name of the generator. Format: + // `projects//locations//generators/` + Name string `json:"name,omitempty"` + // SummarizationContext: Input of prebuilt Summarization feature. + SummarizationContext *GoogleCloudDialogflowV2SummarizationContext `json:"summarizationContext,omitempty"` + // TriggerEvent: Optional. The trigger event of the generator. It defines when + // the generator is triggered in a conversation. + // + // Possible values: + // "TRIGGER_EVENT_UNSPECIFIED" - Default value for TriggerEvent. + // "END_OF_UTTERANCE" - Triggers when each chat message or voice utterance + // ends. + // "MANUAL_CALL" - Triggers on the conversation manually by API calls, such + // as Conversations.GenerateStatelessSuggestion and + // Conversations.GenerateSuggestions. + TriggerEvent string `json:"triggerEvent,omitempty"` + // UpdateTime: Output only. Update time of this generator. + UpdateTime string `json:"updateTime,omitempty"` + + // ServerResponse contains the HTTP response code and headers from the server. + googleapi.ServerResponse `json:"-"` + // ForceSendFields is a list of field names (e.g. "CreateTime") to + // unconditionally include in API requests. By default, fields with empty or + // default values are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. + ForceSendFields []string `json:"-"` + // NullFields is a list of field names (e.g. "CreateTime") to include in API + // requests with the JSON null value. By default, fields with empty values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. + NullFields []string `json:"-"` +} + +func (s *GoogleCloudDialogflowV2Generator) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDialogflowV2Generator + return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) +} + +// GoogleCloudDialogflowV2GeneratorSuggestion: Suggestion generated using a +// Generator. +type GoogleCloudDialogflowV2GeneratorSuggestion struct { + // SummarySuggestion: Optional. Suggested summary. + SummarySuggestion *GoogleCloudDialogflowV2SummarySuggestion `json:"summarySuggestion,omitempty"` + // ForceSendFields is a list of field names (e.g. "SummarySuggestion") to + // unconditionally include in API requests. By default, fields with empty or + // default values are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. + ForceSendFields []string `json:"-"` + // NullFields is a list of field names (e.g. "SummarySuggestion") to include in + // API requests with the JSON null value. By default, fields with empty values + // are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. + NullFields []string `json:"-"` +} + +func (s *GoogleCloudDialogflowV2GeneratorSuggestion) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDialogflowV2GeneratorSuggestion + return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) +} + // GoogleCloudDialogflowV2HumanAgentAssistantConfig: Defines the Human Agent // Assist to connect to a conversation. type GoogleCloudDialogflowV2HumanAgentAssistantConfig struct { @@ -10634,6 +10862,9 @@ type GoogleCloudDialogflowV2HumanAgentAssistantConfigSuggestionConfig struct { // FeatureConfigs: Configuration of different suggestion features. One feature // can have only one config. FeatureConfigs []*GoogleCloudDialogflowV2HumanAgentAssistantConfigSuggestionFeatureConfig `json:"featureConfigs,omitempty"` + // Generators: Optional. List of various generator resource names used in the + // conversation profile. + Generators []string `json:"generators,omitempty"` // GroupSuggestionResponses: If `group_suggestion_responses` is false, and // there are multiple `feature_configs` in `event based suggestion` or // StreamingAnalyzeContent, we will try to deliver suggestions to customers as @@ -11306,6 +11537,68 @@ func (s *GoogleCloudDialogflowV2ImportDocumentsResponse) MarshalJSON() ([]byte, return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) } +// GoogleCloudDialogflowV2InferenceParameter: The parameters of inference. +type GoogleCloudDialogflowV2InferenceParameter struct { + // MaxOutputTokens: Optional. Maximum number of the output tokens for the + // generator. + MaxOutputTokens int64 `json:"maxOutputTokens,omitempty"` + // Temperature: Optional. Controls the randomness of LLM predictions. Low + // temperature = less random. High temperature = more random. If unset (or 0), + // uses a default value of 0. + Temperature float64 `json:"temperature,omitempty"` + // TopK: Optional. Top-k changes how the model selects tokens for output. A + // top-k of 1 means the selected token is the most probable among all tokens in + // the model's vocabulary (also called greedy decoding), while a top-k of 3 + // means that the next token is selected from among the 3 most probable tokens + // (using temperature). For each token selection step, the top K tokens with + // the highest probabilities are sampled. Then tokens are further filtered + // based on topP with the final token selected using temperature sampling. + // Specify a lower value for less random responses and a higher value for more + // random responses. Acceptable value is [1, 40], default to 40. + TopK int64 `json:"topK,omitempty"` + // TopP: Optional. Top-p changes how the model selects tokens for output. + // Tokens are selected from most K (see topK parameter) probable to least until + // the sum of their probabilities equals the top-p value. For example, if + // tokens A, B, and C have a probability of 0.3, 0.2, and 0.1 and the top-p + // value is 0.5, then the model will select either A or B as the next token + // (using temperature) and doesn't consider C. The default top-p value is 0.95. + // Specify a lower value for less random responses and a higher value for more + // random responses. Acceptable value is [0.0, 1.0], default to 0.95. + TopP float64 `json:"topP,omitempty"` + // ForceSendFields is a list of field names (e.g. "MaxOutputTokens") to + // unconditionally include in API requests. By default, fields with empty or + // default values are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. + ForceSendFields []string `json:"-"` + // NullFields is a list of field names (e.g. "MaxOutputTokens") to include in + // API requests with the JSON null value. By default, fields with empty values + // are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. + NullFields []string `json:"-"` +} + +func (s *GoogleCloudDialogflowV2InferenceParameter) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDialogflowV2InferenceParameter + return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) +} + +func (s *GoogleCloudDialogflowV2InferenceParameter) UnmarshalJSON(data []byte) error { + type NoMethod GoogleCloudDialogflowV2InferenceParameter + var s1 struct { + Temperature gensupport.JSONFloat64 `json:"temperature"` + TopP gensupport.JSONFloat64 `json:"topP"` + *NoMethod + } + s1.NoMethod = (*NoMethod)(s) + if err := json.Unmarshal(data, &s1); err != nil { + return err + } + s.Temperature = float64(s1.Temperature) + s.TopP = float64(s1.TopP) + return nil +} + // GoogleCloudDialogflowV2InputAudioConfig: Instructs the speech recognizer how // to process the audio content. type GoogleCloudDialogflowV2InputAudioConfig struct { @@ -13024,6 +13317,34 @@ func (s *GoogleCloudDialogflowV2ListEnvironmentsResponse) MarshalJSON() ([]byte, return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) } +// GoogleCloudDialogflowV2ListGeneratorsResponse: Response of ListGenerators. +type GoogleCloudDialogflowV2ListGeneratorsResponse struct { + // Generators: List of generators retrieved. + Generators []*GoogleCloudDialogflowV2Generator `json:"generators,omitempty"` + // NextPageToken: Token to retrieve the next page of results, or empty if there + // are no more results in the list. + NextPageToken string `json:"nextPageToken,omitempty"` + + // ServerResponse contains the HTTP response code and headers from the server. + googleapi.ServerResponse `json:"-"` + // ForceSendFields is a list of field names (e.g. "Generators") to + // unconditionally include in API requests. By default, fields with empty or + // default values are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. + ForceSendFields []string `json:"-"` + // NullFields is a list of field names (e.g. "Generators") to include in API + // requests with the JSON null value. By default, fields with empty values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. + NullFields []string `json:"-"` +} + +func (s *GoogleCloudDialogflowV2ListGeneratorsResponse) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDialogflowV2ListGeneratorsResponse + return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) +} + // GoogleCloudDialogflowV2ListIntentsResponse: The response message for // Intents.ListIntents. type GoogleCloudDialogflowV2ListIntentsResponse struct { @@ -13309,6 +13630,45 @@ func (s *GoogleCloudDialogflowV2MessageAnnotation) MarshalJSON() ([]byte, error) return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) } +// GoogleCloudDialogflowV2MessageEntry: Represents a message entry of a +// conversation. +type GoogleCloudDialogflowV2MessageEntry struct { + // CreateTime: Optional. Create time of the message entry. + CreateTime string `json:"createTime,omitempty"` + // LanguageCode: Optional. The language of the text. See Language Support + // (https://cloud.google.com/dialogflow/docs/reference/language) for a list of + // the currently supported language codes. + LanguageCode string `json:"languageCode,omitempty"` + // Role: Optional. Participant role of the message. + // + // Possible values: + // "ROLE_UNSPECIFIED" - Participant role not set. + // "HUMAN_AGENT" - Participant is a human agent. + // "AUTOMATED_AGENT" - Participant is an automated agent, such as a + // Dialogflow agent. + // "END_USER" - Participant is an end user that has called or chatted with + // Dialogflow services. + Role string `json:"role,omitempty"` + // Text: Optional. Transcript content of the message. + Text string `json:"text,omitempty"` + // ForceSendFields is a list of field names (e.g. "CreateTime") to + // unconditionally include in API requests. By default, fields with empty or + // default values are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. + ForceSendFields []string `json:"-"` + // NullFields is a list of field names (e.g. "CreateTime") to include in API + // requests with the JSON null value. By default, fields with empty values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. + NullFields []string `json:"-"` +} + +func (s *GoogleCloudDialogflowV2MessageEntry) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDialogflowV2MessageEntry + return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) +} + // GoogleCloudDialogflowV2NotificationConfig: Defines notification behavior. type GoogleCloudDialogflowV2NotificationConfig struct { // MessageFormat: Format of message. @@ -14868,6 +15228,157 @@ func (s *GoogleCloudDialogflowV2SuggestionResult) MarshalJSON() ([]byte, error) return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) } +// GoogleCloudDialogflowV2SummarizationContext: Summarization context that +// customer can configure. +type GoogleCloudDialogflowV2SummarizationContext struct { + // FewShotExamples: Optional. List of few shot examples. + FewShotExamples []*GoogleCloudDialogflowV2FewShotExample `json:"fewShotExamples,omitempty"` + // OutputLanguageCode: Optional. The target language of the generated summary. + // The language code for conversation will be used if this field is empty. + // Supported 2.0 and later versions. + OutputLanguageCode string `json:"outputLanguageCode,omitempty"` + // SummarizationSections: Optional. List of sections. Note it contains both + // predefined section sand customer defined sections. + SummarizationSections []*GoogleCloudDialogflowV2SummarizationSection `json:"summarizationSections,omitempty"` + // Version: Optional. Version of the feature. If not set, default to latest + // version. Current candidates are ["1.0"]. + Version string `json:"version,omitempty"` + // ForceSendFields is a list of field names (e.g. "FewShotExamples") to + // unconditionally include in API requests. By default, fields with empty or + // default values are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. + ForceSendFields []string `json:"-"` + // NullFields is a list of field names (e.g. "FewShotExamples") to include in + // API requests with the JSON null value. By default, fields with empty values + // are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. + NullFields []string `json:"-"` +} + +func (s *GoogleCloudDialogflowV2SummarizationContext) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDialogflowV2SummarizationContext + return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) +} + +// GoogleCloudDialogflowV2SummarizationSection: Represents the section of +// summarization. +type GoogleCloudDialogflowV2SummarizationSection struct { + // Definition: Optional. Definition of the section, for example, "what the + // customer needs help with or has question about." + Definition string `json:"definition,omitempty"` + // Key: Optional. Name of the section, for example, "situation". + Key string `json:"key,omitempty"` + // Type: Optional. Type of the summarization section. + // + // Possible values: + // "TYPE_UNSPECIFIED" - Undefined section type, does not return anything. + // "SITUATION" - What the customer needs help with or has question about. + // Section name: "situation". + // "ACTION" - What the agent does to help the customer. Section name: + // "action". + // "RESOLUTION" - Result of the customer service. A single word describing + // the result of the conversation. Section name: "resolution". + // "REASON_FOR_CANCELLATION" - Reason for cancellation if the customer + // requests for a cancellation. "N/A" otherwise. Section name: + // "reason_for_cancellation". + // "CUSTOMER_SATISFACTION" - "Unsatisfied" or "Satisfied" depending on the + // customer's feelings at the end of the conversation. Section name: + // "customer_satisfaction". + // "ENTITIES" - Key entities extracted from the conversation, such as ticket + // number, order number, dollar amount, etc. Section names are prefixed by + // "entities/". + // "CUSTOMER_DEFINED" - Customer defined sections. + Type string `json:"type,omitempty"` + // ForceSendFields is a list of field names (e.g. "Definition") to + // unconditionally include in API requests. By default, fields with empty or + // default values are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. + ForceSendFields []string `json:"-"` + // NullFields is a list of field names (e.g. "Definition") to include in API + // requests with the JSON null value. By default, fields with empty values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. + NullFields []string `json:"-"` +} + +func (s *GoogleCloudDialogflowV2SummarizationSection) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDialogflowV2SummarizationSection + return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) +} + +// GoogleCloudDialogflowV2SummarizationSectionList: List of summarization +// sections. +type GoogleCloudDialogflowV2SummarizationSectionList struct { + // SummarizationSections: Optional. Summarization sections. + SummarizationSections []*GoogleCloudDialogflowV2SummarizationSection `json:"summarizationSections,omitempty"` + // ForceSendFields is a list of field names (e.g. "SummarizationSections") to + // unconditionally include in API requests. By default, fields with empty or + // default values are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. + ForceSendFields []string `json:"-"` + // NullFields is a list of field names (e.g. "SummarizationSections") to + // include in API requests with the JSON null value. By default, fields with + // empty values are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. + NullFields []string `json:"-"` +} + +func (s *GoogleCloudDialogflowV2SummarizationSectionList) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDialogflowV2SummarizationSectionList + return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) +} + +// GoogleCloudDialogflowV2SummarySuggestion: Suggested summary of the +// conversation. +type GoogleCloudDialogflowV2SummarySuggestion struct { + // SummarySections: Required. All the parts of generated summary. + SummarySections []*GoogleCloudDialogflowV2SummarySuggestionSummarySection `json:"summarySections,omitempty"` + // ForceSendFields is a list of field names (e.g. "SummarySections") to + // unconditionally include in API requests. By default, fields with empty or + // default values are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. + ForceSendFields []string `json:"-"` + // NullFields is a list of field names (e.g. "SummarySections") to include in + // API requests with the JSON null value. By default, fields with empty values + // are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. + NullFields []string `json:"-"` +} + +func (s *GoogleCloudDialogflowV2SummarySuggestion) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDialogflowV2SummarySuggestion + return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) +} + +// GoogleCloudDialogflowV2SummarySuggestionSummarySection: A component of the +// generated summary. +type GoogleCloudDialogflowV2SummarySuggestionSummarySection struct { + // Section: Required. Name of the section. + Section string `json:"section,omitempty"` + // Summary: Required. Summary text for the section. + Summary string `json:"summary,omitempty"` + // ForceSendFields is a list of field names (e.g. "Section") to unconditionally + // include in API requests. By default, fields with empty or default values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. + ForceSendFields []string `json:"-"` + // NullFields is a list of field names (e.g. "Section") to include in API + // requests with the JSON null value. By default, fields with empty values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. + NullFields []string `json:"-"` +} + +func (s *GoogleCloudDialogflowV2SummarySuggestionSummarySection) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDialogflowV2SummarySuggestionSummarySection + return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) +} + // GoogleCloudDialogflowV2SynthesizeSpeechConfig: Configuration of how speech // should be synthesized. type GoogleCloudDialogflowV2SynthesizeSpeechConfig struct { @@ -31907,6 +32418,266 @@ func (c *ProjectsConversationsSuggestionsSuggestConversationSummaryCall) Do(opts return ret, nil } +type ProjectsGeneratorsCreateCall struct { + s *Service + parent string + googleclouddialogflowv2generator *GoogleCloudDialogflowV2Generator + urlParams_ gensupport.URLParams + ctx_ context.Context + header_ http.Header +} + +// Create: Creates a generator. +// +// - parent: The project/location to create generator for. Format: +// `projects//locations/`. +func (r *ProjectsGeneratorsService) Create(parent string, googleclouddialogflowv2generator *GoogleCloudDialogflowV2Generator) *ProjectsGeneratorsCreateCall { + c := &ProjectsGeneratorsCreateCall{s: r.s, urlParams_: make(gensupport.URLParams)} + c.parent = parent + c.googleclouddialogflowv2generator = googleclouddialogflowv2generator + return c +} + +// GeneratorId sets the optional parameter "generatorId": The ID to use for the +// generator, which will become the final component of the generator's resource +// name. The generator ID must be compliant with the regression fomula +// `a-zA-Z*` with the characters length in range of [3,64]. If the field is not +// provided, an Id will be auto-generated. If the field is provided, the caller +// is resposible for 1. the uniqueness of the ID, otherwise the request will be +// rejected. 2. the consistency for whether to use custom ID or not under a +// project to better ensure uniqueness. +func (c *ProjectsGeneratorsCreateCall) GeneratorId(generatorId string) *ProjectsGeneratorsCreateCall { + c.urlParams_.Set("generatorId", generatorId) + return c +} + +// Fields allows partial responses to be retrieved. See +// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more +// details. +func (c *ProjectsGeneratorsCreateCall) Fields(s ...googleapi.Field) *ProjectsGeneratorsCreateCall { + c.urlParams_.Set("fields", googleapi.CombineFields(s)) + return c +} + +// Context sets the context to be used in this call's Do method. +func (c *ProjectsGeneratorsCreateCall) Context(ctx context.Context) *ProjectsGeneratorsCreateCall { + c.ctx_ = ctx + return c +} + +// Header returns a http.Header that can be modified by the caller to add +// headers to the request. +func (c *ProjectsGeneratorsCreateCall) Header() http.Header { + if c.header_ == nil { + c.header_ = make(http.Header) + } + return c.header_ +} + +func (c *ProjectsGeneratorsCreateCall) doRequest(alt string) (*http.Response, error) { + reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "application/json", c.header_) + var body io.Reader = nil + body, err := googleapi.WithoutDataWrapper.JSONReader(c.googleclouddialogflowv2generator) + if err != nil { + return nil, err + } + c.urlParams_.Set("alt", alt) + c.urlParams_.Set("prettyPrint", "false") + urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+parent}/generators") + 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 "dialogflow.projects.generators.create" call. +// Any non-2xx status code is an error. Response headers are in either +// *GoogleCloudDialogflowV2Generator.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 *ProjectsGeneratorsCreateCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDialogflowV2Generator, error) { + gensupport.SetOptions(c.urlParams_, opts...) + res, err := c.doRequest("json") + if res != nil && res.StatusCode == http.StatusNotModified { + if res.Body != nil { + res.Body.Close() + } + return nil, gensupport.WrapError(&googleapi.Error{ + Code: res.StatusCode, + Header: res.Header, + }) + } + if err != nil { + return nil, err + } + defer googleapi.CloseBody(res) + if err := googleapi.CheckResponse(res); err != nil { + return nil, gensupport.WrapError(err) + } + ret := &GoogleCloudDialogflowV2Generator{ + 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 +} + +type ProjectsGeneratorsListCall struct { + s *Service + parent string + urlParams_ gensupport.URLParams + ifNoneMatch_ string + ctx_ context.Context + header_ http.Header +} + +// List: Lists generators. +// +// - parent: The project/location to list generators for. Format: +// `projects//locations/`. +func (r *ProjectsGeneratorsService) List(parent string) *ProjectsGeneratorsListCall { + c := &ProjectsGeneratorsListCall{s: r.s, urlParams_: make(gensupport.URLParams)} + c.parent = parent + return c +} + +// PageSize sets the optional parameter "pageSize": Maximum number of +// conversation models to return in a single page. Default to 10. +func (c *ProjectsGeneratorsListCall) PageSize(pageSize int64) *ProjectsGeneratorsListCall { + c.urlParams_.Set("pageSize", fmt.Sprint(pageSize)) + return c +} + +// PageToken sets the optional parameter "pageToken": The next_page_token value +// returned from a previous list request. +func (c *ProjectsGeneratorsListCall) PageToken(pageToken string) *ProjectsGeneratorsListCall { + c.urlParams_.Set("pageToken", pageToken) + return c +} + +// Fields allows partial responses to be retrieved. See +// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more +// details. +func (c *ProjectsGeneratorsListCall) Fields(s ...googleapi.Field) *ProjectsGeneratorsListCall { + c.urlParams_.Set("fields", googleapi.CombineFields(s)) + return c +} + +// IfNoneMatch sets an 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. +func (c *ProjectsGeneratorsListCall) IfNoneMatch(entityTag string) *ProjectsGeneratorsListCall { + c.ifNoneMatch_ = entityTag + return c +} + +// Context sets the context to be used in this call's Do method. +func (c *ProjectsGeneratorsListCall) Context(ctx context.Context) *ProjectsGeneratorsListCall { + c.ctx_ = ctx + return c +} + +// Header returns a http.Header that can be modified by the caller to add +// headers to the request. +func (c *ProjectsGeneratorsListCall) Header() http.Header { + if c.header_ == nil { + c.header_ = make(http.Header) + } + return c.header_ +} + +func (c *ProjectsGeneratorsListCall) doRequest(alt string) (*http.Response, error) { + reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "", c.header_) + 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}/generators") + 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 "dialogflow.projects.generators.list" call. +// Any non-2xx status code is an error. Response headers are in either +// *GoogleCloudDialogflowV2ListGeneratorsResponse.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 *ProjectsGeneratorsListCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDialogflowV2ListGeneratorsResponse, error) { + gensupport.SetOptions(c.urlParams_, opts...) + res, err := c.doRequest("json") + if res != nil && res.StatusCode == http.StatusNotModified { + if res.Body != nil { + res.Body.Close() + } + return nil, gensupport.WrapError(&googleapi.Error{ + Code: res.StatusCode, + Header: res.Header, + }) + } + if err != nil { + return nil, err + } + defer googleapi.CloseBody(res) + if err := googleapi.CheckResponse(res); err != nil { + return nil, gensupport.WrapError(err) + } + ret := &GoogleCloudDialogflowV2ListGeneratorsResponse{ + 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 +} + +// 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 *ProjectsGeneratorsListCall) Pages(ctx context.Context, f func(*GoogleCloudDialogflowV2ListGeneratorsResponse) error) error { + c.ctx_ = ctx + defer c.PageToken(c.urlParams_.Get("pageToken")) + for { + x, err := c.Do() + if err != nil { + return err + } + if err := f(x); err != nil { + return err + } + if x.NextPageToken == "" { + return nil + } + c.PageToken(x.NextPageToken) + } +} + type ProjectsKnowledgeBasesCreateCall struct { s *Service parent string @@ -45720,6 +46491,582 @@ func (c *ProjectsLocationsConversationsSuggestionsSuggestConversationSummaryCall return ret, nil } +type ProjectsLocationsGeneratorsCreateCall struct { + s *Service + parent string + googleclouddialogflowv2generator *GoogleCloudDialogflowV2Generator + urlParams_ gensupport.URLParams + ctx_ context.Context + header_ http.Header +} + +// Create: Creates a generator. +// +// - parent: The project/location to create generator for. Format: +// `projects//locations/`. +func (r *ProjectsLocationsGeneratorsService) Create(parent string, googleclouddialogflowv2generator *GoogleCloudDialogflowV2Generator) *ProjectsLocationsGeneratorsCreateCall { + c := &ProjectsLocationsGeneratorsCreateCall{s: r.s, urlParams_: make(gensupport.URLParams)} + c.parent = parent + c.googleclouddialogflowv2generator = googleclouddialogflowv2generator + return c +} + +// GeneratorId sets the optional parameter "generatorId": The ID to use for the +// generator, which will become the final component of the generator's resource +// name. The generator ID must be compliant with the regression fomula +// `a-zA-Z*` with the characters length in range of [3,64]. If the field is not +// provided, an Id will be auto-generated. If the field is provided, the caller +// is resposible for 1. the uniqueness of the ID, otherwise the request will be +// rejected. 2. the consistency for whether to use custom ID or not under a +// project to better ensure uniqueness. +func (c *ProjectsLocationsGeneratorsCreateCall) GeneratorId(generatorId string) *ProjectsLocationsGeneratorsCreateCall { + c.urlParams_.Set("generatorId", generatorId) + return c +} + +// Fields allows partial responses to be retrieved. See +// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more +// details. +func (c *ProjectsLocationsGeneratorsCreateCall) Fields(s ...googleapi.Field) *ProjectsLocationsGeneratorsCreateCall { + c.urlParams_.Set("fields", googleapi.CombineFields(s)) + return c +} + +// Context sets the context to be used in this call's Do method. +func (c *ProjectsLocationsGeneratorsCreateCall) Context(ctx context.Context) *ProjectsLocationsGeneratorsCreateCall { + c.ctx_ = ctx + return c +} + +// Header returns a http.Header that can be modified by the caller to add +// headers to the request. +func (c *ProjectsLocationsGeneratorsCreateCall) Header() http.Header { + if c.header_ == nil { + c.header_ = make(http.Header) + } + return c.header_ +} + +func (c *ProjectsLocationsGeneratorsCreateCall) doRequest(alt string) (*http.Response, error) { + reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "application/json", c.header_) + var body io.Reader = nil + body, err := googleapi.WithoutDataWrapper.JSONReader(c.googleclouddialogflowv2generator) + if err != nil { + return nil, err + } + c.urlParams_.Set("alt", alt) + c.urlParams_.Set("prettyPrint", "false") + urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+parent}/generators") + 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 "dialogflow.projects.locations.generators.create" call. +// Any non-2xx status code is an error. Response headers are in either +// *GoogleCloudDialogflowV2Generator.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 *ProjectsLocationsGeneratorsCreateCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDialogflowV2Generator, error) { + gensupport.SetOptions(c.urlParams_, opts...) + res, err := c.doRequest("json") + if res != nil && res.StatusCode == http.StatusNotModified { + if res.Body != nil { + res.Body.Close() + } + return nil, gensupport.WrapError(&googleapi.Error{ + Code: res.StatusCode, + Header: res.Header, + }) + } + if err != nil { + return nil, err + } + defer googleapi.CloseBody(res) + if err := googleapi.CheckResponse(res); err != nil { + return nil, gensupport.WrapError(err) + } + ret := &GoogleCloudDialogflowV2Generator{ + 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 +} + +type ProjectsLocationsGeneratorsDeleteCall struct { + s *Service + name string + urlParams_ gensupport.URLParams + ctx_ context.Context + header_ http.Header +} + +// Delete: Deletes a generator. +// +// - name: The generator resource name to delete. Format: +// `projects//locations//generators/`. +func (r *ProjectsLocationsGeneratorsService) Delete(name string) *ProjectsLocationsGeneratorsDeleteCall { + c := &ProjectsLocationsGeneratorsDeleteCall{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 +// details. +func (c *ProjectsLocationsGeneratorsDeleteCall) Fields(s ...googleapi.Field) *ProjectsLocationsGeneratorsDeleteCall { + c.urlParams_.Set("fields", googleapi.CombineFields(s)) + return c +} + +// Context sets the context to be used in this call's Do method. +func (c *ProjectsLocationsGeneratorsDeleteCall) Context(ctx context.Context) *ProjectsLocationsGeneratorsDeleteCall { + c.ctx_ = ctx + return c +} + +// Header returns a http.Header that can be modified by the caller to add +// headers to the request. +func (c *ProjectsLocationsGeneratorsDeleteCall) Header() http.Header { + if c.header_ == nil { + c.header_ = make(http.Header) + } + return c.header_ +} + +func (c *ProjectsLocationsGeneratorsDeleteCall) doRequest(alt string) (*http.Response, error) { + reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "", c.header_) + 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 "dialogflow.projects.locations.generators.delete" call. +// Any non-2xx status code is an error. Response headers are in either +// *GoogleProtobufEmpty.ServerResponse.Header or (if a response was returned at +// all) in error.(*googleapi.Error).Header. Use googleapi.IsNotModified to +// check whether the returned error was because http.StatusNotModified was +// returned. +func (c *ProjectsLocationsGeneratorsDeleteCall) Do(opts ...googleapi.CallOption) (*GoogleProtobufEmpty, error) { + gensupport.SetOptions(c.urlParams_, opts...) + res, err := c.doRequest("json") + if res != nil && res.StatusCode == http.StatusNotModified { + if res.Body != nil { + res.Body.Close() + } + return nil, gensupport.WrapError(&googleapi.Error{ + Code: res.StatusCode, + Header: res.Header, + }) + } + if err != nil { + return nil, err + } + defer googleapi.CloseBody(res) + if err := googleapi.CheckResponse(res); err != nil { + return nil, gensupport.WrapError(err) + } + ret := &GoogleProtobufEmpty{ + ServerResponse: googleapi.ServerResponse{ + Header: res.Header, + HTTPStatusCode: res.StatusCode, + }, + } + target := &ret + if err := gensupport.DecodeResponse(target, res); err != nil { + return nil, err + } + return ret, nil +} + +type ProjectsLocationsGeneratorsGetCall struct { + s *Service + name string + urlParams_ gensupport.URLParams + ifNoneMatch_ string + ctx_ context.Context + header_ http.Header +} + +// Get: Retrieves a generator. +// +// - name: The generator resource name to retrieve. Format: +// `projects//locations/`/generators/`. +func (r *ProjectsLocationsGeneratorsService) Get(name string) *ProjectsLocationsGeneratorsGetCall { + c := &ProjectsLocationsGeneratorsGetCall{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 +// details. +func (c *ProjectsLocationsGeneratorsGetCall) Fields(s ...googleapi.Field) *ProjectsLocationsGeneratorsGetCall { + c.urlParams_.Set("fields", googleapi.CombineFields(s)) + return c +} + +// IfNoneMatch sets an 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. +func (c *ProjectsLocationsGeneratorsGetCall) IfNoneMatch(entityTag string) *ProjectsLocationsGeneratorsGetCall { + c.ifNoneMatch_ = entityTag + return c +} + +// Context sets the context to be used in this call's Do method. +func (c *ProjectsLocationsGeneratorsGetCall) Context(ctx context.Context) *ProjectsLocationsGeneratorsGetCall { + c.ctx_ = ctx + return c +} + +// Header returns a http.Header that can be modified by the caller to add +// headers to the request. +func (c *ProjectsLocationsGeneratorsGetCall) Header() http.Header { + if c.header_ == nil { + c.header_ = make(http.Header) + } + return c.header_ +} + +func (c *ProjectsLocationsGeneratorsGetCall) doRequest(alt string) (*http.Response, error) { + reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "", c.header_) + 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 "dialogflow.projects.locations.generators.get" call. +// Any non-2xx status code is an error. Response headers are in either +// *GoogleCloudDialogflowV2Generator.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 *ProjectsLocationsGeneratorsGetCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDialogflowV2Generator, error) { + gensupport.SetOptions(c.urlParams_, opts...) + res, err := c.doRequest("json") + if res != nil && res.StatusCode == http.StatusNotModified { + if res.Body != nil { + res.Body.Close() + } + return nil, gensupport.WrapError(&googleapi.Error{ + Code: res.StatusCode, + Header: res.Header, + }) + } + if err != nil { + return nil, err + } + defer googleapi.CloseBody(res) + if err := googleapi.CheckResponse(res); err != nil { + return nil, gensupport.WrapError(err) + } + ret := &GoogleCloudDialogflowV2Generator{ + 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 +} + +type ProjectsLocationsGeneratorsListCall struct { + s *Service + parent string + urlParams_ gensupport.URLParams + ifNoneMatch_ string + ctx_ context.Context + header_ http.Header +} + +// List: Lists generators. +// +// - parent: The project/location to list generators for. Format: +// `projects//locations/`. +func (r *ProjectsLocationsGeneratorsService) List(parent string) *ProjectsLocationsGeneratorsListCall { + c := &ProjectsLocationsGeneratorsListCall{s: r.s, urlParams_: make(gensupport.URLParams)} + c.parent = parent + return c +} + +// PageSize sets the optional parameter "pageSize": Maximum number of +// conversation models to return in a single page. Default to 10. +func (c *ProjectsLocationsGeneratorsListCall) PageSize(pageSize int64) *ProjectsLocationsGeneratorsListCall { + c.urlParams_.Set("pageSize", fmt.Sprint(pageSize)) + return c +} + +// PageToken sets the optional parameter "pageToken": The next_page_token value +// returned from a previous list request. +func (c *ProjectsLocationsGeneratorsListCall) PageToken(pageToken string) *ProjectsLocationsGeneratorsListCall { + c.urlParams_.Set("pageToken", pageToken) + return c +} + +// Fields allows partial responses to be retrieved. See +// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more +// details. +func (c *ProjectsLocationsGeneratorsListCall) Fields(s ...googleapi.Field) *ProjectsLocationsGeneratorsListCall { + c.urlParams_.Set("fields", googleapi.CombineFields(s)) + return c +} + +// IfNoneMatch sets an 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. +func (c *ProjectsLocationsGeneratorsListCall) IfNoneMatch(entityTag string) *ProjectsLocationsGeneratorsListCall { + c.ifNoneMatch_ = entityTag + return c +} + +// Context sets the context to be used in this call's Do method. +func (c *ProjectsLocationsGeneratorsListCall) Context(ctx context.Context) *ProjectsLocationsGeneratorsListCall { + c.ctx_ = ctx + return c +} + +// Header returns a http.Header that can be modified by the caller to add +// headers to the request. +func (c *ProjectsLocationsGeneratorsListCall) Header() http.Header { + if c.header_ == nil { + c.header_ = make(http.Header) + } + return c.header_ +} + +func (c *ProjectsLocationsGeneratorsListCall) doRequest(alt string) (*http.Response, error) { + reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "", c.header_) + 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}/generators") + 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 "dialogflow.projects.locations.generators.list" call. +// Any non-2xx status code is an error. Response headers are in either +// *GoogleCloudDialogflowV2ListGeneratorsResponse.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 *ProjectsLocationsGeneratorsListCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDialogflowV2ListGeneratorsResponse, error) { + gensupport.SetOptions(c.urlParams_, opts...) + res, err := c.doRequest("json") + if res != nil && res.StatusCode == http.StatusNotModified { + if res.Body != nil { + res.Body.Close() + } + return nil, gensupport.WrapError(&googleapi.Error{ + Code: res.StatusCode, + Header: res.Header, + }) + } + if err != nil { + return nil, err + } + defer googleapi.CloseBody(res) + if err := googleapi.CheckResponse(res); err != nil { + return nil, gensupport.WrapError(err) + } + ret := &GoogleCloudDialogflowV2ListGeneratorsResponse{ + 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 +} + +// 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 *ProjectsLocationsGeneratorsListCall) Pages(ctx context.Context, f func(*GoogleCloudDialogflowV2ListGeneratorsResponse) error) error { + c.ctx_ = ctx + defer c.PageToken(c.urlParams_.Get("pageToken")) + for { + x, err := c.Do() + if err != nil { + return err + } + if err := f(x); err != nil { + return err + } + if x.NextPageToken == "" { + return nil + } + c.PageToken(x.NextPageToken) + } +} + +type ProjectsLocationsGeneratorsPatchCall struct { + s *Service + name string + googleclouddialogflowv2generator *GoogleCloudDialogflowV2Generator + urlParams_ gensupport.URLParams + ctx_ context.Context + header_ http.Header +} + +// Patch: Updates a generator. +// +// - name: Output only. Identifier. The resource name of the generator. Format: +// `projects//locations//generators/`. +func (r *ProjectsLocationsGeneratorsService) Patch(name string, googleclouddialogflowv2generator *GoogleCloudDialogflowV2Generator) *ProjectsLocationsGeneratorsPatchCall { + c := &ProjectsLocationsGeneratorsPatchCall{s: r.s, urlParams_: make(gensupport.URLParams)} + c.name = name + c.googleclouddialogflowv2generator = googleclouddialogflowv2generator + return c +} + +// UpdateMask sets the optional parameter "updateMask": The list of fields to +// update. +func (c *ProjectsLocationsGeneratorsPatchCall) UpdateMask(updateMask string) *ProjectsLocationsGeneratorsPatchCall { + 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 +// details. +func (c *ProjectsLocationsGeneratorsPatchCall) Fields(s ...googleapi.Field) *ProjectsLocationsGeneratorsPatchCall { + c.urlParams_.Set("fields", googleapi.CombineFields(s)) + return c +} + +// Context sets the context to be used in this call's Do method. +func (c *ProjectsLocationsGeneratorsPatchCall) Context(ctx context.Context) *ProjectsLocationsGeneratorsPatchCall { + c.ctx_ = ctx + return c +} + +// Header returns a http.Header that can be modified by the caller to add +// headers to the request. +func (c *ProjectsLocationsGeneratorsPatchCall) Header() http.Header { + if c.header_ == nil { + c.header_ = make(http.Header) + } + return c.header_ +} + +func (c *ProjectsLocationsGeneratorsPatchCall) doRequest(alt string) (*http.Response, error) { + reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "application/json", c.header_) + var body io.Reader = nil + body, err := googleapi.WithoutDataWrapper.JSONReader(c.googleclouddialogflowv2generator) + if err != nil { + return nil, err + } + 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 "dialogflow.projects.locations.generators.patch" call. +// Any non-2xx status code is an error. Response headers are in either +// *GoogleCloudDialogflowV2Generator.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 *ProjectsLocationsGeneratorsPatchCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDialogflowV2Generator, error) { + gensupport.SetOptions(c.urlParams_, opts...) + res, err := c.doRequest("json") + if res != nil && res.StatusCode == http.StatusNotModified { + if res.Body != nil { + res.Body.Close() + } + return nil, gensupport.WrapError(&googleapi.Error{ + Code: res.StatusCode, + Header: res.Header, + }) + } + if err != nil { + return nil, err + } + defer googleapi.CloseBody(res) + if err := googleapi.CheckResponse(res); err != nil { + return nil, gensupport.WrapError(err) + } + ret := &GoogleCloudDialogflowV2Generator{ + 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 +} + type ProjectsLocationsKnowledgeBasesCreateCall struct { s *Service parent string @@ -47593,6 +48940,110 @@ func (c *ProjectsLocationsOperationsListCall) Pages(ctx context.Context, f func( } } +type ProjectsLocationsStatelessSuggestionGenerateCall struct { + s *Service + parent string + googleclouddialogflowv2generatestatelesssuggestionrequest *GoogleCloudDialogflowV2GenerateStatelessSuggestionRequest + urlParams_ gensupport.URLParams + ctx_ context.Context + header_ http.Header +} + +// Generate: Generates and returns a suggestion for a conversation that does +// not have a resource created for it. +// +// - parent: The parent resource to charge for the Suggestion's generation. +// Format: `projects//locations/`. +func (r *ProjectsLocationsStatelessSuggestionService) Generate(parent string, googleclouddialogflowv2generatestatelesssuggestionrequest *GoogleCloudDialogflowV2GenerateStatelessSuggestionRequest) *ProjectsLocationsStatelessSuggestionGenerateCall { + c := &ProjectsLocationsStatelessSuggestionGenerateCall{s: r.s, urlParams_: make(gensupport.URLParams)} + c.parent = parent + c.googleclouddialogflowv2generatestatelesssuggestionrequest = googleclouddialogflowv2generatestatelesssuggestionrequest + return c +} + +// Fields allows partial responses to be retrieved. See +// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more +// details. +func (c *ProjectsLocationsStatelessSuggestionGenerateCall) Fields(s ...googleapi.Field) *ProjectsLocationsStatelessSuggestionGenerateCall { + c.urlParams_.Set("fields", googleapi.CombineFields(s)) + return c +} + +// Context sets the context to be used in this call's Do method. +func (c *ProjectsLocationsStatelessSuggestionGenerateCall) Context(ctx context.Context) *ProjectsLocationsStatelessSuggestionGenerateCall { + c.ctx_ = ctx + return c +} + +// Header returns a http.Header that can be modified by the caller to add +// headers to the request. +func (c *ProjectsLocationsStatelessSuggestionGenerateCall) Header() http.Header { + if c.header_ == nil { + c.header_ = make(http.Header) + } + return c.header_ +} + +func (c *ProjectsLocationsStatelessSuggestionGenerateCall) doRequest(alt string) (*http.Response, error) { + reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "application/json", c.header_) + var body io.Reader = nil + body, err := googleapi.WithoutDataWrapper.JSONReader(c.googleclouddialogflowv2generatestatelesssuggestionrequest) + if err != nil { + return nil, err + } + c.urlParams_.Set("alt", alt) + c.urlParams_.Set("prettyPrint", "false") + urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+parent}/statelessSuggestion:generate") + 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 "dialogflow.projects.locations.statelessSuggestion.generate" call. +// Any non-2xx status code is an error. Response headers are in either +// *GoogleCloudDialogflowV2GenerateStatelessSuggestionResponse.ServerResponse.He +// ader 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 *ProjectsLocationsStatelessSuggestionGenerateCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDialogflowV2GenerateStatelessSuggestionResponse, error) { + gensupport.SetOptions(c.urlParams_, opts...) + res, err := c.doRequest("json") + if res != nil && res.StatusCode == http.StatusNotModified { + if res.Body != nil { + res.Body.Close() + } + return nil, gensupport.WrapError(&googleapi.Error{ + Code: res.StatusCode, + Header: res.Header, + }) + } + if err != nil { + return nil, err + } + defer googleapi.CloseBody(res) + if err := googleapi.CheckResponse(res); err != nil { + return nil, gensupport.WrapError(err) + } + ret := &GoogleCloudDialogflowV2GenerateStatelessSuggestionResponse{ + 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 +} + type ProjectsLocationsSuggestionsGenerateStatelessSummaryCall struct { s *Service parent string diff --git a/dialogflow/v2beta1/dialogflow-api.json b/dialogflow/v2beta1/dialogflow-api.json index 674408b2d7d..b8082e00920 100644 --- a/dialogflow/v2beta1/dialogflow-api.json +++ b/dialogflow/v2beta1/dialogflow-api.json @@ -3530,6 +3530,81 @@ } } }, + "generators": { + "methods": { + "create": { + "description": "Creates a generator.", + "flatPath": "v2beta1/projects/{projectsId}/generators", + "httpMethod": "POST", + "id": "dialogflow.projects.generators.create", + "parameterOrder": [ + "parent" + ], + "parameters": { + "generatorId": { + "description": "Optional. The ID to use for the generator, which will become the final component of the generator's resource name. The generator ID must be compliant with the regression fomula `a-zA-Z*` with the characters length in range of [3,64]. If the field is not provided, an Id will be auto-generated. If the field is provided, the caller is resposible for 1. the uniqueness of the ID, otherwise the request will be rejected. 2. the consistency for whether to use custom ID or not under a project to better ensure uniqueness.", + "location": "query", + "type": "string" + }, + "parent": { + "description": "Required. The project/location to create generator for. Format: `projects//locations/`", + "location": "path", + "pattern": "^projects/[^/]+$", + "required": true, + "type": "string" + } + }, + "path": "v2beta1/{+parent}/generators", + "request": { + "$ref": "GoogleCloudDialogflowV2beta1Generator" + }, + "response": { + "$ref": "GoogleCloudDialogflowV2beta1Generator" + }, + "scopes": [ + "https://www.googleapis.com/auth/cloud-platform", + "https://www.googleapis.com/auth/dialogflow" + ] + }, + "list": { + "description": "Lists generators.", + "flatPath": "v2beta1/projects/{projectsId}/generators", + "httpMethod": "GET", + "id": "dialogflow.projects.generators.list", + "parameterOrder": [ + "parent" + ], + "parameters": { + "pageSize": { + "description": "Optional. Maximum number of conversation models to return in a single page. Default to 10.", + "format": "int32", + "location": "query", + "type": "integer" + }, + "pageToken": { + "description": "Optional. The next_page_token value returned from a previous list request.", + "location": "query", + "type": "string" + }, + "parent": { + "description": "Required. The project/location to list generators for. Format: `projects//locations/`", + "location": "path", + "pattern": "^projects/[^/]+$", + "required": true, + "type": "string" + } + }, + "path": "v2beta1/{+parent}/generators", + "response": { + "$ref": "GoogleCloudDialogflowV2beta1ListGeneratorsResponse" + }, + "scopes": [ + "https://www.googleapis.com/auth/cloud-platform", + "https://www.googleapis.com/auth/dialogflow" + ] + } + } + }, "knowledgeBases": { "methods": { "create": { @@ -6976,6 +7051,168 @@ } } }, + "generators": { + "methods": { + "create": { + "description": "Creates a generator.", + "flatPath": "v2beta1/projects/{projectsId}/locations/{locationsId}/generators", + "httpMethod": "POST", + "id": "dialogflow.projects.locations.generators.create", + "parameterOrder": [ + "parent" + ], + "parameters": { + "generatorId": { + "description": "Optional. The ID to use for the generator, which will become the final component of the generator's resource name. The generator ID must be compliant with the regression fomula `a-zA-Z*` with the characters length in range of [3,64]. If the field is not provided, an Id will be auto-generated. If the field is provided, the caller is resposible for 1. the uniqueness of the ID, otherwise the request will be rejected. 2. the consistency for whether to use custom ID or not under a project to better ensure uniqueness.", + "location": "query", + "type": "string" + }, + "parent": { + "description": "Required. The project/location to create generator for. Format: `projects//locations/`", + "location": "path", + "pattern": "^projects/[^/]+/locations/[^/]+$", + "required": true, + "type": "string" + } + }, + "path": "v2beta1/{+parent}/generators", + "request": { + "$ref": "GoogleCloudDialogflowV2beta1Generator" + }, + "response": { + "$ref": "GoogleCloudDialogflowV2beta1Generator" + }, + "scopes": [ + "https://www.googleapis.com/auth/cloud-platform", + "https://www.googleapis.com/auth/dialogflow" + ] + }, + "delete": { + "description": "Deletes a generator.", + "flatPath": "v2beta1/projects/{projectsId}/locations/{locationsId}/generators/{generatorsId}", + "httpMethod": "DELETE", + "id": "dialogflow.projects.locations.generators.delete", + "parameterOrder": [ + "name" + ], + "parameters": { + "name": { + "description": "Required. The generator resource name to delete. Format: `projects//locations//generators/`", + "location": "path", + "pattern": "^projects/[^/]+/locations/[^/]+/generators/[^/]+$", + "required": true, + "type": "string" + } + }, + "path": "v2beta1/{+name}", + "response": { + "$ref": "GoogleProtobufEmpty" + }, + "scopes": [ + "https://www.googleapis.com/auth/cloud-platform", + "https://www.googleapis.com/auth/dialogflow" + ] + }, + "get": { + "description": "Retrieves a generator.", + "flatPath": "v2beta1/projects/{projectsId}/locations/{locationsId}/generators/{generatorsId}", + "httpMethod": "GET", + "id": "dialogflow.projects.locations.generators.get", + "parameterOrder": [ + "name" + ], + "parameters": { + "name": { + "description": "Required. The generator resource name to retrieve. Format: `projects//locations/`/generators/`", + "location": "path", + "pattern": "^projects/[^/]+/locations/[^/]+/generators/[^/]+$", + "required": true, + "type": "string" + } + }, + "path": "v2beta1/{+name}", + "response": { + "$ref": "GoogleCloudDialogflowV2beta1Generator" + }, + "scopes": [ + "https://www.googleapis.com/auth/cloud-platform", + "https://www.googleapis.com/auth/dialogflow" + ] + }, + "list": { + "description": "Lists generators.", + "flatPath": "v2beta1/projects/{projectsId}/locations/{locationsId}/generators", + "httpMethod": "GET", + "id": "dialogflow.projects.locations.generators.list", + "parameterOrder": [ + "parent" + ], + "parameters": { + "pageSize": { + "description": "Optional. Maximum number of conversation models to return in a single page. Default to 10.", + "format": "int32", + "location": "query", + "type": "integer" + }, + "pageToken": { + "description": "Optional. The next_page_token value returned from a previous list request.", + "location": "query", + "type": "string" + }, + "parent": { + "description": "Required. The project/location to list generators for. Format: `projects//locations/`", + "location": "path", + "pattern": "^projects/[^/]+/locations/[^/]+$", + "required": true, + "type": "string" + } + }, + "path": "v2beta1/{+parent}/generators", + "response": { + "$ref": "GoogleCloudDialogflowV2beta1ListGeneratorsResponse" + }, + "scopes": [ + "https://www.googleapis.com/auth/cloud-platform", + "https://www.googleapis.com/auth/dialogflow" + ] + }, + "patch": { + "description": "Updates a generator.", + "flatPath": "v2beta1/projects/{projectsId}/locations/{locationsId}/generators/{generatorsId}", + "httpMethod": "PATCH", + "id": "dialogflow.projects.locations.generators.patch", + "parameterOrder": [ + "name" + ], + "parameters": { + "name": { + "description": "Output only. Identifier. The resource name of the generator. Format: `projects//locations//generators/`", + "location": "path", + "pattern": "^projects/[^/]+/locations/[^/]+/generators/[^/]+$", + "required": true, + "type": "string" + }, + "updateMask": { + "description": "Optional. The list of fields to update.", + "format": "google-fieldmask", + "location": "query", + "type": "string" + } + }, + "path": "v2beta1/{+name}", + "request": { + "$ref": "GoogleCloudDialogflowV2beta1Generator" + }, + "response": { + "$ref": "GoogleCloudDialogflowV2beta1Generator" + }, + "scopes": [ + "https://www.googleapis.com/auth/cloud-platform", + "https://www.googleapis.com/auth/dialogflow" + ] + } + } + }, "knowledgeBases": { "methods": { "create": { @@ -7468,6 +7705,39 @@ } } }, + "statelessSuggestion": { + "methods": { + "generate": { + "description": "Generates and returns a suggestion for a conversation that does not have a resource created for it.", + "flatPath": "v2beta1/projects/{projectsId}/locations/{locationsId}/statelessSuggestion:generate", + "httpMethod": "POST", + "id": "dialogflow.projects.locations.statelessSuggestion.generate", + "parameterOrder": [ + "parent" + ], + "parameters": { + "parent": { + "description": "Required. The parent resource to charge for the Suggestion's generation. Format: `projects//locations/`.", + "location": "path", + "pattern": "^projects/[^/]+/locations/[^/]+$", + "required": true, + "type": "string" + } + }, + "path": "v2beta1/{+parent}/statelessSuggestion:generate", + "request": { + "$ref": "GoogleCloudDialogflowV2beta1GenerateStatelessSuggestionRequest" + }, + "response": { + "$ref": "GoogleCloudDialogflowV2beta1GenerateStatelessSuggestionResponse" + }, + "scopes": [ + "https://www.googleapis.com/auth/cloud-platform", + "https://www.googleapis.com/auth/dialogflow" + ] + } + } + }, "suggestions": { "methods": { "generateStatelessSummary": { @@ -7695,7 +7965,7 @@ } } }, - "revision": "20240507", + "revision": "20240523", "rootUrl": "https://dialogflow.googleapis.com/", "schemas": { "GoogleCloudDialogflowCxV3AdvancedSettings": { @@ -15608,6 +15878,20 @@ }, "type": "object" }, + "GoogleCloudDialogflowV2beta1ConversationContext": { + "description": "Context of the conversation, including transcripts.", + "id": "GoogleCloudDialogflowV2beta1ConversationContext", + "properties": { + "messageEntries": { + "description": "Optional. List of message transcripts in the conversation.", + "items": { + "$ref": "GoogleCloudDialogflowV2beta1MessageEntry" + }, + "type": "array" + } + }, + "type": "object" + }, "GoogleCloudDialogflowV2beta1ConversationEvent": { "description": "Represents a notification sent to Pub/Sub subscribers for conversation lifecycle events.", "id": "GoogleCloudDialogflowV2beta1ConversationEvent", @@ -16226,6 +16510,32 @@ }, "type": "object" }, + "GoogleCloudDialogflowV2beta1FewShotExample": { + "description": "Providing examples in the generator (i.e. building a few-shot generator) helps convey the desired format of the LLM response. NEXT_ID: 10", + "id": "GoogleCloudDialogflowV2beta1FewShotExample", + "properties": { + "conversationContext": { + "$ref": "GoogleCloudDialogflowV2beta1ConversationContext", + "description": "Optional. Conversation transcripts." + }, + "extraInfo": { + "additionalProperties": { + "type": "string" + }, + "description": "Optional. Key is the placeholder field name in input, value is the value of the placeholder. E.g. instruction contains \"@price\", and ingested data has \u003c\"price\", \"10\"\u003e", + "type": "object" + }, + "output": { + "$ref": "GoogleCloudDialogflowV2beta1GeneratorSuggestion", + "description": "Required. Example output of the model." + }, + "summarizationSectionList": { + "$ref": "GoogleCloudDialogflowV2beta1SummarizationSectionList", + "description": "Summarization sections." + } + }, + "type": "object" + }, "GoogleCloudDialogflowV2beta1Fulfillment": { "description": "By default, your agent responds to a matched intent with a static response. As an alternative, you can provide a more dynamic response by using fulfillment. When you enable fulfillment for an intent, Dialogflow responds to that intent by calling a service that you define. For example, if an end-user wants to schedule a haircut on Friday, your service can check your database and respond to the end-user with availability information for Friday. For more information, see the [fulfillment guide](https://cloud.google.com/dialogflow/docs/fulfillment-overview).", "id": "GoogleCloudDialogflowV2beta1Fulfillment", @@ -16342,6 +16652,53 @@ }, "type": "object" }, + "GoogleCloudDialogflowV2beta1GenerateStatelessSuggestionRequest": { + "description": "The request message for Conversations.GenerateStatelessSuggestion.", + "id": "GoogleCloudDialogflowV2beta1GenerateStatelessSuggestionRequest", + "properties": { + "conversationContext": { + "$ref": "GoogleCloudDialogflowV2beta1ConversationContext", + "description": "Optional. Context of the conversation, including transcripts." + }, + "generator": { + "$ref": "GoogleCloudDialogflowV2beta1Generator", + "description": "Uncreated generator. It should be a complete generator that includes all information about the generator." + }, + "generatorName": { + "description": "The resource name of the existing created generator. Format: `projects//locations//generators/`", + "type": "string" + }, + "triggerEvents": { + "description": "Optional. A list of trigger events. Generator will be triggered only if it's trigger event is included here.", + "items": { + "enum": [ + "TRIGGER_EVENT_UNSPECIFIED", + "END_OF_UTTERANCE", + "MANUAL_CALL" + ], + "enumDescriptions": [ + "Default value for TriggerEvent.", + "Triggers when each chat message or voice utterance ends.", + "Triggers on the conversation manually by API calls, such as Conversations.GenerateStatelessSuggestion and Conversations.GenerateSuggestions." + ], + "type": "string" + }, + "type": "array" + } + }, + "type": "object" + }, + "GoogleCloudDialogflowV2beta1GenerateStatelessSuggestionResponse": { + "description": "The response message for Conversations.GenerateStatelessSuggestion.", + "id": "GoogleCloudDialogflowV2beta1GenerateStatelessSuggestionResponse", + "properties": { + "generatorSuggestion": { + "$ref": "GoogleCloudDialogflowV2beta1GeneratorSuggestion", + "description": "Required. Generated suggestion for a conversation." + } + }, + "type": "object" + }, "GoogleCloudDialogflowV2beta1GenerateStatelessSummaryRequest": { "description": "The request message for Conversations.GenerateStatelessSummary.", "id": "GoogleCloudDialogflowV2beta1GenerateStatelessSummaryRequest", @@ -16422,6 +16779,67 @@ }, "type": "object" }, + "GoogleCloudDialogflowV2beta1Generator": { + "description": "LLM generator.", + "id": "GoogleCloudDialogflowV2beta1Generator", + "properties": { + "createTime": { + "description": "Output only. Creation time of this generator.", + "format": "google-datetime", + "readOnly": true, + "type": "string" + }, + "description": { + "description": "Optional. Human readable description of the generator.", + "type": "string" + }, + "inferenceParameter": { + "$ref": "GoogleCloudDialogflowV2beta1InferenceParameter", + "description": "Optional. Inference parameters for this generator." + }, + "name": { + "description": "Output only. Identifier. The resource name of the generator. Format: `projects//locations//generators/`", + "readOnly": true, + "type": "string" + }, + "summarizationContext": { + "$ref": "GoogleCloudDialogflowV2beta1SummarizationContext", + "description": "Input of prebuilt Summarization feature." + }, + "triggerEvent": { + "description": "Optional. The trigger event of the generator. It defines when the generator is triggered in a conversation.", + "enum": [ + "TRIGGER_EVENT_UNSPECIFIED", + "END_OF_UTTERANCE", + "MANUAL_CALL" + ], + "enumDescriptions": [ + "Default value for TriggerEvent.", + "Triggers when each chat message or voice utterance ends.", + "Triggers on the conversation manually by API calls, such as Conversations.GenerateStatelessSuggestion and Conversations.GenerateSuggestions." + ], + "type": "string" + }, + "updateTime": { + "description": "Output only. Update time of this generator.", + "format": "google-datetime", + "readOnly": true, + "type": "string" + } + }, + "type": "object" + }, + "GoogleCloudDialogflowV2beta1GeneratorSuggestion": { + "description": "Suggestion generated using a Generator.", + "id": "GoogleCloudDialogflowV2beta1GeneratorSuggestion", + "properties": { + "summarySuggestion": { + "$ref": "GoogleCloudDialogflowV2beta1SummarySuggestion", + "description": "Optional. Suggested summary." + } + }, + "type": "object" + }, "GoogleCloudDialogflowV2beta1HumanAgentAssistantConfig": { "description": "Defines the Human Agent Assistant to connect to a conversation.", "id": "GoogleCloudDialogflowV2beta1HumanAgentAssistantConfig", @@ -16498,6 +16916,13 @@ }, "type": "array" }, + "generators": { + "description": "Optional. List of various generator resource names used in the conversation profile.", + "items": { + "type": "string" + }, + "type": "array" + }, "groupSuggestionResponses": { "description": "If `group_suggestion_responses` is false, and there are multiple `feature_configs` in `event based suggestion` or StreamingAnalyzeContent, we will try to deliver suggestions to customers as soon as we get new suggestion. Different type of suggestions based on the same context will be in separate Pub/Sub event or `StreamingAnalyzeContentResponse`. If `group_suggestion_responses` set to true. All the suggestions to the same participant based on the same context will be grouped into a single Pub/Sub event or StreamingAnalyzeContentResponse.", "type": "boolean" @@ -16729,7 +17154,7 @@ "properties": { "livePersonConfig": { "$ref": "GoogleCloudDialogflowV2beta1HumanAgentHandoffConfigLivePersonConfig", - "description": "Uses LivePerson (https://www.liveperson.com)." + "description": "Uses [LivePerson](https://www.liveperson.com)." }, "salesforceLiveAgentConfig": { "$ref": "GoogleCloudDialogflowV2beta1HumanAgentHandoffConfigSalesforceLiveAgentConfig", @@ -16739,7 +17164,7 @@ "type": "object" }, "GoogleCloudDialogflowV2beta1HumanAgentHandoffConfigLivePersonConfig": { - "description": "Configuration specific to LivePerson (https://www.liveperson.com).", + "description": "Configuration specific to [LivePerson](https://www.liveperson.com).", "id": "GoogleCloudDialogflowV2beta1HumanAgentHandoffConfigLivePersonConfig", "properties": { "accountNumber": { @@ -16862,6 +17287,33 @@ }, "type": "object" }, + "GoogleCloudDialogflowV2beta1InferenceParameter": { + "description": "The parameters of inference.", + "id": "GoogleCloudDialogflowV2beta1InferenceParameter", + "properties": { + "maxOutputTokens": { + "description": "Optional. Maximum number of the output tokens for the generator.", + "format": "int32", + "type": "integer" + }, + "temperature": { + "description": "Optional. Controls the randomness of LLM predictions. Low temperature = less random. High temperature = more random. If unset (or 0), uses a default value of 0.", + "format": "double", + "type": "number" + }, + "topK": { + "description": "Optional. Top-k changes how the model selects tokens for output. A top-k of 1 means the selected token is the most probable among all tokens in the model's vocabulary (also called greedy decoding), while a top-k of 3 means that the next token is selected from among the 3 most probable tokens (using temperature). For each token selection step, the top K tokens with the highest probabilities are sampled. Then tokens are further filtered based on topP with the final token selected using temperature sampling. Specify a lower value for less random responses and a higher value for more random responses. Acceptable value is [1, 40], default to 40.", + "format": "int32", + "type": "integer" + }, + "topP": { + "description": "Optional. Top-p changes how the model selects tokens for output. Tokens are selected from most K (see topK parameter) probable to least until the sum of their probabilities equals the top-p value. For example, if tokens A, B, and C have a probability of 0.3, 0.2, and 0.1 and the top-p value is 0.5, then the model will select either A or B as the next token (using temperature) and doesn't consider C. The default top-p value is 0.95. Specify a lower value for less random responses and a higher value for more random responses. Acceptable value is [0.0, 1.0], default to 0.95.", + "format": "double", + "type": "number" + } + }, + "type": "object" + }, "GoogleCloudDialogflowV2beta1InputAudioConfig": { "description": "Instructs the speech recognizer on how to process the audio content.", "id": "GoogleCloudDialogflowV2beta1InputAudioConfig", @@ -16894,6 +17346,11 @@ "$ref": "GoogleCloudDialogflowV2beta1BargeInConfig", "description": "Configuration of barge-in behavior during the streaming of input audio." }, + "defaultNoSpeechTimeout": { + "description": "If set, use this no-speech timeout when the agent does not provide a no-speech timeout itself.", + "format": "google-duration", + "type": "string" + }, "disableNoSpeechRecognizedEvent": { "description": "Only used in Participants.AnalyzeContent and Participants.StreamingAnalyzeContent. If `false` and recognition doesn't return any result, trigger `NO_SPEECH_RECOGNIZED` event to Dialogflow agent.", "type": "boolean" @@ -18452,6 +18909,24 @@ }, "type": "object" }, + "GoogleCloudDialogflowV2beta1ListGeneratorsResponse": { + "description": "Response of ListGenerators.", + "id": "GoogleCloudDialogflowV2beta1ListGeneratorsResponse", + "properties": { + "generators": { + "description": "List of generators retrieved.", + "items": { + "$ref": "GoogleCloudDialogflowV2beta1Generator" + }, + "type": "array" + }, + "nextPageToken": { + "description": "Token to retrieve the next page of results, or empty if there are no more results in the list.", + "type": "string" + } + }, + "type": "object" + }, "GoogleCloudDialogflowV2beta1ListIntentsResponse": { "description": "The response message for Intents.ListIntents.", "id": "GoogleCloudDialogflowV2beta1ListIntentsResponse", @@ -18670,6 +19145,42 @@ }, "type": "object" }, + "GoogleCloudDialogflowV2beta1MessageEntry": { + "description": "Represents a message entry of a conversation.", + "id": "GoogleCloudDialogflowV2beta1MessageEntry", + "properties": { + "createTime": { + "description": "Optional. Create time of the message entry.", + "format": "google-datetime", + "type": "string" + }, + "languageCode": { + "description": "Optional. The language of the text. See [Language Support](https://cloud.google.com/dialogflow/docs/reference/language) for a list of the currently supported language codes.", + "type": "string" + }, + "role": { + "description": "Optional. Participant role of the message.", + "enum": [ + "ROLE_UNSPECIFIED", + "HUMAN_AGENT", + "AUTOMATED_AGENT", + "END_USER" + ], + "enumDescriptions": [ + "Participant role not set.", + "Participant is a human agent.", + "Participant is an automated agent, such as a Dialogflow agent.", + "Participant is an end user that has called or chatted with Dialogflow services." + ], + "type": "string" + }, + "text": { + "description": "Optional. Transcript content of the message.", + "type": "string" + } + }, + "type": "object" + }, "GoogleCloudDialogflowV2beta1NotificationConfig": { "description": "Defines notification behavior.", "id": "GoogleCloudDialogflowV2beta1NotificationConfig", @@ -19915,6 +20426,117 @@ }, "type": "object" }, + "GoogleCloudDialogflowV2beta1SummarizationContext": { + "description": "Summarization context that customer can configure.", + "id": "GoogleCloudDialogflowV2beta1SummarizationContext", + "properties": { + "fewShotExamples": { + "description": "Optional. List of few shot examples.", + "items": { + "$ref": "GoogleCloudDialogflowV2beta1FewShotExample" + }, + "type": "array" + }, + "outputLanguageCode": { + "description": "Optional. The target language of the generated summary. The language code for conversation will be used if this field is empty. Supported 2.0 and later versions.", + "type": "string" + }, + "summarizationSections": { + "description": "Optional. List of sections. Note it contains both predefined section sand customer defined sections.", + "items": { + "$ref": "GoogleCloudDialogflowV2beta1SummarizationSection" + }, + "type": "array" + }, + "version": { + "description": "Optional. Version of the feature. If not set, default to latest version. Current candidates are [\"1.0\"].", + "type": "string" + } + }, + "type": "object" + }, + "GoogleCloudDialogflowV2beta1SummarizationSection": { + "description": "Represents the section of summarization.", + "id": "GoogleCloudDialogflowV2beta1SummarizationSection", + "properties": { + "definition": { + "description": "Optional. Definition of the section, for example, \"what the customer needs help with or has question about.\"", + "type": "string" + }, + "key": { + "description": "Optional. Name of the section, for example, \"situation\".", + "type": "string" + }, + "type": { + "description": "Optional. Type of the summarization section.", + "enum": [ + "TYPE_UNSPECIFIED", + "SITUATION", + "ACTION", + "RESOLUTION", + "REASON_FOR_CANCELLATION", + "CUSTOMER_SATISFACTION", + "ENTITIES", + "CUSTOMER_DEFINED" + ], + "enumDescriptions": [ + "Undefined section type, does not return anything.", + "What the customer needs help with or has question about. Section name: \"situation\".", + "What the agent does to help the customer. Section name: \"action\".", + "Result of the customer service. A single word describing the result of the conversation. Section name: \"resolution\".", + "Reason for cancellation if the customer requests for a cancellation. \"N/A\" otherwise. Section name: \"reason_for_cancellation\".", + "\"Unsatisfied\" or \"Satisfied\" depending on the customer's feelings at the end of the conversation. Section name: \"customer_satisfaction\".", + "Key entities extracted from the conversation, such as ticket number, order number, dollar amount, etc. Section names are prefixed by \"entities/\".", + "Customer defined sections." + ], + "type": "string" + } + }, + "type": "object" + }, + "GoogleCloudDialogflowV2beta1SummarizationSectionList": { + "description": "List of summarization sections.", + "id": "GoogleCloudDialogflowV2beta1SummarizationSectionList", + "properties": { + "summarizationSections": { + "description": "Optional. Summarization sections.", + "items": { + "$ref": "GoogleCloudDialogflowV2beta1SummarizationSection" + }, + "type": "array" + } + }, + "type": "object" + }, + "GoogleCloudDialogflowV2beta1SummarySuggestion": { + "description": "Suggested summary of the conversation.", + "id": "GoogleCloudDialogflowV2beta1SummarySuggestion", + "properties": { + "summarySections": { + "description": "Required. All the parts of generated summary.", + "items": { + "$ref": "GoogleCloudDialogflowV2beta1SummarySuggestionSummarySection" + }, + "type": "array" + } + }, + "type": "object" + }, + "GoogleCloudDialogflowV2beta1SummarySuggestionSummarySection": { + "description": "A component of the generated summary.", + "id": "GoogleCloudDialogflowV2beta1SummarySuggestionSummarySection", + "properties": { + "section": { + "description": "Required. Name of the section.", + "type": "string" + }, + "summary": { + "description": "Required. Summary text for the section.", + "type": "string" + } + }, + "type": "object" + }, "GoogleCloudDialogflowV2beta1SynthesizeSpeechConfig": { "description": "Configuration of how speech should be synthesized.", "id": "GoogleCloudDialogflowV2beta1SynthesizeSpeechConfig", diff --git a/dialogflow/v2beta1/dialogflow-gen.go b/dialogflow/v2beta1/dialogflow-gen.go index 67a27f26670..3f72a3fb11a 100644 --- a/dialogflow/v2beta1/dialogflow-gen.go +++ b/dialogflow/v2beta1/dialogflow-gen.go @@ -171,6 +171,7 @@ func NewProjectsService(s *Service) *ProjectsService { rs.AnswerRecords = NewProjectsAnswerRecordsService(s) rs.ConversationProfiles = NewProjectsConversationProfilesService(s) rs.Conversations = NewProjectsConversationsService(s) + rs.Generators = NewProjectsGeneratorsService(s) rs.KnowledgeBases = NewProjectsKnowledgeBasesService(s) rs.Locations = NewProjectsLocationsService(s) rs.Operations = NewProjectsOperationsService(s) @@ -189,6 +190,8 @@ type ProjectsService struct { Conversations *ProjectsConversationsService + Generators *ProjectsGeneratorsService + KnowledgeBases *ProjectsKnowledgeBasesService Locations *ProjectsLocationsService @@ -462,6 +465,15 @@ type ProjectsConversationsSuggestionsService struct { s *Service } +func NewProjectsGeneratorsService(s *Service) *ProjectsGeneratorsService { + rs := &ProjectsGeneratorsService{s: s} + return rs +} + +type ProjectsGeneratorsService struct { + s *Service +} + func NewProjectsKnowledgeBasesService(s *Service) *ProjectsKnowledgeBasesService { rs := &ProjectsKnowledgeBasesService{s: s} rs.Documents = NewProjectsKnowledgeBasesDocumentsService(s) @@ -489,8 +501,10 @@ func NewProjectsLocationsService(s *Service) *ProjectsLocationsService { rs.AnswerRecords = NewProjectsLocationsAnswerRecordsService(s) rs.ConversationProfiles = NewProjectsLocationsConversationProfilesService(s) rs.Conversations = NewProjectsLocationsConversationsService(s) + rs.Generators = NewProjectsLocationsGeneratorsService(s) rs.KnowledgeBases = NewProjectsLocationsKnowledgeBasesService(s) rs.Operations = NewProjectsLocationsOperationsService(s) + rs.StatelessSuggestion = NewProjectsLocationsStatelessSuggestionService(s) rs.Suggestions = NewProjectsLocationsSuggestionsService(s) return rs } @@ -506,10 +520,14 @@ type ProjectsLocationsService struct { Conversations *ProjectsLocationsConversationsService + Generators *ProjectsLocationsGeneratorsService + KnowledgeBases *ProjectsLocationsKnowledgeBasesService Operations *ProjectsLocationsOperationsService + StatelessSuggestion *ProjectsLocationsStatelessSuggestionService + Suggestions *ProjectsLocationsSuggestionsService } @@ -753,6 +771,15 @@ type ProjectsLocationsConversationsSuggestionsService struct { s *Service } +func NewProjectsLocationsGeneratorsService(s *Service) *ProjectsLocationsGeneratorsService { + rs := &ProjectsLocationsGeneratorsService{s: s} + return rs +} + +type ProjectsLocationsGeneratorsService struct { + s *Service +} + func NewProjectsLocationsKnowledgeBasesService(s *Service) *ProjectsLocationsKnowledgeBasesService { rs := &ProjectsLocationsKnowledgeBasesService{s: s} rs.Documents = NewProjectsLocationsKnowledgeBasesDocumentsService(s) @@ -783,6 +810,15 @@ type ProjectsLocationsOperationsService struct { s *Service } +func NewProjectsLocationsStatelessSuggestionService(s *Service) *ProjectsLocationsStatelessSuggestionService { + rs := &ProjectsLocationsStatelessSuggestionService{s: s} + return rs +} + +type ProjectsLocationsStatelessSuggestionService struct { + s *Service +} + func NewProjectsLocationsSuggestionsService(s *Service) *ProjectsLocationsSuggestionsService { rs := &ProjectsLocationsSuggestionsService{s: s} return rs @@ -11866,6 +11902,29 @@ func (s *GoogleCloudDialogflowV2beta1Conversation) MarshalJSON() ([]byte, error) return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) } +// GoogleCloudDialogflowV2beta1ConversationContext: Context of the +// conversation, including transcripts. +type GoogleCloudDialogflowV2beta1ConversationContext struct { + // MessageEntries: Optional. List of message transcripts in the conversation. + MessageEntries []*GoogleCloudDialogflowV2beta1MessageEntry `json:"messageEntries,omitempty"` + // ForceSendFields is a list of field names (e.g. "MessageEntries") to + // unconditionally include in API requests. By default, fields with empty or + // default values are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. + ForceSendFields []string `json:"-"` + // NullFields is a list of field names (e.g. "MessageEntries") to include in + // API requests with the JSON null value. By default, fields with empty values + // are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. + NullFields []string `json:"-"` +} + +func (s *GoogleCloudDialogflowV2beta1ConversationContext) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDialogflowV2beta1ConversationContext + return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) +} + // GoogleCloudDialogflowV2beta1ConversationEvent: Represents a notification // sent to Pub/Sub subscribers for conversation lifecycle events. type GoogleCloudDialogflowV2beta1ConversationEvent struct { @@ -12728,6 +12787,38 @@ func (s *GoogleCloudDialogflowV2beta1FaqAnswer) UnmarshalJSON(data []byte) error return nil } +// GoogleCloudDialogflowV2beta1FewShotExample: Providing examples in the +// generator (i.e. building a few-shot generator) helps convey the desired +// format of the LLM response. NEXT_ID: 10 +type GoogleCloudDialogflowV2beta1FewShotExample struct { + // ConversationContext: Optional. Conversation transcripts. + ConversationContext *GoogleCloudDialogflowV2beta1ConversationContext `json:"conversationContext,omitempty"` + // ExtraInfo: Optional. Key is the placeholder field name in input, value is + // the value of the placeholder. E.g. instruction contains "@price", and + // ingested data has <"price", "10"> + ExtraInfo map[string]string `json:"extraInfo,omitempty"` + // Output: Required. Example output of the model. + Output *GoogleCloudDialogflowV2beta1GeneratorSuggestion `json:"output,omitempty"` + // SummarizationSectionList: Summarization sections. + SummarizationSectionList *GoogleCloudDialogflowV2beta1SummarizationSectionList `json:"summarizationSectionList,omitempty"` + // ForceSendFields is a list of field names (e.g. "ConversationContext") to + // unconditionally include in API requests. By default, fields with empty or + // default values are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. + ForceSendFields []string `json:"-"` + // NullFields is a list of field names (e.g. "ConversationContext") to include + // in API requests with the JSON null value. By default, fields with empty + // values are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. + NullFields []string `json:"-"` +} + +func (s *GoogleCloudDialogflowV2beta1FewShotExample) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDialogflowV2beta1FewShotExample + return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) +} + // GoogleCloudDialogflowV2beta1Fulfillment: By default, your agent responds to // a matched intent with a static response. As an alternative, you can provide // a more dynamic response by using fulfillment. When you enable fulfillment @@ -12916,6 +13007,73 @@ func (s *GoogleCloudDialogflowV2beta1GcsSources) MarshalJSON() ([]byte, error) { return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) } +// GoogleCloudDialogflowV2beta1GenerateStatelessSuggestionRequest: The request +// message for Conversations.GenerateStatelessSuggestion. +type GoogleCloudDialogflowV2beta1GenerateStatelessSuggestionRequest struct { + // ConversationContext: Optional. Context of the conversation, including + // transcripts. + ConversationContext *GoogleCloudDialogflowV2beta1ConversationContext `json:"conversationContext,omitempty"` + // Generator: Uncreated generator. It should be a complete generator that + // includes all information about the generator. + Generator *GoogleCloudDialogflowV2beta1Generator `json:"generator,omitempty"` + // GeneratorName: The resource name of the existing created generator. Format: + // `projects//locations//generators/` + GeneratorName string `json:"generatorName,omitempty"` + // TriggerEvents: Optional. A list of trigger events. Generator will be + // triggered only if it's trigger event is included here. + // + // Possible values: + // "TRIGGER_EVENT_UNSPECIFIED" - Default value for TriggerEvent. + // "END_OF_UTTERANCE" - Triggers when each chat message or voice utterance + // ends. + // "MANUAL_CALL" - Triggers on the conversation manually by API calls, such + // as Conversations.GenerateStatelessSuggestion and + // Conversations.GenerateSuggestions. + TriggerEvents []string `json:"triggerEvents,omitempty"` + // ForceSendFields is a list of field names (e.g. "ConversationContext") to + // unconditionally include in API requests. By default, fields with empty or + // default values are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. + ForceSendFields []string `json:"-"` + // NullFields is a list of field names (e.g. "ConversationContext") to include + // in API requests with the JSON null value. By default, fields with empty + // values are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. + NullFields []string `json:"-"` +} + +func (s *GoogleCloudDialogflowV2beta1GenerateStatelessSuggestionRequest) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDialogflowV2beta1GenerateStatelessSuggestionRequest + return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) +} + +// GoogleCloudDialogflowV2beta1GenerateStatelessSuggestionResponse: The +// response message for Conversations.GenerateStatelessSuggestion. +type GoogleCloudDialogflowV2beta1GenerateStatelessSuggestionResponse struct { + // GeneratorSuggestion: Required. Generated suggestion for a conversation. + GeneratorSuggestion *GoogleCloudDialogflowV2beta1GeneratorSuggestion `json:"generatorSuggestion,omitempty"` + + // ServerResponse contains the HTTP response code and headers from the server. + googleapi.ServerResponse `json:"-"` + // ForceSendFields is a list of field names (e.g. "GeneratorSuggestion") to + // unconditionally include in API requests. By default, fields with empty or + // default values are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. + ForceSendFields []string `json:"-"` + // NullFields is a list of field names (e.g. "GeneratorSuggestion") to include + // in API requests with the JSON null value. By default, fields with empty + // values are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. + NullFields []string `json:"-"` +} + +func (s *GoogleCloudDialogflowV2beta1GenerateStatelessSuggestionResponse) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDialogflowV2beta1GenerateStatelessSuggestionResponse + return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) +} + // GoogleCloudDialogflowV2beta1GenerateStatelessSummaryRequest: The request // message for Conversations.GenerateStatelessSummary. type GoogleCloudDialogflowV2beta1GenerateStatelessSummaryRequest struct { @@ -13046,6 +13204,76 @@ func (s *GoogleCloudDialogflowV2beta1GenerateStatelessSummaryResponseSummary) Ma return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) } +// GoogleCloudDialogflowV2beta1Generator: LLM generator. +type GoogleCloudDialogflowV2beta1Generator struct { + // CreateTime: Output only. Creation time of this generator. + CreateTime string `json:"createTime,omitempty"` + // Description: Optional. Human readable description of the generator. + Description string `json:"description,omitempty"` + // InferenceParameter: Optional. Inference parameters for this generator. + InferenceParameter *GoogleCloudDialogflowV2beta1InferenceParameter `json:"inferenceParameter,omitempty"` + // Name: Output only. Identifier. The resource name of the generator. Format: + // `projects//locations//generators/` + Name string `json:"name,omitempty"` + // SummarizationContext: Input of prebuilt Summarization feature. + SummarizationContext *GoogleCloudDialogflowV2beta1SummarizationContext `json:"summarizationContext,omitempty"` + // TriggerEvent: Optional. The trigger event of the generator. It defines when + // the generator is triggered in a conversation. + // + // Possible values: + // "TRIGGER_EVENT_UNSPECIFIED" - Default value for TriggerEvent. + // "END_OF_UTTERANCE" - Triggers when each chat message or voice utterance + // ends. + // "MANUAL_CALL" - Triggers on the conversation manually by API calls, such + // as Conversations.GenerateStatelessSuggestion and + // Conversations.GenerateSuggestions. + TriggerEvent string `json:"triggerEvent,omitempty"` + // UpdateTime: Output only. Update time of this generator. + UpdateTime string `json:"updateTime,omitempty"` + + // ServerResponse contains the HTTP response code and headers from the server. + googleapi.ServerResponse `json:"-"` + // ForceSendFields is a list of field names (e.g. "CreateTime") to + // unconditionally include in API requests. By default, fields with empty or + // default values are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. + ForceSendFields []string `json:"-"` + // NullFields is a list of field names (e.g. "CreateTime") to include in API + // requests with the JSON null value. By default, fields with empty values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. + NullFields []string `json:"-"` +} + +func (s *GoogleCloudDialogflowV2beta1Generator) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDialogflowV2beta1Generator + return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) +} + +// GoogleCloudDialogflowV2beta1GeneratorSuggestion: Suggestion generated using +// a Generator. +type GoogleCloudDialogflowV2beta1GeneratorSuggestion struct { + // SummarySuggestion: Optional. Suggested summary. + SummarySuggestion *GoogleCloudDialogflowV2beta1SummarySuggestion `json:"summarySuggestion,omitempty"` + // ForceSendFields is a list of field names (e.g. "SummarySuggestion") to + // unconditionally include in API requests. By default, fields with empty or + // default values are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. + ForceSendFields []string `json:"-"` + // NullFields is a list of field names (e.g. "SummarySuggestion") to include in + // API requests with the JSON null value. By default, fields with empty values + // are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. + NullFields []string `json:"-"` +} + +func (s *GoogleCloudDialogflowV2beta1GeneratorSuggestion) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDialogflowV2beta1GeneratorSuggestion + return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) +} + // GoogleCloudDialogflowV2beta1HumanAgentAssistantConfig: Defines the Human // Agent Assistant to connect to a conversation. type GoogleCloudDialogflowV2beta1HumanAgentAssistantConfig struct { @@ -13183,6 +13411,9 @@ type GoogleCloudDialogflowV2beta1HumanAgentAssistantConfigSuggestionConfig struc // FeatureConfigs: Configuration of different suggestion features. One feature // can have only one config. FeatureConfigs []*GoogleCloudDialogflowV2beta1HumanAgentAssistantConfigSuggestionFeatureConfig `json:"featureConfigs,omitempty"` + // Generators: Optional. List of various generator resource names used in the + // conversation profile. + Generators []string `json:"generators,omitempty"` // GroupSuggestionResponses: If `group_suggestion_responses` is false, and // there are multiple `feature_configs` in `event based suggestion` or // StreamingAnalyzeContent, we will try to deliver suggestions to customers as @@ -13782,6 +14013,68 @@ func (s *GoogleCloudDialogflowV2beta1ImportDocumentsResponse) MarshalJSON() ([]b return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) } +// GoogleCloudDialogflowV2beta1InferenceParameter: The parameters of inference. +type GoogleCloudDialogflowV2beta1InferenceParameter struct { + // MaxOutputTokens: Optional. Maximum number of the output tokens for the + // generator. + MaxOutputTokens int64 `json:"maxOutputTokens,omitempty"` + // Temperature: Optional. Controls the randomness of LLM predictions. Low + // temperature = less random. High temperature = more random. If unset (or 0), + // uses a default value of 0. + Temperature float64 `json:"temperature,omitempty"` + // TopK: Optional. Top-k changes how the model selects tokens for output. A + // top-k of 1 means the selected token is the most probable among all tokens in + // the model's vocabulary (also called greedy decoding), while a top-k of 3 + // means that the next token is selected from among the 3 most probable tokens + // (using temperature). For each token selection step, the top K tokens with + // the highest probabilities are sampled. Then tokens are further filtered + // based on topP with the final token selected using temperature sampling. + // Specify a lower value for less random responses and a higher value for more + // random responses. Acceptable value is [1, 40], default to 40. + TopK int64 `json:"topK,omitempty"` + // TopP: Optional. Top-p changes how the model selects tokens for output. + // Tokens are selected from most K (see topK parameter) probable to least until + // the sum of their probabilities equals the top-p value. For example, if + // tokens A, B, and C have a probability of 0.3, 0.2, and 0.1 and the top-p + // value is 0.5, then the model will select either A or B as the next token + // (using temperature) and doesn't consider C. The default top-p value is 0.95. + // Specify a lower value for less random responses and a higher value for more + // random responses. Acceptable value is [0.0, 1.0], default to 0.95. + TopP float64 `json:"topP,omitempty"` + // ForceSendFields is a list of field names (e.g. "MaxOutputTokens") to + // unconditionally include in API requests. By default, fields with empty or + // default values are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. + ForceSendFields []string `json:"-"` + // NullFields is a list of field names (e.g. "MaxOutputTokens") to include in + // API requests with the JSON null value. By default, fields with empty values + // are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. + NullFields []string `json:"-"` +} + +func (s *GoogleCloudDialogflowV2beta1InferenceParameter) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDialogflowV2beta1InferenceParameter + return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) +} + +func (s *GoogleCloudDialogflowV2beta1InferenceParameter) UnmarshalJSON(data []byte) error { + type NoMethod GoogleCloudDialogflowV2beta1InferenceParameter + var s1 struct { + Temperature gensupport.JSONFloat64 `json:"temperature"` + TopP gensupport.JSONFloat64 `json:"topP"` + *NoMethod + } + s1.NoMethod = (*NoMethod)(s) + if err := json.Unmarshal(data, &s1); err != nil { + return err + } + s.Temperature = float64(s1.Temperature) + s.TopP = float64(s1.TopP) + return nil +} + // GoogleCloudDialogflowV2beta1InputAudioConfig: Instructs the speech // recognizer on how to process the audio content. type GoogleCloudDialogflowV2beta1InputAudioConfig struct { @@ -13822,6 +14115,9 @@ type GoogleCloudDialogflowV2beta1InputAudioConfig struct { // BargeInConfig: Configuration of barge-in behavior during the streaming of // input audio. BargeInConfig *GoogleCloudDialogflowV2beta1BargeInConfig `json:"bargeInConfig,omitempty"` + // DefaultNoSpeechTimeout: If set, use this no-speech timeout when the agent + // does not provide a no-speech timeout itself. + DefaultNoSpeechTimeout string `json:"defaultNoSpeechTimeout,omitempty"` // DisableNoSpeechRecognizedEvent: Only used in Participants.AnalyzeContent and // Participants.StreamingAnalyzeContent. If `false` and recognition doesn't // return any result, trigger `NO_SPEECH_RECOGNIZED` event to Dialogflow agent. @@ -15927,6 +16223,35 @@ func (s *GoogleCloudDialogflowV2beta1ListEnvironmentsResponse) MarshalJSON() ([] return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) } +// GoogleCloudDialogflowV2beta1ListGeneratorsResponse: Response of +// ListGenerators. +type GoogleCloudDialogflowV2beta1ListGeneratorsResponse struct { + // Generators: List of generators retrieved. + Generators []*GoogleCloudDialogflowV2beta1Generator `json:"generators,omitempty"` + // NextPageToken: Token to retrieve the next page of results, or empty if there + // are no more results in the list. + NextPageToken string `json:"nextPageToken,omitempty"` + + // ServerResponse contains the HTTP response code and headers from the server. + googleapi.ServerResponse `json:"-"` + // ForceSendFields is a list of field names (e.g. "Generators") to + // unconditionally include in API requests. By default, fields with empty or + // default values are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. + ForceSendFields []string `json:"-"` + // NullFields is a list of field names (e.g. "Generators") to include in API + // requests with the JSON null value. By default, fields with empty values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. + NullFields []string `json:"-"` +} + +func (s *GoogleCloudDialogflowV2beta1ListGeneratorsResponse) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDialogflowV2beta1ListGeneratorsResponse + return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) +} + // GoogleCloudDialogflowV2beta1ListIntentsResponse: The response message for // Intents.ListIntents. type GoogleCloudDialogflowV2beta1ListIntentsResponse struct { @@ -16244,6 +16569,45 @@ func (s *GoogleCloudDialogflowV2beta1MessageAnnotation) MarshalJSON() ([]byte, e return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) } +// GoogleCloudDialogflowV2beta1MessageEntry: Represents a message entry of a +// conversation. +type GoogleCloudDialogflowV2beta1MessageEntry struct { + // CreateTime: Optional. Create time of the message entry. + CreateTime string `json:"createTime,omitempty"` + // LanguageCode: Optional. The language of the text. See Language Support + // (https://cloud.google.com/dialogflow/docs/reference/language) for a list of + // the currently supported language codes. + LanguageCode string `json:"languageCode,omitempty"` + // Role: Optional. Participant role of the message. + // + // Possible values: + // "ROLE_UNSPECIFIED" - Participant role not set. + // "HUMAN_AGENT" - Participant is a human agent. + // "AUTOMATED_AGENT" - Participant is an automated agent, such as a + // Dialogflow agent. + // "END_USER" - Participant is an end user that has called or chatted with + // Dialogflow services. + Role string `json:"role,omitempty"` + // Text: Optional. Transcript content of the message. + Text string `json:"text,omitempty"` + // ForceSendFields is a list of field names (e.g. "CreateTime") to + // unconditionally include in API requests. By default, fields with empty or + // default values are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. + ForceSendFields []string `json:"-"` + // NullFields is a list of field names (e.g. "CreateTime") to include in API + // requests with the JSON null value. By default, fields with empty values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. + NullFields []string `json:"-"` +} + +func (s *GoogleCloudDialogflowV2beta1MessageEntry) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDialogflowV2beta1MessageEntry + return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) +} + // GoogleCloudDialogflowV2beta1NotificationConfig: Defines notification // behavior. type GoogleCloudDialogflowV2beta1NotificationConfig struct { @@ -18086,6 +18450,157 @@ func (s *GoogleCloudDialogflowV2beta1SuggestionResult) MarshalJSON() ([]byte, er return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) } +// GoogleCloudDialogflowV2beta1SummarizationContext: Summarization context that +// customer can configure. +type GoogleCloudDialogflowV2beta1SummarizationContext struct { + // FewShotExamples: Optional. List of few shot examples. + FewShotExamples []*GoogleCloudDialogflowV2beta1FewShotExample `json:"fewShotExamples,omitempty"` + // OutputLanguageCode: Optional. The target language of the generated summary. + // The language code for conversation will be used if this field is empty. + // Supported 2.0 and later versions. + OutputLanguageCode string `json:"outputLanguageCode,omitempty"` + // SummarizationSections: Optional. List of sections. Note it contains both + // predefined section sand customer defined sections. + SummarizationSections []*GoogleCloudDialogflowV2beta1SummarizationSection `json:"summarizationSections,omitempty"` + // Version: Optional. Version of the feature. If not set, default to latest + // version. Current candidates are ["1.0"]. + Version string `json:"version,omitempty"` + // ForceSendFields is a list of field names (e.g. "FewShotExamples") to + // unconditionally include in API requests. By default, fields with empty or + // default values are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. + ForceSendFields []string `json:"-"` + // NullFields is a list of field names (e.g. "FewShotExamples") to include in + // API requests with the JSON null value. By default, fields with empty values + // are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. + NullFields []string `json:"-"` +} + +func (s *GoogleCloudDialogflowV2beta1SummarizationContext) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDialogflowV2beta1SummarizationContext + return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) +} + +// GoogleCloudDialogflowV2beta1SummarizationSection: Represents the section of +// summarization. +type GoogleCloudDialogflowV2beta1SummarizationSection struct { + // Definition: Optional. Definition of the section, for example, "what the + // customer needs help with or has question about." + Definition string `json:"definition,omitempty"` + // Key: Optional. Name of the section, for example, "situation". + Key string `json:"key,omitempty"` + // Type: Optional. Type of the summarization section. + // + // Possible values: + // "TYPE_UNSPECIFIED" - Undefined section type, does not return anything. + // "SITUATION" - What the customer needs help with or has question about. + // Section name: "situation". + // "ACTION" - What the agent does to help the customer. Section name: + // "action". + // "RESOLUTION" - Result of the customer service. A single word describing + // the result of the conversation. Section name: "resolution". + // "REASON_FOR_CANCELLATION" - Reason for cancellation if the customer + // requests for a cancellation. "N/A" otherwise. Section name: + // "reason_for_cancellation". + // "CUSTOMER_SATISFACTION" - "Unsatisfied" or "Satisfied" depending on the + // customer's feelings at the end of the conversation. Section name: + // "customer_satisfaction". + // "ENTITIES" - Key entities extracted from the conversation, such as ticket + // number, order number, dollar amount, etc. Section names are prefixed by + // "entities/". + // "CUSTOMER_DEFINED" - Customer defined sections. + Type string `json:"type,omitempty"` + // ForceSendFields is a list of field names (e.g. "Definition") to + // unconditionally include in API requests. By default, fields with empty or + // default values are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. + ForceSendFields []string `json:"-"` + // NullFields is a list of field names (e.g. "Definition") to include in API + // requests with the JSON null value. By default, fields with empty values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. + NullFields []string `json:"-"` +} + +func (s *GoogleCloudDialogflowV2beta1SummarizationSection) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDialogflowV2beta1SummarizationSection + return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) +} + +// GoogleCloudDialogflowV2beta1SummarizationSectionList: List of summarization +// sections. +type GoogleCloudDialogflowV2beta1SummarizationSectionList struct { + // SummarizationSections: Optional. Summarization sections. + SummarizationSections []*GoogleCloudDialogflowV2beta1SummarizationSection `json:"summarizationSections,omitempty"` + // ForceSendFields is a list of field names (e.g. "SummarizationSections") to + // unconditionally include in API requests. By default, fields with empty or + // default values are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. + ForceSendFields []string `json:"-"` + // NullFields is a list of field names (e.g. "SummarizationSections") to + // include in API requests with the JSON null value. By default, fields with + // empty values are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. + NullFields []string `json:"-"` +} + +func (s *GoogleCloudDialogflowV2beta1SummarizationSectionList) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDialogflowV2beta1SummarizationSectionList + return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) +} + +// GoogleCloudDialogflowV2beta1SummarySuggestion: Suggested summary of the +// conversation. +type GoogleCloudDialogflowV2beta1SummarySuggestion struct { + // SummarySections: Required. All the parts of generated summary. + SummarySections []*GoogleCloudDialogflowV2beta1SummarySuggestionSummarySection `json:"summarySections,omitempty"` + // ForceSendFields is a list of field names (e.g. "SummarySections") to + // unconditionally include in API requests. By default, fields with empty or + // default values are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. + ForceSendFields []string `json:"-"` + // NullFields is a list of field names (e.g. "SummarySections") to include in + // API requests with the JSON null value. By default, fields with empty values + // are omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. + NullFields []string `json:"-"` +} + +func (s *GoogleCloudDialogflowV2beta1SummarySuggestion) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDialogflowV2beta1SummarySuggestion + return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) +} + +// GoogleCloudDialogflowV2beta1SummarySuggestionSummarySection: A component of +// the generated summary. +type GoogleCloudDialogflowV2beta1SummarySuggestionSummarySection struct { + // Section: Required. Name of the section. + Section string `json:"section,omitempty"` + // Summary: Required. Summary text for the section. + Summary string `json:"summary,omitempty"` + // ForceSendFields is a list of field names (e.g. "Section") to unconditionally + // include in API requests. By default, fields with empty or default values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more + // details. + ForceSendFields []string `json:"-"` + // NullFields is a list of field names (e.g. "Section") to include in API + // requests with the JSON null value. By default, fields with empty values are + // omitted from API requests. See + // https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details. + NullFields []string `json:"-"` +} + +func (s *GoogleCloudDialogflowV2beta1SummarySuggestionSummarySection) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDialogflowV2beta1SummarySuggestionSummarySection + return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) +} + // GoogleCloudDialogflowV2beta1SynthesizeSpeechConfig: Configuration of how // speech should be synthesized. type GoogleCloudDialogflowV2beta1SynthesizeSpeechConfig struct { @@ -31363,6 +31878,266 @@ func (c *ProjectsConversationsSuggestionsSuggestConversationSummaryCall) Do(opts return ret, nil } +type ProjectsGeneratorsCreateCall struct { + s *Service + parent string + googleclouddialogflowv2beta1generator *GoogleCloudDialogflowV2beta1Generator + urlParams_ gensupport.URLParams + ctx_ context.Context + header_ http.Header +} + +// Create: Creates a generator. +// +// - parent: The project/location to create generator for. Format: +// `projects//locations/`. +func (r *ProjectsGeneratorsService) Create(parent string, googleclouddialogflowv2beta1generator *GoogleCloudDialogflowV2beta1Generator) *ProjectsGeneratorsCreateCall { + c := &ProjectsGeneratorsCreateCall{s: r.s, urlParams_: make(gensupport.URLParams)} + c.parent = parent + c.googleclouddialogflowv2beta1generator = googleclouddialogflowv2beta1generator + return c +} + +// GeneratorId sets the optional parameter "generatorId": The ID to use for the +// generator, which will become the final component of the generator's resource +// name. The generator ID must be compliant with the regression fomula +// `a-zA-Z*` with the characters length in range of [3,64]. If the field is not +// provided, an Id will be auto-generated. If the field is provided, the caller +// is resposible for 1. the uniqueness of the ID, otherwise the request will be +// rejected. 2. the consistency for whether to use custom ID or not under a +// project to better ensure uniqueness. +func (c *ProjectsGeneratorsCreateCall) GeneratorId(generatorId string) *ProjectsGeneratorsCreateCall { + c.urlParams_.Set("generatorId", generatorId) + return c +} + +// Fields allows partial responses to be retrieved. See +// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more +// details. +func (c *ProjectsGeneratorsCreateCall) Fields(s ...googleapi.Field) *ProjectsGeneratorsCreateCall { + c.urlParams_.Set("fields", googleapi.CombineFields(s)) + return c +} + +// Context sets the context to be used in this call's Do method. +func (c *ProjectsGeneratorsCreateCall) Context(ctx context.Context) *ProjectsGeneratorsCreateCall { + c.ctx_ = ctx + return c +} + +// Header returns a http.Header that can be modified by the caller to add +// headers to the request. +func (c *ProjectsGeneratorsCreateCall) Header() http.Header { + if c.header_ == nil { + c.header_ = make(http.Header) + } + return c.header_ +} + +func (c *ProjectsGeneratorsCreateCall) doRequest(alt string) (*http.Response, error) { + reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "application/json", c.header_) + var body io.Reader = nil + body, err := googleapi.WithoutDataWrapper.JSONReader(c.googleclouddialogflowv2beta1generator) + if err != nil { + return nil, err + } + c.urlParams_.Set("alt", alt) + c.urlParams_.Set("prettyPrint", "false") + urls := googleapi.ResolveRelative(c.s.BasePath, "v2beta1/{+parent}/generators") + 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 "dialogflow.projects.generators.create" call. +// Any non-2xx status code is an error. Response headers are in either +// *GoogleCloudDialogflowV2beta1Generator.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 *ProjectsGeneratorsCreateCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDialogflowV2beta1Generator, error) { + gensupport.SetOptions(c.urlParams_, opts...) + res, err := c.doRequest("json") + if res != nil && res.StatusCode == http.StatusNotModified { + if res.Body != nil { + res.Body.Close() + } + return nil, gensupport.WrapError(&googleapi.Error{ + Code: res.StatusCode, + Header: res.Header, + }) + } + if err != nil { + return nil, err + } + defer googleapi.CloseBody(res) + if err := googleapi.CheckResponse(res); err != nil { + return nil, gensupport.WrapError(err) + } + ret := &GoogleCloudDialogflowV2beta1Generator{ + 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 +} + +type ProjectsGeneratorsListCall struct { + s *Service + parent string + urlParams_ gensupport.URLParams + ifNoneMatch_ string + ctx_ context.Context + header_ http.Header +} + +// List: Lists generators. +// +// - parent: The project/location to list generators for. Format: +// `projects//locations/`. +func (r *ProjectsGeneratorsService) List(parent string) *ProjectsGeneratorsListCall { + c := &ProjectsGeneratorsListCall{s: r.s, urlParams_: make(gensupport.URLParams)} + c.parent = parent + return c +} + +// PageSize sets the optional parameter "pageSize": Maximum number of +// conversation models to return in a single page. Default to 10. +func (c *ProjectsGeneratorsListCall) PageSize(pageSize int64) *ProjectsGeneratorsListCall { + c.urlParams_.Set("pageSize", fmt.Sprint(pageSize)) + return c +} + +// PageToken sets the optional parameter "pageToken": The next_page_token value +// returned from a previous list request. +func (c *ProjectsGeneratorsListCall) PageToken(pageToken string) *ProjectsGeneratorsListCall { + c.urlParams_.Set("pageToken", pageToken) + return c +} + +// Fields allows partial responses to be retrieved. See +// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more +// details. +func (c *ProjectsGeneratorsListCall) Fields(s ...googleapi.Field) *ProjectsGeneratorsListCall { + c.urlParams_.Set("fields", googleapi.CombineFields(s)) + return c +} + +// IfNoneMatch sets an 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. +func (c *ProjectsGeneratorsListCall) IfNoneMatch(entityTag string) *ProjectsGeneratorsListCall { + c.ifNoneMatch_ = entityTag + return c +} + +// Context sets the context to be used in this call's Do method. +func (c *ProjectsGeneratorsListCall) Context(ctx context.Context) *ProjectsGeneratorsListCall { + c.ctx_ = ctx + return c +} + +// Header returns a http.Header that can be modified by the caller to add +// headers to the request. +func (c *ProjectsGeneratorsListCall) Header() http.Header { + if c.header_ == nil { + c.header_ = make(http.Header) + } + return c.header_ +} + +func (c *ProjectsGeneratorsListCall) doRequest(alt string) (*http.Response, error) { + reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "", c.header_) + 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, "v2beta1/{+parent}/generators") + 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 "dialogflow.projects.generators.list" call. +// Any non-2xx status code is an error. Response headers are in either +// *GoogleCloudDialogflowV2beta1ListGeneratorsResponse.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 *ProjectsGeneratorsListCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDialogflowV2beta1ListGeneratorsResponse, error) { + gensupport.SetOptions(c.urlParams_, opts...) + res, err := c.doRequest("json") + if res != nil && res.StatusCode == http.StatusNotModified { + if res.Body != nil { + res.Body.Close() + } + return nil, gensupport.WrapError(&googleapi.Error{ + Code: res.StatusCode, + Header: res.Header, + }) + } + if err != nil { + return nil, err + } + defer googleapi.CloseBody(res) + if err := googleapi.CheckResponse(res); err != nil { + return nil, gensupport.WrapError(err) + } + ret := &GoogleCloudDialogflowV2beta1ListGeneratorsResponse{ + 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 +} + +// 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 *ProjectsGeneratorsListCall) Pages(ctx context.Context, f func(*GoogleCloudDialogflowV2beta1ListGeneratorsResponse) error) error { + c.ctx_ = ctx + defer c.PageToken(c.urlParams_.Get("pageToken")) + for { + x, err := c.Do() + if err != nil { + return err + } + if err := f(x); err != nil { + return err + } + if x.NextPageToken == "" { + return nil + } + c.PageToken(x.NextPageToken) + } +} + type ProjectsKnowledgeBasesCreateCall struct { s *Service parent string @@ -43772,6 +44547,582 @@ func (c *ProjectsLocationsConversationsSuggestionsSuggestConversationSummaryCall return ret, nil } +type ProjectsLocationsGeneratorsCreateCall struct { + s *Service + parent string + googleclouddialogflowv2beta1generator *GoogleCloudDialogflowV2beta1Generator + urlParams_ gensupport.URLParams + ctx_ context.Context + header_ http.Header +} + +// Create: Creates a generator. +// +// - parent: The project/location to create generator for. Format: +// `projects//locations/`. +func (r *ProjectsLocationsGeneratorsService) Create(parent string, googleclouddialogflowv2beta1generator *GoogleCloudDialogflowV2beta1Generator) *ProjectsLocationsGeneratorsCreateCall { + c := &ProjectsLocationsGeneratorsCreateCall{s: r.s, urlParams_: make(gensupport.URLParams)} + c.parent = parent + c.googleclouddialogflowv2beta1generator = googleclouddialogflowv2beta1generator + return c +} + +// GeneratorId sets the optional parameter "generatorId": The ID to use for the +// generator, which will become the final component of the generator's resource +// name. The generator ID must be compliant with the regression fomula +// `a-zA-Z*` with the characters length in range of [3,64]. If the field is not +// provided, an Id will be auto-generated. If the field is provided, the caller +// is resposible for 1. the uniqueness of the ID, otherwise the request will be +// rejected. 2. the consistency for whether to use custom ID or not under a +// project to better ensure uniqueness. +func (c *ProjectsLocationsGeneratorsCreateCall) GeneratorId(generatorId string) *ProjectsLocationsGeneratorsCreateCall { + c.urlParams_.Set("generatorId", generatorId) + return c +} + +// Fields allows partial responses to be retrieved. See +// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more +// details. +func (c *ProjectsLocationsGeneratorsCreateCall) Fields(s ...googleapi.Field) *ProjectsLocationsGeneratorsCreateCall { + c.urlParams_.Set("fields", googleapi.CombineFields(s)) + return c +} + +// Context sets the context to be used in this call's Do method. +func (c *ProjectsLocationsGeneratorsCreateCall) Context(ctx context.Context) *ProjectsLocationsGeneratorsCreateCall { + c.ctx_ = ctx + return c +} + +// Header returns a http.Header that can be modified by the caller to add +// headers to the request. +func (c *ProjectsLocationsGeneratorsCreateCall) Header() http.Header { + if c.header_ == nil { + c.header_ = make(http.Header) + } + return c.header_ +} + +func (c *ProjectsLocationsGeneratorsCreateCall) doRequest(alt string) (*http.Response, error) { + reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "application/json", c.header_) + var body io.Reader = nil + body, err := googleapi.WithoutDataWrapper.JSONReader(c.googleclouddialogflowv2beta1generator) + if err != nil { + return nil, err + } + c.urlParams_.Set("alt", alt) + c.urlParams_.Set("prettyPrint", "false") + urls := googleapi.ResolveRelative(c.s.BasePath, "v2beta1/{+parent}/generators") + 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 "dialogflow.projects.locations.generators.create" call. +// Any non-2xx status code is an error. Response headers are in either +// *GoogleCloudDialogflowV2beta1Generator.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 *ProjectsLocationsGeneratorsCreateCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDialogflowV2beta1Generator, error) { + gensupport.SetOptions(c.urlParams_, opts...) + res, err := c.doRequest("json") + if res != nil && res.StatusCode == http.StatusNotModified { + if res.Body != nil { + res.Body.Close() + } + return nil, gensupport.WrapError(&googleapi.Error{ + Code: res.StatusCode, + Header: res.Header, + }) + } + if err != nil { + return nil, err + } + defer googleapi.CloseBody(res) + if err := googleapi.CheckResponse(res); err != nil { + return nil, gensupport.WrapError(err) + } + ret := &GoogleCloudDialogflowV2beta1Generator{ + 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 +} + +type ProjectsLocationsGeneratorsDeleteCall struct { + s *Service + name string + urlParams_ gensupport.URLParams + ctx_ context.Context + header_ http.Header +} + +// Delete: Deletes a generator. +// +// - name: The generator resource name to delete. Format: +// `projects//locations//generators/`. +func (r *ProjectsLocationsGeneratorsService) Delete(name string) *ProjectsLocationsGeneratorsDeleteCall { + c := &ProjectsLocationsGeneratorsDeleteCall{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 +// details. +func (c *ProjectsLocationsGeneratorsDeleteCall) Fields(s ...googleapi.Field) *ProjectsLocationsGeneratorsDeleteCall { + c.urlParams_.Set("fields", googleapi.CombineFields(s)) + return c +} + +// Context sets the context to be used in this call's Do method. +func (c *ProjectsLocationsGeneratorsDeleteCall) Context(ctx context.Context) *ProjectsLocationsGeneratorsDeleteCall { + c.ctx_ = ctx + return c +} + +// Header returns a http.Header that can be modified by the caller to add +// headers to the request. +func (c *ProjectsLocationsGeneratorsDeleteCall) Header() http.Header { + if c.header_ == nil { + c.header_ = make(http.Header) + } + return c.header_ +} + +func (c *ProjectsLocationsGeneratorsDeleteCall) doRequest(alt string) (*http.Response, error) { + reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "", c.header_) + var body io.Reader = nil + c.urlParams_.Set("alt", alt) + c.urlParams_.Set("prettyPrint", "false") + urls := googleapi.ResolveRelative(c.s.BasePath, "v2beta1/{+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 "dialogflow.projects.locations.generators.delete" call. +// Any non-2xx status code is an error. Response headers are in either +// *GoogleProtobufEmpty.ServerResponse.Header or (if a response was returned at +// all) in error.(*googleapi.Error).Header. Use googleapi.IsNotModified to +// check whether the returned error was because http.StatusNotModified was +// returned. +func (c *ProjectsLocationsGeneratorsDeleteCall) Do(opts ...googleapi.CallOption) (*GoogleProtobufEmpty, error) { + gensupport.SetOptions(c.urlParams_, opts...) + res, err := c.doRequest("json") + if res != nil && res.StatusCode == http.StatusNotModified { + if res.Body != nil { + res.Body.Close() + } + return nil, gensupport.WrapError(&googleapi.Error{ + Code: res.StatusCode, + Header: res.Header, + }) + } + if err != nil { + return nil, err + } + defer googleapi.CloseBody(res) + if err := googleapi.CheckResponse(res); err != nil { + return nil, gensupport.WrapError(err) + } + ret := &GoogleProtobufEmpty{ + ServerResponse: googleapi.ServerResponse{ + Header: res.Header, + HTTPStatusCode: res.StatusCode, + }, + } + target := &ret + if err := gensupport.DecodeResponse(target, res); err != nil { + return nil, err + } + return ret, nil +} + +type ProjectsLocationsGeneratorsGetCall struct { + s *Service + name string + urlParams_ gensupport.URLParams + ifNoneMatch_ string + ctx_ context.Context + header_ http.Header +} + +// Get: Retrieves a generator. +// +// - name: The generator resource name to retrieve. Format: +// `projects//locations/`/generators/`. +func (r *ProjectsLocationsGeneratorsService) Get(name string) *ProjectsLocationsGeneratorsGetCall { + c := &ProjectsLocationsGeneratorsGetCall{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 +// details. +func (c *ProjectsLocationsGeneratorsGetCall) Fields(s ...googleapi.Field) *ProjectsLocationsGeneratorsGetCall { + c.urlParams_.Set("fields", googleapi.CombineFields(s)) + return c +} + +// IfNoneMatch sets an 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. +func (c *ProjectsLocationsGeneratorsGetCall) IfNoneMatch(entityTag string) *ProjectsLocationsGeneratorsGetCall { + c.ifNoneMatch_ = entityTag + return c +} + +// Context sets the context to be used in this call's Do method. +func (c *ProjectsLocationsGeneratorsGetCall) Context(ctx context.Context) *ProjectsLocationsGeneratorsGetCall { + c.ctx_ = ctx + return c +} + +// Header returns a http.Header that can be modified by the caller to add +// headers to the request. +func (c *ProjectsLocationsGeneratorsGetCall) Header() http.Header { + if c.header_ == nil { + c.header_ = make(http.Header) + } + return c.header_ +} + +func (c *ProjectsLocationsGeneratorsGetCall) doRequest(alt string) (*http.Response, error) { + reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "", c.header_) + 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, "v2beta1/{+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 "dialogflow.projects.locations.generators.get" call. +// Any non-2xx status code is an error. Response headers are in either +// *GoogleCloudDialogflowV2beta1Generator.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 *ProjectsLocationsGeneratorsGetCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDialogflowV2beta1Generator, error) { + gensupport.SetOptions(c.urlParams_, opts...) + res, err := c.doRequest("json") + if res != nil && res.StatusCode == http.StatusNotModified { + if res.Body != nil { + res.Body.Close() + } + return nil, gensupport.WrapError(&googleapi.Error{ + Code: res.StatusCode, + Header: res.Header, + }) + } + if err != nil { + return nil, err + } + defer googleapi.CloseBody(res) + if err := googleapi.CheckResponse(res); err != nil { + return nil, gensupport.WrapError(err) + } + ret := &GoogleCloudDialogflowV2beta1Generator{ + 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 +} + +type ProjectsLocationsGeneratorsListCall struct { + s *Service + parent string + urlParams_ gensupport.URLParams + ifNoneMatch_ string + ctx_ context.Context + header_ http.Header +} + +// List: Lists generators. +// +// - parent: The project/location to list generators for. Format: +// `projects//locations/`. +func (r *ProjectsLocationsGeneratorsService) List(parent string) *ProjectsLocationsGeneratorsListCall { + c := &ProjectsLocationsGeneratorsListCall{s: r.s, urlParams_: make(gensupport.URLParams)} + c.parent = parent + return c +} + +// PageSize sets the optional parameter "pageSize": Maximum number of +// conversation models to return in a single page. Default to 10. +func (c *ProjectsLocationsGeneratorsListCall) PageSize(pageSize int64) *ProjectsLocationsGeneratorsListCall { + c.urlParams_.Set("pageSize", fmt.Sprint(pageSize)) + return c +} + +// PageToken sets the optional parameter "pageToken": The next_page_token value +// returned from a previous list request. +func (c *ProjectsLocationsGeneratorsListCall) PageToken(pageToken string) *ProjectsLocationsGeneratorsListCall { + c.urlParams_.Set("pageToken", pageToken) + return c +} + +// Fields allows partial responses to be retrieved. See +// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more +// details. +func (c *ProjectsLocationsGeneratorsListCall) Fields(s ...googleapi.Field) *ProjectsLocationsGeneratorsListCall { + c.urlParams_.Set("fields", googleapi.CombineFields(s)) + return c +} + +// IfNoneMatch sets an 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. +func (c *ProjectsLocationsGeneratorsListCall) IfNoneMatch(entityTag string) *ProjectsLocationsGeneratorsListCall { + c.ifNoneMatch_ = entityTag + return c +} + +// Context sets the context to be used in this call's Do method. +func (c *ProjectsLocationsGeneratorsListCall) Context(ctx context.Context) *ProjectsLocationsGeneratorsListCall { + c.ctx_ = ctx + return c +} + +// Header returns a http.Header that can be modified by the caller to add +// headers to the request. +func (c *ProjectsLocationsGeneratorsListCall) Header() http.Header { + if c.header_ == nil { + c.header_ = make(http.Header) + } + return c.header_ +} + +func (c *ProjectsLocationsGeneratorsListCall) doRequest(alt string) (*http.Response, error) { + reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "", c.header_) + 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, "v2beta1/{+parent}/generators") + 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 "dialogflow.projects.locations.generators.list" call. +// Any non-2xx status code is an error. Response headers are in either +// *GoogleCloudDialogflowV2beta1ListGeneratorsResponse.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 *ProjectsLocationsGeneratorsListCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDialogflowV2beta1ListGeneratorsResponse, error) { + gensupport.SetOptions(c.urlParams_, opts...) + res, err := c.doRequest("json") + if res != nil && res.StatusCode == http.StatusNotModified { + if res.Body != nil { + res.Body.Close() + } + return nil, gensupport.WrapError(&googleapi.Error{ + Code: res.StatusCode, + Header: res.Header, + }) + } + if err != nil { + return nil, err + } + defer googleapi.CloseBody(res) + if err := googleapi.CheckResponse(res); err != nil { + return nil, gensupport.WrapError(err) + } + ret := &GoogleCloudDialogflowV2beta1ListGeneratorsResponse{ + 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 +} + +// 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 *ProjectsLocationsGeneratorsListCall) Pages(ctx context.Context, f func(*GoogleCloudDialogflowV2beta1ListGeneratorsResponse) error) error { + c.ctx_ = ctx + defer c.PageToken(c.urlParams_.Get("pageToken")) + for { + x, err := c.Do() + if err != nil { + return err + } + if err := f(x); err != nil { + return err + } + if x.NextPageToken == "" { + return nil + } + c.PageToken(x.NextPageToken) + } +} + +type ProjectsLocationsGeneratorsPatchCall struct { + s *Service + name string + googleclouddialogflowv2beta1generator *GoogleCloudDialogflowV2beta1Generator + urlParams_ gensupport.URLParams + ctx_ context.Context + header_ http.Header +} + +// Patch: Updates a generator. +// +// - name: Output only. Identifier. The resource name of the generator. Format: +// `projects//locations//generators/`. +func (r *ProjectsLocationsGeneratorsService) Patch(name string, googleclouddialogflowv2beta1generator *GoogleCloudDialogflowV2beta1Generator) *ProjectsLocationsGeneratorsPatchCall { + c := &ProjectsLocationsGeneratorsPatchCall{s: r.s, urlParams_: make(gensupport.URLParams)} + c.name = name + c.googleclouddialogflowv2beta1generator = googleclouddialogflowv2beta1generator + return c +} + +// UpdateMask sets the optional parameter "updateMask": The list of fields to +// update. +func (c *ProjectsLocationsGeneratorsPatchCall) UpdateMask(updateMask string) *ProjectsLocationsGeneratorsPatchCall { + 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 +// details. +func (c *ProjectsLocationsGeneratorsPatchCall) Fields(s ...googleapi.Field) *ProjectsLocationsGeneratorsPatchCall { + c.urlParams_.Set("fields", googleapi.CombineFields(s)) + return c +} + +// Context sets the context to be used in this call's Do method. +func (c *ProjectsLocationsGeneratorsPatchCall) Context(ctx context.Context) *ProjectsLocationsGeneratorsPatchCall { + c.ctx_ = ctx + return c +} + +// Header returns a http.Header that can be modified by the caller to add +// headers to the request. +func (c *ProjectsLocationsGeneratorsPatchCall) Header() http.Header { + if c.header_ == nil { + c.header_ = make(http.Header) + } + return c.header_ +} + +func (c *ProjectsLocationsGeneratorsPatchCall) doRequest(alt string) (*http.Response, error) { + reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "application/json", c.header_) + var body io.Reader = nil + body, err := googleapi.WithoutDataWrapper.JSONReader(c.googleclouddialogflowv2beta1generator) + if err != nil { + return nil, err + } + c.urlParams_.Set("alt", alt) + c.urlParams_.Set("prettyPrint", "false") + urls := googleapi.ResolveRelative(c.s.BasePath, "v2beta1/{+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 "dialogflow.projects.locations.generators.patch" call. +// Any non-2xx status code is an error. Response headers are in either +// *GoogleCloudDialogflowV2beta1Generator.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 *ProjectsLocationsGeneratorsPatchCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDialogflowV2beta1Generator, error) { + gensupport.SetOptions(c.urlParams_, opts...) + res, err := c.doRequest("json") + if res != nil && res.StatusCode == http.StatusNotModified { + if res.Body != nil { + res.Body.Close() + } + return nil, gensupport.WrapError(&googleapi.Error{ + Code: res.StatusCode, + Header: res.Header, + }) + } + if err != nil { + return nil, err + } + defer googleapi.CloseBody(res) + if err := googleapi.CheckResponse(res); err != nil { + return nil, gensupport.WrapError(err) + } + ret := &GoogleCloudDialogflowV2beta1Generator{ + 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 +} + type ProjectsLocationsKnowledgeBasesCreateCall struct { s *Service parent string @@ -45570,6 +46921,110 @@ func (c *ProjectsLocationsOperationsListCall) Pages(ctx context.Context, f func( } } +type ProjectsLocationsStatelessSuggestionGenerateCall struct { + s *Service + parent string + googleclouddialogflowv2beta1generatestatelesssuggestionrequest *GoogleCloudDialogflowV2beta1GenerateStatelessSuggestionRequest + urlParams_ gensupport.URLParams + ctx_ context.Context + header_ http.Header +} + +// Generate: Generates and returns a suggestion for a conversation that does +// not have a resource created for it. +// +// - parent: The parent resource to charge for the Suggestion's generation. +// Format: `projects//locations/`. +func (r *ProjectsLocationsStatelessSuggestionService) Generate(parent string, googleclouddialogflowv2beta1generatestatelesssuggestionrequest *GoogleCloudDialogflowV2beta1GenerateStatelessSuggestionRequest) *ProjectsLocationsStatelessSuggestionGenerateCall { + c := &ProjectsLocationsStatelessSuggestionGenerateCall{s: r.s, urlParams_: make(gensupport.URLParams)} + c.parent = parent + c.googleclouddialogflowv2beta1generatestatelesssuggestionrequest = googleclouddialogflowv2beta1generatestatelesssuggestionrequest + return c +} + +// Fields allows partial responses to be retrieved. See +// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more +// details. +func (c *ProjectsLocationsStatelessSuggestionGenerateCall) Fields(s ...googleapi.Field) *ProjectsLocationsStatelessSuggestionGenerateCall { + c.urlParams_.Set("fields", googleapi.CombineFields(s)) + return c +} + +// Context sets the context to be used in this call's Do method. +func (c *ProjectsLocationsStatelessSuggestionGenerateCall) Context(ctx context.Context) *ProjectsLocationsStatelessSuggestionGenerateCall { + c.ctx_ = ctx + return c +} + +// Header returns a http.Header that can be modified by the caller to add +// headers to the request. +func (c *ProjectsLocationsStatelessSuggestionGenerateCall) Header() http.Header { + if c.header_ == nil { + c.header_ = make(http.Header) + } + return c.header_ +} + +func (c *ProjectsLocationsStatelessSuggestionGenerateCall) doRequest(alt string) (*http.Response, error) { + reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "application/json", c.header_) + var body io.Reader = nil + body, err := googleapi.WithoutDataWrapper.JSONReader(c.googleclouddialogflowv2beta1generatestatelesssuggestionrequest) + if err != nil { + return nil, err + } + c.urlParams_.Set("alt", alt) + c.urlParams_.Set("prettyPrint", "false") + urls := googleapi.ResolveRelative(c.s.BasePath, "v2beta1/{+parent}/statelessSuggestion:generate") + 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 "dialogflow.projects.locations.statelessSuggestion.generate" call. +// Any non-2xx status code is an error. Response headers are in either +// *GoogleCloudDialogflowV2beta1GenerateStatelessSuggestionResponse.ServerRespon +// se.Header or (if a response was returned at all) in +// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check +// whether the returned error was because http.StatusNotModified was returned. +func (c *ProjectsLocationsStatelessSuggestionGenerateCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDialogflowV2beta1GenerateStatelessSuggestionResponse, error) { + gensupport.SetOptions(c.urlParams_, opts...) + res, err := c.doRequest("json") + if res != nil && res.StatusCode == http.StatusNotModified { + if res.Body != nil { + res.Body.Close() + } + return nil, gensupport.WrapError(&googleapi.Error{ + Code: res.StatusCode, + Header: res.Header, + }) + } + if err != nil { + return nil, err + } + defer googleapi.CloseBody(res) + if err := googleapi.CheckResponse(res); err != nil { + return nil, gensupport.WrapError(err) + } + ret := &GoogleCloudDialogflowV2beta1GenerateStatelessSuggestionResponse{ + 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 +} + type ProjectsLocationsSuggestionsGenerateStatelessSummaryCall struct { s *Service parent string diff --git a/displayvideo/v2/displayvideo-api.json b/displayvideo/v2/displayvideo-api.json index ea0cd67ea91..4a8c93a84d3 100644 --- a/displayvideo/v2/displayvideo-api.json +++ b/displayvideo/v2/displayvideo-api.json @@ -9267,7 +9267,7 @@ } } }, - "revision": "20240418", + "revision": "20240530", "rootUrl": "https://displayvideo.googleapis.com/", "schemas": { "ActivateManualTriggerRequest": { @@ -12331,7 +12331,8 @@ "SDF_VERSION_5_4", "SDF_VERSION_5_5", "SDF_VERSION_6", - "SDF_VERSION_7" + "SDF_VERSION_7", + "SDF_VERSION_7_1" ], "enumDeprecated": [ false, @@ -12346,6 +12347,7 @@ true, false, false, + false, false ], "enumDescriptions": [ @@ -12361,7 +12363,8 @@ "SDF version 5.4", "SDF version 5.5", "SDF version 6", - "SDF version 7. Read the [v7 migration guide](/display-video/api/structured-data-file/v7-migration-guide) before migrating to this version." + "SDF version 7. Read the [v7 migration guide](/display-video/api/structured-data-file/v7-migration-guide) before migrating to this version.", + "SDF version 7.1. Read the [v7 migration guide](/display-video/api/structured-data-file/v7-migration-guide) before migrating to this version." ], "type": "string" } @@ -19757,7 +19760,7 @@ "type": "array" }, "publisherReviewStatuses": { - "description": "Publisher review statuses for the creative.", + "description": "Publisher review statuses for the creative. **Warning:** This field will be deprecated on June 26th, 2024. After this date, this field will be empty. Read our [feature deprecation announcement](/display-video/api/deprecations#features.creative_publisher_review_statuses) for more information.", "items": { "$ref": "PublisherReviewStatus" }, @@ -19826,7 +19829,8 @@ "SDF_VERSION_5_4", "SDF_VERSION_5_5", "SDF_VERSION_6", - "SDF_VERSION_7" + "SDF_VERSION_7", + "SDF_VERSION_7_1" ], "enumDeprecated": [ false, @@ -19841,6 +19845,7 @@ true, false, false, + false, false ], "enumDescriptions": [ @@ -19856,7 +19861,8 @@ "SDF version 5.4", "SDF version 5.5", "SDF version 6", - "SDF version 7. Read the [v7 migration guide](/display-video/api/structured-data-file/v7-migration-guide) before migrating to this version." + "SDF version 7. Read the [v7 migration guide](/display-video/api/structured-data-file/v7-migration-guide) before migrating to this version.", + "SDF version 7.1. Read the [v7 migration guide](/display-video/api/structured-data-file/v7-migration-guide) before migrating to this version." ], "type": "string" } @@ -19903,7 +19909,8 @@ "SDF_VERSION_5_4", "SDF_VERSION_5_5", "SDF_VERSION_6", - "SDF_VERSION_7" + "SDF_VERSION_7", + "SDF_VERSION_7_1" ], "enumDeprecated": [ false, @@ -19918,6 +19925,7 @@ true, false, false, + false, false ], "enumDescriptions": [ @@ -19933,7 +19941,8 @@ "SDF version 5.4", "SDF version 5.5", "SDF version 6", - "SDF version 7. Read the [v7 migration guide](/display-video/api/structured-data-file/v7-migration-guide) before migrating to this version." + "SDF version 7. Read the [v7 migration guide](/display-video/api/structured-data-file/v7-migration-guide) before migrating to this version.", + "SDF version 7.1. Read the [v7 migration guide](/display-video/api/structured-data-file/v7-migration-guide) before migrating to this version." ], "type": "string" } diff --git a/displayvideo/v2/displayvideo-gen.go b/displayvideo/v2/displayvideo-gen.go index fe625674ebe..f7f797acd93 100644 --- a/displayvideo/v2/displayvideo-gen.go +++ b/displayvideo/v2/displayvideo-gen.go @@ -4794,6 +4794,9 @@ type CreateSdfDownloadTaskRequest struct { // "SDF_VERSION_7" - SDF version 7. Read the [v7 migration // guide](/display-video/api/structured-data-file/v7-migration-guide) before // migrating to this version. + // "SDF_VERSION_7_1" - SDF version 7.1. Read the [v7 migration + // guide](/display-video/api/structured-data-file/v7-migration-guide) before + // migrating to this version. Version string `json:"version,omitempty"` // ForceSendFields is a list of field names (e.g. "AdvertiserId") to // unconditionally include in API requests. By default, fields with empty or @@ -13102,6 +13105,10 @@ type ReviewStatusInfo struct { // ExchangeReviewStatuses: Exchange review statuses for the creative. ExchangeReviewStatuses []*ExchangeReviewStatus `json:"exchangeReviewStatuses,omitempty"` // PublisherReviewStatuses: Publisher review statuses for the creative. + // **Warning:** This field will be deprecated on June 26th, 2024. After this + // date, this field will be empty. Read our feature deprecation announcement + // (/display-video/api/deprecations#features.creative_publisher_review_statuses) + // for more information. PublisherReviewStatuses []*PublisherReviewStatus `json:"publisherReviewStatuses,omitempty"` // ForceSendFields is a list of field names (e.g. "ApprovalStatus") to // unconditionally include in API requests. By default, fields with empty or @@ -13181,6 +13188,9 @@ type SdfConfig struct { // "SDF_VERSION_7" - SDF version 7. Read the [v7 migration // guide](/display-video/api/structured-data-file/v7-migration-guide) before // migrating to this version. + // "SDF_VERSION_7_1" - SDF version 7.1. Read the [v7 migration + // guide](/display-video/api/structured-data-file/v7-migration-guide) before + // migrating to this version. Version string `json:"version,omitempty"` // ForceSendFields is a list of field names (e.g. "AdminEmail") to // unconditionally include in API requests. By default, fields with empty or @@ -13253,6 +13263,9 @@ type SdfDownloadTaskMetadata struct { // "SDF_VERSION_7" - SDF version 7. Read the [v7 migration // guide](/display-video/api/structured-data-file/v7-migration-guide) before // migrating to this version. + // "SDF_VERSION_7_1" - SDF version 7.1. Read the [v7 migration + // guide](/display-video/api/structured-data-file/v7-migration-guide) before + // migrating to this version. Version string `json:"version,omitempty"` // ForceSendFields is a list of field names (e.g. "CreateTime") to // unconditionally include in API requests. By default, fields with empty or diff --git a/displayvideo/v3/displayvideo-api.json b/displayvideo/v3/displayvideo-api.json index 418eee1cd62..d1af2c371c4 100644 --- a/displayvideo/v3/displayvideo-api.json +++ b/displayvideo/v3/displayvideo-api.json @@ -9222,7 +9222,7 @@ } } }, - "revision": "20240418", + "revision": "20240530", "rootUrl": "https://displayvideo.googleapis.com/", "schemas": { "ActiveViewVideoViewabilityMetricConfig": { @@ -12904,7 +12904,8 @@ "SDF_VERSION_5_4", "SDF_VERSION_5_5", "SDF_VERSION_6", - "SDF_VERSION_7" + "SDF_VERSION_7", + "SDF_VERSION_7_1" ], "enumDeprecated": [ false, @@ -12919,6 +12920,7 @@ true, false, false, + false, false ], "enumDescriptions": [ @@ -12934,7 +12936,8 @@ "SDF version 5.4", "SDF version 5.5", "SDF version 6", - "SDF version 7. Read the [v7 migration guide](/display-video/api/structured-data-file/v7-migration-guide) before migrating to this version." + "SDF version 7. Read the [v7 migration guide](/display-video/api/structured-data-file/v7-migration-guide) before migrating to this version.", + "SDF version 7.1. Read the [v7 migration guide](/display-video/api/structured-data-file/v7-migration-guide) before migrating to this version." ], "type": "string" } @@ -20486,7 +20489,7 @@ "type": "array" }, "publisherReviewStatuses": { - "description": "Publisher review statuses for the creative.", + "description": "Publisher review statuses for the creative. **Warning:** This field will be deprecated on June 26th, 2024. After this date, this field will be empty. Read our [feature deprecation announcement](/display-video/api/deprecations#features.creative_publisher_review_statuses) for more information.", "items": { "$ref": "PublisherReviewStatus" }, @@ -20555,7 +20558,8 @@ "SDF_VERSION_5_4", "SDF_VERSION_5_5", "SDF_VERSION_6", - "SDF_VERSION_7" + "SDF_VERSION_7", + "SDF_VERSION_7_1" ], "enumDeprecated": [ false, @@ -20570,6 +20574,7 @@ true, false, false, + false, false ], "enumDescriptions": [ @@ -20585,7 +20590,8 @@ "SDF version 5.4", "SDF version 5.5", "SDF version 6", - "SDF version 7. Read the [v7 migration guide](/display-video/api/structured-data-file/v7-migration-guide) before migrating to this version." + "SDF version 7. Read the [v7 migration guide](/display-video/api/structured-data-file/v7-migration-guide) before migrating to this version.", + "SDF version 7.1. Read the [v7 migration guide](/display-video/api/structured-data-file/v7-migration-guide) before migrating to this version." ], "type": "string" } @@ -20632,7 +20638,8 @@ "SDF_VERSION_5_4", "SDF_VERSION_5_5", "SDF_VERSION_6", - "SDF_VERSION_7" + "SDF_VERSION_7", + "SDF_VERSION_7_1" ], "enumDeprecated": [ false, @@ -20647,6 +20654,7 @@ true, false, false, + false, false ], "enumDescriptions": [ @@ -20662,7 +20670,8 @@ "SDF version 5.4", "SDF version 5.5", "SDF version 6", - "SDF version 7. Read the [v7 migration guide](/display-video/api/structured-data-file/v7-migration-guide) before migrating to this version." + "SDF version 7. Read the [v7 migration guide](/display-video/api/structured-data-file/v7-migration-guide) before migrating to this version.", + "SDF version 7.1. Read the [v7 migration guide](/display-video/api/structured-data-file/v7-migration-guide) before migrating to this version." ], "type": "string" } diff --git a/displayvideo/v3/displayvideo-gen.go b/displayvideo/v3/displayvideo-gen.go index ddf9152b5b5..8ab2a097fd2 100644 --- a/displayvideo/v3/displayvideo-gen.go +++ b/displayvideo/v3/displayvideo-gen.go @@ -5409,6 +5409,9 @@ type CreateSdfDownloadTaskRequest struct { // "SDF_VERSION_7" - SDF version 7. Read the [v7 migration // guide](/display-video/api/structured-data-file/v7-migration-guide) before // migrating to this version. + // "SDF_VERSION_7_1" - SDF version 7.1. Read the [v7 migration + // guide](/display-video/api/structured-data-file/v7-migration-guide) before + // migrating to this version. Version string `json:"version,omitempty"` // ForceSendFields is a list of field names (e.g. "AdvertiserId") to // unconditionally include in API requests. By default, fields with empty or @@ -13912,6 +13915,10 @@ type ReviewStatusInfo struct { // ExchangeReviewStatuses: Exchange review statuses for the creative. ExchangeReviewStatuses []*ExchangeReviewStatus `json:"exchangeReviewStatuses,omitempty"` // PublisherReviewStatuses: Publisher review statuses for the creative. + // **Warning:** This field will be deprecated on June 26th, 2024. After this + // date, this field will be empty. Read our feature deprecation announcement + // (/display-video/api/deprecations#features.creative_publisher_review_statuses) + // for more information. PublisherReviewStatuses []*PublisherReviewStatus `json:"publisherReviewStatuses,omitempty"` // ForceSendFields is a list of field names (e.g. "ApprovalStatus") to // unconditionally include in API requests. By default, fields with empty or @@ -13991,6 +13998,9 @@ type SdfConfig struct { // "SDF_VERSION_7" - SDF version 7. Read the [v7 migration // guide](/display-video/api/structured-data-file/v7-migration-guide) before // migrating to this version. + // "SDF_VERSION_7_1" - SDF version 7.1. Read the [v7 migration + // guide](/display-video/api/structured-data-file/v7-migration-guide) before + // migrating to this version. Version string `json:"version,omitempty"` // ForceSendFields is a list of field names (e.g. "AdminEmail") to // unconditionally include in API requests. By default, fields with empty or @@ -14063,6 +14073,9 @@ type SdfDownloadTaskMetadata struct { // "SDF_VERSION_7" - SDF version 7. Read the [v7 migration // guide](/display-video/api/structured-data-file/v7-migration-guide) before // migrating to this version. + // "SDF_VERSION_7_1" - SDF version 7.1. Read the [v7 migration + // guide](/display-video/api/structured-data-file/v7-migration-guide) before + // migrating to this version. Version string `json:"version,omitempty"` // ForceSendFields is a list of field names (e.g. "CreateTime") to // unconditionally include in API requests. By default, fields with empty or diff --git a/dlp/v2/dlp-api.json b/dlp/v2/dlp-api.json index a0d9387527a..40489de1e2a 100644 --- a/dlp/v2/dlp-api.json +++ b/dlp/v2/dlp-api.json @@ -4451,7 +4451,7 @@ } } }, - "revision": "20240519", + "revision": "20240526", "rootUrl": "https://dlp.googleapis.com/", "schemas": { "GooglePrivacyDlpV2Action": { @@ -7578,6 +7578,7 @@ "GLOBAL", "ARGENTINA", "AUSTRALIA", + "AZERBAIJAN", "BELGIUM", "BRAZIL", "CANADA", @@ -7628,6 +7629,7 @@ "The infoType is not issued by or tied to a specific region, but is used almost everywhere.", "The infoType is typically used in Argentina.", "The infoType is typically used in Australia.", + "The infoType is typically used in Azerbaijan.", "The infoType is typically used in Belgium.", "The infoType is typically used in Brazil.", "The infoType is typically used in Canada.", diff --git a/dlp/v2/dlp-gen.go b/dlp/v2/dlp-gen.go index f87c55cdf80..f442f6a8fbe 100644 --- a/dlp/v2/dlp-gen.go +++ b/dlp/v2/dlp-gen.go @@ -5035,6 +5035,7 @@ type GooglePrivacyDlpV2InfoTypeCategory struct { // is used almost everywhere. // "ARGENTINA" - The infoType is typically used in Argentina. // "AUSTRALIA" - The infoType is typically used in Australia. + // "AZERBAIJAN" - The infoType is typically used in Azerbaijan. // "BELGIUM" - The infoType is typically used in Belgium. // "BRAZIL" - The infoType is typically used in Brazil. // "CANADA" - The infoType is typically used in Canada. diff --git a/iap/v1/iap-api.json b/iap/v1/iap-api.json index 21a9057ae92..259ce3792f3 100644 --- a/iap/v1/iap-api.json +++ b/iap/v1/iap-api.json @@ -682,7 +682,7 @@ } } }, - "revision": "20240513", + "revision": "20240527", "rootUrl": "https://iap.googleapis.com/", "schemas": { "AccessDeniedPageSettings": { @@ -1156,7 +1156,7 @@ "type": "string" }, "type": { - "description": "Resource type. Types are defined in IAM's .service files. Valid values for type might be 'gce', 'gcs', 'project', 'account' etc.", + "description": "Resource type. Types are defined in IAM's .service files. Valid values for type might be 'storage_buckets', 'compute_instances', 'resourcemanager_customers', 'billing_accounts', etc.", "type": "string" } }, diff --git a/iap/v1/iap-gen.go b/iap/v1/iap-gen.go index fee50b11be2..3b821f122c2 100644 --- a/iap/v1/iap-gen.go +++ b/iap/v1/iap-gen.go @@ -1104,7 +1104,8 @@ type PolicyName struct { // be set to "local". Region string `json:"region,omitempty"` // Type: Resource type. Types are defined in IAM's .service files. Valid values - // for type might be 'gce', 'gcs', 'project', 'account' etc. + // for type might be 'storage_buckets', 'compute_instances', + // 'resourcemanager_customers', 'billing_accounts', etc. Type string `json:"type,omitempty"` // ForceSendFields is a list of field names (e.g. "Id") to unconditionally // include in API requests. By default, fields with empty or default values are diff --git a/marketingplatformadmin/v1alpha/marketingplatformadmin-api.json b/marketingplatformadmin/v1alpha/marketingplatformadmin-api.json index 8728d7b1336..3c35ab7b348 100644 --- a/marketingplatformadmin/v1alpha/marketingplatformadmin-api.json +++ b/marketingplatformadmin/v1alpha/marketingplatformadmin-api.json @@ -15,7 +15,7 @@ "baseUrl": "https://marketingplatformadmin.googleapis.com/", "batchPath": "batch", "canonicalName": "Google Marketing Platform Admin API", - "description": "The Google Marketing Platform Admin API allows for programmatic access to the Google Marketing Platform configuration data. You can use the Google Marketing Platform Admin API to manage links between your Google Marketing Platform organization and Google Analytics accounts, set the service level of your GA4 properties.", + "description": "The Google Marketing Platform Admin API allows for programmatic access to the Google Marketing Platform configuration data. You can use the Google Marketing Platform Admin API to manage links between your Google Marketing Platform organization and Google Analytics accounts, and to set the service level of your GA4 properties.", "discoveryVersion": "v1", "documentationLink": "https://developers.google.com/analytics/devguides/config/gmp/v1", "fullyEncodeReservedExpansion": true, @@ -263,7 +263,7 @@ } } }, - "revision": "20240410", + "revision": "20240530", "rootUrl": "https://marketingplatformadmin.googleapis.com/", "schemas": { "AnalyticsAccountLink": { diff --git a/recaptchaenterprise/v1/recaptchaenterprise-api.json b/recaptchaenterprise/v1/recaptchaenterprise-api.json index 4f112cf59a9..129c55f48b6 100644 --- a/recaptchaenterprise/v1/recaptchaenterprise-api.json +++ b/recaptchaenterprise/v1/recaptchaenterprise-api.json @@ -694,7 +694,7 @@ } } }, - "revision": "20240518", + "revision": "20240526", "rootUrl": "https://recaptchaenterprise.googleapis.com/", "schemas": { "GoogleCloudRecaptchaenterpriseV1AccountDefenderAssessment": { @@ -1553,7 +1553,7 @@ "properties": { "smsTollFraudVerdict": { "$ref": "GoogleCloudRecaptchaenterpriseV1SmsTollFraudVerdict", - "description": "Output only. Assessment of this phone event for risk of sms toll fraud.", + "description": "Output only. Assessment of this phone event for risk of SMS toll fraud.", "readOnly": true } }, @@ -1781,7 +1781,7 @@ "type": "object" }, "GoogleCloudRecaptchaenterpriseV1SmsTollFraudVerdict": { - "description": "Information about sms toll fraud", + "description": "Information about SMS toll fraud.", "id": "GoogleCloudRecaptchaenterpriseV1SmsTollFraudVerdict", "properties": { "reasons": { @@ -1801,7 +1801,7 @@ "type": "array" }, "risk": { - "description": "Output only. Probability of an sms event being fraudulent. Values are from 0.0 (lowest) to 1.0 (highest).", + "description": "Output only. Probability of an SMS event being fraudulent. Values are from 0.0 (lowest) to 1.0 (highest).", "format": "float", "readOnly": true, "type": "number" diff --git a/recaptchaenterprise/v1/recaptchaenterprise-gen.go b/recaptchaenterprise/v1/recaptchaenterprise-gen.go index be7b6595899..c87461fd366 100644 --- a/recaptchaenterprise/v1/recaptchaenterprise-gen.go +++ b/recaptchaenterprise/v1/recaptchaenterprise-gen.go @@ -1417,7 +1417,7 @@ func (s *GoogleCloudRecaptchaenterpriseV1MigrateKeyRequest) MarshalJSON() ([]byt // Fraud type GoogleCloudRecaptchaenterpriseV1PhoneFraudAssessment struct { // SmsTollFraudVerdict: Output only. Assessment of this phone event for risk of - // sms toll fraud. + // SMS toll fraud. SmsTollFraudVerdict *GoogleCloudRecaptchaenterpriseV1SmsTollFraudVerdict `json:"smsTollFraudVerdict,omitempty"` // ForceSendFields is a list of field names (e.g. "SmsTollFraudVerdict") to // unconditionally include in API requests. By default, fields with empty or @@ -1778,8 +1778,8 @@ func (s *GoogleCloudRecaptchaenterpriseV1SearchRelatedAccountGroupMembershipsRes return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) } -// GoogleCloudRecaptchaenterpriseV1SmsTollFraudVerdict: Information about sms -// toll fraud +// GoogleCloudRecaptchaenterpriseV1SmsTollFraudVerdict: Information about SMS +// toll fraud. type GoogleCloudRecaptchaenterpriseV1SmsTollFraudVerdict struct { // Reasons: Output only. Reasons contributing to the SMS toll fraud verdict. // @@ -1787,7 +1787,7 @@ type GoogleCloudRecaptchaenterpriseV1SmsTollFraudVerdict struct { // "SMS_TOLL_FRAUD_REASON_UNSPECIFIED" - Default unspecified reason // "INVALID_PHONE_NUMBER" - The provided phone number was invalid Reasons []string `json:"reasons,omitempty"` - // Risk: Output only. Probability of an sms event being fraudulent. Values are + // Risk: Output only. Probability of an SMS event being fraudulent. Values are // from 0.0 (lowest) to 1.0 (highest). Risk float64 `json:"risk,omitempty"` // ForceSendFields is a list of field names (e.g. "Reasons") to unconditionally diff --git a/run/v1/run-api.json b/run/v1/run-api.json index 9cf351b40f0..e5abeeb9574 100644 --- a/run/v1/run-api.json +++ b/run/v1/run-api.json @@ -377,7 +377,7 @@ ] }, "list": { - "description": "List configurations.", + "description": "List configurations. Results are sorted by creation time, descending.", "flatPath": "apis/serving.knative.dev/v1/namespaces/{namespacesId}/configurations", "httpMethod": "GET", "id": "run.namespaces.configurations.list", @@ -703,7 +703,7 @@ ] }, "list": { - "description": "List executions.", + "description": "List executions. Results are sorted by creation time, descending.", "flatPath": "apis/run.googleapis.com/v1/namespaces/{namespacesId}/executions", "httpMethod": "GET", "id": "run.namespaces.executions.list", @@ -861,7 +861,7 @@ ] }, "list": { - "description": "List jobs.", + "description": "List jobs. Results are sorted by creation time, descending.", "flatPath": "apis/run.googleapis.com/v1/namespaces/{namespacesId}/jobs", "httpMethod": "GET", "id": "run.namespaces.jobs.list", @@ -1052,7 +1052,7 @@ ] }, "list": { - "description": "List revisions.", + "description": "List revisions. Results are sorted by creation time, descending.", "flatPath": "apis/serving.knative.dev/v1/namespaces/{namespacesId}/revisions", "httpMethod": "GET", "id": "run.namespaces.revisions.list", @@ -1142,7 +1142,7 @@ ] }, "list": { - "description": "List routes.", + "description": "List routes. Results are sorted by creation time, descending.", "flatPath": "apis/serving.knative.dev/v1/namespaces/{namespacesId}/routes", "httpMethod": "GET", "id": "run.namespaces.routes.list", @@ -1310,7 +1310,7 @@ ] }, "list": { - "description": "Lists services for the given project and region.", + "description": "Lists services for the given project and region. Results are sorted by creation time, descending.", "flatPath": "apis/serving.knative.dev/v1/namespaces/{namespacesId}/services", "httpMethod": "GET", "id": "run.namespaces.services.list", @@ -1652,7 +1652,7 @@ ] }, "list": { - "description": "List configurations.", + "description": "List configurations. Results are sorted by creation time, descending.", "flatPath": "v1/projects/{projectsId}/locations/{locationsId}/configurations", "httpMethod": "GET", "id": "run.projects.locations.configurations.list", @@ -2169,7 +2169,7 @@ ] }, "list": { - "description": "List revisions.", + "description": "List revisions. Results are sorted by creation time, descending.", "flatPath": "v1/projects/{projectsId}/locations/{locationsId}/revisions", "httpMethod": "GET", "id": "run.projects.locations.revisions.list", @@ -2259,7 +2259,7 @@ ] }, "list": { - "description": "List routes.", + "description": "List routes. Results are sorted by creation time, descending.", "flatPath": "v1/projects/{projectsId}/locations/{locationsId}/routes", "httpMethod": "GET", "id": "run.projects.locations.routes.list", @@ -2458,7 +2458,7 @@ ] }, "list": { - "description": "Lists services for the given project and region.", + "description": "Lists services for the given project and region. Results are sorted by creation time, descending.", "flatPath": "v1/projects/{projectsId}/locations/{locationsId}/services", "httpMethod": "GET", "id": "run.projects.locations.services.list", @@ -2614,7 +2614,7 @@ } } }, - "revision": "20240510", + "revision": "20240524", "rootUrl": "https://run.googleapis.com/", "schemas": { "Addressable": { @@ -3625,7 +3625,7 @@ }, "source": { "$ref": "GoogleDevtoolsCloudbuildV1Source", - "description": "The location of the source files to build." + "description": "Optional. The location of the source files to build." }, "sourceProvenance": { "$ref": "GoogleDevtoolsCloudbuildV1SourceProvenance", @@ -3785,7 +3785,7 @@ "type": "string" }, "diskSizeGb": { - "description": "Requested disk size for the VM that runs the build. Note that this is *NOT* \"disk free\"; some of the space will be used by the operating system and build utilities. Also note that this is the minimum disk size that will be allocated for the build -- the build may run with a larger disk than requested. At present, the maximum disk size is 2000GB; builds that request more than the maximum are rejected with an error.", + "description": "Requested disk size for the VM that runs the build. Note that this is *NOT* \"disk free\"; some of the space will be used by the operating system and build utilities. Also note that this is the minimum disk size that will be allocated for the build -- the build may run with a larger disk than requested. At present, the maximum disk size is 4000GB; builds that request more than the maximum are rejected with an error.", "format": "int64", "type": "string" }, @@ -4092,7 +4092,7 @@ "id": "GoogleDevtoolsCloudbuildV1ConnectedRepository", "properties": { "dir": { - "description": "Directory, relative to the source root, in which to run the build.", + "description": "Optional. Directory, relative to the source root, in which to run the build.", "type": "string" }, "repository": { @@ -4100,7 +4100,7 @@ "type": "string" }, "revision": { - "description": "The revision to fetch from the Git repository such as a branch, a tag, a commit SHA, or any Git ref.", + "description": "Required. The revision to fetch from the Git repository such as a branch, a tag, a commit SHA, or any Git ref.", "type": "string" } }, @@ -4208,15 +4208,15 @@ "id": "GoogleDevtoolsCloudbuildV1GitSource", "properties": { "dir": { - "description": "Directory, relative to the source root, in which to run the build. This must be a relative path. If a step's `dir` is specified and is an absolute path, this value is ignored for that step's execution.", + "description": "Optional. Directory, relative to the source root, in which to run the build. This must be a relative path. If a step's `dir` is specified and is an absolute path, this value is ignored for that step's execution.", "type": "string" }, "revision": { - "description": "The revision to fetch from the Git repository such as a branch, a tag, a commit SHA, or any Git ref. Cloud Build uses `git fetch` to fetch the revision from the Git repository; therefore make sure that the string you provide for `revision` is parsable by the command. For information on string values accepted by `git fetch`, see https://git-scm.com/docs/gitrevisions#_specifying_revisions. For information on `git fetch`, see https://git-scm.com/docs/git-fetch.", + "description": "Optional. The revision to fetch from the Git repository such as a branch, a tag, a commit SHA, or any Git ref. Cloud Build uses `git fetch` to fetch the revision from the Git repository; therefore make sure that the string you provide for `revision` is parsable by the command. For information on string values accepted by `git fetch`, see https://git-scm.com/docs/gitrevisions#_specifying_revisions. For information on `git fetch`, see https://git-scm.com/docs/git-fetch.", "type": "string" }, "url": { - "description": "Location of the Git repo to build. This will be used as a `git remote`, see https://git-scm.com/docs/git-remote.", + "description": "Required. Location of the Git repo to build. This will be used as a `git remote`, see https://git-scm.com/docs/git-remote.", "type": "string" } }, @@ -4368,26 +4368,26 @@ "type": "string" }, "dir": { - "description": "Directory, relative to the source root, in which to run the build. This must be a relative path. If a step's `dir` is specified and is an absolute path, this value is ignored for that step's execution.", + "description": "Optional. Directory, relative to the source root, in which to run the build. This must be a relative path. If a step's `dir` is specified and is an absolute path, this value is ignored for that step's execution.", "type": "string" }, "invertRegex": { - "description": "Only trigger a build if the revision regex does NOT match the revision regex.", + "description": "Optional. Only trigger a build if the revision regex does NOT match the revision regex.", "type": "boolean" }, "projectId": { - "description": "ID of the project that owns the Cloud Source Repository. If omitted, the project ID requesting the build is assumed.", + "description": "Optional. ID of the project that owns the Cloud Source Repository. If omitted, the project ID requesting the build is assumed.", "type": "string" }, "repoName": { - "description": "Name of the Cloud Source Repository.", + "description": "Required. Name of the Cloud Source Repository.", "type": "string" }, "substitutions": { "additionalProperties": { "type": "string" }, - "description": "Substitutions to use in a triggered build. Should only be used with RunBuildTrigger", + "description": "Optional. Substitutions to use in a triggered build. Should only be used with RunBuildTrigger", "type": "object" }, "tagName": { @@ -4592,12 +4592,12 @@ "type": "string" }, "generation": { - "description": "Cloud Storage generation for the object. If the generation is omitted, the latest generation will be used.", + "description": "Optional. Cloud Storage generation for the object. If the generation is omitted, the latest generation will be used.", "format": "int64", "type": "string" }, "object": { - "description": "Cloud Storage object containing the source. This object must be a zipped (`.zip`) or gzipped archive file (`.tar.gz`) containing source to build.", + "description": "Required. Cloud Storage object containing the source. This object must be a zipped (`.zip`) or gzipped archive file (`.tar.gz`) containing source to build.", "type": "string" }, "sourceFetcher": { @@ -4622,7 +4622,7 @@ "id": "GoogleDevtoolsCloudbuildV1StorageSourceManifest", "properties": { "bucket": { - "description": "Cloud Storage bucket containing the source manifest (see [Bucket Name Requirements](https://cloud.google.com/storage/docs/bucket-naming#requirements)).", + "description": "Required. Cloud Storage bucket containing the source manifest (see [Bucket Name Requirements](https://cloud.google.com/storage/docs/bucket-naming#requirements)).", "type": "string" }, "generation": { @@ -4631,7 +4631,7 @@ "type": "string" }, "object": { - "description": "Cloud Storage object containing the source manifest. This object must be a JSON file.", + "description": "Required. Cloud Storage object containing the source manifest. This object must be a JSON file.", "type": "string" } }, diff --git a/run/v1/run-gen.go b/run/v1/run-gen.go index 81d67a5f1cd..2561c7ae59e 100644 --- a/run/v1/run-gen.go +++ b/run/v1/run-gen.go @@ -1816,7 +1816,7 @@ type GoogleDevtoolsCloudbuildV1Build struct { // `projects/{PROJECT_ID}/serviceAccounts/{ACCOUNT}`. ACCOUNT can be email // address or uniqueId of the service account. ServiceAccount string `json:"serviceAccount,omitempty"` - // Source: The location of the source files to build. + // Source: Optional. The location of the source files to build. Source *GoogleDevtoolsCloudbuildV1Source `json:"source,omitempty"` // SourceProvenance: Output only. A permanent fixed identifier for source. SourceProvenance *GoogleDevtoolsCloudbuildV1SourceProvenance `json:"sourceProvenance,omitempty"` @@ -1955,7 +1955,7 @@ type GoogleDevtoolsCloudbuildV1BuildOptions struct { // this is *NOT* "disk free"; some of the space will be used by the operating // system and build utilities. Also note that this is the minimum disk size // that will be allocated for the build -- the build may run with a larger disk - // than requested. At present, the maximum disk size is 2000GB; builds that + // than requested. At present, the maximum disk size is 4000GB; builds that // request more than the maximum are rejected with an error. DiskSizeGb int64 `json:"diskSizeGb,omitempty,string"` // DynamicSubstitutions: Option to specify whether or not to apply bash style @@ -2214,13 +2214,14 @@ func (s *GoogleDevtoolsCloudbuildV1BuiltImage) MarshalJSON() ([]byte, error) { // GoogleDevtoolsCloudbuildV1ConnectedRepository: Location of the source in a // 2nd-gen Google Cloud Build repository resource. type GoogleDevtoolsCloudbuildV1ConnectedRepository struct { - // Dir: Directory, relative to the source root, in which to run the build. + // Dir: Optional. Directory, relative to the source root, in which to run the + // build. Dir string `json:"dir,omitempty"` // Repository: Required. Name of the Google Cloud Build repository, formatted // as `projects/*/locations/*/connections/*/repositories/*`. Repository string `json:"repository,omitempty"` - // Revision: The revision to fetch from the Git repository such as a branch, a - // tag, a commit SHA, or any Git ref. + // Revision: Required. The revision to fetch from the Git repository such as a + // branch, a tag, a commit SHA, or any Git ref. Revision string `json:"revision,omitempty"` // ForceSendFields is a list of field names (e.g. "Dir") to unconditionally // include in API requests. By default, fields with empty or default values are @@ -2384,20 +2385,20 @@ func (s *GoogleDevtoolsCloudbuildV1GitConfig) MarshalJSON() ([]byte, error) { // GoogleDevtoolsCloudbuildV1GitSource: Location of the source in any // accessible Git repository. type GoogleDevtoolsCloudbuildV1GitSource struct { - // Dir: Directory, relative to the source root, in which to run the build. This - // must be a relative path. If a step's `dir` is specified and is an absolute - // path, this value is ignored for that step's execution. + // Dir: Optional. Directory, relative to the source root, in which to run the + // build. This must be a relative path. If a step's `dir` is specified and is + // an absolute path, this value is ignored for that step's execution. Dir string `json:"dir,omitempty"` - // Revision: The revision to fetch from the Git repository such as a branch, a - // tag, a commit SHA, or any Git ref. Cloud Build uses `git fetch` to fetch the - // revision from the Git repository; therefore make sure that the string you - // provide for `revision` is parsable by the command. For information on string - // values accepted by `git fetch`, see + // Revision: Optional. The revision to fetch from the Git repository such as a + // branch, a tag, a commit SHA, or any Git ref. Cloud Build uses `git fetch` to + // fetch the revision from the Git repository; therefore make sure that the + // string you provide for `revision` is parsable by the command. For + // information on string values accepted by `git fetch`, see // https://git-scm.com/docs/gitrevisions#_specifying_revisions. For information // on `git fetch`, see https://git-scm.com/docs/git-fetch. Revision string `json:"revision,omitempty"` - // Url: Location of the Git repo to build. This will be used as a `git remote`, - // see https://git-scm.com/docs/git-remote. + // Url: Required. Location of the Git repo to build. This will be used as a + // `git remote`, see https://git-scm.com/docs/git-remote. Url string `json:"url,omitempty"` // ForceSendFields is a list of field names (e.g. "Dir") to unconditionally // include in API requests. By default, fields with empty or default values are @@ -2639,20 +2640,20 @@ type GoogleDevtoolsCloudbuildV1RepoSource struct { BranchName string `json:"branchName,omitempty"` // CommitSha: Explicit commit SHA to build. CommitSha string `json:"commitSha,omitempty"` - // Dir: Directory, relative to the source root, in which to run the build. This - // must be a relative path. If a step's `dir` is specified and is an absolute - // path, this value is ignored for that step's execution. + // Dir: Optional. Directory, relative to the source root, in which to run the + // build. This must be a relative path. If a step's `dir` is specified and is + // an absolute path, this value is ignored for that step's execution. Dir string `json:"dir,omitempty"` - // InvertRegex: Only trigger a build if the revision regex does NOT match the - // revision regex. + // InvertRegex: Optional. Only trigger a build if the revision regex does NOT + // match the revision regex. InvertRegex bool `json:"invertRegex,omitempty"` - // ProjectId: ID of the project that owns the Cloud Source Repository. If - // omitted, the project ID requesting the build is assumed. + // ProjectId: Optional. ID of the project that owns the Cloud Source + // Repository. If omitted, the project ID requesting the build is assumed. ProjectId string `json:"projectId,omitempty"` - // RepoName: Name of the Cloud Source Repository. + // RepoName: Required. Name of the Cloud Source Repository. RepoName string `json:"repoName,omitempty"` - // Substitutions: Substitutions to use in a triggered build. Should only be - // used with RunBuildTrigger + // Substitutions: Optional. Substitutions to use in a triggered build. Should + // only be used with RunBuildTrigger Substitutions map[string]string `json:"substitutions,omitempty"` // TagName: Regex matching tags to build. The syntax of the regular expressions // accepted is the syntax accepted by RE2 and described at @@ -2904,12 +2905,12 @@ type GoogleDevtoolsCloudbuildV1StorageSource struct { // Requirements // (https://cloud.google.com/storage/docs/bucket-naming#requirements)). Bucket string `json:"bucket,omitempty"` - // Generation: Cloud Storage generation for the object. If the generation is - // omitted, the latest generation will be used. + // Generation: Optional. Cloud Storage generation for the object. If the + // generation is omitted, the latest generation will be used. Generation int64 `json:"generation,omitempty,string"` - // Object: Cloud Storage object containing the source. This object must be a - // zipped (`.zip`) or gzipped archive file (`.tar.gz`) containing source to - // build. + // Object: Required. Cloud Storage object containing the source. This object + // must be a zipped (`.zip`) or gzipped archive file (`.tar.gz`) containing + // source to build. Object string `json:"object,omitempty"` // SourceFetcher: Optional. Option to specify the tool to fetch the source file // for the build. @@ -2942,15 +2943,15 @@ func (s *GoogleDevtoolsCloudbuildV1StorageSource) MarshalJSON() ([]byte, error) // manifest in Cloud Storage. This feature is in Preview; see description here // (https://github.com/GoogleCloudPlatform/cloud-builders/tree/master/gcs-fetcher). type GoogleDevtoolsCloudbuildV1StorageSourceManifest struct { - // Bucket: Cloud Storage bucket containing the source manifest (see Bucket Name - // Requirements + // Bucket: Required. Cloud Storage bucket containing the source manifest (see + // Bucket Name Requirements // (https://cloud.google.com/storage/docs/bucket-naming#requirements)). Bucket string `json:"bucket,omitempty"` // Generation: Cloud Storage generation for the object. If the generation is // omitted, the latest generation will be used. Generation int64 `json:"generation,omitempty,string"` - // Object: Cloud Storage object containing the source manifest. This object - // must be a JSON file. + // Object: Required. Cloud Storage object containing the source manifest. This + // object must be a JSON file. Object string `json:"object,omitempty"` // ForceSendFields is a list of field names (e.g. "Bucket") to unconditionally // include in API requests. By default, fields with empty or default values are @@ -5657,7 +5658,7 @@ type NamespacesConfigurationsListCall struct { header_ http.Header } -// List: List configurations. +// List: List configurations. Results are sorted by creation time, descending. // // - parent: The namespace from which the configurations should be listed. For // Cloud Run, replace {namespace_id} with the project ID or number. @@ -6660,7 +6661,7 @@ type NamespacesExecutionsListCall struct { header_ http.Header } -// List: List executions. +// List: List executions. Results are sorted by creation time, descending. // // - parent: The namespace from which the executions should be listed. Replace // {namespace} with the project ID or number. It takes the form @@ -7152,7 +7153,7 @@ type NamespacesJobsListCall struct { header_ http.Header } -// List: List jobs. +// List: List jobs. Results are sorted by creation time, descending. // // - parent: The namespace from which the jobs should be listed. Replace // {namespace} with the project ID or number. It takes the form @@ -7756,7 +7757,7 @@ type NamespacesRevisionsListCall struct { header_ http.Header } -// List: List revisions. +// List: List revisions. Results are sorted by creation time, descending. // // - parent: The namespace from which the revisions should be listed. For Cloud // Run (fully managed), replace {namespace} with the project ID or number. It @@ -8029,7 +8030,7 @@ type NamespacesRoutesListCall struct { header_ http.Header } -// List: List routes. +// List: List routes. Results are sorted by creation time, descending. // // - parent: The namespace from which the routes should be listed. For Cloud // Run (fully managed), replace {namespace} with the project ID or number. It @@ -8553,7 +8554,8 @@ type NamespacesServicesListCall struct { header_ http.Header } -// List: Lists services for the given project and region. +// List: Lists services for the given project and region. Results are sorted by +// creation time, descending. // // - parent: The parent from where the resources should be listed. In Cloud // Run, it may be one of the following: * `{project_id_or_number}` * @@ -9664,7 +9666,7 @@ type ProjectsLocationsConfigurationsListCall struct { header_ http.Header } -// List: List configurations. +// List: List configurations. Results are sorted by creation time, descending. // // - parent: The namespace from which the configurations should be listed. For // Cloud Run, replace {namespace_id} with the project ID or number. @@ -11383,7 +11385,7 @@ type ProjectsLocationsRevisionsListCall struct { header_ http.Header } -// List: List revisions. +// List: List revisions. Results are sorted by creation time, descending. // // - parent: The namespace from which the revisions should be listed. For Cloud // Run (fully managed), replace {namespace} with the project ID or number. It @@ -11656,7 +11658,7 @@ type ProjectsLocationsRoutesListCall struct { header_ http.Header } -// List: List routes. +// List: List routes. Results are sorted by creation time, descending. // // - parent: The namespace from which the routes should be listed. For Cloud // Run (fully managed), replace {namespace} with the project ID or number. It @@ -12308,7 +12310,8 @@ type ProjectsLocationsServicesListCall struct { header_ http.Header } -// List: Lists services for the given project and region. +// List: Lists services for the given project and region. Results are sorted by +// creation time, descending. // // - parent: The parent from where the resources should be listed. In Cloud // Run, it may be one of the following: * `{project_id_or_number}` * diff --git a/run/v2/run-api.json b/run/v2/run-api.json index ac0f248c9ef..f97aa68c862 100644 --- a/run/v2/run-api.json +++ b/run/v2/run-api.json @@ -523,7 +523,7 @@ ] }, "list": { - "description": "Lists Jobs.", + "description": "Lists Jobs. Results are sorted by creation time, descending.", "flatPath": "v2/projects/{projectsId}/locations/{locationsId}/jobs", "httpMethod": "GET", "id": "run.projects.locations.jobs.list", @@ -811,7 +811,7 @@ ] }, "list": { - "description": "Lists Executions from a Job.", + "description": "Lists Executions from a Job. Results are sorted by creation time, descending.", "flatPath": "v2/projects/{projectsId}/locations/{locationsId}/jobs/{jobsId}/executions", "httpMethod": "GET", "id": "run.projects.locations.jobs.executions.list", @@ -1182,7 +1182,7 @@ ] }, "list": { - "description": "Lists Services.", + "description": "Lists Services. Results are sorted by creation time, descending.", "flatPath": "v2/projects/{projectsId}/locations/{locationsId}/services", "httpMethod": "GET", "id": "run.projects.locations.services.list", @@ -1420,7 +1420,7 @@ ] }, "list": { - "description": "Lists Revisions from a given Service, or from a given location.", + "description": "Lists Revisions from a given Service, or from a given location. Results are sorted by creation time, descending.", "flatPath": "v2/projects/{projectsId}/locations/{locationsId}/services/{servicesId}/revisions", "httpMethod": "GET", "id": "run.projects.locations.services.revisions.list", @@ -1469,7 +1469,7 @@ } } }, - "revision": "20240510", + "revision": "20240524", "rootUrl": "https://run.googleapis.com/", "schemas": { "GoogleCloudRunV2BinaryAuthorization": { @@ -2366,6 +2366,10 @@ "readOnly": true, "type": "boolean" }, + "runExecutionToken": { + "description": "A unique string used as a suffix for creating a new execution. The Job will become ready when the execution is successfully completed. The sum of job name and token length must be fewer than 63 characters.", + "type": "string" + }, "satisfiesPzs": { "description": "Output only. Reserved for future use.", "readOnly": true, @@ -3913,7 +3917,7 @@ }, "source": { "$ref": "GoogleDevtoolsCloudbuildV1Source", - "description": "The location of the source files to build." + "description": "Optional. The location of the source files to build." }, "sourceProvenance": { "$ref": "GoogleDevtoolsCloudbuildV1SourceProvenance", @@ -4073,7 +4077,7 @@ "type": "string" }, "diskSizeGb": { - "description": "Requested disk size for the VM that runs the build. Note that this is *NOT* \"disk free\"; some of the space will be used by the operating system and build utilities. Also note that this is the minimum disk size that will be allocated for the build -- the build may run with a larger disk than requested. At present, the maximum disk size is 2000GB; builds that request more than the maximum are rejected with an error.", + "description": "Requested disk size for the VM that runs the build. Note that this is *NOT* \"disk free\"; some of the space will be used by the operating system and build utilities. Also note that this is the minimum disk size that will be allocated for the build -- the build may run with a larger disk than requested. At present, the maximum disk size is 4000GB; builds that request more than the maximum are rejected with an error.", "format": "int64", "type": "string" }, @@ -4380,7 +4384,7 @@ "id": "GoogleDevtoolsCloudbuildV1ConnectedRepository", "properties": { "dir": { - "description": "Directory, relative to the source root, in which to run the build.", + "description": "Optional. Directory, relative to the source root, in which to run the build.", "type": "string" }, "repository": { @@ -4388,7 +4392,7 @@ "type": "string" }, "revision": { - "description": "The revision to fetch from the Git repository such as a branch, a tag, a commit SHA, or any Git ref.", + "description": "Required. The revision to fetch from the Git repository such as a branch, a tag, a commit SHA, or any Git ref.", "type": "string" } }, @@ -4496,15 +4500,15 @@ "id": "GoogleDevtoolsCloudbuildV1GitSource", "properties": { "dir": { - "description": "Directory, relative to the source root, in which to run the build. This must be a relative path. If a step's `dir` is specified and is an absolute path, this value is ignored for that step's execution.", + "description": "Optional. Directory, relative to the source root, in which to run the build. This must be a relative path. If a step's `dir` is specified and is an absolute path, this value is ignored for that step's execution.", "type": "string" }, "revision": { - "description": "The revision to fetch from the Git repository such as a branch, a tag, a commit SHA, or any Git ref. Cloud Build uses `git fetch` to fetch the revision from the Git repository; therefore make sure that the string you provide for `revision` is parsable by the command. For information on string values accepted by `git fetch`, see https://git-scm.com/docs/gitrevisions#_specifying_revisions. For information on `git fetch`, see https://git-scm.com/docs/git-fetch.", + "description": "Optional. The revision to fetch from the Git repository such as a branch, a tag, a commit SHA, or any Git ref. Cloud Build uses `git fetch` to fetch the revision from the Git repository; therefore make sure that the string you provide for `revision` is parsable by the command. For information on string values accepted by `git fetch`, see https://git-scm.com/docs/gitrevisions#_specifying_revisions. For information on `git fetch`, see https://git-scm.com/docs/git-fetch.", "type": "string" }, "url": { - "description": "Location of the Git repo to build. This will be used as a `git remote`, see https://git-scm.com/docs/git-remote.", + "description": "Required. Location of the Git repo to build. This will be used as a `git remote`, see https://git-scm.com/docs/git-remote.", "type": "string" } }, @@ -4656,26 +4660,26 @@ "type": "string" }, "dir": { - "description": "Directory, relative to the source root, in which to run the build. This must be a relative path. If a step's `dir` is specified and is an absolute path, this value is ignored for that step's execution.", + "description": "Optional. Directory, relative to the source root, in which to run the build. This must be a relative path. If a step's `dir` is specified and is an absolute path, this value is ignored for that step's execution.", "type": "string" }, "invertRegex": { - "description": "Only trigger a build if the revision regex does NOT match the revision regex.", + "description": "Optional. Only trigger a build if the revision regex does NOT match the revision regex.", "type": "boolean" }, "projectId": { - "description": "ID of the project that owns the Cloud Source Repository. If omitted, the project ID requesting the build is assumed.", + "description": "Optional. ID of the project that owns the Cloud Source Repository. If omitted, the project ID requesting the build is assumed.", "type": "string" }, "repoName": { - "description": "Name of the Cloud Source Repository.", + "description": "Required. Name of the Cloud Source Repository.", "type": "string" }, "substitutions": { "additionalProperties": { "type": "string" }, - "description": "Substitutions to use in a triggered build. Should only be used with RunBuildTrigger", + "description": "Optional. Substitutions to use in a triggered build. Should only be used with RunBuildTrigger", "type": "object" }, "tagName": { @@ -4880,12 +4884,12 @@ "type": "string" }, "generation": { - "description": "Cloud Storage generation for the object. If the generation is omitted, the latest generation will be used.", + "description": "Optional. Cloud Storage generation for the object. If the generation is omitted, the latest generation will be used.", "format": "int64", "type": "string" }, "object": { - "description": "Cloud Storage object containing the source. This object must be a zipped (`.zip`) or gzipped archive file (`.tar.gz`) containing source to build.", + "description": "Required. Cloud Storage object containing the source. This object must be a zipped (`.zip`) or gzipped archive file (`.tar.gz`) containing source to build.", "type": "string" }, "sourceFetcher": { @@ -4910,7 +4914,7 @@ "id": "GoogleDevtoolsCloudbuildV1StorageSourceManifest", "properties": { "bucket": { - "description": "Cloud Storage bucket containing the source manifest (see [Bucket Name Requirements](https://cloud.google.com/storage/docs/bucket-naming#requirements)).", + "description": "Required. Cloud Storage bucket containing the source manifest (see [Bucket Name Requirements](https://cloud.google.com/storage/docs/bucket-naming#requirements)).", "type": "string" }, "generation": { @@ -4919,7 +4923,7 @@ "type": "string" }, "object": { - "description": "Cloud Storage object containing the source manifest. This object must be a JSON file.", + "description": "Required. Cloud Storage object containing the source manifest. This object must be a JSON file.", "type": "string" } }, diff --git a/run/v2/run-gen.go b/run/v2/run-gen.go index 75ed32a55ae..57a8c7798b0 100644 --- a/run/v2/run-gen.go +++ b/run/v2/run-gen.go @@ -1252,6 +1252,11 @@ type GoogleCloudRunV2Job struct { // 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"` + // RunExecutionToken: A unique string used as a suffix for creating a new + // execution. The Job will become ready when the execution is successfully + // completed. The sum of job name and token length must be fewer than 63 + // characters. + RunExecutionToken string `json:"runExecutionToken,omitempty"` // SatisfiesPzs: Output only. Reserved for future use. SatisfiesPzs bool `json:"satisfiesPzs,omitempty"` // StartExecutionToken: A unique string used as a suffix creating a new @@ -2990,7 +2995,7 @@ type GoogleDevtoolsCloudbuildV1Build struct { // `projects/{PROJECT_ID}/serviceAccounts/{ACCOUNT}`. ACCOUNT can be email // address or uniqueId of the service account. ServiceAccount string `json:"serviceAccount,omitempty"` - // Source: The location of the source files to build. + // Source: Optional. The location of the source files to build. Source *GoogleDevtoolsCloudbuildV1Source `json:"source,omitempty"` // SourceProvenance: Output only. A permanent fixed identifier for source. SourceProvenance *GoogleDevtoolsCloudbuildV1SourceProvenance `json:"sourceProvenance,omitempty"` @@ -3129,7 +3134,7 @@ type GoogleDevtoolsCloudbuildV1BuildOptions struct { // this is *NOT* "disk free"; some of the space will be used by the operating // system and build utilities. Also note that this is the minimum disk size // that will be allocated for the build -- the build may run with a larger disk - // than requested. At present, the maximum disk size is 2000GB; builds that + // than requested. At present, the maximum disk size is 4000GB; builds that // request more than the maximum are rejected with an error. DiskSizeGb int64 `json:"diskSizeGb,omitempty,string"` // DynamicSubstitutions: Option to specify whether or not to apply bash style @@ -3388,13 +3393,14 @@ func (s *GoogleDevtoolsCloudbuildV1BuiltImage) MarshalJSON() ([]byte, error) { // GoogleDevtoolsCloudbuildV1ConnectedRepository: Location of the source in a // 2nd-gen Google Cloud Build repository resource. type GoogleDevtoolsCloudbuildV1ConnectedRepository struct { - // Dir: Directory, relative to the source root, in which to run the build. + // Dir: Optional. Directory, relative to the source root, in which to run the + // build. Dir string `json:"dir,omitempty"` // Repository: Required. Name of the Google Cloud Build repository, formatted // as `projects/*/locations/*/connections/*/repositories/*`. Repository string `json:"repository,omitempty"` - // Revision: The revision to fetch from the Git repository such as a branch, a - // tag, a commit SHA, or any Git ref. + // Revision: Required. The revision to fetch from the Git repository such as a + // branch, a tag, a commit SHA, or any Git ref. Revision string `json:"revision,omitempty"` // ForceSendFields is a list of field names (e.g. "Dir") to unconditionally // include in API requests. By default, fields with empty or default values are @@ -3558,20 +3564,20 @@ func (s *GoogleDevtoolsCloudbuildV1GitConfig) MarshalJSON() ([]byte, error) { // GoogleDevtoolsCloudbuildV1GitSource: Location of the source in any // accessible Git repository. type GoogleDevtoolsCloudbuildV1GitSource struct { - // Dir: Directory, relative to the source root, in which to run the build. This - // must be a relative path. If a step's `dir` is specified and is an absolute - // path, this value is ignored for that step's execution. + // Dir: Optional. Directory, relative to the source root, in which to run the + // build. This must be a relative path. If a step's `dir` is specified and is + // an absolute path, this value is ignored for that step's execution. Dir string `json:"dir,omitempty"` - // Revision: The revision to fetch from the Git repository such as a branch, a - // tag, a commit SHA, or any Git ref. Cloud Build uses `git fetch` to fetch the - // revision from the Git repository; therefore make sure that the string you - // provide for `revision` is parsable by the command. For information on string - // values accepted by `git fetch`, see + // Revision: Optional. The revision to fetch from the Git repository such as a + // branch, a tag, a commit SHA, or any Git ref. Cloud Build uses `git fetch` to + // fetch the revision from the Git repository; therefore make sure that the + // string you provide for `revision` is parsable by the command. For + // information on string values accepted by `git fetch`, see // https://git-scm.com/docs/gitrevisions#_specifying_revisions. For information // on `git fetch`, see https://git-scm.com/docs/git-fetch. Revision string `json:"revision,omitempty"` - // Url: Location of the Git repo to build. This will be used as a `git remote`, - // see https://git-scm.com/docs/git-remote. + // Url: Required. Location of the Git repo to build. This will be used as a + // `git remote`, see https://git-scm.com/docs/git-remote. Url string `json:"url,omitempty"` // ForceSendFields is a list of field names (e.g. "Dir") to unconditionally // include in API requests. By default, fields with empty or default values are @@ -3813,20 +3819,20 @@ type GoogleDevtoolsCloudbuildV1RepoSource struct { BranchName string `json:"branchName,omitempty"` // CommitSha: Explicit commit SHA to build. CommitSha string `json:"commitSha,omitempty"` - // Dir: Directory, relative to the source root, in which to run the build. This - // must be a relative path. If a step's `dir` is specified and is an absolute - // path, this value is ignored for that step's execution. + // Dir: Optional. Directory, relative to the source root, in which to run the + // build. This must be a relative path. If a step's `dir` is specified and is + // an absolute path, this value is ignored for that step's execution. Dir string `json:"dir,omitempty"` - // InvertRegex: Only trigger a build if the revision regex does NOT match the - // revision regex. + // InvertRegex: Optional. Only trigger a build if the revision regex does NOT + // match the revision regex. InvertRegex bool `json:"invertRegex,omitempty"` - // ProjectId: ID of the project that owns the Cloud Source Repository. If - // omitted, the project ID requesting the build is assumed. + // ProjectId: Optional. ID of the project that owns the Cloud Source + // Repository. If omitted, the project ID requesting the build is assumed. ProjectId string `json:"projectId,omitempty"` - // RepoName: Name of the Cloud Source Repository. + // RepoName: Required. Name of the Cloud Source Repository. RepoName string `json:"repoName,omitempty"` - // Substitutions: Substitutions to use in a triggered build. Should only be - // used with RunBuildTrigger + // Substitutions: Optional. Substitutions to use in a triggered build. Should + // only be used with RunBuildTrigger Substitutions map[string]string `json:"substitutions,omitempty"` // TagName: Regex matching tags to build. The syntax of the regular expressions // accepted is the syntax accepted by RE2 and described at @@ -4078,12 +4084,12 @@ type GoogleDevtoolsCloudbuildV1StorageSource struct { // Requirements // (https://cloud.google.com/storage/docs/bucket-naming#requirements)). Bucket string `json:"bucket,omitempty"` - // Generation: Cloud Storage generation for the object. If the generation is - // omitted, the latest generation will be used. + // Generation: Optional. Cloud Storage generation for the object. If the + // generation is omitted, the latest generation will be used. Generation int64 `json:"generation,omitempty,string"` - // Object: Cloud Storage object containing the source. This object must be a - // zipped (`.zip`) or gzipped archive file (`.tar.gz`) containing source to - // build. + // Object: Required. Cloud Storage object containing the source. This object + // must be a zipped (`.zip`) or gzipped archive file (`.tar.gz`) containing + // source to build. Object string `json:"object,omitempty"` // SourceFetcher: Optional. Option to specify the tool to fetch the source file // for the build. @@ -4116,15 +4122,15 @@ func (s *GoogleDevtoolsCloudbuildV1StorageSource) MarshalJSON() ([]byte, error) // manifest in Cloud Storage. This feature is in Preview; see description here // (https://github.com/GoogleCloudPlatform/cloud-builders/tree/master/gcs-fetcher). type GoogleDevtoolsCloudbuildV1StorageSourceManifest struct { - // Bucket: Cloud Storage bucket containing the source manifest (see Bucket Name - // Requirements + // Bucket: Required. Cloud Storage bucket containing the source manifest (see + // Bucket Name Requirements // (https://cloud.google.com/storage/docs/bucket-naming#requirements)). Bucket string `json:"bucket,omitempty"` // Generation: Cloud Storage generation for the object. If the generation is // omitted, the latest generation will be used. Generation int64 `json:"generation,omitempty,string"` - // Object: Cloud Storage object containing the source manifest. This object - // must be a JSON file. + // Object: Required. Cloud Storage object containing the source manifest. This + // object must be a JSON file. Object string `json:"object,omitempty"` // ForceSendFields is a list of field names (e.g. "Bucket") to unconditionally // include in API requests. By default, fields with empty or default values are @@ -5709,7 +5715,7 @@ type ProjectsLocationsJobsListCall struct { header_ http.Header } -// List: Lists Jobs. +// List: Lists Jobs. Results are sorted by creation time, descending. // // - parent: The location and project to list resources on. Format: // projects/{project}/locations/{location}, where {project} can be project id @@ -6739,7 +6745,8 @@ type ProjectsLocationsJobsExecutionsListCall struct { header_ http.Header } -// List: Lists Executions from a Job. +// List: Lists Executions from a Job. Results are sorted by creation time, +// descending. // // - parent: The Execution from which the Executions should be listed. To list // all Executions across Jobs, use "-" instead of Job name. Format: @@ -8103,7 +8110,7 @@ type ProjectsLocationsServicesListCall struct { header_ http.Header } -// List: Lists Services. +// List: Lists Services. Results are sorted by creation time, descending. // // - parent: The location and project to list resources on. Location must be a // valid Google Cloud region, and cannot be the "-" wildcard. Format: @@ -8937,6 +8944,7 @@ type ProjectsLocationsServicesRevisionsListCall struct { } // List: Lists Revisions from a given Service, or from a given location. +// Results are sorted by creation time, descending. // // - parent: The Service from which the Revisions should be listed. To list all // Revisions across Services, use "-" instead of Service name. Format: diff --git a/secretmanager/v1/secretmanager-api.json b/secretmanager/v1/secretmanager-api.json index 0ec29ab1a51..27c0df5184c 100644 --- a/secretmanager/v1/secretmanager-api.json +++ b/secretmanager/v1/secretmanager-api.json @@ -35,6 +35,61 @@ "description": "Regional Endpoint", "endpointUrl": "https://secretmanager.us-east1.rep.googleapis.com/", "location": "us-east1" + }, + { + "description": "Regional Endpoint", + "endpointUrl": "https://secretmanager.us-central2.rep.googleapis.com/", + "location": "us-central2" + }, + { + "description": "Regional Endpoint", + "endpointUrl": "https://secretmanager.us-west1.rep.googleapis.com/", + "location": "us-west1" + }, + { + "description": "Regional Endpoint", + "endpointUrl": "https://secretmanager.us-west2.rep.googleapis.com/", + "location": "us-west2" + }, + { + "description": "Regional Endpoint", + "endpointUrl": "https://secretmanager.us-west3.rep.googleapis.com/", + "location": "us-west3" + }, + { + "description": "Regional Endpoint", + "endpointUrl": "https://secretmanager.us-west4.rep.googleapis.com/", + "location": "us-west4" + }, + { + "description": "Regional Endpoint", + "endpointUrl": "https://secretmanager.us-east4.rep.googleapis.com/", + "location": "us-east4" + }, + { + "description": "Regional Endpoint", + "endpointUrl": "https://secretmanager.us-east5.rep.googleapis.com/", + "location": "us-east5" + }, + { + "description": "Regional Endpoint", + "endpointUrl": "https://secretmanager.us-south1.rep.googleapis.com/", + "location": "us-south1" + }, + { + "description": "Regional Endpoint", + "endpointUrl": "https://secretmanager.europe-west3.rep.googleapis.com/", + "location": "europe-west3" + }, + { + "description": "Regional Endpoint", + "endpointUrl": "https://secretmanager.europe-west8.rep.googleapis.com/", + "location": "europe-west8" + }, + { + "description": "Regional Endpoint", + "endpointUrl": "https://secretmanager.europe-west9.rep.googleapis.com/", + "location": "europe-west9" } ], "fullyEncodeReservedExpansion": true, @@ -1130,7 +1185,7 @@ } } }, - "revision": "20240523", + "revision": "20240527", "rootUrl": "https://secretmanager.googleapis.com/", "schemas": { "AccessSecretVersionResponse": { diff --git a/secretmanager/v1beta1/secretmanager-api.json b/secretmanager/v1beta1/secretmanager-api.json index 4c8a82ba682..f9e0ffafe03 100644 --- a/secretmanager/v1beta1/secretmanager-api.json +++ b/secretmanager/v1beta1/secretmanager-api.json @@ -35,6 +35,61 @@ "description": "Regional Endpoint", "endpointUrl": "https://secretmanager.us-east1.rep.googleapis.com/", "location": "us-east1" + }, + { + "description": "Regional Endpoint", + "endpointUrl": "https://secretmanager.us-central2.rep.googleapis.com/", + "location": "us-central2" + }, + { + "description": "Regional Endpoint", + "endpointUrl": "https://secretmanager.us-west1.rep.googleapis.com/", + "location": "us-west1" + }, + { + "description": "Regional Endpoint", + "endpointUrl": "https://secretmanager.us-west2.rep.googleapis.com/", + "location": "us-west2" + }, + { + "description": "Regional Endpoint", + "endpointUrl": "https://secretmanager.us-west3.rep.googleapis.com/", + "location": "us-west3" + }, + { + "description": "Regional Endpoint", + "endpointUrl": "https://secretmanager.us-west4.rep.googleapis.com/", + "location": "us-west4" + }, + { + "description": "Regional Endpoint", + "endpointUrl": "https://secretmanager.us-east4.rep.googleapis.com/", + "location": "us-east4" + }, + { + "description": "Regional Endpoint", + "endpointUrl": "https://secretmanager.us-east5.rep.googleapis.com/", + "location": "us-east5" + }, + { + "description": "Regional Endpoint", + "endpointUrl": "https://secretmanager.us-south1.rep.googleapis.com/", + "location": "us-south1" + }, + { + "description": "Regional Endpoint", + "endpointUrl": "https://secretmanager.europe-west3.rep.googleapis.com/", + "location": "europe-west3" + }, + { + "description": "Regional Endpoint", + "endpointUrl": "https://secretmanager.europe-west8.rep.googleapis.com/", + "location": "europe-west8" + }, + { + "description": "Regional Endpoint", + "endpointUrl": "https://secretmanager.europe-west9.rep.googleapis.com/", + "location": "europe-west9" } ], "fullyEncodeReservedExpansion": true, @@ -650,7 +705,7 @@ } } }, - "revision": "20240523", + "revision": "20240527", "rootUrl": "https://secretmanager.googleapis.com/", "schemas": { "AccessSecretVersionResponse": { diff --git a/secretmanager/v1beta2/secretmanager-api.json b/secretmanager/v1beta2/secretmanager-api.json index 046976ad2a5..9d984d8650f 100644 --- a/secretmanager/v1beta2/secretmanager-api.json +++ b/secretmanager/v1beta2/secretmanager-api.json @@ -35,6 +35,61 @@ "description": "Regional Endpoint", "endpointUrl": "https://secretmanager.us-east1.rep.googleapis.com/", "location": "us-east1" + }, + { + "description": "Regional Endpoint", + "endpointUrl": "https://secretmanager.us-central2.rep.googleapis.com/", + "location": "us-central2" + }, + { + "description": "Regional Endpoint", + "endpointUrl": "https://secretmanager.us-west1.rep.googleapis.com/", + "location": "us-west1" + }, + { + "description": "Regional Endpoint", + "endpointUrl": "https://secretmanager.us-west2.rep.googleapis.com/", + "location": "us-west2" + }, + { + "description": "Regional Endpoint", + "endpointUrl": "https://secretmanager.us-west3.rep.googleapis.com/", + "location": "us-west3" + }, + { + "description": "Regional Endpoint", + "endpointUrl": "https://secretmanager.us-west4.rep.googleapis.com/", + "location": "us-west4" + }, + { + "description": "Regional Endpoint", + "endpointUrl": "https://secretmanager.us-east4.rep.googleapis.com/", + "location": "us-east4" + }, + { + "description": "Regional Endpoint", + "endpointUrl": "https://secretmanager.us-east5.rep.googleapis.com/", + "location": "us-east5" + }, + { + "description": "Regional Endpoint", + "endpointUrl": "https://secretmanager.us-south1.rep.googleapis.com/", + "location": "us-south1" + }, + { + "description": "Regional Endpoint", + "endpointUrl": "https://secretmanager.europe-west3.rep.googleapis.com/", + "location": "europe-west3" + }, + { + "description": "Regional Endpoint", + "endpointUrl": "https://secretmanager.europe-west8.rep.googleapis.com/", + "location": "europe-west8" + }, + { + "description": "Regional Endpoint", + "endpointUrl": "https://secretmanager.europe-west9.rep.googleapis.com/", + "location": "europe-west9" } ], "fullyEncodeReservedExpansion": true, @@ -1130,7 +1185,7 @@ } } }, - "revision": "20240523", + "revision": "20240527", "rootUrl": "https://secretmanager.googleapis.com/", "schemas": { "AccessSecretVersionResponse": { diff --git a/servicenetworking/v1/servicenetworking-api.json b/servicenetworking/v1/servicenetworking-api.json index 520b8639ddf..48f90c298c1 100644 --- a/servicenetworking/v1/servicenetworking-api.json +++ b/servicenetworking/v1/servicenetworking-api.json @@ -1029,7 +1029,7 @@ } } }, - "revision": "20240519", + "revision": "20240529", "rootUrl": "https://servicenetworking.googleapis.com/", "schemas": { "AddDnsRecordSetMetadata": { @@ -2421,7 +2421,7 @@ "type": "object" }, "HttpRule": { - "description": "# gRPC Transcoding gRPC Transcoding is a feature for mapping between a gRPC method and one or more HTTP REST endpoints. It allows developers to build a single API service that supports both gRPC APIs and REST APIs. Many systems, including [Google APIs](https://github.com/googleapis/googleapis), [Cloud Endpoints](https://cloud.google.com/endpoints), [gRPC Gateway](https://github.com/grpc-ecosystem/grpc-gateway), and [Envoy](https://github.com/envoyproxy/envoy) proxy support this feature and use it for large scale production services. `HttpRule` defines the schema of the gRPC/REST mapping. The mapping specifies how different portions of the gRPC request message are mapped to the URL path, URL query parameters, and HTTP request body. It also controls how the gRPC response message is mapped to the HTTP response body. `HttpRule` is typically specified as an `google.api.http` annotation on the gRPC method. Each mapping specifies a URL path template and an HTTP method. The path template may refer to one or more fields in the gRPC request message, as long as each field is a non-repeated field with a primitive (non-message) type. The path template controls how fields of the request message are mapped to the URL path. Example: service Messaging { rpc GetMessage(GetMessageRequest) returns (Message) { option (google.api.http) = { get: \"/v1/{name=messages/*}\" }; } } message GetMessageRequest { string name = 1; // Mapped to URL path. } message Message { string text = 1; // The resource content. } This enables an HTTP REST to gRPC mapping as below: HTTP | gRPC -----|----- `GET /v1/messages/123456` | `GetMessage(name: \"messages/123456\")` Any fields in the request message which are not bound by the path template automatically become HTTP query parameters if there is no HTTP request body. For example: service Messaging { rpc GetMessage(GetMessageRequest) returns (Message) { option (google.api.http) = { get:\"/v1/messages/{message_id}\" }; } } message GetMessageRequest { message SubMessage { string subfield = 1; } string message_id = 1; // Mapped to URL path. int64 revision = 2; // Mapped to URL query parameter `revision`. SubMessage sub = 3; // Mapped to URL query parameter `sub.subfield`. } This enables a HTTP JSON to RPC mapping as below: HTTP | gRPC -----|----- `GET /v1/messages/123456?revision=2\u0026sub.subfield=foo` | `GetMessage(message_id: \"123456\" revision: 2 sub: SubMessage(subfield: \"foo\"))` Note that fields which are mapped to URL query parameters must have a primitive type or a repeated primitive type or a non-repeated message type. In the case of a repeated type, the parameter can be repeated in the URL as `...?param=A\u0026param=B`. In the case of a message type, each field of the message is mapped to a separate parameter, such as `...?foo.a=A\u0026foo.b=B\u0026foo.c=C`. For HTTP methods that allow a request body, the `body` field specifies the mapping. Consider a REST update method on the message resource collection: service Messaging { rpc UpdateMessage(UpdateMessageRequest) returns (Message) { option (google.api.http) = { patch: \"/v1/messages/{message_id}\" body: \"message\" }; } } message UpdateMessageRequest { string message_id = 1; // mapped to the URL Message message = 2; // mapped to the body } The following HTTP JSON to RPC mapping is enabled, where the representation of the JSON in the request body is determined by protos JSON encoding: HTTP | gRPC -----|----- `PATCH /v1/messages/123456 { \"text\": \"Hi!\" }` | `UpdateMessage(message_id: \"123456\" message { text: \"Hi!\" })` The special name `*` can be used in the body mapping to define that every field not bound by the path template should be mapped to the request body. This enables the following alternative definition of the update method: service Messaging { rpc UpdateMessage(Message) returns (Message) { option (google.api.http) = { patch: \"/v1/messages/{message_id}\" body: \"*\" }; } } message Message { string message_id = 1; string text = 2; } The following HTTP JSON to RPC mapping is enabled: HTTP | gRPC -----|----- `PATCH /v1/messages/123456 { \"text\": \"Hi!\" }` | `UpdateMessage(message_id: \"123456\" text: \"Hi!\")` Note that when using `*` in the body mapping, it is not possible to have HTTP parameters, as all fields not bound by the path end in the body. This makes this option more rarely used in practice when defining REST APIs. The common usage of `*` is in custom methods which don't use the URL at all for transferring data. It is possible to define multiple HTTP methods for one RPC by using the `additional_bindings` option. Example: service Messaging { rpc GetMessage(GetMessageRequest) returns (Message) { option (google.api.http) = { get: \"/v1/messages/{message_id}\" additional_bindings { get: \"/v1/users/{user_id}/messages/{message_id}\" } }; } } message GetMessageRequest { string message_id = 1; string user_id = 2; } This enables the following two alternative HTTP JSON to RPC mappings: HTTP | gRPC -----|----- `GET /v1/messages/123456` | `GetMessage(message_id: \"123456\")` `GET /v1/users/me/messages/123456` | `GetMessage(user_id: \"me\" message_id: \"123456\")` ## Rules for HTTP mapping 1. Leaf request fields (recursive expansion nested messages in the request message) are classified into three categories: - Fields referred by the path template. They are passed via the URL path. - Fields referred by the HttpRule.body. They are passed via the HTTP request body. - All other fields are passed via the URL query parameters, and the parameter name is the field path in the request message. A repeated field can be represented as multiple query parameters under the same name. 2. If HttpRule.body is \"*\", there is no URL query parameter, all fields are passed via URL path and HTTP request body. 3. If HttpRule.body is omitted, there is no HTTP request body, all fields are passed via URL path and URL query parameters. ### Path template syntax Template = \"/\" Segments [ Verb ] ; Segments = Segment { \"/\" Segment } ; Segment = \"*\" | \"**\" | LITERAL | Variable ; Variable = \"{\" FieldPath [ \"=\" Segments ] \"}\" ; FieldPath = IDENT { \".\" IDENT } ; Verb = \":\" LITERAL ; The syntax `*` matches a single URL path segment. The syntax `**` matches zero or more URL path segments, which must be the last part of the URL path except the `Verb`. The syntax `Variable` matches part of the URL path as specified by its template. A variable template must not contain other variables. If a variable matches a single path segment, its template may be omitted, e.g. `{var}` is equivalent to `{var=*}`. The syntax `LITERAL` matches literal text in the URL path. If the `LITERAL` contains any reserved character, such characters should be percent-encoded before the matching. If a variable contains exactly one path segment, such as `\"{var}\"` or `\"{var=*}\"`, when such a variable is expanded into a URL path on the client side, all characters except `[-_.~0-9a-zA-Z]` are percent-encoded. The server side does the reverse decoding. Such variables show up in the [Discovery Document](https://developers.google.com/discovery/v1/reference/apis) as `{var}`. If a variable contains multiple path segments, such as `\"{var=foo/*}\"` or `\"{var=**}\"`, when such a variable is expanded into a URL path on the client side, all characters except `[-_.~/0-9a-zA-Z]` are percent-encoded. The server side does the reverse decoding, except \"%2F\" and \"%2f\" are left unchanged. Such variables show up in the [Discovery Document](https://developers.google.com/discovery/v1/reference/apis) as `{+var}`. ## Using gRPC API Service Configuration gRPC API Service Configuration (service config) is a configuration language for configuring a gRPC service to become a user-facing product. The service config is simply the YAML representation of the `google.api.Service` proto message. As an alternative to annotating your proto file, you can configure gRPC transcoding in your service config YAML files. You do this by specifying a `HttpRule` that maps the gRPC method to a REST endpoint, achieving the same effect as the proto annotation. This can be particularly useful if you have a proto that is reused in multiple services. Note that any transcoding specified in the service config will override any matching transcoding configuration in the proto. Example: http: rules: # Selects a gRPC method and applies HttpRule to it. - selector: example.v1.Messaging.GetMessage get: /v1/messages/{message_id}/{sub.subfield} ## Special notes When gRPC Transcoding is used to map a gRPC to JSON REST endpoints, the proto to JSON conversion must follow the [proto3 specification](https://developers.google.com/protocol-buffers/docs/proto3#json). While the single segment variable follows the semantics of [RFC 6570](https://tools.ietf.org/html/rfc6570) Section 3.2.2 Simple String Expansion, the multi segment variable **does not** follow RFC 6570 Section 3.2.3 Reserved Expansion. The reason is that the Reserved Expansion does not expand special characters like `?` and `#`, which would lead to invalid URLs. As the result, gRPC Transcoding uses a custom encoding for multi segment variables. The path variables **must not** refer to any repeated or mapped field, because client libraries are not capable of handling such variable expansion. The path variables **must not** capture the leading \"/\" character. The reason is that the most common use case \"{var}\" does not capture the leading \"/\" character. For consistency, all path variables must share the same behavior. Repeated message fields must not be mapped to URL query parameters, because no client library can support such complicated mapping. If an API needs to use a JSON array for request or response body, it can map the request or response body to a repeated field. However, some gRPC Transcoding implementations may not support this feature.", + "description": "gRPC Transcoding gRPC Transcoding is a feature for mapping between a gRPC method and one or more HTTP REST endpoints. It allows developers to build a single API service that supports both gRPC APIs and REST APIs. Many systems, including [Google APIs](https://github.com/googleapis/googleapis), [Cloud Endpoints](https://cloud.google.com/endpoints), [gRPC Gateway](https://github.com/grpc-ecosystem/grpc-gateway), and [Envoy](https://github.com/envoyproxy/envoy) proxy support this feature and use it for large scale production services. `HttpRule` defines the schema of the gRPC/REST mapping. The mapping specifies how different portions of the gRPC request message are mapped to the URL path, URL query parameters, and HTTP request body. It also controls how the gRPC response message is mapped to the HTTP response body. `HttpRule` is typically specified as an `google.api.http` annotation on the gRPC method. Each mapping specifies a URL path template and an HTTP method. The path template may refer to one or more fields in the gRPC request message, as long as each field is a non-repeated field with a primitive (non-message) type. The path template controls how fields of the request message are mapped to the URL path. Example: service Messaging { rpc GetMessage(GetMessageRequest) returns (Message) { option (google.api.http) = { get: \"/v1/{name=messages/*}\" }; } } message GetMessageRequest { string name = 1; // Mapped to URL path. } message Message { string text = 1; // The resource content. } This enables an HTTP REST to gRPC mapping as below: - HTTP: `GET /v1/messages/123456` - gRPC: `GetMessage(name: \"messages/123456\")` Any fields in the request message which are not bound by the path template automatically become HTTP query parameters if there is no HTTP request body. For example: service Messaging { rpc GetMessage(GetMessageRequest) returns (Message) { option (google.api.http) = { get:\"/v1/messages/{message_id}\" }; } } message GetMessageRequest { message SubMessage { string subfield = 1; } string message_id = 1; // Mapped to URL path. int64 revision = 2; // Mapped to URL query parameter `revision`. SubMessage sub = 3; // Mapped to URL query parameter `sub.subfield`. } This enables a HTTP JSON to RPC mapping as below: - HTTP: `GET /v1/messages/123456?revision=2\u0026sub.subfield=foo` - gRPC: `GetMessage(message_id: \"123456\" revision: 2 sub: SubMessage(subfield: \"foo\"))` Note that fields which are mapped to URL query parameters must have a primitive type or a repeated primitive type or a non-repeated message type. In the case of a repeated type, the parameter can be repeated in the URL as `...?param=A\u0026param=B`. In the case of a message type, each field of the message is mapped to a separate parameter, such as `...?foo.a=A\u0026foo.b=B\u0026foo.c=C`. For HTTP methods that allow a request body, the `body` field specifies the mapping. Consider a REST update method on the message resource collection: service Messaging { rpc UpdateMessage(UpdateMessageRequest) returns (Message) { option (google.api.http) = { patch: \"/v1/messages/{message_id}\" body: \"message\" }; } } message UpdateMessageRequest { string message_id = 1; // mapped to the URL Message message = 2; // mapped to the body } The following HTTP JSON to RPC mapping is enabled, where the representation of the JSON in the request body is determined by protos JSON encoding: - HTTP: `PATCH /v1/messages/123456 { \"text\": \"Hi!\" }` - gRPC: `UpdateMessage(message_id: \"123456\" message { text: \"Hi!\" })` The special name `*` can be used in the body mapping to define that every field not bound by the path template should be mapped to the request body. This enables the following alternative definition of the update method: service Messaging { rpc UpdateMessage(Message) returns (Message) { option (google.api.http) = { patch: \"/v1/messages/{message_id}\" body: \"*\" }; } } message Message { string message_id = 1; string text = 2; } The following HTTP JSON to RPC mapping is enabled: - HTTP: `PATCH /v1/messages/123456 { \"text\": \"Hi!\" }` - gRPC: `UpdateMessage(message_id: \"123456\" text: \"Hi!\")` Note that when using `*` in the body mapping, it is not possible to have HTTP parameters, as all fields not bound by the path end in the body. This makes this option more rarely used in practice when defining REST APIs. The common usage of `*` is in custom methods which don't use the URL at all for transferring data. It is possible to define multiple HTTP methods for one RPC by using the `additional_bindings` option. Example: service Messaging { rpc GetMessage(GetMessageRequest) returns (Message) { option (google.api.http) = { get: \"/v1/messages/{message_id}\" additional_bindings { get: \"/v1/users/{user_id}/messages/{message_id}\" } }; } } message GetMessageRequest { string message_id = 1; string user_id = 2; } This enables the following two alternative HTTP JSON to RPC mappings: - HTTP: `GET /v1/messages/123456` - gRPC: `GetMessage(message_id: \"123456\")` - HTTP: `GET /v1/users/me/messages/123456` - gRPC: `GetMessage(user_id: \"me\" message_id: \"123456\")` Rules for HTTP mapping 1. Leaf request fields (recursive expansion nested messages in the request message) are classified into three categories: - Fields referred by the path template. They are passed via the URL path. - Fields referred by the HttpRule.body. They are passed via the HTTP request body. - All other fields are passed via the URL query parameters, and the parameter name is the field path in the request message. A repeated field can be represented as multiple query parameters under the same name. 2. If HttpRule.body is \"*\", there is no URL query parameter, all fields are passed via URL path and HTTP request body. 3. If HttpRule.body is omitted, there is no HTTP request body, all fields are passed via URL path and URL query parameters. Path template syntax Template = \"/\" Segments [ Verb ] ; Segments = Segment { \"/\" Segment } ; Segment = \"*\" | \"**\" | LITERAL | Variable ; Variable = \"{\" FieldPath [ \"=\" Segments ] \"}\" ; FieldPath = IDENT { \".\" IDENT } ; Verb = \":\" LITERAL ; The syntax `*` matches a single URL path segment. The syntax `**` matches zero or more URL path segments, which must be the last part of the URL path except the `Verb`. The syntax `Variable` matches part of the URL path as specified by its template. A variable template must not contain other variables. If a variable matches a single path segment, its template may be omitted, e.g. `{var}` is equivalent to `{var=*}`. The syntax `LITERAL` matches literal text in the URL path. If the `LITERAL` contains any reserved character, such characters should be percent-encoded before the matching. If a variable contains exactly one path segment, such as `\"{var}\"` or `\"{var=*}\"`, when such a variable is expanded into a URL path on the client side, all characters except `[-_.~0-9a-zA-Z]` are percent-encoded. The server side does the reverse decoding. Such variables show up in the [Discovery Document](https://developers.google.com/discovery/v1/reference/apis) as `{var}`. If a variable contains multiple path segments, such as `\"{var=foo/*}\"` or `\"{var=**}\"`, when such a variable is expanded into a URL path on the client side, all characters except `[-_.~/0-9a-zA-Z]` are percent-encoded. The server side does the reverse decoding, except \"%2F\" and \"%2f\" are left unchanged. Such variables show up in the [Discovery Document](https://developers.google.com/discovery/v1/reference/apis) as `{+var}`. Using gRPC API Service Configuration gRPC API Service Configuration (service config) is a configuration language for configuring a gRPC service to become a user-facing product. The service config is simply the YAML representation of the `google.api.Service` proto message. As an alternative to annotating your proto file, you can configure gRPC transcoding in your service config YAML files. You do this by specifying a `HttpRule` that maps the gRPC method to a REST endpoint, achieving the same effect as the proto annotation. This can be particularly useful if you have a proto that is reused in multiple services. Note that any transcoding specified in the service config will override any matching transcoding configuration in the proto. Example below selects a gRPC method and applies HttpRule to it. http: rules: - selector: example.v1.Messaging.GetMessage get: /v1/messages/{message_id}/{sub.subfield} Special notes When gRPC Transcoding is used to map a gRPC to JSON REST endpoints, the proto to JSON conversion must follow the [proto3 specification](https://developers.google.com/protocol-buffers/docs/proto3#json). While the single segment variable follows the semantics of [RFC 6570](https://tools.ietf.org/html/rfc6570) Section 3.2.2 Simple String Expansion, the multi segment variable **does not** follow RFC 6570 Section 3.2.3 Reserved Expansion. The reason is that the Reserved Expansion does not expand special characters like `?` and `#`, which would lead to invalid URLs. As the result, gRPC Transcoding uses a custom encoding for multi segment variables. The path variables **must not** refer to any repeated or mapped field, because client libraries are not capable of handling such variable expansion. The path variables **must not** capture the leading \"/\" character. The reason is that the most common use case \"{var}\" does not capture the leading \"/\" character. For consistency, all path variables must share the same behavior. Repeated message fields must not be mapped to URL query parameters, because no client library can support such complicated mapping. If an API needs to use a JSON array for request or response body, it can map the request or response body to a repeated field. However, some gRPC Transcoding implementations may not support this feature.", "id": "HttpRule", "properties": { "additionalBindings": { diff --git a/servicenetworking/v1/servicenetworking-gen.go b/servicenetworking/v1/servicenetworking-gen.go index c794bb3a67b..9075c85c3fe 100644 --- a/servicenetworking/v1/servicenetworking-gen.go +++ b/servicenetworking/v1/servicenetworking-gen.go @@ -2233,12 +2233,11 @@ func (s *Http) MarshalJSON() ([]byte, error) { return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) } -// HttpRule: # gRPC Transcoding gRPC Transcoding is a feature for mapping -// between a gRPC method and one or more HTTP REST endpoints. It allows -// developers to build a single API service that supports both gRPC APIs and -// REST APIs. Many systems, including Google APIs -// (https://github.com/googleapis/googleapis), Cloud Endpoints -// (https://cloud.google.com/endpoints), gRPC Gateway +// HttpRule: gRPC Transcoding gRPC Transcoding is a feature for mapping between +// a gRPC method and one or more HTTP REST endpoints. It allows developers to +// build a single API service that supports both gRPC APIs and REST APIs. Many +// systems, including Google APIs (https://github.com/googleapis/googleapis), +// Cloud Endpoints (https://cloud.google.com/endpoints), gRPC Gateway // (https://github.com/grpc-ecosystem/grpc-gateway), and Envoy // (https://github.com/envoyproxy/envoy) proxy support this feature and use it // for large scale production services. `HttpRule` defines the schema of the @@ -2255,24 +2254,23 @@ func (s *Http) MarshalJSON() ([]byte, error) { // (Message) { option (google.api.http) = { get: "/v1/{name=messages/*}" }; } } // message GetMessageRequest { string name = 1; // Mapped to URL path. } // message Message { string text = 1; // The resource content. } This enables -// an HTTP REST to gRPC mapping as below: HTTP | gRPC -----|----- `GET -// /v1/messages/123456` | `GetMessage(name: "messages/123456")` Any fields in -// the request message which are not bound by the path template automatically -// become HTTP query parameters if there is no HTTP request body. For example: -// service Messaging { rpc GetMessage(GetMessageRequest) returns (Message) { -// option (google.api.http) = { get:"/v1/messages/{message_id}" }; } } message +// an HTTP REST to gRPC mapping as below: - HTTP: `GET /v1/messages/123456` - +// gRPC: `GetMessage(name: "messages/123456")` Any fields in the request +// message which are not bound by the path template automatically become HTTP +// query parameters if there is no HTTP request body. For example: service +// Messaging { rpc GetMessage(GetMessageRequest) returns (Message) { option +// (google.api.http) = { get:"/v1/messages/{message_id}" }; } } message // GetMessageRequest { message SubMessage { string subfield = 1; } string // message_id = 1; // Mapped to URL path. int64 revision = 2; // Mapped to URL // query parameter `revision`. SubMessage sub = 3; // Mapped to URL query // parameter `sub.subfield`. } This enables a HTTP JSON to RPC mapping as -// below: HTTP | gRPC -----|----- `GET -// /v1/messages/123456?revision=2&sub.subfield=foo` | `GetMessage(message_id: -// "123456" revision: 2 sub: SubMessage(subfield: "foo"))` Note that fields -// which are mapped to URL query parameters must have a primitive type or a -// repeated primitive type or a non-repeated message type. In the case of a -// repeated type, the parameter can be repeated in the URL as -// `...?param=A¶m=B`. In the case of a message type, each field of the -// message is mapped to a separate parameter, such as +// below: - HTTP: `GET /v1/messages/123456?revision=2&sub.subfield=foo` - gRPC: +// `GetMessage(message_id: "123456" revision: 2 sub: SubMessage(subfield: +// "foo"))` Note that fields which are mapped to URL query parameters must have +// a primitive type or a repeated primitive type or a non-repeated message +// type. In the case of a repeated type, the parameter can be repeated in the +// URL as `...?param=A¶m=B`. In the case of a message type, each field of +// the message is mapped to a separate parameter, such as // `...?foo.a=A&foo.b=B&foo.c=C`. For HTTP methods that allow a request body, // the `body` field specifies the mapping. Consider a REST update method on the // message resource collection: service Messaging { rpc @@ -2281,18 +2279,18 @@ func (s *Http) MarshalJSON() ([]byte, error) { // } } message UpdateMessageRequest { string message_id = 1; // mapped to the // URL Message message = 2; // mapped to the body } The following HTTP JSON to // RPC mapping is enabled, where the representation of the JSON in the request -// body is determined by protos JSON encoding: HTTP | gRPC -----|----- `PATCH -// /v1/messages/123456 { "text": "Hi!" }` | `UpdateMessage(message_id: "123456" -// message { text: "Hi!" })` The special name `*` can be used in the body -// mapping to define that every field not bound by the path template should be -// mapped to the request body. This enables the following alternative +// body is determined by protos JSON encoding: - HTTP: `PATCH +// /v1/messages/123456 { "text": "Hi!" }` - gRPC: `UpdateMessage(message_id: +// "123456" message { text: "Hi!" })` The special name `*` can be used in the +// body mapping to define that every field not bound by the path template +// should be mapped to the request body. This enables the following alternative // definition of the update method: service Messaging { rpc // UpdateMessage(Message) returns (Message) { option (google.api.http) = { // patch: "/v1/messages/{message_id}" body: "*" }; } } message Message { string // message_id = 1; string text = 2; } The following HTTP JSON to RPC mapping is -// enabled: HTTP | gRPC -----|----- `PATCH /v1/messages/123456 { "text": "Hi!" -// }` | `UpdateMessage(message_id: "123456" text: "Hi!")` Note that when using -// `*` in the body mapping, it is not possible to have HTTP parameters, as all +// enabled: - HTTP: `PATCH /v1/messages/123456 { "text": "Hi!" }` - gRPC: +// `UpdateMessage(message_id: "123456" text: "Hi!")` Note that when using `*` +// in the body mapping, it is not possible to have HTTP parameters, as all // fields not bound by the path end in the body. This makes this option more // rarely used in practice when defining REST APIs. The common usage of `*` is // in custom methods which don't use the URL at all for transferring data. It @@ -2302,42 +2300,42 @@ func (s *Http) MarshalJSON() ([]byte, error) { // { get: "/v1/messages/{message_id}" additional_bindings { get: // "/v1/users/{user_id}/messages/{message_id}" } }; } } message // GetMessageRequest { string message_id = 1; string user_id = 2; } This -// enables the following two alternative HTTP JSON to RPC mappings: HTTP | gRPC -// -----|----- `GET /v1/messages/123456` | `GetMessage(message_id: "123456")` -// `GET /v1/users/me/messages/123456` | `GetMessage(user_id: "me" message_id: -// "123456")` ## Rules for HTTP mapping 1. Leaf request fields (recursive -// expansion nested messages in the request message) are classified into three -// categories: - Fields referred by the path template. They are passed via the -// URL path. - Fields referred by the HttpRule.body. They are passed via the -// HTTP request body. - All other fields are passed via the URL query -// parameters, and the parameter name is the field path in the request message. -// A repeated field can be represented as multiple query parameters under the -// same name. 2. If HttpRule.body is "*", there is no URL query parameter, all -// fields are passed via URL path and HTTP request body. 3. If HttpRule.body is -// omitted, there is no HTTP request body, all fields are passed via URL path -// and URL query parameters. ### Path template syntax Template = "/" Segments [ -// Verb ] ; Segments = Segment { "/" Segment } ; Segment = "*" | "**" | LITERAL -// | Variable ; Variable = "{" FieldPath [ "=" Segments ] "}" ; FieldPath = -// IDENT { "." IDENT } ; Verb = ":" LITERAL ; The syntax `*` matches a single -// URL path segment. The syntax `**` matches zero or more URL path segments, -// which must be the last part of the URL path except the `Verb`. The syntax -// `Variable` matches part of the URL path as specified by its template. A -// variable template must not contain other variables. If a variable matches a -// single path segment, its template may be omitted, e.g. `{var}` is equivalent -// to `{var=*}`. The syntax `LITERAL` matches literal text in the URL path. If -// the `LITERAL` contains any reserved character, such characters should be -// percent-encoded before the matching. If a variable contains exactly one path -// segment, such as "{var}" or "{var=*}", when such a variable is expanded -// into a URL path on the client side, all characters except `[-_.~0-9a-zA-Z]` -// are percent-encoded. The server side does the reverse decoding. Such -// variables show up in the Discovery Document +// enables the following two alternative HTTP JSON to RPC mappings: - HTTP: +// `GET /v1/messages/123456` - gRPC: `GetMessage(message_id: "123456")` - HTTP: +// `GET /v1/users/me/messages/123456` - gRPC: `GetMessage(user_id: "me" +// message_id: "123456")` Rules for HTTP mapping 1. Leaf request fields +// (recursive expansion nested messages in the request message) are classified +// into three categories: - Fields referred by the path template. They are +// passed via the URL path. - Fields referred by the HttpRule.body. They are +// passed via the HTTP request body. - All other fields are passed via the URL +// query parameters, and the parameter name is the field path in the request +// message. A repeated field can be represented as multiple query parameters +// under the same name. 2. If HttpRule.body is "*", there is no URL query +// parameter, all fields are passed via URL path and HTTP request body. 3. If +// HttpRule.body is omitted, there is no HTTP request body, all fields are +// passed via URL path and URL query parameters. Path template syntax Template +// = "/" Segments [ Verb ] ; Segments = Segment { "/" Segment } ; Segment = "*" +// | "**" | LITERAL | Variable ; Variable = "{" FieldPath [ "=" Segments ] "}" +// ; FieldPath = IDENT { "." IDENT } ; Verb = ":" LITERAL ; The syntax `*` +// matches a single URL path segment. The syntax `**` matches zero or more URL +// path segments, which must be the last part of the URL path except the +// `Verb`. The syntax `Variable` matches part of the URL path as specified by +// its template. A variable template must not contain other variables. If a +// variable matches a single path segment, its template may be omitted, e.g. +// `{var}` is equivalent to `{var=*}`. The syntax `LITERAL` matches literal +// text in the URL path. If the `LITERAL` contains any reserved character, such +// characters should be percent-encoded before the matching. If a variable +// contains exactly one path segment, such as "{var}" or "{var=*}", when +// such a variable is expanded into a URL path on the client side, all +// characters except `[-_.~0-9a-zA-Z]` are percent-encoded. The server side +// does the reverse decoding. Such variables show up in the Discovery Document // (https://developers.google.com/discovery/v1/reference/apis) as `{var}`. If a // variable contains multiple path segments, such as "{var=foo/*}" or // "{var=**}", when such a variable is expanded into a URL path on the client // side, all characters except `[-_.~/0-9a-zA-Z]` are percent-encoded. The // server side does the reverse decoding, except "%2F" and "%2f" are left // unchanged. Such variables show up in the Discovery Document -// (https://developers.google.com/discovery/v1/reference/apis) as `{+var}`. ## +// (https://developers.google.com/discovery/v1/reference/apis) as `{+var}`. // Using gRPC API Service Configuration gRPC API Service Configuration (service // config) is a configuration language for configuring a gRPC service to become // a user-facing product. The service config is simply the YAML representation @@ -2347,12 +2345,12 @@ func (s *Http) MarshalJSON() ([]byte, error) { // to a REST endpoint, achieving the same effect as the proto annotation. This // can be particularly useful if you have a proto that is reused in multiple // services. Note that any transcoding specified in the service config will -// override any matching transcoding configuration in the proto. Example: http: -// rules: # Selects a gRPC method and applies HttpRule to it. - selector: +// override any matching transcoding configuration in the proto. Example below +// selects a gRPC method and applies HttpRule to it. http: rules: - selector: // example.v1.Messaging.GetMessage get: -// /v1/messages/{message_id}/{sub.subfield} ## Special notes When gRPC -// Transcoding is used to map a gRPC to JSON REST endpoints, the proto to JSON -// conversion must follow the proto3 specification +// /v1/messages/{message_id}/{sub.subfield} Special notes When gRPC Transcoding +// is used to map a gRPC to JSON REST endpoints, the proto to JSON conversion +// must follow the proto3 specification // (https://developers.google.com/protocol-buffers/docs/proto3#json). While the // single segment variable follows the semantics of RFC 6570 // (https://tools.ietf.org/html/rfc6570) Section 3.2.2 Simple String Expansion, diff --git a/servicenetworking/v1beta/servicenetworking-api.json b/servicenetworking/v1beta/servicenetworking-api.json index b063738137d..8ebb32a6a11 100644 --- a/servicenetworking/v1beta/servicenetworking-api.json +++ b/servicenetworking/v1beta/servicenetworking-api.json @@ -307,7 +307,7 @@ } } }, - "revision": "20240519", + "revision": "20240529", "rootUrl": "https://servicenetworking.googleapis.com/", "schemas": { "AddDnsRecordSetMetadata": { @@ -1505,7 +1505,7 @@ "type": "object" }, "HttpRule": { - "description": "# gRPC Transcoding gRPC Transcoding is a feature for mapping between a gRPC method and one or more HTTP REST endpoints. It allows developers to build a single API service that supports both gRPC APIs and REST APIs. Many systems, including [Google APIs](https://github.com/googleapis/googleapis), [Cloud Endpoints](https://cloud.google.com/endpoints), [gRPC Gateway](https://github.com/grpc-ecosystem/grpc-gateway), and [Envoy](https://github.com/envoyproxy/envoy) proxy support this feature and use it for large scale production services. `HttpRule` defines the schema of the gRPC/REST mapping. The mapping specifies how different portions of the gRPC request message are mapped to the URL path, URL query parameters, and HTTP request body. It also controls how the gRPC response message is mapped to the HTTP response body. `HttpRule` is typically specified as an `google.api.http` annotation on the gRPC method. Each mapping specifies a URL path template and an HTTP method. The path template may refer to one or more fields in the gRPC request message, as long as each field is a non-repeated field with a primitive (non-message) type. The path template controls how fields of the request message are mapped to the URL path. Example: service Messaging { rpc GetMessage(GetMessageRequest) returns (Message) { option (google.api.http) = { get: \"/v1/{name=messages/*}\" }; } } message GetMessageRequest { string name = 1; // Mapped to URL path. } message Message { string text = 1; // The resource content. } This enables an HTTP REST to gRPC mapping as below: HTTP | gRPC -----|----- `GET /v1/messages/123456` | `GetMessage(name: \"messages/123456\")` Any fields in the request message which are not bound by the path template automatically become HTTP query parameters if there is no HTTP request body. For example: service Messaging { rpc GetMessage(GetMessageRequest) returns (Message) { option (google.api.http) = { get:\"/v1/messages/{message_id}\" }; } } message GetMessageRequest { message SubMessage { string subfield = 1; } string message_id = 1; // Mapped to URL path. int64 revision = 2; // Mapped to URL query parameter `revision`. SubMessage sub = 3; // Mapped to URL query parameter `sub.subfield`. } This enables a HTTP JSON to RPC mapping as below: HTTP | gRPC -----|----- `GET /v1/messages/123456?revision=2\u0026sub.subfield=foo` | `GetMessage(message_id: \"123456\" revision: 2 sub: SubMessage(subfield: \"foo\"))` Note that fields which are mapped to URL query parameters must have a primitive type or a repeated primitive type or a non-repeated message type. In the case of a repeated type, the parameter can be repeated in the URL as `...?param=A\u0026param=B`. In the case of a message type, each field of the message is mapped to a separate parameter, such as `...?foo.a=A\u0026foo.b=B\u0026foo.c=C`. For HTTP methods that allow a request body, the `body` field specifies the mapping. Consider a REST update method on the message resource collection: service Messaging { rpc UpdateMessage(UpdateMessageRequest) returns (Message) { option (google.api.http) = { patch: \"/v1/messages/{message_id}\" body: \"message\" }; } } message UpdateMessageRequest { string message_id = 1; // mapped to the URL Message message = 2; // mapped to the body } The following HTTP JSON to RPC mapping is enabled, where the representation of the JSON in the request body is determined by protos JSON encoding: HTTP | gRPC -----|----- `PATCH /v1/messages/123456 { \"text\": \"Hi!\" }` | `UpdateMessage(message_id: \"123456\" message { text: \"Hi!\" })` The special name `*` can be used in the body mapping to define that every field not bound by the path template should be mapped to the request body. This enables the following alternative definition of the update method: service Messaging { rpc UpdateMessage(Message) returns (Message) { option (google.api.http) = { patch: \"/v1/messages/{message_id}\" body: \"*\" }; } } message Message { string message_id = 1; string text = 2; } The following HTTP JSON to RPC mapping is enabled: HTTP | gRPC -----|----- `PATCH /v1/messages/123456 { \"text\": \"Hi!\" }` | `UpdateMessage(message_id: \"123456\" text: \"Hi!\")` Note that when using `*` in the body mapping, it is not possible to have HTTP parameters, as all fields not bound by the path end in the body. This makes this option more rarely used in practice when defining REST APIs. The common usage of `*` is in custom methods which don't use the URL at all for transferring data. It is possible to define multiple HTTP methods for one RPC by using the `additional_bindings` option. Example: service Messaging { rpc GetMessage(GetMessageRequest) returns (Message) { option (google.api.http) = { get: \"/v1/messages/{message_id}\" additional_bindings { get: \"/v1/users/{user_id}/messages/{message_id}\" } }; } } message GetMessageRequest { string message_id = 1; string user_id = 2; } This enables the following two alternative HTTP JSON to RPC mappings: HTTP | gRPC -----|----- `GET /v1/messages/123456` | `GetMessage(message_id: \"123456\")` `GET /v1/users/me/messages/123456` | `GetMessage(user_id: \"me\" message_id: \"123456\")` ## Rules for HTTP mapping 1. Leaf request fields (recursive expansion nested messages in the request message) are classified into three categories: - Fields referred by the path template. They are passed via the URL path. - Fields referred by the HttpRule.body. They are passed via the HTTP request body. - All other fields are passed via the URL query parameters, and the parameter name is the field path in the request message. A repeated field can be represented as multiple query parameters under the same name. 2. If HttpRule.body is \"*\", there is no URL query parameter, all fields are passed via URL path and HTTP request body. 3. If HttpRule.body is omitted, there is no HTTP request body, all fields are passed via URL path and URL query parameters. ### Path template syntax Template = \"/\" Segments [ Verb ] ; Segments = Segment { \"/\" Segment } ; Segment = \"*\" | \"**\" | LITERAL | Variable ; Variable = \"{\" FieldPath [ \"=\" Segments ] \"}\" ; FieldPath = IDENT { \".\" IDENT } ; Verb = \":\" LITERAL ; The syntax `*` matches a single URL path segment. The syntax `**` matches zero or more URL path segments, which must be the last part of the URL path except the `Verb`. The syntax `Variable` matches part of the URL path as specified by its template. A variable template must not contain other variables. If a variable matches a single path segment, its template may be omitted, e.g. `{var}` is equivalent to `{var=*}`. The syntax `LITERAL` matches literal text in the URL path. If the `LITERAL` contains any reserved character, such characters should be percent-encoded before the matching. If a variable contains exactly one path segment, such as `\"{var}\"` or `\"{var=*}\"`, when such a variable is expanded into a URL path on the client side, all characters except `[-_.~0-9a-zA-Z]` are percent-encoded. The server side does the reverse decoding. Such variables show up in the [Discovery Document](https://developers.google.com/discovery/v1/reference/apis) as `{var}`. If a variable contains multiple path segments, such as `\"{var=foo/*}\"` or `\"{var=**}\"`, when such a variable is expanded into a URL path on the client side, all characters except `[-_.~/0-9a-zA-Z]` are percent-encoded. The server side does the reverse decoding, except \"%2F\" and \"%2f\" are left unchanged. Such variables show up in the [Discovery Document](https://developers.google.com/discovery/v1/reference/apis) as `{+var}`. ## Using gRPC API Service Configuration gRPC API Service Configuration (service config) is a configuration language for configuring a gRPC service to become a user-facing product. The service config is simply the YAML representation of the `google.api.Service` proto message. As an alternative to annotating your proto file, you can configure gRPC transcoding in your service config YAML files. You do this by specifying a `HttpRule` that maps the gRPC method to a REST endpoint, achieving the same effect as the proto annotation. This can be particularly useful if you have a proto that is reused in multiple services. Note that any transcoding specified in the service config will override any matching transcoding configuration in the proto. Example: http: rules: # Selects a gRPC method and applies HttpRule to it. - selector: example.v1.Messaging.GetMessage get: /v1/messages/{message_id}/{sub.subfield} ## Special notes When gRPC Transcoding is used to map a gRPC to JSON REST endpoints, the proto to JSON conversion must follow the [proto3 specification](https://developers.google.com/protocol-buffers/docs/proto3#json). While the single segment variable follows the semantics of [RFC 6570](https://tools.ietf.org/html/rfc6570) Section 3.2.2 Simple String Expansion, the multi segment variable **does not** follow RFC 6570 Section 3.2.3 Reserved Expansion. The reason is that the Reserved Expansion does not expand special characters like `?` and `#`, which would lead to invalid URLs. As the result, gRPC Transcoding uses a custom encoding for multi segment variables. The path variables **must not** refer to any repeated or mapped field, because client libraries are not capable of handling such variable expansion. The path variables **must not** capture the leading \"/\" character. The reason is that the most common use case \"{var}\" does not capture the leading \"/\" character. For consistency, all path variables must share the same behavior. Repeated message fields must not be mapped to URL query parameters, because no client library can support such complicated mapping. If an API needs to use a JSON array for request or response body, it can map the request or response body to a repeated field. However, some gRPC Transcoding implementations may not support this feature.", + "description": "gRPC Transcoding gRPC Transcoding is a feature for mapping between a gRPC method and one or more HTTP REST endpoints. It allows developers to build a single API service that supports both gRPC APIs and REST APIs. Many systems, including [Google APIs](https://github.com/googleapis/googleapis), [Cloud Endpoints](https://cloud.google.com/endpoints), [gRPC Gateway](https://github.com/grpc-ecosystem/grpc-gateway), and [Envoy](https://github.com/envoyproxy/envoy) proxy support this feature and use it for large scale production services. `HttpRule` defines the schema of the gRPC/REST mapping. The mapping specifies how different portions of the gRPC request message are mapped to the URL path, URL query parameters, and HTTP request body. It also controls how the gRPC response message is mapped to the HTTP response body. `HttpRule` is typically specified as an `google.api.http` annotation on the gRPC method. Each mapping specifies a URL path template and an HTTP method. The path template may refer to one or more fields in the gRPC request message, as long as each field is a non-repeated field with a primitive (non-message) type. The path template controls how fields of the request message are mapped to the URL path. Example: service Messaging { rpc GetMessage(GetMessageRequest) returns (Message) { option (google.api.http) = { get: \"/v1/{name=messages/*}\" }; } } message GetMessageRequest { string name = 1; // Mapped to URL path. } message Message { string text = 1; // The resource content. } This enables an HTTP REST to gRPC mapping as below: - HTTP: `GET /v1/messages/123456` - gRPC: `GetMessage(name: \"messages/123456\")` Any fields in the request message which are not bound by the path template automatically become HTTP query parameters if there is no HTTP request body. For example: service Messaging { rpc GetMessage(GetMessageRequest) returns (Message) { option (google.api.http) = { get:\"/v1/messages/{message_id}\" }; } } message GetMessageRequest { message SubMessage { string subfield = 1; } string message_id = 1; // Mapped to URL path. int64 revision = 2; // Mapped to URL query parameter `revision`. SubMessage sub = 3; // Mapped to URL query parameter `sub.subfield`. } This enables a HTTP JSON to RPC mapping as below: - HTTP: `GET /v1/messages/123456?revision=2\u0026sub.subfield=foo` - gRPC: `GetMessage(message_id: \"123456\" revision: 2 sub: SubMessage(subfield: \"foo\"))` Note that fields which are mapped to URL query parameters must have a primitive type or a repeated primitive type or a non-repeated message type. In the case of a repeated type, the parameter can be repeated in the URL as `...?param=A\u0026param=B`. In the case of a message type, each field of the message is mapped to a separate parameter, such as `...?foo.a=A\u0026foo.b=B\u0026foo.c=C`. For HTTP methods that allow a request body, the `body` field specifies the mapping. Consider a REST update method on the message resource collection: service Messaging { rpc UpdateMessage(UpdateMessageRequest) returns (Message) { option (google.api.http) = { patch: \"/v1/messages/{message_id}\" body: \"message\" }; } } message UpdateMessageRequest { string message_id = 1; // mapped to the URL Message message = 2; // mapped to the body } The following HTTP JSON to RPC mapping is enabled, where the representation of the JSON in the request body is determined by protos JSON encoding: - HTTP: `PATCH /v1/messages/123456 { \"text\": \"Hi!\" }` - gRPC: `UpdateMessage(message_id: \"123456\" message { text: \"Hi!\" })` The special name `*` can be used in the body mapping to define that every field not bound by the path template should be mapped to the request body. This enables the following alternative definition of the update method: service Messaging { rpc UpdateMessage(Message) returns (Message) { option (google.api.http) = { patch: \"/v1/messages/{message_id}\" body: \"*\" }; } } message Message { string message_id = 1; string text = 2; } The following HTTP JSON to RPC mapping is enabled: - HTTP: `PATCH /v1/messages/123456 { \"text\": \"Hi!\" }` - gRPC: `UpdateMessage(message_id: \"123456\" text: \"Hi!\")` Note that when using `*` in the body mapping, it is not possible to have HTTP parameters, as all fields not bound by the path end in the body. This makes this option more rarely used in practice when defining REST APIs. The common usage of `*` is in custom methods which don't use the URL at all for transferring data. It is possible to define multiple HTTP methods for one RPC by using the `additional_bindings` option. Example: service Messaging { rpc GetMessage(GetMessageRequest) returns (Message) { option (google.api.http) = { get: \"/v1/messages/{message_id}\" additional_bindings { get: \"/v1/users/{user_id}/messages/{message_id}\" } }; } } message GetMessageRequest { string message_id = 1; string user_id = 2; } This enables the following two alternative HTTP JSON to RPC mappings: - HTTP: `GET /v1/messages/123456` - gRPC: `GetMessage(message_id: \"123456\")` - HTTP: `GET /v1/users/me/messages/123456` - gRPC: `GetMessage(user_id: \"me\" message_id: \"123456\")` Rules for HTTP mapping 1. Leaf request fields (recursive expansion nested messages in the request message) are classified into three categories: - Fields referred by the path template. They are passed via the URL path. - Fields referred by the HttpRule.body. They are passed via the HTTP request body. - All other fields are passed via the URL query parameters, and the parameter name is the field path in the request message. A repeated field can be represented as multiple query parameters under the same name. 2. If HttpRule.body is \"*\", there is no URL query parameter, all fields are passed via URL path and HTTP request body. 3. If HttpRule.body is omitted, there is no HTTP request body, all fields are passed via URL path and URL query parameters. Path template syntax Template = \"/\" Segments [ Verb ] ; Segments = Segment { \"/\" Segment } ; Segment = \"*\" | \"**\" | LITERAL | Variable ; Variable = \"{\" FieldPath [ \"=\" Segments ] \"}\" ; FieldPath = IDENT { \".\" IDENT } ; Verb = \":\" LITERAL ; The syntax `*` matches a single URL path segment. The syntax `**` matches zero or more URL path segments, which must be the last part of the URL path except the `Verb`. The syntax `Variable` matches part of the URL path as specified by its template. A variable template must not contain other variables. If a variable matches a single path segment, its template may be omitted, e.g. `{var}` is equivalent to `{var=*}`. The syntax `LITERAL` matches literal text in the URL path. If the `LITERAL` contains any reserved character, such characters should be percent-encoded before the matching. If a variable contains exactly one path segment, such as `\"{var}\"` or `\"{var=*}\"`, when such a variable is expanded into a URL path on the client side, all characters except `[-_.~0-9a-zA-Z]` are percent-encoded. The server side does the reverse decoding. Such variables show up in the [Discovery Document](https://developers.google.com/discovery/v1/reference/apis) as `{var}`. If a variable contains multiple path segments, such as `\"{var=foo/*}\"` or `\"{var=**}\"`, when such a variable is expanded into a URL path on the client side, all characters except `[-_.~/0-9a-zA-Z]` are percent-encoded. The server side does the reverse decoding, except \"%2F\" and \"%2f\" are left unchanged. Such variables show up in the [Discovery Document](https://developers.google.com/discovery/v1/reference/apis) as `{+var}`. Using gRPC API Service Configuration gRPC API Service Configuration (service config) is a configuration language for configuring a gRPC service to become a user-facing product. The service config is simply the YAML representation of the `google.api.Service` proto message. As an alternative to annotating your proto file, you can configure gRPC transcoding in your service config YAML files. You do this by specifying a `HttpRule` that maps the gRPC method to a REST endpoint, achieving the same effect as the proto annotation. This can be particularly useful if you have a proto that is reused in multiple services. Note that any transcoding specified in the service config will override any matching transcoding configuration in the proto. Example below selects a gRPC method and applies HttpRule to it. http: rules: - selector: example.v1.Messaging.GetMessage get: /v1/messages/{message_id}/{sub.subfield} Special notes When gRPC Transcoding is used to map a gRPC to JSON REST endpoints, the proto to JSON conversion must follow the [proto3 specification](https://developers.google.com/protocol-buffers/docs/proto3#json). While the single segment variable follows the semantics of [RFC 6570](https://tools.ietf.org/html/rfc6570) Section 3.2.2 Simple String Expansion, the multi segment variable **does not** follow RFC 6570 Section 3.2.3 Reserved Expansion. The reason is that the Reserved Expansion does not expand special characters like `?` and `#`, which would lead to invalid URLs. As the result, gRPC Transcoding uses a custom encoding for multi segment variables. The path variables **must not** refer to any repeated or mapped field, because client libraries are not capable of handling such variable expansion. The path variables **must not** capture the leading \"/\" character. The reason is that the most common use case \"{var}\" does not capture the leading \"/\" character. For consistency, all path variables must share the same behavior. Repeated message fields must not be mapped to URL query parameters, because no client library can support such complicated mapping. If an API needs to use a JSON array for request or response body, it can map the request or response body to a repeated field. However, some gRPC Transcoding implementations may not support this feature.", "id": "HttpRule", "properties": { "additionalBindings": { diff --git a/servicenetworking/v1beta/servicenetworking-gen.go b/servicenetworking/v1beta/servicenetworking-gen.go index 1150bc2a724..1abff8e5527 100644 --- a/servicenetworking/v1beta/servicenetworking-gen.go +++ b/servicenetworking/v1beta/servicenetworking-gen.go @@ -1801,12 +1801,11 @@ func (s *Http) MarshalJSON() ([]byte, error) { return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields) } -// HttpRule: # gRPC Transcoding gRPC Transcoding is a feature for mapping -// between a gRPC method and one or more HTTP REST endpoints. It allows -// developers to build a single API service that supports both gRPC APIs and -// REST APIs. Many systems, including Google APIs -// (https://github.com/googleapis/googleapis), Cloud Endpoints -// (https://cloud.google.com/endpoints), gRPC Gateway +// HttpRule: gRPC Transcoding gRPC Transcoding is a feature for mapping between +// a gRPC method and one or more HTTP REST endpoints. It allows developers to +// build a single API service that supports both gRPC APIs and REST APIs. Many +// systems, including Google APIs (https://github.com/googleapis/googleapis), +// Cloud Endpoints (https://cloud.google.com/endpoints), gRPC Gateway // (https://github.com/grpc-ecosystem/grpc-gateway), and Envoy // (https://github.com/envoyproxy/envoy) proxy support this feature and use it // for large scale production services. `HttpRule` defines the schema of the @@ -1823,24 +1822,23 @@ func (s *Http) MarshalJSON() ([]byte, error) { // (Message) { option (google.api.http) = { get: "/v1/{name=messages/*}" }; } } // message GetMessageRequest { string name = 1; // Mapped to URL path. } // message Message { string text = 1; // The resource content. } This enables -// an HTTP REST to gRPC mapping as below: HTTP | gRPC -----|----- `GET -// /v1/messages/123456` | `GetMessage(name: "messages/123456")` Any fields in -// the request message which are not bound by the path template automatically -// become HTTP query parameters if there is no HTTP request body. For example: -// service Messaging { rpc GetMessage(GetMessageRequest) returns (Message) { -// option (google.api.http) = { get:"/v1/messages/{message_id}" }; } } message +// an HTTP REST to gRPC mapping as below: - HTTP: `GET /v1/messages/123456` - +// gRPC: `GetMessage(name: "messages/123456")` Any fields in the request +// message which are not bound by the path template automatically become HTTP +// query parameters if there is no HTTP request body. For example: service +// Messaging { rpc GetMessage(GetMessageRequest) returns (Message) { option +// (google.api.http) = { get:"/v1/messages/{message_id}" }; } } message // GetMessageRequest { message SubMessage { string subfield = 1; } string // message_id = 1; // Mapped to URL path. int64 revision = 2; // Mapped to URL // query parameter `revision`. SubMessage sub = 3; // Mapped to URL query // parameter `sub.subfield`. } This enables a HTTP JSON to RPC mapping as -// below: HTTP | gRPC -----|----- `GET -// /v1/messages/123456?revision=2&sub.subfield=foo` | `GetMessage(message_id: -// "123456" revision: 2 sub: SubMessage(subfield: "foo"))` Note that fields -// which are mapped to URL query parameters must have a primitive type or a -// repeated primitive type or a non-repeated message type. In the case of a -// repeated type, the parameter can be repeated in the URL as -// `...?param=A¶m=B`. In the case of a message type, each field of the -// message is mapped to a separate parameter, such as +// below: - HTTP: `GET /v1/messages/123456?revision=2&sub.subfield=foo` - gRPC: +// `GetMessage(message_id: "123456" revision: 2 sub: SubMessage(subfield: +// "foo"))` Note that fields which are mapped to URL query parameters must have +// a primitive type or a repeated primitive type or a non-repeated message +// type. In the case of a repeated type, the parameter can be repeated in the +// URL as `...?param=A¶m=B`. In the case of a message type, each field of +// the message is mapped to a separate parameter, such as // `...?foo.a=A&foo.b=B&foo.c=C`. For HTTP methods that allow a request body, // the `body` field specifies the mapping. Consider a REST update method on the // message resource collection: service Messaging { rpc @@ -1849,18 +1847,18 @@ func (s *Http) MarshalJSON() ([]byte, error) { // } } message UpdateMessageRequest { string message_id = 1; // mapped to the // URL Message message = 2; // mapped to the body } The following HTTP JSON to // RPC mapping is enabled, where the representation of the JSON in the request -// body is determined by protos JSON encoding: HTTP | gRPC -----|----- `PATCH -// /v1/messages/123456 { "text": "Hi!" }` | `UpdateMessage(message_id: "123456" -// message { text: "Hi!" })` The special name `*` can be used in the body -// mapping to define that every field not bound by the path template should be -// mapped to the request body. This enables the following alternative +// body is determined by protos JSON encoding: - HTTP: `PATCH +// /v1/messages/123456 { "text": "Hi!" }` - gRPC: `UpdateMessage(message_id: +// "123456" message { text: "Hi!" })` The special name `*` can be used in the +// body mapping to define that every field not bound by the path template +// should be mapped to the request body. This enables the following alternative // definition of the update method: service Messaging { rpc // UpdateMessage(Message) returns (Message) { option (google.api.http) = { // patch: "/v1/messages/{message_id}" body: "*" }; } } message Message { string // message_id = 1; string text = 2; } The following HTTP JSON to RPC mapping is -// enabled: HTTP | gRPC -----|----- `PATCH /v1/messages/123456 { "text": "Hi!" -// }` | `UpdateMessage(message_id: "123456" text: "Hi!")` Note that when using -// `*` in the body mapping, it is not possible to have HTTP parameters, as all +// enabled: - HTTP: `PATCH /v1/messages/123456 { "text": "Hi!" }` - gRPC: +// `UpdateMessage(message_id: "123456" text: "Hi!")` Note that when using `*` +// in the body mapping, it is not possible to have HTTP parameters, as all // fields not bound by the path end in the body. This makes this option more // rarely used in practice when defining REST APIs. The common usage of `*` is // in custom methods which don't use the URL at all for transferring data. It @@ -1870,42 +1868,42 @@ func (s *Http) MarshalJSON() ([]byte, error) { // { get: "/v1/messages/{message_id}" additional_bindings { get: // "/v1/users/{user_id}/messages/{message_id}" } }; } } message // GetMessageRequest { string message_id = 1; string user_id = 2; } This -// enables the following two alternative HTTP JSON to RPC mappings: HTTP | gRPC -// -----|----- `GET /v1/messages/123456` | `GetMessage(message_id: "123456")` -// `GET /v1/users/me/messages/123456` | `GetMessage(user_id: "me" message_id: -// "123456")` ## Rules for HTTP mapping 1. Leaf request fields (recursive -// expansion nested messages in the request message) are classified into three -// categories: - Fields referred by the path template. They are passed via the -// URL path. - Fields referred by the HttpRule.body. They are passed via the -// HTTP request body. - All other fields are passed via the URL query -// parameters, and the parameter name is the field path in the request message. -// A repeated field can be represented as multiple query parameters under the -// same name. 2. If HttpRule.body is "*", there is no URL query parameter, all -// fields are passed via URL path and HTTP request body. 3. If HttpRule.body is -// omitted, there is no HTTP request body, all fields are passed via URL path -// and URL query parameters. ### Path template syntax Template = "/" Segments [ -// Verb ] ; Segments = Segment { "/" Segment } ; Segment = "*" | "**" | LITERAL -// | Variable ; Variable = "{" FieldPath [ "=" Segments ] "}" ; FieldPath = -// IDENT { "." IDENT } ; Verb = ":" LITERAL ; The syntax `*` matches a single -// URL path segment. The syntax `**` matches zero or more URL path segments, -// which must be the last part of the URL path except the `Verb`. The syntax -// `Variable` matches part of the URL path as specified by its template. A -// variable template must not contain other variables. If a variable matches a -// single path segment, its template may be omitted, e.g. `{var}` is equivalent -// to `{var=*}`. The syntax `LITERAL` matches literal text in the URL path. If -// the `LITERAL` contains any reserved character, such characters should be -// percent-encoded before the matching. If a variable contains exactly one path -// segment, such as "{var}" or "{var=*}", when such a variable is expanded -// into a URL path on the client side, all characters except `[-_.~0-9a-zA-Z]` -// are percent-encoded. The server side does the reverse decoding. Such -// variables show up in the Discovery Document +// enables the following two alternative HTTP JSON to RPC mappings: - HTTP: +// `GET /v1/messages/123456` - gRPC: `GetMessage(message_id: "123456")` - HTTP: +// `GET /v1/users/me/messages/123456` - gRPC: `GetMessage(user_id: "me" +// message_id: "123456")` Rules for HTTP mapping 1. Leaf request fields +// (recursive expansion nested messages in the request message) are classified +// into three categories: - Fields referred by the path template. They are +// passed via the URL path. - Fields referred by the HttpRule.body. They are +// passed via the HTTP request body. - All other fields are passed via the URL +// query parameters, and the parameter name is the field path in the request +// message. A repeated field can be represented as multiple query parameters +// under the same name. 2. If HttpRule.body is "*", there is no URL query +// parameter, all fields are passed via URL path and HTTP request body. 3. If +// HttpRule.body is omitted, there is no HTTP request body, all fields are +// passed via URL path and URL query parameters. Path template syntax Template +// = "/" Segments [ Verb ] ; Segments = Segment { "/" Segment } ; Segment = "*" +// | "**" | LITERAL | Variable ; Variable = "{" FieldPath [ "=" Segments ] "}" +// ; FieldPath = IDENT { "." IDENT } ; Verb = ":" LITERAL ; The syntax `*` +// matches a single URL path segment. The syntax `**` matches zero or more URL +// path segments, which must be the last part of the URL path except the +// `Verb`. The syntax `Variable` matches part of the URL path as specified by +// its template. A variable template must not contain other variables. If a +// variable matches a single path segment, its template may be omitted, e.g. +// `{var}` is equivalent to `{var=*}`. The syntax `LITERAL` matches literal +// text in the URL path. If the `LITERAL` contains any reserved character, such +// characters should be percent-encoded before the matching. If a variable +// contains exactly one path segment, such as "{var}" or "{var=*}", when +// such a variable is expanded into a URL path on the client side, all +// characters except `[-_.~0-9a-zA-Z]` are percent-encoded. The server side +// does the reverse decoding. Such variables show up in the Discovery Document // (https://developers.google.com/discovery/v1/reference/apis) as `{var}`. If a // variable contains multiple path segments, such as "{var=foo/*}" or // "{var=**}", when such a variable is expanded into a URL path on the client // side, all characters except `[-_.~/0-9a-zA-Z]` are percent-encoded. The // server side does the reverse decoding, except "%2F" and "%2f" are left // unchanged. Such variables show up in the Discovery Document -// (https://developers.google.com/discovery/v1/reference/apis) as `{+var}`. ## +// (https://developers.google.com/discovery/v1/reference/apis) as `{+var}`. // Using gRPC API Service Configuration gRPC API Service Configuration (service // config) is a configuration language for configuring a gRPC service to become // a user-facing product. The service config is simply the YAML representation @@ -1915,12 +1913,12 @@ func (s *Http) MarshalJSON() ([]byte, error) { // to a REST endpoint, achieving the same effect as the proto annotation. This // can be particularly useful if you have a proto that is reused in multiple // services. Note that any transcoding specified in the service config will -// override any matching transcoding configuration in the proto. Example: http: -// rules: # Selects a gRPC method and applies HttpRule to it. - selector: +// override any matching transcoding configuration in the proto. Example below +// selects a gRPC method and applies HttpRule to it. http: rules: - selector: // example.v1.Messaging.GetMessage get: -// /v1/messages/{message_id}/{sub.subfield} ## Special notes When gRPC -// Transcoding is used to map a gRPC to JSON REST endpoints, the proto to JSON -// conversion must follow the proto3 specification +// /v1/messages/{message_id}/{sub.subfield} Special notes When gRPC Transcoding +// is used to map a gRPC to JSON REST endpoints, the proto to JSON conversion +// must follow the proto3 specification // (https://developers.google.com/protocol-buffers/docs/proto3#json). While the // single segment variable follows the semantics of RFC 6570 // (https://tools.ietf.org/html/rfc6570) Section 3.2.2 Simple String Expansion, diff --git a/versionhistory/v1/versionhistory-api.json b/versionhistory/v1/versionhistory-api.json index 467be3666bc..64f47b09270 100644 --- a/versionhistory/v1/versionhistory-api.json +++ b/versionhistory/v1/versionhistory-api.json @@ -271,7 +271,7 @@ } } }, - "revision": "20240331", + "revision": "20240529", "rootUrl": "https://versionhistory.googleapis.com/", "schemas": { "Channel": { @@ -471,6 +471,10 @@ "description": "Release name. Format is \"{product}/platforms/{platform}/channels/{channel}/versions/{version}/releases/{release}\"", "type": "string" }, + "pinnable": { + "description": "Whether or not the release was available for version pinning.", + "type": "boolean" + }, "serving": { "$ref": "Interval", "description": "Timestamp interval of when the release was live. If end_time is unspecified, the release is currently live." diff --git a/versionhistory/v1/versionhistory-gen.go b/versionhistory/v1/versionhistory-gen.go index 10a8b0ed250..03ffd878f3a 100644 --- a/versionhistory/v1/versionhistory-gen.go +++ b/versionhistory/v1/versionhistory-gen.go @@ -433,6 +433,8 @@ type Release struct { // "{product}/platforms/{platform}/channels/{channel}/versions/{version}/release // s/{release}" Name string `json:"name,omitempty"` + // Pinnable: Whether or not the release was available for version pinning. + Pinnable bool `json:"pinnable,omitempty"` // Serving: Timestamp interval of when the release was live. If end_time is // unspecified, the release is currently live. Serving *Interval `json:"serving,omitempty"`