1// Copyright 2021 Google LLC.
2// Use of this source code is governed by a BSD-style
3// license that can be found in the LICENSE file.
4
5// Code generated file. DO NOT EDIT.
6
7// Package dialogflow provides access to the Dialogflow API.
8//
9// This package is DEPRECATED. Use package cloud.google.com/go/dialogflow/apiv2 instead.
10//
11// For product documentation, see: https://cloud.google.com/dialogflow/
12//
13// Creating a client
14//
15// Usage example:
16//
17//   import "google.golang.org/api/dialogflow/v2"
18//   ...
19//   ctx := context.Background()
20//   dialogflowService, err := dialogflow.NewService(ctx)
21//
22// In this example, Google Application Default Credentials are used for authentication.
23//
24// For information on how to create and obtain Application Default Credentials, see https://developers.google.com/identity/protocols/application-default-credentials.
25//
26// Other authentication options
27//
28// By default, all available scopes (see "Constants") are used to authenticate. To restrict scopes, use option.WithScopes:
29//
30//   dialogflowService, err := dialogflow.NewService(ctx, option.WithScopes(dialogflow.DialogflowScope))
31//
32// To use an API key for authentication (note: some APIs do not support API keys), use option.WithAPIKey:
33//
34//   dialogflowService, err := dialogflow.NewService(ctx, option.WithAPIKey("AIza..."))
35//
36// To use an OAuth token (e.g., a user token obtained via a three-legged OAuth flow), use option.WithTokenSource:
37//
38//   config := &oauth2.Config{...}
39//   // ...
40//   token, err := config.Exchange(ctx, ...)
41//   dialogflowService, err := dialogflow.NewService(ctx, option.WithTokenSource(config.TokenSource(ctx, token)))
42//
43// See https://godoc.org/google.golang.org/api/option/ for details on options.
44package dialogflow // import "google.golang.org/api/dialogflow/v2"
45
46import (
47	"bytes"
48	"context"
49	"encoding/json"
50	"errors"
51	"fmt"
52	"io"
53	"net/http"
54	"net/url"
55	"strconv"
56	"strings"
57
58	googleapi "google.golang.org/api/googleapi"
59	gensupport "google.golang.org/api/internal/gensupport"
60	option "google.golang.org/api/option"
61	internaloption "google.golang.org/api/option/internaloption"
62	htransport "google.golang.org/api/transport/http"
63)
64
65// Always reference these packages, just in case the auto-generated code
66// below doesn't.
67var _ = bytes.NewBuffer
68var _ = strconv.Itoa
69var _ = fmt.Sprintf
70var _ = json.NewDecoder
71var _ = io.Copy
72var _ = url.Parse
73var _ = gensupport.MarshalJSON
74var _ = googleapi.Version
75var _ = errors.New
76var _ = strings.Replace
77var _ = context.Canceled
78var _ = internaloption.WithDefaultEndpoint
79
80const apiId = "dialogflow:v2"
81const apiName = "dialogflow"
82const apiVersion = "v2"
83const basePath = "https://dialogflow.googleapis.com/"
84const mtlsBasePath = "https://dialogflow.mtls.googleapis.com/"
85
86// OAuth2 scopes used by this API.
87const (
88	// See, edit, configure, and delete your Google Cloud data and see the
89	// email address for your Google Account.
90	CloudPlatformScope = "https://www.googleapis.com/auth/cloud-platform"
91
92	// View, manage and query your Dialogflow agents
93	DialogflowScope = "https://www.googleapis.com/auth/dialogflow"
94)
95
96// NewService creates a new Service.
97func NewService(ctx context.Context, opts ...option.ClientOption) (*Service, error) {
98	scopesOption := option.WithScopes(
99		"https://www.googleapis.com/auth/cloud-platform",
100		"https://www.googleapis.com/auth/dialogflow",
101	)
102	// NOTE: prepend, so we don't override user-specified scopes.
103	opts = append([]option.ClientOption{scopesOption}, opts...)
104	opts = append(opts, internaloption.WithDefaultEndpoint(basePath))
105	opts = append(opts, internaloption.WithDefaultMTLSEndpoint(mtlsBasePath))
106	client, endpoint, err := htransport.NewClient(ctx, opts...)
107	if err != nil {
108		return nil, err
109	}
110	s, err := New(client)
111	if err != nil {
112		return nil, err
113	}
114	if endpoint != "" {
115		s.BasePath = endpoint
116	}
117	return s, nil
118}
119
120// New creates a new Service. It uses the provided http.Client for requests.
121//
122// Deprecated: please use NewService instead.
123// To provide a custom HTTP client, use option.WithHTTPClient.
124// If you are using google.golang.org/api/googleapis/transport.APIKey, use option.WithAPIKey with NewService instead.
125func New(client *http.Client) (*Service, error) {
126	if client == nil {
127		return nil, errors.New("client is nil")
128	}
129	s := &Service{client: client, BasePath: basePath}
130	s.Projects = NewProjectsService(s)
131	return s, nil
132}
133
134type Service struct {
135	client    *http.Client
136	BasePath  string // API endpoint base URL
137	UserAgent string // optional additional User-Agent fragment
138
139	Projects *ProjectsService
140}
141
142func (s *Service) userAgent() string {
143	if s.UserAgent == "" {
144		return googleapi.UserAgent
145	}
146	return googleapi.UserAgent + " " + s.UserAgent
147}
148
149func NewProjectsService(s *Service) *ProjectsService {
150	rs := &ProjectsService{s: s}
151	rs.Agent = NewProjectsAgentService(s)
152	rs.AnswerRecords = NewProjectsAnswerRecordsService(s)
153	rs.ConversationProfiles = NewProjectsConversationProfilesService(s)
154	rs.Conversations = NewProjectsConversationsService(s)
155	rs.KnowledgeBases = NewProjectsKnowledgeBasesService(s)
156	rs.Locations = NewProjectsLocationsService(s)
157	rs.Operations = NewProjectsOperationsService(s)
158	return rs
159}
160
161type ProjectsService struct {
162	s *Service
163
164	Agent *ProjectsAgentService
165
166	AnswerRecords *ProjectsAnswerRecordsService
167
168	ConversationProfiles *ProjectsConversationProfilesService
169
170	Conversations *ProjectsConversationsService
171
172	KnowledgeBases *ProjectsKnowledgeBasesService
173
174	Locations *ProjectsLocationsService
175
176	Operations *ProjectsOperationsService
177}
178
179func NewProjectsAgentService(s *Service) *ProjectsAgentService {
180	rs := &ProjectsAgentService{s: s}
181	rs.EntityTypes = NewProjectsAgentEntityTypesService(s)
182	rs.Environments = NewProjectsAgentEnvironmentsService(s)
183	rs.Intents = NewProjectsAgentIntentsService(s)
184	rs.KnowledgeBases = NewProjectsAgentKnowledgeBasesService(s)
185	rs.Sessions = NewProjectsAgentSessionsService(s)
186	rs.Versions = NewProjectsAgentVersionsService(s)
187	return rs
188}
189
190type ProjectsAgentService struct {
191	s *Service
192
193	EntityTypes *ProjectsAgentEntityTypesService
194
195	Environments *ProjectsAgentEnvironmentsService
196
197	Intents *ProjectsAgentIntentsService
198
199	KnowledgeBases *ProjectsAgentKnowledgeBasesService
200
201	Sessions *ProjectsAgentSessionsService
202
203	Versions *ProjectsAgentVersionsService
204}
205
206func NewProjectsAgentEntityTypesService(s *Service) *ProjectsAgentEntityTypesService {
207	rs := &ProjectsAgentEntityTypesService{s: s}
208	rs.Entities = NewProjectsAgentEntityTypesEntitiesService(s)
209	return rs
210}
211
212type ProjectsAgentEntityTypesService struct {
213	s *Service
214
215	Entities *ProjectsAgentEntityTypesEntitiesService
216}
217
218func NewProjectsAgentEntityTypesEntitiesService(s *Service) *ProjectsAgentEntityTypesEntitiesService {
219	rs := &ProjectsAgentEntityTypesEntitiesService{s: s}
220	return rs
221}
222
223type ProjectsAgentEntityTypesEntitiesService struct {
224	s *Service
225}
226
227func NewProjectsAgentEnvironmentsService(s *Service) *ProjectsAgentEnvironmentsService {
228	rs := &ProjectsAgentEnvironmentsService{s: s}
229	rs.Intents = NewProjectsAgentEnvironmentsIntentsService(s)
230	rs.Users = NewProjectsAgentEnvironmentsUsersService(s)
231	return rs
232}
233
234type ProjectsAgentEnvironmentsService struct {
235	s *Service
236
237	Intents *ProjectsAgentEnvironmentsIntentsService
238
239	Users *ProjectsAgentEnvironmentsUsersService
240}
241
242func NewProjectsAgentEnvironmentsIntentsService(s *Service) *ProjectsAgentEnvironmentsIntentsService {
243	rs := &ProjectsAgentEnvironmentsIntentsService{s: s}
244	return rs
245}
246
247type ProjectsAgentEnvironmentsIntentsService struct {
248	s *Service
249}
250
251func NewProjectsAgentEnvironmentsUsersService(s *Service) *ProjectsAgentEnvironmentsUsersService {
252	rs := &ProjectsAgentEnvironmentsUsersService{s: s}
253	rs.Sessions = NewProjectsAgentEnvironmentsUsersSessionsService(s)
254	return rs
255}
256
257type ProjectsAgentEnvironmentsUsersService struct {
258	s *Service
259
260	Sessions *ProjectsAgentEnvironmentsUsersSessionsService
261}
262
263func NewProjectsAgentEnvironmentsUsersSessionsService(s *Service) *ProjectsAgentEnvironmentsUsersSessionsService {
264	rs := &ProjectsAgentEnvironmentsUsersSessionsService{s: s}
265	rs.Contexts = NewProjectsAgentEnvironmentsUsersSessionsContextsService(s)
266	rs.EntityTypes = NewProjectsAgentEnvironmentsUsersSessionsEntityTypesService(s)
267	return rs
268}
269
270type ProjectsAgentEnvironmentsUsersSessionsService struct {
271	s *Service
272
273	Contexts *ProjectsAgentEnvironmentsUsersSessionsContextsService
274
275	EntityTypes *ProjectsAgentEnvironmentsUsersSessionsEntityTypesService
276}
277
278func NewProjectsAgentEnvironmentsUsersSessionsContextsService(s *Service) *ProjectsAgentEnvironmentsUsersSessionsContextsService {
279	rs := &ProjectsAgentEnvironmentsUsersSessionsContextsService{s: s}
280	return rs
281}
282
283type ProjectsAgentEnvironmentsUsersSessionsContextsService struct {
284	s *Service
285}
286
287func NewProjectsAgentEnvironmentsUsersSessionsEntityTypesService(s *Service) *ProjectsAgentEnvironmentsUsersSessionsEntityTypesService {
288	rs := &ProjectsAgentEnvironmentsUsersSessionsEntityTypesService{s: s}
289	return rs
290}
291
292type ProjectsAgentEnvironmentsUsersSessionsEntityTypesService struct {
293	s *Service
294}
295
296func NewProjectsAgentIntentsService(s *Service) *ProjectsAgentIntentsService {
297	rs := &ProjectsAgentIntentsService{s: s}
298	return rs
299}
300
301type ProjectsAgentIntentsService struct {
302	s *Service
303}
304
305func NewProjectsAgentKnowledgeBasesService(s *Service) *ProjectsAgentKnowledgeBasesService {
306	rs := &ProjectsAgentKnowledgeBasesService{s: s}
307	rs.Documents = NewProjectsAgentKnowledgeBasesDocumentsService(s)
308	return rs
309}
310
311type ProjectsAgentKnowledgeBasesService struct {
312	s *Service
313
314	Documents *ProjectsAgentKnowledgeBasesDocumentsService
315}
316
317func NewProjectsAgentKnowledgeBasesDocumentsService(s *Service) *ProjectsAgentKnowledgeBasesDocumentsService {
318	rs := &ProjectsAgentKnowledgeBasesDocumentsService{s: s}
319	return rs
320}
321
322type ProjectsAgentKnowledgeBasesDocumentsService struct {
323	s *Service
324}
325
326func NewProjectsAgentSessionsService(s *Service) *ProjectsAgentSessionsService {
327	rs := &ProjectsAgentSessionsService{s: s}
328	rs.Contexts = NewProjectsAgentSessionsContextsService(s)
329	rs.EntityTypes = NewProjectsAgentSessionsEntityTypesService(s)
330	return rs
331}
332
333type ProjectsAgentSessionsService struct {
334	s *Service
335
336	Contexts *ProjectsAgentSessionsContextsService
337
338	EntityTypes *ProjectsAgentSessionsEntityTypesService
339}
340
341func NewProjectsAgentSessionsContextsService(s *Service) *ProjectsAgentSessionsContextsService {
342	rs := &ProjectsAgentSessionsContextsService{s: s}
343	return rs
344}
345
346type ProjectsAgentSessionsContextsService struct {
347	s *Service
348}
349
350func NewProjectsAgentSessionsEntityTypesService(s *Service) *ProjectsAgentSessionsEntityTypesService {
351	rs := &ProjectsAgentSessionsEntityTypesService{s: s}
352	return rs
353}
354
355type ProjectsAgentSessionsEntityTypesService struct {
356	s *Service
357}
358
359func NewProjectsAgentVersionsService(s *Service) *ProjectsAgentVersionsService {
360	rs := &ProjectsAgentVersionsService{s: s}
361	return rs
362}
363
364type ProjectsAgentVersionsService struct {
365	s *Service
366}
367
368func NewProjectsAnswerRecordsService(s *Service) *ProjectsAnswerRecordsService {
369	rs := &ProjectsAnswerRecordsService{s: s}
370	return rs
371}
372
373type ProjectsAnswerRecordsService struct {
374	s *Service
375}
376
377func NewProjectsConversationProfilesService(s *Service) *ProjectsConversationProfilesService {
378	rs := &ProjectsConversationProfilesService{s: s}
379	return rs
380}
381
382type ProjectsConversationProfilesService struct {
383	s *Service
384}
385
386func NewProjectsConversationsService(s *Service) *ProjectsConversationsService {
387	rs := &ProjectsConversationsService{s: s}
388	rs.Messages = NewProjectsConversationsMessagesService(s)
389	rs.Participants = NewProjectsConversationsParticipantsService(s)
390	return rs
391}
392
393type ProjectsConversationsService struct {
394	s *Service
395
396	Messages *ProjectsConversationsMessagesService
397
398	Participants *ProjectsConversationsParticipantsService
399}
400
401func NewProjectsConversationsMessagesService(s *Service) *ProjectsConversationsMessagesService {
402	rs := &ProjectsConversationsMessagesService{s: s}
403	return rs
404}
405
406type ProjectsConversationsMessagesService struct {
407	s *Service
408}
409
410func NewProjectsConversationsParticipantsService(s *Service) *ProjectsConversationsParticipantsService {
411	rs := &ProjectsConversationsParticipantsService{s: s}
412	rs.Suggestions = NewProjectsConversationsParticipantsSuggestionsService(s)
413	return rs
414}
415
416type ProjectsConversationsParticipantsService struct {
417	s *Service
418
419	Suggestions *ProjectsConversationsParticipantsSuggestionsService
420}
421
422func NewProjectsConversationsParticipantsSuggestionsService(s *Service) *ProjectsConversationsParticipantsSuggestionsService {
423	rs := &ProjectsConversationsParticipantsSuggestionsService{s: s}
424	return rs
425}
426
427type ProjectsConversationsParticipantsSuggestionsService struct {
428	s *Service
429}
430
431func NewProjectsKnowledgeBasesService(s *Service) *ProjectsKnowledgeBasesService {
432	rs := &ProjectsKnowledgeBasesService{s: s}
433	rs.Documents = NewProjectsKnowledgeBasesDocumentsService(s)
434	return rs
435}
436
437type ProjectsKnowledgeBasesService struct {
438	s *Service
439
440	Documents *ProjectsKnowledgeBasesDocumentsService
441}
442
443func NewProjectsKnowledgeBasesDocumentsService(s *Service) *ProjectsKnowledgeBasesDocumentsService {
444	rs := &ProjectsKnowledgeBasesDocumentsService{s: s}
445	return rs
446}
447
448type ProjectsKnowledgeBasesDocumentsService struct {
449	s *Service
450}
451
452func NewProjectsLocationsService(s *Service) *ProjectsLocationsService {
453	rs := &ProjectsLocationsService{s: s}
454	rs.Agent = NewProjectsLocationsAgentService(s)
455	rs.AnswerRecords = NewProjectsLocationsAnswerRecordsService(s)
456	rs.ConversationProfiles = NewProjectsLocationsConversationProfilesService(s)
457	rs.Conversations = NewProjectsLocationsConversationsService(s)
458	rs.KnowledgeBases = NewProjectsLocationsKnowledgeBasesService(s)
459	rs.Operations = NewProjectsLocationsOperationsService(s)
460	return rs
461}
462
463type ProjectsLocationsService struct {
464	s *Service
465
466	Agent *ProjectsLocationsAgentService
467
468	AnswerRecords *ProjectsLocationsAnswerRecordsService
469
470	ConversationProfiles *ProjectsLocationsConversationProfilesService
471
472	Conversations *ProjectsLocationsConversationsService
473
474	KnowledgeBases *ProjectsLocationsKnowledgeBasesService
475
476	Operations *ProjectsLocationsOperationsService
477}
478
479func NewProjectsLocationsAgentService(s *Service) *ProjectsLocationsAgentService {
480	rs := &ProjectsLocationsAgentService{s: s}
481	rs.EntityTypes = NewProjectsLocationsAgentEntityTypesService(s)
482	rs.Environments = NewProjectsLocationsAgentEnvironmentsService(s)
483	rs.Intents = NewProjectsLocationsAgentIntentsService(s)
484	rs.Sessions = NewProjectsLocationsAgentSessionsService(s)
485	rs.Versions = NewProjectsLocationsAgentVersionsService(s)
486	return rs
487}
488
489type ProjectsLocationsAgentService struct {
490	s *Service
491
492	EntityTypes *ProjectsLocationsAgentEntityTypesService
493
494	Environments *ProjectsLocationsAgentEnvironmentsService
495
496	Intents *ProjectsLocationsAgentIntentsService
497
498	Sessions *ProjectsLocationsAgentSessionsService
499
500	Versions *ProjectsLocationsAgentVersionsService
501}
502
503func NewProjectsLocationsAgentEntityTypesService(s *Service) *ProjectsLocationsAgentEntityTypesService {
504	rs := &ProjectsLocationsAgentEntityTypesService{s: s}
505	rs.Entities = NewProjectsLocationsAgentEntityTypesEntitiesService(s)
506	return rs
507}
508
509type ProjectsLocationsAgentEntityTypesService struct {
510	s *Service
511
512	Entities *ProjectsLocationsAgentEntityTypesEntitiesService
513}
514
515func NewProjectsLocationsAgentEntityTypesEntitiesService(s *Service) *ProjectsLocationsAgentEntityTypesEntitiesService {
516	rs := &ProjectsLocationsAgentEntityTypesEntitiesService{s: s}
517	return rs
518}
519
520type ProjectsLocationsAgentEntityTypesEntitiesService struct {
521	s *Service
522}
523
524func NewProjectsLocationsAgentEnvironmentsService(s *Service) *ProjectsLocationsAgentEnvironmentsService {
525	rs := &ProjectsLocationsAgentEnvironmentsService{s: s}
526	rs.Intents = NewProjectsLocationsAgentEnvironmentsIntentsService(s)
527	rs.Users = NewProjectsLocationsAgentEnvironmentsUsersService(s)
528	return rs
529}
530
531type ProjectsLocationsAgentEnvironmentsService struct {
532	s *Service
533
534	Intents *ProjectsLocationsAgentEnvironmentsIntentsService
535
536	Users *ProjectsLocationsAgentEnvironmentsUsersService
537}
538
539func NewProjectsLocationsAgentEnvironmentsIntentsService(s *Service) *ProjectsLocationsAgentEnvironmentsIntentsService {
540	rs := &ProjectsLocationsAgentEnvironmentsIntentsService{s: s}
541	return rs
542}
543
544type ProjectsLocationsAgentEnvironmentsIntentsService struct {
545	s *Service
546}
547
548func NewProjectsLocationsAgentEnvironmentsUsersService(s *Service) *ProjectsLocationsAgentEnvironmentsUsersService {
549	rs := &ProjectsLocationsAgentEnvironmentsUsersService{s: s}
550	rs.Sessions = NewProjectsLocationsAgentEnvironmentsUsersSessionsService(s)
551	return rs
552}
553
554type ProjectsLocationsAgentEnvironmentsUsersService struct {
555	s *Service
556
557	Sessions *ProjectsLocationsAgentEnvironmentsUsersSessionsService
558}
559
560func NewProjectsLocationsAgentEnvironmentsUsersSessionsService(s *Service) *ProjectsLocationsAgentEnvironmentsUsersSessionsService {
561	rs := &ProjectsLocationsAgentEnvironmentsUsersSessionsService{s: s}
562	rs.Contexts = NewProjectsLocationsAgentEnvironmentsUsersSessionsContextsService(s)
563	rs.EntityTypes = NewProjectsLocationsAgentEnvironmentsUsersSessionsEntityTypesService(s)
564	return rs
565}
566
567type ProjectsLocationsAgentEnvironmentsUsersSessionsService struct {
568	s *Service
569
570	Contexts *ProjectsLocationsAgentEnvironmentsUsersSessionsContextsService
571
572	EntityTypes *ProjectsLocationsAgentEnvironmentsUsersSessionsEntityTypesService
573}
574
575func NewProjectsLocationsAgentEnvironmentsUsersSessionsContextsService(s *Service) *ProjectsLocationsAgentEnvironmentsUsersSessionsContextsService {
576	rs := &ProjectsLocationsAgentEnvironmentsUsersSessionsContextsService{s: s}
577	return rs
578}
579
580type ProjectsLocationsAgentEnvironmentsUsersSessionsContextsService struct {
581	s *Service
582}
583
584func NewProjectsLocationsAgentEnvironmentsUsersSessionsEntityTypesService(s *Service) *ProjectsLocationsAgentEnvironmentsUsersSessionsEntityTypesService {
585	rs := &ProjectsLocationsAgentEnvironmentsUsersSessionsEntityTypesService{s: s}
586	return rs
587}
588
589type ProjectsLocationsAgentEnvironmentsUsersSessionsEntityTypesService struct {
590	s *Service
591}
592
593func NewProjectsLocationsAgentIntentsService(s *Service) *ProjectsLocationsAgentIntentsService {
594	rs := &ProjectsLocationsAgentIntentsService{s: s}
595	return rs
596}
597
598type ProjectsLocationsAgentIntentsService struct {
599	s *Service
600}
601
602func NewProjectsLocationsAgentSessionsService(s *Service) *ProjectsLocationsAgentSessionsService {
603	rs := &ProjectsLocationsAgentSessionsService{s: s}
604	rs.Contexts = NewProjectsLocationsAgentSessionsContextsService(s)
605	rs.EntityTypes = NewProjectsLocationsAgentSessionsEntityTypesService(s)
606	return rs
607}
608
609type ProjectsLocationsAgentSessionsService struct {
610	s *Service
611
612	Contexts *ProjectsLocationsAgentSessionsContextsService
613
614	EntityTypes *ProjectsLocationsAgentSessionsEntityTypesService
615}
616
617func NewProjectsLocationsAgentSessionsContextsService(s *Service) *ProjectsLocationsAgentSessionsContextsService {
618	rs := &ProjectsLocationsAgentSessionsContextsService{s: s}
619	return rs
620}
621
622type ProjectsLocationsAgentSessionsContextsService struct {
623	s *Service
624}
625
626func NewProjectsLocationsAgentSessionsEntityTypesService(s *Service) *ProjectsLocationsAgentSessionsEntityTypesService {
627	rs := &ProjectsLocationsAgentSessionsEntityTypesService{s: s}
628	return rs
629}
630
631type ProjectsLocationsAgentSessionsEntityTypesService struct {
632	s *Service
633}
634
635func NewProjectsLocationsAgentVersionsService(s *Service) *ProjectsLocationsAgentVersionsService {
636	rs := &ProjectsLocationsAgentVersionsService{s: s}
637	return rs
638}
639
640type ProjectsLocationsAgentVersionsService struct {
641	s *Service
642}
643
644func NewProjectsLocationsAnswerRecordsService(s *Service) *ProjectsLocationsAnswerRecordsService {
645	rs := &ProjectsLocationsAnswerRecordsService{s: s}
646	return rs
647}
648
649type ProjectsLocationsAnswerRecordsService struct {
650	s *Service
651}
652
653func NewProjectsLocationsConversationProfilesService(s *Service) *ProjectsLocationsConversationProfilesService {
654	rs := &ProjectsLocationsConversationProfilesService{s: s}
655	return rs
656}
657
658type ProjectsLocationsConversationProfilesService struct {
659	s *Service
660}
661
662func NewProjectsLocationsConversationsService(s *Service) *ProjectsLocationsConversationsService {
663	rs := &ProjectsLocationsConversationsService{s: s}
664	rs.Messages = NewProjectsLocationsConversationsMessagesService(s)
665	rs.Participants = NewProjectsLocationsConversationsParticipantsService(s)
666	return rs
667}
668
669type ProjectsLocationsConversationsService struct {
670	s *Service
671
672	Messages *ProjectsLocationsConversationsMessagesService
673
674	Participants *ProjectsLocationsConversationsParticipantsService
675}
676
677func NewProjectsLocationsConversationsMessagesService(s *Service) *ProjectsLocationsConversationsMessagesService {
678	rs := &ProjectsLocationsConversationsMessagesService{s: s}
679	return rs
680}
681
682type ProjectsLocationsConversationsMessagesService struct {
683	s *Service
684}
685
686func NewProjectsLocationsConversationsParticipantsService(s *Service) *ProjectsLocationsConversationsParticipantsService {
687	rs := &ProjectsLocationsConversationsParticipantsService{s: s}
688	rs.Suggestions = NewProjectsLocationsConversationsParticipantsSuggestionsService(s)
689	return rs
690}
691
692type ProjectsLocationsConversationsParticipantsService struct {
693	s *Service
694
695	Suggestions *ProjectsLocationsConversationsParticipantsSuggestionsService
696}
697
698func NewProjectsLocationsConversationsParticipantsSuggestionsService(s *Service) *ProjectsLocationsConversationsParticipantsSuggestionsService {
699	rs := &ProjectsLocationsConversationsParticipantsSuggestionsService{s: s}
700	return rs
701}
702
703type ProjectsLocationsConversationsParticipantsSuggestionsService struct {
704	s *Service
705}
706
707func NewProjectsLocationsKnowledgeBasesService(s *Service) *ProjectsLocationsKnowledgeBasesService {
708	rs := &ProjectsLocationsKnowledgeBasesService{s: s}
709	rs.Documents = NewProjectsLocationsKnowledgeBasesDocumentsService(s)
710	return rs
711}
712
713type ProjectsLocationsKnowledgeBasesService struct {
714	s *Service
715
716	Documents *ProjectsLocationsKnowledgeBasesDocumentsService
717}
718
719func NewProjectsLocationsKnowledgeBasesDocumentsService(s *Service) *ProjectsLocationsKnowledgeBasesDocumentsService {
720	rs := &ProjectsLocationsKnowledgeBasesDocumentsService{s: s}
721	return rs
722}
723
724type ProjectsLocationsKnowledgeBasesDocumentsService struct {
725	s *Service
726}
727
728func NewProjectsLocationsOperationsService(s *Service) *ProjectsLocationsOperationsService {
729	rs := &ProjectsLocationsOperationsService{s: s}
730	return rs
731}
732
733type ProjectsLocationsOperationsService struct {
734	s *Service
735}
736
737func NewProjectsOperationsService(s *Service) *ProjectsOperationsService {
738	rs := &ProjectsOperationsService{s: s}
739	return rs
740}
741
742type ProjectsOperationsService struct {
743	s *Service
744}
745
746// GoogleCloudDialogflowCxV3AudioInput: Represents the natural speech
747// audio to be processed.
748type GoogleCloudDialogflowCxV3AudioInput struct {
749	// Audio: The natural language speech audio to be processed. A single
750	// request can contain up to 1 minute of speech audio data. The
751	// transcribed text cannot contain more than 256 bytes. For
752	// non-streaming audio detect intent, both `config` and `audio` must be
753	// provided. For streaming audio detect intent, `config` must be
754	// provided in the first request and `audio` must be provided in all
755	// following requests.
756	Audio string `json:"audio,omitempty"`
757
758	// Config: Required. Instructs the speech recognizer how to process the
759	// speech audio.
760	Config *GoogleCloudDialogflowCxV3InputAudioConfig `json:"config,omitempty"`
761
762	// ForceSendFields is a list of field names (e.g. "Audio") to
763	// unconditionally include in API requests. By default, fields with
764	// empty or default values are omitted from API requests. However, any
765	// non-pointer, non-interface field appearing in ForceSendFields will be
766	// sent to the server regardless of whether the field is empty or not.
767	// This may be used to include empty fields in Patch requests.
768	ForceSendFields []string `json:"-"`
769
770	// NullFields is a list of field names (e.g. "Audio") to include in API
771	// requests with the JSON null value. By default, fields with empty
772	// values are omitted from API requests. However, any field with an
773	// empty value appearing in NullFields will be sent to the server as
774	// null. It is an error if a field in this list has a non-empty value.
775	// This may be used to include null fields in Patch requests.
776	NullFields []string `json:"-"`
777}
778
779func (s *GoogleCloudDialogflowCxV3AudioInput) MarshalJSON() ([]byte, error) {
780	type NoMethod GoogleCloudDialogflowCxV3AudioInput
781	raw := NoMethod(*s)
782	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
783}
784
785// GoogleCloudDialogflowCxV3BatchRunTestCasesMetadata: Metadata returned
786// for the TestCases.BatchRunTestCases long running operation.
787type GoogleCloudDialogflowCxV3BatchRunTestCasesMetadata struct {
788	// Errors: The test errors.
789	Errors []*GoogleCloudDialogflowCxV3TestError `json:"errors,omitempty"`
790
791	// ForceSendFields is a list of field names (e.g. "Errors") to
792	// unconditionally include in API requests. By default, fields with
793	// empty or default values are omitted from API requests. However, any
794	// non-pointer, non-interface field appearing in ForceSendFields will be
795	// sent to the server regardless of whether the field is empty or not.
796	// This may be used to include empty fields in Patch requests.
797	ForceSendFields []string `json:"-"`
798
799	// NullFields is a list of field names (e.g. "Errors") to include in API
800	// requests with the JSON null value. By default, fields with empty
801	// values are omitted from API requests. However, any field with an
802	// empty value appearing in NullFields will be sent to the server as
803	// null. It is an error if a field in this list has a non-empty value.
804	// This may be used to include null fields in Patch requests.
805	NullFields []string `json:"-"`
806}
807
808func (s *GoogleCloudDialogflowCxV3BatchRunTestCasesMetadata) MarshalJSON() ([]byte, error) {
809	type NoMethod GoogleCloudDialogflowCxV3BatchRunTestCasesMetadata
810	raw := NoMethod(*s)
811	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
812}
813
814// GoogleCloudDialogflowCxV3BatchRunTestCasesResponse: The response
815// message for TestCases.BatchRunTestCases.
816type GoogleCloudDialogflowCxV3BatchRunTestCasesResponse struct {
817	// Results: The test case results. The detailed conversation turns are
818	// empty in this response.
819	Results []*GoogleCloudDialogflowCxV3TestCaseResult `json:"results,omitempty"`
820
821	// ForceSendFields is a list of field names (e.g. "Results") to
822	// unconditionally include in API requests. By default, fields with
823	// empty or default values are omitted from API requests. However, any
824	// non-pointer, non-interface field appearing in ForceSendFields will be
825	// sent to the server regardless of whether the field is empty or not.
826	// This may be used to include empty fields in Patch requests.
827	ForceSendFields []string `json:"-"`
828
829	// NullFields is a list of field names (e.g. "Results") to include in
830	// API requests with the JSON null value. By default, fields with empty
831	// values are omitted from API requests. However, any field with an
832	// empty value appearing in NullFields will be sent to the server as
833	// null. It is an error if a field in this list has a non-empty value.
834	// This may be used to include null fields in Patch requests.
835	NullFields []string `json:"-"`
836}
837
838func (s *GoogleCloudDialogflowCxV3BatchRunTestCasesResponse) MarshalJSON() ([]byte, error) {
839	type NoMethod GoogleCloudDialogflowCxV3BatchRunTestCasesResponse
840	raw := NoMethod(*s)
841	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
842}
843
844// GoogleCloudDialogflowCxV3ContinuousTestResult: Represents a result
845// from running a test case in an agent environment.
846type GoogleCloudDialogflowCxV3ContinuousTestResult struct {
847	// Name: The resource name for the continuous test result. Format:
848	// `projects//locations//agents//environments//continuousTestResults/`.
849	Name string `json:"name,omitempty"`
850
851	// Result: The result of this continuous test run, i.e. whether all the
852	// tests in this continuous test run pass or not.
853	//
854	// Possible values:
855	//   "AGGREGATED_TEST_RESULT_UNSPECIFIED" - Not specified. Should never
856	// be used.
857	//   "PASSED" - All the tests passed.
858	//   "FAILED" - At least one test did not pass.
859	Result string `json:"result,omitempty"`
860
861	// RunTime: Time when the continuous testing run starts.
862	RunTime string `json:"runTime,omitempty"`
863
864	// TestCaseResults: A list of individual test case results names in this
865	// continuous test run.
866	TestCaseResults []string `json:"testCaseResults,omitempty"`
867
868	// ForceSendFields is a list of field names (e.g. "Name") to
869	// unconditionally include in API requests. By default, fields with
870	// empty or default values are omitted from API requests. However, any
871	// non-pointer, non-interface field appearing in ForceSendFields will be
872	// sent to the server regardless of whether the field is empty or not.
873	// This may be used to include empty fields in Patch requests.
874	ForceSendFields []string `json:"-"`
875
876	// NullFields is a list of field names (e.g. "Name") to include in API
877	// requests with the JSON null value. By default, fields with empty
878	// values are omitted from API requests. However, any field with an
879	// empty value appearing in NullFields will be sent to the server as
880	// null. It is an error if a field in this list has a non-empty value.
881	// This may be used to include null fields in Patch requests.
882	NullFields []string `json:"-"`
883}
884
885func (s *GoogleCloudDialogflowCxV3ContinuousTestResult) MarshalJSON() ([]byte, error) {
886	type NoMethod GoogleCloudDialogflowCxV3ContinuousTestResult
887	raw := NoMethod(*s)
888	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
889}
890
891// GoogleCloudDialogflowCxV3ConversationTurn: One interaction between a
892// human and virtual agent. The human provides some input and the
893// virtual agent provides a response.
894type GoogleCloudDialogflowCxV3ConversationTurn struct {
895	// UserInput: The user input.
896	UserInput *GoogleCloudDialogflowCxV3ConversationTurnUserInput `json:"userInput,omitempty"`
897
898	// VirtualAgentOutput: The virtual agent output.
899	VirtualAgentOutput *GoogleCloudDialogflowCxV3ConversationTurnVirtualAgentOutput `json:"virtualAgentOutput,omitempty"`
900
901	// ForceSendFields is a list of field names (e.g. "UserInput") to
902	// unconditionally include in API requests. By default, fields with
903	// empty or default values are omitted from API requests. However, any
904	// non-pointer, non-interface field appearing in ForceSendFields will be
905	// sent to the server regardless of whether the field is empty or not.
906	// This may be used to include empty fields in Patch requests.
907	ForceSendFields []string `json:"-"`
908
909	// NullFields is a list of field names (e.g. "UserInput") to include in
910	// API requests with the JSON null value. By default, fields with empty
911	// values are omitted from API requests. However, any field with an
912	// empty value appearing in NullFields will be sent to the server as
913	// null. It is an error if a field in this list has a non-empty value.
914	// This may be used to include null fields in Patch requests.
915	NullFields []string `json:"-"`
916}
917
918func (s *GoogleCloudDialogflowCxV3ConversationTurn) MarshalJSON() ([]byte, error) {
919	type NoMethod GoogleCloudDialogflowCxV3ConversationTurn
920	raw := NoMethod(*s)
921	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
922}
923
924// GoogleCloudDialogflowCxV3ConversationTurnUserInput: The input from
925// the human user.
926type GoogleCloudDialogflowCxV3ConversationTurnUserInput struct {
927	// EnableSentimentAnalysis: Whether sentiment analysis is enabled.
928	EnableSentimentAnalysis bool `json:"enableSentimentAnalysis,omitempty"`
929
930	// InjectedParameters: Parameters that need to be injected into the
931	// conversation during intent detection.
932	InjectedParameters googleapi.RawMessage `json:"injectedParameters,omitempty"`
933
934	// Input: Supports text input, event input, dtmf input in the test case.
935	Input *GoogleCloudDialogflowCxV3QueryInput `json:"input,omitempty"`
936
937	// IsWebhookEnabled: If webhooks should be allowed to trigger in
938	// response to the user utterance. Often if parameters are injected,
939	// webhooks should not be enabled.
940	IsWebhookEnabled bool `json:"isWebhookEnabled,omitempty"`
941
942	// ForceSendFields is a list of field names (e.g.
943	// "EnableSentimentAnalysis") to unconditionally include in API
944	// requests. By default, fields with empty or default values are omitted
945	// from API requests. However, any non-pointer, non-interface field
946	// appearing in ForceSendFields will be sent to the server regardless of
947	// whether the field is empty or not. This may be used to include empty
948	// fields in Patch requests.
949	ForceSendFields []string `json:"-"`
950
951	// NullFields is a list of field names (e.g. "EnableSentimentAnalysis")
952	// to include in API requests with the JSON null value. By default,
953	// fields with empty values are omitted from API requests. However, any
954	// field with an empty value appearing in NullFields will be sent to the
955	// server as null. It is an error if a field in this list has a
956	// non-empty value. This may be used to include null fields in Patch
957	// requests.
958	NullFields []string `json:"-"`
959}
960
961func (s *GoogleCloudDialogflowCxV3ConversationTurnUserInput) MarshalJSON() ([]byte, error) {
962	type NoMethod GoogleCloudDialogflowCxV3ConversationTurnUserInput
963	raw := NoMethod(*s)
964	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
965}
966
967// GoogleCloudDialogflowCxV3ConversationTurnVirtualAgentOutput: The
968// output from the virtual agent.
969type GoogleCloudDialogflowCxV3ConversationTurnVirtualAgentOutput struct {
970	// CurrentPage: The Page on which the utterance was spoken. Only name
971	// and displayName will be set.
972	CurrentPage *GoogleCloudDialogflowCxV3Page `json:"currentPage,omitempty"`
973
974	// DiagnosticInfo: Required. Input only. The diagnostic info output for
975	// the turn. Required to calculate the testing coverage.
976	DiagnosticInfo googleapi.RawMessage `json:"diagnosticInfo,omitempty"`
977
978	// Differences: Output only. If this is part of a result conversation
979	// turn, the list of differences between the original run and the replay
980	// for this output, if any.
981	Differences []*GoogleCloudDialogflowCxV3TestRunDifference `json:"differences,omitempty"`
982
983	// SessionParameters: The session parameters available to the bot at
984	// this point.
985	SessionParameters googleapi.RawMessage `json:"sessionParameters,omitempty"`
986
987	// Status: Response error from the agent in the test result. If set,
988	// other output is empty.
989	Status *GoogleRpcStatus `json:"status,omitempty"`
990
991	// TextResponses: The text responses from the agent for the turn.
992	TextResponses []*GoogleCloudDialogflowCxV3ResponseMessageText `json:"textResponses,omitempty"`
993
994	// TriggeredIntent: The Intent that triggered the response. Only name
995	// and displayName will be set.
996	TriggeredIntent *GoogleCloudDialogflowCxV3Intent `json:"triggeredIntent,omitempty"`
997
998	// ForceSendFields is a list of field names (e.g. "CurrentPage") to
999	// unconditionally include in API requests. By default, fields with
1000	// empty or default values are omitted from API requests. However, any
1001	// non-pointer, non-interface field appearing in ForceSendFields will be
1002	// sent to the server regardless of whether the field is empty or not.
1003	// This may be used to include empty fields in Patch requests.
1004	ForceSendFields []string `json:"-"`
1005
1006	// NullFields is a list of field names (e.g. "CurrentPage") to include
1007	// in API requests with the JSON null value. By default, fields with
1008	// empty values are omitted from API requests. However, any field with
1009	// an empty value appearing in NullFields will be sent to the server as
1010	// null. It is an error if a field in this list has a non-empty value.
1011	// This may be used to include null fields in Patch requests.
1012	NullFields []string `json:"-"`
1013}
1014
1015func (s *GoogleCloudDialogflowCxV3ConversationTurnVirtualAgentOutput) MarshalJSON() ([]byte, error) {
1016	type NoMethod GoogleCloudDialogflowCxV3ConversationTurnVirtualAgentOutput
1017	raw := NoMethod(*s)
1018	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
1019}
1020
1021// GoogleCloudDialogflowCxV3CreateDocumentOperationMetadata: Metadata
1022// for CreateDocument operation.
1023type GoogleCloudDialogflowCxV3CreateDocumentOperationMetadata struct {
1024	// GenericMetadata: The generic information of the operation.
1025	GenericMetadata *GoogleCloudDialogflowCxV3GenericKnowledgeOperationMetadata `json:"genericMetadata,omitempty"`
1026
1027	// ForceSendFields is a list of field names (e.g. "GenericMetadata") to
1028	// unconditionally include in API requests. By default, fields with
1029	// empty or default values are omitted from API requests. However, any
1030	// non-pointer, non-interface field appearing in ForceSendFields will be
1031	// sent to the server regardless of whether the field is empty or not.
1032	// This may be used to include empty fields in Patch requests.
1033	ForceSendFields []string `json:"-"`
1034
1035	// NullFields is a list of field names (e.g. "GenericMetadata") to
1036	// include in API requests with the JSON null value. By default, fields
1037	// with empty values are omitted from API requests. However, any field
1038	// with an empty value appearing in NullFields will be sent to the
1039	// server as null. It is an error if a field in this list has a
1040	// non-empty value. This may be used to include null fields in Patch
1041	// requests.
1042	NullFields []string `json:"-"`
1043}
1044
1045func (s *GoogleCloudDialogflowCxV3CreateDocumentOperationMetadata) MarshalJSON() ([]byte, error) {
1046	type NoMethod GoogleCloudDialogflowCxV3CreateDocumentOperationMetadata
1047	raw := NoMethod(*s)
1048	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
1049}
1050
1051// GoogleCloudDialogflowCxV3CreateVersionOperationMetadata: Metadata
1052// associated with the long running operation for
1053// Versions.CreateVersion.
1054type GoogleCloudDialogflowCxV3CreateVersionOperationMetadata struct {
1055	// Version: Name of the created version. Format:
1056	// `projects//locations//agents//flows//versions/`.
1057	Version string `json:"version,omitempty"`
1058
1059	// ForceSendFields is a list of field names (e.g. "Version") to
1060	// unconditionally include in API requests. By default, fields with
1061	// empty or default values are omitted from API requests. However, any
1062	// non-pointer, non-interface field appearing in ForceSendFields will be
1063	// sent to the server regardless of whether the field is empty or not.
1064	// This may be used to include empty fields in Patch requests.
1065	ForceSendFields []string `json:"-"`
1066
1067	// NullFields is a list of field names (e.g. "Version") to include in
1068	// API requests with the JSON null value. By default, fields with empty
1069	// values are omitted from API requests. However, any field with an
1070	// empty value appearing in NullFields will be sent to the server as
1071	// null. It is an error if a field in this list has a non-empty value.
1072	// This may be used to include null fields in Patch requests.
1073	NullFields []string `json:"-"`
1074}
1075
1076func (s *GoogleCloudDialogflowCxV3CreateVersionOperationMetadata) MarshalJSON() ([]byte, error) {
1077	type NoMethod GoogleCloudDialogflowCxV3CreateVersionOperationMetadata
1078	raw := NoMethod(*s)
1079	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
1080}
1081
1082// GoogleCloudDialogflowCxV3DeleteDocumentOperationMetadata: Metadata
1083// for DeleteDocument operation.
1084type GoogleCloudDialogflowCxV3DeleteDocumentOperationMetadata struct {
1085	// GenericMetadata: The generic information of the operation.
1086	GenericMetadata *GoogleCloudDialogflowCxV3GenericKnowledgeOperationMetadata `json:"genericMetadata,omitempty"`
1087
1088	// ForceSendFields is a list of field names (e.g. "GenericMetadata") to
1089	// unconditionally include in API requests. By default, fields with
1090	// empty or default values are omitted from API requests. However, any
1091	// non-pointer, non-interface field appearing in ForceSendFields will be
1092	// sent to the server regardless of whether the field is empty or not.
1093	// This may be used to include empty fields in Patch requests.
1094	ForceSendFields []string `json:"-"`
1095
1096	// NullFields is a list of field names (e.g. "GenericMetadata") to
1097	// include in API requests with the JSON null value. By default, fields
1098	// with empty values are omitted from API requests. However, any field
1099	// with an empty value appearing in NullFields will be sent to the
1100	// server as null. It is an error if a field in this list has a
1101	// non-empty value. This may be used to include null fields in Patch
1102	// requests.
1103	NullFields []string `json:"-"`
1104}
1105
1106func (s *GoogleCloudDialogflowCxV3DeleteDocumentOperationMetadata) MarshalJSON() ([]byte, error) {
1107	type NoMethod GoogleCloudDialogflowCxV3DeleteDocumentOperationMetadata
1108	raw := NoMethod(*s)
1109	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
1110}
1111
1112// GoogleCloudDialogflowCxV3DeployFlowMetadata: Metadata returned for
1113// the Environments.DeployFlow long running operation.
1114type GoogleCloudDialogflowCxV3DeployFlowMetadata struct {
1115	// TestErrors: Errors of running deployment tests.
1116	TestErrors []*GoogleCloudDialogflowCxV3TestError `json:"testErrors,omitempty"`
1117
1118	// ForceSendFields is a list of field names (e.g. "TestErrors") to
1119	// unconditionally include in API requests. By default, fields with
1120	// empty or default values are omitted from API requests. However, any
1121	// non-pointer, non-interface field appearing in ForceSendFields will be
1122	// sent to the server regardless of whether the field is empty or not.
1123	// This may be used to include empty fields in Patch requests.
1124	ForceSendFields []string `json:"-"`
1125
1126	// NullFields is a list of field names (e.g. "TestErrors") to include in
1127	// API requests with the JSON null value. By default, fields with empty
1128	// values are omitted from API requests. However, any field with an
1129	// empty value appearing in NullFields will be sent to the server as
1130	// null. It is an error if a field in this list has a non-empty value.
1131	// This may be used to include null fields in Patch requests.
1132	NullFields []string `json:"-"`
1133}
1134
1135func (s *GoogleCloudDialogflowCxV3DeployFlowMetadata) MarshalJSON() ([]byte, error) {
1136	type NoMethod GoogleCloudDialogflowCxV3DeployFlowMetadata
1137	raw := NoMethod(*s)
1138	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
1139}
1140
1141// GoogleCloudDialogflowCxV3DeployFlowResponse: The response message for
1142// Environments.DeployFlow.
1143type GoogleCloudDialogflowCxV3DeployFlowResponse struct {
1144	// Deployment: The name of the flow version Deployment. Format:
1145	// `projects//locations//agents// environments//deployments/`.
1146	Deployment string `json:"deployment,omitempty"`
1147
1148	// Environment: The updated environment where the flow is deployed.
1149	Environment *GoogleCloudDialogflowCxV3Environment `json:"environment,omitempty"`
1150
1151	// ForceSendFields is a list of field names (e.g. "Deployment") to
1152	// unconditionally include in API requests. By default, fields with
1153	// empty or default values are omitted from API requests. However, any
1154	// non-pointer, non-interface field appearing in ForceSendFields will be
1155	// sent to the server regardless of whether the field is empty or not.
1156	// This may be used to include empty fields in Patch requests.
1157	ForceSendFields []string `json:"-"`
1158
1159	// NullFields is a list of field names (e.g. "Deployment") to include in
1160	// API requests with the JSON null value. By default, fields with empty
1161	// values are omitted from API requests. However, any field with an
1162	// empty value appearing in NullFields will be sent to the server as
1163	// null. It is an error if a field in this list has a non-empty value.
1164	// This may be used to include null fields in Patch requests.
1165	NullFields []string `json:"-"`
1166}
1167
1168func (s *GoogleCloudDialogflowCxV3DeployFlowResponse) MarshalJSON() ([]byte, error) {
1169	type NoMethod GoogleCloudDialogflowCxV3DeployFlowResponse
1170	raw := NoMethod(*s)
1171	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
1172}
1173
1174// GoogleCloudDialogflowCxV3DtmfInput: Represents the input for dtmf
1175// event.
1176type GoogleCloudDialogflowCxV3DtmfInput struct {
1177	// Digits: The dtmf digits.
1178	Digits string `json:"digits,omitempty"`
1179
1180	// FinishDigit: The finish digit (if any).
1181	FinishDigit string `json:"finishDigit,omitempty"`
1182
1183	// ForceSendFields is a list of field names (e.g. "Digits") to
1184	// unconditionally include in API requests. By default, fields with
1185	// empty or default values are omitted from API requests. However, any
1186	// non-pointer, non-interface field appearing in ForceSendFields will be
1187	// sent to the server regardless of whether the field is empty or not.
1188	// This may be used to include empty fields in Patch requests.
1189	ForceSendFields []string `json:"-"`
1190
1191	// NullFields is a list of field names (e.g. "Digits") to include in API
1192	// requests with the JSON null value. By default, fields with empty
1193	// values are omitted from API requests. However, any field with an
1194	// empty value appearing in NullFields will be sent to the server as
1195	// null. It is an error if a field in this list has a non-empty value.
1196	// This may be used to include null fields in Patch requests.
1197	NullFields []string `json:"-"`
1198}
1199
1200func (s *GoogleCloudDialogflowCxV3DtmfInput) MarshalJSON() ([]byte, error) {
1201	type NoMethod GoogleCloudDialogflowCxV3DtmfInput
1202	raw := NoMethod(*s)
1203	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
1204}
1205
1206// GoogleCloudDialogflowCxV3Environment: Represents an environment for
1207// an agent. You can create multiple versions of your agent and publish
1208// them to separate environments. When you edit an agent, you are
1209// editing the draft agent. At any point, you can save the draft agent
1210// as an agent version, which is an immutable snapshot of your agent.
1211// When you save the draft agent, it is published to the default
1212// environment. When you create agent versions, you can publish them to
1213// custom environments. You can create a variety of custom environments
1214// for testing, development, production, etc.
1215type GoogleCloudDialogflowCxV3Environment struct {
1216	// Description: The human-readable description of the environment. The
1217	// maximum length is 500 characters. If exceeded, the request is
1218	// rejected.
1219	Description string `json:"description,omitempty"`
1220
1221	// DisplayName: Required. The human-readable name of the environment
1222	// (unique in an agent). Limit of 64 characters.
1223	DisplayName string `json:"displayName,omitempty"`
1224
1225	// Name: The name of the environment. Format:
1226	// `projects//locations//agents//environments/`.
1227	Name string `json:"name,omitempty"`
1228
1229	// TestCasesConfig: The test cases config for continuous tests of this
1230	// environment.
1231	TestCasesConfig *GoogleCloudDialogflowCxV3EnvironmentTestCasesConfig `json:"testCasesConfig,omitempty"`
1232
1233	// UpdateTime: Output only. Update time of this environment.
1234	UpdateTime string `json:"updateTime,omitempty"`
1235
1236	// VersionConfigs: Required. A list of configurations for flow versions.
1237	// You should include version configs for all flows that are reachable
1238	// from `Start Flow` in the agent. Otherwise, an error will be returned.
1239	VersionConfigs []*GoogleCloudDialogflowCxV3EnvironmentVersionConfig `json:"versionConfigs,omitempty"`
1240
1241	// ForceSendFields is a list of field names (e.g. "Description") to
1242	// unconditionally include in API requests. By default, fields with
1243	// empty or default values are omitted from API requests. However, any
1244	// non-pointer, non-interface field appearing in ForceSendFields will be
1245	// sent to the server regardless of whether the field is empty or not.
1246	// This may be used to include empty fields in Patch requests.
1247	ForceSendFields []string `json:"-"`
1248
1249	// NullFields is a list of field names (e.g. "Description") to include
1250	// in API requests with the JSON null value. By default, fields with
1251	// empty values are omitted from API requests. However, any field with
1252	// an empty value appearing in NullFields will be sent to the server as
1253	// null. It is an error if a field in this list has a non-empty value.
1254	// This may be used to include null fields in Patch requests.
1255	NullFields []string `json:"-"`
1256}
1257
1258func (s *GoogleCloudDialogflowCxV3Environment) MarshalJSON() ([]byte, error) {
1259	type NoMethod GoogleCloudDialogflowCxV3Environment
1260	raw := NoMethod(*s)
1261	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
1262}
1263
1264// GoogleCloudDialogflowCxV3EnvironmentTestCasesConfig: The
1265// configuration for continuous tests.
1266type GoogleCloudDialogflowCxV3EnvironmentTestCasesConfig struct {
1267	// EnableContinuousRun: Whether to run test cases in
1268	// TestCasesConfig.test_cases periodically. Default false. If set to
1269	// ture, run once a day.
1270	EnableContinuousRun bool `json:"enableContinuousRun,omitempty"`
1271
1272	// EnablePredeploymentRun: Whether to run test cases in
1273	// TestCasesConfig.test_cases before deploying a flow version to the
1274	// environment. Default false.
1275	EnablePredeploymentRun bool `json:"enablePredeploymentRun,omitempty"`
1276
1277	// TestCases: A list of test case names to run. They should be under the
1278	// same agent. Format of each test case name: `projects//locations/
1279	// /agents//testCases/`
1280	TestCases []string `json:"testCases,omitempty"`
1281
1282	// ForceSendFields is a list of field names (e.g. "EnableContinuousRun")
1283	// to unconditionally include in API requests. By default, fields with
1284	// empty or default values are omitted from API requests. However, any
1285	// non-pointer, non-interface field appearing in ForceSendFields will be
1286	// sent to the server regardless of whether the field is empty or not.
1287	// This may be used to include empty fields in Patch requests.
1288	ForceSendFields []string `json:"-"`
1289
1290	// NullFields is a list of field names (e.g. "EnableContinuousRun") to
1291	// include in API requests with the JSON null value. By default, fields
1292	// with empty values are omitted from API requests. However, any field
1293	// with an empty value appearing in NullFields will be sent to the
1294	// server as null. It is an error if a field in this list has a
1295	// non-empty value. This may be used to include null fields in Patch
1296	// requests.
1297	NullFields []string `json:"-"`
1298}
1299
1300func (s *GoogleCloudDialogflowCxV3EnvironmentTestCasesConfig) MarshalJSON() ([]byte, error) {
1301	type NoMethod GoogleCloudDialogflowCxV3EnvironmentTestCasesConfig
1302	raw := NoMethod(*s)
1303	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
1304}
1305
1306// GoogleCloudDialogflowCxV3EnvironmentVersionConfig: Configuration for
1307// the version.
1308type GoogleCloudDialogflowCxV3EnvironmentVersionConfig struct {
1309	// Version: Required. Format:
1310	// projects//locations//agents//flows//versions/.
1311	Version string `json:"version,omitempty"`
1312
1313	// ForceSendFields is a list of field names (e.g. "Version") to
1314	// unconditionally include in API requests. By default, fields with
1315	// empty or default values are omitted from API requests. However, any
1316	// non-pointer, non-interface field appearing in ForceSendFields will be
1317	// sent to the server regardless of whether the field is empty or not.
1318	// This may be used to include empty fields in Patch requests.
1319	ForceSendFields []string `json:"-"`
1320
1321	// NullFields is a list of field names (e.g. "Version") to include in
1322	// API requests with the JSON null value. By default, fields with empty
1323	// values are omitted from API requests. However, any field with an
1324	// empty value appearing in NullFields will be sent to the server as
1325	// null. It is an error if a field in this list has a non-empty value.
1326	// This may be used to include null fields in Patch requests.
1327	NullFields []string `json:"-"`
1328}
1329
1330func (s *GoogleCloudDialogflowCxV3EnvironmentVersionConfig) MarshalJSON() ([]byte, error) {
1331	type NoMethod GoogleCloudDialogflowCxV3EnvironmentVersionConfig
1332	raw := NoMethod(*s)
1333	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
1334}
1335
1336// GoogleCloudDialogflowCxV3EventHandler: An event handler specifies an
1337// event that can be handled during a session. When the specified event
1338// happens, the following actions are taken in order: * If there is a
1339// `trigger_fulfillment` associated with the event, it will be called. *
1340// If there is a `target_page` associated with the event, the session
1341// will transition into the specified page. * If there is a
1342// `target_flow` associated with the event, the session will transition
1343// into the specified flow.
1344type GoogleCloudDialogflowCxV3EventHandler struct {
1345	// Event: Required. The name of the event to handle.
1346	Event string `json:"event,omitempty"`
1347
1348	// Name: Output only. The unique identifier of this event handler.
1349	Name string `json:"name,omitempty"`
1350
1351	// TargetFlow: The target flow to transition to. Format:
1352	// `projects//locations//agents//flows/`.
1353	TargetFlow string `json:"targetFlow,omitempty"`
1354
1355	// TargetPage: The target page to transition to. Format:
1356	// `projects//locations//agents//flows//pages/`.
1357	TargetPage string `json:"targetPage,omitempty"`
1358
1359	// TriggerFulfillment: The fulfillment to call when the event occurs.
1360	// Handling webhook errors with a fulfillment enabled with webhook could
1361	// cause infinite loop. It is invalid to specify such fulfillment for a
1362	// handler handling webhooks.
1363	TriggerFulfillment *GoogleCloudDialogflowCxV3Fulfillment `json:"triggerFulfillment,omitempty"`
1364
1365	// ForceSendFields is a list of field names (e.g. "Event") to
1366	// unconditionally include in API requests. By default, fields with
1367	// empty or default values are omitted from API requests. However, any
1368	// non-pointer, non-interface field appearing in ForceSendFields will be
1369	// sent to the server regardless of whether the field is empty or not.
1370	// This may be used to include empty fields in Patch requests.
1371	ForceSendFields []string `json:"-"`
1372
1373	// NullFields is a list of field names (e.g. "Event") to include in API
1374	// requests with the JSON null value. By default, fields with empty
1375	// values are omitted from API requests. However, any field with an
1376	// empty value appearing in NullFields will be sent to the server as
1377	// null. It is an error if a field in this list has a non-empty value.
1378	// This may be used to include null fields in Patch requests.
1379	NullFields []string `json:"-"`
1380}
1381
1382func (s *GoogleCloudDialogflowCxV3EventHandler) MarshalJSON() ([]byte, error) {
1383	type NoMethod GoogleCloudDialogflowCxV3EventHandler
1384	raw := NoMethod(*s)
1385	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
1386}
1387
1388// GoogleCloudDialogflowCxV3EventInput: Represents the event to trigger.
1389type GoogleCloudDialogflowCxV3EventInput struct {
1390	// Event: Name of the event.
1391	Event string `json:"event,omitempty"`
1392
1393	// ForceSendFields is a list of field names (e.g. "Event") to
1394	// unconditionally include in API requests. By default, fields with
1395	// empty or default values are omitted from API requests. However, any
1396	// non-pointer, non-interface field appearing in ForceSendFields will be
1397	// sent to the server regardless of whether the field is empty or not.
1398	// This may be used to include empty fields in Patch requests.
1399	ForceSendFields []string `json:"-"`
1400
1401	// NullFields is a list of field names (e.g. "Event") to include in API
1402	// requests with the JSON null value. By default, fields with empty
1403	// values are omitted from API requests. However, any field with an
1404	// empty value appearing in NullFields will be sent to the server as
1405	// null. It is an error if a field in this list has a non-empty value.
1406	// This may be used to include null fields in Patch requests.
1407	NullFields []string `json:"-"`
1408}
1409
1410func (s *GoogleCloudDialogflowCxV3EventInput) MarshalJSON() ([]byte, error) {
1411	type NoMethod GoogleCloudDialogflowCxV3EventInput
1412	raw := NoMethod(*s)
1413	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
1414}
1415
1416// GoogleCloudDialogflowCxV3ExportAgentResponse: The response message
1417// for Agents.ExportAgent.
1418type GoogleCloudDialogflowCxV3ExportAgentResponse struct {
1419	// AgentContent: Uncompressed raw byte content for agent.
1420	AgentContent string `json:"agentContent,omitempty"`
1421
1422	// AgentUri: The URI to a file containing the exported agent. This field
1423	// is populated only if `agent_uri` is specified in ExportAgentRequest.
1424	AgentUri string `json:"agentUri,omitempty"`
1425
1426	// ForceSendFields is a list of field names (e.g. "AgentContent") to
1427	// unconditionally include in API requests. By default, fields with
1428	// empty or default values are omitted from API requests. However, any
1429	// non-pointer, non-interface field appearing in ForceSendFields will be
1430	// sent to the server regardless of whether the field is empty or not.
1431	// This may be used to include empty fields in Patch requests.
1432	ForceSendFields []string `json:"-"`
1433
1434	// NullFields is a list of field names (e.g. "AgentContent") to include
1435	// in API requests with the JSON null value. By default, fields with
1436	// empty values are omitted from API requests. However, any field with
1437	// an empty value appearing in NullFields will be sent to the server as
1438	// null. It is an error if a field in this list has a non-empty value.
1439	// This may be used to include null fields in Patch requests.
1440	NullFields []string `json:"-"`
1441}
1442
1443func (s *GoogleCloudDialogflowCxV3ExportAgentResponse) MarshalJSON() ([]byte, error) {
1444	type NoMethod GoogleCloudDialogflowCxV3ExportAgentResponse
1445	raw := NoMethod(*s)
1446	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
1447}
1448
1449// GoogleCloudDialogflowCxV3ExportFlowResponse: The response message for
1450// Flows.ExportFlow.
1451type GoogleCloudDialogflowCxV3ExportFlowResponse struct {
1452	// FlowContent: Uncompressed raw byte content for flow.
1453	FlowContent string `json:"flowContent,omitempty"`
1454
1455	// FlowUri: The URI to a file containing the exported flow. This field
1456	// is populated only if `flow_uri` is specified in ExportFlowRequest.
1457	FlowUri string `json:"flowUri,omitempty"`
1458
1459	// ForceSendFields is a list of field names (e.g. "FlowContent") to
1460	// unconditionally include in API requests. By default, fields with
1461	// empty or default values are omitted from API requests. However, any
1462	// non-pointer, non-interface field appearing in ForceSendFields will be
1463	// sent to the server regardless of whether the field is empty or not.
1464	// This may be used to include empty fields in Patch requests.
1465	ForceSendFields []string `json:"-"`
1466
1467	// NullFields is a list of field names (e.g. "FlowContent") to include
1468	// in API requests with the JSON null value. By default, fields with
1469	// empty values are omitted from API requests. However, any field with
1470	// an empty value appearing in NullFields will be sent to the server as
1471	// null. It is an error if a field in this list has a non-empty value.
1472	// This may be used to include null fields in Patch requests.
1473	NullFields []string `json:"-"`
1474}
1475
1476func (s *GoogleCloudDialogflowCxV3ExportFlowResponse) MarshalJSON() ([]byte, error) {
1477	type NoMethod GoogleCloudDialogflowCxV3ExportFlowResponse
1478	raw := NoMethod(*s)
1479	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
1480}
1481
1482// GoogleCloudDialogflowCxV3ExportTestCasesMetadata: Metadata returned
1483// for the TestCases.ExportTestCases long running operation. This
1484// message currently has no fields.
1485type GoogleCloudDialogflowCxV3ExportTestCasesMetadata struct {
1486}
1487
1488// GoogleCloudDialogflowCxV3ExportTestCasesResponse: The response
1489// message for TestCases.ExportTestCases.
1490type GoogleCloudDialogflowCxV3ExportTestCasesResponse struct {
1491	// Content: Uncompressed raw byte content for test cases.
1492	Content string `json:"content,omitempty"`
1493
1494	// GcsUri: The URI to a file containing the exported test cases. This
1495	// field is populated only if `gcs_uri` is specified in
1496	// ExportTestCasesRequest.
1497	GcsUri string `json:"gcsUri,omitempty"`
1498
1499	// ForceSendFields is a list of field names (e.g. "Content") to
1500	// unconditionally include in API requests. By default, fields with
1501	// empty or default values are omitted from API requests. However, any
1502	// non-pointer, non-interface field appearing in ForceSendFields will be
1503	// sent to the server regardless of whether the field is empty or not.
1504	// This may be used to include empty fields in Patch requests.
1505	ForceSendFields []string `json:"-"`
1506
1507	// NullFields is a list of field names (e.g. "Content") to include in
1508	// API requests with the JSON null value. By default, fields with empty
1509	// values are omitted from API requests. However, any field with an
1510	// empty value appearing in NullFields will be sent to the server as
1511	// null. It is an error if a field in this list has a non-empty value.
1512	// This may be used to include null fields in Patch requests.
1513	NullFields []string `json:"-"`
1514}
1515
1516func (s *GoogleCloudDialogflowCxV3ExportTestCasesResponse) MarshalJSON() ([]byte, error) {
1517	type NoMethod GoogleCloudDialogflowCxV3ExportTestCasesResponse
1518	raw := NoMethod(*s)
1519	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
1520}
1521
1522// GoogleCloudDialogflowCxV3Form: A form is a data model that groups
1523// related parameters that can be collected from the user. The process
1524// in which the agent prompts the user and collects parameter values
1525// from the user is called form filling. A form can be added to a page.
1526// When form filling is done, the filled parameters will be written to
1527// the session.
1528type GoogleCloudDialogflowCxV3Form struct {
1529	// Parameters: Parameters to collect from the user.
1530	Parameters []*GoogleCloudDialogflowCxV3FormParameter `json:"parameters,omitempty"`
1531
1532	// ForceSendFields is a list of field names (e.g. "Parameters") to
1533	// unconditionally include in API requests. By default, fields with
1534	// empty or default values are omitted from API requests. However, any
1535	// non-pointer, non-interface field appearing in ForceSendFields will be
1536	// sent to the server regardless of whether the field is empty or not.
1537	// This may be used to include empty fields in Patch requests.
1538	ForceSendFields []string `json:"-"`
1539
1540	// NullFields is a list of field names (e.g. "Parameters") to include in
1541	// API requests with the JSON null value. By default, fields with empty
1542	// values are omitted from API requests. However, any field with an
1543	// empty value appearing in NullFields will be sent to the server as
1544	// null. It is an error if a field in this list has a non-empty value.
1545	// This may be used to include null fields in Patch requests.
1546	NullFields []string `json:"-"`
1547}
1548
1549func (s *GoogleCloudDialogflowCxV3Form) MarshalJSON() ([]byte, error) {
1550	type NoMethod GoogleCloudDialogflowCxV3Form
1551	raw := NoMethod(*s)
1552	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
1553}
1554
1555// GoogleCloudDialogflowCxV3FormParameter: Represents a form parameter.
1556type GoogleCloudDialogflowCxV3FormParameter struct {
1557	// DefaultValue: The default value of an optional parameter. If the
1558	// parameter is required, the default value will be ignored.
1559	DefaultValue interface{} `json:"defaultValue,omitempty"`
1560
1561	// DisplayName: Required. The human-readable name of the parameter,
1562	// unique within the form.
1563	DisplayName string `json:"displayName,omitempty"`
1564
1565	// EntityType: Required. The entity type of the parameter. Format:
1566	// `projects/-/locations/-/agents/-/entityTypes/` for system entity
1567	// types (for example,
1568	// `projects/-/locations/-/agents/-/entityTypes/sys.date`), or
1569	// `projects//locations//agents//entityTypes/` for developer entity
1570	// types.
1571	EntityType string `json:"entityType,omitempty"`
1572
1573	// FillBehavior: Required. Defines fill behavior for the parameter.
1574	FillBehavior *GoogleCloudDialogflowCxV3FormParameterFillBehavior `json:"fillBehavior,omitempty"`
1575
1576	// IsList: Indicates whether the parameter represents a list of values.
1577	IsList bool `json:"isList,omitempty"`
1578
1579	// Redact: Indicates whether the parameter content should be redacted in
1580	// log. If redaction is enabled, the parameter content will be replaced
1581	// by parameter name during logging. Note: the parameter content is
1582	// subject to redaction if either parameter level redaction or entity
1583	// type level redaction is enabled.
1584	Redact bool `json:"redact,omitempty"`
1585
1586	// Required: Indicates whether the parameter is required. Optional
1587	// parameters will not trigger prompts; however, they are filled if the
1588	// user specifies them. Required parameters must be filled before form
1589	// filling concludes.
1590	Required bool `json:"required,omitempty"`
1591
1592	// ForceSendFields is a list of field names (e.g. "DefaultValue") to
1593	// unconditionally include in API requests. By default, fields with
1594	// empty or default values are omitted from API requests. However, any
1595	// non-pointer, non-interface field appearing in ForceSendFields will be
1596	// sent to the server regardless of whether the field is empty or not.
1597	// This may be used to include empty fields in Patch requests.
1598	ForceSendFields []string `json:"-"`
1599
1600	// NullFields is a list of field names (e.g. "DefaultValue") to include
1601	// in API requests with the JSON null value. By default, fields with
1602	// empty values are omitted from API requests. However, any field with
1603	// an empty value appearing in NullFields will be sent to the server as
1604	// null. It is an error if a field in this list has a non-empty value.
1605	// This may be used to include null fields in Patch requests.
1606	NullFields []string `json:"-"`
1607}
1608
1609func (s *GoogleCloudDialogflowCxV3FormParameter) MarshalJSON() ([]byte, error) {
1610	type NoMethod GoogleCloudDialogflowCxV3FormParameter
1611	raw := NoMethod(*s)
1612	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
1613}
1614
1615// GoogleCloudDialogflowCxV3FormParameterFillBehavior: Configuration for
1616// how the filling of a parameter should be handled.
1617type GoogleCloudDialogflowCxV3FormParameterFillBehavior struct {
1618	// InitialPromptFulfillment: Required. The fulfillment to provide the
1619	// initial prompt that the agent can present to the user in order to
1620	// fill the parameter.
1621	InitialPromptFulfillment *GoogleCloudDialogflowCxV3Fulfillment `json:"initialPromptFulfillment,omitempty"`
1622
1623	// RepromptEventHandlers: The handlers for parameter-level events, used
1624	// to provide reprompt for the parameter or transition to a different
1625	// page/flow. The supported events are: * `sys.no-match-`, where N can
1626	// be from 1 to 6 * `sys.no-match-default` * `sys.no-input-`, where N
1627	// can be from 1 to 6 * `sys.no-input-default` * `sys.invalid-parameter`
1628	// `initial_prompt_fulfillment` provides the first prompt for the
1629	// parameter. If the user's response does not fill the parameter, a
1630	// no-match/no-input event will be triggered, and the fulfillment
1631	// associated with the `sys.no-match-1`/`sys.no-input-1` handler (if
1632	// defined) will be called to provide a prompt. The
1633	// `sys.no-match-2`/`sys.no-input-2` handler (if defined) will respond
1634	// to the next no-match/no-input event, and so on. A
1635	// `sys.no-match-default` or `sys.no-input-default` handler will be used
1636	// to handle all following no-match/no-input events after all numbered
1637	// no-match/no-input handlers for the parameter are consumed. A
1638	// `sys.invalid-parameter` handler can be defined to handle the case
1639	// where the parameter values have been `invalidated` by webhook. For
1640	// example, if the user's response fill the parameter, however the
1641	// parameter was invalidated by webhook, the fulfillment associated with
1642	// the `sys.invalid-parameter` handler (if defined) will be called to
1643	// provide a prompt. If the event handler for the corresponding event
1644	// can't be found on the parameter, `initial_prompt_fulfillment` will be
1645	// re-prompted.
1646	RepromptEventHandlers []*GoogleCloudDialogflowCxV3EventHandler `json:"repromptEventHandlers,omitempty"`
1647
1648	// ForceSendFields is a list of field names (e.g.
1649	// "InitialPromptFulfillment") to unconditionally include in API
1650	// requests. By default, fields with empty or default values are omitted
1651	// from API requests. However, any non-pointer, non-interface field
1652	// appearing in ForceSendFields will be sent to the server regardless of
1653	// whether the field is empty or not. This may be used to include empty
1654	// fields in Patch requests.
1655	ForceSendFields []string `json:"-"`
1656
1657	// NullFields is a list of field names (e.g. "InitialPromptFulfillment")
1658	// to include in API requests with the JSON null value. By default,
1659	// fields with empty values are omitted from API requests. However, any
1660	// field with an empty value appearing in NullFields will be sent to the
1661	// server as null. It is an error if a field in this list has a
1662	// non-empty value. This may be used to include null fields in Patch
1663	// requests.
1664	NullFields []string `json:"-"`
1665}
1666
1667func (s *GoogleCloudDialogflowCxV3FormParameterFillBehavior) MarshalJSON() ([]byte, error) {
1668	type NoMethod GoogleCloudDialogflowCxV3FormParameterFillBehavior
1669	raw := NoMethod(*s)
1670	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
1671}
1672
1673// GoogleCloudDialogflowCxV3Fulfillment: A fulfillment can do one or
1674// more of the following actions at the same time: * Generate rich
1675// message responses. * Set parameter values. * Call the webhook.
1676// Fulfillments can be called at various stages in the Page or Form
1677// lifecycle. For example, when a DetectIntentRequest drives a session
1678// to enter a new page, the page's entry fulfillment can add a static
1679// response to the QueryResult in the returning DetectIntentResponse,
1680// call the webhook (for example, to load user data from a database), or
1681// both.
1682type GoogleCloudDialogflowCxV3Fulfillment struct {
1683	// ConditionalCases: Conditional cases for this fulfillment.
1684	ConditionalCases []*GoogleCloudDialogflowCxV3FulfillmentConditionalCases `json:"conditionalCases,omitempty"`
1685
1686	// Messages: The list of rich message responses to present to the user.
1687	Messages []*GoogleCloudDialogflowCxV3ResponseMessage `json:"messages,omitempty"`
1688
1689	// ReturnPartialResponses: Whether Dialogflow should return currently
1690	// queued fulfillment response messages in streaming APIs. If a webhook
1691	// is specified, it happens before Dialogflow invokes webhook. Warning:
1692	// 1) This flag only affects streaming API. Responses are still queued
1693	// and returned once in non-streaming API. 2) The flag can be enabled in
1694	// any fulfillment but only the first 3 partial responses will be
1695	// returned. You may only want to apply it to fulfillments that have
1696	// slow webhooks.
1697	ReturnPartialResponses bool `json:"returnPartialResponses,omitempty"`
1698
1699	// SetParameterActions: Set parameter values before executing the
1700	// webhook.
1701	SetParameterActions []*GoogleCloudDialogflowCxV3FulfillmentSetParameterAction `json:"setParameterActions,omitempty"`
1702
1703	// Tag: The tag used by the webhook to identify which fulfillment is
1704	// being called. This field is required if `webhook` is specified.
1705	Tag string `json:"tag,omitempty"`
1706
1707	// Webhook: The webhook to call. Format:
1708	// `projects//locations//agents//webhooks/`.
1709	Webhook string `json:"webhook,omitempty"`
1710
1711	// ForceSendFields is a list of field names (e.g. "ConditionalCases") to
1712	// unconditionally include in API requests. By default, fields with
1713	// empty or default values are omitted from API requests. However, any
1714	// non-pointer, non-interface field appearing in ForceSendFields will be
1715	// sent to the server regardless of whether the field is empty or not.
1716	// This may be used to include empty fields in Patch requests.
1717	ForceSendFields []string `json:"-"`
1718
1719	// NullFields is a list of field names (e.g. "ConditionalCases") to
1720	// include in API requests with the JSON null value. By default, fields
1721	// with empty values are omitted from API requests. However, any field
1722	// with an empty value appearing in NullFields will be sent to the
1723	// server as null. It is an error if a field in this list has a
1724	// non-empty value. This may be used to include null fields in Patch
1725	// requests.
1726	NullFields []string `json:"-"`
1727}
1728
1729func (s *GoogleCloudDialogflowCxV3Fulfillment) MarshalJSON() ([]byte, error) {
1730	type NoMethod GoogleCloudDialogflowCxV3Fulfillment
1731	raw := NoMethod(*s)
1732	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
1733}
1734
1735// GoogleCloudDialogflowCxV3FulfillmentConditionalCases: A list of
1736// cascading if-else conditions. Cases are mutually exclusive. The first
1737// one with a matching condition is selected, all the rest ignored.
1738type GoogleCloudDialogflowCxV3FulfillmentConditionalCases struct {
1739	// Cases: A list of cascading if-else conditions.
1740	Cases []*GoogleCloudDialogflowCxV3FulfillmentConditionalCasesCase `json:"cases,omitempty"`
1741
1742	// ForceSendFields is a list of field names (e.g. "Cases") to
1743	// unconditionally include in API requests. By default, fields with
1744	// empty or default values are omitted from API requests. However, any
1745	// non-pointer, non-interface field appearing in ForceSendFields will be
1746	// sent to the server regardless of whether the field is empty or not.
1747	// This may be used to include empty fields in Patch requests.
1748	ForceSendFields []string `json:"-"`
1749
1750	// NullFields is a list of field names (e.g. "Cases") to include in API
1751	// requests with the JSON null value. By default, fields with empty
1752	// values are omitted from API requests. However, any field with an
1753	// empty value appearing in NullFields will be sent to the server as
1754	// null. It is an error if a field in this list has a non-empty value.
1755	// This may be used to include null fields in Patch requests.
1756	NullFields []string `json:"-"`
1757}
1758
1759func (s *GoogleCloudDialogflowCxV3FulfillmentConditionalCases) MarshalJSON() ([]byte, error) {
1760	type NoMethod GoogleCloudDialogflowCxV3FulfillmentConditionalCases
1761	raw := NoMethod(*s)
1762	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
1763}
1764
1765// GoogleCloudDialogflowCxV3FulfillmentConditionalCasesCase: Each case
1766// has a Boolean condition. When it is evaluated to be True, the
1767// corresponding messages will be selected and evaluated recursively.
1768type GoogleCloudDialogflowCxV3FulfillmentConditionalCasesCase struct {
1769	// CaseContent: A list of case content.
1770	CaseContent []*GoogleCloudDialogflowCxV3FulfillmentConditionalCasesCaseCaseContent `json:"caseContent,omitempty"`
1771
1772	// Condition: The condition to activate and select this case. Empty
1773	// means the condition is always true. The condition is evaluated
1774	// against form parameters or session parameters. See the conditions
1775	// reference
1776	// (https://cloud.google.com/dialogflow/cx/docs/reference/condition).
1777	Condition string `json:"condition,omitempty"`
1778
1779	// ForceSendFields is a list of field names (e.g. "CaseContent") to
1780	// unconditionally include in API requests. By default, fields with
1781	// empty or default values are omitted from API requests. However, any
1782	// non-pointer, non-interface field appearing in ForceSendFields will be
1783	// sent to the server regardless of whether the field is empty or not.
1784	// This may be used to include empty fields in Patch requests.
1785	ForceSendFields []string `json:"-"`
1786
1787	// NullFields is a list of field names (e.g. "CaseContent") to include
1788	// in API requests with the JSON null value. By default, fields with
1789	// empty values are omitted from API requests. However, any field with
1790	// an empty value appearing in NullFields will be sent to the server as
1791	// null. It is an error if a field in this list has a non-empty value.
1792	// This may be used to include null fields in Patch requests.
1793	NullFields []string `json:"-"`
1794}
1795
1796func (s *GoogleCloudDialogflowCxV3FulfillmentConditionalCasesCase) MarshalJSON() ([]byte, error) {
1797	type NoMethod GoogleCloudDialogflowCxV3FulfillmentConditionalCasesCase
1798	raw := NoMethod(*s)
1799	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
1800}
1801
1802// GoogleCloudDialogflowCxV3FulfillmentConditionalCasesCaseCaseContent:
1803// The list of messages or conditional cases to activate for this case.
1804type GoogleCloudDialogflowCxV3FulfillmentConditionalCasesCaseCaseContent struct {
1805	// AdditionalCases: Additional cases to be evaluated.
1806	AdditionalCases *GoogleCloudDialogflowCxV3FulfillmentConditionalCases `json:"additionalCases,omitempty"`
1807
1808	// Message: Returned message.
1809	Message *GoogleCloudDialogflowCxV3ResponseMessage `json:"message,omitempty"`
1810
1811	// ForceSendFields is a list of field names (e.g. "AdditionalCases") to
1812	// unconditionally include in API requests. By default, fields with
1813	// empty or default values are omitted from API requests. However, any
1814	// non-pointer, non-interface field appearing in ForceSendFields will be
1815	// sent to the server regardless of whether the field is empty or not.
1816	// This may be used to include empty fields in Patch requests.
1817	ForceSendFields []string `json:"-"`
1818
1819	// NullFields is a list of field names (e.g. "AdditionalCases") to
1820	// include in API requests with the JSON null value. By default, fields
1821	// with empty values are omitted from API requests. However, any field
1822	// with an empty value appearing in NullFields will be sent to the
1823	// server as null. It is an error if a field in this list has a
1824	// non-empty value. This may be used to include null fields in Patch
1825	// requests.
1826	NullFields []string `json:"-"`
1827}
1828
1829func (s *GoogleCloudDialogflowCxV3FulfillmentConditionalCasesCaseCaseContent) MarshalJSON() ([]byte, error) {
1830	type NoMethod GoogleCloudDialogflowCxV3FulfillmentConditionalCasesCaseCaseContent
1831	raw := NoMethod(*s)
1832	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
1833}
1834
1835// GoogleCloudDialogflowCxV3FulfillmentSetParameterAction: Setting a
1836// parameter value.
1837type GoogleCloudDialogflowCxV3FulfillmentSetParameterAction struct {
1838	// Parameter: Display name of the parameter.
1839	Parameter string `json:"parameter,omitempty"`
1840
1841	// Value: The new value of the parameter. A null value clears the
1842	// parameter.
1843	Value interface{} `json:"value,omitempty"`
1844
1845	// ForceSendFields is a list of field names (e.g. "Parameter") to
1846	// unconditionally include in API requests. By default, fields with
1847	// empty or default values are omitted from API requests. However, any
1848	// non-pointer, non-interface field appearing in ForceSendFields will be
1849	// sent to the server regardless of whether the field is empty or not.
1850	// This may be used to include empty fields in Patch requests.
1851	ForceSendFields []string `json:"-"`
1852
1853	// NullFields is a list of field names (e.g. "Parameter") to include in
1854	// API requests with the JSON null value. By default, fields with empty
1855	// values are omitted from API requests. However, any field with an
1856	// empty value appearing in NullFields will be sent to the server as
1857	// null. It is an error if a field in this list has a non-empty value.
1858	// This may be used to include null fields in Patch requests.
1859	NullFields []string `json:"-"`
1860}
1861
1862func (s *GoogleCloudDialogflowCxV3FulfillmentSetParameterAction) MarshalJSON() ([]byte, error) {
1863	type NoMethod GoogleCloudDialogflowCxV3FulfillmentSetParameterAction
1864	raw := NoMethod(*s)
1865	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
1866}
1867
1868// GoogleCloudDialogflowCxV3GenericKnowledgeOperationMetadata: Metadata
1869// in google::longrunning::Operation for Knowledge operations.
1870type GoogleCloudDialogflowCxV3GenericKnowledgeOperationMetadata struct {
1871	// State: Required. Output only. The current state of this operation.
1872	//
1873	// Possible values:
1874	//   "STATE_UNSPECIFIED" - State unspecified.
1875	//   "PENDING" - The operation has been created.
1876	//   "RUNNING" - The operation is currently running.
1877	//   "DONE" - The operation is done, either cancelled or completed.
1878	State string `json:"state,omitempty"`
1879
1880	// ForceSendFields is a list of field names (e.g. "State") to
1881	// unconditionally include in API requests. By default, fields with
1882	// empty or default values are omitted from API requests. However, any
1883	// non-pointer, non-interface field appearing in ForceSendFields will be
1884	// sent to the server regardless of whether the field is empty or not.
1885	// This may be used to include empty fields in Patch requests.
1886	ForceSendFields []string `json:"-"`
1887
1888	// NullFields is a list of field names (e.g. "State") to include in API
1889	// requests with the JSON null value. By default, fields with empty
1890	// values are omitted from API requests. However, any field with an
1891	// empty value appearing in NullFields will be sent to the server as
1892	// null. It is an error if a field in this list has a non-empty value.
1893	// This may be used to include null fields in Patch requests.
1894	NullFields []string `json:"-"`
1895}
1896
1897func (s *GoogleCloudDialogflowCxV3GenericKnowledgeOperationMetadata) MarshalJSON() ([]byte, error) {
1898	type NoMethod GoogleCloudDialogflowCxV3GenericKnowledgeOperationMetadata
1899	raw := NoMethod(*s)
1900	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
1901}
1902
1903// GoogleCloudDialogflowCxV3ImportDocumentsOperationMetadata: Metadata
1904// for ImportDocuments operation.
1905type GoogleCloudDialogflowCxV3ImportDocumentsOperationMetadata struct {
1906	// GenericMetadata: The generic information of the operation.
1907	GenericMetadata *GoogleCloudDialogflowCxV3GenericKnowledgeOperationMetadata `json:"genericMetadata,omitempty"`
1908
1909	// ForceSendFields is a list of field names (e.g. "GenericMetadata") to
1910	// unconditionally include in API requests. By default, fields with
1911	// empty or default values are omitted from API requests. However, any
1912	// non-pointer, non-interface field appearing in ForceSendFields will be
1913	// sent to the server regardless of whether the field is empty or not.
1914	// This may be used to include empty fields in Patch requests.
1915	ForceSendFields []string `json:"-"`
1916
1917	// NullFields is a list of field names (e.g. "GenericMetadata") to
1918	// include in API requests with the JSON null value. By default, fields
1919	// with empty values are omitted from API requests. However, any field
1920	// with an empty value appearing in NullFields will be sent to the
1921	// server as null. It is an error if a field in this list has a
1922	// non-empty value. This may be used to include null fields in Patch
1923	// requests.
1924	NullFields []string `json:"-"`
1925}
1926
1927func (s *GoogleCloudDialogflowCxV3ImportDocumentsOperationMetadata) MarshalJSON() ([]byte, error) {
1928	type NoMethod GoogleCloudDialogflowCxV3ImportDocumentsOperationMetadata
1929	raw := NoMethod(*s)
1930	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
1931}
1932
1933// GoogleCloudDialogflowCxV3ImportDocumentsResponse: Response message
1934// for Documents.ImportDocuments.
1935type GoogleCloudDialogflowCxV3ImportDocumentsResponse struct {
1936	// Warnings: Includes details about skipped documents or any other
1937	// warnings.
1938	Warnings []*GoogleRpcStatus `json:"warnings,omitempty"`
1939
1940	// ForceSendFields is a list of field names (e.g. "Warnings") to
1941	// unconditionally include in API requests. By default, fields with
1942	// empty or default values are omitted from API requests. However, any
1943	// non-pointer, non-interface field appearing in ForceSendFields will be
1944	// sent to the server regardless of whether the field is empty or not.
1945	// This may be used to include empty fields in Patch requests.
1946	ForceSendFields []string `json:"-"`
1947
1948	// NullFields is a list of field names (e.g. "Warnings") to include in
1949	// API requests with the JSON null value. By default, fields with empty
1950	// values are omitted from API requests. However, any field with an
1951	// empty value appearing in NullFields will be sent to the server as
1952	// null. It is an error if a field in this list has a non-empty value.
1953	// This may be used to include null fields in Patch requests.
1954	NullFields []string `json:"-"`
1955}
1956
1957func (s *GoogleCloudDialogflowCxV3ImportDocumentsResponse) MarshalJSON() ([]byte, error) {
1958	type NoMethod GoogleCloudDialogflowCxV3ImportDocumentsResponse
1959	raw := NoMethod(*s)
1960	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
1961}
1962
1963// GoogleCloudDialogflowCxV3ImportFlowResponse: The response message for
1964// Flows.ImportFlow.
1965type GoogleCloudDialogflowCxV3ImportFlowResponse struct {
1966	// Flow: The unique identifier of the new flow. Format:
1967	// `projects//locations//agents//flows/`.
1968	Flow string `json:"flow,omitempty"`
1969
1970	// ForceSendFields is a list of field names (e.g. "Flow") to
1971	// unconditionally include in API requests. By default, fields with
1972	// empty or default values are omitted from API requests. However, any
1973	// non-pointer, non-interface field appearing in ForceSendFields will be
1974	// sent to the server regardless of whether the field is empty or not.
1975	// This may be used to include empty fields in Patch requests.
1976	ForceSendFields []string `json:"-"`
1977
1978	// NullFields is a list of field names (e.g. "Flow") to include in API
1979	// requests with the JSON null value. By default, fields with empty
1980	// values are omitted from API requests. However, any field with an
1981	// empty value appearing in NullFields will be sent to the server as
1982	// null. It is an error if a field in this list has a non-empty value.
1983	// This may be used to include null fields in Patch requests.
1984	NullFields []string `json:"-"`
1985}
1986
1987func (s *GoogleCloudDialogflowCxV3ImportFlowResponse) MarshalJSON() ([]byte, error) {
1988	type NoMethod GoogleCloudDialogflowCxV3ImportFlowResponse
1989	raw := NoMethod(*s)
1990	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
1991}
1992
1993// GoogleCloudDialogflowCxV3ImportTestCasesMetadata: Metadata returned
1994// for the TestCases.ImportTestCases long running operation.
1995type GoogleCloudDialogflowCxV3ImportTestCasesMetadata struct {
1996	// Errors: Errors for failed test cases.
1997	Errors []*GoogleCloudDialogflowCxV3TestCaseError `json:"errors,omitempty"`
1998
1999	// ForceSendFields is a list of field names (e.g. "Errors") to
2000	// unconditionally include in API requests. By default, fields with
2001	// empty or default values are omitted from API requests. However, any
2002	// non-pointer, non-interface field appearing in ForceSendFields will be
2003	// sent to the server regardless of whether the field is empty or not.
2004	// This may be used to include empty fields in Patch requests.
2005	ForceSendFields []string `json:"-"`
2006
2007	// NullFields is a list of field names (e.g. "Errors") to include in API
2008	// requests with the JSON null value. By default, fields with empty
2009	// values are omitted from API requests. However, any field with an
2010	// empty value appearing in NullFields will be sent to the server as
2011	// null. It is an error if a field in this list has a non-empty value.
2012	// This may be used to include null fields in Patch requests.
2013	NullFields []string `json:"-"`
2014}
2015
2016func (s *GoogleCloudDialogflowCxV3ImportTestCasesMetadata) MarshalJSON() ([]byte, error) {
2017	type NoMethod GoogleCloudDialogflowCxV3ImportTestCasesMetadata
2018	raw := NoMethod(*s)
2019	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
2020}
2021
2022// GoogleCloudDialogflowCxV3ImportTestCasesResponse: The response
2023// message for TestCases.ImportTestCases.
2024type GoogleCloudDialogflowCxV3ImportTestCasesResponse struct {
2025	// Names: The unique identifiers of the new test cases. Format:
2026	// `projects//locations//agents//testCases/`.
2027	Names []string `json:"names,omitempty"`
2028
2029	// ForceSendFields is a list of field names (e.g. "Names") to
2030	// unconditionally include in API requests. By default, fields with
2031	// empty or default values are omitted from API requests. However, any
2032	// non-pointer, non-interface field appearing in ForceSendFields will be
2033	// sent to the server regardless of whether the field is empty or not.
2034	// This may be used to include empty fields in Patch requests.
2035	ForceSendFields []string `json:"-"`
2036
2037	// NullFields is a list of field names (e.g. "Names") to include in API
2038	// requests with the JSON null value. By default, fields with empty
2039	// values are omitted from API requests. However, any field with an
2040	// empty value appearing in NullFields will be sent to the server as
2041	// null. It is an error if a field in this list has a non-empty value.
2042	// This may be used to include null fields in Patch requests.
2043	NullFields []string `json:"-"`
2044}
2045
2046func (s *GoogleCloudDialogflowCxV3ImportTestCasesResponse) MarshalJSON() ([]byte, error) {
2047	type NoMethod GoogleCloudDialogflowCxV3ImportTestCasesResponse
2048	raw := NoMethod(*s)
2049	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
2050}
2051
2052// GoogleCloudDialogflowCxV3InputAudioConfig: Instructs the speech
2053// recognizer on how to process the audio content.
2054type GoogleCloudDialogflowCxV3InputAudioConfig struct {
2055	// AudioEncoding: Required. Audio encoding of the audio content to
2056	// process.
2057	//
2058	// Possible values:
2059	//   "AUDIO_ENCODING_UNSPECIFIED" - Not specified.
2060	//   "AUDIO_ENCODING_LINEAR_16" - Uncompressed 16-bit signed
2061	// little-endian samples (Linear PCM).
2062	//   "AUDIO_ENCODING_FLAC" -
2063	// [`FLAC`](https://xiph.org/flac/documentation.html) (Free Lossless
2064	// Audio Codec) is the recommended encoding because it is lossless
2065	// (therefore recognition is not compromised) and requires only about
2066	// half the bandwidth of `LINEAR16`. `FLAC` stream encoding supports
2067	// 16-bit and 24-bit samples, however, not all fields in `STREAMINFO`
2068	// are supported.
2069	//   "AUDIO_ENCODING_MULAW" - 8-bit samples that compand 14-bit audio
2070	// samples using G.711 PCMU/mu-law.
2071	//   "AUDIO_ENCODING_AMR" - Adaptive Multi-Rate Narrowband codec.
2072	// `sample_rate_hertz` must be 8000.
2073	//   "AUDIO_ENCODING_AMR_WB" - Adaptive Multi-Rate Wideband codec.
2074	// `sample_rate_hertz` must be 16000.
2075	//   "AUDIO_ENCODING_OGG_OPUS" - Opus encoded audio frames in Ogg
2076	// container ([OggOpus](https://wiki.xiph.org/OggOpus)).
2077	// `sample_rate_hertz` must be 16000.
2078	//   "AUDIO_ENCODING_SPEEX_WITH_HEADER_BYTE" - Although the use of lossy
2079	// encodings is not recommended, if a very low bitrate encoding is
2080	// required, `OGG_OPUS` is highly preferred over Speex encoding. The
2081	// [Speex](https://speex.org/) encoding supported by Dialogflow API has
2082	// a header byte in each block, as in MIME type
2083	// `audio/x-speex-with-header-byte`. It is a variant of the RTP Speex
2084	// encoding defined in [RFC 5574](https://tools.ietf.org/html/rfc5574).
2085	// The stream is a sequence of blocks, one block per RTP packet. Each
2086	// block starts with a byte containing the length of the block, in
2087	// bytes, followed by one or more frames of Speex data, padded to an
2088	// integral number of bytes (octets) as specified in RFC 5574. In other
2089	// words, each RTP header is replaced with a single byte containing the
2090	// block length. Only Speex wideband is supported. `sample_rate_hertz`
2091	// must be 16000.
2092	AudioEncoding string `json:"audioEncoding,omitempty"`
2093
2094	// EnableWordInfo: Optional. If `true`, Dialogflow returns
2095	// SpeechWordInfo in StreamingRecognitionResult with information about
2096	// the recognized speech words, e.g. start and end time offsets. If
2097	// false or unspecified, Speech doesn't return any word-level
2098	// information.
2099	EnableWordInfo bool `json:"enableWordInfo,omitempty"`
2100
2101	// Model: Optional. Which Speech model to select for the given request.
2102	// Select the model best suited to your domain to get best results. If a
2103	// model is not explicitly specified, then we auto-select a model based
2104	// on the parameters in the InputAudioConfig. If enhanced speech model
2105	// is enabled for the agent and an enhanced version of the specified
2106	// model for the language does not exist, then the speech is recognized
2107	// using the standard version of the specified model. Refer to Cloud
2108	// Speech API documentation
2109	// (https://cloud.google.com/speech-to-text/docs/basics#select-model)
2110	// for more details.
2111	Model string `json:"model,omitempty"`
2112
2113	// ModelVariant: Optional. Which variant of the Speech model to use.
2114	//
2115	// Possible values:
2116	//   "SPEECH_MODEL_VARIANT_UNSPECIFIED" - No model variant specified. In
2117	// this case Dialogflow defaults to USE_BEST_AVAILABLE.
2118	//   "USE_BEST_AVAILABLE" - Use the best available variant of the Speech
2119	// model that the caller is eligible for. Please see the [Dialogflow
2120	// docs](https://cloud.google.com/dialogflow/docs/data-logging) for how
2121	// to make your project eligible for enhanced models.
2122	//   "USE_STANDARD" - Use standard model variant even if an enhanced
2123	// model is available. See the [Cloud Speech
2124	// documentation](https://cloud.google.com/speech-to-text/docs/enhanced-m
2125	// odels) for details about enhanced models.
2126	//   "USE_ENHANCED" - Use an enhanced model variant: * If an enhanced
2127	// variant does not exist for the given model and request language,
2128	// Dialogflow falls back to the standard variant. The [Cloud Speech
2129	// documentation](https://cloud.google.com/speech-to-text/docs/enhanced-m
2130	// odels) describes which models have enhanced variants. * If the API
2131	// caller isn't eligible for enhanced models, Dialogflow returns an
2132	// error. Please see the [Dialogflow
2133	// docs](https://cloud.google.com/dialogflow/docs/data-logging) for how
2134	// to make your project eligible.
2135	ModelVariant string `json:"modelVariant,omitempty"`
2136
2137	// PhraseHints: Optional. A list of strings containing words and phrases
2138	// that the speech recognizer should recognize with higher likelihood.
2139	// See the Cloud Speech documentation
2140	// (https://cloud.google.com/speech-to-text/docs/basics#phrase-hints)
2141	// for more details.
2142	PhraseHints []string `json:"phraseHints,omitempty"`
2143
2144	// SampleRateHertz: Sample rate (in Hertz) of the audio content sent in
2145	// the query. Refer to Cloud Speech API documentation
2146	// (https://cloud.google.com/speech-to-text/docs/basics) for more
2147	// details.
2148	SampleRateHertz int64 `json:"sampleRateHertz,omitempty"`
2149
2150	// SingleUtterance: Optional. If `false` (default), recognition does not
2151	// cease until the client closes the stream. If `true`, the recognizer
2152	// will detect a single spoken utterance in input audio. Recognition
2153	// ceases when it detects the audio's voice has stopped or paused. In
2154	// this case, once a detected intent is received, the client should
2155	// close the stream and start a new request with a new stream as needed.
2156	// Note: This setting is relevant only for streaming methods.
2157	SingleUtterance bool `json:"singleUtterance,omitempty"`
2158
2159	// ForceSendFields is a list of field names (e.g. "AudioEncoding") to
2160	// unconditionally include in API requests. By default, fields with
2161	// empty or default values are omitted from API requests. However, any
2162	// non-pointer, non-interface field appearing in ForceSendFields will be
2163	// sent to the server regardless of whether the field is empty or not.
2164	// This may be used to include empty fields in Patch requests.
2165	ForceSendFields []string `json:"-"`
2166
2167	// NullFields is a list of field names (e.g. "AudioEncoding") to include
2168	// in API requests with the JSON null value. By default, fields with
2169	// empty values are omitted from API requests. However, any field with
2170	// an empty value appearing in NullFields will be sent to the server as
2171	// null. It is an error if a field in this list has a non-empty value.
2172	// This may be used to include null fields in Patch requests.
2173	NullFields []string `json:"-"`
2174}
2175
2176func (s *GoogleCloudDialogflowCxV3InputAudioConfig) MarshalJSON() ([]byte, error) {
2177	type NoMethod GoogleCloudDialogflowCxV3InputAudioConfig
2178	raw := NoMethod(*s)
2179	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
2180}
2181
2182// GoogleCloudDialogflowCxV3Intent: An intent represents a user's intent
2183// to interact with a conversational agent. You can provide information
2184// for the Dialogflow API to use to match user input to an intent by
2185// adding training phrases (i.e., examples of user input) to your
2186// intent.
2187type GoogleCloudDialogflowCxV3Intent struct {
2188	// Description: Human readable description for better understanding an
2189	// intent like its scope, content, result etc. Maximum character limit:
2190	// 140 characters.
2191	Description string `json:"description,omitempty"`
2192
2193	// DisplayName: Required. The human-readable name of the intent, unique
2194	// within the agent.
2195	DisplayName string `json:"displayName,omitempty"`
2196
2197	// IsFallback: Indicates whether this is a fallback intent. Currently
2198	// only default fallback intent is allowed in the agent, which is added
2199	// upon agent creation. Adding training phrases to fallback intent is
2200	// useful in the case of requests that are mistakenly matched, since
2201	// training phrases assigned to fallback intents act as negative
2202	// examples that triggers no-match event.
2203	IsFallback bool `json:"isFallback,omitempty"`
2204
2205	// Labels: The key/value metadata to label an intent. Labels can contain
2206	// lowercase letters, digits and the symbols '-' and '_'. International
2207	// characters are allowed, including letters from unicase alphabets.
2208	// Keys must start with a letter. Keys and values can be no longer than
2209	// 63 characters and no more than 128 bytes. Prefix "sys-" is reserved
2210	// for Dialogflow defined labels. Currently allowed Dialogflow defined
2211	// labels include: * sys-head * sys-contextual The above labels do not
2212	// require value. "sys-head" means the intent is a head intent.
2213	// "sys.contextual" means the intent is a contextual intent.
2214	Labels map[string]string `json:"labels,omitempty"`
2215
2216	// Name: The unique identifier of the intent. Required for the
2217	// Intents.UpdateIntent method. Intents.CreateIntent populates the name
2218	// automatically. Format: `projects//locations//agents//intents/`.
2219	Name string `json:"name,omitempty"`
2220
2221	// Parameters: The collection of parameters associated with the intent.
2222	Parameters []*GoogleCloudDialogflowCxV3IntentParameter `json:"parameters,omitempty"`
2223
2224	// Priority: The priority of this intent. Higher numbers represent
2225	// higher priorities. - If the supplied value is unspecified or 0, the
2226	// service translates the value to 500,000, which corresponds to the
2227	// `Normal` priority in the console. - If the supplied value is
2228	// negative, the intent is ignored in runtime detect intent requests.
2229	Priority int64 `json:"priority,omitempty"`
2230
2231	// TrainingPhrases: The collection of training phrases the agent is
2232	// trained on to identify the intent.
2233	TrainingPhrases []*GoogleCloudDialogflowCxV3IntentTrainingPhrase `json:"trainingPhrases,omitempty"`
2234
2235	// ForceSendFields is a list of field names (e.g. "Description") to
2236	// unconditionally include in API requests. By default, fields with
2237	// empty or default values are omitted from API requests. However, any
2238	// non-pointer, non-interface field appearing in ForceSendFields will be
2239	// sent to the server regardless of whether the field is empty or not.
2240	// This may be used to include empty fields in Patch requests.
2241	ForceSendFields []string `json:"-"`
2242
2243	// NullFields is a list of field names (e.g. "Description") to include
2244	// in API requests with the JSON null value. By default, fields with
2245	// empty values are omitted from API requests. However, any field with
2246	// an empty value appearing in NullFields will be sent to the server as
2247	// null. It is an error if a field in this list has a non-empty value.
2248	// This may be used to include null fields in Patch requests.
2249	NullFields []string `json:"-"`
2250}
2251
2252func (s *GoogleCloudDialogflowCxV3Intent) MarshalJSON() ([]byte, error) {
2253	type NoMethod GoogleCloudDialogflowCxV3Intent
2254	raw := NoMethod(*s)
2255	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
2256}
2257
2258// GoogleCloudDialogflowCxV3IntentInput: Represents the intent to
2259// trigger programmatically rather than as a result of natural language
2260// processing.
2261type GoogleCloudDialogflowCxV3IntentInput struct {
2262	// Intent: Required. The unique identifier of the intent. Format:
2263	// `projects//locations//agents//intents/`.
2264	Intent string `json:"intent,omitempty"`
2265
2266	// ForceSendFields is a list of field names (e.g. "Intent") to
2267	// unconditionally include in API requests. By default, fields with
2268	// empty or default values are omitted from API requests. However, any
2269	// non-pointer, non-interface field appearing in ForceSendFields will be
2270	// sent to the server regardless of whether the field is empty or not.
2271	// This may be used to include empty fields in Patch requests.
2272	ForceSendFields []string `json:"-"`
2273
2274	// NullFields is a list of field names (e.g. "Intent") to include in API
2275	// requests with the JSON null value. By default, fields with empty
2276	// values are omitted from API requests. However, any field with an
2277	// empty value appearing in NullFields will be sent to the server as
2278	// null. It is an error if a field in this list has a non-empty value.
2279	// This may be used to include null fields in Patch requests.
2280	NullFields []string `json:"-"`
2281}
2282
2283func (s *GoogleCloudDialogflowCxV3IntentInput) MarshalJSON() ([]byte, error) {
2284	type NoMethod GoogleCloudDialogflowCxV3IntentInput
2285	raw := NoMethod(*s)
2286	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
2287}
2288
2289// GoogleCloudDialogflowCxV3IntentParameter: Represents an intent
2290// parameter.
2291type GoogleCloudDialogflowCxV3IntentParameter struct {
2292	// EntityType: Required. The entity type of the parameter. Format:
2293	// `projects/-/locations/-/agents/-/entityTypes/` for system entity
2294	// types (for example,
2295	// `projects/-/locations/-/agents/-/entityTypes/sys.date`), or
2296	// `projects//locations//agents//entityTypes/` for developer entity
2297	// types.
2298	EntityType string `json:"entityType,omitempty"`
2299
2300	// Id: Required. The unique identifier of the parameter. This field is
2301	// used by training phrases to annotate their parts.
2302	Id string `json:"id,omitempty"`
2303
2304	// IsList: Indicates whether the parameter represents a list of values.
2305	IsList bool `json:"isList,omitempty"`
2306
2307	// Redact: Indicates whether the parameter content should be redacted in
2308	// log. If redaction is enabled, the parameter content will be replaced
2309	// by parameter name during logging. Note: the parameter content is
2310	// subject to redaction if either parameter level redaction or entity
2311	// type level redaction is enabled.
2312	Redact bool `json:"redact,omitempty"`
2313
2314	// ForceSendFields is a list of field names (e.g. "EntityType") to
2315	// unconditionally include in API requests. By default, fields with
2316	// empty or default values are omitted from API requests. However, any
2317	// non-pointer, non-interface field appearing in ForceSendFields will be
2318	// sent to the server regardless of whether the field is empty or not.
2319	// This may be used to include empty fields in Patch requests.
2320	ForceSendFields []string `json:"-"`
2321
2322	// NullFields is a list of field names (e.g. "EntityType") to include in
2323	// API requests with the JSON null value. By default, fields with empty
2324	// values are omitted from API requests. However, any field with an
2325	// empty value appearing in NullFields will be sent to the server as
2326	// null. It is an error if a field in this list has a non-empty value.
2327	// This may be used to include null fields in Patch requests.
2328	NullFields []string `json:"-"`
2329}
2330
2331func (s *GoogleCloudDialogflowCxV3IntentParameter) MarshalJSON() ([]byte, error) {
2332	type NoMethod GoogleCloudDialogflowCxV3IntentParameter
2333	raw := NoMethod(*s)
2334	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
2335}
2336
2337// GoogleCloudDialogflowCxV3IntentTrainingPhrase: Represents an example
2338// that the agent is trained on to identify the intent.
2339type GoogleCloudDialogflowCxV3IntentTrainingPhrase struct {
2340	// Id: Output only. The unique identifier of the training phrase.
2341	Id string `json:"id,omitempty"`
2342
2343	// Parts: Required. The ordered list of training phrase parts. The parts
2344	// are concatenated in order to form the training phrase. Note: The API
2345	// does not automatically annotate training phrases like the Dialogflow
2346	// Console does. Note: Do not forget to include whitespace at part
2347	// boundaries, so the training phrase is well formatted when the parts
2348	// are concatenated. If the training phrase does not need to be
2349	// annotated with parameters, you just need a single part with only the
2350	// Part.text field set. If you want to annotate the training phrase, you
2351	// must create multiple parts, where the fields of each part are
2352	// populated in one of two ways: - `Part.text` is set to a part of the
2353	// phrase that has no parameters. - `Part.text` is set to a part of the
2354	// phrase that you want to annotate, and the `parameter_id` field is
2355	// set.
2356	Parts []*GoogleCloudDialogflowCxV3IntentTrainingPhrasePart `json:"parts,omitempty"`
2357
2358	// RepeatCount: Indicates how many times this example was added to the
2359	// intent.
2360	RepeatCount int64 `json:"repeatCount,omitempty"`
2361
2362	// ForceSendFields is a list of field names (e.g. "Id") to
2363	// unconditionally include in API requests. By default, fields with
2364	// empty or default values are omitted from API requests. However, any
2365	// non-pointer, non-interface field appearing in ForceSendFields will be
2366	// sent to the server regardless of whether the field is empty or not.
2367	// This may be used to include empty fields in Patch requests.
2368	ForceSendFields []string `json:"-"`
2369
2370	// NullFields is a list of field names (e.g. "Id") to include in API
2371	// requests with the JSON null value. By default, fields with empty
2372	// values are omitted from API requests. However, any field with an
2373	// empty value appearing in NullFields will be sent to the server as
2374	// null. It is an error if a field in this list has a non-empty value.
2375	// This may be used to include null fields in Patch requests.
2376	NullFields []string `json:"-"`
2377}
2378
2379func (s *GoogleCloudDialogflowCxV3IntentTrainingPhrase) MarshalJSON() ([]byte, error) {
2380	type NoMethod GoogleCloudDialogflowCxV3IntentTrainingPhrase
2381	raw := NoMethod(*s)
2382	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
2383}
2384
2385// GoogleCloudDialogflowCxV3IntentTrainingPhrasePart: Represents a part
2386// of a training phrase.
2387type GoogleCloudDialogflowCxV3IntentTrainingPhrasePart struct {
2388	// ParameterId: The parameter used to annotate this part of the training
2389	// phrase. This field is required for annotated parts of the training
2390	// phrase.
2391	ParameterId string `json:"parameterId,omitempty"`
2392
2393	// Text: Required. The text for this part.
2394	Text string `json:"text,omitempty"`
2395
2396	// ForceSendFields is a list of field names (e.g. "ParameterId") to
2397	// unconditionally include in API requests. By default, fields with
2398	// empty or default values are omitted from API requests. However, any
2399	// non-pointer, non-interface field appearing in ForceSendFields will be
2400	// sent to the server regardless of whether the field is empty or not.
2401	// This may be used to include empty fields in Patch requests.
2402	ForceSendFields []string `json:"-"`
2403
2404	// NullFields is a list of field names (e.g. "ParameterId") to include
2405	// in API requests with the JSON null value. By default, fields with
2406	// empty values are omitted from API requests. However, any field with
2407	// an empty value appearing in NullFields will be sent to the server as
2408	// null. It is an error if a field in this list has a non-empty value.
2409	// This may be used to include null fields in Patch requests.
2410	NullFields []string `json:"-"`
2411}
2412
2413func (s *GoogleCloudDialogflowCxV3IntentTrainingPhrasePart) MarshalJSON() ([]byte, error) {
2414	type NoMethod GoogleCloudDialogflowCxV3IntentTrainingPhrasePart
2415	raw := NoMethod(*s)
2416	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
2417}
2418
2419// GoogleCloudDialogflowCxV3Page: A Dialogflow CX conversation (session)
2420// can be described and visualized as a state machine. The states of a
2421// CX session are represented by pages. For each flow, you define many
2422// pages, where your combined pages can handle a complete conversation
2423// on the topics the flow is designed for. At any given moment, exactly
2424// one page is the current page, the current page is considered active,
2425// and the flow associated with that page is considered active. Every
2426// flow has a special start page. When a flow initially becomes active,
2427// the start page page becomes the current page. For each conversational
2428// turn, the current page will either stay the same or transition to
2429// another page. You configure each page to collect information from the
2430// end-user that is relevant for the conversational state represented by
2431// the page. For more information, see the Page guide
2432// (https://cloud.google.com/dialogflow/cx/docs/concept/page).
2433type GoogleCloudDialogflowCxV3Page struct {
2434	// DisplayName: Required. The human-readable name of the page, unique
2435	// within the agent.
2436	DisplayName string `json:"displayName,omitempty"`
2437
2438	// EntryFulfillment: The fulfillment to call when the session is
2439	// entering the page.
2440	EntryFulfillment *GoogleCloudDialogflowCxV3Fulfillment `json:"entryFulfillment,omitempty"`
2441
2442	// EventHandlers: Handlers associated with the page to handle events
2443	// such as webhook errors, no match or no input.
2444	EventHandlers []*GoogleCloudDialogflowCxV3EventHandler `json:"eventHandlers,omitempty"`
2445
2446	// Form: The form associated with the page, used for collecting
2447	// parameters relevant to the page.
2448	Form *GoogleCloudDialogflowCxV3Form `json:"form,omitempty"`
2449
2450	// Name: The unique identifier of the page. Required for the
2451	// Pages.UpdatePage method. Pages.CreatePage populates the name
2452	// automatically. Format: `projects//locations//agents//flows//pages/`.
2453	Name string `json:"name,omitempty"`
2454
2455	// TransitionRouteGroups: Ordered list of `TransitionRouteGroups`
2456	// associated with the page. Transition route groups must be unique
2457	// within a page. * If multiple transition routes within a page scope
2458	// refer to the same intent, then the precedence order is: page's
2459	// transition route -> page's transition route group -> flow's
2460	// transition routes. * If multiple transition route groups within a
2461	// page contain the same intent, then the first group in the ordered
2462	// list takes precedence.
2463	// Format:`projects//locations//agents//flows//transitionRouteGroups/`.
2464	TransitionRouteGroups []string `json:"transitionRouteGroups,omitempty"`
2465
2466	// TransitionRoutes: A list of transitions for the transition rules of
2467	// this page. They route the conversation to another page in the same
2468	// flow, or another flow. When we are in a certain page, the
2469	// TransitionRoutes are evalauted in the following order: *
2470	// TransitionRoutes defined in the page with intent specified. *
2471	// TransitionRoutes defined in the transition route groups with intent
2472	// specified. * TransitionRoutes defined in flow with intent specified.
2473	// * TransitionRoutes defined in the transition route groups with intent
2474	// specified. * TransitionRoutes defined in the page with only condition
2475	// specified. * TransitionRoutes defined in the transition route groups
2476	// with only condition specified.
2477	TransitionRoutes []*GoogleCloudDialogflowCxV3TransitionRoute `json:"transitionRoutes,omitempty"`
2478
2479	// ForceSendFields is a list of field names (e.g. "DisplayName") to
2480	// unconditionally include in API requests. By default, fields with
2481	// empty or default values are omitted from API requests. However, any
2482	// non-pointer, non-interface field appearing in ForceSendFields will be
2483	// sent to the server regardless of whether the field is empty or not.
2484	// This may be used to include empty fields in Patch requests.
2485	ForceSendFields []string `json:"-"`
2486
2487	// NullFields is a list of field names (e.g. "DisplayName") to include
2488	// in API requests with the JSON null value. By default, fields with
2489	// empty values are omitted from API requests. However, any field with
2490	// an empty value appearing in NullFields will be sent to the server as
2491	// null. It is an error if a field in this list has a non-empty value.
2492	// This may be used to include null fields in Patch requests.
2493	NullFields []string `json:"-"`
2494}
2495
2496func (s *GoogleCloudDialogflowCxV3Page) MarshalJSON() ([]byte, error) {
2497	type NoMethod GoogleCloudDialogflowCxV3Page
2498	raw := NoMethod(*s)
2499	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
2500}
2501
2502// GoogleCloudDialogflowCxV3PageInfo: Represents page information
2503// communicated to and from the webhook.
2504type GoogleCloudDialogflowCxV3PageInfo struct {
2505	// CurrentPage: Always present for WebhookRequest. Ignored for
2506	// WebhookResponse. The unique identifier of the current page. Format:
2507	// `projects//locations//agents//flows//pages/`.
2508	CurrentPage string `json:"currentPage,omitempty"`
2509
2510	// FormInfo: Optional for both WebhookRequest and WebhookResponse.
2511	// Information about the form.
2512	FormInfo *GoogleCloudDialogflowCxV3PageInfoFormInfo `json:"formInfo,omitempty"`
2513
2514	// ForceSendFields is a list of field names (e.g. "CurrentPage") to
2515	// unconditionally include in API requests. By default, fields with
2516	// empty or default values are omitted from API requests. However, any
2517	// non-pointer, non-interface field appearing in ForceSendFields will be
2518	// sent to the server regardless of whether the field is empty or not.
2519	// This may be used to include empty fields in Patch requests.
2520	ForceSendFields []string `json:"-"`
2521
2522	// NullFields is a list of field names (e.g. "CurrentPage") to include
2523	// in API requests with the JSON null value. By default, fields with
2524	// empty values are omitted from API requests. However, any field with
2525	// an empty value appearing in NullFields will be sent to the server as
2526	// null. It is an error if a field in this list has a non-empty value.
2527	// This may be used to include null fields in Patch requests.
2528	NullFields []string `json:"-"`
2529}
2530
2531func (s *GoogleCloudDialogflowCxV3PageInfo) MarshalJSON() ([]byte, error) {
2532	type NoMethod GoogleCloudDialogflowCxV3PageInfo
2533	raw := NoMethod(*s)
2534	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
2535}
2536
2537// GoogleCloudDialogflowCxV3PageInfoFormInfo: Represents form
2538// information.
2539type GoogleCloudDialogflowCxV3PageInfoFormInfo struct {
2540	// ParameterInfo: Optional for both WebhookRequest and WebhookResponse.
2541	// The parameters contained in the form. Note that the webhook cannot
2542	// add or remove any form parameter.
2543	ParameterInfo []*GoogleCloudDialogflowCxV3PageInfoFormInfoParameterInfo `json:"parameterInfo,omitempty"`
2544
2545	// ForceSendFields is a list of field names (e.g. "ParameterInfo") to
2546	// unconditionally include in API requests. By default, fields with
2547	// empty or default values are omitted from API requests. However, any
2548	// non-pointer, non-interface field appearing in ForceSendFields will be
2549	// sent to the server regardless of whether the field is empty or not.
2550	// This may be used to include empty fields in Patch requests.
2551	ForceSendFields []string `json:"-"`
2552
2553	// NullFields is a list of field names (e.g. "ParameterInfo") to include
2554	// in API requests with the JSON null value. By default, fields with
2555	// empty values are omitted from API requests. However, any field with
2556	// an empty value appearing in NullFields will be sent to the server as
2557	// null. It is an error if a field in this list has a non-empty value.
2558	// This may be used to include null fields in Patch requests.
2559	NullFields []string `json:"-"`
2560}
2561
2562func (s *GoogleCloudDialogflowCxV3PageInfoFormInfo) MarshalJSON() ([]byte, error) {
2563	type NoMethod GoogleCloudDialogflowCxV3PageInfoFormInfo
2564	raw := NoMethod(*s)
2565	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
2566}
2567
2568// GoogleCloudDialogflowCxV3PageInfoFormInfoParameterInfo: Represents
2569// parameter information.
2570type GoogleCloudDialogflowCxV3PageInfoFormInfoParameterInfo struct {
2571	// DisplayName: Always present for WebhookRequest. Required for
2572	// WebhookResponse. The human-readable name of the parameter, unique
2573	// within the form. This field cannot be modified by the webhook.
2574	DisplayName string `json:"displayName,omitempty"`
2575
2576	// JustCollected: Optional for WebhookRequest. Ignored for
2577	// WebhookResponse. Indicates if the parameter value was just collected
2578	// on the last conversation turn.
2579	JustCollected bool `json:"justCollected,omitempty"`
2580
2581	// Required: Optional for both WebhookRequest and WebhookResponse.
2582	// Indicates whether the parameter is required. Optional parameters will
2583	// not trigger prompts; however, they are filled if the user specifies
2584	// them. Required parameters must be filled before form filling
2585	// concludes.
2586	Required bool `json:"required,omitempty"`
2587
2588	// State: Always present for WebhookRequest. Required for
2589	// WebhookResponse. The state of the parameter. This field can be set to
2590	// INVALID by the webhook to invalidate the parameter; other values set
2591	// by the webhook will be ignored.
2592	//
2593	// Possible values:
2594	//   "PARAMETER_STATE_UNSPECIFIED" - Not specified. This value should be
2595	// never used.
2596	//   "EMPTY" - Indicates that the parameter does not have a value.
2597	//   "INVALID" - Indicates that the parameter value is invalid. This
2598	// field can be used by the webhook to invalidate the parameter and ask
2599	// the server to collect it from the user again.
2600	//   "FILLED" - Indicates that the parameter has a value.
2601	State string `json:"state,omitempty"`
2602
2603	// Value: Optional for both WebhookRequest and WebhookResponse. The
2604	// value of the parameter. This field can be set by the webhook to
2605	// change the parameter value.
2606	Value interface{} `json:"value,omitempty"`
2607
2608	// ForceSendFields is a list of field names (e.g. "DisplayName") to
2609	// unconditionally include in API requests. By default, fields with
2610	// empty or default values are omitted from API requests. However, any
2611	// non-pointer, non-interface field appearing in ForceSendFields will be
2612	// sent to the server regardless of whether the field is empty or not.
2613	// This may be used to include empty fields in Patch requests.
2614	ForceSendFields []string `json:"-"`
2615
2616	// NullFields is a list of field names (e.g. "DisplayName") to include
2617	// in API requests with the JSON null value. By default, fields with
2618	// empty values are omitted from API requests. However, any field with
2619	// an empty value appearing in NullFields will be sent to the server as
2620	// null. It is an error if a field in this list has a non-empty value.
2621	// This may be used to include null fields in Patch requests.
2622	NullFields []string `json:"-"`
2623}
2624
2625func (s *GoogleCloudDialogflowCxV3PageInfoFormInfoParameterInfo) MarshalJSON() ([]byte, error) {
2626	type NoMethod GoogleCloudDialogflowCxV3PageInfoFormInfoParameterInfo
2627	raw := NoMethod(*s)
2628	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
2629}
2630
2631// GoogleCloudDialogflowCxV3QueryInput: Represents the query input. It
2632// can contain one of: 1. A conversational query in the form of text. 2.
2633// An intent query that specifies which intent to trigger. 3. Natural
2634// language speech audio to be processed. 4. An event to be triggered.
2635type GoogleCloudDialogflowCxV3QueryInput struct {
2636	// Audio: The natural language speech audio to be processed.
2637	Audio *GoogleCloudDialogflowCxV3AudioInput `json:"audio,omitempty"`
2638
2639	// Dtmf: The DTMF event to be handled.
2640	Dtmf *GoogleCloudDialogflowCxV3DtmfInput `json:"dtmf,omitempty"`
2641
2642	// Event: The event to be triggered.
2643	Event *GoogleCloudDialogflowCxV3EventInput `json:"event,omitempty"`
2644
2645	// Intent: The intent to be triggered.
2646	Intent *GoogleCloudDialogflowCxV3IntentInput `json:"intent,omitempty"`
2647
2648	// LanguageCode: Required. The language of the input. See Language
2649	// Support
2650	// (https://cloud.google.com/dialogflow/cx/docs/reference/language) for
2651	// a list of the currently supported language codes. Note that queries
2652	// in the same session do not necessarily need to specify the same
2653	// language.
2654	LanguageCode string `json:"languageCode,omitempty"`
2655
2656	// Text: The natural language text to be processed.
2657	Text *GoogleCloudDialogflowCxV3TextInput `json:"text,omitempty"`
2658
2659	// ForceSendFields is a list of field names (e.g. "Audio") to
2660	// unconditionally include in API requests. By default, fields with
2661	// empty or default values are omitted from API requests. However, any
2662	// non-pointer, non-interface field appearing in ForceSendFields will be
2663	// sent to the server regardless of whether the field is empty or not.
2664	// This may be used to include empty fields in Patch requests.
2665	ForceSendFields []string `json:"-"`
2666
2667	// NullFields is a list of field names (e.g. "Audio") to include in API
2668	// requests with the JSON null value. By default, fields with empty
2669	// values are omitted from API requests. However, any field with an
2670	// empty value appearing in NullFields will be sent to the server as
2671	// null. It is an error if a field in this list has a non-empty value.
2672	// This may be used to include null fields in Patch requests.
2673	NullFields []string `json:"-"`
2674}
2675
2676func (s *GoogleCloudDialogflowCxV3QueryInput) MarshalJSON() ([]byte, error) {
2677	type NoMethod GoogleCloudDialogflowCxV3QueryInput
2678	raw := NoMethod(*s)
2679	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
2680}
2681
2682// GoogleCloudDialogflowCxV3ReloadDocumentOperationMetadata: Metadata
2683// for ReloadDocument operation.
2684type GoogleCloudDialogflowCxV3ReloadDocumentOperationMetadata struct {
2685	// GenericMetadata: The generic information of the operation.
2686	GenericMetadata *GoogleCloudDialogflowCxV3GenericKnowledgeOperationMetadata `json:"genericMetadata,omitempty"`
2687
2688	// ForceSendFields is a list of field names (e.g. "GenericMetadata") to
2689	// unconditionally include in API requests. By default, fields with
2690	// empty or default values are omitted from API requests. However, any
2691	// non-pointer, non-interface field appearing in ForceSendFields will be
2692	// sent to the server regardless of whether the field is empty or not.
2693	// This may be used to include empty fields in Patch requests.
2694	ForceSendFields []string `json:"-"`
2695
2696	// NullFields is a list of field names (e.g. "GenericMetadata") to
2697	// include in API requests with the JSON null value. By default, fields
2698	// with empty values are omitted from API requests. However, any field
2699	// with an empty value appearing in NullFields will be sent to the
2700	// server as null. It is an error if a field in this list has a
2701	// non-empty value. This may be used to include null fields in Patch
2702	// requests.
2703	NullFields []string `json:"-"`
2704}
2705
2706func (s *GoogleCloudDialogflowCxV3ReloadDocumentOperationMetadata) MarshalJSON() ([]byte, error) {
2707	type NoMethod GoogleCloudDialogflowCxV3ReloadDocumentOperationMetadata
2708	raw := NoMethod(*s)
2709	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
2710}
2711
2712// GoogleCloudDialogflowCxV3ResponseMessage: Represents a response
2713// message that can be returned by a conversational agent. Response
2714// messages are also used for output audio synthesis. The approach is as
2715// follows: * If at least one OutputAudioText response is present, then
2716// all OutputAudioText responses are linearly concatenated, and the
2717// result is used for output audio synthesis. * If the OutputAudioText
2718// responses are a mixture of text and SSML, then the concatenated
2719// result is treated as SSML; otherwise, the result is treated as either
2720// text or SSML as appropriate. The agent designer should ideally use
2721// either text or SSML consistently throughout the bot design. *
2722// Otherwise, all Text responses are linearly concatenated, and the
2723// result is used for output audio synthesis. This approach allows for
2724// more sophisticated user experience scenarios, where the text
2725// displayed to the user may differ from what is heard.
2726type GoogleCloudDialogflowCxV3ResponseMessage struct {
2727	// ConversationSuccess: Indicates that the conversation succeeded.
2728	ConversationSuccess *GoogleCloudDialogflowCxV3ResponseMessageConversationSuccess `json:"conversationSuccess,omitempty"`
2729
2730	// EndInteraction: Output only. A signal that indicates the interaction
2731	// with the Dialogflow agent has ended. This message is generated by
2732	// Dialogflow only when the conversation reaches `END_SESSION` page. It
2733	// is not supposed to be defined by the user. It's guaranteed that there
2734	// is at most one such message in each response.
2735	EndInteraction *GoogleCloudDialogflowCxV3ResponseMessageEndInteraction `json:"endInteraction,omitempty"`
2736
2737	// LiveAgentHandoff: Hands off conversation to a human agent.
2738	LiveAgentHandoff *GoogleCloudDialogflowCxV3ResponseMessageLiveAgentHandoff `json:"liveAgentHandoff,omitempty"`
2739
2740	// MixedAudio: Output only. An audio response message composed of both
2741	// the synthesized Dialogflow agent responses and responses defined via
2742	// play_audio. This message is generated by Dialogflow only and not
2743	// supposed to be defined by the user.
2744	MixedAudio *GoogleCloudDialogflowCxV3ResponseMessageMixedAudio `json:"mixedAudio,omitempty"`
2745
2746	// OutputAudioText: A text or ssml response that is preferentially used
2747	// for TTS output audio synthesis, as described in the comment on the
2748	// ResponseMessage message.
2749	OutputAudioText *GoogleCloudDialogflowCxV3ResponseMessageOutputAudioText `json:"outputAudioText,omitempty"`
2750
2751	// Payload: Returns a response containing a custom, platform-specific
2752	// payload.
2753	Payload googleapi.RawMessage `json:"payload,omitempty"`
2754
2755	// PlayAudio: Signal that the client should play an audio clip hosted at
2756	// a client-specific URI. Dialogflow uses this to construct mixed_audio.
2757	// However, Dialogflow itself does not try to read or process the URI in
2758	// any way.
2759	PlayAudio *GoogleCloudDialogflowCxV3ResponseMessagePlayAudio `json:"playAudio,omitempty"`
2760
2761	// Text: Returns a text response.
2762	Text *GoogleCloudDialogflowCxV3ResponseMessageText `json:"text,omitempty"`
2763
2764	// ForceSendFields is a list of field names (e.g. "ConversationSuccess")
2765	// to unconditionally include in API requests. By default, fields with
2766	// empty or default values are omitted from API requests. However, any
2767	// non-pointer, non-interface field appearing in ForceSendFields will be
2768	// sent to the server regardless of whether the field is empty or not.
2769	// This may be used to include empty fields in Patch requests.
2770	ForceSendFields []string `json:"-"`
2771
2772	// NullFields is a list of field names (e.g. "ConversationSuccess") to
2773	// include in API requests with the JSON null value. By default, fields
2774	// with empty values are omitted from API requests. However, any field
2775	// with an empty value appearing in NullFields will be sent to the
2776	// server as null. It is an error if a field in this list has a
2777	// non-empty value. This may be used to include null fields in Patch
2778	// requests.
2779	NullFields []string `json:"-"`
2780}
2781
2782func (s *GoogleCloudDialogflowCxV3ResponseMessage) MarshalJSON() ([]byte, error) {
2783	type NoMethod GoogleCloudDialogflowCxV3ResponseMessage
2784	raw := NoMethod(*s)
2785	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
2786}
2787
2788// GoogleCloudDialogflowCxV3ResponseMessageConversationSuccess:
2789// Indicates that the conversation succeeded, i.e., the bot handled the
2790// issue that the customer talked to it about. Dialogflow only uses this
2791// to determine which conversations should be counted as successful and
2792// doesn't process the metadata in this message in any way. Note that
2793// Dialogflow also considers conversations that get to the conversation
2794// end page as successful even if they don't return ConversationSuccess.
2795// You may set this, for example: * In the entry_fulfillment of a Page
2796// if entering the page indicates that the conversation succeeded. * In
2797// a webhook response when you determine that you handled the customer
2798// issue.
2799type GoogleCloudDialogflowCxV3ResponseMessageConversationSuccess struct {
2800	// Metadata: Custom metadata. Dialogflow doesn't impose any structure on
2801	// this.
2802	Metadata googleapi.RawMessage `json:"metadata,omitempty"`
2803
2804	// ForceSendFields is a list of field names (e.g. "Metadata") to
2805	// unconditionally include in API requests. By default, fields with
2806	// empty or default values are omitted from API requests. However, any
2807	// non-pointer, non-interface field appearing in ForceSendFields will be
2808	// sent to the server regardless of whether the field is empty or not.
2809	// This may be used to include empty fields in Patch requests.
2810	ForceSendFields []string `json:"-"`
2811
2812	// NullFields is a list of field names (e.g. "Metadata") to include in
2813	// API requests with the JSON null value. By default, fields with empty
2814	// values are omitted from API requests. However, any field with an
2815	// empty value appearing in NullFields will be sent to the server as
2816	// null. It is an error if a field in this list has a non-empty value.
2817	// This may be used to include null fields in Patch requests.
2818	NullFields []string `json:"-"`
2819}
2820
2821func (s *GoogleCloudDialogflowCxV3ResponseMessageConversationSuccess) MarshalJSON() ([]byte, error) {
2822	type NoMethod GoogleCloudDialogflowCxV3ResponseMessageConversationSuccess
2823	raw := NoMethod(*s)
2824	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
2825}
2826
2827// GoogleCloudDialogflowCxV3ResponseMessageEndInteraction: Indicates
2828// that interaction with the Dialogflow agent has ended. This message is
2829// generated by Dialogflow only and not supposed to be defined by the
2830// user.
2831type GoogleCloudDialogflowCxV3ResponseMessageEndInteraction struct {
2832}
2833
2834// GoogleCloudDialogflowCxV3ResponseMessageLiveAgentHandoff: Indicates
2835// that the conversation should be handed off to a live agent.
2836// Dialogflow only uses this to determine which conversations were
2837// handed off to a human agent for measurement purposes. What else to do
2838// with this signal is up to you and your handoff procedures. You may
2839// set this, for example: * In the entry_fulfillment of a Page if
2840// entering the page indicates something went extremely wrong in the
2841// conversation. * In a webhook response when you determine that the
2842// customer issue can only be handled by a human.
2843type GoogleCloudDialogflowCxV3ResponseMessageLiveAgentHandoff struct {
2844	// Metadata: Custom metadata for your handoff procedure. Dialogflow
2845	// doesn't impose any structure on this.
2846	Metadata googleapi.RawMessage `json:"metadata,omitempty"`
2847
2848	// ForceSendFields is a list of field names (e.g. "Metadata") to
2849	// unconditionally include in API requests. By default, fields with
2850	// empty or default values are omitted from API requests. However, any
2851	// non-pointer, non-interface field appearing in ForceSendFields will be
2852	// sent to the server regardless of whether the field is empty or not.
2853	// This may be used to include empty fields in Patch requests.
2854	ForceSendFields []string `json:"-"`
2855
2856	// NullFields is a list of field names (e.g. "Metadata") to include in
2857	// API requests with the JSON null value. By default, fields with empty
2858	// values are omitted from API requests. However, any field with an
2859	// empty value appearing in NullFields will be sent to the server as
2860	// null. It is an error if a field in this list has a non-empty value.
2861	// This may be used to include null fields in Patch requests.
2862	NullFields []string `json:"-"`
2863}
2864
2865func (s *GoogleCloudDialogflowCxV3ResponseMessageLiveAgentHandoff) MarshalJSON() ([]byte, error) {
2866	type NoMethod GoogleCloudDialogflowCxV3ResponseMessageLiveAgentHandoff
2867	raw := NoMethod(*s)
2868	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
2869}
2870
2871// GoogleCloudDialogflowCxV3ResponseMessageMixedAudio: Represents an
2872// audio message that is composed of both segments synthesized from the
2873// Dialogflow agent prompts and ones hosted externally at the specified
2874// URIs. The external URIs are specified via play_audio. This message is
2875// generated by Dialogflow only and not supposed to be defined by the
2876// user.
2877type GoogleCloudDialogflowCxV3ResponseMessageMixedAudio struct {
2878	// Segments: Segments this audio response is composed of.
2879	Segments []*GoogleCloudDialogflowCxV3ResponseMessageMixedAudioSegment `json:"segments,omitempty"`
2880
2881	// ForceSendFields is a list of field names (e.g. "Segments") to
2882	// unconditionally include in API requests. By default, fields with
2883	// empty or default values are omitted from API requests. However, any
2884	// non-pointer, non-interface field appearing in ForceSendFields will be
2885	// sent to the server regardless of whether the field is empty or not.
2886	// This may be used to include empty fields in Patch requests.
2887	ForceSendFields []string `json:"-"`
2888
2889	// NullFields is a list of field names (e.g. "Segments") to include in
2890	// API requests with the JSON null value. By default, fields with empty
2891	// values are omitted from API requests. However, any field with an
2892	// empty value appearing in NullFields will be sent to the server as
2893	// null. It is an error if a field in this list has a non-empty value.
2894	// This may be used to include null fields in Patch requests.
2895	NullFields []string `json:"-"`
2896}
2897
2898func (s *GoogleCloudDialogflowCxV3ResponseMessageMixedAudio) MarshalJSON() ([]byte, error) {
2899	type NoMethod GoogleCloudDialogflowCxV3ResponseMessageMixedAudio
2900	raw := NoMethod(*s)
2901	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
2902}
2903
2904// GoogleCloudDialogflowCxV3ResponseMessageMixedAudioSegment: Represents
2905// one segment of audio.
2906type GoogleCloudDialogflowCxV3ResponseMessageMixedAudioSegment struct {
2907	// AllowPlaybackInterruption: Output only. Whether the playback of this
2908	// segment can be interrupted by the end user's speech and the client
2909	// should then start the next Dialogflow request.
2910	AllowPlaybackInterruption bool `json:"allowPlaybackInterruption,omitempty"`
2911
2912	// Audio: Raw audio synthesized from the Dialogflow agent's response
2913	// using the output config specified in the request.
2914	Audio string `json:"audio,omitempty"`
2915
2916	// Uri: Client-specific URI that points to an audio clip accessible to
2917	// the client. Dialogflow does not impose any validation on it.
2918	Uri string `json:"uri,omitempty"`
2919
2920	// ForceSendFields is a list of field names (e.g.
2921	// "AllowPlaybackInterruption") to unconditionally include in API
2922	// requests. By default, fields with empty or default values are omitted
2923	// from API requests. However, any non-pointer, non-interface field
2924	// appearing in ForceSendFields will be sent to the server regardless of
2925	// whether the field is empty or not. This may be used to include empty
2926	// fields in Patch requests.
2927	ForceSendFields []string `json:"-"`
2928
2929	// NullFields is a list of field names (e.g.
2930	// "AllowPlaybackInterruption") to include in API requests with the JSON
2931	// null value. By default, fields with empty values are omitted from API
2932	// requests. However, any field with an empty value appearing in
2933	// NullFields will be sent to the server as null. It is an error if a
2934	// field in this list has a non-empty value. This may be used to include
2935	// null fields in Patch requests.
2936	NullFields []string `json:"-"`
2937}
2938
2939func (s *GoogleCloudDialogflowCxV3ResponseMessageMixedAudioSegment) MarshalJSON() ([]byte, error) {
2940	type NoMethod GoogleCloudDialogflowCxV3ResponseMessageMixedAudioSegment
2941	raw := NoMethod(*s)
2942	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
2943}
2944
2945// GoogleCloudDialogflowCxV3ResponseMessageOutputAudioText: A text or
2946// ssml response that is preferentially used for TTS output audio
2947// synthesis, as described in the comment on the ResponseMessage
2948// message.
2949type GoogleCloudDialogflowCxV3ResponseMessageOutputAudioText struct {
2950	// AllowPlaybackInterruption: Output only. Whether the playback of this
2951	// message can be interrupted by the end user's speech and the client
2952	// can then starts the next Dialogflow request.
2953	AllowPlaybackInterruption bool `json:"allowPlaybackInterruption,omitempty"`
2954
2955	// Ssml: The SSML text to be synthesized. For more information, see SSML
2956	// (/speech/text-to-speech/docs/ssml).
2957	Ssml string `json:"ssml,omitempty"`
2958
2959	// Text: The raw text to be synthesized.
2960	Text string `json:"text,omitempty"`
2961
2962	// ForceSendFields is a list of field names (e.g.
2963	// "AllowPlaybackInterruption") to unconditionally include in API
2964	// requests. By default, fields with empty or default values are omitted
2965	// from API requests. However, any non-pointer, non-interface field
2966	// appearing in ForceSendFields will be sent to the server regardless of
2967	// whether the field is empty or not. This may be used to include empty
2968	// fields in Patch requests.
2969	ForceSendFields []string `json:"-"`
2970
2971	// NullFields is a list of field names (e.g.
2972	// "AllowPlaybackInterruption") to include in API requests with the JSON
2973	// null value. By default, fields with empty values are omitted from API
2974	// requests. However, any field with an empty value appearing in
2975	// NullFields will be sent to the server as null. It is an error if a
2976	// field in this list has a non-empty value. This may be used to include
2977	// null fields in Patch requests.
2978	NullFields []string `json:"-"`
2979}
2980
2981func (s *GoogleCloudDialogflowCxV3ResponseMessageOutputAudioText) MarshalJSON() ([]byte, error) {
2982	type NoMethod GoogleCloudDialogflowCxV3ResponseMessageOutputAudioText
2983	raw := NoMethod(*s)
2984	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
2985}
2986
2987// GoogleCloudDialogflowCxV3ResponseMessagePlayAudio: Specifies an audio
2988// clip to be played by the client as part of the response.
2989type GoogleCloudDialogflowCxV3ResponseMessagePlayAudio struct {
2990	// AllowPlaybackInterruption: Output only. Whether the playback of this
2991	// message can be interrupted by the end user's speech and the client
2992	// can then starts the next Dialogflow request.
2993	AllowPlaybackInterruption bool `json:"allowPlaybackInterruption,omitempty"`
2994
2995	// AudioUri: Required. URI of the audio clip. Dialogflow does not impose
2996	// any validation on this value. It is specific to the client that reads
2997	// it.
2998	AudioUri string `json:"audioUri,omitempty"`
2999
3000	// ForceSendFields is a list of field names (e.g.
3001	// "AllowPlaybackInterruption") to unconditionally include in API
3002	// requests. By default, fields with empty or default values are omitted
3003	// from API requests. However, any non-pointer, non-interface field
3004	// appearing in ForceSendFields will be sent to the server regardless of
3005	// whether the field is empty or not. This may be used to include empty
3006	// fields in Patch requests.
3007	ForceSendFields []string `json:"-"`
3008
3009	// NullFields is a list of field names (e.g.
3010	// "AllowPlaybackInterruption") to include in API requests with the JSON
3011	// null value. By default, fields with empty values are omitted from API
3012	// requests. However, any field with an empty value appearing in
3013	// NullFields will be sent to the server as null. It is an error if a
3014	// field in this list has a non-empty value. This may be used to include
3015	// null fields in Patch requests.
3016	NullFields []string `json:"-"`
3017}
3018
3019func (s *GoogleCloudDialogflowCxV3ResponseMessagePlayAudio) MarshalJSON() ([]byte, error) {
3020	type NoMethod GoogleCloudDialogflowCxV3ResponseMessagePlayAudio
3021	raw := NoMethod(*s)
3022	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
3023}
3024
3025// GoogleCloudDialogflowCxV3ResponseMessageText: The text response
3026// message.
3027type GoogleCloudDialogflowCxV3ResponseMessageText struct {
3028	// AllowPlaybackInterruption: Output only. Whether the playback of this
3029	// message can be interrupted by the end user's speech and the client
3030	// can then starts the next Dialogflow request.
3031	AllowPlaybackInterruption bool `json:"allowPlaybackInterruption,omitempty"`
3032
3033	// Text: Required. A collection of text responses.
3034	Text []string `json:"text,omitempty"`
3035
3036	// ForceSendFields is a list of field names (e.g.
3037	// "AllowPlaybackInterruption") to unconditionally include in API
3038	// requests. By default, fields with empty or default values are omitted
3039	// from API requests. However, any non-pointer, non-interface field
3040	// appearing in ForceSendFields will be sent to the server regardless of
3041	// whether the field is empty or not. This may be used to include empty
3042	// fields in Patch requests.
3043	ForceSendFields []string `json:"-"`
3044
3045	// NullFields is a list of field names (e.g.
3046	// "AllowPlaybackInterruption") to include in API requests with the JSON
3047	// null value. By default, fields with empty values are omitted from API
3048	// requests. However, any field with an empty value appearing in
3049	// NullFields will be sent to the server as null. It is an error if a
3050	// field in this list has a non-empty value. This may be used to include
3051	// null fields in Patch requests.
3052	NullFields []string `json:"-"`
3053}
3054
3055func (s *GoogleCloudDialogflowCxV3ResponseMessageText) MarshalJSON() ([]byte, error) {
3056	type NoMethod GoogleCloudDialogflowCxV3ResponseMessageText
3057	raw := NoMethod(*s)
3058	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
3059}
3060
3061// GoogleCloudDialogflowCxV3RunContinuousTestMetadata: Metadata returned
3062// for the Environments.RunContinuousTest long running operation.
3063type GoogleCloudDialogflowCxV3RunContinuousTestMetadata struct {
3064	// Errors: The test errors.
3065	Errors []*GoogleCloudDialogflowCxV3TestError `json:"errors,omitempty"`
3066
3067	// ForceSendFields is a list of field names (e.g. "Errors") to
3068	// unconditionally include in API requests. By default, fields with
3069	// empty or default values are omitted from API requests. However, any
3070	// non-pointer, non-interface field appearing in ForceSendFields will be
3071	// sent to the server regardless of whether the field is empty or not.
3072	// This may be used to include empty fields in Patch requests.
3073	ForceSendFields []string `json:"-"`
3074
3075	// NullFields is a list of field names (e.g. "Errors") to include in API
3076	// requests with the JSON null value. By default, fields with empty
3077	// values are omitted from API requests. However, any field with an
3078	// empty value appearing in NullFields will be sent to the server as
3079	// null. It is an error if a field in this list has a non-empty value.
3080	// This may be used to include null fields in Patch requests.
3081	NullFields []string `json:"-"`
3082}
3083
3084func (s *GoogleCloudDialogflowCxV3RunContinuousTestMetadata) MarshalJSON() ([]byte, error) {
3085	type NoMethod GoogleCloudDialogflowCxV3RunContinuousTestMetadata
3086	raw := NoMethod(*s)
3087	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
3088}
3089
3090// GoogleCloudDialogflowCxV3RunContinuousTestResponse: The response
3091// message for Environments.RunContinuousTest.
3092type GoogleCloudDialogflowCxV3RunContinuousTestResponse struct {
3093	// ContinuousTestResult: The result for a continuous test run.
3094	ContinuousTestResult *GoogleCloudDialogflowCxV3ContinuousTestResult `json:"continuousTestResult,omitempty"`
3095
3096	// ForceSendFields is a list of field names (e.g.
3097	// "ContinuousTestResult") to unconditionally include in API requests.
3098	// By default, fields with empty or default values are omitted from API
3099	// requests. However, any non-pointer, non-interface field appearing in
3100	// ForceSendFields will be sent to the server regardless of whether the
3101	// field is empty or not. This may be used to include empty fields in
3102	// Patch requests.
3103	ForceSendFields []string `json:"-"`
3104
3105	// NullFields is a list of field names (e.g. "ContinuousTestResult") to
3106	// include in API requests with the JSON null value. By default, fields
3107	// with empty values are omitted from API requests. However, any field
3108	// with an empty value appearing in NullFields will be sent to the
3109	// server as null. It is an error if a field in this list has a
3110	// non-empty value. This may be used to include null fields in Patch
3111	// requests.
3112	NullFields []string `json:"-"`
3113}
3114
3115func (s *GoogleCloudDialogflowCxV3RunContinuousTestResponse) MarshalJSON() ([]byte, error) {
3116	type NoMethod GoogleCloudDialogflowCxV3RunContinuousTestResponse
3117	raw := NoMethod(*s)
3118	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
3119}
3120
3121// GoogleCloudDialogflowCxV3RunTestCaseMetadata: Metadata returned for
3122// the TestCases.RunTestCase long running operation. This message
3123// currently has no fields.
3124type GoogleCloudDialogflowCxV3RunTestCaseMetadata struct {
3125}
3126
3127// GoogleCloudDialogflowCxV3RunTestCaseResponse: The response message
3128// for TestCases.RunTestCase.
3129type GoogleCloudDialogflowCxV3RunTestCaseResponse struct {
3130	// Result: The result.
3131	Result *GoogleCloudDialogflowCxV3TestCaseResult `json:"result,omitempty"`
3132
3133	// ForceSendFields is a list of field names (e.g. "Result") to
3134	// unconditionally include in API requests. By default, fields with
3135	// empty or default values are omitted from API requests. However, any
3136	// non-pointer, non-interface field appearing in ForceSendFields will be
3137	// sent to the server regardless of whether the field is empty or not.
3138	// This may be used to include empty fields in Patch requests.
3139	ForceSendFields []string `json:"-"`
3140
3141	// NullFields is a list of field names (e.g. "Result") to include in API
3142	// requests with the JSON null value. By default, fields with empty
3143	// values are omitted from API requests. However, any field with an
3144	// empty value appearing in NullFields will be sent to the server as
3145	// null. It is an error if a field in this list has a non-empty value.
3146	// This may be used to include null fields in Patch requests.
3147	NullFields []string `json:"-"`
3148}
3149
3150func (s *GoogleCloudDialogflowCxV3RunTestCaseResponse) MarshalJSON() ([]byte, error) {
3151	type NoMethod GoogleCloudDialogflowCxV3RunTestCaseResponse
3152	raw := NoMethod(*s)
3153	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
3154}
3155
3156// GoogleCloudDialogflowCxV3SessionInfo: Represents session information
3157// communicated to and from the webhook.
3158type GoogleCloudDialogflowCxV3SessionInfo struct {
3159	// Parameters: Optional for WebhookRequest. Optional for
3160	// WebhookResponse. All parameters collected from forms and intents
3161	// during the session. Parameters can be created, updated, or removed by
3162	// the webhook. To remove a parameter from the session, the webhook
3163	// should explicitly set the parameter value to null in WebhookResponse.
3164	// The map is keyed by parameters' display names.
3165	Parameters googleapi.RawMessage `json:"parameters,omitempty"`
3166
3167	// Session: Always present for WebhookRequest. Ignored for
3168	// WebhookResponse. The unique identifier of the session. This field can
3169	// be used by the webhook to identify a session. Format:
3170	// `projects//locations//agents//sessions/` or
3171	// `projects//locations//agents//environments//sessions/` if environment
3172	// is specified.
3173	Session string `json:"session,omitempty"`
3174
3175	// ForceSendFields is a list of field names (e.g. "Parameters") to
3176	// unconditionally include in API requests. By default, fields with
3177	// empty or default values are omitted from API requests. However, any
3178	// non-pointer, non-interface field appearing in ForceSendFields will be
3179	// sent to the server regardless of whether the field is empty or not.
3180	// This may be used to include empty fields in Patch requests.
3181	ForceSendFields []string `json:"-"`
3182
3183	// NullFields is a list of field names (e.g. "Parameters") to include in
3184	// API requests with the JSON null value. By default, fields with empty
3185	// values are omitted from API requests. However, any field with an
3186	// empty value appearing in NullFields will be sent to the server as
3187	// null. It is an error if a field in this list has a non-empty value.
3188	// This may be used to include null fields in Patch requests.
3189	NullFields []string `json:"-"`
3190}
3191
3192func (s *GoogleCloudDialogflowCxV3SessionInfo) MarshalJSON() ([]byte, error) {
3193	type NoMethod GoogleCloudDialogflowCxV3SessionInfo
3194	raw := NoMethod(*s)
3195	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
3196}
3197
3198// GoogleCloudDialogflowCxV3TestCase: Represents a test case.
3199type GoogleCloudDialogflowCxV3TestCase struct {
3200	// CreationTime: Output only. When the test was created.
3201	CreationTime string `json:"creationTime,omitempty"`
3202
3203	// DisplayName: Required. The human-readable name of the test case,
3204	// unique within the agent. Limit of 200 characters.
3205	DisplayName string `json:"displayName,omitempty"`
3206
3207	// LastTestResult: The latest test result.
3208	LastTestResult *GoogleCloudDialogflowCxV3TestCaseResult `json:"lastTestResult,omitempty"`
3209
3210	// Name: The unique identifier of the test case.
3211	// TestCases.CreateTestCase will populate the name automatically.
3212	// Otherwise use format: `projects//locations//agents/ /testCases/`.
3213	Name string `json:"name,omitempty"`
3214
3215	// Notes: Additional freeform notes about the test case. Limit of 400
3216	// characters.
3217	Notes string `json:"notes,omitempty"`
3218
3219	// Tags: Tags are short descriptions that users may apply to test cases
3220	// for organizational and filtering purposes. Each tag should start with
3221	// "#" and has a limit of 30 characters.
3222	Tags []string `json:"tags,omitempty"`
3223
3224	// TestCaseConversationTurns: The conversation turns uttered when the
3225	// test case was created, in chronological order. These include the
3226	// canonical set of agent utterances that should occur when the agent is
3227	// working properly.
3228	TestCaseConversationTurns []*GoogleCloudDialogflowCxV3ConversationTurn `json:"testCaseConversationTurns,omitempty"`
3229
3230	// TestConfig: Config for the test case.
3231	TestConfig *GoogleCloudDialogflowCxV3TestConfig `json:"testConfig,omitempty"`
3232
3233	// ForceSendFields is a list of field names (e.g. "CreationTime") to
3234	// unconditionally include in API requests. By default, fields with
3235	// empty or default values are omitted from API requests. However, any
3236	// non-pointer, non-interface field appearing in ForceSendFields will be
3237	// sent to the server regardless of whether the field is empty or not.
3238	// This may be used to include empty fields in Patch requests.
3239	ForceSendFields []string `json:"-"`
3240
3241	// NullFields is a list of field names (e.g. "CreationTime") to include
3242	// in API requests with the JSON null value. By default, fields with
3243	// empty values are omitted from API requests. However, any field with
3244	// an empty value appearing in NullFields will be sent to the server as
3245	// null. It is an error if a field in this list has a non-empty value.
3246	// This may be used to include null fields in Patch requests.
3247	NullFields []string `json:"-"`
3248}
3249
3250func (s *GoogleCloudDialogflowCxV3TestCase) MarshalJSON() ([]byte, error) {
3251	type NoMethod GoogleCloudDialogflowCxV3TestCase
3252	raw := NoMethod(*s)
3253	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
3254}
3255
3256// GoogleCloudDialogflowCxV3TestCaseError: Error info for importing a
3257// test.
3258type GoogleCloudDialogflowCxV3TestCaseError struct {
3259	// Status: The status associated with the test case.
3260	Status *GoogleRpcStatus `json:"status,omitempty"`
3261
3262	// TestCase: The test case.
3263	TestCase *GoogleCloudDialogflowCxV3TestCase `json:"testCase,omitempty"`
3264
3265	// ForceSendFields is a list of field names (e.g. "Status") to
3266	// unconditionally include in API requests. By default, fields with
3267	// empty or default values are omitted from API requests. However, any
3268	// non-pointer, non-interface field appearing in ForceSendFields will be
3269	// sent to the server regardless of whether the field is empty or not.
3270	// This may be used to include empty fields in Patch requests.
3271	ForceSendFields []string `json:"-"`
3272
3273	// NullFields is a list of field names (e.g. "Status") to include in API
3274	// requests with the JSON null value. By default, fields with empty
3275	// values are omitted from API requests. However, any field with an
3276	// empty value appearing in NullFields will be sent to the server as
3277	// null. It is an error if a field in this list has a non-empty value.
3278	// This may be used to include null fields in Patch requests.
3279	NullFields []string `json:"-"`
3280}
3281
3282func (s *GoogleCloudDialogflowCxV3TestCaseError) MarshalJSON() ([]byte, error) {
3283	type NoMethod GoogleCloudDialogflowCxV3TestCaseError
3284	raw := NoMethod(*s)
3285	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
3286}
3287
3288// GoogleCloudDialogflowCxV3TestCaseResult: Represents a result from
3289// running a test case in an agent environment.
3290type GoogleCloudDialogflowCxV3TestCaseResult struct {
3291	// ConversationTurns: The conversation turns uttered during the test
3292	// case replay in chronological order.
3293	ConversationTurns []*GoogleCloudDialogflowCxV3ConversationTurn `json:"conversationTurns,omitempty"`
3294
3295	// Environment: Environment where the test was run. If not set, it
3296	// indicates the draft environment.
3297	Environment string `json:"environment,omitempty"`
3298
3299	// Name: The resource name for the test case result. Format:
3300	// `projects//locations//agents//testCases/ /results/`.
3301	Name string `json:"name,omitempty"`
3302
3303	// TestResult: Whether the test case passed in the agent environment.
3304	//
3305	// Possible values:
3306	//   "TEST_RESULT_UNSPECIFIED" - Not specified. Should never be used.
3307	//   "PASSED" - The test passed.
3308	//   "FAILED" - The test did not pass.
3309	TestResult string `json:"testResult,omitempty"`
3310
3311	// TestTime: The time that the test was run.
3312	TestTime string `json:"testTime,omitempty"`
3313
3314	// ForceSendFields is a list of field names (e.g. "ConversationTurns")
3315	// to unconditionally include in API requests. By default, fields with
3316	// empty or default values are omitted from API requests. However, any
3317	// non-pointer, non-interface field appearing in ForceSendFields will be
3318	// sent to the server regardless of whether the field is empty or not.
3319	// This may be used to include empty fields in Patch requests.
3320	ForceSendFields []string `json:"-"`
3321
3322	// NullFields is a list of field names (e.g. "ConversationTurns") to
3323	// include in API requests with the JSON null value. By default, fields
3324	// with empty values are omitted from API requests. However, any field
3325	// with an empty value appearing in NullFields will be sent to the
3326	// server as null. It is an error if a field in this list has a
3327	// non-empty value. This may be used to include null fields in Patch
3328	// requests.
3329	NullFields []string `json:"-"`
3330}
3331
3332func (s *GoogleCloudDialogflowCxV3TestCaseResult) MarshalJSON() ([]byte, error) {
3333	type NoMethod GoogleCloudDialogflowCxV3TestCaseResult
3334	raw := NoMethod(*s)
3335	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
3336}
3337
3338// GoogleCloudDialogflowCxV3TestConfig: Represents configurations for a
3339// test case.
3340type GoogleCloudDialogflowCxV3TestConfig struct {
3341	// Flow: Flow name. If not set, default start flow is assumed. Format:
3342	// `projects//locations//agents//flows/`.
3343	Flow string `json:"flow,omitempty"`
3344
3345	// TrackingParameters: Session parameters to be compared when
3346	// calculating differences.
3347	TrackingParameters []string `json:"trackingParameters,omitempty"`
3348
3349	// ForceSendFields is a list of field names (e.g. "Flow") to
3350	// unconditionally include in API requests. By default, fields with
3351	// empty or default values are omitted from API requests. However, any
3352	// non-pointer, non-interface field appearing in ForceSendFields will be
3353	// sent to the server regardless of whether the field is empty or not.
3354	// This may be used to include empty fields in Patch requests.
3355	ForceSendFields []string `json:"-"`
3356
3357	// NullFields is a list of field names (e.g. "Flow") to include in API
3358	// requests with the JSON null value. By default, fields with empty
3359	// values are omitted from API requests. However, any field with an
3360	// empty value appearing in NullFields will be sent to the server as
3361	// null. It is an error if a field in this list has a non-empty value.
3362	// This may be used to include null fields in Patch requests.
3363	NullFields []string `json:"-"`
3364}
3365
3366func (s *GoogleCloudDialogflowCxV3TestConfig) MarshalJSON() ([]byte, error) {
3367	type NoMethod GoogleCloudDialogflowCxV3TestConfig
3368	raw := NoMethod(*s)
3369	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
3370}
3371
3372// GoogleCloudDialogflowCxV3TestError: Error info for running a test.
3373type GoogleCloudDialogflowCxV3TestError struct {
3374	// Status: The status associated with the test.
3375	Status *GoogleRpcStatus `json:"status,omitempty"`
3376
3377	// TestCase: The test case resource name.
3378	TestCase string `json:"testCase,omitempty"`
3379
3380	// TestTime: The timestamp when the test was completed.
3381	TestTime string `json:"testTime,omitempty"`
3382
3383	// ForceSendFields is a list of field names (e.g. "Status") to
3384	// unconditionally include in API requests. By default, fields with
3385	// empty or default values are omitted from API requests. However, any
3386	// non-pointer, non-interface field appearing in ForceSendFields will be
3387	// sent to the server regardless of whether the field is empty or not.
3388	// This may be used to include empty fields in Patch requests.
3389	ForceSendFields []string `json:"-"`
3390
3391	// NullFields is a list of field names (e.g. "Status") to include in API
3392	// requests with the JSON null value. By default, fields with empty
3393	// values are omitted from API requests. However, any field with an
3394	// empty value appearing in NullFields will be sent to the server as
3395	// null. It is an error if a field in this list has a non-empty value.
3396	// This may be used to include null fields in Patch requests.
3397	NullFields []string `json:"-"`
3398}
3399
3400func (s *GoogleCloudDialogflowCxV3TestError) MarshalJSON() ([]byte, error) {
3401	type NoMethod GoogleCloudDialogflowCxV3TestError
3402	raw := NoMethod(*s)
3403	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
3404}
3405
3406// GoogleCloudDialogflowCxV3TestRunDifference: The description of
3407// differences between original and replayed agent output.
3408type GoogleCloudDialogflowCxV3TestRunDifference struct {
3409	// Description: A description of the diff, showing the actual output vs
3410	// expected output.
3411	Description string `json:"description,omitempty"`
3412
3413	// Type: The type of diff.
3414	//
3415	// Possible values:
3416	//   "DIFF_TYPE_UNSPECIFIED" - Should never be used.
3417	//   "INTENT" - The intent.
3418	//   "PAGE" - The page.
3419	//   "PARAMETERS" - The parameters.
3420	//   "UTTERANCE" - The message utterance.
3421	Type string `json:"type,omitempty"`
3422
3423	// ForceSendFields is a list of field names (e.g. "Description") to
3424	// unconditionally include in API requests. By default, fields with
3425	// empty or default values are omitted from API requests. However, any
3426	// non-pointer, non-interface field appearing in ForceSendFields will be
3427	// sent to the server regardless of whether the field is empty or not.
3428	// This may be used to include empty fields in Patch requests.
3429	ForceSendFields []string `json:"-"`
3430
3431	// NullFields is a list of field names (e.g. "Description") to include
3432	// in API requests with the JSON null value. By default, fields with
3433	// empty values are omitted from API requests. However, any field with
3434	// an empty value appearing in NullFields will be sent to the server as
3435	// null. It is an error if a field in this list has a non-empty value.
3436	// This may be used to include null fields in Patch requests.
3437	NullFields []string `json:"-"`
3438}
3439
3440func (s *GoogleCloudDialogflowCxV3TestRunDifference) MarshalJSON() ([]byte, error) {
3441	type NoMethod GoogleCloudDialogflowCxV3TestRunDifference
3442	raw := NoMethod(*s)
3443	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
3444}
3445
3446// GoogleCloudDialogflowCxV3TextInput: Represents the natural language
3447// text to be processed.
3448type GoogleCloudDialogflowCxV3TextInput struct {
3449	// Text: Required. The UTF-8 encoded natural language text to be
3450	// processed. Text length must not exceed 256 characters.
3451	Text string `json:"text,omitempty"`
3452
3453	// ForceSendFields is a list of field names (e.g. "Text") to
3454	// unconditionally include in API requests. By default, fields with
3455	// empty or default values are omitted from API requests. However, any
3456	// non-pointer, non-interface field appearing in ForceSendFields will be
3457	// sent to the server regardless of whether the field is empty or not.
3458	// This may be used to include empty fields in Patch requests.
3459	ForceSendFields []string `json:"-"`
3460
3461	// NullFields is a list of field names (e.g. "Text") to include in API
3462	// requests with the JSON null value. By default, fields with empty
3463	// values are omitted from API requests. However, any field with an
3464	// empty value appearing in NullFields will be sent to the server as
3465	// null. It is an error if a field in this list has a non-empty value.
3466	// This may be used to include null fields in Patch requests.
3467	NullFields []string `json:"-"`
3468}
3469
3470func (s *GoogleCloudDialogflowCxV3TextInput) MarshalJSON() ([]byte, error) {
3471	type NoMethod GoogleCloudDialogflowCxV3TextInput
3472	raw := NoMethod(*s)
3473	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
3474}
3475
3476// GoogleCloudDialogflowCxV3TransitionRoute: A transition route
3477// specifies a intent that can be matched and/or a data condition that
3478// can be evaluated during a session. When a specified transition is
3479// matched, the following actions are taken in order: * If there is a
3480// `trigger_fulfillment` associated with the transition, it will be
3481// called. * If there is a `target_page` associated with the transition,
3482// the session will transition into the specified page. * If there is a
3483// `target_flow` associated with the transition, the session will
3484// transition into the specified flow.
3485type GoogleCloudDialogflowCxV3TransitionRoute struct {
3486	// Condition: The condition to evaluate against form parameters or
3487	// session parameters. See the conditions reference
3488	// (https://cloud.google.com/dialogflow/cx/docs/reference/condition). At
3489	// least one of `intent` or `condition` must be specified. When both
3490	// `intent` and `condition` are specified, the transition can only
3491	// happen when both are fulfilled.
3492	Condition string `json:"condition,omitempty"`
3493
3494	// Intent: The unique identifier of an Intent. Format:
3495	// `projects//locations//agents//intents/`. Indicates that the
3496	// transition can only happen when the given intent is matched. At least
3497	// one of `intent` or `condition` must be specified. When both `intent`
3498	// and `condition` are specified, the transition can only happen when
3499	// both are fulfilled.
3500	Intent string `json:"intent,omitempty"`
3501
3502	// Name: Output only. The unique identifier of this transition route.
3503	Name string `json:"name,omitempty"`
3504
3505	// TargetFlow: The target flow to transition to. Format:
3506	// `projects//locations//agents//flows/`.
3507	TargetFlow string `json:"targetFlow,omitempty"`
3508
3509	// TargetPage: The target page to transition to. Format:
3510	// `projects//locations//agents//flows//pages/`.
3511	TargetPage string `json:"targetPage,omitempty"`
3512
3513	// TriggerFulfillment: The fulfillment to call when the condition is
3514	// satisfied. At least one of `trigger_fulfillment` and `target` must be
3515	// specified. When both are defined, `trigger_fulfillment` is executed
3516	// first.
3517	TriggerFulfillment *GoogleCloudDialogflowCxV3Fulfillment `json:"triggerFulfillment,omitempty"`
3518
3519	// ForceSendFields is a list of field names (e.g. "Condition") to
3520	// unconditionally include in API requests. By default, fields with
3521	// empty or default values are omitted from API requests. However, any
3522	// non-pointer, non-interface field appearing in ForceSendFields will be
3523	// sent to the server regardless of whether the field is empty or not.
3524	// This may be used to include empty fields in Patch requests.
3525	ForceSendFields []string `json:"-"`
3526
3527	// NullFields is a list of field names (e.g. "Condition") to include in
3528	// API requests with the JSON null value. By default, fields with empty
3529	// values are omitted from API requests. However, any field with an
3530	// empty value appearing in NullFields will be sent to the server as
3531	// null. It is an error if a field in this list has a non-empty value.
3532	// This may be used to include null fields in Patch requests.
3533	NullFields []string `json:"-"`
3534}
3535
3536func (s *GoogleCloudDialogflowCxV3TransitionRoute) MarshalJSON() ([]byte, error) {
3537	type NoMethod GoogleCloudDialogflowCxV3TransitionRoute
3538	raw := NoMethod(*s)
3539	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
3540}
3541
3542// GoogleCloudDialogflowCxV3UpdateDocumentOperationMetadata: Metadata
3543// for UpdateDocument operation.
3544type GoogleCloudDialogflowCxV3UpdateDocumentOperationMetadata struct {
3545	// GenericMetadata: The generic information of the operation.
3546	GenericMetadata *GoogleCloudDialogflowCxV3GenericKnowledgeOperationMetadata `json:"genericMetadata,omitempty"`
3547
3548	// ForceSendFields is a list of field names (e.g. "GenericMetadata") to
3549	// unconditionally include in API requests. By default, fields with
3550	// empty or default values are omitted from API requests. However, any
3551	// non-pointer, non-interface field appearing in ForceSendFields will be
3552	// sent to the server regardless of whether the field is empty or not.
3553	// This may be used to include empty fields in Patch requests.
3554	ForceSendFields []string `json:"-"`
3555
3556	// NullFields is a list of field names (e.g. "GenericMetadata") to
3557	// include in API requests with the JSON null value. By default, fields
3558	// with empty values are omitted from API requests. However, any field
3559	// with an empty value appearing in NullFields will be sent to the
3560	// server as null. It is an error if a field in this list has a
3561	// non-empty value. This may be used to include null fields in Patch
3562	// requests.
3563	NullFields []string `json:"-"`
3564}
3565
3566func (s *GoogleCloudDialogflowCxV3UpdateDocumentOperationMetadata) MarshalJSON() ([]byte, error) {
3567	type NoMethod GoogleCloudDialogflowCxV3UpdateDocumentOperationMetadata
3568	raw := NoMethod(*s)
3569	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
3570}
3571
3572// GoogleCloudDialogflowCxV3WebhookRequest: The request message for a
3573// webhook call. The request is sent as a JSON object and the field
3574// names will be presented in camel cases.
3575type GoogleCloudDialogflowCxV3WebhookRequest struct {
3576	// DetectIntentResponseId: Always present. The unique identifier of the
3577	// DetectIntentResponse that will be returned to the API caller.
3578	DetectIntentResponseId string `json:"detectIntentResponseId,omitempty"`
3579
3580	// FulfillmentInfo: Always present. Information about the fulfillment
3581	// that triggered this webhook call.
3582	FulfillmentInfo *GoogleCloudDialogflowCxV3WebhookRequestFulfillmentInfo `json:"fulfillmentInfo,omitempty"`
3583
3584	// IntentInfo: Information about the last matched intent.
3585	IntentInfo *GoogleCloudDialogflowCxV3WebhookRequestIntentInfo `json:"intentInfo,omitempty"`
3586
3587	// LanguageCode: The language code specified in the original request.
3588	LanguageCode string `json:"languageCode,omitempty"`
3589
3590	// Messages: The list of rich message responses to present to the user.
3591	// Webhook can choose to append or replace this list in
3592	// WebhookResponse.fulfillment_response;
3593	Messages []*GoogleCloudDialogflowCxV3ResponseMessage `json:"messages,omitempty"`
3594
3595	// PageInfo: Information about page status.
3596	PageInfo *GoogleCloudDialogflowCxV3PageInfo `json:"pageInfo,omitempty"`
3597
3598	// Payload: Custom data set in QueryParameters.payload.
3599	Payload googleapi.RawMessage `json:"payload,omitempty"`
3600
3601	// SentimentAnalysisResult: The sentiment analysis result of the current
3602	// user request. The field is filled when sentiment analysis is
3603	// configured to be enabled for the request.
3604	SentimentAnalysisResult *GoogleCloudDialogflowCxV3WebhookRequestSentimentAnalysisResult `json:"sentimentAnalysisResult,omitempty"`
3605
3606	// SessionInfo: Information about session status.
3607	SessionInfo *GoogleCloudDialogflowCxV3SessionInfo `json:"sessionInfo,omitempty"`
3608
3609	// Text: If natural language text was provided as input, this field will
3610	// contain a copy of the text.
3611	Text string `json:"text,omitempty"`
3612
3613	// Transcript: If natural language speech audio was provided as input,
3614	// this field will contain the transcript for the audio.
3615	Transcript string `json:"transcript,omitempty"`
3616
3617	// TriggerEvent: If an event was provided as input, this field will
3618	// contain the name of the event.
3619	TriggerEvent string `json:"triggerEvent,omitempty"`
3620
3621	// TriggerIntent: If an intent was provided as input, this field will
3622	// contain a copy of the intent identifier. Format:
3623	// `projects//locations//agents//intents/`.
3624	TriggerIntent string `json:"triggerIntent,omitempty"`
3625
3626	// ForceSendFields is a list of field names (e.g.
3627	// "DetectIntentResponseId") to unconditionally include in API requests.
3628	// By default, fields with empty or default values are omitted from API
3629	// requests. However, any non-pointer, non-interface field appearing in
3630	// ForceSendFields will be sent to the server regardless of whether the
3631	// field is empty or not. This may be used to include empty fields in
3632	// Patch requests.
3633	ForceSendFields []string `json:"-"`
3634
3635	// NullFields is a list of field names (e.g. "DetectIntentResponseId")
3636	// to include in API requests with the JSON null value. By default,
3637	// fields with empty values are omitted from API requests. However, any
3638	// field with an empty value appearing in NullFields will be sent to the
3639	// server as null. It is an error if a field in this list has a
3640	// non-empty value. This may be used to include null fields in Patch
3641	// requests.
3642	NullFields []string `json:"-"`
3643}
3644
3645func (s *GoogleCloudDialogflowCxV3WebhookRequest) MarshalJSON() ([]byte, error) {
3646	type NoMethod GoogleCloudDialogflowCxV3WebhookRequest
3647	raw := NoMethod(*s)
3648	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
3649}
3650
3651// GoogleCloudDialogflowCxV3WebhookRequestFulfillmentInfo: Represents
3652// fulfillment information communicated to the webhook.
3653type GoogleCloudDialogflowCxV3WebhookRequestFulfillmentInfo struct {
3654	// Tag: Always present. The tag used to identify which fulfillment is
3655	// being called.
3656	Tag string `json:"tag,omitempty"`
3657
3658	// ForceSendFields is a list of field names (e.g. "Tag") to
3659	// unconditionally include in API requests. By default, fields with
3660	// empty or default values are omitted from API requests. However, any
3661	// non-pointer, non-interface field appearing in ForceSendFields will be
3662	// sent to the server regardless of whether the field is empty or not.
3663	// This may be used to include empty fields in Patch requests.
3664	ForceSendFields []string `json:"-"`
3665
3666	// NullFields is a list of field names (e.g. "Tag") to include in API
3667	// requests with the JSON null value. By default, fields with empty
3668	// values are omitted from API requests. However, any field with an
3669	// empty value appearing in NullFields will be sent to the server as
3670	// null. It is an error if a field in this list has a non-empty value.
3671	// This may be used to include null fields in Patch requests.
3672	NullFields []string `json:"-"`
3673}
3674
3675func (s *GoogleCloudDialogflowCxV3WebhookRequestFulfillmentInfo) MarshalJSON() ([]byte, error) {
3676	type NoMethod GoogleCloudDialogflowCxV3WebhookRequestFulfillmentInfo
3677	raw := NoMethod(*s)
3678	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
3679}
3680
3681// GoogleCloudDialogflowCxV3WebhookRequestIntentInfo: Represents intent
3682// information communicated to the webhook.
3683type GoogleCloudDialogflowCxV3WebhookRequestIntentInfo struct {
3684	// Confidence: The confidence of the matched intent. Values range from
3685	// 0.0 (completely uncertain) to 1.0 (completely certain).
3686	Confidence float64 `json:"confidence,omitempty"`
3687
3688	// DisplayName: Always present. The display name of the last matched
3689	// intent.
3690	DisplayName string `json:"displayName,omitempty"`
3691
3692	// LastMatchedIntent: Always present. The unique identifier of the last
3693	// matched intent. Format: `projects//locations//agents//intents/`.
3694	LastMatchedIntent string `json:"lastMatchedIntent,omitempty"`
3695
3696	// Parameters: Parameters identified as a result of intent matching.
3697	// This is a map of the name of the identified parameter to the value of
3698	// the parameter identified from the user's utterance. All parameters
3699	// defined in the matched intent that are identified will be surfaced
3700	// here.
3701	Parameters map[string]GoogleCloudDialogflowCxV3WebhookRequestIntentInfoIntentParameterValue `json:"parameters,omitempty"`
3702
3703	// ForceSendFields is a list of field names (e.g. "Confidence") to
3704	// unconditionally include in API requests. By default, fields with
3705	// empty or default values are omitted from API requests. However, any
3706	// non-pointer, non-interface field appearing in ForceSendFields will be
3707	// sent to the server regardless of whether the field is empty or not.
3708	// This may be used to include empty fields in Patch requests.
3709	ForceSendFields []string `json:"-"`
3710
3711	// NullFields is a list of field names (e.g. "Confidence") to include in
3712	// API requests with the JSON null value. By default, fields with empty
3713	// values are omitted from API requests. However, any field with an
3714	// empty value appearing in NullFields will be sent to the server as
3715	// null. It is an error if a field in this list has a non-empty value.
3716	// This may be used to include null fields in Patch requests.
3717	NullFields []string `json:"-"`
3718}
3719
3720func (s *GoogleCloudDialogflowCxV3WebhookRequestIntentInfo) MarshalJSON() ([]byte, error) {
3721	type NoMethod GoogleCloudDialogflowCxV3WebhookRequestIntentInfo
3722	raw := NoMethod(*s)
3723	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
3724}
3725
3726func (s *GoogleCloudDialogflowCxV3WebhookRequestIntentInfo) UnmarshalJSON(data []byte) error {
3727	type NoMethod GoogleCloudDialogflowCxV3WebhookRequestIntentInfo
3728	var s1 struct {
3729		Confidence gensupport.JSONFloat64 `json:"confidence"`
3730		*NoMethod
3731	}
3732	s1.NoMethod = (*NoMethod)(s)
3733	if err := json.Unmarshal(data, &s1); err != nil {
3734		return err
3735	}
3736	s.Confidence = float64(s1.Confidence)
3737	return nil
3738}
3739
3740// GoogleCloudDialogflowCxV3WebhookRequestIntentInfoIntentParameterValue:
3741//  Represents a value for an intent parameter.
3742type GoogleCloudDialogflowCxV3WebhookRequestIntentInfoIntentParameterValue struct {
3743	// OriginalValue: Always present. Original text value extracted from
3744	// user utterance.
3745	OriginalValue string `json:"originalValue,omitempty"`
3746
3747	// ResolvedValue: Always present. Structured value for the parameter
3748	// extracted from user utterance.
3749	ResolvedValue interface{} `json:"resolvedValue,omitempty"`
3750
3751	// ForceSendFields is a list of field names (e.g. "OriginalValue") to
3752	// unconditionally include in API requests. By default, fields with
3753	// empty or default values are omitted from API requests. However, any
3754	// non-pointer, non-interface field appearing in ForceSendFields will be
3755	// sent to the server regardless of whether the field is empty or not.
3756	// This may be used to include empty fields in Patch requests.
3757	ForceSendFields []string `json:"-"`
3758
3759	// NullFields is a list of field names (e.g. "OriginalValue") to include
3760	// in API requests with the JSON null value. By default, fields with
3761	// empty values are omitted from API requests. However, any field with
3762	// an empty value appearing in NullFields will be sent to the server as
3763	// null. It is an error if a field in this list has a non-empty value.
3764	// This may be used to include null fields in Patch requests.
3765	NullFields []string `json:"-"`
3766}
3767
3768func (s *GoogleCloudDialogflowCxV3WebhookRequestIntentInfoIntentParameterValue) MarshalJSON() ([]byte, error) {
3769	type NoMethod GoogleCloudDialogflowCxV3WebhookRequestIntentInfoIntentParameterValue
3770	raw := NoMethod(*s)
3771	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
3772}
3773
3774// GoogleCloudDialogflowCxV3WebhookRequestSentimentAnalysisResult:
3775// Represents the result of sentiment analysis.
3776type GoogleCloudDialogflowCxV3WebhookRequestSentimentAnalysisResult struct {
3777	// Magnitude: A non-negative number in the [0, +inf) range, which
3778	// represents the absolute magnitude of sentiment, regardless of score
3779	// (positive or negative).
3780	Magnitude float64 `json:"magnitude,omitempty"`
3781
3782	// Score: Sentiment score between -1.0 (negative sentiment) and 1.0
3783	// (positive sentiment).
3784	Score float64 `json:"score,omitempty"`
3785
3786	// ForceSendFields is a list of field names (e.g. "Magnitude") to
3787	// unconditionally include in API requests. By default, fields with
3788	// empty or default values are omitted from API requests. However, any
3789	// non-pointer, non-interface field appearing in ForceSendFields will be
3790	// sent to the server regardless of whether the field is empty or not.
3791	// This may be used to include empty fields in Patch requests.
3792	ForceSendFields []string `json:"-"`
3793
3794	// NullFields is a list of field names (e.g. "Magnitude") to include in
3795	// API requests with the JSON null value. By default, fields with empty
3796	// values are omitted from API requests. However, any field with an
3797	// empty value appearing in NullFields will be sent to the server as
3798	// null. It is an error if a field in this list has a non-empty value.
3799	// This may be used to include null fields in Patch requests.
3800	NullFields []string `json:"-"`
3801}
3802
3803func (s *GoogleCloudDialogflowCxV3WebhookRequestSentimentAnalysisResult) MarshalJSON() ([]byte, error) {
3804	type NoMethod GoogleCloudDialogflowCxV3WebhookRequestSentimentAnalysisResult
3805	raw := NoMethod(*s)
3806	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
3807}
3808
3809func (s *GoogleCloudDialogflowCxV3WebhookRequestSentimentAnalysisResult) UnmarshalJSON(data []byte) error {
3810	type NoMethod GoogleCloudDialogflowCxV3WebhookRequestSentimentAnalysisResult
3811	var s1 struct {
3812		Magnitude gensupport.JSONFloat64 `json:"magnitude"`
3813		Score     gensupport.JSONFloat64 `json:"score"`
3814		*NoMethod
3815	}
3816	s1.NoMethod = (*NoMethod)(s)
3817	if err := json.Unmarshal(data, &s1); err != nil {
3818		return err
3819	}
3820	s.Magnitude = float64(s1.Magnitude)
3821	s.Score = float64(s1.Score)
3822	return nil
3823}
3824
3825// GoogleCloudDialogflowCxV3WebhookResponse: The response message for a
3826// webhook call.
3827type GoogleCloudDialogflowCxV3WebhookResponse struct {
3828	// FulfillmentResponse: The fulfillment response to send to the user.
3829	// This field can be omitted by the webhook if it does not intend to
3830	// send any response to the user.
3831	FulfillmentResponse *GoogleCloudDialogflowCxV3WebhookResponseFulfillmentResponse `json:"fulfillmentResponse,omitempty"`
3832
3833	// PageInfo: Information about page status. This field can be omitted by
3834	// the webhook if it does not intend to modify page status.
3835	PageInfo *GoogleCloudDialogflowCxV3PageInfo `json:"pageInfo,omitempty"`
3836
3837	// Payload: Value to append directly to QueryResult.webhook_payloads.
3838	Payload googleapi.RawMessage `json:"payload,omitempty"`
3839
3840	// SessionInfo: Information about session status. This field can be
3841	// omitted by the webhook if it does not intend to modify session
3842	// status.
3843	SessionInfo *GoogleCloudDialogflowCxV3SessionInfo `json:"sessionInfo,omitempty"`
3844
3845	// TargetFlow: The target flow to transition to. Format:
3846	// `projects//locations//agents//flows/`.
3847	TargetFlow string `json:"targetFlow,omitempty"`
3848
3849	// TargetPage: The target page to transition to. Format:
3850	// `projects//locations//agents//flows//pages/`.
3851	TargetPage string `json:"targetPage,omitempty"`
3852
3853	// ForceSendFields is a list of field names (e.g. "FulfillmentResponse")
3854	// to unconditionally include in API requests. By default, fields with
3855	// empty or default values are omitted from API requests. However, any
3856	// non-pointer, non-interface field appearing in ForceSendFields will be
3857	// sent to the server regardless of whether the field is empty or not.
3858	// This may be used to include empty fields in Patch requests.
3859	ForceSendFields []string `json:"-"`
3860
3861	// NullFields is a list of field names (e.g. "FulfillmentResponse") to
3862	// include in API requests with the JSON null value. By default, fields
3863	// with empty values are omitted from API requests. However, any field
3864	// with an empty value appearing in NullFields will be sent to the
3865	// server as null. It is an error if a field in this list has a
3866	// non-empty value. This may be used to include null fields in Patch
3867	// requests.
3868	NullFields []string `json:"-"`
3869}
3870
3871func (s *GoogleCloudDialogflowCxV3WebhookResponse) MarshalJSON() ([]byte, error) {
3872	type NoMethod GoogleCloudDialogflowCxV3WebhookResponse
3873	raw := NoMethod(*s)
3874	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
3875}
3876
3877// GoogleCloudDialogflowCxV3WebhookResponseFulfillmentResponse:
3878// Represents a fulfillment response to the user.
3879type GoogleCloudDialogflowCxV3WebhookResponseFulfillmentResponse struct {
3880	// MergeBehavior: Merge behavior for `messages`.
3881	//
3882	// Possible values:
3883	//   "MERGE_BEHAVIOR_UNSPECIFIED" - Not specified. `APPEND` will be
3884	// used.
3885	//   "APPEND" - `messages` will be appended to the list of messages
3886	// waiting to be sent to the user.
3887	//   "REPLACE" - `messages` will replace the list of messages waiting to
3888	// be sent to the user.
3889	MergeBehavior string `json:"mergeBehavior,omitempty"`
3890
3891	// Messages: The list of rich message responses to present to the user.
3892	Messages []*GoogleCloudDialogflowCxV3ResponseMessage `json:"messages,omitempty"`
3893
3894	// ForceSendFields is a list of field names (e.g. "MergeBehavior") to
3895	// unconditionally include in API requests. By default, fields with
3896	// empty or default values are omitted from API requests. However, any
3897	// non-pointer, non-interface field appearing in ForceSendFields will be
3898	// sent to the server regardless of whether the field is empty or not.
3899	// This may be used to include empty fields in Patch requests.
3900	ForceSendFields []string `json:"-"`
3901
3902	// NullFields is a list of field names (e.g. "MergeBehavior") to include
3903	// in API requests with the JSON null value. By default, fields with
3904	// empty values are omitted from API requests. However, any field with
3905	// an empty value appearing in NullFields will be sent to the server as
3906	// null. It is an error if a field in this list has a non-empty value.
3907	// This may be used to include null fields in Patch requests.
3908	NullFields []string `json:"-"`
3909}
3910
3911func (s *GoogleCloudDialogflowCxV3WebhookResponseFulfillmentResponse) MarshalJSON() ([]byte, error) {
3912	type NoMethod GoogleCloudDialogflowCxV3WebhookResponseFulfillmentResponse
3913	raw := NoMethod(*s)
3914	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
3915}
3916
3917// GoogleCloudDialogflowCxV3beta1AudioInput: Represents the natural
3918// speech audio to be processed.
3919type GoogleCloudDialogflowCxV3beta1AudioInput struct {
3920	// Audio: The natural language speech audio to be processed. A single
3921	// request can contain up to 1 minute of speech audio data. The
3922	// transcribed text cannot contain more than 256 bytes. For
3923	// non-streaming audio detect intent, both `config` and `audio` must be
3924	// provided. For streaming audio detect intent, `config` must be
3925	// provided in the first request and `audio` must be provided in all
3926	// following requests.
3927	Audio string `json:"audio,omitempty"`
3928
3929	// Config: Required. Instructs the speech recognizer how to process the
3930	// speech audio.
3931	Config *GoogleCloudDialogflowCxV3beta1InputAudioConfig `json:"config,omitempty"`
3932
3933	// ForceSendFields is a list of field names (e.g. "Audio") to
3934	// unconditionally include in API requests. By default, fields with
3935	// empty or default values are omitted from API requests. However, any
3936	// non-pointer, non-interface field appearing in ForceSendFields will be
3937	// sent to the server regardless of whether the field is empty or not.
3938	// This may be used to include empty fields in Patch requests.
3939	ForceSendFields []string `json:"-"`
3940
3941	// NullFields is a list of field names (e.g. "Audio") to include in API
3942	// requests with the JSON null value. By default, fields with empty
3943	// values are omitted from API requests. However, any field with an
3944	// empty value appearing in NullFields will be sent to the server as
3945	// null. It is an error if a field in this list has a non-empty value.
3946	// This may be used to include null fields in Patch requests.
3947	NullFields []string `json:"-"`
3948}
3949
3950func (s *GoogleCloudDialogflowCxV3beta1AudioInput) MarshalJSON() ([]byte, error) {
3951	type NoMethod GoogleCloudDialogflowCxV3beta1AudioInput
3952	raw := NoMethod(*s)
3953	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
3954}
3955
3956// GoogleCloudDialogflowCxV3beta1BatchRunTestCasesMetadata: Metadata
3957// returned for the TestCases.BatchRunTestCases long running operation.
3958type GoogleCloudDialogflowCxV3beta1BatchRunTestCasesMetadata struct {
3959	// Errors: The test errors.
3960	Errors []*GoogleCloudDialogflowCxV3beta1TestError `json:"errors,omitempty"`
3961
3962	// ForceSendFields is a list of field names (e.g. "Errors") to
3963	// unconditionally include in API requests. By default, fields with
3964	// empty or default values are omitted from API requests. However, any
3965	// non-pointer, non-interface field appearing in ForceSendFields will be
3966	// sent to the server regardless of whether the field is empty or not.
3967	// This may be used to include empty fields in Patch requests.
3968	ForceSendFields []string `json:"-"`
3969
3970	// NullFields is a list of field names (e.g. "Errors") to include in API
3971	// requests with the JSON null value. By default, fields with empty
3972	// values are omitted from API requests. However, any field with an
3973	// empty value appearing in NullFields will be sent to the server as
3974	// null. It is an error if a field in this list has a non-empty value.
3975	// This may be used to include null fields in Patch requests.
3976	NullFields []string `json:"-"`
3977}
3978
3979func (s *GoogleCloudDialogflowCxV3beta1BatchRunTestCasesMetadata) MarshalJSON() ([]byte, error) {
3980	type NoMethod GoogleCloudDialogflowCxV3beta1BatchRunTestCasesMetadata
3981	raw := NoMethod(*s)
3982	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
3983}
3984
3985// GoogleCloudDialogflowCxV3beta1BatchRunTestCasesResponse: The response
3986// message for TestCases.BatchRunTestCases.
3987type GoogleCloudDialogflowCxV3beta1BatchRunTestCasesResponse struct {
3988	// Results: The test case results. The detailed conversation turns are
3989	// empty in this response.
3990	Results []*GoogleCloudDialogflowCxV3beta1TestCaseResult `json:"results,omitempty"`
3991
3992	// ForceSendFields is a list of field names (e.g. "Results") to
3993	// unconditionally include in API requests. By default, fields with
3994	// empty or default values are omitted from API requests. However, any
3995	// non-pointer, non-interface field appearing in ForceSendFields will be
3996	// sent to the server regardless of whether the field is empty or not.
3997	// This may be used to include empty fields in Patch requests.
3998	ForceSendFields []string `json:"-"`
3999
4000	// NullFields is a list of field names (e.g. "Results") to include in
4001	// API requests with the JSON null value. By default, fields with empty
4002	// values are omitted from API requests. However, any field with an
4003	// empty value appearing in NullFields will be sent to the server as
4004	// null. It is an error if a field in this list has a non-empty value.
4005	// This may be used to include null fields in Patch requests.
4006	NullFields []string `json:"-"`
4007}
4008
4009func (s *GoogleCloudDialogflowCxV3beta1BatchRunTestCasesResponse) MarshalJSON() ([]byte, error) {
4010	type NoMethod GoogleCloudDialogflowCxV3beta1BatchRunTestCasesResponse
4011	raw := NoMethod(*s)
4012	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
4013}
4014
4015// GoogleCloudDialogflowCxV3beta1ContinuousTestResult: Represents a
4016// result from running a test case in an agent environment.
4017type GoogleCloudDialogflowCxV3beta1ContinuousTestResult struct {
4018	// Name: The resource name for the continuous test result. Format:
4019	// `projects//locations//agents//environments//continuousTestResults/`.
4020	Name string `json:"name,omitempty"`
4021
4022	// Result: The result of this continuous test run, i.e. whether all the
4023	// tests in this continuous test run pass or not.
4024	//
4025	// Possible values:
4026	//   "AGGREGATED_TEST_RESULT_UNSPECIFIED" - Not specified. Should never
4027	// be used.
4028	//   "PASSED" - All the tests passed.
4029	//   "FAILED" - At least one test did not pass.
4030	Result string `json:"result,omitempty"`
4031
4032	// RunTime: Time when the continuous testing run starts.
4033	RunTime string `json:"runTime,omitempty"`
4034
4035	// TestCaseResults: A list of individual test case results names in this
4036	// continuous test run.
4037	TestCaseResults []string `json:"testCaseResults,omitempty"`
4038
4039	// ForceSendFields is a list of field names (e.g. "Name") to
4040	// unconditionally include in API requests. By default, fields with
4041	// empty or default values are omitted from API requests. However, any
4042	// non-pointer, non-interface field appearing in ForceSendFields will be
4043	// sent to the server regardless of whether the field is empty or not.
4044	// This may be used to include empty fields in Patch requests.
4045	ForceSendFields []string `json:"-"`
4046
4047	// NullFields is a list of field names (e.g. "Name") to include in API
4048	// requests with the JSON null value. By default, fields with empty
4049	// values are omitted from API requests. However, any field with an
4050	// empty value appearing in NullFields will be sent to the server as
4051	// null. It is an error if a field in this list has a non-empty value.
4052	// This may be used to include null fields in Patch requests.
4053	NullFields []string `json:"-"`
4054}
4055
4056func (s *GoogleCloudDialogflowCxV3beta1ContinuousTestResult) MarshalJSON() ([]byte, error) {
4057	type NoMethod GoogleCloudDialogflowCxV3beta1ContinuousTestResult
4058	raw := NoMethod(*s)
4059	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
4060}
4061
4062// GoogleCloudDialogflowCxV3beta1ConversationTurn: One interaction
4063// between a human and virtual agent. The human provides some input and
4064// the virtual agent provides a response.
4065type GoogleCloudDialogflowCxV3beta1ConversationTurn struct {
4066	// UserInput: The user input.
4067	UserInput *GoogleCloudDialogflowCxV3beta1ConversationTurnUserInput `json:"userInput,omitempty"`
4068
4069	// VirtualAgentOutput: The virtual agent output.
4070	VirtualAgentOutput *GoogleCloudDialogflowCxV3beta1ConversationTurnVirtualAgentOutput `json:"virtualAgentOutput,omitempty"`
4071
4072	// ForceSendFields is a list of field names (e.g. "UserInput") to
4073	// unconditionally include in API requests. By default, fields with
4074	// empty or default values are omitted from API requests. However, any
4075	// non-pointer, non-interface field appearing in ForceSendFields will be
4076	// sent to the server regardless of whether the field is empty or not.
4077	// This may be used to include empty fields in Patch requests.
4078	ForceSendFields []string `json:"-"`
4079
4080	// NullFields is a list of field names (e.g. "UserInput") to include in
4081	// API requests with the JSON null value. By default, fields with empty
4082	// values are omitted from API requests. However, any field with an
4083	// empty value appearing in NullFields will be sent to the server as
4084	// null. It is an error if a field in this list has a non-empty value.
4085	// This may be used to include null fields in Patch requests.
4086	NullFields []string `json:"-"`
4087}
4088
4089func (s *GoogleCloudDialogflowCxV3beta1ConversationTurn) MarshalJSON() ([]byte, error) {
4090	type NoMethod GoogleCloudDialogflowCxV3beta1ConversationTurn
4091	raw := NoMethod(*s)
4092	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
4093}
4094
4095// GoogleCloudDialogflowCxV3beta1ConversationTurnUserInput: The input
4096// from the human user.
4097type GoogleCloudDialogflowCxV3beta1ConversationTurnUserInput struct {
4098	// EnableSentimentAnalysis: Whether sentiment analysis is enabled.
4099	EnableSentimentAnalysis bool `json:"enableSentimentAnalysis,omitempty"`
4100
4101	// InjectedParameters: Parameters that need to be injected into the
4102	// conversation during intent detection.
4103	InjectedParameters googleapi.RawMessage `json:"injectedParameters,omitempty"`
4104
4105	// Input: Supports text input, event input, dtmf input in the test case.
4106	Input *GoogleCloudDialogflowCxV3beta1QueryInput `json:"input,omitempty"`
4107
4108	// IsWebhookEnabled: If webhooks should be allowed to trigger in
4109	// response to the user utterance. Often if parameters are injected,
4110	// webhooks should not be enabled.
4111	IsWebhookEnabled bool `json:"isWebhookEnabled,omitempty"`
4112
4113	// ForceSendFields is a list of field names (e.g.
4114	// "EnableSentimentAnalysis") to unconditionally include in API
4115	// requests. By default, fields with empty or default values are omitted
4116	// from API requests. However, any non-pointer, non-interface field
4117	// appearing in ForceSendFields will be sent to the server regardless of
4118	// whether the field is empty or not. This may be used to include empty
4119	// fields in Patch requests.
4120	ForceSendFields []string `json:"-"`
4121
4122	// NullFields is a list of field names (e.g. "EnableSentimentAnalysis")
4123	// to include in API requests with the JSON null value. By default,
4124	// fields with empty values are omitted from API requests. However, any
4125	// field with an empty value appearing in NullFields will be sent to the
4126	// server as null. It is an error if a field in this list has a
4127	// non-empty value. This may be used to include null fields in Patch
4128	// requests.
4129	NullFields []string `json:"-"`
4130}
4131
4132func (s *GoogleCloudDialogflowCxV3beta1ConversationTurnUserInput) MarshalJSON() ([]byte, error) {
4133	type NoMethod GoogleCloudDialogflowCxV3beta1ConversationTurnUserInput
4134	raw := NoMethod(*s)
4135	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
4136}
4137
4138// GoogleCloudDialogflowCxV3beta1ConversationTurnVirtualAgentOutput: The
4139// output from the virtual agent.
4140type GoogleCloudDialogflowCxV3beta1ConversationTurnVirtualAgentOutput struct {
4141	// CurrentPage: The Page on which the utterance was spoken. Only name
4142	// and displayName will be set.
4143	CurrentPage *GoogleCloudDialogflowCxV3beta1Page `json:"currentPage,omitempty"`
4144
4145	// DiagnosticInfo: Required. Input only. The diagnostic info output for
4146	// the turn. Required to calculate the testing coverage.
4147	DiagnosticInfo googleapi.RawMessage `json:"diagnosticInfo,omitempty"`
4148
4149	// Differences: Output only. If this is part of a result conversation
4150	// turn, the list of differences between the original run and the replay
4151	// for this output, if any.
4152	Differences []*GoogleCloudDialogflowCxV3beta1TestRunDifference `json:"differences,omitempty"`
4153
4154	// SessionParameters: The session parameters available to the bot at
4155	// this point.
4156	SessionParameters googleapi.RawMessage `json:"sessionParameters,omitempty"`
4157
4158	// Status: Response error from the agent in the test result. If set,
4159	// other output is empty.
4160	Status *GoogleRpcStatus `json:"status,omitempty"`
4161
4162	// TextResponses: The text responses from the agent for the turn.
4163	TextResponses []*GoogleCloudDialogflowCxV3beta1ResponseMessageText `json:"textResponses,omitempty"`
4164
4165	// TriggeredIntent: The Intent that triggered the response. Only name
4166	// and displayName will be set.
4167	TriggeredIntent *GoogleCloudDialogflowCxV3beta1Intent `json:"triggeredIntent,omitempty"`
4168
4169	// ForceSendFields is a list of field names (e.g. "CurrentPage") to
4170	// unconditionally include in API requests. By default, fields with
4171	// empty or default values are omitted from API requests. However, any
4172	// non-pointer, non-interface field appearing in ForceSendFields will be
4173	// sent to the server regardless of whether the field is empty or not.
4174	// This may be used to include empty fields in Patch requests.
4175	ForceSendFields []string `json:"-"`
4176
4177	// NullFields is a list of field names (e.g. "CurrentPage") to include
4178	// in API requests with the JSON null value. By default, fields with
4179	// empty values are omitted from API requests. However, any field with
4180	// an empty value appearing in NullFields will be sent to the server as
4181	// null. It is an error if a field in this list has a non-empty value.
4182	// This may be used to include null fields in Patch requests.
4183	NullFields []string `json:"-"`
4184}
4185
4186func (s *GoogleCloudDialogflowCxV3beta1ConversationTurnVirtualAgentOutput) MarshalJSON() ([]byte, error) {
4187	type NoMethod GoogleCloudDialogflowCxV3beta1ConversationTurnVirtualAgentOutput
4188	raw := NoMethod(*s)
4189	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
4190}
4191
4192// GoogleCloudDialogflowCxV3beta1CreateDocumentOperationMetadata:
4193// Metadata for CreateDocument operation.
4194type GoogleCloudDialogflowCxV3beta1CreateDocumentOperationMetadata struct {
4195	// GenericMetadata: The generic information of the operation.
4196	GenericMetadata *GoogleCloudDialogflowCxV3beta1GenericKnowledgeOperationMetadata `json:"genericMetadata,omitempty"`
4197
4198	// ForceSendFields is a list of field names (e.g. "GenericMetadata") to
4199	// unconditionally include in API requests. By default, fields with
4200	// empty or default values are omitted from API requests. However, any
4201	// non-pointer, non-interface field appearing in ForceSendFields will be
4202	// sent to the server regardless of whether the field is empty or not.
4203	// This may be used to include empty fields in Patch requests.
4204	ForceSendFields []string `json:"-"`
4205
4206	// NullFields is a list of field names (e.g. "GenericMetadata") to
4207	// include in API requests with the JSON null value. By default, fields
4208	// with empty values are omitted from API requests. However, any field
4209	// with an empty value appearing in NullFields will be sent to the
4210	// server as null. It is an error if a field in this list has a
4211	// non-empty value. This may be used to include null fields in Patch
4212	// requests.
4213	NullFields []string `json:"-"`
4214}
4215
4216func (s *GoogleCloudDialogflowCxV3beta1CreateDocumentOperationMetadata) MarshalJSON() ([]byte, error) {
4217	type NoMethod GoogleCloudDialogflowCxV3beta1CreateDocumentOperationMetadata
4218	raw := NoMethod(*s)
4219	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
4220}
4221
4222// GoogleCloudDialogflowCxV3beta1CreateVersionOperationMetadata:
4223// Metadata associated with the long running operation for
4224// Versions.CreateVersion.
4225type GoogleCloudDialogflowCxV3beta1CreateVersionOperationMetadata struct {
4226	// Version: Name of the created version. Format:
4227	// `projects//locations//agents//flows//versions/`.
4228	Version string `json:"version,omitempty"`
4229
4230	// ForceSendFields is a list of field names (e.g. "Version") to
4231	// unconditionally include in API requests. By default, fields with
4232	// empty or default values are omitted from API requests. However, any
4233	// non-pointer, non-interface field appearing in ForceSendFields will be
4234	// sent to the server regardless of whether the field is empty or not.
4235	// This may be used to include empty fields in Patch requests.
4236	ForceSendFields []string `json:"-"`
4237
4238	// NullFields is a list of field names (e.g. "Version") to include in
4239	// API requests with the JSON null value. By default, fields with empty
4240	// values are omitted from API requests. However, any field with an
4241	// empty value appearing in NullFields will be sent to the server as
4242	// null. It is an error if a field in this list has a non-empty value.
4243	// This may be used to include null fields in Patch requests.
4244	NullFields []string `json:"-"`
4245}
4246
4247func (s *GoogleCloudDialogflowCxV3beta1CreateVersionOperationMetadata) MarshalJSON() ([]byte, error) {
4248	type NoMethod GoogleCloudDialogflowCxV3beta1CreateVersionOperationMetadata
4249	raw := NoMethod(*s)
4250	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
4251}
4252
4253// GoogleCloudDialogflowCxV3beta1DeleteDocumentOperationMetadata:
4254// Metadata for DeleteDocument operation.
4255type GoogleCloudDialogflowCxV3beta1DeleteDocumentOperationMetadata struct {
4256	// GenericMetadata: The generic information of the operation.
4257	GenericMetadata *GoogleCloudDialogflowCxV3beta1GenericKnowledgeOperationMetadata `json:"genericMetadata,omitempty"`
4258
4259	// ForceSendFields is a list of field names (e.g. "GenericMetadata") to
4260	// unconditionally include in API requests. By default, fields with
4261	// empty or default values are omitted from API requests. However, any
4262	// non-pointer, non-interface field appearing in ForceSendFields will be
4263	// sent to the server regardless of whether the field is empty or not.
4264	// This may be used to include empty fields in Patch requests.
4265	ForceSendFields []string `json:"-"`
4266
4267	// NullFields is a list of field names (e.g. "GenericMetadata") to
4268	// include in API requests with the JSON null value. By default, fields
4269	// with empty values are omitted from API requests. However, any field
4270	// with an empty value appearing in NullFields will be sent to the
4271	// server as null. It is an error if a field in this list has a
4272	// non-empty value. This may be used to include null fields in Patch
4273	// requests.
4274	NullFields []string `json:"-"`
4275}
4276
4277func (s *GoogleCloudDialogflowCxV3beta1DeleteDocumentOperationMetadata) MarshalJSON() ([]byte, error) {
4278	type NoMethod GoogleCloudDialogflowCxV3beta1DeleteDocumentOperationMetadata
4279	raw := NoMethod(*s)
4280	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
4281}
4282
4283// GoogleCloudDialogflowCxV3beta1DeployFlowMetadata: Metadata returned
4284// for the Environments.DeployFlow long running operation.
4285type GoogleCloudDialogflowCxV3beta1DeployFlowMetadata struct {
4286	// TestErrors: Errors of running deployment tests.
4287	TestErrors []*GoogleCloudDialogflowCxV3beta1TestError `json:"testErrors,omitempty"`
4288
4289	// ForceSendFields is a list of field names (e.g. "TestErrors") to
4290	// unconditionally include in API requests. By default, fields with
4291	// empty or default values are omitted from API requests. However, any
4292	// non-pointer, non-interface field appearing in ForceSendFields will be
4293	// sent to the server regardless of whether the field is empty or not.
4294	// This may be used to include empty fields in Patch requests.
4295	ForceSendFields []string `json:"-"`
4296
4297	// NullFields is a list of field names (e.g. "TestErrors") to include in
4298	// API requests with the JSON null value. By default, fields with empty
4299	// values are omitted from API requests. However, any field with an
4300	// empty value appearing in NullFields will be sent to the server as
4301	// null. It is an error if a field in this list has a non-empty value.
4302	// This may be used to include null fields in Patch requests.
4303	NullFields []string `json:"-"`
4304}
4305
4306func (s *GoogleCloudDialogflowCxV3beta1DeployFlowMetadata) MarshalJSON() ([]byte, error) {
4307	type NoMethod GoogleCloudDialogflowCxV3beta1DeployFlowMetadata
4308	raw := NoMethod(*s)
4309	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
4310}
4311
4312// GoogleCloudDialogflowCxV3beta1DeployFlowResponse: The response
4313// message for Environments.DeployFlow.
4314type GoogleCloudDialogflowCxV3beta1DeployFlowResponse struct {
4315	// Deployment: The name of the flow version deployment. Format:
4316	// `projects//locations//agents// environments//deployments/`.
4317	Deployment string `json:"deployment,omitempty"`
4318
4319	// Environment: The updated environment where the flow is deployed.
4320	Environment *GoogleCloudDialogflowCxV3beta1Environment `json:"environment,omitempty"`
4321
4322	// ForceSendFields is a list of field names (e.g. "Deployment") to
4323	// unconditionally include in API requests. By default, fields with
4324	// empty or default values are omitted from API requests. However, any
4325	// non-pointer, non-interface field appearing in ForceSendFields will be
4326	// sent to the server regardless of whether the field is empty or not.
4327	// This may be used to include empty fields in Patch requests.
4328	ForceSendFields []string `json:"-"`
4329
4330	// NullFields is a list of field names (e.g. "Deployment") to include in
4331	// API requests with the JSON null value. By default, fields with empty
4332	// values are omitted from API requests. However, any field with an
4333	// empty value appearing in NullFields will be sent to the server as
4334	// null. It is an error if a field in this list has a non-empty value.
4335	// This may be used to include null fields in Patch requests.
4336	NullFields []string `json:"-"`
4337}
4338
4339func (s *GoogleCloudDialogflowCxV3beta1DeployFlowResponse) MarshalJSON() ([]byte, error) {
4340	type NoMethod GoogleCloudDialogflowCxV3beta1DeployFlowResponse
4341	raw := NoMethod(*s)
4342	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
4343}
4344
4345// GoogleCloudDialogflowCxV3beta1DtmfInput: Represents the input for
4346// dtmf event.
4347type GoogleCloudDialogflowCxV3beta1DtmfInput struct {
4348	// Digits: The dtmf digits.
4349	Digits string `json:"digits,omitempty"`
4350
4351	// FinishDigit: The finish digit (if any).
4352	FinishDigit string `json:"finishDigit,omitempty"`
4353
4354	// ForceSendFields is a list of field names (e.g. "Digits") to
4355	// unconditionally include in API requests. By default, fields with
4356	// empty or default values are omitted from API requests. However, any
4357	// non-pointer, non-interface field appearing in ForceSendFields will be
4358	// sent to the server regardless of whether the field is empty or not.
4359	// This may be used to include empty fields in Patch requests.
4360	ForceSendFields []string `json:"-"`
4361
4362	// NullFields is a list of field names (e.g. "Digits") to include in API
4363	// requests with the JSON null value. By default, fields with empty
4364	// values are omitted from API requests. However, any field with an
4365	// empty value appearing in NullFields will be sent to the server as
4366	// null. It is an error if a field in this list has a non-empty value.
4367	// This may be used to include null fields in Patch requests.
4368	NullFields []string `json:"-"`
4369}
4370
4371func (s *GoogleCloudDialogflowCxV3beta1DtmfInput) MarshalJSON() ([]byte, error) {
4372	type NoMethod GoogleCloudDialogflowCxV3beta1DtmfInput
4373	raw := NoMethod(*s)
4374	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
4375}
4376
4377// GoogleCloudDialogflowCxV3beta1Environment: Represents an environment
4378// for an agent. You can create multiple versions of your agent and
4379// publish them to separate environments. When you edit an agent, you
4380// are editing the draft agent. At any point, you can save the draft
4381// agent as an agent version, which is an immutable snapshot of your
4382// agent. When you save the draft agent, it is published to the default
4383// environment. When you create agent versions, you can publish them to
4384// custom environments. You can create a variety of custom environments
4385// for testing, development, production, etc.
4386type GoogleCloudDialogflowCxV3beta1Environment struct {
4387	// Description: The human-readable description of the environment. The
4388	// maximum length is 500 characters. If exceeded, the request is
4389	// rejected.
4390	Description string `json:"description,omitempty"`
4391
4392	// DisplayName: Required. The human-readable name of the environment
4393	// (unique in an agent). Limit of 64 characters.
4394	DisplayName string `json:"displayName,omitempty"`
4395
4396	// Name: The name of the environment. Format:
4397	// `projects//locations//agents//environments/`.
4398	Name string `json:"name,omitempty"`
4399
4400	// TestCasesConfig: The test cases config for continuous tests of this
4401	// environment.
4402	TestCasesConfig *GoogleCloudDialogflowCxV3beta1EnvironmentTestCasesConfig `json:"testCasesConfig,omitempty"`
4403
4404	// UpdateTime: Output only. Update time of this environment.
4405	UpdateTime string `json:"updateTime,omitempty"`
4406
4407	// VersionConfigs: Required. A list of configurations for flow versions.
4408	// You should include version configs for all flows that are reachable
4409	// from `Start Flow` in the agent. Otherwise, an error will be returned.
4410	VersionConfigs []*GoogleCloudDialogflowCxV3beta1EnvironmentVersionConfig `json:"versionConfigs,omitempty"`
4411
4412	// ForceSendFields is a list of field names (e.g. "Description") to
4413	// unconditionally include in API requests. By default, fields with
4414	// empty or default values are omitted from API requests. However, any
4415	// non-pointer, non-interface field appearing in ForceSendFields will be
4416	// sent to the server regardless of whether the field is empty or not.
4417	// This may be used to include empty fields in Patch requests.
4418	ForceSendFields []string `json:"-"`
4419
4420	// NullFields is a list of field names (e.g. "Description") to include
4421	// in API requests with the JSON null value. By default, fields with
4422	// empty values are omitted from API requests. However, any field with
4423	// an empty value appearing in NullFields will be sent to the server as
4424	// null. It is an error if a field in this list has a non-empty value.
4425	// This may be used to include null fields in Patch requests.
4426	NullFields []string `json:"-"`
4427}
4428
4429func (s *GoogleCloudDialogflowCxV3beta1Environment) MarshalJSON() ([]byte, error) {
4430	type NoMethod GoogleCloudDialogflowCxV3beta1Environment
4431	raw := NoMethod(*s)
4432	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
4433}
4434
4435// GoogleCloudDialogflowCxV3beta1EnvironmentTestCasesConfig: The
4436// configuration for continuous tests.
4437type GoogleCloudDialogflowCxV3beta1EnvironmentTestCasesConfig struct {
4438	// EnableContinuousRun: Whether to run test cases in
4439	// TestCasesConfig.test_cases periodically. Default false. If set to
4440	// ture, run once a day.
4441	EnableContinuousRun bool `json:"enableContinuousRun,omitempty"`
4442
4443	// EnablePredeploymentRun: Whether to run test cases in
4444	// TestCasesConfig.test_cases before deploying a flow version to the
4445	// environment. Default false.
4446	EnablePredeploymentRun bool `json:"enablePredeploymentRun,omitempty"`
4447
4448	// TestCases: A list of test case names to run. They should be under the
4449	// same agent. Format of each test case name: `projects//locations/
4450	// /agents//testCases/`
4451	TestCases []string `json:"testCases,omitempty"`
4452
4453	// ForceSendFields is a list of field names (e.g. "EnableContinuousRun")
4454	// to unconditionally include in API requests. By default, fields with
4455	// empty or default values are omitted from API requests. However, any
4456	// non-pointer, non-interface field appearing in ForceSendFields will be
4457	// sent to the server regardless of whether the field is empty or not.
4458	// This may be used to include empty fields in Patch requests.
4459	ForceSendFields []string `json:"-"`
4460
4461	// NullFields is a list of field names (e.g. "EnableContinuousRun") to
4462	// include in API requests with the JSON null value. By default, fields
4463	// with empty values are omitted from API requests. However, any field
4464	// with an empty value appearing in NullFields will be sent to the
4465	// server as null. It is an error if a field in this list has a
4466	// non-empty value. This may be used to include null fields in Patch
4467	// requests.
4468	NullFields []string `json:"-"`
4469}
4470
4471func (s *GoogleCloudDialogflowCxV3beta1EnvironmentTestCasesConfig) MarshalJSON() ([]byte, error) {
4472	type NoMethod GoogleCloudDialogflowCxV3beta1EnvironmentTestCasesConfig
4473	raw := NoMethod(*s)
4474	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
4475}
4476
4477// GoogleCloudDialogflowCxV3beta1EnvironmentVersionConfig: Configuration
4478// for the version.
4479type GoogleCloudDialogflowCxV3beta1EnvironmentVersionConfig struct {
4480	// Version: Required. Format:
4481	// projects//locations//agents//flows//versions/.
4482	Version string `json:"version,omitempty"`
4483
4484	// ForceSendFields is a list of field names (e.g. "Version") to
4485	// unconditionally include in API requests. By default, fields with
4486	// empty or default values are omitted from API requests. However, any
4487	// non-pointer, non-interface field appearing in ForceSendFields will be
4488	// sent to the server regardless of whether the field is empty or not.
4489	// This may be used to include empty fields in Patch requests.
4490	ForceSendFields []string `json:"-"`
4491
4492	// NullFields is a list of field names (e.g. "Version") to include in
4493	// API requests with the JSON null value. By default, fields with empty
4494	// values are omitted from API requests. However, any field with an
4495	// empty value appearing in NullFields will be sent to the server as
4496	// null. It is an error if a field in this list has a non-empty value.
4497	// This may be used to include null fields in Patch requests.
4498	NullFields []string `json:"-"`
4499}
4500
4501func (s *GoogleCloudDialogflowCxV3beta1EnvironmentVersionConfig) MarshalJSON() ([]byte, error) {
4502	type NoMethod GoogleCloudDialogflowCxV3beta1EnvironmentVersionConfig
4503	raw := NoMethod(*s)
4504	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
4505}
4506
4507// GoogleCloudDialogflowCxV3beta1EventHandler: An event handler
4508// specifies an event that can be handled during a session. When the
4509// specified event happens, the following actions are taken in order: *
4510// If there is a `trigger_fulfillment` associated with the event, it
4511// will be called. * If there is a `target_page` associated with the
4512// event, the session will transition into the specified page. * If
4513// there is a `target_flow` associated with the event, the session will
4514// transition into the specified flow.
4515type GoogleCloudDialogflowCxV3beta1EventHandler struct {
4516	// Event: Required. The name of the event to handle.
4517	Event string `json:"event,omitempty"`
4518
4519	// Name: Output only. The unique identifier of this event handler.
4520	Name string `json:"name,omitempty"`
4521
4522	// TargetFlow: The target flow to transition to. Format:
4523	// `projects//locations//agents//flows/`.
4524	TargetFlow string `json:"targetFlow,omitempty"`
4525
4526	// TargetPage: The target page to transition to. Format:
4527	// `projects//locations//agents//flows//pages/`.
4528	TargetPage string `json:"targetPage,omitempty"`
4529
4530	// TriggerFulfillment: The fulfillment to call when the event occurs.
4531	// Handling webhook errors with a fulfillment enabled with webhook could
4532	// cause infinite loop. It is invalid to specify such fulfillment for a
4533	// handler handling webhooks.
4534	TriggerFulfillment *GoogleCloudDialogflowCxV3beta1Fulfillment `json:"triggerFulfillment,omitempty"`
4535
4536	// ForceSendFields is a list of field names (e.g. "Event") to
4537	// unconditionally include in API requests. By default, fields with
4538	// empty or default values are omitted from API requests. However, any
4539	// non-pointer, non-interface field appearing in ForceSendFields will be
4540	// sent to the server regardless of whether the field is empty or not.
4541	// This may be used to include empty fields in Patch requests.
4542	ForceSendFields []string `json:"-"`
4543
4544	// NullFields is a list of field names (e.g. "Event") to include in API
4545	// requests with the JSON null value. By default, fields with empty
4546	// values are omitted from API requests. However, any field with an
4547	// empty value appearing in NullFields will be sent to the server as
4548	// null. It is an error if a field in this list has a non-empty value.
4549	// This may be used to include null fields in Patch requests.
4550	NullFields []string `json:"-"`
4551}
4552
4553func (s *GoogleCloudDialogflowCxV3beta1EventHandler) MarshalJSON() ([]byte, error) {
4554	type NoMethod GoogleCloudDialogflowCxV3beta1EventHandler
4555	raw := NoMethod(*s)
4556	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
4557}
4558
4559// GoogleCloudDialogflowCxV3beta1EventInput: Represents the event to
4560// trigger.
4561type GoogleCloudDialogflowCxV3beta1EventInput struct {
4562	// Event: Name of the event.
4563	Event string `json:"event,omitempty"`
4564
4565	// ForceSendFields is a list of field names (e.g. "Event") to
4566	// unconditionally include in API requests. By default, fields with
4567	// empty or default values are omitted from API requests. However, any
4568	// non-pointer, non-interface field appearing in ForceSendFields will be
4569	// sent to the server regardless of whether the field is empty or not.
4570	// This may be used to include empty fields in Patch requests.
4571	ForceSendFields []string `json:"-"`
4572
4573	// NullFields is a list of field names (e.g. "Event") to include in API
4574	// requests with the JSON null value. By default, fields with empty
4575	// values are omitted from API requests. However, any field with an
4576	// empty value appearing in NullFields will be sent to the server as
4577	// null. It is an error if a field in this list has a non-empty value.
4578	// This may be used to include null fields in Patch requests.
4579	NullFields []string `json:"-"`
4580}
4581
4582func (s *GoogleCloudDialogflowCxV3beta1EventInput) MarshalJSON() ([]byte, error) {
4583	type NoMethod GoogleCloudDialogflowCxV3beta1EventInput
4584	raw := NoMethod(*s)
4585	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
4586}
4587
4588// GoogleCloudDialogflowCxV3beta1ExportAgentResponse: The response
4589// message for Agents.ExportAgent.
4590type GoogleCloudDialogflowCxV3beta1ExportAgentResponse struct {
4591	// AgentContent: Uncompressed raw byte content for agent.
4592	AgentContent string `json:"agentContent,omitempty"`
4593
4594	// AgentUri: The URI to a file containing the exported agent. This field
4595	// is populated only if `agent_uri` is specified in ExportAgentRequest.
4596	AgentUri string `json:"agentUri,omitempty"`
4597
4598	// ForceSendFields is a list of field names (e.g. "AgentContent") to
4599	// unconditionally include in API requests. By default, fields with
4600	// empty or default values are omitted from API requests. However, any
4601	// non-pointer, non-interface field appearing in ForceSendFields will be
4602	// sent to the server regardless of whether the field is empty or not.
4603	// This may be used to include empty fields in Patch requests.
4604	ForceSendFields []string `json:"-"`
4605
4606	// NullFields is a list of field names (e.g. "AgentContent") to include
4607	// in API requests with the JSON null value. By default, fields with
4608	// empty values are omitted from API requests. However, any field with
4609	// an empty value appearing in NullFields will be sent to the server as
4610	// null. It is an error if a field in this list has a non-empty value.
4611	// This may be used to include null fields in Patch requests.
4612	NullFields []string `json:"-"`
4613}
4614
4615func (s *GoogleCloudDialogflowCxV3beta1ExportAgentResponse) MarshalJSON() ([]byte, error) {
4616	type NoMethod GoogleCloudDialogflowCxV3beta1ExportAgentResponse
4617	raw := NoMethod(*s)
4618	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
4619}
4620
4621// GoogleCloudDialogflowCxV3beta1ExportFlowResponse: The response
4622// message for Flows.ExportFlow.
4623type GoogleCloudDialogflowCxV3beta1ExportFlowResponse struct {
4624	// FlowContent: Uncompressed raw byte content for flow.
4625	FlowContent string `json:"flowContent,omitempty"`
4626
4627	// FlowUri: The URI to a file containing the exported flow. This field
4628	// is populated only if `flow_uri` is specified in ExportFlowRequest.
4629	FlowUri string `json:"flowUri,omitempty"`
4630
4631	// ForceSendFields is a list of field names (e.g. "FlowContent") to
4632	// unconditionally include in API requests. By default, fields with
4633	// empty or default values are omitted from API requests. However, any
4634	// non-pointer, non-interface field appearing in ForceSendFields will be
4635	// sent to the server regardless of whether the field is empty or not.
4636	// This may be used to include empty fields in Patch requests.
4637	ForceSendFields []string `json:"-"`
4638
4639	// NullFields is a list of field names (e.g. "FlowContent") to include
4640	// in API requests with the JSON null value. By default, fields with
4641	// empty values are omitted from API requests. However, any field with
4642	// an empty value appearing in NullFields will be sent to the server as
4643	// null. It is an error if a field in this list has a non-empty value.
4644	// This may be used to include null fields in Patch requests.
4645	NullFields []string `json:"-"`
4646}
4647
4648func (s *GoogleCloudDialogflowCxV3beta1ExportFlowResponse) MarshalJSON() ([]byte, error) {
4649	type NoMethod GoogleCloudDialogflowCxV3beta1ExportFlowResponse
4650	raw := NoMethod(*s)
4651	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
4652}
4653
4654// GoogleCloudDialogflowCxV3beta1ExportTestCasesMetadata: Metadata
4655// returned for the TestCases.ExportTestCases long running operation.
4656// This message currently has no fields.
4657type GoogleCloudDialogflowCxV3beta1ExportTestCasesMetadata struct {
4658}
4659
4660// GoogleCloudDialogflowCxV3beta1ExportTestCasesResponse: The response
4661// message for TestCases.ExportTestCases.
4662type GoogleCloudDialogflowCxV3beta1ExportTestCasesResponse struct {
4663	// Content: Uncompressed raw byte content for test cases.
4664	Content string `json:"content,omitempty"`
4665
4666	// GcsUri: The URI to a file containing the exported test cases. This
4667	// field is populated only if `gcs_uri` is specified in
4668	// ExportTestCasesRequest.
4669	GcsUri string `json:"gcsUri,omitempty"`
4670
4671	// ForceSendFields is a list of field names (e.g. "Content") to
4672	// unconditionally include in API requests. By default, fields with
4673	// empty or default values are omitted from API requests. However, any
4674	// non-pointer, non-interface field appearing in ForceSendFields will be
4675	// sent to the server regardless of whether the field is empty or not.
4676	// This may be used to include empty fields in Patch requests.
4677	ForceSendFields []string `json:"-"`
4678
4679	// NullFields is a list of field names (e.g. "Content") to include in
4680	// API requests with the JSON null value. By default, fields with empty
4681	// values are omitted from API requests. However, any field with an
4682	// empty value appearing in NullFields will be sent to the server as
4683	// null. It is an error if a field in this list has a non-empty value.
4684	// This may be used to include null fields in Patch requests.
4685	NullFields []string `json:"-"`
4686}
4687
4688func (s *GoogleCloudDialogflowCxV3beta1ExportTestCasesResponse) MarshalJSON() ([]byte, error) {
4689	type NoMethod GoogleCloudDialogflowCxV3beta1ExportTestCasesResponse
4690	raw := NoMethod(*s)
4691	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
4692}
4693
4694// GoogleCloudDialogflowCxV3beta1Form: A form is a data model that
4695// groups related parameters that can be collected from the user. The
4696// process in which the agent prompts the user and collects parameter
4697// values from the user is called form filling. A form can be added to a
4698// page. When form filling is done, the filled parameters will be
4699// written to the session.
4700type GoogleCloudDialogflowCxV3beta1Form struct {
4701	// Parameters: Parameters to collect from the user.
4702	Parameters []*GoogleCloudDialogflowCxV3beta1FormParameter `json:"parameters,omitempty"`
4703
4704	// ForceSendFields is a list of field names (e.g. "Parameters") to
4705	// unconditionally include in API requests. By default, fields with
4706	// empty or default values are omitted from API requests. However, any
4707	// non-pointer, non-interface field appearing in ForceSendFields will be
4708	// sent to the server regardless of whether the field is empty or not.
4709	// This may be used to include empty fields in Patch requests.
4710	ForceSendFields []string `json:"-"`
4711
4712	// NullFields is a list of field names (e.g. "Parameters") to include in
4713	// API requests with the JSON null value. By default, fields with empty
4714	// values are omitted from API requests. However, any field with an
4715	// empty value appearing in NullFields will be sent to the server as
4716	// null. It is an error if a field in this list has a non-empty value.
4717	// This may be used to include null fields in Patch requests.
4718	NullFields []string `json:"-"`
4719}
4720
4721func (s *GoogleCloudDialogflowCxV3beta1Form) MarshalJSON() ([]byte, error) {
4722	type NoMethod GoogleCloudDialogflowCxV3beta1Form
4723	raw := NoMethod(*s)
4724	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
4725}
4726
4727// GoogleCloudDialogflowCxV3beta1FormParameter: Represents a form
4728// parameter.
4729type GoogleCloudDialogflowCxV3beta1FormParameter struct {
4730	// DefaultValue: The default value of an optional parameter. If the
4731	// parameter is required, the default value will be ignored.
4732	DefaultValue interface{} `json:"defaultValue,omitempty"`
4733
4734	// DisplayName: Required. The human-readable name of the parameter,
4735	// unique within the form.
4736	DisplayName string `json:"displayName,omitempty"`
4737
4738	// EntityType: Required. The entity type of the parameter. Format:
4739	// `projects/-/locations/-/agents/-/entityTypes/` for system entity
4740	// types (for example,
4741	// `projects/-/locations/-/agents/-/entityTypes/sys.date`), or
4742	// `projects//locations//agents//entityTypes/` for developer entity
4743	// types.
4744	EntityType string `json:"entityType,omitempty"`
4745
4746	// FillBehavior: Required. Defines fill behavior for the parameter.
4747	FillBehavior *GoogleCloudDialogflowCxV3beta1FormParameterFillBehavior `json:"fillBehavior,omitempty"`
4748
4749	// IsList: Indicates whether the parameter represents a list of values.
4750	IsList bool `json:"isList,omitempty"`
4751
4752	// Redact: Indicates whether the parameter content should be redacted in
4753	// log. If redaction is enabled, the parameter content will be replaced
4754	// by parameter name during logging. Note: the parameter content is
4755	// subject to redaction if either parameter level redaction or entity
4756	// type level redaction is enabled.
4757	Redact bool `json:"redact,omitempty"`
4758
4759	// Required: Indicates whether the parameter is required. Optional
4760	// parameters will not trigger prompts; however, they are filled if the
4761	// user specifies them. Required parameters must be filled before form
4762	// filling concludes.
4763	Required bool `json:"required,omitempty"`
4764
4765	// ForceSendFields is a list of field names (e.g. "DefaultValue") to
4766	// unconditionally include in API requests. By default, fields with
4767	// empty or default values are omitted from API requests. However, any
4768	// non-pointer, non-interface field appearing in ForceSendFields will be
4769	// sent to the server regardless of whether the field is empty or not.
4770	// This may be used to include empty fields in Patch requests.
4771	ForceSendFields []string `json:"-"`
4772
4773	// NullFields is a list of field names (e.g. "DefaultValue") to include
4774	// in API requests with the JSON null value. By default, fields with
4775	// empty values are omitted from API requests. However, any field with
4776	// an empty value appearing in NullFields will be sent to the server as
4777	// null. It is an error if a field in this list has a non-empty value.
4778	// This may be used to include null fields in Patch requests.
4779	NullFields []string `json:"-"`
4780}
4781
4782func (s *GoogleCloudDialogflowCxV3beta1FormParameter) MarshalJSON() ([]byte, error) {
4783	type NoMethod GoogleCloudDialogflowCxV3beta1FormParameter
4784	raw := NoMethod(*s)
4785	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
4786}
4787
4788// GoogleCloudDialogflowCxV3beta1FormParameterFillBehavior:
4789// Configuration for how the filling of a parameter should be handled.
4790type GoogleCloudDialogflowCxV3beta1FormParameterFillBehavior struct {
4791	// InitialPromptFulfillment: Required. The fulfillment to provide the
4792	// initial prompt that the agent can present to the user in order to
4793	// fill the parameter.
4794	InitialPromptFulfillment *GoogleCloudDialogflowCxV3beta1Fulfillment `json:"initialPromptFulfillment,omitempty"`
4795
4796	// RepromptEventHandlers: The handlers for parameter-level events, used
4797	// to provide reprompt for the parameter or transition to a different
4798	// page/flow. The supported events are: * `sys.no-match-`, where N can
4799	// be from 1 to 6 * `sys.no-match-default` * `sys.no-input-`, where N
4800	// can be from 1 to 6 * `sys.no-input-default` * `sys.invalid-parameter`
4801	// `initial_prompt_fulfillment` provides the first prompt for the
4802	// parameter. If the user's response does not fill the parameter, a
4803	// no-match/no-input event will be triggered, and the fulfillment
4804	// associated with the `sys.no-match-1`/`sys.no-input-1` handler (if
4805	// defined) will be called to provide a prompt. The
4806	// `sys.no-match-2`/`sys.no-input-2` handler (if defined) will respond
4807	// to the next no-match/no-input event, and so on. A
4808	// `sys.no-match-default` or `sys.no-input-default` handler will be used
4809	// to handle all following no-match/no-input events after all numbered
4810	// no-match/no-input handlers for the parameter are consumed. A
4811	// `sys.invalid-parameter` handler can be defined to handle the case
4812	// where the parameter values have been `invalidated` by webhook. For
4813	// example, if the user's response fill the parameter, however the
4814	// parameter was invalidated by webhook, the fulfillment associated with
4815	// the `sys.invalid-parameter` handler (if defined) will be called to
4816	// provide a prompt. If the event handler for the corresponding event
4817	// can't be found on the parameter, `initial_prompt_fulfillment` will be
4818	// re-prompted.
4819	RepromptEventHandlers []*GoogleCloudDialogflowCxV3beta1EventHandler `json:"repromptEventHandlers,omitempty"`
4820
4821	// ForceSendFields is a list of field names (e.g.
4822	// "InitialPromptFulfillment") to unconditionally include in API
4823	// requests. By default, fields with empty or default values are omitted
4824	// from API requests. However, any non-pointer, non-interface field
4825	// appearing in ForceSendFields will be sent to the server regardless of
4826	// whether the field is empty or not. This may be used to include empty
4827	// fields in Patch requests.
4828	ForceSendFields []string `json:"-"`
4829
4830	// NullFields is a list of field names (e.g. "InitialPromptFulfillment")
4831	// to include in API requests with the JSON null value. By default,
4832	// fields with empty values are omitted from API requests. However, any
4833	// field with an empty value appearing in NullFields will be sent to the
4834	// server as null. It is an error if a field in this list has a
4835	// non-empty value. This may be used to include null fields in Patch
4836	// requests.
4837	NullFields []string `json:"-"`
4838}
4839
4840func (s *GoogleCloudDialogflowCxV3beta1FormParameterFillBehavior) MarshalJSON() ([]byte, error) {
4841	type NoMethod GoogleCloudDialogflowCxV3beta1FormParameterFillBehavior
4842	raw := NoMethod(*s)
4843	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
4844}
4845
4846// GoogleCloudDialogflowCxV3beta1Fulfillment: A fulfillment can do one
4847// or more of the following actions at the same time: * Generate rich
4848// message responses. * Set parameter values. * Call the webhook.
4849// Fulfillments can be called at various stages in the Page or Form
4850// lifecycle. For example, when a DetectIntentRequest drives a session
4851// to enter a new page, the page's entry fulfillment can add a static
4852// response to the QueryResult in the returning DetectIntentResponse,
4853// call the webhook (for example, to load user data from a database), or
4854// both.
4855type GoogleCloudDialogflowCxV3beta1Fulfillment struct {
4856	// ConditionalCases: Conditional cases for this fulfillment.
4857	ConditionalCases []*GoogleCloudDialogflowCxV3beta1FulfillmentConditionalCases `json:"conditionalCases,omitempty"`
4858
4859	// Messages: The list of rich message responses to present to the user.
4860	Messages []*GoogleCloudDialogflowCxV3beta1ResponseMessage `json:"messages,omitempty"`
4861
4862	// ReturnPartialResponses: Whether Dialogflow should return currently
4863	// queued fulfillment response messages in streaming APIs. If a webhook
4864	// is specified, it happens before Dialogflow invokes webhook. Warning:
4865	// 1) This flag only affects streaming API. Responses are still queued
4866	// and returned once in non-streaming API. 2) The flag can be enabled in
4867	// any fulfillment but only the first 3 partial responses will be
4868	// returned. You may only want to apply it to fulfillments that have
4869	// slow webhooks.
4870	ReturnPartialResponses bool `json:"returnPartialResponses,omitempty"`
4871
4872	// SetParameterActions: Set parameter values before executing the
4873	// webhook.
4874	SetParameterActions []*GoogleCloudDialogflowCxV3beta1FulfillmentSetParameterAction `json:"setParameterActions,omitempty"`
4875
4876	// Tag: The tag used by the webhook to identify which fulfillment is
4877	// being called. This field is required if `webhook` is specified.
4878	Tag string `json:"tag,omitempty"`
4879
4880	// Webhook: The webhook to call. Format:
4881	// `projects//locations//agents//webhooks/`.
4882	Webhook string `json:"webhook,omitempty"`
4883
4884	// ForceSendFields is a list of field names (e.g. "ConditionalCases") to
4885	// unconditionally include in API requests. By default, fields with
4886	// empty or default values are omitted from API requests. However, any
4887	// non-pointer, non-interface field appearing in ForceSendFields will be
4888	// sent to the server regardless of whether the field is empty or not.
4889	// This may be used to include empty fields in Patch requests.
4890	ForceSendFields []string `json:"-"`
4891
4892	// NullFields is a list of field names (e.g. "ConditionalCases") to
4893	// include in API requests with the JSON null value. By default, fields
4894	// with empty values are omitted from API requests. However, any field
4895	// with an empty value appearing in NullFields will be sent to the
4896	// server as null. It is an error if a field in this list has a
4897	// non-empty value. This may be used to include null fields in Patch
4898	// requests.
4899	NullFields []string `json:"-"`
4900}
4901
4902func (s *GoogleCloudDialogflowCxV3beta1Fulfillment) MarshalJSON() ([]byte, error) {
4903	type NoMethod GoogleCloudDialogflowCxV3beta1Fulfillment
4904	raw := NoMethod(*s)
4905	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
4906}
4907
4908// GoogleCloudDialogflowCxV3beta1FulfillmentConditionalCases: A list of
4909// cascading if-else conditions. Cases are mutually exclusive. The first
4910// one with a matching condition is selected, all the rest ignored.
4911type GoogleCloudDialogflowCxV3beta1FulfillmentConditionalCases struct {
4912	// Cases: A list of cascading if-else conditions.
4913	Cases []*GoogleCloudDialogflowCxV3beta1FulfillmentConditionalCasesCase `json:"cases,omitempty"`
4914
4915	// ForceSendFields is a list of field names (e.g. "Cases") to
4916	// unconditionally include in API requests. By default, fields with
4917	// empty or default values are omitted from API requests. However, any
4918	// non-pointer, non-interface field appearing in ForceSendFields will be
4919	// sent to the server regardless of whether the field is empty or not.
4920	// This may be used to include empty fields in Patch requests.
4921	ForceSendFields []string `json:"-"`
4922
4923	// NullFields is a list of field names (e.g. "Cases") to include in API
4924	// requests with the JSON null value. By default, fields with empty
4925	// values are omitted from API requests. However, any field with an
4926	// empty value appearing in NullFields will be sent to the server as
4927	// null. It is an error if a field in this list has a non-empty value.
4928	// This may be used to include null fields in Patch requests.
4929	NullFields []string `json:"-"`
4930}
4931
4932func (s *GoogleCloudDialogflowCxV3beta1FulfillmentConditionalCases) MarshalJSON() ([]byte, error) {
4933	type NoMethod GoogleCloudDialogflowCxV3beta1FulfillmentConditionalCases
4934	raw := NoMethod(*s)
4935	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
4936}
4937
4938// GoogleCloudDialogflowCxV3beta1FulfillmentConditionalCasesCase: Each
4939// case has a Boolean condition. When it is evaluated to be True, the
4940// corresponding messages will be selected and evaluated recursively.
4941type GoogleCloudDialogflowCxV3beta1FulfillmentConditionalCasesCase struct {
4942	// CaseContent: A list of case content.
4943	CaseContent []*GoogleCloudDialogflowCxV3beta1FulfillmentConditionalCasesCaseCaseContent `json:"caseContent,omitempty"`
4944
4945	// Condition: The condition to activate and select this case. Empty
4946	// means the condition is always true. The condition is evaluated
4947	// against form parameters or session parameters. See the conditions
4948	// reference
4949	// (https://cloud.google.com/dialogflow/cx/docs/reference/condition).
4950	Condition string `json:"condition,omitempty"`
4951
4952	// ForceSendFields is a list of field names (e.g. "CaseContent") to
4953	// unconditionally include in API requests. By default, fields with
4954	// empty or default values are omitted from API requests. However, any
4955	// non-pointer, non-interface field appearing in ForceSendFields will be
4956	// sent to the server regardless of whether the field is empty or not.
4957	// This may be used to include empty fields in Patch requests.
4958	ForceSendFields []string `json:"-"`
4959
4960	// NullFields is a list of field names (e.g. "CaseContent") to include
4961	// in API requests with the JSON null value. By default, fields with
4962	// empty values are omitted from API requests. However, any field with
4963	// an empty value appearing in NullFields will be sent to the server as
4964	// null. It is an error if a field in this list has a non-empty value.
4965	// This may be used to include null fields in Patch requests.
4966	NullFields []string `json:"-"`
4967}
4968
4969func (s *GoogleCloudDialogflowCxV3beta1FulfillmentConditionalCasesCase) MarshalJSON() ([]byte, error) {
4970	type NoMethod GoogleCloudDialogflowCxV3beta1FulfillmentConditionalCasesCase
4971	raw := NoMethod(*s)
4972	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
4973}
4974
4975// GoogleCloudDialogflowCxV3beta1FulfillmentConditionalCasesCaseCaseConte
4976// nt: The list of messages or conditional cases to activate for this
4977// case.
4978type GoogleCloudDialogflowCxV3beta1FulfillmentConditionalCasesCaseCaseContent struct {
4979	// AdditionalCases: Additional cases to be evaluated.
4980	AdditionalCases *GoogleCloudDialogflowCxV3beta1FulfillmentConditionalCases `json:"additionalCases,omitempty"`
4981
4982	// Message: Returned message.
4983	Message *GoogleCloudDialogflowCxV3beta1ResponseMessage `json:"message,omitempty"`
4984
4985	// ForceSendFields is a list of field names (e.g. "AdditionalCases") to
4986	// unconditionally include in API requests. By default, fields with
4987	// empty or default values are omitted from API requests. However, any
4988	// non-pointer, non-interface field appearing in ForceSendFields will be
4989	// sent to the server regardless of whether the field is empty or not.
4990	// This may be used to include empty fields in Patch requests.
4991	ForceSendFields []string `json:"-"`
4992
4993	// NullFields is a list of field names (e.g. "AdditionalCases") to
4994	// include in API requests with the JSON null value. By default, fields
4995	// with empty values are omitted from API requests. However, any field
4996	// with an empty value appearing in NullFields will be sent to the
4997	// server as null. It is an error if a field in this list has a
4998	// non-empty value. This may be used to include null fields in Patch
4999	// requests.
5000	NullFields []string `json:"-"`
5001}
5002
5003func (s *GoogleCloudDialogflowCxV3beta1FulfillmentConditionalCasesCaseCaseContent) MarshalJSON() ([]byte, error) {
5004	type NoMethod GoogleCloudDialogflowCxV3beta1FulfillmentConditionalCasesCaseCaseContent
5005	raw := NoMethod(*s)
5006	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
5007}
5008
5009// GoogleCloudDialogflowCxV3beta1FulfillmentSetParameterAction: Setting
5010// a parameter value.
5011type GoogleCloudDialogflowCxV3beta1FulfillmentSetParameterAction struct {
5012	// Parameter: Display name of the parameter.
5013	Parameter string `json:"parameter,omitempty"`
5014
5015	// Value: The new value of the parameter. A null value clears the
5016	// parameter.
5017	Value interface{} `json:"value,omitempty"`
5018
5019	// ForceSendFields is a list of field names (e.g. "Parameter") to
5020	// unconditionally include in API requests. By default, fields with
5021	// empty or default values are omitted from API requests. However, any
5022	// non-pointer, non-interface field appearing in ForceSendFields will be
5023	// sent to the server regardless of whether the field is empty or not.
5024	// This may be used to include empty fields in Patch requests.
5025	ForceSendFields []string `json:"-"`
5026
5027	// NullFields is a list of field names (e.g. "Parameter") to include in
5028	// API requests with the JSON null value. By default, fields with empty
5029	// values are omitted from API requests. However, any field with an
5030	// empty value appearing in NullFields will be sent to the server as
5031	// null. It is an error if a field in this list has a non-empty value.
5032	// This may be used to include null fields in Patch requests.
5033	NullFields []string `json:"-"`
5034}
5035
5036func (s *GoogleCloudDialogflowCxV3beta1FulfillmentSetParameterAction) MarshalJSON() ([]byte, error) {
5037	type NoMethod GoogleCloudDialogflowCxV3beta1FulfillmentSetParameterAction
5038	raw := NoMethod(*s)
5039	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
5040}
5041
5042// GoogleCloudDialogflowCxV3beta1GenericKnowledgeOperationMetadata:
5043// Metadata in google::longrunning::Operation for Knowledge operations.
5044type GoogleCloudDialogflowCxV3beta1GenericKnowledgeOperationMetadata struct {
5045	// State: Required. Output only. The current state of this operation.
5046	//
5047	// Possible values:
5048	//   "STATE_UNSPECIFIED" - State unspecified.
5049	//   "PENDING" - The operation has been created.
5050	//   "RUNNING" - The operation is currently running.
5051	//   "DONE" - The operation is done, either cancelled or completed.
5052	State string `json:"state,omitempty"`
5053
5054	// ForceSendFields is a list of field names (e.g. "State") to
5055	// unconditionally include in API requests. By default, fields with
5056	// empty or default values are omitted from API requests. However, any
5057	// non-pointer, non-interface field appearing in ForceSendFields will be
5058	// sent to the server regardless of whether the field is empty or not.
5059	// This may be used to include empty fields in Patch requests.
5060	ForceSendFields []string `json:"-"`
5061
5062	// NullFields is a list of field names (e.g. "State") to include in API
5063	// requests with the JSON null value. By default, fields with empty
5064	// values are omitted from API requests. However, any field with an
5065	// empty value appearing in NullFields will be sent to the server as
5066	// null. It is an error if a field in this list has a non-empty value.
5067	// This may be used to include null fields in Patch requests.
5068	NullFields []string `json:"-"`
5069}
5070
5071func (s *GoogleCloudDialogflowCxV3beta1GenericKnowledgeOperationMetadata) MarshalJSON() ([]byte, error) {
5072	type NoMethod GoogleCloudDialogflowCxV3beta1GenericKnowledgeOperationMetadata
5073	raw := NoMethod(*s)
5074	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
5075}
5076
5077// GoogleCloudDialogflowCxV3beta1ImportDocumentsOperationMetadata:
5078// Metadata for ImportDocuments operation.
5079type GoogleCloudDialogflowCxV3beta1ImportDocumentsOperationMetadata struct {
5080	// GenericMetadata: The generic information of the operation.
5081	GenericMetadata *GoogleCloudDialogflowCxV3beta1GenericKnowledgeOperationMetadata `json:"genericMetadata,omitempty"`
5082
5083	// ForceSendFields is a list of field names (e.g. "GenericMetadata") to
5084	// unconditionally include in API requests. By default, fields with
5085	// empty or default values are omitted from API requests. However, any
5086	// non-pointer, non-interface field appearing in ForceSendFields will be
5087	// sent to the server regardless of whether the field is empty or not.
5088	// This may be used to include empty fields in Patch requests.
5089	ForceSendFields []string `json:"-"`
5090
5091	// NullFields is a list of field names (e.g. "GenericMetadata") to
5092	// include in API requests with the JSON null value. By default, fields
5093	// with empty values are omitted from API requests. However, any field
5094	// with an empty value appearing in NullFields will be sent to the
5095	// server as null. It is an error if a field in this list has a
5096	// non-empty value. This may be used to include null fields in Patch
5097	// requests.
5098	NullFields []string `json:"-"`
5099}
5100
5101func (s *GoogleCloudDialogflowCxV3beta1ImportDocumentsOperationMetadata) MarshalJSON() ([]byte, error) {
5102	type NoMethod GoogleCloudDialogflowCxV3beta1ImportDocumentsOperationMetadata
5103	raw := NoMethod(*s)
5104	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
5105}
5106
5107// GoogleCloudDialogflowCxV3beta1ImportDocumentsResponse: Response
5108// message for Documents.ImportDocuments.
5109type GoogleCloudDialogflowCxV3beta1ImportDocumentsResponse struct {
5110	// Warnings: Includes details about skipped documents or any other
5111	// warnings.
5112	Warnings []*GoogleRpcStatus `json:"warnings,omitempty"`
5113
5114	// ForceSendFields is a list of field names (e.g. "Warnings") to
5115	// unconditionally include in API requests. By default, fields with
5116	// empty or default values are omitted from API requests. However, any
5117	// non-pointer, non-interface field appearing in ForceSendFields will be
5118	// sent to the server regardless of whether the field is empty or not.
5119	// This may be used to include empty fields in Patch requests.
5120	ForceSendFields []string `json:"-"`
5121
5122	// NullFields is a list of field names (e.g. "Warnings") to include in
5123	// API requests with the JSON null value. By default, fields with empty
5124	// values are omitted from API requests. However, any field with an
5125	// empty value appearing in NullFields will be sent to the server as
5126	// null. It is an error if a field in this list has a non-empty value.
5127	// This may be used to include null fields in Patch requests.
5128	NullFields []string `json:"-"`
5129}
5130
5131func (s *GoogleCloudDialogflowCxV3beta1ImportDocumentsResponse) MarshalJSON() ([]byte, error) {
5132	type NoMethod GoogleCloudDialogflowCxV3beta1ImportDocumentsResponse
5133	raw := NoMethod(*s)
5134	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
5135}
5136
5137// GoogleCloudDialogflowCxV3beta1ImportFlowResponse: The response
5138// message for Flows.ImportFlow.
5139type GoogleCloudDialogflowCxV3beta1ImportFlowResponse struct {
5140	// Flow: The unique identifier of the new flow. Format:
5141	// `projects//locations//agents//flows/`.
5142	Flow string `json:"flow,omitempty"`
5143
5144	// ForceSendFields is a list of field names (e.g. "Flow") to
5145	// unconditionally include in API requests. By default, fields with
5146	// empty or default values are omitted from API requests. However, any
5147	// non-pointer, non-interface field appearing in ForceSendFields will be
5148	// sent to the server regardless of whether the field is empty or not.
5149	// This may be used to include empty fields in Patch requests.
5150	ForceSendFields []string `json:"-"`
5151
5152	// NullFields is a list of field names (e.g. "Flow") to include in API
5153	// requests with the JSON null value. By default, fields with empty
5154	// values are omitted from API requests. However, any field with an
5155	// empty value appearing in NullFields will be sent to the server as
5156	// null. It is an error if a field in this list has a non-empty value.
5157	// This may be used to include null fields in Patch requests.
5158	NullFields []string `json:"-"`
5159}
5160
5161func (s *GoogleCloudDialogflowCxV3beta1ImportFlowResponse) MarshalJSON() ([]byte, error) {
5162	type NoMethod GoogleCloudDialogflowCxV3beta1ImportFlowResponse
5163	raw := NoMethod(*s)
5164	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
5165}
5166
5167// GoogleCloudDialogflowCxV3beta1ImportTestCasesMetadata: Metadata
5168// returned for the TestCases.ImportTestCases long running operation.
5169type GoogleCloudDialogflowCxV3beta1ImportTestCasesMetadata struct {
5170	// Errors: Errors for failed test cases.
5171	Errors []*GoogleCloudDialogflowCxV3beta1TestCaseError `json:"errors,omitempty"`
5172
5173	// ForceSendFields is a list of field names (e.g. "Errors") to
5174	// unconditionally include in API requests. By default, fields with
5175	// empty or default values are omitted from API requests. However, any
5176	// non-pointer, non-interface field appearing in ForceSendFields will be
5177	// sent to the server regardless of whether the field is empty or not.
5178	// This may be used to include empty fields in Patch requests.
5179	ForceSendFields []string `json:"-"`
5180
5181	// NullFields is a list of field names (e.g. "Errors") to include in API
5182	// requests with the JSON null value. By default, fields with empty
5183	// values are omitted from API requests. However, any field with an
5184	// empty value appearing in NullFields will be sent to the server as
5185	// null. It is an error if a field in this list has a non-empty value.
5186	// This may be used to include null fields in Patch requests.
5187	NullFields []string `json:"-"`
5188}
5189
5190func (s *GoogleCloudDialogflowCxV3beta1ImportTestCasesMetadata) MarshalJSON() ([]byte, error) {
5191	type NoMethod GoogleCloudDialogflowCxV3beta1ImportTestCasesMetadata
5192	raw := NoMethod(*s)
5193	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
5194}
5195
5196// GoogleCloudDialogflowCxV3beta1ImportTestCasesResponse: The response
5197// message for TestCases.ImportTestCases.
5198type GoogleCloudDialogflowCxV3beta1ImportTestCasesResponse struct {
5199	// Names: The unique identifiers of the new test cases. Format:
5200	// `projects//locations//agents//testCases/`.
5201	Names []string `json:"names,omitempty"`
5202
5203	// ForceSendFields is a list of field names (e.g. "Names") to
5204	// unconditionally include in API requests. By default, fields with
5205	// empty or default values are omitted from API requests. However, any
5206	// non-pointer, non-interface field appearing in ForceSendFields will be
5207	// sent to the server regardless of whether the field is empty or not.
5208	// This may be used to include empty fields in Patch requests.
5209	ForceSendFields []string `json:"-"`
5210
5211	// NullFields is a list of field names (e.g. "Names") to include in API
5212	// requests with the JSON null value. By default, fields with empty
5213	// values are omitted from API requests. However, any field with an
5214	// empty value appearing in NullFields will be sent to the server as
5215	// null. It is an error if a field in this list has a non-empty value.
5216	// This may be used to include null fields in Patch requests.
5217	NullFields []string `json:"-"`
5218}
5219
5220func (s *GoogleCloudDialogflowCxV3beta1ImportTestCasesResponse) MarshalJSON() ([]byte, error) {
5221	type NoMethod GoogleCloudDialogflowCxV3beta1ImportTestCasesResponse
5222	raw := NoMethod(*s)
5223	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
5224}
5225
5226// GoogleCloudDialogflowCxV3beta1InputAudioConfig: Instructs the speech
5227// recognizer on how to process the audio content.
5228type GoogleCloudDialogflowCxV3beta1InputAudioConfig struct {
5229	// AudioEncoding: Required. Audio encoding of the audio content to
5230	// process.
5231	//
5232	// Possible values:
5233	//   "AUDIO_ENCODING_UNSPECIFIED" - Not specified.
5234	//   "AUDIO_ENCODING_LINEAR_16" - Uncompressed 16-bit signed
5235	// little-endian samples (Linear PCM).
5236	//   "AUDIO_ENCODING_FLAC" -
5237	// [`FLAC`](https://xiph.org/flac/documentation.html) (Free Lossless
5238	// Audio Codec) is the recommended encoding because it is lossless
5239	// (therefore recognition is not compromised) and requires only about
5240	// half the bandwidth of `LINEAR16`. `FLAC` stream encoding supports
5241	// 16-bit and 24-bit samples, however, not all fields in `STREAMINFO`
5242	// are supported.
5243	//   "AUDIO_ENCODING_MULAW" - 8-bit samples that compand 14-bit audio
5244	// samples using G.711 PCMU/mu-law.
5245	//   "AUDIO_ENCODING_AMR" - Adaptive Multi-Rate Narrowband codec.
5246	// `sample_rate_hertz` must be 8000.
5247	//   "AUDIO_ENCODING_AMR_WB" - Adaptive Multi-Rate Wideband codec.
5248	// `sample_rate_hertz` must be 16000.
5249	//   "AUDIO_ENCODING_OGG_OPUS" - Opus encoded audio frames in Ogg
5250	// container ([OggOpus](https://wiki.xiph.org/OggOpus)).
5251	// `sample_rate_hertz` must be 16000.
5252	//   "AUDIO_ENCODING_SPEEX_WITH_HEADER_BYTE" - Although the use of lossy
5253	// encodings is not recommended, if a very low bitrate encoding is
5254	// required, `OGG_OPUS` is highly preferred over Speex encoding. The
5255	// [Speex](https://speex.org/) encoding supported by Dialogflow API has
5256	// a header byte in each block, as in MIME type
5257	// `audio/x-speex-with-header-byte`. It is a variant of the RTP Speex
5258	// encoding defined in [RFC 5574](https://tools.ietf.org/html/rfc5574).
5259	// The stream is a sequence of blocks, one block per RTP packet. Each
5260	// block starts with a byte containing the length of the block, in
5261	// bytes, followed by one or more frames of Speex data, padded to an
5262	// integral number of bytes (octets) as specified in RFC 5574. In other
5263	// words, each RTP header is replaced with a single byte containing the
5264	// block length. Only Speex wideband is supported. `sample_rate_hertz`
5265	// must be 16000.
5266	AudioEncoding string `json:"audioEncoding,omitempty"`
5267
5268	// EnableWordInfo: Optional. If `true`, Dialogflow returns
5269	// SpeechWordInfo in StreamingRecognitionResult with information about
5270	// the recognized speech words, e.g. start and end time offsets. If
5271	// false or unspecified, Speech doesn't return any word-level
5272	// information.
5273	EnableWordInfo bool `json:"enableWordInfo,omitempty"`
5274
5275	// Model: Optional. Which Speech model to select for the given request.
5276	// Select the model best suited to your domain to get best results. If a
5277	// model is not explicitly specified, then we auto-select a model based
5278	// on the parameters in the InputAudioConfig. If enhanced speech model
5279	// is enabled for the agent and an enhanced version of the specified
5280	// model for the language does not exist, then the speech is recognized
5281	// using the standard version of the specified model. Refer to Cloud
5282	// Speech API documentation
5283	// (https://cloud.google.com/speech-to-text/docs/basics#select-model)
5284	// for more details.
5285	Model string `json:"model,omitempty"`
5286
5287	// ModelVariant: Optional. Which variant of the Speech model to use.
5288	//
5289	// Possible values:
5290	//   "SPEECH_MODEL_VARIANT_UNSPECIFIED" - No model variant specified. In
5291	// this case Dialogflow defaults to USE_BEST_AVAILABLE.
5292	//   "USE_BEST_AVAILABLE" - Use the best available variant of the Speech
5293	// model that the caller is eligible for. Please see the [Dialogflow
5294	// docs](https://cloud.google.com/dialogflow/docs/data-logging) for how
5295	// to make your project eligible for enhanced models.
5296	//   "USE_STANDARD" - Use standard model variant even if an enhanced
5297	// model is available. See the [Cloud Speech
5298	// documentation](https://cloud.google.com/speech-to-text/docs/enhanced-m
5299	// odels) for details about enhanced models.
5300	//   "USE_ENHANCED" - Use an enhanced model variant: * If an enhanced
5301	// variant does not exist for the given model and request language,
5302	// Dialogflow falls back to the standard variant. The [Cloud Speech
5303	// documentation](https://cloud.google.com/speech-to-text/docs/enhanced-m
5304	// odels) describes which models have enhanced variants. * If the API
5305	// caller isn't eligible for enhanced models, Dialogflow returns an
5306	// error. Please see the [Dialogflow
5307	// docs](https://cloud.google.com/dialogflow/docs/data-logging) for how
5308	// to make your project eligible.
5309	ModelVariant string `json:"modelVariant,omitempty"`
5310
5311	// PhraseHints: Optional. A list of strings containing words and phrases
5312	// that the speech recognizer should recognize with higher likelihood.
5313	// See the Cloud Speech documentation
5314	// (https://cloud.google.com/speech-to-text/docs/basics#phrase-hints)
5315	// for more details.
5316	PhraseHints []string `json:"phraseHints,omitempty"`
5317
5318	// SampleRateHertz: Sample rate (in Hertz) of the audio content sent in
5319	// the query. Refer to Cloud Speech API documentation
5320	// (https://cloud.google.com/speech-to-text/docs/basics) for more
5321	// details.
5322	SampleRateHertz int64 `json:"sampleRateHertz,omitempty"`
5323
5324	// SingleUtterance: Optional. If `false` (default), recognition does not
5325	// cease until the client closes the stream. If `true`, the recognizer
5326	// will detect a single spoken utterance in input audio. Recognition
5327	// ceases when it detects the audio's voice has stopped or paused. In
5328	// this case, once a detected intent is received, the client should
5329	// close the stream and start a new request with a new stream as needed.
5330	// Note: This setting is relevant only for streaming methods.
5331	SingleUtterance bool `json:"singleUtterance,omitempty"`
5332
5333	// ForceSendFields is a list of field names (e.g. "AudioEncoding") to
5334	// unconditionally include in API requests. By default, fields with
5335	// empty or default values are omitted from API requests. However, any
5336	// non-pointer, non-interface field appearing in ForceSendFields will be
5337	// sent to the server regardless of whether the field is empty or not.
5338	// This may be used to include empty fields in Patch requests.
5339	ForceSendFields []string `json:"-"`
5340
5341	// NullFields is a list of field names (e.g. "AudioEncoding") to include
5342	// in API requests with the JSON null value. By default, fields with
5343	// empty values are omitted from API requests. However, any field with
5344	// an empty value appearing in NullFields will be sent to the server as
5345	// null. It is an error if a field in this list has a non-empty value.
5346	// This may be used to include null fields in Patch requests.
5347	NullFields []string `json:"-"`
5348}
5349
5350func (s *GoogleCloudDialogflowCxV3beta1InputAudioConfig) MarshalJSON() ([]byte, error) {
5351	type NoMethod GoogleCloudDialogflowCxV3beta1InputAudioConfig
5352	raw := NoMethod(*s)
5353	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
5354}
5355
5356// GoogleCloudDialogflowCxV3beta1Intent: An intent represents a user's
5357// intent to interact with a conversational agent. You can provide
5358// information for the Dialogflow API to use to match user input to an
5359// intent by adding training phrases (i.e., examples of user input) to
5360// your intent.
5361type GoogleCloudDialogflowCxV3beta1Intent struct {
5362	// Description: Human readable description for better understanding an
5363	// intent like its scope, content, result etc. Maximum character limit:
5364	// 140 characters.
5365	Description string `json:"description,omitempty"`
5366
5367	// DisplayName: Required. The human-readable name of the intent, unique
5368	// within the agent.
5369	DisplayName string `json:"displayName,omitempty"`
5370
5371	// IsFallback: Indicates whether this is a fallback intent. Currently
5372	// only default fallback intent is allowed in the agent, which is added
5373	// upon agent creation. Adding training phrases to fallback intent is
5374	// useful in the case of requests that are mistakenly matched, since
5375	// training phrases assigned to fallback intents act as negative
5376	// examples that triggers no-match event.
5377	IsFallback bool `json:"isFallback,omitempty"`
5378
5379	// Labels: The key/value metadata to label an intent. Labels can contain
5380	// lowercase letters, digits and the symbols '-' and '_'. International
5381	// characters are allowed, including letters from unicase alphabets.
5382	// Keys must start with a letter. Keys and values can be no longer than
5383	// 63 characters and no more than 128 bytes. Prefix "sys-" is reserved
5384	// for Dialogflow defined labels. Currently allowed Dialogflow defined
5385	// labels include: * sys-head * sys-contextual The above labels do not
5386	// require value. "sys-head" means the intent is a head intent.
5387	// "sys-contextual" means the intent is a contextual intent.
5388	Labels map[string]string `json:"labels,omitempty"`
5389
5390	// Name: The unique identifier of the intent. Required for the
5391	// Intents.UpdateIntent method. Intents.CreateIntent populates the name
5392	// automatically. Format: `projects//locations//agents//intents/`.
5393	Name string `json:"name,omitempty"`
5394
5395	// Parameters: The collection of parameters associated with the intent.
5396	Parameters []*GoogleCloudDialogflowCxV3beta1IntentParameter `json:"parameters,omitempty"`
5397
5398	// Priority: The priority of this intent. Higher numbers represent
5399	// higher priorities. - If the supplied value is unspecified or 0, the
5400	// service translates the value to 500,000, which corresponds to the
5401	// `Normal` priority in the console. - If the supplied value is
5402	// negative, the intent is ignored in runtime detect intent requests.
5403	Priority int64 `json:"priority,omitempty"`
5404
5405	// TrainingPhrases: The collection of training phrases the agent is
5406	// trained on to identify the intent.
5407	TrainingPhrases []*GoogleCloudDialogflowCxV3beta1IntentTrainingPhrase `json:"trainingPhrases,omitempty"`
5408
5409	// ForceSendFields is a list of field names (e.g. "Description") to
5410	// unconditionally include in API requests. By default, fields with
5411	// empty or default values are omitted from API requests. However, any
5412	// non-pointer, non-interface field appearing in ForceSendFields will be
5413	// sent to the server regardless of whether the field is empty or not.
5414	// This may be used to include empty fields in Patch requests.
5415	ForceSendFields []string `json:"-"`
5416
5417	// NullFields is a list of field names (e.g. "Description") to include
5418	// in API requests with the JSON null value. By default, fields with
5419	// empty values are omitted from API requests. However, any field with
5420	// an empty value appearing in NullFields will be sent to the server as
5421	// null. It is an error if a field in this list has a non-empty value.
5422	// This may be used to include null fields in Patch requests.
5423	NullFields []string `json:"-"`
5424}
5425
5426func (s *GoogleCloudDialogflowCxV3beta1Intent) MarshalJSON() ([]byte, error) {
5427	type NoMethod GoogleCloudDialogflowCxV3beta1Intent
5428	raw := NoMethod(*s)
5429	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
5430}
5431
5432// GoogleCloudDialogflowCxV3beta1IntentInput: Represents the intent to
5433// trigger programmatically rather than as a result of natural language
5434// processing.
5435type GoogleCloudDialogflowCxV3beta1IntentInput struct {
5436	// Intent: Required. The unique identifier of the intent. Format:
5437	// `projects//locations//agents//intents/`.
5438	Intent string `json:"intent,omitempty"`
5439
5440	// ForceSendFields is a list of field names (e.g. "Intent") to
5441	// unconditionally include in API requests. By default, fields with
5442	// empty or default values are omitted from API requests. However, any
5443	// non-pointer, non-interface field appearing in ForceSendFields will be
5444	// sent to the server regardless of whether the field is empty or not.
5445	// This may be used to include empty fields in Patch requests.
5446	ForceSendFields []string `json:"-"`
5447
5448	// NullFields is a list of field names (e.g. "Intent") to include in API
5449	// requests with the JSON null value. By default, fields with empty
5450	// values are omitted from API requests. However, any field with an
5451	// empty value appearing in NullFields will be sent to the server as
5452	// null. It is an error if a field in this list has a non-empty value.
5453	// This may be used to include null fields in Patch requests.
5454	NullFields []string `json:"-"`
5455}
5456
5457func (s *GoogleCloudDialogflowCxV3beta1IntentInput) MarshalJSON() ([]byte, error) {
5458	type NoMethod GoogleCloudDialogflowCxV3beta1IntentInput
5459	raw := NoMethod(*s)
5460	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
5461}
5462
5463// GoogleCloudDialogflowCxV3beta1IntentParameter: Represents an intent
5464// parameter.
5465type GoogleCloudDialogflowCxV3beta1IntentParameter struct {
5466	// EntityType: Required. The entity type of the parameter. Format:
5467	// `projects/-/locations/-/agents/-/entityTypes/` for system entity
5468	// types (for example,
5469	// `projects/-/locations/-/agents/-/entityTypes/sys.date`), or
5470	// `projects//locations//agents//entityTypes/` for developer entity
5471	// types.
5472	EntityType string `json:"entityType,omitempty"`
5473
5474	// Id: Required. The unique identifier of the parameter. This field is
5475	// used by training phrases to annotate their parts.
5476	Id string `json:"id,omitempty"`
5477
5478	// IsList: Indicates whether the parameter represents a list of values.
5479	IsList bool `json:"isList,omitempty"`
5480
5481	// Redact: Indicates whether the parameter content should be redacted in
5482	// log. If redaction is enabled, the parameter content will be replaced
5483	// by parameter name during logging. Note: the parameter content is
5484	// subject to redaction if either parameter level redaction or entity
5485	// type level redaction is enabled.
5486	Redact bool `json:"redact,omitempty"`
5487
5488	// ForceSendFields is a list of field names (e.g. "EntityType") to
5489	// unconditionally include in API requests. By default, fields with
5490	// empty or default values are omitted from API requests. However, any
5491	// non-pointer, non-interface field appearing in ForceSendFields will be
5492	// sent to the server regardless of whether the field is empty or not.
5493	// This may be used to include empty fields in Patch requests.
5494	ForceSendFields []string `json:"-"`
5495
5496	// NullFields is a list of field names (e.g. "EntityType") to include in
5497	// API requests with the JSON null value. By default, fields with empty
5498	// values are omitted from API requests. However, any field with an
5499	// empty value appearing in NullFields will be sent to the server as
5500	// null. It is an error if a field in this list has a non-empty value.
5501	// This may be used to include null fields in Patch requests.
5502	NullFields []string `json:"-"`
5503}
5504
5505func (s *GoogleCloudDialogflowCxV3beta1IntentParameter) MarshalJSON() ([]byte, error) {
5506	type NoMethod GoogleCloudDialogflowCxV3beta1IntentParameter
5507	raw := NoMethod(*s)
5508	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
5509}
5510
5511// GoogleCloudDialogflowCxV3beta1IntentTrainingPhrase: Represents an
5512// example that the agent is trained on to identify the intent.
5513type GoogleCloudDialogflowCxV3beta1IntentTrainingPhrase struct {
5514	// Id: Output only. The unique identifier of the training phrase.
5515	Id string `json:"id,omitempty"`
5516
5517	// Parts: Required. The ordered list of training phrase parts. The parts
5518	// are concatenated in order to form the training phrase. Note: The API
5519	// does not automatically annotate training phrases like the Dialogflow
5520	// Console does. Note: Do not forget to include whitespace at part
5521	// boundaries, so the training phrase is well formatted when the parts
5522	// are concatenated. If the training phrase does not need to be
5523	// annotated with parameters, you just need a single part with only the
5524	// Part.text field set. If you want to annotate the training phrase, you
5525	// must create multiple parts, where the fields of each part are
5526	// populated in one of two ways: - `Part.text` is set to a part of the
5527	// phrase that has no parameters. - `Part.text` is set to a part of the
5528	// phrase that you want to annotate, and the `parameter_id` field is
5529	// set.
5530	Parts []*GoogleCloudDialogflowCxV3beta1IntentTrainingPhrasePart `json:"parts,omitempty"`
5531
5532	// RepeatCount: Indicates how many times this example was added to the
5533	// intent.
5534	RepeatCount int64 `json:"repeatCount,omitempty"`
5535
5536	// ForceSendFields is a list of field names (e.g. "Id") to
5537	// unconditionally include in API requests. By default, fields with
5538	// empty or default values are omitted from API requests. However, any
5539	// non-pointer, non-interface field appearing in ForceSendFields will be
5540	// sent to the server regardless of whether the field is empty or not.
5541	// This may be used to include empty fields in Patch requests.
5542	ForceSendFields []string `json:"-"`
5543
5544	// NullFields is a list of field names (e.g. "Id") to include in API
5545	// requests with the JSON null value. By default, fields with empty
5546	// values are omitted from API requests. However, any field with an
5547	// empty value appearing in NullFields will be sent to the server as
5548	// null. It is an error if a field in this list has a non-empty value.
5549	// This may be used to include null fields in Patch requests.
5550	NullFields []string `json:"-"`
5551}
5552
5553func (s *GoogleCloudDialogflowCxV3beta1IntentTrainingPhrase) MarshalJSON() ([]byte, error) {
5554	type NoMethod GoogleCloudDialogflowCxV3beta1IntentTrainingPhrase
5555	raw := NoMethod(*s)
5556	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
5557}
5558
5559// GoogleCloudDialogflowCxV3beta1IntentTrainingPhrasePart: Represents a
5560// part of a training phrase.
5561type GoogleCloudDialogflowCxV3beta1IntentTrainingPhrasePart struct {
5562	// ParameterId: The parameter used to annotate this part of the training
5563	// phrase. This field is required for annotated parts of the training
5564	// phrase.
5565	ParameterId string `json:"parameterId,omitempty"`
5566
5567	// Text: Required. The text for this part.
5568	Text string `json:"text,omitempty"`
5569
5570	// ForceSendFields is a list of field names (e.g. "ParameterId") to
5571	// unconditionally include in API requests. By default, fields with
5572	// empty or default values are omitted from API requests. However, any
5573	// non-pointer, non-interface field appearing in ForceSendFields will be
5574	// sent to the server regardless of whether the field is empty or not.
5575	// This may be used to include empty fields in Patch requests.
5576	ForceSendFields []string `json:"-"`
5577
5578	// NullFields is a list of field names (e.g. "ParameterId") to include
5579	// in API requests with the JSON null value. By default, fields with
5580	// empty values are omitted from API requests. However, any field with
5581	// an empty value appearing in NullFields will be sent to the server as
5582	// null. It is an error if a field in this list has a non-empty value.
5583	// This may be used to include null fields in Patch requests.
5584	NullFields []string `json:"-"`
5585}
5586
5587func (s *GoogleCloudDialogflowCxV3beta1IntentTrainingPhrasePart) MarshalJSON() ([]byte, error) {
5588	type NoMethod GoogleCloudDialogflowCxV3beta1IntentTrainingPhrasePart
5589	raw := NoMethod(*s)
5590	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
5591}
5592
5593// GoogleCloudDialogflowCxV3beta1Page: A Dialogflow CX conversation
5594// (session) can be described and visualized as a state machine. The
5595// states of a CX session are represented by pages. For each flow, you
5596// define many pages, where your combined pages can handle a complete
5597// conversation on the topics the flow is designed for. At any given
5598// moment, exactly one page is the current page, the current page is
5599// considered active, and the flow associated with that page is
5600// considered active. Every flow has a special start page. When a flow
5601// initially becomes active, the start page page becomes the current
5602// page. For each conversational turn, the current page will either stay
5603// the same or transition to another page. You configure each page to
5604// collect information from the end-user that is relevant for the
5605// conversational state represented by the page. For more information,
5606// see the Page guide
5607// (https://cloud.google.com/dialogflow/cx/docs/concept/page).
5608type GoogleCloudDialogflowCxV3beta1Page struct {
5609	// DisplayName: Required. The human-readable name of the page, unique
5610	// within the agent.
5611	DisplayName string `json:"displayName,omitempty"`
5612
5613	// EntryFulfillment: The fulfillment to call when the session is
5614	// entering the page.
5615	EntryFulfillment *GoogleCloudDialogflowCxV3beta1Fulfillment `json:"entryFulfillment,omitempty"`
5616
5617	// EventHandlers: Handlers associated with the page to handle events
5618	// such as webhook errors, no match or no input.
5619	EventHandlers []*GoogleCloudDialogflowCxV3beta1EventHandler `json:"eventHandlers,omitempty"`
5620
5621	// Form: The form associated with the page, used for collecting
5622	// parameters relevant to the page.
5623	Form *GoogleCloudDialogflowCxV3beta1Form `json:"form,omitempty"`
5624
5625	// Name: The unique identifier of the page. Required for the
5626	// Pages.UpdatePage method. Pages.CreatePage populates the name
5627	// automatically. Format: `projects//locations//agents//flows//pages/`.
5628	Name string `json:"name,omitempty"`
5629
5630	// TransitionRouteGroups: Ordered list of `TransitionRouteGroups`
5631	// associated with the page. Transition route groups must be unique
5632	// within a page. * If multiple transition routes within a page scope
5633	// refer to the same intent, then the precedence order is: page's
5634	// transition route -> page's transition route group -> flow's
5635	// transition routes. * If multiple transition route groups within a
5636	// page contain the same intent, then the first group in the ordered
5637	// list takes precedence.
5638	// Format:`projects//locations//agents//flows//transitionRouteGroups/`.
5639	TransitionRouteGroups []string `json:"transitionRouteGroups,omitempty"`
5640
5641	// TransitionRoutes: A list of transitions for the transition rules of
5642	// this page. They route the conversation to another page in the same
5643	// flow, or another flow. When we are in a certain page, the
5644	// TransitionRoutes are evalauted in the following order: *
5645	// TransitionRoutes defined in the page with intent specified. *
5646	// TransitionRoutes defined in the transition route groups with intent
5647	// specified. * TransitionRoutes defined in flow with intent specified.
5648	// * TransitionRoutes defined in the transition route groups with intent
5649	// specified. * TransitionRoutes defined in the page with only condition
5650	// specified. * TransitionRoutes defined in the transition route groups
5651	// with only condition specified.
5652	TransitionRoutes []*GoogleCloudDialogflowCxV3beta1TransitionRoute `json:"transitionRoutes,omitempty"`
5653
5654	// ForceSendFields is a list of field names (e.g. "DisplayName") to
5655	// unconditionally include in API requests. By default, fields with
5656	// empty or default values are omitted from API requests. However, any
5657	// non-pointer, non-interface field appearing in ForceSendFields will be
5658	// sent to the server regardless of whether the field is empty or not.
5659	// This may be used to include empty fields in Patch requests.
5660	ForceSendFields []string `json:"-"`
5661
5662	// NullFields is a list of field names (e.g. "DisplayName") to include
5663	// in API requests with the JSON null value. By default, fields with
5664	// empty values are omitted from API requests. However, any field with
5665	// an empty value appearing in NullFields will be sent to the server as
5666	// null. It is an error if a field in this list has a non-empty value.
5667	// This may be used to include null fields in Patch requests.
5668	NullFields []string `json:"-"`
5669}
5670
5671func (s *GoogleCloudDialogflowCxV3beta1Page) MarshalJSON() ([]byte, error) {
5672	type NoMethod GoogleCloudDialogflowCxV3beta1Page
5673	raw := NoMethod(*s)
5674	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
5675}
5676
5677// GoogleCloudDialogflowCxV3beta1PageInfo: Represents page information
5678// communicated to and from the webhook.
5679type GoogleCloudDialogflowCxV3beta1PageInfo struct {
5680	// CurrentPage: Always present for WebhookRequest. Ignored for
5681	// WebhookResponse. The unique identifier of the current page. Format:
5682	// `projects//locations//agents//flows//pages/`.
5683	CurrentPage string `json:"currentPage,omitempty"`
5684
5685	// FormInfo: Optional for both WebhookRequest and WebhookResponse.
5686	// Information about the form.
5687	FormInfo *GoogleCloudDialogflowCxV3beta1PageInfoFormInfo `json:"formInfo,omitempty"`
5688
5689	// ForceSendFields is a list of field names (e.g. "CurrentPage") to
5690	// unconditionally include in API requests. By default, fields with
5691	// empty or default values are omitted from API requests. However, any
5692	// non-pointer, non-interface field appearing in ForceSendFields will be
5693	// sent to the server regardless of whether the field is empty or not.
5694	// This may be used to include empty fields in Patch requests.
5695	ForceSendFields []string `json:"-"`
5696
5697	// NullFields is a list of field names (e.g. "CurrentPage") to include
5698	// in API requests with the JSON null value. By default, fields with
5699	// empty values are omitted from API requests. However, any field with
5700	// an empty value appearing in NullFields will be sent to the server as
5701	// null. It is an error if a field in this list has a non-empty value.
5702	// This may be used to include null fields in Patch requests.
5703	NullFields []string `json:"-"`
5704}
5705
5706func (s *GoogleCloudDialogflowCxV3beta1PageInfo) MarshalJSON() ([]byte, error) {
5707	type NoMethod GoogleCloudDialogflowCxV3beta1PageInfo
5708	raw := NoMethod(*s)
5709	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
5710}
5711
5712// GoogleCloudDialogflowCxV3beta1PageInfoFormInfo: Represents form
5713// information.
5714type GoogleCloudDialogflowCxV3beta1PageInfoFormInfo struct {
5715	// ParameterInfo: Optional for both WebhookRequest and WebhookResponse.
5716	// The parameters contained in the form. Note that the webhook cannot
5717	// add or remove any form parameter.
5718	ParameterInfo []*GoogleCloudDialogflowCxV3beta1PageInfoFormInfoParameterInfo `json:"parameterInfo,omitempty"`
5719
5720	// ForceSendFields is a list of field names (e.g. "ParameterInfo") to
5721	// unconditionally include in API requests. By default, fields with
5722	// empty or default values are omitted from API requests. However, any
5723	// non-pointer, non-interface field appearing in ForceSendFields will be
5724	// sent to the server regardless of whether the field is empty or not.
5725	// This may be used to include empty fields in Patch requests.
5726	ForceSendFields []string `json:"-"`
5727
5728	// NullFields is a list of field names (e.g. "ParameterInfo") to include
5729	// in API requests with the JSON null value. By default, fields with
5730	// empty values are omitted from API requests. However, any field with
5731	// an empty value appearing in NullFields will be sent to the server as
5732	// null. It is an error if a field in this list has a non-empty value.
5733	// This may be used to include null fields in Patch requests.
5734	NullFields []string `json:"-"`
5735}
5736
5737func (s *GoogleCloudDialogflowCxV3beta1PageInfoFormInfo) MarshalJSON() ([]byte, error) {
5738	type NoMethod GoogleCloudDialogflowCxV3beta1PageInfoFormInfo
5739	raw := NoMethod(*s)
5740	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
5741}
5742
5743// GoogleCloudDialogflowCxV3beta1PageInfoFormInfoParameterInfo:
5744// Represents parameter information.
5745type GoogleCloudDialogflowCxV3beta1PageInfoFormInfoParameterInfo struct {
5746	// DisplayName: Always present for WebhookRequest. Required for
5747	// WebhookResponse. The human-readable name of the parameter, unique
5748	// within the form. This field cannot be modified by the webhook.
5749	DisplayName string `json:"displayName,omitempty"`
5750
5751	// JustCollected: Optional for WebhookRequest. Ignored for
5752	// WebhookResponse. Indicates if the parameter value was just collected
5753	// on the last conversation turn.
5754	JustCollected bool `json:"justCollected,omitempty"`
5755
5756	// Required: Optional for both WebhookRequest and WebhookResponse.
5757	// Indicates whether the parameter is required. Optional parameters will
5758	// not trigger prompts; however, they are filled if the user specifies
5759	// them. Required parameters must be filled before form filling
5760	// concludes.
5761	Required bool `json:"required,omitempty"`
5762
5763	// State: Always present for WebhookRequest. Required for
5764	// WebhookResponse. The state of the parameter. This field can be set to
5765	// INVALID by the webhook to invalidate the parameter; other values set
5766	// by the webhook will be ignored.
5767	//
5768	// Possible values:
5769	//   "PARAMETER_STATE_UNSPECIFIED" - Not specified. This value should be
5770	// never used.
5771	//   "EMPTY" - Indicates that the parameter does not have a value.
5772	//   "INVALID" - Indicates that the parameter value is invalid. This
5773	// field can be used by the webhook to invalidate the parameter and ask
5774	// the server to collect it from the user again.
5775	//   "FILLED" - Indicates that the parameter has a value.
5776	State string `json:"state,omitempty"`
5777
5778	// Value: Optional for both WebhookRequest and WebhookResponse. The
5779	// value of the parameter. This field can be set by the webhook to
5780	// change the parameter value.
5781	Value interface{} `json:"value,omitempty"`
5782
5783	// ForceSendFields is a list of field names (e.g. "DisplayName") to
5784	// unconditionally include in API requests. By default, fields with
5785	// empty or default values are omitted from API requests. However, any
5786	// non-pointer, non-interface field appearing in ForceSendFields will be
5787	// sent to the server regardless of whether the field is empty or not.
5788	// This may be used to include empty fields in Patch requests.
5789	ForceSendFields []string `json:"-"`
5790
5791	// NullFields is a list of field names (e.g. "DisplayName") to include
5792	// in API requests with the JSON null value. By default, fields with
5793	// empty values are omitted from API requests. However, any field with
5794	// an empty value appearing in NullFields will be sent to the server as
5795	// null. It is an error if a field in this list has a non-empty value.
5796	// This may be used to include null fields in Patch requests.
5797	NullFields []string `json:"-"`
5798}
5799
5800func (s *GoogleCloudDialogflowCxV3beta1PageInfoFormInfoParameterInfo) MarshalJSON() ([]byte, error) {
5801	type NoMethod GoogleCloudDialogflowCxV3beta1PageInfoFormInfoParameterInfo
5802	raw := NoMethod(*s)
5803	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
5804}
5805
5806// GoogleCloudDialogflowCxV3beta1QueryInput: Represents the query input.
5807// It can contain one of: 1. A conversational query in the form of text.
5808// 2. An intent query that specifies which intent to trigger. 3. Natural
5809// language speech audio to be processed. 4. An event to be triggered.
5810type GoogleCloudDialogflowCxV3beta1QueryInput struct {
5811	// Audio: The natural language speech audio to be processed.
5812	Audio *GoogleCloudDialogflowCxV3beta1AudioInput `json:"audio,omitempty"`
5813
5814	// Dtmf: The DTMF event to be handled.
5815	Dtmf *GoogleCloudDialogflowCxV3beta1DtmfInput `json:"dtmf,omitempty"`
5816
5817	// Event: The event to be triggered.
5818	Event *GoogleCloudDialogflowCxV3beta1EventInput `json:"event,omitempty"`
5819
5820	// Intent: The intent to be triggered.
5821	Intent *GoogleCloudDialogflowCxV3beta1IntentInput `json:"intent,omitempty"`
5822
5823	// LanguageCode: Required. The language of the input. See Language
5824	// Support
5825	// (https://cloud.google.com/dialogflow/cx/docs/reference/language) for
5826	// a list of the currently supported language codes. Note that queries
5827	// in the same session do not necessarily need to specify the same
5828	// language.
5829	LanguageCode string `json:"languageCode,omitempty"`
5830
5831	// Text: The natural language text to be processed.
5832	Text *GoogleCloudDialogflowCxV3beta1TextInput `json:"text,omitempty"`
5833
5834	// ForceSendFields is a list of field names (e.g. "Audio") to
5835	// unconditionally include in API requests. By default, fields with
5836	// empty or default values are omitted from API requests. However, any
5837	// non-pointer, non-interface field appearing in ForceSendFields will be
5838	// sent to the server regardless of whether the field is empty or not.
5839	// This may be used to include empty fields in Patch requests.
5840	ForceSendFields []string `json:"-"`
5841
5842	// NullFields is a list of field names (e.g. "Audio") to include in API
5843	// requests with the JSON null value. By default, fields with empty
5844	// values are omitted from API requests. However, any field with an
5845	// empty value appearing in NullFields will be sent to the server as
5846	// null. It is an error if a field in this list has a non-empty value.
5847	// This may be used to include null fields in Patch requests.
5848	NullFields []string `json:"-"`
5849}
5850
5851func (s *GoogleCloudDialogflowCxV3beta1QueryInput) MarshalJSON() ([]byte, error) {
5852	type NoMethod GoogleCloudDialogflowCxV3beta1QueryInput
5853	raw := NoMethod(*s)
5854	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
5855}
5856
5857// GoogleCloudDialogflowCxV3beta1ReloadDocumentOperationMetadata:
5858// Metadata for ReloadDocument operation.
5859type GoogleCloudDialogflowCxV3beta1ReloadDocumentOperationMetadata struct {
5860	// GenericMetadata: The generic information of the operation.
5861	GenericMetadata *GoogleCloudDialogflowCxV3beta1GenericKnowledgeOperationMetadata `json:"genericMetadata,omitempty"`
5862
5863	// ForceSendFields is a list of field names (e.g. "GenericMetadata") to
5864	// unconditionally include in API requests. By default, fields with
5865	// empty or default values are omitted from API requests. However, any
5866	// non-pointer, non-interface field appearing in ForceSendFields will be
5867	// sent to the server regardless of whether the field is empty or not.
5868	// This may be used to include empty fields in Patch requests.
5869	ForceSendFields []string `json:"-"`
5870
5871	// NullFields is a list of field names (e.g. "GenericMetadata") to
5872	// include in API requests with the JSON null value. By default, fields
5873	// with empty values are omitted from API requests. However, any field
5874	// with an empty value appearing in NullFields will be sent to the
5875	// server as null. It is an error if a field in this list has a
5876	// non-empty value. This may be used to include null fields in Patch
5877	// requests.
5878	NullFields []string `json:"-"`
5879}
5880
5881func (s *GoogleCloudDialogflowCxV3beta1ReloadDocumentOperationMetadata) MarshalJSON() ([]byte, error) {
5882	type NoMethod GoogleCloudDialogflowCxV3beta1ReloadDocumentOperationMetadata
5883	raw := NoMethod(*s)
5884	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
5885}
5886
5887// GoogleCloudDialogflowCxV3beta1ResponseMessage: Represents a response
5888// message that can be returned by a conversational agent. Response
5889// messages are also used for output audio synthesis. The approach is as
5890// follows: * If at least one OutputAudioText response is present, then
5891// all OutputAudioText responses are linearly concatenated, and the
5892// result is used for output audio synthesis. * If the OutputAudioText
5893// responses are a mixture of text and SSML, then the concatenated
5894// result is treated as SSML; otherwise, the result is treated as either
5895// text or SSML as appropriate. The agent designer should ideally use
5896// either text or SSML consistently throughout the bot design. *
5897// Otherwise, all Text responses are linearly concatenated, and the
5898// result is used for output audio synthesis. This approach allows for
5899// more sophisticated user experience scenarios, where the text
5900// displayed to the user may differ from what is heard.
5901type GoogleCloudDialogflowCxV3beta1ResponseMessage struct {
5902	// ConversationSuccess: Indicates that the conversation succeeded.
5903	ConversationSuccess *GoogleCloudDialogflowCxV3beta1ResponseMessageConversationSuccess `json:"conversationSuccess,omitempty"`
5904
5905	// EndInteraction: Output only. A signal that indicates the interaction
5906	// with the Dialogflow agent has ended. This message is generated by
5907	// Dialogflow only when the conversation reaches `END_SESSION` page. It
5908	// is not supposed to be defined by the user. It's guaranteed that there
5909	// is at most one such message in each response.
5910	EndInteraction *GoogleCloudDialogflowCxV3beta1ResponseMessageEndInteraction `json:"endInteraction,omitempty"`
5911
5912	// LiveAgentHandoff: Hands off conversation to a human agent.
5913	LiveAgentHandoff *GoogleCloudDialogflowCxV3beta1ResponseMessageLiveAgentHandoff `json:"liveAgentHandoff,omitempty"`
5914
5915	// MixedAudio: Output only. An audio response message composed of both
5916	// the synthesized Dialogflow agent responses and responses defined via
5917	// play_audio. This message is generated by Dialogflow only and not
5918	// supposed to be defined by the user.
5919	MixedAudio *GoogleCloudDialogflowCxV3beta1ResponseMessageMixedAudio `json:"mixedAudio,omitempty"`
5920
5921	// OutputAudioText: A text or ssml response that is preferentially used
5922	// for TTS output audio synthesis, as described in the comment on the
5923	// ResponseMessage message.
5924	OutputAudioText *GoogleCloudDialogflowCxV3beta1ResponseMessageOutputAudioText `json:"outputAudioText,omitempty"`
5925
5926	// Payload: Returns a response containing a custom, platform-specific
5927	// payload.
5928	Payload googleapi.RawMessage `json:"payload,omitempty"`
5929
5930	// PlayAudio: Signal that the client should play an audio clip hosted at
5931	// a client-specific URI. Dialogflow uses this to construct mixed_audio.
5932	// However, Dialogflow itself does not try to read or process the URI in
5933	// any way.
5934	PlayAudio *GoogleCloudDialogflowCxV3beta1ResponseMessagePlayAudio `json:"playAudio,omitempty"`
5935
5936	// Text: Returns a text response.
5937	Text *GoogleCloudDialogflowCxV3beta1ResponseMessageText `json:"text,omitempty"`
5938
5939	// ForceSendFields is a list of field names (e.g. "ConversationSuccess")
5940	// to unconditionally include in API requests. By default, fields with
5941	// empty or default values are omitted from API requests. However, any
5942	// non-pointer, non-interface field appearing in ForceSendFields will be
5943	// sent to the server regardless of whether the field is empty or not.
5944	// This may be used to include empty fields in Patch requests.
5945	ForceSendFields []string `json:"-"`
5946
5947	// NullFields is a list of field names (e.g. "ConversationSuccess") to
5948	// include in API requests with the JSON null value. By default, fields
5949	// with empty values are omitted from API requests. However, any field
5950	// with an empty value appearing in NullFields will be sent to the
5951	// server as null. It is an error if a field in this list has a
5952	// non-empty value. This may be used to include null fields in Patch
5953	// requests.
5954	NullFields []string `json:"-"`
5955}
5956
5957func (s *GoogleCloudDialogflowCxV3beta1ResponseMessage) MarshalJSON() ([]byte, error) {
5958	type NoMethod GoogleCloudDialogflowCxV3beta1ResponseMessage
5959	raw := NoMethod(*s)
5960	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
5961}
5962
5963// GoogleCloudDialogflowCxV3beta1ResponseMessageConversationSuccess:
5964// Indicates that the conversation succeeded, i.e., the bot handled the
5965// issue that the customer talked to it about. Dialogflow only uses this
5966// to determine which conversations should be counted as successful and
5967// doesn't process the metadata in this message in any way. Note that
5968// Dialogflow also considers conversations that get to the conversation
5969// end page as successful even if they don't return ConversationSuccess.
5970// You may set this, for example: * In the entry_fulfillment of a Page
5971// if entering the page indicates that the conversation succeeded. * In
5972// a webhook response when you determine that you handled the customer
5973// issue.
5974type GoogleCloudDialogflowCxV3beta1ResponseMessageConversationSuccess struct {
5975	// Metadata: Custom metadata. Dialogflow doesn't impose any structure on
5976	// this.
5977	Metadata googleapi.RawMessage `json:"metadata,omitempty"`
5978
5979	// ForceSendFields is a list of field names (e.g. "Metadata") to
5980	// unconditionally include in API requests. By default, fields with
5981	// empty or default values are omitted from API requests. However, any
5982	// non-pointer, non-interface field appearing in ForceSendFields will be
5983	// sent to the server regardless of whether the field is empty or not.
5984	// This may be used to include empty fields in Patch requests.
5985	ForceSendFields []string `json:"-"`
5986
5987	// NullFields is a list of field names (e.g. "Metadata") to include in
5988	// API requests with the JSON null value. By default, fields with empty
5989	// values are omitted from API requests. However, any field with an
5990	// empty value appearing in NullFields will be sent to the server as
5991	// null. It is an error if a field in this list has a non-empty value.
5992	// This may be used to include null fields in Patch requests.
5993	NullFields []string `json:"-"`
5994}
5995
5996func (s *GoogleCloudDialogflowCxV3beta1ResponseMessageConversationSuccess) MarshalJSON() ([]byte, error) {
5997	type NoMethod GoogleCloudDialogflowCxV3beta1ResponseMessageConversationSuccess
5998	raw := NoMethod(*s)
5999	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
6000}
6001
6002// GoogleCloudDialogflowCxV3beta1ResponseMessageEndInteraction:
6003// Indicates that interaction with the Dialogflow agent has ended. This
6004// message is generated by Dialogflow only and not supposed to be
6005// defined by the user.
6006type GoogleCloudDialogflowCxV3beta1ResponseMessageEndInteraction struct {
6007}
6008
6009// GoogleCloudDialogflowCxV3beta1ResponseMessageLiveAgentHandoff:
6010// Indicates that the conversation should be handed off to a live agent.
6011// Dialogflow only uses this to determine which conversations were
6012// handed off to a human agent for measurement purposes. What else to do
6013// with this signal is up to you and your handoff procedures. You may
6014// set this, for example: * In the entry_fulfillment of a Page if
6015// entering the page indicates something went extremely wrong in the
6016// conversation. * In a webhook response when you determine that the
6017// customer issue can only be handled by a human.
6018type GoogleCloudDialogflowCxV3beta1ResponseMessageLiveAgentHandoff struct {
6019	// Metadata: Custom metadata for your handoff procedure. Dialogflow
6020	// doesn't impose any structure on this.
6021	Metadata googleapi.RawMessage `json:"metadata,omitempty"`
6022
6023	// ForceSendFields is a list of field names (e.g. "Metadata") to
6024	// unconditionally include in API requests. By default, fields with
6025	// empty or default values are omitted from API requests. However, any
6026	// non-pointer, non-interface field appearing in ForceSendFields will be
6027	// sent to the server regardless of whether the field is empty or not.
6028	// This may be used to include empty fields in Patch requests.
6029	ForceSendFields []string `json:"-"`
6030
6031	// NullFields is a list of field names (e.g. "Metadata") to include in
6032	// API requests with the JSON null value. By default, fields with empty
6033	// values are omitted from API requests. However, any field with an
6034	// empty value appearing in NullFields will be sent to the server as
6035	// null. It is an error if a field in this list has a non-empty value.
6036	// This may be used to include null fields in Patch requests.
6037	NullFields []string `json:"-"`
6038}
6039
6040func (s *GoogleCloudDialogflowCxV3beta1ResponseMessageLiveAgentHandoff) MarshalJSON() ([]byte, error) {
6041	type NoMethod GoogleCloudDialogflowCxV3beta1ResponseMessageLiveAgentHandoff
6042	raw := NoMethod(*s)
6043	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
6044}
6045
6046// GoogleCloudDialogflowCxV3beta1ResponseMessageMixedAudio: Represents
6047// an audio message that is composed of both segments synthesized from
6048// the Dialogflow agent prompts and ones hosted externally at the
6049// specified URIs. The external URIs are specified via play_audio. This
6050// message is generated by Dialogflow only and not supposed to be
6051// defined by the user.
6052type GoogleCloudDialogflowCxV3beta1ResponseMessageMixedAudio struct {
6053	// Segments: Segments this audio response is composed of.
6054	Segments []*GoogleCloudDialogflowCxV3beta1ResponseMessageMixedAudioSegment `json:"segments,omitempty"`
6055
6056	// ForceSendFields is a list of field names (e.g. "Segments") to
6057	// unconditionally include in API requests. By default, fields with
6058	// empty or default values are omitted from API requests. However, any
6059	// non-pointer, non-interface field appearing in ForceSendFields will be
6060	// sent to the server regardless of whether the field is empty or not.
6061	// This may be used to include empty fields in Patch requests.
6062	ForceSendFields []string `json:"-"`
6063
6064	// NullFields is a list of field names (e.g. "Segments") to include in
6065	// API requests with the JSON null value. By default, fields with empty
6066	// values are omitted from API requests. However, any field with an
6067	// empty value appearing in NullFields will be sent to the server as
6068	// null. It is an error if a field in this list has a non-empty value.
6069	// This may be used to include null fields in Patch requests.
6070	NullFields []string `json:"-"`
6071}
6072
6073func (s *GoogleCloudDialogflowCxV3beta1ResponseMessageMixedAudio) MarshalJSON() ([]byte, error) {
6074	type NoMethod GoogleCloudDialogflowCxV3beta1ResponseMessageMixedAudio
6075	raw := NoMethod(*s)
6076	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
6077}
6078
6079// GoogleCloudDialogflowCxV3beta1ResponseMessageMixedAudioSegment:
6080// Represents one segment of audio.
6081type GoogleCloudDialogflowCxV3beta1ResponseMessageMixedAudioSegment struct {
6082	// AllowPlaybackInterruption: Output only. Whether the playback of this
6083	// segment can be interrupted by the end user's speech and the client
6084	// should then start the next Dialogflow request.
6085	AllowPlaybackInterruption bool `json:"allowPlaybackInterruption,omitempty"`
6086
6087	// Audio: Raw audio synthesized from the Dialogflow agent's response
6088	// using the output config specified in the request.
6089	Audio string `json:"audio,omitempty"`
6090
6091	// Uri: Client-specific URI that points to an audio clip accessible to
6092	// the client. Dialogflow does not impose any validation on it.
6093	Uri string `json:"uri,omitempty"`
6094
6095	// ForceSendFields is a list of field names (e.g.
6096	// "AllowPlaybackInterruption") to unconditionally include in API
6097	// requests. By default, fields with empty or default values are omitted
6098	// from API requests. However, any non-pointer, non-interface field
6099	// appearing in ForceSendFields will be sent to the server regardless of
6100	// whether the field is empty or not. This may be used to include empty
6101	// fields in Patch requests.
6102	ForceSendFields []string `json:"-"`
6103
6104	// NullFields is a list of field names (e.g.
6105	// "AllowPlaybackInterruption") to include in API requests with the JSON
6106	// null value. By default, fields with empty values are omitted from API
6107	// requests. However, any field with an empty value appearing in
6108	// NullFields will be sent to the server as null. It is an error if a
6109	// field in this list has a non-empty value. This may be used to include
6110	// null fields in Patch requests.
6111	NullFields []string `json:"-"`
6112}
6113
6114func (s *GoogleCloudDialogflowCxV3beta1ResponseMessageMixedAudioSegment) MarshalJSON() ([]byte, error) {
6115	type NoMethod GoogleCloudDialogflowCxV3beta1ResponseMessageMixedAudioSegment
6116	raw := NoMethod(*s)
6117	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
6118}
6119
6120// GoogleCloudDialogflowCxV3beta1ResponseMessageOutputAudioText: A text
6121// or ssml response that is preferentially used for TTS output audio
6122// synthesis, as described in the comment on the ResponseMessage
6123// message.
6124type GoogleCloudDialogflowCxV3beta1ResponseMessageOutputAudioText struct {
6125	// AllowPlaybackInterruption: Output only. Whether the playback of this
6126	// message can be interrupted by the end user's speech and the client
6127	// can then starts the next Dialogflow request.
6128	AllowPlaybackInterruption bool `json:"allowPlaybackInterruption,omitempty"`
6129
6130	// Ssml: The SSML text to be synthesized. For more information, see SSML
6131	// (/speech/text-to-speech/docs/ssml).
6132	Ssml string `json:"ssml,omitempty"`
6133
6134	// Text: The raw text to be synthesized.
6135	Text string `json:"text,omitempty"`
6136
6137	// ForceSendFields is a list of field names (e.g.
6138	// "AllowPlaybackInterruption") to unconditionally include in API
6139	// requests. By default, fields with empty or default values are omitted
6140	// from API requests. However, any non-pointer, non-interface field
6141	// appearing in ForceSendFields will be sent to the server regardless of
6142	// whether the field is empty or not. This may be used to include empty
6143	// fields in Patch requests.
6144	ForceSendFields []string `json:"-"`
6145
6146	// NullFields is a list of field names (e.g.
6147	// "AllowPlaybackInterruption") to include in API requests with the JSON
6148	// null value. By default, fields with empty values are omitted from API
6149	// requests. However, any field with an empty value appearing in
6150	// NullFields will be sent to the server as null. It is an error if a
6151	// field in this list has a non-empty value. This may be used to include
6152	// null fields in Patch requests.
6153	NullFields []string `json:"-"`
6154}
6155
6156func (s *GoogleCloudDialogflowCxV3beta1ResponseMessageOutputAudioText) MarshalJSON() ([]byte, error) {
6157	type NoMethod GoogleCloudDialogflowCxV3beta1ResponseMessageOutputAudioText
6158	raw := NoMethod(*s)
6159	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
6160}
6161
6162// GoogleCloudDialogflowCxV3beta1ResponseMessagePlayAudio: Specifies an
6163// audio clip to be played by the client as part of the response.
6164type GoogleCloudDialogflowCxV3beta1ResponseMessagePlayAudio struct {
6165	// AllowPlaybackInterruption: Output only. Whether the playback of this
6166	// message can be interrupted by the end user's speech and the client
6167	// can then starts the next Dialogflow request.
6168	AllowPlaybackInterruption bool `json:"allowPlaybackInterruption,omitempty"`
6169
6170	// AudioUri: Required. URI of the audio clip. Dialogflow does not impose
6171	// any validation on this value. It is specific to the client that reads
6172	// it.
6173	AudioUri string `json:"audioUri,omitempty"`
6174
6175	// ForceSendFields is a list of field names (e.g.
6176	// "AllowPlaybackInterruption") to unconditionally include in API
6177	// requests. By default, fields with empty or default values are omitted
6178	// from API requests. However, any non-pointer, non-interface field
6179	// appearing in ForceSendFields will be sent to the server regardless of
6180	// whether the field is empty or not. This may be used to include empty
6181	// fields in Patch requests.
6182	ForceSendFields []string `json:"-"`
6183
6184	// NullFields is a list of field names (e.g.
6185	// "AllowPlaybackInterruption") to include in API requests with the JSON
6186	// null value. By default, fields with empty values are omitted from API
6187	// requests. However, any field with an empty value appearing in
6188	// NullFields will be sent to the server as null. It is an error if a
6189	// field in this list has a non-empty value. This may be used to include
6190	// null fields in Patch requests.
6191	NullFields []string `json:"-"`
6192}
6193
6194func (s *GoogleCloudDialogflowCxV3beta1ResponseMessagePlayAudio) MarshalJSON() ([]byte, error) {
6195	type NoMethod GoogleCloudDialogflowCxV3beta1ResponseMessagePlayAudio
6196	raw := NoMethod(*s)
6197	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
6198}
6199
6200// GoogleCloudDialogflowCxV3beta1ResponseMessageText: The text response
6201// message.
6202type GoogleCloudDialogflowCxV3beta1ResponseMessageText struct {
6203	// AllowPlaybackInterruption: Output only. Whether the playback of this
6204	// message can be interrupted by the end user's speech and the client
6205	// can then starts the next Dialogflow request.
6206	AllowPlaybackInterruption bool `json:"allowPlaybackInterruption,omitempty"`
6207
6208	// Text: Required. A collection of text responses.
6209	Text []string `json:"text,omitempty"`
6210
6211	// ForceSendFields is a list of field names (e.g.
6212	// "AllowPlaybackInterruption") to unconditionally include in API
6213	// requests. By default, fields with empty or default values are omitted
6214	// from API requests. However, any non-pointer, non-interface field
6215	// appearing in ForceSendFields will be sent to the server regardless of
6216	// whether the field is empty or not. This may be used to include empty
6217	// fields in Patch requests.
6218	ForceSendFields []string `json:"-"`
6219
6220	// NullFields is a list of field names (e.g.
6221	// "AllowPlaybackInterruption") to include in API requests with the JSON
6222	// null value. By default, fields with empty values are omitted from API
6223	// requests. However, any field with an empty value appearing in
6224	// NullFields will be sent to the server as null. It is an error if a
6225	// field in this list has a non-empty value. This may be used to include
6226	// null fields in Patch requests.
6227	NullFields []string `json:"-"`
6228}
6229
6230func (s *GoogleCloudDialogflowCxV3beta1ResponseMessageText) MarshalJSON() ([]byte, error) {
6231	type NoMethod GoogleCloudDialogflowCxV3beta1ResponseMessageText
6232	raw := NoMethod(*s)
6233	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
6234}
6235
6236// GoogleCloudDialogflowCxV3beta1RunContinuousTestMetadata: Metadata
6237// returned for the Environments.RunContinuousTest long running
6238// operation.
6239type GoogleCloudDialogflowCxV3beta1RunContinuousTestMetadata struct {
6240	// Errors: The test errors.
6241	Errors []*GoogleCloudDialogflowCxV3beta1TestError `json:"errors,omitempty"`
6242
6243	// ForceSendFields is a list of field names (e.g. "Errors") to
6244	// unconditionally include in API requests. By default, fields with
6245	// empty or default values are omitted from API requests. However, any
6246	// non-pointer, non-interface field appearing in ForceSendFields will be
6247	// sent to the server regardless of whether the field is empty or not.
6248	// This may be used to include empty fields in Patch requests.
6249	ForceSendFields []string `json:"-"`
6250
6251	// NullFields is a list of field names (e.g. "Errors") to include in API
6252	// requests with the JSON null value. By default, fields with empty
6253	// values are omitted from API requests. However, any field with an
6254	// empty value appearing in NullFields will be sent to the server as
6255	// null. It is an error if a field in this list has a non-empty value.
6256	// This may be used to include null fields in Patch requests.
6257	NullFields []string `json:"-"`
6258}
6259
6260func (s *GoogleCloudDialogflowCxV3beta1RunContinuousTestMetadata) MarshalJSON() ([]byte, error) {
6261	type NoMethod GoogleCloudDialogflowCxV3beta1RunContinuousTestMetadata
6262	raw := NoMethod(*s)
6263	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
6264}
6265
6266// GoogleCloudDialogflowCxV3beta1RunContinuousTestResponse: The response
6267// message for Environments.RunContinuousTest.
6268type GoogleCloudDialogflowCxV3beta1RunContinuousTestResponse struct {
6269	// ContinuousTestResult: The result for a continuous test run.
6270	ContinuousTestResult *GoogleCloudDialogflowCxV3beta1ContinuousTestResult `json:"continuousTestResult,omitempty"`
6271
6272	// ForceSendFields is a list of field names (e.g.
6273	// "ContinuousTestResult") to unconditionally include in API requests.
6274	// By default, fields with empty or default values are omitted from API
6275	// requests. However, any non-pointer, non-interface field appearing in
6276	// ForceSendFields will be sent to the server regardless of whether the
6277	// field is empty or not. This may be used to include empty fields in
6278	// Patch requests.
6279	ForceSendFields []string `json:"-"`
6280
6281	// NullFields is a list of field names (e.g. "ContinuousTestResult") to
6282	// include in API requests with the JSON null value. By default, fields
6283	// with empty values are omitted from API requests. However, any field
6284	// with an empty value appearing in NullFields will be sent to the
6285	// server as null. It is an error if a field in this list has a
6286	// non-empty value. This may be used to include null fields in Patch
6287	// requests.
6288	NullFields []string `json:"-"`
6289}
6290
6291func (s *GoogleCloudDialogflowCxV3beta1RunContinuousTestResponse) MarshalJSON() ([]byte, error) {
6292	type NoMethod GoogleCloudDialogflowCxV3beta1RunContinuousTestResponse
6293	raw := NoMethod(*s)
6294	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
6295}
6296
6297// GoogleCloudDialogflowCxV3beta1RunTestCaseMetadata: Metadata returned
6298// for the TestCases.RunTestCase long running operation. This message
6299// currently has no fields.
6300type GoogleCloudDialogflowCxV3beta1RunTestCaseMetadata struct {
6301}
6302
6303// GoogleCloudDialogflowCxV3beta1RunTestCaseResponse: The response
6304// message for TestCases.RunTestCase.
6305type GoogleCloudDialogflowCxV3beta1RunTestCaseResponse struct {
6306	// Result: The result.
6307	Result *GoogleCloudDialogflowCxV3beta1TestCaseResult `json:"result,omitempty"`
6308
6309	// ForceSendFields is a list of field names (e.g. "Result") to
6310	// unconditionally include in API requests. By default, fields with
6311	// empty or default values are omitted from API requests. However, any
6312	// non-pointer, non-interface field appearing in ForceSendFields will be
6313	// sent to the server regardless of whether the field is empty or not.
6314	// This may be used to include empty fields in Patch requests.
6315	ForceSendFields []string `json:"-"`
6316
6317	// NullFields is a list of field names (e.g. "Result") to include in API
6318	// requests with the JSON null value. By default, fields with empty
6319	// values are omitted from API requests. However, any field with an
6320	// empty value appearing in NullFields will be sent to the server as
6321	// null. It is an error if a field in this list has a non-empty value.
6322	// This may be used to include null fields in Patch requests.
6323	NullFields []string `json:"-"`
6324}
6325
6326func (s *GoogleCloudDialogflowCxV3beta1RunTestCaseResponse) MarshalJSON() ([]byte, error) {
6327	type NoMethod GoogleCloudDialogflowCxV3beta1RunTestCaseResponse
6328	raw := NoMethod(*s)
6329	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
6330}
6331
6332// GoogleCloudDialogflowCxV3beta1SessionInfo: Represents session
6333// information communicated to and from the webhook.
6334type GoogleCloudDialogflowCxV3beta1SessionInfo struct {
6335	// Parameters: Optional for WebhookRequest. Optional for
6336	// WebhookResponse. All parameters collected from forms and intents
6337	// during the session. Parameters can be created, updated, or removed by
6338	// the webhook. To remove a parameter from the session, the webhook
6339	// should explicitly set the parameter value to null in WebhookResponse.
6340	// The map is keyed by parameters' display names.
6341	Parameters googleapi.RawMessage `json:"parameters,omitempty"`
6342
6343	// Session: Always present for WebhookRequest. Ignored for
6344	// WebhookResponse. The unique identifier of the session. This field can
6345	// be used by the webhook to identify a session. Format:
6346	// `projects//locations//agents//sessions/` or
6347	// `projects//locations//agents//environments//sessions/` if environment
6348	// is specified.
6349	Session string `json:"session,omitempty"`
6350
6351	// ForceSendFields is a list of field names (e.g. "Parameters") to
6352	// unconditionally include in API requests. By default, fields with
6353	// empty or default values are omitted from API requests. However, any
6354	// non-pointer, non-interface field appearing in ForceSendFields will be
6355	// sent to the server regardless of whether the field is empty or not.
6356	// This may be used to include empty fields in Patch requests.
6357	ForceSendFields []string `json:"-"`
6358
6359	// NullFields is a list of field names (e.g. "Parameters") to include in
6360	// API requests with the JSON null value. By default, fields with empty
6361	// values are omitted from API requests. However, any field with an
6362	// empty value appearing in NullFields will be sent to the server as
6363	// null. It is an error if a field in this list has a non-empty value.
6364	// This may be used to include null fields in Patch requests.
6365	NullFields []string `json:"-"`
6366}
6367
6368func (s *GoogleCloudDialogflowCxV3beta1SessionInfo) MarshalJSON() ([]byte, error) {
6369	type NoMethod GoogleCloudDialogflowCxV3beta1SessionInfo
6370	raw := NoMethod(*s)
6371	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
6372}
6373
6374// GoogleCloudDialogflowCxV3beta1TestCase: Represents a test case.
6375type GoogleCloudDialogflowCxV3beta1TestCase struct {
6376	// CreationTime: Output only. When the test was created.
6377	CreationTime string `json:"creationTime,omitempty"`
6378
6379	// DisplayName: Required. The human-readable name of the test case,
6380	// unique within the agent. Limit of 200 characters.
6381	DisplayName string `json:"displayName,omitempty"`
6382
6383	// LastTestResult: The latest test result.
6384	LastTestResult *GoogleCloudDialogflowCxV3beta1TestCaseResult `json:"lastTestResult,omitempty"`
6385
6386	// Name: The unique identifier of the test case.
6387	// TestCases.CreateTestCase will populate the name automatically.
6388	// Otherwise use format: `projects//locations//agents/ /testCases/`.
6389	Name string `json:"name,omitempty"`
6390
6391	// Notes: Additional freeform notes about the test case. Limit of 400
6392	// characters.
6393	Notes string `json:"notes,omitempty"`
6394
6395	// Tags: Tags are short descriptions that users may apply to test cases
6396	// for organizational and filtering purposes. Each tag should start with
6397	// "#" and has a limit of 30 characters.
6398	Tags []string `json:"tags,omitempty"`
6399
6400	// TestCaseConversationTurns: The conversation turns uttered when the
6401	// test case was created, in chronological order. These include the
6402	// canonical set of agent utterances that should occur when the agent is
6403	// working properly.
6404	TestCaseConversationTurns []*GoogleCloudDialogflowCxV3beta1ConversationTurn `json:"testCaseConversationTurns,omitempty"`
6405
6406	// TestConfig: Config for the test case.
6407	TestConfig *GoogleCloudDialogflowCxV3beta1TestConfig `json:"testConfig,omitempty"`
6408
6409	// ForceSendFields is a list of field names (e.g. "CreationTime") to
6410	// unconditionally include in API requests. By default, fields with
6411	// empty or default values are omitted from API requests. However, any
6412	// non-pointer, non-interface field appearing in ForceSendFields will be
6413	// sent to the server regardless of whether the field is empty or not.
6414	// This may be used to include empty fields in Patch requests.
6415	ForceSendFields []string `json:"-"`
6416
6417	// NullFields is a list of field names (e.g. "CreationTime") to include
6418	// in API requests with the JSON null value. By default, fields with
6419	// empty values are omitted from API requests. However, any field with
6420	// an empty value appearing in NullFields will be sent to the server as
6421	// null. It is an error if a field in this list has a non-empty value.
6422	// This may be used to include null fields in Patch requests.
6423	NullFields []string `json:"-"`
6424}
6425
6426func (s *GoogleCloudDialogflowCxV3beta1TestCase) MarshalJSON() ([]byte, error) {
6427	type NoMethod GoogleCloudDialogflowCxV3beta1TestCase
6428	raw := NoMethod(*s)
6429	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
6430}
6431
6432// GoogleCloudDialogflowCxV3beta1TestCaseError: Error info for importing
6433// a test.
6434type GoogleCloudDialogflowCxV3beta1TestCaseError struct {
6435	// Status: The status associated with the test case.
6436	Status *GoogleRpcStatus `json:"status,omitempty"`
6437
6438	// TestCase: The test case.
6439	TestCase *GoogleCloudDialogflowCxV3beta1TestCase `json:"testCase,omitempty"`
6440
6441	// ForceSendFields is a list of field names (e.g. "Status") to
6442	// unconditionally include in API requests. By default, fields with
6443	// empty or default values are omitted from API requests. However, any
6444	// non-pointer, non-interface field appearing in ForceSendFields will be
6445	// sent to the server regardless of whether the field is empty or not.
6446	// This may be used to include empty fields in Patch requests.
6447	ForceSendFields []string `json:"-"`
6448
6449	// NullFields is a list of field names (e.g. "Status") to include in API
6450	// requests with the JSON null value. By default, fields with empty
6451	// values are omitted from API requests. However, any field with an
6452	// empty value appearing in NullFields will be sent to the server as
6453	// null. It is an error if a field in this list has a non-empty value.
6454	// This may be used to include null fields in Patch requests.
6455	NullFields []string `json:"-"`
6456}
6457
6458func (s *GoogleCloudDialogflowCxV3beta1TestCaseError) MarshalJSON() ([]byte, error) {
6459	type NoMethod GoogleCloudDialogflowCxV3beta1TestCaseError
6460	raw := NoMethod(*s)
6461	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
6462}
6463
6464// GoogleCloudDialogflowCxV3beta1TestCaseResult: Represents a result
6465// from running a test case in an agent environment.
6466type GoogleCloudDialogflowCxV3beta1TestCaseResult struct {
6467	// ConversationTurns: The conversation turns uttered during the test
6468	// case replay in chronological order.
6469	ConversationTurns []*GoogleCloudDialogflowCxV3beta1ConversationTurn `json:"conversationTurns,omitempty"`
6470
6471	// Environment: Environment where the test was run. If not set, it
6472	// indicates the draft environment.
6473	Environment string `json:"environment,omitempty"`
6474
6475	// Name: The resource name for the test case result. Format:
6476	// `projects//locations//agents//testCases/ /results/`.
6477	Name string `json:"name,omitempty"`
6478
6479	// TestResult: Whether the test case passed in the agent environment.
6480	//
6481	// Possible values:
6482	//   "TEST_RESULT_UNSPECIFIED" - Not specified. Should never be used.
6483	//   "PASSED" - The test passed.
6484	//   "FAILED" - The test did not pass.
6485	TestResult string `json:"testResult,omitempty"`
6486
6487	// TestTime: The time that the test was run.
6488	TestTime string `json:"testTime,omitempty"`
6489
6490	// ForceSendFields is a list of field names (e.g. "ConversationTurns")
6491	// to unconditionally include in API requests. By default, fields with
6492	// empty or default values are omitted from API requests. However, any
6493	// non-pointer, non-interface field appearing in ForceSendFields will be
6494	// sent to the server regardless of whether the field is empty or not.
6495	// This may be used to include empty fields in Patch requests.
6496	ForceSendFields []string `json:"-"`
6497
6498	// NullFields is a list of field names (e.g. "ConversationTurns") to
6499	// include in API requests with the JSON null value. By default, fields
6500	// with empty values are omitted from API requests. However, any field
6501	// with an empty value appearing in NullFields will be sent to the
6502	// server as null. It is an error if a field in this list has a
6503	// non-empty value. This may be used to include null fields in Patch
6504	// requests.
6505	NullFields []string `json:"-"`
6506}
6507
6508func (s *GoogleCloudDialogflowCxV3beta1TestCaseResult) MarshalJSON() ([]byte, error) {
6509	type NoMethod GoogleCloudDialogflowCxV3beta1TestCaseResult
6510	raw := NoMethod(*s)
6511	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
6512}
6513
6514// GoogleCloudDialogflowCxV3beta1TestConfig: Represents configurations
6515// for a test case.
6516type GoogleCloudDialogflowCxV3beta1TestConfig struct {
6517	// Flow: Flow name. If not set, default start flow is assumed. Format:
6518	// `projects//locations//agents//flows/`.
6519	Flow string `json:"flow,omitempty"`
6520
6521	// TrackingParameters: Session parameters to be compared when
6522	// calculating differences.
6523	TrackingParameters []string `json:"trackingParameters,omitempty"`
6524
6525	// ForceSendFields is a list of field names (e.g. "Flow") to
6526	// unconditionally include in API requests. By default, fields with
6527	// empty or default values are omitted from API requests. However, any
6528	// non-pointer, non-interface field appearing in ForceSendFields will be
6529	// sent to the server regardless of whether the field is empty or not.
6530	// This may be used to include empty fields in Patch requests.
6531	ForceSendFields []string `json:"-"`
6532
6533	// NullFields is a list of field names (e.g. "Flow") to include in API
6534	// requests with the JSON null value. By default, fields with empty
6535	// values are omitted from API requests. However, any field with an
6536	// empty value appearing in NullFields will be sent to the server as
6537	// null. It is an error if a field in this list has a non-empty value.
6538	// This may be used to include null fields in Patch requests.
6539	NullFields []string `json:"-"`
6540}
6541
6542func (s *GoogleCloudDialogflowCxV3beta1TestConfig) MarshalJSON() ([]byte, error) {
6543	type NoMethod GoogleCloudDialogflowCxV3beta1TestConfig
6544	raw := NoMethod(*s)
6545	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
6546}
6547
6548// GoogleCloudDialogflowCxV3beta1TestError: Error info for running a
6549// test.
6550type GoogleCloudDialogflowCxV3beta1TestError struct {
6551	// Status: The status associated with the test.
6552	Status *GoogleRpcStatus `json:"status,omitempty"`
6553
6554	// TestCase: The test case resource name.
6555	TestCase string `json:"testCase,omitempty"`
6556
6557	// TestTime: The timestamp when the test was completed.
6558	TestTime string `json:"testTime,omitempty"`
6559
6560	// ForceSendFields is a list of field names (e.g. "Status") to
6561	// unconditionally include in API requests. By default, fields with
6562	// empty or default values are omitted from API requests. However, any
6563	// non-pointer, non-interface field appearing in ForceSendFields will be
6564	// sent to the server regardless of whether the field is empty or not.
6565	// This may be used to include empty fields in Patch requests.
6566	ForceSendFields []string `json:"-"`
6567
6568	// NullFields is a list of field names (e.g. "Status") to include in API
6569	// requests with the JSON null value. By default, fields with empty
6570	// values are omitted from API requests. However, any field with an
6571	// empty value appearing in NullFields will be sent to the server as
6572	// null. It is an error if a field in this list has a non-empty value.
6573	// This may be used to include null fields in Patch requests.
6574	NullFields []string `json:"-"`
6575}
6576
6577func (s *GoogleCloudDialogflowCxV3beta1TestError) MarshalJSON() ([]byte, error) {
6578	type NoMethod GoogleCloudDialogflowCxV3beta1TestError
6579	raw := NoMethod(*s)
6580	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
6581}
6582
6583// GoogleCloudDialogflowCxV3beta1TestRunDifference: The description of
6584// differences between original and replayed agent output.
6585type GoogleCloudDialogflowCxV3beta1TestRunDifference struct {
6586	// Description: A description of the diff, showing the actual output vs
6587	// expected output.
6588	Description string `json:"description,omitempty"`
6589
6590	// Type: The type of diff.
6591	//
6592	// Possible values:
6593	//   "DIFF_TYPE_UNSPECIFIED" - Should never be used.
6594	//   "INTENT" - The intent.
6595	//   "PAGE" - The page.
6596	//   "PARAMETERS" - The parameters.
6597	//   "UTTERANCE" - The message utterance.
6598	Type string `json:"type,omitempty"`
6599
6600	// ForceSendFields is a list of field names (e.g. "Description") to
6601	// unconditionally include in API requests. By default, fields with
6602	// empty or default values are omitted from API requests. However, any
6603	// non-pointer, non-interface field appearing in ForceSendFields will be
6604	// sent to the server regardless of whether the field is empty or not.
6605	// This may be used to include empty fields in Patch requests.
6606	ForceSendFields []string `json:"-"`
6607
6608	// NullFields is a list of field names (e.g. "Description") to include
6609	// in API requests with the JSON null value. By default, fields with
6610	// empty values are omitted from API requests. However, any field with
6611	// an empty value appearing in NullFields will be sent to the server as
6612	// null. It is an error if a field in this list has a non-empty value.
6613	// This may be used to include null fields in Patch requests.
6614	NullFields []string `json:"-"`
6615}
6616
6617func (s *GoogleCloudDialogflowCxV3beta1TestRunDifference) MarshalJSON() ([]byte, error) {
6618	type NoMethod GoogleCloudDialogflowCxV3beta1TestRunDifference
6619	raw := NoMethod(*s)
6620	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
6621}
6622
6623// GoogleCloudDialogflowCxV3beta1TextInput: Represents the natural
6624// language text to be processed.
6625type GoogleCloudDialogflowCxV3beta1TextInput struct {
6626	// Text: Required. The UTF-8 encoded natural language text to be
6627	// processed. Text length must not exceed 256 characters.
6628	Text string `json:"text,omitempty"`
6629
6630	// ForceSendFields is a list of field names (e.g. "Text") to
6631	// unconditionally include in API requests. By default, fields with
6632	// empty or default values are omitted from API requests. However, any
6633	// non-pointer, non-interface field appearing in ForceSendFields will be
6634	// sent to the server regardless of whether the field is empty or not.
6635	// This may be used to include empty fields in Patch requests.
6636	ForceSendFields []string `json:"-"`
6637
6638	// NullFields is a list of field names (e.g. "Text") to include in API
6639	// requests with the JSON null value. By default, fields with empty
6640	// values are omitted from API requests. However, any field with an
6641	// empty value appearing in NullFields will be sent to the server as
6642	// null. It is an error if a field in this list has a non-empty value.
6643	// This may be used to include null fields in Patch requests.
6644	NullFields []string `json:"-"`
6645}
6646
6647func (s *GoogleCloudDialogflowCxV3beta1TextInput) MarshalJSON() ([]byte, error) {
6648	type NoMethod GoogleCloudDialogflowCxV3beta1TextInput
6649	raw := NoMethod(*s)
6650	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
6651}
6652
6653// GoogleCloudDialogflowCxV3beta1TransitionRoute: A transition route
6654// specifies a intent that can be matched and/or a data condition that
6655// can be evaluated during a session. When a specified transition is
6656// matched, the following actions are taken in order: * If there is a
6657// `trigger_fulfillment` associated with the transition, it will be
6658// called. * If there is a `target_page` associated with the transition,
6659// the session will transition into the specified page. * If there is a
6660// `target_flow` associated with the transition, the session will
6661// transition into the specified flow.
6662type GoogleCloudDialogflowCxV3beta1TransitionRoute struct {
6663	// Condition: The condition to evaluate against form parameters or
6664	// session parameters. See the conditions reference
6665	// (https://cloud.google.com/dialogflow/cx/docs/reference/condition). At
6666	// least one of `intent` or `condition` must be specified. When both
6667	// `intent` and `condition` are specified, the transition can only
6668	// happen when both are fulfilled.
6669	Condition string `json:"condition,omitempty"`
6670
6671	// Intent: The unique identifier of an Intent. Format:
6672	// `projects//locations//agents//intents/`. Indicates that the
6673	// transition can only happen when the given intent is matched. At least
6674	// one of `intent` or `condition` must be specified. When both `intent`
6675	// and `condition` are specified, the transition can only happen when
6676	// both are fulfilled.
6677	Intent string `json:"intent,omitempty"`
6678
6679	// Name: Output only. The unique identifier of this transition route.
6680	Name string `json:"name,omitempty"`
6681
6682	// TargetFlow: The target flow to transition to. Format:
6683	// `projects//locations//agents//flows/`.
6684	TargetFlow string `json:"targetFlow,omitempty"`
6685
6686	// TargetPage: The target page to transition to. Format:
6687	// `projects//locations//agents//flows//pages/`.
6688	TargetPage string `json:"targetPage,omitempty"`
6689
6690	// TriggerFulfillment: The fulfillment to call when the condition is
6691	// satisfied. At least one of `trigger_fulfillment` and `target` must be
6692	// specified. When both are defined, `trigger_fulfillment` is executed
6693	// first.
6694	TriggerFulfillment *GoogleCloudDialogflowCxV3beta1Fulfillment `json:"triggerFulfillment,omitempty"`
6695
6696	// ForceSendFields is a list of field names (e.g. "Condition") to
6697	// unconditionally include in API requests. By default, fields with
6698	// empty or default values are omitted from API requests. However, any
6699	// non-pointer, non-interface field appearing in ForceSendFields will be
6700	// sent to the server regardless of whether the field is empty or not.
6701	// This may be used to include empty fields in Patch requests.
6702	ForceSendFields []string `json:"-"`
6703
6704	// NullFields is a list of field names (e.g. "Condition") to include in
6705	// API requests with the JSON null value. By default, fields with empty
6706	// values are omitted from API requests. However, any field with an
6707	// empty value appearing in NullFields will be sent to the server as
6708	// null. It is an error if a field in this list has a non-empty value.
6709	// This may be used to include null fields in Patch requests.
6710	NullFields []string `json:"-"`
6711}
6712
6713func (s *GoogleCloudDialogflowCxV3beta1TransitionRoute) MarshalJSON() ([]byte, error) {
6714	type NoMethod GoogleCloudDialogflowCxV3beta1TransitionRoute
6715	raw := NoMethod(*s)
6716	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
6717}
6718
6719// GoogleCloudDialogflowCxV3beta1UpdateDocumentOperationMetadata:
6720// Metadata for UpdateDocument operation.
6721type GoogleCloudDialogflowCxV3beta1UpdateDocumentOperationMetadata struct {
6722	// GenericMetadata: The generic information of the operation.
6723	GenericMetadata *GoogleCloudDialogflowCxV3beta1GenericKnowledgeOperationMetadata `json:"genericMetadata,omitempty"`
6724
6725	// ForceSendFields is a list of field names (e.g. "GenericMetadata") to
6726	// unconditionally include in API requests. By default, fields with
6727	// empty or default values are omitted from API requests. However, any
6728	// non-pointer, non-interface field appearing in ForceSendFields will be
6729	// sent to the server regardless of whether the field is empty or not.
6730	// This may be used to include empty fields in Patch requests.
6731	ForceSendFields []string `json:"-"`
6732
6733	// NullFields is a list of field names (e.g. "GenericMetadata") to
6734	// include in API requests with the JSON null value. By default, fields
6735	// with empty values are omitted from API requests. However, any field
6736	// with an empty value appearing in NullFields will be sent to the
6737	// server as null. It is an error if a field in this list has a
6738	// non-empty value. This may be used to include null fields in Patch
6739	// requests.
6740	NullFields []string `json:"-"`
6741}
6742
6743func (s *GoogleCloudDialogflowCxV3beta1UpdateDocumentOperationMetadata) MarshalJSON() ([]byte, error) {
6744	type NoMethod GoogleCloudDialogflowCxV3beta1UpdateDocumentOperationMetadata
6745	raw := NoMethod(*s)
6746	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
6747}
6748
6749// GoogleCloudDialogflowCxV3beta1WebhookRequest: The request message for
6750// a webhook call. The request is sent as a JSON object and the field
6751// names will be presented in camel cases.
6752type GoogleCloudDialogflowCxV3beta1WebhookRequest struct {
6753	// DetectIntentResponseId: Always present. The unique identifier of the
6754	// DetectIntentResponse that will be returned to the API caller.
6755	DetectIntentResponseId string `json:"detectIntentResponseId,omitempty"`
6756
6757	// FulfillmentInfo: Always present. Information about the fulfillment
6758	// that triggered this webhook call.
6759	FulfillmentInfo *GoogleCloudDialogflowCxV3beta1WebhookRequestFulfillmentInfo `json:"fulfillmentInfo,omitempty"`
6760
6761	// IntentInfo: Information about the last matched intent.
6762	IntentInfo *GoogleCloudDialogflowCxV3beta1WebhookRequestIntentInfo `json:"intentInfo,omitempty"`
6763
6764	// LanguageCode: The language code specified in the original request.
6765	LanguageCode string `json:"languageCode,omitempty"`
6766
6767	// Messages: The list of rich message responses to present to the user.
6768	// Webhook can choose to append or replace this list in
6769	// WebhookResponse.fulfillment_response;
6770	Messages []*GoogleCloudDialogflowCxV3beta1ResponseMessage `json:"messages,omitempty"`
6771
6772	// PageInfo: Information about page status.
6773	PageInfo *GoogleCloudDialogflowCxV3beta1PageInfo `json:"pageInfo,omitempty"`
6774
6775	// Payload: Custom data set in QueryParameters.payload.
6776	Payload googleapi.RawMessage `json:"payload,omitempty"`
6777
6778	// SentimentAnalysisResult: The sentiment analysis result of the current
6779	// user request. The field is filled when sentiment analysis is
6780	// configured to be enabled for the request.
6781	SentimentAnalysisResult *GoogleCloudDialogflowCxV3beta1WebhookRequestSentimentAnalysisResult `json:"sentimentAnalysisResult,omitempty"`
6782
6783	// SessionInfo: Information about session status.
6784	SessionInfo *GoogleCloudDialogflowCxV3beta1SessionInfo `json:"sessionInfo,omitempty"`
6785
6786	// Text: If natural language text was provided as input, this field will
6787	// contain a copy of the text.
6788	Text string `json:"text,omitempty"`
6789
6790	// Transcript: If natural language speech audio was provided as input,
6791	// this field will contain the transcript for the audio.
6792	Transcript string `json:"transcript,omitempty"`
6793
6794	// TriggerEvent: If an event was provided as input, this field will
6795	// contain the name of the event.
6796	TriggerEvent string `json:"triggerEvent,omitempty"`
6797
6798	// TriggerIntent: If an intent was provided as input, this field will
6799	// contain a copy of the intent identifier. Format:
6800	// `projects//locations//agents//intents/`.
6801	TriggerIntent string `json:"triggerIntent,omitempty"`
6802
6803	// ForceSendFields is a list of field names (e.g.
6804	// "DetectIntentResponseId") to unconditionally include in API requests.
6805	// By default, fields with empty or default values are omitted from API
6806	// requests. However, any non-pointer, non-interface field appearing in
6807	// ForceSendFields will be sent to the server regardless of whether the
6808	// field is empty or not. This may be used to include empty fields in
6809	// Patch requests.
6810	ForceSendFields []string `json:"-"`
6811
6812	// NullFields is a list of field names (e.g. "DetectIntentResponseId")
6813	// to include in API requests with the JSON null value. By default,
6814	// fields with empty values are omitted from API requests. However, any
6815	// field with an empty value appearing in NullFields will be sent to the
6816	// server as null. It is an error if a field in this list has a
6817	// non-empty value. This may be used to include null fields in Patch
6818	// requests.
6819	NullFields []string `json:"-"`
6820}
6821
6822func (s *GoogleCloudDialogflowCxV3beta1WebhookRequest) MarshalJSON() ([]byte, error) {
6823	type NoMethod GoogleCloudDialogflowCxV3beta1WebhookRequest
6824	raw := NoMethod(*s)
6825	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
6826}
6827
6828// GoogleCloudDialogflowCxV3beta1WebhookRequestFulfillmentInfo:
6829// Represents fulfillment information communicated to the webhook.
6830type GoogleCloudDialogflowCxV3beta1WebhookRequestFulfillmentInfo struct {
6831	// Tag: Always present. The tag used to identify which fulfillment is
6832	// being called.
6833	Tag string `json:"tag,omitempty"`
6834
6835	// ForceSendFields is a list of field names (e.g. "Tag") to
6836	// unconditionally include in API requests. By default, fields with
6837	// empty or default values are omitted from API requests. However, any
6838	// non-pointer, non-interface field appearing in ForceSendFields will be
6839	// sent to the server regardless of whether the field is empty or not.
6840	// This may be used to include empty fields in Patch requests.
6841	ForceSendFields []string `json:"-"`
6842
6843	// NullFields is a list of field names (e.g. "Tag") to include in API
6844	// requests with the JSON null value. By default, fields with empty
6845	// values are omitted from API requests. However, any field with an
6846	// empty value appearing in NullFields will be sent to the server as
6847	// null. It is an error if a field in this list has a non-empty value.
6848	// This may be used to include null fields in Patch requests.
6849	NullFields []string `json:"-"`
6850}
6851
6852func (s *GoogleCloudDialogflowCxV3beta1WebhookRequestFulfillmentInfo) MarshalJSON() ([]byte, error) {
6853	type NoMethod GoogleCloudDialogflowCxV3beta1WebhookRequestFulfillmentInfo
6854	raw := NoMethod(*s)
6855	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
6856}
6857
6858// GoogleCloudDialogflowCxV3beta1WebhookRequestIntentInfo: Represents
6859// intent information communicated to the webhook.
6860type GoogleCloudDialogflowCxV3beta1WebhookRequestIntentInfo struct {
6861	// Confidence: The confidence of the matched intent. Values range from
6862	// 0.0 (completely uncertain) to 1.0 (completely certain).
6863	Confidence float64 `json:"confidence,omitempty"`
6864
6865	// DisplayName: Always present. The display name of the last matched
6866	// intent.
6867	DisplayName string `json:"displayName,omitempty"`
6868
6869	// LastMatchedIntent: Always present. The unique identifier of the last
6870	// matched intent. Format: `projects//locations//agents//intents/`.
6871	LastMatchedIntent string `json:"lastMatchedIntent,omitempty"`
6872
6873	// Parameters: Parameters identified as a result of intent matching.
6874	// This is a map of the name of the identified parameter to the value of
6875	// the parameter identified from the user's utterance. All parameters
6876	// defined in the matched intent that are identified will be surfaced
6877	// here.
6878	Parameters map[string]GoogleCloudDialogflowCxV3beta1WebhookRequestIntentInfoIntentParameterValue `json:"parameters,omitempty"`
6879
6880	// ForceSendFields is a list of field names (e.g. "Confidence") to
6881	// unconditionally include in API requests. By default, fields with
6882	// empty or default values are omitted from API requests. However, any
6883	// non-pointer, non-interface field appearing in ForceSendFields will be
6884	// sent to the server regardless of whether the field is empty or not.
6885	// This may be used to include empty fields in Patch requests.
6886	ForceSendFields []string `json:"-"`
6887
6888	// NullFields is a list of field names (e.g. "Confidence") to include in
6889	// API requests with the JSON null value. By default, fields with empty
6890	// values are omitted from API requests. However, any field with an
6891	// empty value appearing in NullFields will be sent to the server as
6892	// null. It is an error if a field in this list has a non-empty value.
6893	// This may be used to include null fields in Patch requests.
6894	NullFields []string `json:"-"`
6895}
6896
6897func (s *GoogleCloudDialogflowCxV3beta1WebhookRequestIntentInfo) MarshalJSON() ([]byte, error) {
6898	type NoMethod GoogleCloudDialogflowCxV3beta1WebhookRequestIntentInfo
6899	raw := NoMethod(*s)
6900	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
6901}
6902
6903func (s *GoogleCloudDialogflowCxV3beta1WebhookRequestIntentInfo) UnmarshalJSON(data []byte) error {
6904	type NoMethod GoogleCloudDialogflowCxV3beta1WebhookRequestIntentInfo
6905	var s1 struct {
6906		Confidence gensupport.JSONFloat64 `json:"confidence"`
6907		*NoMethod
6908	}
6909	s1.NoMethod = (*NoMethod)(s)
6910	if err := json.Unmarshal(data, &s1); err != nil {
6911		return err
6912	}
6913	s.Confidence = float64(s1.Confidence)
6914	return nil
6915}
6916
6917// GoogleCloudDialogflowCxV3beta1WebhookRequestIntentInfoIntentParameterV
6918// alue: Represents a value for an intent parameter.
6919type GoogleCloudDialogflowCxV3beta1WebhookRequestIntentInfoIntentParameterValue struct {
6920	// OriginalValue: Always present. Original text value extracted from
6921	// user utterance.
6922	OriginalValue string `json:"originalValue,omitempty"`
6923
6924	// ResolvedValue: Always present. Structured value for the parameter
6925	// extracted from user utterance.
6926	ResolvedValue interface{} `json:"resolvedValue,omitempty"`
6927
6928	// ForceSendFields is a list of field names (e.g. "OriginalValue") to
6929	// unconditionally include in API requests. By default, fields with
6930	// empty or default values are omitted from API requests. However, any
6931	// non-pointer, non-interface field appearing in ForceSendFields will be
6932	// sent to the server regardless of whether the field is empty or not.
6933	// This may be used to include empty fields in Patch requests.
6934	ForceSendFields []string `json:"-"`
6935
6936	// NullFields is a list of field names (e.g. "OriginalValue") to include
6937	// in API requests with the JSON null value. By default, fields with
6938	// empty values are omitted from API requests. However, any field with
6939	// an empty value appearing in NullFields will be sent to the server as
6940	// null. It is an error if a field in this list has a non-empty value.
6941	// This may be used to include null fields in Patch requests.
6942	NullFields []string `json:"-"`
6943}
6944
6945func (s *GoogleCloudDialogflowCxV3beta1WebhookRequestIntentInfoIntentParameterValue) MarshalJSON() ([]byte, error) {
6946	type NoMethod GoogleCloudDialogflowCxV3beta1WebhookRequestIntentInfoIntentParameterValue
6947	raw := NoMethod(*s)
6948	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
6949}
6950
6951// GoogleCloudDialogflowCxV3beta1WebhookRequestSentimentAnalysisResult:
6952// Represents the result of sentiment analysis.
6953type GoogleCloudDialogflowCxV3beta1WebhookRequestSentimentAnalysisResult struct {
6954	// Magnitude: A non-negative number in the [0, +inf) range, which
6955	// represents the absolute magnitude of sentiment, regardless of score
6956	// (positive or negative).
6957	Magnitude float64 `json:"magnitude,omitempty"`
6958
6959	// Score: Sentiment score between -1.0 (negative sentiment) and 1.0
6960	// (positive sentiment).
6961	Score float64 `json:"score,omitempty"`
6962
6963	// ForceSendFields is a list of field names (e.g. "Magnitude") to
6964	// unconditionally include in API requests. By default, fields with
6965	// empty or default values are omitted from API requests. However, any
6966	// non-pointer, non-interface field appearing in ForceSendFields will be
6967	// sent to the server regardless of whether the field is empty or not.
6968	// This may be used to include empty fields in Patch requests.
6969	ForceSendFields []string `json:"-"`
6970
6971	// NullFields is a list of field names (e.g. "Magnitude") to include in
6972	// API requests with the JSON null value. By default, fields with empty
6973	// values are omitted from API requests. However, any field with an
6974	// empty value appearing in NullFields will be sent to the server as
6975	// null. It is an error if a field in this list has a non-empty value.
6976	// This may be used to include null fields in Patch requests.
6977	NullFields []string `json:"-"`
6978}
6979
6980func (s *GoogleCloudDialogflowCxV3beta1WebhookRequestSentimentAnalysisResult) MarshalJSON() ([]byte, error) {
6981	type NoMethod GoogleCloudDialogflowCxV3beta1WebhookRequestSentimentAnalysisResult
6982	raw := NoMethod(*s)
6983	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
6984}
6985
6986func (s *GoogleCloudDialogflowCxV3beta1WebhookRequestSentimentAnalysisResult) UnmarshalJSON(data []byte) error {
6987	type NoMethod GoogleCloudDialogflowCxV3beta1WebhookRequestSentimentAnalysisResult
6988	var s1 struct {
6989		Magnitude gensupport.JSONFloat64 `json:"magnitude"`
6990		Score     gensupport.JSONFloat64 `json:"score"`
6991		*NoMethod
6992	}
6993	s1.NoMethod = (*NoMethod)(s)
6994	if err := json.Unmarshal(data, &s1); err != nil {
6995		return err
6996	}
6997	s.Magnitude = float64(s1.Magnitude)
6998	s.Score = float64(s1.Score)
6999	return nil
7000}
7001
7002// GoogleCloudDialogflowCxV3beta1WebhookResponse: The response message
7003// for a webhook call.
7004type GoogleCloudDialogflowCxV3beta1WebhookResponse struct {
7005	// FulfillmentResponse: The fulfillment response to send to the user.
7006	// This field can be omitted by the webhook if it does not intend to
7007	// send any response to the user.
7008	FulfillmentResponse *GoogleCloudDialogflowCxV3beta1WebhookResponseFulfillmentResponse `json:"fulfillmentResponse,omitempty"`
7009
7010	// PageInfo: Information about page status. This field can be omitted by
7011	// the webhook if it does not intend to modify page status.
7012	PageInfo *GoogleCloudDialogflowCxV3beta1PageInfo `json:"pageInfo,omitempty"`
7013
7014	// Payload: Value to append directly to QueryResult.webhook_payloads.
7015	Payload googleapi.RawMessage `json:"payload,omitempty"`
7016
7017	// SessionInfo: Information about session status. This field can be
7018	// omitted by the webhook if it does not intend to modify session
7019	// status.
7020	SessionInfo *GoogleCloudDialogflowCxV3beta1SessionInfo `json:"sessionInfo,omitempty"`
7021
7022	// TargetFlow: The target flow to transition to. Format:
7023	// `projects//locations//agents//flows/`.
7024	TargetFlow string `json:"targetFlow,omitempty"`
7025
7026	// TargetPage: The target page to transition to. Format:
7027	// `projects//locations//agents//flows//pages/`.
7028	TargetPage string `json:"targetPage,omitempty"`
7029
7030	// ForceSendFields is a list of field names (e.g. "FulfillmentResponse")
7031	// to unconditionally include in API requests. By default, fields with
7032	// empty or default values are omitted from API requests. However, any
7033	// non-pointer, non-interface field appearing in ForceSendFields will be
7034	// sent to the server regardless of whether the field is empty or not.
7035	// This may be used to include empty fields in Patch requests.
7036	ForceSendFields []string `json:"-"`
7037
7038	// NullFields is a list of field names (e.g. "FulfillmentResponse") to
7039	// include in API requests with the JSON null value. By default, fields
7040	// with empty values are omitted from API requests. However, any field
7041	// with an empty value appearing in NullFields will be sent to the
7042	// server as null. It is an error if a field in this list has a
7043	// non-empty value. This may be used to include null fields in Patch
7044	// requests.
7045	NullFields []string `json:"-"`
7046}
7047
7048func (s *GoogleCloudDialogflowCxV3beta1WebhookResponse) MarshalJSON() ([]byte, error) {
7049	type NoMethod GoogleCloudDialogflowCxV3beta1WebhookResponse
7050	raw := NoMethod(*s)
7051	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
7052}
7053
7054// GoogleCloudDialogflowCxV3beta1WebhookResponseFulfillmentResponse:
7055// Represents a fulfillment response to the user.
7056type GoogleCloudDialogflowCxV3beta1WebhookResponseFulfillmentResponse struct {
7057	// MergeBehavior: Merge behavior for `messages`.
7058	//
7059	// Possible values:
7060	//   "MERGE_BEHAVIOR_UNSPECIFIED" - Not specified. `APPEND` will be
7061	// used.
7062	//   "APPEND" - `messages` will be appended to the list of messages
7063	// waiting to be sent to the user.
7064	//   "REPLACE" - `messages` will replace the list of messages waiting to
7065	// be sent to the user.
7066	MergeBehavior string `json:"mergeBehavior,omitempty"`
7067
7068	// Messages: The list of rich message responses to present to the user.
7069	Messages []*GoogleCloudDialogflowCxV3beta1ResponseMessage `json:"messages,omitempty"`
7070
7071	// ForceSendFields is a list of field names (e.g. "MergeBehavior") to
7072	// unconditionally include in API requests. By default, fields with
7073	// empty or default values are omitted from API requests. However, any
7074	// non-pointer, non-interface field appearing in ForceSendFields will be
7075	// sent to the server regardless of whether the field is empty or not.
7076	// This may be used to include empty fields in Patch requests.
7077	ForceSendFields []string `json:"-"`
7078
7079	// NullFields is a list of field names (e.g. "MergeBehavior") to include
7080	// in API requests with the JSON null value. By default, fields with
7081	// empty values are omitted from API requests. However, any field with
7082	// an empty value appearing in NullFields will be sent to the server as
7083	// null. It is an error if a field in this list has a non-empty value.
7084	// This may be used to include null fields in Patch requests.
7085	NullFields []string `json:"-"`
7086}
7087
7088func (s *GoogleCloudDialogflowCxV3beta1WebhookResponseFulfillmentResponse) MarshalJSON() ([]byte, error) {
7089	type NoMethod GoogleCloudDialogflowCxV3beta1WebhookResponseFulfillmentResponse
7090	raw := NoMethod(*s)
7091	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
7092}
7093
7094// GoogleCloudDialogflowV2Agent: A Dialogflow agent is a virtual agent
7095// that handles conversations with your end-users. It is a natural
7096// language understanding module that understands the nuances of human
7097// language. Dialogflow translates end-user text or audio during a
7098// conversation to structured data that your apps and services can
7099// understand. You design and build a Dialogflow agent to handle the
7100// types of conversations required for your system. For more information
7101// about agents, see the Agent guide
7102// (https://cloud.google.com/dialogflow/docs/agents-overview).
7103type GoogleCloudDialogflowV2Agent struct {
7104	// ApiVersion: Optional. API version displayed in Dialogflow console. If
7105	// not specified, V2 API is assumed. Clients are free to query different
7106	// service endpoints for different API versions. However, bots
7107	// connectors and webhook calls will follow the specified API version.
7108	//
7109	// Possible values:
7110	//   "API_VERSION_UNSPECIFIED" - Not specified.
7111	//   "API_VERSION_V1" - Legacy V1 API.
7112	//   "API_VERSION_V2" - V2 API.
7113	//   "API_VERSION_V2_BETA_1" - V2beta1 API.
7114	ApiVersion string `json:"apiVersion,omitempty"`
7115
7116	// AvatarUri: Optional. The URI of the agent's avatar. Avatars are used
7117	// throughout the Dialogflow console and in the self-hosted Web Demo
7118	// (https://cloud.google.com/dialogflow/docs/integrations/web-demo)
7119	// integration.
7120	AvatarUri string `json:"avatarUri,omitempty"`
7121
7122	// ClassificationThreshold: Optional. To filter out false positive
7123	// results and still get variety in matched natural language inputs for
7124	// your agent, you can tune the machine learning classification
7125	// threshold. If the returned score value is less than the threshold
7126	// value, then a fallback intent will be triggered or, if there are no
7127	// fallback intents defined, no intent will be triggered. The score
7128	// values range from 0.0 (completely uncertain) to 1.0 (completely
7129	// certain). If set to 0.0, the default of 0.3 is used.
7130	ClassificationThreshold float64 `json:"classificationThreshold,omitempty"`
7131
7132	// DefaultLanguageCode: Required. The default language of the agent as a
7133	// language tag. See Language Support
7134	// (https://cloud.google.com/dialogflow/docs/reference/language) for a
7135	// list of the currently supported language codes. This field cannot be
7136	// set by the `Update` method.
7137	DefaultLanguageCode string `json:"defaultLanguageCode,omitempty"`
7138
7139	// Description: Optional. The description of this agent. The maximum
7140	// length is 500 characters. If exceeded, the request is rejected.
7141	Description string `json:"description,omitempty"`
7142
7143	// DisplayName: Required. The name of this agent.
7144	DisplayName string `json:"displayName,omitempty"`
7145
7146	// EnableLogging: Optional. Determines whether this agent should log
7147	// conversation queries.
7148	EnableLogging bool `json:"enableLogging,omitempty"`
7149
7150	// MatchMode: Optional. Determines how intents are detected from user
7151	// queries.
7152	//
7153	// Possible values:
7154	//   "MATCH_MODE_UNSPECIFIED" - Not specified.
7155	//   "MATCH_MODE_HYBRID" - Best for agents with a small number of
7156	// examples in intents and/or wide use of templates syntax and composite
7157	// entities.
7158	//   "MATCH_MODE_ML_ONLY" - Can be used for agents with a large number
7159	// of examples in intents, especially the ones using @sys.any or very
7160	// large custom entities.
7161	MatchMode string `json:"matchMode,omitempty"`
7162
7163	// Parent: Required. The project of this agent. Format: `projects/`.
7164	Parent string `json:"parent,omitempty"`
7165
7166	// SupportedLanguageCodes: Optional. The list of all languages supported
7167	// by this agent (except for the `default_language_code`).
7168	SupportedLanguageCodes []string `json:"supportedLanguageCodes,omitempty"`
7169
7170	// Tier: Optional. The agent tier. If not specified, TIER_STANDARD is
7171	// assumed.
7172	//
7173	// Possible values:
7174	//   "TIER_UNSPECIFIED" - Not specified. This value should never be
7175	// used.
7176	//   "TIER_STANDARD" - Standard tier.
7177	//   "TIER_ENTERPRISE" - Enterprise tier (Essentials).
7178	//   "TIER_ENTERPRISE_PLUS" - Enterprise tier (Plus).
7179	Tier string `json:"tier,omitempty"`
7180
7181	// TimeZone: Required. The time zone of this agent from the time zone
7182	// database (https://www.iana.org/time-zones), e.g., America/New_York,
7183	// Europe/Paris.
7184	TimeZone string `json:"timeZone,omitempty"`
7185
7186	// ServerResponse contains the HTTP response code and headers from the
7187	// server.
7188	googleapi.ServerResponse `json:"-"`
7189
7190	// ForceSendFields is a list of field names (e.g. "ApiVersion") to
7191	// unconditionally include in API requests. By default, fields with
7192	// empty or default values are omitted from API requests. However, any
7193	// non-pointer, non-interface field appearing in ForceSendFields will be
7194	// sent to the server regardless of whether the field is empty or not.
7195	// This may be used to include empty fields in Patch requests.
7196	ForceSendFields []string `json:"-"`
7197
7198	// NullFields is a list of field names (e.g. "ApiVersion") to include in
7199	// API requests with the JSON null value. By default, fields with empty
7200	// values are omitted from API requests. However, any field with an
7201	// empty value appearing in NullFields will be sent to the server as
7202	// null. It is an error if a field in this list has a non-empty value.
7203	// This may be used to include null fields in Patch requests.
7204	NullFields []string `json:"-"`
7205}
7206
7207func (s *GoogleCloudDialogflowV2Agent) MarshalJSON() ([]byte, error) {
7208	type NoMethod GoogleCloudDialogflowV2Agent
7209	raw := NoMethod(*s)
7210	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
7211}
7212
7213func (s *GoogleCloudDialogflowV2Agent) UnmarshalJSON(data []byte) error {
7214	type NoMethod GoogleCloudDialogflowV2Agent
7215	var s1 struct {
7216		ClassificationThreshold gensupport.JSONFloat64 `json:"classificationThreshold"`
7217		*NoMethod
7218	}
7219	s1.NoMethod = (*NoMethod)(s)
7220	if err := json.Unmarshal(data, &s1); err != nil {
7221		return err
7222	}
7223	s.ClassificationThreshold = float64(s1.ClassificationThreshold)
7224	return nil
7225}
7226
7227// GoogleCloudDialogflowV2AgentAssistantFeedback: Detail feedback of
7228// Agent Assist result.
7229type GoogleCloudDialogflowV2AgentAssistantFeedback struct {
7230	// AnswerRelevance: Optional. Whether or not the suggested answer is
7231	// relevant. For example: * Query: "Can I change my mailing address?" *
7232	// Suggested document says: "Items must be returned/exchanged within 60
7233	// days of the purchase date." * answer_relevance:
7234	// AnswerRelevance.IRRELEVANT
7235	//
7236	// Possible values:
7237	//   "ANSWER_RELEVANCE_UNSPECIFIED" - Answer relevance unspecified.
7238	//   "IRRELEVANT" - Answer is irrelevant to query.
7239	//   "RELEVANT" - Answer is relevant to query.
7240	AnswerRelevance string `json:"answerRelevance,omitempty"`
7241
7242	// DocumentCorrectness: Optional. Whether or not the information in the
7243	// document is correct. For example: * Query: "Can I return the package
7244	// in 2 days once received?" * Suggested document says: "Items must be
7245	// returned/exchanged within 60 days of the purchase date." * Ground
7246	// truth: "No return or exchange is allowed." * [document_correctness]:
7247	// INCORRECT
7248	//
7249	// Possible values:
7250	//   "DOCUMENT_CORRECTNESS_UNSPECIFIED" - Document correctness
7251	// unspecified.
7252	//   "INCORRECT" - Information in document is incorrect.
7253	//   "CORRECT" - Information in document is correct.
7254	DocumentCorrectness string `json:"documentCorrectness,omitempty"`
7255
7256	// DocumentEfficiency: Optional. Whether or not the suggested document
7257	// is efficient. For example, if the document is poorly written, hard to
7258	// understand, hard to use or too long to find useful information,
7259	// document_efficiency is DocumentEfficiency.INEFFICIENT.
7260	//
7261	// Possible values:
7262	//   "DOCUMENT_EFFICIENCY_UNSPECIFIED" - Document efficiency
7263	// unspecified.
7264	//   "INEFFICIENT" - Document is inefficient.
7265	//   "EFFICIENT" - Document is efficient.
7266	DocumentEfficiency string `json:"documentEfficiency,omitempty"`
7267
7268	// ForceSendFields is a list of field names (e.g. "AnswerRelevance") to
7269	// unconditionally include in API requests. By default, fields with
7270	// empty or default values are omitted from API requests. However, any
7271	// non-pointer, non-interface field appearing in ForceSendFields will be
7272	// sent to the server regardless of whether the field is empty or not.
7273	// This may be used to include empty fields in Patch requests.
7274	ForceSendFields []string `json:"-"`
7275
7276	// NullFields is a list of field names (e.g. "AnswerRelevance") to
7277	// include in API requests with the JSON null value. By default, fields
7278	// with empty values are omitted from API requests. However, any field
7279	// with an empty value appearing in NullFields will be sent to the
7280	// server as null. It is an error if a field in this list has a
7281	// non-empty value. This may be used to include null fields in Patch
7282	// requests.
7283	NullFields []string `json:"-"`
7284}
7285
7286func (s *GoogleCloudDialogflowV2AgentAssistantFeedback) MarshalJSON() ([]byte, error) {
7287	type NoMethod GoogleCloudDialogflowV2AgentAssistantFeedback
7288	raw := NoMethod(*s)
7289	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
7290}
7291
7292// GoogleCloudDialogflowV2AgentAssistantRecord: Represents a record of a
7293// human agent assist answer.
7294type GoogleCloudDialogflowV2AgentAssistantRecord struct {
7295	// ArticleSuggestionAnswer: Output only. The article suggestion answer.
7296	ArticleSuggestionAnswer *GoogleCloudDialogflowV2ArticleAnswer `json:"articleSuggestionAnswer,omitempty"`
7297
7298	// FaqAnswer: Output only. The FAQ answer.
7299	FaqAnswer *GoogleCloudDialogflowV2FaqAnswer `json:"faqAnswer,omitempty"`
7300
7301	// ForceSendFields is a list of field names (e.g.
7302	// "ArticleSuggestionAnswer") to unconditionally include in API
7303	// requests. By default, fields with empty or default values are omitted
7304	// from API requests. However, any non-pointer, non-interface field
7305	// appearing in ForceSendFields will be sent to the server regardless of
7306	// whether the field is empty or not. This may be used to include empty
7307	// fields in Patch requests.
7308	ForceSendFields []string `json:"-"`
7309
7310	// NullFields is a list of field names (e.g. "ArticleSuggestionAnswer")
7311	// to include in API requests with the JSON null value. By default,
7312	// fields with empty values are omitted from API requests. However, any
7313	// field with an empty value appearing in NullFields will be sent to the
7314	// server as null. It is an error if a field in this list has a
7315	// non-empty value. This may be used to include null fields in Patch
7316	// requests.
7317	NullFields []string `json:"-"`
7318}
7319
7320func (s *GoogleCloudDialogflowV2AgentAssistantRecord) MarshalJSON() ([]byte, error) {
7321	type NoMethod GoogleCloudDialogflowV2AgentAssistantRecord
7322	raw := NoMethod(*s)
7323	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
7324}
7325
7326// GoogleCloudDialogflowV2AnalyzeContentRequest: The request message for
7327// Participants.AnalyzeContent.
7328type GoogleCloudDialogflowV2AnalyzeContentRequest struct {
7329	// EventInput: An input event to send to Dialogflow.
7330	EventInput *GoogleCloudDialogflowV2EventInput `json:"eventInput,omitempty"`
7331
7332	// QueryParams: Parameters for a Dialogflow virtual-agent query.
7333	QueryParams *GoogleCloudDialogflowV2QueryParameters `json:"queryParams,omitempty"`
7334
7335	// ReplyAudioConfig: Speech synthesis configuration. The speech
7336	// synthesis settings for a virtual agent that may be configured for the
7337	// associated conversation profile are not used when calling
7338	// AnalyzeContent. If this configuration is not supplied, speech
7339	// synthesis is disabled.
7340	ReplyAudioConfig *GoogleCloudDialogflowV2OutputAudioConfig `json:"replyAudioConfig,omitempty"`
7341
7342	// RequestId: A unique identifier for this request. Restricted to 36
7343	// ASCII characters. A random UUID is recommended. This request is only
7344	// idempotent if a `request_id` is provided.
7345	RequestId string `json:"requestId,omitempty"`
7346
7347	// TextInput: The natural language text to be processed.
7348	TextInput *GoogleCloudDialogflowV2TextInput `json:"textInput,omitempty"`
7349
7350	// ForceSendFields is a list of field names (e.g. "EventInput") to
7351	// unconditionally include in API requests. By default, fields with
7352	// empty or default values are omitted from API requests. However, any
7353	// non-pointer, non-interface field appearing in ForceSendFields will be
7354	// sent to the server regardless of whether the field is empty or not.
7355	// This may be used to include empty fields in Patch requests.
7356	ForceSendFields []string `json:"-"`
7357
7358	// NullFields is a list of field names (e.g. "EventInput") to include in
7359	// API requests with the JSON null value. By default, fields with empty
7360	// values are omitted from API requests. However, any field with an
7361	// empty value appearing in NullFields will be sent to the server as
7362	// null. It is an error if a field in this list has a non-empty value.
7363	// This may be used to include null fields in Patch requests.
7364	NullFields []string `json:"-"`
7365}
7366
7367func (s *GoogleCloudDialogflowV2AnalyzeContentRequest) MarshalJSON() ([]byte, error) {
7368	type NoMethod GoogleCloudDialogflowV2AnalyzeContentRequest
7369	raw := NoMethod(*s)
7370	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
7371}
7372
7373// GoogleCloudDialogflowV2AnalyzeContentResponse: The response message
7374// for Participants.AnalyzeContent.
7375type GoogleCloudDialogflowV2AnalyzeContentResponse struct {
7376	// AutomatedAgentReply: Only set if a Dialogflow automated agent has
7377	// responded. Note that:
7378	// AutomatedAgentReply.detect_intent_response.output_audio and
7379	// AutomatedAgentReply.detect_intent_response.output_audio_config are
7380	// always empty, use reply_audio instead.
7381	AutomatedAgentReply *GoogleCloudDialogflowV2AutomatedAgentReply `json:"automatedAgentReply,omitempty"`
7382
7383	// DtmfParameters: Indicates the parameters of DTMF.
7384	DtmfParameters *GoogleCloudDialogflowV2DtmfParameters `json:"dtmfParameters,omitempty"`
7385
7386	// EndUserSuggestionResults: The suggestions for end user. The order is
7387	// the same as
7388	// HumanAgentAssistantConfig.SuggestionConfig.feature_configs of
7389	// HumanAgentAssistantConfig.end_user_suggestion_config.
7390	EndUserSuggestionResults []*GoogleCloudDialogflowV2SuggestionResult `json:"endUserSuggestionResults,omitempty"`
7391
7392	// HumanAgentSuggestionResults: The suggestions for most recent human
7393	// agent. The order is the same as
7394	// HumanAgentAssistantConfig.SuggestionConfig.feature_configs of
7395	// HumanAgentAssistantConfig.human_agent_suggestion_config.
7396	HumanAgentSuggestionResults []*GoogleCloudDialogflowV2SuggestionResult `json:"humanAgentSuggestionResults,omitempty"`
7397
7398	// Message: Message analyzed by CCAI.
7399	Message *GoogleCloudDialogflowV2Message `json:"message,omitempty"`
7400
7401	// ReplyAudio: The audio data bytes encoded as specified in the request.
7402	// This field is set if: - `reply_audio_config` was specified in the
7403	// request, or - The automated agent responded with audio to play to the
7404	// user. In such case, `reply_audio.config` contains settings used to
7405	// synthesize the speech. In some scenarios, multiple output audio
7406	// fields may be present in the response structure. In these cases, only
7407	// the top-most-level audio output has content.
7408	ReplyAudio *GoogleCloudDialogflowV2OutputAudio `json:"replyAudio,omitempty"`
7409
7410	// ReplyText: The output text content. This field is set if the
7411	// automated agent responded with text to show to the user.
7412	ReplyText string `json:"replyText,omitempty"`
7413
7414	// ServerResponse contains the HTTP response code and headers from the
7415	// server.
7416	googleapi.ServerResponse `json:"-"`
7417
7418	// ForceSendFields is a list of field names (e.g. "AutomatedAgentReply")
7419	// to unconditionally include in API requests. By default, fields with
7420	// empty or default values are omitted from API requests. However, any
7421	// non-pointer, non-interface field appearing in ForceSendFields will be
7422	// sent to the server regardless of whether the field is empty or not.
7423	// This may be used to include empty fields in Patch requests.
7424	ForceSendFields []string `json:"-"`
7425
7426	// NullFields is a list of field names (e.g. "AutomatedAgentReply") to
7427	// include in API requests with the JSON null value. By default, fields
7428	// with empty values are omitted from API requests. However, any field
7429	// with an empty value appearing in NullFields will be sent to the
7430	// server as null. It is an error if a field in this list has a
7431	// non-empty value. This may be used to include null fields in Patch
7432	// requests.
7433	NullFields []string `json:"-"`
7434}
7435
7436func (s *GoogleCloudDialogflowV2AnalyzeContentResponse) MarshalJSON() ([]byte, error) {
7437	type NoMethod GoogleCloudDialogflowV2AnalyzeContentResponse
7438	raw := NoMethod(*s)
7439	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
7440}
7441
7442// GoogleCloudDialogflowV2AnnotatedMessagePart: Represents a part of a
7443// message possibly annotated with an entity. The part can be an entity
7444// or purely a part of the message between two entities or message
7445// start/end.
7446type GoogleCloudDialogflowV2AnnotatedMessagePart struct {
7447	// EntityType: The Dialogflow system entity type
7448	// (https://cloud.google.com/dialogflow/docs/reference/system-entities)
7449	// of this message part. If this is empty, Dialogflow could not annotate
7450	// the phrase part with a system entity.
7451	EntityType string `json:"entityType,omitempty"`
7452
7453	// FormattedValue: The Dialogflow system entity formatted value
7454	// (https://cloud.google.com/dialogflow/docs/reference/system-entities)
7455	// of this message part. For example for a system entity of type
7456	// `@sys.unit-currency`, this may contain: { "amount": 5, "currency":
7457	// "USD" }
7458	FormattedValue interface{} `json:"formattedValue,omitempty"`
7459
7460	// Text: A part of a message possibly annotated with an entity.
7461	Text string `json:"text,omitempty"`
7462
7463	// ForceSendFields is a list of field names (e.g. "EntityType") to
7464	// unconditionally include in API requests. By default, fields with
7465	// empty or default values are omitted from API requests. However, any
7466	// non-pointer, non-interface field appearing in ForceSendFields will be
7467	// sent to the server regardless of whether the field is empty or not.
7468	// This may be used to include empty fields in Patch requests.
7469	ForceSendFields []string `json:"-"`
7470
7471	// NullFields is a list of field names (e.g. "EntityType") to include in
7472	// API requests with the JSON null value. By default, fields with empty
7473	// values are omitted from API requests. However, any field with an
7474	// empty value appearing in NullFields will be sent to the server as
7475	// null. It is an error if a field in this list has a non-empty value.
7476	// This may be used to include null fields in Patch requests.
7477	NullFields []string `json:"-"`
7478}
7479
7480func (s *GoogleCloudDialogflowV2AnnotatedMessagePart) MarshalJSON() ([]byte, error) {
7481	type NoMethod GoogleCloudDialogflowV2AnnotatedMessagePart
7482	raw := NoMethod(*s)
7483	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
7484}
7485
7486// GoogleCloudDialogflowV2AnswerFeedback: Represents feedback the
7487// customer has about the quality & correctness of a certain answer in a
7488// conversation.
7489type GoogleCloudDialogflowV2AnswerFeedback struct {
7490	// AgentAssistantDetailFeedback: Detail feedback of agent assist
7491	// suggestions.
7492	AgentAssistantDetailFeedback *GoogleCloudDialogflowV2AgentAssistantFeedback `json:"agentAssistantDetailFeedback,omitempty"`
7493
7494	// ClickTime: Time when the answer/item was clicked.
7495	ClickTime string `json:"clickTime,omitempty"`
7496
7497	// Clicked: Indicates whether the answer/item was clicked by the human
7498	// agent or not. Default to false.
7499	Clicked bool `json:"clicked,omitempty"`
7500
7501	// CorrectnessLevel: The correctness level of the specific answer.
7502	//
7503	// Possible values:
7504	//   "CORRECTNESS_LEVEL_UNSPECIFIED" - Correctness level unspecified.
7505	//   "NOT_CORRECT" - Answer is totally wrong.
7506	//   "PARTIALLY_CORRECT" - Answer is partially correct.
7507	//   "FULLY_CORRECT" - Answer is fully correct.
7508	CorrectnessLevel string `json:"correctnessLevel,omitempty"`
7509
7510	// DisplayTime: Time when the answer/item was displayed.
7511	DisplayTime string `json:"displayTime,omitempty"`
7512
7513	// Displayed: Indicates whether the answer/item was displayed to the
7514	// human agent in the agent desktop UI. Default to false.
7515	Displayed bool `json:"displayed,omitempty"`
7516
7517	// ForceSendFields is a list of field names (e.g.
7518	// "AgentAssistantDetailFeedback") to unconditionally include in API
7519	// requests. By default, fields with empty or default values are omitted
7520	// from API requests. However, any non-pointer, non-interface field
7521	// appearing in ForceSendFields will be sent to the server regardless of
7522	// whether the field is empty or not. This may be used to include empty
7523	// fields in Patch requests.
7524	ForceSendFields []string `json:"-"`
7525
7526	// NullFields is a list of field names (e.g.
7527	// "AgentAssistantDetailFeedback") to include in API requests with the
7528	// JSON null value. By default, fields with empty values are omitted
7529	// from API requests. However, any field with an empty value appearing
7530	// in NullFields will be sent to the server as null. It is an error if a
7531	// field in this list has a non-empty value. This may be used to include
7532	// null fields in Patch requests.
7533	NullFields []string `json:"-"`
7534}
7535
7536func (s *GoogleCloudDialogflowV2AnswerFeedback) MarshalJSON() ([]byte, error) {
7537	type NoMethod GoogleCloudDialogflowV2AnswerFeedback
7538	raw := NoMethod(*s)
7539	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
7540}
7541
7542// GoogleCloudDialogflowV2AnswerRecord: Answer records are records to
7543// manage answer history and feedbacks for Dialogflow. Currently, answer
7544// record includes: - human agent assistant article suggestion - human
7545// agent assistant faq article It doesn't include: - `DetectIntent`
7546// intent matching - `DetectIntent` knowledge Answer records are not
7547// related to the conversation history in the Dialogflow Console. A
7548// Record is generated even when the end-user disables conversation
7549// history in the console. Records are created when there's a human
7550// agent assistant suggestion generated. A typical workflow for
7551// customers provide feedback to an answer is: 1. For human agent
7552// assistant, customers get suggestion via ListSuggestions API. Together
7553// with the answers, AnswerRecord.name are returned to the customers. 2.
7554// The customer uses the AnswerRecord.name to call the
7555// UpdateAnswerRecord method to send feedback about a specific answer
7556// that they believe is wrong.
7557type GoogleCloudDialogflowV2AnswerRecord struct {
7558	// AgentAssistantRecord: Output only. The record for human agent
7559	// assistant.
7560	AgentAssistantRecord *GoogleCloudDialogflowV2AgentAssistantRecord `json:"agentAssistantRecord,omitempty"`
7561
7562	// AnswerFeedback: Required. The AnswerFeedback for this record. You can
7563	// set this with AnswerRecords.UpdateAnswerRecord in order to give us
7564	// feedback about this answer.
7565	AnswerFeedback *GoogleCloudDialogflowV2AnswerFeedback `json:"answerFeedback,omitempty"`
7566
7567	// Name: The unique identifier of this answer record. Format:
7568	// `projects//locations//answerRecords/`.
7569	Name string `json:"name,omitempty"`
7570
7571	// ServerResponse contains the HTTP response code and headers from the
7572	// server.
7573	googleapi.ServerResponse `json:"-"`
7574
7575	// ForceSendFields is a list of field names (e.g.
7576	// "AgentAssistantRecord") to unconditionally include in API requests.
7577	// By default, fields with empty or default values are omitted from API
7578	// requests. However, any non-pointer, non-interface field appearing in
7579	// ForceSendFields will be sent to the server regardless of whether the
7580	// field is empty or not. This may be used to include empty fields in
7581	// Patch requests.
7582	ForceSendFields []string `json:"-"`
7583
7584	// NullFields is a list of field names (e.g. "AgentAssistantRecord") to
7585	// include in API requests with the JSON null value. By default, fields
7586	// with empty values are omitted from API requests. However, any field
7587	// with an empty value appearing in NullFields will be sent to the
7588	// server as null. It is an error if a field in this list has a
7589	// non-empty value. This may be used to include null fields in Patch
7590	// requests.
7591	NullFields []string `json:"-"`
7592}
7593
7594func (s *GoogleCloudDialogflowV2AnswerRecord) MarshalJSON() ([]byte, error) {
7595	type NoMethod GoogleCloudDialogflowV2AnswerRecord
7596	raw := NoMethod(*s)
7597	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
7598}
7599
7600// GoogleCloudDialogflowV2ArticleAnswer: Represents article answer.
7601type GoogleCloudDialogflowV2ArticleAnswer struct {
7602	// AnswerRecord: The name of answer record, in the format of
7603	// "projects//locations//answerRecords/"
7604	AnswerRecord string `json:"answerRecord,omitempty"`
7605
7606	// Confidence: Article match confidence. The system's confidence score
7607	// that this article is a good match for this conversation, as a value
7608	// from 0.0 (completely uncertain) to 1.0 (completely certain).
7609	Confidence float64 `json:"confidence,omitempty"`
7610
7611	// Metadata: A map that contains metadata about the answer and the
7612	// document from which it originates.
7613	Metadata map[string]string `json:"metadata,omitempty"`
7614
7615	// Snippets: Article snippets.
7616	Snippets []string `json:"snippets,omitempty"`
7617
7618	// Title: The article title.
7619	Title string `json:"title,omitempty"`
7620
7621	// Uri: The article URI.
7622	Uri string `json:"uri,omitempty"`
7623
7624	// ForceSendFields is a list of field names (e.g. "AnswerRecord") to
7625	// unconditionally include in API requests. By default, fields with
7626	// empty or default values are omitted from API requests. However, any
7627	// non-pointer, non-interface field appearing in ForceSendFields will be
7628	// sent to the server regardless of whether the field is empty or not.
7629	// This may be used to include empty fields in Patch requests.
7630	ForceSendFields []string `json:"-"`
7631
7632	// NullFields is a list of field names (e.g. "AnswerRecord") to include
7633	// in API requests with the JSON null value. By default, fields with
7634	// empty values are omitted from API requests. However, any field with
7635	// an empty value appearing in NullFields will be sent to the server as
7636	// null. It is an error if a field in this list has a non-empty value.
7637	// This may be used to include null fields in Patch requests.
7638	NullFields []string `json:"-"`
7639}
7640
7641func (s *GoogleCloudDialogflowV2ArticleAnswer) MarshalJSON() ([]byte, error) {
7642	type NoMethod GoogleCloudDialogflowV2ArticleAnswer
7643	raw := NoMethod(*s)
7644	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
7645}
7646
7647func (s *GoogleCloudDialogflowV2ArticleAnswer) UnmarshalJSON(data []byte) error {
7648	type NoMethod GoogleCloudDialogflowV2ArticleAnswer
7649	var s1 struct {
7650		Confidence gensupport.JSONFloat64 `json:"confidence"`
7651		*NoMethod
7652	}
7653	s1.NoMethod = (*NoMethod)(s)
7654	if err := json.Unmarshal(data, &s1); err != nil {
7655		return err
7656	}
7657	s.Confidence = float64(s1.Confidence)
7658	return nil
7659}
7660
7661// GoogleCloudDialogflowV2AutomatedAgentConfig: Defines the Automated
7662// Agent to connect to a conversation.
7663type GoogleCloudDialogflowV2AutomatedAgentConfig struct {
7664	// Agent: Required. ID of the Dialogflow agent environment to use. This
7665	// project needs to either be the same project as the conversation or
7666	// you need to grant
7667	// `service-@gcp-sa-dialogflow.iam.gserviceaccount.com` the `Dialogflow
7668	// API Service Agent` role in this project. Format:
7669	// `projects//locations//agent/environments/`. If environment is not
7670	// specified, the default `draft` environment is used. Refer to
7671	// DetectIntentRequest
7672	// (/dialogflow/docs/reference/rpc/google.cloud.dialogflow.v2#google.clou
7673	// d.dialogflow.v2.DetectIntentRequest) for more details.
7674	Agent string `json:"agent,omitempty"`
7675
7676	// ForceSendFields is a list of field names (e.g. "Agent") to
7677	// unconditionally include in API requests. By default, fields with
7678	// empty or default values are omitted from API requests. However, any
7679	// non-pointer, non-interface field appearing in ForceSendFields will be
7680	// sent to the server regardless of whether the field is empty or not.
7681	// This may be used to include empty fields in Patch requests.
7682	ForceSendFields []string `json:"-"`
7683
7684	// NullFields is a list of field names (e.g. "Agent") to include in API
7685	// requests with the JSON null value. By default, fields with empty
7686	// values are omitted from API requests. However, any field with an
7687	// empty value appearing in NullFields will be sent to the server as
7688	// null. It is an error if a field in this list has a non-empty value.
7689	// This may be used to include null fields in Patch requests.
7690	NullFields []string `json:"-"`
7691}
7692
7693func (s *GoogleCloudDialogflowV2AutomatedAgentConfig) MarshalJSON() ([]byte, error) {
7694	type NoMethod GoogleCloudDialogflowV2AutomatedAgentConfig
7695	raw := NoMethod(*s)
7696	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
7697}
7698
7699// GoogleCloudDialogflowV2AutomatedAgentReply: Represents a response
7700// from an automated agent.
7701type GoogleCloudDialogflowV2AutomatedAgentReply struct {
7702	// AllowCancellation: Indicates whether the partial automated agent
7703	// reply is interruptible when a later reply message arrives. e.g. if
7704	// the agent specified some music as partial response, it can be
7705	// cancelled.
7706	AllowCancellation bool `json:"allowCancellation,omitempty"`
7707
7708	// AutomatedAgentReplyType: AutomatedAgentReply type.
7709	//
7710	// Possible values:
7711	//   "AUTOMATED_AGENT_REPLY_TYPE_UNSPECIFIED" - Not specified. This
7712	// should never happen.
7713	//   "PARTIAL" - Partial reply. e.g. Aggregated responses in a
7714	// `Fulfillment` that enables `return_partial_response` can be returned
7715	// as partial reply. WARNING: partial reply is not eligible for
7716	// barge-in.
7717	//   "FINAL" - Final reply.
7718	AutomatedAgentReplyType string `json:"automatedAgentReplyType,omitempty"`
7719
7720	// DetectIntentResponse: Response of the Dialogflow
7721	// Sessions.DetectIntent call.
7722	DetectIntentResponse *GoogleCloudDialogflowV2DetectIntentResponse `json:"detectIntentResponse,omitempty"`
7723
7724	// ForceSendFields is a list of field names (e.g. "AllowCancellation")
7725	// to unconditionally include in API requests. By default, fields with
7726	// empty or default values are omitted from API requests. However, any
7727	// non-pointer, non-interface field appearing in ForceSendFields will be
7728	// sent to the server regardless of whether the field is empty or not.
7729	// This may be used to include empty fields in Patch requests.
7730	ForceSendFields []string `json:"-"`
7731
7732	// NullFields is a list of field names (e.g. "AllowCancellation") to
7733	// include in API requests with the JSON null value. By default, fields
7734	// with empty values are omitted from API requests. However, any field
7735	// with an empty value appearing in NullFields will be sent to the
7736	// server as null. It is an error if a field in this list has a
7737	// non-empty value. This may be used to include null fields in Patch
7738	// requests.
7739	NullFields []string `json:"-"`
7740}
7741
7742func (s *GoogleCloudDialogflowV2AutomatedAgentReply) MarshalJSON() ([]byte, error) {
7743	type NoMethod GoogleCloudDialogflowV2AutomatedAgentReply
7744	raw := NoMethod(*s)
7745	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
7746}
7747
7748// GoogleCloudDialogflowV2BatchCreateEntitiesRequest: The request
7749// message for EntityTypes.BatchCreateEntities.
7750type GoogleCloudDialogflowV2BatchCreateEntitiesRequest struct {
7751	// Entities: Required. The entities to create.
7752	Entities []*GoogleCloudDialogflowV2EntityTypeEntity `json:"entities,omitempty"`
7753
7754	// LanguageCode: Optional. The language used to access language-specific
7755	// data. If not specified, the agent's default language is used. For
7756	// more information, see Multilingual intent and entity data
7757	// (https://cloud.google.com/dialogflow/docs/agents-multilingual#intent-entity).
7758	LanguageCode string `json:"languageCode,omitempty"`
7759
7760	// ForceSendFields is a list of field names (e.g. "Entities") to
7761	// unconditionally include in API requests. By default, fields with
7762	// empty or default values are omitted from API requests. However, any
7763	// non-pointer, non-interface field appearing in ForceSendFields will be
7764	// sent to the server regardless of whether the field is empty or not.
7765	// This may be used to include empty fields in Patch requests.
7766	ForceSendFields []string `json:"-"`
7767
7768	// NullFields is a list of field names (e.g. "Entities") to include in
7769	// API requests with the JSON null value. By default, fields with empty
7770	// values are omitted from API requests. However, any field with an
7771	// empty value appearing in NullFields will be sent to the server as
7772	// null. It is an error if a field in this list has a non-empty value.
7773	// This may be used to include null fields in Patch requests.
7774	NullFields []string `json:"-"`
7775}
7776
7777func (s *GoogleCloudDialogflowV2BatchCreateEntitiesRequest) MarshalJSON() ([]byte, error) {
7778	type NoMethod GoogleCloudDialogflowV2BatchCreateEntitiesRequest
7779	raw := NoMethod(*s)
7780	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
7781}
7782
7783// GoogleCloudDialogflowV2BatchDeleteEntitiesRequest: The request
7784// message for EntityTypes.BatchDeleteEntities.
7785type GoogleCloudDialogflowV2BatchDeleteEntitiesRequest struct {
7786	// EntityValues: Required. The reference `values` of the entities to
7787	// delete. Note that these are not fully-qualified names, i.e. they
7788	// don't start with `projects/`.
7789	EntityValues []string `json:"entityValues,omitempty"`
7790
7791	// LanguageCode: Optional. The language used to access language-specific
7792	// data. If not specified, the agent's default language is used. For
7793	// more information, see Multilingual intent and entity data
7794	// (https://cloud.google.com/dialogflow/docs/agents-multilingual#intent-entity).
7795	LanguageCode string `json:"languageCode,omitempty"`
7796
7797	// ForceSendFields is a list of field names (e.g. "EntityValues") to
7798	// unconditionally include in API requests. By default, fields with
7799	// empty or default values are omitted from API requests. However, any
7800	// non-pointer, non-interface field appearing in ForceSendFields will be
7801	// sent to the server regardless of whether the field is empty or not.
7802	// This may be used to include empty fields in Patch requests.
7803	ForceSendFields []string `json:"-"`
7804
7805	// NullFields is a list of field names (e.g. "EntityValues") to include
7806	// in API requests with the JSON null value. By default, fields with
7807	// empty values are omitted from API requests. However, any field with
7808	// an empty value appearing in NullFields will be sent to the server as
7809	// null. It is an error if a field in this list has a non-empty value.
7810	// This may be used to include null fields in Patch requests.
7811	NullFields []string `json:"-"`
7812}
7813
7814func (s *GoogleCloudDialogflowV2BatchDeleteEntitiesRequest) MarshalJSON() ([]byte, error) {
7815	type NoMethod GoogleCloudDialogflowV2BatchDeleteEntitiesRequest
7816	raw := NoMethod(*s)
7817	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
7818}
7819
7820// GoogleCloudDialogflowV2BatchDeleteEntityTypesRequest: The request
7821// message for EntityTypes.BatchDeleteEntityTypes.
7822type GoogleCloudDialogflowV2BatchDeleteEntityTypesRequest struct {
7823	// EntityTypeNames: Required. The names entity types to delete. All
7824	// names must point to the same agent as `parent`.
7825	EntityTypeNames []string `json:"entityTypeNames,omitempty"`
7826
7827	// ForceSendFields is a list of field names (e.g. "EntityTypeNames") to
7828	// unconditionally include in API requests. By default, fields with
7829	// empty or default values are omitted from API requests. However, any
7830	// non-pointer, non-interface field appearing in ForceSendFields will be
7831	// sent to the server regardless of whether the field is empty or not.
7832	// This may be used to include empty fields in Patch requests.
7833	ForceSendFields []string `json:"-"`
7834
7835	// NullFields is a list of field names (e.g. "EntityTypeNames") to
7836	// include in API requests with the JSON null value. By default, fields
7837	// with empty values are omitted from API requests. However, any field
7838	// with an empty value appearing in NullFields will be sent to the
7839	// server as null. It is an error if a field in this list has a
7840	// non-empty value. This may be used to include null fields in Patch
7841	// requests.
7842	NullFields []string `json:"-"`
7843}
7844
7845func (s *GoogleCloudDialogflowV2BatchDeleteEntityTypesRequest) MarshalJSON() ([]byte, error) {
7846	type NoMethod GoogleCloudDialogflowV2BatchDeleteEntityTypesRequest
7847	raw := NoMethod(*s)
7848	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
7849}
7850
7851// GoogleCloudDialogflowV2BatchDeleteIntentsRequest: The request message
7852// for Intents.BatchDeleteIntents.
7853type GoogleCloudDialogflowV2BatchDeleteIntentsRequest struct {
7854	// Intents: Required. The collection of intents to delete. Only intent
7855	// `name` must be filled in.
7856	Intents []*GoogleCloudDialogflowV2Intent `json:"intents,omitempty"`
7857
7858	// ForceSendFields is a list of field names (e.g. "Intents") to
7859	// unconditionally include in API requests. By default, fields with
7860	// empty or default values are omitted from API requests. However, any
7861	// non-pointer, non-interface field appearing in ForceSendFields will be
7862	// sent to the server regardless of whether the field is empty or not.
7863	// This may be used to include empty fields in Patch requests.
7864	ForceSendFields []string `json:"-"`
7865
7866	// NullFields is a list of field names (e.g. "Intents") to include in
7867	// API requests with the JSON null value. By default, fields with empty
7868	// values are omitted from API requests. However, any field with an
7869	// empty value appearing in NullFields will be sent to the server as
7870	// null. It is an error if a field in this list has a non-empty value.
7871	// This may be used to include null fields in Patch requests.
7872	NullFields []string `json:"-"`
7873}
7874
7875func (s *GoogleCloudDialogflowV2BatchDeleteIntentsRequest) MarshalJSON() ([]byte, error) {
7876	type NoMethod GoogleCloudDialogflowV2BatchDeleteIntentsRequest
7877	raw := NoMethod(*s)
7878	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
7879}
7880
7881// GoogleCloudDialogflowV2BatchUpdateEntitiesRequest: The request
7882// message for EntityTypes.BatchUpdateEntities.
7883type GoogleCloudDialogflowV2BatchUpdateEntitiesRequest struct {
7884	// Entities: Required. The entities to update or create.
7885	Entities []*GoogleCloudDialogflowV2EntityTypeEntity `json:"entities,omitempty"`
7886
7887	// LanguageCode: Optional. The language used to access language-specific
7888	// data. If not specified, the agent's default language is used. For
7889	// more information, see Multilingual intent and entity data
7890	// (https://cloud.google.com/dialogflow/docs/agents-multilingual#intent-entity).
7891	LanguageCode string `json:"languageCode,omitempty"`
7892
7893	// UpdateMask: Optional. The mask to control which fields get updated.
7894	UpdateMask string `json:"updateMask,omitempty"`
7895
7896	// ForceSendFields is a list of field names (e.g. "Entities") to
7897	// unconditionally include in API requests. By default, fields with
7898	// empty or default values are omitted from API requests. However, any
7899	// non-pointer, non-interface field appearing in ForceSendFields will be
7900	// sent to the server regardless of whether the field is empty or not.
7901	// This may be used to include empty fields in Patch requests.
7902	ForceSendFields []string `json:"-"`
7903
7904	// NullFields is a list of field names (e.g. "Entities") to include in
7905	// API requests with the JSON null value. By default, fields with empty
7906	// values are omitted from API requests. However, any field with an
7907	// empty value appearing in NullFields will be sent to the server as
7908	// null. It is an error if a field in this list has a non-empty value.
7909	// This may be used to include null fields in Patch requests.
7910	NullFields []string `json:"-"`
7911}
7912
7913func (s *GoogleCloudDialogflowV2BatchUpdateEntitiesRequest) MarshalJSON() ([]byte, error) {
7914	type NoMethod GoogleCloudDialogflowV2BatchUpdateEntitiesRequest
7915	raw := NoMethod(*s)
7916	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
7917}
7918
7919// GoogleCloudDialogflowV2BatchUpdateEntityTypesRequest: The request
7920// message for EntityTypes.BatchUpdateEntityTypes.
7921type GoogleCloudDialogflowV2BatchUpdateEntityTypesRequest struct {
7922	// EntityTypeBatchInline: The collection of entity types to update or
7923	// create.
7924	EntityTypeBatchInline *GoogleCloudDialogflowV2EntityTypeBatch `json:"entityTypeBatchInline,omitempty"`
7925
7926	// EntityTypeBatchUri: The URI to a Google Cloud Storage file containing
7927	// entity types to update or create. The file format can either be a
7928	// serialized proto (of EntityBatch type) or a JSON object. Note: The
7929	// URI must start with "gs://".
7930	EntityTypeBatchUri string `json:"entityTypeBatchUri,omitempty"`
7931
7932	// LanguageCode: Optional. The language used to access language-specific
7933	// data. If not specified, the agent's default language is used. For
7934	// more information, see Multilingual intent and entity data
7935	// (https://cloud.google.com/dialogflow/docs/agents-multilingual#intent-entity).
7936	LanguageCode string `json:"languageCode,omitempty"`
7937
7938	// UpdateMask: Optional. The mask to control which fields get updated.
7939	UpdateMask string `json:"updateMask,omitempty"`
7940
7941	// ForceSendFields is a list of field names (e.g.
7942	// "EntityTypeBatchInline") to unconditionally include in API requests.
7943	// By default, fields with empty or default values are omitted from API
7944	// requests. However, any non-pointer, non-interface field appearing in
7945	// ForceSendFields will be sent to the server regardless of whether the
7946	// field is empty or not. This may be used to include empty fields in
7947	// Patch requests.
7948	ForceSendFields []string `json:"-"`
7949
7950	// NullFields is a list of field names (e.g. "EntityTypeBatchInline") to
7951	// include in API requests with the JSON null value. By default, fields
7952	// with empty values are omitted from API requests. However, any field
7953	// with an empty value appearing in NullFields will be sent to the
7954	// server as null. It is an error if a field in this list has a
7955	// non-empty value. This may be used to include null fields in Patch
7956	// requests.
7957	NullFields []string `json:"-"`
7958}
7959
7960func (s *GoogleCloudDialogflowV2BatchUpdateEntityTypesRequest) MarshalJSON() ([]byte, error) {
7961	type NoMethod GoogleCloudDialogflowV2BatchUpdateEntityTypesRequest
7962	raw := NoMethod(*s)
7963	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
7964}
7965
7966// GoogleCloudDialogflowV2BatchUpdateEntityTypesResponse: The response
7967// message for EntityTypes.BatchUpdateEntityTypes.
7968type GoogleCloudDialogflowV2BatchUpdateEntityTypesResponse struct {
7969	// EntityTypes: The collection of updated or created entity types.
7970	EntityTypes []*GoogleCloudDialogflowV2EntityType `json:"entityTypes,omitempty"`
7971
7972	// ForceSendFields is a list of field names (e.g. "EntityTypes") to
7973	// unconditionally include in API requests. By default, fields with
7974	// empty or default values are omitted from API requests. However, any
7975	// non-pointer, non-interface field appearing in ForceSendFields will be
7976	// sent to the server regardless of whether the field is empty or not.
7977	// This may be used to include empty fields in Patch requests.
7978	ForceSendFields []string `json:"-"`
7979
7980	// NullFields is a list of field names (e.g. "EntityTypes") to include
7981	// in API requests with the JSON null value. By default, fields with
7982	// empty values are omitted from API requests. However, any field with
7983	// an empty value appearing in NullFields will be sent to the server as
7984	// null. It is an error if a field in this list has a non-empty value.
7985	// This may be used to include null fields in Patch requests.
7986	NullFields []string `json:"-"`
7987}
7988
7989func (s *GoogleCloudDialogflowV2BatchUpdateEntityTypesResponse) MarshalJSON() ([]byte, error) {
7990	type NoMethod GoogleCloudDialogflowV2BatchUpdateEntityTypesResponse
7991	raw := NoMethod(*s)
7992	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
7993}
7994
7995type GoogleCloudDialogflowV2BatchUpdateIntentsRequest struct {
7996	// IntentBatchInline: The collection of intents to update or create.
7997	IntentBatchInline *GoogleCloudDialogflowV2IntentBatch `json:"intentBatchInline,omitempty"`
7998
7999	// IntentBatchUri: The URI to a Google Cloud Storage file containing
8000	// intents to update or create. The file format can either be a
8001	// serialized proto (of IntentBatch type) or JSON object. Note: The URI
8002	// must start with "gs://".
8003	IntentBatchUri string `json:"intentBatchUri,omitempty"`
8004
8005	// IntentView: Optional. The resource view to apply to the returned
8006	// intent.
8007	//
8008	// Possible values:
8009	//   "INTENT_VIEW_UNSPECIFIED" - Training phrases field is not populated
8010	// in the response.
8011	//   "INTENT_VIEW_FULL" - All fields are populated.
8012	IntentView string `json:"intentView,omitempty"`
8013
8014	// LanguageCode: Optional. The language used to access language-specific
8015	// data. If not specified, the agent's default language is used. For
8016	// more information, see Multilingual intent and entity data
8017	// (https://cloud.google.com/dialogflow/docs/agents-multilingual#intent-entity).
8018	LanguageCode string `json:"languageCode,omitempty"`
8019
8020	// UpdateMask: Optional. The mask to control which fields get updated.
8021	UpdateMask string `json:"updateMask,omitempty"`
8022
8023	// ForceSendFields is a list of field names (e.g. "IntentBatchInline")
8024	// to unconditionally include in API requests. By default, fields with
8025	// empty or default values are omitted from API requests. However, any
8026	// non-pointer, non-interface field appearing in ForceSendFields will be
8027	// sent to the server regardless of whether the field is empty or not.
8028	// This may be used to include empty fields in Patch requests.
8029	ForceSendFields []string `json:"-"`
8030
8031	// NullFields is a list of field names (e.g. "IntentBatchInline") to
8032	// include in API requests with the JSON null value. By default, fields
8033	// with empty values are omitted from API requests. However, any field
8034	// with an empty value appearing in NullFields will be sent to the
8035	// server as null. It is an error if a field in this list has a
8036	// non-empty value. This may be used to include null fields in Patch
8037	// requests.
8038	NullFields []string `json:"-"`
8039}
8040
8041func (s *GoogleCloudDialogflowV2BatchUpdateIntentsRequest) MarshalJSON() ([]byte, error) {
8042	type NoMethod GoogleCloudDialogflowV2BatchUpdateIntentsRequest
8043	raw := NoMethod(*s)
8044	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
8045}
8046
8047// GoogleCloudDialogflowV2BatchUpdateIntentsResponse: The response
8048// message for Intents.BatchUpdateIntents.
8049type GoogleCloudDialogflowV2BatchUpdateIntentsResponse struct {
8050	// Intents: The collection of updated or created intents.
8051	Intents []*GoogleCloudDialogflowV2Intent `json:"intents,omitempty"`
8052
8053	// ForceSendFields is a list of field names (e.g. "Intents") to
8054	// unconditionally include in API requests. By default, fields with
8055	// empty or default values are omitted from API requests. However, any
8056	// non-pointer, non-interface field appearing in ForceSendFields will be
8057	// sent to the server regardless of whether the field is empty or not.
8058	// This may be used to include empty fields in Patch requests.
8059	ForceSendFields []string `json:"-"`
8060
8061	// NullFields is a list of field names (e.g. "Intents") to include in
8062	// API requests with the JSON null value. By default, fields with empty
8063	// values are omitted from API requests. However, any field with an
8064	// empty value appearing in NullFields will be sent to the server as
8065	// null. It is an error if a field in this list has a non-empty value.
8066	// This may be used to include null fields in Patch requests.
8067	NullFields []string `json:"-"`
8068}
8069
8070func (s *GoogleCloudDialogflowV2BatchUpdateIntentsResponse) MarshalJSON() ([]byte, error) {
8071	type NoMethod GoogleCloudDialogflowV2BatchUpdateIntentsResponse
8072	raw := NoMethod(*s)
8073	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
8074}
8075
8076// GoogleCloudDialogflowV2CompleteConversationRequest: The request
8077// message for Conversations.CompleteConversation.
8078type GoogleCloudDialogflowV2CompleteConversationRequest struct {
8079}
8080
8081// GoogleCloudDialogflowV2Context: Dialogflow contexts are similar to
8082// natural language context. If a person says to you "they are orange",
8083// you need context in order to understand what "they" is referring to.
8084// Similarly, for Dialogflow to handle an end-user expression like that,
8085// it needs to be provided with context in order to correctly match an
8086// intent. Using contexts, you can control the flow of a conversation.
8087// You can configure contexts for an intent by setting input and output
8088// contexts, which are identified by string names. When an intent is
8089// matched, any configured output contexts for that intent become
8090// active. While any contexts are active, Dialogflow is more likely to
8091// match intents that are configured with input contexts that correspond
8092// to the currently active contexts. For more information about context,
8093// see the Contexts guide
8094// (https://cloud.google.com/dialogflow/docs/contexts-overview).
8095type GoogleCloudDialogflowV2Context struct {
8096	// LifespanCount: Optional. The number of conversational query requests
8097	// after which the context expires. The default is `0`. If set to `0`,
8098	// the context expires immediately. Contexts expire automatically after
8099	// 20 minutes if there are no matching queries.
8100	LifespanCount int64 `json:"lifespanCount,omitempty"`
8101
8102	// Name: Required. The unique identifier of the context. Format:
8103	// `projects//agent/sessions//contexts/`, or
8104	// `projects//agent/environments//users//sessions//contexts/`. The
8105	// `Context ID` is always converted to lowercase, may only contain
8106	// characters in a-zA-Z0-9_-% and may be at most 250 bytes long. If
8107	// `Environment ID` is not specified, we assume default 'draft'
8108	// environment. If `User ID` is not specified, we assume default '-'
8109	// user. The following context names are reserved for internal use by
8110	// Dialogflow. You should not use these contexts or create contexts with
8111	// these names: * `__system_counters__` * `*_id_dialog_context` *
8112	// `*_dialog_params_size`
8113	Name string `json:"name,omitempty"`
8114
8115	// Parameters: Optional. The collection of parameters associated with
8116	// this context. Depending on your protocol or client library language,
8117	// this is a map, associative array, symbol table, dictionary, or JSON
8118	// object composed of a collection of (MapKey, MapValue) pairs: - MapKey
8119	// type: string - MapKey value: parameter name - MapValue type: - If
8120	// parameter's entity type is a composite entity: map - Else: depending
8121	// on parameter value type, could be one of string, number, boolean,
8122	// null, list or map - MapValue value: - If parameter's entity type is a
8123	// composite entity: map from composite entity property names to
8124	// property values - Else: parameter value
8125	Parameters googleapi.RawMessage `json:"parameters,omitempty"`
8126
8127	// ServerResponse contains the HTTP response code and headers from the
8128	// server.
8129	googleapi.ServerResponse `json:"-"`
8130
8131	// ForceSendFields is a list of field names (e.g. "LifespanCount") to
8132	// unconditionally include in API requests. By default, fields with
8133	// empty or default values are omitted from API requests. However, any
8134	// non-pointer, non-interface field appearing in ForceSendFields will be
8135	// sent to the server regardless of whether the field is empty or not.
8136	// This may be used to include empty fields in Patch requests.
8137	ForceSendFields []string `json:"-"`
8138
8139	// NullFields is a list of field names (e.g. "LifespanCount") to include
8140	// in API requests with the JSON null value. By default, fields with
8141	// empty values are omitted from API requests. However, any field with
8142	// an empty value appearing in NullFields will be sent to the server as
8143	// null. It is an error if a field in this list has a non-empty value.
8144	// This may be used to include null fields in Patch requests.
8145	NullFields []string `json:"-"`
8146}
8147
8148func (s *GoogleCloudDialogflowV2Context) MarshalJSON() ([]byte, error) {
8149	type NoMethod GoogleCloudDialogflowV2Context
8150	raw := NoMethod(*s)
8151	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
8152}
8153
8154// GoogleCloudDialogflowV2Conversation: Represents a conversation. A
8155// conversation is an interaction between an agent, including live
8156// agents and Dialogflow agents, and a support customer. Conversations
8157// can include phone calls and text-based chat sessions.
8158type GoogleCloudDialogflowV2Conversation struct {
8159	// ConversationProfile: Required. The Conversation Profile to be used to
8160	// configure this Conversation. This field cannot be updated. Format:
8161	// `projects//locations//conversationProfiles/`.
8162	ConversationProfile string `json:"conversationProfile,omitempty"`
8163
8164	// ConversationStage: The stage of a conversation. It indicates whether
8165	// the virtual agent or a human agent is handling the conversation. If
8166	// the conversation is created with the conversation profile that has
8167	// Dialogflow config set, defaults to
8168	// ConversationStage.VIRTUAL_AGENT_STAGE; Otherwise, defaults to
8169	// ConversationStage.HUMAN_ASSIST_STAGE. If the conversation is created
8170	// with the conversation profile that has Dialogflow config set but
8171	// explicitly sets conversation_stage to
8172	// ConversationStage.HUMAN_ASSIST_STAGE, it skips
8173	// ConversationStage.VIRTUAL_AGENT_STAGE stage and directly goes to
8174	// ConversationStage.HUMAN_ASSIST_STAGE.
8175	//
8176	// Possible values:
8177	//   "CONVERSATION_STAGE_UNSPECIFIED" - Unknown. Should never be used
8178	// after a conversation is successfully created.
8179	//   "VIRTUAL_AGENT_STAGE" - The conversation should return virtual
8180	// agent responses into the conversation.
8181	//   "HUMAN_ASSIST_STAGE" - The conversation should not provide
8182	// responses, just listen and provide suggestions.
8183	ConversationStage string `json:"conversationStage,omitempty"`
8184
8185	// EndTime: Output only. The time the conversation was finished.
8186	EndTime string `json:"endTime,omitempty"`
8187
8188	// LifecycleState: Output only. The current state of the Conversation.
8189	//
8190	// Possible values:
8191	//   "LIFECYCLE_STATE_UNSPECIFIED" - Unknown.
8192	//   "IN_PROGRESS" - Conversation is currently open for media analysis.
8193	//   "COMPLETED" - Conversation has been completed.
8194	LifecycleState string `json:"lifecycleState,omitempty"`
8195
8196	// Name: Output only. The unique identifier of this conversation.
8197	// Format: `projects//locations//conversations/`.
8198	Name string `json:"name,omitempty"`
8199
8200	// PhoneNumber: Output only. It will not be empty if the conversation is
8201	// to be connected over telephony.
8202	PhoneNumber *GoogleCloudDialogflowV2ConversationPhoneNumber `json:"phoneNumber,omitempty"`
8203
8204	// StartTime: Output only. The time the conversation was started.
8205	StartTime string `json:"startTime,omitempty"`
8206
8207	// ServerResponse contains the HTTP response code and headers from the
8208	// server.
8209	googleapi.ServerResponse `json:"-"`
8210
8211	// ForceSendFields is a list of field names (e.g. "ConversationProfile")
8212	// to unconditionally include in API requests. By default, fields with
8213	// empty or default values are omitted from API requests. However, any
8214	// non-pointer, non-interface field appearing in ForceSendFields will be
8215	// sent to the server regardless of whether the field is empty or not.
8216	// This may be used to include empty fields in Patch requests.
8217	ForceSendFields []string `json:"-"`
8218
8219	// NullFields is a list of field names (e.g. "ConversationProfile") to
8220	// include in API requests with the JSON null value. By default, fields
8221	// with empty values are omitted from API requests. However, any field
8222	// with an empty value appearing in NullFields will be sent to the
8223	// server as null. It is an error if a field in this list has a
8224	// non-empty value. This may be used to include null fields in Patch
8225	// requests.
8226	NullFields []string `json:"-"`
8227}
8228
8229func (s *GoogleCloudDialogflowV2Conversation) MarshalJSON() ([]byte, error) {
8230	type NoMethod GoogleCloudDialogflowV2Conversation
8231	raw := NoMethod(*s)
8232	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
8233}
8234
8235// GoogleCloudDialogflowV2ConversationEvent: Represents a notification
8236// sent to Pub/Sub subscribers for conversation lifecycle events.
8237type GoogleCloudDialogflowV2ConversationEvent struct {
8238	// Conversation: The unique identifier of the conversation this
8239	// notification refers to. Format: `projects//conversations/`.
8240	Conversation string `json:"conversation,omitempty"`
8241
8242	// ErrorStatus: More detailed information about an error. Only set for
8243	// type UNRECOVERABLE_ERROR_IN_PHONE_CALL.
8244	ErrorStatus *GoogleRpcStatus `json:"errorStatus,omitempty"`
8245
8246	// NewMessagePayload: Payload of NEW_MESSAGE event.
8247	NewMessagePayload *GoogleCloudDialogflowV2Message `json:"newMessagePayload,omitempty"`
8248
8249	// Type: The type of the event that this notification refers to.
8250	//
8251	// Possible values:
8252	//   "TYPE_UNSPECIFIED" - Type not set.
8253	//   "CONVERSATION_STARTED" - A new conversation has been opened. This
8254	// is fired when a telephone call is answered, or a conversation is
8255	// created via the API.
8256	//   "CONVERSATION_FINISHED" - An existing conversation has closed. This
8257	// is fired when a telephone call is terminated, or a conversation is
8258	// closed via the API.
8259	//   "HUMAN_INTERVENTION_NEEDED" - An existing conversation has received
8260	// notification from Dialogflow that human intervention is required.
8261	//   "NEW_MESSAGE" - An existing conversation has received a new
8262	// message, either from API or telephony. It is configured in
8263	// ConversationProfile.new_message_event_notification_config
8264	//   "UNRECOVERABLE_ERROR" - Unrecoverable error during a telephone
8265	// call. In general non-recoverable errors only occur if something was
8266	// misconfigured in the ConversationProfile corresponding to the call.
8267	// After a non-recoverable error, Dialogflow may stop responding. We
8268	// don't fire this event: * in an API call because we can directly
8269	// return the error, or, * when we can recover from an error.
8270	Type string `json:"type,omitempty"`
8271
8272	// ForceSendFields is a list of field names (e.g. "Conversation") to
8273	// unconditionally include in API requests. By default, fields with
8274	// empty or default values are omitted from API requests. However, any
8275	// non-pointer, non-interface field appearing in ForceSendFields will be
8276	// sent to the server regardless of whether the field is empty or not.
8277	// This may be used to include empty fields in Patch requests.
8278	ForceSendFields []string `json:"-"`
8279
8280	// NullFields is a list of field names (e.g. "Conversation") to include
8281	// in API requests with the JSON null value. By default, fields with
8282	// empty values are omitted from API requests. However, any field with
8283	// an empty value appearing in NullFields will be sent to the server as
8284	// null. It is an error if a field in this list has a non-empty value.
8285	// This may be used to include null fields in Patch requests.
8286	NullFields []string `json:"-"`
8287}
8288
8289func (s *GoogleCloudDialogflowV2ConversationEvent) MarshalJSON() ([]byte, error) {
8290	type NoMethod GoogleCloudDialogflowV2ConversationEvent
8291	raw := NoMethod(*s)
8292	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
8293}
8294
8295// GoogleCloudDialogflowV2ConversationPhoneNumber: Represents a phone
8296// number for telephony integration. It allows for connecting a
8297// particular conversation over telephony.
8298type GoogleCloudDialogflowV2ConversationPhoneNumber struct {
8299	// PhoneNumber: Output only. The phone number to connect to this
8300	// conversation.
8301	PhoneNumber string `json:"phoneNumber,omitempty"`
8302
8303	// ForceSendFields is a list of field names (e.g. "PhoneNumber") to
8304	// unconditionally include in API requests. By default, fields with
8305	// empty or default values are omitted from API requests. However, any
8306	// non-pointer, non-interface field appearing in ForceSendFields will be
8307	// sent to the server regardless of whether the field is empty or not.
8308	// This may be used to include empty fields in Patch requests.
8309	ForceSendFields []string `json:"-"`
8310
8311	// NullFields is a list of field names (e.g. "PhoneNumber") to include
8312	// in API requests with the JSON null value. By default, fields with
8313	// empty values are omitted from API requests. However, any field with
8314	// an empty value appearing in NullFields will be sent to the server as
8315	// null. It is an error if a field in this list has a non-empty value.
8316	// This may be used to include null fields in Patch requests.
8317	NullFields []string `json:"-"`
8318}
8319
8320func (s *GoogleCloudDialogflowV2ConversationPhoneNumber) MarshalJSON() ([]byte, error) {
8321	type NoMethod GoogleCloudDialogflowV2ConversationPhoneNumber
8322	raw := NoMethod(*s)
8323	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
8324}
8325
8326// GoogleCloudDialogflowV2ConversationProfile: Defines the services to
8327// connect to incoming Dialogflow conversations.
8328type GoogleCloudDialogflowV2ConversationProfile struct {
8329	// AutomatedAgentConfig: Configuration for an automated agent to use
8330	// with this profile.
8331	AutomatedAgentConfig *GoogleCloudDialogflowV2AutomatedAgentConfig `json:"automatedAgentConfig,omitempty"`
8332
8333	// CreateTime: Output only. Create time of the conversation profile.
8334	CreateTime string `json:"createTime,omitempty"`
8335
8336	// DisplayName: Required. Human readable name for this profile. Max
8337	// length 1024 bytes.
8338	DisplayName string `json:"displayName,omitempty"`
8339
8340	// HumanAgentAssistantConfig: Configuration for agent assistance to use
8341	// with this profile.
8342	HumanAgentAssistantConfig *GoogleCloudDialogflowV2HumanAgentAssistantConfig `json:"humanAgentAssistantConfig,omitempty"`
8343
8344	// HumanAgentHandoffConfig: Configuration for connecting to a live
8345	// agent. Currently, this feature is not general available, please
8346	// contact Google to get access.
8347	HumanAgentHandoffConfig *GoogleCloudDialogflowV2HumanAgentHandoffConfig `json:"humanAgentHandoffConfig,omitempty"`
8348
8349	// LanguageCode: Language which represents the conversationProfile. If
8350	// unspecified, the default language code en-us applies. Users need to
8351	// create a ConversationProfile for each language they want to support.
8352	LanguageCode string `json:"languageCode,omitempty"`
8353
8354	// LoggingConfig: Configuration for logging conversation lifecycle
8355	// events.
8356	LoggingConfig *GoogleCloudDialogflowV2LoggingConfig `json:"loggingConfig,omitempty"`
8357
8358	// Name: The unique identifier of this conversation profile. Format:
8359	// `projects//locations//conversationProfiles/`.
8360	Name string `json:"name,omitempty"`
8361
8362	// NewMessageEventNotificationConfig: Configuration for publishing new
8363	// message events. Event will be sent in format of ConversationEvent
8364	NewMessageEventNotificationConfig *GoogleCloudDialogflowV2NotificationConfig `json:"newMessageEventNotificationConfig,omitempty"`
8365
8366	// NotificationConfig: Configuration for publishing conversation
8367	// lifecycle events.
8368	NotificationConfig *GoogleCloudDialogflowV2NotificationConfig `json:"notificationConfig,omitempty"`
8369
8370	// SttConfig: Settings for speech transcription.
8371	SttConfig *GoogleCloudDialogflowV2SpeechToTextConfig `json:"sttConfig,omitempty"`
8372
8373	// UpdateTime: Output only. Update time of the conversation profile.
8374	UpdateTime string `json:"updateTime,omitempty"`
8375
8376	// ServerResponse contains the HTTP response code and headers from the
8377	// server.
8378	googleapi.ServerResponse `json:"-"`
8379
8380	// ForceSendFields is a list of field names (e.g.
8381	// "AutomatedAgentConfig") to unconditionally include in API requests.
8382	// By default, fields with empty or default values are omitted from API
8383	// requests. However, any non-pointer, non-interface field appearing in
8384	// ForceSendFields will be sent to the server regardless of whether the
8385	// field is empty or not. This may be used to include empty fields in
8386	// Patch requests.
8387	ForceSendFields []string `json:"-"`
8388
8389	// NullFields is a list of field names (e.g. "AutomatedAgentConfig") to
8390	// include in API requests with the JSON null value. By default, fields
8391	// with empty values are omitted from API requests. However, any field
8392	// with an empty value appearing in NullFields will be sent to the
8393	// server as null. It is an error if a field in this list has a
8394	// non-empty value. This may be used to include null fields in Patch
8395	// requests.
8396	NullFields []string `json:"-"`
8397}
8398
8399func (s *GoogleCloudDialogflowV2ConversationProfile) MarshalJSON() ([]byte, error) {
8400	type NoMethod GoogleCloudDialogflowV2ConversationProfile
8401	raw := NoMethod(*s)
8402	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
8403}
8404
8405// GoogleCloudDialogflowV2DetectIntentRequest: The request to detect
8406// user's intent.
8407type GoogleCloudDialogflowV2DetectIntentRequest struct {
8408	// InputAudio: The natural language speech audio to be processed. This
8409	// field should be populated iff `query_input` is set to an input audio
8410	// config. A single request can contain up to 1 minute of speech audio
8411	// data.
8412	InputAudio string `json:"inputAudio,omitempty"`
8413
8414	// OutputAudioConfig: Instructs the speech synthesizer how to generate
8415	// the output audio. If this field is not set and agent-level speech
8416	// synthesizer is not configured, no output audio is generated.
8417	OutputAudioConfig *GoogleCloudDialogflowV2OutputAudioConfig `json:"outputAudioConfig,omitempty"`
8418
8419	// OutputAudioConfigMask: Mask for output_audio_config indicating which
8420	// settings in this request-level config should override speech
8421	// synthesizer settings defined at agent-level. If unspecified or empty,
8422	// output_audio_config replaces the agent-level config in its entirety.
8423	OutputAudioConfigMask string `json:"outputAudioConfigMask,omitempty"`
8424
8425	// QueryInput: Required. The input specification. It can be set to: 1.
8426	// an audio config which instructs the speech recognizer how to process
8427	// the speech audio, 2. a conversational query in the form of text, or
8428	// 3. an event that specifies which intent to trigger.
8429	QueryInput *GoogleCloudDialogflowV2QueryInput `json:"queryInput,omitempty"`
8430
8431	// QueryParams: The parameters of this query.
8432	QueryParams *GoogleCloudDialogflowV2QueryParameters `json:"queryParams,omitempty"`
8433
8434	// ForceSendFields is a list of field names (e.g. "InputAudio") to
8435	// unconditionally include in API requests. By default, fields with
8436	// empty or default values are omitted from API requests. However, any
8437	// non-pointer, non-interface field appearing in ForceSendFields will be
8438	// sent to the server regardless of whether the field is empty or not.
8439	// This may be used to include empty fields in Patch requests.
8440	ForceSendFields []string `json:"-"`
8441
8442	// NullFields is a list of field names (e.g. "InputAudio") to include in
8443	// API requests with the JSON null value. By default, fields with empty
8444	// values are omitted from API requests. However, any field with an
8445	// empty value appearing in NullFields will be sent to the server as
8446	// null. It is an error if a field in this list has a non-empty value.
8447	// This may be used to include null fields in Patch requests.
8448	NullFields []string `json:"-"`
8449}
8450
8451func (s *GoogleCloudDialogflowV2DetectIntentRequest) MarshalJSON() ([]byte, error) {
8452	type NoMethod GoogleCloudDialogflowV2DetectIntentRequest
8453	raw := NoMethod(*s)
8454	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
8455}
8456
8457// GoogleCloudDialogflowV2DetectIntentResponse: The message returned
8458// from the DetectIntent method.
8459type GoogleCloudDialogflowV2DetectIntentResponse struct {
8460	// OutputAudio: The audio data bytes encoded as specified in the
8461	// request. Note: The output audio is generated based on the values of
8462	// default platform text responses found in the
8463	// `query_result.fulfillment_messages` field. If multiple default text
8464	// responses exist, they will be concatenated when generating audio. If
8465	// no default platform text responses exist, the generated audio content
8466	// will be empty. In some scenarios, multiple output audio fields may be
8467	// present in the response structure. In these cases, only the
8468	// top-most-level audio output has content.
8469	OutputAudio string `json:"outputAudio,omitempty"`
8470
8471	// OutputAudioConfig: The config used by the speech synthesizer to
8472	// generate the output audio.
8473	OutputAudioConfig *GoogleCloudDialogflowV2OutputAudioConfig `json:"outputAudioConfig,omitempty"`
8474
8475	// QueryResult: The selected results of the conversational query or
8476	// event processing. See `alternative_query_results` for additional
8477	// potential results.
8478	QueryResult *GoogleCloudDialogflowV2QueryResult `json:"queryResult,omitempty"`
8479
8480	// ResponseId: The unique identifier of the response. It can be used to
8481	// locate a response in the training example set or for reporting
8482	// issues.
8483	ResponseId string `json:"responseId,omitempty"`
8484
8485	// WebhookStatus: Specifies the status of the webhook request.
8486	WebhookStatus *GoogleRpcStatus `json:"webhookStatus,omitempty"`
8487
8488	// ServerResponse contains the HTTP response code and headers from the
8489	// server.
8490	googleapi.ServerResponse `json:"-"`
8491
8492	// ForceSendFields is a list of field names (e.g. "OutputAudio") to
8493	// unconditionally include in API requests. By default, fields with
8494	// empty or default values are omitted from API requests. However, any
8495	// non-pointer, non-interface field appearing in ForceSendFields will be
8496	// sent to the server regardless of whether the field is empty or not.
8497	// This may be used to include empty fields in Patch requests.
8498	ForceSendFields []string `json:"-"`
8499
8500	// NullFields is a list of field names (e.g. "OutputAudio") to include
8501	// in API requests with the JSON null value. By default, fields with
8502	// empty values are omitted from API requests. However, any field with
8503	// an empty value appearing in NullFields will be sent to the server as
8504	// null. It is an error if a field in this list has a non-empty value.
8505	// This may be used to include null fields in Patch requests.
8506	NullFields []string `json:"-"`
8507}
8508
8509func (s *GoogleCloudDialogflowV2DetectIntentResponse) MarshalJSON() ([]byte, error) {
8510	type NoMethod GoogleCloudDialogflowV2DetectIntentResponse
8511	raw := NoMethod(*s)
8512	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
8513}
8514
8515// GoogleCloudDialogflowV2Document: A knowledge document to be used by a
8516// KnowledgeBase. For more information, see the knowledge base guide
8517// (https://cloud.google.com/dialogflow/docs/how/knowledge-bases). Note:
8518// The `projects.agent.knowledgeBases.documents` resource is deprecated;
8519// only use `projects.knowledgeBases.documents`.
8520type GoogleCloudDialogflowV2Document struct {
8521	// ContentUri: The URI where the file content is located. For documents
8522	// stored in Google Cloud Storage, these URIs must have the form
8523	// `gs:///`. NOTE: External URLs must correspond to public webpages,
8524	// i.e., they must be indexed by Google Search. In particular, URLs for
8525	// showing documents in Google Cloud Storage (i.e. the URL in your
8526	// browser) are not supported. Instead use the `gs://` format URI
8527	// described above.
8528	ContentUri string `json:"contentUri,omitempty"`
8529
8530	// DisplayName: Required. The display name of the document. The name
8531	// must be 1024 bytes or less; otherwise, the creation request fails.
8532	DisplayName string `json:"displayName,omitempty"`
8533
8534	// EnableAutoReload: Optional. If true, we try to automatically reload
8535	// the document every day (at a time picked by the system). If false or
8536	// unspecified, we don't try to automatically reload the document.
8537	// Currently you can only enable automatic reload for documents sourced
8538	// from a public url, see `source` field for the source types. Reload
8539	// status can be tracked in `latest_reload_status`. If a reload fails,
8540	// we will keep the document unchanged. If a reload fails with internal
8541	// errors, the system will try to reload the document on the next day.
8542	// If a reload fails with non-retriable errors (e.g. PERMISION_DENIED),
8543	// the system will not try to reload the document anymore. You need to
8544	// manually reload the document successfully by calling `ReloadDocument`
8545	// and clear the errors.
8546	EnableAutoReload bool `json:"enableAutoReload,omitempty"`
8547
8548	// KnowledgeTypes: Required. The knowledge type of document content.
8549	//
8550	// Possible values:
8551	//   "KNOWLEDGE_TYPE_UNSPECIFIED" - The type is unspecified or
8552	// arbitrary.
8553	//   "FAQ" - The document content contains question and answer pairs as
8554	// either HTML or CSV. Typical FAQ HTML formats are parsed accurately,
8555	// but unusual formats may fail to be parsed. CSV must have questions in
8556	// the first column and answers in the second, with no header. Because
8557	// of this explicit format, they are always parsed accurately.
8558	//   "EXTRACTIVE_QA" - Documents for which unstructured text is
8559	// extracted and used for question answering.
8560	//   "ARTICLE_SUGGESTION" - The entire document content as a whole can
8561	// be used for query results. Only for Contact Center Solutions on
8562	// Dialogflow.
8563	KnowledgeTypes []string `json:"knowledgeTypes,omitempty"`
8564
8565	// LatestReloadStatus: Output only. The time and status of the latest
8566	// reload. This reload may have been triggered automatically or manually
8567	// and may not have succeeded.
8568	LatestReloadStatus *GoogleCloudDialogflowV2DocumentReloadStatus `json:"latestReloadStatus,omitempty"`
8569
8570	// Metadata: Optional. Metadata for the document. The metadata supports
8571	// arbitrary key-value pairs. Suggested use cases include storing a
8572	// document's title, an external URL distinct from the document's
8573	// content_uri, etc. The max size of a `key` or a `value` of the
8574	// metadata is 1024 bytes.
8575	Metadata map[string]string `json:"metadata,omitempty"`
8576
8577	// MimeType: Required. The MIME type of this document.
8578	MimeType string `json:"mimeType,omitempty"`
8579
8580	// Name: Optional. The document resource name. The name must be empty
8581	// when creating a document. Format:
8582	// `projects//locations//knowledgeBases//documents/`.
8583	Name string `json:"name,omitempty"`
8584
8585	// RawContent: The raw content of the document. This field is only
8586	// permitted for EXTRACTIVE_QA and FAQ knowledge types.
8587	RawContent string `json:"rawContent,omitempty"`
8588
8589	// ServerResponse contains the HTTP response code and headers from the
8590	// server.
8591	googleapi.ServerResponse `json:"-"`
8592
8593	// ForceSendFields is a list of field names (e.g. "ContentUri") to
8594	// unconditionally include in API requests. By default, fields with
8595	// empty or default values are omitted from API requests. However, any
8596	// non-pointer, non-interface field appearing in ForceSendFields will be
8597	// sent to the server regardless of whether the field is empty or not.
8598	// This may be used to include empty fields in Patch requests.
8599	ForceSendFields []string `json:"-"`
8600
8601	// NullFields is a list of field names (e.g. "ContentUri") to include in
8602	// API requests with the JSON null value. By default, fields with empty
8603	// values are omitted from API requests. However, any field with an
8604	// empty value appearing in NullFields will be sent to the server as
8605	// null. It is an error if a field in this list has a non-empty value.
8606	// This may be used to include null fields in Patch requests.
8607	NullFields []string `json:"-"`
8608}
8609
8610func (s *GoogleCloudDialogflowV2Document) MarshalJSON() ([]byte, error) {
8611	type NoMethod GoogleCloudDialogflowV2Document
8612	raw := NoMethod(*s)
8613	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
8614}
8615
8616// GoogleCloudDialogflowV2DocumentReloadStatus: The status of a reload
8617// attempt.
8618type GoogleCloudDialogflowV2DocumentReloadStatus struct {
8619	// Status: The status of a reload attempt or the initial load.
8620	Status *GoogleRpcStatus `json:"status,omitempty"`
8621
8622	// Time: The time of a reload attempt. This reload may have been
8623	// triggered automatically or manually and may not have succeeded.
8624	Time string `json:"time,omitempty"`
8625
8626	// ForceSendFields is a list of field names (e.g. "Status") to
8627	// unconditionally include in API requests. By default, fields with
8628	// empty or default values are omitted from API requests. However, any
8629	// non-pointer, non-interface field appearing in ForceSendFields will be
8630	// sent to the server regardless of whether the field is empty or not.
8631	// This may be used to include empty fields in Patch requests.
8632	ForceSendFields []string `json:"-"`
8633
8634	// NullFields is a list of field names (e.g. "Status") to include in API
8635	// requests with the JSON null value. By default, fields with empty
8636	// values are omitted from API requests. However, any field with an
8637	// empty value appearing in NullFields will be sent to the server as
8638	// null. It is an error if a field in this list has a non-empty value.
8639	// This may be used to include null fields in Patch requests.
8640	NullFields []string `json:"-"`
8641}
8642
8643func (s *GoogleCloudDialogflowV2DocumentReloadStatus) MarshalJSON() ([]byte, error) {
8644	type NoMethod GoogleCloudDialogflowV2DocumentReloadStatus
8645	raw := NoMethod(*s)
8646	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
8647}
8648
8649// GoogleCloudDialogflowV2DtmfParameters: The message in the response
8650// that indicates the parameters of DTMF.
8651type GoogleCloudDialogflowV2DtmfParameters struct {
8652	// AcceptsDtmfInput: Indicates whether DTMF input can be handled in the
8653	// next request.
8654	AcceptsDtmfInput bool `json:"acceptsDtmfInput,omitempty"`
8655
8656	// ForceSendFields is a list of field names (e.g. "AcceptsDtmfInput") to
8657	// unconditionally include in API requests. By default, fields with
8658	// empty or default values are omitted from API requests. However, any
8659	// non-pointer, non-interface field appearing in ForceSendFields will be
8660	// sent to the server regardless of whether the field is empty or not.
8661	// This may be used to include empty fields in Patch requests.
8662	ForceSendFields []string `json:"-"`
8663
8664	// NullFields is a list of field names (e.g. "AcceptsDtmfInput") to
8665	// include in API requests with the JSON null value. By default, fields
8666	// with empty values are omitted from API requests. However, any field
8667	// with an empty value appearing in NullFields will be sent to the
8668	// server as null. It is an error if a field in this list has a
8669	// non-empty value. This may be used to include null fields in Patch
8670	// requests.
8671	NullFields []string `json:"-"`
8672}
8673
8674func (s *GoogleCloudDialogflowV2DtmfParameters) MarshalJSON() ([]byte, error) {
8675	type NoMethod GoogleCloudDialogflowV2DtmfParameters
8676	raw := NoMethod(*s)
8677	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
8678}
8679
8680// GoogleCloudDialogflowV2EntityType: Each intent parameter has a type,
8681// called the entity type, which dictates exactly how data from an
8682// end-user expression is extracted. Dialogflow provides predefined
8683// system entities that can match many common types of data. For
8684// example, there are system entities for matching dates, times, colors,
8685// email addresses, and so on. You can also create your own custom
8686// entities for matching custom data. For example, you could define a
8687// vegetable entity that can match the types of vegetables available for
8688// purchase with a grocery store agent. For more information, see the
8689// Entity guide
8690// (https://cloud.google.com/dialogflow/docs/entities-overview).
8691type GoogleCloudDialogflowV2EntityType struct {
8692	// AutoExpansionMode: Optional. Indicates whether the entity type can be
8693	// automatically expanded.
8694	//
8695	// Possible values:
8696	//   "AUTO_EXPANSION_MODE_UNSPECIFIED" - Auto expansion disabled for the
8697	// entity.
8698	//   "AUTO_EXPANSION_MODE_DEFAULT" - Allows an agent to recognize values
8699	// that have not been explicitly listed in the entity.
8700	AutoExpansionMode string `json:"autoExpansionMode,omitempty"`
8701
8702	// DisplayName: Required. The name of the entity type.
8703	DisplayName string `json:"displayName,omitempty"`
8704
8705	// EnableFuzzyExtraction: Optional. Enables fuzzy entity extraction
8706	// during classification.
8707	EnableFuzzyExtraction bool `json:"enableFuzzyExtraction,omitempty"`
8708
8709	// Entities: Optional. The collection of entity entries associated with
8710	// the entity type.
8711	Entities []*GoogleCloudDialogflowV2EntityTypeEntity `json:"entities,omitempty"`
8712
8713	// Kind: Required. Indicates the kind of entity type.
8714	//
8715	// Possible values:
8716	//   "KIND_UNSPECIFIED" - Not specified. This value should be never
8717	// used.
8718	//   "KIND_MAP" - Map entity types allow mapping of a group of synonyms
8719	// to a reference value.
8720	//   "KIND_LIST" - List entity types contain a set of entries that do
8721	// not map to reference values. However, list entity types can contain
8722	// references to other entity types (with or without aliases).
8723	//   "KIND_REGEXP" - Regexp entity types allow to specify regular
8724	// expressions in entries values.
8725	Kind string `json:"kind,omitempty"`
8726
8727	// Name: The unique identifier of the entity type. Required for
8728	// EntityTypes.UpdateEntityType and EntityTypes.BatchUpdateEntityTypes
8729	// methods. Format: `projects//agent/entityTypes/`.
8730	Name string `json:"name,omitempty"`
8731
8732	// ServerResponse contains the HTTP response code and headers from the
8733	// server.
8734	googleapi.ServerResponse `json:"-"`
8735
8736	// ForceSendFields is a list of field names (e.g. "AutoExpansionMode")
8737	// to unconditionally include in API requests. By default, fields with
8738	// empty or default values are omitted from API requests. However, any
8739	// non-pointer, non-interface field appearing in ForceSendFields will be
8740	// sent to the server regardless of whether the field is empty or not.
8741	// This may be used to include empty fields in Patch requests.
8742	ForceSendFields []string `json:"-"`
8743
8744	// NullFields is a list of field names (e.g. "AutoExpansionMode") to
8745	// include in API requests with the JSON null value. By default, fields
8746	// with empty values are omitted from API requests. However, any field
8747	// with an empty value appearing in NullFields will be sent to the
8748	// server as null. It is an error if a field in this list has a
8749	// non-empty value. This may be used to include null fields in Patch
8750	// requests.
8751	NullFields []string `json:"-"`
8752}
8753
8754func (s *GoogleCloudDialogflowV2EntityType) MarshalJSON() ([]byte, error) {
8755	type NoMethod GoogleCloudDialogflowV2EntityType
8756	raw := NoMethod(*s)
8757	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
8758}
8759
8760// GoogleCloudDialogflowV2EntityTypeBatch: This message is a wrapper
8761// around a collection of entity types.
8762type GoogleCloudDialogflowV2EntityTypeBatch struct {
8763	// EntityTypes: A collection of entity types.
8764	EntityTypes []*GoogleCloudDialogflowV2EntityType `json:"entityTypes,omitempty"`
8765
8766	// ForceSendFields is a list of field names (e.g. "EntityTypes") to
8767	// unconditionally include in API requests. By default, fields with
8768	// empty or default values are omitted from API requests. However, any
8769	// non-pointer, non-interface field appearing in ForceSendFields will be
8770	// sent to the server regardless of whether the field is empty or not.
8771	// This may be used to include empty fields in Patch requests.
8772	ForceSendFields []string `json:"-"`
8773
8774	// NullFields is a list of field names (e.g. "EntityTypes") to include
8775	// in API requests with the JSON null value. By default, fields with
8776	// empty values are omitted from API requests. However, any field with
8777	// an empty value appearing in NullFields will be sent to the server as
8778	// null. It is an error if a field in this list has a non-empty value.
8779	// This may be used to include null fields in Patch requests.
8780	NullFields []string `json:"-"`
8781}
8782
8783func (s *GoogleCloudDialogflowV2EntityTypeBatch) MarshalJSON() ([]byte, error) {
8784	type NoMethod GoogleCloudDialogflowV2EntityTypeBatch
8785	raw := NoMethod(*s)
8786	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
8787}
8788
8789// GoogleCloudDialogflowV2EntityTypeEntity: An **entity entry** for an
8790// associated entity type.
8791type GoogleCloudDialogflowV2EntityTypeEntity struct {
8792	// Synonyms: Required. A collection of value synonyms. For example, if
8793	// the entity type is *vegetable*, and `value` is *scallions*, a synonym
8794	// could be *green onions*. For `KIND_LIST` entity types: * This
8795	// collection must contain exactly one synonym equal to `value`.
8796	Synonyms []string `json:"synonyms,omitempty"`
8797
8798	// Value: Required. The primary value associated with this entity entry.
8799	// For example, if the entity type is *vegetable*, the value could be
8800	// *scallions*. For `KIND_MAP` entity types: * A reference value to be
8801	// used in place of synonyms. For `KIND_LIST` entity types: * A string
8802	// that can contain references to other entity types (with or without
8803	// aliases).
8804	Value string `json:"value,omitempty"`
8805
8806	// ForceSendFields is a list of field names (e.g. "Synonyms") to
8807	// unconditionally include in API requests. By default, fields with
8808	// empty or default values are omitted from API requests. However, any
8809	// non-pointer, non-interface field appearing in ForceSendFields will be
8810	// sent to the server regardless of whether the field is empty or not.
8811	// This may be used to include empty fields in Patch requests.
8812	ForceSendFields []string `json:"-"`
8813
8814	// NullFields is a list of field names (e.g. "Synonyms") to include in
8815	// API requests with the JSON null value. By default, fields with empty
8816	// values are omitted from API requests. However, any field with an
8817	// empty value appearing in NullFields will be sent to the server as
8818	// null. It is an error if a field in this list has a non-empty value.
8819	// This may be used to include null fields in Patch requests.
8820	NullFields []string `json:"-"`
8821}
8822
8823func (s *GoogleCloudDialogflowV2EntityTypeEntity) MarshalJSON() ([]byte, error) {
8824	type NoMethod GoogleCloudDialogflowV2EntityTypeEntity
8825	raw := NoMethod(*s)
8826	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
8827}
8828
8829// GoogleCloudDialogflowV2Environment: You can create multiple versions
8830// of your agent and publish them to separate environments. When you
8831// edit an agent, you are editing the draft agent. At any point, you can
8832// save the draft agent as an agent version, which is an immutable
8833// snapshot of your agent. When you save the draft agent, it is
8834// published to the default environment. When you create agent versions,
8835// you can publish them to custom environments. You can create a variety
8836// of custom environments for: - testing - development - production -
8837// etc. For more information, see the versions and environments guide
8838// (https://cloud.google.com/dialogflow/docs/agents-versions).
8839type GoogleCloudDialogflowV2Environment struct {
8840	// AgentVersion: Optional. The agent version loaded into this
8841	// environment. Supported formats: - `projects//agent/versions/` -
8842	// `projects//locations//agent/versions/`
8843	AgentVersion string `json:"agentVersion,omitempty"`
8844
8845	// Description: Optional. The developer-provided description for this
8846	// environment. The maximum length is 500 characters. If exceeded, the
8847	// request is rejected.
8848	Description string `json:"description,omitempty"`
8849
8850	// Fulfillment: Optional. The fulfillment settings to use for this
8851	// environment.
8852	Fulfillment *GoogleCloudDialogflowV2Fulfillment `json:"fulfillment,omitempty"`
8853
8854	// Name: Output only. The unique identifier of this agent environment.
8855	// Supported formats: - `projects//agent/environments/` -
8856	// `projects//locations//agent/environments/` The environment ID for the
8857	// default environment is `-`.
8858	Name string `json:"name,omitempty"`
8859
8860	// State: Output only. The state of this environment. This field is
8861	// read-only, i.e., it cannot be set by create and update methods.
8862	//
8863	// Possible values:
8864	//   "STATE_UNSPECIFIED" - Not specified. This value is not used.
8865	//   "STOPPED" - Stopped.
8866	//   "LOADING" - Loading.
8867	//   "RUNNING" - Running.
8868	State string `json:"state,omitempty"`
8869
8870	// TextToSpeechSettings: Optional. Text to speech settings for this
8871	// environment.
8872	TextToSpeechSettings *GoogleCloudDialogflowV2TextToSpeechSettings `json:"textToSpeechSettings,omitempty"`
8873
8874	// UpdateTime: Output only. The last update time of this environment.
8875	// This field is read-only, i.e., it cannot be set by create and update
8876	// methods.
8877	UpdateTime string `json:"updateTime,omitempty"`
8878
8879	// ServerResponse contains the HTTP response code and headers from the
8880	// server.
8881	googleapi.ServerResponse `json:"-"`
8882
8883	// ForceSendFields is a list of field names (e.g. "AgentVersion") to
8884	// unconditionally include in API requests. By default, fields with
8885	// empty or default values are omitted from API requests. However, any
8886	// non-pointer, non-interface field appearing in ForceSendFields will be
8887	// sent to the server regardless of whether the field is empty or not.
8888	// This may be used to include empty fields in Patch requests.
8889	ForceSendFields []string `json:"-"`
8890
8891	// NullFields is a list of field names (e.g. "AgentVersion") to include
8892	// in API requests with the JSON null value. By default, fields with
8893	// empty values are omitted from API requests. However, any field with
8894	// an empty value appearing in NullFields will be sent to the server as
8895	// null. It is an error if a field in this list has a non-empty value.
8896	// This may be used to include null fields in Patch requests.
8897	NullFields []string `json:"-"`
8898}
8899
8900func (s *GoogleCloudDialogflowV2Environment) MarshalJSON() ([]byte, error) {
8901	type NoMethod GoogleCloudDialogflowV2Environment
8902	raw := NoMethod(*s)
8903	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
8904}
8905
8906// GoogleCloudDialogflowV2EnvironmentHistory: The response message for
8907// Environments.GetEnvironmentHistory.
8908type GoogleCloudDialogflowV2EnvironmentHistory struct {
8909	// Entries: Output only. The list of agent environments. There will be a
8910	// maximum number of items returned based on the page_size field in the
8911	// request.
8912	Entries []*GoogleCloudDialogflowV2EnvironmentHistoryEntry `json:"entries,omitempty"`
8913
8914	// NextPageToken: Output only. Token to retrieve the next page of
8915	// results, or empty if there are no more results in the list.
8916	NextPageToken string `json:"nextPageToken,omitempty"`
8917
8918	// Parent: Output only. The name of the environment this history is for.
8919	// Supported formats: - `projects//agent/environments/` -
8920	// `projects//locations//agent/environments/` The environment ID for the
8921	// default environment is `-`.
8922	Parent string `json:"parent,omitempty"`
8923
8924	// ServerResponse contains the HTTP response code and headers from the
8925	// server.
8926	googleapi.ServerResponse `json:"-"`
8927
8928	// ForceSendFields is a list of field names (e.g. "Entries") to
8929	// unconditionally include in API requests. By default, fields with
8930	// empty or default values are omitted from API requests. However, any
8931	// non-pointer, non-interface field appearing in ForceSendFields will be
8932	// sent to the server regardless of whether the field is empty or not.
8933	// This may be used to include empty fields in Patch requests.
8934	ForceSendFields []string `json:"-"`
8935
8936	// NullFields is a list of field names (e.g. "Entries") to include in
8937	// API requests with the JSON null value. By default, fields with empty
8938	// values are omitted from API requests. However, any field with an
8939	// empty value appearing in NullFields will be sent to the server as
8940	// null. It is an error if a field in this list has a non-empty value.
8941	// This may be used to include null fields in Patch requests.
8942	NullFields []string `json:"-"`
8943}
8944
8945func (s *GoogleCloudDialogflowV2EnvironmentHistory) MarshalJSON() ([]byte, error) {
8946	type NoMethod GoogleCloudDialogflowV2EnvironmentHistory
8947	raw := NoMethod(*s)
8948	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
8949}
8950
8951// GoogleCloudDialogflowV2EnvironmentHistoryEntry: Represents an
8952// environment history entry.
8953type GoogleCloudDialogflowV2EnvironmentHistoryEntry struct {
8954	// AgentVersion: The agent version loaded into this environment history
8955	// entry.
8956	AgentVersion string `json:"agentVersion,omitempty"`
8957
8958	// CreateTime: The creation time of this environment history entry.
8959	CreateTime string `json:"createTime,omitempty"`
8960
8961	// Description: The developer-provided description for this environment
8962	// history entry.
8963	Description string `json:"description,omitempty"`
8964
8965	// ForceSendFields is a list of field names (e.g. "AgentVersion") to
8966	// unconditionally include in API requests. By default, fields with
8967	// empty or default values are omitted from API requests. However, any
8968	// non-pointer, non-interface field appearing in ForceSendFields will be
8969	// sent to the server regardless of whether the field is empty or not.
8970	// This may be used to include empty fields in Patch requests.
8971	ForceSendFields []string `json:"-"`
8972
8973	// NullFields is a list of field names (e.g. "AgentVersion") to include
8974	// in API requests with the JSON null value. By default, fields with
8975	// empty values are omitted from API requests. However, any field with
8976	// an empty value appearing in NullFields will be sent to the server as
8977	// null. It is an error if a field in this list has a non-empty value.
8978	// This may be used to include null fields in Patch requests.
8979	NullFields []string `json:"-"`
8980}
8981
8982func (s *GoogleCloudDialogflowV2EnvironmentHistoryEntry) MarshalJSON() ([]byte, error) {
8983	type NoMethod GoogleCloudDialogflowV2EnvironmentHistoryEntry
8984	raw := NoMethod(*s)
8985	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
8986}
8987
8988// GoogleCloudDialogflowV2EventInput: Events allow for matching intents
8989// by event name instead of the natural language input. For instance,
8990// input `` can trigger a personalized welcome response. The parameter
8991// `name` may be used by the agent in the response: "Hello
8992// #welcome_event.name! What can I do for you today?".
8993type GoogleCloudDialogflowV2EventInput struct {
8994	// LanguageCode: Required. The language of this query. See Language
8995	// Support (https://cloud.google.com/dialogflow/docs/reference/language)
8996	// for a list of the currently supported language codes. Note that
8997	// queries in the same session do not necessarily need to specify the
8998	// same language.
8999	LanguageCode string `json:"languageCode,omitempty"`
9000
9001	// Name: Required. The unique identifier of the event.
9002	Name string `json:"name,omitempty"`
9003
9004	// Parameters: The collection of parameters associated with the event.
9005	// Depending on your protocol or client library language, this is a map,
9006	// associative array, symbol table, dictionary, or JSON object composed
9007	// of a collection of (MapKey, MapValue) pairs: - MapKey type: string -
9008	// MapKey value: parameter name - MapValue type: - If parameter's entity
9009	// type is a composite entity: map - Else: depending on parameter value
9010	// type, could be one of string, number, boolean, null, list or map -
9011	// MapValue value: - If parameter's entity type is a composite entity:
9012	// map from composite entity property names to property values - Else:
9013	// parameter value
9014	Parameters googleapi.RawMessage `json:"parameters,omitempty"`
9015
9016	// ForceSendFields is a list of field names (e.g. "LanguageCode") to
9017	// unconditionally include in API requests. By default, fields with
9018	// empty or default values are omitted from API requests. However, any
9019	// non-pointer, non-interface field appearing in ForceSendFields will be
9020	// sent to the server regardless of whether the field is empty or not.
9021	// This may be used to include empty fields in Patch requests.
9022	ForceSendFields []string `json:"-"`
9023
9024	// NullFields is a list of field names (e.g. "LanguageCode") to include
9025	// in API requests with the JSON null value. By default, fields with
9026	// empty values are omitted from API requests. However, any field with
9027	// an empty value appearing in NullFields will be sent to the server as
9028	// null. It is an error if a field in this list has a non-empty value.
9029	// This may be used to include null fields in Patch requests.
9030	NullFields []string `json:"-"`
9031}
9032
9033func (s *GoogleCloudDialogflowV2EventInput) MarshalJSON() ([]byte, error) {
9034	type NoMethod GoogleCloudDialogflowV2EventInput
9035	raw := NoMethod(*s)
9036	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
9037}
9038
9039// GoogleCloudDialogflowV2ExportAgentRequest: The request message for
9040// Agents.ExportAgent.
9041type GoogleCloudDialogflowV2ExportAgentRequest struct {
9042	// AgentUri: Required. The Google Cloud Storage
9043	// (https://cloud.google.com/storage/docs/) URI to export the agent to.
9044	// The format of this URI must be `gs:///`. If left unspecified, the
9045	// serialized agent is returned inline.
9046	AgentUri string `json:"agentUri,omitempty"`
9047
9048	// ForceSendFields is a list of field names (e.g. "AgentUri") to
9049	// unconditionally include in API requests. By default, fields with
9050	// empty or default values are omitted from API requests. However, any
9051	// non-pointer, non-interface field appearing in ForceSendFields will be
9052	// sent to the server regardless of whether the field is empty or not.
9053	// This may be used to include empty fields in Patch requests.
9054	ForceSendFields []string `json:"-"`
9055
9056	// NullFields is a list of field names (e.g. "AgentUri") to include in
9057	// API requests with the JSON null value. By default, fields with empty
9058	// values are omitted from API requests. However, any field with an
9059	// empty value appearing in NullFields will be sent to the server as
9060	// null. It is an error if a field in this list has a non-empty value.
9061	// This may be used to include null fields in Patch requests.
9062	NullFields []string `json:"-"`
9063}
9064
9065func (s *GoogleCloudDialogflowV2ExportAgentRequest) MarshalJSON() ([]byte, error) {
9066	type NoMethod GoogleCloudDialogflowV2ExportAgentRequest
9067	raw := NoMethod(*s)
9068	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
9069}
9070
9071// GoogleCloudDialogflowV2ExportAgentResponse: The response message for
9072// Agents.ExportAgent.
9073type GoogleCloudDialogflowV2ExportAgentResponse struct {
9074	// AgentContent: Zip compressed raw byte content for agent.
9075	AgentContent string `json:"agentContent,omitempty"`
9076
9077	// AgentUri: The URI to a file containing the exported agent. This field
9078	// is populated only if `agent_uri` is specified in
9079	// `ExportAgentRequest`.
9080	AgentUri string `json:"agentUri,omitempty"`
9081
9082	// ForceSendFields is a list of field names (e.g. "AgentContent") to
9083	// unconditionally include in API requests. By default, fields with
9084	// empty or default values are omitted from API requests. However, any
9085	// non-pointer, non-interface field appearing in ForceSendFields will be
9086	// sent to the server regardless of whether the field is empty or not.
9087	// This may be used to include empty fields in Patch requests.
9088	ForceSendFields []string `json:"-"`
9089
9090	// NullFields is a list of field names (e.g. "AgentContent") to include
9091	// in API requests with the JSON null value. By default, fields with
9092	// empty values are omitted from API requests. However, any field with
9093	// an empty value appearing in NullFields will be sent to the server as
9094	// null. It is an error if a field in this list has a non-empty value.
9095	// This may be used to include null fields in Patch requests.
9096	NullFields []string `json:"-"`
9097}
9098
9099func (s *GoogleCloudDialogflowV2ExportAgentResponse) MarshalJSON() ([]byte, error) {
9100	type NoMethod GoogleCloudDialogflowV2ExportAgentResponse
9101	raw := NoMethod(*s)
9102	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
9103}
9104
9105// GoogleCloudDialogflowV2FaqAnswer: Represents answer from "frequently
9106// asked questions".
9107type GoogleCloudDialogflowV2FaqAnswer struct {
9108	// Answer: The piece of text from the `source` knowledge base document.
9109	Answer string `json:"answer,omitempty"`
9110
9111	// AnswerRecord: The name of answer record, in the format of
9112	// "projects//locations//answerRecords/"
9113	AnswerRecord string `json:"answerRecord,omitempty"`
9114
9115	// Confidence: The system's confidence score that this Knowledge answer
9116	// is a good match for this conversational query, range from 0.0
9117	// (completely uncertain) to 1.0 (completely certain).
9118	Confidence float64 `json:"confidence,omitempty"`
9119
9120	// Metadata: A map that contains metadata about the answer and the
9121	// document from which it originates.
9122	Metadata map[string]string `json:"metadata,omitempty"`
9123
9124	// Question: The corresponding FAQ question.
9125	Question string `json:"question,omitempty"`
9126
9127	// Source: Indicates which Knowledge Document this answer was extracted
9128	// from. Format:
9129	// `projects//locations//agent/knowledgeBases//documents/`.
9130	Source string `json:"source,omitempty"`
9131
9132	// ForceSendFields is a list of field names (e.g. "Answer") to
9133	// unconditionally include in API requests. By default, fields with
9134	// empty or default values are omitted from API requests. However, any
9135	// non-pointer, non-interface field appearing in ForceSendFields will be
9136	// sent to the server regardless of whether the field is empty or not.
9137	// This may be used to include empty fields in Patch requests.
9138	ForceSendFields []string `json:"-"`
9139
9140	// NullFields is a list of field names (e.g. "Answer") to include in API
9141	// requests with the JSON null value. By default, fields with empty
9142	// values are omitted from API requests. However, any field with an
9143	// empty value appearing in NullFields will be sent to the server as
9144	// null. It is an error if a field in this list has a non-empty value.
9145	// This may be used to include null fields in Patch requests.
9146	NullFields []string `json:"-"`
9147}
9148
9149func (s *GoogleCloudDialogflowV2FaqAnswer) MarshalJSON() ([]byte, error) {
9150	type NoMethod GoogleCloudDialogflowV2FaqAnswer
9151	raw := NoMethod(*s)
9152	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
9153}
9154
9155func (s *GoogleCloudDialogflowV2FaqAnswer) UnmarshalJSON(data []byte) error {
9156	type NoMethod GoogleCloudDialogflowV2FaqAnswer
9157	var s1 struct {
9158		Confidence gensupport.JSONFloat64 `json:"confidence"`
9159		*NoMethod
9160	}
9161	s1.NoMethod = (*NoMethod)(s)
9162	if err := json.Unmarshal(data, &s1); err != nil {
9163		return err
9164	}
9165	s.Confidence = float64(s1.Confidence)
9166	return nil
9167}
9168
9169// GoogleCloudDialogflowV2Fulfillment: By default, your agent responds
9170// to a matched intent with a static response. As an alternative, you
9171// can provide a more dynamic response by using fulfillment. When you
9172// enable fulfillment for an intent, Dialogflow responds to that intent
9173// by calling a service that you define. For example, if an end-user
9174// wants to schedule a haircut on Friday, your service can check your
9175// database and respond to the end-user with availability information
9176// for Friday. For more information, see the fulfillment guide
9177// (https://cloud.google.com/dialogflow/docs/fulfillment-overview).
9178type GoogleCloudDialogflowV2Fulfillment struct {
9179	// DisplayName: Optional. The human-readable name of the fulfillment,
9180	// unique within the agent. This field is not used for Fulfillment in an
9181	// Environment.
9182	DisplayName string `json:"displayName,omitempty"`
9183
9184	// Enabled: Optional. Whether fulfillment is enabled.
9185	Enabled bool `json:"enabled,omitempty"`
9186
9187	// Features: Optional. The field defines whether the fulfillment is
9188	// enabled for certain features.
9189	Features []*GoogleCloudDialogflowV2FulfillmentFeature `json:"features,omitempty"`
9190
9191	// GenericWebService: Configuration for a generic web service.
9192	GenericWebService *GoogleCloudDialogflowV2FulfillmentGenericWebService `json:"genericWebService,omitempty"`
9193
9194	// Name: Required. The unique identifier of the fulfillment. Supported
9195	// formats: - `projects//agent/fulfillment` -
9196	// `projects//locations//agent/fulfillment` This field is not used for
9197	// Fulfillment in an Environment.
9198	Name string `json:"name,omitempty"`
9199
9200	// ServerResponse contains the HTTP response code and headers from the
9201	// server.
9202	googleapi.ServerResponse `json:"-"`
9203
9204	// ForceSendFields is a list of field names (e.g. "DisplayName") to
9205	// unconditionally include in API requests. By default, fields with
9206	// empty or default values are omitted from API requests. However, any
9207	// non-pointer, non-interface field appearing in ForceSendFields will be
9208	// sent to the server regardless of whether the field is empty or not.
9209	// This may be used to include empty fields in Patch requests.
9210	ForceSendFields []string `json:"-"`
9211
9212	// NullFields is a list of field names (e.g. "DisplayName") to include
9213	// in API requests with the JSON null value. By default, fields with
9214	// empty values are omitted from API requests. However, any field with
9215	// an empty value appearing in NullFields will be sent to the server as
9216	// null. It is an error if a field in this list has a non-empty value.
9217	// This may be used to include null fields in Patch requests.
9218	NullFields []string `json:"-"`
9219}
9220
9221func (s *GoogleCloudDialogflowV2Fulfillment) MarshalJSON() ([]byte, error) {
9222	type NoMethod GoogleCloudDialogflowV2Fulfillment
9223	raw := NoMethod(*s)
9224	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
9225}
9226
9227// GoogleCloudDialogflowV2FulfillmentFeature: Whether fulfillment is
9228// enabled for the specific feature.
9229type GoogleCloudDialogflowV2FulfillmentFeature struct {
9230	// Type: The type of the feature that enabled for fulfillment.
9231	//
9232	// Possible values:
9233	//   "TYPE_UNSPECIFIED" - Feature type not specified.
9234	//   "SMALLTALK" - Fulfillment is enabled for SmallTalk.
9235	Type string `json:"type,omitempty"`
9236
9237	// ForceSendFields is a list of field names (e.g. "Type") to
9238	// unconditionally include in API requests. By default, fields with
9239	// empty or default values are omitted from API requests. However, any
9240	// non-pointer, non-interface field appearing in ForceSendFields will be
9241	// sent to the server regardless of whether the field is empty or not.
9242	// This may be used to include empty fields in Patch requests.
9243	ForceSendFields []string `json:"-"`
9244
9245	// NullFields is a list of field names (e.g. "Type") to include in API
9246	// requests with the JSON null value. By default, fields with empty
9247	// values are omitted from API requests. However, any field with an
9248	// empty value appearing in NullFields will be sent to the server as
9249	// null. It is an error if a field in this list has a non-empty value.
9250	// This may be used to include null fields in Patch requests.
9251	NullFields []string `json:"-"`
9252}
9253
9254func (s *GoogleCloudDialogflowV2FulfillmentFeature) MarshalJSON() ([]byte, error) {
9255	type NoMethod GoogleCloudDialogflowV2FulfillmentFeature
9256	raw := NoMethod(*s)
9257	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
9258}
9259
9260// GoogleCloudDialogflowV2FulfillmentGenericWebService: Represents
9261// configuration for a generic web service. Dialogflow supports two
9262// mechanisms for authentications: - Basic authentication with username
9263// and password. - Authentication with additional authentication
9264// headers. More information could be found at:
9265// https://cloud.google.com/dialogflow/docs/fulfillment-configure.
9266type GoogleCloudDialogflowV2FulfillmentGenericWebService struct {
9267	// IsCloudFunction: Optional. Indicates if generic web service is
9268	// created through Cloud Functions integration. Defaults to false.
9269	// is_cloud_function is deprecated. Cloud functions can be configured by
9270	// its uri as a regular web service now.
9271	IsCloudFunction bool `json:"isCloudFunction,omitempty"`
9272
9273	// Password: Optional. The password for HTTP Basic authentication.
9274	Password string `json:"password,omitempty"`
9275
9276	// RequestHeaders: Optional. The HTTP request headers to send together
9277	// with fulfillment requests.
9278	RequestHeaders map[string]string `json:"requestHeaders,omitempty"`
9279
9280	// Uri: Required. The fulfillment URI for receiving POST requests. It
9281	// must use https protocol.
9282	Uri string `json:"uri,omitempty"`
9283
9284	// Username: Optional. The user name for HTTP Basic authentication.
9285	Username string `json:"username,omitempty"`
9286
9287	// ForceSendFields is a list of field names (e.g. "IsCloudFunction") to
9288	// unconditionally include in API requests. By default, fields with
9289	// empty or default values are omitted from API requests. However, any
9290	// non-pointer, non-interface field appearing in ForceSendFields will be
9291	// sent to the server regardless of whether the field is empty or not.
9292	// This may be used to include empty fields in Patch requests.
9293	ForceSendFields []string `json:"-"`
9294
9295	// NullFields is a list of field names (e.g. "IsCloudFunction") to
9296	// include in API requests with the JSON null value. By default, fields
9297	// with empty values are omitted from API requests. However, any field
9298	// with an empty value appearing in NullFields will be sent to the
9299	// server as null. It is an error if a field in this list has a
9300	// non-empty value. This may be used to include null fields in Patch
9301	// requests.
9302	NullFields []string `json:"-"`
9303}
9304
9305func (s *GoogleCloudDialogflowV2FulfillmentGenericWebService) MarshalJSON() ([]byte, error) {
9306	type NoMethod GoogleCloudDialogflowV2FulfillmentGenericWebService
9307	raw := NoMethod(*s)
9308	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
9309}
9310
9311// GoogleCloudDialogflowV2HumanAgentAssistantConfig: Defines the Human
9312// Agent Assist to connect to a conversation.
9313type GoogleCloudDialogflowV2HumanAgentAssistantConfig struct {
9314	// EndUserSuggestionConfig: Configuration for agent assistance of end
9315	// user participant. Currently, this feature is not general available,
9316	// please contact Google to get access.
9317	EndUserSuggestionConfig *GoogleCloudDialogflowV2HumanAgentAssistantConfigSuggestionConfig `json:"endUserSuggestionConfig,omitempty"`
9318
9319	// HumanAgentSuggestionConfig: Configuration for agent assistance of
9320	// human agent participant.
9321	HumanAgentSuggestionConfig *GoogleCloudDialogflowV2HumanAgentAssistantConfigSuggestionConfig `json:"humanAgentSuggestionConfig,omitempty"`
9322
9323	// MessageAnalysisConfig: Configuration for message analysis.
9324	MessageAnalysisConfig *GoogleCloudDialogflowV2HumanAgentAssistantConfigMessageAnalysisConfig `json:"messageAnalysisConfig,omitempty"`
9325
9326	// NotificationConfig: Pub/Sub topic on which to publish new agent
9327	// assistant events.
9328	NotificationConfig *GoogleCloudDialogflowV2NotificationConfig `json:"notificationConfig,omitempty"`
9329
9330	// ForceSendFields is a list of field names (e.g.
9331	// "EndUserSuggestionConfig") to unconditionally include in API
9332	// requests. By default, fields with empty or default values are omitted
9333	// from API requests. However, any non-pointer, non-interface field
9334	// appearing in ForceSendFields will be sent to the server regardless of
9335	// whether the field is empty or not. This may be used to include empty
9336	// fields in Patch requests.
9337	ForceSendFields []string `json:"-"`
9338
9339	// NullFields is a list of field names (e.g. "EndUserSuggestionConfig")
9340	// to include in API requests with the JSON null value. By default,
9341	// fields with empty values are omitted from API requests. However, any
9342	// field with an empty value appearing in NullFields will be sent to the
9343	// server as null. It is an error if a field in this list has a
9344	// non-empty value. This may be used to include null fields in Patch
9345	// requests.
9346	NullFields []string `json:"-"`
9347}
9348
9349func (s *GoogleCloudDialogflowV2HumanAgentAssistantConfig) MarshalJSON() ([]byte, error) {
9350	type NoMethod GoogleCloudDialogflowV2HumanAgentAssistantConfig
9351	raw := NoMethod(*s)
9352	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
9353}
9354
9355// GoogleCloudDialogflowV2HumanAgentAssistantConfigConversationModelConfi
9356// g: Custom conversation models used in agent assist feature. Supported
9357// feature: ARTICLE_SUGGESTION, SMART_COMPOSE, SMART_REPLY.
9358type GoogleCloudDialogflowV2HumanAgentAssistantConfigConversationModelConfig struct {
9359	// Model: Conversation model resource name. Format:
9360	// `projects//conversationModels/`.
9361	Model string `json:"model,omitempty"`
9362
9363	// ForceSendFields is a list of field names (e.g. "Model") to
9364	// unconditionally include in API requests. By default, fields with
9365	// empty or default values are omitted from API requests. However, any
9366	// non-pointer, non-interface field appearing in ForceSendFields will be
9367	// sent to the server regardless of whether the field is empty or not.
9368	// This may be used to include empty fields in Patch requests.
9369	ForceSendFields []string `json:"-"`
9370
9371	// NullFields is a list of field names (e.g. "Model") to include in API
9372	// requests with the JSON null value. By default, fields with empty
9373	// values are omitted from API requests. However, any field with an
9374	// empty value appearing in NullFields will be sent to the server as
9375	// null. It is an error if a field in this list has a non-empty value.
9376	// This may be used to include null fields in Patch requests.
9377	NullFields []string `json:"-"`
9378}
9379
9380func (s *GoogleCloudDialogflowV2HumanAgentAssistantConfigConversationModelConfig) MarshalJSON() ([]byte, error) {
9381	type NoMethod GoogleCloudDialogflowV2HumanAgentAssistantConfigConversationModelConfig
9382	raw := NoMethod(*s)
9383	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
9384}
9385
9386// GoogleCloudDialogflowV2HumanAgentAssistantConfigMessageAnalysisConfig:
9387//  Configuration for analyses to run on each conversation message.
9388type GoogleCloudDialogflowV2HumanAgentAssistantConfigMessageAnalysisConfig struct {
9389	// EnableEntityExtraction: Enable entity extraction in conversation
9390	// messages on agent assist stage
9391	// (https://cloud.google.com/dialogflow/priv/docs/contact-center/basics#stages).
9392	// If unspecified, defaults to false. Currently, this feature is not
9393	// general available, please contact Google to get access.
9394	EnableEntityExtraction bool `json:"enableEntityExtraction,omitempty"`
9395
9396	// EnableSentimentAnalysis: Enable sentiment analysis in conversation
9397	// messages on agent assist stage
9398	// (https://cloud.google.com/dialogflow/priv/docs/contact-center/basics#stages).
9399	// If unspecified, defaults to false. Sentiment analysis inspects user
9400	// input and identifies the prevailing subjective opinion, especially to
9401	// determine a user's attitude as positive, negative, or neutral:
9402	// https://cloud.google.com/natural-language/docs/basics#sentiment_analysis
9403	// For Participants.StreamingAnalyzeContent method, result will be in
9404	// StreamingAnalyzeContentResponse.message.SentimentAnalysisResult. For
9405	// Participants.AnalyzeContent method, result will be in
9406	// AnalyzeContentResponse.message.SentimentAnalysisResult For
9407	// Conversations.ListMessages method, result will be in
9408	// ListMessagesResponse.messages.SentimentAnalysisResult If Pub/Sub
9409	// notification is configured, result will be in
9410	// ConversationEvent.new_message_payload.SentimentAnalysisResult.
9411	EnableSentimentAnalysis bool `json:"enableSentimentAnalysis,omitempty"`
9412
9413	// ForceSendFields is a list of field names (e.g.
9414	// "EnableEntityExtraction") to unconditionally include in API requests.
9415	// By default, fields with empty or default values are omitted from API
9416	// requests. However, any non-pointer, non-interface field appearing in
9417	// ForceSendFields will be sent to the server regardless of whether the
9418	// field is empty or not. This may be used to include empty fields in
9419	// Patch requests.
9420	ForceSendFields []string `json:"-"`
9421
9422	// NullFields is a list of field names (e.g. "EnableEntityExtraction")
9423	// to include in API requests with the JSON null value. By default,
9424	// fields with empty values are omitted from API requests. However, any
9425	// field with an empty value appearing in NullFields will be sent to the
9426	// server as null. It is an error if a field in this list has a
9427	// non-empty value. This may be used to include null fields in Patch
9428	// requests.
9429	NullFields []string `json:"-"`
9430}
9431
9432func (s *GoogleCloudDialogflowV2HumanAgentAssistantConfigMessageAnalysisConfig) MarshalJSON() ([]byte, error) {
9433	type NoMethod GoogleCloudDialogflowV2HumanAgentAssistantConfigMessageAnalysisConfig
9434	raw := NoMethod(*s)
9435	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
9436}
9437
9438// GoogleCloudDialogflowV2HumanAgentAssistantConfigSuggestionConfig:
9439// Detail human agent assistant config.
9440type GoogleCloudDialogflowV2HumanAgentAssistantConfigSuggestionConfig struct {
9441	// FeatureConfigs: Configuration of different suggestion features. One
9442	// feature can have only one config.
9443	FeatureConfigs []*GoogleCloudDialogflowV2HumanAgentAssistantConfigSuggestionFeatureConfig `json:"featureConfigs,omitempty"`
9444
9445	// GroupSuggestionResponses: If `group_suggestion_responses` is false,
9446	// and there are multiple `feature_configs` in `event based suggestion`
9447	// or StreamingAnalyzeContent, we will try to deliver suggestions to
9448	// customers as soon as we get new suggestion. Different type of
9449	// suggestions based on the same context will be in separate Pub/Sub
9450	// event or `StreamingAnalyzeContentResponse`. If
9451	// `group_suggestion_responses` set to true. All the suggestions to the
9452	// same participant based on the same context will be grouped into a
9453	// single Pub/Sub event or StreamingAnalyzeContentResponse.
9454	GroupSuggestionResponses bool `json:"groupSuggestionResponses,omitempty"`
9455
9456	// ForceSendFields is a list of field names (e.g. "FeatureConfigs") to
9457	// unconditionally include in API requests. By default, fields with
9458	// empty or default values are omitted from API requests. However, any
9459	// non-pointer, non-interface field appearing in ForceSendFields will be
9460	// sent to the server regardless of whether the field is empty or not.
9461	// This may be used to include empty fields in Patch requests.
9462	ForceSendFields []string `json:"-"`
9463
9464	// NullFields is a list of field names (e.g. "FeatureConfigs") to
9465	// include in API requests with the JSON null value. By default, fields
9466	// with empty values are omitted from API requests. However, any field
9467	// with an empty value appearing in NullFields will be sent to the
9468	// server as null. It is an error if a field in this list has a
9469	// non-empty value. This may be used to include null fields in Patch
9470	// requests.
9471	NullFields []string `json:"-"`
9472}
9473
9474func (s *GoogleCloudDialogflowV2HumanAgentAssistantConfigSuggestionConfig) MarshalJSON() ([]byte, error) {
9475	type NoMethod GoogleCloudDialogflowV2HumanAgentAssistantConfigSuggestionConfig
9476	raw := NoMethod(*s)
9477	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
9478}
9479
9480// GoogleCloudDialogflowV2HumanAgentAssistantConfigSuggestionFeatureConfi
9481// g: Config for suggestion features.
9482type GoogleCloudDialogflowV2HumanAgentAssistantConfigSuggestionFeatureConfig struct {
9483	// ConversationModelConfig: Configs of custom conversation model.
9484	ConversationModelConfig *GoogleCloudDialogflowV2HumanAgentAssistantConfigConversationModelConfig `json:"conversationModelConfig,omitempty"`
9485
9486	// EnableEventBasedSuggestion: Automatically iterates all participants
9487	// and tries to compile suggestions. Supported features:
9488	// ARTICLE_SUGGESTION, FAQ, DIALOGFLOW_ASSIST.
9489	EnableEventBasedSuggestion bool `json:"enableEventBasedSuggestion,omitempty"`
9490
9491	// QueryConfig: Configs of query.
9492	QueryConfig *GoogleCloudDialogflowV2HumanAgentAssistantConfigSuggestionQueryConfig `json:"queryConfig,omitempty"`
9493
9494	// SuggestionFeature: The suggestion feature.
9495	SuggestionFeature *GoogleCloudDialogflowV2SuggestionFeature `json:"suggestionFeature,omitempty"`
9496
9497	// SuggestionTriggerSettings: Settings of suggestion trigger. Currently,
9498	// only ARTICLE_SUGGESTION and FAQ will use this field.
9499	SuggestionTriggerSettings *GoogleCloudDialogflowV2HumanAgentAssistantConfigSuggestionTriggerSettings `json:"suggestionTriggerSettings,omitempty"`
9500
9501	// ForceSendFields is a list of field names (e.g.
9502	// "ConversationModelConfig") to unconditionally include in API
9503	// requests. By default, fields with empty or default values are omitted
9504	// from API requests. However, any non-pointer, non-interface field
9505	// appearing in ForceSendFields will be sent to the server regardless of
9506	// whether the field is empty or not. This may be used to include empty
9507	// fields in Patch requests.
9508	ForceSendFields []string `json:"-"`
9509
9510	// NullFields is a list of field names (e.g. "ConversationModelConfig")
9511	// to include in API requests with the JSON null value. By default,
9512	// fields with empty values are omitted from API requests. However, any
9513	// field with an empty value appearing in NullFields will be sent to the
9514	// server as null. It is an error if a field in this list has a
9515	// non-empty value. This may be used to include null fields in Patch
9516	// requests.
9517	NullFields []string `json:"-"`
9518}
9519
9520func (s *GoogleCloudDialogflowV2HumanAgentAssistantConfigSuggestionFeatureConfig) MarshalJSON() ([]byte, error) {
9521	type NoMethod GoogleCloudDialogflowV2HumanAgentAssistantConfigSuggestionFeatureConfig
9522	raw := NoMethod(*s)
9523	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
9524}
9525
9526// GoogleCloudDialogflowV2HumanAgentAssistantConfigSuggestionQueryConfig:
9527//  Config for suggestion query.
9528type GoogleCloudDialogflowV2HumanAgentAssistantConfigSuggestionQueryConfig struct {
9529	// ConfidenceThreshold: Confidence threshold of query result. Agent
9530	// Assist gives each suggestion a score in the range [0.0, 1.0], based
9531	// on the relevance between the suggestion and the current conversation
9532	// context. A score of 0.0 has no relevance, while a score of 1.0 has
9533	// high relevance. Only suggestions with a score greater than or equal
9534	// to the value of this field are included in the results. For a
9535	// baseline model (the default), the recommended value is in the range
9536	// [0.05, 0.1]. For a custom model, there is no recommended value. Tune
9537	// this value by starting from a very low value and slowly increasing
9538	// until you have desired results. If this field is not set, it defaults
9539	// to 0.0, which means that all suggestions are returned. Supported
9540	// features: ARTICLE_SUGGESTION.
9541	ConfidenceThreshold float64 `json:"confidenceThreshold,omitempty"`
9542
9543	// ContextFilterSettings: Determines how recent conversation context is
9544	// filtered when generating suggestions. If unspecified, no messages
9545	// will be dropped.
9546	ContextFilterSettings *GoogleCloudDialogflowV2HumanAgentAssistantConfigSuggestionQueryConfigContextFilterSettings `json:"contextFilterSettings,omitempty"`
9547
9548	// DialogflowQuerySource: Query from Dialogflow agent. It is used by
9549	// DIALOGFLOW_ASSIST.
9550	DialogflowQuerySource *GoogleCloudDialogflowV2HumanAgentAssistantConfigSuggestionQueryConfigDialogflowQuerySource `json:"dialogflowQuerySource,omitempty"`
9551
9552	// DocumentQuerySource: Query from knowledge base document. It is used
9553	// by: SMART_REPLY, SMART_COMPOSE.
9554	DocumentQuerySource *GoogleCloudDialogflowV2HumanAgentAssistantConfigSuggestionQueryConfigDocumentQuerySource `json:"documentQuerySource,omitempty"`
9555
9556	// KnowledgeBaseQuerySource: Query from knowledgebase. It is used by:
9557	// ARTICLE_SUGGESTION, FAQ.
9558	KnowledgeBaseQuerySource *GoogleCloudDialogflowV2HumanAgentAssistantConfigSuggestionQueryConfigKnowledgeBaseQuerySource `json:"knowledgeBaseQuerySource,omitempty"`
9559
9560	// MaxResults: Maximum number of results to return. Currently, if unset,
9561	// defaults to 10. And the max number is 20.
9562	MaxResults int64 `json:"maxResults,omitempty"`
9563
9564	// ForceSendFields is a list of field names (e.g. "ConfidenceThreshold")
9565	// to unconditionally include in API requests. By default, fields with
9566	// empty or default values are omitted from API requests. However, any
9567	// non-pointer, non-interface field appearing in ForceSendFields will be
9568	// sent to the server regardless of whether the field is empty or not.
9569	// This may be used to include empty fields in Patch requests.
9570	ForceSendFields []string `json:"-"`
9571
9572	// NullFields is a list of field names (e.g. "ConfidenceThreshold") to
9573	// include in API requests with the JSON null value. By default, fields
9574	// with empty values are omitted from API requests. However, any field
9575	// with an empty value appearing in NullFields will be sent to the
9576	// server as null. It is an error if a field in this list has a
9577	// non-empty value. This may be used to include null fields in Patch
9578	// requests.
9579	NullFields []string `json:"-"`
9580}
9581
9582func (s *GoogleCloudDialogflowV2HumanAgentAssistantConfigSuggestionQueryConfig) MarshalJSON() ([]byte, error) {
9583	type NoMethod GoogleCloudDialogflowV2HumanAgentAssistantConfigSuggestionQueryConfig
9584	raw := NoMethod(*s)
9585	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
9586}
9587
9588func (s *GoogleCloudDialogflowV2HumanAgentAssistantConfigSuggestionQueryConfig) UnmarshalJSON(data []byte) error {
9589	type NoMethod GoogleCloudDialogflowV2HumanAgentAssistantConfigSuggestionQueryConfig
9590	var s1 struct {
9591		ConfidenceThreshold gensupport.JSONFloat64 `json:"confidenceThreshold"`
9592		*NoMethod
9593	}
9594	s1.NoMethod = (*NoMethod)(s)
9595	if err := json.Unmarshal(data, &s1); err != nil {
9596		return err
9597	}
9598	s.ConfidenceThreshold = float64(s1.ConfidenceThreshold)
9599	return nil
9600}
9601
9602// GoogleCloudDialogflowV2HumanAgentAssistantConfigSuggestionQueryConfigC
9603// ontextFilterSettings: Settings that determine how to filter recent
9604// conversation context when generating suggestions.
9605type GoogleCloudDialogflowV2HumanAgentAssistantConfigSuggestionQueryConfigContextFilterSettings struct {
9606	// DropHandoffMessages: If set to true, the last message from virtual
9607	// agent (hand off message) and the message before it (trigger message
9608	// of hand off) are dropped.
9609	DropHandoffMessages bool `json:"dropHandoffMessages,omitempty"`
9610
9611	// DropIvrMessages: If set to true, all messages from ivr stage are
9612	// dropped.
9613	DropIvrMessages bool `json:"dropIvrMessages,omitempty"`
9614
9615	// DropVirtualAgentMessages: If set to true, all messages from virtual
9616	// agent are dropped.
9617	DropVirtualAgentMessages bool `json:"dropVirtualAgentMessages,omitempty"`
9618
9619	// ForceSendFields is a list of field names (e.g. "DropHandoffMessages")
9620	// to unconditionally include in API requests. By default, fields with
9621	// empty or default values are omitted from API requests. However, any
9622	// non-pointer, non-interface field appearing in ForceSendFields will be
9623	// sent to the server regardless of whether the field is empty or not.
9624	// This may be used to include empty fields in Patch requests.
9625	ForceSendFields []string `json:"-"`
9626
9627	// NullFields is a list of field names (e.g. "DropHandoffMessages") to
9628	// include in API requests with the JSON null value. By default, fields
9629	// with empty values are omitted from API requests. However, any field
9630	// with an empty value appearing in NullFields will be sent to the
9631	// server as null. It is an error if a field in this list has a
9632	// non-empty value. This may be used to include null fields in Patch
9633	// requests.
9634	NullFields []string `json:"-"`
9635}
9636
9637func (s *GoogleCloudDialogflowV2HumanAgentAssistantConfigSuggestionQueryConfigContextFilterSettings) MarshalJSON() ([]byte, error) {
9638	type NoMethod GoogleCloudDialogflowV2HumanAgentAssistantConfigSuggestionQueryConfigContextFilterSettings
9639	raw := NoMethod(*s)
9640	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
9641}
9642
9643// GoogleCloudDialogflowV2HumanAgentAssistantConfigSuggestionQueryConfigD
9644// ialogflowQuerySource: Dialogflow source setting. Supported feature:
9645// DIALOGFLOW_ASSIST.
9646type GoogleCloudDialogflowV2HumanAgentAssistantConfigSuggestionQueryConfigDialogflowQuerySource struct {
9647	// Agent: Required. The name of a Dialogflow virtual agent used for end
9648	// user side intent detection and suggestion. Format:
9649	// `projects//locations//agent`. When multiple agents are allowed in the
9650	// same Dialogflow project.
9651	Agent string `json:"agent,omitempty"`
9652
9653	// ForceSendFields is a list of field names (e.g. "Agent") to
9654	// unconditionally include in API requests. By default, fields with
9655	// empty or default values are omitted from API requests. However, any
9656	// non-pointer, non-interface field appearing in ForceSendFields will be
9657	// sent to the server regardless of whether the field is empty or not.
9658	// This may be used to include empty fields in Patch requests.
9659	ForceSendFields []string `json:"-"`
9660
9661	// NullFields is a list of field names (e.g. "Agent") to include in API
9662	// requests with the JSON null value. By default, fields with empty
9663	// values are omitted from API requests. However, any field with an
9664	// empty value appearing in NullFields will be sent to the server as
9665	// null. It is an error if a field in this list has a non-empty value.
9666	// This may be used to include null fields in Patch requests.
9667	NullFields []string `json:"-"`
9668}
9669
9670func (s *GoogleCloudDialogflowV2HumanAgentAssistantConfigSuggestionQueryConfigDialogflowQuerySource) MarshalJSON() ([]byte, error) {
9671	type NoMethod GoogleCloudDialogflowV2HumanAgentAssistantConfigSuggestionQueryConfigDialogflowQuerySource
9672	raw := NoMethod(*s)
9673	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
9674}
9675
9676// GoogleCloudDialogflowV2HumanAgentAssistantConfigSuggestionQueryConfigD
9677// ocumentQuerySource: Document source settings. Supported features:
9678// SMART_REPLY, SMART_COMPOSE.
9679type GoogleCloudDialogflowV2HumanAgentAssistantConfigSuggestionQueryConfigDocumentQuerySource struct {
9680	// Documents: Required. Knowledge documents to query from. Format:
9681	// `projects//locations//knowledgeBases//documents/`. Currently, at most
9682	// 5 documents are supported.
9683	Documents []string `json:"documents,omitempty"`
9684
9685	// ForceSendFields is a list of field names (e.g. "Documents") to
9686	// unconditionally include in API requests. By default, fields with
9687	// empty or default values are omitted from API requests. However, any
9688	// non-pointer, non-interface field appearing in ForceSendFields will be
9689	// sent to the server regardless of whether the field is empty or not.
9690	// This may be used to include empty fields in Patch requests.
9691	ForceSendFields []string `json:"-"`
9692
9693	// NullFields is a list of field names (e.g. "Documents") to include in
9694	// API requests with the JSON null value. By default, fields with empty
9695	// values are omitted from API requests. However, any field with an
9696	// empty value appearing in NullFields will be sent to the server as
9697	// null. It is an error if a field in this list has a non-empty value.
9698	// This may be used to include null fields in Patch requests.
9699	NullFields []string `json:"-"`
9700}
9701
9702func (s *GoogleCloudDialogflowV2HumanAgentAssistantConfigSuggestionQueryConfigDocumentQuerySource) MarshalJSON() ([]byte, error) {
9703	type NoMethod GoogleCloudDialogflowV2HumanAgentAssistantConfigSuggestionQueryConfigDocumentQuerySource
9704	raw := NoMethod(*s)
9705	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
9706}
9707
9708// GoogleCloudDialogflowV2HumanAgentAssistantConfigSuggestionQueryConfigK
9709// nowledgeBaseQuerySource: Knowledge base source settings. Supported
9710// features: ARTICLE_SUGGESTION, FAQ.
9711type GoogleCloudDialogflowV2HumanAgentAssistantConfigSuggestionQueryConfigKnowledgeBaseQuerySource struct {
9712	// KnowledgeBases: Required. Knowledge bases to query. Format:
9713	// `projects//locations//knowledgeBases/`. Currently, at most 5
9714	// knowledge bases are supported.
9715	KnowledgeBases []string `json:"knowledgeBases,omitempty"`
9716
9717	// ForceSendFields is a list of field names (e.g. "KnowledgeBases") to
9718	// unconditionally include in API requests. By default, fields with
9719	// empty or default values are omitted from API requests. However, any
9720	// non-pointer, non-interface field appearing in ForceSendFields will be
9721	// sent to the server regardless of whether the field is empty or not.
9722	// This may be used to include empty fields in Patch requests.
9723	ForceSendFields []string `json:"-"`
9724
9725	// NullFields is a list of field names (e.g. "KnowledgeBases") to
9726	// include in API requests with the JSON null value. By default, fields
9727	// with empty values are omitted from API requests. However, any field
9728	// with an empty value appearing in NullFields will be sent to the
9729	// server as null. It is an error if a field in this list has a
9730	// non-empty value. This may be used to include null fields in Patch
9731	// requests.
9732	NullFields []string `json:"-"`
9733}
9734
9735func (s *GoogleCloudDialogflowV2HumanAgentAssistantConfigSuggestionQueryConfigKnowledgeBaseQuerySource) MarshalJSON() ([]byte, error) {
9736	type NoMethod GoogleCloudDialogflowV2HumanAgentAssistantConfigSuggestionQueryConfigKnowledgeBaseQuerySource
9737	raw := NoMethod(*s)
9738	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
9739}
9740
9741// GoogleCloudDialogflowV2HumanAgentAssistantConfigSuggestionTriggerSetti
9742// ngs: Settings of suggestion trigger.
9743type GoogleCloudDialogflowV2HumanAgentAssistantConfigSuggestionTriggerSettings struct {
9744	// NoSmalltalk: Do not trigger if last utterance is small talk.
9745	NoSmalltalk bool `json:"noSmalltalk,omitempty"`
9746
9747	// OnlyEndUser: Only trigger suggestion if participant role of last
9748	// utterance is END_USER.
9749	OnlyEndUser bool `json:"onlyEndUser,omitempty"`
9750
9751	// ForceSendFields is a list of field names (e.g. "NoSmalltalk") to
9752	// unconditionally include in API requests. By default, fields with
9753	// empty or default values are omitted from API requests. However, any
9754	// non-pointer, non-interface field appearing in ForceSendFields will be
9755	// sent to the server regardless of whether the field is empty or not.
9756	// This may be used to include empty fields in Patch requests.
9757	ForceSendFields []string `json:"-"`
9758
9759	// NullFields is a list of field names (e.g. "NoSmalltalk") to include
9760	// in API requests with the JSON null value. By default, fields with
9761	// empty values are omitted from API requests. However, any field with
9762	// an empty value appearing in NullFields will be sent to the server as
9763	// null. It is an error if a field in this list has a non-empty value.
9764	// This may be used to include null fields in Patch requests.
9765	NullFields []string `json:"-"`
9766}
9767
9768func (s *GoogleCloudDialogflowV2HumanAgentAssistantConfigSuggestionTriggerSettings) MarshalJSON() ([]byte, error) {
9769	type NoMethod GoogleCloudDialogflowV2HumanAgentAssistantConfigSuggestionTriggerSettings
9770	raw := NoMethod(*s)
9771	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
9772}
9773
9774// GoogleCloudDialogflowV2HumanAgentAssistantEvent: Represents a
9775// notification sent to Cloud Pub/Sub subscribers for human agent
9776// assistant events in a specific conversation.
9777type GoogleCloudDialogflowV2HumanAgentAssistantEvent struct {
9778	// Conversation: The conversation this notification refers to. Format:
9779	// `projects//conversations/`.
9780	Conversation string `json:"conversation,omitempty"`
9781
9782	// Participant: The participant that the suggestion is compiled for.
9783	// Format: `projects//conversations//participants/`. It will not be set
9784	// in legacy workflow.
9785	Participant string `json:"participant,omitempty"`
9786
9787	// SuggestionResults: The suggestion results payload that this
9788	// notification refers to.
9789	SuggestionResults []*GoogleCloudDialogflowV2SuggestionResult `json:"suggestionResults,omitempty"`
9790
9791	// ForceSendFields is a list of field names (e.g. "Conversation") to
9792	// unconditionally include in API requests. By default, fields with
9793	// empty or default values are omitted from API requests. However, any
9794	// non-pointer, non-interface field appearing in ForceSendFields will be
9795	// sent to the server regardless of whether the field is empty or not.
9796	// This may be used to include empty fields in Patch requests.
9797	ForceSendFields []string `json:"-"`
9798
9799	// NullFields is a list of field names (e.g. "Conversation") to include
9800	// in API requests with the JSON null value. By default, fields with
9801	// empty values are omitted from API requests. However, any field with
9802	// an empty value appearing in NullFields will be sent to the server as
9803	// null. It is an error if a field in this list has a non-empty value.
9804	// This may be used to include null fields in Patch requests.
9805	NullFields []string `json:"-"`
9806}
9807
9808func (s *GoogleCloudDialogflowV2HumanAgentAssistantEvent) MarshalJSON() ([]byte, error) {
9809	type NoMethod GoogleCloudDialogflowV2HumanAgentAssistantEvent
9810	raw := NoMethod(*s)
9811	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
9812}
9813
9814// GoogleCloudDialogflowV2HumanAgentHandoffConfig: Defines the hand off
9815// to a live agent, typically on which external agent service provider
9816// to connect to a conversation. Currently, this feature is not general
9817// available, please contact Google to get access.
9818type GoogleCloudDialogflowV2HumanAgentHandoffConfig struct {
9819	// LivePersonConfig: Uses LivePerson (https://www.liveperson.com).
9820	LivePersonConfig *GoogleCloudDialogflowV2HumanAgentHandoffConfigLivePersonConfig `json:"livePersonConfig,omitempty"`
9821
9822	// SalesforceLiveAgentConfig: Uses Salesforce Live Agent.
9823	SalesforceLiveAgentConfig *GoogleCloudDialogflowV2HumanAgentHandoffConfigSalesforceLiveAgentConfig `json:"salesforceLiveAgentConfig,omitempty"`
9824
9825	// ForceSendFields is a list of field names (e.g. "LivePersonConfig") to
9826	// unconditionally include in API requests. By default, fields with
9827	// empty or default values are omitted from API requests. However, any
9828	// non-pointer, non-interface field appearing in ForceSendFields will be
9829	// sent to the server regardless of whether the field is empty or not.
9830	// This may be used to include empty fields in Patch requests.
9831	ForceSendFields []string `json:"-"`
9832
9833	// NullFields is a list of field names (e.g. "LivePersonConfig") to
9834	// include in API requests with the JSON null value. By default, fields
9835	// with empty values are omitted from API requests. However, any field
9836	// with an empty value appearing in NullFields will be sent to the
9837	// server as null. It is an error if a field in this list has a
9838	// non-empty value. This may be used to include null fields in Patch
9839	// requests.
9840	NullFields []string `json:"-"`
9841}
9842
9843func (s *GoogleCloudDialogflowV2HumanAgentHandoffConfig) MarshalJSON() ([]byte, error) {
9844	type NoMethod GoogleCloudDialogflowV2HumanAgentHandoffConfig
9845	raw := NoMethod(*s)
9846	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
9847}
9848
9849// GoogleCloudDialogflowV2HumanAgentHandoffConfigLivePersonConfig:
9850// Configuration specific to LivePerson (https://www.liveperson.com).
9851type GoogleCloudDialogflowV2HumanAgentHandoffConfigLivePersonConfig struct {
9852	// AccountNumber: Required. Account number of the LivePerson account to
9853	// connect. This is the account number you input at the login page.
9854	AccountNumber string `json:"accountNumber,omitempty"`
9855
9856	// ForceSendFields is a list of field names (e.g. "AccountNumber") to
9857	// unconditionally include in API requests. By default, fields with
9858	// empty or default values are omitted from API requests. However, any
9859	// non-pointer, non-interface field appearing in ForceSendFields will be
9860	// sent to the server regardless of whether the field is empty or not.
9861	// This may be used to include empty fields in Patch requests.
9862	ForceSendFields []string `json:"-"`
9863
9864	// NullFields is a list of field names (e.g. "AccountNumber") to include
9865	// in API requests with the JSON null value. By default, fields with
9866	// empty values are omitted from API requests. However, any field with
9867	// an empty value appearing in NullFields will be sent to the server as
9868	// null. It is an error if a field in this list has a non-empty value.
9869	// This may be used to include null fields in Patch requests.
9870	NullFields []string `json:"-"`
9871}
9872
9873func (s *GoogleCloudDialogflowV2HumanAgentHandoffConfigLivePersonConfig) MarshalJSON() ([]byte, error) {
9874	type NoMethod GoogleCloudDialogflowV2HumanAgentHandoffConfigLivePersonConfig
9875	raw := NoMethod(*s)
9876	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
9877}
9878
9879// GoogleCloudDialogflowV2HumanAgentHandoffConfigSalesforceLiveAgentConfi
9880// g: Configuration specific to Salesforce Live Agent.
9881type GoogleCloudDialogflowV2HumanAgentHandoffConfigSalesforceLiveAgentConfig struct {
9882	// ButtonId: Required. Live Agent chat button ID.
9883	ButtonId string `json:"buttonId,omitempty"`
9884
9885	// DeploymentId: Required. Live Agent deployment ID.
9886	DeploymentId string `json:"deploymentId,omitempty"`
9887
9888	// EndpointDomain: Required. Domain of the Live Agent endpoint for this
9889	// agent. You can find the endpoint URL in the `Live Agent settings`
9890	// page. For example if URL has the form
9891	// https://d.la4-c2-phx.salesforceliveagent.com/..., you should fill in
9892	// d.la4-c2-phx.salesforceliveagent.com.
9893	EndpointDomain string `json:"endpointDomain,omitempty"`
9894
9895	// OrganizationId: Required. The organization ID of the Salesforce
9896	// account.
9897	OrganizationId string `json:"organizationId,omitempty"`
9898
9899	// ForceSendFields is a list of field names (e.g. "ButtonId") to
9900	// unconditionally include in API requests. By default, fields with
9901	// empty or default values are omitted from API requests. However, any
9902	// non-pointer, non-interface field appearing in ForceSendFields will be
9903	// sent to the server regardless of whether the field is empty or not.
9904	// This may be used to include empty fields in Patch requests.
9905	ForceSendFields []string `json:"-"`
9906
9907	// NullFields is a list of field names (e.g. "ButtonId") to include in
9908	// API requests with the JSON null value. By default, fields with empty
9909	// values are omitted from API requests. However, any field with an
9910	// empty value appearing in NullFields will be sent to the server as
9911	// null. It is an error if a field in this list has a non-empty value.
9912	// This may be used to include null fields in Patch requests.
9913	NullFields []string `json:"-"`
9914}
9915
9916func (s *GoogleCloudDialogflowV2HumanAgentHandoffConfigSalesforceLiveAgentConfig) MarshalJSON() ([]byte, error) {
9917	type NoMethod GoogleCloudDialogflowV2HumanAgentHandoffConfigSalesforceLiveAgentConfig
9918	raw := NoMethod(*s)
9919	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
9920}
9921
9922// GoogleCloudDialogflowV2ImportAgentRequest: The request message for
9923// Agents.ImportAgent.
9924type GoogleCloudDialogflowV2ImportAgentRequest struct {
9925	// AgentContent: Zip compressed raw byte content for agent.
9926	AgentContent string `json:"agentContent,omitempty"`
9927
9928	// AgentUri: The URI to a Google Cloud Storage file containing the agent
9929	// to import. Note: The URI must start with "gs://".
9930	AgentUri string `json:"agentUri,omitempty"`
9931
9932	// ForceSendFields is a list of field names (e.g. "AgentContent") to
9933	// unconditionally include in API requests. By default, fields with
9934	// empty or default values are omitted from API requests. However, any
9935	// non-pointer, non-interface field appearing in ForceSendFields will be
9936	// sent to the server regardless of whether the field is empty or not.
9937	// This may be used to include empty fields in Patch requests.
9938	ForceSendFields []string `json:"-"`
9939
9940	// NullFields is a list of field names (e.g. "AgentContent") to include
9941	// in API requests with the JSON null value. By default, fields with
9942	// empty values are omitted from API requests. However, any field with
9943	// an empty value appearing in NullFields will be sent to the server as
9944	// null. It is an error if a field in this list has a non-empty value.
9945	// This may be used to include null fields in Patch requests.
9946	NullFields []string `json:"-"`
9947}
9948
9949func (s *GoogleCloudDialogflowV2ImportAgentRequest) MarshalJSON() ([]byte, error) {
9950	type NoMethod GoogleCloudDialogflowV2ImportAgentRequest
9951	raw := NoMethod(*s)
9952	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
9953}
9954
9955// GoogleCloudDialogflowV2InputAudioConfig: Instructs the speech
9956// recognizer how to process the audio content.
9957type GoogleCloudDialogflowV2InputAudioConfig struct {
9958	// AudioEncoding: Required. Audio encoding of the audio content to
9959	// process.
9960	//
9961	// Possible values:
9962	//   "AUDIO_ENCODING_UNSPECIFIED" - Not specified.
9963	//   "AUDIO_ENCODING_LINEAR_16" - Uncompressed 16-bit signed
9964	// little-endian samples (Linear PCM).
9965	//   "AUDIO_ENCODING_FLAC" -
9966	// [`FLAC`](https://xiph.org/flac/documentation.html) (Free Lossless
9967	// Audio Codec) is the recommended encoding because it is lossless
9968	// (therefore recognition is not compromised) and requires only about
9969	// half the bandwidth of `LINEAR16`. `FLAC` stream encoding supports
9970	// 16-bit and 24-bit samples, however, not all fields in `STREAMINFO`
9971	// are supported.
9972	//   "AUDIO_ENCODING_MULAW" - 8-bit samples that compand 14-bit audio
9973	// samples using G.711 PCMU/mu-law.
9974	//   "AUDIO_ENCODING_AMR" - Adaptive Multi-Rate Narrowband codec.
9975	// `sample_rate_hertz` must be 8000.
9976	//   "AUDIO_ENCODING_AMR_WB" - Adaptive Multi-Rate Wideband codec.
9977	// `sample_rate_hertz` must be 16000.
9978	//   "AUDIO_ENCODING_OGG_OPUS" - Opus encoded audio frames in Ogg
9979	// container ([OggOpus](https://wiki.xiph.org/OggOpus)).
9980	// `sample_rate_hertz` must be 16000.
9981	//   "AUDIO_ENCODING_SPEEX_WITH_HEADER_BYTE" - Although the use of lossy
9982	// encodings is not recommended, if a very low bitrate encoding is
9983	// required, `OGG_OPUS` is highly preferred over Speex encoding. The
9984	// [Speex](https://speex.org/) encoding supported by Dialogflow API has
9985	// a header byte in each block, as in MIME type
9986	// `audio/x-speex-with-header-byte`. It is a variant of the RTP Speex
9987	// encoding defined in [RFC 5574](https://tools.ietf.org/html/rfc5574).
9988	// The stream is a sequence of blocks, one block per RTP packet. Each
9989	// block starts with a byte containing the length of the block, in
9990	// bytes, followed by one or more frames of Speex data, padded to an
9991	// integral number of bytes (octets) as specified in RFC 5574. In other
9992	// words, each RTP header is replaced with a single byte containing the
9993	// block length. Only Speex wideband is supported. `sample_rate_hertz`
9994	// must be 16000.
9995	AudioEncoding string `json:"audioEncoding,omitempty"`
9996
9997	// DisableNoSpeechRecognizedEvent: Only used in
9998	// Participants.AnalyzeContent and Participants.StreamingAnalyzeContent.
9999	// If `false` and recognition doesn't return any result, trigger
10000	// `NO_SPEECH_RECOGNIZED` event to Dialogflow agent.
10001	DisableNoSpeechRecognizedEvent bool `json:"disableNoSpeechRecognizedEvent,omitempty"`
10002
10003	// EnableWordInfo: If `true`, Dialogflow returns SpeechWordInfo in
10004	// StreamingRecognitionResult with information about the recognized
10005	// speech words, e.g. start and end time offsets. If false or
10006	// unspecified, Speech doesn't return any word-level information.
10007	EnableWordInfo bool `json:"enableWordInfo,omitempty"`
10008
10009	// LanguageCode: Required. The language of the supplied audio.
10010	// Dialogflow does not do translations. See Language Support
10011	// (https://cloud.google.com/dialogflow/docs/reference/language) for a
10012	// list of the currently supported language codes. Note that queries in
10013	// the same session do not necessarily need to specify the same
10014	// language.
10015	LanguageCode string `json:"languageCode,omitempty"`
10016
10017	// Model: Which Speech model to select for the given request. Select the
10018	// model best suited to your domain to get best results. If a model is
10019	// not explicitly specified, then we auto-select a model based on the
10020	// parameters in the InputAudioConfig. If enhanced speech model is
10021	// enabled for the agent and an enhanced version of the specified model
10022	// for the language does not exist, then the speech is recognized using
10023	// the standard version of the specified model. Refer to Cloud Speech
10024	// API documentation
10025	// (https://cloud.google.com/speech-to-text/docs/basics#select-model)
10026	// for more details.
10027	Model string `json:"model,omitempty"`
10028
10029	// ModelVariant: Which variant of the Speech model to use.
10030	//
10031	// Possible values:
10032	//   "SPEECH_MODEL_VARIANT_UNSPECIFIED" - No model variant specified. In
10033	// this case Dialogflow defaults to USE_BEST_AVAILABLE.
10034	//   "USE_BEST_AVAILABLE" - Use the best available variant of the Speech
10035	// model that the caller is eligible for. Please see the [Dialogflow
10036	// docs](https://cloud.google.com/dialogflow/docs/data-logging) for how
10037	// to make your project eligible for enhanced models.
10038	//   "USE_STANDARD" - Use standard model variant even if an enhanced
10039	// model is available. See the [Cloud Speech
10040	// documentation](https://cloud.google.com/speech-to-text/docs/enhanced-m
10041	// odels) for details about enhanced models.
10042	//   "USE_ENHANCED" - Use an enhanced model variant: * If an enhanced
10043	// variant does not exist for the given model and request language,
10044	// Dialogflow falls back to the standard variant. The [Cloud Speech
10045	// documentation](https://cloud.google.com/speech-to-text/docs/enhanced-m
10046	// odels) describes which models have enhanced variants. * If the API
10047	// caller isn't eligible for enhanced models, Dialogflow returns an
10048	// error. Please see the [Dialogflow
10049	// docs](https://cloud.google.com/dialogflow/docs/data-logging) for how
10050	// to make your project eligible.
10051	ModelVariant string `json:"modelVariant,omitempty"`
10052
10053	// PhraseHints: A list of strings containing words and phrases that the
10054	// speech recognizer should recognize with higher likelihood. See the
10055	// Cloud Speech documentation
10056	// (https://cloud.google.com/speech-to-text/docs/basics#phrase-hints)
10057	// for more details. This field is deprecated. Please use
10058	// speech_contexts () instead. If you specify both phrase_hints () and
10059	// speech_contexts (), Dialogflow will treat the phrase_hints () as a
10060	// single additional SpeechContext ().
10061	PhraseHints []string `json:"phraseHints,omitempty"`
10062
10063	// SampleRateHertz: Required. Sample rate (in Hertz) of the audio
10064	// content sent in the query. Refer to Cloud Speech API documentation
10065	// (https://cloud.google.com/speech-to-text/docs/basics) for more
10066	// details.
10067	SampleRateHertz int64 `json:"sampleRateHertz,omitempty"`
10068
10069	// SingleUtterance: If `false` (default), recognition does not cease
10070	// until the client closes the stream. If `true`, the recognizer will
10071	// detect a single spoken utterance in input audio. Recognition ceases
10072	// when it detects the audio's voice has stopped or paused. In this
10073	// case, once a detected intent is received, the client should close the
10074	// stream and start a new request with a new stream as needed. Note:
10075	// This setting is relevant only for streaming methods. Note: When
10076	// specified, InputAudioConfig.single_utterance takes precedence over
10077	// StreamingDetectIntentRequest.single_utterance.
10078	SingleUtterance bool `json:"singleUtterance,omitempty"`
10079
10080	// SpeechContexts: Context information to assist speech recognition. See
10081	// the Cloud Speech documentation
10082	// (https://cloud.google.com/speech-to-text/docs/basics#phrase-hints)
10083	// for more details.
10084	SpeechContexts []*GoogleCloudDialogflowV2SpeechContext `json:"speechContexts,omitempty"`
10085
10086	// ForceSendFields is a list of field names (e.g. "AudioEncoding") to
10087	// unconditionally include in API requests. By default, fields with
10088	// empty or default values are omitted from API requests. However, any
10089	// non-pointer, non-interface field appearing in ForceSendFields will be
10090	// sent to the server regardless of whether the field is empty or not.
10091	// This may be used to include empty fields in Patch requests.
10092	ForceSendFields []string `json:"-"`
10093
10094	// NullFields is a list of field names (e.g. "AudioEncoding") to include
10095	// in API requests with the JSON null value. By default, fields with
10096	// empty values are omitted from API requests. However, any field with
10097	// an empty value appearing in NullFields will be sent to the server as
10098	// null. It is an error if a field in this list has a non-empty value.
10099	// This may be used to include null fields in Patch requests.
10100	NullFields []string `json:"-"`
10101}
10102
10103func (s *GoogleCloudDialogflowV2InputAudioConfig) MarshalJSON() ([]byte, error) {
10104	type NoMethod GoogleCloudDialogflowV2InputAudioConfig
10105	raw := NoMethod(*s)
10106	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
10107}
10108
10109// GoogleCloudDialogflowV2Intent: An intent categorizes an end-user's
10110// intention for one conversation turn. For each agent, you define many
10111// intents, where your combined intents can handle a complete
10112// conversation. When an end-user writes or says something, referred to
10113// as an end-user expression or end-user input, Dialogflow matches the
10114// end-user input to the best intent in your agent. Matching an intent
10115// is also known as intent classification. For more information, see the
10116// intent guide
10117// (https://cloud.google.com/dialogflow/docs/intents-overview).
10118type GoogleCloudDialogflowV2Intent struct {
10119	// Action: Optional. The name of the action associated with the intent.
10120	// Note: The action name must not contain whitespaces.
10121	Action string `json:"action,omitempty"`
10122
10123	// DefaultResponsePlatforms: Optional. The list of platforms for which
10124	// the first responses will be copied from the messages in
10125	// PLATFORM_UNSPECIFIED (i.e. default platform).
10126	//
10127	// Possible values:
10128	//   "PLATFORM_UNSPECIFIED" - Default platform.
10129	//   "FACEBOOK" - Facebook.
10130	//   "SLACK" - Slack.
10131	//   "TELEGRAM" - Telegram.
10132	//   "KIK" - Kik.
10133	//   "SKYPE" - Skype.
10134	//   "LINE" - Line.
10135	//   "VIBER" - Viber.
10136	//   "ACTIONS_ON_GOOGLE" - Google Assistant See [Dialogflow webhook
10137	// format](https://developers.google.com/assistant/actions/build/json/dia
10138	// logflow-webhook-json)
10139	//   "GOOGLE_HANGOUTS" - Google Hangouts.
10140	DefaultResponsePlatforms []string `json:"defaultResponsePlatforms,omitempty"`
10141
10142	// DisplayName: Required. The name of this intent.
10143	DisplayName string `json:"displayName,omitempty"`
10144
10145	// EndInteraction: Optional. Indicates that this intent ends an
10146	// interaction. Some integrations (e.g., Actions on Google or Dialogflow
10147	// phone gateway) use this information to close interaction with an end
10148	// user. Default is false.
10149	EndInteraction bool `json:"endInteraction,omitempty"`
10150
10151	// Events: Optional. The collection of event names that trigger the
10152	// intent. If the collection of input contexts is not empty, all of the
10153	// contexts must be present in the active user session for an event to
10154	// trigger this intent. Event names are limited to 150 characters.
10155	Events []string `json:"events,omitempty"`
10156
10157	// FollowupIntentInfo: Output only. Read-only. Information about all
10158	// followup intents that have this intent as a direct or indirect
10159	// parent. We populate this field only in the output.
10160	FollowupIntentInfo []*GoogleCloudDialogflowV2IntentFollowupIntentInfo `json:"followupIntentInfo,omitempty"`
10161
10162	// InputContextNames: Optional. The list of context names required for
10163	// this intent to be triggered. Format:
10164	// `projects//agent/sessions/-/contexts/`.
10165	InputContextNames []string `json:"inputContextNames,omitempty"`
10166
10167	// IsFallback: Optional. Indicates whether this is a fallback intent.
10168	IsFallback bool `json:"isFallback,omitempty"`
10169
10170	// LiveAgentHandoff: Optional. Indicates that a live agent should be
10171	// brought in to handle the interaction with the user. In most cases,
10172	// when you set this flag to true, you would also want to set
10173	// end_interaction to true as well. Default is false.
10174	LiveAgentHandoff bool `json:"liveAgentHandoff,omitempty"`
10175
10176	// Messages: Optional. The collection of rich messages corresponding to
10177	// the `Response` field in the Dialogflow console.
10178	Messages []*GoogleCloudDialogflowV2IntentMessage `json:"messages,omitempty"`
10179
10180	// MlDisabled: Optional. Indicates whether Machine Learning is disabled
10181	// for the intent. Note: If `ml_disabled` setting is set to true, then
10182	// this intent is not taken into account during inference in `ML ONLY`
10183	// match mode. Also, auto-markup in the UI is turned off.
10184	MlDisabled bool `json:"mlDisabled,omitempty"`
10185
10186	// Name: Optional. The unique identifier of this intent. Required for
10187	// Intents.UpdateIntent and Intents.BatchUpdateIntents methods. Format:
10188	// `projects//agent/intents/`.
10189	Name string `json:"name,omitempty"`
10190
10191	// OutputContexts: Optional. The collection of contexts that are
10192	// activated when the intent is matched. Context messages in this
10193	// collection should not set the parameters field. Setting the
10194	// `lifespan_count` to 0 will reset the context when the intent is
10195	// matched. Format: `projects//agent/sessions/-/contexts/`.
10196	OutputContexts []*GoogleCloudDialogflowV2Context `json:"outputContexts,omitempty"`
10197
10198	// Parameters: Optional. The collection of parameters associated with
10199	// the intent.
10200	Parameters []*GoogleCloudDialogflowV2IntentParameter `json:"parameters,omitempty"`
10201
10202	// ParentFollowupIntentName: Read-only after creation. The unique
10203	// identifier of the parent intent in the chain of followup intents. You
10204	// can set this field when creating an intent, for example with
10205	// CreateIntent or BatchUpdateIntents, in order to make this intent a
10206	// followup intent. It identifies the parent followup intent. Format:
10207	// `projects//agent/intents/`.
10208	ParentFollowupIntentName string `json:"parentFollowupIntentName,omitempty"`
10209
10210	// Priority: Optional. The priority of this intent. Higher numbers
10211	// represent higher priorities. - If the supplied value is unspecified
10212	// or 0, the service translates the value to 500,000, which corresponds
10213	// to the `Normal` priority in the console. - If the supplied value is
10214	// negative, the intent is ignored in runtime detect intent requests.
10215	Priority int64 `json:"priority,omitempty"`
10216
10217	// ResetContexts: Optional. Indicates whether to delete all contexts in
10218	// the current session when this intent is matched.
10219	ResetContexts bool `json:"resetContexts,omitempty"`
10220
10221	// RootFollowupIntentName: Output only. Read-only. The unique identifier
10222	// of the root intent in the chain of followup intents. It identifies
10223	// the correct followup intents chain for this intent. We populate this
10224	// field only in the output. Format: `projects//agent/intents/`.
10225	RootFollowupIntentName string `json:"rootFollowupIntentName,omitempty"`
10226
10227	// TrainingPhrases: Optional. The collection of examples that the agent
10228	// is trained on.
10229	TrainingPhrases []*GoogleCloudDialogflowV2IntentTrainingPhrase `json:"trainingPhrases,omitempty"`
10230
10231	// WebhookState: Optional. Indicates whether webhooks are enabled for
10232	// the intent.
10233	//
10234	// Possible values:
10235	//   "WEBHOOK_STATE_UNSPECIFIED" - Webhook is disabled in the agent and
10236	// in the intent.
10237	//   "WEBHOOK_STATE_ENABLED" - Webhook is enabled in the agent and in
10238	// the intent.
10239	//   "WEBHOOK_STATE_ENABLED_FOR_SLOT_FILLING" - Webhook is enabled in
10240	// the agent and in the intent. Also, each slot filling prompt is
10241	// forwarded to the webhook.
10242	WebhookState string `json:"webhookState,omitempty"`
10243
10244	// ServerResponse contains the HTTP response code and headers from the
10245	// server.
10246	googleapi.ServerResponse `json:"-"`
10247
10248	// ForceSendFields is a list of field names (e.g. "Action") to
10249	// unconditionally include in API requests. By default, fields with
10250	// empty or default values are omitted from API requests. However, any
10251	// non-pointer, non-interface field appearing in ForceSendFields will be
10252	// sent to the server regardless of whether the field is empty or not.
10253	// This may be used to include empty fields in Patch requests.
10254	ForceSendFields []string `json:"-"`
10255
10256	// NullFields is a list of field names (e.g. "Action") to include in API
10257	// requests with the JSON null value. By default, fields with empty
10258	// values are omitted from API requests. However, any field with an
10259	// empty value appearing in NullFields will be sent to the server as
10260	// null. It is an error if a field in this list has a non-empty value.
10261	// This may be used to include null fields in Patch requests.
10262	NullFields []string `json:"-"`
10263}
10264
10265func (s *GoogleCloudDialogflowV2Intent) MarshalJSON() ([]byte, error) {
10266	type NoMethod GoogleCloudDialogflowV2Intent
10267	raw := NoMethod(*s)
10268	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
10269}
10270
10271// GoogleCloudDialogflowV2IntentBatch: This message is a wrapper around
10272// a collection of intents.
10273type GoogleCloudDialogflowV2IntentBatch struct {
10274	// Intents: A collection of intents.
10275	Intents []*GoogleCloudDialogflowV2Intent `json:"intents,omitempty"`
10276
10277	// ForceSendFields is a list of field names (e.g. "Intents") to
10278	// unconditionally include in API requests. By default, fields with
10279	// empty or default values are omitted from API requests. However, any
10280	// non-pointer, non-interface field appearing in ForceSendFields will be
10281	// sent to the server regardless of whether the field is empty or not.
10282	// This may be used to include empty fields in Patch requests.
10283	ForceSendFields []string `json:"-"`
10284
10285	// NullFields is a list of field names (e.g. "Intents") to include in
10286	// API requests with the JSON null value. By default, fields with empty
10287	// values are omitted from API requests. However, any field with an
10288	// empty value appearing in NullFields will be sent to the server as
10289	// null. It is an error if a field in this list has a non-empty value.
10290	// This may be used to include null fields in Patch requests.
10291	NullFields []string `json:"-"`
10292}
10293
10294func (s *GoogleCloudDialogflowV2IntentBatch) MarshalJSON() ([]byte, error) {
10295	type NoMethod GoogleCloudDialogflowV2IntentBatch
10296	raw := NoMethod(*s)
10297	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
10298}
10299
10300// GoogleCloudDialogflowV2IntentFollowupIntentInfo: Represents a single
10301// followup intent in the chain.
10302type GoogleCloudDialogflowV2IntentFollowupIntentInfo struct {
10303	// FollowupIntentName: The unique identifier of the followup intent.
10304	// Format: `projects//agent/intents/`.
10305	FollowupIntentName string `json:"followupIntentName,omitempty"`
10306
10307	// ParentFollowupIntentName: The unique identifier of the followup
10308	// intent's parent. Format: `projects//agent/intents/`.
10309	ParentFollowupIntentName string `json:"parentFollowupIntentName,omitempty"`
10310
10311	// ForceSendFields is a list of field names (e.g. "FollowupIntentName")
10312	// to unconditionally include in API requests. By default, fields with
10313	// empty or default values are omitted from API requests. However, any
10314	// non-pointer, non-interface field appearing in ForceSendFields will be
10315	// sent to the server regardless of whether the field is empty or not.
10316	// This may be used to include empty fields in Patch requests.
10317	ForceSendFields []string `json:"-"`
10318
10319	// NullFields is a list of field names (e.g. "FollowupIntentName") to
10320	// include in API requests with the JSON null value. By default, fields
10321	// with empty values are omitted from API requests. However, any field
10322	// with an empty value appearing in NullFields will be sent to the
10323	// server as null. It is an error if a field in this list has a
10324	// non-empty value. This may be used to include null fields in Patch
10325	// requests.
10326	NullFields []string `json:"-"`
10327}
10328
10329func (s *GoogleCloudDialogflowV2IntentFollowupIntentInfo) MarshalJSON() ([]byte, error) {
10330	type NoMethod GoogleCloudDialogflowV2IntentFollowupIntentInfo
10331	raw := NoMethod(*s)
10332	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
10333}
10334
10335// GoogleCloudDialogflowV2IntentMessage: A rich response message.
10336// Corresponds to the intent `Response` field in the Dialogflow console.
10337// For more information, see Rich response messages
10338// (https://cloud.google.com/dialogflow/docs/intents-rich-messages).
10339type GoogleCloudDialogflowV2IntentMessage struct {
10340	// BasicCard: The basic card response for Actions on Google.
10341	BasicCard *GoogleCloudDialogflowV2IntentMessageBasicCard `json:"basicCard,omitempty"`
10342
10343	// BrowseCarouselCard: Browse carousel card for Actions on Google.
10344	BrowseCarouselCard *GoogleCloudDialogflowV2IntentMessageBrowseCarouselCard `json:"browseCarouselCard,omitempty"`
10345
10346	// Card: The card response.
10347	Card *GoogleCloudDialogflowV2IntentMessageCard `json:"card,omitempty"`
10348
10349	// CarouselSelect: The carousel card response for Actions on Google.
10350	CarouselSelect *GoogleCloudDialogflowV2IntentMessageCarouselSelect `json:"carouselSelect,omitempty"`
10351
10352	// Image: The image response.
10353	Image *GoogleCloudDialogflowV2IntentMessageImage `json:"image,omitempty"`
10354
10355	// LinkOutSuggestion: The link out suggestion chip for Actions on
10356	// Google.
10357	LinkOutSuggestion *GoogleCloudDialogflowV2IntentMessageLinkOutSuggestion `json:"linkOutSuggestion,omitempty"`
10358
10359	// ListSelect: The list card response for Actions on Google.
10360	ListSelect *GoogleCloudDialogflowV2IntentMessageListSelect `json:"listSelect,omitempty"`
10361
10362	// MediaContent: The media content card for Actions on Google.
10363	MediaContent *GoogleCloudDialogflowV2IntentMessageMediaContent `json:"mediaContent,omitempty"`
10364
10365	// Payload: A custom platform-specific response.
10366	Payload googleapi.RawMessage `json:"payload,omitempty"`
10367
10368	// Platform: Optional. The platform that this message is intended for.
10369	//
10370	// Possible values:
10371	//   "PLATFORM_UNSPECIFIED" - Default platform.
10372	//   "FACEBOOK" - Facebook.
10373	//   "SLACK" - Slack.
10374	//   "TELEGRAM" - Telegram.
10375	//   "KIK" - Kik.
10376	//   "SKYPE" - Skype.
10377	//   "LINE" - Line.
10378	//   "VIBER" - Viber.
10379	//   "ACTIONS_ON_GOOGLE" - Google Assistant See [Dialogflow webhook
10380	// format](https://developers.google.com/assistant/actions/build/json/dia
10381	// logflow-webhook-json)
10382	//   "GOOGLE_HANGOUTS" - Google Hangouts.
10383	Platform string `json:"platform,omitempty"`
10384
10385	// QuickReplies: The quick replies response.
10386	QuickReplies *GoogleCloudDialogflowV2IntentMessageQuickReplies `json:"quickReplies,omitempty"`
10387
10388	// SimpleResponses: The voice and text-only responses for Actions on
10389	// Google.
10390	SimpleResponses *GoogleCloudDialogflowV2IntentMessageSimpleResponses `json:"simpleResponses,omitempty"`
10391
10392	// Suggestions: The suggestion chips for Actions on Google.
10393	Suggestions *GoogleCloudDialogflowV2IntentMessageSuggestions `json:"suggestions,omitempty"`
10394
10395	// TableCard: Table card for Actions on Google.
10396	TableCard *GoogleCloudDialogflowV2IntentMessageTableCard `json:"tableCard,omitempty"`
10397
10398	// Text: The text response.
10399	Text *GoogleCloudDialogflowV2IntentMessageText `json:"text,omitempty"`
10400
10401	// ForceSendFields is a list of field names (e.g. "BasicCard") to
10402	// unconditionally include in API requests. By default, fields with
10403	// empty or default values are omitted from API requests. However, any
10404	// non-pointer, non-interface field appearing in ForceSendFields will be
10405	// sent to the server regardless of whether the field is empty or not.
10406	// This may be used to include empty fields in Patch requests.
10407	ForceSendFields []string `json:"-"`
10408
10409	// NullFields is a list of field names (e.g. "BasicCard") to include in
10410	// API requests with the JSON null value. By default, fields with empty
10411	// values are omitted from API requests. However, any field with an
10412	// empty value appearing in NullFields will be sent to the server as
10413	// null. It is an error if a field in this list has a non-empty value.
10414	// This may be used to include null fields in Patch requests.
10415	NullFields []string `json:"-"`
10416}
10417
10418func (s *GoogleCloudDialogflowV2IntentMessage) MarshalJSON() ([]byte, error) {
10419	type NoMethod GoogleCloudDialogflowV2IntentMessage
10420	raw := NoMethod(*s)
10421	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
10422}
10423
10424// GoogleCloudDialogflowV2IntentMessageBasicCard: The basic card
10425// message. Useful for displaying information.
10426type GoogleCloudDialogflowV2IntentMessageBasicCard struct {
10427	// Buttons: Optional. The collection of card buttons.
10428	Buttons []*GoogleCloudDialogflowV2IntentMessageBasicCardButton `json:"buttons,omitempty"`
10429
10430	// FormattedText: Required, unless image is present. The body text of
10431	// the card.
10432	FormattedText string `json:"formattedText,omitempty"`
10433
10434	// Image: Optional. The image for the card.
10435	Image *GoogleCloudDialogflowV2IntentMessageImage `json:"image,omitempty"`
10436
10437	// Subtitle: Optional. The subtitle of the card.
10438	Subtitle string `json:"subtitle,omitempty"`
10439
10440	// Title: Optional. The title of the card.
10441	Title string `json:"title,omitempty"`
10442
10443	// ForceSendFields is a list of field names (e.g. "Buttons") to
10444	// unconditionally include in API requests. By default, fields with
10445	// empty or default values are omitted from API requests. However, any
10446	// non-pointer, non-interface field appearing in ForceSendFields will be
10447	// sent to the server regardless of whether the field is empty or not.
10448	// This may be used to include empty fields in Patch requests.
10449	ForceSendFields []string `json:"-"`
10450
10451	// NullFields is a list of field names (e.g. "Buttons") to include in
10452	// API requests with the JSON null value. By default, fields with empty
10453	// values are omitted from API requests. However, any field with an
10454	// empty value appearing in NullFields will be sent to the server as
10455	// null. It is an error if a field in this list has a non-empty value.
10456	// This may be used to include null fields in Patch requests.
10457	NullFields []string `json:"-"`
10458}
10459
10460func (s *GoogleCloudDialogflowV2IntentMessageBasicCard) MarshalJSON() ([]byte, error) {
10461	type NoMethod GoogleCloudDialogflowV2IntentMessageBasicCard
10462	raw := NoMethod(*s)
10463	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
10464}
10465
10466// GoogleCloudDialogflowV2IntentMessageBasicCardButton: The button
10467// object that appears at the bottom of a card.
10468type GoogleCloudDialogflowV2IntentMessageBasicCardButton struct {
10469	// OpenUriAction: Required. Action to take when a user taps on the
10470	// button.
10471	OpenUriAction *GoogleCloudDialogflowV2IntentMessageBasicCardButtonOpenUriAction `json:"openUriAction,omitempty"`
10472
10473	// Title: Required. The title of the button.
10474	Title string `json:"title,omitempty"`
10475
10476	// ForceSendFields is a list of field names (e.g. "OpenUriAction") to
10477	// unconditionally include in API requests. By default, fields with
10478	// empty or default values are omitted from API requests. However, any
10479	// non-pointer, non-interface field appearing in ForceSendFields will be
10480	// sent to the server regardless of whether the field is empty or not.
10481	// This may be used to include empty fields in Patch requests.
10482	ForceSendFields []string `json:"-"`
10483
10484	// NullFields is a list of field names (e.g. "OpenUriAction") to include
10485	// in API requests with the JSON null value. By default, fields with
10486	// empty values are omitted from API requests. However, any field with
10487	// an empty value appearing in NullFields will be sent to the server as
10488	// null. It is an error if a field in this list has a non-empty value.
10489	// This may be used to include null fields in Patch requests.
10490	NullFields []string `json:"-"`
10491}
10492
10493func (s *GoogleCloudDialogflowV2IntentMessageBasicCardButton) MarshalJSON() ([]byte, error) {
10494	type NoMethod GoogleCloudDialogflowV2IntentMessageBasicCardButton
10495	raw := NoMethod(*s)
10496	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
10497}
10498
10499// GoogleCloudDialogflowV2IntentMessageBasicCardButtonOpenUriAction:
10500// Opens the given URI.
10501type GoogleCloudDialogflowV2IntentMessageBasicCardButtonOpenUriAction struct {
10502	// Uri: Required. The HTTP or HTTPS scheme URI.
10503	Uri string `json:"uri,omitempty"`
10504
10505	// ForceSendFields is a list of field names (e.g. "Uri") to
10506	// unconditionally include in API requests. By default, fields with
10507	// empty or default values are omitted from API requests. However, any
10508	// non-pointer, non-interface field appearing in ForceSendFields will be
10509	// sent to the server regardless of whether the field is empty or not.
10510	// This may be used to include empty fields in Patch requests.
10511	ForceSendFields []string `json:"-"`
10512
10513	// NullFields is a list of field names (e.g. "Uri") to include in API
10514	// requests with the JSON null value. By default, fields with empty
10515	// values are omitted from API requests. However, any field with an
10516	// empty value appearing in NullFields will be sent to the server as
10517	// null. It is an error if a field in this list has a non-empty value.
10518	// This may be used to include null fields in Patch requests.
10519	NullFields []string `json:"-"`
10520}
10521
10522func (s *GoogleCloudDialogflowV2IntentMessageBasicCardButtonOpenUriAction) MarshalJSON() ([]byte, error) {
10523	type NoMethod GoogleCloudDialogflowV2IntentMessageBasicCardButtonOpenUriAction
10524	raw := NoMethod(*s)
10525	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
10526}
10527
10528// GoogleCloudDialogflowV2IntentMessageBrowseCarouselCard: Browse
10529// Carousel Card for Actions on Google.
10530// https://developers.google.com/actions/assistant/responses#browsing_carousel
10531type GoogleCloudDialogflowV2IntentMessageBrowseCarouselCard struct {
10532	// ImageDisplayOptions: Optional. Settings for displaying the image.
10533	// Applies to every image in items.
10534	//
10535	// Possible values:
10536	//   "IMAGE_DISPLAY_OPTIONS_UNSPECIFIED" - Fill the gaps between the
10537	// image and the image container with gray bars.
10538	//   "GRAY" - Fill the gaps between the image and the image container
10539	// with gray bars.
10540	//   "WHITE" - Fill the gaps between the image and the image container
10541	// with white bars.
10542	//   "CROPPED" - Image is scaled such that the image width and height
10543	// match or exceed the container dimensions. This may crop the top and
10544	// bottom of the image if the scaled image height is greater than the
10545	// container height, or crop the left and right of the image if the
10546	// scaled image width is greater than the container width. This is
10547	// similar to "Zoom Mode" on a widescreen TV when playing a 4:3 video.
10548	//   "BLURRED_BACKGROUND" - Pad the gaps between image and image frame
10549	// with a blurred copy of the same image.
10550	ImageDisplayOptions string `json:"imageDisplayOptions,omitempty"`
10551
10552	// Items: Required. List of items in the Browse Carousel Card. Minimum
10553	// of two items, maximum of ten.
10554	Items []*GoogleCloudDialogflowV2IntentMessageBrowseCarouselCardBrowseCarouselCardItem `json:"items,omitempty"`
10555
10556	// ForceSendFields is a list of field names (e.g. "ImageDisplayOptions")
10557	// to unconditionally include in API requests. By default, fields with
10558	// empty or default values are omitted from API requests. However, any
10559	// non-pointer, non-interface field appearing in ForceSendFields will be
10560	// sent to the server regardless of whether the field is empty or not.
10561	// This may be used to include empty fields in Patch requests.
10562	ForceSendFields []string `json:"-"`
10563
10564	// NullFields is a list of field names (e.g. "ImageDisplayOptions") to
10565	// include in API requests with the JSON null value. By default, fields
10566	// with empty values are omitted from API requests. However, any field
10567	// with an empty value appearing in NullFields will be sent to the
10568	// server as null. It is an error if a field in this list has a
10569	// non-empty value. This may be used to include null fields in Patch
10570	// requests.
10571	NullFields []string `json:"-"`
10572}
10573
10574func (s *GoogleCloudDialogflowV2IntentMessageBrowseCarouselCard) MarshalJSON() ([]byte, error) {
10575	type NoMethod GoogleCloudDialogflowV2IntentMessageBrowseCarouselCard
10576	raw := NoMethod(*s)
10577	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
10578}
10579
10580// GoogleCloudDialogflowV2IntentMessageBrowseCarouselCardBrowseCarouselCa
10581// rdItem: Browsing carousel tile
10582type GoogleCloudDialogflowV2IntentMessageBrowseCarouselCardBrowseCarouselCardItem struct {
10583	// Description: Optional. Description of the carousel item. Maximum of
10584	// four lines of text.
10585	Description string `json:"description,omitempty"`
10586
10587	// Footer: Optional. Text that appears at the bottom of the Browse
10588	// Carousel Card. Maximum of one line of text.
10589	Footer string `json:"footer,omitempty"`
10590
10591	// Image: Optional. Hero image for the carousel item.
10592	Image *GoogleCloudDialogflowV2IntentMessageImage `json:"image,omitempty"`
10593
10594	// OpenUriAction: Required. Action to present to the user.
10595	OpenUriAction *GoogleCloudDialogflowV2IntentMessageBrowseCarouselCardBrowseCarouselCardItemOpenUrlAction `json:"openUriAction,omitempty"`
10596
10597	// Title: Required. Title of the carousel item. Maximum of two lines of
10598	// text.
10599	Title string `json:"title,omitempty"`
10600
10601	// ForceSendFields is a list of field names (e.g. "Description") to
10602	// unconditionally include in API requests. By default, fields with
10603	// empty or default values are omitted from API requests. However, any
10604	// non-pointer, non-interface field appearing in ForceSendFields will be
10605	// sent to the server regardless of whether the field is empty or not.
10606	// This may be used to include empty fields in Patch requests.
10607	ForceSendFields []string `json:"-"`
10608
10609	// NullFields is a list of field names (e.g. "Description") to include
10610	// in API requests with the JSON null value. By default, fields with
10611	// empty values are omitted from API requests. However, any field with
10612	// an empty value appearing in NullFields will be sent to the server as
10613	// null. It is an error if a field in this list has a non-empty value.
10614	// This may be used to include null fields in Patch requests.
10615	NullFields []string `json:"-"`
10616}
10617
10618func (s *GoogleCloudDialogflowV2IntentMessageBrowseCarouselCardBrowseCarouselCardItem) MarshalJSON() ([]byte, error) {
10619	type NoMethod GoogleCloudDialogflowV2IntentMessageBrowseCarouselCardBrowseCarouselCardItem
10620	raw := NoMethod(*s)
10621	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
10622}
10623
10624// GoogleCloudDialogflowV2IntentMessageBrowseCarouselCardBrowseCarouselCa
10625// rdItemOpenUrlAction: Actions on Google action to open a given url.
10626type GoogleCloudDialogflowV2IntentMessageBrowseCarouselCardBrowseCarouselCardItemOpenUrlAction struct {
10627	// Url: Required. URL
10628	Url string `json:"url,omitempty"`
10629
10630	// UrlTypeHint: Optional. Specifies the type of viewer that is used when
10631	// opening the URL. Defaults to opening via web browser.
10632	//
10633	// Possible values:
10634	//   "URL_TYPE_HINT_UNSPECIFIED" - Unspecified
10635	//   "AMP_ACTION" - Url would be an amp action
10636	//   "AMP_CONTENT" - URL that points directly to AMP content, or to a
10637	// canonical URL which refers to AMP content via .
10638	UrlTypeHint string `json:"urlTypeHint,omitempty"`
10639
10640	// ForceSendFields is a list of field names (e.g. "Url") to
10641	// unconditionally include in API requests. By default, fields with
10642	// empty or default values are omitted from API requests. However, any
10643	// non-pointer, non-interface field appearing in ForceSendFields will be
10644	// sent to the server regardless of whether the field is empty or not.
10645	// This may be used to include empty fields in Patch requests.
10646	ForceSendFields []string `json:"-"`
10647
10648	// NullFields is a list of field names (e.g. "Url") to include in API
10649	// requests with the JSON null value. By default, fields with empty
10650	// values are omitted from API requests. However, any field with an
10651	// empty value appearing in NullFields will be sent to the server as
10652	// null. It is an error if a field in this list has a non-empty value.
10653	// This may be used to include null fields in Patch requests.
10654	NullFields []string `json:"-"`
10655}
10656
10657func (s *GoogleCloudDialogflowV2IntentMessageBrowseCarouselCardBrowseCarouselCardItemOpenUrlAction) MarshalJSON() ([]byte, error) {
10658	type NoMethod GoogleCloudDialogflowV2IntentMessageBrowseCarouselCardBrowseCarouselCardItemOpenUrlAction
10659	raw := NoMethod(*s)
10660	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
10661}
10662
10663// GoogleCloudDialogflowV2IntentMessageCard: The card response message.
10664type GoogleCloudDialogflowV2IntentMessageCard struct {
10665	// Buttons: Optional. The collection of card buttons.
10666	Buttons []*GoogleCloudDialogflowV2IntentMessageCardButton `json:"buttons,omitempty"`
10667
10668	// ImageUri: Optional. The public URI to an image file for the card.
10669	ImageUri string `json:"imageUri,omitempty"`
10670
10671	// Subtitle: Optional. The subtitle of the card.
10672	Subtitle string `json:"subtitle,omitempty"`
10673
10674	// Title: Optional. The title of the card.
10675	Title string `json:"title,omitempty"`
10676
10677	// ForceSendFields is a list of field names (e.g. "Buttons") to
10678	// unconditionally include in API requests. By default, fields with
10679	// empty or default values are omitted from API requests. However, any
10680	// non-pointer, non-interface field appearing in ForceSendFields will be
10681	// sent to the server regardless of whether the field is empty or not.
10682	// This may be used to include empty fields in Patch requests.
10683	ForceSendFields []string `json:"-"`
10684
10685	// NullFields is a list of field names (e.g. "Buttons") to include in
10686	// API requests with the JSON null value. By default, fields with empty
10687	// values are omitted from API requests. However, any field with an
10688	// empty value appearing in NullFields will be sent to the server as
10689	// null. It is an error if a field in this list has a non-empty value.
10690	// This may be used to include null fields in Patch requests.
10691	NullFields []string `json:"-"`
10692}
10693
10694func (s *GoogleCloudDialogflowV2IntentMessageCard) MarshalJSON() ([]byte, error) {
10695	type NoMethod GoogleCloudDialogflowV2IntentMessageCard
10696	raw := NoMethod(*s)
10697	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
10698}
10699
10700// GoogleCloudDialogflowV2IntentMessageCardButton: Contains information
10701// about a button.
10702type GoogleCloudDialogflowV2IntentMessageCardButton struct {
10703	// Postback: Optional. The text to send back to the Dialogflow API or a
10704	// URI to open.
10705	Postback string `json:"postback,omitempty"`
10706
10707	// Text: Optional. The text to show on the button.
10708	Text string `json:"text,omitempty"`
10709
10710	// ForceSendFields is a list of field names (e.g. "Postback") to
10711	// unconditionally include in API requests. By default, fields with
10712	// empty or default values are omitted from API requests. However, any
10713	// non-pointer, non-interface field appearing in ForceSendFields will be
10714	// sent to the server regardless of whether the field is empty or not.
10715	// This may be used to include empty fields in Patch requests.
10716	ForceSendFields []string `json:"-"`
10717
10718	// NullFields is a list of field names (e.g. "Postback") to include in
10719	// API requests with the JSON null value. By default, fields with empty
10720	// values are omitted from API requests. However, any field with an
10721	// empty value appearing in NullFields will be sent to the server as
10722	// null. It is an error if a field in this list has a non-empty value.
10723	// This may be used to include null fields in Patch requests.
10724	NullFields []string `json:"-"`
10725}
10726
10727func (s *GoogleCloudDialogflowV2IntentMessageCardButton) MarshalJSON() ([]byte, error) {
10728	type NoMethod GoogleCloudDialogflowV2IntentMessageCardButton
10729	raw := NoMethod(*s)
10730	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
10731}
10732
10733// GoogleCloudDialogflowV2IntentMessageCarouselSelect: The card for
10734// presenting a carousel of options to select from.
10735type GoogleCloudDialogflowV2IntentMessageCarouselSelect struct {
10736	// Items: Required. Carousel items.
10737	Items []*GoogleCloudDialogflowV2IntentMessageCarouselSelectItem `json:"items,omitempty"`
10738
10739	// ForceSendFields is a list of field names (e.g. "Items") to
10740	// unconditionally include in API requests. By default, fields with
10741	// empty or default values are omitted from API requests. However, any
10742	// non-pointer, non-interface field appearing in ForceSendFields will be
10743	// sent to the server regardless of whether the field is empty or not.
10744	// This may be used to include empty fields in Patch requests.
10745	ForceSendFields []string `json:"-"`
10746
10747	// NullFields is a list of field names (e.g. "Items") to include in API
10748	// requests with the JSON null value. By default, fields with empty
10749	// values are omitted from API requests. However, any field with an
10750	// empty value appearing in NullFields will be sent to the server as
10751	// null. It is an error if a field in this list has a non-empty value.
10752	// This may be used to include null fields in Patch requests.
10753	NullFields []string `json:"-"`
10754}
10755
10756func (s *GoogleCloudDialogflowV2IntentMessageCarouselSelect) MarshalJSON() ([]byte, error) {
10757	type NoMethod GoogleCloudDialogflowV2IntentMessageCarouselSelect
10758	raw := NoMethod(*s)
10759	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
10760}
10761
10762// GoogleCloudDialogflowV2IntentMessageCarouselSelectItem: An item in
10763// the carousel.
10764type GoogleCloudDialogflowV2IntentMessageCarouselSelectItem struct {
10765	// Description: Optional. The body text of the card.
10766	Description string `json:"description,omitempty"`
10767
10768	// Image: Optional. The image to display.
10769	Image *GoogleCloudDialogflowV2IntentMessageImage `json:"image,omitempty"`
10770
10771	// Info: Required. Additional info about the option item.
10772	Info *GoogleCloudDialogflowV2IntentMessageSelectItemInfo `json:"info,omitempty"`
10773
10774	// Title: Required. Title of the carousel item.
10775	Title string `json:"title,omitempty"`
10776
10777	// ForceSendFields is a list of field names (e.g. "Description") to
10778	// unconditionally include in API requests. By default, fields with
10779	// empty or default values are omitted from API requests. However, any
10780	// non-pointer, non-interface field appearing in ForceSendFields will be
10781	// sent to the server regardless of whether the field is empty or not.
10782	// This may be used to include empty fields in Patch requests.
10783	ForceSendFields []string `json:"-"`
10784
10785	// NullFields is a list of field names (e.g. "Description") to include
10786	// in API requests with the JSON null value. By default, fields with
10787	// empty values are omitted from API requests. However, any field with
10788	// an empty value appearing in NullFields will be sent to the server as
10789	// null. It is an error if a field in this list has a non-empty value.
10790	// This may be used to include null fields in Patch requests.
10791	NullFields []string `json:"-"`
10792}
10793
10794func (s *GoogleCloudDialogflowV2IntentMessageCarouselSelectItem) MarshalJSON() ([]byte, error) {
10795	type NoMethod GoogleCloudDialogflowV2IntentMessageCarouselSelectItem
10796	raw := NoMethod(*s)
10797	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
10798}
10799
10800// GoogleCloudDialogflowV2IntentMessageColumnProperties: Column
10801// properties for TableCard.
10802type GoogleCloudDialogflowV2IntentMessageColumnProperties struct {
10803	// Header: Required. Column heading.
10804	Header string `json:"header,omitempty"`
10805
10806	// HorizontalAlignment: Optional. Defines text alignment for all cells
10807	// in this column.
10808	//
10809	// Possible values:
10810	//   "HORIZONTAL_ALIGNMENT_UNSPECIFIED" - Text is aligned to the leading
10811	// edge of the column.
10812	//   "LEADING" - Text is aligned to the leading edge of the column.
10813	//   "CENTER" - Text is centered in the column.
10814	//   "TRAILING" - Text is aligned to the trailing edge of the column.
10815	HorizontalAlignment string `json:"horizontalAlignment,omitempty"`
10816
10817	// ForceSendFields is a list of field names (e.g. "Header") to
10818	// unconditionally include in API requests. By default, fields with
10819	// empty or default values are omitted from API requests. However, any
10820	// non-pointer, non-interface field appearing in ForceSendFields will be
10821	// sent to the server regardless of whether the field is empty or not.
10822	// This may be used to include empty fields in Patch requests.
10823	ForceSendFields []string `json:"-"`
10824
10825	// NullFields is a list of field names (e.g. "Header") to include in API
10826	// requests with the JSON null value. By default, fields with empty
10827	// values are omitted from API requests. However, any field with an
10828	// empty value appearing in NullFields will be sent to the server as
10829	// null. It is an error if a field in this list has a non-empty value.
10830	// This may be used to include null fields in Patch requests.
10831	NullFields []string `json:"-"`
10832}
10833
10834func (s *GoogleCloudDialogflowV2IntentMessageColumnProperties) MarshalJSON() ([]byte, error) {
10835	type NoMethod GoogleCloudDialogflowV2IntentMessageColumnProperties
10836	raw := NoMethod(*s)
10837	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
10838}
10839
10840// GoogleCloudDialogflowV2IntentMessageImage: The image response
10841// message.
10842type GoogleCloudDialogflowV2IntentMessageImage struct {
10843	// AccessibilityText: Optional. A text description of the image to be
10844	// used for accessibility, e.g., screen readers.
10845	AccessibilityText string `json:"accessibilityText,omitempty"`
10846
10847	// ImageUri: Optional. The public URI to an image file.
10848	ImageUri string `json:"imageUri,omitempty"`
10849
10850	// ForceSendFields is a list of field names (e.g. "AccessibilityText")
10851	// to unconditionally include in API requests. By default, fields with
10852	// empty or default values are omitted from API requests. However, any
10853	// non-pointer, non-interface field appearing in ForceSendFields will be
10854	// sent to the server regardless of whether the field is empty or not.
10855	// This may be used to include empty fields in Patch requests.
10856	ForceSendFields []string `json:"-"`
10857
10858	// NullFields is a list of field names (e.g. "AccessibilityText") to
10859	// include in API requests with the JSON null value. By default, fields
10860	// with empty values are omitted from API requests. However, any field
10861	// with an empty value appearing in NullFields will be sent to the
10862	// server as null. It is an error if a field in this list has a
10863	// non-empty value. This may be used to include null fields in Patch
10864	// requests.
10865	NullFields []string `json:"-"`
10866}
10867
10868func (s *GoogleCloudDialogflowV2IntentMessageImage) MarshalJSON() ([]byte, error) {
10869	type NoMethod GoogleCloudDialogflowV2IntentMessageImage
10870	raw := NoMethod(*s)
10871	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
10872}
10873
10874// GoogleCloudDialogflowV2IntentMessageLinkOutSuggestion: The suggestion
10875// chip message that allows the user to jump out to the app or website
10876// associated with this agent.
10877type GoogleCloudDialogflowV2IntentMessageLinkOutSuggestion struct {
10878	// DestinationName: Required. The name of the app or site this chip is
10879	// linking to.
10880	DestinationName string `json:"destinationName,omitempty"`
10881
10882	// Uri: Required. The URI of the app or site to open when the user taps
10883	// the suggestion chip.
10884	Uri string `json:"uri,omitempty"`
10885
10886	// ForceSendFields is a list of field names (e.g. "DestinationName") to
10887	// unconditionally include in API requests. By default, fields with
10888	// empty or default values are omitted from API requests. However, any
10889	// non-pointer, non-interface field appearing in ForceSendFields will be
10890	// sent to the server regardless of whether the field is empty or not.
10891	// This may be used to include empty fields in Patch requests.
10892	ForceSendFields []string `json:"-"`
10893
10894	// NullFields is a list of field names (e.g. "DestinationName") to
10895	// include in API requests with the JSON null value. By default, fields
10896	// with empty values are omitted from API requests. However, any field
10897	// with an empty value appearing in NullFields will be sent to the
10898	// server as null. It is an error if a field in this list has a
10899	// non-empty value. This may be used to include null fields in Patch
10900	// requests.
10901	NullFields []string `json:"-"`
10902}
10903
10904func (s *GoogleCloudDialogflowV2IntentMessageLinkOutSuggestion) MarshalJSON() ([]byte, error) {
10905	type NoMethod GoogleCloudDialogflowV2IntentMessageLinkOutSuggestion
10906	raw := NoMethod(*s)
10907	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
10908}
10909
10910// GoogleCloudDialogflowV2IntentMessageListSelect: The card for
10911// presenting a list of options to select from.
10912type GoogleCloudDialogflowV2IntentMessageListSelect struct {
10913	// Items: Required. List items.
10914	Items []*GoogleCloudDialogflowV2IntentMessageListSelectItem `json:"items,omitempty"`
10915
10916	// Subtitle: Optional. Subtitle of the list.
10917	Subtitle string `json:"subtitle,omitempty"`
10918
10919	// Title: Optional. The overall title of the list.
10920	Title string `json:"title,omitempty"`
10921
10922	// ForceSendFields is a list of field names (e.g. "Items") to
10923	// unconditionally include in API requests. By default, fields with
10924	// empty or default values are omitted from API requests. However, any
10925	// non-pointer, non-interface field appearing in ForceSendFields will be
10926	// sent to the server regardless of whether the field is empty or not.
10927	// This may be used to include empty fields in Patch requests.
10928	ForceSendFields []string `json:"-"`
10929
10930	// NullFields is a list of field names (e.g. "Items") to include in API
10931	// requests with the JSON null value. By default, fields with empty
10932	// values are omitted from API requests. However, any field with an
10933	// empty value appearing in NullFields will be sent to the server as
10934	// null. It is an error if a field in this list has a non-empty value.
10935	// This may be used to include null fields in Patch requests.
10936	NullFields []string `json:"-"`
10937}
10938
10939func (s *GoogleCloudDialogflowV2IntentMessageListSelect) MarshalJSON() ([]byte, error) {
10940	type NoMethod GoogleCloudDialogflowV2IntentMessageListSelect
10941	raw := NoMethod(*s)
10942	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
10943}
10944
10945// GoogleCloudDialogflowV2IntentMessageListSelectItem: An item in the
10946// list.
10947type GoogleCloudDialogflowV2IntentMessageListSelectItem struct {
10948	// Description: Optional. The main text describing the item.
10949	Description string `json:"description,omitempty"`
10950
10951	// Image: Optional. The image to display.
10952	Image *GoogleCloudDialogflowV2IntentMessageImage `json:"image,omitempty"`
10953
10954	// Info: Required. Additional information about this option.
10955	Info *GoogleCloudDialogflowV2IntentMessageSelectItemInfo `json:"info,omitempty"`
10956
10957	// Title: Required. The title of the list item.
10958	Title string `json:"title,omitempty"`
10959
10960	// ForceSendFields is a list of field names (e.g. "Description") to
10961	// unconditionally include in API requests. By default, fields with
10962	// empty or default values are omitted from API requests. However, any
10963	// non-pointer, non-interface field appearing in ForceSendFields will be
10964	// sent to the server regardless of whether the field is empty or not.
10965	// This may be used to include empty fields in Patch requests.
10966	ForceSendFields []string `json:"-"`
10967
10968	// NullFields is a list of field names (e.g. "Description") to include
10969	// in API requests with the JSON null value. By default, fields with
10970	// empty values are omitted from API requests. However, any field with
10971	// an empty value appearing in NullFields will be sent to the server as
10972	// null. It is an error if a field in this list has a non-empty value.
10973	// This may be used to include null fields in Patch requests.
10974	NullFields []string `json:"-"`
10975}
10976
10977func (s *GoogleCloudDialogflowV2IntentMessageListSelectItem) MarshalJSON() ([]byte, error) {
10978	type NoMethod GoogleCloudDialogflowV2IntentMessageListSelectItem
10979	raw := NoMethod(*s)
10980	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
10981}
10982
10983// GoogleCloudDialogflowV2IntentMessageMediaContent: The media content
10984// card for Actions on Google.
10985type GoogleCloudDialogflowV2IntentMessageMediaContent struct {
10986	// MediaObjects: Required. List of media objects.
10987	MediaObjects []*GoogleCloudDialogflowV2IntentMessageMediaContentResponseMediaObject `json:"mediaObjects,omitempty"`
10988
10989	// MediaType: Optional. What type of media is the content (ie "audio").
10990	//
10991	// Possible values:
10992	//   "RESPONSE_MEDIA_TYPE_UNSPECIFIED" - Unspecified.
10993	//   "AUDIO" - Response media type is audio.
10994	MediaType string `json:"mediaType,omitempty"`
10995
10996	// ForceSendFields is a list of field names (e.g. "MediaObjects") to
10997	// unconditionally include in API requests. By default, fields with
10998	// empty or default values are omitted from API requests. However, any
10999	// non-pointer, non-interface field appearing in ForceSendFields will be
11000	// sent to the server regardless of whether the field is empty or not.
11001	// This may be used to include empty fields in Patch requests.
11002	ForceSendFields []string `json:"-"`
11003
11004	// NullFields is a list of field names (e.g. "MediaObjects") to include
11005	// in API requests with the JSON null value. By default, fields with
11006	// empty values are omitted from API requests. However, any field with
11007	// an empty value appearing in NullFields will be sent to the server as
11008	// null. It is an error if a field in this list has a non-empty value.
11009	// This may be used to include null fields in Patch requests.
11010	NullFields []string `json:"-"`
11011}
11012
11013func (s *GoogleCloudDialogflowV2IntentMessageMediaContent) MarshalJSON() ([]byte, error) {
11014	type NoMethod GoogleCloudDialogflowV2IntentMessageMediaContent
11015	raw := NoMethod(*s)
11016	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
11017}
11018
11019// GoogleCloudDialogflowV2IntentMessageMediaContentResponseMediaObject:
11020// Response media object for media content card.
11021type GoogleCloudDialogflowV2IntentMessageMediaContentResponseMediaObject struct {
11022	// ContentUrl: Required. Url where the media is stored.
11023	ContentUrl string `json:"contentUrl,omitempty"`
11024
11025	// Description: Optional. Description of media card.
11026	Description string `json:"description,omitempty"`
11027
11028	// Icon: Optional. Icon to display above media content.
11029	Icon *GoogleCloudDialogflowV2IntentMessageImage `json:"icon,omitempty"`
11030
11031	// LargeImage: Optional. Image to display above media content.
11032	LargeImage *GoogleCloudDialogflowV2IntentMessageImage `json:"largeImage,omitempty"`
11033
11034	// Name: Required. Name of media card.
11035	Name string `json:"name,omitempty"`
11036
11037	// ForceSendFields is a list of field names (e.g. "ContentUrl") to
11038	// unconditionally include in API requests. By default, fields with
11039	// empty or default values are omitted from API requests. However, any
11040	// non-pointer, non-interface field appearing in ForceSendFields will be
11041	// sent to the server regardless of whether the field is empty or not.
11042	// This may be used to include empty fields in Patch requests.
11043	ForceSendFields []string `json:"-"`
11044
11045	// NullFields is a list of field names (e.g. "ContentUrl") to include in
11046	// API requests with the JSON null value. By default, fields with empty
11047	// values are omitted from API requests. However, any field with an
11048	// empty value appearing in NullFields will be sent to the server as
11049	// null. It is an error if a field in this list has a non-empty value.
11050	// This may be used to include null fields in Patch requests.
11051	NullFields []string `json:"-"`
11052}
11053
11054func (s *GoogleCloudDialogflowV2IntentMessageMediaContentResponseMediaObject) MarshalJSON() ([]byte, error) {
11055	type NoMethod GoogleCloudDialogflowV2IntentMessageMediaContentResponseMediaObject
11056	raw := NoMethod(*s)
11057	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
11058}
11059
11060// GoogleCloudDialogflowV2IntentMessageQuickReplies: The quick replies
11061// response message.
11062type GoogleCloudDialogflowV2IntentMessageQuickReplies struct {
11063	// QuickReplies: Optional. The collection of quick replies.
11064	QuickReplies []string `json:"quickReplies,omitempty"`
11065
11066	// Title: Optional. The title of the collection of quick replies.
11067	Title string `json:"title,omitempty"`
11068
11069	// ForceSendFields is a list of field names (e.g. "QuickReplies") to
11070	// unconditionally include in API requests. By default, fields with
11071	// empty or default values are omitted from API requests. However, any
11072	// non-pointer, non-interface field appearing in ForceSendFields will be
11073	// sent to the server regardless of whether the field is empty or not.
11074	// This may be used to include empty fields in Patch requests.
11075	ForceSendFields []string `json:"-"`
11076
11077	// NullFields is a list of field names (e.g. "QuickReplies") to include
11078	// in API requests with the JSON null value. By default, fields with
11079	// empty values are omitted from API requests. However, any field with
11080	// an empty value appearing in NullFields will be sent to the server as
11081	// null. It is an error if a field in this list has a non-empty value.
11082	// This may be used to include null fields in Patch requests.
11083	NullFields []string `json:"-"`
11084}
11085
11086func (s *GoogleCloudDialogflowV2IntentMessageQuickReplies) MarshalJSON() ([]byte, error) {
11087	type NoMethod GoogleCloudDialogflowV2IntentMessageQuickReplies
11088	raw := NoMethod(*s)
11089	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
11090}
11091
11092// GoogleCloudDialogflowV2IntentMessageSelectItemInfo: Additional info
11093// about the select item for when it is triggered in a dialog.
11094type GoogleCloudDialogflowV2IntentMessageSelectItemInfo struct {
11095	// Key: Required. A unique key that will be sent back to the agent if
11096	// this response is given.
11097	Key string `json:"key,omitempty"`
11098
11099	// Synonyms: Optional. A list of synonyms that can also be used to
11100	// trigger this item in dialog.
11101	Synonyms []string `json:"synonyms,omitempty"`
11102
11103	// ForceSendFields is a list of field names (e.g. "Key") to
11104	// unconditionally include in API requests. By default, fields with
11105	// empty or default values are omitted from API requests. However, any
11106	// non-pointer, non-interface field appearing in ForceSendFields will be
11107	// sent to the server regardless of whether the field is empty or not.
11108	// This may be used to include empty fields in Patch requests.
11109	ForceSendFields []string `json:"-"`
11110
11111	// NullFields is a list of field names (e.g. "Key") to include in API
11112	// requests with the JSON null value. By default, fields with empty
11113	// values are omitted from API requests. However, any field with an
11114	// empty value appearing in NullFields will be sent to the server as
11115	// null. It is an error if a field in this list has a non-empty value.
11116	// This may be used to include null fields in Patch requests.
11117	NullFields []string `json:"-"`
11118}
11119
11120func (s *GoogleCloudDialogflowV2IntentMessageSelectItemInfo) MarshalJSON() ([]byte, error) {
11121	type NoMethod GoogleCloudDialogflowV2IntentMessageSelectItemInfo
11122	raw := NoMethod(*s)
11123	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
11124}
11125
11126// GoogleCloudDialogflowV2IntentMessageSimpleResponse: The simple
11127// response message containing speech or text.
11128type GoogleCloudDialogflowV2IntentMessageSimpleResponse struct {
11129	// DisplayText: Optional. The text to display.
11130	DisplayText string `json:"displayText,omitempty"`
11131
11132	// Ssml: One of text_to_speech or ssml must be provided. Structured
11133	// spoken response to the user in the SSML format. Mutually exclusive
11134	// with text_to_speech.
11135	Ssml string `json:"ssml,omitempty"`
11136
11137	// TextToSpeech: One of text_to_speech or ssml must be provided. The
11138	// plain text of the speech output. Mutually exclusive with ssml.
11139	TextToSpeech string `json:"textToSpeech,omitempty"`
11140
11141	// ForceSendFields is a list of field names (e.g. "DisplayText") to
11142	// unconditionally include in API requests. By default, fields with
11143	// empty or default values are omitted from API requests. However, any
11144	// non-pointer, non-interface field appearing in ForceSendFields will be
11145	// sent to the server regardless of whether the field is empty or not.
11146	// This may be used to include empty fields in Patch requests.
11147	ForceSendFields []string `json:"-"`
11148
11149	// NullFields is a list of field names (e.g. "DisplayText") to include
11150	// in API requests with the JSON null value. By default, fields with
11151	// empty values are omitted from API requests. However, any field with
11152	// an empty value appearing in NullFields will be sent to the server as
11153	// null. It is an error if a field in this list has a non-empty value.
11154	// This may be used to include null fields in Patch requests.
11155	NullFields []string `json:"-"`
11156}
11157
11158func (s *GoogleCloudDialogflowV2IntentMessageSimpleResponse) MarshalJSON() ([]byte, error) {
11159	type NoMethod GoogleCloudDialogflowV2IntentMessageSimpleResponse
11160	raw := NoMethod(*s)
11161	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
11162}
11163
11164// GoogleCloudDialogflowV2IntentMessageSimpleResponses: The collection
11165// of simple response candidates. This message in
11166// `QueryResult.fulfillment_messages` and
11167// `WebhookResponse.fulfillment_messages` should contain only one
11168// `SimpleResponse`.
11169type GoogleCloudDialogflowV2IntentMessageSimpleResponses struct {
11170	// SimpleResponses: Required. The list of simple responses.
11171	SimpleResponses []*GoogleCloudDialogflowV2IntentMessageSimpleResponse `json:"simpleResponses,omitempty"`
11172
11173	// ForceSendFields is a list of field names (e.g. "SimpleResponses") to
11174	// unconditionally include in API requests. By default, fields with
11175	// empty or default values are omitted from API requests. However, any
11176	// non-pointer, non-interface field appearing in ForceSendFields will be
11177	// sent to the server regardless of whether the field is empty or not.
11178	// This may be used to include empty fields in Patch requests.
11179	ForceSendFields []string `json:"-"`
11180
11181	// NullFields is a list of field names (e.g. "SimpleResponses") to
11182	// include in API requests with the JSON null value. By default, fields
11183	// with empty values are omitted from API requests. However, any field
11184	// with an empty value appearing in NullFields will be sent to the
11185	// server as null. It is an error if a field in this list has a
11186	// non-empty value. This may be used to include null fields in Patch
11187	// requests.
11188	NullFields []string `json:"-"`
11189}
11190
11191func (s *GoogleCloudDialogflowV2IntentMessageSimpleResponses) MarshalJSON() ([]byte, error) {
11192	type NoMethod GoogleCloudDialogflowV2IntentMessageSimpleResponses
11193	raw := NoMethod(*s)
11194	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
11195}
11196
11197// GoogleCloudDialogflowV2IntentMessageSuggestion: The suggestion chip
11198// message that the user can tap to quickly post a reply to the
11199// conversation.
11200type GoogleCloudDialogflowV2IntentMessageSuggestion struct {
11201	// Title: Required. The text shown the in the suggestion chip.
11202	Title string `json:"title,omitempty"`
11203
11204	// ForceSendFields is a list of field names (e.g. "Title") to
11205	// unconditionally include in API requests. By default, fields with
11206	// empty or default values are omitted from API requests. However, any
11207	// non-pointer, non-interface field appearing in ForceSendFields will be
11208	// sent to the server regardless of whether the field is empty or not.
11209	// This may be used to include empty fields in Patch requests.
11210	ForceSendFields []string `json:"-"`
11211
11212	// NullFields is a list of field names (e.g. "Title") to include in API
11213	// requests with the JSON null value. By default, fields with empty
11214	// values are omitted from API requests. However, any field with an
11215	// empty value appearing in NullFields will be sent to the server as
11216	// null. It is an error if a field in this list has a non-empty value.
11217	// This may be used to include null fields in Patch requests.
11218	NullFields []string `json:"-"`
11219}
11220
11221func (s *GoogleCloudDialogflowV2IntentMessageSuggestion) MarshalJSON() ([]byte, error) {
11222	type NoMethod GoogleCloudDialogflowV2IntentMessageSuggestion
11223	raw := NoMethod(*s)
11224	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
11225}
11226
11227// GoogleCloudDialogflowV2IntentMessageSuggestions: The collection of
11228// suggestions.
11229type GoogleCloudDialogflowV2IntentMessageSuggestions struct {
11230	// Suggestions: Required. The list of suggested replies.
11231	Suggestions []*GoogleCloudDialogflowV2IntentMessageSuggestion `json:"suggestions,omitempty"`
11232
11233	// ForceSendFields is a list of field names (e.g. "Suggestions") to
11234	// unconditionally include in API requests. By default, fields with
11235	// empty or default values are omitted from API requests. However, any
11236	// non-pointer, non-interface field appearing in ForceSendFields will be
11237	// sent to the server regardless of whether the field is empty or not.
11238	// This may be used to include empty fields in Patch requests.
11239	ForceSendFields []string `json:"-"`
11240
11241	// NullFields is a list of field names (e.g. "Suggestions") to include
11242	// in API requests with the JSON null value. By default, fields with
11243	// empty values are omitted from API requests. However, any field with
11244	// an empty value appearing in NullFields will be sent to the server as
11245	// null. It is an error if a field in this list has a non-empty value.
11246	// This may be used to include null fields in Patch requests.
11247	NullFields []string `json:"-"`
11248}
11249
11250func (s *GoogleCloudDialogflowV2IntentMessageSuggestions) MarshalJSON() ([]byte, error) {
11251	type NoMethod GoogleCloudDialogflowV2IntentMessageSuggestions
11252	raw := NoMethod(*s)
11253	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
11254}
11255
11256// GoogleCloudDialogflowV2IntentMessageTableCard: Table card for Actions
11257// on Google.
11258type GoogleCloudDialogflowV2IntentMessageTableCard struct {
11259	// Buttons: Optional. List of buttons for the card.
11260	Buttons []*GoogleCloudDialogflowV2IntentMessageBasicCardButton `json:"buttons,omitempty"`
11261
11262	// ColumnProperties: Optional. Display properties for the columns in
11263	// this table.
11264	ColumnProperties []*GoogleCloudDialogflowV2IntentMessageColumnProperties `json:"columnProperties,omitempty"`
11265
11266	// Image: Optional. Image which should be displayed on the card.
11267	Image *GoogleCloudDialogflowV2IntentMessageImage `json:"image,omitempty"`
11268
11269	// Rows: Optional. Rows in this table of data.
11270	Rows []*GoogleCloudDialogflowV2IntentMessageTableCardRow `json:"rows,omitempty"`
11271
11272	// Subtitle: Optional. Subtitle to the title.
11273	Subtitle string `json:"subtitle,omitempty"`
11274
11275	// Title: Required. Title of the card.
11276	Title string `json:"title,omitempty"`
11277
11278	// ForceSendFields is a list of field names (e.g. "Buttons") to
11279	// unconditionally include in API requests. By default, fields with
11280	// empty or default values are omitted from API requests. However, any
11281	// non-pointer, non-interface field appearing in ForceSendFields will be
11282	// sent to the server regardless of whether the field is empty or not.
11283	// This may be used to include empty fields in Patch requests.
11284	ForceSendFields []string `json:"-"`
11285
11286	// NullFields is a list of field names (e.g. "Buttons") to include in
11287	// API requests with the JSON null value. By default, fields with empty
11288	// values are omitted from API requests. However, any field with an
11289	// empty value appearing in NullFields will be sent to the server as
11290	// null. It is an error if a field in this list has a non-empty value.
11291	// This may be used to include null fields in Patch requests.
11292	NullFields []string `json:"-"`
11293}
11294
11295func (s *GoogleCloudDialogflowV2IntentMessageTableCard) MarshalJSON() ([]byte, error) {
11296	type NoMethod GoogleCloudDialogflowV2IntentMessageTableCard
11297	raw := NoMethod(*s)
11298	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
11299}
11300
11301// GoogleCloudDialogflowV2IntentMessageTableCardCell: Cell of
11302// TableCardRow.
11303type GoogleCloudDialogflowV2IntentMessageTableCardCell struct {
11304	// Text: Required. Text in this cell.
11305	Text string `json:"text,omitempty"`
11306
11307	// ForceSendFields is a list of field names (e.g. "Text") to
11308	// unconditionally include in API requests. By default, fields with
11309	// empty or default values are omitted from API requests. However, any
11310	// non-pointer, non-interface field appearing in ForceSendFields will be
11311	// sent to the server regardless of whether the field is empty or not.
11312	// This may be used to include empty fields in Patch requests.
11313	ForceSendFields []string `json:"-"`
11314
11315	// NullFields is a list of field names (e.g. "Text") to include in API
11316	// requests with the JSON null value. By default, fields with empty
11317	// values are omitted from API requests. However, any field with an
11318	// empty value appearing in NullFields will be sent to the server as
11319	// null. It is an error if a field in this list has a non-empty value.
11320	// This may be used to include null fields in Patch requests.
11321	NullFields []string `json:"-"`
11322}
11323
11324func (s *GoogleCloudDialogflowV2IntentMessageTableCardCell) MarshalJSON() ([]byte, error) {
11325	type NoMethod GoogleCloudDialogflowV2IntentMessageTableCardCell
11326	raw := NoMethod(*s)
11327	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
11328}
11329
11330// GoogleCloudDialogflowV2IntentMessageTableCardRow: Row of TableCard.
11331type GoogleCloudDialogflowV2IntentMessageTableCardRow struct {
11332	// Cells: Optional. List of cells that make up this row.
11333	Cells []*GoogleCloudDialogflowV2IntentMessageTableCardCell `json:"cells,omitempty"`
11334
11335	// DividerAfter: Optional. Whether to add a visual divider after this
11336	// row.
11337	DividerAfter bool `json:"dividerAfter,omitempty"`
11338
11339	// ForceSendFields is a list of field names (e.g. "Cells") to
11340	// unconditionally include in API requests. By default, fields with
11341	// empty or default values are omitted from API requests. However, any
11342	// non-pointer, non-interface field appearing in ForceSendFields will be
11343	// sent to the server regardless of whether the field is empty or not.
11344	// This may be used to include empty fields in Patch requests.
11345	ForceSendFields []string `json:"-"`
11346
11347	// NullFields is a list of field names (e.g. "Cells") to include in API
11348	// requests with the JSON null value. By default, fields with empty
11349	// values are omitted from API requests. However, any field with an
11350	// empty value appearing in NullFields will be sent to the server as
11351	// null. It is an error if a field in this list has a non-empty value.
11352	// This may be used to include null fields in Patch requests.
11353	NullFields []string `json:"-"`
11354}
11355
11356func (s *GoogleCloudDialogflowV2IntentMessageTableCardRow) MarshalJSON() ([]byte, error) {
11357	type NoMethod GoogleCloudDialogflowV2IntentMessageTableCardRow
11358	raw := NoMethod(*s)
11359	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
11360}
11361
11362// GoogleCloudDialogflowV2IntentMessageText: The text response message.
11363type GoogleCloudDialogflowV2IntentMessageText struct {
11364	// Text: Optional. The collection of the agent's responses.
11365	Text []string `json:"text,omitempty"`
11366
11367	// ForceSendFields is a list of field names (e.g. "Text") to
11368	// unconditionally include in API requests. By default, fields with
11369	// empty or default values are omitted from API requests. However, any
11370	// non-pointer, non-interface field appearing in ForceSendFields will be
11371	// sent to the server regardless of whether the field is empty or not.
11372	// This may be used to include empty fields in Patch requests.
11373	ForceSendFields []string `json:"-"`
11374
11375	// NullFields is a list of field names (e.g. "Text") to include in API
11376	// requests with the JSON null value. By default, fields with empty
11377	// values are omitted from API requests. However, any field with an
11378	// empty value appearing in NullFields will be sent to the server as
11379	// null. It is an error if a field in this list has a non-empty value.
11380	// This may be used to include null fields in Patch requests.
11381	NullFields []string `json:"-"`
11382}
11383
11384func (s *GoogleCloudDialogflowV2IntentMessageText) MarshalJSON() ([]byte, error) {
11385	type NoMethod GoogleCloudDialogflowV2IntentMessageText
11386	raw := NoMethod(*s)
11387	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
11388}
11389
11390// GoogleCloudDialogflowV2IntentParameter: Represents intent parameters.
11391type GoogleCloudDialogflowV2IntentParameter struct {
11392	// DefaultValue: Optional. The default value to use when the `value`
11393	// yields an empty result. Default values can be extracted from contexts
11394	// by using the following syntax: `#context_name.parameter_name`.
11395	DefaultValue string `json:"defaultValue,omitempty"`
11396
11397	// DisplayName: Required. The name of the parameter.
11398	DisplayName string `json:"displayName,omitempty"`
11399
11400	// EntityTypeDisplayName: Optional. The name of the entity type,
11401	// prefixed with `@`, that describes values of the parameter. If the
11402	// parameter is required, this must be provided.
11403	EntityTypeDisplayName string `json:"entityTypeDisplayName,omitempty"`
11404
11405	// IsList: Optional. Indicates whether the parameter represents a list
11406	// of values.
11407	IsList bool `json:"isList,omitempty"`
11408
11409	// Mandatory: Optional. Indicates whether the parameter is required.
11410	// That is, whether the intent cannot be completed without collecting
11411	// the parameter value.
11412	Mandatory bool `json:"mandatory,omitempty"`
11413
11414	// Name: The unique identifier of this parameter.
11415	Name string `json:"name,omitempty"`
11416
11417	// Prompts: Optional. The collection of prompts that the agent can
11418	// present to the user in order to collect a value for the parameter.
11419	Prompts []string `json:"prompts,omitempty"`
11420
11421	// Value: Optional. The definition of the parameter value. It can be: -
11422	// a constant string, - a parameter value defined as `$parameter_name`,
11423	// - an original parameter value defined as `$parameter_name.original`,
11424	// - a parameter value from some context defined as
11425	// `#context_name.parameter_name`.
11426	Value string `json:"value,omitempty"`
11427
11428	// ForceSendFields is a list of field names (e.g. "DefaultValue") to
11429	// unconditionally include in API requests. By default, fields with
11430	// empty or default values are omitted from API requests. However, any
11431	// non-pointer, non-interface field appearing in ForceSendFields will be
11432	// sent to the server regardless of whether the field is empty or not.
11433	// This may be used to include empty fields in Patch requests.
11434	ForceSendFields []string `json:"-"`
11435
11436	// NullFields is a list of field names (e.g. "DefaultValue") to include
11437	// in API requests with the JSON null value. By default, fields with
11438	// empty values are omitted from API requests. However, any field with
11439	// an empty value appearing in NullFields will be sent to the server as
11440	// null. It is an error if a field in this list has a non-empty value.
11441	// This may be used to include null fields in Patch requests.
11442	NullFields []string `json:"-"`
11443}
11444
11445func (s *GoogleCloudDialogflowV2IntentParameter) MarshalJSON() ([]byte, error) {
11446	type NoMethod GoogleCloudDialogflowV2IntentParameter
11447	raw := NoMethod(*s)
11448	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
11449}
11450
11451// GoogleCloudDialogflowV2IntentTrainingPhrase: Represents an example
11452// that the agent is trained on.
11453type GoogleCloudDialogflowV2IntentTrainingPhrase struct {
11454	// Name: Output only. The unique identifier of this training phrase.
11455	Name string `json:"name,omitempty"`
11456
11457	// Parts: Required. The ordered list of training phrase parts. The parts
11458	// are concatenated in order to form the training phrase. Note: The API
11459	// does not automatically annotate training phrases like the Dialogflow
11460	// Console does. Note: Do not forget to include whitespace at part
11461	// boundaries, so the training phrase is well formatted when the parts
11462	// are concatenated. If the training phrase does not need to be
11463	// annotated with parameters, you just need a single part with only the
11464	// Part.text field set. If you want to annotate the training phrase, you
11465	// must create multiple parts, where the fields of each part are
11466	// populated in one of two ways: - `Part.text` is set to a part of the
11467	// phrase that has no parameters. - `Part.text` is set to a part of the
11468	// phrase that you want to annotate, and the `entity_type`, `alias`, and
11469	// `user_defined` fields are all set.
11470	Parts []*GoogleCloudDialogflowV2IntentTrainingPhrasePart `json:"parts,omitempty"`
11471
11472	// TimesAddedCount: Optional. Indicates how many times this example was
11473	// added to the intent. Each time a developer adds an existing sample by
11474	// editing an intent or training, this counter is increased.
11475	TimesAddedCount int64 `json:"timesAddedCount,omitempty"`
11476
11477	// Type: Required. The type of the training phrase.
11478	//
11479	// Possible values:
11480	//   "TYPE_UNSPECIFIED" - Not specified. This value should never be
11481	// used.
11482	//   "EXAMPLE" - Examples do not contain @-prefixed entity type names,
11483	// but example parts can be annotated with entity types.
11484	//   "TEMPLATE" - Templates are not annotated with entity types, but
11485	// they can contain @-prefixed entity type names as substrings. Template
11486	// mode has been deprecated. Example mode is the only supported way to
11487	// create new training phrases. If you have existing training phrases
11488	// that you've created in template mode, those will continue to work.
11489	Type string `json:"type,omitempty"`
11490
11491	// ForceSendFields is a list of field names (e.g. "Name") to
11492	// unconditionally include in API requests. By default, fields with
11493	// empty or default values are omitted from API requests. However, any
11494	// non-pointer, non-interface field appearing in ForceSendFields will be
11495	// sent to the server regardless of whether the field is empty or not.
11496	// This may be used to include empty fields in Patch requests.
11497	ForceSendFields []string `json:"-"`
11498
11499	// NullFields is a list of field names (e.g. "Name") to include in API
11500	// requests with the JSON null value. By default, fields with empty
11501	// values are omitted from API requests. However, any field with an
11502	// empty value appearing in NullFields will be sent to the server as
11503	// null. It is an error if a field in this list has a non-empty value.
11504	// This may be used to include null fields in Patch requests.
11505	NullFields []string `json:"-"`
11506}
11507
11508func (s *GoogleCloudDialogflowV2IntentTrainingPhrase) MarshalJSON() ([]byte, error) {
11509	type NoMethod GoogleCloudDialogflowV2IntentTrainingPhrase
11510	raw := NoMethod(*s)
11511	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
11512}
11513
11514// GoogleCloudDialogflowV2IntentTrainingPhrasePart: Represents a part of
11515// a training phrase.
11516type GoogleCloudDialogflowV2IntentTrainingPhrasePart struct {
11517	// Alias: Optional. The parameter name for the value extracted from the
11518	// annotated part of the example. This field is required for annotated
11519	// parts of the training phrase.
11520	Alias string `json:"alias,omitempty"`
11521
11522	// EntityType: Optional. The entity type name prefixed with `@`. This
11523	// field is required for annotated parts of the training phrase.
11524	EntityType string `json:"entityType,omitempty"`
11525
11526	// Text: Required. The text for this part.
11527	Text string `json:"text,omitempty"`
11528
11529	// UserDefined: Optional. Indicates whether the text was manually
11530	// annotated. This field is set to true when the Dialogflow Console is
11531	// used to manually annotate the part. When creating an annotated part
11532	// with the API, you must set this to true.
11533	UserDefined bool `json:"userDefined,omitempty"`
11534
11535	// ForceSendFields is a list of field names (e.g. "Alias") to
11536	// unconditionally include in API requests. By default, fields with
11537	// empty or default values are omitted from API requests. However, any
11538	// non-pointer, non-interface field appearing in ForceSendFields will be
11539	// sent to the server regardless of whether the field is empty or not.
11540	// This may be used to include empty fields in Patch requests.
11541	ForceSendFields []string `json:"-"`
11542
11543	// NullFields is a list of field names (e.g. "Alias") to include in API
11544	// requests with the JSON null value. By default, fields with empty
11545	// values are omitted from API requests. However, any field with an
11546	// empty value appearing in NullFields will be sent to the server as
11547	// null. It is an error if a field in this list has a non-empty value.
11548	// This may be used to include null fields in Patch requests.
11549	NullFields []string `json:"-"`
11550}
11551
11552func (s *GoogleCloudDialogflowV2IntentTrainingPhrasePart) MarshalJSON() ([]byte, error) {
11553	type NoMethod GoogleCloudDialogflowV2IntentTrainingPhrasePart
11554	raw := NoMethod(*s)
11555	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
11556}
11557
11558// GoogleCloudDialogflowV2KnowledgeBase: A knowledge base represents a
11559// collection of knowledge documents that you provide to Dialogflow.
11560// Your knowledge documents contain information that may be useful
11561// during conversations with end-users. Some Dialogflow features use
11562// knowledge bases when looking for a response to an end-user input. For
11563// more information, see the knowledge base guide
11564// (https://cloud.google.com/dialogflow/docs/how/knowledge-bases). Note:
11565// The `projects.agent.knowledgeBases` resource is deprecated; only use
11566// `projects.knowledgeBases`.
11567type GoogleCloudDialogflowV2KnowledgeBase struct {
11568	// DisplayName: Required. The display name of the knowledge base. The
11569	// name must be 1024 bytes or less; otherwise, the creation request
11570	// fails.
11571	DisplayName string `json:"displayName,omitempty"`
11572
11573	// LanguageCode: Language which represents the KnowledgeBase. When the
11574	// KnowledgeBase is created/updated, expect this to be present for non
11575	// en-us languages. When unspecified, the default language code en-us
11576	// applies.
11577	LanguageCode string `json:"languageCode,omitempty"`
11578
11579	// Name: The knowledge base resource name. The name must be empty when
11580	// creating a knowledge base. Format:
11581	// `projects//locations//knowledgeBases/`.
11582	Name string `json:"name,omitempty"`
11583
11584	// ServerResponse contains the HTTP response code and headers from the
11585	// server.
11586	googleapi.ServerResponse `json:"-"`
11587
11588	// ForceSendFields is a list of field names (e.g. "DisplayName") to
11589	// unconditionally include in API requests. By default, fields with
11590	// empty or default values are omitted from API requests. However, any
11591	// non-pointer, non-interface field appearing in ForceSendFields will be
11592	// sent to the server regardless of whether the field is empty or not.
11593	// This may be used to include empty fields in Patch requests.
11594	ForceSendFields []string `json:"-"`
11595
11596	// NullFields is a list of field names (e.g. "DisplayName") to include
11597	// in API requests with the JSON null value. By default, fields with
11598	// empty values are omitted from API requests. However, any field with
11599	// an empty value appearing in NullFields will be sent to the server as
11600	// null. It is an error if a field in this list has a non-empty value.
11601	// This may be used to include null fields in Patch requests.
11602	NullFields []string `json:"-"`
11603}
11604
11605func (s *GoogleCloudDialogflowV2KnowledgeBase) MarshalJSON() ([]byte, error) {
11606	type NoMethod GoogleCloudDialogflowV2KnowledgeBase
11607	raw := NoMethod(*s)
11608	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
11609}
11610
11611// GoogleCloudDialogflowV2KnowledgeOperationMetadata: Metadata in
11612// google::longrunning::Operation for Knowledge operations.
11613type GoogleCloudDialogflowV2KnowledgeOperationMetadata struct {
11614	// State: Output only. The current state of this operation.
11615	//
11616	// Possible values:
11617	//   "STATE_UNSPECIFIED" - State unspecified.
11618	//   "PENDING" - The operation has been created.
11619	//   "RUNNING" - The operation is currently running.
11620	//   "DONE" - The operation is done, either cancelled or completed.
11621	State string `json:"state,omitempty"`
11622
11623	// ForceSendFields is a list of field names (e.g. "State") to
11624	// unconditionally include in API requests. By default, fields with
11625	// empty or default values are omitted from API requests. However, any
11626	// non-pointer, non-interface field appearing in ForceSendFields will be
11627	// sent to the server regardless of whether the field is empty or not.
11628	// This may be used to include empty fields in Patch requests.
11629	ForceSendFields []string `json:"-"`
11630
11631	// NullFields is a list of field names (e.g. "State") to include in API
11632	// requests with the JSON null value. By default, fields with empty
11633	// values are omitted from API requests. However, any field with an
11634	// empty value appearing in NullFields will be sent to the server as
11635	// null. It is an error if a field in this list has a non-empty value.
11636	// This may be used to include null fields in Patch requests.
11637	NullFields []string `json:"-"`
11638}
11639
11640func (s *GoogleCloudDialogflowV2KnowledgeOperationMetadata) MarshalJSON() ([]byte, error) {
11641	type NoMethod GoogleCloudDialogflowV2KnowledgeOperationMetadata
11642	raw := NoMethod(*s)
11643	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
11644}
11645
11646// GoogleCloudDialogflowV2ListAnswerRecordsResponse: Response message
11647// for AnswerRecords.ListAnswerRecords.
11648type GoogleCloudDialogflowV2ListAnswerRecordsResponse struct {
11649	// AnswerRecords: The list of answer records.
11650	AnswerRecords []*GoogleCloudDialogflowV2AnswerRecord `json:"answerRecords,omitempty"`
11651
11652	// NextPageToken: A token to retrieve next page of results. Or empty if
11653	// there are no more results. Pass this value in the
11654	// ListAnswerRecordsRequest.page_token field in the subsequent call to
11655	// `ListAnswerRecords` method to retrieve the next page of results.
11656	NextPageToken string `json:"nextPageToken,omitempty"`
11657
11658	// ServerResponse contains the HTTP response code and headers from the
11659	// server.
11660	googleapi.ServerResponse `json:"-"`
11661
11662	// ForceSendFields is a list of field names (e.g. "AnswerRecords") to
11663	// unconditionally include in API requests. By default, fields with
11664	// empty or default values are omitted from API requests. However, any
11665	// non-pointer, non-interface field appearing in ForceSendFields will be
11666	// sent to the server regardless of whether the field is empty or not.
11667	// This may be used to include empty fields in Patch requests.
11668	ForceSendFields []string `json:"-"`
11669
11670	// NullFields is a list of field names (e.g. "AnswerRecords") to include
11671	// in API requests with the JSON null value. By default, fields with
11672	// empty values are omitted from API requests. However, any field with
11673	// an empty value appearing in NullFields will be sent to the server as
11674	// null. It is an error if a field in this list has a non-empty value.
11675	// This may be used to include null fields in Patch requests.
11676	NullFields []string `json:"-"`
11677}
11678
11679func (s *GoogleCloudDialogflowV2ListAnswerRecordsResponse) MarshalJSON() ([]byte, error) {
11680	type NoMethod GoogleCloudDialogflowV2ListAnswerRecordsResponse
11681	raw := NoMethod(*s)
11682	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
11683}
11684
11685// GoogleCloudDialogflowV2ListContextsResponse: The response message for
11686// Contexts.ListContexts.
11687type GoogleCloudDialogflowV2ListContextsResponse struct {
11688	// Contexts: The list of contexts. There will be a maximum number of
11689	// items returned based on the page_size field in the request.
11690	Contexts []*GoogleCloudDialogflowV2Context `json:"contexts,omitempty"`
11691
11692	// NextPageToken: Token to retrieve the next page of results, or empty
11693	// if there are no more results in the list.
11694	NextPageToken string `json:"nextPageToken,omitempty"`
11695
11696	// ServerResponse contains the HTTP response code and headers from the
11697	// server.
11698	googleapi.ServerResponse `json:"-"`
11699
11700	// ForceSendFields is a list of field names (e.g. "Contexts") to
11701	// unconditionally include in API requests. By default, fields with
11702	// empty or default values are omitted from API requests. However, any
11703	// non-pointer, non-interface field appearing in ForceSendFields will be
11704	// sent to the server regardless of whether the field is empty or not.
11705	// This may be used to include empty fields in Patch requests.
11706	ForceSendFields []string `json:"-"`
11707
11708	// NullFields is a list of field names (e.g. "Contexts") to include in
11709	// API requests with the JSON null value. By default, fields with empty
11710	// values are omitted from API requests. However, any field with an
11711	// empty value appearing in NullFields will be sent to the server as
11712	// null. It is an error if a field in this list has a non-empty value.
11713	// This may be used to include null fields in Patch requests.
11714	NullFields []string `json:"-"`
11715}
11716
11717func (s *GoogleCloudDialogflowV2ListContextsResponse) MarshalJSON() ([]byte, error) {
11718	type NoMethod GoogleCloudDialogflowV2ListContextsResponse
11719	raw := NoMethod(*s)
11720	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
11721}
11722
11723// GoogleCloudDialogflowV2ListConversationProfilesResponse: The response
11724// message for ConversationProfiles.ListConversationProfiles.
11725type GoogleCloudDialogflowV2ListConversationProfilesResponse struct {
11726	// ConversationProfiles: The list of project conversation profiles.
11727	// There is a maximum number of items returned based on the page_size
11728	// field in the request.
11729	ConversationProfiles []*GoogleCloudDialogflowV2ConversationProfile `json:"conversationProfiles,omitempty"`
11730
11731	// NextPageToken: Token to retrieve the next page of results, or empty
11732	// if there are no more results in the list.
11733	NextPageToken string `json:"nextPageToken,omitempty"`
11734
11735	// ServerResponse contains the HTTP response code and headers from the
11736	// server.
11737	googleapi.ServerResponse `json:"-"`
11738
11739	// ForceSendFields is a list of field names (e.g.
11740	// "ConversationProfiles") to unconditionally include in API requests.
11741	// By default, fields with empty or default values are omitted from API
11742	// requests. However, any non-pointer, non-interface field appearing in
11743	// ForceSendFields will be sent to the server regardless of whether the
11744	// field is empty or not. This may be used to include empty fields in
11745	// Patch requests.
11746	ForceSendFields []string `json:"-"`
11747
11748	// NullFields is a list of field names (e.g. "ConversationProfiles") to
11749	// include in API requests with the JSON null value. By default, fields
11750	// with empty values are omitted from API requests. However, any field
11751	// with an empty value appearing in NullFields will be sent to the
11752	// server as null. It is an error if a field in this list has a
11753	// non-empty value. This may be used to include null fields in Patch
11754	// requests.
11755	NullFields []string `json:"-"`
11756}
11757
11758func (s *GoogleCloudDialogflowV2ListConversationProfilesResponse) MarshalJSON() ([]byte, error) {
11759	type NoMethod GoogleCloudDialogflowV2ListConversationProfilesResponse
11760	raw := NoMethod(*s)
11761	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
11762}
11763
11764// GoogleCloudDialogflowV2ListConversationsResponse: The response
11765// message for Conversations.ListConversations.
11766type GoogleCloudDialogflowV2ListConversationsResponse struct {
11767	// Conversations: The list of conversations. There will be a maximum
11768	// number of items returned based on the page_size field in the request.
11769	Conversations []*GoogleCloudDialogflowV2Conversation `json:"conversations,omitempty"`
11770
11771	// NextPageToken: Token to retrieve the next page of results, or empty
11772	// if there are no more results in the list.
11773	NextPageToken string `json:"nextPageToken,omitempty"`
11774
11775	// ServerResponse contains the HTTP response code and headers from the
11776	// server.
11777	googleapi.ServerResponse `json:"-"`
11778
11779	// ForceSendFields is a list of field names (e.g. "Conversations") to
11780	// unconditionally include in API requests. By default, fields with
11781	// empty or default values are omitted from API requests. However, any
11782	// non-pointer, non-interface field appearing in ForceSendFields will be
11783	// sent to the server regardless of whether the field is empty or not.
11784	// This may be used to include empty fields in Patch requests.
11785	ForceSendFields []string `json:"-"`
11786
11787	// NullFields is a list of field names (e.g. "Conversations") to include
11788	// in API requests with the JSON null value. By default, fields with
11789	// empty values are omitted from API requests. However, any field with
11790	// an empty value appearing in NullFields will be sent to the server as
11791	// null. It is an error if a field in this list has a non-empty value.
11792	// This may be used to include null fields in Patch requests.
11793	NullFields []string `json:"-"`
11794}
11795
11796func (s *GoogleCloudDialogflowV2ListConversationsResponse) MarshalJSON() ([]byte, error) {
11797	type NoMethod GoogleCloudDialogflowV2ListConversationsResponse
11798	raw := NoMethod(*s)
11799	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
11800}
11801
11802// GoogleCloudDialogflowV2ListDocumentsResponse: Response message for
11803// Documents.ListDocuments.
11804type GoogleCloudDialogflowV2ListDocumentsResponse struct {
11805	// Documents: The list of documents.
11806	Documents []*GoogleCloudDialogflowV2Document `json:"documents,omitempty"`
11807
11808	// NextPageToken: Token to retrieve the next page of results, or empty
11809	// if there are no more results in the list.
11810	NextPageToken string `json:"nextPageToken,omitempty"`
11811
11812	// ServerResponse contains the HTTP response code and headers from the
11813	// server.
11814	googleapi.ServerResponse `json:"-"`
11815
11816	// ForceSendFields is a list of field names (e.g. "Documents") to
11817	// unconditionally include in API requests. By default, fields with
11818	// empty or default values are omitted from API requests. However, any
11819	// non-pointer, non-interface field appearing in ForceSendFields will be
11820	// sent to the server regardless of whether the field is empty or not.
11821	// This may be used to include empty fields in Patch requests.
11822	ForceSendFields []string `json:"-"`
11823
11824	// NullFields is a list of field names (e.g. "Documents") to include in
11825	// API requests with the JSON null value. By default, fields with empty
11826	// values are omitted from API requests. However, any field with an
11827	// empty value appearing in NullFields will be sent to the server as
11828	// null. It is an error if a field in this list has a non-empty value.
11829	// This may be used to include null fields in Patch requests.
11830	NullFields []string `json:"-"`
11831}
11832
11833func (s *GoogleCloudDialogflowV2ListDocumentsResponse) MarshalJSON() ([]byte, error) {
11834	type NoMethod GoogleCloudDialogflowV2ListDocumentsResponse
11835	raw := NoMethod(*s)
11836	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
11837}
11838
11839// GoogleCloudDialogflowV2ListEntityTypesResponse: The response message
11840// for EntityTypes.ListEntityTypes.
11841type GoogleCloudDialogflowV2ListEntityTypesResponse struct {
11842	// EntityTypes: The list of agent entity types. There will be a maximum
11843	// number of items returned based on the page_size field in the request.
11844	EntityTypes []*GoogleCloudDialogflowV2EntityType `json:"entityTypes,omitempty"`
11845
11846	// NextPageToken: Token to retrieve the next page of results, or empty
11847	// if there are no more results in the list.
11848	NextPageToken string `json:"nextPageToken,omitempty"`
11849
11850	// ServerResponse contains the HTTP response code and headers from the
11851	// server.
11852	googleapi.ServerResponse `json:"-"`
11853
11854	// ForceSendFields is a list of field names (e.g. "EntityTypes") to
11855	// unconditionally include in API requests. By default, fields with
11856	// empty or default values are omitted from API requests. However, any
11857	// non-pointer, non-interface field appearing in ForceSendFields will be
11858	// sent to the server regardless of whether the field is empty or not.
11859	// This may be used to include empty fields in Patch requests.
11860	ForceSendFields []string `json:"-"`
11861
11862	// NullFields is a list of field names (e.g. "EntityTypes") to include
11863	// in API requests with the JSON null value. By default, fields with
11864	// empty values are omitted from API requests. However, any field with
11865	// an empty value appearing in NullFields will be sent to the server as
11866	// null. It is an error if a field in this list has a non-empty value.
11867	// This may be used to include null fields in Patch requests.
11868	NullFields []string `json:"-"`
11869}
11870
11871func (s *GoogleCloudDialogflowV2ListEntityTypesResponse) MarshalJSON() ([]byte, error) {
11872	type NoMethod GoogleCloudDialogflowV2ListEntityTypesResponse
11873	raw := NoMethod(*s)
11874	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
11875}
11876
11877// GoogleCloudDialogflowV2ListEnvironmentsResponse: The response message
11878// for Environments.ListEnvironments.
11879type GoogleCloudDialogflowV2ListEnvironmentsResponse struct {
11880	// Environments: The list of agent environments. There will be a maximum
11881	// number of items returned based on the page_size field in the request.
11882	Environments []*GoogleCloudDialogflowV2Environment `json:"environments,omitempty"`
11883
11884	// NextPageToken: Token to retrieve the next page of results, or empty
11885	// if there are no more results in the list.
11886	NextPageToken string `json:"nextPageToken,omitempty"`
11887
11888	// ServerResponse contains the HTTP response code and headers from the
11889	// server.
11890	googleapi.ServerResponse `json:"-"`
11891
11892	// ForceSendFields is a list of field names (e.g. "Environments") to
11893	// unconditionally include in API requests. By default, fields with
11894	// empty or default values are omitted from API requests. However, any
11895	// non-pointer, non-interface field appearing in ForceSendFields will be
11896	// sent to the server regardless of whether the field is empty or not.
11897	// This may be used to include empty fields in Patch requests.
11898	ForceSendFields []string `json:"-"`
11899
11900	// NullFields is a list of field names (e.g. "Environments") to include
11901	// in API requests with the JSON null value. By default, fields with
11902	// empty values are omitted from API requests. However, any field with
11903	// an empty value appearing in NullFields will be sent to the server as
11904	// null. It is an error if a field in this list has a non-empty value.
11905	// This may be used to include null fields in Patch requests.
11906	NullFields []string `json:"-"`
11907}
11908
11909func (s *GoogleCloudDialogflowV2ListEnvironmentsResponse) MarshalJSON() ([]byte, error) {
11910	type NoMethod GoogleCloudDialogflowV2ListEnvironmentsResponse
11911	raw := NoMethod(*s)
11912	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
11913}
11914
11915// GoogleCloudDialogflowV2ListIntentsResponse: The response message for
11916// Intents.ListIntents.
11917type GoogleCloudDialogflowV2ListIntentsResponse struct {
11918	// Intents: The list of agent intents. There will be a maximum number of
11919	// items returned based on the page_size field in the request.
11920	Intents []*GoogleCloudDialogflowV2Intent `json:"intents,omitempty"`
11921
11922	// NextPageToken: Token to retrieve the next page of results, or empty
11923	// if there are no more results in the list.
11924	NextPageToken string `json:"nextPageToken,omitempty"`
11925
11926	// ServerResponse contains the HTTP response code and headers from the
11927	// server.
11928	googleapi.ServerResponse `json:"-"`
11929
11930	// ForceSendFields is a list of field names (e.g. "Intents") to
11931	// unconditionally include in API requests. By default, fields with
11932	// empty or default values are omitted from API requests. However, any
11933	// non-pointer, non-interface field appearing in ForceSendFields will be
11934	// sent to the server regardless of whether the field is empty or not.
11935	// This may be used to include empty fields in Patch requests.
11936	ForceSendFields []string `json:"-"`
11937
11938	// NullFields is a list of field names (e.g. "Intents") to include in
11939	// API requests with the JSON null value. By default, fields with empty
11940	// values are omitted from API requests. However, any field with an
11941	// empty value appearing in NullFields will be sent to the server as
11942	// null. It is an error if a field in this list has a non-empty value.
11943	// This may be used to include null fields in Patch requests.
11944	NullFields []string `json:"-"`
11945}
11946
11947func (s *GoogleCloudDialogflowV2ListIntentsResponse) MarshalJSON() ([]byte, error) {
11948	type NoMethod GoogleCloudDialogflowV2ListIntentsResponse
11949	raw := NoMethod(*s)
11950	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
11951}
11952
11953// GoogleCloudDialogflowV2ListKnowledgeBasesResponse: Response message
11954// for KnowledgeBases.ListKnowledgeBases.
11955type GoogleCloudDialogflowV2ListKnowledgeBasesResponse struct {
11956	// KnowledgeBases: The list of knowledge bases.
11957	KnowledgeBases []*GoogleCloudDialogflowV2KnowledgeBase `json:"knowledgeBases,omitempty"`
11958
11959	// NextPageToken: Token to retrieve the next page of results, or empty
11960	// if there are no more results in the list.
11961	NextPageToken string `json:"nextPageToken,omitempty"`
11962
11963	// ServerResponse contains the HTTP response code and headers from the
11964	// server.
11965	googleapi.ServerResponse `json:"-"`
11966
11967	// ForceSendFields is a list of field names (e.g. "KnowledgeBases") to
11968	// unconditionally include in API requests. By default, fields with
11969	// empty or default values are omitted from API requests. However, any
11970	// non-pointer, non-interface field appearing in ForceSendFields will be
11971	// sent to the server regardless of whether the field is empty or not.
11972	// This may be used to include empty fields in Patch requests.
11973	ForceSendFields []string `json:"-"`
11974
11975	// NullFields is a list of field names (e.g. "KnowledgeBases") to
11976	// include in API requests with the JSON null value. By default, fields
11977	// with empty values are omitted from API requests. However, any field
11978	// with an empty value appearing in NullFields will be sent to the
11979	// server as null. It is an error if a field in this list has a
11980	// non-empty value. This may be used to include null fields in Patch
11981	// requests.
11982	NullFields []string `json:"-"`
11983}
11984
11985func (s *GoogleCloudDialogflowV2ListKnowledgeBasesResponse) MarshalJSON() ([]byte, error) {
11986	type NoMethod GoogleCloudDialogflowV2ListKnowledgeBasesResponse
11987	raw := NoMethod(*s)
11988	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
11989}
11990
11991// GoogleCloudDialogflowV2ListMessagesResponse: The response message for
11992// Conversations.ListMessages.
11993type GoogleCloudDialogflowV2ListMessagesResponse struct {
11994	// Messages: The list of messages. There will be a maximum number of
11995	// items returned based on the page_size field in the request.
11996	// `messages` is sorted by `create_time` in descending order.
11997	Messages []*GoogleCloudDialogflowV2Message `json:"messages,omitempty"`
11998
11999	// NextPageToken: Token to retrieve the next page of results, or empty
12000	// if there are no more results in the list.
12001	NextPageToken string `json:"nextPageToken,omitempty"`
12002
12003	// ServerResponse contains the HTTP response code and headers from the
12004	// server.
12005	googleapi.ServerResponse `json:"-"`
12006
12007	// ForceSendFields is a list of field names (e.g. "Messages") to
12008	// unconditionally include in API requests. By default, fields with
12009	// empty or default values are omitted from API requests. However, any
12010	// non-pointer, non-interface field appearing in ForceSendFields will be
12011	// sent to the server regardless of whether the field is empty or not.
12012	// This may be used to include empty fields in Patch requests.
12013	ForceSendFields []string `json:"-"`
12014
12015	// NullFields is a list of field names (e.g. "Messages") to include in
12016	// API requests with the JSON null value. By default, fields with empty
12017	// values are omitted from API requests. However, any field with an
12018	// empty value appearing in NullFields will be sent to the server as
12019	// null. It is an error if a field in this list has a non-empty value.
12020	// This may be used to include null fields in Patch requests.
12021	NullFields []string `json:"-"`
12022}
12023
12024func (s *GoogleCloudDialogflowV2ListMessagesResponse) MarshalJSON() ([]byte, error) {
12025	type NoMethod GoogleCloudDialogflowV2ListMessagesResponse
12026	raw := NoMethod(*s)
12027	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
12028}
12029
12030// GoogleCloudDialogflowV2ListParticipantsResponse: The response message
12031// for Participants.ListParticipants.
12032type GoogleCloudDialogflowV2ListParticipantsResponse struct {
12033	// NextPageToken: Token to retrieve the next page of results or empty if
12034	// there are no more results in the list.
12035	NextPageToken string `json:"nextPageToken,omitempty"`
12036
12037	// Participants: The list of participants. There is a maximum number of
12038	// items returned based on the page_size field in the request.
12039	Participants []*GoogleCloudDialogflowV2Participant `json:"participants,omitempty"`
12040
12041	// ServerResponse contains the HTTP response code and headers from the
12042	// server.
12043	googleapi.ServerResponse `json:"-"`
12044
12045	// ForceSendFields is a list of field names (e.g. "NextPageToken") to
12046	// unconditionally include in API requests. By default, fields with
12047	// empty or default values are omitted from API requests. However, any
12048	// non-pointer, non-interface field appearing in ForceSendFields will be
12049	// sent to the server regardless of whether the field is empty or not.
12050	// This may be used to include empty fields in Patch requests.
12051	ForceSendFields []string `json:"-"`
12052
12053	// NullFields is a list of field names (e.g. "NextPageToken") to include
12054	// in API requests with the JSON null value. By default, fields with
12055	// empty values are omitted from API requests. However, any field with
12056	// an empty value appearing in NullFields will be sent to the server as
12057	// null. It is an error if a field in this list has a non-empty value.
12058	// This may be used to include null fields in Patch requests.
12059	NullFields []string `json:"-"`
12060}
12061
12062func (s *GoogleCloudDialogflowV2ListParticipantsResponse) MarshalJSON() ([]byte, error) {
12063	type NoMethod GoogleCloudDialogflowV2ListParticipantsResponse
12064	raw := NoMethod(*s)
12065	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
12066}
12067
12068// GoogleCloudDialogflowV2ListSessionEntityTypesResponse: The response
12069// message for SessionEntityTypes.ListSessionEntityTypes.
12070type GoogleCloudDialogflowV2ListSessionEntityTypesResponse struct {
12071	// NextPageToken: Token to retrieve the next page of results, or empty
12072	// if there are no more results in the list.
12073	NextPageToken string `json:"nextPageToken,omitempty"`
12074
12075	// SessionEntityTypes: The list of session entity types. There will be a
12076	// maximum number of items returned based on the page_size field in the
12077	// request.
12078	SessionEntityTypes []*GoogleCloudDialogflowV2SessionEntityType `json:"sessionEntityTypes,omitempty"`
12079
12080	// ServerResponse contains the HTTP response code and headers from the
12081	// server.
12082	googleapi.ServerResponse `json:"-"`
12083
12084	// ForceSendFields is a list of field names (e.g. "NextPageToken") to
12085	// unconditionally include in API requests. By default, fields with
12086	// empty or default values are omitted from API requests. However, any
12087	// non-pointer, non-interface field appearing in ForceSendFields will be
12088	// sent to the server regardless of whether the field is empty or not.
12089	// This may be used to include empty fields in Patch requests.
12090	ForceSendFields []string `json:"-"`
12091
12092	// NullFields is a list of field names (e.g. "NextPageToken") to include
12093	// in API requests with the JSON null value. By default, fields with
12094	// empty values are omitted from API requests. However, any field with
12095	// an empty value appearing in NullFields will be sent to the server as
12096	// null. It is an error if a field in this list has a non-empty value.
12097	// This may be used to include null fields in Patch requests.
12098	NullFields []string `json:"-"`
12099}
12100
12101func (s *GoogleCloudDialogflowV2ListSessionEntityTypesResponse) MarshalJSON() ([]byte, error) {
12102	type NoMethod GoogleCloudDialogflowV2ListSessionEntityTypesResponse
12103	raw := NoMethod(*s)
12104	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
12105}
12106
12107// GoogleCloudDialogflowV2ListVersionsResponse: The response message for
12108// Versions.ListVersions.
12109type GoogleCloudDialogflowV2ListVersionsResponse struct {
12110	// NextPageToken: Token to retrieve the next page of results, or empty
12111	// if there are no more results in the list.
12112	NextPageToken string `json:"nextPageToken,omitempty"`
12113
12114	// Versions: The list of agent versions. There will be a maximum number
12115	// of items returned based on the page_size field in the request.
12116	Versions []*GoogleCloudDialogflowV2Version `json:"versions,omitempty"`
12117
12118	// ServerResponse contains the HTTP response code and headers from the
12119	// server.
12120	googleapi.ServerResponse `json:"-"`
12121
12122	// ForceSendFields is a list of field names (e.g. "NextPageToken") to
12123	// unconditionally include in API requests. By default, fields with
12124	// empty or default values are omitted from API requests. However, any
12125	// non-pointer, non-interface field appearing in ForceSendFields will be
12126	// sent to the server regardless of whether the field is empty or not.
12127	// This may be used to include empty fields in Patch requests.
12128	ForceSendFields []string `json:"-"`
12129
12130	// NullFields is a list of field names (e.g. "NextPageToken") to include
12131	// in API requests with the JSON null value. By default, fields with
12132	// empty values are omitted from API requests. However, any field with
12133	// an empty value appearing in NullFields will be sent to the server as
12134	// null. It is an error if a field in this list has a non-empty value.
12135	// This may be used to include null fields in Patch requests.
12136	NullFields []string `json:"-"`
12137}
12138
12139func (s *GoogleCloudDialogflowV2ListVersionsResponse) MarshalJSON() ([]byte, error) {
12140	type NoMethod GoogleCloudDialogflowV2ListVersionsResponse
12141	raw := NoMethod(*s)
12142	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
12143}
12144
12145// GoogleCloudDialogflowV2LoggingConfig: Defines logging behavior for
12146// conversation lifecycle events.
12147type GoogleCloudDialogflowV2LoggingConfig struct {
12148	// EnableStackdriverLogging: Whether to log conversation events like
12149	// CONVERSATION_STARTED to Stackdriver in the conversation project as
12150	// JSON format ConversationEvent protos.
12151	EnableStackdriverLogging bool `json:"enableStackdriverLogging,omitempty"`
12152
12153	// ForceSendFields is a list of field names (e.g.
12154	// "EnableStackdriverLogging") to unconditionally include in API
12155	// requests. By default, fields with empty or default values are omitted
12156	// from API requests. However, any non-pointer, non-interface field
12157	// appearing in ForceSendFields will be sent to the server regardless of
12158	// whether the field is empty or not. This may be used to include empty
12159	// fields in Patch requests.
12160	ForceSendFields []string `json:"-"`
12161
12162	// NullFields is a list of field names (e.g. "EnableStackdriverLogging")
12163	// to include in API requests with the JSON null value. By default,
12164	// fields with empty values are omitted from API requests. However, any
12165	// field with an empty value appearing in NullFields will be sent to the
12166	// server as null. It is an error if a field in this list has a
12167	// non-empty value. This may be used to include null fields in Patch
12168	// requests.
12169	NullFields []string `json:"-"`
12170}
12171
12172func (s *GoogleCloudDialogflowV2LoggingConfig) MarshalJSON() ([]byte, error) {
12173	type NoMethod GoogleCloudDialogflowV2LoggingConfig
12174	raw := NoMethod(*s)
12175	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
12176}
12177
12178// GoogleCloudDialogflowV2Message: Represents a message posted into a
12179// conversation.
12180type GoogleCloudDialogflowV2Message struct {
12181	// Content: Required. The message content.
12182	Content string `json:"content,omitempty"`
12183
12184	// CreateTime: Output only. The time when the message was created.
12185	CreateTime string `json:"createTime,omitempty"`
12186
12187	// LanguageCode: Optional. The message language. This should be a BCP-47
12188	// (https://www.rfc-editor.org/rfc/bcp/bcp47.txt) language tag. Example:
12189	// "en-US".
12190	LanguageCode string `json:"languageCode,omitempty"`
12191
12192	// MessageAnnotation: Output only. The annotation for the message.
12193	MessageAnnotation *GoogleCloudDialogflowV2MessageAnnotation `json:"messageAnnotation,omitempty"`
12194
12195	// Name: The unique identifier of the message. Format:
12196	// `projects//locations//conversations//messages/`.
12197	Name string `json:"name,omitempty"`
12198
12199	// Participant: Output only. The participant that sends this message.
12200	Participant string `json:"participant,omitempty"`
12201
12202	// ParticipantRole: Output only. The role of the participant.
12203	//
12204	// Possible values:
12205	//   "ROLE_UNSPECIFIED" - Participant role not set.
12206	//   "HUMAN_AGENT" - Participant is a human agent.
12207	//   "AUTOMATED_AGENT" - Participant is an automated agent, such as a
12208	// Dialogflow agent.
12209	//   "END_USER" - Participant is an end user that has called or chatted
12210	// with Dialogflow services.
12211	ParticipantRole string `json:"participantRole,omitempty"`
12212
12213	// ForceSendFields is a list of field names (e.g. "Content") to
12214	// unconditionally include in API requests. By default, fields with
12215	// empty or default values are omitted from API requests. However, any
12216	// non-pointer, non-interface field appearing in ForceSendFields will be
12217	// sent to the server regardless of whether the field is empty or not.
12218	// This may be used to include empty fields in Patch requests.
12219	ForceSendFields []string `json:"-"`
12220
12221	// NullFields is a list of field names (e.g. "Content") to include in
12222	// API requests with the JSON null value. By default, fields with empty
12223	// values are omitted from API requests. However, any field with an
12224	// empty value appearing in NullFields will be sent to the server as
12225	// null. It is an error if a field in this list has a non-empty value.
12226	// This may be used to include null fields in Patch requests.
12227	NullFields []string `json:"-"`
12228}
12229
12230func (s *GoogleCloudDialogflowV2Message) MarshalJSON() ([]byte, error) {
12231	type NoMethod GoogleCloudDialogflowV2Message
12232	raw := NoMethod(*s)
12233	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
12234}
12235
12236// GoogleCloudDialogflowV2MessageAnnotation: Represents the result of
12237// annotation for the message.
12238type GoogleCloudDialogflowV2MessageAnnotation struct {
12239	// ContainEntities: Indicates whether the text message contains
12240	// entities.
12241	ContainEntities bool `json:"containEntities,omitempty"`
12242
12243	// Parts: The collection of annotated message parts ordered by their
12244	// position in the message. You can recover the annotated message by
12245	// concatenating [AnnotatedMessagePart.text].
12246	Parts []*GoogleCloudDialogflowV2AnnotatedMessagePart `json:"parts,omitempty"`
12247
12248	// ForceSendFields is a list of field names (e.g. "ContainEntities") to
12249	// unconditionally include in API requests. By default, fields with
12250	// empty or default values are omitted from API requests. However, any
12251	// non-pointer, non-interface field appearing in ForceSendFields will be
12252	// sent to the server regardless of whether the field is empty or not.
12253	// This may be used to include empty fields in Patch requests.
12254	ForceSendFields []string `json:"-"`
12255
12256	// NullFields is a list of field names (e.g. "ContainEntities") to
12257	// include in API requests with the JSON null value. By default, fields
12258	// with empty values are omitted from API requests. However, any field
12259	// with an empty value appearing in NullFields will be sent to the
12260	// server as null. It is an error if a field in this list has a
12261	// non-empty value. This may be used to include null fields in Patch
12262	// requests.
12263	NullFields []string `json:"-"`
12264}
12265
12266func (s *GoogleCloudDialogflowV2MessageAnnotation) MarshalJSON() ([]byte, error) {
12267	type NoMethod GoogleCloudDialogflowV2MessageAnnotation
12268	raw := NoMethod(*s)
12269	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
12270}
12271
12272// GoogleCloudDialogflowV2NotificationConfig: Defines notification
12273// behavior.
12274type GoogleCloudDialogflowV2NotificationConfig struct {
12275	// MessageFormat: Format of message.
12276	//
12277	// Possible values:
12278	//   "MESSAGE_FORMAT_UNSPECIFIED" - If it is unspeified, PROTO will be
12279	// used.
12280	//   "PROTO" - Pubsub message will be serialized proto.
12281	//   "JSON" - Pubsub message will be json.
12282	MessageFormat string `json:"messageFormat,omitempty"`
12283
12284	// Topic: Name of the Pub/Sub topic to publish conversation events like
12285	// CONVERSATION_STARTED as serialized ConversationEvent protos.
12286	// Notification works for phone calls, if this topic either is in the
12287	// same project as the conversation or you grant
12288	// `service-@gcp-sa-dialogflow.iam.gserviceaccount.com` the `Dialogflow
12289	// Service Agent` role in the topic project. Format:
12290	// `projects//locations//topics/`.
12291	Topic string `json:"topic,omitempty"`
12292
12293	// ForceSendFields is a list of field names (e.g. "MessageFormat") to
12294	// unconditionally include in API requests. By default, fields with
12295	// empty or default values are omitted from API requests. However, any
12296	// non-pointer, non-interface field appearing in ForceSendFields will be
12297	// sent to the server regardless of whether the field is empty or not.
12298	// This may be used to include empty fields in Patch requests.
12299	ForceSendFields []string `json:"-"`
12300
12301	// NullFields is a list of field names (e.g. "MessageFormat") to include
12302	// in API requests with the JSON null value. By default, fields with
12303	// empty values are omitted from API requests. However, any field with
12304	// an empty value appearing in NullFields will be sent to the server as
12305	// null. It is an error if a field in this list has a non-empty value.
12306	// This may be used to include null fields in Patch requests.
12307	NullFields []string `json:"-"`
12308}
12309
12310func (s *GoogleCloudDialogflowV2NotificationConfig) MarshalJSON() ([]byte, error) {
12311	type NoMethod GoogleCloudDialogflowV2NotificationConfig
12312	raw := NoMethod(*s)
12313	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
12314}
12315
12316// GoogleCloudDialogflowV2OriginalDetectIntentRequest: Represents the
12317// contents of the original request that was passed to the
12318// `[Streaming]DetectIntent` call.
12319type GoogleCloudDialogflowV2OriginalDetectIntentRequest struct {
12320	// Payload: Optional. This field is set to the value of the
12321	// `QueryParameters.payload` field passed in the request. Some
12322	// integrations that query a Dialogflow agent may provide additional
12323	// information in the payload. In particular, for the Dialogflow Phone
12324	// Gateway integration, this field has the form: { "telephony": {
12325	// "caller_id": "+18558363987" } } Note: The caller ID field
12326	// (`caller_id`) will be redacted for Trial Edition agents and populated
12327	// with the caller ID in E.164 format
12328	// (https://en.wikipedia.org/wiki/E.164) for Essentials Edition agents.
12329	Payload googleapi.RawMessage `json:"payload,omitempty"`
12330
12331	// Source: The source of this request, e.g., `google`, `facebook`,
12332	// `slack`. It is set by Dialogflow-owned servers.
12333	Source string `json:"source,omitempty"`
12334
12335	// Version: Optional. The version of the protocol used for this request.
12336	// This field is AoG-specific.
12337	Version string `json:"version,omitempty"`
12338
12339	// ForceSendFields is a list of field names (e.g. "Payload") to
12340	// unconditionally include in API requests. By default, fields with
12341	// empty or default values are omitted from API requests. However, any
12342	// non-pointer, non-interface field appearing in ForceSendFields will be
12343	// sent to the server regardless of whether the field is empty or not.
12344	// This may be used to include empty fields in Patch requests.
12345	ForceSendFields []string `json:"-"`
12346
12347	// NullFields is a list of field names (e.g. "Payload") to include in
12348	// API requests with the JSON null value. By default, fields with empty
12349	// values are omitted from API requests. However, any field with an
12350	// empty value appearing in NullFields will be sent to the server as
12351	// null. It is an error if a field in this list has a non-empty value.
12352	// This may be used to include null fields in Patch requests.
12353	NullFields []string `json:"-"`
12354}
12355
12356func (s *GoogleCloudDialogflowV2OriginalDetectIntentRequest) MarshalJSON() ([]byte, error) {
12357	type NoMethod GoogleCloudDialogflowV2OriginalDetectIntentRequest
12358	raw := NoMethod(*s)
12359	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
12360}
12361
12362// GoogleCloudDialogflowV2OutputAudio: Represents the natural language
12363// speech audio to be played to the end user.
12364type GoogleCloudDialogflowV2OutputAudio struct {
12365	// Audio: The natural language speech audio.
12366	Audio string `json:"audio,omitempty"`
12367
12368	// Config: Instructs the speech synthesizer how to generate the speech
12369	// audio.
12370	Config *GoogleCloudDialogflowV2OutputAudioConfig `json:"config,omitempty"`
12371
12372	// ForceSendFields is a list of field names (e.g. "Audio") to
12373	// unconditionally include in API requests. By default, fields with
12374	// empty or default values are omitted from API requests. However, any
12375	// non-pointer, non-interface field appearing in ForceSendFields will be
12376	// sent to the server regardless of whether the field is empty or not.
12377	// This may be used to include empty fields in Patch requests.
12378	ForceSendFields []string `json:"-"`
12379
12380	// NullFields is a list of field names (e.g. "Audio") to include in API
12381	// requests with the JSON null value. By default, fields with empty
12382	// values are omitted from API requests. However, any field with an
12383	// empty value appearing in NullFields will be sent to the server as
12384	// null. It is an error if a field in this list has a non-empty value.
12385	// This may be used to include null fields in Patch requests.
12386	NullFields []string `json:"-"`
12387}
12388
12389func (s *GoogleCloudDialogflowV2OutputAudio) MarshalJSON() ([]byte, error) {
12390	type NoMethod GoogleCloudDialogflowV2OutputAudio
12391	raw := NoMethod(*s)
12392	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
12393}
12394
12395// GoogleCloudDialogflowV2OutputAudioConfig: Instructs the speech
12396// synthesizer on how to generate the output audio content. If this
12397// audio config is supplied in a request, it overrides all existing
12398// text-to-speech settings applied to the agent.
12399type GoogleCloudDialogflowV2OutputAudioConfig struct {
12400	// AudioEncoding: Required. Audio encoding of the synthesized audio
12401	// content.
12402	//
12403	// Possible values:
12404	//   "OUTPUT_AUDIO_ENCODING_UNSPECIFIED" - Not specified.
12405	//   "OUTPUT_AUDIO_ENCODING_LINEAR_16" - Uncompressed 16-bit signed
12406	// little-endian samples (Linear PCM). Audio content returned as
12407	// LINEAR16 also contains a WAV header.
12408	//   "OUTPUT_AUDIO_ENCODING_MP3" - MP3 audio at 32kbps.
12409	//   "OUTPUT_AUDIO_ENCODING_MP3_64_KBPS" - MP3 audio at 64kbps.
12410	//   "OUTPUT_AUDIO_ENCODING_OGG_OPUS" - Opus encoded audio wrapped in an
12411	// ogg container. The result will be a file which can be played natively
12412	// on Android, and in browsers (at least Chrome and Firefox). The
12413	// quality of the encoding is considerably higher than MP3 while using
12414	// approximately the same bitrate.
12415	//   "OUTPUT_AUDIO_ENCODING_MULAW" - 8-bit samples that compand 14-bit
12416	// audio samples using G.711 PCMU/mu-law.
12417	AudioEncoding string `json:"audioEncoding,omitempty"`
12418
12419	// SampleRateHertz: The synthesis sample rate (in hertz) for this audio.
12420	// If not provided, then the synthesizer will use the default sample
12421	// rate based on the audio encoding. If this is different from the
12422	// voice's natural sample rate, then the synthesizer will honor this
12423	// request by converting to the desired sample rate (which might result
12424	// in worse audio quality).
12425	SampleRateHertz int64 `json:"sampleRateHertz,omitempty"`
12426
12427	// SynthesizeSpeechConfig: Configuration of how speech should be
12428	// synthesized.
12429	SynthesizeSpeechConfig *GoogleCloudDialogflowV2SynthesizeSpeechConfig `json:"synthesizeSpeechConfig,omitempty"`
12430
12431	// ForceSendFields is a list of field names (e.g. "AudioEncoding") to
12432	// unconditionally include in API requests. By default, fields with
12433	// empty or default values are omitted from API requests. However, any
12434	// non-pointer, non-interface field appearing in ForceSendFields will be
12435	// sent to the server regardless of whether the field is empty or not.
12436	// This may be used to include empty fields in Patch requests.
12437	ForceSendFields []string `json:"-"`
12438
12439	// NullFields is a list of field names (e.g. "AudioEncoding") to include
12440	// in API requests with the JSON null value. By default, fields with
12441	// empty values are omitted from API requests. However, any field with
12442	// an empty value appearing in NullFields will be sent to the server as
12443	// null. It is an error if a field in this list has a non-empty value.
12444	// This may be used to include null fields in Patch requests.
12445	NullFields []string `json:"-"`
12446}
12447
12448func (s *GoogleCloudDialogflowV2OutputAudioConfig) MarshalJSON() ([]byte, error) {
12449	type NoMethod GoogleCloudDialogflowV2OutputAudioConfig
12450	raw := NoMethod(*s)
12451	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
12452}
12453
12454// GoogleCloudDialogflowV2Participant: Represents a conversation
12455// participant (human agent, virtual agent, end-user).
12456type GoogleCloudDialogflowV2Participant struct {
12457	// Name: Optional. The unique identifier of this participant. Format:
12458	// `projects//locations//conversations//participants/`.
12459	Name string `json:"name,omitempty"`
12460
12461	// Role: Immutable. The role this participant plays in the conversation.
12462	// This field must be set during participant creation and is then
12463	// immutable.
12464	//
12465	// Possible values:
12466	//   "ROLE_UNSPECIFIED" - Participant role not set.
12467	//   "HUMAN_AGENT" - Participant is a human agent.
12468	//   "AUTOMATED_AGENT" - Participant is an automated agent, such as a
12469	// Dialogflow agent.
12470	//   "END_USER" - Participant is an end user that has called or chatted
12471	// with Dialogflow services.
12472	Role string `json:"role,omitempty"`
12473
12474	// SipRecordingMediaLabel: Optional. Label applied to streams
12475	// representing this participant in SIPREC XML metadata and SDP. This is
12476	// used to assign transcriptions from that media stream to this
12477	// participant. This field can be updated.
12478	SipRecordingMediaLabel string `json:"sipRecordingMediaLabel,omitempty"`
12479
12480	// ServerResponse contains the HTTP response code and headers from the
12481	// server.
12482	googleapi.ServerResponse `json:"-"`
12483
12484	// ForceSendFields is a list of field names (e.g. "Name") to
12485	// unconditionally include in API requests. By default, fields with
12486	// empty or default values are omitted from API requests. However, any
12487	// non-pointer, non-interface field appearing in ForceSendFields will be
12488	// sent to the server regardless of whether the field is empty or not.
12489	// This may be used to include empty fields in Patch requests.
12490	ForceSendFields []string `json:"-"`
12491
12492	// NullFields is a list of field names (e.g. "Name") to include in API
12493	// requests with the JSON null value. By default, fields with empty
12494	// values are omitted from API requests. However, any field with an
12495	// empty value appearing in NullFields will be sent to the server as
12496	// null. It is an error if a field in this list has a non-empty value.
12497	// This may be used to include null fields in Patch requests.
12498	NullFields []string `json:"-"`
12499}
12500
12501func (s *GoogleCloudDialogflowV2Participant) MarshalJSON() ([]byte, error) {
12502	type NoMethod GoogleCloudDialogflowV2Participant
12503	raw := NoMethod(*s)
12504	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
12505}
12506
12507// GoogleCloudDialogflowV2QueryInput: Represents the query input. It can
12508// contain either: 1. An audio config which instructs the speech
12509// recognizer how to process the speech audio. 2. A conversational query
12510// in the form of text,. 3. An event that specifies which intent to
12511// trigger.
12512type GoogleCloudDialogflowV2QueryInput struct {
12513	// AudioConfig: Instructs the speech recognizer how to process the
12514	// speech audio.
12515	AudioConfig *GoogleCloudDialogflowV2InputAudioConfig `json:"audioConfig,omitempty"`
12516
12517	// Event: The event to be processed.
12518	Event *GoogleCloudDialogflowV2EventInput `json:"event,omitempty"`
12519
12520	// Text: The natural language text to be processed.
12521	Text *GoogleCloudDialogflowV2TextInput `json:"text,omitempty"`
12522
12523	// ForceSendFields is a list of field names (e.g. "AudioConfig") to
12524	// unconditionally include in API requests. By default, fields with
12525	// empty or default values are omitted from API requests. However, any
12526	// non-pointer, non-interface field appearing in ForceSendFields will be
12527	// sent to the server regardless of whether the field is empty or not.
12528	// This may be used to include empty fields in Patch requests.
12529	ForceSendFields []string `json:"-"`
12530
12531	// NullFields is a list of field names (e.g. "AudioConfig") to include
12532	// in API requests with the JSON null value. By default, fields with
12533	// empty values are omitted from API requests. However, any field with
12534	// an empty value appearing in NullFields will be sent to the server as
12535	// null. It is an error if a field in this list has a non-empty value.
12536	// This may be used to include null fields in Patch requests.
12537	NullFields []string `json:"-"`
12538}
12539
12540func (s *GoogleCloudDialogflowV2QueryInput) MarshalJSON() ([]byte, error) {
12541	type NoMethod GoogleCloudDialogflowV2QueryInput
12542	raw := NoMethod(*s)
12543	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
12544}
12545
12546// GoogleCloudDialogflowV2QueryParameters: Represents the parameters of
12547// the conversational query.
12548type GoogleCloudDialogflowV2QueryParameters struct {
12549	// Contexts: The collection of contexts to be activated before this
12550	// query is executed.
12551	Contexts []*GoogleCloudDialogflowV2Context `json:"contexts,omitempty"`
12552
12553	// GeoLocation: The geo location of this conversational query.
12554	GeoLocation *GoogleTypeLatLng `json:"geoLocation,omitempty"`
12555
12556	// Payload: This field can be used to pass custom data to your webhook.
12557	// Arbitrary JSON objects are supported. If supplied, the value is used
12558	// to populate the
12559	// `WebhookRequest.original_detect_intent_request.payload` field sent to
12560	// your webhook.
12561	Payload googleapi.RawMessage `json:"payload,omitempty"`
12562
12563	// ResetContexts: Specifies whether to delete all contexts in the
12564	// current session before the new ones are activated.
12565	ResetContexts bool `json:"resetContexts,omitempty"`
12566
12567	// SentimentAnalysisRequestConfig: Configures the type of sentiment
12568	// analysis to perform. If not provided, sentiment analysis is not
12569	// performed.
12570	SentimentAnalysisRequestConfig *GoogleCloudDialogflowV2SentimentAnalysisRequestConfig `json:"sentimentAnalysisRequestConfig,omitempty"`
12571
12572	// SessionEntityTypes: Additional session entity types to replace or
12573	// extend developer entity types with. The entity synonyms apply to all
12574	// languages and persist for the session of this query.
12575	SessionEntityTypes []*GoogleCloudDialogflowV2SessionEntityType `json:"sessionEntityTypes,omitempty"`
12576
12577	// TimeZone: The time zone of this conversational query from the time
12578	// zone database (https://www.iana.org/time-zones), e.g.,
12579	// America/New_York, Europe/Paris. If not provided, the time zone
12580	// specified in agent settings is used.
12581	TimeZone string `json:"timeZone,omitempty"`
12582
12583	// WebhookHeaders: This field can be used to pass HTTP headers for a
12584	// webhook call. These headers will be sent to webhook along with the
12585	// headers that have been configured through the Dialogflow web console.
12586	// The headers defined within this field will overwrite the headers
12587	// configured through the Dialogflow console if there is a conflict.
12588	// Header names are case-insensitive. Google's specified headers are not
12589	// allowed. Including: "Host", "Content-Length", "Connection", "From",
12590	// "User-Agent", "Accept-Encoding", "If-Modified-Since",
12591	// "If-None-Match", "X-Forwarded-For", etc.
12592	WebhookHeaders map[string]string `json:"webhookHeaders,omitempty"`
12593
12594	// ForceSendFields is a list of field names (e.g. "Contexts") to
12595	// unconditionally include in API requests. By default, fields with
12596	// empty or default values are omitted from API requests. However, any
12597	// non-pointer, non-interface field appearing in ForceSendFields will be
12598	// sent to the server regardless of whether the field is empty or not.
12599	// This may be used to include empty fields in Patch requests.
12600	ForceSendFields []string `json:"-"`
12601
12602	// NullFields is a list of field names (e.g. "Contexts") to include in
12603	// API requests with the JSON null value. By default, fields with empty
12604	// values are omitted from API requests. However, any field with an
12605	// empty value appearing in NullFields will be sent to the server as
12606	// null. It is an error if a field in this list has a non-empty value.
12607	// This may be used to include null fields in Patch requests.
12608	NullFields []string `json:"-"`
12609}
12610
12611func (s *GoogleCloudDialogflowV2QueryParameters) MarshalJSON() ([]byte, error) {
12612	type NoMethod GoogleCloudDialogflowV2QueryParameters
12613	raw := NoMethod(*s)
12614	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
12615}
12616
12617// GoogleCloudDialogflowV2QueryResult: Represents the result of
12618// conversational query or event processing.
12619type GoogleCloudDialogflowV2QueryResult struct {
12620	// Action: The action name from the matched intent.
12621	Action string `json:"action,omitempty"`
12622
12623	// AllRequiredParamsPresent: This field is set to: - `false` if the
12624	// matched intent has required parameters and not all of the required
12625	// parameter values have been collected. - `true` if all required
12626	// parameter values have been collected, or if the matched intent
12627	// doesn't contain any required parameters.
12628	AllRequiredParamsPresent bool `json:"allRequiredParamsPresent,omitempty"`
12629
12630	// CancelsSlotFilling: Indicates whether the conversational query
12631	// triggers a cancellation for slot filling.
12632	CancelsSlotFilling bool `json:"cancelsSlotFilling,omitempty"`
12633
12634	// DiagnosticInfo: Free-form diagnostic information for the associated
12635	// detect intent request. The fields of this data can change without
12636	// notice, so you should not write code that depends on its structure.
12637	// The data may contain: - webhook call latency - webhook errors
12638	DiagnosticInfo googleapi.RawMessage `json:"diagnosticInfo,omitempty"`
12639
12640	// FulfillmentMessages: The collection of rich messages to present to
12641	// the user.
12642	FulfillmentMessages []*GoogleCloudDialogflowV2IntentMessage `json:"fulfillmentMessages,omitempty"`
12643
12644	// FulfillmentText: The text to be pronounced to the user or shown on
12645	// the screen. Note: This is a legacy field, `fulfillment_messages`
12646	// should be preferred.
12647	FulfillmentText string `json:"fulfillmentText,omitempty"`
12648
12649	// Intent: The intent that matched the conversational query. Some, not
12650	// all fields are filled in this message, including but not limited to:
12651	// `name`, `display_name`, `end_interaction` and `is_fallback`.
12652	Intent *GoogleCloudDialogflowV2Intent `json:"intent,omitempty"`
12653
12654	// IntentDetectionConfidence: The intent detection confidence. Values
12655	// range from 0.0 (completely uncertain) to 1.0 (completely certain).
12656	// This value is for informational purpose only and is only used to help
12657	// match the best intent within the classification threshold. This value
12658	// may change for the same end-user expression at any time due to a
12659	// model retraining or change in implementation. If there are `multiple
12660	// knowledge_answers` messages, this value is set to the greatest
12661	// `knowledgeAnswers.match_confidence` value in the list.
12662	IntentDetectionConfidence float64 `json:"intentDetectionConfidence,omitempty"`
12663
12664	// LanguageCode: The language that was triggered during intent
12665	// detection. See Language Support
12666	// (https://cloud.google.com/dialogflow/docs/reference/language) for a
12667	// list of the currently supported language codes.
12668	LanguageCode string `json:"languageCode,omitempty"`
12669
12670	// OutputContexts: The collection of output contexts. If applicable,
12671	// `output_contexts.parameters` contains entries with name `.original`
12672	// containing the original parameter values before the query.
12673	OutputContexts []*GoogleCloudDialogflowV2Context `json:"outputContexts,omitempty"`
12674
12675	// Parameters: The collection of extracted parameters. Depending on your
12676	// protocol or client library language, this is a map, associative
12677	// array, symbol table, dictionary, or JSON object composed of a
12678	// collection of (MapKey, MapValue) pairs: - MapKey type: string -
12679	// MapKey value: parameter name - MapValue type: - If parameter's entity
12680	// type is a composite entity: map - Else: depending on parameter value
12681	// type, could be one of string, number, boolean, null, list or map -
12682	// MapValue value: - If parameter's entity type is a composite entity:
12683	// map from composite entity property names to property values - Else:
12684	// parameter value
12685	Parameters googleapi.RawMessage `json:"parameters,omitempty"`
12686
12687	// QueryText: The original conversational query text: - If natural
12688	// language text was provided as input, `query_text` contains a copy of
12689	// the input. - If natural language speech audio was provided as input,
12690	// `query_text` contains the speech recognition result. If speech
12691	// recognizer produced multiple alternatives, a particular one is
12692	// picked. - If automatic spell correction is enabled, `query_text` will
12693	// contain the corrected user input.
12694	QueryText string `json:"queryText,omitempty"`
12695
12696	// SentimentAnalysisResult: The sentiment analysis result, which depends
12697	// on the `sentiment_analysis_request_config` specified in the request.
12698	SentimentAnalysisResult *GoogleCloudDialogflowV2SentimentAnalysisResult `json:"sentimentAnalysisResult,omitempty"`
12699
12700	// SpeechRecognitionConfidence: The Speech recognition confidence
12701	// between 0.0 and 1.0. A higher number indicates an estimated greater
12702	// likelihood that the recognized words are correct. The default of 0.0
12703	// is a sentinel value indicating that confidence was not set. This
12704	// field is not guaranteed to be accurate or set. In particular this
12705	// field isn't set for StreamingDetectIntent since the streaming
12706	// endpoint has separate confidence estimates per portion of the audio
12707	// in StreamingRecognitionResult.
12708	SpeechRecognitionConfidence float64 `json:"speechRecognitionConfidence,omitempty"`
12709
12710	// WebhookPayload: If the query was fulfilled by a webhook call, this
12711	// field is set to the value of the `payload` field returned in the
12712	// webhook response.
12713	WebhookPayload googleapi.RawMessage `json:"webhookPayload,omitempty"`
12714
12715	// WebhookSource: If the query was fulfilled by a webhook call, this
12716	// field is set to the value of the `source` field returned in the
12717	// webhook response.
12718	WebhookSource string `json:"webhookSource,omitempty"`
12719
12720	// ForceSendFields is a list of field names (e.g. "Action") to
12721	// unconditionally include in API requests. By default, fields with
12722	// empty or default values are omitted from API requests. However, any
12723	// non-pointer, non-interface field appearing in ForceSendFields will be
12724	// sent to the server regardless of whether the field is empty or not.
12725	// This may be used to include empty fields in Patch requests.
12726	ForceSendFields []string `json:"-"`
12727
12728	// NullFields is a list of field names (e.g. "Action") to include in API
12729	// requests with the JSON null value. By default, fields with empty
12730	// values are omitted from API requests. However, any field with an
12731	// empty value appearing in NullFields will be sent to the server as
12732	// null. It is an error if a field in this list has a non-empty value.
12733	// This may be used to include null fields in Patch requests.
12734	NullFields []string `json:"-"`
12735}
12736
12737func (s *GoogleCloudDialogflowV2QueryResult) MarshalJSON() ([]byte, error) {
12738	type NoMethod GoogleCloudDialogflowV2QueryResult
12739	raw := NoMethod(*s)
12740	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
12741}
12742
12743func (s *GoogleCloudDialogflowV2QueryResult) UnmarshalJSON(data []byte) error {
12744	type NoMethod GoogleCloudDialogflowV2QueryResult
12745	var s1 struct {
12746		IntentDetectionConfidence   gensupport.JSONFloat64 `json:"intentDetectionConfidence"`
12747		SpeechRecognitionConfidence gensupport.JSONFloat64 `json:"speechRecognitionConfidence"`
12748		*NoMethod
12749	}
12750	s1.NoMethod = (*NoMethod)(s)
12751	if err := json.Unmarshal(data, &s1); err != nil {
12752		return err
12753	}
12754	s.IntentDetectionConfidence = float64(s1.IntentDetectionConfidence)
12755	s.SpeechRecognitionConfidence = float64(s1.SpeechRecognitionConfidence)
12756	return nil
12757}
12758
12759// GoogleCloudDialogflowV2ReloadDocumentRequest: Request message for
12760// Documents.ReloadDocument.
12761type GoogleCloudDialogflowV2ReloadDocumentRequest struct {
12762	// ContentUri: Optional. The path of gcs source file for reloading
12763	// document content. For now, only gcs uri is supported. For documents
12764	// stored in Google Cloud Storage, these URIs must have the form
12765	// `gs:///`.
12766	ContentUri string `json:"contentUri,omitempty"`
12767
12768	// ForceSendFields is a list of field names (e.g. "ContentUri") to
12769	// unconditionally include in API requests. By default, fields with
12770	// empty or default values are omitted from API requests. However, any
12771	// non-pointer, non-interface field appearing in ForceSendFields will be
12772	// sent to the server regardless of whether the field is empty or not.
12773	// This may be used to include empty fields in Patch requests.
12774	ForceSendFields []string `json:"-"`
12775
12776	// NullFields is a list of field names (e.g. "ContentUri") to include in
12777	// API requests with the JSON null value. By default, fields with empty
12778	// values are omitted from API requests. However, any field with an
12779	// empty value appearing in NullFields will be sent to the server as
12780	// null. It is an error if a field in this list has a non-empty value.
12781	// This may be used to include null fields in Patch requests.
12782	NullFields []string `json:"-"`
12783}
12784
12785func (s *GoogleCloudDialogflowV2ReloadDocumentRequest) MarshalJSON() ([]byte, error) {
12786	type NoMethod GoogleCloudDialogflowV2ReloadDocumentRequest
12787	raw := NoMethod(*s)
12788	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
12789}
12790
12791// GoogleCloudDialogflowV2RestoreAgentRequest: The request message for
12792// Agents.RestoreAgent.
12793type GoogleCloudDialogflowV2RestoreAgentRequest struct {
12794	// AgentContent: Zip compressed raw byte content for agent.
12795	AgentContent string `json:"agentContent,omitempty"`
12796
12797	// AgentUri: The URI to a Google Cloud Storage file containing the agent
12798	// to restore. Note: The URI must start with "gs://".
12799	AgentUri string `json:"agentUri,omitempty"`
12800
12801	// ForceSendFields is a list of field names (e.g. "AgentContent") to
12802	// unconditionally include in API requests. By default, fields with
12803	// empty or default values are omitted from API requests. However, any
12804	// non-pointer, non-interface field appearing in ForceSendFields will be
12805	// sent to the server regardless of whether the field is empty or not.
12806	// This may be used to include empty fields in Patch requests.
12807	ForceSendFields []string `json:"-"`
12808
12809	// NullFields is a list of field names (e.g. "AgentContent") to include
12810	// in API requests with the JSON null value. By default, fields with
12811	// empty values are omitted from API requests. However, any field with
12812	// an empty value appearing in NullFields will be sent to the server as
12813	// null. It is an error if a field in this list has a non-empty value.
12814	// This may be used to include null fields in Patch requests.
12815	NullFields []string `json:"-"`
12816}
12817
12818func (s *GoogleCloudDialogflowV2RestoreAgentRequest) MarshalJSON() ([]byte, error) {
12819	type NoMethod GoogleCloudDialogflowV2RestoreAgentRequest
12820	raw := NoMethod(*s)
12821	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
12822}
12823
12824// GoogleCloudDialogflowV2SearchAgentsResponse: The response message for
12825// Agents.SearchAgents.
12826type GoogleCloudDialogflowV2SearchAgentsResponse struct {
12827	// Agents: The list of agents. There will be a maximum number of items
12828	// returned based on the page_size field in the request.
12829	Agents []*GoogleCloudDialogflowV2Agent `json:"agents,omitempty"`
12830
12831	// NextPageToken: Token to retrieve the next page of results, or empty
12832	// if there are no more results in the list.
12833	NextPageToken string `json:"nextPageToken,omitempty"`
12834
12835	// ServerResponse contains the HTTP response code and headers from the
12836	// server.
12837	googleapi.ServerResponse `json:"-"`
12838
12839	// ForceSendFields is a list of field names (e.g. "Agents") to
12840	// unconditionally include in API requests. By default, fields with
12841	// empty or default values are omitted from API requests. However, any
12842	// non-pointer, non-interface field appearing in ForceSendFields will be
12843	// sent to the server regardless of whether the field is empty or not.
12844	// This may be used to include empty fields in Patch requests.
12845	ForceSendFields []string `json:"-"`
12846
12847	// NullFields is a list of field names (e.g. "Agents") to include in API
12848	// requests with the JSON null value. By default, fields with empty
12849	// values are omitted from API requests. However, any field with an
12850	// empty value appearing in NullFields will be sent to the server as
12851	// null. It is an error if a field in this list has a non-empty value.
12852	// This may be used to include null fields in Patch requests.
12853	NullFields []string `json:"-"`
12854}
12855
12856func (s *GoogleCloudDialogflowV2SearchAgentsResponse) MarshalJSON() ([]byte, error) {
12857	type NoMethod GoogleCloudDialogflowV2SearchAgentsResponse
12858	raw := NoMethod(*s)
12859	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
12860}
12861
12862// GoogleCloudDialogflowV2Sentiment: The sentiment, such as
12863// positive/negative feeling or association, for a unit of analysis,
12864// such as the query text.
12865type GoogleCloudDialogflowV2Sentiment struct {
12866	// Magnitude: A non-negative number in the [0, +inf) range, which
12867	// represents the absolute magnitude of sentiment, regardless of score
12868	// (positive or negative).
12869	Magnitude float64 `json:"magnitude,omitempty"`
12870
12871	// Score: Sentiment score between -1.0 (negative sentiment) and 1.0
12872	// (positive sentiment).
12873	Score float64 `json:"score,omitempty"`
12874
12875	// ForceSendFields is a list of field names (e.g. "Magnitude") to
12876	// unconditionally include in API requests. By default, fields with
12877	// empty or default values are omitted from API requests. However, any
12878	// non-pointer, non-interface field appearing in ForceSendFields will be
12879	// sent to the server regardless of whether the field is empty or not.
12880	// This may be used to include empty fields in Patch requests.
12881	ForceSendFields []string `json:"-"`
12882
12883	// NullFields is a list of field names (e.g. "Magnitude") to include in
12884	// API requests with the JSON null value. By default, fields with empty
12885	// values are omitted from API requests. However, any field with an
12886	// empty value appearing in NullFields will be sent to the server as
12887	// null. It is an error if a field in this list has a non-empty value.
12888	// This may be used to include null fields in Patch requests.
12889	NullFields []string `json:"-"`
12890}
12891
12892func (s *GoogleCloudDialogflowV2Sentiment) MarshalJSON() ([]byte, error) {
12893	type NoMethod GoogleCloudDialogflowV2Sentiment
12894	raw := NoMethod(*s)
12895	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
12896}
12897
12898func (s *GoogleCloudDialogflowV2Sentiment) UnmarshalJSON(data []byte) error {
12899	type NoMethod GoogleCloudDialogflowV2Sentiment
12900	var s1 struct {
12901		Magnitude gensupport.JSONFloat64 `json:"magnitude"`
12902		Score     gensupport.JSONFloat64 `json:"score"`
12903		*NoMethod
12904	}
12905	s1.NoMethod = (*NoMethod)(s)
12906	if err := json.Unmarshal(data, &s1); err != nil {
12907		return err
12908	}
12909	s.Magnitude = float64(s1.Magnitude)
12910	s.Score = float64(s1.Score)
12911	return nil
12912}
12913
12914// GoogleCloudDialogflowV2SentimentAnalysisRequestConfig: Configures the
12915// types of sentiment analysis to perform.
12916type GoogleCloudDialogflowV2SentimentAnalysisRequestConfig struct {
12917	// AnalyzeQueryTextSentiment: Instructs the service to perform sentiment
12918	// analysis on `query_text`. If not provided, sentiment analysis is not
12919	// performed on `query_text`.
12920	AnalyzeQueryTextSentiment bool `json:"analyzeQueryTextSentiment,omitempty"`
12921
12922	// ForceSendFields is a list of field names (e.g.
12923	// "AnalyzeQueryTextSentiment") to unconditionally include in API
12924	// requests. By default, fields with empty or default values are omitted
12925	// from API requests. However, any non-pointer, non-interface field
12926	// appearing in ForceSendFields will be sent to the server regardless of
12927	// whether the field is empty or not. This may be used to include empty
12928	// fields in Patch requests.
12929	ForceSendFields []string `json:"-"`
12930
12931	// NullFields is a list of field names (e.g.
12932	// "AnalyzeQueryTextSentiment") to include in API requests with the JSON
12933	// null value. By default, fields with empty values are omitted from API
12934	// requests. However, any field with an empty value appearing in
12935	// NullFields will be sent to the server as null. It is an error if a
12936	// field in this list has a non-empty value. This may be used to include
12937	// null fields in Patch requests.
12938	NullFields []string `json:"-"`
12939}
12940
12941func (s *GoogleCloudDialogflowV2SentimentAnalysisRequestConfig) MarshalJSON() ([]byte, error) {
12942	type NoMethod GoogleCloudDialogflowV2SentimentAnalysisRequestConfig
12943	raw := NoMethod(*s)
12944	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
12945}
12946
12947// GoogleCloudDialogflowV2SentimentAnalysisResult: The result of
12948// sentiment analysis. Sentiment analysis inspects user input and
12949// identifies the prevailing subjective opinion, especially to determine
12950// a user's attitude as positive, negative, or neutral. For
12951// Participants.DetectIntent, it needs to be configured in
12952// DetectIntentRequest.query_params. For
12953// Participants.StreamingDetectIntent, it needs to be configured in
12954// StreamingDetectIntentRequest.query_params. And for
12955// Participants.AnalyzeContent and Participants.StreamingAnalyzeContent,
12956// it needs to be configured in
12957// ConversationProfile.human_agent_assistant_config
12958type GoogleCloudDialogflowV2SentimentAnalysisResult struct {
12959	// QueryTextSentiment: The sentiment analysis result for `query_text`.
12960	QueryTextSentiment *GoogleCloudDialogflowV2Sentiment `json:"queryTextSentiment,omitempty"`
12961
12962	// ForceSendFields is a list of field names (e.g. "QueryTextSentiment")
12963	// to unconditionally include in API requests. By default, fields with
12964	// empty or default values are omitted from API requests. However, any
12965	// non-pointer, non-interface field appearing in ForceSendFields will be
12966	// sent to the server regardless of whether the field is empty or not.
12967	// This may be used to include empty fields in Patch requests.
12968	ForceSendFields []string `json:"-"`
12969
12970	// NullFields is a list of field names (e.g. "QueryTextSentiment") to
12971	// include in API requests with the JSON null value. By default, fields
12972	// with empty values are omitted from API requests. However, any field
12973	// with an empty value appearing in NullFields will be sent to the
12974	// server as null. It is an error if a field in this list has a
12975	// non-empty value. This may be used to include null fields in Patch
12976	// requests.
12977	NullFields []string `json:"-"`
12978}
12979
12980func (s *GoogleCloudDialogflowV2SentimentAnalysisResult) MarshalJSON() ([]byte, error) {
12981	type NoMethod GoogleCloudDialogflowV2SentimentAnalysisResult
12982	raw := NoMethod(*s)
12983	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
12984}
12985
12986// GoogleCloudDialogflowV2SessionEntityType: A session represents a
12987// conversation between a Dialogflow agent and an end-user. You can
12988// create special entities, called session entities, during a session.
12989// Session entities can extend or replace custom entity types and only
12990// exist during the session that they were created for. All session
12991// data, including session entities, is stored by Dialogflow for 20
12992// minutes. For more information, see the session entity guide
12993// (https://cloud.google.com/dialogflow/docs/entities-session).
12994type GoogleCloudDialogflowV2SessionEntityType struct {
12995	// Entities: Required. The collection of entities associated with this
12996	// session entity type.
12997	Entities []*GoogleCloudDialogflowV2EntityTypeEntity `json:"entities,omitempty"`
12998
12999	// EntityOverrideMode: Required. Indicates whether the additional data
13000	// should override or supplement the custom entity type definition.
13001	//
13002	// Possible values:
13003	//   "ENTITY_OVERRIDE_MODE_UNSPECIFIED" - Not specified. This value
13004	// should be never used.
13005	//   "ENTITY_OVERRIDE_MODE_OVERRIDE" - The collection of session
13006	// entities overrides the collection of entities in the corresponding
13007	// custom entity type.
13008	//   "ENTITY_OVERRIDE_MODE_SUPPLEMENT" - The collection of session
13009	// entities extends the collection of entities in the corresponding
13010	// custom entity type. Note: Even in this override mode calls to
13011	// `ListSessionEntityTypes`, `GetSessionEntityType`,
13012	// `CreateSessionEntityType` and `UpdateSessionEntityType` only return
13013	// the additional entities added in this session entity type. If you
13014	// want to get the supplemented list, please call
13015	// EntityTypes.GetEntityType on the custom entity type and merge.
13016	EntityOverrideMode string `json:"entityOverrideMode,omitempty"`
13017
13018	// Name: Required. The unique identifier of this session entity type.
13019	// Format: `projects//agent/sessions//entityTypes/`, or
13020	// `projects//agent/environments//users//sessions//entityTypes/`. If
13021	// `Environment ID` is not specified, we assume default 'draft'
13022	// environment. If `User ID` is not specified, we assume default '-'
13023	// user. `` must be the display name of an existing entity type in the
13024	// same agent that will be overridden or supplemented.
13025	Name string `json:"name,omitempty"`
13026
13027	// ServerResponse contains the HTTP response code and headers from the
13028	// server.
13029	googleapi.ServerResponse `json:"-"`
13030
13031	// ForceSendFields is a list of field names (e.g. "Entities") to
13032	// unconditionally include in API requests. By default, fields with
13033	// empty or default values are omitted from API requests. However, any
13034	// non-pointer, non-interface field appearing in ForceSendFields will be
13035	// sent to the server regardless of whether the field is empty or not.
13036	// This may be used to include empty fields in Patch requests.
13037	ForceSendFields []string `json:"-"`
13038
13039	// NullFields is a list of field names (e.g. "Entities") to include in
13040	// API requests with the JSON null value. By default, fields with empty
13041	// values are omitted from API requests. However, any field with an
13042	// empty value appearing in NullFields will be sent to the server as
13043	// null. It is an error if a field in this list has a non-empty value.
13044	// This may be used to include null fields in Patch requests.
13045	NullFields []string `json:"-"`
13046}
13047
13048func (s *GoogleCloudDialogflowV2SessionEntityType) MarshalJSON() ([]byte, error) {
13049	type NoMethod GoogleCloudDialogflowV2SessionEntityType
13050	raw := NoMethod(*s)
13051	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
13052}
13053
13054// GoogleCloudDialogflowV2SpeechContext: Hints for the speech recognizer
13055// to help with recognition in a specific conversation state.
13056type GoogleCloudDialogflowV2SpeechContext struct {
13057	// Boost: Optional. Boost for this context compared to other contexts: *
13058	// If the boost is positive, Dialogflow will increase the probability
13059	// that the phrases in this context are recognized over similar sounding
13060	// phrases. * If the boost is unspecified or non-positive, Dialogflow
13061	// will not apply any boost. Dialogflow recommends that you use boosts
13062	// in the range (0, 20] and that you find a value that fits your use
13063	// case with binary search.
13064	Boost float64 `json:"boost,omitempty"`
13065
13066	// Phrases: Optional. A list of strings containing words and phrases
13067	// that the speech recognizer should recognize with higher likelihood.
13068	// This list can be used to: * improve accuracy for words and phrases
13069	// you expect the user to say, e.g. typical commands for your Dialogflow
13070	// agent * add additional words to the speech recognizer vocabulary *
13071	// ... See the Cloud Speech documentation
13072	// (https://cloud.google.com/speech-to-text/quotas) for usage limits.
13073	Phrases []string `json:"phrases,omitempty"`
13074
13075	// ForceSendFields is a list of field names (e.g. "Boost") to
13076	// unconditionally include in API requests. By default, fields with
13077	// empty or default values are omitted from API requests. However, any
13078	// non-pointer, non-interface field appearing in ForceSendFields will be
13079	// sent to the server regardless of whether the field is empty or not.
13080	// This may be used to include empty fields in Patch requests.
13081	ForceSendFields []string `json:"-"`
13082
13083	// NullFields is a list of field names (e.g. "Boost") to include in API
13084	// requests with the JSON null value. By default, fields with empty
13085	// values are omitted from API requests. However, any field with an
13086	// empty value appearing in NullFields will be sent to the server as
13087	// null. It is an error if a field in this list has a non-empty value.
13088	// This may be used to include null fields in Patch requests.
13089	NullFields []string `json:"-"`
13090}
13091
13092func (s *GoogleCloudDialogflowV2SpeechContext) MarshalJSON() ([]byte, error) {
13093	type NoMethod GoogleCloudDialogflowV2SpeechContext
13094	raw := NoMethod(*s)
13095	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
13096}
13097
13098func (s *GoogleCloudDialogflowV2SpeechContext) UnmarshalJSON(data []byte) error {
13099	type NoMethod GoogleCloudDialogflowV2SpeechContext
13100	var s1 struct {
13101		Boost gensupport.JSONFloat64 `json:"boost"`
13102		*NoMethod
13103	}
13104	s1.NoMethod = (*NoMethod)(s)
13105	if err := json.Unmarshal(data, &s1); err != nil {
13106		return err
13107	}
13108	s.Boost = float64(s1.Boost)
13109	return nil
13110}
13111
13112// GoogleCloudDialogflowV2SpeechToTextConfig: Configures speech
13113// transcription for ConversationProfile.
13114type GoogleCloudDialogflowV2SpeechToTextConfig struct {
13115	// SpeechModelVariant: Optional. The speech model used in speech to
13116	// text. `SPEECH_MODEL_VARIANT_UNSPECIFIED`, `USE_BEST_AVAILABLE` will
13117	// be treated as `USE_ENHANCED`. It can be overridden in
13118	// AnalyzeContentRequest and StreamingAnalyzeContentRequest request.
13119	//
13120	// Possible values:
13121	//   "SPEECH_MODEL_VARIANT_UNSPECIFIED" - No model variant specified. In
13122	// this case Dialogflow defaults to USE_BEST_AVAILABLE.
13123	//   "USE_BEST_AVAILABLE" - Use the best available variant of the Speech
13124	// model that the caller is eligible for. Please see the [Dialogflow
13125	// docs](https://cloud.google.com/dialogflow/docs/data-logging) for how
13126	// to make your project eligible for enhanced models.
13127	//   "USE_STANDARD" - Use standard model variant even if an enhanced
13128	// model is available. See the [Cloud Speech
13129	// documentation](https://cloud.google.com/speech-to-text/docs/enhanced-m
13130	// odels) for details about enhanced models.
13131	//   "USE_ENHANCED" - Use an enhanced model variant: * If an enhanced
13132	// variant does not exist for the given model and request language,
13133	// Dialogflow falls back to the standard variant. The [Cloud Speech
13134	// documentation](https://cloud.google.com/speech-to-text/docs/enhanced-m
13135	// odels) describes which models have enhanced variants. * If the API
13136	// caller isn't eligible for enhanced models, Dialogflow returns an
13137	// error. Please see the [Dialogflow
13138	// docs](https://cloud.google.com/dialogflow/docs/data-logging) for how
13139	// to make your project eligible.
13140	SpeechModelVariant string `json:"speechModelVariant,omitempty"`
13141
13142	// ForceSendFields is a list of field names (e.g. "SpeechModelVariant")
13143	// to unconditionally include in API requests. By default, fields with
13144	// empty or default values are omitted from API requests. However, any
13145	// non-pointer, non-interface field appearing in ForceSendFields will be
13146	// sent to the server regardless of whether the field is empty or not.
13147	// This may be used to include empty fields in Patch requests.
13148	ForceSendFields []string `json:"-"`
13149
13150	// NullFields is a list of field names (e.g. "SpeechModelVariant") to
13151	// include in API requests with the JSON null value. By default, fields
13152	// with empty values are omitted from API requests. However, any field
13153	// with an empty value appearing in NullFields will be sent to the
13154	// server as null. It is an error if a field in this list has a
13155	// non-empty value. This may be used to include null fields in Patch
13156	// requests.
13157	NullFields []string `json:"-"`
13158}
13159
13160func (s *GoogleCloudDialogflowV2SpeechToTextConfig) MarshalJSON() ([]byte, error) {
13161	type NoMethod GoogleCloudDialogflowV2SpeechToTextConfig
13162	raw := NoMethod(*s)
13163	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
13164}
13165
13166// GoogleCloudDialogflowV2SuggestArticlesRequest: The request message
13167// for Participants.SuggestArticles.
13168type GoogleCloudDialogflowV2SuggestArticlesRequest struct {
13169	// ContextSize: Max number of messages prior to and including
13170	// latest_message to use as context when compiling the suggestion. By
13171	// default 20 and at most 50.
13172	ContextSize int64 `json:"contextSize,omitempty"`
13173
13174	// LatestMessage: The name of the latest conversation message to compile
13175	// suggestion for. If empty, it will be the latest message of the
13176	// conversation. Format:
13177	// `projects//locations//conversations//messages/`.
13178	LatestMessage string `json:"latestMessage,omitempty"`
13179
13180	// ForceSendFields is a list of field names (e.g. "ContextSize") to
13181	// unconditionally include in API requests. By default, fields with
13182	// empty or default values are omitted from API requests. However, any
13183	// non-pointer, non-interface field appearing in ForceSendFields will be
13184	// sent to the server regardless of whether the field is empty or not.
13185	// This may be used to include empty fields in Patch requests.
13186	ForceSendFields []string `json:"-"`
13187
13188	// NullFields is a list of field names (e.g. "ContextSize") to include
13189	// in API requests with the JSON null value. By default, fields with
13190	// empty values are omitted from API requests. However, any field with
13191	// an empty value appearing in NullFields will be sent to the server as
13192	// null. It is an error if a field in this list has a non-empty value.
13193	// This may be used to include null fields in Patch requests.
13194	NullFields []string `json:"-"`
13195}
13196
13197func (s *GoogleCloudDialogflowV2SuggestArticlesRequest) MarshalJSON() ([]byte, error) {
13198	type NoMethod GoogleCloudDialogflowV2SuggestArticlesRequest
13199	raw := NoMethod(*s)
13200	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
13201}
13202
13203// GoogleCloudDialogflowV2SuggestArticlesResponse: The response message
13204// for Participants.SuggestArticles.
13205type GoogleCloudDialogflowV2SuggestArticlesResponse struct {
13206	// ArticleAnswers: Articles ordered by score in descending order.
13207	ArticleAnswers []*GoogleCloudDialogflowV2ArticleAnswer `json:"articleAnswers,omitempty"`
13208
13209	// ContextSize: Number of messages prior to and including latest_message
13210	// to compile the suggestion. It may be smaller than the
13211	// SuggestArticlesRequest.context_size field in the request if there
13212	// aren't that many messages in the conversation.
13213	ContextSize int64 `json:"contextSize,omitempty"`
13214
13215	// LatestMessage: The name of the latest conversation message used to
13216	// compile suggestion for. Format:
13217	// `projects//locations//conversations//messages/`.
13218	LatestMessage string `json:"latestMessage,omitempty"`
13219
13220	// ServerResponse contains the HTTP response code and headers from the
13221	// server.
13222	googleapi.ServerResponse `json:"-"`
13223
13224	// ForceSendFields is a list of field names (e.g. "ArticleAnswers") to
13225	// unconditionally include in API requests. By default, fields with
13226	// empty or default values are omitted from API requests. However, any
13227	// non-pointer, non-interface field appearing in ForceSendFields will be
13228	// sent to the server regardless of whether the field is empty or not.
13229	// This may be used to include empty fields in Patch requests.
13230	ForceSendFields []string `json:"-"`
13231
13232	// NullFields is a list of field names (e.g. "ArticleAnswers") to
13233	// include in API requests with the JSON null value. By default, fields
13234	// with empty values are omitted from API requests. However, any field
13235	// with an empty value appearing in NullFields will be sent to the
13236	// server as null. It is an error if a field in this list has a
13237	// non-empty value. This may be used to include null fields in Patch
13238	// requests.
13239	NullFields []string `json:"-"`
13240}
13241
13242func (s *GoogleCloudDialogflowV2SuggestArticlesResponse) MarshalJSON() ([]byte, error) {
13243	type NoMethod GoogleCloudDialogflowV2SuggestArticlesResponse
13244	raw := NoMethod(*s)
13245	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
13246}
13247
13248// GoogleCloudDialogflowV2SuggestFaqAnswersRequest: The request message
13249// for Participants.SuggestFaqAnswers.
13250type GoogleCloudDialogflowV2SuggestFaqAnswersRequest struct {
13251	// ContextSize: Max number of messages prior to and including
13252	// [latest_message] to use as context when compiling the suggestion. By
13253	// default 20 and at most 50.
13254	ContextSize int64 `json:"contextSize,omitempty"`
13255
13256	// LatestMessage: The name of the latest conversation message to compile
13257	// suggestion for. If empty, it will be the latest message of the
13258	// conversation. Format:
13259	// `projects//locations//conversations//messages/`.
13260	LatestMessage string `json:"latestMessage,omitempty"`
13261
13262	// ForceSendFields is a list of field names (e.g. "ContextSize") to
13263	// unconditionally include in API requests. By default, fields with
13264	// empty or default values are omitted from API requests. However, any
13265	// non-pointer, non-interface field appearing in ForceSendFields will be
13266	// sent to the server regardless of whether the field is empty or not.
13267	// This may be used to include empty fields in Patch requests.
13268	ForceSendFields []string `json:"-"`
13269
13270	// NullFields is a list of field names (e.g. "ContextSize") to include
13271	// in API requests with the JSON null value. By default, fields with
13272	// empty values are omitted from API requests. However, any field with
13273	// an empty value appearing in NullFields will be sent to the server as
13274	// null. It is an error if a field in this list has a non-empty value.
13275	// This may be used to include null fields in Patch requests.
13276	NullFields []string `json:"-"`
13277}
13278
13279func (s *GoogleCloudDialogflowV2SuggestFaqAnswersRequest) MarshalJSON() ([]byte, error) {
13280	type NoMethod GoogleCloudDialogflowV2SuggestFaqAnswersRequest
13281	raw := NoMethod(*s)
13282	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
13283}
13284
13285// GoogleCloudDialogflowV2SuggestFaqAnswersResponse: The request message
13286// for Participants.SuggestFaqAnswers.
13287type GoogleCloudDialogflowV2SuggestFaqAnswersResponse struct {
13288	// ContextSize: Number of messages prior to and including latest_message
13289	// to compile the suggestion. It may be smaller than the
13290	// SuggestFaqAnswersRequest.context_size field in the request if there
13291	// aren't that many messages in the conversation.
13292	ContextSize int64 `json:"contextSize,omitempty"`
13293
13294	// FaqAnswers: Answers extracted from FAQ documents.
13295	FaqAnswers []*GoogleCloudDialogflowV2FaqAnswer `json:"faqAnswers,omitempty"`
13296
13297	// LatestMessage: The name of the latest conversation message used to
13298	// compile suggestion for. Format:
13299	// `projects//locations//conversations//messages/`.
13300	LatestMessage string `json:"latestMessage,omitempty"`
13301
13302	// ServerResponse contains the HTTP response code and headers from the
13303	// server.
13304	googleapi.ServerResponse `json:"-"`
13305
13306	// ForceSendFields is a list of field names (e.g. "ContextSize") to
13307	// unconditionally include in API requests. By default, fields with
13308	// empty or default values are omitted from API requests. However, any
13309	// non-pointer, non-interface field appearing in ForceSendFields will be
13310	// sent to the server regardless of whether the field is empty or not.
13311	// This may be used to include empty fields in Patch requests.
13312	ForceSendFields []string `json:"-"`
13313
13314	// NullFields is a list of field names (e.g. "ContextSize") to include
13315	// in API requests with the JSON null value. By default, fields with
13316	// empty values are omitted from API requests. However, any field with
13317	// an empty value appearing in NullFields will be sent to the server as
13318	// null. It is an error if a field in this list has a non-empty value.
13319	// This may be used to include null fields in Patch requests.
13320	NullFields []string `json:"-"`
13321}
13322
13323func (s *GoogleCloudDialogflowV2SuggestFaqAnswersResponse) MarshalJSON() ([]byte, error) {
13324	type NoMethod GoogleCloudDialogflowV2SuggestFaqAnswersResponse
13325	raw := NoMethod(*s)
13326	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
13327}
13328
13329// GoogleCloudDialogflowV2SuggestionFeature: The type of Human Agent
13330// Assistant API suggestion to perform, and the maximum number of
13331// results to return for that type. Multiple `Feature` objects can be
13332// specified in the `features` list.
13333type GoogleCloudDialogflowV2SuggestionFeature struct {
13334	// Type: Type of Human Agent Assistant API feature to request.
13335	//
13336	// Possible values:
13337	//   "TYPE_UNSPECIFIED" - Unspecified feature type.
13338	//   "ARTICLE_SUGGESTION" - Run article suggestion model.
13339	//   "FAQ" - Run FAQ model.
13340	Type string `json:"type,omitempty"`
13341
13342	// ForceSendFields is a list of field names (e.g. "Type") to
13343	// unconditionally include in API requests. By default, fields with
13344	// empty or default values are omitted from API requests. However, any
13345	// non-pointer, non-interface field appearing in ForceSendFields will be
13346	// sent to the server regardless of whether the field is empty or not.
13347	// This may be used to include empty fields in Patch requests.
13348	ForceSendFields []string `json:"-"`
13349
13350	// NullFields is a list of field names (e.g. "Type") to include in API
13351	// requests with the JSON null value. By default, fields with empty
13352	// values are omitted from API requests. However, any field with an
13353	// empty value appearing in NullFields will be sent to the server as
13354	// null. It is an error if a field in this list has a non-empty value.
13355	// This may be used to include null fields in Patch requests.
13356	NullFields []string `json:"-"`
13357}
13358
13359func (s *GoogleCloudDialogflowV2SuggestionFeature) MarshalJSON() ([]byte, error) {
13360	type NoMethod GoogleCloudDialogflowV2SuggestionFeature
13361	raw := NoMethod(*s)
13362	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
13363}
13364
13365// GoogleCloudDialogflowV2SuggestionResult: One response of different
13366// type of suggestion response which is used in the response of
13367// Participants.AnalyzeContent and Participants.AnalyzeContent, as well
13368// as HumanAgentAssistantEvent.
13369type GoogleCloudDialogflowV2SuggestionResult struct {
13370	// Error: Error status if the request failed.
13371	Error *GoogleRpcStatus `json:"error,omitempty"`
13372
13373	// SuggestArticlesResponse: SuggestArticlesResponse if request is for
13374	// ARTICLE_SUGGESTION.
13375	SuggestArticlesResponse *GoogleCloudDialogflowV2SuggestArticlesResponse `json:"suggestArticlesResponse,omitempty"`
13376
13377	// SuggestFaqAnswersResponse: SuggestFaqAnswersResponse if request is
13378	// for FAQ_ANSWER.
13379	SuggestFaqAnswersResponse *GoogleCloudDialogflowV2SuggestFaqAnswersResponse `json:"suggestFaqAnswersResponse,omitempty"`
13380
13381	// ForceSendFields is a list of field names (e.g. "Error") to
13382	// unconditionally include in API requests. By default, fields with
13383	// empty or default values are omitted from API requests. However, any
13384	// non-pointer, non-interface field appearing in ForceSendFields will be
13385	// sent to the server regardless of whether the field is empty or not.
13386	// This may be used to include empty fields in Patch requests.
13387	ForceSendFields []string `json:"-"`
13388
13389	// NullFields is a list of field names (e.g. "Error") to include in API
13390	// requests with the JSON null value. By default, fields with empty
13391	// values are omitted from API requests. However, any field with an
13392	// empty value appearing in NullFields will be sent to the server as
13393	// null. It is an error if a field in this list has a non-empty value.
13394	// This may be used to include null fields in Patch requests.
13395	NullFields []string `json:"-"`
13396}
13397
13398func (s *GoogleCloudDialogflowV2SuggestionResult) MarshalJSON() ([]byte, error) {
13399	type NoMethod GoogleCloudDialogflowV2SuggestionResult
13400	raw := NoMethod(*s)
13401	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
13402}
13403
13404// GoogleCloudDialogflowV2SynthesizeSpeechConfig: Configuration of how
13405// speech should be synthesized.
13406type GoogleCloudDialogflowV2SynthesizeSpeechConfig struct {
13407	// EffectsProfileId: Optional. An identifier which selects 'audio
13408	// effects' profiles that are applied on (post synthesized) text to
13409	// speech. Effects are applied on top of each other in the order they
13410	// are given.
13411	EffectsProfileId []string `json:"effectsProfileId,omitempty"`
13412
13413	// Pitch: Optional. Speaking pitch, in the range [-20.0, 20.0]. 20 means
13414	// increase 20 semitones from the original pitch. -20 means decrease 20
13415	// semitones from the original pitch.
13416	Pitch float64 `json:"pitch,omitempty"`
13417
13418	// SpeakingRate: Optional. Speaking rate/speed, in the range [0.25,
13419	// 4.0]. 1.0 is the normal native speed supported by the specific voice.
13420	// 2.0 is twice as fast, and 0.5 is half as fast. If unset(0.0),
13421	// defaults to the native 1.0 speed. Any other values < 0.25 or > 4.0
13422	// will return an error.
13423	SpeakingRate float64 `json:"speakingRate,omitempty"`
13424
13425	// Voice: Optional. The desired voice of the synthesized audio.
13426	Voice *GoogleCloudDialogflowV2VoiceSelectionParams `json:"voice,omitempty"`
13427
13428	// VolumeGainDb: Optional. Volume gain (in dB) of the normal native
13429	// volume supported by the specific voice, in the range [-96.0, 16.0].
13430	// If unset, or set to a value of 0.0 (dB), will play at normal native
13431	// signal amplitude. A value of -6.0 (dB) will play at approximately
13432	// half the amplitude of the normal native signal amplitude. A value of
13433	// +6.0 (dB) will play at approximately twice the amplitude of the
13434	// normal native signal amplitude. We strongly recommend not to exceed
13435	// +10 (dB) as there's usually no effective increase in loudness for any
13436	// value greater than that.
13437	VolumeGainDb float64 `json:"volumeGainDb,omitempty"`
13438
13439	// ForceSendFields is a list of field names (e.g. "EffectsProfileId") to
13440	// unconditionally include in API requests. By default, fields with
13441	// empty or default values are omitted from API requests. However, any
13442	// non-pointer, non-interface field appearing in ForceSendFields will be
13443	// sent to the server regardless of whether the field is empty or not.
13444	// This may be used to include empty fields in Patch requests.
13445	ForceSendFields []string `json:"-"`
13446
13447	// NullFields is a list of field names (e.g. "EffectsProfileId") to
13448	// include in API requests with the JSON null value. By default, fields
13449	// with empty values are omitted from API requests. However, any field
13450	// with an empty value appearing in NullFields will be sent to the
13451	// server as null. It is an error if a field in this list has a
13452	// non-empty value. This may be used to include null fields in Patch
13453	// requests.
13454	NullFields []string `json:"-"`
13455}
13456
13457func (s *GoogleCloudDialogflowV2SynthesizeSpeechConfig) MarshalJSON() ([]byte, error) {
13458	type NoMethod GoogleCloudDialogflowV2SynthesizeSpeechConfig
13459	raw := NoMethod(*s)
13460	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
13461}
13462
13463func (s *GoogleCloudDialogflowV2SynthesizeSpeechConfig) UnmarshalJSON(data []byte) error {
13464	type NoMethod GoogleCloudDialogflowV2SynthesizeSpeechConfig
13465	var s1 struct {
13466		Pitch        gensupport.JSONFloat64 `json:"pitch"`
13467		SpeakingRate gensupport.JSONFloat64 `json:"speakingRate"`
13468		VolumeGainDb gensupport.JSONFloat64 `json:"volumeGainDb"`
13469		*NoMethod
13470	}
13471	s1.NoMethod = (*NoMethod)(s)
13472	if err := json.Unmarshal(data, &s1); err != nil {
13473		return err
13474	}
13475	s.Pitch = float64(s1.Pitch)
13476	s.SpeakingRate = float64(s1.SpeakingRate)
13477	s.VolumeGainDb = float64(s1.VolumeGainDb)
13478	return nil
13479}
13480
13481// GoogleCloudDialogflowV2TextInput: Represents the natural language
13482// text to be processed.
13483type GoogleCloudDialogflowV2TextInput struct {
13484	// LanguageCode: Required. The language of this conversational query.
13485	// See Language Support
13486	// (https://cloud.google.com/dialogflow/docs/reference/language) for a
13487	// list of the currently supported language codes. Note that queries in
13488	// the same session do not necessarily need to specify the same
13489	// language.
13490	LanguageCode string `json:"languageCode,omitempty"`
13491
13492	// Text: Required. The UTF-8 encoded natural language text to be
13493	// processed. Text length must not exceed 256 characters.
13494	Text string `json:"text,omitempty"`
13495
13496	// ForceSendFields is a list of field names (e.g. "LanguageCode") to
13497	// unconditionally include in API requests. By default, fields with
13498	// empty or default values are omitted from API requests. However, any
13499	// non-pointer, non-interface field appearing in ForceSendFields will be
13500	// sent to the server regardless of whether the field is empty or not.
13501	// This may be used to include empty fields in Patch requests.
13502	ForceSendFields []string `json:"-"`
13503
13504	// NullFields is a list of field names (e.g. "LanguageCode") to include
13505	// in API requests with the JSON null value. By default, fields with
13506	// empty values are omitted from API requests. However, any field with
13507	// an empty value appearing in NullFields will be sent to the server as
13508	// null. It is an error if a field in this list has a non-empty value.
13509	// This may be used to include null fields in Patch requests.
13510	NullFields []string `json:"-"`
13511}
13512
13513func (s *GoogleCloudDialogflowV2TextInput) MarshalJSON() ([]byte, error) {
13514	type NoMethod GoogleCloudDialogflowV2TextInput
13515	raw := NoMethod(*s)
13516	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
13517}
13518
13519// GoogleCloudDialogflowV2TextToSpeechSettings: Instructs the speech
13520// synthesizer on how to generate the output audio content.
13521type GoogleCloudDialogflowV2TextToSpeechSettings struct {
13522	// EnableTextToSpeech: Optional. Indicates whether text to speech is
13523	// enabled. Even when this field is false, other settings in this proto
13524	// are still retained.
13525	EnableTextToSpeech bool `json:"enableTextToSpeech,omitempty"`
13526
13527	// OutputAudioEncoding: Required. Audio encoding of the synthesized
13528	// audio content.
13529	//
13530	// Possible values:
13531	//   "OUTPUT_AUDIO_ENCODING_UNSPECIFIED" - Not specified.
13532	//   "OUTPUT_AUDIO_ENCODING_LINEAR_16" - Uncompressed 16-bit signed
13533	// little-endian samples (Linear PCM). Audio content returned as
13534	// LINEAR16 also contains a WAV header.
13535	//   "OUTPUT_AUDIO_ENCODING_MP3" - MP3 audio at 32kbps.
13536	//   "OUTPUT_AUDIO_ENCODING_MP3_64_KBPS" - MP3 audio at 64kbps.
13537	//   "OUTPUT_AUDIO_ENCODING_OGG_OPUS" - Opus encoded audio wrapped in an
13538	// ogg container. The result will be a file which can be played natively
13539	// on Android, and in browsers (at least Chrome and Firefox). The
13540	// quality of the encoding is considerably higher than MP3 while using
13541	// approximately the same bitrate.
13542	//   "OUTPUT_AUDIO_ENCODING_MULAW" - 8-bit samples that compand 14-bit
13543	// audio samples using G.711 PCMU/mu-law.
13544	OutputAudioEncoding string `json:"outputAudioEncoding,omitempty"`
13545
13546	// SampleRateHertz: Optional. The synthesis sample rate (in hertz) for
13547	// this audio. If not provided, then the synthesizer will use the
13548	// default sample rate based on the audio encoding. If this is different
13549	// from the voice's natural sample rate, then the synthesizer will honor
13550	// this request by converting to the desired sample rate (which might
13551	// result in worse audio quality).
13552	SampleRateHertz int64 `json:"sampleRateHertz,omitempty"`
13553
13554	// SynthesizeSpeechConfigs: Optional. Configuration of how speech should
13555	// be synthesized, mapping from language
13556	// (https://cloud.google.com/dialogflow/docs/reference/language) to
13557	// SynthesizeSpeechConfig.
13558	SynthesizeSpeechConfigs map[string]GoogleCloudDialogflowV2SynthesizeSpeechConfig `json:"synthesizeSpeechConfigs,omitempty"`
13559
13560	// ForceSendFields is a list of field names (e.g. "EnableTextToSpeech")
13561	// to unconditionally include in API requests. By default, fields with
13562	// empty or default values are omitted from API requests. However, any
13563	// non-pointer, non-interface field appearing in ForceSendFields will be
13564	// sent to the server regardless of whether the field is empty or not.
13565	// This may be used to include empty fields in Patch requests.
13566	ForceSendFields []string `json:"-"`
13567
13568	// NullFields is a list of field names (e.g. "EnableTextToSpeech") to
13569	// include in API requests with the JSON null value. By default, fields
13570	// with empty values are omitted from API requests. However, any field
13571	// with an empty value appearing in NullFields will be sent to the
13572	// server as null. It is an error if a field in this list has a
13573	// non-empty value. This may be used to include null fields in Patch
13574	// requests.
13575	NullFields []string `json:"-"`
13576}
13577
13578func (s *GoogleCloudDialogflowV2TextToSpeechSettings) MarshalJSON() ([]byte, error) {
13579	type NoMethod GoogleCloudDialogflowV2TextToSpeechSettings
13580	raw := NoMethod(*s)
13581	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
13582}
13583
13584// GoogleCloudDialogflowV2TrainAgentRequest: The request message for
13585// Agents.TrainAgent.
13586type GoogleCloudDialogflowV2TrainAgentRequest struct {
13587}
13588
13589// GoogleCloudDialogflowV2ValidationError: Represents a single
13590// validation error.
13591type GoogleCloudDialogflowV2ValidationError struct {
13592	// Entries: The names of the entries that the error is associated with.
13593	// Format: - "projects//agent", if the error is associated with the
13594	// entire agent. - "projects//agent/intents/", if the error is
13595	// associated with certain intents. -
13596	// "projects//agent/intents//trainingPhrases/", if the error is
13597	// associated with certain intent training phrases. -
13598	// "projects//agent/intents//parameters/", if the error is associated
13599	// with certain intent parameters. - "projects//agent/entities/", if the
13600	// error is associated with certain entities.
13601	Entries []string `json:"entries,omitempty"`
13602
13603	// ErrorMessage: The detailed error message.
13604	ErrorMessage string `json:"errorMessage,omitempty"`
13605
13606	// Severity: The severity of the error.
13607	//
13608	// Possible values:
13609	//   "SEVERITY_UNSPECIFIED" - Not specified. This value should never be
13610	// used.
13611	//   "INFO" - The agent doesn't follow Dialogflow best practices.
13612	//   "WARNING" - The agent may not behave as expected.
13613	//   "ERROR" - The agent may experience partial failures.
13614	//   "CRITICAL" - The agent may completely fail.
13615	Severity string `json:"severity,omitempty"`
13616
13617	// ForceSendFields is a list of field names (e.g. "Entries") to
13618	// unconditionally include in API requests. By default, fields with
13619	// empty or default values are omitted from API requests. However, any
13620	// non-pointer, non-interface field appearing in ForceSendFields will be
13621	// sent to the server regardless of whether the field is empty or not.
13622	// This may be used to include empty fields in Patch requests.
13623	ForceSendFields []string `json:"-"`
13624
13625	// NullFields is a list of field names (e.g. "Entries") to include in
13626	// API requests with the JSON null value. By default, fields with empty
13627	// values are omitted from API requests. However, any field with an
13628	// empty value appearing in NullFields will be sent to the server as
13629	// null. It is an error if a field in this list has a non-empty value.
13630	// This may be used to include null fields in Patch requests.
13631	NullFields []string `json:"-"`
13632}
13633
13634func (s *GoogleCloudDialogflowV2ValidationError) MarshalJSON() ([]byte, error) {
13635	type NoMethod GoogleCloudDialogflowV2ValidationError
13636	raw := NoMethod(*s)
13637	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
13638}
13639
13640// GoogleCloudDialogflowV2ValidationResult: Represents the output of
13641// agent validation.
13642type GoogleCloudDialogflowV2ValidationResult struct {
13643	// ValidationErrors: Contains all validation errors.
13644	ValidationErrors []*GoogleCloudDialogflowV2ValidationError `json:"validationErrors,omitempty"`
13645
13646	// ServerResponse contains the HTTP response code and headers from the
13647	// server.
13648	googleapi.ServerResponse `json:"-"`
13649
13650	// ForceSendFields is a list of field names (e.g. "ValidationErrors") to
13651	// unconditionally include in API requests. By default, fields with
13652	// empty or default values are omitted from API requests. However, any
13653	// non-pointer, non-interface field appearing in ForceSendFields will be
13654	// sent to the server regardless of whether the field is empty or not.
13655	// This may be used to include empty fields in Patch requests.
13656	ForceSendFields []string `json:"-"`
13657
13658	// NullFields is a list of field names (e.g. "ValidationErrors") to
13659	// include in API requests with the JSON null value. By default, fields
13660	// with empty values are omitted from API requests. However, any field
13661	// with an empty value appearing in NullFields will be sent to the
13662	// server as null. It is an error if a field in this list has a
13663	// non-empty value. This may be used to include null fields in Patch
13664	// requests.
13665	NullFields []string `json:"-"`
13666}
13667
13668func (s *GoogleCloudDialogflowV2ValidationResult) MarshalJSON() ([]byte, error) {
13669	type NoMethod GoogleCloudDialogflowV2ValidationResult
13670	raw := NoMethod(*s)
13671	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
13672}
13673
13674// GoogleCloudDialogflowV2Version: You can create multiple versions of
13675// your agent and publish them to separate environments. When you edit
13676// an agent, you are editing the draft agent. At any point, you can save
13677// the draft agent as an agent version, which is an immutable snapshot
13678// of your agent. When you save the draft agent, it is published to the
13679// default environment. When you create agent versions, you can publish
13680// them to custom environments. You can create a variety of custom
13681// environments for: - testing - development - production - etc. For
13682// more information, see the versions and environments guide
13683// (https://cloud.google.com/dialogflow/docs/agents-versions).
13684type GoogleCloudDialogflowV2Version struct {
13685	// CreateTime: Output only. The creation time of this version. This
13686	// field is read-only, i.e., it cannot be set by create and update
13687	// methods.
13688	CreateTime string `json:"createTime,omitempty"`
13689
13690	// Description: Optional. The developer-provided description of this
13691	// version.
13692	Description string `json:"description,omitempty"`
13693
13694	// Name: Output only. The unique identifier of this agent version.
13695	// Supported formats: - `projects//agent/versions/` -
13696	// `projects//locations//agent/versions/`
13697	Name string `json:"name,omitempty"`
13698
13699	// Status: Output only. The status of this version. This field is
13700	// read-only and cannot be set by create and update methods.
13701	//
13702	// Possible values:
13703	//   "VERSION_STATUS_UNSPECIFIED" - Not specified. This value is not
13704	// used.
13705	//   "IN_PROGRESS" - Version is not ready to serve (e.g. training is in
13706	// progress).
13707	//   "READY" - Version is ready to serve.
13708	//   "FAILED" - Version training failed.
13709	Status string `json:"status,omitempty"`
13710
13711	// VersionNumber: Output only. The sequential number of this version.
13712	// This field is read-only which means it cannot be set by create and
13713	// update methods.
13714	VersionNumber int64 `json:"versionNumber,omitempty"`
13715
13716	// ServerResponse contains the HTTP response code and headers from the
13717	// server.
13718	googleapi.ServerResponse `json:"-"`
13719
13720	// ForceSendFields is a list of field names (e.g. "CreateTime") to
13721	// unconditionally include in API requests. By default, fields with
13722	// empty or default values are omitted from API requests. However, any
13723	// non-pointer, non-interface field appearing in ForceSendFields will be
13724	// sent to the server regardless of whether the field is empty or not.
13725	// This may be used to include empty fields in Patch requests.
13726	ForceSendFields []string `json:"-"`
13727
13728	// NullFields is a list of field names (e.g. "CreateTime") to include in
13729	// API requests with the JSON null value. By default, fields with empty
13730	// values are omitted from API requests. However, any field with an
13731	// empty value appearing in NullFields will be sent to the server as
13732	// null. It is an error if a field in this list has a non-empty value.
13733	// This may be used to include null fields in Patch requests.
13734	NullFields []string `json:"-"`
13735}
13736
13737func (s *GoogleCloudDialogflowV2Version) MarshalJSON() ([]byte, error) {
13738	type NoMethod GoogleCloudDialogflowV2Version
13739	raw := NoMethod(*s)
13740	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
13741}
13742
13743// GoogleCloudDialogflowV2VoiceSelectionParams: Description of which
13744// voice to use for speech synthesis.
13745type GoogleCloudDialogflowV2VoiceSelectionParams struct {
13746	// Name: Optional. The name of the voice. If not set, the service will
13747	// choose a voice based on the other parameters such as language_code
13748	// and ssml_gender.
13749	Name string `json:"name,omitempty"`
13750
13751	// SsmlGender: Optional. The preferred gender of the voice. If not set,
13752	// the service will choose a voice based on the other parameters such as
13753	// language_code and name. Note that this is only a preference, not
13754	// requirement. If a voice of the appropriate gender is not available,
13755	// the synthesizer should substitute a voice with a different gender
13756	// rather than failing the request.
13757	//
13758	// Possible values:
13759	//   "SSML_VOICE_GENDER_UNSPECIFIED" - An unspecified gender, which
13760	// means that the client doesn't care which gender the selected voice
13761	// will have.
13762	//   "SSML_VOICE_GENDER_MALE" - A male voice.
13763	//   "SSML_VOICE_GENDER_FEMALE" - A female voice.
13764	//   "SSML_VOICE_GENDER_NEUTRAL" - A gender-neutral voice.
13765	SsmlGender string `json:"ssmlGender,omitempty"`
13766
13767	// ForceSendFields is a list of field names (e.g. "Name") to
13768	// unconditionally include in API requests. By default, fields with
13769	// empty or default values are omitted from API requests. However, any
13770	// non-pointer, non-interface field appearing in ForceSendFields will be
13771	// sent to the server regardless of whether the field is empty or not.
13772	// This may be used to include empty fields in Patch requests.
13773	ForceSendFields []string `json:"-"`
13774
13775	// NullFields is a list of field names (e.g. "Name") to include in API
13776	// requests with the JSON null value. By default, fields with empty
13777	// values are omitted from API requests. However, any field with an
13778	// empty value appearing in NullFields will be sent to the server as
13779	// null. It is an error if a field in this list has a non-empty value.
13780	// This may be used to include null fields in Patch requests.
13781	NullFields []string `json:"-"`
13782}
13783
13784func (s *GoogleCloudDialogflowV2VoiceSelectionParams) MarshalJSON() ([]byte, error) {
13785	type NoMethod GoogleCloudDialogflowV2VoiceSelectionParams
13786	raw := NoMethod(*s)
13787	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
13788}
13789
13790// GoogleCloudDialogflowV2WebhookRequest: The request message for a
13791// webhook call.
13792type GoogleCloudDialogflowV2WebhookRequest struct {
13793	// OriginalDetectIntentRequest: Optional. The contents of the original
13794	// request that was passed to `[Streaming]DetectIntent` call.
13795	OriginalDetectIntentRequest *GoogleCloudDialogflowV2OriginalDetectIntentRequest `json:"originalDetectIntentRequest,omitempty"`
13796
13797	// QueryResult: The result of the conversational query or event
13798	// processing. Contains the same value as
13799	// `[Streaming]DetectIntentResponse.query_result`.
13800	QueryResult *GoogleCloudDialogflowV2QueryResult `json:"queryResult,omitempty"`
13801
13802	// ResponseId: The unique identifier of the response. Contains the same
13803	// value as `[Streaming]DetectIntentResponse.response_id`.
13804	ResponseId string `json:"responseId,omitempty"`
13805
13806	// Session: The unique identifier of detectIntent request session. Can
13807	// be used to identify end-user inside webhook implementation. Format:
13808	// `projects//agent/sessions/`, or
13809	// `projects//agent/environments//users//sessions/`.
13810	Session string `json:"session,omitempty"`
13811
13812	// ForceSendFields is a list of field names (e.g.
13813	// "OriginalDetectIntentRequest") to unconditionally include in API
13814	// requests. By default, fields with empty or default values are omitted
13815	// from API requests. However, any non-pointer, non-interface field
13816	// appearing in ForceSendFields will be sent to the server regardless of
13817	// whether the field is empty or not. This may be used to include empty
13818	// fields in Patch requests.
13819	ForceSendFields []string `json:"-"`
13820
13821	// NullFields is a list of field names (e.g.
13822	// "OriginalDetectIntentRequest") to include in API requests with the
13823	// JSON null value. By default, fields with empty values are omitted
13824	// from API requests. However, any field with an empty value appearing
13825	// in NullFields will be sent to the server as null. It is an error if a
13826	// field in this list has a non-empty value. This may be used to include
13827	// null fields in Patch requests.
13828	NullFields []string `json:"-"`
13829}
13830
13831func (s *GoogleCloudDialogflowV2WebhookRequest) MarshalJSON() ([]byte, error) {
13832	type NoMethod GoogleCloudDialogflowV2WebhookRequest
13833	raw := NoMethod(*s)
13834	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
13835}
13836
13837// GoogleCloudDialogflowV2WebhookResponse: The response message for a
13838// webhook call. This response is validated by the Dialogflow server. If
13839// validation fails, an error will be returned in the
13840// QueryResult.diagnostic_info field. Setting JSON fields to an empty
13841// value with the wrong type is a common error. To avoid this error: -
13842// Use "" for empty strings - Use `{}` or `null` for empty objects -
13843// Use `[]` or `null` for empty arrays For more information, see the
13844// Protocol Buffers Language Guide
13845// (https://developers.google.com/protocol-buffers/docs/proto3#json).
13846type GoogleCloudDialogflowV2WebhookResponse struct {
13847	// FollowupEventInput: Optional. Invokes the supplied events. When this
13848	// field is set, Dialogflow ignores the `fulfillment_text`,
13849	// `fulfillment_messages`, and `payload` fields.
13850	FollowupEventInput *GoogleCloudDialogflowV2EventInput `json:"followupEventInput,omitempty"`
13851
13852	// FulfillmentMessages: Optional. The rich response messages intended
13853	// for the end-user. When provided, Dialogflow uses this field to
13854	// populate QueryResult.fulfillment_messages sent to the integration or
13855	// API caller.
13856	FulfillmentMessages []*GoogleCloudDialogflowV2IntentMessage `json:"fulfillmentMessages,omitempty"`
13857
13858	// FulfillmentText: Optional. The text response message intended for the
13859	// end-user. It is recommended to use
13860	// `fulfillment_messages.text.text[0]` instead. When provided,
13861	// Dialogflow uses this field to populate QueryResult.fulfillment_text
13862	// sent to the integration or API caller.
13863	FulfillmentText string `json:"fulfillmentText,omitempty"`
13864
13865	// OutputContexts: Optional. The collection of output contexts that will
13866	// overwrite currently active contexts for the session and reset their
13867	// lifespans. When provided, Dialogflow uses this field to populate
13868	// QueryResult.output_contexts sent to the integration or API caller.
13869	OutputContexts []*GoogleCloudDialogflowV2Context `json:"outputContexts,omitempty"`
13870
13871	// Payload: Optional. This field can be used to pass custom data from
13872	// your webhook to the integration or API caller. Arbitrary JSON objects
13873	// are supported. When provided, Dialogflow uses this field to populate
13874	// QueryResult.webhook_payload sent to the integration or API caller.
13875	// This field is also used by the Google Assistant integration
13876	// (https://cloud.google.com/dialogflow/docs/integrations/aog) for rich
13877	// response messages. See the format definition at Google Assistant
13878	// Dialogflow webhook format
13879	// (https://developers.google.com/assistant/actions/build/json/dialogflow-webhook-json)
13880	Payload googleapi.RawMessage `json:"payload,omitempty"`
13881
13882	// SessionEntityTypes: Optional. Additional session entity types to
13883	// replace or extend developer entity types with. The entity synonyms
13884	// apply to all languages and persist for the session. Setting this data
13885	// from a webhook overwrites the session entity types that have been set
13886	// using `detectIntent`, `streamingDetectIntent` or SessionEntityType
13887	// management methods.
13888	SessionEntityTypes []*GoogleCloudDialogflowV2SessionEntityType `json:"sessionEntityTypes,omitempty"`
13889
13890	// Source: Optional. A custom field used to identify the webhook source.
13891	// Arbitrary strings are supported. When provided, Dialogflow uses this
13892	// field to populate QueryResult.webhook_source sent to the integration
13893	// or API caller.
13894	Source string `json:"source,omitempty"`
13895
13896	// ForceSendFields is a list of field names (e.g. "FollowupEventInput")
13897	// to unconditionally include in API requests. By default, fields with
13898	// empty or default values are omitted from API requests. However, any
13899	// non-pointer, non-interface field appearing in ForceSendFields will be
13900	// sent to the server regardless of whether the field is empty or not.
13901	// This may be used to include empty fields in Patch requests.
13902	ForceSendFields []string `json:"-"`
13903
13904	// NullFields is a list of field names (e.g. "FollowupEventInput") to
13905	// include in API requests with the JSON null value. By default, fields
13906	// with empty values are omitted from API requests. However, any field
13907	// with an empty value appearing in NullFields will be sent to the
13908	// server as null. It is an error if a field in this list has a
13909	// non-empty value. This may be used to include null fields in Patch
13910	// requests.
13911	NullFields []string `json:"-"`
13912}
13913
13914func (s *GoogleCloudDialogflowV2WebhookResponse) MarshalJSON() ([]byte, error) {
13915	type NoMethod GoogleCloudDialogflowV2WebhookResponse
13916	raw := NoMethod(*s)
13917	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
13918}
13919
13920// GoogleCloudDialogflowV2beta1AnnotatedMessagePart: Represents a part
13921// of a message possibly annotated with an entity. The part can be an
13922// entity or purely a part of the message between two entities or
13923// message start/end.
13924type GoogleCloudDialogflowV2beta1AnnotatedMessagePart struct {
13925	// EntityType: Optional. The Dialogflow system entity type
13926	// (https://cloud.google.com/dialogflow/docs/reference/system-entities)
13927	// of this message part. If this is empty, Dialogflow could not annotate
13928	// the phrase part with a system entity.
13929	EntityType string `json:"entityType,omitempty"`
13930
13931	// FormattedValue: Optional. The Dialogflow system entity formatted
13932	// value
13933	// (https://cloud.google.com/dialogflow/docs/reference/system-entities)
13934	// of this message part. For example for a system entity of type
13935	// `@sys.unit-currency`, this may contain: { "amount": 5, "currency":
13936	// "USD" }
13937	FormattedValue interface{} `json:"formattedValue,omitempty"`
13938
13939	// Text: Required. A part of a message possibly annotated with an
13940	// entity.
13941	Text string `json:"text,omitempty"`
13942
13943	// ForceSendFields is a list of field names (e.g. "EntityType") to
13944	// unconditionally include in API requests. By default, fields with
13945	// empty or default values are omitted from API requests. However, any
13946	// non-pointer, non-interface field appearing in ForceSendFields will be
13947	// sent to the server regardless of whether the field is empty or not.
13948	// This may be used to include empty fields in Patch requests.
13949	ForceSendFields []string `json:"-"`
13950
13951	// NullFields is a list of field names (e.g. "EntityType") to include in
13952	// API requests with the JSON null value. By default, fields with empty
13953	// values are omitted from API requests. However, any field with an
13954	// empty value appearing in NullFields will be sent to the server as
13955	// null. It is an error if a field in this list has a non-empty value.
13956	// This may be used to include null fields in Patch requests.
13957	NullFields []string `json:"-"`
13958}
13959
13960func (s *GoogleCloudDialogflowV2beta1AnnotatedMessagePart) MarshalJSON() ([]byte, error) {
13961	type NoMethod GoogleCloudDialogflowV2beta1AnnotatedMessagePart
13962	raw := NoMethod(*s)
13963	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
13964}
13965
13966// GoogleCloudDialogflowV2beta1ArticleAnswer: Represents article answer.
13967type GoogleCloudDialogflowV2beta1ArticleAnswer struct {
13968	// AnswerRecord: The name of answer record, in the format of
13969	// "projects//locations//answerRecords/"
13970	AnswerRecord string `json:"answerRecord,omitempty"`
13971
13972	// Metadata: A map that contains metadata about the answer and the
13973	// document from which it originates.
13974	Metadata map[string]string `json:"metadata,omitempty"`
13975
13976	// Snippets: Output only. Article snippets.
13977	Snippets []string `json:"snippets,omitempty"`
13978
13979	// Title: The article title.
13980	Title string `json:"title,omitempty"`
13981
13982	// Uri: The article URI.
13983	Uri string `json:"uri,omitempty"`
13984
13985	// ForceSendFields is a list of field names (e.g. "AnswerRecord") to
13986	// unconditionally include in API requests. By default, fields with
13987	// empty or default values are omitted from API requests. However, any
13988	// non-pointer, non-interface field appearing in ForceSendFields will be
13989	// sent to the server regardless of whether the field is empty or not.
13990	// This may be used to include empty fields in Patch requests.
13991	ForceSendFields []string `json:"-"`
13992
13993	// NullFields is a list of field names (e.g. "AnswerRecord") to include
13994	// in API requests with the JSON null value. By default, fields with
13995	// empty values are omitted from API requests. However, any field with
13996	// an empty value appearing in NullFields will be sent to the server as
13997	// null. It is an error if a field in this list has a non-empty value.
13998	// This may be used to include null fields in Patch requests.
13999	NullFields []string `json:"-"`
14000}
14001
14002func (s *GoogleCloudDialogflowV2beta1ArticleAnswer) MarshalJSON() ([]byte, error) {
14003	type NoMethod GoogleCloudDialogflowV2beta1ArticleAnswer
14004	raw := NoMethod(*s)
14005	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
14006}
14007
14008// GoogleCloudDialogflowV2beta1BatchUpdateEntityTypesResponse: The
14009// response message for EntityTypes.BatchUpdateEntityTypes.
14010type GoogleCloudDialogflowV2beta1BatchUpdateEntityTypesResponse struct {
14011	// EntityTypes: The collection of updated or created entity types.
14012	EntityTypes []*GoogleCloudDialogflowV2beta1EntityType `json:"entityTypes,omitempty"`
14013
14014	// ForceSendFields is a list of field names (e.g. "EntityTypes") to
14015	// unconditionally include in API requests. By default, fields with
14016	// empty or default values are omitted from API requests. However, any
14017	// non-pointer, non-interface field appearing in ForceSendFields will be
14018	// sent to the server regardless of whether the field is empty or not.
14019	// This may be used to include empty fields in Patch requests.
14020	ForceSendFields []string `json:"-"`
14021
14022	// NullFields is a list of field names (e.g. "EntityTypes") to include
14023	// in API requests with the JSON null value. By default, fields with
14024	// empty values are omitted from API requests. However, any field with
14025	// an empty value appearing in NullFields will be sent to the server as
14026	// null. It is an error if a field in this list has a non-empty value.
14027	// This may be used to include null fields in Patch requests.
14028	NullFields []string `json:"-"`
14029}
14030
14031func (s *GoogleCloudDialogflowV2beta1BatchUpdateEntityTypesResponse) MarshalJSON() ([]byte, error) {
14032	type NoMethod GoogleCloudDialogflowV2beta1BatchUpdateEntityTypesResponse
14033	raw := NoMethod(*s)
14034	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
14035}
14036
14037// GoogleCloudDialogflowV2beta1BatchUpdateIntentsResponse: The response
14038// message for Intents.BatchUpdateIntents.
14039type GoogleCloudDialogflowV2beta1BatchUpdateIntentsResponse struct {
14040	// Intents: The collection of updated or created intents.
14041	Intents []*GoogleCloudDialogflowV2beta1Intent `json:"intents,omitempty"`
14042
14043	// ForceSendFields is a list of field names (e.g. "Intents") to
14044	// unconditionally include in API requests. By default, fields with
14045	// empty or default values are omitted from API requests. However, any
14046	// non-pointer, non-interface field appearing in ForceSendFields will be
14047	// sent to the server regardless of whether the field is empty or not.
14048	// This may be used to include empty fields in Patch requests.
14049	ForceSendFields []string `json:"-"`
14050
14051	// NullFields is a list of field names (e.g. "Intents") to include in
14052	// API requests with the JSON null value. By default, fields with empty
14053	// values are omitted from API requests. However, any field with an
14054	// empty value appearing in NullFields will be sent to the server as
14055	// null. It is an error if a field in this list has a non-empty value.
14056	// This may be used to include null fields in Patch requests.
14057	NullFields []string `json:"-"`
14058}
14059
14060func (s *GoogleCloudDialogflowV2beta1BatchUpdateIntentsResponse) MarshalJSON() ([]byte, error) {
14061	type NoMethod GoogleCloudDialogflowV2beta1BatchUpdateIntentsResponse
14062	raw := NoMethod(*s)
14063	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
14064}
14065
14066// GoogleCloudDialogflowV2beta1Context: Dialogflow contexts are similar
14067// to natural language context. If a person says to you "they are
14068// orange", you need context in order to understand what "they" is
14069// referring to. Similarly, for Dialogflow to handle an end-user
14070// expression like that, it needs to be provided with context in order
14071// to correctly match an intent. Using contexts, you can control the
14072// flow of a conversation. You can configure contexts for an intent by
14073// setting input and output contexts, which are identified by string
14074// names. When an intent is matched, any configured output contexts for
14075// that intent become active. While any contexts are active, Dialogflow
14076// is more likely to match intents that are configured with input
14077// contexts that correspond to the currently active contexts. For more
14078// information about context, see the Contexts guide
14079// (https://cloud.google.com/dialogflow/docs/contexts-overview).
14080type GoogleCloudDialogflowV2beta1Context struct {
14081	// LifespanCount: Optional. The number of conversational query requests
14082	// after which the context expires. The default is `0`. If set to `0`,
14083	// the context expires immediately. Contexts expire automatically after
14084	// 20 minutes if there are no matching queries.
14085	LifespanCount int64 `json:"lifespanCount,omitempty"`
14086
14087	// Name: Required. The unique identifier of the context. Supported
14088	// formats: - `projects//agent/sessions//contexts/`, -
14089	// `projects//locations//agent/sessions//contexts/`, -
14090	// `projects//agent/environments//users//sessions//contexts/`, -
14091	// `projects//locations//agent/environments//users//sessions//contexts/`,
14092	//  The `Context ID` is always converted to lowercase, may only contain
14093	// characters in a-zA-Z0-9_-% and may be at most 250 bytes long. If
14094	// `Environment ID` is not specified, we assume default 'draft'
14095	// environment. If `User ID` is not specified, we assume default '-'
14096	// user. The following context names are reserved for internal use by
14097	// Dialogflow. You should not use these contexts or create contexts with
14098	// these names: * `__system_counters__` * `*_id_dialog_context` *
14099	// `*_dialog_params_size`
14100	Name string `json:"name,omitempty"`
14101
14102	// Parameters: Optional. The collection of parameters associated with
14103	// this context. Depending on your protocol or client library language,
14104	// this is a map, associative array, symbol table, dictionary, or JSON
14105	// object composed of a collection of (MapKey, MapValue) pairs: - MapKey
14106	// type: string - MapKey value: parameter name - MapValue type: - If
14107	// parameter's entity type is a composite entity: map - Else: depending
14108	// on parameter value type, could be one of string, number, boolean,
14109	// null, list or map - MapValue value: - If parameter's entity type is a
14110	// composite entity: map from composite entity property names to
14111	// property values - Else: parameter value
14112	Parameters googleapi.RawMessage `json:"parameters,omitempty"`
14113
14114	// ForceSendFields is a list of field names (e.g. "LifespanCount") to
14115	// unconditionally include in API requests. By default, fields with
14116	// empty or default values are omitted from API requests. However, any
14117	// non-pointer, non-interface field appearing in ForceSendFields will be
14118	// sent to the server regardless of whether the field is empty or not.
14119	// This may be used to include empty fields in Patch requests.
14120	ForceSendFields []string `json:"-"`
14121
14122	// NullFields is a list of field names (e.g. "LifespanCount") to include
14123	// in API requests with the JSON null value. By default, fields with
14124	// empty values are omitted from API requests. However, any field with
14125	// an empty value appearing in NullFields will be sent to the server as
14126	// null. It is an error if a field in this list has a non-empty value.
14127	// This may be used to include null fields in Patch requests.
14128	NullFields []string `json:"-"`
14129}
14130
14131func (s *GoogleCloudDialogflowV2beta1Context) MarshalJSON() ([]byte, error) {
14132	type NoMethod GoogleCloudDialogflowV2beta1Context
14133	raw := NoMethod(*s)
14134	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
14135}
14136
14137// GoogleCloudDialogflowV2beta1ConversationEvent: Represents a
14138// notification sent to Pub/Sub subscribers for conversation lifecycle
14139// events.
14140type GoogleCloudDialogflowV2beta1ConversationEvent struct {
14141	// Conversation: Required. The unique identifier of the conversation
14142	// this notification refers to. Format: `projects//conversations/`.
14143	Conversation string `json:"conversation,omitempty"`
14144
14145	// ErrorStatus: Optional. More detailed information about an error. Only
14146	// set for type UNRECOVERABLE_ERROR_IN_PHONE_CALL.
14147	ErrorStatus *GoogleRpcStatus `json:"errorStatus,omitempty"`
14148
14149	// NewMessagePayload: Payload of NEW_MESSAGE event.
14150	NewMessagePayload *GoogleCloudDialogflowV2beta1Message `json:"newMessagePayload,omitempty"`
14151
14152	// Type: Required. The type of the event that this notification refers
14153	// to.
14154	//
14155	// Possible values:
14156	//   "TYPE_UNSPECIFIED" - Type not set.
14157	//   "CONVERSATION_STARTED" - A new conversation has been opened. This
14158	// is fired when a telephone call is answered, or a conversation is
14159	// created via the API.
14160	//   "CONVERSATION_FINISHED" - An existing conversation has closed. This
14161	// is fired when a telephone call is terminated, or a conversation is
14162	// closed via the API.
14163	//   "NEW_MESSAGE" - An existing conversation has received a new
14164	// message, either from API or telephony. It is configured in
14165	// ConversationProfile.new_message_event_notification_config
14166	//   "UNRECOVERABLE_ERROR" - Unrecoverable error during a telephone
14167	// call. In general non-recoverable errors only occur if something was
14168	// misconfigured in the ConversationProfile corresponding to the call.
14169	// After a non-recoverable error, Dialogflow may stop responding. We
14170	// don't fire this event: * in an API call because we can directly
14171	// return the error, or, * when we can recover from an error.
14172	Type string `json:"type,omitempty"`
14173
14174	// ForceSendFields is a list of field names (e.g. "Conversation") to
14175	// unconditionally include in API requests. By default, fields with
14176	// empty or default values are omitted from API requests. However, any
14177	// non-pointer, non-interface field appearing in ForceSendFields will be
14178	// sent to the server regardless of whether the field is empty or not.
14179	// This may be used to include empty fields in Patch requests.
14180	ForceSendFields []string `json:"-"`
14181
14182	// NullFields is a list of field names (e.g. "Conversation") to include
14183	// in API requests with the JSON null value. By default, fields with
14184	// empty values are omitted from API requests. However, any field with
14185	// an empty value appearing in NullFields will be sent to the server as
14186	// null. It is an error if a field in this list has a non-empty value.
14187	// This may be used to include null fields in Patch requests.
14188	NullFields []string `json:"-"`
14189}
14190
14191func (s *GoogleCloudDialogflowV2beta1ConversationEvent) MarshalJSON() ([]byte, error) {
14192	type NoMethod GoogleCloudDialogflowV2beta1ConversationEvent
14193	raw := NoMethod(*s)
14194	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
14195}
14196
14197// GoogleCloudDialogflowV2beta1EntityType: Each intent parameter has a
14198// type, called the entity type, which dictates exactly how data from an
14199// end-user expression is extracted. Dialogflow provides predefined
14200// system entities that can match many common types of data. For
14201// example, there are system entities for matching dates, times, colors,
14202// email addresses, and so on. You can also create your own custom
14203// entities for matching custom data. For example, you could define a
14204// vegetable entity that can match the types of vegetables available for
14205// purchase with a grocery store agent. For more information, see the
14206// Entity guide
14207// (https://cloud.google.com/dialogflow/docs/entities-overview).
14208type GoogleCloudDialogflowV2beta1EntityType struct {
14209	// AutoExpansionMode: Optional. Indicates whether the entity type can be
14210	// automatically expanded.
14211	//
14212	// Possible values:
14213	//   "AUTO_EXPANSION_MODE_UNSPECIFIED" - Auto expansion disabled for the
14214	// entity.
14215	//   "AUTO_EXPANSION_MODE_DEFAULT" - Allows an agent to recognize values
14216	// that have not been explicitly listed in the entity.
14217	AutoExpansionMode string `json:"autoExpansionMode,omitempty"`
14218
14219	// DisplayName: Required. The name of the entity type.
14220	DisplayName string `json:"displayName,omitempty"`
14221
14222	// EnableFuzzyExtraction: Optional. Enables fuzzy entity extraction
14223	// during classification.
14224	EnableFuzzyExtraction bool `json:"enableFuzzyExtraction,omitempty"`
14225
14226	// Entities: Optional. The collection of entity entries associated with
14227	// the entity type.
14228	Entities []*GoogleCloudDialogflowV2beta1EntityTypeEntity `json:"entities,omitempty"`
14229
14230	// Kind: Required. Indicates the kind of entity type.
14231	//
14232	// Possible values:
14233	//   "KIND_UNSPECIFIED" - Not specified. This value should be never
14234	// used.
14235	//   "KIND_MAP" - Map entity types allow mapping of a group of synonyms
14236	// to a reference value.
14237	//   "KIND_LIST" - List entity types contain a set of entries that do
14238	// not map to reference values. However, list entity types can contain
14239	// references to other entity types (with or without aliases).
14240	//   "KIND_REGEXP" - Regexp entity types allow to specify regular
14241	// expressions in entries values.
14242	Kind string `json:"kind,omitempty"`
14243
14244	// Name: The unique identifier of the entity type. Required for
14245	// EntityTypes.UpdateEntityType and EntityTypes.BatchUpdateEntityTypes
14246	// methods. Supported formats: - `projects//agent/entityTypes/` -
14247	// `projects//locations//agent/entityTypes/`
14248	Name string `json:"name,omitempty"`
14249
14250	// ForceSendFields is a list of field names (e.g. "AutoExpansionMode")
14251	// to unconditionally include in API requests. By default, fields with
14252	// empty or default values are omitted from API requests. However, any
14253	// non-pointer, non-interface field appearing in ForceSendFields will be
14254	// sent to the server regardless of whether the field is empty or not.
14255	// This may be used to include empty fields in Patch requests.
14256	ForceSendFields []string `json:"-"`
14257
14258	// NullFields is a list of field names (e.g. "AutoExpansionMode") to
14259	// include in API requests with the JSON null value. By default, fields
14260	// with empty values are omitted from API requests. However, any field
14261	// with an empty value appearing in NullFields will be sent to the
14262	// server as null. It is an error if a field in this list has a
14263	// non-empty value. This may be used to include null fields in Patch
14264	// requests.
14265	NullFields []string `json:"-"`
14266}
14267
14268func (s *GoogleCloudDialogflowV2beta1EntityType) MarshalJSON() ([]byte, error) {
14269	type NoMethod GoogleCloudDialogflowV2beta1EntityType
14270	raw := NoMethod(*s)
14271	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
14272}
14273
14274// GoogleCloudDialogflowV2beta1EntityTypeEntity: An **entity entry** for
14275// an associated entity type.
14276type GoogleCloudDialogflowV2beta1EntityTypeEntity struct {
14277	// Synonyms: Required. A collection of value synonyms. For example, if
14278	// the entity type is *vegetable*, and `value` is *scallions*, a synonym
14279	// could be *green onions*. For `KIND_LIST` entity types: * This
14280	// collection must contain exactly one synonym equal to `value`.
14281	Synonyms []string `json:"synonyms,omitempty"`
14282
14283	// Value: Required. The primary value associated with this entity entry.
14284	// For example, if the entity type is *vegetable*, the value could be
14285	// *scallions*. For `KIND_MAP` entity types: * A reference value to be
14286	// used in place of synonyms. For `KIND_LIST` entity types: * A string
14287	// that can contain references to other entity types (with or without
14288	// aliases).
14289	Value string `json:"value,omitempty"`
14290
14291	// ForceSendFields is a list of field names (e.g. "Synonyms") to
14292	// unconditionally include in API requests. By default, fields with
14293	// empty or default values are omitted from API requests. However, any
14294	// non-pointer, non-interface field appearing in ForceSendFields will be
14295	// sent to the server regardless of whether the field is empty or not.
14296	// This may be used to include empty fields in Patch requests.
14297	ForceSendFields []string `json:"-"`
14298
14299	// NullFields is a list of field names (e.g. "Synonyms") to include in
14300	// API requests with the JSON null value. By default, fields with empty
14301	// values are omitted from API requests. However, any field with an
14302	// empty value appearing in NullFields will be sent to the server as
14303	// null. It is an error if a field in this list has a non-empty value.
14304	// This may be used to include null fields in Patch requests.
14305	NullFields []string `json:"-"`
14306}
14307
14308func (s *GoogleCloudDialogflowV2beta1EntityTypeEntity) MarshalJSON() ([]byte, error) {
14309	type NoMethod GoogleCloudDialogflowV2beta1EntityTypeEntity
14310	raw := NoMethod(*s)
14311	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
14312}
14313
14314// GoogleCloudDialogflowV2beta1EventInput: Events allow for matching
14315// intents by event name instead of the natural language input. For
14316// instance, input `` can trigger a personalized welcome response. The
14317// parameter `name` may be used by the agent in the response: "Hello
14318// #welcome_event.name! What can I do for you today?".
14319type GoogleCloudDialogflowV2beta1EventInput struct {
14320	// LanguageCode: Required. The language of this query. See Language
14321	// Support (https://cloud.google.com/dialogflow/docs/reference/language)
14322	// for a list of the currently supported language codes. Note that
14323	// queries in the same session do not necessarily need to specify the
14324	// same language.
14325	LanguageCode string `json:"languageCode,omitempty"`
14326
14327	// Name: Required. The unique identifier of the event.
14328	Name string `json:"name,omitempty"`
14329
14330	// Parameters: The collection of parameters associated with the event.
14331	// Depending on your protocol or client library language, this is a map,
14332	// associative array, symbol table, dictionary, or JSON object composed
14333	// of a collection of (MapKey, MapValue) pairs: - MapKey type: string -
14334	// MapKey value: parameter name - MapValue type: - If parameter's entity
14335	// type is a composite entity: map - Else: depending on parameter value
14336	// type, could be one of string, number, boolean, null, list or map -
14337	// MapValue value: - If parameter's entity type is a composite entity:
14338	// map from composite entity property names to property values - Else:
14339	// parameter value
14340	Parameters googleapi.RawMessage `json:"parameters,omitempty"`
14341
14342	// ForceSendFields is a list of field names (e.g. "LanguageCode") to
14343	// unconditionally include in API requests. By default, fields with
14344	// empty or default values are omitted from API requests. However, any
14345	// non-pointer, non-interface field appearing in ForceSendFields will be
14346	// sent to the server regardless of whether the field is empty or not.
14347	// This may be used to include empty fields in Patch requests.
14348	ForceSendFields []string `json:"-"`
14349
14350	// NullFields is a list of field names (e.g. "LanguageCode") to include
14351	// in API requests with the JSON null value. By default, fields with
14352	// empty values are omitted from API requests. However, any field with
14353	// an empty value appearing in NullFields will be sent to the server as
14354	// null. It is an error if a field in this list has a non-empty value.
14355	// This may be used to include null fields in Patch requests.
14356	NullFields []string `json:"-"`
14357}
14358
14359func (s *GoogleCloudDialogflowV2beta1EventInput) MarshalJSON() ([]byte, error) {
14360	type NoMethod GoogleCloudDialogflowV2beta1EventInput
14361	raw := NoMethod(*s)
14362	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
14363}
14364
14365// GoogleCloudDialogflowV2beta1ExportAgentResponse: The response message
14366// for Agents.ExportAgent.
14367type GoogleCloudDialogflowV2beta1ExportAgentResponse struct {
14368	// AgentContent: Zip compressed raw byte content for agent.
14369	AgentContent string `json:"agentContent,omitempty"`
14370
14371	// AgentUri: The URI to a file containing the exported agent. This field
14372	// is populated only if `agent_uri` is specified in
14373	// `ExportAgentRequest`.
14374	AgentUri string `json:"agentUri,omitempty"`
14375
14376	// ForceSendFields is a list of field names (e.g. "AgentContent") to
14377	// unconditionally include in API requests. By default, fields with
14378	// empty or default values are omitted from API requests. However, any
14379	// non-pointer, non-interface field appearing in ForceSendFields will be
14380	// sent to the server regardless of whether the field is empty or not.
14381	// This may be used to include empty fields in Patch requests.
14382	ForceSendFields []string `json:"-"`
14383
14384	// NullFields is a list of field names (e.g. "AgentContent") to include
14385	// in API requests with the JSON null value. By default, fields with
14386	// empty values are omitted from API requests. However, any field with
14387	// an empty value appearing in NullFields will be sent to the server as
14388	// null. It is an error if a field in this list has a non-empty value.
14389	// This may be used to include null fields in Patch requests.
14390	NullFields []string `json:"-"`
14391}
14392
14393func (s *GoogleCloudDialogflowV2beta1ExportAgentResponse) MarshalJSON() ([]byte, error) {
14394	type NoMethod GoogleCloudDialogflowV2beta1ExportAgentResponse
14395	raw := NoMethod(*s)
14396	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
14397}
14398
14399// GoogleCloudDialogflowV2beta1FaqAnswer: Represents answer from
14400// "frequently asked questions".
14401type GoogleCloudDialogflowV2beta1FaqAnswer struct {
14402	// Answer: The piece of text from the `source` knowledge base document.
14403	Answer string `json:"answer,omitempty"`
14404
14405	// AnswerRecord: The name of answer record, in the format of
14406	// "projects//locations//answerRecords/"
14407	AnswerRecord string `json:"answerRecord,omitempty"`
14408
14409	// Confidence: The system's confidence score that this Knowledge answer
14410	// is a good match for this conversational query, range from 0.0
14411	// (completely uncertain) to 1.0 (completely certain).
14412	Confidence float64 `json:"confidence,omitempty"`
14413
14414	// Metadata: A map that contains metadata about the answer and the
14415	// document from which it originates.
14416	Metadata map[string]string `json:"metadata,omitempty"`
14417
14418	// Question: The corresponding FAQ question.
14419	Question string `json:"question,omitempty"`
14420
14421	// Source: Indicates which Knowledge Document this answer was extracted
14422	// from. Format:
14423	// `projects//locations//agent/knowledgeBases//documents/`.
14424	Source string `json:"source,omitempty"`
14425
14426	// ForceSendFields is a list of field names (e.g. "Answer") to
14427	// unconditionally include in API requests. By default, fields with
14428	// empty or default values are omitted from API requests. However, any
14429	// non-pointer, non-interface field appearing in ForceSendFields will be
14430	// sent to the server regardless of whether the field is empty or not.
14431	// This may be used to include empty fields in Patch requests.
14432	ForceSendFields []string `json:"-"`
14433
14434	// NullFields is a list of field names (e.g. "Answer") to include in API
14435	// requests with the JSON null value. By default, fields with empty
14436	// values are omitted from API requests. However, any field with an
14437	// empty value appearing in NullFields will be sent to the server as
14438	// null. It is an error if a field in this list has a non-empty value.
14439	// This may be used to include null fields in Patch requests.
14440	NullFields []string `json:"-"`
14441}
14442
14443func (s *GoogleCloudDialogflowV2beta1FaqAnswer) MarshalJSON() ([]byte, error) {
14444	type NoMethod GoogleCloudDialogflowV2beta1FaqAnswer
14445	raw := NoMethod(*s)
14446	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
14447}
14448
14449func (s *GoogleCloudDialogflowV2beta1FaqAnswer) UnmarshalJSON(data []byte) error {
14450	type NoMethod GoogleCloudDialogflowV2beta1FaqAnswer
14451	var s1 struct {
14452		Confidence gensupport.JSONFloat64 `json:"confidence"`
14453		*NoMethod
14454	}
14455	s1.NoMethod = (*NoMethod)(s)
14456	if err := json.Unmarshal(data, &s1); err != nil {
14457		return err
14458	}
14459	s.Confidence = float64(s1.Confidence)
14460	return nil
14461}
14462
14463// GoogleCloudDialogflowV2beta1HumanAgentAssistantEvent: Output only.
14464// Represents a notification sent to Pub/Sub subscribers for agent
14465// assistant events in a specific conversation.
14466type GoogleCloudDialogflowV2beta1HumanAgentAssistantEvent struct {
14467	// Conversation: The conversation this notification refers to. Format:
14468	// `projects//conversations/`.
14469	Conversation string `json:"conversation,omitempty"`
14470
14471	// Participant: The participant that the suggestion is compiled for. And
14472	// This field is used to call Participants.ListSuggestions API. Format:
14473	// `projects//conversations//participants/`. It will not be set in
14474	// legacy workflow. HumanAgentAssistantConfig.name for more information.
14475	Participant string `json:"participant,omitempty"`
14476
14477	// SuggestionResults: The suggestion results payload that this
14478	// notification refers to. It will only be set when
14479	// HumanAgentAssistantConfig.SuggestionConfig.group_suggestion_responses
14480	// sets to true.
14481	SuggestionResults []*GoogleCloudDialogflowV2beta1SuggestionResult `json:"suggestionResults,omitempty"`
14482
14483	// ForceSendFields is a list of field names (e.g. "Conversation") to
14484	// unconditionally include in API requests. By default, fields with
14485	// empty or default values are omitted from API requests. However, any
14486	// non-pointer, non-interface field appearing in ForceSendFields will be
14487	// sent to the server regardless of whether the field is empty or not.
14488	// This may be used to include empty fields in Patch requests.
14489	ForceSendFields []string `json:"-"`
14490
14491	// NullFields is a list of field names (e.g. "Conversation") to include
14492	// in API requests with the JSON null value. By default, fields with
14493	// empty values are omitted from API requests. However, any field with
14494	// an empty value appearing in NullFields will be sent to the server as
14495	// null. It is an error if a field in this list has a non-empty value.
14496	// This may be used to include null fields in Patch requests.
14497	NullFields []string `json:"-"`
14498}
14499
14500func (s *GoogleCloudDialogflowV2beta1HumanAgentAssistantEvent) MarshalJSON() ([]byte, error) {
14501	type NoMethod GoogleCloudDialogflowV2beta1HumanAgentAssistantEvent
14502	raw := NoMethod(*s)
14503	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
14504}
14505
14506// GoogleCloudDialogflowV2beta1ImportDocumentsResponse: Response message
14507// for Documents.ImportDocuments.
14508type GoogleCloudDialogflowV2beta1ImportDocumentsResponse struct {
14509	// Warnings: Includes details about skipped documents or any other
14510	// warnings.
14511	Warnings []*GoogleRpcStatus `json:"warnings,omitempty"`
14512
14513	// ForceSendFields is a list of field names (e.g. "Warnings") to
14514	// unconditionally include in API requests. By default, fields with
14515	// empty or default values are omitted from API requests. However, any
14516	// non-pointer, non-interface field appearing in ForceSendFields will be
14517	// sent to the server regardless of whether the field is empty or not.
14518	// This may be used to include empty fields in Patch requests.
14519	ForceSendFields []string `json:"-"`
14520
14521	// NullFields is a list of field names (e.g. "Warnings") to include in
14522	// API requests with the JSON null value. By default, fields with empty
14523	// values are omitted from API requests. However, any field with an
14524	// empty value appearing in NullFields will be sent to the server as
14525	// null. It is an error if a field in this list has a non-empty value.
14526	// This may be used to include null fields in Patch requests.
14527	NullFields []string `json:"-"`
14528}
14529
14530func (s *GoogleCloudDialogflowV2beta1ImportDocumentsResponse) MarshalJSON() ([]byte, error) {
14531	type NoMethod GoogleCloudDialogflowV2beta1ImportDocumentsResponse
14532	raw := NoMethod(*s)
14533	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
14534}
14535
14536// GoogleCloudDialogflowV2beta1Intent: An intent categorizes an
14537// end-user's intention for one conversation turn. For each agent, you
14538// define many intents, where your combined intents can handle a
14539// complete conversation. When an end-user writes or says something,
14540// referred to as an end-user expression or end-user input, Dialogflow
14541// matches the end-user input to the best intent in your agent. Matching
14542// an intent is also known as intent classification. For more
14543// information, see the intent guide
14544// (https://cloud.google.com/dialogflow/docs/intents-overview).
14545type GoogleCloudDialogflowV2beta1Intent struct {
14546	// Action: Optional. The name of the action associated with the intent.
14547	// Note: The action name must not contain whitespaces.
14548	Action string `json:"action,omitempty"`
14549
14550	// DefaultResponsePlatforms: Optional. The list of platforms for which
14551	// the first responses will be copied from the messages in
14552	// PLATFORM_UNSPECIFIED (i.e. default platform).
14553	//
14554	// Possible values:
14555	//   "PLATFORM_UNSPECIFIED" - Not specified.
14556	//   "FACEBOOK" - Facebook.
14557	//   "SLACK" - Slack.
14558	//   "TELEGRAM" - Telegram.
14559	//   "KIK" - Kik.
14560	//   "SKYPE" - Skype.
14561	//   "LINE" - Line.
14562	//   "VIBER" - Viber.
14563	//   "ACTIONS_ON_GOOGLE" - Google Assistant See [Dialogflow webhook
14564	// format](https://developers.google.com/assistant/actions/build/json/dia
14565	// logflow-webhook-json)
14566	//   "TELEPHONY" - Telephony Gateway.
14567	//   "GOOGLE_HANGOUTS" - Google Hangouts.
14568	DefaultResponsePlatforms []string `json:"defaultResponsePlatforms,omitempty"`
14569
14570	// DisplayName: Required. The name of this intent.
14571	DisplayName string `json:"displayName,omitempty"`
14572
14573	// EndInteraction: Optional. Indicates that this intent ends an
14574	// interaction. Some integrations (e.g., Actions on Google or Dialogflow
14575	// phone gateway) use this information to close interaction with an end
14576	// user. Default is false.
14577	EndInteraction bool `json:"endInteraction,omitempty"`
14578
14579	// Events: Optional. The collection of event names that trigger the
14580	// intent. If the collection of input contexts is not empty, all of the
14581	// contexts must be present in the active user session for an event to
14582	// trigger this intent. Event names are limited to 150 characters.
14583	Events []string `json:"events,omitempty"`
14584
14585	// FollowupIntentInfo: Output only. Information about all followup
14586	// intents that have this intent as a direct or indirect parent. We
14587	// populate this field only in the output.
14588	FollowupIntentInfo []*GoogleCloudDialogflowV2beta1IntentFollowupIntentInfo `json:"followupIntentInfo,omitempty"`
14589
14590	// InputContextNames: Optional. The list of context names required for
14591	// this intent to be triggered. Formats: -
14592	// `projects//agent/sessions/-/contexts/` -
14593	// `projects//locations//agent/sessions/-/contexts/`
14594	InputContextNames []string `json:"inputContextNames,omitempty"`
14595
14596	// IsFallback: Optional. Indicates whether this is a fallback intent.
14597	IsFallback bool `json:"isFallback,omitempty"`
14598
14599	// LiveAgentHandoff: Optional. Indicates that a live agent should be
14600	// brought in to handle the interaction with the user. In most cases,
14601	// when you set this flag to true, you would also want to set
14602	// end_interaction to true as well. Default is false.
14603	LiveAgentHandoff bool `json:"liveAgentHandoff,omitempty"`
14604
14605	// Messages: Optional. The collection of rich messages corresponding to
14606	// the `Response` field in the Dialogflow console.
14607	Messages []*GoogleCloudDialogflowV2beta1IntentMessage `json:"messages,omitempty"`
14608
14609	// MlDisabled: Optional. Indicates whether Machine Learning is disabled
14610	// for the intent. Note: If `ml_disabled` setting is set to true, then
14611	// this intent is not taken into account during inference in `ML ONLY`
14612	// match mode. Also, auto-markup in the UI is turned off.
14613	MlDisabled bool `json:"mlDisabled,omitempty"`
14614
14615	// MlEnabled: Optional. Indicates whether Machine Learning is enabled
14616	// for the intent. Note: If `ml_enabled` setting is set to false, then
14617	// this intent is not taken into account during inference in `ML ONLY`
14618	// match mode. Also, auto-markup in the UI is turned off. DEPRECATED!
14619	// Please use `ml_disabled` field instead. NOTE: If both `ml_enabled`
14620	// and `ml_disabled` are either not set or false, then the default value
14621	// is determined as follows: - Before April 15th, 2018 the default is:
14622	// ml_enabled = false / ml_disabled = true. - After April 15th, 2018 the
14623	// default is: ml_enabled = true / ml_disabled = false.
14624	MlEnabled bool `json:"mlEnabled,omitempty"`
14625
14626	// Name: Optional. The unique identifier of this intent. Required for
14627	// Intents.UpdateIntent and Intents.BatchUpdateIntents methods.
14628	// Supported formats: - `projects//agent/intents/` -
14629	// `projects//locations//agent/intents/`
14630	Name string `json:"name,omitempty"`
14631
14632	// OutputContexts: Optional. The collection of contexts that are
14633	// activated when the intent is matched. Context messages in this
14634	// collection should not set the parameters field. Setting the
14635	// `lifespan_count` to 0 will reset the context when the intent is
14636	// matched. Format: `projects//agent/sessions/-/contexts/`.
14637	OutputContexts []*GoogleCloudDialogflowV2beta1Context `json:"outputContexts,omitempty"`
14638
14639	// Parameters: Optional. The collection of parameters associated with
14640	// the intent.
14641	Parameters []*GoogleCloudDialogflowV2beta1IntentParameter `json:"parameters,omitempty"`
14642
14643	// ParentFollowupIntentName: Optional. The unique identifier of the
14644	// parent intent in the chain of followup intents. You can set this
14645	// field when creating an intent, for example with CreateIntent or
14646	// BatchUpdateIntents, in order to make this intent a followup intent.
14647	// It identifies the parent followup intent. Format:
14648	// `projects//agent/intents/`.
14649	ParentFollowupIntentName string `json:"parentFollowupIntentName,omitempty"`
14650
14651	// Priority: Optional. The priority of this intent. Higher numbers
14652	// represent higher priorities. - If the supplied value is unspecified
14653	// or 0, the service translates the value to 500,000, which corresponds
14654	// to the `Normal` priority in the console. - If the supplied value is
14655	// negative, the intent is ignored in runtime detect intent requests.
14656	Priority int64 `json:"priority,omitempty"`
14657
14658	// ResetContexts: Optional. Indicates whether to delete all contexts in
14659	// the current session when this intent is matched.
14660	ResetContexts bool `json:"resetContexts,omitempty"`
14661
14662	// RootFollowupIntentName: Output only. The unique identifier of the
14663	// root intent in the chain of followup intents. It identifies the
14664	// correct followup intents chain for this intent. Format:
14665	// `projects//agent/intents/`.
14666	RootFollowupIntentName string `json:"rootFollowupIntentName,omitempty"`
14667
14668	// TrainingPhrases: Optional. The collection of examples that the agent
14669	// is trained on.
14670	TrainingPhrases []*GoogleCloudDialogflowV2beta1IntentTrainingPhrase `json:"trainingPhrases,omitempty"`
14671
14672	// WebhookState: Optional. Indicates whether webhooks are enabled for
14673	// the intent.
14674	//
14675	// Possible values:
14676	//   "WEBHOOK_STATE_UNSPECIFIED" - Webhook is disabled in the agent and
14677	// in the intent.
14678	//   "WEBHOOK_STATE_ENABLED" - Webhook is enabled in the agent and in
14679	// the intent.
14680	//   "WEBHOOK_STATE_ENABLED_FOR_SLOT_FILLING" - Webhook is enabled in
14681	// the agent and in the intent. Also, each slot filling prompt is
14682	// forwarded to the webhook.
14683	WebhookState string `json:"webhookState,omitempty"`
14684
14685	// ForceSendFields is a list of field names (e.g. "Action") to
14686	// unconditionally include in API requests. By default, fields with
14687	// empty or default values are omitted from API requests. However, any
14688	// non-pointer, non-interface field appearing in ForceSendFields will be
14689	// sent to the server regardless of whether the field is empty or not.
14690	// This may be used to include empty fields in Patch requests.
14691	ForceSendFields []string `json:"-"`
14692
14693	// NullFields is a list of field names (e.g. "Action") to include in API
14694	// requests with the JSON null value. By default, fields with empty
14695	// values are omitted from API requests. However, any field with an
14696	// empty value appearing in NullFields will be sent to the server as
14697	// null. It is an error if a field in this list has a non-empty value.
14698	// This may be used to include null fields in Patch requests.
14699	NullFields []string `json:"-"`
14700}
14701
14702func (s *GoogleCloudDialogflowV2beta1Intent) MarshalJSON() ([]byte, error) {
14703	type NoMethod GoogleCloudDialogflowV2beta1Intent
14704	raw := NoMethod(*s)
14705	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
14706}
14707
14708// GoogleCloudDialogflowV2beta1IntentFollowupIntentInfo: Represents a
14709// single followup intent in the chain.
14710type GoogleCloudDialogflowV2beta1IntentFollowupIntentInfo struct {
14711	// FollowupIntentName: The unique identifier of the followup intent.
14712	// Format: `projects//agent/intents/`.
14713	FollowupIntentName string `json:"followupIntentName,omitempty"`
14714
14715	// ParentFollowupIntentName: The unique identifier of the followup
14716	// intent's parent. Format: `projects//agent/intents/`.
14717	ParentFollowupIntentName string `json:"parentFollowupIntentName,omitempty"`
14718
14719	// ForceSendFields is a list of field names (e.g. "FollowupIntentName")
14720	// to unconditionally include in API requests. By default, fields with
14721	// empty or default values are omitted from API requests. However, any
14722	// non-pointer, non-interface field appearing in ForceSendFields will be
14723	// sent to the server regardless of whether the field is empty or not.
14724	// This may be used to include empty fields in Patch requests.
14725	ForceSendFields []string `json:"-"`
14726
14727	// NullFields is a list of field names (e.g. "FollowupIntentName") to
14728	// include in API requests with the JSON null value. By default, fields
14729	// with empty values are omitted from API requests. However, any field
14730	// with an empty value appearing in NullFields will be sent to the
14731	// server as null. It is an error if a field in this list has a
14732	// non-empty value. This may be used to include null fields in Patch
14733	// requests.
14734	NullFields []string `json:"-"`
14735}
14736
14737func (s *GoogleCloudDialogflowV2beta1IntentFollowupIntentInfo) MarshalJSON() ([]byte, error) {
14738	type NoMethod GoogleCloudDialogflowV2beta1IntentFollowupIntentInfo
14739	raw := NoMethod(*s)
14740	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
14741}
14742
14743// GoogleCloudDialogflowV2beta1IntentMessage: Corresponds to the
14744// `Response` field in the Dialogflow console.
14745type GoogleCloudDialogflowV2beta1IntentMessage struct {
14746	// BasicCard: Displays a basic card for Actions on Google.
14747	BasicCard *GoogleCloudDialogflowV2beta1IntentMessageBasicCard `json:"basicCard,omitempty"`
14748
14749	// BrowseCarouselCard: Browse carousel card for Actions on Google.
14750	BrowseCarouselCard *GoogleCloudDialogflowV2beta1IntentMessageBrowseCarouselCard `json:"browseCarouselCard,omitempty"`
14751
14752	// Card: Displays a card.
14753	Card *GoogleCloudDialogflowV2beta1IntentMessageCard `json:"card,omitempty"`
14754
14755	// CarouselSelect: Displays a carousel card for Actions on Google.
14756	CarouselSelect *GoogleCloudDialogflowV2beta1IntentMessageCarouselSelect `json:"carouselSelect,omitempty"`
14757
14758	// Image: Displays an image.
14759	Image *GoogleCloudDialogflowV2beta1IntentMessageImage `json:"image,omitempty"`
14760
14761	// LinkOutSuggestion: Displays a link out suggestion chip for Actions on
14762	// Google.
14763	LinkOutSuggestion *GoogleCloudDialogflowV2beta1IntentMessageLinkOutSuggestion `json:"linkOutSuggestion,omitempty"`
14764
14765	// ListSelect: Displays a list card for Actions on Google.
14766	ListSelect *GoogleCloudDialogflowV2beta1IntentMessageListSelect `json:"listSelect,omitempty"`
14767
14768	// MediaContent: The media content card for Actions on Google.
14769	MediaContent *GoogleCloudDialogflowV2beta1IntentMessageMediaContent `json:"mediaContent,omitempty"`
14770
14771	// Payload: A custom platform-specific response.
14772	Payload googleapi.RawMessage `json:"payload,omitempty"`
14773
14774	// Platform: Optional. The platform that this message is intended for.
14775	//
14776	// Possible values:
14777	//   "PLATFORM_UNSPECIFIED" - Not specified.
14778	//   "FACEBOOK" - Facebook.
14779	//   "SLACK" - Slack.
14780	//   "TELEGRAM" - Telegram.
14781	//   "KIK" - Kik.
14782	//   "SKYPE" - Skype.
14783	//   "LINE" - Line.
14784	//   "VIBER" - Viber.
14785	//   "ACTIONS_ON_GOOGLE" - Google Assistant See [Dialogflow webhook
14786	// format](https://developers.google.com/assistant/actions/build/json/dia
14787	// logflow-webhook-json)
14788	//   "TELEPHONY" - Telephony Gateway.
14789	//   "GOOGLE_HANGOUTS" - Google Hangouts.
14790	Platform string `json:"platform,omitempty"`
14791
14792	// QuickReplies: Displays quick replies.
14793	QuickReplies *GoogleCloudDialogflowV2beta1IntentMessageQuickReplies `json:"quickReplies,omitempty"`
14794
14795	// RbmCarouselRichCard: Rich Business Messaging (RBM) carousel rich card
14796	// response.
14797	RbmCarouselRichCard *GoogleCloudDialogflowV2beta1IntentMessageRbmCarouselCard `json:"rbmCarouselRichCard,omitempty"`
14798
14799	// RbmStandaloneRichCard: Standalone Rich Business Messaging (RBM) rich
14800	// card response.
14801	RbmStandaloneRichCard *GoogleCloudDialogflowV2beta1IntentMessageRbmStandaloneCard `json:"rbmStandaloneRichCard,omitempty"`
14802
14803	// RbmText: Rich Business Messaging (RBM) text response. RBM allows
14804	// businesses to send enriched and branded versions of SMS. See
14805	// https://jibe.google.com/business-messaging.
14806	RbmText *GoogleCloudDialogflowV2beta1IntentMessageRbmText `json:"rbmText,omitempty"`
14807
14808	// SimpleResponses: Returns a voice or text-only response for Actions on
14809	// Google.
14810	SimpleResponses *GoogleCloudDialogflowV2beta1IntentMessageSimpleResponses `json:"simpleResponses,omitempty"`
14811
14812	// Suggestions: Displays suggestion chips for Actions on Google.
14813	Suggestions *GoogleCloudDialogflowV2beta1IntentMessageSuggestions `json:"suggestions,omitempty"`
14814
14815	// TableCard: Table card for Actions on Google.
14816	TableCard *GoogleCloudDialogflowV2beta1IntentMessageTableCard `json:"tableCard,omitempty"`
14817
14818	// TelephonyPlayAudio: Plays audio from a file in Telephony Gateway.
14819	TelephonyPlayAudio *GoogleCloudDialogflowV2beta1IntentMessageTelephonyPlayAudio `json:"telephonyPlayAudio,omitempty"`
14820
14821	// TelephonySynthesizeSpeech: Synthesizes speech in Telephony Gateway.
14822	TelephonySynthesizeSpeech *GoogleCloudDialogflowV2beta1IntentMessageTelephonySynthesizeSpeech `json:"telephonySynthesizeSpeech,omitempty"`
14823
14824	// TelephonyTransferCall: Transfers the call in Telephony Gateway.
14825	TelephonyTransferCall *GoogleCloudDialogflowV2beta1IntentMessageTelephonyTransferCall `json:"telephonyTransferCall,omitempty"`
14826
14827	// Text: Returns a text response.
14828	Text *GoogleCloudDialogflowV2beta1IntentMessageText `json:"text,omitempty"`
14829
14830	// ForceSendFields is a list of field names (e.g. "BasicCard") to
14831	// unconditionally include in API requests. By default, fields with
14832	// empty or default values are omitted from API requests. However, any
14833	// non-pointer, non-interface field appearing in ForceSendFields will be
14834	// sent to the server regardless of whether the field is empty or not.
14835	// This may be used to include empty fields in Patch requests.
14836	ForceSendFields []string `json:"-"`
14837
14838	// NullFields is a list of field names (e.g. "BasicCard") to include in
14839	// API requests with the JSON null value. By default, fields with empty
14840	// values are omitted from API requests. However, any field with an
14841	// empty value appearing in NullFields will be sent to the server as
14842	// null. It is an error if a field in this list has a non-empty value.
14843	// This may be used to include null fields in Patch requests.
14844	NullFields []string `json:"-"`
14845}
14846
14847func (s *GoogleCloudDialogflowV2beta1IntentMessage) MarshalJSON() ([]byte, error) {
14848	type NoMethod GoogleCloudDialogflowV2beta1IntentMessage
14849	raw := NoMethod(*s)
14850	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
14851}
14852
14853// GoogleCloudDialogflowV2beta1IntentMessageBasicCard: The basic card
14854// message. Useful for displaying information.
14855type GoogleCloudDialogflowV2beta1IntentMessageBasicCard struct {
14856	// Buttons: Optional. The collection of card buttons.
14857	Buttons []*GoogleCloudDialogflowV2beta1IntentMessageBasicCardButton `json:"buttons,omitempty"`
14858
14859	// FormattedText: Required, unless image is present. The body text of
14860	// the card.
14861	FormattedText string `json:"formattedText,omitempty"`
14862
14863	// Image: Optional. The image for the card.
14864	Image *GoogleCloudDialogflowV2beta1IntentMessageImage `json:"image,omitempty"`
14865
14866	// Subtitle: Optional. The subtitle of the card.
14867	Subtitle string `json:"subtitle,omitempty"`
14868
14869	// Title: Optional. The title of the card.
14870	Title string `json:"title,omitempty"`
14871
14872	// ForceSendFields is a list of field names (e.g. "Buttons") to
14873	// unconditionally include in API requests. By default, fields with
14874	// empty or default values are omitted from API requests. However, any
14875	// non-pointer, non-interface field appearing in ForceSendFields will be
14876	// sent to the server regardless of whether the field is empty or not.
14877	// This may be used to include empty fields in Patch requests.
14878	ForceSendFields []string `json:"-"`
14879
14880	// NullFields is a list of field names (e.g. "Buttons") to include in
14881	// API requests with the JSON null value. By default, fields with empty
14882	// values are omitted from API requests. However, any field with an
14883	// empty value appearing in NullFields will be sent to the server as
14884	// null. It is an error if a field in this list has a non-empty value.
14885	// This may be used to include null fields in Patch requests.
14886	NullFields []string `json:"-"`
14887}
14888
14889func (s *GoogleCloudDialogflowV2beta1IntentMessageBasicCard) MarshalJSON() ([]byte, error) {
14890	type NoMethod GoogleCloudDialogflowV2beta1IntentMessageBasicCard
14891	raw := NoMethod(*s)
14892	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
14893}
14894
14895// GoogleCloudDialogflowV2beta1IntentMessageBasicCardButton: The button
14896// object that appears at the bottom of a card.
14897type GoogleCloudDialogflowV2beta1IntentMessageBasicCardButton struct {
14898	// OpenUriAction: Required. Action to take when a user taps on the
14899	// button.
14900	OpenUriAction *GoogleCloudDialogflowV2beta1IntentMessageBasicCardButtonOpenUriAction `json:"openUriAction,omitempty"`
14901
14902	// Title: Required. The title of the button.
14903	Title string `json:"title,omitempty"`
14904
14905	// ForceSendFields is a list of field names (e.g. "OpenUriAction") to
14906	// unconditionally include in API requests. By default, fields with
14907	// empty or default values are omitted from API requests. However, any
14908	// non-pointer, non-interface field appearing in ForceSendFields will be
14909	// sent to the server regardless of whether the field is empty or not.
14910	// This may be used to include empty fields in Patch requests.
14911	ForceSendFields []string `json:"-"`
14912
14913	// NullFields is a list of field names (e.g. "OpenUriAction") to include
14914	// in API requests with the JSON null value. By default, fields with
14915	// empty values are omitted from API requests. However, any field with
14916	// an empty value appearing in NullFields will be sent to the server as
14917	// null. It is an error if a field in this list has a non-empty value.
14918	// This may be used to include null fields in Patch requests.
14919	NullFields []string `json:"-"`
14920}
14921
14922func (s *GoogleCloudDialogflowV2beta1IntentMessageBasicCardButton) MarshalJSON() ([]byte, error) {
14923	type NoMethod GoogleCloudDialogflowV2beta1IntentMessageBasicCardButton
14924	raw := NoMethod(*s)
14925	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
14926}
14927
14928// GoogleCloudDialogflowV2beta1IntentMessageBasicCardButtonOpenUriAction:
14929//  Opens the given URI.
14930type GoogleCloudDialogflowV2beta1IntentMessageBasicCardButtonOpenUriAction struct {
14931	// Uri: Required. The HTTP or HTTPS scheme URI.
14932	Uri string `json:"uri,omitempty"`
14933
14934	// ForceSendFields is a list of field names (e.g. "Uri") to
14935	// unconditionally include in API requests. By default, fields with
14936	// empty or default values are omitted from API requests. However, any
14937	// non-pointer, non-interface field appearing in ForceSendFields will be
14938	// sent to the server regardless of whether the field is empty or not.
14939	// This may be used to include empty fields in Patch requests.
14940	ForceSendFields []string `json:"-"`
14941
14942	// NullFields is a list of field names (e.g. "Uri") to include in API
14943	// requests with the JSON null value. By default, fields with empty
14944	// values are omitted from API requests. However, any field with an
14945	// empty value appearing in NullFields will be sent to the server as
14946	// null. It is an error if a field in this list has a non-empty value.
14947	// This may be used to include null fields in Patch requests.
14948	NullFields []string `json:"-"`
14949}
14950
14951func (s *GoogleCloudDialogflowV2beta1IntentMessageBasicCardButtonOpenUriAction) MarshalJSON() ([]byte, error) {
14952	type NoMethod GoogleCloudDialogflowV2beta1IntentMessageBasicCardButtonOpenUriAction
14953	raw := NoMethod(*s)
14954	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
14955}
14956
14957// GoogleCloudDialogflowV2beta1IntentMessageBrowseCarouselCard: Browse
14958// Carousel Card for Actions on Google.
14959// https://developers.google.com/actions/assistant/responses#browsing_carousel
14960type GoogleCloudDialogflowV2beta1IntentMessageBrowseCarouselCard struct {
14961	// ImageDisplayOptions: Optional. Settings for displaying the image.
14962	// Applies to every image in items.
14963	//
14964	// Possible values:
14965	//   "IMAGE_DISPLAY_OPTIONS_UNSPECIFIED" - Fill the gaps between the
14966	// image and the image container with gray bars.
14967	//   "GRAY" - Fill the gaps between the image and the image container
14968	// with gray bars.
14969	//   "WHITE" - Fill the gaps between the image and the image container
14970	// with white bars.
14971	//   "CROPPED" - Image is scaled such that the image width and height
14972	// match or exceed the container dimensions. This may crop the top and
14973	// bottom of the image if the scaled image height is greater than the
14974	// container height, or crop the left and right of the image if the
14975	// scaled image width is greater than the container width. This is
14976	// similar to "Zoom Mode" on a widescreen TV when playing a 4:3 video.
14977	//   "BLURRED_BACKGROUND" - Pad the gaps between image and image frame
14978	// with a blurred copy of the same image.
14979	ImageDisplayOptions string `json:"imageDisplayOptions,omitempty"`
14980
14981	// Items: Required. List of items in the Browse Carousel Card. Minimum
14982	// of two items, maximum of ten.
14983	Items []*GoogleCloudDialogflowV2beta1IntentMessageBrowseCarouselCardBrowseCarouselCardItem `json:"items,omitempty"`
14984
14985	// ForceSendFields is a list of field names (e.g. "ImageDisplayOptions")
14986	// to unconditionally include in API requests. By default, fields with
14987	// empty or default values are omitted from API requests. However, any
14988	// non-pointer, non-interface field appearing in ForceSendFields will be
14989	// sent to the server regardless of whether the field is empty or not.
14990	// This may be used to include empty fields in Patch requests.
14991	ForceSendFields []string `json:"-"`
14992
14993	// NullFields is a list of field names (e.g. "ImageDisplayOptions") to
14994	// include in API requests with the JSON null value. By default, fields
14995	// with empty values are omitted from API requests. However, any field
14996	// with an empty value appearing in NullFields will be sent to the
14997	// server as null. It is an error if a field in this list has a
14998	// non-empty value. This may be used to include null fields in Patch
14999	// requests.
15000	NullFields []string `json:"-"`
15001}
15002
15003func (s *GoogleCloudDialogflowV2beta1IntentMessageBrowseCarouselCard) MarshalJSON() ([]byte, error) {
15004	type NoMethod GoogleCloudDialogflowV2beta1IntentMessageBrowseCarouselCard
15005	raw := NoMethod(*s)
15006	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
15007}
15008
15009// GoogleCloudDialogflowV2beta1IntentMessageBrowseCarouselCardBrowseCarou
15010// selCardItem: Browsing carousel tile
15011type GoogleCloudDialogflowV2beta1IntentMessageBrowseCarouselCardBrowseCarouselCardItem struct {
15012	// Description: Optional. Description of the carousel item. Maximum of
15013	// four lines of text.
15014	Description string `json:"description,omitempty"`
15015
15016	// Footer: Optional. Text that appears at the bottom of the Browse
15017	// Carousel Card. Maximum of one line of text.
15018	Footer string `json:"footer,omitempty"`
15019
15020	// Image: Optional. Hero image for the carousel item.
15021	Image *GoogleCloudDialogflowV2beta1IntentMessageImage `json:"image,omitempty"`
15022
15023	// OpenUriAction: Required. Action to present to the user.
15024	OpenUriAction *GoogleCloudDialogflowV2beta1IntentMessageBrowseCarouselCardBrowseCarouselCardItemOpenUrlAction `json:"openUriAction,omitempty"`
15025
15026	// Title: Required. Title of the carousel item. Maximum of two lines of
15027	// text.
15028	Title string `json:"title,omitempty"`
15029
15030	// ForceSendFields is a list of field names (e.g. "Description") to
15031	// unconditionally include in API requests. By default, fields with
15032	// empty or default values are omitted from API requests. However, any
15033	// non-pointer, non-interface field appearing in ForceSendFields will be
15034	// sent to the server regardless of whether the field is empty or not.
15035	// This may be used to include empty fields in Patch requests.
15036	ForceSendFields []string `json:"-"`
15037
15038	// NullFields is a list of field names (e.g. "Description") to include
15039	// in API requests with the JSON null value. By default, fields with
15040	// empty values are omitted from API requests. However, any field with
15041	// an empty value appearing in NullFields will be sent to the server as
15042	// null. It is an error if a field in this list has a non-empty value.
15043	// This may be used to include null fields in Patch requests.
15044	NullFields []string `json:"-"`
15045}
15046
15047func (s *GoogleCloudDialogflowV2beta1IntentMessageBrowseCarouselCardBrowseCarouselCardItem) MarshalJSON() ([]byte, error) {
15048	type NoMethod GoogleCloudDialogflowV2beta1IntentMessageBrowseCarouselCardBrowseCarouselCardItem
15049	raw := NoMethod(*s)
15050	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
15051}
15052
15053// GoogleCloudDialogflowV2beta1IntentMessageBrowseCarouselCardBrowseCarou
15054// selCardItemOpenUrlAction: Actions on Google action to open a given
15055// url.
15056type GoogleCloudDialogflowV2beta1IntentMessageBrowseCarouselCardBrowseCarouselCardItemOpenUrlAction struct {
15057	// Url: Required. URL
15058	Url string `json:"url,omitempty"`
15059
15060	// UrlTypeHint: Optional. Specifies the type of viewer that is used when
15061	// opening the URL. Defaults to opening via web browser.
15062	//
15063	// Possible values:
15064	//   "URL_TYPE_HINT_UNSPECIFIED" - Unspecified
15065	//   "AMP_ACTION" - Url would be an amp action
15066	//   "AMP_CONTENT" - URL that points directly to AMP content, or to a
15067	// canonical URL which refers to AMP content via .
15068	UrlTypeHint string `json:"urlTypeHint,omitempty"`
15069
15070	// ForceSendFields is a list of field names (e.g. "Url") to
15071	// unconditionally include in API requests. By default, fields with
15072	// empty or default values are omitted from API requests. However, any
15073	// non-pointer, non-interface field appearing in ForceSendFields will be
15074	// sent to the server regardless of whether the field is empty or not.
15075	// This may be used to include empty fields in Patch requests.
15076	ForceSendFields []string `json:"-"`
15077
15078	// NullFields is a list of field names (e.g. "Url") to include in API
15079	// requests with the JSON null value. By default, fields with empty
15080	// values are omitted from API requests. However, any field with an
15081	// empty value appearing in NullFields will be sent to the server as
15082	// null. It is an error if a field in this list has a non-empty value.
15083	// This may be used to include null fields in Patch requests.
15084	NullFields []string `json:"-"`
15085}
15086
15087func (s *GoogleCloudDialogflowV2beta1IntentMessageBrowseCarouselCardBrowseCarouselCardItemOpenUrlAction) MarshalJSON() ([]byte, error) {
15088	type NoMethod GoogleCloudDialogflowV2beta1IntentMessageBrowseCarouselCardBrowseCarouselCardItemOpenUrlAction
15089	raw := NoMethod(*s)
15090	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
15091}
15092
15093// GoogleCloudDialogflowV2beta1IntentMessageCard: The card response
15094// message.
15095type GoogleCloudDialogflowV2beta1IntentMessageCard struct {
15096	// Buttons: Optional. The collection of card buttons.
15097	Buttons []*GoogleCloudDialogflowV2beta1IntentMessageCardButton `json:"buttons,omitempty"`
15098
15099	// ImageUri: Optional. The public URI to an image file for the card.
15100	ImageUri string `json:"imageUri,omitempty"`
15101
15102	// Subtitle: Optional. The subtitle of the card.
15103	Subtitle string `json:"subtitle,omitempty"`
15104
15105	// Title: Optional. The title of the card.
15106	Title string `json:"title,omitempty"`
15107
15108	// ForceSendFields is a list of field names (e.g. "Buttons") to
15109	// unconditionally include in API requests. By default, fields with
15110	// empty or default values are omitted from API requests. However, any
15111	// non-pointer, non-interface field appearing in ForceSendFields will be
15112	// sent to the server regardless of whether the field is empty or not.
15113	// This may be used to include empty fields in Patch requests.
15114	ForceSendFields []string `json:"-"`
15115
15116	// NullFields is a list of field names (e.g. "Buttons") to include in
15117	// API requests with the JSON null value. By default, fields with empty
15118	// values are omitted from API requests. However, any field with an
15119	// empty value appearing in NullFields will be sent to the server as
15120	// null. It is an error if a field in this list has a non-empty value.
15121	// This may be used to include null fields in Patch requests.
15122	NullFields []string `json:"-"`
15123}
15124
15125func (s *GoogleCloudDialogflowV2beta1IntentMessageCard) MarshalJSON() ([]byte, error) {
15126	type NoMethod GoogleCloudDialogflowV2beta1IntentMessageCard
15127	raw := NoMethod(*s)
15128	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
15129}
15130
15131// GoogleCloudDialogflowV2beta1IntentMessageCardButton: Optional.
15132// Contains information about a button.
15133type GoogleCloudDialogflowV2beta1IntentMessageCardButton struct {
15134	// Postback: Optional. The text to send back to the Dialogflow API or a
15135	// URI to open.
15136	Postback string `json:"postback,omitempty"`
15137
15138	// Text: Optional. The text to show on the button.
15139	Text string `json:"text,omitempty"`
15140
15141	// ForceSendFields is a list of field names (e.g. "Postback") to
15142	// unconditionally include in API requests. By default, fields with
15143	// empty or default values are omitted from API requests. However, any
15144	// non-pointer, non-interface field appearing in ForceSendFields will be
15145	// sent to the server regardless of whether the field is empty or not.
15146	// This may be used to include empty fields in Patch requests.
15147	ForceSendFields []string `json:"-"`
15148
15149	// NullFields is a list of field names (e.g. "Postback") to include in
15150	// API requests with the JSON null value. By default, fields with empty
15151	// values are omitted from API requests. However, any field with an
15152	// empty value appearing in NullFields will be sent to the server as
15153	// null. It is an error if a field in this list has a non-empty value.
15154	// This may be used to include null fields in Patch requests.
15155	NullFields []string `json:"-"`
15156}
15157
15158func (s *GoogleCloudDialogflowV2beta1IntentMessageCardButton) MarshalJSON() ([]byte, error) {
15159	type NoMethod GoogleCloudDialogflowV2beta1IntentMessageCardButton
15160	raw := NoMethod(*s)
15161	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
15162}
15163
15164// GoogleCloudDialogflowV2beta1IntentMessageCarouselSelect: The card for
15165// presenting a carousel of options to select from.
15166type GoogleCloudDialogflowV2beta1IntentMessageCarouselSelect struct {
15167	// Items: Required. Carousel items.
15168	Items []*GoogleCloudDialogflowV2beta1IntentMessageCarouselSelectItem `json:"items,omitempty"`
15169
15170	// ForceSendFields is a list of field names (e.g. "Items") to
15171	// unconditionally include in API requests. By default, fields with
15172	// empty or default values are omitted from API requests. However, any
15173	// non-pointer, non-interface field appearing in ForceSendFields will be
15174	// sent to the server regardless of whether the field is empty or not.
15175	// This may be used to include empty fields in Patch requests.
15176	ForceSendFields []string `json:"-"`
15177
15178	// NullFields is a list of field names (e.g. "Items") to include in API
15179	// requests with the JSON null value. By default, fields with empty
15180	// values are omitted from API requests. However, any field with an
15181	// empty value appearing in NullFields will be sent to the server as
15182	// null. It is an error if a field in this list has a non-empty value.
15183	// This may be used to include null fields in Patch requests.
15184	NullFields []string `json:"-"`
15185}
15186
15187func (s *GoogleCloudDialogflowV2beta1IntentMessageCarouselSelect) MarshalJSON() ([]byte, error) {
15188	type NoMethod GoogleCloudDialogflowV2beta1IntentMessageCarouselSelect
15189	raw := NoMethod(*s)
15190	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
15191}
15192
15193// GoogleCloudDialogflowV2beta1IntentMessageCarouselSelectItem: An item
15194// in the carousel.
15195type GoogleCloudDialogflowV2beta1IntentMessageCarouselSelectItem struct {
15196	// Description: Optional. The body text of the card.
15197	Description string `json:"description,omitempty"`
15198
15199	// Image: Optional. The image to display.
15200	Image *GoogleCloudDialogflowV2beta1IntentMessageImage `json:"image,omitempty"`
15201
15202	// Info: Required. Additional info about the option item.
15203	Info *GoogleCloudDialogflowV2beta1IntentMessageSelectItemInfo `json:"info,omitempty"`
15204
15205	// Title: Required. Title of the carousel item.
15206	Title string `json:"title,omitempty"`
15207
15208	// ForceSendFields is a list of field names (e.g. "Description") to
15209	// unconditionally include in API requests. By default, fields with
15210	// empty or default values are omitted from API requests. However, any
15211	// non-pointer, non-interface field appearing in ForceSendFields will be
15212	// sent to the server regardless of whether the field is empty or not.
15213	// This may be used to include empty fields in Patch requests.
15214	ForceSendFields []string `json:"-"`
15215
15216	// NullFields is a list of field names (e.g. "Description") to include
15217	// in API requests with the JSON null value. By default, fields with
15218	// empty values are omitted from API requests. However, any field with
15219	// an empty value appearing in NullFields will be sent to the server as
15220	// null. It is an error if a field in this list has a non-empty value.
15221	// This may be used to include null fields in Patch requests.
15222	NullFields []string `json:"-"`
15223}
15224
15225func (s *GoogleCloudDialogflowV2beta1IntentMessageCarouselSelectItem) MarshalJSON() ([]byte, error) {
15226	type NoMethod GoogleCloudDialogflowV2beta1IntentMessageCarouselSelectItem
15227	raw := NoMethod(*s)
15228	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
15229}
15230
15231// GoogleCloudDialogflowV2beta1IntentMessageColumnProperties: Column
15232// properties for TableCard.
15233type GoogleCloudDialogflowV2beta1IntentMessageColumnProperties struct {
15234	// Header: Required. Column heading.
15235	Header string `json:"header,omitempty"`
15236
15237	// HorizontalAlignment: Optional. Defines text alignment for all cells
15238	// in this column.
15239	//
15240	// Possible values:
15241	//   "HORIZONTAL_ALIGNMENT_UNSPECIFIED" - Text is aligned to the leading
15242	// edge of the column.
15243	//   "LEADING" - Text is aligned to the leading edge of the column.
15244	//   "CENTER" - Text is centered in the column.
15245	//   "TRAILING" - Text is aligned to the trailing edge of the column.
15246	HorizontalAlignment string `json:"horizontalAlignment,omitempty"`
15247
15248	// ForceSendFields is a list of field names (e.g. "Header") to
15249	// unconditionally include in API requests. By default, fields with
15250	// empty or default values are omitted from API requests. However, any
15251	// non-pointer, non-interface field appearing in ForceSendFields will be
15252	// sent to the server regardless of whether the field is empty or not.
15253	// This may be used to include empty fields in Patch requests.
15254	ForceSendFields []string `json:"-"`
15255
15256	// NullFields is a list of field names (e.g. "Header") to include in API
15257	// requests with the JSON null value. By default, fields with empty
15258	// values are omitted from API requests. However, any field with an
15259	// empty value appearing in NullFields will be sent to the server as
15260	// null. It is an error if a field in this list has a non-empty value.
15261	// This may be used to include null fields in Patch requests.
15262	NullFields []string `json:"-"`
15263}
15264
15265func (s *GoogleCloudDialogflowV2beta1IntentMessageColumnProperties) MarshalJSON() ([]byte, error) {
15266	type NoMethod GoogleCloudDialogflowV2beta1IntentMessageColumnProperties
15267	raw := NoMethod(*s)
15268	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
15269}
15270
15271// GoogleCloudDialogflowV2beta1IntentMessageImage: The image response
15272// message.
15273type GoogleCloudDialogflowV2beta1IntentMessageImage struct {
15274	// AccessibilityText: A text description of the image to be used for
15275	// accessibility, e.g., screen readers. Required if image_uri is set for
15276	// CarouselSelect.
15277	AccessibilityText string `json:"accessibilityText,omitempty"`
15278
15279	// ImageUri: Optional. The public URI to an image file.
15280	ImageUri string `json:"imageUri,omitempty"`
15281
15282	// ForceSendFields is a list of field names (e.g. "AccessibilityText")
15283	// to unconditionally include in API requests. By default, fields with
15284	// empty or default values are omitted from API requests. However, any
15285	// non-pointer, non-interface field appearing in ForceSendFields will be
15286	// sent to the server regardless of whether the field is empty or not.
15287	// This may be used to include empty fields in Patch requests.
15288	ForceSendFields []string `json:"-"`
15289
15290	// NullFields is a list of field names (e.g. "AccessibilityText") to
15291	// include in API requests with the JSON null value. By default, fields
15292	// with empty values are omitted from API requests. However, any field
15293	// with an empty value appearing in NullFields will be sent to the
15294	// server as null. It is an error if a field in this list has a
15295	// non-empty value. This may be used to include null fields in Patch
15296	// requests.
15297	NullFields []string `json:"-"`
15298}
15299
15300func (s *GoogleCloudDialogflowV2beta1IntentMessageImage) MarshalJSON() ([]byte, error) {
15301	type NoMethod GoogleCloudDialogflowV2beta1IntentMessageImage
15302	raw := NoMethod(*s)
15303	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
15304}
15305
15306// GoogleCloudDialogflowV2beta1IntentMessageLinkOutSuggestion: The
15307// suggestion chip message that allows the user to jump out to the app
15308// or website associated with this agent.
15309type GoogleCloudDialogflowV2beta1IntentMessageLinkOutSuggestion struct {
15310	// DestinationName: Required. The name of the app or site this chip is
15311	// linking to.
15312	DestinationName string `json:"destinationName,omitempty"`
15313
15314	// Uri: Required. The URI of the app or site to open when the user taps
15315	// the suggestion chip.
15316	Uri string `json:"uri,omitempty"`
15317
15318	// ForceSendFields is a list of field names (e.g. "DestinationName") to
15319	// unconditionally include in API requests. By default, fields with
15320	// empty or default values are omitted from API requests. However, any
15321	// non-pointer, non-interface field appearing in ForceSendFields will be
15322	// sent to the server regardless of whether the field is empty or not.
15323	// This may be used to include empty fields in Patch requests.
15324	ForceSendFields []string `json:"-"`
15325
15326	// NullFields is a list of field names (e.g. "DestinationName") to
15327	// include in API requests with the JSON null value. By default, fields
15328	// with empty values are omitted from API requests. However, any field
15329	// with an empty value appearing in NullFields will be sent to the
15330	// server as null. It is an error if a field in this list has a
15331	// non-empty value. This may be used to include null fields in Patch
15332	// requests.
15333	NullFields []string `json:"-"`
15334}
15335
15336func (s *GoogleCloudDialogflowV2beta1IntentMessageLinkOutSuggestion) MarshalJSON() ([]byte, error) {
15337	type NoMethod GoogleCloudDialogflowV2beta1IntentMessageLinkOutSuggestion
15338	raw := NoMethod(*s)
15339	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
15340}
15341
15342// GoogleCloudDialogflowV2beta1IntentMessageListSelect: The card for
15343// presenting a list of options to select from.
15344type GoogleCloudDialogflowV2beta1IntentMessageListSelect struct {
15345	// Items: Required. List items.
15346	Items []*GoogleCloudDialogflowV2beta1IntentMessageListSelectItem `json:"items,omitempty"`
15347
15348	// Subtitle: Optional. Subtitle of the list.
15349	Subtitle string `json:"subtitle,omitempty"`
15350
15351	// Title: Optional. The overall title of the list.
15352	Title string `json:"title,omitempty"`
15353
15354	// ForceSendFields is a list of field names (e.g. "Items") to
15355	// unconditionally include in API requests. By default, fields with
15356	// empty or default values are omitted from API requests. However, any
15357	// non-pointer, non-interface field appearing in ForceSendFields will be
15358	// sent to the server regardless of whether the field is empty or not.
15359	// This may be used to include empty fields in Patch requests.
15360	ForceSendFields []string `json:"-"`
15361
15362	// NullFields is a list of field names (e.g. "Items") to include in API
15363	// requests with the JSON null value. By default, fields with empty
15364	// values are omitted from API requests. However, any field with an
15365	// empty value appearing in NullFields will be sent to the server as
15366	// null. It is an error if a field in this list has a non-empty value.
15367	// This may be used to include null fields in Patch requests.
15368	NullFields []string `json:"-"`
15369}
15370
15371func (s *GoogleCloudDialogflowV2beta1IntentMessageListSelect) MarshalJSON() ([]byte, error) {
15372	type NoMethod GoogleCloudDialogflowV2beta1IntentMessageListSelect
15373	raw := NoMethod(*s)
15374	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
15375}
15376
15377// GoogleCloudDialogflowV2beta1IntentMessageListSelectItem: An item in
15378// the list.
15379type GoogleCloudDialogflowV2beta1IntentMessageListSelectItem struct {
15380	// Description: Optional. The main text describing the item.
15381	Description string `json:"description,omitempty"`
15382
15383	// Image: Optional. The image to display.
15384	Image *GoogleCloudDialogflowV2beta1IntentMessageImage `json:"image,omitempty"`
15385
15386	// Info: Required. Additional information about this option.
15387	Info *GoogleCloudDialogflowV2beta1IntentMessageSelectItemInfo `json:"info,omitempty"`
15388
15389	// Title: Required. The title of the list item.
15390	Title string `json:"title,omitempty"`
15391
15392	// ForceSendFields is a list of field names (e.g. "Description") to
15393	// unconditionally include in API requests. By default, fields with
15394	// empty or default values are omitted from API requests. However, any
15395	// non-pointer, non-interface field appearing in ForceSendFields will be
15396	// sent to the server regardless of whether the field is empty or not.
15397	// This may be used to include empty fields in Patch requests.
15398	ForceSendFields []string `json:"-"`
15399
15400	// NullFields is a list of field names (e.g. "Description") to include
15401	// in API requests with the JSON null value. By default, fields with
15402	// empty values are omitted from API requests. However, any field with
15403	// an empty value appearing in NullFields will be sent to the server as
15404	// null. It is an error if a field in this list has a non-empty value.
15405	// This may be used to include null fields in Patch requests.
15406	NullFields []string `json:"-"`
15407}
15408
15409func (s *GoogleCloudDialogflowV2beta1IntentMessageListSelectItem) MarshalJSON() ([]byte, error) {
15410	type NoMethod GoogleCloudDialogflowV2beta1IntentMessageListSelectItem
15411	raw := NoMethod(*s)
15412	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
15413}
15414
15415// GoogleCloudDialogflowV2beta1IntentMessageMediaContent: The media
15416// content card for Actions on Google.
15417type GoogleCloudDialogflowV2beta1IntentMessageMediaContent struct {
15418	// MediaObjects: Required. List of media objects.
15419	MediaObjects []*GoogleCloudDialogflowV2beta1IntentMessageMediaContentResponseMediaObject `json:"mediaObjects,omitempty"`
15420
15421	// MediaType: Optional. What type of media is the content (ie "audio").
15422	//
15423	// Possible values:
15424	//   "RESPONSE_MEDIA_TYPE_UNSPECIFIED" - Unspecified.
15425	//   "AUDIO" - Response media type is audio.
15426	MediaType string `json:"mediaType,omitempty"`
15427
15428	// ForceSendFields is a list of field names (e.g. "MediaObjects") to
15429	// unconditionally include in API requests. By default, fields with
15430	// empty or default values are omitted from API requests. However, any
15431	// non-pointer, non-interface field appearing in ForceSendFields will be
15432	// sent to the server regardless of whether the field is empty or not.
15433	// This may be used to include empty fields in Patch requests.
15434	ForceSendFields []string `json:"-"`
15435
15436	// NullFields is a list of field names (e.g. "MediaObjects") to include
15437	// in API requests with the JSON null value. By default, fields with
15438	// empty values are omitted from API requests. However, any field with
15439	// an empty value appearing in NullFields will be sent to the server as
15440	// null. It is an error if a field in this list has a non-empty value.
15441	// This may be used to include null fields in Patch requests.
15442	NullFields []string `json:"-"`
15443}
15444
15445func (s *GoogleCloudDialogflowV2beta1IntentMessageMediaContent) MarshalJSON() ([]byte, error) {
15446	type NoMethod GoogleCloudDialogflowV2beta1IntentMessageMediaContent
15447	raw := NoMethod(*s)
15448	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
15449}
15450
15451// GoogleCloudDialogflowV2beta1IntentMessageMediaContentResponseMediaObje
15452// ct: Response media object for media content card.
15453type GoogleCloudDialogflowV2beta1IntentMessageMediaContentResponseMediaObject struct {
15454	// ContentUrl: Required. Url where the media is stored.
15455	ContentUrl string `json:"contentUrl,omitempty"`
15456
15457	// Description: Optional. Description of media card.
15458	Description string `json:"description,omitempty"`
15459
15460	// Icon: Optional. Icon to display above media content.
15461	Icon *GoogleCloudDialogflowV2beta1IntentMessageImage `json:"icon,omitempty"`
15462
15463	// LargeImage: Optional. Image to display above media content.
15464	LargeImage *GoogleCloudDialogflowV2beta1IntentMessageImage `json:"largeImage,omitempty"`
15465
15466	// Name: Required. Name of media card.
15467	Name string `json:"name,omitempty"`
15468
15469	// ForceSendFields is a list of field names (e.g. "ContentUrl") to
15470	// unconditionally include in API requests. By default, fields with
15471	// empty or default values are omitted from API requests. However, any
15472	// non-pointer, non-interface field appearing in ForceSendFields will be
15473	// sent to the server regardless of whether the field is empty or not.
15474	// This may be used to include empty fields in Patch requests.
15475	ForceSendFields []string `json:"-"`
15476
15477	// NullFields is a list of field names (e.g. "ContentUrl") to include in
15478	// API requests with the JSON null value. By default, fields with empty
15479	// values are omitted from API requests. However, any field with an
15480	// empty value appearing in NullFields will be sent to the server as
15481	// null. It is an error if a field in this list has a non-empty value.
15482	// This may be used to include null fields in Patch requests.
15483	NullFields []string `json:"-"`
15484}
15485
15486func (s *GoogleCloudDialogflowV2beta1IntentMessageMediaContentResponseMediaObject) MarshalJSON() ([]byte, error) {
15487	type NoMethod GoogleCloudDialogflowV2beta1IntentMessageMediaContentResponseMediaObject
15488	raw := NoMethod(*s)
15489	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
15490}
15491
15492// GoogleCloudDialogflowV2beta1IntentMessageQuickReplies: The quick
15493// replies response message.
15494type GoogleCloudDialogflowV2beta1IntentMessageQuickReplies struct {
15495	// QuickReplies: Optional. The collection of quick replies.
15496	QuickReplies []string `json:"quickReplies,omitempty"`
15497
15498	// Title: Optional. The title of the collection of quick replies.
15499	Title string `json:"title,omitempty"`
15500
15501	// ForceSendFields is a list of field names (e.g. "QuickReplies") to
15502	// unconditionally include in API requests. By default, fields with
15503	// empty or default values are omitted from API requests. However, any
15504	// non-pointer, non-interface field appearing in ForceSendFields will be
15505	// sent to the server regardless of whether the field is empty or not.
15506	// This may be used to include empty fields in Patch requests.
15507	ForceSendFields []string `json:"-"`
15508
15509	// NullFields is a list of field names (e.g. "QuickReplies") to include
15510	// in API requests with the JSON null value. By default, fields with
15511	// empty values are omitted from API requests. However, any field with
15512	// an empty value appearing in NullFields will be sent to the server as
15513	// null. It is an error if a field in this list has a non-empty value.
15514	// This may be used to include null fields in Patch requests.
15515	NullFields []string `json:"-"`
15516}
15517
15518func (s *GoogleCloudDialogflowV2beta1IntentMessageQuickReplies) MarshalJSON() ([]byte, error) {
15519	type NoMethod GoogleCloudDialogflowV2beta1IntentMessageQuickReplies
15520	raw := NoMethod(*s)
15521	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
15522}
15523
15524// GoogleCloudDialogflowV2beta1IntentMessageRbmCardContent: Rich
15525// Business Messaging (RBM) Card content
15526type GoogleCloudDialogflowV2beta1IntentMessageRbmCardContent struct {
15527	// Description: Optional. Description of the card (at most 2000 bytes).
15528	// At least one of the title, description or media must be set.
15529	Description string `json:"description,omitempty"`
15530
15531	// Media: Optional. However at least one of the title, description or
15532	// media must be set. Media (image, GIF or a video) to include in the
15533	// card.
15534	Media *GoogleCloudDialogflowV2beta1IntentMessageRbmCardContentRbmMedia `json:"media,omitempty"`
15535
15536	// Suggestions: Optional. List of suggestions to include in the card.
15537	Suggestions []*GoogleCloudDialogflowV2beta1IntentMessageRbmSuggestion `json:"suggestions,omitempty"`
15538
15539	// Title: Optional. Title of the card (at most 200 bytes). At least one
15540	// of the title, description or media must be set.
15541	Title string `json:"title,omitempty"`
15542
15543	// ForceSendFields is a list of field names (e.g. "Description") to
15544	// unconditionally include in API requests. By default, fields with
15545	// empty or default values are omitted from API requests. However, any
15546	// non-pointer, non-interface field appearing in ForceSendFields will be
15547	// sent to the server regardless of whether the field is empty or not.
15548	// This may be used to include empty fields in Patch requests.
15549	ForceSendFields []string `json:"-"`
15550
15551	// NullFields is a list of field names (e.g. "Description") to include
15552	// in API requests with the JSON null value. By default, fields with
15553	// empty values are omitted from API requests. However, any field with
15554	// an empty value appearing in NullFields will be sent to the server as
15555	// null. It is an error if a field in this list has a non-empty value.
15556	// This may be used to include null fields in Patch requests.
15557	NullFields []string `json:"-"`
15558}
15559
15560func (s *GoogleCloudDialogflowV2beta1IntentMessageRbmCardContent) MarshalJSON() ([]byte, error) {
15561	type NoMethod GoogleCloudDialogflowV2beta1IntentMessageRbmCardContent
15562	raw := NoMethod(*s)
15563	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
15564}
15565
15566// GoogleCloudDialogflowV2beta1IntentMessageRbmCardContentRbmMedia: Rich
15567// Business Messaging (RBM) Media displayed in Cards The following
15568// media-types are currently supported: Image Types * image/jpeg *
15569// image/jpg' * image/gif * image/png Video Types * video/h263 *
15570// video/m4v * video/mp4 * video/mpeg * video/mpeg4 * video/webm
15571type GoogleCloudDialogflowV2beta1IntentMessageRbmCardContentRbmMedia struct {
15572	// FileUri: Required. Publicly reachable URI of the file. The RBM
15573	// platform determines the MIME type of the file from the content-type
15574	// field in the HTTP headers when the platform fetches the file. The
15575	// content-type field must be present and accurate in the HTTP response
15576	// from the URL.
15577	FileUri string `json:"fileUri,omitempty"`
15578
15579	// Height: Required for cards with vertical orientation. The height of
15580	// the media within a rich card with a vertical layout. For a standalone
15581	// card with horizontal layout, height is not customizable, and this
15582	// field is ignored.
15583	//
15584	// Possible values:
15585	//   "HEIGHT_UNSPECIFIED" - Not specified.
15586	//   "SHORT" - 112 DP.
15587	//   "MEDIUM" - 168 DP.
15588	//   "TALL" - 264 DP. Not available for rich card carousels when the
15589	// card width is set to small.
15590	Height string `json:"height,omitempty"`
15591
15592	// ThumbnailUri: Optional. Publicly reachable URI of the thumbnail.If
15593	// you don't provide a thumbnail URI, the RBM platform displays a blank
15594	// placeholder thumbnail until the user's device downloads the file.
15595	// Depending on the user's setting, the file may not download
15596	// automatically and may require the user to tap a download button.
15597	ThumbnailUri string `json:"thumbnailUri,omitempty"`
15598
15599	// ForceSendFields is a list of field names (e.g. "FileUri") to
15600	// unconditionally include in API requests. By default, fields with
15601	// empty or default values are omitted from API requests. However, any
15602	// non-pointer, non-interface field appearing in ForceSendFields will be
15603	// sent to the server regardless of whether the field is empty or not.
15604	// This may be used to include empty fields in Patch requests.
15605	ForceSendFields []string `json:"-"`
15606
15607	// NullFields is a list of field names (e.g. "FileUri") to include in
15608	// API requests with the JSON null value. By default, fields with empty
15609	// values are omitted from API requests. However, any field with an
15610	// empty value appearing in NullFields will be sent to the server as
15611	// null. It is an error if a field in this list has a non-empty value.
15612	// This may be used to include null fields in Patch requests.
15613	NullFields []string `json:"-"`
15614}
15615
15616func (s *GoogleCloudDialogflowV2beta1IntentMessageRbmCardContentRbmMedia) MarshalJSON() ([]byte, error) {
15617	type NoMethod GoogleCloudDialogflowV2beta1IntentMessageRbmCardContentRbmMedia
15618	raw := NoMethod(*s)
15619	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
15620}
15621
15622// GoogleCloudDialogflowV2beta1IntentMessageRbmCarouselCard: Carousel
15623// Rich Business Messaging (RBM) rich card. Rich cards allow you to
15624// respond to users with more vivid content, e.g. with media and
15625// suggestions. If you want to show a single card with more control over
15626// the layout, please use RbmStandaloneCard instead.
15627type GoogleCloudDialogflowV2beta1IntentMessageRbmCarouselCard struct {
15628	// CardContents: Required. The cards in the carousel. A carousel must
15629	// have at least 2 cards and at most 10.
15630	CardContents []*GoogleCloudDialogflowV2beta1IntentMessageRbmCardContent `json:"cardContents,omitempty"`
15631
15632	// CardWidth: Required. The width of the cards in the carousel.
15633	//
15634	// Possible values:
15635	//   "CARD_WIDTH_UNSPECIFIED" - Not specified.
15636	//   "SMALL" - 120 DP. Note that tall media cannot be used.
15637	//   "MEDIUM" - 232 DP.
15638	CardWidth string `json:"cardWidth,omitempty"`
15639
15640	// ForceSendFields is a list of field names (e.g. "CardContents") to
15641	// unconditionally include in API requests. By default, fields with
15642	// empty or default values are omitted from API requests. However, any
15643	// non-pointer, non-interface field appearing in ForceSendFields will be
15644	// sent to the server regardless of whether the field is empty or not.
15645	// This may be used to include empty fields in Patch requests.
15646	ForceSendFields []string `json:"-"`
15647
15648	// NullFields is a list of field names (e.g. "CardContents") to include
15649	// in API requests with the JSON null value. By default, fields with
15650	// empty values are omitted from API requests. However, any field with
15651	// an empty value appearing in NullFields will be sent to the server as
15652	// null. It is an error if a field in this list has a non-empty value.
15653	// This may be used to include null fields in Patch requests.
15654	NullFields []string `json:"-"`
15655}
15656
15657func (s *GoogleCloudDialogflowV2beta1IntentMessageRbmCarouselCard) MarshalJSON() ([]byte, error) {
15658	type NoMethod GoogleCloudDialogflowV2beta1IntentMessageRbmCarouselCard
15659	raw := NoMethod(*s)
15660	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
15661}
15662
15663// GoogleCloudDialogflowV2beta1IntentMessageRbmStandaloneCard:
15664// Standalone Rich Business Messaging (RBM) rich card. Rich cards allow
15665// you to respond to users with more vivid content, e.g. with media and
15666// suggestions. You can group multiple rich cards into one using
15667// RbmCarouselCard but carousel cards will give you less control over
15668// the card layout.
15669type GoogleCloudDialogflowV2beta1IntentMessageRbmStandaloneCard struct {
15670	// CardContent: Required. Card content.
15671	CardContent *GoogleCloudDialogflowV2beta1IntentMessageRbmCardContent `json:"cardContent,omitempty"`
15672
15673	// CardOrientation: Required. Orientation of the card.
15674	//
15675	// Possible values:
15676	//   "CARD_ORIENTATION_UNSPECIFIED" - Not specified.
15677	//   "HORIZONTAL" - Horizontal layout.
15678	//   "VERTICAL" - Vertical layout.
15679	CardOrientation string `json:"cardOrientation,omitempty"`
15680
15681	// ThumbnailImageAlignment: Required if orientation is horizontal. Image
15682	// preview alignment for standalone cards with horizontal layout.
15683	//
15684	// Possible values:
15685	//   "THUMBNAIL_IMAGE_ALIGNMENT_UNSPECIFIED" - Not specified.
15686	//   "LEFT" - Thumbnail preview is left-aligned.
15687	//   "RIGHT" - Thumbnail preview is right-aligned.
15688	ThumbnailImageAlignment string `json:"thumbnailImageAlignment,omitempty"`
15689
15690	// ForceSendFields is a list of field names (e.g. "CardContent") to
15691	// unconditionally include in API requests. By default, fields with
15692	// empty or default values are omitted from API requests. However, any
15693	// non-pointer, non-interface field appearing in ForceSendFields will be
15694	// sent to the server regardless of whether the field is empty or not.
15695	// This may be used to include empty fields in Patch requests.
15696	ForceSendFields []string `json:"-"`
15697
15698	// NullFields is a list of field names (e.g. "CardContent") to include
15699	// in API requests with the JSON null value. By default, fields with
15700	// empty values are omitted from API requests. However, any field with
15701	// an empty value appearing in NullFields will be sent to the server as
15702	// null. It is an error if a field in this list has a non-empty value.
15703	// This may be used to include null fields in Patch requests.
15704	NullFields []string `json:"-"`
15705}
15706
15707func (s *GoogleCloudDialogflowV2beta1IntentMessageRbmStandaloneCard) MarshalJSON() ([]byte, error) {
15708	type NoMethod GoogleCloudDialogflowV2beta1IntentMessageRbmStandaloneCard
15709	raw := NoMethod(*s)
15710	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
15711}
15712
15713// GoogleCloudDialogflowV2beta1IntentMessageRbmSuggestedAction: Rich
15714// Business Messaging (RBM) suggested client-side action that the user
15715// can choose from the card.
15716type GoogleCloudDialogflowV2beta1IntentMessageRbmSuggestedAction struct {
15717	// Dial: Suggested client side action: Dial a phone number
15718	Dial *GoogleCloudDialogflowV2beta1IntentMessageRbmSuggestedActionRbmSuggestedActionDial `json:"dial,omitempty"`
15719
15720	// OpenUrl: Suggested client side action: Open a URI on device
15721	OpenUrl *GoogleCloudDialogflowV2beta1IntentMessageRbmSuggestedActionRbmSuggestedActionOpenUri `json:"openUrl,omitempty"`
15722
15723	// PostbackData: Opaque payload that the Dialogflow receives in a user
15724	// event when the user taps the suggested action. This data will be also
15725	// forwarded to webhook to allow performing custom business logic.
15726	PostbackData string `json:"postbackData,omitempty"`
15727
15728	// ShareLocation: Suggested client side action: Share user location
15729	ShareLocation *GoogleCloudDialogflowV2beta1IntentMessageRbmSuggestedActionRbmSuggestedActionShareLocation `json:"shareLocation,omitempty"`
15730
15731	// Text: Text to display alongside the action.
15732	Text string `json:"text,omitempty"`
15733
15734	// ForceSendFields is a list of field names (e.g. "Dial") to
15735	// unconditionally include in API requests. By default, fields with
15736	// empty or default values are omitted from API requests. However, any
15737	// non-pointer, non-interface field appearing in ForceSendFields will be
15738	// sent to the server regardless of whether the field is empty or not.
15739	// This may be used to include empty fields in Patch requests.
15740	ForceSendFields []string `json:"-"`
15741
15742	// NullFields is a list of field names (e.g. "Dial") to include in API
15743	// requests with the JSON null value. By default, fields with empty
15744	// values are omitted from API requests. However, any field with an
15745	// empty value appearing in NullFields will be sent to the server as
15746	// null. It is an error if a field in this list has a non-empty value.
15747	// This may be used to include null fields in Patch requests.
15748	NullFields []string `json:"-"`
15749}
15750
15751func (s *GoogleCloudDialogflowV2beta1IntentMessageRbmSuggestedAction) MarshalJSON() ([]byte, error) {
15752	type NoMethod GoogleCloudDialogflowV2beta1IntentMessageRbmSuggestedAction
15753	raw := NoMethod(*s)
15754	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
15755}
15756
15757// GoogleCloudDialogflowV2beta1IntentMessageRbmSuggestedActionRbmSuggeste
15758// dActionDial: Opens the user's default dialer app with the specified
15759// phone number but does not dial automatically.
15760type GoogleCloudDialogflowV2beta1IntentMessageRbmSuggestedActionRbmSuggestedActionDial struct {
15761	// PhoneNumber: Required. The phone number to fill in the default dialer
15762	// app. This field should be in E.164
15763	// (https://en.wikipedia.org/wiki/E.164) format. An example of a
15764	// correctly formatted phone number: +15556767888.
15765	PhoneNumber string `json:"phoneNumber,omitempty"`
15766
15767	// ForceSendFields is a list of field names (e.g. "PhoneNumber") to
15768	// unconditionally include in API requests. By default, fields with
15769	// empty or default values are omitted from API requests. However, any
15770	// non-pointer, non-interface field appearing in ForceSendFields will be
15771	// sent to the server regardless of whether the field is empty or not.
15772	// This may be used to include empty fields in Patch requests.
15773	ForceSendFields []string `json:"-"`
15774
15775	// NullFields is a list of field names (e.g. "PhoneNumber") to include
15776	// in API requests with the JSON null value. By default, fields with
15777	// empty values are omitted from API requests. However, any field with
15778	// an empty value appearing in NullFields will be sent to the server as
15779	// null. It is an error if a field in this list has a non-empty value.
15780	// This may be used to include null fields in Patch requests.
15781	NullFields []string `json:"-"`
15782}
15783
15784func (s *GoogleCloudDialogflowV2beta1IntentMessageRbmSuggestedActionRbmSuggestedActionDial) MarshalJSON() ([]byte, error) {
15785	type NoMethod GoogleCloudDialogflowV2beta1IntentMessageRbmSuggestedActionRbmSuggestedActionDial
15786	raw := NoMethod(*s)
15787	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
15788}
15789
15790// GoogleCloudDialogflowV2beta1IntentMessageRbmSuggestedActionRbmSuggeste
15791// dActionOpenUri: Opens the user's default web browser app to the
15792// specified uri If the user has an app installed that is registered as
15793// the default handler for the URL, then this app will be opened
15794// instead, and its icon will be used in the suggested action UI.
15795type GoogleCloudDialogflowV2beta1IntentMessageRbmSuggestedActionRbmSuggestedActionOpenUri struct {
15796	// Uri: Required. The uri to open on the user device
15797	Uri string `json:"uri,omitempty"`
15798
15799	// ForceSendFields is a list of field names (e.g. "Uri") to
15800	// unconditionally include in API requests. By default, fields with
15801	// empty or default values are omitted from API requests. However, any
15802	// non-pointer, non-interface field appearing in ForceSendFields will be
15803	// sent to the server regardless of whether the field is empty or not.
15804	// This may be used to include empty fields in Patch requests.
15805	ForceSendFields []string `json:"-"`
15806
15807	// NullFields is a list of field names (e.g. "Uri") to include in API
15808	// requests with the JSON null value. By default, fields with empty
15809	// values are omitted from API requests. However, any field with an
15810	// empty value appearing in NullFields will be sent to the server as
15811	// null. It is an error if a field in this list has a non-empty value.
15812	// This may be used to include null fields in Patch requests.
15813	NullFields []string `json:"-"`
15814}
15815
15816func (s *GoogleCloudDialogflowV2beta1IntentMessageRbmSuggestedActionRbmSuggestedActionOpenUri) MarshalJSON() ([]byte, error) {
15817	type NoMethod GoogleCloudDialogflowV2beta1IntentMessageRbmSuggestedActionRbmSuggestedActionOpenUri
15818	raw := NoMethod(*s)
15819	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
15820}
15821
15822// GoogleCloudDialogflowV2beta1IntentMessageRbmSuggestedActionRbmSuggeste
15823// dActionShareLocation: Opens the device's location chooser so the user
15824// can pick a location to send back to the agent.
15825type GoogleCloudDialogflowV2beta1IntentMessageRbmSuggestedActionRbmSuggestedActionShareLocation struct {
15826}
15827
15828// GoogleCloudDialogflowV2beta1IntentMessageRbmSuggestedReply: Rich
15829// Business Messaging (RBM) suggested reply that the user can click
15830// instead of typing in their own response.
15831type GoogleCloudDialogflowV2beta1IntentMessageRbmSuggestedReply struct {
15832	// PostbackData: Opaque payload that the Dialogflow receives in a user
15833	// event when the user taps the suggested reply. This data will be also
15834	// forwarded to webhook to allow performing custom business logic.
15835	PostbackData string `json:"postbackData,omitempty"`
15836
15837	// Text: Suggested reply text.
15838	Text string `json:"text,omitempty"`
15839
15840	// ForceSendFields is a list of field names (e.g. "PostbackData") to
15841	// unconditionally include in API requests. By default, fields with
15842	// empty or default values are omitted from API requests. However, any
15843	// non-pointer, non-interface field appearing in ForceSendFields will be
15844	// sent to the server regardless of whether the field is empty or not.
15845	// This may be used to include empty fields in Patch requests.
15846	ForceSendFields []string `json:"-"`
15847
15848	// NullFields is a list of field names (e.g. "PostbackData") to include
15849	// in API requests with the JSON null value. By default, fields with
15850	// empty values are omitted from API requests. However, any field with
15851	// an empty value appearing in NullFields will be sent to the server as
15852	// null. It is an error if a field in this list has a non-empty value.
15853	// This may be used to include null fields in Patch requests.
15854	NullFields []string `json:"-"`
15855}
15856
15857func (s *GoogleCloudDialogflowV2beta1IntentMessageRbmSuggestedReply) MarshalJSON() ([]byte, error) {
15858	type NoMethod GoogleCloudDialogflowV2beta1IntentMessageRbmSuggestedReply
15859	raw := NoMethod(*s)
15860	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
15861}
15862
15863// GoogleCloudDialogflowV2beta1IntentMessageRbmSuggestion: Rich Business
15864// Messaging (RBM) suggestion. Suggestions allow user to easily
15865// select/click a predefined response or perform an action (like opening
15866// a web uri).
15867type GoogleCloudDialogflowV2beta1IntentMessageRbmSuggestion struct {
15868	// Action: Predefined client side actions that user can choose
15869	Action *GoogleCloudDialogflowV2beta1IntentMessageRbmSuggestedAction `json:"action,omitempty"`
15870
15871	// Reply: Predefined replies for user to select instead of typing
15872	Reply *GoogleCloudDialogflowV2beta1IntentMessageRbmSuggestedReply `json:"reply,omitempty"`
15873
15874	// ForceSendFields is a list of field names (e.g. "Action") to
15875	// unconditionally include in API requests. By default, fields with
15876	// empty or default values are omitted from API requests. However, any
15877	// non-pointer, non-interface field appearing in ForceSendFields will be
15878	// sent to the server regardless of whether the field is empty or not.
15879	// This may be used to include empty fields in Patch requests.
15880	ForceSendFields []string `json:"-"`
15881
15882	// NullFields is a list of field names (e.g. "Action") to include in API
15883	// requests with the JSON null value. By default, fields with empty
15884	// values are omitted from API requests. However, any field with an
15885	// empty value appearing in NullFields will be sent to the server as
15886	// null. It is an error if a field in this list has a non-empty value.
15887	// This may be used to include null fields in Patch requests.
15888	NullFields []string `json:"-"`
15889}
15890
15891func (s *GoogleCloudDialogflowV2beta1IntentMessageRbmSuggestion) MarshalJSON() ([]byte, error) {
15892	type NoMethod GoogleCloudDialogflowV2beta1IntentMessageRbmSuggestion
15893	raw := NoMethod(*s)
15894	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
15895}
15896
15897// GoogleCloudDialogflowV2beta1IntentMessageRbmText: Rich Business
15898// Messaging (RBM) text response with suggestions.
15899type GoogleCloudDialogflowV2beta1IntentMessageRbmText struct {
15900	// RbmSuggestion: Optional. One or more suggestions to show to the user.
15901	RbmSuggestion []*GoogleCloudDialogflowV2beta1IntentMessageRbmSuggestion `json:"rbmSuggestion,omitempty"`
15902
15903	// Text: Required. Text sent and displayed to the user.
15904	Text string `json:"text,omitempty"`
15905
15906	// ForceSendFields is a list of field names (e.g. "RbmSuggestion") to
15907	// unconditionally include in API requests. By default, fields with
15908	// empty or default values are omitted from API requests. However, any
15909	// non-pointer, non-interface field appearing in ForceSendFields will be
15910	// sent to the server regardless of whether the field is empty or not.
15911	// This may be used to include empty fields in Patch requests.
15912	ForceSendFields []string `json:"-"`
15913
15914	// NullFields is a list of field names (e.g. "RbmSuggestion") to include
15915	// in API requests with the JSON null value. By default, fields with
15916	// empty values are omitted from API requests. However, any field with
15917	// an empty value appearing in NullFields will be sent to the server as
15918	// null. It is an error if a field in this list has a non-empty value.
15919	// This may be used to include null fields in Patch requests.
15920	NullFields []string `json:"-"`
15921}
15922
15923func (s *GoogleCloudDialogflowV2beta1IntentMessageRbmText) MarshalJSON() ([]byte, error) {
15924	type NoMethod GoogleCloudDialogflowV2beta1IntentMessageRbmText
15925	raw := NoMethod(*s)
15926	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
15927}
15928
15929// GoogleCloudDialogflowV2beta1IntentMessageSelectItemInfo: Additional
15930// info about the select item for when it is triggered in a dialog.
15931type GoogleCloudDialogflowV2beta1IntentMessageSelectItemInfo struct {
15932	// Key: Required. A unique key that will be sent back to the agent if
15933	// this response is given.
15934	Key string `json:"key,omitempty"`
15935
15936	// Synonyms: Optional. A list of synonyms that can also be used to
15937	// trigger this item in dialog.
15938	Synonyms []string `json:"synonyms,omitempty"`
15939
15940	// ForceSendFields is a list of field names (e.g. "Key") to
15941	// unconditionally include in API requests. By default, fields with
15942	// empty or default values are omitted from API requests. However, any
15943	// non-pointer, non-interface field appearing in ForceSendFields will be
15944	// sent to the server regardless of whether the field is empty or not.
15945	// This may be used to include empty fields in Patch requests.
15946	ForceSendFields []string `json:"-"`
15947
15948	// NullFields is a list of field names (e.g. "Key") to include in API
15949	// requests with the JSON null value. By default, fields with empty
15950	// values are omitted from API requests. However, any field with an
15951	// empty value appearing in NullFields will be sent to the server as
15952	// null. It is an error if a field in this list has a non-empty value.
15953	// This may be used to include null fields in Patch requests.
15954	NullFields []string `json:"-"`
15955}
15956
15957func (s *GoogleCloudDialogflowV2beta1IntentMessageSelectItemInfo) MarshalJSON() ([]byte, error) {
15958	type NoMethod GoogleCloudDialogflowV2beta1IntentMessageSelectItemInfo
15959	raw := NoMethod(*s)
15960	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
15961}
15962
15963// GoogleCloudDialogflowV2beta1IntentMessageSimpleResponse: The simple
15964// response message containing speech or text.
15965type GoogleCloudDialogflowV2beta1IntentMessageSimpleResponse struct {
15966	// DisplayText: Optional. The text to display.
15967	DisplayText string `json:"displayText,omitempty"`
15968
15969	// Ssml: One of text_to_speech or ssml must be provided. Structured
15970	// spoken response to the user in the SSML format. Mutually exclusive
15971	// with text_to_speech.
15972	Ssml string `json:"ssml,omitempty"`
15973
15974	// TextToSpeech: One of text_to_speech or ssml must be provided. The
15975	// plain text of the speech output. Mutually exclusive with ssml.
15976	TextToSpeech string `json:"textToSpeech,omitempty"`
15977
15978	// ForceSendFields is a list of field names (e.g. "DisplayText") to
15979	// unconditionally include in API requests. By default, fields with
15980	// empty or default values are omitted from API requests. However, any
15981	// non-pointer, non-interface field appearing in ForceSendFields will be
15982	// sent to the server regardless of whether the field is empty or not.
15983	// This may be used to include empty fields in Patch requests.
15984	ForceSendFields []string `json:"-"`
15985
15986	// NullFields is a list of field names (e.g. "DisplayText") to include
15987	// in API requests with the JSON null value. By default, fields with
15988	// empty values are omitted from API requests. However, any field with
15989	// an empty value appearing in NullFields will be sent to the server as
15990	// null. It is an error if a field in this list has a non-empty value.
15991	// This may be used to include null fields in Patch requests.
15992	NullFields []string `json:"-"`
15993}
15994
15995func (s *GoogleCloudDialogflowV2beta1IntentMessageSimpleResponse) MarshalJSON() ([]byte, error) {
15996	type NoMethod GoogleCloudDialogflowV2beta1IntentMessageSimpleResponse
15997	raw := NoMethod(*s)
15998	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
15999}
16000
16001// GoogleCloudDialogflowV2beta1IntentMessageSimpleResponses: The
16002// collection of simple response candidates. This message in
16003// `QueryResult.fulfillment_messages` and
16004// `WebhookResponse.fulfillment_messages` should contain only one
16005// `SimpleResponse`.
16006type GoogleCloudDialogflowV2beta1IntentMessageSimpleResponses struct {
16007	// SimpleResponses: Required. The list of simple responses.
16008	SimpleResponses []*GoogleCloudDialogflowV2beta1IntentMessageSimpleResponse `json:"simpleResponses,omitempty"`
16009
16010	// ForceSendFields is a list of field names (e.g. "SimpleResponses") to
16011	// unconditionally include in API requests. By default, fields with
16012	// empty or default values are omitted from API requests. However, any
16013	// non-pointer, non-interface field appearing in ForceSendFields will be
16014	// sent to the server regardless of whether the field is empty or not.
16015	// This may be used to include empty fields in Patch requests.
16016	ForceSendFields []string `json:"-"`
16017
16018	// NullFields is a list of field names (e.g. "SimpleResponses") to
16019	// include in API requests with the JSON null value. By default, fields
16020	// with empty values are omitted from API requests. However, any field
16021	// with an empty value appearing in NullFields will be sent to the
16022	// server as null. It is an error if a field in this list has a
16023	// non-empty value. This may be used to include null fields in Patch
16024	// requests.
16025	NullFields []string `json:"-"`
16026}
16027
16028func (s *GoogleCloudDialogflowV2beta1IntentMessageSimpleResponses) MarshalJSON() ([]byte, error) {
16029	type NoMethod GoogleCloudDialogflowV2beta1IntentMessageSimpleResponses
16030	raw := NoMethod(*s)
16031	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
16032}
16033
16034// GoogleCloudDialogflowV2beta1IntentMessageSuggestion: The suggestion
16035// chip message that the user can tap to quickly post a reply to the
16036// conversation.
16037type GoogleCloudDialogflowV2beta1IntentMessageSuggestion struct {
16038	// Title: Required. The text shown the in the suggestion chip.
16039	Title string `json:"title,omitempty"`
16040
16041	// ForceSendFields is a list of field names (e.g. "Title") to
16042	// unconditionally include in API requests. By default, fields with
16043	// empty or default values are omitted from API requests. However, any
16044	// non-pointer, non-interface field appearing in ForceSendFields will be
16045	// sent to the server regardless of whether the field is empty or not.
16046	// This may be used to include empty fields in Patch requests.
16047	ForceSendFields []string `json:"-"`
16048
16049	// NullFields is a list of field names (e.g. "Title") to include in API
16050	// requests with the JSON null value. By default, fields with empty
16051	// values are omitted from API requests. However, any field with an
16052	// empty value appearing in NullFields will be sent to the server as
16053	// null. It is an error if a field in this list has a non-empty value.
16054	// This may be used to include null fields in Patch requests.
16055	NullFields []string `json:"-"`
16056}
16057
16058func (s *GoogleCloudDialogflowV2beta1IntentMessageSuggestion) MarshalJSON() ([]byte, error) {
16059	type NoMethod GoogleCloudDialogflowV2beta1IntentMessageSuggestion
16060	raw := NoMethod(*s)
16061	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
16062}
16063
16064// GoogleCloudDialogflowV2beta1IntentMessageSuggestions: The collection
16065// of suggestions.
16066type GoogleCloudDialogflowV2beta1IntentMessageSuggestions struct {
16067	// Suggestions: Required. The list of suggested replies.
16068	Suggestions []*GoogleCloudDialogflowV2beta1IntentMessageSuggestion `json:"suggestions,omitempty"`
16069
16070	// ForceSendFields is a list of field names (e.g. "Suggestions") to
16071	// unconditionally include in API requests. By default, fields with
16072	// empty or default values are omitted from API requests. However, any
16073	// non-pointer, non-interface field appearing in ForceSendFields will be
16074	// sent to the server regardless of whether the field is empty or not.
16075	// This may be used to include empty fields in Patch requests.
16076	ForceSendFields []string `json:"-"`
16077
16078	// NullFields is a list of field names (e.g. "Suggestions") to include
16079	// in API requests with the JSON null value. By default, fields with
16080	// empty values are omitted from API requests. However, any field with
16081	// an empty value appearing in NullFields will be sent to the server as
16082	// null. It is an error if a field in this list has a non-empty value.
16083	// This may be used to include null fields in Patch requests.
16084	NullFields []string `json:"-"`
16085}
16086
16087func (s *GoogleCloudDialogflowV2beta1IntentMessageSuggestions) MarshalJSON() ([]byte, error) {
16088	type NoMethod GoogleCloudDialogflowV2beta1IntentMessageSuggestions
16089	raw := NoMethod(*s)
16090	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
16091}
16092
16093// GoogleCloudDialogflowV2beta1IntentMessageTableCard: Table card for
16094// Actions on Google.
16095type GoogleCloudDialogflowV2beta1IntentMessageTableCard struct {
16096	// Buttons: Optional. List of buttons for the card.
16097	Buttons []*GoogleCloudDialogflowV2beta1IntentMessageBasicCardButton `json:"buttons,omitempty"`
16098
16099	// ColumnProperties: Optional. Display properties for the columns in
16100	// this table.
16101	ColumnProperties []*GoogleCloudDialogflowV2beta1IntentMessageColumnProperties `json:"columnProperties,omitempty"`
16102
16103	// Image: Optional. Image which should be displayed on the card.
16104	Image *GoogleCloudDialogflowV2beta1IntentMessageImage `json:"image,omitempty"`
16105
16106	// Rows: Optional. Rows in this table of data.
16107	Rows []*GoogleCloudDialogflowV2beta1IntentMessageTableCardRow `json:"rows,omitempty"`
16108
16109	// Subtitle: Optional. Subtitle to the title.
16110	Subtitle string `json:"subtitle,omitempty"`
16111
16112	// Title: Required. Title of the card.
16113	Title string `json:"title,omitempty"`
16114
16115	// ForceSendFields is a list of field names (e.g. "Buttons") to
16116	// unconditionally include in API requests. By default, fields with
16117	// empty or default values are omitted from API requests. However, any
16118	// non-pointer, non-interface field appearing in ForceSendFields will be
16119	// sent to the server regardless of whether the field is empty or not.
16120	// This may be used to include empty fields in Patch requests.
16121	ForceSendFields []string `json:"-"`
16122
16123	// NullFields is a list of field names (e.g. "Buttons") to include in
16124	// API requests with the JSON null value. By default, fields with empty
16125	// values are omitted from API requests. However, any field with an
16126	// empty value appearing in NullFields will be sent to the server as
16127	// null. It is an error if a field in this list has a non-empty value.
16128	// This may be used to include null fields in Patch requests.
16129	NullFields []string `json:"-"`
16130}
16131
16132func (s *GoogleCloudDialogflowV2beta1IntentMessageTableCard) MarshalJSON() ([]byte, error) {
16133	type NoMethod GoogleCloudDialogflowV2beta1IntentMessageTableCard
16134	raw := NoMethod(*s)
16135	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
16136}
16137
16138// GoogleCloudDialogflowV2beta1IntentMessageTableCardCell: Cell of
16139// TableCardRow.
16140type GoogleCloudDialogflowV2beta1IntentMessageTableCardCell struct {
16141	// Text: Required. Text in this cell.
16142	Text string `json:"text,omitempty"`
16143
16144	// ForceSendFields is a list of field names (e.g. "Text") to
16145	// unconditionally include in API requests. By default, fields with
16146	// empty or default values are omitted from API requests. However, any
16147	// non-pointer, non-interface field appearing in ForceSendFields will be
16148	// sent to the server regardless of whether the field is empty or not.
16149	// This may be used to include empty fields in Patch requests.
16150	ForceSendFields []string `json:"-"`
16151
16152	// NullFields is a list of field names (e.g. "Text") to include in API
16153	// requests with the JSON null value. By default, fields with empty
16154	// values are omitted from API requests. However, any field with an
16155	// empty value appearing in NullFields will be sent to the server as
16156	// null. It is an error if a field in this list has a non-empty value.
16157	// This may be used to include null fields in Patch requests.
16158	NullFields []string `json:"-"`
16159}
16160
16161func (s *GoogleCloudDialogflowV2beta1IntentMessageTableCardCell) MarshalJSON() ([]byte, error) {
16162	type NoMethod GoogleCloudDialogflowV2beta1IntentMessageTableCardCell
16163	raw := NoMethod(*s)
16164	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
16165}
16166
16167// GoogleCloudDialogflowV2beta1IntentMessageTableCardRow: Row of
16168// TableCard.
16169type GoogleCloudDialogflowV2beta1IntentMessageTableCardRow struct {
16170	// Cells: Optional. List of cells that make up this row.
16171	Cells []*GoogleCloudDialogflowV2beta1IntentMessageTableCardCell `json:"cells,omitempty"`
16172
16173	// DividerAfter: Optional. Whether to add a visual divider after this
16174	// row.
16175	DividerAfter bool `json:"dividerAfter,omitempty"`
16176
16177	// ForceSendFields is a list of field names (e.g. "Cells") to
16178	// unconditionally include in API requests. By default, fields with
16179	// empty or default values are omitted from API requests. However, any
16180	// non-pointer, non-interface field appearing in ForceSendFields will be
16181	// sent to the server regardless of whether the field is empty or not.
16182	// This may be used to include empty fields in Patch requests.
16183	ForceSendFields []string `json:"-"`
16184
16185	// NullFields is a list of field names (e.g. "Cells") to include in API
16186	// requests with the JSON null value. By default, fields with empty
16187	// values are omitted from API requests. However, any field with an
16188	// empty value appearing in NullFields will be sent to the server as
16189	// null. It is an error if a field in this list has a non-empty value.
16190	// This may be used to include null fields in Patch requests.
16191	NullFields []string `json:"-"`
16192}
16193
16194func (s *GoogleCloudDialogflowV2beta1IntentMessageTableCardRow) MarshalJSON() ([]byte, error) {
16195	type NoMethod GoogleCloudDialogflowV2beta1IntentMessageTableCardRow
16196	raw := NoMethod(*s)
16197	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
16198}
16199
16200// GoogleCloudDialogflowV2beta1IntentMessageTelephonyPlayAudio: Plays
16201// audio from a file in Telephony Gateway.
16202type GoogleCloudDialogflowV2beta1IntentMessageTelephonyPlayAudio struct {
16203	// AudioUri: Required. URI to a Google Cloud Storage object containing
16204	// the audio to play, e.g., "gs://bucket/object". The object must
16205	// contain a single channel (mono) of linear PCM audio (2 bytes /
16206	// sample) at 8kHz. This object must be readable by the
16207	// `service-@gcp-sa-dialogflow.iam.gserviceaccount.com` service account
16208	// where is the number of the Telephony Gateway project (usually the
16209	// same as the Dialogflow agent project). If the Google Cloud Storage
16210	// bucket is in the Telephony Gateway project, this permission is added
16211	// by default when enabling the Dialogflow V2 API. For audio from other
16212	// sources, consider using the `TelephonySynthesizeSpeech` message with
16213	// SSML.
16214	AudioUri string `json:"audioUri,omitempty"`
16215
16216	// ForceSendFields is a list of field names (e.g. "AudioUri") to
16217	// unconditionally include in API requests. By default, fields with
16218	// empty or default values are omitted from API requests. However, any
16219	// non-pointer, non-interface field appearing in ForceSendFields will be
16220	// sent to the server regardless of whether the field is empty or not.
16221	// This may be used to include empty fields in Patch requests.
16222	ForceSendFields []string `json:"-"`
16223
16224	// NullFields is a list of field names (e.g. "AudioUri") to include in
16225	// API requests with the JSON null value. By default, fields with empty
16226	// values are omitted from API requests. However, any field with an
16227	// empty value appearing in NullFields will be sent to the server as
16228	// null. It is an error if a field in this list has a non-empty value.
16229	// This may be used to include null fields in Patch requests.
16230	NullFields []string `json:"-"`
16231}
16232
16233func (s *GoogleCloudDialogflowV2beta1IntentMessageTelephonyPlayAudio) MarshalJSON() ([]byte, error) {
16234	type NoMethod GoogleCloudDialogflowV2beta1IntentMessageTelephonyPlayAudio
16235	raw := NoMethod(*s)
16236	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
16237}
16238
16239// GoogleCloudDialogflowV2beta1IntentMessageTelephonySynthesizeSpeech:
16240// Synthesizes speech and plays back the synthesized audio to the caller
16241// in Telephony Gateway. Telephony Gateway takes the synthesizer
16242// settings from `DetectIntentResponse.output_audio_config` which can
16243// either be set at request-level or can come from the agent-level
16244// synthesizer config.
16245type GoogleCloudDialogflowV2beta1IntentMessageTelephonySynthesizeSpeech struct {
16246	// Ssml: The SSML to be synthesized. For more information, see SSML
16247	// (https://developers.google.com/actions/reference/ssml).
16248	Ssml string `json:"ssml,omitempty"`
16249
16250	// Text: The raw text to be synthesized.
16251	Text string `json:"text,omitempty"`
16252
16253	// ForceSendFields is a list of field names (e.g. "Ssml") to
16254	// unconditionally include in API requests. By default, fields with
16255	// empty or default values are omitted from API requests. However, any
16256	// non-pointer, non-interface field appearing in ForceSendFields will be
16257	// sent to the server regardless of whether the field is empty or not.
16258	// This may be used to include empty fields in Patch requests.
16259	ForceSendFields []string `json:"-"`
16260
16261	// NullFields is a list of field names (e.g. "Ssml") to include in API
16262	// requests with the JSON null value. By default, fields with empty
16263	// values are omitted from API requests. However, any field with an
16264	// empty value appearing in NullFields will be sent to the server as
16265	// null. It is an error if a field in this list has a non-empty value.
16266	// This may be used to include null fields in Patch requests.
16267	NullFields []string `json:"-"`
16268}
16269
16270func (s *GoogleCloudDialogflowV2beta1IntentMessageTelephonySynthesizeSpeech) MarshalJSON() ([]byte, error) {
16271	type NoMethod GoogleCloudDialogflowV2beta1IntentMessageTelephonySynthesizeSpeech
16272	raw := NoMethod(*s)
16273	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
16274}
16275
16276// GoogleCloudDialogflowV2beta1IntentMessageTelephonyTransferCall:
16277// Transfers the call in Telephony Gateway.
16278type GoogleCloudDialogflowV2beta1IntentMessageTelephonyTransferCall struct {
16279	// PhoneNumber: Required. The phone number to transfer the call to in
16280	// E.164 format (https://en.wikipedia.org/wiki/E.164). We currently only
16281	// allow transferring to US numbers (+1xxxyyyzzzz).
16282	PhoneNumber string `json:"phoneNumber,omitempty"`
16283
16284	// ForceSendFields is a list of field names (e.g. "PhoneNumber") to
16285	// unconditionally include in API requests. By default, fields with
16286	// empty or default values are omitted from API requests. However, any
16287	// non-pointer, non-interface field appearing in ForceSendFields will be
16288	// sent to the server regardless of whether the field is empty or not.
16289	// This may be used to include empty fields in Patch requests.
16290	ForceSendFields []string `json:"-"`
16291
16292	// NullFields is a list of field names (e.g. "PhoneNumber") to include
16293	// in API requests with the JSON null value. By default, fields with
16294	// empty values are omitted from API requests. However, any field with
16295	// an empty value appearing in NullFields will be sent to the server as
16296	// null. It is an error if a field in this list has a non-empty value.
16297	// This may be used to include null fields in Patch requests.
16298	NullFields []string `json:"-"`
16299}
16300
16301func (s *GoogleCloudDialogflowV2beta1IntentMessageTelephonyTransferCall) MarshalJSON() ([]byte, error) {
16302	type NoMethod GoogleCloudDialogflowV2beta1IntentMessageTelephonyTransferCall
16303	raw := NoMethod(*s)
16304	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
16305}
16306
16307// GoogleCloudDialogflowV2beta1IntentMessageText: The text response
16308// message.
16309type GoogleCloudDialogflowV2beta1IntentMessageText struct {
16310	// Text: Optional. The collection of the agent's responses.
16311	Text []string `json:"text,omitempty"`
16312
16313	// ForceSendFields is a list of field names (e.g. "Text") to
16314	// unconditionally include in API requests. By default, fields with
16315	// empty or default values are omitted from API requests. However, any
16316	// non-pointer, non-interface field appearing in ForceSendFields will be
16317	// sent to the server regardless of whether the field is empty or not.
16318	// This may be used to include empty fields in Patch requests.
16319	ForceSendFields []string `json:"-"`
16320
16321	// NullFields is a list of field names (e.g. "Text") to include in API
16322	// requests with the JSON null value. By default, fields with empty
16323	// values are omitted from API requests. However, any field with an
16324	// empty value appearing in NullFields will be sent to the server as
16325	// null. It is an error if a field in this list has a non-empty value.
16326	// This may be used to include null fields in Patch requests.
16327	NullFields []string `json:"-"`
16328}
16329
16330func (s *GoogleCloudDialogflowV2beta1IntentMessageText) MarshalJSON() ([]byte, error) {
16331	type NoMethod GoogleCloudDialogflowV2beta1IntentMessageText
16332	raw := NoMethod(*s)
16333	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
16334}
16335
16336// GoogleCloudDialogflowV2beta1IntentParameter: Represents intent
16337// parameters.
16338type GoogleCloudDialogflowV2beta1IntentParameter struct {
16339	// DefaultValue: Optional. The default value to use when the `value`
16340	// yields an empty result. Default values can be extracted from contexts
16341	// by using the following syntax: `#context_name.parameter_name`.
16342	DefaultValue string `json:"defaultValue,omitempty"`
16343
16344	// DisplayName: Required. The name of the parameter.
16345	DisplayName string `json:"displayName,omitempty"`
16346
16347	// EntityTypeDisplayName: Optional. The name of the entity type,
16348	// prefixed with `@`, that describes values of the parameter. If the
16349	// parameter is required, this must be provided.
16350	EntityTypeDisplayName string `json:"entityTypeDisplayName,omitempty"`
16351
16352	// IsList: Optional. Indicates whether the parameter represents a list
16353	// of values.
16354	IsList bool `json:"isList,omitempty"`
16355
16356	// Mandatory: Optional. Indicates whether the parameter is required.
16357	// That is, whether the intent cannot be completed without collecting
16358	// the parameter value.
16359	Mandatory bool `json:"mandatory,omitempty"`
16360
16361	// Name: The unique identifier of this parameter.
16362	Name string `json:"name,omitempty"`
16363
16364	// Prompts: Optional. The collection of prompts that the agent can
16365	// present to the user in order to collect a value for the parameter.
16366	Prompts []string `json:"prompts,omitempty"`
16367
16368	// Value: Optional. The definition of the parameter value. It can be: -
16369	// a constant string, - a parameter value defined as `$parameter_name`,
16370	// - an original parameter value defined as `$parameter_name.original`,
16371	// - a parameter value from some context defined as
16372	// `#context_name.parameter_name`.
16373	Value string `json:"value,omitempty"`
16374
16375	// ForceSendFields is a list of field names (e.g. "DefaultValue") to
16376	// unconditionally include in API requests. By default, fields with
16377	// empty or default values are omitted from API requests. However, any
16378	// non-pointer, non-interface field appearing in ForceSendFields will be
16379	// sent to the server regardless of whether the field is empty or not.
16380	// This may be used to include empty fields in Patch requests.
16381	ForceSendFields []string `json:"-"`
16382
16383	// NullFields is a list of field names (e.g. "DefaultValue") to include
16384	// in API requests with the JSON null value. By default, fields with
16385	// empty values are omitted from API requests. However, any field with
16386	// an empty value appearing in NullFields will be sent to the server as
16387	// null. It is an error if a field in this list has a non-empty value.
16388	// This may be used to include null fields in Patch requests.
16389	NullFields []string `json:"-"`
16390}
16391
16392func (s *GoogleCloudDialogflowV2beta1IntentParameter) MarshalJSON() ([]byte, error) {
16393	type NoMethod GoogleCloudDialogflowV2beta1IntentParameter
16394	raw := NoMethod(*s)
16395	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
16396}
16397
16398// GoogleCloudDialogflowV2beta1IntentTrainingPhrase: Represents an
16399// example that the agent is trained on.
16400type GoogleCloudDialogflowV2beta1IntentTrainingPhrase struct {
16401	// Name: Output only. The unique identifier of this training phrase.
16402	Name string `json:"name,omitempty"`
16403
16404	// Parts: Required. The ordered list of training phrase parts. The parts
16405	// are concatenated in order to form the training phrase. Note: The API
16406	// does not automatically annotate training phrases like the Dialogflow
16407	// Console does. Note: Do not forget to include whitespace at part
16408	// boundaries, so the training phrase is well formatted when the parts
16409	// are concatenated. If the training phrase does not need to be
16410	// annotated with parameters, you just need a single part with only the
16411	// Part.text field set. If you want to annotate the training phrase, you
16412	// must create multiple parts, where the fields of each part are
16413	// populated in one of two ways: - `Part.text` is set to a part of the
16414	// phrase that has no parameters. - `Part.text` is set to a part of the
16415	// phrase that you want to annotate, and the `entity_type`, `alias`, and
16416	// `user_defined` fields are all set.
16417	Parts []*GoogleCloudDialogflowV2beta1IntentTrainingPhrasePart `json:"parts,omitempty"`
16418
16419	// TimesAddedCount: Optional. Indicates how many times this example was
16420	// added to the intent. Each time a developer adds an existing sample by
16421	// editing an intent or training, this counter is increased.
16422	TimesAddedCount int64 `json:"timesAddedCount,omitempty"`
16423
16424	// Type: Required. The type of the training phrase.
16425	//
16426	// Possible values:
16427	//   "TYPE_UNSPECIFIED" - Not specified. This value should never be
16428	// used.
16429	//   "EXAMPLE" - Examples do not contain @-prefixed entity type names,
16430	// but example parts can be annotated with entity types.
16431	//   "TEMPLATE" - Templates are not annotated with entity types, but
16432	// they can contain @-prefixed entity type names as substrings. Template
16433	// mode has been deprecated. Example mode is the only supported way to
16434	// create new training phrases. If you have existing training phrases
16435	// that you've created in template mode, those will continue to work.
16436	Type string `json:"type,omitempty"`
16437
16438	// ForceSendFields is a list of field names (e.g. "Name") to
16439	// unconditionally include in API requests. By default, fields with
16440	// empty or default values are omitted from API requests. However, any
16441	// non-pointer, non-interface field appearing in ForceSendFields will be
16442	// sent to the server regardless of whether the field is empty or not.
16443	// This may be used to include empty fields in Patch requests.
16444	ForceSendFields []string `json:"-"`
16445
16446	// NullFields is a list of field names (e.g. "Name") to include in API
16447	// requests with the JSON null value. By default, fields with empty
16448	// values are omitted from API requests. However, any field with an
16449	// empty value appearing in NullFields will be sent to the server as
16450	// null. It is an error if a field in this list has a non-empty value.
16451	// This may be used to include null fields in Patch requests.
16452	NullFields []string `json:"-"`
16453}
16454
16455func (s *GoogleCloudDialogflowV2beta1IntentTrainingPhrase) MarshalJSON() ([]byte, error) {
16456	type NoMethod GoogleCloudDialogflowV2beta1IntentTrainingPhrase
16457	raw := NoMethod(*s)
16458	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
16459}
16460
16461// GoogleCloudDialogflowV2beta1IntentTrainingPhrasePart: Represents a
16462// part of a training phrase.
16463type GoogleCloudDialogflowV2beta1IntentTrainingPhrasePart struct {
16464	// Alias: Optional. The parameter name for the value extracted from the
16465	// annotated part of the example. This field is required for annotated
16466	// parts of the training phrase.
16467	Alias string `json:"alias,omitempty"`
16468
16469	// EntityType: Optional. The entity type name prefixed with `@`. This
16470	// field is required for annotated parts of the training phrase.
16471	EntityType string `json:"entityType,omitempty"`
16472
16473	// Text: Required. The text for this part.
16474	Text string `json:"text,omitempty"`
16475
16476	// UserDefined: Optional. Indicates whether the text was manually
16477	// annotated. This field is set to true when the Dialogflow Console is
16478	// used to manually annotate the part. When creating an annotated part
16479	// with the API, you must set this to true.
16480	UserDefined bool `json:"userDefined,omitempty"`
16481
16482	// ForceSendFields is a list of field names (e.g. "Alias") to
16483	// unconditionally include in API requests. By default, fields with
16484	// empty or default values are omitted from API requests. However, any
16485	// non-pointer, non-interface field appearing in ForceSendFields will be
16486	// sent to the server regardless of whether the field is empty or not.
16487	// This may be used to include empty fields in Patch requests.
16488	ForceSendFields []string `json:"-"`
16489
16490	// NullFields is a list of field names (e.g. "Alias") to include in API
16491	// requests with the JSON null value. By default, fields with empty
16492	// values are omitted from API requests. However, any field with an
16493	// empty value appearing in NullFields will be sent to the server as
16494	// null. It is an error if a field in this list has a non-empty value.
16495	// This may be used to include null fields in Patch requests.
16496	NullFields []string `json:"-"`
16497}
16498
16499func (s *GoogleCloudDialogflowV2beta1IntentTrainingPhrasePart) MarshalJSON() ([]byte, error) {
16500	type NoMethod GoogleCloudDialogflowV2beta1IntentTrainingPhrasePart
16501	raw := NoMethod(*s)
16502	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
16503}
16504
16505// GoogleCloudDialogflowV2beta1KnowledgeAnswers: Represents the result
16506// of querying a Knowledge base.
16507type GoogleCloudDialogflowV2beta1KnowledgeAnswers struct {
16508	// Answers: A list of answers from Knowledge Connector.
16509	Answers []*GoogleCloudDialogflowV2beta1KnowledgeAnswersAnswer `json:"answers,omitempty"`
16510
16511	// ForceSendFields is a list of field names (e.g. "Answers") to
16512	// unconditionally include in API requests. By default, fields with
16513	// empty or default values are omitted from API requests. However, any
16514	// non-pointer, non-interface field appearing in ForceSendFields will be
16515	// sent to the server regardless of whether the field is empty or not.
16516	// This may be used to include empty fields in Patch requests.
16517	ForceSendFields []string `json:"-"`
16518
16519	// NullFields is a list of field names (e.g. "Answers") to include in
16520	// API requests with the JSON null value. By default, fields with empty
16521	// values are omitted from API requests. However, any field with an
16522	// empty value appearing in NullFields will be sent to the server as
16523	// null. It is an error if a field in this list has a non-empty value.
16524	// This may be used to include null fields in Patch requests.
16525	NullFields []string `json:"-"`
16526}
16527
16528func (s *GoogleCloudDialogflowV2beta1KnowledgeAnswers) MarshalJSON() ([]byte, error) {
16529	type NoMethod GoogleCloudDialogflowV2beta1KnowledgeAnswers
16530	raw := NoMethod(*s)
16531	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
16532}
16533
16534// GoogleCloudDialogflowV2beta1KnowledgeAnswersAnswer: An answer from
16535// Knowledge Connector.
16536type GoogleCloudDialogflowV2beta1KnowledgeAnswersAnswer struct {
16537	// Answer: The piece of text from the `source` knowledge base document
16538	// that answers this conversational query.
16539	Answer string `json:"answer,omitempty"`
16540
16541	// FaqQuestion: The corresponding FAQ question if the answer was
16542	// extracted from a FAQ Document, empty otherwise.
16543	FaqQuestion string `json:"faqQuestion,omitempty"`
16544
16545	// MatchConfidence: The system's confidence score that this Knowledge
16546	// answer is a good match for this conversational query. The range is
16547	// from 0.0 (completely uncertain) to 1.0 (completely certain). Note:
16548	// The confidence score is likely to vary somewhat (possibly even for
16549	// identical requests), as the underlying model is under constant
16550	// improvement. It may be deprecated in the future. We recommend using
16551	// `match_confidence_level` which should be generally more stable.
16552	MatchConfidence float64 `json:"matchConfidence,omitempty"`
16553
16554	// MatchConfidenceLevel: The system's confidence level that this
16555	// knowledge answer is a good match for this conversational query. NOTE:
16556	// The confidence level for a given `` pair may change without notice,
16557	// as it depends on models that are constantly being improved. However,
16558	// it will change less frequently than the confidence score below, and
16559	// should be preferred for referencing the quality of an answer.
16560	//
16561	// Possible values:
16562	//   "MATCH_CONFIDENCE_LEVEL_UNSPECIFIED" - Not specified.
16563	//   "LOW" - Indicates that the confidence is low.
16564	//   "MEDIUM" - Indicates our confidence is medium.
16565	//   "HIGH" - Indicates our confidence is high.
16566	MatchConfidenceLevel string `json:"matchConfidenceLevel,omitempty"`
16567
16568	// Source: Indicates which Knowledge Document this answer was extracted
16569	// from. Format: `projects//knowledgeBases//documents/`.
16570	Source string `json:"source,omitempty"`
16571
16572	// ForceSendFields is a list of field names (e.g. "Answer") to
16573	// unconditionally include in API requests. By default, fields with
16574	// empty or default values are omitted from API requests. However, any
16575	// non-pointer, non-interface field appearing in ForceSendFields will be
16576	// sent to the server regardless of whether the field is empty or not.
16577	// This may be used to include empty fields in Patch requests.
16578	ForceSendFields []string `json:"-"`
16579
16580	// NullFields is a list of field names (e.g. "Answer") to include in API
16581	// requests with the JSON null value. By default, fields with empty
16582	// values are omitted from API requests. However, any field with an
16583	// empty value appearing in NullFields will be sent to the server as
16584	// null. It is an error if a field in this list has a non-empty value.
16585	// This may be used to include null fields in Patch requests.
16586	NullFields []string `json:"-"`
16587}
16588
16589func (s *GoogleCloudDialogflowV2beta1KnowledgeAnswersAnswer) MarshalJSON() ([]byte, error) {
16590	type NoMethod GoogleCloudDialogflowV2beta1KnowledgeAnswersAnswer
16591	raw := NoMethod(*s)
16592	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
16593}
16594
16595func (s *GoogleCloudDialogflowV2beta1KnowledgeAnswersAnswer) UnmarshalJSON(data []byte) error {
16596	type NoMethod GoogleCloudDialogflowV2beta1KnowledgeAnswersAnswer
16597	var s1 struct {
16598		MatchConfidence gensupport.JSONFloat64 `json:"matchConfidence"`
16599		*NoMethod
16600	}
16601	s1.NoMethod = (*NoMethod)(s)
16602	if err := json.Unmarshal(data, &s1); err != nil {
16603		return err
16604	}
16605	s.MatchConfidence = float64(s1.MatchConfidence)
16606	return nil
16607}
16608
16609// GoogleCloudDialogflowV2beta1KnowledgeOperationMetadata: Metadata in
16610// google::longrunning::Operation for Knowledge operations.
16611type GoogleCloudDialogflowV2beta1KnowledgeOperationMetadata struct {
16612	// State: Required. Output only. The current state of this operation.
16613	//
16614	// Possible values:
16615	//   "STATE_UNSPECIFIED" - State unspecified.
16616	//   "PENDING" - The operation has been created.
16617	//   "RUNNING" - The operation is currently running.
16618	//   "DONE" - The operation is done, either cancelled or completed.
16619	State string `json:"state,omitempty"`
16620
16621	// ForceSendFields is a list of field names (e.g. "State") to
16622	// unconditionally include in API requests. By default, fields with
16623	// empty or default values are omitted from API requests. However, any
16624	// non-pointer, non-interface field appearing in ForceSendFields will be
16625	// sent to the server regardless of whether the field is empty or not.
16626	// This may be used to include empty fields in Patch requests.
16627	ForceSendFields []string `json:"-"`
16628
16629	// NullFields is a list of field names (e.g. "State") to include in API
16630	// requests with the JSON null value. By default, fields with empty
16631	// values are omitted from API requests. However, any field with an
16632	// empty value appearing in NullFields will be sent to the server as
16633	// null. It is an error if a field in this list has a non-empty value.
16634	// This may be used to include null fields in Patch requests.
16635	NullFields []string `json:"-"`
16636}
16637
16638func (s *GoogleCloudDialogflowV2beta1KnowledgeOperationMetadata) MarshalJSON() ([]byte, error) {
16639	type NoMethod GoogleCloudDialogflowV2beta1KnowledgeOperationMetadata
16640	raw := NoMethod(*s)
16641	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
16642}
16643
16644// GoogleCloudDialogflowV2beta1Message: Represents a message posted into
16645// a conversation.
16646type GoogleCloudDialogflowV2beta1Message struct {
16647	// Content: Required. The message content.
16648	Content string `json:"content,omitempty"`
16649
16650	// CreateTime: Output only. The time when the message was created in
16651	// Contact Center AI.
16652	CreateTime string `json:"createTime,omitempty"`
16653
16654	// LanguageCode: Optional. The message language. This should be a BCP-47
16655	// (https://www.rfc-editor.org/rfc/bcp/bcp47.txt) language tag. Example:
16656	// "en-US".
16657	LanguageCode string `json:"languageCode,omitempty"`
16658
16659	// MessageAnnotation: Output only. The annotation for the message.
16660	MessageAnnotation *GoogleCloudDialogflowV2beta1MessageAnnotation `json:"messageAnnotation,omitempty"`
16661
16662	// Name: Optional. The unique identifier of the message. Format:
16663	// `projects//locations//conversations//messages/`.
16664	Name string `json:"name,omitempty"`
16665
16666	// Participant: Output only. The participant that sends this message.
16667	Participant string `json:"participant,omitempty"`
16668
16669	// ParticipantRole: Output only. The role of the participant.
16670	//
16671	// Possible values:
16672	//   "ROLE_UNSPECIFIED" - Participant role not set.
16673	//   "HUMAN_AGENT" - Participant is a human agent.
16674	//   "AUTOMATED_AGENT" - Participant is an automated agent, such as a
16675	// Dialogflow agent.
16676	//   "END_USER" - Participant is an end user that has called or chatted
16677	// with Dialogflow services.
16678	ParticipantRole string `json:"participantRole,omitempty"`
16679
16680	// SendTime: Optional. The time when the message was sent.
16681	SendTime string `json:"sendTime,omitempty"`
16682
16683	// SentimentAnalysis: Output only. The sentiment analysis result for the
16684	// message.
16685	SentimentAnalysis *GoogleCloudDialogflowV2beta1SentimentAnalysisResult `json:"sentimentAnalysis,omitempty"`
16686
16687	// ForceSendFields is a list of field names (e.g. "Content") to
16688	// unconditionally include in API requests. By default, fields with
16689	// empty or default values are omitted from API requests. However, any
16690	// non-pointer, non-interface field appearing in ForceSendFields will be
16691	// sent to the server regardless of whether the field is empty or not.
16692	// This may be used to include empty fields in Patch requests.
16693	ForceSendFields []string `json:"-"`
16694
16695	// NullFields is a list of field names (e.g. "Content") to include in
16696	// API requests with the JSON null value. By default, fields with empty
16697	// values are omitted from API requests. However, any field with an
16698	// empty value appearing in NullFields will be sent to the server as
16699	// null. It is an error if a field in this list has a non-empty value.
16700	// This may be used to include null fields in Patch requests.
16701	NullFields []string `json:"-"`
16702}
16703
16704func (s *GoogleCloudDialogflowV2beta1Message) MarshalJSON() ([]byte, error) {
16705	type NoMethod GoogleCloudDialogflowV2beta1Message
16706	raw := NoMethod(*s)
16707	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
16708}
16709
16710// GoogleCloudDialogflowV2beta1MessageAnnotation: Represents the result
16711// of annotation for the message.
16712type GoogleCloudDialogflowV2beta1MessageAnnotation struct {
16713	// ContainEntities: Required. Indicates whether the text message
16714	// contains entities.
16715	ContainEntities bool `json:"containEntities,omitempty"`
16716
16717	// Parts: Optional. The collection of annotated message parts ordered by
16718	// their position in the message. You can recover the annotated message
16719	// by concatenating [AnnotatedMessagePart.text].
16720	Parts []*GoogleCloudDialogflowV2beta1AnnotatedMessagePart `json:"parts,omitempty"`
16721
16722	// ForceSendFields is a list of field names (e.g. "ContainEntities") to
16723	// unconditionally include in API requests. By default, fields with
16724	// empty or default values are omitted from API requests. However, any
16725	// non-pointer, non-interface field appearing in ForceSendFields will be
16726	// sent to the server regardless of whether the field is empty or not.
16727	// This may be used to include empty fields in Patch requests.
16728	ForceSendFields []string `json:"-"`
16729
16730	// NullFields is a list of field names (e.g. "ContainEntities") to
16731	// include in API requests with the JSON null value. By default, fields
16732	// with empty values are omitted from API requests. However, any field
16733	// with an empty value appearing in NullFields will be sent to the
16734	// server as null. It is an error if a field in this list has a
16735	// non-empty value. This may be used to include null fields in Patch
16736	// requests.
16737	NullFields []string `json:"-"`
16738}
16739
16740func (s *GoogleCloudDialogflowV2beta1MessageAnnotation) MarshalJSON() ([]byte, error) {
16741	type NoMethod GoogleCloudDialogflowV2beta1MessageAnnotation
16742	raw := NoMethod(*s)
16743	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
16744}
16745
16746// GoogleCloudDialogflowV2beta1OriginalDetectIntentRequest: Represents
16747// the contents of the original request that was passed to the
16748// `[Streaming]DetectIntent` call.
16749type GoogleCloudDialogflowV2beta1OriginalDetectIntentRequest struct {
16750	// Payload: Optional. This field is set to the value of the
16751	// `QueryParameters.payload` field passed in the request. Some
16752	// integrations that query a Dialogflow agent may provide additional
16753	// information in the payload. In particular, for the Dialogflow Phone
16754	// Gateway integration, this field has the form: { "telephony": {
16755	// "caller_id": "+18558363987" } } Note: The caller ID field
16756	// (`caller_id`) will be redacted for Trial Edition agents and populated
16757	// with the caller ID in E.164 format
16758	// (https://en.wikipedia.org/wiki/E.164) for Essentials Edition agents.
16759	Payload googleapi.RawMessage `json:"payload,omitempty"`
16760
16761	// Source: The source of this request, e.g., `google`, `facebook`,
16762	// `slack`. It is set by Dialogflow-owned servers.
16763	Source string `json:"source,omitempty"`
16764
16765	// Version: Optional. The version of the protocol used for this request.
16766	// This field is AoG-specific.
16767	Version string `json:"version,omitempty"`
16768
16769	// ForceSendFields is a list of field names (e.g. "Payload") to
16770	// unconditionally include in API requests. By default, fields with
16771	// empty or default values are omitted from API requests. However, any
16772	// non-pointer, non-interface field appearing in ForceSendFields will be
16773	// sent to the server regardless of whether the field is empty or not.
16774	// This may be used to include empty fields in Patch requests.
16775	ForceSendFields []string `json:"-"`
16776
16777	// NullFields is a list of field names (e.g. "Payload") to include in
16778	// API requests with the JSON null value. By default, fields with empty
16779	// values are omitted from API requests. However, any field with an
16780	// empty value appearing in NullFields will be sent to the server as
16781	// null. It is an error if a field in this list has a non-empty value.
16782	// This may be used to include null fields in Patch requests.
16783	NullFields []string `json:"-"`
16784}
16785
16786func (s *GoogleCloudDialogflowV2beta1OriginalDetectIntentRequest) MarshalJSON() ([]byte, error) {
16787	type NoMethod GoogleCloudDialogflowV2beta1OriginalDetectIntentRequest
16788	raw := NoMethod(*s)
16789	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
16790}
16791
16792// GoogleCloudDialogflowV2beta1QueryResult: Represents the result of
16793// conversational query or event processing.
16794type GoogleCloudDialogflowV2beta1QueryResult struct {
16795	// Action: The action name from the matched intent.
16796	Action string `json:"action,omitempty"`
16797
16798	// AllRequiredParamsPresent: This field is set to: - `false` if the
16799	// matched intent has required parameters and not all of the required
16800	// parameter values have been collected. - `true` if all required
16801	// parameter values have been collected, or if the matched intent
16802	// doesn't contain any required parameters.
16803	AllRequiredParamsPresent bool `json:"allRequiredParamsPresent,omitempty"`
16804
16805	// CancelsSlotFilling: Indicates whether the conversational query
16806	// triggers a cancellation for slot filling.
16807	CancelsSlotFilling bool `json:"cancelsSlotFilling,omitempty"`
16808
16809	// DiagnosticInfo: Free-form diagnostic information for the associated
16810	// detect intent request. The fields of this data can change without
16811	// notice, so you should not write code that depends on its structure.
16812	// The data may contain: - webhook call latency - webhook errors
16813	DiagnosticInfo googleapi.RawMessage `json:"diagnosticInfo,omitempty"`
16814
16815	// FulfillmentMessages: The collection of rich messages to present to
16816	// the user.
16817	FulfillmentMessages []*GoogleCloudDialogflowV2beta1IntentMessage `json:"fulfillmentMessages,omitempty"`
16818
16819	// FulfillmentText: The text to be pronounced to the user or shown on
16820	// the screen. Note: This is a legacy field, `fulfillment_messages`
16821	// should be preferred.
16822	FulfillmentText string `json:"fulfillmentText,omitempty"`
16823
16824	// Intent: The intent that matched the conversational query. Some, not
16825	// all fields are filled in this message, including but not limited to:
16826	// `name`, `display_name`, `end_interaction` and `is_fallback`.
16827	Intent *GoogleCloudDialogflowV2beta1Intent `json:"intent,omitempty"`
16828
16829	// IntentDetectionConfidence: The intent detection confidence. Values
16830	// range from 0.0 (completely uncertain) to 1.0 (completely certain).
16831	// This value is for informational purpose only and is only used to help
16832	// match the best intent within the classification threshold. This value
16833	// may change for the same end-user expression at any time due to a
16834	// model retraining or change in implementation. If there are `multiple
16835	// knowledge_answers` messages, this value is set to the greatest
16836	// `knowledgeAnswers.match_confidence` value in the list.
16837	IntentDetectionConfidence float64 `json:"intentDetectionConfidence,omitempty"`
16838
16839	// KnowledgeAnswers: The result from Knowledge Connector (if any),
16840	// ordered by decreasing `KnowledgeAnswers.match_confidence`.
16841	KnowledgeAnswers *GoogleCloudDialogflowV2beta1KnowledgeAnswers `json:"knowledgeAnswers,omitempty"`
16842
16843	// LanguageCode: The language that was triggered during intent
16844	// detection. See Language Support
16845	// (https://cloud.google.com/dialogflow/docs/reference/language) for a
16846	// list of the currently supported language codes.
16847	LanguageCode string `json:"languageCode,omitempty"`
16848
16849	// OutputContexts: The collection of output contexts. If applicable,
16850	// `output_contexts.parameters` contains entries with name `.original`
16851	// containing the original parameter values before the query.
16852	OutputContexts []*GoogleCloudDialogflowV2beta1Context `json:"outputContexts,omitempty"`
16853
16854	// Parameters: The collection of extracted parameters. Depending on your
16855	// protocol or client library language, this is a map, associative
16856	// array, symbol table, dictionary, or JSON object composed of a
16857	// collection of (MapKey, MapValue) pairs: - MapKey type: string -
16858	// MapKey value: parameter name - MapValue type: - If parameter's entity
16859	// type is a composite entity: map - Else: depending on parameter value
16860	// type, could be one of string, number, boolean, null, list or map -
16861	// MapValue value: - If parameter's entity type is a composite entity:
16862	// map from composite entity property names to property values - Else:
16863	// parameter value
16864	Parameters googleapi.RawMessage `json:"parameters,omitempty"`
16865
16866	// QueryText: The original conversational query text: - If natural
16867	// language text was provided as input, `query_text` contains a copy of
16868	// the input. - If natural language speech audio was provided as input,
16869	// `query_text` contains the speech recognition result. If speech
16870	// recognizer produced multiple alternatives, a particular one is
16871	// picked. - If automatic spell correction is enabled, `query_text` will
16872	// contain the corrected user input.
16873	QueryText string `json:"queryText,omitempty"`
16874
16875	// SentimentAnalysisResult: The sentiment analysis result, which depends
16876	// on the `sentiment_analysis_request_config` specified in the request.
16877	SentimentAnalysisResult *GoogleCloudDialogflowV2beta1SentimentAnalysisResult `json:"sentimentAnalysisResult,omitempty"`
16878
16879	// SpeechRecognitionConfidence: The Speech recognition confidence
16880	// between 0.0 and 1.0. A higher number indicates an estimated greater
16881	// likelihood that the recognized words are correct. The default of 0.0
16882	// is a sentinel value indicating that confidence was not set. This
16883	// field is not guaranteed to be accurate or set. In particular this
16884	// field isn't set for StreamingDetectIntent since the streaming
16885	// endpoint has separate confidence estimates per portion of the audio
16886	// in StreamingRecognitionResult.
16887	SpeechRecognitionConfidence float64 `json:"speechRecognitionConfidence,omitempty"`
16888
16889	// WebhookPayload: If the query was fulfilled by a webhook call, this
16890	// field is set to the value of the `payload` field returned in the
16891	// webhook response.
16892	WebhookPayload googleapi.RawMessage `json:"webhookPayload,omitempty"`
16893
16894	// WebhookSource: If the query was fulfilled by a webhook call, this
16895	// field is set to the value of the `source` field returned in the
16896	// webhook response.
16897	WebhookSource string `json:"webhookSource,omitempty"`
16898
16899	// ForceSendFields is a list of field names (e.g. "Action") to
16900	// unconditionally include in API requests. By default, fields with
16901	// empty or default values are omitted from API requests. However, any
16902	// non-pointer, non-interface field appearing in ForceSendFields will be
16903	// sent to the server regardless of whether the field is empty or not.
16904	// This may be used to include empty fields in Patch requests.
16905	ForceSendFields []string `json:"-"`
16906
16907	// NullFields is a list of field names (e.g. "Action") to include in API
16908	// requests with the JSON null value. By default, fields with empty
16909	// values are omitted from API requests. However, any field with an
16910	// empty value appearing in NullFields will be sent to the server as
16911	// null. It is an error if a field in this list has a non-empty value.
16912	// This may be used to include null fields in Patch requests.
16913	NullFields []string `json:"-"`
16914}
16915
16916func (s *GoogleCloudDialogflowV2beta1QueryResult) MarshalJSON() ([]byte, error) {
16917	type NoMethod GoogleCloudDialogflowV2beta1QueryResult
16918	raw := NoMethod(*s)
16919	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
16920}
16921
16922func (s *GoogleCloudDialogflowV2beta1QueryResult) UnmarshalJSON(data []byte) error {
16923	type NoMethod GoogleCloudDialogflowV2beta1QueryResult
16924	var s1 struct {
16925		IntentDetectionConfidence   gensupport.JSONFloat64 `json:"intentDetectionConfidence"`
16926		SpeechRecognitionConfidence gensupport.JSONFloat64 `json:"speechRecognitionConfidence"`
16927		*NoMethod
16928	}
16929	s1.NoMethod = (*NoMethod)(s)
16930	if err := json.Unmarshal(data, &s1); err != nil {
16931		return err
16932	}
16933	s.IntentDetectionConfidence = float64(s1.IntentDetectionConfidence)
16934	s.SpeechRecognitionConfidence = float64(s1.SpeechRecognitionConfidence)
16935	return nil
16936}
16937
16938// GoogleCloudDialogflowV2beta1Sentiment: The sentiment, such as
16939// positive/negative feeling or association, for a unit of analysis,
16940// such as the query text.
16941type GoogleCloudDialogflowV2beta1Sentiment struct {
16942	// Magnitude: A non-negative number in the [0, +inf) range, which
16943	// represents the absolute magnitude of sentiment, regardless of score
16944	// (positive or negative).
16945	Magnitude float64 `json:"magnitude,omitempty"`
16946
16947	// Score: Sentiment score between -1.0 (negative sentiment) and 1.0
16948	// (positive sentiment).
16949	Score float64 `json:"score,omitempty"`
16950
16951	// ForceSendFields is a list of field names (e.g. "Magnitude") to
16952	// unconditionally include in API requests. By default, fields with
16953	// empty or default values are omitted from API requests. However, any
16954	// non-pointer, non-interface field appearing in ForceSendFields will be
16955	// sent to the server regardless of whether the field is empty or not.
16956	// This may be used to include empty fields in Patch requests.
16957	ForceSendFields []string `json:"-"`
16958
16959	// NullFields is a list of field names (e.g. "Magnitude") to include in
16960	// API requests with the JSON null value. By default, fields with empty
16961	// values are omitted from API requests. However, any field with an
16962	// empty value appearing in NullFields will be sent to the server as
16963	// null. It is an error if a field in this list has a non-empty value.
16964	// This may be used to include null fields in Patch requests.
16965	NullFields []string `json:"-"`
16966}
16967
16968func (s *GoogleCloudDialogflowV2beta1Sentiment) MarshalJSON() ([]byte, error) {
16969	type NoMethod GoogleCloudDialogflowV2beta1Sentiment
16970	raw := NoMethod(*s)
16971	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
16972}
16973
16974func (s *GoogleCloudDialogflowV2beta1Sentiment) UnmarshalJSON(data []byte) error {
16975	type NoMethod GoogleCloudDialogflowV2beta1Sentiment
16976	var s1 struct {
16977		Magnitude gensupport.JSONFloat64 `json:"magnitude"`
16978		Score     gensupport.JSONFloat64 `json:"score"`
16979		*NoMethod
16980	}
16981	s1.NoMethod = (*NoMethod)(s)
16982	if err := json.Unmarshal(data, &s1); err != nil {
16983		return err
16984	}
16985	s.Magnitude = float64(s1.Magnitude)
16986	s.Score = float64(s1.Score)
16987	return nil
16988}
16989
16990// GoogleCloudDialogflowV2beta1SentimentAnalysisResult: The result of
16991// sentiment analysis. Sentiment analysis inspects user input and
16992// identifies the prevailing subjective opinion, especially to determine
16993// a user's attitude as positive, negative, or neutral. For
16994// Participants.DetectIntent, it needs to be configured in
16995// DetectIntentRequest.query_params. For
16996// Participants.StreamingDetectIntent, it needs to be configured in
16997// StreamingDetectIntentRequest.query_params. And for
16998// Participants.AnalyzeContent and Participants.StreamingAnalyzeContent,
16999// it needs to be configured in
17000// ConversationProfile.human_agent_assistant_config
17001type GoogleCloudDialogflowV2beta1SentimentAnalysisResult struct {
17002	// QueryTextSentiment: The sentiment analysis result for `query_text`.
17003	QueryTextSentiment *GoogleCloudDialogflowV2beta1Sentiment `json:"queryTextSentiment,omitempty"`
17004
17005	// ForceSendFields is a list of field names (e.g. "QueryTextSentiment")
17006	// to unconditionally include in API requests. By default, fields with
17007	// empty or default values are omitted from API requests. However, any
17008	// non-pointer, non-interface field appearing in ForceSendFields will be
17009	// sent to the server regardless of whether the field is empty or not.
17010	// This may be used to include empty fields in Patch requests.
17011	ForceSendFields []string `json:"-"`
17012
17013	// NullFields is a list of field names (e.g. "QueryTextSentiment") to
17014	// include in API requests with the JSON null value. By default, fields
17015	// with empty values are omitted from API requests. However, any field
17016	// with an empty value appearing in NullFields will be sent to the
17017	// server as null. It is an error if a field in this list has a
17018	// non-empty value. This may be used to include null fields in Patch
17019	// requests.
17020	NullFields []string `json:"-"`
17021}
17022
17023func (s *GoogleCloudDialogflowV2beta1SentimentAnalysisResult) MarshalJSON() ([]byte, error) {
17024	type NoMethod GoogleCloudDialogflowV2beta1SentimentAnalysisResult
17025	raw := NoMethod(*s)
17026	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
17027}
17028
17029// GoogleCloudDialogflowV2beta1SessionEntityType: A session represents a
17030// conversation between a Dialogflow agent and an end-user. You can
17031// create special entities, called session entities, during a session.
17032// Session entities can extend or replace custom entity types and only
17033// exist during the session that they were created for. All session
17034// data, including session entities, is stored by Dialogflow for 20
17035// minutes. For more information, see the session entity guide
17036// (https://cloud.google.com/dialogflow/docs/entities-session).
17037type GoogleCloudDialogflowV2beta1SessionEntityType struct {
17038	// Entities: Required. The collection of entities associated with this
17039	// session entity type.
17040	Entities []*GoogleCloudDialogflowV2beta1EntityTypeEntity `json:"entities,omitempty"`
17041
17042	// EntityOverrideMode: Required. Indicates whether the additional data
17043	// should override or supplement the custom entity type definition.
17044	//
17045	// Possible values:
17046	//   "ENTITY_OVERRIDE_MODE_UNSPECIFIED" - Not specified. This value
17047	// should be never used.
17048	//   "ENTITY_OVERRIDE_MODE_OVERRIDE" - The collection of session
17049	// entities overrides the collection of entities in the corresponding
17050	// custom entity type.
17051	//   "ENTITY_OVERRIDE_MODE_SUPPLEMENT" - The collection of session
17052	// entities extends the collection of entities in the corresponding
17053	// custom entity type. Note: Even in this override mode calls to
17054	// `ListSessionEntityTypes`, `GetSessionEntityType`,
17055	// `CreateSessionEntityType` and `UpdateSessionEntityType` only return
17056	// the additional entities added in this session entity type. If you
17057	// want to get the supplemented list, please call
17058	// EntityTypes.GetEntityType on the custom entity type and merge.
17059	EntityOverrideMode string `json:"entityOverrideMode,omitempty"`
17060
17061	// Name: Required. The unique identifier of this session entity type.
17062	// Supported formats: - `projects//agent/sessions//entityTypes/` -
17063	// `projects//locations//agent/sessions//entityTypes/` -
17064	// `projects//agent/environments//users//sessions//entityTypes/` -
17065	// `projects//locations//agent/environments/
17066	// /users//sessions//entityTypes/` If `Location ID` is not specified we
17067	// assume default 'us' location. If `Environment ID` is not specified,
17068	// we assume default 'draft' environment. If `User ID` is not specified,
17069	// we assume default '-' user. `` must be the display name of an
17070	// existing entity type in the same agent that will be overridden or
17071	// supplemented.
17072	Name string `json:"name,omitempty"`
17073
17074	// ForceSendFields is a list of field names (e.g. "Entities") to
17075	// unconditionally include in API requests. By default, fields with
17076	// empty or default values are omitted from API requests. However, any
17077	// non-pointer, non-interface field appearing in ForceSendFields will be
17078	// sent to the server regardless of whether the field is empty or not.
17079	// This may be used to include empty fields in Patch requests.
17080	ForceSendFields []string `json:"-"`
17081
17082	// NullFields is a list of field names (e.g. "Entities") to include in
17083	// API requests with the JSON null value. By default, fields with empty
17084	// values are omitted from API requests. However, any field with an
17085	// empty value appearing in NullFields will be sent to the server as
17086	// null. It is an error if a field in this list has a non-empty value.
17087	// This may be used to include null fields in Patch requests.
17088	NullFields []string `json:"-"`
17089}
17090
17091func (s *GoogleCloudDialogflowV2beta1SessionEntityType) MarshalJSON() ([]byte, error) {
17092	type NoMethod GoogleCloudDialogflowV2beta1SessionEntityType
17093	raw := NoMethod(*s)
17094	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
17095}
17096
17097// GoogleCloudDialogflowV2beta1SmartReplyAnswer: Represents a smart
17098// reply answer.
17099type GoogleCloudDialogflowV2beta1SmartReplyAnswer struct {
17100	// AnswerRecord: The name of answer record, in the format of
17101	// "projects//locations//answerRecords/"
17102	AnswerRecord string `json:"answerRecord,omitempty"`
17103
17104	// Confidence: Smart reply confidence. The system's confidence score
17105	// that this reply is a good match for this conversation, as a value
17106	// from 0.0 (completely uncertain) to 1.0 (completely certain).
17107	Confidence float64 `json:"confidence,omitempty"`
17108
17109	// Reply: The content of the reply.
17110	Reply string `json:"reply,omitempty"`
17111
17112	// ForceSendFields is a list of field names (e.g. "AnswerRecord") to
17113	// unconditionally include in API requests. By default, fields with
17114	// empty or default values are omitted from API requests. However, any
17115	// non-pointer, non-interface field appearing in ForceSendFields will be
17116	// sent to the server regardless of whether the field is empty or not.
17117	// This may be used to include empty fields in Patch requests.
17118	ForceSendFields []string `json:"-"`
17119
17120	// NullFields is a list of field names (e.g. "AnswerRecord") to include
17121	// in API requests with the JSON null value. By default, fields with
17122	// empty values are omitted from API requests. However, any field with
17123	// an empty value appearing in NullFields will be sent to the server as
17124	// null. It is an error if a field in this list has a non-empty value.
17125	// This may be used to include null fields in Patch requests.
17126	NullFields []string `json:"-"`
17127}
17128
17129func (s *GoogleCloudDialogflowV2beta1SmartReplyAnswer) MarshalJSON() ([]byte, error) {
17130	type NoMethod GoogleCloudDialogflowV2beta1SmartReplyAnswer
17131	raw := NoMethod(*s)
17132	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
17133}
17134
17135func (s *GoogleCloudDialogflowV2beta1SmartReplyAnswer) UnmarshalJSON(data []byte) error {
17136	type NoMethod GoogleCloudDialogflowV2beta1SmartReplyAnswer
17137	var s1 struct {
17138		Confidence gensupport.JSONFloat64 `json:"confidence"`
17139		*NoMethod
17140	}
17141	s1.NoMethod = (*NoMethod)(s)
17142	if err := json.Unmarshal(data, &s1); err != nil {
17143		return err
17144	}
17145	s.Confidence = float64(s1.Confidence)
17146	return nil
17147}
17148
17149// GoogleCloudDialogflowV2beta1SuggestArticlesResponse: The response
17150// message for Participants.SuggestArticles.
17151type GoogleCloudDialogflowV2beta1SuggestArticlesResponse struct {
17152	// ArticleAnswers: Output only. Articles ordered by score in descending
17153	// order.
17154	ArticleAnswers []*GoogleCloudDialogflowV2beta1ArticleAnswer `json:"articleAnswers,omitempty"`
17155
17156	// ContextSize: Number of messages prior to and including latest_message
17157	// to compile the suggestion. It may be smaller than the
17158	// SuggestArticlesResponse.context_size field in the request if there
17159	// aren't that many messages in the conversation.
17160	ContextSize int64 `json:"contextSize,omitempty"`
17161
17162	// LatestMessage: The name of the latest conversation message used to
17163	// compile suggestion for. Format:
17164	// `projects//locations//conversations//messages/`.
17165	LatestMessage string `json:"latestMessage,omitempty"`
17166
17167	// ForceSendFields is a list of field names (e.g. "ArticleAnswers") to
17168	// unconditionally include in API requests. By default, fields with
17169	// empty or default values are omitted from API requests. However, any
17170	// non-pointer, non-interface field appearing in ForceSendFields will be
17171	// sent to the server regardless of whether the field is empty or not.
17172	// This may be used to include empty fields in Patch requests.
17173	ForceSendFields []string `json:"-"`
17174
17175	// NullFields is a list of field names (e.g. "ArticleAnswers") to
17176	// include in API requests with the JSON null value. By default, fields
17177	// with empty values are omitted from API requests. However, any field
17178	// with an empty value appearing in NullFields will be sent to the
17179	// server as null. It is an error if a field in this list has a
17180	// non-empty value. This may be used to include null fields in Patch
17181	// requests.
17182	NullFields []string `json:"-"`
17183}
17184
17185func (s *GoogleCloudDialogflowV2beta1SuggestArticlesResponse) MarshalJSON() ([]byte, error) {
17186	type NoMethod GoogleCloudDialogflowV2beta1SuggestArticlesResponse
17187	raw := NoMethod(*s)
17188	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
17189}
17190
17191// GoogleCloudDialogflowV2beta1SuggestFaqAnswersResponse: The request
17192// message for Participants.SuggestFaqAnswers.
17193type GoogleCloudDialogflowV2beta1SuggestFaqAnswersResponse struct {
17194	// ContextSize: Number of messages prior to and including latest_message
17195	// to compile the suggestion. It may be smaller than the
17196	// SuggestFaqAnswersRequest.context_size field in the request if there
17197	// aren't that many messages in the conversation.
17198	ContextSize int64 `json:"contextSize,omitempty"`
17199
17200	// FaqAnswers: Output only. Answers extracted from FAQ documents.
17201	FaqAnswers []*GoogleCloudDialogflowV2beta1FaqAnswer `json:"faqAnswers,omitempty"`
17202
17203	// LatestMessage: The name of the latest conversation message used to
17204	// compile suggestion for. Format:
17205	// `projects//locations//conversations//messages/`.
17206	LatestMessage string `json:"latestMessage,omitempty"`
17207
17208	// ForceSendFields is a list of field names (e.g. "ContextSize") to
17209	// unconditionally include in API requests. By default, fields with
17210	// empty or default values are omitted from API requests. However, any
17211	// non-pointer, non-interface field appearing in ForceSendFields will be
17212	// sent to the server regardless of whether the field is empty or not.
17213	// This may be used to include empty fields in Patch requests.
17214	ForceSendFields []string `json:"-"`
17215
17216	// NullFields is a list of field names (e.g. "ContextSize") to include
17217	// in API requests with the JSON null value. By default, fields with
17218	// empty values are omitted from API requests. However, any field with
17219	// an empty value appearing in NullFields will be sent to the server as
17220	// null. It is an error if a field in this list has a non-empty value.
17221	// This may be used to include null fields in Patch requests.
17222	NullFields []string `json:"-"`
17223}
17224
17225func (s *GoogleCloudDialogflowV2beta1SuggestFaqAnswersResponse) MarshalJSON() ([]byte, error) {
17226	type NoMethod GoogleCloudDialogflowV2beta1SuggestFaqAnswersResponse
17227	raw := NoMethod(*s)
17228	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
17229}
17230
17231// GoogleCloudDialogflowV2beta1SuggestSmartRepliesResponse: The response
17232// message for Participants.SuggestSmartReplies.
17233type GoogleCloudDialogflowV2beta1SuggestSmartRepliesResponse struct {
17234	// ContextSize: Number of messages prior to and including latest_message
17235	// to compile the suggestion. It may be smaller than the
17236	// SuggestSmartRepliesRequest.context_size field in the request if there
17237	// aren't that many messages in the conversation.
17238	ContextSize int64 `json:"contextSize,omitempty"`
17239
17240	// LatestMessage: The name of the latest conversation message used to
17241	// compile suggestion for. Format:
17242	// `projects//locations//conversations//messages/`.
17243	LatestMessage string `json:"latestMessage,omitempty"`
17244
17245	// SmartReplyAnswers: Output only. Multiple reply options provided by
17246	// smart reply service. The order is based on the rank of the model
17247	// prediction. The maximum number of the returned replies is set in
17248	// SmartReplyConfig.
17249	SmartReplyAnswers []*GoogleCloudDialogflowV2beta1SmartReplyAnswer `json:"smartReplyAnswers,omitempty"`
17250
17251	// ForceSendFields is a list of field names (e.g. "ContextSize") to
17252	// unconditionally include in API requests. By default, fields with
17253	// empty or default values are omitted from API requests. However, any
17254	// non-pointer, non-interface field appearing in ForceSendFields will be
17255	// sent to the server regardless of whether the field is empty or not.
17256	// This may be used to include empty fields in Patch requests.
17257	ForceSendFields []string `json:"-"`
17258
17259	// NullFields is a list of field names (e.g. "ContextSize") to include
17260	// in API requests with the JSON null value. By default, fields with
17261	// empty values are omitted from API requests. However, any field with
17262	// an empty value appearing in NullFields will be sent to the server as
17263	// null. It is an error if a field in this list has a non-empty value.
17264	// This may be used to include null fields in Patch requests.
17265	NullFields []string `json:"-"`
17266}
17267
17268func (s *GoogleCloudDialogflowV2beta1SuggestSmartRepliesResponse) MarshalJSON() ([]byte, error) {
17269	type NoMethod GoogleCloudDialogflowV2beta1SuggestSmartRepliesResponse
17270	raw := NoMethod(*s)
17271	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
17272}
17273
17274// GoogleCloudDialogflowV2beta1SuggestionResult: One response of
17275// different type of suggestion response which is used in the response
17276// of Participants.AnalyzeContent and Participants.AnalyzeContent, as
17277// well as HumanAgentAssistantEvent.
17278type GoogleCloudDialogflowV2beta1SuggestionResult struct {
17279	// Error: Error status if the request failed.
17280	Error *GoogleRpcStatus `json:"error,omitempty"`
17281
17282	// SuggestArticlesResponse: SuggestArticlesResponse if request is for
17283	// ARTICLE_SUGGESTION.
17284	SuggestArticlesResponse *GoogleCloudDialogflowV2beta1SuggestArticlesResponse `json:"suggestArticlesResponse,omitempty"`
17285
17286	// SuggestFaqAnswersResponse: SuggestFaqAnswersResponse if request is
17287	// for FAQ_ANSWER.
17288	SuggestFaqAnswersResponse *GoogleCloudDialogflowV2beta1SuggestFaqAnswersResponse `json:"suggestFaqAnswersResponse,omitempty"`
17289
17290	// SuggestSmartRepliesResponse: SuggestSmartRepliesResponse if request
17291	// is for SMART_REPLY.
17292	SuggestSmartRepliesResponse *GoogleCloudDialogflowV2beta1SuggestSmartRepliesResponse `json:"suggestSmartRepliesResponse,omitempty"`
17293
17294	// ForceSendFields is a list of field names (e.g. "Error") to
17295	// unconditionally include in API requests. By default, fields with
17296	// empty or default values are omitted from API requests. However, any
17297	// non-pointer, non-interface field appearing in ForceSendFields will be
17298	// sent to the server regardless of whether the field is empty or not.
17299	// This may be used to include empty fields in Patch requests.
17300	ForceSendFields []string `json:"-"`
17301
17302	// NullFields is a list of field names (e.g. "Error") to include in API
17303	// requests with the JSON null value. By default, fields with empty
17304	// values are omitted from API requests. However, any field with an
17305	// empty value appearing in NullFields will be sent to the server as
17306	// null. It is an error if a field in this list has a non-empty value.
17307	// This may be used to include null fields in Patch requests.
17308	NullFields []string `json:"-"`
17309}
17310
17311func (s *GoogleCloudDialogflowV2beta1SuggestionResult) MarshalJSON() ([]byte, error) {
17312	type NoMethod GoogleCloudDialogflowV2beta1SuggestionResult
17313	raw := NoMethod(*s)
17314	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
17315}
17316
17317// GoogleCloudDialogflowV2beta1WebhookRequest: The request message for a
17318// webhook call.
17319type GoogleCloudDialogflowV2beta1WebhookRequest struct {
17320	// AlternativeQueryResults: Alternative query results from
17321	// KnowledgeService.
17322	AlternativeQueryResults []*GoogleCloudDialogflowV2beta1QueryResult `json:"alternativeQueryResults,omitempty"`
17323
17324	// OriginalDetectIntentRequest: Optional. The contents of the original
17325	// request that was passed to `[Streaming]DetectIntent` call.
17326	OriginalDetectIntentRequest *GoogleCloudDialogflowV2beta1OriginalDetectIntentRequest `json:"originalDetectIntentRequest,omitempty"`
17327
17328	// QueryResult: The result of the conversational query or event
17329	// processing. Contains the same value as
17330	// `[Streaming]DetectIntentResponse.query_result`.
17331	QueryResult *GoogleCloudDialogflowV2beta1QueryResult `json:"queryResult,omitempty"`
17332
17333	// ResponseId: The unique identifier of the response. Contains the same
17334	// value as `[Streaming]DetectIntentResponse.response_id`.
17335	ResponseId string `json:"responseId,omitempty"`
17336
17337	// Session: The unique identifier of detectIntent request session. Can
17338	// be used to identify end-user inside webhook implementation. Supported
17339	// formats: - `projects//agent/sessions/, -
17340	// `projects//locations//agent/sessions/`, -
17341	// `projects//agent/environments//users//sessions/`, -
17342	// `projects//locations//agent/environments//users//sessions/`,
17343	Session string `json:"session,omitempty"`
17344
17345	// ForceSendFields is a list of field names (e.g.
17346	// "AlternativeQueryResults") to unconditionally include in API
17347	// requests. By default, fields with empty or default values are omitted
17348	// from API requests. However, any non-pointer, non-interface field
17349	// appearing in ForceSendFields will be sent to the server regardless of
17350	// whether the field is empty or not. This may be used to include empty
17351	// fields in Patch requests.
17352	ForceSendFields []string `json:"-"`
17353
17354	// NullFields is a list of field names (e.g. "AlternativeQueryResults")
17355	// to include in API requests with the JSON null value. By default,
17356	// fields with empty values are omitted from API requests. However, any
17357	// field with an empty value appearing in NullFields will be sent to the
17358	// server as null. It is an error if a field in this list has a
17359	// non-empty value. This may be used to include null fields in Patch
17360	// requests.
17361	NullFields []string `json:"-"`
17362}
17363
17364func (s *GoogleCloudDialogflowV2beta1WebhookRequest) MarshalJSON() ([]byte, error) {
17365	type NoMethod GoogleCloudDialogflowV2beta1WebhookRequest
17366	raw := NoMethod(*s)
17367	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
17368}
17369
17370// GoogleCloudDialogflowV2beta1WebhookResponse: The response message for
17371// a webhook call. This response is validated by the Dialogflow server.
17372// If validation fails, an error will be returned in the
17373// QueryResult.diagnostic_info field. Setting JSON fields to an empty
17374// value with the wrong type is a common error. To avoid this error: -
17375// Use "" for empty strings - Use `{}` or `null` for empty objects -
17376// Use `[]` or `null` for empty arrays For more information, see the
17377// Protocol Buffers Language Guide
17378// (https://developers.google.com/protocol-buffers/docs/proto3#json).
17379type GoogleCloudDialogflowV2beta1WebhookResponse struct {
17380	// EndInteraction: Optional. Indicates that this intent ends an
17381	// interaction. Some integrations (e.g., Actions on Google or Dialogflow
17382	// phone gateway) use this information to close interaction with an end
17383	// user. Default is false.
17384	EndInteraction bool `json:"endInteraction,omitempty"`
17385
17386	// FollowupEventInput: Optional. Invokes the supplied events. When this
17387	// field is set, Dialogflow ignores the `fulfillment_text`,
17388	// `fulfillment_messages`, and `payload` fields.
17389	FollowupEventInput *GoogleCloudDialogflowV2beta1EventInput `json:"followupEventInput,omitempty"`
17390
17391	// FulfillmentMessages: Optional. The rich response messages intended
17392	// for the end-user. When provided, Dialogflow uses this field to
17393	// populate QueryResult.fulfillment_messages sent to the integration or
17394	// API caller.
17395	FulfillmentMessages []*GoogleCloudDialogflowV2beta1IntentMessage `json:"fulfillmentMessages,omitempty"`
17396
17397	// FulfillmentText: Optional. The text response message intended for the
17398	// end-user. It is recommended to use
17399	// `fulfillment_messages.text.text[0]` instead. When provided,
17400	// Dialogflow uses this field to populate QueryResult.fulfillment_text
17401	// sent to the integration or API caller.
17402	FulfillmentText string `json:"fulfillmentText,omitempty"`
17403
17404	// LiveAgentHandoff: Indicates that a live agent should be brought in to
17405	// handle the interaction with the user. In most cases, when you set
17406	// this flag to true, you would also want to set end_interaction to true
17407	// as well. Default is false.
17408	LiveAgentHandoff bool `json:"liveAgentHandoff,omitempty"`
17409
17410	// OutputContexts: Optional. The collection of output contexts that will
17411	// overwrite currently active contexts for the session and reset their
17412	// lifespans. When provided, Dialogflow uses this field to populate
17413	// QueryResult.output_contexts sent to the integration or API caller.
17414	OutputContexts []*GoogleCloudDialogflowV2beta1Context `json:"outputContexts,omitempty"`
17415
17416	// Payload: Optional. This field can be used to pass custom data from
17417	// your webhook to the integration or API caller. Arbitrary JSON objects
17418	// are supported. When provided, Dialogflow uses this field to populate
17419	// QueryResult.webhook_payload sent to the integration or API caller.
17420	// This field is also used by the Google Assistant integration
17421	// (https://cloud.google.com/dialogflow/docs/integrations/aog) for rich
17422	// response messages. See the format definition at Google Assistant
17423	// Dialogflow webhook format
17424	// (https://developers.google.com/assistant/actions/build/json/dialogflow-webhook-json)
17425	Payload googleapi.RawMessage `json:"payload,omitempty"`
17426
17427	// SessionEntityTypes: Optional. Additional session entity types to
17428	// replace or extend developer entity types with. The entity synonyms
17429	// apply to all languages and persist for the session. Setting this data
17430	// from a webhook overwrites the session entity types that have been set
17431	// using `detectIntent`, `streamingDetectIntent` or SessionEntityType
17432	// management methods.
17433	SessionEntityTypes []*GoogleCloudDialogflowV2beta1SessionEntityType `json:"sessionEntityTypes,omitempty"`
17434
17435	// Source: Optional. A custom field used to identify the webhook source.
17436	// Arbitrary strings are supported. When provided, Dialogflow uses this
17437	// field to populate QueryResult.webhook_source sent to the integration
17438	// or API caller.
17439	Source string `json:"source,omitempty"`
17440
17441	// ForceSendFields is a list of field names (e.g. "EndInteraction") to
17442	// unconditionally include in API requests. By default, fields with
17443	// empty or default values are omitted from API requests. However, any
17444	// non-pointer, non-interface field appearing in ForceSendFields will be
17445	// sent to the server regardless of whether the field is empty or not.
17446	// This may be used to include empty fields in Patch requests.
17447	ForceSendFields []string `json:"-"`
17448
17449	// NullFields is a list of field names (e.g. "EndInteraction") to
17450	// include in API requests with the JSON null value. By default, fields
17451	// with empty values are omitted from API requests. However, any field
17452	// with an empty value appearing in NullFields will be sent to the
17453	// server as null. It is an error if a field in this list has a
17454	// non-empty value. This may be used to include null fields in Patch
17455	// requests.
17456	NullFields []string `json:"-"`
17457}
17458
17459func (s *GoogleCloudDialogflowV2beta1WebhookResponse) MarshalJSON() ([]byte, error) {
17460	type NoMethod GoogleCloudDialogflowV2beta1WebhookResponse
17461	raw := NoMethod(*s)
17462	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
17463}
17464
17465// GoogleCloudDialogflowV3alpha1CreateDocumentOperationMetadata:
17466// Metadata for CreateDocument operation.
17467type GoogleCloudDialogflowV3alpha1CreateDocumentOperationMetadata struct {
17468	// GenericMetadata: The generic information of the operation.
17469	GenericMetadata *GoogleCloudDialogflowV3alpha1GenericKnowledgeOperationMetadata `json:"genericMetadata,omitempty"`
17470
17471	// ForceSendFields is a list of field names (e.g. "GenericMetadata") to
17472	// unconditionally include in API requests. By default, fields with
17473	// empty or default values are omitted from API requests. However, any
17474	// non-pointer, non-interface field appearing in ForceSendFields will be
17475	// sent to the server regardless of whether the field is empty or not.
17476	// This may be used to include empty fields in Patch requests.
17477	ForceSendFields []string `json:"-"`
17478
17479	// NullFields is a list of field names (e.g. "GenericMetadata") to
17480	// include in API requests with the JSON null value. By default, fields
17481	// with empty values are omitted from API requests. However, any field
17482	// with an empty value appearing in NullFields will be sent to the
17483	// server as null. It is an error if a field in this list has a
17484	// non-empty value. This may be used to include null fields in Patch
17485	// requests.
17486	NullFields []string `json:"-"`
17487}
17488
17489func (s *GoogleCloudDialogflowV3alpha1CreateDocumentOperationMetadata) MarshalJSON() ([]byte, error) {
17490	type NoMethod GoogleCloudDialogflowV3alpha1CreateDocumentOperationMetadata
17491	raw := NoMethod(*s)
17492	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
17493}
17494
17495// GoogleCloudDialogflowV3alpha1DeleteDocumentOperationMetadata:
17496// Metadata for DeleteDocument operation.
17497type GoogleCloudDialogflowV3alpha1DeleteDocumentOperationMetadata struct {
17498	// GenericMetadata: The generic information of the operation.
17499	GenericMetadata *GoogleCloudDialogflowV3alpha1GenericKnowledgeOperationMetadata `json:"genericMetadata,omitempty"`
17500
17501	// ForceSendFields is a list of field names (e.g. "GenericMetadata") to
17502	// unconditionally include in API requests. By default, fields with
17503	// empty or default values are omitted from API requests. However, any
17504	// non-pointer, non-interface field appearing in ForceSendFields will be
17505	// sent to the server regardless of whether the field is empty or not.
17506	// This may be used to include empty fields in Patch requests.
17507	ForceSendFields []string `json:"-"`
17508
17509	// NullFields is a list of field names (e.g. "GenericMetadata") to
17510	// include in API requests with the JSON null value. By default, fields
17511	// with empty values are omitted from API requests. However, any field
17512	// with an empty value appearing in NullFields will be sent to the
17513	// server as null. It is an error if a field in this list has a
17514	// non-empty value. This may be used to include null fields in Patch
17515	// requests.
17516	NullFields []string `json:"-"`
17517}
17518
17519func (s *GoogleCloudDialogflowV3alpha1DeleteDocumentOperationMetadata) MarshalJSON() ([]byte, error) {
17520	type NoMethod GoogleCloudDialogflowV3alpha1DeleteDocumentOperationMetadata
17521	raw := NoMethod(*s)
17522	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
17523}
17524
17525// GoogleCloudDialogflowV3alpha1GenericKnowledgeOperationMetadata:
17526// Metadata in google::longrunning::Operation for Knowledge operations.
17527type GoogleCloudDialogflowV3alpha1GenericKnowledgeOperationMetadata struct {
17528	// State: Required. Output only. The current state of this operation.
17529	//
17530	// Possible values:
17531	//   "STATE_UNSPECIFIED" - State unspecified.
17532	//   "PENDING" - The operation has been created.
17533	//   "RUNNING" - The operation is currently running.
17534	//   "DONE" - The operation is done, either cancelled or completed.
17535	State string `json:"state,omitempty"`
17536
17537	// ForceSendFields is a list of field names (e.g. "State") to
17538	// unconditionally include in API requests. By default, fields with
17539	// empty or default values are omitted from API requests. However, any
17540	// non-pointer, non-interface field appearing in ForceSendFields will be
17541	// sent to the server regardless of whether the field is empty or not.
17542	// This may be used to include empty fields in Patch requests.
17543	ForceSendFields []string `json:"-"`
17544
17545	// NullFields is a list of field names (e.g. "State") to include in API
17546	// requests with the JSON null value. By default, fields with empty
17547	// values are omitted from API requests. However, any field with an
17548	// empty value appearing in NullFields will be sent to the server as
17549	// null. It is an error if a field in this list has a non-empty value.
17550	// This may be used to include null fields in Patch requests.
17551	NullFields []string `json:"-"`
17552}
17553
17554func (s *GoogleCloudDialogflowV3alpha1GenericKnowledgeOperationMetadata) MarshalJSON() ([]byte, error) {
17555	type NoMethod GoogleCloudDialogflowV3alpha1GenericKnowledgeOperationMetadata
17556	raw := NoMethod(*s)
17557	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
17558}
17559
17560// GoogleCloudDialogflowV3alpha1ImportDocumentsOperationMetadata:
17561// Metadata for ImportDocuments operation.
17562type GoogleCloudDialogflowV3alpha1ImportDocumentsOperationMetadata struct {
17563	// GenericMetadata: The generic information of the operation.
17564	GenericMetadata *GoogleCloudDialogflowV3alpha1GenericKnowledgeOperationMetadata `json:"genericMetadata,omitempty"`
17565
17566	// ForceSendFields is a list of field names (e.g. "GenericMetadata") to
17567	// unconditionally include in API requests. By default, fields with
17568	// empty or default values are omitted from API requests. However, any
17569	// non-pointer, non-interface field appearing in ForceSendFields will be
17570	// sent to the server regardless of whether the field is empty or not.
17571	// This may be used to include empty fields in Patch requests.
17572	ForceSendFields []string `json:"-"`
17573
17574	// NullFields is a list of field names (e.g. "GenericMetadata") to
17575	// include in API requests with the JSON null value. By default, fields
17576	// with empty values are omitted from API requests. However, any field
17577	// with an empty value appearing in NullFields will be sent to the
17578	// server as null. It is an error if a field in this list has a
17579	// non-empty value. This may be used to include null fields in Patch
17580	// requests.
17581	NullFields []string `json:"-"`
17582}
17583
17584func (s *GoogleCloudDialogflowV3alpha1ImportDocumentsOperationMetadata) MarshalJSON() ([]byte, error) {
17585	type NoMethod GoogleCloudDialogflowV3alpha1ImportDocumentsOperationMetadata
17586	raw := NoMethod(*s)
17587	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
17588}
17589
17590// GoogleCloudDialogflowV3alpha1ImportDocumentsResponse: Response
17591// message for Documents.ImportDocuments.
17592type GoogleCloudDialogflowV3alpha1ImportDocumentsResponse struct {
17593	// Warnings: Includes details about skipped documents or any other
17594	// warnings.
17595	Warnings []*GoogleRpcStatus `json:"warnings,omitempty"`
17596
17597	// ForceSendFields is a list of field names (e.g. "Warnings") to
17598	// unconditionally include in API requests. By default, fields with
17599	// empty or default values are omitted from API requests. However, any
17600	// non-pointer, non-interface field appearing in ForceSendFields will be
17601	// sent to the server regardless of whether the field is empty or not.
17602	// This may be used to include empty fields in Patch requests.
17603	ForceSendFields []string `json:"-"`
17604
17605	// NullFields is a list of field names (e.g. "Warnings") to include in
17606	// API requests with the JSON null value. By default, fields with empty
17607	// values are omitted from API requests. However, any field with an
17608	// empty value appearing in NullFields will be sent to the server as
17609	// null. It is an error if a field in this list has a non-empty value.
17610	// This may be used to include null fields in Patch requests.
17611	NullFields []string `json:"-"`
17612}
17613
17614func (s *GoogleCloudDialogflowV3alpha1ImportDocumentsResponse) MarshalJSON() ([]byte, error) {
17615	type NoMethod GoogleCloudDialogflowV3alpha1ImportDocumentsResponse
17616	raw := NoMethod(*s)
17617	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
17618}
17619
17620// GoogleCloudDialogflowV3alpha1ReloadDocumentOperationMetadata:
17621// Metadata for ReloadDocument operation.
17622type GoogleCloudDialogflowV3alpha1ReloadDocumentOperationMetadata struct {
17623	// GenericMetadata: The generic information of the operation.
17624	GenericMetadata *GoogleCloudDialogflowV3alpha1GenericKnowledgeOperationMetadata `json:"genericMetadata,omitempty"`
17625
17626	// ForceSendFields is a list of field names (e.g. "GenericMetadata") to
17627	// unconditionally include in API requests. By default, fields with
17628	// empty or default values are omitted from API requests. However, any
17629	// non-pointer, non-interface field appearing in ForceSendFields will be
17630	// sent to the server regardless of whether the field is empty or not.
17631	// This may be used to include empty fields in Patch requests.
17632	ForceSendFields []string `json:"-"`
17633
17634	// NullFields is a list of field names (e.g. "GenericMetadata") to
17635	// include in API requests with the JSON null value. By default, fields
17636	// with empty values are omitted from API requests. However, any field
17637	// with an empty value appearing in NullFields will be sent to the
17638	// server as null. It is an error if a field in this list has a
17639	// non-empty value. This may be used to include null fields in Patch
17640	// requests.
17641	NullFields []string `json:"-"`
17642}
17643
17644func (s *GoogleCloudDialogflowV3alpha1ReloadDocumentOperationMetadata) MarshalJSON() ([]byte, error) {
17645	type NoMethod GoogleCloudDialogflowV3alpha1ReloadDocumentOperationMetadata
17646	raw := NoMethod(*s)
17647	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
17648}
17649
17650// GoogleCloudDialogflowV3alpha1UpdateDocumentOperationMetadata:
17651// Metadata for UpdateDocument operation.
17652type GoogleCloudDialogflowV3alpha1UpdateDocumentOperationMetadata struct {
17653	// GenericMetadata: The generic information of the operation.
17654	GenericMetadata *GoogleCloudDialogflowV3alpha1GenericKnowledgeOperationMetadata `json:"genericMetadata,omitempty"`
17655
17656	// ForceSendFields is a list of field names (e.g. "GenericMetadata") to
17657	// unconditionally include in API requests. By default, fields with
17658	// empty or default values are omitted from API requests. However, any
17659	// non-pointer, non-interface field appearing in ForceSendFields will be
17660	// sent to the server regardless of whether the field is empty or not.
17661	// This may be used to include empty fields in Patch requests.
17662	ForceSendFields []string `json:"-"`
17663
17664	// NullFields is a list of field names (e.g. "GenericMetadata") to
17665	// include in API requests with the JSON null value. By default, fields
17666	// with empty values are omitted from API requests. However, any field
17667	// with an empty value appearing in NullFields will be sent to the
17668	// server as null. It is an error if a field in this list has a
17669	// non-empty value. This may be used to include null fields in Patch
17670	// requests.
17671	NullFields []string `json:"-"`
17672}
17673
17674func (s *GoogleCloudDialogflowV3alpha1UpdateDocumentOperationMetadata) MarshalJSON() ([]byte, error) {
17675	type NoMethod GoogleCloudDialogflowV3alpha1UpdateDocumentOperationMetadata
17676	raw := NoMethod(*s)
17677	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
17678}
17679
17680// GoogleCloudLocationListLocationsResponse: The response message for
17681// Locations.ListLocations.
17682type GoogleCloudLocationListLocationsResponse struct {
17683	// Locations: A list of locations that matches the specified filter in
17684	// the request.
17685	Locations []*GoogleCloudLocationLocation `json:"locations,omitempty"`
17686
17687	// NextPageToken: The standard List next-page token.
17688	NextPageToken string `json:"nextPageToken,omitempty"`
17689
17690	// ServerResponse contains the HTTP response code and headers from the
17691	// server.
17692	googleapi.ServerResponse `json:"-"`
17693
17694	// ForceSendFields is a list of field names (e.g. "Locations") to
17695	// unconditionally include in API requests. By default, fields with
17696	// empty or default values are omitted from API requests. However, any
17697	// non-pointer, non-interface field appearing in ForceSendFields will be
17698	// sent to the server regardless of whether the field is empty or not.
17699	// This may be used to include empty fields in Patch requests.
17700	ForceSendFields []string `json:"-"`
17701
17702	// NullFields is a list of field names (e.g. "Locations") to include in
17703	// API requests with the JSON null value. By default, fields with empty
17704	// values are omitted from API requests. However, any field with an
17705	// empty value appearing in NullFields will be sent to the server as
17706	// null. It is an error if a field in this list has a non-empty value.
17707	// This may be used to include null fields in Patch requests.
17708	NullFields []string `json:"-"`
17709}
17710
17711func (s *GoogleCloudLocationListLocationsResponse) MarshalJSON() ([]byte, error) {
17712	type NoMethod GoogleCloudLocationListLocationsResponse
17713	raw := NoMethod(*s)
17714	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
17715}
17716
17717// GoogleCloudLocationLocation: A resource that represents Google Cloud
17718// Platform location.
17719type GoogleCloudLocationLocation struct {
17720	// DisplayName: The friendly name for this location, typically a nearby
17721	// city name. For example, "Tokyo".
17722	DisplayName string `json:"displayName,omitempty"`
17723
17724	// Labels: Cross-service attributes for the location. For example
17725	// {"cloud.googleapis.com/region": "us-east1"}
17726	Labels map[string]string `json:"labels,omitempty"`
17727
17728	// LocationId: The canonical id for this location. For example:
17729	// "us-east1".
17730	LocationId string `json:"locationId,omitempty"`
17731
17732	// Metadata: Service-specific metadata. For example the available
17733	// capacity at the given location.
17734	Metadata googleapi.RawMessage `json:"metadata,omitempty"`
17735
17736	// Name: Resource name for the location, which may vary between
17737	// implementations. For example:
17738	// "projects/example-project/locations/us-east1"
17739	Name string `json:"name,omitempty"`
17740
17741	// ServerResponse contains the HTTP response code and headers from the
17742	// server.
17743	googleapi.ServerResponse `json:"-"`
17744
17745	// ForceSendFields is a list of field names (e.g. "DisplayName") to
17746	// unconditionally include in API requests. By default, fields with
17747	// empty or default values are omitted from API requests. However, any
17748	// non-pointer, non-interface field appearing in ForceSendFields will be
17749	// sent to the server regardless of whether the field is empty or not.
17750	// This may be used to include empty fields in Patch requests.
17751	ForceSendFields []string `json:"-"`
17752
17753	// NullFields is a list of field names (e.g. "DisplayName") to include
17754	// in API requests with the JSON null value. By default, fields with
17755	// empty values are omitted from API requests. However, any field with
17756	// an empty value appearing in NullFields will be sent to the server as
17757	// null. It is an error if a field in this list has a non-empty value.
17758	// This may be used to include null fields in Patch requests.
17759	NullFields []string `json:"-"`
17760}
17761
17762func (s *GoogleCloudLocationLocation) MarshalJSON() ([]byte, error) {
17763	type NoMethod GoogleCloudLocationLocation
17764	raw := NoMethod(*s)
17765	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
17766}
17767
17768// GoogleLongrunningListOperationsResponse: The response message for
17769// Operations.ListOperations.
17770type GoogleLongrunningListOperationsResponse struct {
17771	// NextPageToken: The standard List next-page token.
17772	NextPageToken string `json:"nextPageToken,omitempty"`
17773
17774	// Operations: A list of operations that matches the specified filter in
17775	// the request.
17776	Operations []*GoogleLongrunningOperation `json:"operations,omitempty"`
17777
17778	// ServerResponse contains the HTTP response code and headers from the
17779	// server.
17780	googleapi.ServerResponse `json:"-"`
17781
17782	// ForceSendFields is a list of field names (e.g. "NextPageToken") to
17783	// unconditionally include in API requests. By default, fields with
17784	// empty or default values are omitted from API requests. However, any
17785	// non-pointer, non-interface field appearing in ForceSendFields will be
17786	// sent to the server regardless of whether the field is empty or not.
17787	// This may be used to include empty fields in Patch requests.
17788	ForceSendFields []string `json:"-"`
17789
17790	// NullFields is a list of field names (e.g. "NextPageToken") to include
17791	// in API requests with the JSON null value. By default, fields with
17792	// empty values are omitted from API requests. However, any field with
17793	// an empty value appearing in NullFields will be sent to the server as
17794	// null. It is an error if a field in this list has a non-empty value.
17795	// This may be used to include null fields in Patch requests.
17796	NullFields []string `json:"-"`
17797}
17798
17799func (s *GoogleLongrunningListOperationsResponse) MarshalJSON() ([]byte, error) {
17800	type NoMethod GoogleLongrunningListOperationsResponse
17801	raw := NoMethod(*s)
17802	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
17803}
17804
17805// GoogleLongrunningOperation: This resource represents a long-running
17806// operation that is the result of a network API call.
17807type GoogleLongrunningOperation struct {
17808	// Done: If the value is `false`, it means the operation is still in
17809	// progress. If `true`, the operation is completed, and either `error`
17810	// or `response` is available.
17811	Done bool `json:"done,omitempty"`
17812
17813	// Error: The error result of the operation in case of failure or
17814	// cancellation.
17815	Error *GoogleRpcStatus `json:"error,omitempty"`
17816
17817	// Metadata: Service-specific metadata associated with the operation. It
17818	// typically contains progress information and common metadata such as
17819	// create time. Some services might not provide such metadata. Any
17820	// method that returns a long-running operation should document the
17821	// metadata type, if any.
17822	Metadata googleapi.RawMessage `json:"metadata,omitempty"`
17823
17824	// Name: The server-assigned name, which is only unique within the same
17825	// service that originally returns it. If you use the default HTTP
17826	// mapping, the `name` should be a resource name ending with
17827	// `operations/{unique_id}`.
17828	Name string `json:"name,omitempty"`
17829
17830	// Response: The normal response of the operation in case of success. If
17831	// the original method returns no data on success, such as `Delete`, the
17832	// response is `google.protobuf.Empty`. If the original method is
17833	// standard `Get`/`Create`/`Update`, the response should be the
17834	// resource. For other methods, the response should have the type
17835	// `XxxResponse`, where `Xxx` is the original method name. For example,
17836	// if the original method name is `TakeSnapshot()`, the inferred
17837	// response type is `TakeSnapshotResponse`.
17838	Response googleapi.RawMessage `json:"response,omitempty"`
17839
17840	// ServerResponse contains the HTTP response code and headers from the
17841	// server.
17842	googleapi.ServerResponse `json:"-"`
17843
17844	// ForceSendFields is a list of field names (e.g. "Done") to
17845	// unconditionally include in API requests. By default, fields with
17846	// empty or default values are omitted from API requests. However, any
17847	// non-pointer, non-interface field appearing in ForceSendFields will be
17848	// sent to the server regardless of whether the field is empty or not.
17849	// This may be used to include empty fields in Patch requests.
17850	ForceSendFields []string `json:"-"`
17851
17852	// NullFields is a list of field names (e.g. "Done") to include in API
17853	// requests with the JSON null value. By default, fields with empty
17854	// values are omitted from API requests. However, any field with an
17855	// empty value appearing in NullFields will be sent to the server as
17856	// null. It is an error if a field in this list has a non-empty value.
17857	// This may be used to include null fields in Patch requests.
17858	NullFields []string `json:"-"`
17859}
17860
17861func (s *GoogleLongrunningOperation) MarshalJSON() ([]byte, error) {
17862	type NoMethod GoogleLongrunningOperation
17863	raw := NoMethod(*s)
17864	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
17865}
17866
17867// GoogleProtobufEmpty: A generic empty message that you can re-use to
17868// avoid defining duplicated empty messages in your APIs. A typical
17869// example is to use it as the request or the response type of an API
17870// method. For instance: service Foo { rpc Bar(google.protobuf.Empty)
17871// returns (google.protobuf.Empty); } The JSON representation for
17872// `Empty` is empty JSON object `{}`.
17873type GoogleProtobufEmpty struct {
17874	// ServerResponse contains the HTTP response code and headers from the
17875	// server.
17876	googleapi.ServerResponse `json:"-"`
17877}
17878
17879// GoogleRpcStatus: The `Status` type defines a logical error model that
17880// is suitable for different programming environments, including REST
17881// APIs and RPC APIs. It is used by gRPC (https://github.com/grpc). Each
17882// `Status` message contains three pieces of data: error code, error
17883// message, and error details. You can find out more about this error
17884// model and how to work with it in the API Design Guide
17885// (https://cloud.google.com/apis/design/errors).
17886type GoogleRpcStatus struct {
17887	// Code: The status code, which should be an enum value of
17888	// google.rpc.Code.
17889	Code int64 `json:"code,omitempty"`
17890
17891	// Details: A list of messages that carry the error details. There is a
17892	// common set of message types for APIs to use.
17893	Details []googleapi.RawMessage `json:"details,omitempty"`
17894
17895	// Message: A developer-facing error message, which should be in
17896	// English. Any user-facing error message should be localized and sent
17897	// in the google.rpc.Status.details field, or localized by the client.
17898	Message string `json:"message,omitempty"`
17899
17900	// ForceSendFields is a list of field names (e.g. "Code") to
17901	// unconditionally include in API requests. By default, fields with
17902	// empty or default values are omitted from API requests. However, any
17903	// non-pointer, non-interface field appearing in ForceSendFields will be
17904	// sent to the server regardless of whether the field is empty or not.
17905	// This may be used to include empty fields in Patch requests.
17906	ForceSendFields []string `json:"-"`
17907
17908	// NullFields is a list of field names (e.g. "Code") to include in API
17909	// requests with the JSON null value. By default, fields with empty
17910	// values are omitted from API requests. However, any field with an
17911	// empty value appearing in NullFields will be sent to the server as
17912	// null. It is an error if a field in this list has a non-empty value.
17913	// This may be used to include null fields in Patch requests.
17914	NullFields []string `json:"-"`
17915}
17916
17917func (s *GoogleRpcStatus) MarshalJSON() ([]byte, error) {
17918	type NoMethod GoogleRpcStatus
17919	raw := NoMethod(*s)
17920	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
17921}
17922
17923// GoogleTypeLatLng: An object that represents a latitude/longitude
17924// pair. This is expressed as a pair of doubles to represent degrees
17925// latitude and degrees longitude. Unless specified otherwise, this
17926// object must conform to the WGS84 standard. Values must be within
17927// normalized ranges.
17928type GoogleTypeLatLng struct {
17929	// Latitude: The latitude in degrees. It must be in the range [-90.0,
17930	// +90.0].
17931	Latitude float64 `json:"latitude,omitempty"`
17932
17933	// Longitude: The longitude in degrees. It must be in the range [-180.0,
17934	// +180.0].
17935	Longitude float64 `json:"longitude,omitempty"`
17936
17937	// ForceSendFields is a list of field names (e.g. "Latitude") to
17938	// unconditionally include in API requests. By default, fields with
17939	// empty or default values are omitted from API requests. However, any
17940	// non-pointer, non-interface field appearing in ForceSendFields will be
17941	// sent to the server regardless of whether the field is empty or not.
17942	// This may be used to include empty fields in Patch requests.
17943	ForceSendFields []string `json:"-"`
17944
17945	// NullFields is a list of field names (e.g. "Latitude") to include in
17946	// API requests with the JSON null value. By default, fields with empty
17947	// values are omitted from API requests. However, any field with an
17948	// empty value appearing in NullFields will be sent to the server as
17949	// null. It is an error if a field in this list has a non-empty value.
17950	// This may be used to include null fields in Patch requests.
17951	NullFields []string `json:"-"`
17952}
17953
17954func (s *GoogleTypeLatLng) MarshalJSON() ([]byte, error) {
17955	type NoMethod GoogleTypeLatLng
17956	raw := NoMethod(*s)
17957	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
17958}
17959
17960func (s *GoogleTypeLatLng) UnmarshalJSON(data []byte) error {
17961	type NoMethod GoogleTypeLatLng
17962	var s1 struct {
17963		Latitude  gensupport.JSONFloat64 `json:"latitude"`
17964		Longitude gensupport.JSONFloat64 `json:"longitude"`
17965		*NoMethod
17966	}
17967	s1.NoMethod = (*NoMethod)(s)
17968	if err := json.Unmarshal(data, &s1); err != nil {
17969		return err
17970	}
17971	s.Latitude = float64(s1.Latitude)
17972	s.Longitude = float64(s1.Longitude)
17973	return nil
17974}
17975
17976// method id "dialogflow.projects.deleteAgent":
17977
17978type ProjectsDeleteAgentCall struct {
17979	s          *Service
17980	parent     string
17981	urlParams_ gensupport.URLParams
17982	ctx_       context.Context
17983	header_    http.Header
17984}
17985
17986// DeleteAgent: Deletes the specified agent.
17987//
17988// - parent: The project that the agent to delete is associated with.
17989//   Format: `projects/`.
17990func (r *ProjectsService) DeleteAgent(parent string) *ProjectsDeleteAgentCall {
17991	c := &ProjectsDeleteAgentCall{s: r.s, urlParams_: make(gensupport.URLParams)}
17992	c.parent = parent
17993	return c
17994}
17995
17996// Fields allows partial responses to be retrieved. See
17997// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
17998// for more information.
17999func (c *ProjectsDeleteAgentCall) Fields(s ...googleapi.Field) *ProjectsDeleteAgentCall {
18000	c.urlParams_.Set("fields", googleapi.CombineFields(s))
18001	return c
18002}
18003
18004// Context sets the context to be used in this call's Do method. Any
18005// pending HTTP request will be aborted if the provided context is
18006// canceled.
18007func (c *ProjectsDeleteAgentCall) Context(ctx context.Context) *ProjectsDeleteAgentCall {
18008	c.ctx_ = ctx
18009	return c
18010}
18011
18012// Header returns an http.Header that can be modified by the caller to
18013// add HTTP headers to the request.
18014func (c *ProjectsDeleteAgentCall) Header() http.Header {
18015	if c.header_ == nil {
18016		c.header_ = make(http.Header)
18017	}
18018	return c.header_
18019}
18020
18021func (c *ProjectsDeleteAgentCall) doRequest(alt string) (*http.Response, error) {
18022	reqHeaders := make(http.Header)
18023	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20211027")
18024	for k, v := range c.header_ {
18025		reqHeaders[k] = v
18026	}
18027	reqHeaders.Set("User-Agent", c.s.userAgent())
18028	var body io.Reader = nil
18029	c.urlParams_.Set("alt", alt)
18030	c.urlParams_.Set("prettyPrint", "false")
18031	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+parent}/agent")
18032	urls += "?" + c.urlParams_.Encode()
18033	req, err := http.NewRequest("DELETE", urls, body)
18034	if err != nil {
18035		return nil, err
18036	}
18037	req.Header = reqHeaders
18038	googleapi.Expand(req.URL, map[string]string{
18039		"parent": c.parent,
18040	})
18041	return gensupport.SendRequest(c.ctx_, c.s.client, req)
18042}
18043
18044// Do executes the "dialogflow.projects.deleteAgent" call.
18045// Exactly one of *GoogleProtobufEmpty or error will be non-nil. Any
18046// non-2xx status code is an error. Response headers are in either
18047// *GoogleProtobufEmpty.ServerResponse.Header or (if a response was
18048// returned at all) in error.(*googleapi.Error).Header. Use
18049// googleapi.IsNotModified to check whether the returned error was
18050// because http.StatusNotModified was returned.
18051func (c *ProjectsDeleteAgentCall) Do(opts ...googleapi.CallOption) (*GoogleProtobufEmpty, error) {
18052	gensupport.SetOptions(c.urlParams_, opts...)
18053	res, err := c.doRequest("json")
18054	if res != nil && res.StatusCode == http.StatusNotModified {
18055		if res.Body != nil {
18056			res.Body.Close()
18057		}
18058		return nil, &googleapi.Error{
18059			Code:   res.StatusCode,
18060			Header: res.Header,
18061		}
18062	}
18063	if err != nil {
18064		return nil, err
18065	}
18066	defer googleapi.CloseBody(res)
18067	if err := googleapi.CheckResponse(res); err != nil {
18068		return nil, err
18069	}
18070	ret := &GoogleProtobufEmpty{
18071		ServerResponse: googleapi.ServerResponse{
18072			Header:         res.Header,
18073			HTTPStatusCode: res.StatusCode,
18074		},
18075	}
18076	target := &ret
18077	if err := gensupport.DecodeResponse(target, res); err != nil {
18078		return nil, err
18079	}
18080	return ret, nil
18081	// {
18082	//   "description": "Deletes the specified agent.",
18083	//   "flatPath": "v2/projects/{projectsId}/agent",
18084	//   "httpMethod": "DELETE",
18085	//   "id": "dialogflow.projects.deleteAgent",
18086	//   "parameterOrder": [
18087	//     "parent"
18088	//   ],
18089	//   "parameters": {
18090	//     "parent": {
18091	//       "description": "Required. The project that the agent to delete is associated with. Format: `projects/`.",
18092	//       "location": "path",
18093	//       "pattern": "^projects/[^/]+$",
18094	//       "required": true,
18095	//       "type": "string"
18096	//     }
18097	//   },
18098	//   "path": "v2/{+parent}/agent",
18099	//   "response": {
18100	//     "$ref": "GoogleProtobufEmpty"
18101	//   },
18102	//   "scopes": [
18103	//     "https://www.googleapis.com/auth/cloud-platform",
18104	//     "https://www.googleapis.com/auth/dialogflow"
18105	//   ]
18106	// }
18107
18108}
18109
18110// method id "dialogflow.projects.getAgent":
18111
18112type ProjectsGetAgentCall struct {
18113	s            *Service
18114	parent       string
18115	urlParams_   gensupport.URLParams
18116	ifNoneMatch_ string
18117	ctx_         context.Context
18118	header_      http.Header
18119}
18120
18121// GetAgent: Retrieves the specified agent.
18122//
18123// - parent: The project that the agent to fetch is associated with.
18124//   Format: `projects/`.
18125func (r *ProjectsService) GetAgent(parent string) *ProjectsGetAgentCall {
18126	c := &ProjectsGetAgentCall{s: r.s, urlParams_: make(gensupport.URLParams)}
18127	c.parent = parent
18128	return c
18129}
18130
18131// Fields allows partial responses to be retrieved. See
18132// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
18133// for more information.
18134func (c *ProjectsGetAgentCall) Fields(s ...googleapi.Field) *ProjectsGetAgentCall {
18135	c.urlParams_.Set("fields", googleapi.CombineFields(s))
18136	return c
18137}
18138
18139// IfNoneMatch sets the optional parameter which makes the operation
18140// fail if the object's ETag matches the given value. This is useful for
18141// getting updates only after the object has changed since the last
18142// request. Use googleapi.IsNotModified to check whether the response
18143// error from Do is the result of In-None-Match.
18144func (c *ProjectsGetAgentCall) IfNoneMatch(entityTag string) *ProjectsGetAgentCall {
18145	c.ifNoneMatch_ = entityTag
18146	return c
18147}
18148
18149// Context sets the context to be used in this call's Do method. Any
18150// pending HTTP request will be aborted if the provided context is
18151// canceled.
18152func (c *ProjectsGetAgentCall) Context(ctx context.Context) *ProjectsGetAgentCall {
18153	c.ctx_ = ctx
18154	return c
18155}
18156
18157// Header returns an http.Header that can be modified by the caller to
18158// add HTTP headers to the request.
18159func (c *ProjectsGetAgentCall) Header() http.Header {
18160	if c.header_ == nil {
18161		c.header_ = make(http.Header)
18162	}
18163	return c.header_
18164}
18165
18166func (c *ProjectsGetAgentCall) doRequest(alt string) (*http.Response, error) {
18167	reqHeaders := make(http.Header)
18168	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20211027")
18169	for k, v := range c.header_ {
18170		reqHeaders[k] = v
18171	}
18172	reqHeaders.Set("User-Agent", c.s.userAgent())
18173	if c.ifNoneMatch_ != "" {
18174		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
18175	}
18176	var body io.Reader = nil
18177	c.urlParams_.Set("alt", alt)
18178	c.urlParams_.Set("prettyPrint", "false")
18179	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+parent}/agent")
18180	urls += "?" + c.urlParams_.Encode()
18181	req, err := http.NewRequest("GET", urls, body)
18182	if err != nil {
18183		return nil, err
18184	}
18185	req.Header = reqHeaders
18186	googleapi.Expand(req.URL, map[string]string{
18187		"parent": c.parent,
18188	})
18189	return gensupport.SendRequest(c.ctx_, c.s.client, req)
18190}
18191
18192// Do executes the "dialogflow.projects.getAgent" call.
18193// Exactly one of *GoogleCloudDialogflowV2Agent or error will be
18194// non-nil. Any non-2xx status code is an error. Response headers are in
18195// either *GoogleCloudDialogflowV2Agent.ServerResponse.Header or (if a
18196// response was returned at all) in error.(*googleapi.Error).Header. Use
18197// googleapi.IsNotModified to check whether the returned error was
18198// because http.StatusNotModified was returned.
18199func (c *ProjectsGetAgentCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDialogflowV2Agent, error) {
18200	gensupport.SetOptions(c.urlParams_, opts...)
18201	res, err := c.doRequest("json")
18202	if res != nil && res.StatusCode == http.StatusNotModified {
18203		if res.Body != nil {
18204			res.Body.Close()
18205		}
18206		return nil, &googleapi.Error{
18207			Code:   res.StatusCode,
18208			Header: res.Header,
18209		}
18210	}
18211	if err != nil {
18212		return nil, err
18213	}
18214	defer googleapi.CloseBody(res)
18215	if err := googleapi.CheckResponse(res); err != nil {
18216		return nil, err
18217	}
18218	ret := &GoogleCloudDialogflowV2Agent{
18219		ServerResponse: googleapi.ServerResponse{
18220			Header:         res.Header,
18221			HTTPStatusCode: res.StatusCode,
18222		},
18223	}
18224	target := &ret
18225	if err := gensupport.DecodeResponse(target, res); err != nil {
18226		return nil, err
18227	}
18228	return ret, nil
18229	// {
18230	//   "description": "Retrieves the specified agent.",
18231	//   "flatPath": "v2/projects/{projectsId}/agent",
18232	//   "httpMethod": "GET",
18233	//   "id": "dialogflow.projects.getAgent",
18234	//   "parameterOrder": [
18235	//     "parent"
18236	//   ],
18237	//   "parameters": {
18238	//     "parent": {
18239	//       "description": "Required. The project that the agent to fetch is associated with. Format: `projects/`.",
18240	//       "location": "path",
18241	//       "pattern": "^projects/[^/]+$",
18242	//       "required": true,
18243	//       "type": "string"
18244	//     }
18245	//   },
18246	//   "path": "v2/{+parent}/agent",
18247	//   "response": {
18248	//     "$ref": "GoogleCloudDialogflowV2Agent"
18249	//   },
18250	//   "scopes": [
18251	//     "https://www.googleapis.com/auth/cloud-platform",
18252	//     "https://www.googleapis.com/auth/dialogflow"
18253	//   ]
18254	// }
18255
18256}
18257
18258// method id "dialogflow.projects.setAgent":
18259
18260type ProjectsSetAgentCall struct {
18261	s                            *Service
18262	parent                       string
18263	googleclouddialogflowv2agent *GoogleCloudDialogflowV2Agent
18264	urlParams_                   gensupport.URLParams
18265	ctx_                         context.Context
18266	header_                      http.Header
18267}
18268
18269// SetAgent: Creates/updates the specified agent. Note: You should
18270// always train an agent prior to sending it queries. See the training
18271// documentation (https://cloud.google.com/dialogflow/es/docs/training).
18272//
18273// - parent: The project of this agent. Format: `projects/`.
18274func (r *ProjectsService) SetAgent(parent string, googleclouddialogflowv2agent *GoogleCloudDialogflowV2Agent) *ProjectsSetAgentCall {
18275	c := &ProjectsSetAgentCall{s: r.s, urlParams_: make(gensupport.URLParams)}
18276	c.parent = parent
18277	c.googleclouddialogflowv2agent = googleclouddialogflowv2agent
18278	return c
18279}
18280
18281// UpdateMask sets the optional parameter "updateMask": The mask to
18282// control which fields get updated.
18283func (c *ProjectsSetAgentCall) UpdateMask(updateMask string) *ProjectsSetAgentCall {
18284	c.urlParams_.Set("updateMask", updateMask)
18285	return c
18286}
18287
18288// Fields allows partial responses to be retrieved. See
18289// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
18290// for more information.
18291func (c *ProjectsSetAgentCall) Fields(s ...googleapi.Field) *ProjectsSetAgentCall {
18292	c.urlParams_.Set("fields", googleapi.CombineFields(s))
18293	return c
18294}
18295
18296// Context sets the context to be used in this call's Do method. Any
18297// pending HTTP request will be aborted if the provided context is
18298// canceled.
18299func (c *ProjectsSetAgentCall) Context(ctx context.Context) *ProjectsSetAgentCall {
18300	c.ctx_ = ctx
18301	return c
18302}
18303
18304// Header returns an http.Header that can be modified by the caller to
18305// add HTTP headers to the request.
18306func (c *ProjectsSetAgentCall) Header() http.Header {
18307	if c.header_ == nil {
18308		c.header_ = make(http.Header)
18309	}
18310	return c.header_
18311}
18312
18313func (c *ProjectsSetAgentCall) doRequest(alt string) (*http.Response, error) {
18314	reqHeaders := make(http.Header)
18315	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20211027")
18316	for k, v := range c.header_ {
18317		reqHeaders[k] = v
18318	}
18319	reqHeaders.Set("User-Agent", c.s.userAgent())
18320	var body io.Reader = nil
18321	body, err := googleapi.WithoutDataWrapper.JSONReader(c.googleclouddialogflowv2agent)
18322	if err != nil {
18323		return nil, err
18324	}
18325	reqHeaders.Set("Content-Type", "application/json")
18326	c.urlParams_.Set("alt", alt)
18327	c.urlParams_.Set("prettyPrint", "false")
18328	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+parent}/agent")
18329	urls += "?" + c.urlParams_.Encode()
18330	req, err := http.NewRequest("POST", urls, body)
18331	if err != nil {
18332		return nil, err
18333	}
18334	req.Header = reqHeaders
18335	googleapi.Expand(req.URL, map[string]string{
18336		"parent": c.parent,
18337	})
18338	return gensupport.SendRequest(c.ctx_, c.s.client, req)
18339}
18340
18341// Do executes the "dialogflow.projects.setAgent" call.
18342// Exactly one of *GoogleCloudDialogflowV2Agent or error will be
18343// non-nil. Any non-2xx status code is an error. Response headers are in
18344// either *GoogleCloudDialogflowV2Agent.ServerResponse.Header or (if a
18345// response was returned at all) in error.(*googleapi.Error).Header. Use
18346// googleapi.IsNotModified to check whether the returned error was
18347// because http.StatusNotModified was returned.
18348func (c *ProjectsSetAgentCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDialogflowV2Agent, error) {
18349	gensupport.SetOptions(c.urlParams_, opts...)
18350	res, err := c.doRequest("json")
18351	if res != nil && res.StatusCode == http.StatusNotModified {
18352		if res.Body != nil {
18353			res.Body.Close()
18354		}
18355		return nil, &googleapi.Error{
18356			Code:   res.StatusCode,
18357			Header: res.Header,
18358		}
18359	}
18360	if err != nil {
18361		return nil, err
18362	}
18363	defer googleapi.CloseBody(res)
18364	if err := googleapi.CheckResponse(res); err != nil {
18365		return nil, err
18366	}
18367	ret := &GoogleCloudDialogflowV2Agent{
18368		ServerResponse: googleapi.ServerResponse{
18369			Header:         res.Header,
18370			HTTPStatusCode: res.StatusCode,
18371		},
18372	}
18373	target := &ret
18374	if err := gensupport.DecodeResponse(target, res); err != nil {
18375		return nil, err
18376	}
18377	return ret, nil
18378	// {
18379	//   "description": "Creates/updates the specified agent. Note: You should always train an agent prior to sending it queries. See the [training documentation](https://cloud.google.com/dialogflow/es/docs/training).",
18380	//   "flatPath": "v2/projects/{projectsId}/agent",
18381	//   "httpMethod": "POST",
18382	//   "id": "dialogflow.projects.setAgent",
18383	//   "parameterOrder": [
18384	//     "parent"
18385	//   ],
18386	//   "parameters": {
18387	//     "parent": {
18388	//       "description": "Required. The project of this agent. Format: `projects/`.",
18389	//       "location": "path",
18390	//       "pattern": "^projects/[^/]+$",
18391	//       "required": true,
18392	//       "type": "string"
18393	//     },
18394	//     "updateMask": {
18395	//       "description": "Optional. The mask to control which fields get updated.",
18396	//       "format": "google-fieldmask",
18397	//       "location": "query",
18398	//       "type": "string"
18399	//     }
18400	//   },
18401	//   "path": "v2/{+parent}/agent",
18402	//   "request": {
18403	//     "$ref": "GoogleCloudDialogflowV2Agent"
18404	//   },
18405	//   "response": {
18406	//     "$ref": "GoogleCloudDialogflowV2Agent"
18407	//   },
18408	//   "scopes": [
18409	//     "https://www.googleapis.com/auth/cloud-platform",
18410	//     "https://www.googleapis.com/auth/dialogflow"
18411	//   ]
18412	// }
18413
18414}
18415
18416// method id "dialogflow.projects.agent.export":
18417
18418type ProjectsAgentExportCall struct {
18419	s                                         *Service
18420	parent                                    string
18421	googleclouddialogflowv2exportagentrequest *GoogleCloudDialogflowV2ExportAgentRequest
18422	urlParams_                                gensupport.URLParams
18423	ctx_                                      context.Context
18424	header_                                   http.Header
18425}
18426
18427// Export: Exports the specified agent to a ZIP file. This method is a
18428// long-running operation
18429// (https://cloud.google.com/dialogflow/es/docs/how/long-running-operations).
18430// The returned `Operation` type has the following method-specific
18431// fields: - `metadata`: An empty Struct message
18432// (https://developers.google.com/protocol-buffers/docs/reference/google.protobuf#struct)
18433// - `response`: ExportAgentResponse
18434//
18435// - parent: The project that the agent to export is associated with.
18436//   Format: `projects/`.
18437func (r *ProjectsAgentService) Export(parent string, googleclouddialogflowv2exportagentrequest *GoogleCloudDialogflowV2ExportAgentRequest) *ProjectsAgentExportCall {
18438	c := &ProjectsAgentExportCall{s: r.s, urlParams_: make(gensupport.URLParams)}
18439	c.parent = parent
18440	c.googleclouddialogflowv2exportagentrequest = googleclouddialogflowv2exportagentrequest
18441	return c
18442}
18443
18444// Fields allows partial responses to be retrieved. See
18445// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
18446// for more information.
18447func (c *ProjectsAgentExportCall) Fields(s ...googleapi.Field) *ProjectsAgentExportCall {
18448	c.urlParams_.Set("fields", googleapi.CombineFields(s))
18449	return c
18450}
18451
18452// Context sets the context to be used in this call's Do method. Any
18453// pending HTTP request will be aborted if the provided context is
18454// canceled.
18455func (c *ProjectsAgentExportCall) Context(ctx context.Context) *ProjectsAgentExportCall {
18456	c.ctx_ = ctx
18457	return c
18458}
18459
18460// Header returns an http.Header that can be modified by the caller to
18461// add HTTP headers to the request.
18462func (c *ProjectsAgentExportCall) Header() http.Header {
18463	if c.header_ == nil {
18464		c.header_ = make(http.Header)
18465	}
18466	return c.header_
18467}
18468
18469func (c *ProjectsAgentExportCall) doRequest(alt string) (*http.Response, error) {
18470	reqHeaders := make(http.Header)
18471	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20211027")
18472	for k, v := range c.header_ {
18473		reqHeaders[k] = v
18474	}
18475	reqHeaders.Set("User-Agent", c.s.userAgent())
18476	var body io.Reader = nil
18477	body, err := googleapi.WithoutDataWrapper.JSONReader(c.googleclouddialogflowv2exportagentrequest)
18478	if err != nil {
18479		return nil, err
18480	}
18481	reqHeaders.Set("Content-Type", "application/json")
18482	c.urlParams_.Set("alt", alt)
18483	c.urlParams_.Set("prettyPrint", "false")
18484	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+parent}/agent:export")
18485	urls += "?" + c.urlParams_.Encode()
18486	req, err := http.NewRequest("POST", urls, body)
18487	if err != nil {
18488		return nil, err
18489	}
18490	req.Header = reqHeaders
18491	googleapi.Expand(req.URL, map[string]string{
18492		"parent": c.parent,
18493	})
18494	return gensupport.SendRequest(c.ctx_, c.s.client, req)
18495}
18496
18497// Do executes the "dialogflow.projects.agent.export" call.
18498// Exactly one of *GoogleLongrunningOperation or error will be non-nil.
18499// Any non-2xx status code is an error. Response headers are in either
18500// *GoogleLongrunningOperation.ServerResponse.Header or (if a response
18501// was returned at all) in error.(*googleapi.Error).Header. Use
18502// googleapi.IsNotModified to check whether the returned error was
18503// because http.StatusNotModified was returned.
18504func (c *ProjectsAgentExportCall) Do(opts ...googleapi.CallOption) (*GoogleLongrunningOperation, error) {
18505	gensupport.SetOptions(c.urlParams_, opts...)
18506	res, err := c.doRequest("json")
18507	if res != nil && res.StatusCode == http.StatusNotModified {
18508		if res.Body != nil {
18509			res.Body.Close()
18510		}
18511		return nil, &googleapi.Error{
18512			Code:   res.StatusCode,
18513			Header: res.Header,
18514		}
18515	}
18516	if err != nil {
18517		return nil, err
18518	}
18519	defer googleapi.CloseBody(res)
18520	if err := googleapi.CheckResponse(res); err != nil {
18521		return nil, err
18522	}
18523	ret := &GoogleLongrunningOperation{
18524		ServerResponse: googleapi.ServerResponse{
18525			Header:         res.Header,
18526			HTTPStatusCode: res.StatusCode,
18527		},
18528	}
18529	target := &ret
18530	if err := gensupport.DecodeResponse(target, res); err != nil {
18531		return nil, err
18532	}
18533	return ret, nil
18534	// {
18535	//   "description": "Exports the specified agent to a ZIP file. This method is a [long-running operation](https://cloud.google.com/dialogflow/es/docs/how/long-running-operations). The returned `Operation` type has the following method-specific fields: - `metadata`: An empty [Struct message](https://developers.google.com/protocol-buffers/docs/reference/google.protobuf#struct) - `response`: ExportAgentResponse",
18536	//   "flatPath": "v2/projects/{projectsId}/agent:export",
18537	//   "httpMethod": "POST",
18538	//   "id": "dialogflow.projects.agent.export",
18539	//   "parameterOrder": [
18540	//     "parent"
18541	//   ],
18542	//   "parameters": {
18543	//     "parent": {
18544	//       "description": "Required. The project that the agent to export is associated with. Format: `projects/`.",
18545	//       "location": "path",
18546	//       "pattern": "^projects/[^/]+$",
18547	//       "required": true,
18548	//       "type": "string"
18549	//     }
18550	//   },
18551	//   "path": "v2/{+parent}/agent:export",
18552	//   "request": {
18553	//     "$ref": "GoogleCloudDialogflowV2ExportAgentRequest"
18554	//   },
18555	//   "response": {
18556	//     "$ref": "GoogleLongrunningOperation"
18557	//   },
18558	//   "scopes": [
18559	//     "https://www.googleapis.com/auth/cloud-platform",
18560	//     "https://www.googleapis.com/auth/dialogflow"
18561	//   ]
18562	// }
18563
18564}
18565
18566// method id "dialogflow.projects.agent.getFulfillment":
18567
18568type ProjectsAgentGetFulfillmentCall struct {
18569	s            *Service
18570	name         string
18571	urlParams_   gensupport.URLParams
18572	ifNoneMatch_ string
18573	ctx_         context.Context
18574	header_      http.Header
18575}
18576
18577// GetFulfillment: Retrieves the fulfillment.
18578//
18579// - name: The name of the fulfillment. Format:
18580//   `projects//agent/fulfillment`.
18581func (r *ProjectsAgentService) GetFulfillment(name string) *ProjectsAgentGetFulfillmentCall {
18582	c := &ProjectsAgentGetFulfillmentCall{s: r.s, urlParams_: make(gensupport.URLParams)}
18583	c.name = name
18584	return c
18585}
18586
18587// Fields allows partial responses to be retrieved. See
18588// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
18589// for more information.
18590func (c *ProjectsAgentGetFulfillmentCall) Fields(s ...googleapi.Field) *ProjectsAgentGetFulfillmentCall {
18591	c.urlParams_.Set("fields", googleapi.CombineFields(s))
18592	return c
18593}
18594
18595// IfNoneMatch sets the optional parameter which makes the operation
18596// fail if the object's ETag matches the given value. This is useful for
18597// getting updates only after the object has changed since the last
18598// request. Use googleapi.IsNotModified to check whether the response
18599// error from Do is the result of In-None-Match.
18600func (c *ProjectsAgentGetFulfillmentCall) IfNoneMatch(entityTag string) *ProjectsAgentGetFulfillmentCall {
18601	c.ifNoneMatch_ = entityTag
18602	return c
18603}
18604
18605// Context sets the context to be used in this call's Do method. Any
18606// pending HTTP request will be aborted if the provided context is
18607// canceled.
18608func (c *ProjectsAgentGetFulfillmentCall) Context(ctx context.Context) *ProjectsAgentGetFulfillmentCall {
18609	c.ctx_ = ctx
18610	return c
18611}
18612
18613// Header returns an http.Header that can be modified by the caller to
18614// add HTTP headers to the request.
18615func (c *ProjectsAgentGetFulfillmentCall) Header() http.Header {
18616	if c.header_ == nil {
18617		c.header_ = make(http.Header)
18618	}
18619	return c.header_
18620}
18621
18622func (c *ProjectsAgentGetFulfillmentCall) doRequest(alt string) (*http.Response, error) {
18623	reqHeaders := make(http.Header)
18624	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20211027")
18625	for k, v := range c.header_ {
18626		reqHeaders[k] = v
18627	}
18628	reqHeaders.Set("User-Agent", c.s.userAgent())
18629	if c.ifNoneMatch_ != "" {
18630		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
18631	}
18632	var body io.Reader = nil
18633	c.urlParams_.Set("alt", alt)
18634	c.urlParams_.Set("prettyPrint", "false")
18635	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+name}")
18636	urls += "?" + c.urlParams_.Encode()
18637	req, err := http.NewRequest("GET", urls, body)
18638	if err != nil {
18639		return nil, err
18640	}
18641	req.Header = reqHeaders
18642	googleapi.Expand(req.URL, map[string]string{
18643		"name": c.name,
18644	})
18645	return gensupport.SendRequest(c.ctx_, c.s.client, req)
18646}
18647
18648// Do executes the "dialogflow.projects.agent.getFulfillment" call.
18649// Exactly one of *GoogleCloudDialogflowV2Fulfillment or error will be
18650// non-nil. Any non-2xx status code is an error. Response headers are in
18651// either *GoogleCloudDialogflowV2Fulfillment.ServerResponse.Header or
18652// (if a response was returned at all) in
18653// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
18654// whether the returned error was because http.StatusNotModified was
18655// returned.
18656func (c *ProjectsAgentGetFulfillmentCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDialogflowV2Fulfillment, error) {
18657	gensupport.SetOptions(c.urlParams_, opts...)
18658	res, err := c.doRequest("json")
18659	if res != nil && res.StatusCode == http.StatusNotModified {
18660		if res.Body != nil {
18661			res.Body.Close()
18662		}
18663		return nil, &googleapi.Error{
18664			Code:   res.StatusCode,
18665			Header: res.Header,
18666		}
18667	}
18668	if err != nil {
18669		return nil, err
18670	}
18671	defer googleapi.CloseBody(res)
18672	if err := googleapi.CheckResponse(res); err != nil {
18673		return nil, err
18674	}
18675	ret := &GoogleCloudDialogflowV2Fulfillment{
18676		ServerResponse: googleapi.ServerResponse{
18677			Header:         res.Header,
18678			HTTPStatusCode: res.StatusCode,
18679		},
18680	}
18681	target := &ret
18682	if err := gensupport.DecodeResponse(target, res); err != nil {
18683		return nil, err
18684	}
18685	return ret, nil
18686	// {
18687	//   "description": "Retrieves the fulfillment.",
18688	//   "flatPath": "v2/projects/{projectsId}/agent/fulfillment",
18689	//   "httpMethod": "GET",
18690	//   "id": "dialogflow.projects.agent.getFulfillment",
18691	//   "parameterOrder": [
18692	//     "name"
18693	//   ],
18694	//   "parameters": {
18695	//     "name": {
18696	//       "description": "Required. The name of the fulfillment. Format: `projects//agent/fulfillment`.",
18697	//       "location": "path",
18698	//       "pattern": "^projects/[^/]+/agent/fulfillment$",
18699	//       "required": true,
18700	//       "type": "string"
18701	//     }
18702	//   },
18703	//   "path": "v2/{+name}",
18704	//   "response": {
18705	//     "$ref": "GoogleCloudDialogflowV2Fulfillment"
18706	//   },
18707	//   "scopes": [
18708	//     "https://www.googleapis.com/auth/cloud-platform",
18709	//     "https://www.googleapis.com/auth/dialogflow"
18710	//   ]
18711	// }
18712
18713}
18714
18715// method id "dialogflow.projects.agent.getValidationResult":
18716
18717type ProjectsAgentGetValidationResultCall struct {
18718	s            *Service
18719	parent       string
18720	urlParams_   gensupport.URLParams
18721	ifNoneMatch_ string
18722	ctx_         context.Context
18723	header_      http.Header
18724}
18725
18726// GetValidationResult: Gets agent validation result. Agent validation
18727// is performed during training time and is updated automatically when
18728// training is completed.
18729//
18730// - parent: The project that the agent is associated with. Format:
18731//   `projects/`.
18732func (r *ProjectsAgentService) GetValidationResult(parent string) *ProjectsAgentGetValidationResultCall {
18733	c := &ProjectsAgentGetValidationResultCall{s: r.s, urlParams_: make(gensupport.URLParams)}
18734	c.parent = parent
18735	return c
18736}
18737
18738// LanguageCode sets the optional parameter "languageCode": The language
18739// for which you want a validation result. If not specified, the agent's
18740// default language is used. Many languages
18741// (https://cloud.google.com/dialogflow/docs/reference/language) are
18742// supported. Note: languages must be enabled in the agent before they
18743// can be used.
18744func (c *ProjectsAgentGetValidationResultCall) LanguageCode(languageCode string) *ProjectsAgentGetValidationResultCall {
18745	c.urlParams_.Set("languageCode", languageCode)
18746	return c
18747}
18748
18749// Fields allows partial responses to be retrieved. See
18750// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
18751// for more information.
18752func (c *ProjectsAgentGetValidationResultCall) Fields(s ...googleapi.Field) *ProjectsAgentGetValidationResultCall {
18753	c.urlParams_.Set("fields", googleapi.CombineFields(s))
18754	return c
18755}
18756
18757// IfNoneMatch sets the optional parameter which makes the operation
18758// fail if the object's ETag matches the given value. This is useful for
18759// getting updates only after the object has changed since the last
18760// request. Use googleapi.IsNotModified to check whether the response
18761// error from Do is the result of In-None-Match.
18762func (c *ProjectsAgentGetValidationResultCall) IfNoneMatch(entityTag string) *ProjectsAgentGetValidationResultCall {
18763	c.ifNoneMatch_ = entityTag
18764	return c
18765}
18766
18767// Context sets the context to be used in this call's Do method. Any
18768// pending HTTP request will be aborted if the provided context is
18769// canceled.
18770func (c *ProjectsAgentGetValidationResultCall) Context(ctx context.Context) *ProjectsAgentGetValidationResultCall {
18771	c.ctx_ = ctx
18772	return c
18773}
18774
18775// Header returns an http.Header that can be modified by the caller to
18776// add HTTP headers to the request.
18777func (c *ProjectsAgentGetValidationResultCall) Header() http.Header {
18778	if c.header_ == nil {
18779		c.header_ = make(http.Header)
18780	}
18781	return c.header_
18782}
18783
18784func (c *ProjectsAgentGetValidationResultCall) doRequest(alt string) (*http.Response, error) {
18785	reqHeaders := make(http.Header)
18786	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20211027")
18787	for k, v := range c.header_ {
18788		reqHeaders[k] = v
18789	}
18790	reqHeaders.Set("User-Agent", c.s.userAgent())
18791	if c.ifNoneMatch_ != "" {
18792		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
18793	}
18794	var body io.Reader = nil
18795	c.urlParams_.Set("alt", alt)
18796	c.urlParams_.Set("prettyPrint", "false")
18797	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+parent}/agent/validationResult")
18798	urls += "?" + c.urlParams_.Encode()
18799	req, err := http.NewRequest("GET", urls, body)
18800	if err != nil {
18801		return nil, err
18802	}
18803	req.Header = reqHeaders
18804	googleapi.Expand(req.URL, map[string]string{
18805		"parent": c.parent,
18806	})
18807	return gensupport.SendRequest(c.ctx_, c.s.client, req)
18808}
18809
18810// Do executes the "dialogflow.projects.agent.getValidationResult" call.
18811// Exactly one of *GoogleCloudDialogflowV2ValidationResult or error will
18812// be non-nil. Any non-2xx status code is an error. Response headers are
18813// in either
18814// *GoogleCloudDialogflowV2ValidationResult.ServerResponse.Header or (if
18815// a response was returned at all) in error.(*googleapi.Error).Header.
18816// Use googleapi.IsNotModified to check whether the returned error was
18817// because http.StatusNotModified was returned.
18818func (c *ProjectsAgentGetValidationResultCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDialogflowV2ValidationResult, error) {
18819	gensupport.SetOptions(c.urlParams_, opts...)
18820	res, err := c.doRequest("json")
18821	if res != nil && res.StatusCode == http.StatusNotModified {
18822		if res.Body != nil {
18823			res.Body.Close()
18824		}
18825		return nil, &googleapi.Error{
18826			Code:   res.StatusCode,
18827			Header: res.Header,
18828		}
18829	}
18830	if err != nil {
18831		return nil, err
18832	}
18833	defer googleapi.CloseBody(res)
18834	if err := googleapi.CheckResponse(res); err != nil {
18835		return nil, err
18836	}
18837	ret := &GoogleCloudDialogflowV2ValidationResult{
18838		ServerResponse: googleapi.ServerResponse{
18839			Header:         res.Header,
18840			HTTPStatusCode: res.StatusCode,
18841		},
18842	}
18843	target := &ret
18844	if err := gensupport.DecodeResponse(target, res); err != nil {
18845		return nil, err
18846	}
18847	return ret, nil
18848	// {
18849	//   "description": "Gets agent validation result. Agent validation is performed during training time and is updated automatically when training is completed.",
18850	//   "flatPath": "v2/projects/{projectsId}/agent/validationResult",
18851	//   "httpMethod": "GET",
18852	//   "id": "dialogflow.projects.agent.getValidationResult",
18853	//   "parameterOrder": [
18854	//     "parent"
18855	//   ],
18856	//   "parameters": {
18857	//     "languageCode": {
18858	//       "description": "Optional. The language for which you want a validation result. If not specified, the agent's default language is used. [Many languages](https://cloud.google.com/dialogflow/docs/reference/language) are supported. Note: languages must be enabled in the agent before they can be used.",
18859	//       "location": "query",
18860	//       "type": "string"
18861	//     },
18862	//     "parent": {
18863	//       "description": "Required. The project that the agent is associated with. Format: `projects/`.",
18864	//       "location": "path",
18865	//       "pattern": "^projects/[^/]+$",
18866	//       "required": true,
18867	//       "type": "string"
18868	//     }
18869	//   },
18870	//   "path": "v2/{+parent}/agent/validationResult",
18871	//   "response": {
18872	//     "$ref": "GoogleCloudDialogflowV2ValidationResult"
18873	//   },
18874	//   "scopes": [
18875	//     "https://www.googleapis.com/auth/cloud-platform",
18876	//     "https://www.googleapis.com/auth/dialogflow"
18877	//   ]
18878	// }
18879
18880}
18881
18882// method id "dialogflow.projects.agent.import":
18883
18884type ProjectsAgentImportCall struct {
18885	s                                         *Service
18886	parent                                    string
18887	googleclouddialogflowv2importagentrequest *GoogleCloudDialogflowV2ImportAgentRequest
18888	urlParams_                                gensupport.URLParams
18889	ctx_                                      context.Context
18890	header_                                   http.Header
18891}
18892
18893// Import: Imports the specified agent from a ZIP file. Uploads new
18894// intents and entity types without deleting the existing ones. Intents
18895// and entity types with the same name are replaced with the new
18896// versions from ImportAgentRequest. After the import, the imported
18897// draft agent will be trained automatically (unless disabled in agent
18898// settings). However, once the import is done, training may not be
18899// completed yet. Please call TrainAgent and wait for the operation it
18900// returns in order to train explicitly. This method is a long-running
18901// operation
18902// (https://cloud.google.com/dialogflow/es/docs/how/long-running-operations).
18903// The returned `Operation` type has the following method-specific
18904// fields: - `metadata`: An empty Struct message
18905// (https://developers.google.com/protocol-buffers/docs/reference/google.protobuf#struct)
18906// - `response`: An Empty message
18907// (https://developers.google.com/protocol-buffers/docs/reference/google.protobuf#empty)
18908// The operation only tracks when importing is complete, not when it is
18909// done training. Note: You should always train an agent prior to
18910// sending it queries. See the training documentation
18911// (https://cloud.google.com/dialogflow/es/docs/training).
18912//
18913// - parent: The project that the agent to import is associated with.
18914//   Format: `projects/`.
18915func (r *ProjectsAgentService) Import(parent string, googleclouddialogflowv2importagentrequest *GoogleCloudDialogflowV2ImportAgentRequest) *ProjectsAgentImportCall {
18916	c := &ProjectsAgentImportCall{s: r.s, urlParams_: make(gensupport.URLParams)}
18917	c.parent = parent
18918	c.googleclouddialogflowv2importagentrequest = googleclouddialogflowv2importagentrequest
18919	return c
18920}
18921
18922// Fields allows partial responses to be retrieved. See
18923// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
18924// for more information.
18925func (c *ProjectsAgentImportCall) Fields(s ...googleapi.Field) *ProjectsAgentImportCall {
18926	c.urlParams_.Set("fields", googleapi.CombineFields(s))
18927	return c
18928}
18929
18930// Context sets the context to be used in this call's Do method. Any
18931// pending HTTP request will be aborted if the provided context is
18932// canceled.
18933func (c *ProjectsAgentImportCall) Context(ctx context.Context) *ProjectsAgentImportCall {
18934	c.ctx_ = ctx
18935	return c
18936}
18937
18938// Header returns an http.Header that can be modified by the caller to
18939// add HTTP headers to the request.
18940func (c *ProjectsAgentImportCall) Header() http.Header {
18941	if c.header_ == nil {
18942		c.header_ = make(http.Header)
18943	}
18944	return c.header_
18945}
18946
18947func (c *ProjectsAgentImportCall) doRequest(alt string) (*http.Response, error) {
18948	reqHeaders := make(http.Header)
18949	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20211027")
18950	for k, v := range c.header_ {
18951		reqHeaders[k] = v
18952	}
18953	reqHeaders.Set("User-Agent", c.s.userAgent())
18954	var body io.Reader = nil
18955	body, err := googleapi.WithoutDataWrapper.JSONReader(c.googleclouddialogflowv2importagentrequest)
18956	if err != nil {
18957		return nil, err
18958	}
18959	reqHeaders.Set("Content-Type", "application/json")
18960	c.urlParams_.Set("alt", alt)
18961	c.urlParams_.Set("prettyPrint", "false")
18962	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+parent}/agent:import")
18963	urls += "?" + c.urlParams_.Encode()
18964	req, err := http.NewRequest("POST", urls, body)
18965	if err != nil {
18966		return nil, err
18967	}
18968	req.Header = reqHeaders
18969	googleapi.Expand(req.URL, map[string]string{
18970		"parent": c.parent,
18971	})
18972	return gensupport.SendRequest(c.ctx_, c.s.client, req)
18973}
18974
18975// Do executes the "dialogflow.projects.agent.import" call.
18976// Exactly one of *GoogleLongrunningOperation or error will be non-nil.
18977// Any non-2xx status code is an error. Response headers are in either
18978// *GoogleLongrunningOperation.ServerResponse.Header or (if a response
18979// was returned at all) in error.(*googleapi.Error).Header. Use
18980// googleapi.IsNotModified to check whether the returned error was
18981// because http.StatusNotModified was returned.
18982func (c *ProjectsAgentImportCall) Do(opts ...googleapi.CallOption) (*GoogleLongrunningOperation, error) {
18983	gensupport.SetOptions(c.urlParams_, opts...)
18984	res, err := c.doRequest("json")
18985	if res != nil && res.StatusCode == http.StatusNotModified {
18986		if res.Body != nil {
18987			res.Body.Close()
18988		}
18989		return nil, &googleapi.Error{
18990			Code:   res.StatusCode,
18991			Header: res.Header,
18992		}
18993	}
18994	if err != nil {
18995		return nil, err
18996	}
18997	defer googleapi.CloseBody(res)
18998	if err := googleapi.CheckResponse(res); err != nil {
18999		return nil, err
19000	}
19001	ret := &GoogleLongrunningOperation{
19002		ServerResponse: googleapi.ServerResponse{
19003			Header:         res.Header,
19004			HTTPStatusCode: res.StatusCode,
19005		},
19006	}
19007	target := &ret
19008	if err := gensupport.DecodeResponse(target, res); err != nil {
19009		return nil, err
19010	}
19011	return ret, nil
19012	// {
19013	//   "description": "Imports the specified agent from a ZIP file. Uploads new intents and entity types without deleting the existing ones. Intents and entity types with the same name are replaced with the new versions from ImportAgentRequest. After the import, the imported draft agent will be trained automatically (unless disabled in agent settings). However, once the import is done, training may not be completed yet. Please call TrainAgent and wait for the operation it returns in order to train explicitly. This method is a [long-running operation](https://cloud.google.com/dialogflow/es/docs/how/long-running-operations). The returned `Operation` type has the following method-specific fields: - `metadata`: An empty [Struct message](https://developers.google.com/protocol-buffers/docs/reference/google.protobuf#struct) - `response`: An [Empty message](https://developers.google.com/protocol-buffers/docs/reference/google.protobuf#empty) The operation only tracks when importing is complete, not when it is done training. Note: You should always train an agent prior to sending it queries. See the [training documentation](https://cloud.google.com/dialogflow/es/docs/training).",
19014	//   "flatPath": "v2/projects/{projectsId}/agent:import",
19015	//   "httpMethod": "POST",
19016	//   "id": "dialogflow.projects.agent.import",
19017	//   "parameterOrder": [
19018	//     "parent"
19019	//   ],
19020	//   "parameters": {
19021	//     "parent": {
19022	//       "description": "Required. The project that the agent to import is associated with. Format: `projects/`.",
19023	//       "location": "path",
19024	//       "pattern": "^projects/[^/]+$",
19025	//       "required": true,
19026	//       "type": "string"
19027	//     }
19028	//   },
19029	//   "path": "v2/{+parent}/agent:import",
19030	//   "request": {
19031	//     "$ref": "GoogleCloudDialogflowV2ImportAgentRequest"
19032	//   },
19033	//   "response": {
19034	//     "$ref": "GoogleLongrunningOperation"
19035	//   },
19036	//   "scopes": [
19037	//     "https://www.googleapis.com/auth/cloud-platform",
19038	//     "https://www.googleapis.com/auth/dialogflow"
19039	//   ]
19040	// }
19041
19042}
19043
19044// method id "dialogflow.projects.agent.restore":
19045
19046type ProjectsAgentRestoreCall struct {
19047	s                                          *Service
19048	parent                                     string
19049	googleclouddialogflowv2restoreagentrequest *GoogleCloudDialogflowV2RestoreAgentRequest
19050	urlParams_                                 gensupport.URLParams
19051	ctx_                                       context.Context
19052	header_                                    http.Header
19053}
19054
19055// Restore: Restores the specified agent from a ZIP file. Replaces the
19056// current agent version with a new one. All the intents and entity
19057// types in the older version are deleted. After the restore, the
19058// restored draft agent will be trained automatically (unless disabled
19059// in agent settings). However, once the restore is done, training may
19060// not be completed yet. Please call TrainAgent and wait for the
19061// operation it returns in order to train explicitly. This method is a
19062// long-running operation
19063// (https://cloud.google.com/dialogflow/es/docs/how/long-running-operations).
19064// The returned `Operation` type has the following method-specific
19065// fields: - `metadata`: An empty Struct message
19066// (https://developers.google.com/protocol-buffers/docs/reference/google.protobuf#struct)
19067// - `response`: An Empty message
19068// (https://developers.google.com/protocol-buffers/docs/reference/google.protobuf#empty)
19069// The operation only tracks when restoring is complete, not when it is
19070// done training. Note: You should always train an agent prior to
19071// sending it queries. See the training documentation
19072// (https://cloud.google.com/dialogflow/es/docs/training).
19073//
19074// - parent: The project that the agent to restore is associated with.
19075//   Format: `projects/`.
19076func (r *ProjectsAgentService) Restore(parent string, googleclouddialogflowv2restoreagentrequest *GoogleCloudDialogflowV2RestoreAgentRequest) *ProjectsAgentRestoreCall {
19077	c := &ProjectsAgentRestoreCall{s: r.s, urlParams_: make(gensupport.URLParams)}
19078	c.parent = parent
19079	c.googleclouddialogflowv2restoreagentrequest = googleclouddialogflowv2restoreagentrequest
19080	return c
19081}
19082
19083// Fields allows partial responses to be retrieved. See
19084// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
19085// for more information.
19086func (c *ProjectsAgentRestoreCall) Fields(s ...googleapi.Field) *ProjectsAgentRestoreCall {
19087	c.urlParams_.Set("fields", googleapi.CombineFields(s))
19088	return c
19089}
19090
19091// Context sets the context to be used in this call's Do method. Any
19092// pending HTTP request will be aborted if the provided context is
19093// canceled.
19094func (c *ProjectsAgentRestoreCall) Context(ctx context.Context) *ProjectsAgentRestoreCall {
19095	c.ctx_ = ctx
19096	return c
19097}
19098
19099// Header returns an http.Header that can be modified by the caller to
19100// add HTTP headers to the request.
19101func (c *ProjectsAgentRestoreCall) Header() http.Header {
19102	if c.header_ == nil {
19103		c.header_ = make(http.Header)
19104	}
19105	return c.header_
19106}
19107
19108func (c *ProjectsAgentRestoreCall) doRequest(alt string) (*http.Response, error) {
19109	reqHeaders := make(http.Header)
19110	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20211027")
19111	for k, v := range c.header_ {
19112		reqHeaders[k] = v
19113	}
19114	reqHeaders.Set("User-Agent", c.s.userAgent())
19115	var body io.Reader = nil
19116	body, err := googleapi.WithoutDataWrapper.JSONReader(c.googleclouddialogflowv2restoreagentrequest)
19117	if err != nil {
19118		return nil, err
19119	}
19120	reqHeaders.Set("Content-Type", "application/json")
19121	c.urlParams_.Set("alt", alt)
19122	c.urlParams_.Set("prettyPrint", "false")
19123	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+parent}/agent:restore")
19124	urls += "?" + c.urlParams_.Encode()
19125	req, err := http.NewRequest("POST", urls, body)
19126	if err != nil {
19127		return nil, err
19128	}
19129	req.Header = reqHeaders
19130	googleapi.Expand(req.URL, map[string]string{
19131		"parent": c.parent,
19132	})
19133	return gensupport.SendRequest(c.ctx_, c.s.client, req)
19134}
19135
19136// Do executes the "dialogflow.projects.agent.restore" call.
19137// Exactly one of *GoogleLongrunningOperation or error will be non-nil.
19138// Any non-2xx status code is an error. Response headers are in either
19139// *GoogleLongrunningOperation.ServerResponse.Header or (if a response
19140// was returned at all) in error.(*googleapi.Error).Header. Use
19141// googleapi.IsNotModified to check whether the returned error was
19142// because http.StatusNotModified was returned.
19143func (c *ProjectsAgentRestoreCall) Do(opts ...googleapi.CallOption) (*GoogleLongrunningOperation, error) {
19144	gensupport.SetOptions(c.urlParams_, opts...)
19145	res, err := c.doRequest("json")
19146	if res != nil && res.StatusCode == http.StatusNotModified {
19147		if res.Body != nil {
19148			res.Body.Close()
19149		}
19150		return nil, &googleapi.Error{
19151			Code:   res.StatusCode,
19152			Header: res.Header,
19153		}
19154	}
19155	if err != nil {
19156		return nil, err
19157	}
19158	defer googleapi.CloseBody(res)
19159	if err := googleapi.CheckResponse(res); err != nil {
19160		return nil, err
19161	}
19162	ret := &GoogleLongrunningOperation{
19163		ServerResponse: googleapi.ServerResponse{
19164			Header:         res.Header,
19165			HTTPStatusCode: res.StatusCode,
19166		},
19167	}
19168	target := &ret
19169	if err := gensupport.DecodeResponse(target, res); err != nil {
19170		return nil, err
19171	}
19172	return ret, nil
19173	// {
19174	//   "description": "Restores the specified agent from a ZIP file. Replaces the current agent version with a new one. All the intents and entity types in the older version are deleted. After the restore, the restored draft agent will be trained automatically (unless disabled in agent settings). However, once the restore is done, training may not be completed yet. Please call TrainAgent and wait for the operation it returns in order to train explicitly. This method is a [long-running operation](https://cloud.google.com/dialogflow/es/docs/how/long-running-operations). The returned `Operation` type has the following method-specific fields: - `metadata`: An empty [Struct message](https://developers.google.com/protocol-buffers/docs/reference/google.protobuf#struct) - `response`: An [Empty message](https://developers.google.com/protocol-buffers/docs/reference/google.protobuf#empty) The operation only tracks when restoring is complete, not when it is done training. Note: You should always train an agent prior to sending it queries. See the [training documentation](https://cloud.google.com/dialogflow/es/docs/training).",
19175	//   "flatPath": "v2/projects/{projectsId}/agent:restore",
19176	//   "httpMethod": "POST",
19177	//   "id": "dialogflow.projects.agent.restore",
19178	//   "parameterOrder": [
19179	//     "parent"
19180	//   ],
19181	//   "parameters": {
19182	//     "parent": {
19183	//       "description": "Required. The project that the agent to restore is associated with. Format: `projects/`.",
19184	//       "location": "path",
19185	//       "pattern": "^projects/[^/]+$",
19186	//       "required": true,
19187	//       "type": "string"
19188	//     }
19189	//   },
19190	//   "path": "v2/{+parent}/agent:restore",
19191	//   "request": {
19192	//     "$ref": "GoogleCloudDialogflowV2RestoreAgentRequest"
19193	//   },
19194	//   "response": {
19195	//     "$ref": "GoogleLongrunningOperation"
19196	//   },
19197	//   "scopes": [
19198	//     "https://www.googleapis.com/auth/cloud-platform",
19199	//     "https://www.googleapis.com/auth/dialogflow"
19200	//   ]
19201	// }
19202
19203}
19204
19205// method id "dialogflow.projects.agent.search":
19206
19207type ProjectsAgentSearchCall struct {
19208	s            *Service
19209	parent       string
19210	urlParams_   gensupport.URLParams
19211	ifNoneMatch_ string
19212	ctx_         context.Context
19213	header_      http.Header
19214}
19215
19216// Search: Returns the list of agents. Since there is at most one
19217// conversational agent per project, this method is useful primarily for
19218// listing all agents across projects the caller has access to. One can
19219// achieve that with a wildcard project collection id "-". Refer to List
19220// Sub-Collections
19221// (https://cloud.google.com/apis/design/design_patterns#list_sub-collections).
19222//
19223// - parent: The project to list agents from. Format: `projects/`.
19224func (r *ProjectsAgentService) Search(parent string) *ProjectsAgentSearchCall {
19225	c := &ProjectsAgentSearchCall{s: r.s, urlParams_: make(gensupport.URLParams)}
19226	c.parent = parent
19227	return c
19228}
19229
19230// PageSize sets the optional parameter "pageSize": The maximum number
19231// of items to return in a single page. By default 100 and at most 1000.
19232func (c *ProjectsAgentSearchCall) PageSize(pageSize int64) *ProjectsAgentSearchCall {
19233	c.urlParams_.Set("pageSize", fmt.Sprint(pageSize))
19234	return c
19235}
19236
19237// PageToken sets the optional parameter "pageToken": The
19238// next_page_token value returned from a previous list request.
19239func (c *ProjectsAgentSearchCall) PageToken(pageToken string) *ProjectsAgentSearchCall {
19240	c.urlParams_.Set("pageToken", pageToken)
19241	return c
19242}
19243
19244// Fields allows partial responses to be retrieved. See
19245// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
19246// for more information.
19247func (c *ProjectsAgentSearchCall) Fields(s ...googleapi.Field) *ProjectsAgentSearchCall {
19248	c.urlParams_.Set("fields", googleapi.CombineFields(s))
19249	return c
19250}
19251
19252// IfNoneMatch sets the optional parameter which makes the operation
19253// fail if the object's ETag matches the given value. This is useful for
19254// getting updates only after the object has changed since the last
19255// request. Use googleapi.IsNotModified to check whether the response
19256// error from Do is the result of In-None-Match.
19257func (c *ProjectsAgentSearchCall) IfNoneMatch(entityTag string) *ProjectsAgentSearchCall {
19258	c.ifNoneMatch_ = entityTag
19259	return c
19260}
19261
19262// Context sets the context to be used in this call's Do method. Any
19263// pending HTTP request will be aborted if the provided context is
19264// canceled.
19265func (c *ProjectsAgentSearchCall) Context(ctx context.Context) *ProjectsAgentSearchCall {
19266	c.ctx_ = ctx
19267	return c
19268}
19269
19270// Header returns an http.Header that can be modified by the caller to
19271// add HTTP headers to the request.
19272func (c *ProjectsAgentSearchCall) Header() http.Header {
19273	if c.header_ == nil {
19274		c.header_ = make(http.Header)
19275	}
19276	return c.header_
19277}
19278
19279func (c *ProjectsAgentSearchCall) doRequest(alt string) (*http.Response, error) {
19280	reqHeaders := make(http.Header)
19281	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20211027")
19282	for k, v := range c.header_ {
19283		reqHeaders[k] = v
19284	}
19285	reqHeaders.Set("User-Agent", c.s.userAgent())
19286	if c.ifNoneMatch_ != "" {
19287		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
19288	}
19289	var body io.Reader = nil
19290	c.urlParams_.Set("alt", alt)
19291	c.urlParams_.Set("prettyPrint", "false")
19292	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+parent}/agent:search")
19293	urls += "?" + c.urlParams_.Encode()
19294	req, err := http.NewRequest("GET", urls, body)
19295	if err != nil {
19296		return nil, err
19297	}
19298	req.Header = reqHeaders
19299	googleapi.Expand(req.URL, map[string]string{
19300		"parent": c.parent,
19301	})
19302	return gensupport.SendRequest(c.ctx_, c.s.client, req)
19303}
19304
19305// Do executes the "dialogflow.projects.agent.search" call.
19306// Exactly one of *GoogleCloudDialogflowV2SearchAgentsResponse or error
19307// will be non-nil. Any non-2xx status code is an error. Response
19308// headers are in either
19309// *GoogleCloudDialogflowV2SearchAgentsResponse.ServerResponse.Header or
19310// (if a response was returned at all) in
19311// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
19312// whether the returned error was because http.StatusNotModified was
19313// returned.
19314func (c *ProjectsAgentSearchCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDialogflowV2SearchAgentsResponse, error) {
19315	gensupport.SetOptions(c.urlParams_, opts...)
19316	res, err := c.doRequest("json")
19317	if res != nil && res.StatusCode == http.StatusNotModified {
19318		if res.Body != nil {
19319			res.Body.Close()
19320		}
19321		return nil, &googleapi.Error{
19322			Code:   res.StatusCode,
19323			Header: res.Header,
19324		}
19325	}
19326	if err != nil {
19327		return nil, err
19328	}
19329	defer googleapi.CloseBody(res)
19330	if err := googleapi.CheckResponse(res); err != nil {
19331		return nil, err
19332	}
19333	ret := &GoogleCloudDialogflowV2SearchAgentsResponse{
19334		ServerResponse: googleapi.ServerResponse{
19335			Header:         res.Header,
19336			HTTPStatusCode: res.StatusCode,
19337		},
19338	}
19339	target := &ret
19340	if err := gensupport.DecodeResponse(target, res); err != nil {
19341		return nil, err
19342	}
19343	return ret, nil
19344	// {
19345	//   "description": "Returns the list of agents. Since there is at most one conversational agent per project, this method is useful primarily for listing all agents across projects the caller has access to. One can achieve that with a wildcard project collection id \"-\". Refer to [List Sub-Collections](https://cloud.google.com/apis/design/design_patterns#list_sub-collections).",
19346	//   "flatPath": "v2/projects/{projectsId}/agent:search",
19347	//   "httpMethod": "GET",
19348	//   "id": "dialogflow.projects.agent.search",
19349	//   "parameterOrder": [
19350	//     "parent"
19351	//   ],
19352	//   "parameters": {
19353	//     "pageSize": {
19354	//       "description": "Optional. The maximum number of items to return in a single page. By default 100 and at most 1000.",
19355	//       "format": "int32",
19356	//       "location": "query",
19357	//       "type": "integer"
19358	//     },
19359	//     "pageToken": {
19360	//       "description": "The next_page_token value returned from a previous list request.",
19361	//       "location": "query",
19362	//       "type": "string"
19363	//     },
19364	//     "parent": {
19365	//       "description": "Required. The project to list agents from. Format: `projects/`.",
19366	//       "location": "path",
19367	//       "pattern": "^projects/[^/]+$",
19368	//       "required": true,
19369	//       "type": "string"
19370	//     }
19371	//   },
19372	//   "path": "v2/{+parent}/agent:search",
19373	//   "response": {
19374	//     "$ref": "GoogleCloudDialogflowV2SearchAgentsResponse"
19375	//   },
19376	//   "scopes": [
19377	//     "https://www.googleapis.com/auth/cloud-platform",
19378	//     "https://www.googleapis.com/auth/dialogflow"
19379	//   ]
19380	// }
19381
19382}
19383
19384// Pages invokes f for each page of results.
19385// A non-nil error returned from f will halt the iteration.
19386// The provided context supersedes any context provided to the Context method.
19387func (c *ProjectsAgentSearchCall) Pages(ctx context.Context, f func(*GoogleCloudDialogflowV2SearchAgentsResponse) error) error {
19388	c.ctx_ = ctx
19389	defer c.PageToken(c.urlParams_.Get("pageToken")) // reset paging to original point
19390	for {
19391		x, err := c.Do()
19392		if err != nil {
19393			return err
19394		}
19395		if err := f(x); err != nil {
19396			return err
19397		}
19398		if x.NextPageToken == "" {
19399			return nil
19400		}
19401		c.PageToken(x.NextPageToken)
19402	}
19403}
19404
19405// method id "dialogflow.projects.agent.train":
19406
19407type ProjectsAgentTrainCall struct {
19408	s                                        *Service
19409	parent                                   string
19410	googleclouddialogflowv2trainagentrequest *GoogleCloudDialogflowV2TrainAgentRequest
19411	urlParams_                               gensupport.URLParams
19412	ctx_                                     context.Context
19413	header_                                  http.Header
19414}
19415
19416// Train: Trains the specified agent. This method is a long-running
19417// operation
19418// (https://cloud.google.com/dialogflow/es/docs/how/long-running-operations).
19419// The returned `Operation` type has the following method-specific
19420// fields: - `metadata`: An empty Struct message
19421// (https://developers.google.com/protocol-buffers/docs/reference/google.protobuf#struct)
19422// - `response`: An Empty message
19423// (https://developers.google.com/protocol-buffers/docs/reference/google.protobuf#empty)
19424// Note: You should always train an agent prior to sending it queries.
19425// See the training documentation
19426// (https://cloud.google.com/dialogflow/es/docs/training).
19427//
19428// - parent: The project that the agent to train is associated with.
19429//   Format: `projects/`.
19430func (r *ProjectsAgentService) Train(parent string, googleclouddialogflowv2trainagentrequest *GoogleCloudDialogflowV2TrainAgentRequest) *ProjectsAgentTrainCall {
19431	c := &ProjectsAgentTrainCall{s: r.s, urlParams_: make(gensupport.URLParams)}
19432	c.parent = parent
19433	c.googleclouddialogflowv2trainagentrequest = googleclouddialogflowv2trainagentrequest
19434	return c
19435}
19436
19437// Fields allows partial responses to be retrieved. See
19438// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
19439// for more information.
19440func (c *ProjectsAgentTrainCall) Fields(s ...googleapi.Field) *ProjectsAgentTrainCall {
19441	c.urlParams_.Set("fields", googleapi.CombineFields(s))
19442	return c
19443}
19444
19445// Context sets the context to be used in this call's Do method. Any
19446// pending HTTP request will be aborted if the provided context is
19447// canceled.
19448func (c *ProjectsAgentTrainCall) Context(ctx context.Context) *ProjectsAgentTrainCall {
19449	c.ctx_ = ctx
19450	return c
19451}
19452
19453// Header returns an http.Header that can be modified by the caller to
19454// add HTTP headers to the request.
19455func (c *ProjectsAgentTrainCall) Header() http.Header {
19456	if c.header_ == nil {
19457		c.header_ = make(http.Header)
19458	}
19459	return c.header_
19460}
19461
19462func (c *ProjectsAgentTrainCall) doRequest(alt string) (*http.Response, error) {
19463	reqHeaders := make(http.Header)
19464	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20211027")
19465	for k, v := range c.header_ {
19466		reqHeaders[k] = v
19467	}
19468	reqHeaders.Set("User-Agent", c.s.userAgent())
19469	var body io.Reader = nil
19470	body, err := googleapi.WithoutDataWrapper.JSONReader(c.googleclouddialogflowv2trainagentrequest)
19471	if err != nil {
19472		return nil, err
19473	}
19474	reqHeaders.Set("Content-Type", "application/json")
19475	c.urlParams_.Set("alt", alt)
19476	c.urlParams_.Set("prettyPrint", "false")
19477	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+parent}/agent:train")
19478	urls += "?" + c.urlParams_.Encode()
19479	req, err := http.NewRequest("POST", urls, body)
19480	if err != nil {
19481		return nil, err
19482	}
19483	req.Header = reqHeaders
19484	googleapi.Expand(req.URL, map[string]string{
19485		"parent": c.parent,
19486	})
19487	return gensupport.SendRequest(c.ctx_, c.s.client, req)
19488}
19489
19490// Do executes the "dialogflow.projects.agent.train" call.
19491// Exactly one of *GoogleLongrunningOperation or error will be non-nil.
19492// Any non-2xx status code is an error. Response headers are in either
19493// *GoogleLongrunningOperation.ServerResponse.Header or (if a response
19494// was returned at all) in error.(*googleapi.Error).Header. Use
19495// googleapi.IsNotModified to check whether the returned error was
19496// because http.StatusNotModified was returned.
19497func (c *ProjectsAgentTrainCall) Do(opts ...googleapi.CallOption) (*GoogleLongrunningOperation, error) {
19498	gensupport.SetOptions(c.urlParams_, opts...)
19499	res, err := c.doRequest("json")
19500	if res != nil && res.StatusCode == http.StatusNotModified {
19501		if res.Body != nil {
19502			res.Body.Close()
19503		}
19504		return nil, &googleapi.Error{
19505			Code:   res.StatusCode,
19506			Header: res.Header,
19507		}
19508	}
19509	if err != nil {
19510		return nil, err
19511	}
19512	defer googleapi.CloseBody(res)
19513	if err := googleapi.CheckResponse(res); err != nil {
19514		return nil, err
19515	}
19516	ret := &GoogleLongrunningOperation{
19517		ServerResponse: googleapi.ServerResponse{
19518			Header:         res.Header,
19519			HTTPStatusCode: res.StatusCode,
19520		},
19521	}
19522	target := &ret
19523	if err := gensupport.DecodeResponse(target, res); err != nil {
19524		return nil, err
19525	}
19526	return ret, nil
19527	// {
19528	//   "description": "Trains the specified agent. This method is a [long-running operation](https://cloud.google.com/dialogflow/es/docs/how/long-running-operations). The returned `Operation` type has the following method-specific fields: - `metadata`: An empty [Struct message](https://developers.google.com/protocol-buffers/docs/reference/google.protobuf#struct) - `response`: An [Empty message](https://developers.google.com/protocol-buffers/docs/reference/google.protobuf#empty) Note: You should always train an agent prior to sending it queries. See the [training documentation](https://cloud.google.com/dialogflow/es/docs/training).",
19529	//   "flatPath": "v2/projects/{projectsId}/agent:train",
19530	//   "httpMethod": "POST",
19531	//   "id": "dialogflow.projects.agent.train",
19532	//   "parameterOrder": [
19533	//     "parent"
19534	//   ],
19535	//   "parameters": {
19536	//     "parent": {
19537	//       "description": "Required. The project that the agent to train is associated with. Format: `projects/`.",
19538	//       "location": "path",
19539	//       "pattern": "^projects/[^/]+$",
19540	//       "required": true,
19541	//       "type": "string"
19542	//     }
19543	//   },
19544	//   "path": "v2/{+parent}/agent:train",
19545	//   "request": {
19546	//     "$ref": "GoogleCloudDialogflowV2TrainAgentRequest"
19547	//   },
19548	//   "response": {
19549	//     "$ref": "GoogleLongrunningOperation"
19550	//   },
19551	//   "scopes": [
19552	//     "https://www.googleapis.com/auth/cloud-platform",
19553	//     "https://www.googleapis.com/auth/dialogflow"
19554	//   ]
19555	// }
19556
19557}
19558
19559// method id "dialogflow.projects.agent.updateFulfillment":
19560
19561type ProjectsAgentUpdateFulfillmentCall struct {
19562	s                                  *Service
19563	nameid                             string
19564	googleclouddialogflowv2fulfillment *GoogleCloudDialogflowV2Fulfillment
19565	urlParams_                         gensupport.URLParams
19566	ctx_                               context.Context
19567	header_                            http.Header
19568}
19569
19570// UpdateFulfillment: Updates the fulfillment.
19571//
19572// - name: The unique identifier of the fulfillment. Supported formats:
19573//   - `projects//agent/fulfillment` -
19574//   `projects//locations//agent/fulfillment` This field is not used for
19575//   Fulfillment in an Environment.
19576func (r *ProjectsAgentService) UpdateFulfillment(nameid string, googleclouddialogflowv2fulfillment *GoogleCloudDialogflowV2Fulfillment) *ProjectsAgentUpdateFulfillmentCall {
19577	c := &ProjectsAgentUpdateFulfillmentCall{s: r.s, urlParams_: make(gensupport.URLParams)}
19578	c.nameid = nameid
19579	c.googleclouddialogflowv2fulfillment = googleclouddialogflowv2fulfillment
19580	return c
19581}
19582
19583// UpdateMask sets the optional parameter "updateMask": Required. The
19584// mask to control which fields get updated. If the mask is not present,
19585// all fields will be updated.
19586func (c *ProjectsAgentUpdateFulfillmentCall) UpdateMask(updateMask string) *ProjectsAgentUpdateFulfillmentCall {
19587	c.urlParams_.Set("updateMask", updateMask)
19588	return c
19589}
19590
19591// Fields allows partial responses to be retrieved. See
19592// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
19593// for more information.
19594func (c *ProjectsAgentUpdateFulfillmentCall) Fields(s ...googleapi.Field) *ProjectsAgentUpdateFulfillmentCall {
19595	c.urlParams_.Set("fields", googleapi.CombineFields(s))
19596	return c
19597}
19598
19599// Context sets the context to be used in this call's Do method. Any
19600// pending HTTP request will be aborted if the provided context is
19601// canceled.
19602func (c *ProjectsAgentUpdateFulfillmentCall) Context(ctx context.Context) *ProjectsAgentUpdateFulfillmentCall {
19603	c.ctx_ = ctx
19604	return c
19605}
19606
19607// Header returns an http.Header that can be modified by the caller to
19608// add HTTP headers to the request.
19609func (c *ProjectsAgentUpdateFulfillmentCall) Header() http.Header {
19610	if c.header_ == nil {
19611		c.header_ = make(http.Header)
19612	}
19613	return c.header_
19614}
19615
19616func (c *ProjectsAgentUpdateFulfillmentCall) doRequest(alt string) (*http.Response, error) {
19617	reqHeaders := make(http.Header)
19618	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20211027")
19619	for k, v := range c.header_ {
19620		reqHeaders[k] = v
19621	}
19622	reqHeaders.Set("User-Agent", c.s.userAgent())
19623	var body io.Reader = nil
19624	body, err := googleapi.WithoutDataWrapper.JSONReader(c.googleclouddialogflowv2fulfillment)
19625	if err != nil {
19626		return nil, err
19627	}
19628	reqHeaders.Set("Content-Type", "application/json")
19629	c.urlParams_.Set("alt", alt)
19630	c.urlParams_.Set("prettyPrint", "false")
19631	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+name}")
19632	urls += "?" + c.urlParams_.Encode()
19633	req, err := http.NewRequest("PATCH", urls, body)
19634	if err != nil {
19635		return nil, err
19636	}
19637	req.Header = reqHeaders
19638	googleapi.Expand(req.URL, map[string]string{
19639		"name": c.nameid,
19640	})
19641	return gensupport.SendRequest(c.ctx_, c.s.client, req)
19642}
19643
19644// Do executes the "dialogflow.projects.agent.updateFulfillment" call.
19645// Exactly one of *GoogleCloudDialogflowV2Fulfillment or error will be
19646// non-nil. Any non-2xx status code is an error. Response headers are in
19647// either *GoogleCloudDialogflowV2Fulfillment.ServerResponse.Header or
19648// (if a response was returned at all) in
19649// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
19650// whether the returned error was because http.StatusNotModified was
19651// returned.
19652func (c *ProjectsAgentUpdateFulfillmentCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDialogflowV2Fulfillment, error) {
19653	gensupport.SetOptions(c.urlParams_, opts...)
19654	res, err := c.doRequest("json")
19655	if res != nil && res.StatusCode == http.StatusNotModified {
19656		if res.Body != nil {
19657			res.Body.Close()
19658		}
19659		return nil, &googleapi.Error{
19660			Code:   res.StatusCode,
19661			Header: res.Header,
19662		}
19663	}
19664	if err != nil {
19665		return nil, err
19666	}
19667	defer googleapi.CloseBody(res)
19668	if err := googleapi.CheckResponse(res); err != nil {
19669		return nil, err
19670	}
19671	ret := &GoogleCloudDialogflowV2Fulfillment{
19672		ServerResponse: googleapi.ServerResponse{
19673			Header:         res.Header,
19674			HTTPStatusCode: res.StatusCode,
19675		},
19676	}
19677	target := &ret
19678	if err := gensupport.DecodeResponse(target, res); err != nil {
19679		return nil, err
19680	}
19681	return ret, nil
19682	// {
19683	//   "description": "Updates the fulfillment.",
19684	//   "flatPath": "v2/projects/{projectsId}/agent/fulfillment",
19685	//   "httpMethod": "PATCH",
19686	//   "id": "dialogflow.projects.agent.updateFulfillment",
19687	//   "parameterOrder": [
19688	//     "name"
19689	//   ],
19690	//   "parameters": {
19691	//     "name": {
19692	//       "description": "Required. The unique identifier of the fulfillment. Supported formats: - `projects//agent/fulfillment` - `projects//locations//agent/fulfillment` This field is not used for Fulfillment in an Environment.",
19693	//       "location": "path",
19694	//       "pattern": "^projects/[^/]+/agent/fulfillment$",
19695	//       "required": true,
19696	//       "type": "string"
19697	//     },
19698	//     "updateMask": {
19699	//       "description": "Required. The mask to control which fields get updated. If the mask is not present, all fields will be updated.",
19700	//       "format": "google-fieldmask",
19701	//       "location": "query",
19702	//       "type": "string"
19703	//     }
19704	//   },
19705	//   "path": "v2/{+name}",
19706	//   "request": {
19707	//     "$ref": "GoogleCloudDialogflowV2Fulfillment"
19708	//   },
19709	//   "response": {
19710	//     "$ref": "GoogleCloudDialogflowV2Fulfillment"
19711	//   },
19712	//   "scopes": [
19713	//     "https://www.googleapis.com/auth/cloud-platform",
19714	//     "https://www.googleapis.com/auth/dialogflow"
19715	//   ]
19716	// }
19717
19718}
19719
19720// method id "dialogflow.projects.agent.entityTypes.batchDelete":
19721
19722type ProjectsAgentEntityTypesBatchDeleteCall struct {
19723	s                                                    *Service
19724	parent                                               string
19725	googleclouddialogflowv2batchdeleteentitytypesrequest *GoogleCloudDialogflowV2BatchDeleteEntityTypesRequest
19726	urlParams_                                           gensupport.URLParams
19727	ctx_                                                 context.Context
19728	header_                                              http.Header
19729}
19730
19731// BatchDelete: Deletes entity types in the specified agent. This method
19732// is a long-running operation
19733// (https://cloud.google.com/dialogflow/es/docs/how/long-running-operations).
19734// The returned `Operation` type has the following method-specific
19735// fields: - `metadata`: An empty Struct message
19736// (https://developers.google.com/protocol-buffers/docs/reference/google.protobuf#struct)
19737// - `response`: An Empty message
19738// (https://developers.google.com/protocol-buffers/docs/reference/google.protobuf#empty)
19739// Note: You should always train an agent prior to sending it queries.
19740// See the training documentation
19741// (https://cloud.google.com/dialogflow/es/docs/training).
19742//
19743// - parent: The name of the agent to delete all entities types for.
19744//   Format: `projects//agent`.
19745func (r *ProjectsAgentEntityTypesService) BatchDelete(parent string, googleclouddialogflowv2batchdeleteentitytypesrequest *GoogleCloudDialogflowV2BatchDeleteEntityTypesRequest) *ProjectsAgentEntityTypesBatchDeleteCall {
19746	c := &ProjectsAgentEntityTypesBatchDeleteCall{s: r.s, urlParams_: make(gensupport.URLParams)}
19747	c.parent = parent
19748	c.googleclouddialogflowv2batchdeleteentitytypesrequest = googleclouddialogflowv2batchdeleteentitytypesrequest
19749	return c
19750}
19751
19752// Fields allows partial responses to be retrieved. See
19753// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
19754// for more information.
19755func (c *ProjectsAgentEntityTypesBatchDeleteCall) Fields(s ...googleapi.Field) *ProjectsAgentEntityTypesBatchDeleteCall {
19756	c.urlParams_.Set("fields", googleapi.CombineFields(s))
19757	return c
19758}
19759
19760// Context sets the context to be used in this call's Do method. Any
19761// pending HTTP request will be aborted if the provided context is
19762// canceled.
19763func (c *ProjectsAgentEntityTypesBatchDeleteCall) Context(ctx context.Context) *ProjectsAgentEntityTypesBatchDeleteCall {
19764	c.ctx_ = ctx
19765	return c
19766}
19767
19768// Header returns an http.Header that can be modified by the caller to
19769// add HTTP headers to the request.
19770func (c *ProjectsAgentEntityTypesBatchDeleteCall) Header() http.Header {
19771	if c.header_ == nil {
19772		c.header_ = make(http.Header)
19773	}
19774	return c.header_
19775}
19776
19777func (c *ProjectsAgentEntityTypesBatchDeleteCall) doRequest(alt string) (*http.Response, error) {
19778	reqHeaders := make(http.Header)
19779	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20211027")
19780	for k, v := range c.header_ {
19781		reqHeaders[k] = v
19782	}
19783	reqHeaders.Set("User-Agent", c.s.userAgent())
19784	var body io.Reader = nil
19785	body, err := googleapi.WithoutDataWrapper.JSONReader(c.googleclouddialogflowv2batchdeleteentitytypesrequest)
19786	if err != nil {
19787		return nil, err
19788	}
19789	reqHeaders.Set("Content-Type", "application/json")
19790	c.urlParams_.Set("alt", alt)
19791	c.urlParams_.Set("prettyPrint", "false")
19792	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+parent}/entityTypes:batchDelete")
19793	urls += "?" + c.urlParams_.Encode()
19794	req, err := http.NewRequest("POST", urls, body)
19795	if err != nil {
19796		return nil, err
19797	}
19798	req.Header = reqHeaders
19799	googleapi.Expand(req.URL, map[string]string{
19800		"parent": c.parent,
19801	})
19802	return gensupport.SendRequest(c.ctx_, c.s.client, req)
19803}
19804
19805// Do executes the "dialogflow.projects.agent.entityTypes.batchDelete" call.
19806// Exactly one of *GoogleLongrunningOperation or error will be non-nil.
19807// Any non-2xx status code is an error. Response headers are in either
19808// *GoogleLongrunningOperation.ServerResponse.Header or (if a response
19809// was returned at all) in error.(*googleapi.Error).Header. Use
19810// googleapi.IsNotModified to check whether the returned error was
19811// because http.StatusNotModified was returned.
19812func (c *ProjectsAgentEntityTypesBatchDeleteCall) Do(opts ...googleapi.CallOption) (*GoogleLongrunningOperation, error) {
19813	gensupport.SetOptions(c.urlParams_, opts...)
19814	res, err := c.doRequest("json")
19815	if res != nil && res.StatusCode == http.StatusNotModified {
19816		if res.Body != nil {
19817			res.Body.Close()
19818		}
19819		return nil, &googleapi.Error{
19820			Code:   res.StatusCode,
19821			Header: res.Header,
19822		}
19823	}
19824	if err != nil {
19825		return nil, err
19826	}
19827	defer googleapi.CloseBody(res)
19828	if err := googleapi.CheckResponse(res); err != nil {
19829		return nil, err
19830	}
19831	ret := &GoogleLongrunningOperation{
19832		ServerResponse: googleapi.ServerResponse{
19833			Header:         res.Header,
19834			HTTPStatusCode: res.StatusCode,
19835		},
19836	}
19837	target := &ret
19838	if err := gensupport.DecodeResponse(target, res); err != nil {
19839		return nil, err
19840	}
19841	return ret, nil
19842	// {
19843	//   "description": "Deletes entity types in the specified agent. This method is a [long-running operation](https://cloud.google.com/dialogflow/es/docs/how/long-running-operations). The returned `Operation` type has the following method-specific fields: - `metadata`: An empty [Struct message](https://developers.google.com/protocol-buffers/docs/reference/google.protobuf#struct) - `response`: An [Empty message](https://developers.google.com/protocol-buffers/docs/reference/google.protobuf#empty) Note: You should always train an agent prior to sending it queries. See the [training documentation](https://cloud.google.com/dialogflow/es/docs/training).",
19844	//   "flatPath": "v2/projects/{projectsId}/agent/entityTypes:batchDelete",
19845	//   "httpMethod": "POST",
19846	//   "id": "dialogflow.projects.agent.entityTypes.batchDelete",
19847	//   "parameterOrder": [
19848	//     "parent"
19849	//   ],
19850	//   "parameters": {
19851	//     "parent": {
19852	//       "description": "Required. The name of the agent to delete all entities types for. Format: `projects//agent`.",
19853	//       "location": "path",
19854	//       "pattern": "^projects/[^/]+/agent$",
19855	//       "required": true,
19856	//       "type": "string"
19857	//     }
19858	//   },
19859	//   "path": "v2/{+parent}/entityTypes:batchDelete",
19860	//   "request": {
19861	//     "$ref": "GoogleCloudDialogflowV2BatchDeleteEntityTypesRequest"
19862	//   },
19863	//   "response": {
19864	//     "$ref": "GoogleLongrunningOperation"
19865	//   },
19866	//   "scopes": [
19867	//     "https://www.googleapis.com/auth/cloud-platform",
19868	//     "https://www.googleapis.com/auth/dialogflow"
19869	//   ]
19870	// }
19871
19872}
19873
19874// method id "dialogflow.projects.agent.entityTypes.batchUpdate":
19875
19876type ProjectsAgentEntityTypesBatchUpdateCall struct {
19877	s                                                    *Service
19878	parent                                               string
19879	googleclouddialogflowv2batchupdateentitytypesrequest *GoogleCloudDialogflowV2BatchUpdateEntityTypesRequest
19880	urlParams_                                           gensupport.URLParams
19881	ctx_                                                 context.Context
19882	header_                                              http.Header
19883}
19884
19885// BatchUpdate: Updates/Creates multiple entity types in the specified
19886// agent. This method is a long-running operation
19887// (https://cloud.google.com/dialogflow/es/docs/how/long-running-operations).
19888// The returned `Operation` type has the following method-specific
19889// fields: - `metadata`: An empty Struct message
19890// (https://developers.google.com/protocol-buffers/docs/reference/google.protobuf#struct)
19891// - `response`: BatchUpdateEntityTypesResponse Note: You should always
19892// train an agent prior to sending it queries. See the training
19893// documentation (https://cloud.google.com/dialogflow/es/docs/training).
19894//
19895// - parent: The name of the agent to update or create entity types in.
19896//   Format: `projects//agent`.
19897func (r *ProjectsAgentEntityTypesService) BatchUpdate(parent string, googleclouddialogflowv2batchupdateentitytypesrequest *GoogleCloudDialogflowV2BatchUpdateEntityTypesRequest) *ProjectsAgentEntityTypesBatchUpdateCall {
19898	c := &ProjectsAgentEntityTypesBatchUpdateCall{s: r.s, urlParams_: make(gensupport.URLParams)}
19899	c.parent = parent
19900	c.googleclouddialogflowv2batchupdateentitytypesrequest = googleclouddialogflowv2batchupdateentitytypesrequest
19901	return c
19902}
19903
19904// Fields allows partial responses to be retrieved. See
19905// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
19906// for more information.
19907func (c *ProjectsAgentEntityTypesBatchUpdateCall) Fields(s ...googleapi.Field) *ProjectsAgentEntityTypesBatchUpdateCall {
19908	c.urlParams_.Set("fields", googleapi.CombineFields(s))
19909	return c
19910}
19911
19912// Context sets the context to be used in this call's Do method. Any
19913// pending HTTP request will be aborted if the provided context is
19914// canceled.
19915func (c *ProjectsAgentEntityTypesBatchUpdateCall) Context(ctx context.Context) *ProjectsAgentEntityTypesBatchUpdateCall {
19916	c.ctx_ = ctx
19917	return c
19918}
19919
19920// Header returns an http.Header that can be modified by the caller to
19921// add HTTP headers to the request.
19922func (c *ProjectsAgentEntityTypesBatchUpdateCall) Header() http.Header {
19923	if c.header_ == nil {
19924		c.header_ = make(http.Header)
19925	}
19926	return c.header_
19927}
19928
19929func (c *ProjectsAgentEntityTypesBatchUpdateCall) doRequest(alt string) (*http.Response, error) {
19930	reqHeaders := make(http.Header)
19931	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20211027")
19932	for k, v := range c.header_ {
19933		reqHeaders[k] = v
19934	}
19935	reqHeaders.Set("User-Agent", c.s.userAgent())
19936	var body io.Reader = nil
19937	body, err := googleapi.WithoutDataWrapper.JSONReader(c.googleclouddialogflowv2batchupdateentitytypesrequest)
19938	if err != nil {
19939		return nil, err
19940	}
19941	reqHeaders.Set("Content-Type", "application/json")
19942	c.urlParams_.Set("alt", alt)
19943	c.urlParams_.Set("prettyPrint", "false")
19944	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+parent}/entityTypes:batchUpdate")
19945	urls += "?" + c.urlParams_.Encode()
19946	req, err := http.NewRequest("POST", urls, body)
19947	if err != nil {
19948		return nil, err
19949	}
19950	req.Header = reqHeaders
19951	googleapi.Expand(req.URL, map[string]string{
19952		"parent": c.parent,
19953	})
19954	return gensupport.SendRequest(c.ctx_, c.s.client, req)
19955}
19956
19957// Do executes the "dialogflow.projects.agent.entityTypes.batchUpdate" call.
19958// Exactly one of *GoogleLongrunningOperation or error will be non-nil.
19959// Any non-2xx status code is an error. Response headers are in either
19960// *GoogleLongrunningOperation.ServerResponse.Header or (if a response
19961// was returned at all) in error.(*googleapi.Error).Header. Use
19962// googleapi.IsNotModified to check whether the returned error was
19963// because http.StatusNotModified was returned.
19964func (c *ProjectsAgentEntityTypesBatchUpdateCall) Do(opts ...googleapi.CallOption) (*GoogleLongrunningOperation, error) {
19965	gensupport.SetOptions(c.urlParams_, opts...)
19966	res, err := c.doRequest("json")
19967	if res != nil && res.StatusCode == http.StatusNotModified {
19968		if res.Body != nil {
19969			res.Body.Close()
19970		}
19971		return nil, &googleapi.Error{
19972			Code:   res.StatusCode,
19973			Header: res.Header,
19974		}
19975	}
19976	if err != nil {
19977		return nil, err
19978	}
19979	defer googleapi.CloseBody(res)
19980	if err := googleapi.CheckResponse(res); err != nil {
19981		return nil, err
19982	}
19983	ret := &GoogleLongrunningOperation{
19984		ServerResponse: googleapi.ServerResponse{
19985			Header:         res.Header,
19986			HTTPStatusCode: res.StatusCode,
19987		},
19988	}
19989	target := &ret
19990	if err := gensupport.DecodeResponse(target, res); err != nil {
19991		return nil, err
19992	}
19993	return ret, nil
19994	// {
19995	//   "description": "Updates/Creates multiple entity types in the specified agent. This method is a [long-running operation](https://cloud.google.com/dialogflow/es/docs/how/long-running-operations). The returned `Operation` type has the following method-specific fields: - `metadata`: An empty [Struct message](https://developers.google.com/protocol-buffers/docs/reference/google.protobuf#struct) - `response`: BatchUpdateEntityTypesResponse Note: You should always train an agent prior to sending it queries. See the [training documentation](https://cloud.google.com/dialogflow/es/docs/training).",
19996	//   "flatPath": "v2/projects/{projectsId}/agent/entityTypes:batchUpdate",
19997	//   "httpMethod": "POST",
19998	//   "id": "dialogflow.projects.agent.entityTypes.batchUpdate",
19999	//   "parameterOrder": [
20000	//     "parent"
20001	//   ],
20002	//   "parameters": {
20003	//     "parent": {
20004	//       "description": "Required. The name of the agent to update or create entity types in. Format: `projects//agent`.",
20005	//       "location": "path",
20006	//       "pattern": "^projects/[^/]+/agent$",
20007	//       "required": true,
20008	//       "type": "string"
20009	//     }
20010	//   },
20011	//   "path": "v2/{+parent}/entityTypes:batchUpdate",
20012	//   "request": {
20013	//     "$ref": "GoogleCloudDialogflowV2BatchUpdateEntityTypesRequest"
20014	//   },
20015	//   "response": {
20016	//     "$ref": "GoogleLongrunningOperation"
20017	//   },
20018	//   "scopes": [
20019	//     "https://www.googleapis.com/auth/cloud-platform",
20020	//     "https://www.googleapis.com/auth/dialogflow"
20021	//   ]
20022	// }
20023
20024}
20025
20026// method id "dialogflow.projects.agent.entityTypes.create":
20027
20028type ProjectsAgentEntityTypesCreateCall struct {
20029	s                                 *Service
20030	parent                            string
20031	googleclouddialogflowv2entitytype *GoogleCloudDialogflowV2EntityType
20032	urlParams_                        gensupport.URLParams
20033	ctx_                              context.Context
20034	header_                           http.Header
20035}
20036
20037// Create: Creates an entity type in the specified agent. Note: You
20038// should always train an agent prior to sending it queries. See the
20039// training documentation
20040// (https://cloud.google.com/dialogflow/es/docs/training).
20041//
20042// - parent: The agent to create a entity type for. Format:
20043//   `projects//agent`.
20044func (r *ProjectsAgentEntityTypesService) Create(parent string, googleclouddialogflowv2entitytype *GoogleCloudDialogflowV2EntityType) *ProjectsAgentEntityTypesCreateCall {
20045	c := &ProjectsAgentEntityTypesCreateCall{s: r.s, urlParams_: make(gensupport.URLParams)}
20046	c.parent = parent
20047	c.googleclouddialogflowv2entitytype = googleclouddialogflowv2entitytype
20048	return c
20049}
20050
20051// LanguageCode sets the optional parameter "languageCode": The language
20052// used to access language-specific data. If not specified, the agent's
20053// default language is used. For more information, see Multilingual
20054// intent and entity data
20055// (https://cloud.google.com/dialogflow/docs/agents-multilingual#intent-entity).
20056func (c *ProjectsAgentEntityTypesCreateCall) LanguageCode(languageCode string) *ProjectsAgentEntityTypesCreateCall {
20057	c.urlParams_.Set("languageCode", languageCode)
20058	return c
20059}
20060
20061// Fields allows partial responses to be retrieved. See
20062// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
20063// for more information.
20064func (c *ProjectsAgentEntityTypesCreateCall) Fields(s ...googleapi.Field) *ProjectsAgentEntityTypesCreateCall {
20065	c.urlParams_.Set("fields", googleapi.CombineFields(s))
20066	return c
20067}
20068
20069// Context sets the context to be used in this call's Do method. Any
20070// pending HTTP request will be aborted if the provided context is
20071// canceled.
20072func (c *ProjectsAgentEntityTypesCreateCall) Context(ctx context.Context) *ProjectsAgentEntityTypesCreateCall {
20073	c.ctx_ = ctx
20074	return c
20075}
20076
20077// Header returns an http.Header that can be modified by the caller to
20078// add HTTP headers to the request.
20079func (c *ProjectsAgentEntityTypesCreateCall) Header() http.Header {
20080	if c.header_ == nil {
20081		c.header_ = make(http.Header)
20082	}
20083	return c.header_
20084}
20085
20086func (c *ProjectsAgentEntityTypesCreateCall) doRequest(alt string) (*http.Response, error) {
20087	reqHeaders := make(http.Header)
20088	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20211027")
20089	for k, v := range c.header_ {
20090		reqHeaders[k] = v
20091	}
20092	reqHeaders.Set("User-Agent", c.s.userAgent())
20093	var body io.Reader = nil
20094	body, err := googleapi.WithoutDataWrapper.JSONReader(c.googleclouddialogflowv2entitytype)
20095	if err != nil {
20096		return nil, err
20097	}
20098	reqHeaders.Set("Content-Type", "application/json")
20099	c.urlParams_.Set("alt", alt)
20100	c.urlParams_.Set("prettyPrint", "false")
20101	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+parent}/entityTypes")
20102	urls += "?" + c.urlParams_.Encode()
20103	req, err := http.NewRequest("POST", urls, body)
20104	if err != nil {
20105		return nil, err
20106	}
20107	req.Header = reqHeaders
20108	googleapi.Expand(req.URL, map[string]string{
20109		"parent": c.parent,
20110	})
20111	return gensupport.SendRequest(c.ctx_, c.s.client, req)
20112}
20113
20114// Do executes the "dialogflow.projects.agent.entityTypes.create" call.
20115// Exactly one of *GoogleCloudDialogflowV2EntityType or error will be
20116// non-nil. Any non-2xx status code is an error. Response headers are in
20117// either *GoogleCloudDialogflowV2EntityType.ServerResponse.Header or
20118// (if a response was returned at all) in
20119// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
20120// whether the returned error was because http.StatusNotModified was
20121// returned.
20122func (c *ProjectsAgentEntityTypesCreateCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDialogflowV2EntityType, error) {
20123	gensupport.SetOptions(c.urlParams_, opts...)
20124	res, err := c.doRequest("json")
20125	if res != nil && res.StatusCode == http.StatusNotModified {
20126		if res.Body != nil {
20127			res.Body.Close()
20128		}
20129		return nil, &googleapi.Error{
20130			Code:   res.StatusCode,
20131			Header: res.Header,
20132		}
20133	}
20134	if err != nil {
20135		return nil, err
20136	}
20137	defer googleapi.CloseBody(res)
20138	if err := googleapi.CheckResponse(res); err != nil {
20139		return nil, err
20140	}
20141	ret := &GoogleCloudDialogflowV2EntityType{
20142		ServerResponse: googleapi.ServerResponse{
20143			Header:         res.Header,
20144			HTTPStatusCode: res.StatusCode,
20145		},
20146	}
20147	target := &ret
20148	if err := gensupport.DecodeResponse(target, res); err != nil {
20149		return nil, err
20150	}
20151	return ret, nil
20152	// {
20153	//   "description": "Creates an entity type in the specified agent. Note: You should always train an agent prior to sending it queries. See the [training documentation](https://cloud.google.com/dialogflow/es/docs/training).",
20154	//   "flatPath": "v2/projects/{projectsId}/agent/entityTypes",
20155	//   "httpMethod": "POST",
20156	//   "id": "dialogflow.projects.agent.entityTypes.create",
20157	//   "parameterOrder": [
20158	//     "parent"
20159	//   ],
20160	//   "parameters": {
20161	//     "languageCode": {
20162	//       "description": "Optional. The language used to access language-specific data. If not specified, the agent's default language is used. For more information, see [Multilingual intent and entity data](https://cloud.google.com/dialogflow/docs/agents-multilingual#intent-entity).",
20163	//       "location": "query",
20164	//       "type": "string"
20165	//     },
20166	//     "parent": {
20167	//       "description": "Required. The agent to create a entity type for. Format: `projects//agent`.",
20168	//       "location": "path",
20169	//       "pattern": "^projects/[^/]+/agent$",
20170	//       "required": true,
20171	//       "type": "string"
20172	//     }
20173	//   },
20174	//   "path": "v2/{+parent}/entityTypes",
20175	//   "request": {
20176	//     "$ref": "GoogleCloudDialogflowV2EntityType"
20177	//   },
20178	//   "response": {
20179	//     "$ref": "GoogleCloudDialogflowV2EntityType"
20180	//   },
20181	//   "scopes": [
20182	//     "https://www.googleapis.com/auth/cloud-platform",
20183	//     "https://www.googleapis.com/auth/dialogflow"
20184	//   ]
20185	// }
20186
20187}
20188
20189// method id "dialogflow.projects.agent.entityTypes.delete":
20190
20191type ProjectsAgentEntityTypesDeleteCall struct {
20192	s          *Service
20193	name       string
20194	urlParams_ gensupport.URLParams
20195	ctx_       context.Context
20196	header_    http.Header
20197}
20198
20199// Delete: Deletes the specified entity type. Note: You should always
20200// train an agent prior to sending it queries. See the training
20201// documentation (https://cloud.google.com/dialogflow/es/docs/training).
20202//
20203// - name: The name of the entity type to delete. Format:
20204//   `projects//agent/entityTypes/`.
20205func (r *ProjectsAgentEntityTypesService) Delete(name string) *ProjectsAgentEntityTypesDeleteCall {
20206	c := &ProjectsAgentEntityTypesDeleteCall{s: r.s, urlParams_: make(gensupport.URLParams)}
20207	c.name = name
20208	return c
20209}
20210
20211// Fields allows partial responses to be retrieved. See
20212// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
20213// for more information.
20214func (c *ProjectsAgentEntityTypesDeleteCall) Fields(s ...googleapi.Field) *ProjectsAgentEntityTypesDeleteCall {
20215	c.urlParams_.Set("fields", googleapi.CombineFields(s))
20216	return c
20217}
20218
20219// Context sets the context to be used in this call's Do method. Any
20220// pending HTTP request will be aborted if the provided context is
20221// canceled.
20222func (c *ProjectsAgentEntityTypesDeleteCall) Context(ctx context.Context) *ProjectsAgentEntityTypesDeleteCall {
20223	c.ctx_ = ctx
20224	return c
20225}
20226
20227// Header returns an http.Header that can be modified by the caller to
20228// add HTTP headers to the request.
20229func (c *ProjectsAgentEntityTypesDeleteCall) Header() http.Header {
20230	if c.header_ == nil {
20231		c.header_ = make(http.Header)
20232	}
20233	return c.header_
20234}
20235
20236func (c *ProjectsAgentEntityTypesDeleteCall) doRequest(alt string) (*http.Response, error) {
20237	reqHeaders := make(http.Header)
20238	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20211027")
20239	for k, v := range c.header_ {
20240		reqHeaders[k] = v
20241	}
20242	reqHeaders.Set("User-Agent", c.s.userAgent())
20243	var body io.Reader = nil
20244	c.urlParams_.Set("alt", alt)
20245	c.urlParams_.Set("prettyPrint", "false")
20246	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+name}")
20247	urls += "?" + c.urlParams_.Encode()
20248	req, err := http.NewRequest("DELETE", urls, body)
20249	if err != nil {
20250		return nil, err
20251	}
20252	req.Header = reqHeaders
20253	googleapi.Expand(req.URL, map[string]string{
20254		"name": c.name,
20255	})
20256	return gensupport.SendRequest(c.ctx_, c.s.client, req)
20257}
20258
20259// Do executes the "dialogflow.projects.agent.entityTypes.delete" call.
20260// Exactly one of *GoogleProtobufEmpty or error will be non-nil. Any
20261// non-2xx status code is an error. Response headers are in either
20262// *GoogleProtobufEmpty.ServerResponse.Header or (if a response was
20263// returned at all) in error.(*googleapi.Error).Header. Use
20264// googleapi.IsNotModified to check whether the returned error was
20265// because http.StatusNotModified was returned.
20266func (c *ProjectsAgentEntityTypesDeleteCall) Do(opts ...googleapi.CallOption) (*GoogleProtobufEmpty, error) {
20267	gensupport.SetOptions(c.urlParams_, opts...)
20268	res, err := c.doRequest("json")
20269	if res != nil && res.StatusCode == http.StatusNotModified {
20270		if res.Body != nil {
20271			res.Body.Close()
20272		}
20273		return nil, &googleapi.Error{
20274			Code:   res.StatusCode,
20275			Header: res.Header,
20276		}
20277	}
20278	if err != nil {
20279		return nil, err
20280	}
20281	defer googleapi.CloseBody(res)
20282	if err := googleapi.CheckResponse(res); err != nil {
20283		return nil, err
20284	}
20285	ret := &GoogleProtobufEmpty{
20286		ServerResponse: googleapi.ServerResponse{
20287			Header:         res.Header,
20288			HTTPStatusCode: res.StatusCode,
20289		},
20290	}
20291	target := &ret
20292	if err := gensupport.DecodeResponse(target, res); err != nil {
20293		return nil, err
20294	}
20295	return ret, nil
20296	// {
20297	//   "description": "Deletes the specified entity type. Note: You should always train an agent prior to sending it queries. See the [training documentation](https://cloud.google.com/dialogflow/es/docs/training).",
20298	//   "flatPath": "v2/projects/{projectsId}/agent/entityTypes/{entityTypesId}",
20299	//   "httpMethod": "DELETE",
20300	//   "id": "dialogflow.projects.agent.entityTypes.delete",
20301	//   "parameterOrder": [
20302	//     "name"
20303	//   ],
20304	//   "parameters": {
20305	//     "name": {
20306	//       "description": "Required. The name of the entity type to delete. Format: `projects//agent/entityTypes/`.",
20307	//       "location": "path",
20308	//       "pattern": "^projects/[^/]+/agent/entityTypes/[^/]+$",
20309	//       "required": true,
20310	//       "type": "string"
20311	//     }
20312	//   },
20313	//   "path": "v2/{+name}",
20314	//   "response": {
20315	//     "$ref": "GoogleProtobufEmpty"
20316	//   },
20317	//   "scopes": [
20318	//     "https://www.googleapis.com/auth/cloud-platform",
20319	//     "https://www.googleapis.com/auth/dialogflow"
20320	//   ]
20321	// }
20322
20323}
20324
20325// method id "dialogflow.projects.agent.entityTypes.get":
20326
20327type ProjectsAgentEntityTypesGetCall struct {
20328	s            *Service
20329	name         string
20330	urlParams_   gensupport.URLParams
20331	ifNoneMatch_ string
20332	ctx_         context.Context
20333	header_      http.Header
20334}
20335
20336// Get: Retrieves the specified entity type.
20337//
20338// - name: The name of the entity type. Format:
20339//   `projects//agent/entityTypes/`.
20340func (r *ProjectsAgentEntityTypesService) Get(name string) *ProjectsAgentEntityTypesGetCall {
20341	c := &ProjectsAgentEntityTypesGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
20342	c.name = name
20343	return c
20344}
20345
20346// LanguageCode sets the optional parameter "languageCode": The language
20347// used to access language-specific data. If not specified, the agent's
20348// default language is used. For more information, see Multilingual
20349// intent and entity data
20350// (https://cloud.google.com/dialogflow/docs/agents-multilingual#intent-entity).
20351func (c *ProjectsAgentEntityTypesGetCall) LanguageCode(languageCode string) *ProjectsAgentEntityTypesGetCall {
20352	c.urlParams_.Set("languageCode", languageCode)
20353	return c
20354}
20355
20356// Fields allows partial responses to be retrieved. See
20357// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
20358// for more information.
20359func (c *ProjectsAgentEntityTypesGetCall) Fields(s ...googleapi.Field) *ProjectsAgentEntityTypesGetCall {
20360	c.urlParams_.Set("fields", googleapi.CombineFields(s))
20361	return c
20362}
20363
20364// IfNoneMatch sets the optional parameter which makes the operation
20365// fail if the object's ETag matches the given value. This is useful for
20366// getting updates only after the object has changed since the last
20367// request. Use googleapi.IsNotModified to check whether the response
20368// error from Do is the result of In-None-Match.
20369func (c *ProjectsAgentEntityTypesGetCall) IfNoneMatch(entityTag string) *ProjectsAgentEntityTypesGetCall {
20370	c.ifNoneMatch_ = entityTag
20371	return c
20372}
20373
20374// Context sets the context to be used in this call's Do method. Any
20375// pending HTTP request will be aborted if the provided context is
20376// canceled.
20377func (c *ProjectsAgentEntityTypesGetCall) Context(ctx context.Context) *ProjectsAgentEntityTypesGetCall {
20378	c.ctx_ = ctx
20379	return c
20380}
20381
20382// Header returns an http.Header that can be modified by the caller to
20383// add HTTP headers to the request.
20384func (c *ProjectsAgentEntityTypesGetCall) Header() http.Header {
20385	if c.header_ == nil {
20386		c.header_ = make(http.Header)
20387	}
20388	return c.header_
20389}
20390
20391func (c *ProjectsAgentEntityTypesGetCall) doRequest(alt string) (*http.Response, error) {
20392	reqHeaders := make(http.Header)
20393	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20211027")
20394	for k, v := range c.header_ {
20395		reqHeaders[k] = v
20396	}
20397	reqHeaders.Set("User-Agent", c.s.userAgent())
20398	if c.ifNoneMatch_ != "" {
20399		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
20400	}
20401	var body io.Reader = nil
20402	c.urlParams_.Set("alt", alt)
20403	c.urlParams_.Set("prettyPrint", "false")
20404	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+name}")
20405	urls += "?" + c.urlParams_.Encode()
20406	req, err := http.NewRequest("GET", urls, body)
20407	if err != nil {
20408		return nil, err
20409	}
20410	req.Header = reqHeaders
20411	googleapi.Expand(req.URL, map[string]string{
20412		"name": c.name,
20413	})
20414	return gensupport.SendRequest(c.ctx_, c.s.client, req)
20415}
20416
20417// Do executes the "dialogflow.projects.agent.entityTypes.get" call.
20418// Exactly one of *GoogleCloudDialogflowV2EntityType or error will be
20419// non-nil. Any non-2xx status code is an error. Response headers are in
20420// either *GoogleCloudDialogflowV2EntityType.ServerResponse.Header or
20421// (if a response was returned at all) in
20422// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
20423// whether the returned error was because http.StatusNotModified was
20424// returned.
20425func (c *ProjectsAgentEntityTypesGetCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDialogflowV2EntityType, error) {
20426	gensupport.SetOptions(c.urlParams_, opts...)
20427	res, err := c.doRequest("json")
20428	if res != nil && res.StatusCode == http.StatusNotModified {
20429		if res.Body != nil {
20430			res.Body.Close()
20431		}
20432		return nil, &googleapi.Error{
20433			Code:   res.StatusCode,
20434			Header: res.Header,
20435		}
20436	}
20437	if err != nil {
20438		return nil, err
20439	}
20440	defer googleapi.CloseBody(res)
20441	if err := googleapi.CheckResponse(res); err != nil {
20442		return nil, err
20443	}
20444	ret := &GoogleCloudDialogflowV2EntityType{
20445		ServerResponse: googleapi.ServerResponse{
20446			Header:         res.Header,
20447			HTTPStatusCode: res.StatusCode,
20448		},
20449	}
20450	target := &ret
20451	if err := gensupport.DecodeResponse(target, res); err != nil {
20452		return nil, err
20453	}
20454	return ret, nil
20455	// {
20456	//   "description": "Retrieves the specified entity type.",
20457	//   "flatPath": "v2/projects/{projectsId}/agent/entityTypes/{entityTypesId}",
20458	//   "httpMethod": "GET",
20459	//   "id": "dialogflow.projects.agent.entityTypes.get",
20460	//   "parameterOrder": [
20461	//     "name"
20462	//   ],
20463	//   "parameters": {
20464	//     "languageCode": {
20465	//       "description": "Optional. The language used to access language-specific data. If not specified, the agent's default language is used. For more information, see [Multilingual intent and entity data](https://cloud.google.com/dialogflow/docs/agents-multilingual#intent-entity).",
20466	//       "location": "query",
20467	//       "type": "string"
20468	//     },
20469	//     "name": {
20470	//       "description": "Required. The name of the entity type. Format: `projects//agent/entityTypes/`.",
20471	//       "location": "path",
20472	//       "pattern": "^projects/[^/]+/agent/entityTypes/[^/]+$",
20473	//       "required": true,
20474	//       "type": "string"
20475	//     }
20476	//   },
20477	//   "path": "v2/{+name}",
20478	//   "response": {
20479	//     "$ref": "GoogleCloudDialogflowV2EntityType"
20480	//   },
20481	//   "scopes": [
20482	//     "https://www.googleapis.com/auth/cloud-platform",
20483	//     "https://www.googleapis.com/auth/dialogflow"
20484	//   ]
20485	// }
20486
20487}
20488
20489// method id "dialogflow.projects.agent.entityTypes.list":
20490
20491type ProjectsAgentEntityTypesListCall struct {
20492	s            *Service
20493	parent       string
20494	urlParams_   gensupport.URLParams
20495	ifNoneMatch_ string
20496	ctx_         context.Context
20497	header_      http.Header
20498}
20499
20500// List: Returns the list of all entity types in the specified agent.
20501//
20502// - parent: The agent to list all entity types from. Format:
20503//   `projects//agent`.
20504func (r *ProjectsAgentEntityTypesService) List(parent string) *ProjectsAgentEntityTypesListCall {
20505	c := &ProjectsAgentEntityTypesListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
20506	c.parent = parent
20507	return c
20508}
20509
20510// LanguageCode sets the optional parameter "languageCode": The language
20511// used to access language-specific data. If not specified, the agent's
20512// default language is used. For more information, see Multilingual
20513// intent and entity data
20514// (https://cloud.google.com/dialogflow/docs/agents-multilingual#intent-entity).
20515func (c *ProjectsAgentEntityTypesListCall) LanguageCode(languageCode string) *ProjectsAgentEntityTypesListCall {
20516	c.urlParams_.Set("languageCode", languageCode)
20517	return c
20518}
20519
20520// PageSize sets the optional parameter "pageSize": The maximum number
20521// of items to return in a single page. By default 100 and at most 1000.
20522func (c *ProjectsAgentEntityTypesListCall) PageSize(pageSize int64) *ProjectsAgentEntityTypesListCall {
20523	c.urlParams_.Set("pageSize", fmt.Sprint(pageSize))
20524	return c
20525}
20526
20527// PageToken sets the optional parameter "pageToken": The
20528// next_page_token value returned from a previous list request.
20529func (c *ProjectsAgentEntityTypesListCall) PageToken(pageToken string) *ProjectsAgentEntityTypesListCall {
20530	c.urlParams_.Set("pageToken", pageToken)
20531	return c
20532}
20533
20534// Fields allows partial responses to be retrieved. See
20535// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
20536// for more information.
20537func (c *ProjectsAgentEntityTypesListCall) Fields(s ...googleapi.Field) *ProjectsAgentEntityTypesListCall {
20538	c.urlParams_.Set("fields", googleapi.CombineFields(s))
20539	return c
20540}
20541
20542// IfNoneMatch sets the optional parameter which makes the operation
20543// fail if the object's ETag matches the given value. This is useful for
20544// getting updates only after the object has changed since the last
20545// request. Use googleapi.IsNotModified to check whether the response
20546// error from Do is the result of In-None-Match.
20547func (c *ProjectsAgentEntityTypesListCall) IfNoneMatch(entityTag string) *ProjectsAgentEntityTypesListCall {
20548	c.ifNoneMatch_ = entityTag
20549	return c
20550}
20551
20552// Context sets the context to be used in this call's Do method. Any
20553// pending HTTP request will be aborted if the provided context is
20554// canceled.
20555func (c *ProjectsAgentEntityTypesListCall) Context(ctx context.Context) *ProjectsAgentEntityTypesListCall {
20556	c.ctx_ = ctx
20557	return c
20558}
20559
20560// Header returns an http.Header that can be modified by the caller to
20561// add HTTP headers to the request.
20562func (c *ProjectsAgentEntityTypesListCall) Header() http.Header {
20563	if c.header_ == nil {
20564		c.header_ = make(http.Header)
20565	}
20566	return c.header_
20567}
20568
20569func (c *ProjectsAgentEntityTypesListCall) doRequest(alt string) (*http.Response, error) {
20570	reqHeaders := make(http.Header)
20571	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20211027")
20572	for k, v := range c.header_ {
20573		reqHeaders[k] = v
20574	}
20575	reqHeaders.Set("User-Agent", c.s.userAgent())
20576	if c.ifNoneMatch_ != "" {
20577		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
20578	}
20579	var body io.Reader = nil
20580	c.urlParams_.Set("alt", alt)
20581	c.urlParams_.Set("prettyPrint", "false")
20582	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+parent}/entityTypes")
20583	urls += "?" + c.urlParams_.Encode()
20584	req, err := http.NewRequest("GET", urls, body)
20585	if err != nil {
20586		return nil, err
20587	}
20588	req.Header = reqHeaders
20589	googleapi.Expand(req.URL, map[string]string{
20590		"parent": c.parent,
20591	})
20592	return gensupport.SendRequest(c.ctx_, c.s.client, req)
20593}
20594
20595// Do executes the "dialogflow.projects.agent.entityTypes.list" call.
20596// Exactly one of *GoogleCloudDialogflowV2ListEntityTypesResponse or
20597// error will be non-nil. Any non-2xx status code is an error. Response
20598// headers are in either
20599// *GoogleCloudDialogflowV2ListEntityTypesResponse.ServerResponse.Header
20600// or (if a response was returned at all) in
20601// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
20602// whether the returned error was because http.StatusNotModified was
20603// returned.
20604func (c *ProjectsAgentEntityTypesListCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDialogflowV2ListEntityTypesResponse, error) {
20605	gensupport.SetOptions(c.urlParams_, opts...)
20606	res, err := c.doRequest("json")
20607	if res != nil && res.StatusCode == http.StatusNotModified {
20608		if res.Body != nil {
20609			res.Body.Close()
20610		}
20611		return nil, &googleapi.Error{
20612			Code:   res.StatusCode,
20613			Header: res.Header,
20614		}
20615	}
20616	if err != nil {
20617		return nil, err
20618	}
20619	defer googleapi.CloseBody(res)
20620	if err := googleapi.CheckResponse(res); err != nil {
20621		return nil, err
20622	}
20623	ret := &GoogleCloudDialogflowV2ListEntityTypesResponse{
20624		ServerResponse: googleapi.ServerResponse{
20625			Header:         res.Header,
20626			HTTPStatusCode: res.StatusCode,
20627		},
20628	}
20629	target := &ret
20630	if err := gensupport.DecodeResponse(target, res); err != nil {
20631		return nil, err
20632	}
20633	return ret, nil
20634	// {
20635	//   "description": "Returns the list of all entity types in the specified agent.",
20636	//   "flatPath": "v2/projects/{projectsId}/agent/entityTypes",
20637	//   "httpMethod": "GET",
20638	//   "id": "dialogflow.projects.agent.entityTypes.list",
20639	//   "parameterOrder": [
20640	//     "parent"
20641	//   ],
20642	//   "parameters": {
20643	//     "languageCode": {
20644	//       "description": "Optional. The language used to access language-specific data. If not specified, the agent's default language is used. For more information, see [Multilingual intent and entity data](https://cloud.google.com/dialogflow/docs/agents-multilingual#intent-entity).",
20645	//       "location": "query",
20646	//       "type": "string"
20647	//     },
20648	//     "pageSize": {
20649	//       "description": "Optional. The maximum number of items to return in a single page. By default 100 and at most 1000.",
20650	//       "format": "int32",
20651	//       "location": "query",
20652	//       "type": "integer"
20653	//     },
20654	//     "pageToken": {
20655	//       "description": "Optional. The next_page_token value returned from a previous list request.",
20656	//       "location": "query",
20657	//       "type": "string"
20658	//     },
20659	//     "parent": {
20660	//       "description": "Required. The agent to list all entity types from. Format: `projects//agent`.",
20661	//       "location": "path",
20662	//       "pattern": "^projects/[^/]+/agent$",
20663	//       "required": true,
20664	//       "type": "string"
20665	//     }
20666	//   },
20667	//   "path": "v2/{+parent}/entityTypes",
20668	//   "response": {
20669	//     "$ref": "GoogleCloudDialogflowV2ListEntityTypesResponse"
20670	//   },
20671	//   "scopes": [
20672	//     "https://www.googleapis.com/auth/cloud-platform",
20673	//     "https://www.googleapis.com/auth/dialogflow"
20674	//   ]
20675	// }
20676
20677}
20678
20679// Pages invokes f for each page of results.
20680// A non-nil error returned from f will halt the iteration.
20681// The provided context supersedes any context provided to the Context method.
20682func (c *ProjectsAgentEntityTypesListCall) Pages(ctx context.Context, f func(*GoogleCloudDialogflowV2ListEntityTypesResponse) error) error {
20683	c.ctx_ = ctx
20684	defer c.PageToken(c.urlParams_.Get("pageToken")) // reset paging to original point
20685	for {
20686		x, err := c.Do()
20687		if err != nil {
20688			return err
20689		}
20690		if err := f(x); err != nil {
20691			return err
20692		}
20693		if x.NextPageToken == "" {
20694			return nil
20695		}
20696		c.PageToken(x.NextPageToken)
20697	}
20698}
20699
20700// method id "dialogflow.projects.agent.entityTypes.patch":
20701
20702type ProjectsAgentEntityTypesPatchCall struct {
20703	s                                 *Service
20704	nameid                            string
20705	googleclouddialogflowv2entitytype *GoogleCloudDialogflowV2EntityType
20706	urlParams_                        gensupport.URLParams
20707	ctx_                              context.Context
20708	header_                           http.Header
20709}
20710
20711// Patch: Updates the specified entity type. Note: You should always
20712// train an agent prior to sending it queries. See the training
20713// documentation (https://cloud.google.com/dialogflow/es/docs/training).
20714//
20715// - name: The unique identifier of the entity type. Required for
20716//   EntityTypes.UpdateEntityType and EntityTypes.BatchUpdateEntityTypes
20717//   methods. Format: `projects//agent/entityTypes/`.
20718func (r *ProjectsAgentEntityTypesService) Patch(nameid string, googleclouddialogflowv2entitytype *GoogleCloudDialogflowV2EntityType) *ProjectsAgentEntityTypesPatchCall {
20719	c := &ProjectsAgentEntityTypesPatchCall{s: r.s, urlParams_: make(gensupport.URLParams)}
20720	c.nameid = nameid
20721	c.googleclouddialogflowv2entitytype = googleclouddialogflowv2entitytype
20722	return c
20723}
20724
20725// LanguageCode sets the optional parameter "languageCode": The language
20726// used to access language-specific data. If not specified, the agent's
20727// default language is used. For more information, see Multilingual
20728// intent and entity data
20729// (https://cloud.google.com/dialogflow/docs/agents-multilingual#intent-entity).
20730func (c *ProjectsAgentEntityTypesPatchCall) LanguageCode(languageCode string) *ProjectsAgentEntityTypesPatchCall {
20731	c.urlParams_.Set("languageCode", languageCode)
20732	return c
20733}
20734
20735// UpdateMask sets the optional parameter "updateMask": The mask to
20736// control which fields get updated.
20737func (c *ProjectsAgentEntityTypesPatchCall) UpdateMask(updateMask string) *ProjectsAgentEntityTypesPatchCall {
20738	c.urlParams_.Set("updateMask", updateMask)
20739	return c
20740}
20741
20742// Fields allows partial responses to be retrieved. See
20743// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
20744// for more information.
20745func (c *ProjectsAgentEntityTypesPatchCall) Fields(s ...googleapi.Field) *ProjectsAgentEntityTypesPatchCall {
20746	c.urlParams_.Set("fields", googleapi.CombineFields(s))
20747	return c
20748}
20749
20750// Context sets the context to be used in this call's Do method. Any
20751// pending HTTP request will be aborted if the provided context is
20752// canceled.
20753func (c *ProjectsAgentEntityTypesPatchCall) Context(ctx context.Context) *ProjectsAgentEntityTypesPatchCall {
20754	c.ctx_ = ctx
20755	return c
20756}
20757
20758// Header returns an http.Header that can be modified by the caller to
20759// add HTTP headers to the request.
20760func (c *ProjectsAgentEntityTypesPatchCall) Header() http.Header {
20761	if c.header_ == nil {
20762		c.header_ = make(http.Header)
20763	}
20764	return c.header_
20765}
20766
20767func (c *ProjectsAgentEntityTypesPatchCall) doRequest(alt string) (*http.Response, error) {
20768	reqHeaders := make(http.Header)
20769	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20211027")
20770	for k, v := range c.header_ {
20771		reqHeaders[k] = v
20772	}
20773	reqHeaders.Set("User-Agent", c.s.userAgent())
20774	var body io.Reader = nil
20775	body, err := googleapi.WithoutDataWrapper.JSONReader(c.googleclouddialogflowv2entitytype)
20776	if err != nil {
20777		return nil, err
20778	}
20779	reqHeaders.Set("Content-Type", "application/json")
20780	c.urlParams_.Set("alt", alt)
20781	c.urlParams_.Set("prettyPrint", "false")
20782	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+name}")
20783	urls += "?" + c.urlParams_.Encode()
20784	req, err := http.NewRequest("PATCH", urls, body)
20785	if err != nil {
20786		return nil, err
20787	}
20788	req.Header = reqHeaders
20789	googleapi.Expand(req.URL, map[string]string{
20790		"name": c.nameid,
20791	})
20792	return gensupport.SendRequest(c.ctx_, c.s.client, req)
20793}
20794
20795// Do executes the "dialogflow.projects.agent.entityTypes.patch" call.
20796// Exactly one of *GoogleCloudDialogflowV2EntityType or error will be
20797// non-nil. Any non-2xx status code is an error. Response headers are in
20798// either *GoogleCloudDialogflowV2EntityType.ServerResponse.Header or
20799// (if a response was returned at all) in
20800// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
20801// whether the returned error was because http.StatusNotModified was
20802// returned.
20803func (c *ProjectsAgentEntityTypesPatchCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDialogflowV2EntityType, error) {
20804	gensupport.SetOptions(c.urlParams_, opts...)
20805	res, err := c.doRequest("json")
20806	if res != nil && res.StatusCode == http.StatusNotModified {
20807		if res.Body != nil {
20808			res.Body.Close()
20809		}
20810		return nil, &googleapi.Error{
20811			Code:   res.StatusCode,
20812			Header: res.Header,
20813		}
20814	}
20815	if err != nil {
20816		return nil, err
20817	}
20818	defer googleapi.CloseBody(res)
20819	if err := googleapi.CheckResponse(res); err != nil {
20820		return nil, err
20821	}
20822	ret := &GoogleCloudDialogflowV2EntityType{
20823		ServerResponse: googleapi.ServerResponse{
20824			Header:         res.Header,
20825			HTTPStatusCode: res.StatusCode,
20826		},
20827	}
20828	target := &ret
20829	if err := gensupport.DecodeResponse(target, res); err != nil {
20830		return nil, err
20831	}
20832	return ret, nil
20833	// {
20834	//   "description": "Updates the specified entity type. Note: You should always train an agent prior to sending it queries. See the [training documentation](https://cloud.google.com/dialogflow/es/docs/training).",
20835	//   "flatPath": "v2/projects/{projectsId}/agent/entityTypes/{entityTypesId}",
20836	//   "httpMethod": "PATCH",
20837	//   "id": "dialogflow.projects.agent.entityTypes.patch",
20838	//   "parameterOrder": [
20839	//     "name"
20840	//   ],
20841	//   "parameters": {
20842	//     "languageCode": {
20843	//       "description": "Optional. The language used to access language-specific data. If not specified, the agent's default language is used. For more information, see [Multilingual intent and entity data](https://cloud.google.com/dialogflow/docs/agents-multilingual#intent-entity).",
20844	//       "location": "query",
20845	//       "type": "string"
20846	//     },
20847	//     "name": {
20848	//       "description": "The unique identifier of the entity type. Required for EntityTypes.UpdateEntityType and EntityTypes.BatchUpdateEntityTypes methods. Format: `projects//agent/entityTypes/`.",
20849	//       "location": "path",
20850	//       "pattern": "^projects/[^/]+/agent/entityTypes/[^/]+$",
20851	//       "required": true,
20852	//       "type": "string"
20853	//     },
20854	//     "updateMask": {
20855	//       "description": "Optional. The mask to control which fields get updated.",
20856	//       "format": "google-fieldmask",
20857	//       "location": "query",
20858	//       "type": "string"
20859	//     }
20860	//   },
20861	//   "path": "v2/{+name}",
20862	//   "request": {
20863	//     "$ref": "GoogleCloudDialogflowV2EntityType"
20864	//   },
20865	//   "response": {
20866	//     "$ref": "GoogleCloudDialogflowV2EntityType"
20867	//   },
20868	//   "scopes": [
20869	//     "https://www.googleapis.com/auth/cloud-platform",
20870	//     "https://www.googleapis.com/auth/dialogflow"
20871	//   ]
20872	// }
20873
20874}
20875
20876// method id "dialogflow.projects.agent.entityTypes.entities.batchCreate":
20877
20878type ProjectsAgentEntityTypesEntitiesBatchCreateCall struct {
20879	s                                                 *Service
20880	parent                                            string
20881	googleclouddialogflowv2batchcreateentitiesrequest *GoogleCloudDialogflowV2BatchCreateEntitiesRequest
20882	urlParams_                                        gensupport.URLParams
20883	ctx_                                              context.Context
20884	header_                                           http.Header
20885}
20886
20887// BatchCreate: Creates multiple new entities in the specified entity
20888// type. This method is a long-running operation
20889// (https://cloud.google.com/dialogflow/es/docs/how/long-running-operations).
20890// The returned `Operation` type has the following method-specific
20891// fields: - `metadata`: An empty Struct message
20892// (https://developers.google.com/protocol-buffers/docs/reference/google.protobuf#struct)
20893// - `response`: An Empty message
20894// (https://developers.google.com/protocol-buffers/docs/reference/google.protobuf#empty)
20895// Note: You should always train an agent prior to sending it queries.
20896// See the training documentation
20897// (https://cloud.google.com/dialogflow/es/docs/training).
20898//
20899// - parent: The name of the entity type to create entities in. Format:
20900//   `projects//agent/entityTypes/`.
20901func (r *ProjectsAgentEntityTypesEntitiesService) BatchCreate(parent string, googleclouddialogflowv2batchcreateentitiesrequest *GoogleCloudDialogflowV2BatchCreateEntitiesRequest) *ProjectsAgentEntityTypesEntitiesBatchCreateCall {
20902	c := &ProjectsAgentEntityTypesEntitiesBatchCreateCall{s: r.s, urlParams_: make(gensupport.URLParams)}
20903	c.parent = parent
20904	c.googleclouddialogflowv2batchcreateentitiesrequest = googleclouddialogflowv2batchcreateentitiesrequest
20905	return c
20906}
20907
20908// Fields allows partial responses to be retrieved. See
20909// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
20910// for more information.
20911func (c *ProjectsAgentEntityTypesEntitiesBatchCreateCall) Fields(s ...googleapi.Field) *ProjectsAgentEntityTypesEntitiesBatchCreateCall {
20912	c.urlParams_.Set("fields", googleapi.CombineFields(s))
20913	return c
20914}
20915
20916// Context sets the context to be used in this call's Do method. Any
20917// pending HTTP request will be aborted if the provided context is
20918// canceled.
20919func (c *ProjectsAgentEntityTypesEntitiesBatchCreateCall) Context(ctx context.Context) *ProjectsAgentEntityTypesEntitiesBatchCreateCall {
20920	c.ctx_ = ctx
20921	return c
20922}
20923
20924// Header returns an http.Header that can be modified by the caller to
20925// add HTTP headers to the request.
20926func (c *ProjectsAgentEntityTypesEntitiesBatchCreateCall) Header() http.Header {
20927	if c.header_ == nil {
20928		c.header_ = make(http.Header)
20929	}
20930	return c.header_
20931}
20932
20933func (c *ProjectsAgentEntityTypesEntitiesBatchCreateCall) doRequest(alt string) (*http.Response, error) {
20934	reqHeaders := make(http.Header)
20935	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20211027")
20936	for k, v := range c.header_ {
20937		reqHeaders[k] = v
20938	}
20939	reqHeaders.Set("User-Agent", c.s.userAgent())
20940	var body io.Reader = nil
20941	body, err := googleapi.WithoutDataWrapper.JSONReader(c.googleclouddialogflowv2batchcreateentitiesrequest)
20942	if err != nil {
20943		return nil, err
20944	}
20945	reqHeaders.Set("Content-Type", "application/json")
20946	c.urlParams_.Set("alt", alt)
20947	c.urlParams_.Set("prettyPrint", "false")
20948	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+parent}/entities:batchCreate")
20949	urls += "?" + c.urlParams_.Encode()
20950	req, err := http.NewRequest("POST", urls, body)
20951	if err != nil {
20952		return nil, err
20953	}
20954	req.Header = reqHeaders
20955	googleapi.Expand(req.URL, map[string]string{
20956		"parent": c.parent,
20957	})
20958	return gensupport.SendRequest(c.ctx_, c.s.client, req)
20959}
20960
20961// Do executes the "dialogflow.projects.agent.entityTypes.entities.batchCreate" call.
20962// Exactly one of *GoogleLongrunningOperation or error will be non-nil.
20963// Any non-2xx status code is an error. Response headers are in either
20964// *GoogleLongrunningOperation.ServerResponse.Header or (if a response
20965// was returned at all) in error.(*googleapi.Error).Header. Use
20966// googleapi.IsNotModified to check whether the returned error was
20967// because http.StatusNotModified was returned.
20968func (c *ProjectsAgentEntityTypesEntitiesBatchCreateCall) Do(opts ...googleapi.CallOption) (*GoogleLongrunningOperation, error) {
20969	gensupport.SetOptions(c.urlParams_, opts...)
20970	res, err := c.doRequest("json")
20971	if res != nil && res.StatusCode == http.StatusNotModified {
20972		if res.Body != nil {
20973			res.Body.Close()
20974		}
20975		return nil, &googleapi.Error{
20976			Code:   res.StatusCode,
20977			Header: res.Header,
20978		}
20979	}
20980	if err != nil {
20981		return nil, err
20982	}
20983	defer googleapi.CloseBody(res)
20984	if err := googleapi.CheckResponse(res); err != nil {
20985		return nil, err
20986	}
20987	ret := &GoogleLongrunningOperation{
20988		ServerResponse: googleapi.ServerResponse{
20989			Header:         res.Header,
20990			HTTPStatusCode: res.StatusCode,
20991		},
20992	}
20993	target := &ret
20994	if err := gensupport.DecodeResponse(target, res); err != nil {
20995		return nil, err
20996	}
20997	return ret, nil
20998	// {
20999	//   "description": "Creates multiple new entities in the specified entity type. This method is a [long-running operation](https://cloud.google.com/dialogflow/es/docs/how/long-running-operations). The returned `Operation` type has the following method-specific fields: - `metadata`: An empty [Struct message](https://developers.google.com/protocol-buffers/docs/reference/google.protobuf#struct) - `response`: An [Empty message](https://developers.google.com/protocol-buffers/docs/reference/google.protobuf#empty) Note: You should always train an agent prior to sending it queries. See the [training documentation](https://cloud.google.com/dialogflow/es/docs/training).",
21000	//   "flatPath": "v2/projects/{projectsId}/agent/entityTypes/{entityTypesId}/entities:batchCreate",
21001	//   "httpMethod": "POST",
21002	//   "id": "dialogflow.projects.agent.entityTypes.entities.batchCreate",
21003	//   "parameterOrder": [
21004	//     "parent"
21005	//   ],
21006	//   "parameters": {
21007	//     "parent": {
21008	//       "description": "Required. The name of the entity type to create entities in. Format: `projects//agent/entityTypes/`.",
21009	//       "location": "path",
21010	//       "pattern": "^projects/[^/]+/agent/entityTypes/[^/]+$",
21011	//       "required": true,
21012	//       "type": "string"
21013	//     }
21014	//   },
21015	//   "path": "v2/{+parent}/entities:batchCreate",
21016	//   "request": {
21017	//     "$ref": "GoogleCloudDialogflowV2BatchCreateEntitiesRequest"
21018	//   },
21019	//   "response": {
21020	//     "$ref": "GoogleLongrunningOperation"
21021	//   },
21022	//   "scopes": [
21023	//     "https://www.googleapis.com/auth/cloud-platform",
21024	//     "https://www.googleapis.com/auth/dialogflow"
21025	//   ]
21026	// }
21027
21028}
21029
21030// method id "dialogflow.projects.agent.entityTypes.entities.batchDelete":
21031
21032type ProjectsAgentEntityTypesEntitiesBatchDeleteCall struct {
21033	s                                                 *Service
21034	parent                                            string
21035	googleclouddialogflowv2batchdeleteentitiesrequest *GoogleCloudDialogflowV2BatchDeleteEntitiesRequest
21036	urlParams_                                        gensupport.URLParams
21037	ctx_                                              context.Context
21038	header_                                           http.Header
21039}
21040
21041// BatchDelete: Deletes entities in the specified entity type. This
21042// method is a long-running operation
21043// (https://cloud.google.com/dialogflow/es/docs/how/long-running-operations).
21044// The returned `Operation` type has the following method-specific
21045// fields: - `metadata`: An empty Struct message
21046// (https://developers.google.com/protocol-buffers/docs/reference/google.protobuf#struct)
21047// - `response`: An Empty message
21048// (https://developers.google.com/protocol-buffers/docs/reference/google.protobuf#empty)
21049// Note: You should always train an agent prior to sending it queries.
21050// See the training documentation
21051// (https://cloud.google.com/dialogflow/es/docs/training).
21052//
21053// - parent: The name of the entity type to delete entries for. Format:
21054//   `projects//agent/entityTypes/`.
21055func (r *ProjectsAgentEntityTypesEntitiesService) BatchDelete(parent string, googleclouddialogflowv2batchdeleteentitiesrequest *GoogleCloudDialogflowV2BatchDeleteEntitiesRequest) *ProjectsAgentEntityTypesEntitiesBatchDeleteCall {
21056	c := &ProjectsAgentEntityTypesEntitiesBatchDeleteCall{s: r.s, urlParams_: make(gensupport.URLParams)}
21057	c.parent = parent
21058	c.googleclouddialogflowv2batchdeleteentitiesrequest = googleclouddialogflowv2batchdeleteentitiesrequest
21059	return c
21060}
21061
21062// Fields allows partial responses to be retrieved. See
21063// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
21064// for more information.
21065func (c *ProjectsAgentEntityTypesEntitiesBatchDeleteCall) Fields(s ...googleapi.Field) *ProjectsAgentEntityTypesEntitiesBatchDeleteCall {
21066	c.urlParams_.Set("fields", googleapi.CombineFields(s))
21067	return c
21068}
21069
21070// Context sets the context to be used in this call's Do method. Any
21071// pending HTTP request will be aborted if the provided context is
21072// canceled.
21073func (c *ProjectsAgentEntityTypesEntitiesBatchDeleteCall) Context(ctx context.Context) *ProjectsAgentEntityTypesEntitiesBatchDeleteCall {
21074	c.ctx_ = ctx
21075	return c
21076}
21077
21078// Header returns an http.Header that can be modified by the caller to
21079// add HTTP headers to the request.
21080func (c *ProjectsAgentEntityTypesEntitiesBatchDeleteCall) Header() http.Header {
21081	if c.header_ == nil {
21082		c.header_ = make(http.Header)
21083	}
21084	return c.header_
21085}
21086
21087func (c *ProjectsAgentEntityTypesEntitiesBatchDeleteCall) doRequest(alt string) (*http.Response, error) {
21088	reqHeaders := make(http.Header)
21089	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20211027")
21090	for k, v := range c.header_ {
21091		reqHeaders[k] = v
21092	}
21093	reqHeaders.Set("User-Agent", c.s.userAgent())
21094	var body io.Reader = nil
21095	body, err := googleapi.WithoutDataWrapper.JSONReader(c.googleclouddialogflowv2batchdeleteentitiesrequest)
21096	if err != nil {
21097		return nil, err
21098	}
21099	reqHeaders.Set("Content-Type", "application/json")
21100	c.urlParams_.Set("alt", alt)
21101	c.urlParams_.Set("prettyPrint", "false")
21102	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+parent}/entities:batchDelete")
21103	urls += "?" + c.urlParams_.Encode()
21104	req, err := http.NewRequest("POST", urls, body)
21105	if err != nil {
21106		return nil, err
21107	}
21108	req.Header = reqHeaders
21109	googleapi.Expand(req.URL, map[string]string{
21110		"parent": c.parent,
21111	})
21112	return gensupport.SendRequest(c.ctx_, c.s.client, req)
21113}
21114
21115// Do executes the "dialogflow.projects.agent.entityTypes.entities.batchDelete" call.
21116// Exactly one of *GoogleLongrunningOperation or error will be non-nil.
21117// Any non-2xx status code is an error. Response headers are in either
21118// *GoogleLongrunningOperation.ServerResponse.Header or (if a response
21119// was returned at all) in error.(*googleapi.Error).Header. Use
21120// googleapi.IsNotModified to check whether the returned error was
21121// because http.StatusNotModified was returned.
21122func (c *ProjectsAgentEntityTypesEntitiesBatchDeleteCall) Do(opts ...googleapi.CallOption) (*GoogleLongrunningOperation, error) {
21123	gensupport.SetOptions(c.urlParams_, opts...)
21124	res, err := c.doRequest("json")
21125	if res != nil && res.StatusCode == http.StatusNotModified {
21126		if res.Body != nil {
21127			res.Body.Close()
21128		}
21129		return nil, &googleapi.Error{
21130			Code:   res.StatusCode,
21131			Header: res.Header,
21132		}
21133	}
21134	if err != nil {
21135		return nil, err
21136	}
21137	defer googleapi.CloseBody(res)
21138	if err := googleapi.CheckResponse(res); err != nil {
21139		return nil, err
21140	}
21141	ret := &GoogleLongrunningOperation{
21142		ServerResponse: googleapi.ServerResponse{
21143			Header:         res.Header,
21144			HTTPStatusCode: res.StatusCode,
21145		},
21146	}
21147	target := &ret
21148	if err := gensupport.DecodeResponse(target, res); err != nil {
21149		return nil, err
21150	}
21151	return ret, nil
21152	// {
21153	//   "description": "Deletes entities in the specified entity type. This method is a [long-running operation](https://cloud.google.com/dialogflow/es/docs/how/long-running-operations). The returned `Operation` type has the following method-specific fields: - `metadata`: An empty [Struct message](https://developers.google.com/protocol-buffers/docs/reference/google.protobuf#struct) - `response`: An [Empty message](https://developers.google.com/protocol-buffers/docs/reference/google.protobuf#empty) Note: You should always train an agent prior to sending it queries. See the [training documentation](https://cloud.google.com/dialogflow/es/docs/training).",
21154	//   "flatPath": "v2/projects/{projectsId}/agent/entityTypes/{entityTypesId}/entities:batchDelete",
21155	//   "httpMethod": "POST",
21156	//   "id": "dialogflow.projects.agent.entityTypes.entities.batchDelete",
21157	//   "parameterOrder": [
21158	//     "parent"
21159	//   ],
21160	//   "parameters": {
21161	//     "parent": {
21162	//       "description": "Required. The name of the entity type to delete entries for. Format: `projects//agent/entityTypes/`.",
21163	//       "location": "path",
21164	//       "pattern": "^projects/[^/]+/agent/entityTypes/[^/]+$",
21165	//       "required": true,
21166	//       "type": "string"
21167	//     }
21168	//   },
21169	//   "path": "v2/{+parent}/entities:batchDelete",
21170	//   "request": {
21171	//     "$ref": "GoogleCloudDialogflowV2BatchDeleteEntitiesRequest"
21172	//   },
21173	//   "response": {
21174	//     "$ref": "GoogleLongrunningOperation"
21175	//   },
21176	//   "scopes": [
21177	//     "https://www.googleapis.com/auth/cloud-platform",
21178	//     "https://www.googleapis.com/auth/dialogflow"
21179	//   ]
21180	// }
21181
21182}
21183
21184// method id "dialogflow.projects.agent.entityTypes.entities.batchUpdate":
21185
21186type ProjectsAgentEntityTypesEntitiesBatchUpdateCall struct {
21187	s                                                 *Service
21188	parent                                            string
21189	googleclouddialogflowv2batchupdateentitiesrequest *GoogleCloudDialogflowV2BatchUpdateEntitiesRequest
21190	urlParams_                                        gensupport.URLParams
21191	ctx_                                              context.Context
21192	header_                                           http.Header
21193}
21194
21195// BatchUpdate: Updates or creates multiple entities in the specified
21196// entity type. This method does not affect entities in the entity type
21197// that aren't explicitly specified in the request. This method is a
21198// long-running operation
21199// (https://cloud.google.com/dialogflow/es/docs/how/long-running-operations).
21200// The returned `Operation` type has the following method-specific
21201// fields: - `metadata`: An empty Struct message
21202// (https://developers.google.com/protocol-buffers/docs/reference/google.protobuf#struct)
21203// - `response`: An Empty message
21204// (https://developers.google.com/protocol-buffers/docs/reference/google.protobuf#empty)
21205// Note: You should always train an agent prior to sending it queries.
21206// See the training documentation
21207// (https://cloud.google.com/dialogflow/es/docs/training).
21208//
21209// - parent: The name of the entity type to update or create entities
21210//   in. Format: `projects//agent/entityTypes/`.
21211func (r *ProjectsAgentEntityTypesEntitiesService) BatchUpdate(parent string, googleclouddialogflowv2batchupdateentitiesrequest *GoogleCloudDialogflowV2BatchUpdateEntitiesRequest) *ProjectsAgentEntityTypesEntitiesBatchUpdateCall {
21212	c := &ProjectsAgentEntityTypesEntitiesBatchUpdateCall{s: r.s, urlParams_: make(gensupport.URLParams)}
21213	c.parent = parent
21214	c.googleclouddialogflowv2batchupdateentitiesrequest = googleclouddialogflowv2batchupdateentitiesrequest
21215	return c
21216}
21217
21218// Fields allows partial responses to be retrieved. See
21219// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
21220// for more information.
21221func (c *ProjectsAgentEntityTypesEntitiesBatchUpdateCall) Fields(s ...googleapi.Field) *ProjectsAgentEntityTypesEntitiesBatchUpdateCall {
21222	c.urlParams_.Set("fields", googleapi.CombineFields(s))
21223	return c
21224}
21225
21226// Context sets the context to be used in this call's Do method. Any
21227// pending HTTP request will be aborted if the provided context is
21228// canceled.
21229func (c *ProjectsAgentEntityTypesEntitiesBatchUpdateCall) Context(ctx context.Context) *ProjectsAgentEntityTypesEntitiesBatchUpdateCall {
21230	c.ctx_ = ctx
21231	return c
21232}
21233
21234// Header returns an http.Header that can be modified by the caller to
21235// add HTTP headers to the request.
21236func (c *ProjectsAgentEntityTypesEntitiesBatchUpdateCall) Header() http.Header {
21237	if c.header_ == nil {
21238		c.header_ = make(http.Header)
21239	}
21240	return c.header_
21241}
21242
21243func (c *ProjectsAgentEntityTypesEntitiesBatchUpdateCall) doRequest(alt string) (*http.Response, error) {
21244	reqHeaders := make(http.Header)
21245	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20211027")
21246	for k, v := range c.header_ {
21247		reqHeaders[k] = v
21248	}
21249	reqHeaders.Set("User-Agent", c.s.userAgent())
21250	var body io.Reader = nil
21251	body, err := googleapi.WithoutDataWrapper.JSONReader(c.googleclouddialogflowv2batchupdateentitiesrequest)
21252	if err != nil {
21253		return nil, err
21254	}
21255	reqHeaders.Set("Content-Type", "application/json")
21256	c.urlParams_.Set("alt", alt)
21257	c.urlParams_.Set("prettyPrint", "false")
21258	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+parent}/entities:batchUpdate")
21259	urls += "?" + c.urlParams_.Encode()
21260	req, err := http.NewRequest("POST", urls, body)
21261	if err != nil {
21262		return nil, err
21263	}
21264	req.Header = reqHeaders
21265	googleapi.Expand(req.URL, map[string]string{
21266		"parent": c.parent,
21267	})
21268	return gensupport.SendRequest(c.ctx_, c.s.client, req)
21269}
21270
21271// Do executes the "dialogflow.projects.agent.entityTypes.entities.batchUpdate" call.
21272// Exactly one of *GoogleLongrunningOperation or error will be non-nil.
21273// Any non-2xx status code is an error. Response headers are in either
21274// *GoogleLongrunningOperation.ServerResponse.Header or (if a response
21275// was returned at all) in error.(*googleapi.Error).Header. Use
21276// googleapi.IsNotModified to check whether the returned error was
21277// because http.StatusNotModified was returned.
21278func (c *ProjectsAgentEntityTypesEntitiesBatchUpdateCall) Do(opts ...googleapi.CallOption) (*GoogleLongrunningOperation, error) {
21279	gensupport.SetOptions(c.urlParams_, opts...)
21280	res, err := c.doRequest("json")
21281	if res != nil && res.StatusCode == http.StatusNotModified {
21282		if res.Body != nil {
21283			res.Body.Close()
21284		}
21285		return nil, &googleapi.Error{
21286			Code:   res.StatusCode,
21287			Header: res.Header,
21288		}
21289	}
21290	if err != nil {
21291		return nil, err
21292	}
21293	defer googleapi.CloseBody(res)
21294	if err := googleapi.CheckResponse(res); err != nil {
21295		return nil, err
21296	}
21297	ret := &GoogleLongrunningOperation{
21298		ServerResponse: googleapi.ServerResponse{
21299			Header:         res.Header,
21300			HTTPStatusCode: res.StatusCode,
21301		},
21302	}
21303	target := &ret
21304	if err := gensupport.DecodeResponse(target, res); err != nil {
21305		return nil, err
21306	}
21307	return ret, nil
21308	// {
21309	//   "description": "Updates or creates multiple entities in the specified entity type. This method does not affect entities in the entity type that aren't explicitly specified in the request. This method is a [long-running operation](https://cloud.google.com/dialogflow/es/docs/how/long-running-operations). The returned `Operation` type has the following method-specific fields: - `metadata`: An empty [Struct message](https://developers.google.com/protocol-buffers/docs/reference/google.protobuf#struct) - `response`: An [Empty message](https://developers.google.com/protocol-buffers/docs/reference/google.protobuf#empty) Note: You should always train an agent prior to sending it queries. See the [training documentation](https://cloud.google.com/dialogflow/es/docs/training). ",
21310	//   "flatPath": "v2/projects/{projectsId}/agent/entityTypes/{entityTypesId}/entities:batchUpdate",
21311	//   "httpMethod": "POST",
21312	//   "id": "dialogflow.projects.agent.entityTypes.entities.batchUpdate",
21313	//   "parameterOrder": [
21314	//     "parent"
21315	//   ],
21316	//   "parameters": {
21317	//     "parent": {
21318	//       "description": "Required. The name of the entity type to update or create entities in. Format: `projects//agent/entityTypes/`.",
21319	//       "location": "path",
21320	//       "pattern": "^projects/[^/]+/agent/entityTypes/[^/]+$",
21321	//       "required": true,
21322	//       "type": "string"
21323	//     }
21324	//   },
21325	//   "path": "v2/{+parent}/entities:batchUpdate",
21326	//   "request": {
21327	//     "$ref": "GoogleCloudDialogflowV2BatchUpdateEntitiesRequest"
21328	//   },
21329	//   "response": {
21330	//     "$ref": "GoogleLongrunningOperation"
21331	//   },
21332	//   "scopes": [
21333	//     "https://www.googleapis.com/auth/cloud-platform",
21334	//     "https://www.googleapis.com/auth/dialogflow"
21335	//   ]
21336	// }
21337
21338}
21339
21340// method id "dialogflow.projects.agent.environments.create":
21341
21342type ProjectsAgentEnvironmentsCreateCall struct {
21343	s                                  *Service
21344	parent                             string
21345	googleclouddialogflowv2environment *GoogleCloudDialogflowV2Environment
21346	urlParams_                         gensupport.URLParams
21347	ctx_                               context.Context
21348	header_                            http.Header
21349}
21350
21351// Create: Creates an agent environment.
21352//
21353// - parent: The agent to create an environment for. Supported formats:
21354//   - `projects//agent` - `projects//locations//agent`.
21355func (r *ProjectsAgentEnvironmentsService) Create(parent string, googleclouddialogflowv2environment *GoogleCloudDialogflowV2Environment) *ProjectsAgentEnvironmentsCreateCall {
21356	c := &ProjectsAgentEnvironmentsCreateCall{s: r.s, urlParams_: make(gensupport.URLParams)}
21357	c.parent = parent
21358	c.googleclouddialogflowv2environment = googleclouddialogflowv2environment
21359	return c
21360}
21361
21362// EnvironmentId sets the optional parameter "environmentId": Required.
21363// The unique id of the new environment.
21364func (c *ProjectsAgentEnvironmentsCreateCall) EnvironmentId(environmentId string) *ProjectsAgentEnvironmentsCreateCall {
21365	c.urlParams_.Set("environmentId", environmentId)
21366	return c
21367}
21368
21369// Fields allows partial responses to be retrieved. See
21370// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
21371// for more information.
21372func (c *ProjectsAgentEnvironmentsCreateCall) Fields(s ...googleapi.Field) *ProjectsAgentEnvironmentsCreateCall {
21373	c.urlParams_.Set("fields", googleapi.CombineFields(s))
21374	return c
21375}
21376
21377// Context sets the context to be used in this call's Do method. Any
21378// pending HTTP request will be aborted if the provided context is
21379// canceled.
21380func (c *ProjectsAgentEnvironmentsCreateCall) Context(ctx context.Context) *ProjectsAgentEnvironmentsCreateCall {
21381	c.ctx_ = ctx
21382	return c
21383}
21384
21385// Header returns an http.Header that can be modified by the caller to
21386// add HTTP headers to the request.
21387func (c *ProjectsAgentEnvironmentsCreateCall) Header() http.Header {
21388	if c.header_ == nil {
21389		c.header_ = make(http.Header)
21390	}
21391	return c.header_
21392}
21393
21394func (c *ProjectsAgentEnvironmentsCreateCall) doRequest(alt string) (*http.Response, error) {
21395	reqHeaders := make(http.Header)
21396	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20211027")
21397	for k, v := range c.header_ {
21398		reqHeaders[k] = v
21399	}
21400	reqHeaders.Set("User-Agent", c.s.userAgent())
21401	var body io.Reader = nil
21402	body, err := googleapi.WithoutDataWrapper.JSONReader(c.googleclouddialogflowv2environment)
21403	if err != nil {
21404		return nil, err
21405	}
21406	reqHeaders.Set("Content-Type", "application/json")
21407	c.urlParams_.Set("alt", alt)
21408	c.urlParams_.Set("prettyPrint", "false")
21409	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+parent}/environments")
21410	urls += "?" + c.urlParams_.Encode()
21411	req, err := http.NewRequest("POST", urls, body)
21412	if err != nil {
21413		return nil, err
21414	}
21415	req.Header = reqHeaders
21416	googleapi.Expand(req.URL, map[string]string{
21417		"parent": c.parent,
21418	})
21419	return gensupport.SendRequest(c.ctx_, c.s.client, req)
21420}
21421
21422// Do executes the "dialogflow.projects.agent.environments.create" call.
21423// Exactly one of *GoogleCloudDialogflowV2Environment or error will be
21424// non-nil. Any non-2xx status code is an error. Response headers are in
21425// either *GoogleCloudDialogflowV2Environment.ServerResponse.Header or
21426// (if a response was returned at all) in
21427// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
21428// whether the returned error was because http.StatusNotModified was
21429// returned.
21430func (c *ProjectsAgentEnvironmentsCreateCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDialogflowV2Environment, error) {
21431	gensupport.SetOptions(c.urlParams_, opts...)
21432	res, err := c.doRequest("json")
21433	if res != nil && res.StatusCode == http.StatusNotModified {
21434		if res.Body != nil {
21435			res.Body.Close()
21436		}
21437		return nil, &googleapi.Error{
21438			Code:   res.StatusCode,
21439			Header: res.Header,
21440		}
21441	}
21442	if err != nil {
21443		return nil, err
21444	}
21445	defer googleapi.CloseBody(res)
21446	if err := googleapi.CheckResponse(res); err != nil {
21447		return nil, err
21448	}
21449	ret := &GoogleCloudDialogflowV2Environment{
21450		ServerResponse: googleapi.ServerResponse{
21451			Header:         res.Header,
21452			HTTPStatusCode: res.StatusCode,
21453		},
21454	}
21455	target := &ret
21456	if err := gensupport.DecodeResponse(target, res); err != nil {
21457		return nil, err
21458	}
21459	return ret, nil
21460	// {
21461	//   "description": "Creates an agent environment.",
21462	//   "flatPath": "v2/projects/{projectsId}/agent/environments",
21463	//   "httpMethod": "POST",
21464	//   "id": "dialogflow.projects.agent.environments.create",
21465	//   "parameterOrder": [
21466	//     "parent"
21467	//   ],
21468	//   "parameters": {
21469	//     "environmentId": {
21470	//       "description": "Required. The unique id of the new environment.",
21471	//       "location": "query",
21472	//       "type": "string"
21473	//     },
21474	//     "parent": {
21475	//       "description": "Required. The agent to create an environment for. Supported formats: - `projects//agent` - `projects//locations//agent`",
21476	//       "location": "path",
21477	//       "pattern": "^projects/[^/]+/agent$",
21478	//       "required": true,
21479	//       "type": "string"
21480	//     }
21481	//   },
21482	//   "path": "v2/{+parent}/environments",
21483	//   "request": {
21484	//     "$ref": "GoogleCloudDialogflowV2Environment"
21485	//   },
21486	//   "response": {
21487	//     "$ref": "GoogleCloudDialogflowV2Environment"
21488	//   },
21489	//   "scopes": [
21490	//     "https://www.googleapis.com/auth/cloud-platform",
21491	//     "https://www.googleapis.com/auth/dialogflow"
21492	//   ]
21493	// }
21494
21495}
21496
21497// method id "dialogflow.projects.agent.environments.delete":
21498
21499type ProjectsAgentEnvironmentsDeleteCall struct {
21500	s          *Service
21501	name       string
21502	urlParams_ gensupport.URLParams
21503	ctx_       context.Context
21504	header_    http.Header
21505}
21506
21507// Delete: Deletes the specified agent environment.
21508//
21509// - name: The name of the environment to delete. / Format: -
21510//   `projects//agent/environments/` -
21511//   `projects//locations//agent/environments/` The environment ID for
21512//   the default environment is `-`.
21513func (r *ProjectsAgentEnvironmentsService) Delete(name string) *ProjectsAgentEnvironmentsDeleteCall {
21514	c := &ProjectsAgentEnvironmentsDeleteCall{s: r.s, urlParams_: make(gensupport.URLParams)}
21515	c.name = name
21516	return c
21517}
21518
21519// Fields allows partial responses to be retrieved. See
21520// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
21521// for more information.
21522func (c *ProjectsAgentEnvironmentsDeleteCall) Fields(s ...googleapi.Field) *ProjectsAgentEnvironmentsDeleteCall {
21523	c.urlParams_.Set("fields", googleapi.CombineFields(s))
21524	return c
21525}
21526
21527// Context sets the context to be used in this call's Do method. Any
21528// pending HTTP request will be aborted if the provided context is
21529// canceled.
21530func (c *ProjectsAgentEnvironmentsDeleteCall) Context(ctx context.Context) *ProjectsAgentEnvironmentsDeleteCall {
21531	c.ctx_ = ctx
21532	return c
21533}
21534
21535// Header returns an http.Header that can be modified by the caller to
21536// add HTTP headers to the request.
21537func (c *ProjectsAgentEnvironmentsDeleteCall) Header() http.Header {
21538	if c.header_ == nil {
21539		c.header_ = make(http.Header)
21540	}
21541	return c.header_
21542}
21543
21544func (c *ProjectsAgentEnvironmentsDeleteCall) doRequest(alt string) (*http.Response, error) {
21545	reqHeaders := make(http.Header)
21546	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20211027")
21547	for k, v := range c.header_ {
21548		reqHeaders[k] = v
21549	}
21550	reqHeaders.Set("User-Agent", c.s.userAgent())
21551	var body io.Reader = nil
21552	c.urlParams_.Set("alt", alt)
21553	c.urlParams_.Set("prettyPrint", "false")
21554	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+name}")
21555	urls += "?" + c.urlParams_.Encode()
21556	req, err := http.NewRequest("DELETE", urls, body)
21557	if err != nil {
21558		return nil, err
21559	}
21560	req.Header = reqHeaders
21561	googleapi.Expand(req.URL, map[string]string{
21562		"name": c.name,
21563	})
21564	return gensupport.SendRequest(c.ctx_, c.s.client, req)
21565}
21566
21567// Do executes the "dialogflow.projects.agent.environments.delete" call.
21568// Exactly one of *GoogleProtobufEmpty or error will be non-nil. Any
21569// non-2xx status code is an error. Response headers are in either
21570// *GoogleProtobufEmpty.ServerResponse.Header or (if a response was
21571// returned at all) in error.(*googleapi.Error).Header. Use
21572// googleapi.IsNotModified to check whether the returned error was
21573// because http.StatusNotModified was returned.
21574func (c *ProjectsAgentEnvironmentsDeleteCall) Do(opts ...googleapi.CallOption) (*GoogleProtobufEmpty, error) {
21575	gensupport.SetOptions(c.urlParams_, opts...)
21576	res, err := c.doRequest("json")
21577	if res != nil && res.StatusCode == http.StatusNotModified {
21578		if res.Body != nil {
21579			res.Body.Close()
21580		}
21581		return nil, &googleapi.Error{
21582			Code:   res.StatusCode,
21583			Header: res.Header,
21584		}
21585	}
21586	if err != nil {
21587		return nil, err
21588	}
21589	defer googleapi.CloseBody(res)
21590	if err := googleapi.CheckResponse(res); err != nil {
21591		return nil, err
21592	}
21593	ret := &GoogleProtobufEmpty{
21594		ServerResponse: googleapi.ServerResponse{
21595			Header:         res.Header,
21596			HTTPStatusCode: res.StatusCode,
21597		},
21598	}
21599	target := &ret
21600	if err := gensupport.DecodeResponse(target, res); err != nil {
21601		return nil, err
21602	}
21603	return ret, nil
21604	// {
21605	//   "description": "Deletes the specified agent environment.",
21606	//   "flatPath": "v2/projects/{projectsId}/agent/environments/{environmentsId}",
21607	//   "httpMethod": "DELETE",
21608	//   "id": "dialogflow.projects.agent.environments.delete",
21609	//   "parameterOrder": [
21610	//     "name"
21611	//   ],
21612	//   "parameters": {
21613	//     "name": {
21614	//       "description": "Required. The name of the environment to delete. / Format: - `projects//agent/environments/` - `projects//locations//agent/environments/` The environment ID for the default environment is `-`.",
21615	//       "location": "path",
21616	//       "pattern": "^projects/[^/]+/agent/environments/[^/]+$",
21617	//       "required": true,
21618	//       "type": "string"
21619	//     }
21620	//   },
21621	//   "path": "v2/{+name}",
21622	//   "response": {
21623	//     "$ref": "GoogleProtobufEmpty"
21624	//   },
21625	//   "scopes": [
21626	//     "https://www.googleapis.com/auth/cloud-platform",
21627	//     "https://www.googleapis.com/auth/dialogflow"
21628	//   ]
21629	// }
21630
21631}
21632
21633// method id "dialogflow.projects.agent.environments.get":
21634
21635type ProjectsAgentEnvironmentsGetCall struct {
21636	s            *Service
21637	name         string
21638	urlParams_   gensupport.URLParams
21639	ifNoneMatch_ string
21640	ctx_         context.Context
21641	header_      http.Header
21642}
21643
21644// Get: Retrieves the specified agent environment.
21645//
21646// - name: The name of the environment. Supported formats: -
21647//   `projects//agent/environments/` -
21648//   `projects//locations//agent/environments/` The environment ID for
21649//   the default environment is `-`.
21650func (r *ProjectsAgentEnvironmentsService) Get(name string) *ProjectsAgentEnvironmentsGetCall {
21651	c := &ProjectsAgentEnvironmentsGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
21652	c.name = name
21653	return c
21654}
21655
21656// Fields allows partial responses to be retrieved. See
21657// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
21658// for more information.
21659func (c *ProjectsAgentEnvironmentsGetCall) Fields(s ...googleapi.Field) *ProjectsAgentEnvironmentsGetCall {
21660	c.urlParams_.Set("fields", googleapi.CombineFields(s))
21661	return c
21662}
21663
21664// IfNoneMatch sets the optional parameter which makes the operation
21665// fail if the object's ETag matches the given value. This is useful for
21666// getting updates only after the object has changed since the last
21667// request. Use googleapi.IsNotModified to check whether the response
21668// error from Do is the result of In-None-Match.
21669func (c *ProjectsAgentEnvironmentsGetCall) IfNoneMatch(entityTag string) *ProjectsAgentEnvironmentsGetCall {
21670	c.ifNoneMatch_ = entityTag
21671	return c
21672}
21673
21674// Context sets the context to be used in this call's Do method. Any
21675// pending HTTP request will be aborted if the provided context is
21676// canceled.
21677func (c *ProjectsAgentEnvironmentsGetCall) Context(ctx context.Context) *ProjectsAgentEnvironmentsGetCall {
21678	c.ctx_ = ctx
21679	return c
21680}
21681
21682// Header returns an http.Header that can be modified by the caller to
21683// add HTTP headers to the request.
21684func (c *ProjectsAgentEnvironmentsGetCall) Header() http.Header {
21685	if c.header_ == nil {
21686		c.header_ = make(http.Header)
21687	}
21688	return c.header_
21689}
21690
21691func (c *ProjectsAgentEnvironmentsGetCall) doRequest(alt string) (*http.Response, error) {
21692	reqHeaders := make(http.Header)
21693	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20211027")
21694	for k, v := range c.header_ {
21695		reqHeaders[k] = v
21696	}
21697	reqHeaders.Set("User-Agent", c.s.userAgent())
21698	if c.ifNoneMatch_ != "" {
21699		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
21700	}
21701	var body io.Reader = nil
21702	c.urlParams_.Set("alt", alt)
21703	c.urlParams_.Set("prettyPrint", "false")
21704	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+name}")
21705	urls += "?" + c.urlParams_.Encode()
21706	req, err := http.NewRequest("GET", urls, body)
21707	if err != nil {
21708		return nil, err
21709	}
21710	req.Header = reqHeaders
21711	googleapi.Expand(req.URL, map[string]string{
21712		"name": c.name,
21713	})
21714	return gensupport.SendRequest(c.ctx_, c.s.client, req)
21715}
21716
21717// Do executes the "dialogflow.projects.agent.environments.get" call.
21718// Exactly one of *GoogleCloudDialogflowV2Environment or error will be
21719// non-nil. Any non-2xx status code is an error. Response headers are in
21720// either *GoogleCloudDialogflowV2Environment.ServerResponse.Header or
21721// (if a response was returned at all) in
21722// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
21723// whether the returned error was because http.StatusNotModified was
21724// returned.
21725func (c *ProjectsAgentEnvironmentsGetCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDialogflowV2Environment, error) {
21726	gensupport.SetOptions(c.urlParams_, opts...)
21727	res, err := c.doRequest("json")
21728	if res != nil && res.StatusCode == http.StatusNotModified {
21729		if res.Body != nil {
21730			res.Body.Close()
21731		}
21732		return nil, &googleapi.Error{
21733			Code:   res.StatusCode,
21734			Header: res.Header,
21735		}
21736	}
21737	if err != nil {
21738		return nil, err
21739	}
21740	defer googleapi.CloseBody(res)
21741	if err := googleapi.CheckResponse(res); err != nil {
21742		return nil, err
21743	}
21744	ret := &GoogleCloudDialogflowV2Environment{
21745		ServerResponse: googleapi.ServerResponse{
21746			Header:         res.Header,
21747			HTTPStatusCode: res.StatusCode,
21748		},
21749	}
21750	target := &ret
21751	if err := gensupport.DecodeResponse(target, res); err != nil {
21752		return nil, err
21753	}
21754	return ret, nil
21755	// {
21756	//   "description": "Retrieves the specified agent environment.",
21757	//   "flatPath": "v2/projects/{projectsId}/agent/environments/{environmentsId}",
21758	//   "httpMethod": "GET",
21759	//   "id": "dialogflow.projects.agent.environments.get",
21760	//   "parameterOrder": [
21761	//     "name"
21762	//   ],
21763	//   "parameters": {
21764	//     "name": {
21765	//       "description": "Required. The name of the environment. Supported formats: - `projects//agent/environments/` - `projects//locations//agent/environments/` The environment ID for the default environment is `-`.",
21766	//       "location": "path",
21767	//       "pattern": "^projects/[^/]+/agent/environments/[^/]+$",
21768	//       "required": true,
21769	//       "type": "string"
21770	//     }
21771	//   },
21772	//   "path": "v2/{+name}",
21773	//   "response": {
21774	//     "$ref": "GoogleCloudDialogflowV2Environment"
21775	//   },
21776	//   "scopes": [
21777	//     "https://www.googleapis.com/auth/cloud-platform",
21778	//     "https://www.googleapis.com/auth/dialogflow"
21779	//   ]
21780	// }
21781
21782}
21783
21784// method id "dialogflow.projects.agent.environments.getHistory":
21785
21786type ProjectsAgentEnvironmentsGetHistoryCall struct {
21787	s            *Service
21788	parent       string
21789	urlParams_   gensupport.URLParams
21790	ifNoneMatch_ string
21791	ctx_         context.Context
21792	header_      http.Header
21793}
21794
21795// GetHistory: Gets the history of the specified environment.
21796//
21797// - parent: The name of the environment to retrieve history for.
21798//   Supported formats: - `projects//agent/environments/` -
21799//   `projects//locations//agent/environments/` The environment ID for
21800//   the default environment is `-`.
21801func (r *ProjectsAgentEnvironmentsService) GetHistory(parent string) *ProjectsAgentEnvironmentsGetHistoryCall {
21802	c := &ProjectsAgentEnvironmentsGetHistoryCall{s: r.s, urlParams_: make(gensupport.URLParams)}
21803	c.parent = parent
21804	return c
21805}
21806
21807// PageSize sets the optional parameter "pageSize": The maximum number
21808// of items to return in a single page. By default 100 and at most 1000.
21809func (c *ProjectsAgentEnvironmentsGetHistoryCall) PageSize(pageSize int64) *ProjectsAgentEnvironmentsGetHistoryCall {
21810	c.urlParams_.Set("pageSize", fmt.Sprint(pageSize))
21811	return c
21812}
21813
21814// PageToken sets the optional parameter "pageToken": The
21815// next_page_token value returned from a previous list request.
21816func (c *ProjectsAgentEnvironmentsGetHistoryCall) PageToken(pageToken string) *ProjectsAgentEnvironmentsGetHistoryCall {
21817	c.urlParams_.Set("pageToken", pageToken)
21818	return c
21819}
21820
21821// Fields allows partial responses to be retrieved. See
21822// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
21823// for more information.
21824func (c *ProjectsAgentEnvironmentsGetHistoryCall) Fields(s ...googleapi.Field) *ProjectsAgentEnvironmentsGetHistoryCall {
21825	c.urlParams_.Set("fields", googleapi.CombineFields(s))
21826	return c
21827}
21828
21829// IfNoneMatch sets the optional parameter which makes the operation
21830// fail if the object's ETag matches the given value. This is useful for
21831// getting updates only after the object has changed since the last
21832// request. Use googleapi.IsNotModified to check whether the response
21833// error from Do is the result of In-None-Match.
21834func (c *ProjectsAgentEnvironmentsGetHistoryCall) IfNoneMatch(entityTag string) *ProjectsAgentEnvironmentsGetHistoryCall {
21835	c.ifNoneMatch_ = entityTag
21836	return c
21837}
21838
21839// Context sets the context to be used in this call's Do method. Any
21840// pending HTTP request will be aborted if the provided context is
21841// canceled.
21842func (c *ProjectsAgentEnvironmentsGetHistoryCall) Context(ctx context.Context) *ProjectsAgentEnvironmentsGetHistoryCall {
21843	c.ctx_ = ctx
21844	return c
21845}
21846
21847// Header returns an http.Header that can be modified by the caller to
21848// add HTTP headers to the request.
21849func (c *ProjectsAgentEnvironmentsGetHistoryCall) Header() http.Header {
21850	if c.header_ == nil {
21851		c.header_ = make(http.Header)
21852	}
21853	return c.header_
21854}
21855
21856func (c *ProjectsAgentEnvironmentsGetHistoryCall) doRequest(alt string) (*http.Response, error) {
21857	reqHeaders := make(http.Header)
21858	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20211027")
21859	for k, v := range c.header_ {
21860		reqHeaders[k] = v
21861	}
21862	reqHeaders.Set("User-Agent", c.s.userAgent())
21863	if c.ifNoneMatch_ != "" {
21864		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
21865	}
21866	var body io.Reader = nil
21867	c.urlParams_.Set("alt", alt)
21868	c.urlParams_.Set("prettyPrint", "false")
21869	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+parent}/history")
21870	urls += "?" + c.urlParams_.Encode()
21871	req, err := http.NewRequest("GET", urls, body)
21872	if err != nil {
21873		return nil, err
21874	}
21875	req.Header = reqHeaders
21876	googleapi.Expand(req.URL, map[string]string{
21877		"parent": c.parent,
21878	})
21879	return gensupport.SendRequest(c.ctx_, c.s.client, req)
21880}
21881
21882// Do executes the "dialogflow.projects.agent.environments.getHistory" call.
21883// Exactly one of *GoogleCloudDialogflowV2EnvironmentHistory or error
21884// will be non-nil. Any non-2xx status code is an error. Response
21885// headers are in either
21886// *GoogleCloudDialogflowV2EnvironmentHistory.ServerResponse.Header or
21887// (if a response was returned at all) in
21888// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
21889// whether the returned error was because http.StatusNotModified was
21890// returned.
21891func (c *ProjectsAgentEnvironmentsGetHistoryCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDialogflowV2EnvironmentHistory, error) {
21892	gensupport.SetOptions(c.urlParams_, opts...)
21893	res, err := c.doRequest("json")
21894	if res != nil && res.StatusCode == http.StatusNotModified {
21895		if res.Body != nil {
21896			res.Body.Close()
21897		}
21898		return nil, &googleapi.Error{
21899			Code:   res.StatusCode,
21900			Header: res.Header,
21901		}
21902	}
21903	if err != nil {
21904		return nil, err
21905	}
21906	defer googleapi.CloseBody(res)
21907	if err := googleapi.CheckResponse(res); err != nil {
21908		return nil, err
21909	}
21910	ret := &GoogleCloudDialogflowV2EnvironmentHistory{
21911		ServerResponse: googleapi.ServerResponse{
21912			Header:         res.Header,
21913			HTTPStatusCode: res.StatusCode,
21914		},
21915	}
21916	target := &ret
21917	if err := gensupport.DecodeResponse(target, res); err != nil {
21918		return nil, err
21919	}
21920	return ret, nil
21921	// {
21922	//   "description": "Gets the history of the specified environment.",
21923	//   "flatPath": "v2/projects/{projectsId}/agent/environments/{environmentsId}/history",
21924	//   "httpMethod": "GET",
21925	//   "id": "dialogflow.projects.agent.environments.getHistory",
21926	//   "parameterOrder": [
21927	//     "parent"
21928	//   ],
21929	//   "parameters": {
21930	//     "pageSize": {
21931	//       "description": "Optional. The maximum number of items to return in a single page. By default 100 and at most 1000.",
21932	//       "format": "int32",
21933	//       "location": "query",
21934	//       "type": "integer"
21935	//     },
21936	//     "pageToken": {
21937	//       "description": "Optional. The next_page_token value returned from a previous list request.",
21938	//       "location": "query",
21939	//       "type": "string"
21940	//     },
21941	//     "parent": {
21942	//       "description": "Required. The name of the environment to retrieve history for. Supported formats: - `projects//agent/environments/` - `projects//locations//agent/environments/` The environment ID for the default environment is `-`.",
21943	//       "location": "path",
21944	//       "pattern": "^projects/[^/]+/agent/environments/[^/]+$",
21945	//       "required": true,
21946	//       "type": "string"
21947	//     }
21948	//   },
21949	//   "path": "v2/{+parent}/history",
21950	//   "response": {
21951	//     "$ref": "GoogleCloudDialogflowV2EnvironmentHistory"
21952	//   },
21953	//   "scopes": [
21954	//     "https://www.googleapis.com/auth/cloud-platform",
21955	//     "https://www.googleapis.com/auth/dialogflow"
21956	//   ]
21957	// }
21958
21959}
21960
21961// Pages invokes f for each page of results.
21962// A non-nil error returned from f will halt the iteration.
21963// The provided context supersedes any context provided to the Context method.
21964func (c *ProjectsAgentEnvironmentsGetHistoryCall) Pages(ctx context.Context, f func(*GoogleCloudDialogflowV2EnvironmentHistory) error) error {
21965	c.ctx_ = ctx
21966	defer c.PageToken(c.urlParams_.Get("pageToken")) // reset paging to original point
21967	for {
21968		x, err := c.Do()
21969		if err != nil {
21970			return err
21971		}
21972		if err := f(x); err != nil {
21973			return err
21974		}
21975		if x.NextPageToken == "" {
21976			return nil
21977		}
21978		c.PageToken(x.NextPageToken)
21979	}
21980}
21981
21982// method id "dialogflow.projects.agent.environments.list":
21983
21984type ProjectsAgentEnvironmentsListCall struct {
21985	s            *Service
21986	parent       string
21987	urlParams_   gensupport.URLParams
21988	ifNoneMatch_ string
21989	ctx_         context.Context
21990	header_      http.Header
21991}
21992
21993// List: Returns the list of all non-default environments of the
21994// specified agent.
21995//
21996// - parent: The agent to list all environments from. Format: -
21997//   `projects//agent` - `projects//locations//agent`.
21998func (r *ProjectsAgentEnvironmentsService) List(parent string) *ProjectsAgentEnvironmentsListCall {
21999	c := &ProjectsAgentEnvironmentsListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
22000	c.parent = parent
22001	return c
22002}
22003
22004// PageSize sets the optional parameter "pageSize": The maximum number
22005// of items to return in a single page. By default 100 and at most 1000.
22006func (c *ProjectsAgentEnvironmentsListCall) PageSize(pageSize int64) *ProjectsAgentEnvironmentsListCall {
22007	c.urlParams_.Set("pageSize", fmt.Sprint(pageSize))
22008	return c
22009}
22010
22011// PageToken sets the optional parameter "pageToken": The
22012// next_page_token value returned from a previous list request.
22013func (c *ProjectsAgentEnvironmentsListCall) PageToken(pageToken string) *ProjectsAgentEnvironmentsListCall {
22014	c.urlParams_.Set("pageToken", pageToken)
22015	return c
22016}
22017
22018// Fields allows partial responses to be retrieved. See
22019// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
22020// for more information.
22021func (c *ProjectsAgentEnvironmentsListCall) Fields(s ...googleapi.Field) *ProjectsAgentEnvironmentsListCall {
22022	c.urlParams_.Set("fields", googleapi.CombineFields(s))
22023	return c
22024}
22025
22026// IfNoneMatch sets the optional parameter which makes the operation
22027// fail if the object's ETag matches the given value. This is useful for
22028// getting updates only after the object has changed since the last
22029// request. Use googleapi.IsNotModified to check whether the response
22030// error from Do is the result of In-None-Match.
22031func (c *ProjectsAgentEnvironmentsListCall) IfNoneMatch(entityTag string) *ProjectsAgentEnvironmentsListCall {
22032	c.ifNoneMatch_ = entityTag
22033	return c
22034}
22035
22036// Context sets the context to be used in this call's Do method. Any
22037// pending HTTP request will be aborted if the provided context is
22038// canceled.
22039func (c *ProjectsAgentEnvironmentsListCall) Context(ctx context.Context) *ProjectsAgentEnvironmentsListCall {
22040	c.ctx_ = ctx
22041	return c
22042}
22043
22044// Header returns an http.Header that can be modified by the caller to
22045// add HTTP headers to the request.
22046func (c *ProjectsAgentEnvironmentsListCall) Header() http.Header {
22047	if c.header_ == nil {
22048		c.header_ = make(http.Header)
22049	}
22050	return c.header_
22051}
22052
22053func (c *ProjectsAgentEnvironmentsListCall) doRequest(alt string) (*http.Response, error) {
22054	reqHeaders := make(http.Header)
22055	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20211027")
22056	for k, v := range c.header_ {
22057		reqHeaders[k] = v
22058	}
22059	reqHeaders.Set("User-Agent", c.s.userAgent())
22060	if c.ifNoneMatch_ != "" {
22061		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
22062	}
22063	var body io.Reader = nil
22064	c.urlParams_.Set("alt", alt)
22065	c.urlParams_.Set("prettyPrint", "false")
22066	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+parent}/environments")
22067	urls += "?" + c.urlParams_.Encode()
22068	req, err := http.NewRequest("GET", urls, body)
22069	if err != nil {
22070		return nil, err
22071	}
22072	req.Header = reqHeaders
22073	googleapi.Expand(req.URL, map[string]string{
22074		"parent": c.parent,
22075	})
22076	return gensupport.SendRequest(c.ctx_, c.s.client, req)
22077}
22078
22079// Do executes the "dialogflow.projects.agent.environments.list" call.
22080// Exactly one of *GoogleCloudDialogflowV2ListEnvironmentsResponse or
22081// error will be non-nil. Any non-2xx status code is an error. Response
22082// headers are in either
22083// *GoogleCloudDialogflowV2ListEnvironmentsResponse.ServerResponse.Header
22084//  or (if a response was returned at all) in
22085// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
22086// whether the returned error was because http.StatusNotModified was
22087// returned.
22088func (c *ProjectsAgentEnvironmentsListCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDialogflowV2ListEnvironmentsResponse, error) {
22089	gensupport.SetOptions(c.urlParams_, opts...)
22090	res, err := c.doRequest("json")
22091	if res != nil && res.StatusCode == http.StatusNotModified {
22092		if res.Body != nil {
22093			res.Body.Close()
22094		}
22095		return nil, &googleapi.Error{
22096			Code:   res.StatusCode,
22097			Header: res.Header,
22098		}
22099	}
22100	if err != nil {
22101		return nil, err
22102	}
22103	defer googleapi.CloseBody(res)
22104	if err := googleapi.CheckResponse(res); err != nil {
22105		return nil, err
22106	}
22107	ret := &GoogleCloudDialogflowV2ListEnvironmentsResponse{
22108		ServerResponse: googleapi.ServerResponse{
22109			Header:         res.Header,
22110			HTTPStatusCode: res.StatusCode,
22111		},
22112	}
22113	target := &ret
22114	if err := gensupport.DecodeResponse(target, res); err != nil {
22115		return nil, err
22116	}
22117	return ret, nil
22118	// {
22119	//   "description": "Returns the list of all non-default environments of the specified agent.",
22120	//   "flatPath": "v2/projects/{projectsId}/agent/environments",
22121	//   "httpMethod": "GET",
22122	//   "id": "dialogflow.projects.agent.environments.list",
22123	//   "parameterOrder": [
22124	//     "parent"
22125	//   ],
22126	//   "parameters": {
22127	//     "pageSize": {
22128	//       "description": "Optional. The maximum number of items to return in a single page. By default 100 and at most 1000.",
22129	//       "format": "int32",
22130	//       "location": "query",
22131	//       "type": "integer"
22132	//     },
22133	//     "pageToken": {
22134	//       "description": "Optional. The next_page_token value returned from a previous list request.",
22135	//       "location": "query",
22136	//       "type": "string"
22137	//     },
22138	//     "parent": {
22139	//       "description": "Required. The agent to list all environments from. Format: - `projects//agent` - `projects//locations//agent`",
22140	//       "location": "path",
22141	//       "pattern": "^projects/[^/]+/agent$",
22142	//       "required": true,
22143	//       "type": "string"
22144	//     }
22145	//   },
22146	//   "path": "v2/{+parent}/environments",
22147	//   "response": {
22148	//     "$ref": "GoogleCloudDialogflowV2ListEnvironmentsResponse"
22149	//   },
22150	//   "scopes": [
22151	//     "https://www.googleapis.com/auth/cloud-platform",
22152	//     "https://www.googleapis.com/auth/dialogflow"
22153	//   ]
22154	// }
22155
22156}
22157
22158// Pages invokes f for each page of results.
22159// A non-nil error returned from f will halt the iteration.
22160// The provided context supersedes any context provided to the Context method.
22161func (c *ProjectsAgentEnvironmentsListCall) Pages(ctx context.Context, f func(*GoogleCloudDialogflowV2ListEnvironmentsResponse) error) error {
22162	c.ctx_ = ctx
22163	defer c.PageToken(c.urlParams_.Get("pageToken")) // reset paging to original point
22164	for {
22165		x, err := c.Do()
22166		if err != nil {
22167			return err
22168		}
22169		if err := f(x); err != nil {
22170			return err
22171		}
22172		if x.NextPageToken == "" {
22173			return nil
22174		}
22175		c.PageToken(x.NextPageToken)
22176	}
22177}
22178
22179// method id "dialogflow.projects.agent.environments.patch":
22180
22181type ProjectsAgentEnvironmentsPatchCall struct {
22182	s                                  *Service
22183	nameid                             string
22184	googleclouddialogflowv2environment *GoogleCloudDialogflowV2Environment
22185	urlParams_                         gensupport.URLParams
22186	ctx_                               context.Context
22187	header_                            http.Header
22188}
22189
22190// Patch: Updates the specified agent environment. This method allows
22191// you to deploy new agent versions into the environment. When an
22192// environment is pointed to a new agent version by setting
22193// `environment.agent_version`, the environment is temporarily set to
22194// the `LOADING` state. During that time, the environment continues
22195// serving the previous version of the agent. After the new agent
22196// version is done loading, the environment is set back to the `RUNNING`
22197// state. You can use "-" as Environment ID in environment name to
22198// update an agent version in the default environment. WARNING: this
22199// will negate all recent changes to the draft agent and can't be
22200// undone. You may want to save the draft agent to a version before
22201// calling this method.
22202//
22203// - name: Output only. The unique identifier of this agent environment.
22204//   Supported formats: - `projects//agent/environments/` -
22205//   `projects//locations//agent/environments/` The environment ID for
22206//   the default environment is `-`.
22207func (r *ProjectsAgentEnvironmentsService) Patch(nameid string, googleclouddialogflowv2environment *GoogleCloudDialogflowV2Environment) *ProjectsAgentEnvironmentsPatchCall {
22208	c := &ProjectsAgentEnvironmentsPatchCall{s: r.s, urlParams_: make(gensupport.URLParams)}
22209	c.nameid = nameid
22210	c.googleclouddialogflowv2environment = googleclouddialogflowv2environment
22211	return c
22212}
22213
22214// AllowLoadToDraftAndDiscardChanges sets the optional parameter
22215// "allowLoadToDraftAndDiscardChanges": This field is used to prevent
22216// accidental overwrite of the default environment, which is an
22217// operation that cannot be undone. To confirm that the caller desires
22218// this overwrite, this field must be explicitly set to true when
22219// updating the default environment (environment ID = `-`).
22220func (c *ProjectsAgentEnvironmentsPatchCall) AllowLoadToDraftAndDiscardChanges(allowLoadToDraftAndDiscardChanges bool) *ProjectsAgentEnvironmentsPatchCall {
22221	c.urlParams_.Set("allowLoadToDraftAndDiscardChanges", fmt.Sprint(allowLoadToDraftAndDiscardChanges))
22222	return c
22223}
22224
22225// UpdateMask sets the optional parameter "updateMask": Required. The
22226// mask to control which fields get updated.
22227func (c *ProjectsAgentEnvironmentsPatchCall) UpdateMask(updateMask string) *ProjectsAgentEnvironmentsPatchCall {
22228	c.urlParams_.Set("updateMask", updateMask)
22229	return c
22230}
22231
22232// Fields allows partial responses to be retrieved. See
22233// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
22234// for more information.
22235func (c *ProjectsAgentEnvironmentsPatchCall) Fields(s ...googleapi.Field) *ProjectsAgentEnvironmentsPatchCall {
22236	c.urlParams_.Set("fields", googleapi.CombineFields(s))
22237	return c
22238}
22239
22240// Context sets the context to be used in this call's Do method. Any
22241// pending HTTP request will be aborted if the provided context is
22242// canceled.
22243func (c *ProjectsAgentEnvironmentsPatchCall) Context(ctx context.Context) *ProjectsAgentEnvironmentsPatchCall {
22244	c.ctx_ = ctx
22245	return c
22246}
22247
22248// Header returns an http.Header that can be modified by the caller to
22249// add HTTP headers to the request.
22250func (c *ProjectsAgentEnvironmentsPatchCall) Header() http.Header {
22251	if c.header_ == nil {
22252		c.header_ = make(http.Header)
22253	}
22254	return c.header_
22255}
22256
22257func (c *ProjectsAgentEnvironmentsPatchCall) doRequest(alt string) (*http.Response, error) {
22258	reqHeaders := make(http.Header)
22259	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20211027")
22260	for k, v := range c.header_ {
22261		reqHeaders[k] = v
22262	}
22263	reqHeaders.Set("User-Agent", c.s.userAgent())
22264	var body io.Reader = nil
22265	body, err := googleapi.WithoutDataWrapper.JSONReader(c.googleclouddialogflowv2environment)
22266	if err != nil {
22267		return nil, err
22268	}
22269	reqHeaders.Set("Content-Type", "application/json")
22270	c.urlParams_.Set("alt", alt)
22271	c.urlParams_.Set("prettyPrint", "false")
22272	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+name}")
22273	urls += "?" + c.urlParams_.Encode()
22274	req, err := http.NewRequest("PATCH", urls, body)
22275	if err != nil {
22276		return nil, err
22277	}
22278	req.Header = reqHeaders
22279	googleapi.Expand(req.URL, map[string]string{
22280		"name": c.nameid,
22281	})
22282	return gensupport.SendRequest(c.ctx_, c.s.client, req)
22283}
22284
22285// Do executes the "dialogflow.projects.agent.environments.patch" call.
22286// Exactly one of *GoogleCloudDialogflowV2Environment or error will be
22287// non-nil. Any non-2xx status code is an error. Response headers are in
22288// either *GoogleCloudDialogflowV2Environment.ServerResponse.Header or
22289// (if a response was returned at all) in
22290// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
22291// whether the returned error was because http.StatusNotModified was
22292// returned.
22293func (c *ProjectsAgentEnvironmentsPatchCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDialogflowV2Environment, error) {
22294	gensupport.SetOptions(c.urlParams_, opts...)
22295	res, err := c.doRequest("json")
22296	if res != nil && res.StatusCode == http.StatusNotModified {
22297		if res.Body != nil {
22298			res.Body.Close()
22299		}
22300		return nil, &googleapi.Error{
22301			Code:   res.StatusCode,
22302			Header: res.Header,
22303		}
22304	}
22305	if err != nil {
22306		return nil, err
22307	}
22308	defer googleapi.CloseBody(res)
22309	if err := googleapi.CheckResponse(res); err != nil {
22310		return nil, err
22311	}
22312	ret := &GoogleCloudDialogflowV2Environment{
22313		ServerResponse: googleapi.ServerResponse{
22314			Header:         res.Header,
22315			HTTPStatusCode: res.StatusCode,
22316		},
22317	}
22318	target := &ret
22319	if err := gensupport.DecodeResponse(target, res); err != nil {
22320		return nil, err
22321	}
22322	return ret, nil
22323	// {
22324	//   "description": "Updates the specified agent environment. This method allows you to deploy new agent versions into the environment. When an environment is pointed to a new agent version by setting `environment.agent_version`, the environment is temporarily set to the `LOADING` state. During that time, the environment continues serving the previous version of the agent. After the new agent version is done loading, the environment is set back to the `RUNNING` state. You can use \"-\" as Environment ID in environment name to update an agent version in the default environment. WARNING: this will negate all recent changes to the draft agent and can't be undone. You may want to save the draft agent to a version before calling this method.",
22325	//   "flatPath": "v2/projects/{projectsId}/agent/environments/{environmentsId}",
22326	//   "httpMethod": "PATCH",
22327	//   "id": "dialogflow.projects.agent.environments.patch",
22328	//   "parameterOrder": [
22329	//     "name"
22330	//   ],
22331	//   "parameters": {
22332	//     "allowLoadToDraftAndDiscardChanges": {
22333	//       "description": "Optional. This field is used to prevent accidental overwrite of the default environment, which is an operation that cannot be undone. To confirm that the caller desires this overwrite, this field must be explicitly set to true when updating the default environment (environment ID = `-`).",
22334	//       "location": "query",
22335	//       "type": "boolean"
22336	//     },
22337	//     "name": {
22338	//       "description": "Output only. The unique identifier of this agent environment. Supported formats: - `projects//agent/environments/` - `projects//locations//agent/environments/` The environment ID for the default environment is `-`.",
22339	//       "location": "path",
22340	//       "pattern": "^projects/[^/]+/agent/environments/[^/]+$",
22341	//       "required": true,
22342	//       "type": "string"
22343	//     },
22344	//     "updateMask": {
22345	//       "description": "Required. The mask to control which fields get updated.",
22346	//       "format": "google-fieldmask",
22347	//       "location": "query",
22348	//       "type": "string"
22349	//     }
22350	//   },
22351	//   "path": "v2/{+name}",
22352	//   "request": {
22353	//     "$ref": "GoogleCloudDialogflowV2Environment"
22354	//   },
22355	//   "response": {
22356	//     "$ref": "GoogleCloudDialogflowV2Environment"
22357	//   },
22358	//   "scopes": [
22359	//     "https://www.googleapis.com/auth/cloud-platform",
22360	//     "https://www.googleapis.com/auth/dialogflow"
22361	//   ]
22362	// }
22363
22364}
22365
22366// method id "dialogflow.projects.agent.environments.intents.list":
22367
22368type ProjectsAgentEnvironmentsIntentsListCall struct {
22369	s            *Service
22370	parent       string
22371	urlParams_   gensupport.URLParams
22372	ifNoneMatch_ string
22373	ctx_         context.Context
22374	header_      http.Header
22375}
22376
22377// List: Returns the list of all intents in the specified agent.
22378//
22379// - parent: The agent to list all intents from. Format:
22380//   `projects//agent` or `projects//locations//agent`. Alternatively,
22381//   you can specify the environment to list intents for. Format:
22382//   `projects//agent/environments/` or
22383//   `projects//locations//agent/environments/`. Note: training phrases
22384//   of the intents will not be returned for non-draft environment.
22385func (r *ProjectsAgentEnvironmentsIntentsService) List(parent string) *ProjectsAgentEnvironmentsIntentsListCall {
22386	c := &ProjectsAgentEnvironmentsIntentsListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
22387	c.parent = parent
22388	return c
22389}
22390
22391// IntentView sets the optional parameter "intentView": The resource
22392// view to apply to the returned intent.
22393//
22394// Possible values:
22395//   "INTENT_VIEW_UNSPECIFIED" - Training phrases field is not populated
22396// in the response.
22397//   "INTENT_VIEW_FULL" - All fields are populated.
22398func (c *ProjectsAgentEnvironmentsIntentsListCall) IntentView(intentView string) *ProjectsAgentEnvironmentsIntentsListCall {
22399	c.urlParams_.Set("intentView", intentView)
22400	return c
22401}
22402
22403// LanguageCode sets the optional parameter "languageCode": The language
22404// used to access language-specific data. If not specified, the agent's
22405// default language is used. For more information, see Multilingual
22406// intent and entity data
22407// (https://cloud.google.com/dialogflow/docs/agents-multilingual#intent-entity).
22408func (c *ProjectsAgentEnvironmentsIntentsListCall) LanguageCode(languageCode string) *ProjectsAgentEnvironmentsIntentsListCall {
22409	c.urlParams_.Set("languageCode", languageCode)
22410	return c
22411}
22412
22413// PageSize sets the optional parameter "pageSize": The maximum number
22414// of items to return in a single page. By default 100 and at most 1000.
22415func (c *ProjectsAgentEnvironmentsIntentsListCall) PageSize(pageSize int64) *ProjectsAgentEnvironmentsIntentsListCall {
22416	c.urlParams_.Set("pageSize", fmt.Sprint(pageSize))
22417	return c
22418}
22419
22420// PageToken sets the optional parameter "pageToken": The
22421// next_page_token value returned from a previous list request.
22422func (c *ProjectsAgentEnvironmentsIntentsListCall) PageToken(pageToken string) *ProjectsAgentEnvironmentsIntentsListCall {
22423	c.urlParams_.Set("pageToken", pageToken)
22424	return c
22425}
22426
22427// Fields allows partial responses to be retrieved. See
22428// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
22429// for more information.
22430func (c *ProjectsAgentEnvironmentsIntentsListCall) Fields(s ...googleapi.Field) *ProjectsAgentEnvironmentsIntentsListCall {
22431	c.urlParams_.Set("fields", googleapi.CombineFields(s))
22432	return c
22433}
22434
22435// IfNoneMatch sets the optional parameter which makes the operation
22436// fail if the object's ETag matches the given value. This is useful for
22437// getting updates only after the object has changed since the last
22438// request. Use googleapi.IsNotModified to check whether the response
22439// error from Do is the result of In-None-Match.
22440func (c *ProjectsAgentEnvironmentsIntentsListCall) IfNoneMatch(entityTag string) *ProjectsAgentEnvironmentsIntentsListCall {
22441	c.ifNoneMatch_ = entityTag
22442	return c
22443}
22444
22445// Context sets the context to be used in this call's Do method. Any
22446// pending HTTP request will be aborted if the provided context is
22447// canceled.
22448func (c *ProjectsAgentEnvironmentsIntentsListCall) Context(ctx context.Context) *ProjectsAgentEnvironmentsIntentsListCall {
22449	c.ctx_ = ctx
22450	return c
22451}
22452
22453// Header returns an http.Header that can be modified by the caller to
22454// add HTTP headers to the request.
22455func (c *ProjectsAgentEnvironmentsIntentsListCall) Header() http.Header {
22456	if c.header_ == nil {
22457		c.header_ = make(http.Header)
22458	}
22459	return c.header_
22460}
22461
22462func (c *ProjectsAgentEnvironmentsIntentsListCall) doRequest(alt string) (*http.Response, error) {
22463	reqHeaders := make(http.Header)
22464	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20211027")
22465	for k, v := range c.header_ {
22466		reqHeaders[k] = v
22467	}
22468	reqHeaders.Set("User-Agent", c.s.userAgent())
22469	if c.ifNoneMatch_ != "" {
22470		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
22471	}
22472	var body io.Reader = nil
22473	c.urlParams_.Set("alt", alt)
22474	c.urlParams_.Set("prettyPrint", "false")
22475	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+parent}/intents")
22476	urls += "?" + c.urlParams_.Encode()
22477	req, err := http.NewRequest("GET", urls, body)
22478	if err != nil {
22479		return nil, err
22480	}
22481	req.Header = reqHeaders
22482	googleapi.Expand(req.URL, map[string]string{
22483		"parent": c.parent,
22484	})
22485	return gensupport.SendRequest(c.ctx_, c.s.client, req)
22486}
22487
22488// Do executes the "dialogflow.projects.agent.environments.intents.list" call.
22489// Exactly one of *GoogleCloudDialogflowV2ListIntentsResponse or error
22490// will be non-nil. Any non-2xx status code is an error. Response
22491// headers are in either
22492// *GoogleCloudDialogflowV2ListIntentsResponse.ServerResponse.Header or
22493// (if a response was returned at all) in
22494// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
22495// whether the returned error was because http.StatusNotModified was
22496// returned.
22497func (c *ProjectsAgentEnvironmentsIntentsListCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDialogflowV2ListIntentsResponse, error) {
22498	gensupport.SetOptions(c.urlParams_, opts...)
22499	res, err := c.doRequest("json")
22500	if res != nil && res.StatusCode == http.StatusNotModified {
22501		if res.Body != nil {
22502			res.Body.Close()
22503		}
22504		return nil, &googleapi.Error{
22505			Code:   res.StatusCode,
22506			Header: res.Header,
22507		}
22508	}
22509	if err != nil {
22510		return nil, err
22511	}
22512	defer googleapi.CloseBody(res)
22513	if err := googleapi.CheckResponse(res); err != nil {
22514		return nil, err
22515	}
22516	ret := &GoogleCloudDialogflowV2ListIntentsResponse{
22517		ServerResponse: googleapi.ServerResponse{
22518			Header:         res.Header,
22519			HTTPStatusCode: res.StatusCode,
22520		},
22521	}
22522	target := &ret
22523	if err := gensupport.DecodeResponse(target, res); err != nil {
22524		return nil, err
22525	}
22526	return ret, nil
22527	// {
22528	//   "description": "Returns the list of all intents in the specified agent.",
22529	//   "flatPath": "v2/projects/{projectsId}/agent/environments/{environmentsId}/intents",
22530	//   "httpMethod": "GET",
22531	//   "id": "dialogflow.projects.agent.environments.intents.list",
22532	//   "parameterOrder": [
22533	//     "parent"
22534	//   ],
22535	//   "parameters": {
22536	//     "intentView": {
22537	//       "description": "Optional. The resource view to apply to the returned intent.",
22538	//       "enum": [
22539	//         "INTENT_VIEW_UNSPECIFIED",
22540	//         "INTENT_VIEW_FULL"
22541	//       ],
22542	//       "enumDescriptions": [
22543	//         "Training phrases field is not populated in the response.",
22544	//         "All fields are populated."
22545	//       ],
22546	//       "location": "query",
22547	//       "type": "string"
22548	//     },
22549	//     "languageCode": {
22550	//       "description": "Optional. The language used to access language-specific data. If not specified, the agent's default language is used. For more information, see [Multilingual intent and entity data](https://cloud.google.com/dialogflow/docs/agents-multilingual#intent-entity).",
22551	//       "location": "query",
22552	//       "type": "string"
22553	//     },
22554	//     "pageSize": {
22555	//       "description": "Optional. The maximum number of items to return in a single page. By default 100 and at most 1000.",
22556	//       "format": "int32",
22557	//       "location": "query",
22558	//       "type": "integer"
22559	//     },
22560	//     "pageToken": {
22561	//       "description": "Optional. The next_page_token value returned from a previous list request.",
22562	//       "location": "query",
22563	//       "type": "string"
22564	//     },
22565	//     "parent": {
22566	//       "description": "Required. The agent to list all intents from. Format: `projects//agent` or `projects//locations//agent`. Alternatively, you can specify the environment to list intents for. Format: `projects//agent/environments/` or `projects//locations//agent/environments/`. Note: training phrases of the intents will not be returned for non-draft environment.",
22567	//       "location": "path",
22568	//       "pattern": "^projects/[^/]+/agent/environments/[^/]+$",
22569	//       "required": true,
22570	//       "type": "string"
22571	//     }
22572	//   },
22573	//   "path": "v2/{+parent}/intents",
22574	//   "response": {
22575	//     "$ref": "GoogleCloudDialogflowV2ListIntentsResponse"
22576	//   },
22577	//   "scopes": [
22578	//     "https://www.googleapis.com/auth/cloud-platform",
22579	//     "https://www.googleapis.com/auth/dialogflow"
22580	//   ]
22581	// }
22582
22583}
22584
22585// Pages invokes f for each page of results.
22586// A non-nil error returned from f will halt the iteration.
22587// The provided context supersedes any context provided to the Context method.
22588func (c *ProjectsAgentEnvironmentsIntentsListCall) Pages(ctx context.Context, f func(*GoogleCloudDialogflowV2ListIntentsResponse) error) error {
22589	c.ctx_ = ctx
22590	defer c.PageToken(c.urlParams_.Get("pageToken")) // reset paging to original point
22591	for {
22592		x, err := c.Do()
22593		if err != nil {
22594			return err
22595		}
22596		if err := f(x); err != nil {
22597			return err
22598		}
22599		if x.NextPageToken == "" {
22600			return nil
22601		}
22602		c.PageToken(x.NextPageToken)
22603	}
22604}
22605
22606// method id "dialogflow.projects.agent.environments.users.sessions.deleteContexts":
22607
22608type ProjectsAgentEnvironmentsUsersSessionsDeleteContextsCall struct {
22609	s          *Service
22610	parent     string
22611	urlParams_ gensupport.URLParams
22612	ctx_       context.Context
22613	header_    http.Header
22614}
22615
22616// DeleteContexts: Deletes all active contexts in the specified session.
22617//
22618// - parent: The name of the session to delete all contexts from.
22619//   Format: `projects//agent/sessions/` or
22620//   `projects//agent/environments//users//sessions/`. If `Environment
22621//   ID` is not specified we assume default 'draft' environment. If
22622//   `User ID` is not specified, we assume default '-' user.
22623func (r *ProjectsAgentEnvironmentsUsersSessionsService) DeleteContexts(parent string) *ProjectsAgentEnvironmentsUsersSessionsDeleteContextsCall {
22624	c := &ProjectsAgentEnvironmentsUsersSessionsDeleteContextsCall{s: r.s, urlParams_: make(gensupport.URLParams)}
22625	c.parent = parent
22626	return c
22627}
22628
22629// Fields allows partial responses to be retrieved. See
22630// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
22631// for more information.
22632func (c *ProjectsAgentEnvironmentsUsersSessionsDeleteContextsCall) Fields(s ...googleapi.Field) *ProjectsAgentEnvironmentsUsersSessionsDeleteContextsCall {
22633	c.urlParams_.Set("fields", googleapi.CombineFields(s))
22634	return c
22635}
22636
22637// Context sets the context to be used in this call's Do method. Any
22638// pending HTTP request will be aborted if the provided context is
22639// canceled.
22640func (c *ProjectsAgentEnvironmentsUsersSessionsDeleteContextsCall) Context(ctx context.Context) *ProjectsAgentEnvironmentsUsersSessionsDeleteContextsCall {
22641	c.ctx_ = ctx
22642	return c
22643}
22644
22645// Header returns an http.Header that can be modified by the caller to
22646// add HTTP headers to the request.
22647func (c *ProjectsAgentEnvironmentsUsersSessionsDeleteContextsCall) Header() http.Header {
22648	if c.header_ == nil {
22649		c.header_ = make(http.Header)
22650	}
22651	return c.header_
22652}
22653
22654func (c *ProjectsAgentEnvironmentsUsersSessionsDeleteContextsCall) doRequest(alt string) (*http.Response, error) {
22655	reqHeaders := make(http.Header)
22656	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20211027")
22657	for k, v := range c.header_ {
22658		reqHeaders[k] = v
22659	}
22660	reqHeaders.Set("User-Agent", c.s.userAgent())
22661	var body io.Reader = nil
22662	c.urlParams_.Set("alt", alt)
22663	c.urlParams_.Set("prettyPrint", "false")
22664	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+parent}/contexts")
22665	urls += "?" + c.urlParams_.Encode()
22666	req, err := http.NewRequest("DELETE", urls, body)
22667	if err != nil {
22668		return nil, err
22669	}
22670	req.Header = reqHeaders
22671	googleapi.Expand(req.URL, map[string]string{
22672		"parent": c.parent,
22673	})
22674	return gensupport.SendRequest(c.ctx_, c.s.client, req)
22675}
22676
22677// Do executes the "dialogflow.projects.agent.environments.users.sessions.deleteContexts" call.
22678// Exactly one of *GoogleProtobufEmpty or error will be non-nil. Any
22679// non-2xx status code is an error. Response headers are in either
22680// *GoogleProtobufEmpty.ServerResponse.Header or (if a response was
22681// returned at all) in error.(*googleapi.Error).Header. Use
22682// googleapi.IsNotModified to check whether the returned error was
22683// because http.StatusNotModified was returned.
22684func (c *ProjectsAgentEnvironmentsUsersSessionsDeleteContextsCall) Do(opts ...googleapi.CallOption) (*GoogleProtobufEmpty, error) {
22685	gensupport.SetOptions(c.urlParams_, opts...)
22686	res, err := c.doRequest("json")
22687	if res != nil && res.StatusCode == http.StatusNotModified {
22688		if res.Body != nil {
22689			res.Body.Close()
22690		}
22691		return nil, &googleapi.Error{
22692			Code:   res.StatusCode,
22693			Header: res.Header,
22694		}
22695	}
22696	if err != nil {
22697		return nil, err
22698	}
22699	defer googleapi.CloseBody(res)
22700	if err := googleapi.CheckResponse(res); err != nil {
22701		return nil, err
22702	}
22703	ret := &GoogleProtobufEmpty{
22704		ServerResponse: googleapi.ServerResponse{
22705			Header:         res.Header,
22706			HTTPStatusCode: res.StatusCode,
22707		},
22708	}
22709	target := &ret
22710	if err := gensupport.DecodeResponse(target, res); err != nil {
22711		return nil, err
22712	}
22713	return ret, nil
22714	// {
22715	//   "description": "Deletes all active contexts in the specified session.",
22716	//   "flatPath": "v2/projects/{projectsId}/agent/environments/{environmentsId}/users/{usersId}/sessions/{sessionsId}/contexts",
22717	//   "httpMethod": "DELETE",
22718	//   "id": "dialogflow.projects.agent.environments.users.sessions.deleteContexts",
22719	//   "parameterOrder": [
22720	//     "parent"
22721	//   ],
22722	//   "parameters": {
22723	//     "parent": {
22724	//       "description": "Required. The name of the session to delete all contexts from. Format: `projects//agent/sessions/` or `projects//agent/environments//users//sessions/`. If `Environment ID` is not specified we assume default 'draft' environment. If `User ID` is not specified, we assume default '-' user.",
22725	//       "location": "path",
22726	//       "pattern": "^projects/[^/]+/agent/environments/[^/]+/users/[^/]+/sessions/[^/]+$",
22727	//       "required": true,
22728	//       "type": "string"
22729	//     }
22730	//   },
22731	//   "path": "v2/{+parent}/contexts",
22732	//   "response": {
22733	//     "$ref": "GoogleProtobufEmpty"
22734	//   },
22735	//   "scopes": [
22736	//     "https://www.googleapis.com/auth/cloud-platform",
22737	//     "https://www.googleapis.com/auth/dialogflow"
22738	//   ]
22739	// }
22740
22741}
22742
22743// method id "dialogflow.projects.agent.environments.users.sessions.detectIntent":
22744
22745type ProjectsAgentEnvironmentsUsersSessionsDetectIntentCall struct {
22746	s                                          *Service
22747	sessionid                                  string
22748	googleclouddialogflowv2detectintentrequest *GoogleCloudDialogflowV2DetectIntentRequest
22749	urlParams_                                 gensupport.URLParams
22750	ctx_                                       context.Context
22751	header_                                    http.Header
22752}
22753
22754// DetectIntent: Processes a natural language query and returns
22755// structured, actionable data as a result. This method is not
22756// idempotent, because it may cause contexts and session entity types to
22757// be updated, which in turn might affect results of future queries. If
22758// you might use Agent Assist
22759// (https://cloud.google.com/dialogflow/docs/#aa) or other CCAI products
22760// now or in the future, consider using AnalyzeContent instead of
22761// `DetectIntent`. `AnalyzeContent` has additional functionality for
22762// Agent Assist and other CCAI products. Note: Always use agent versions
22763// for production traffic. See Versions and environments
22764// (https://cloud.google.com/dialogflow/es/docs/agents-versions).
22765//
22766// - session: The name of the session this query is sent to. Format:
22767//   `projects//agent/sessions/`, or
22768//   `projects//agent/environments//users//sessions/`. If `Environment
22769//   ID` is not specified, we assume default 'draft' environment
22770//   (`Environment ID` might be referred to as environment name at some
22771//   places). If `User ID` is not specified, we are using "-". It's up
22772//   to the API caller to choose an appropriate `Session ID` and `User
22773//   Id`. They can be a random number or some type of user and session
22774//   identifiers (preferably hashed). The length of the `Session ID` and
22775//   `User ID` must not exceed 36 characters. For more information, see
22776//   the API interactions guide
22777//   (https://cloud.google.com/dialogflow/docs/api-overview). Note:
22778//   Always use agent versions for production traffic. See Versions and
22779//   environments
22780//   (https://cloud.google.com/dialogflow/es/docs/agents-versions).
22781func (r *ProjectsAgentEnvironmentsUsersSessionsService) DetectIntent(sessionid string, googleclouddialogflowv2detectintentrequest *GoogleCloudDialogflowV2DetectIntentRequest) *ProjectsAgentEnvironmentsUsersSessionsDetectIntentCall {
22782	c := &ProjectsAgentEnvironmentsUsersSessionsDetectIntentCall{s: r.s, urlParams_: make(gensupport.URLParams)}
22783	c.sessionid = sessionid
22784	c.googleclouddialogflowv2detectintentrequest = googleclouddialogflowv2detectintentrequest
22785	return c
22786}
22787
22788// Fields allows partial responses to be retrieved. See
22789// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
22790// for more information.
22791func (c *ProjectsAgentEnvironmentsUsersSessionsDetectIntentCall) Fields(s ...googleapi.Field) *ProjectsAgentEnvironmentsUsersSessionsDetectIntentCall {
22792	c.urlParams_.Set("fields", googleapi.CombineFields(s))
22793	return c
22794}
22795
22796// Context sets the context to be used in this call's Do method. Any
22797// pending HTTP request will be aborted if the provided context is
22798// canceled.
22799func (c *ProjectsAgentEnvironmentsUsersSessionsDetectIntentCall) Context(ctx context.Context) *ProjectsAgentEnvironmentsUsersSessionsDetectIntentCall {
22800	c.ctx_ = ctx
22801	return c
22802}
22803
22804// Header returns an http.Header that can be modified by the caller to
22805// add HTTP headers to the request.
22806func (c *ProjectsAgentEnvironmentsUsersSessionsDetectIntentCall) Header() http.Header {
22807	if c.header_ == nil {
22808		c.header_ = make(http.Header)
22809	}
22810	return c.header_
22811}
22812
22813func (c *ProjectsAgentEnvironmentsUsersSessionsDetectIntentCall) doRequest(alt string) (*http.Response, error) {
22814	reqHeaders := make(http.Header)
22815	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20211027")
22816	for k, v := range c.header_ {
22817		reqHeaders[k] = v
22818	}
22819	reqHeaders.Set("User-Agent", c.s.userAgent())
22820	var body io.Reader = nil
22821	body, err := googleapi.WithoutDataWrapper.JSONReader(c.googleclouddialogflowv2detectintentrequest)
22822	if err != nil {
22823		return nil, err
22824	}
22825	reqHeaders.Set("Content-Type", "application/json")
22826	c.urlParams_.Set("alt", alt)
22827	c.urlParams_.Set("prettyPrint", "false")
22828	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+session}:detectIntent")
22829	urls += "?" + c.urlParams_.Encode()
22830	req, err := http.NewRequest("POST", urls, body)
22831	if err != nil {
22832		return nil, err
22833	}
22834	req.Header = reqHeaders
22835	googleapi.Expand(req.URL, map[string]string{
22836		"session": c.sessionid,
22837	})
22838	return gensupport.SendRequest(c.ctx_, c.s.client, req)
22839}
22840
22841// Do executes the "dialogflow.projects.agent.environments.users.sessions.detectIntent" call.
22842// Exactly one of *GoogleCloudDialogflowV2DetectIntentResponse or error
22843// will be non-nil. Any non-2xx status code is an error. Response
22844// headers are in either
22845// *GoogleCloudDialogflowV2DetectIntentResponse.ServerResponse.Header or
22846// (if a response was returned at all) in
22847// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
22848// whether the returned error was because http.StatusNotModified was
22849// returned.
22850func (c *ProjectsAgentEnvironmentsUsersSessionsDetectIntentCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDialogflowV2DetectIntentResponse, error) {
22851	gensupport.SetOptions(c.urlParams_, opts...)
22852	res, err := c.doRequest("json")
22853	if res != nil && res.StatusCode == http.StatusNotModified {
22854		if res.Body != nil {
22855			res.Body.Close()
22856		}
22857		return nil, &googleapi.Error{
22858			Code:   res.StatusCode,
22859			Header: res.Header,
22860		}
22861	}
22862	if err != nil {
22863		return nil, err
22864	}
22865	defer googleapi.CloseBody(res)
22866	if err := googleapi.CheckResponse(res); err != nil {
22867		return nil, err
22868	}
22869	ret := &GoogleCloudDialogflowV2DetectIntentResponse{
22870		ServerResponse: googleapi.ServerResponse{
22871			Header:         res.Header,
22872			HTTPStatusCode: res.StatusCode,
22873		},
22874	}
22875	target := &ret
22876	if err := gensupport.DecodeResponse(target, res); err != nil {
22877		return nil, err
22878	}
22879	return ret, nil
22880	// {
22881	//   "description": "Processes a natural language query and returns structured, actionable data as a result. This method is not idempotent, because it may cause contexts and session entity types to be updated, which in turn might affect results of future queries. If you might use [Agent Assist](https://cloud.google.com/dialogflow/docs/#aa) or other CCAI products now or in the future, consider using AnalyzeContent instead of `DetectIntent`. `AnalyzeContent` has additional functionality for Agent Assist and other CCAI products. Note: Always use agent versions for production traffic. See [Versions and environments](https://cloud.google.com/dialogflow/es/docs/agents-versions).",
22882	//   "flatPath": "v2/projects/{projectsId}/agent/environments/{environmentsId}/users/{usersId}/sessions/{sessionsId}:detectIntent",
22883	//   "httpMethod": "POST",
22884	//   "id": "dialogflow.projects.agent.environments.users.sessions.detectIntent",
22885	//   "parameterOrder": [
22886	//     "session"
22887	//   ],
22888	//   "parameters": {
22889	//     "session": {
22890	//       "description": "Required. The name of the session this query is sent to. Format: `projects//agent/sessions/`, or `projects//agent/environments//users//sessions/`. If `Environment ID` is not specified, we assume default 'draft' environment (`Environment ID` might be referred to as environment name at some places). If `User ID` is not specified, we are using \"-\". It's up to the API caller to choose an appropriate `Session ID` and `User Id`. They can be a random number or some type of user and session identifiers (preferably hashed). The length of the `Session ID` and `User ID` must not exceed 36 characters. For more information, see the [API interactions guide](https://cloud.google.com/dialogflow/docs/api-overview). Note: Always use agent versions for production traffic. See [Versions and environments](https://cloud.google.com/dialogflow/es/docs/agents-versions).",
22891	//       "location": "path",
22892	//       "pattern": "^projects/[^/]+/agent/environments/[^/]+/users/[^/]+/sessions/[^/]+$",
22893	//       "required": true,
22894	//       "type": "string"
22895	//     }
22896	//   },
22897	//   "path": "v2/{+session}:detectIntent",
22898	//   "request": {
22899	//     "$ref": "GoogleCloudDialogflowV2DetectIntentRequest"
22900	//   },
22901	//   "response": {
22902	//     "$ref": "GoogleCloudDialogflowV2DetectIntentResponse"
22903	//   },
22904	//   "scopes": [
22905	//     "https://www.googleapis.com/auth/cloud-platform",
22906	//     "https://www.googleapis.com/auth/dialogflow"
22907	//   ]
22908	// }
22909
22910}
22911
22912// method id "dialogflow.projects.agent.environments.users.sessions.contexts.create":
22913
22914type ProjectsAgentEnvironmentsUsersSessionsContextsCreateCall struct {
22915	s                              *Service
22916	parent                         string
22917	googleclouddialogflowv2context *GoogleCloudDialogflowV2Context
22918	urlParams_                     gensupport.URLParams
22919	ctx_                           context.Context
22920	header_                        http.Header
22921}
22922
22923// Create: Creates a context. If the specified context already exists,
22924// overrides the context.
22925//
22926// - parent: The session to create a context for. Format:
22927//   `projects//agent/sessions/` or
22928//   `projects//agent/environments//users//sessions/`. If `Environment
22929//   ID` is not specified, we assume default 'draft' environment. If
22930//   `User ID` is not specified, we assume default '-' user.
22931func (r *ProjectsAgentEnvironmentsUsersSessionsContextsService) Create(parent string, googleclouddialogflowv2context *GoogleCloudDialogflowV2Context) *ProjectsAgentEnvironmentsUsersSessionsContextsCreateCall {
22932	c := &ProjectsAgentEnvironmentsUsersSessionsContextsCreateCall{s: r.s, urlParams_: make(gensupport.URLParams)}
22933	c.parent = parent
22934	c.googleclouddialogflowv2context = googleclouddialogflowv2context
22935	return c
22936}
22937
22938// Fields allows partial responses to be retrieved. See
22939// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
22940// for more information.
22941func (c *ProjectsAgentEnvironmentsUsersSessionsContextsCreateCall) Fields(s ...googleapi.Field) *ProjectsAgentEnvironmentsUsersSessionsContextsCreateCall {
22942	c.urlParams_.Set("fields", googleapi.CombineFields(s))
22943	return c
22944}
22945
22946// Context sets the context to be used in this call's Do method. Any
22947// pending HTTP request will be aborted if the provided context is
22948// canceled.
22949func (c *ProjectsAgentEnvironmentsUsersSessionsContextsCreateCall) Context(ctx context.Context) *ProjectsAgentEnvironmentsUsersSessionsContextsCreateCall {
22950	c.ctx_ = ctx
22951	return c
22952}
22953
22954// Header returns an http.Header that can be modified by the caller to
22955// add HTTP headers to the request.
22956func (c *ProjectsAgentEnvironmentsUsersSessionsContextsCreateCall) Header() http.Header {
22957	if c.header_ == nil {
22958		c.header_ = make(http.Header)
22959	}
22960	return c.header_
22961}
22962
22963func (c *ProjectsAgentEnvironmentsUsersSessionsContextsCreateCall) doRequest(alt string) (*http.Response, error) {
22964	reqHeaders := make(http.Header)
22965	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20211027")
22966	for k, v := range c.header_ {
22967		reqHeaders[k] = v
22968	}
22969	reqHeaders.Set("User-Agent", c.s.userAgent())
22970	var body io.Reader = nil
22971	body, err := googleapi.WithoutDataWrapper.JSONReader(c.googleclouddialogflowv2context)
22972	if err != nil {
22973		return nil, err
22974	}
22975	reqHeaders.Set("Content-Type", "application/json")
22976	c.urlParams_.Set("alt", alt)
22977	c.urlParams_.Set("prettyPrint", "false")
22978	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+parent}/contexts")
22979	urls += "?" + c.urlParams_.Encode()
22980	req, err := http.NewRequest("POST", urls, body)
22981	if err != nil {
22982		return nil, err
22983	}
22984	req.Header = reqHeaders
22985	googleapi.Expand(req.URL, map[string]string{
22986		"parent": c.parent,
22987	})
22988	return gensupport.SendRequest(c.ctx_, c.s.client, req)
22989}
22990
22991// Do executes the "dialogflow.projects.agent.environments.users.sessions.contexts.create" call.
22992// Exactly one of *GoogleCloudDialogflowV2Context or error will be
22993// non-nil. Any non-2xx status code is an error. Response headers are in
22994// either *GoogleCloudDialogflowV2Context.ServerResponse.Header or (if a
22995// response was returned at all) in error.(*googleapi.Error).Header. Use
22996// googleapi.IsNotModified to check whether the returned error was
22997// because http.StatusNotModified was returned.
22998func (c *ProjectsAgentEnvironmentsUsersSessionsContextsCreateCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDialogflowV2Context, error) {
22999	gensupport.SetOptions(c.urlParams_, opts...)
23000	res, err := c.doRequest("json")
23001	if res != nil && res.StatusCode == http.StatusNotModified {
23002		if res.Body != nil {
23003			res.Body.Close()
23004		}
23005		return nil, &googleapi.Error{
23006			Code:   res.StatusCode,
23007			Header: res.Header,
23008		}
23009	}
23010	if err != nil {
23011		return nil, err
23012	}
23013	defer googleapi.CloseBody(res)
23014	if err := googleapi.CheckResponse(res); err != nil {
23015		return nil, err
23016	}
23017	ret := &GoogleCloudDialogflowV2Context{
23018		ServerResponse: googleapi.ServerResponse{
23019			Header:         res.Header,
23020			HTTPStatusCode: res.StatusCode,
23021		},
23022	}
23023	target := &ret
23024	if err := gensupport.DecodeResponse(target, res); err != nil {
23025		return nil, err
23026	}
23027	return ret, nil
23028	// {
23029	//   "description": "Creates a context. If the specified context already exists, overrides the context.",
23030	//   "flatPath": "v2/projects/{projectsId}/agent/environments/{environmentsId}/users/{usersId}/sessions/{sessionsId}/contexts",
23031	//   "httpMethod": "POST",
23032	//   "id": "dialogflow.projects.agent.environments.users.sessions.contexts.create",
23033	//   "parameterOrder": [
23034	//     "parent"
23035	//   ],
23036	//   "parameters": {
23037	//     "parent": {
23038	//       "description": "Required. The session to create a context for. Format: `projects//agent/sessions/` or `projects//agent/environments//users//sessions/`. If `Environment ID` is not specified, we assume default 'draft' environment. If `User ID` is not specified, we assume default '-' user.",
23039	//       "location": "path",
23040	//       "pattern": "^projects/[^/]+/agent/environments/[^/]+/users/[^/]+/sessions/[^/]+$",
23041	//       "required": true,
23042	//       "type": "string"
23043	//     }
23044	//   },
23045	//   "path": "v2/{+parent}/contexts",
23046	//   "request": {
23047	//     "$ref": "GoogleCloudDialogflowV2Context"
23048	//   },
23049	//   "response": {
23050	//     "$ref": "GoogleCloudDialogflowV2Context"
23051	//   },
23052	//   "scopes": [
23053	//     "https://www.googleapis.com/auth/cloud-platform",
23054	//     "https://www.googleapis.com/auth/dialogflow"
23055	//   ]
23056	// }
23057
23058}
23059
23060// method id "dialogflow.projects.agent.environments.users.sessions.contexts.delete":
23061
23062type ProjectsAgentEnvironmentsUsersSessionsContextsDeleteCall struct {
23063	s          *Service
23064	name       string
23065	urlParams_ gensupport.URLParams
23066	ctx_       context.Context
23067	header_    http.Header
23068}
23069
23070// Delete: Deletes the specified context.
23071//
23072// - name: The name of the context to delete. Format:
23073//   `projects//agent/sessions//contexts/` or
23074//   `projects//agent/environments//users//sessions//contexts/`. If
23075//   `Environment ID` is not specified, we assume default 'draft'
23076//   environment. If `User ID` is not specified, we assume default '-'
23077//   user.
23078func (r *ProjectsAgentEnvironmentsUsersSessionsContextsService) Delete(name string) *ProjectsAgentEnvironmentsUsersSessionsContextsDeleteCall {
23079	c := &ProjectsAgentEnvironmentsUsersSessionsContextsDeleteCall{s: r.s, urlParams_: make(gensupport.URLParams)}
23080	c.name = name
23081	return c
23082}
23083
23084// Fields allows partial responses to be retrieved. See
23085// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
23086// for more information.
23087func (c *ProjectsAgentEnvironmentsUsersSessionsContextsDeleteCall) Fields(s ...googleapi.Field) *ProjectsAgentEnvironmentsUsersSessionsContextsDeleteCall {
23088	c.urlParams_.Set("fields", googleapi.CombineFields(s))
23089	return c
23090}
23091
23092// Context sets the context to be used in this call's Do method. Any
23093// pending HTTP request will be aborted if the provided context is
23094// canceled.
23095func (c *ProjectsAgentEnvironmentsUsersSessionsContextsDeleteCall) Context(ctx context.Context) *ProjectsAgentEnvironmentsUsersSessionsContextsDeleteCall {
23096	c.ctx_ = ctx
23097	return c
23098}
23099
23100// Header returns an http.Header that can be modified by the caller to
23101// add HTTP headers to the request.
23102func (c *ProjectsAgentEnvironmentsUsersSessionsContextsDeleteCall) Header() http.Header {
23103	if c.header_ == nil {
23104		c.header_ = make(http.Header)
23105	}
23106	return c.header_
23107}
23108
23109func (c *ProjectsAgentEnvironmentsUsersSessionsContextsDeleteCall) doRequest(alt string) (*http.Response, error) {
23110	reqHeaders := make(http.Header)
23111	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20211027")
23112	for k, v := range c.header_ {
23113		reqHeaders[k] = v
23114	}
23115	reqHeaders.Set("User-Agent", c.s.userAgent())
23116	var body io.Reader = nil
23117	c.urlParams_.Set("alt", alt)
23118	c.urlParams_.Set("prettyPrint", "false")
23119	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+name}")
23120	urls += "?" + c.urlParams_.Encode()
23121	req, err := http.NewRequest("DELETE", urls, body)
23122	if err != nil {
23123		return nil, err
23124	}
23125	req.Header = reqHeaders
23126	googleapi.Expand(req.URL, map[string]string{
23127		"name": c.name,
23128	})
23129	return gensupport.SendRequest(c.ctx_, c.s.client, req)
23130}
23131
23132// Do executes the "dialogflow.projects.agent.environments.users.sessions.contexts.delete" call.
23133// Exactly one of *GoogleProtobufEmpty or error will be non-nil. Any
23134// non-2xx status code is an error. Response headers are in either
23135// *GoogleProtobufEmpty.ServerResponse.Header or (if a response was
23136// returned at all) in error.(*googleapi.Error).Header. Use
23137// googleapi.IsNotModified to check whether the returned error was
23138// because http.StatusNotModified was returned.
23139func (c *ProjectsAgentEnvironmentsUsersSessionsContextsDeleteCall) Do(opts ...googleapi.CallOption) (*GoogleProtobufEmpty, error) {
23140	gensupport.SetOptions(c.urlParams_, opts...)
23141	res, err := c.doRequest("json")
23142	if res != nil && res.StatusCode == http.StatusNotModified {
23143		if res.Body != nil {
23144			res.Body.Close()
23145		}
23146		return nil, &googleapi.Error{
23147			Code:   res.StatusCode,
23148			Header: res.Header,
23149		}
23150	}
23151	if err != nil {
23152		return nil, err
23153	}
23154	defer googleapi.CloseBody(res)
23155	if err := googleapi.CheckResponse(res); err != nil {
23156		return nil, err
23157	}
23158	ret := &GoogleProtobufEmpty{
23159		ServerResponse: googleapi.ServerResponse{
23160			Header:         res.Header,
23161			HTTPStatusCode: res.StatusCode,
23162		},
23163	}
23164	target := &ret
23165	if err := gensupport.DecodeResponse(target, res); err != nil {
23166		return nil, err
23167	}
23168	return ret, nil
23169	// {
23170	//   "description": "Deletes the specified context.",
23171	//   "flatPath": "v2/projects/{projectsId}/agent/environments/{environmentsId}/users/{usersId}/sessions/{sessionsId}/contexts/{contextsId}",
23172	//   "httpMethod": "DELETE",
23173	//   "id": "dialogflow.projects.agent.environments.users.sessions.contexts.delete",
23174	//   "parameterOrder": [
23175	//     "name"
23176	//   ],
23177	//   "parameters": {
23178	//     "name": {
23179	//       "description": "Required. The name of the context to delete. Format: `projects//agent/sessions//contexts/` or `projects//agent/environments//users//sessions//contexts/`. If `Environment ID` is not specified, we assume default 'draft' environment. If `User ID` is not specified, we assume default '-' user.",
23180	//       "location": "path",
23181	//       "pattern": "^projects/[^/]+/agent/environments/[^/]+/users/[^/]+/sessions/[^/]+/contexts/[^/]+$",
23182	//       "required": true,
23183	//       "type": "string"
23184	//     }
23185	//   },
23186	//   "path": "v2/{+name}",
23187	//   "response": {
23188	//     "$ref": "GoogleProtobufEmpty"
23189	//   },
23190	//   "scopes": [
23191	//     "https://www.googleapis.com/auth/cloud-platform",
23192	//     "https://www.googleapis.com/auth/dialogflow"
23193	//   ]
23194	// }
23195
23196}
23197
23198// method id "dialogflow.projects.agent.environments.users.sessions.contexts.get":
23199
23200type ProjectsAgentEnvironmentsUsersSessionsContextsGetCall struct {
23201	s            *Service
23202	name         string
23203	urlParams_   gensupport.URLParams
23204	ifNoneMatch_ string
23205	ctx_         context.Context
23206	header_      http.Header
23207}
23208
23209// Get: Retrieves the specified context.
23210//
23211// - name: The name of the context. Format:
23212//   `projects//agent/sessions//contexts/` or
23213//   `projects//agent/environments//users//sessions//contexts/`. If
23214//   `Environment ID` is not specified, we assume default 'draft'
23215//   environment. If `User ID` is not specified, we assume default '-'
23216//   user.
23217func (r *ProjectsAgentEnvironmentsUsersSessionsContextsService) Get(name string) *ProjectsAgentEnvironmentsUsersSessionsContextsGetCall {
23218	c := &ProjectsAgentEnvironmentsUsersSessionsContextsGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
23219	c.name = name
23220	return c
23221}
23222
23223// Fields allows partial responses to be retrieved. See
23224// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
23225// for more information.
23226func (c *ProjectsAgentEnvironmentsUsersSessionsContextsGetCall) Fields(s ...googleapi.Field) *ProjectsAgentEnvironmentsUsersSessionsContextsGetCall {
23227	c.urlParams_.Set("fields", googleapi.CombineFields(s))
23228	return c
23229}
23230
23231// IfNoneMatch sets the optional parameter which makes the operation
23232// fail if the object's ETag matches the given value. This is useful for
23233// getting updates only after the object has changed since the last
23234// request. Use googleapi.IsNotModified to check whether the response
23235// error from Do is the result of In-None-Match.
23236func (c *ProjectsAgentEnvironmentsUsersSessionsContextsGetCall) IfNoneMatch(entityTag string) *ProjectsAgentEnvironmentsUsersSessionsContextsGetCall {
23237	c.ifNoneMatch_ = entityTag
23238	return c
23239}
23240
23241// Context sets the context to be used in this call's Do method. Any
23242// pending HTTP request will be aborted if the provided context is
23243// canceled.
23244func (c *ProjectsAgentEnvironmentsUsersSessionsContextsGetCall) Context(ctx context.Context) *ProjectsAgentEnvironmentsUsersSessionsContextsGetCall {
23245	c.ctx_ = ctx
23246	return c
23247}
23248
23249// Header returns an http.Header that can be modified by the caller to
23250// add HTTP headers to the request.
23251func (c *ProjectsAgentEnvironmentsUsersSessionsContextsGetCall) Header() http.Header {
23252	if c.header_ == nil {
23253		c.header_ = make(http.Header)
23254	}
23255	return c.header_
23256}
23257
23258func (c *ProjectsAgentEnvironmentsUsersSessionsContextsGetCall) doRequest(alt string) (*http.Response, error) {
23259	reqHeaders := make(http.Header)
23260	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20211027")
23261	for k, v := range c.header_ {
23262		reqHeaders[k] = v
23263	}
23264	reqHeaders.Set("User-Agent", c.s.userAgent())
23265	if c.ifNoneMatch_ != "" {
23266		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
23267	}
23268	var body io.Reader = nil
23269	c.urlParams_.Set("alt", alt)
23270	c.urlParams_.Set("prettyPrint", "false")
23271	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+name}")
23272	urls += "?" + c.urlParams_.Encode()
23273	req, err := http.NewRequest("GET", urls, body)
23274	if err != nil {
23275		return nil, err
23276	}
23277	req.Header = reqHeaders
23278	googleapi.Expand(req.URL, map[string]string{
23279		"name": c.name,
23280	})
23281	return gensupport.SendRequest(c.ctx_, c.s.client, req)
23282}
23283
23284// Do executes the "dialogflow.projects.agent.environments.users.sessions.contexts.get" call.
23285// Exactly one of *GoogleCloudDialogflowV2Context or error will be
23286// non-nil. Any non-2xx status code is an error. Response headers are in
23287// either *GoogleCloudDialogflowV2Context.ServerResponse.Header or (if a
23288// response was returned at all) in error.(*googleapi.Error).Header. Use
23289// googleapi.IsNotModified to check whether the returned error was
23290// because http.StatusNotModified was returned.
23291func (c *ProjectsAgentEnvironmentsUsersSessionsContextsGetCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDialogflowV2Context, error) {
23292	gensupport.SetOptions(c.urlParams_, opts...)
23293	res, err := c.doRequest("json")
23294	if res != nil && res.StatusCode == http.StatusNotModified {
23295		if res.Body != nil {
23296			res.Body.Close()
23297		}
23298		return nil, &googleapi.Error{
23299			Code:   res.StatusCode,
23300			Header: res.Header,
23301		}
23302	}
23303	if err != nil {
23304		return nil, err
23305	}
23306	defer googleapi.CloseBody(res)
23307	if err := googleapi.CheckResponse(res); err != nil {
23308		return nil, err
23309	}
23310	ret := &GoogleCloudDialogflowV2Context{
23311		ServerResponse: googleapi.ServerResponse{
23312			Header:         res.Header,
23313			HTTPStatusCode: res.StatusCode,
23314		},
23315	}
23316	target := &ret
23317	if err := gensupport.DecodeResponse(target, res); err != nil {
23318		return nil, err
23319	}
23320	return ret, nil
23321	// {
23322	//   "description": "Retrieves the specified context.",
23323	//   "flatPath": "v2/projects/{projectsId}/agent/environments/{environmentsId}/users/{usersId}/sessions/{sessionsId}/contexts/{contextsId}",
23324	//   "httpMethod": "GET",
23325	//   "id": "dialogflow.projects.agent.environments.users.sessions.contexts.get",
23326	//   "parameterOrder": [
23327	//     "name"
23328	//   ],
23329	//   "parameters": {
23330	//     "name": {
23331	//       "description": "Required. The name of the context. Format: `projects//agent/sessions//contexts/` or `projects//agent/environments//users//sessions//contexts/`. If `Environment ID` is not specified, we assume default 'draft' environment. If `User ID` is not specified, we assume default '-' user.",
23332	//       "location": "path",
23333	//       "pattern": "^projects/[^/]+/agent/environments/[^/]+/users/[^/]+/sessions/[^/]+/contexts/[^/]+$",
23334	//       "required": true,
23335	//       "type": "string"
23336	//     }
23337	//   },
23338	//   "path": "v2/{+name}",
23339	//   "response": {
23340	//     "$ref": "GoogleCloudDialogflowV2Context"
23341	//   },
23342	//   "scopes": [
23343	//     "https://www.googleapis.com/auth/cloud-platform",
23344	//     "https://www.googleapis.com/auth/dialogflow"
23345	//   ]
23346	// }
23347
23348}
23349
23350// method id "dialogflow.projects.agent.environments.users.sessions.contexts.list":
23351
23352type ProjectsAgentEnvironmentsUsersSessionsContextsListCall struct {
23353	s            *Service
23354	parent       string
23355	urlParams_   gensupport.URLParams
23356	ifNoneMatch_ string
23357	ctx_         context.Context
23358	header_      http.Header
23359}
23360
23361// List: Returns the list of all contexts in the specified session.
23362//
23363// - parent: The session to list all contexts from. Format:
23364//   `projects//agent/sessions/` or
23365//   `projects//agent/environments//users//sessions/`. If `Environment
23366//   ID` is not specified, we assume default 'draft' environment. If
23367//   `User ID` is not specified, we assume default '-' user.
23368func (r *ProjectsAgentEnvironmentsUsersSessionsContextsService) List(parent string) *ProjectsAgentEnvironmentsUsersSessionsContextsListCall {
23369	c := &ProjectsAgentEnvironmentsUsersSessionsContextsListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
23370	c.parent = parent
23371	return c
23372}
23373
23374// PageSize sets the optional parameter "pageSize": The maximum number
23375// of items to return in a single page. By default 100 and at most 1000.
23376func (c *ProjectsAgentEnvironmentsUsersSessionsContextsListCall) PageSize(pageSize int64) *ProjectsAgentEnvironmentsUsersSessionsContextsListCall {
23377	c.urlParams_.Set("pageSize", fmt.Sprint(pageSize))
23378	return c
23379}
23380
23381// PageToken sets the optional parameter "pageToken": The
23382// next_page_token value returned from a previous list request.
23383func (c *ProjectsAgentEnvironmentsUsersSessionsContextsListCall) PageToken(pageToken string) *ProjectsAgentEnvironmentsUsersSessionsContextsListCall {
23384	c.urlParams_.Set("pageToken", pageToken)
23385	return c
23386}
23387
23388// Fields allows partial responses to be retrieved. See
23389// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
23390// for more information.
23391func (c *ProjectsAgentEnvironmentsUsersSessionsContextsListCall) Fields(s ...googleapi.Field) *ProjectsAgentEnvironmentsUsersSessionsContextsListCall {
23392	c.urlParams_.Set("fields", googleapi.CombineFields(s))
23393	return c
23394}
23395
23396// IfNoneMatch sets the optional parameter which makes the operation
23397// fail if the object's ETag matches the given value. This is useful for
23398// getting updates only after the object has changed since the last
23399// request. Use googleapi.IsNotModified to check whether the response
23400// error from Do is the result of In-None-Match.
23401func (c *ProjectsAgentEnvironmentsUsersSessionsContextsListCall) IfNoneMatch(entityTag string) *ProjectsAgentEnvironmentsUsersSessionsContextsListCall {
23402	c.ifNoneMatch_ = entityTag
23403	return c
23404}
23405
23406// Context sets the context to be used in this call's Do method. Any
23407// pending HTTP request will be aborted if the provided context is
23408// canceled.
23409func (c *ProjectsAgentEnvironmentsUsersSessionsContextsListCall) Context(ctx context.Context) *ProjectsAgentEnvironmentsUsersSessionsContextsListCall {
23410	c.ctx_ = ctx
23411	return c
23412}
23413
23414// Header returns an http.Header that can be modified by the caller to
23415// add HTTP headers to the request.
23416func (c *ProjectsAgentEnvironmentsUsersSessionsContextsListCall) Header() http.Header {
23417	if c.header_ == nil {
23418		c.header_ = make(http.Header)
23419	}
23420	return c.header_
23421}
23422
23423func (c *ProjectsAgentEnvironmentsUsersSessionsContextsListCall) doRequest(alt string) (*http.Response, error) {
23424	reqHeaders := make(http.Header)
23425	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20211027")
23426	for k, v := range c.header_ {
23427		reqHeaders[k] = v
23428	}
23429	reqHeaders.Set("User-Agent", c.s.userAgent())
23430	if c.ifNoneMatch_ != "" {
23431		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
23432	}
23433	var body io.Reader = nil
23434	c.urlParams_.Set("alt", alt)
23435	c.urlParams_.Set("prettyPrint", "false")
23436	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+parent}/contexts")
23437	urls += "?" + c.urlParams_.Encode()
23438	req, err := http.NewRequest("GET", urls, body)
23439	if err != nil {
23440		return nil, err
23441	}
23442	req.Header = reqHeaders
23443	googleapi.Expand(req.URL, map[string]string{
23444		"parent": c.parent,
23445	})
23446	return gensupport.SendRequest(c.ctx_, c.s.client, req)
23447}
23448
23449// Do executes the "dialogflow.projects.agent.environments.users.sessions.contexts.list" call.
23450// Exactly one of *GoogleCloudDialogflowV2ListContextsResponse or error
23451// will be non-nil. Any non-2xx status code is an error. Response
23452// headers are in either
23453// *GoogleCloudDialogflowV2ListContextsResponse.ServerResponse.Header or
23454// (if a response was returned at all) in
23455// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
23456// whether the returned error was because http.StatusNotModified was
23457// returned.
23458func (c *ProjectsAgentEnvironmentsUsersSessionsContextsListCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDialogflowV2ListContextsResponse, error) {
23459	gensupport.SetOptions(c.urlParams_, opts...)
23460	res, err := c.doRequest("json")
23461	if res != nil && res.StatusCode == http.StatusNotModified {
23462		if res.Body != nil {
23463			res.Body.Close()
23464		}
23465		return nil, &googleapi.Error{
23466			Code:   res.StatusCode,
23467			Header: res.Header,
23468		}
23469	}
23470	if err != nil {
23471		return nil, err
23472	}
23473	defer googleapi.CloseBody(res)
23474	if err := googleapi.CheckResponse(res); err != nil {
23475		return nil, err
23476	}
23477	ret := &GoogleCloudDialogflowV2ListContextsResponse{
23478		ServerResponse: googleapi.ServerResponse{
23479			Header:         res.Header,
23480			HTTPStatusCode: res.StatusCode,
23481		},
23482	}
23483	target := &ret
23484	if err := gensupport.DecodeResponse(target, res); err != nil {
23485		return nil, err
23486	}
23487	return ret, nil
23488	// {
23489	//   "description": "Returns the list of all contexts in the specified session.",
23490	//   "flatPath": "v2/projects/{projectsId}/agent/environments/{environmentsId}/users/{usersId}/sessions/{sessionsId}/contexts",
23491	//   "httpMethod": "GET",
23492	//   "id": "dialogflow.projects.agent.environments.users.sessions.contexts.list",
23493	//   "parameterOrder": [
23494	//     "parent"
23495	//   ],
23496	//   "parameters": {
23497	//     "pageSize": {
23498	//       "description": "Optional. The maximum number of items to return in a single page. By default 100 and at most 1000.",
23499	//       "format": "int32",
23500	//       "location": "query",
23501	//       "type": "integer"
23502	//     },
23503	//     "pageToken": {
23504	//       "description": "Optional. The next_page_token value returned from a previous list request.",
23505	//       "location": "query",
23506	//       "type": "string"
23507	//     },
23508	//     "parent": {
23509	//       "description": "Required. The session to list all contexts from. Format: `projects//agent/sessions/` or `projects//agent/environments//users//sessions/`. If `Environment ID` is not specified, we assume default 'draft' environment. If `User ID` is not specified, we assume default '-' user.",
23510	//       "location": "path",
23511	//       "pattern": "^projects/[^/]+/agent/environments/[^/]+/users/[^/]+/sessions/[^/]+$",
23512	//       "required": true,
23513	//       "type": "string"
23514	//     }
23515	//   },
23516	//   "path": "v2/{+parent}/contexts",
23517	//   "response": {
23518	//     "$ref": "GoogleCloudDialogflowV2ListContextsResponse"
23519	//   },
23520	//   "scopes": [
23521	//     "https://www.googleapis.com/auth/cloud-platform",
23522	//     "https://www.googleapis.com/auth/dialogflow"
23523	//   ]
23524	// }
23525
23526}
23527
23528// Pages invokes f for each page of results.
23529// A non-nil error returned from f will halt the iteration.
23530// The provided context supersedes any context provided to the Context method.
23531func (c *ProjectsAgentEnvironmentsUsersSessionsContextsListCall) Pages(ctx context.Context, f func(*GoogleCloudDialogflowV2ListContextsResponse) error) error {
23532	c.ctx_ = ctx
23533	defer c.PageToken(c.urlParams_.Get("pageToken")) // reset paging to original point
23534	for {
23535		x, err := c.Do()
23536		if err != nil {
23537			return err
23538		}
23539		if err := f(x); err != nil {
23540			return err
23541		}
23542		if x.NextPageToken == "" {
23543			return nil
23544		}
23545		c.PageToken(x.NextPageToken)
23546	}
23547}
23548
23549// method id "dialogflow.projects.agent.environments.users.sessions.contexts.patch":
23550
23551type ProjectsAgentEnvironmentsUsersSessionsContextsPatchCall struct {
23552	s                              *Service
23553	nameid                         string
23554	googleclouddialogflowv2context *GoogleCloudDialogflowV2Context
23555	urlParams_                     gensupport.URLParams
23556	ctx_                           context.Context
23557	header_                        http.Header
23558}
23559
23560// Patch: Updates the specified context.
23561//
23562// - name: The unique identifier of the context. Format:
23563//   `projects//agent/sessions//contexts/`, or
23564//   `projects//agent/environments//users//sessions//contexts/`. The
23565//   `Context ID` is always converted to lowercase, may only contain
23566//   characters in a-zA-Z0-9_-% and may be at most 250 bytes long. If
23567//   `Environment ID` is not specified, we assume default 'draft'
23568//   environment. If `User ID` is not specified, we assume default '-'
23569//   user. The following context names are reserved for internal use by
23570//   Dialogflow. You should not use these contexts or create contexts
23571//   with these names: * `__system_counters__` * `*_id_dialog_context` *
23572//   `*_dialog_params_size`.
23573func (r *ProjectsAgentEnvironmentsUsersSessionsContextsService) Patch(nameid string, googleclouddialogflowv2context *GoogleCloudDialogflowV2Context) *ProjectsAgentEnvironmentsUsersSessionsContextsPatchCall {
23574	c := &ProjectsAgentEnvironmentsUsersSessionsContextsPatchCall{s: r.s, urlParams_: make(gensupport.URLParams)}
23575	c.nameid = nameid
23576	c.googleclouddialogflowv2context = googleclouddialogflowv2context
23577	return c
23578}
23579
23580// UpdateMask sets the optional parameter "updateMask": The mask to
23581// control which fields get updated.
23582func (c *ProjectsAgentEnvironmentsUsersSessionsContextsPatchCall) UpdateMask(updateMask string) *ProjectsAgentEnvironmentsUsersSessionsContextsPatchCall {
23583	c.urlParams_.Set("updateMask", updateMask)
23584	return c
23585}
23586
23587// Fields allows partial responses to be retrieved. See
23588// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
23589// for more information.
23590func (c *ProjectsAgentEnvironmentsUsersSessionsContextsPatchCall) Fields(s ...googleapi.Field) *ProjectsAgentEnvironmentsUsersSessionsContextsPatchCall {
23591	c.urlParams_.Set("fields", googleapi.CombineFields(s))
23592	return c
23593}
23594
23595// Context sets the context to be used in this call's Do method. Any
23596// pending HTTP request will be aborted if the provided context is
23597// canceled.
23598func (c *ProjectsAgentEnvironmentsUsersSessionsContextsPatchCall) Context(ctx context.Context) *ProjectsAgentEnvironmentsUsersSessionsContextsPatchCall {
23599	c.ctx_ = ctx
23600	return c
23601}
23602
23603// Header returns an http.Header that can be modified by the caller to
23604// add HTTP headers to the request.
23605func (c *ProjectsAgentEnvironmentsUsersSessionsContextsPatchCall) Header() http.Header {
23606	if c.header_ == nil {
23607		c.header_ = make(http.Header)
23608	}
23609	return c.header_
23610}
23611
23612func (c *ProjectsAgentEnvironmentsUsersSessionsContextsPatchCall) doRequest(alt string) (*http.Response, error) {
23613	reqHeaders := make(http.Header)
23614	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20211027")
23615	for k, v := range c.header_ {
23616		reqHeaders[k] = v
23617	}
23618	reqHeaders.Set("User-Agent", c.s.userAgent())
23619	var body io.Reader = nil
23620	body, err := googleapi.WithoutDataWrapper.JSONReader(c.googleclouddialogflowv2context)
23621	if err != nil {
23622		return nil, err
23623	}
23624	reqHeaders.Set("Content-Type", "application/json")
23625	c.urlParams_.Set("alt", alt)
23626	c.urlParams_.Set("prettyPrint", "false")
23627	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+name}")
23628	urls += "?" + c.urlParams_.Encode()
23629	req, err := http.NewRequest("PATCH", urls, body)
23630	if err != nil {
23631		return nil, err
23632	}
23633	req.Header = reqHeaders
23634	googleapi.Expand(req.URL, map[string]string{
23635		"name": c.nameid,
23636	})
23637	return gensupport.SendRequest(c.ctx_, c.s.client, req)
23638}
23639
23640// Do executes the "dialogflow.projects.agent.environments.users.sessions.contexts.patch" call.
23641// Exactly one of *GoogleCloudDialogflowV2Context or error will be
23642// non-nil. Any non-2xx status code is an error. Response headers are in
23643// either *GoogleCloudDialogflowV2Context.ServerResponse.Header or (if a
23644// response was returned at all) in error.(*googleapi.Error).Header. Use
23645// googleapi.IsNotModified to check whether the returned error was
23646// because http.StatusNotModified was returned.
23647func (c *ProjectsAgentEnvironmentsUsersSessionsContextsPatchCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDialogflowV2Context, error) {
23648	gensupport.SetOptions(c.urlParams_, opts...)
23649	res, err := c.doRequest("json")
23650	if res != nil && res.StatusCode == http.StatusNotModified {
23651		if res.Body != nil {
23652			res.Body.Close()
23653		}
23654		return nil, &googleapi.Error{
23655			Code:   res.StatusCode,
23656			Header: res.Header,
23657		}
23658	}
23659	if err != nil {
23660		return nil, err
23661	}
23662	defer googleapi.CloseBody(res)
23663	if err := googleapi.CheckResponse(res); err != nil {
23664		return nil, err
23665	}
23666	ret := &GoogleCloudDialogflowV2Context{
23667		ServerResponse: googleapi.ServerResponse{
23668			Header:         res.Header,
23669			HTTPStatusCode: res.StatusCode,
23670		},
23671	}
23672	target := &ret
23673	if err := gensupport.DecodeResponse(target, res); err != nil {
23674		return nil, err
23675	}
23676	return ret, nil
23677	// {
23678	//   "description": "Updates the specified context.",
23679	//   "flatPath": "v2/projects/{projectsId}/agent/environments/{environmentsId}/users/{usersId}/sessions/{sessionsId}/contexts/{contextsId}",
23680	//   "httpMethod": "PATCH",
23681	//   "id": "dialogflow.projects.agent.environments.users.sessions.contexts.patch",
23682	//   "parameterOrder": [
23683	//     "name"
23684	//   ],
23685	//   "parameters": {
23686	//     "name": {
23687	//       "description": "Required. The unique identifier of the context. Format: `projects//agent/sessions//contexts/`, or `projects//agent/environments//users//sessions//contexts/`. The `Context ID` is always converted to lowercase, may only contain characters in a-zA-Z0-9_-% and may be at most 250 bytes long. If `Environment ID` is not specified, we assume default 'draft' environment. If `User ID` is not specified, we assume default '-' user. The following context names are reserved for internal use by Dialogflow. You should not use these contexts or create contexts with these names: * `__system_counters__` * `*_id_dialog_context` * `*_dialog_params_size`",
23688	//       "location": "path",
23689	//       "pattern": "^projects/[^/]+/agent/environments/[^/]+/users/[^/]+/sessions/[^/]+/contexts/[^/]+$",
23690	//       "required": true,
23691	//       "type": "string"
23692	//     },
23693	//     "updateMask": {
23694	//       "description": "Optional. The mask to control which fields get updated.",
23695	//       "format": "google-fieldmask",
23696	//       "location": "query",
23697	//       "type": "string"
23698	//     }
23699	//   },
23700	//   "path": "v2/{+name}",
23701	//   "request": {
23702	//     "$ref": "GoogleCloudDialogflowV2Context"
23703	//   },
23704	//   "response": {
23705	//     "$ref": "GoogleCloudDialogflowV2Context"
23706	//   },
23707	//   "scopes": [
23708	//     "https://www.googleapis.com/auth/cloud-platform",
23709	//     "https://www.googleapis.com/auth/dialogflow"
23710	//   ]
23711	// }
23712
23713}
23714
23715// method id "dialogflow.projects.agent.environments.users.sessions.entityTypes.create":
23716
23717type ProjectsAgentEnvironmentsUsersSessionsEntityTypesCreateCall struct {
23718	s                                        *Service
23719	parent                                   string
23720	googleclouddialogflowv2sessionentitytype *GoogleCloudDialogflowV2SessionEntityType
23721	urlParams_                               gensupport.URLParams
23722	ctx_                                     context.Context
23723	header_                                  http.Header
23724}
23725
23726// Create: Creates a session entity type. If the specified session
23727// entity type already exists, overrides the session entity type. This
23728// method doesn't work with Google Assistant integration. Contact
23729// Dialogflow support if you need to use session entities with Google
23730// Assistant integration.
23731//
23732// - parent: The session to create a session entity type for. Format:
23733//   `projects//agent/sessions/` or
23734//   `projects//agent/environments//users// sessions/`. If `Environment
23735//   ID` is not specified, we assume default 'draft' environment. If
23736//   `User ID` is not specified, we assume default '-' user.
23737func (r *ProjectsAgentEnvironmentsUsersSessionsEntityTypesService) Create(parent string, googleclouddialogflowv2sessionentitytype *GoogleCloudDialogflowV2SessionEntityType) *ProjectsAgentEnvironmentsUsersSessionsEntityTypesCreateCall {
23738	c := &ProjectsAgentEnvironmentsUsersSessionsEntityTypesCreateCall{s: r.s, urlParams_: make(gensupport.URLParams)}
23739	c.parent = parent
23740	c.googleclouddialogflowv2sessionentitytype = googleclouddialogflowv2sessionentitytype
23741	return c
23742}
23743
23744// Fields allows partial responses to be retrieved. See
23745// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
23746// for more information.
23747func (c *ProjectsAgentEnvironmentsUsersSessionsEntityTypesCreateCall) Fields(s ...googleapi.Field) *ProjectsAgentEnvironmentsUsersSessionsEntityTypesCreateCall {
23748	c.urlParams_.Set("fields", googleapi.CombineFields(s))
23749	return c
23750}
23751
23752// Context sets the context to be used in this call's Do method. Any
23753// pending HTTP request will be aborted if the provided context is
23754// canceled.
23755func (c *ProjectsAgentEnvironmentsUsersSessionsEntityTypesCreateCall) Context(ctx context.Context) *ProjectsAgentEnvironmentsUsersSessionsEntityTypesCreateCall {
23756	c.ctx_ = ctx
23757	return c
23758}
23759
23760// Header returns an http.Header that can be modified by the caller to
23761// add HTTP headers to the request.
23762func (c *ProjectsAgentEnvironmentsUsersSessionsEntityTypesCreateCall) Header() http.Header {
23763	if c.header_ == nil {
23764		c.header_ = make(http.Header)
23765	}
23766	return c.header_
23767}
23768
23769func (c *ProjectsAgentEnvironmentsUsersSessionsEntityTypesCreateCall) doRequest(alt string) (*http.Response, error) {
23770	reqHeaders := make(http.Header)
23771	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20211027")
23772	for k, v := range c.header_ {
23773		reqHeaders[k] = v
23774	}
23775	reqHeaders.Set("User-Agent", c.s.userAgent())
23776	var body io.Reader = nil
23777	body, err := googleapi.WithoutDataWrapper.JSONReader(c.googleclouddialogflowv2sessionentitytype)
23778	if err != nil {
23779		return nil, err
23780	}
23781	reqHeaders.Set("Content-Type", "application/json")
23782	c.urlParams_.Set("alt", alt)
23783	c.urlParams_.Set("prettyPrint", "false")
23784	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+parent}/entityTypes")
23785	urls += "?" + c.urlParams_.Encode()
23786	req, err := http.NewRequest("POST", urls, body)
23787	if err != nil {
23788		return nil, err
23789	}
23790	req.Header = reqHeaders
23791	googleapi.Expand(req.URL, map[string]string{
23792		"parent": c.parent,
23793	})
23794	return gensupport.SendRequest(c.ctx_, c.s.client, req)
23795}
23796
23797// Do executes the "dialogflow.projects.agent.environments.users.sessions.entityTypes.create" call.
23798// Exactly one of *GoogleCloudDialogflowV2SessionEntityType or error
23799// will be non-nil. Any non-2xx status code is an error. Response
23800// headers are in either
23801// *GoogleCloudDialogflowV2SessionEntityType.ServerResponse.Header or
23802// (if a response was returned at all) in
23803// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
23804// whether the returned error was because http.StatusNotModified was
23805// returned.
23806func (c *ProjectsAgentEnvironmentsUsersSessionsEntityTypesCreateCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDialogflowV2SessionEntityType, error) {
23807	gensupport.SetOptions(c.urlParams_, opts...)
23808	res, err := c.doRequest("json")
23809	if res != nil && res.StatusCode == http.StatusNotModified {
23810		if res.Body != nil {
23811			res.Body.Close()
23812		}
23813		return nil, &googleapi.Error{
23814			Code:   res.StatusCode,
23815			Header: res.Header,
23816		}
23817	}
23818	if err != nil {
23819		return nil, err
23820	}
23821	defer googleapi.CloseBody(res)
23822	if err := googleapi.CheckResponse(res); err != nil {
23823		return nil, err
23824	}
23825	ret := &GoogleCloudDialogflowV2SessionEntityType{
23826		ServerResponse: googleapi.ServerResponse{
23827			Header:         res.Header,
23828			HTTPStatusCode: res.StatusCode,
23829		},
23830	}
23831	target := &ret
23832	if err := gensupport.DecodeResponse(target, res); err != nil {
23833		return nil, err
23834	}
23835	return ret, nil
23836	// {
23837	//   "description": "Creates a session entity type. If the specified session entity type already exists, overrides the session entity type. This method doesn't work with Google Assistant integration. Contact Dialogflow support if you need to use session entities with Google Assistant integration.",
23838	//   "flatPath": "v2/projects/{projectsId}/agent/environments/{environmentsId}/users/{usersId}/sessions/{sessionsId}/entityTypes",
23839	//   "httpMethod": "POST",
23840	//   "id": "dialogflow.projects.agent.environments.users.sessions.entityTypes.create",
23841	//   "parameterOrder": [
23842	//     "parent"
23843	//   ],
23844	//   "parameters": {
23845	//     "parent": {
23846	//       "description": "Required. The session to create a session entity type for. Format: `projects//agent/sessions/` or `projects//agent/environments//users// sessions/`. If `Environment ID` is not specified, we assume default 'draft' environment. If `User ID` is not specified, we assume default '-' user.",
23847	//       "location": "path",
23848	//       "pattern": "^projects/[^/]+/agent/environments/[^/]+/users/[^/]+/sessions/[^/]+$",
23849	//       "required": true,
23850	//       "type": "string"
23851	//     }
23852	//   },
23853	//   "path": "v2/{+parent}/entityTypes",
23854	//   "request": {
23855	//     "$ref": "GoogleCloudDialogflowV2SessionEntityType"
23856	//   },
23857	//   "response": {
23858	//     "$ref": "GoogleCloudDialogflowV2SessionEntityType"
23859	//   },
23860	//   "scopes": [
23861	//     "https://www.googleapis.com/auth/cloud-platform",
23862	//     "https://www.googleapis.com/auth/dialogflow"
23863	//   ]
23864	// }
23865
23866}
23867
23868// method id "dialogflow.projects.agent.environments.users.sessions.entityTypes.delete":
23869
23870type ProjectsAgentEnvironmentsUsersSessionsEntityTypesDeleteCall struct {
23871	s          *Service
23872	name       string
23873	urlParams_ gensupport.URLParams
23874	ctx_       context.Context
23875	header_    http.Header
23876}
23877
23878// Delete: Deletes the specified session entity type. This method
23879// doesn't work with Google Assistant integration. Contact Dialogflow
23880// support if you need to use session entities with Google Assistant
23881// integration.
23882//
23883// - name: The name of the entity type to delete. Format:
23884//   `projects//agent/sessions//entityTypes/` or
23885//   `projects//agent/environments//users//sessions//entityTypes/`. If
23886//   `Environment ID` is not specified, we assume default 'draft'
23887//   environment. If `User ID` is not specified, we assume default '-'
23888//   user.
23889func (r *ProjectsAgentEnvironmentsUsersSessionsEntityTypesService) Delete(name string) *ProjectsAgentEnvironmentsUsersSessionsEntityTypesDeleteCall {
23890	c := &ProjectsAgentEnvironmentsUsersSessionsEntityTypesDeleteCall{s: r.s, urlParams_: make(gensupport.URLParams)}
23891	c.name = name
23892	return c
23893}
23894
23895// Fields allows partial responses to be retrieved. See
23896// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
23897// for more information.
23898func (c *ProjectsAgentEnvironmentsUsersSessionsEntityTypesDeleteCall) Fields(s ...googleapi.Field) *ProjectsAgentEnvironmentsUsersSessionsEntityTypesDeleteCall {
23899	c.urlParams_.Set("fields", googleapi.CombineFields(s))
23900	return c
23901}
23902
23903// Context sets the context to be used in this call's Do method. Any
23904// pending HTTP request will be aborted if the provided context is
23905// canceled.
23906func (c *ProjectsAgentEnvironmentsUsersSessionsEntityTypesDeleteCall) Context(ctx context.Context) *ProjectsAgentEnvironmentsUsersSessionsEntityTypesDeleteCall {
23907	c.ctx_ = ctx
23908	return c
23909}
23910
23911// Header returns an http.Header that can be modified by the caller to
23912// add HTTP headers to the request.
23913func (c *ProjectsAgentEnvironmentsUsersSessionsEntityTypesDeleteCall) Header() http.Header {
23914	if c.header_ == nil {
23915		c.header_ = make(http.Header)
23916	}
23917	return c.header_
23918}
23919
23920func (c *ProjectsAgentEnvironmentsUsersSessionsEntityTypesDeleteCall) doRequest(alt string) (*http.Response, error) {
23921	reqHeaders := make(http.Header)
23922	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20211027")
23923	for k, v := range c.header_ {
23924		reqHeaders[k] = v
23925	}
23926	reqHeaders.Set("User-Agent", c.s.userAgent())
23927	var body io.Reader = nil
23928	c.urlParams_.Set("alt", alt)
23929	c.urlParams_.Set("prettyPrint", "false")
23930	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+name}")
23931	urls += "?" + c.urlParams_.Encode()
23932	req, err := http.NewRequest("DELETE", urls, body)
23933	if err != nil {
23934		return nil, err
23935	}
23936	req.Header = reqHeaders
23937	googleapi.Expand(req.URL, map[string]string{
23938		"name": c.name,
23939	})
23940	return gensupport.SendRequest(c.ctx_, c.s.client, req)
23941}
23942
23943// Do executes the "dialogflow.projects.agent.environments.users.sessions.entityTypes.delete" call.
23944// Exactly one of *GoogleProtobufEmpty or error will be non-nil. Any
23945// non-2xx status code is an error. Response headers are in either
23946// *GoogleProtobufEmpty.ServerResponse.Header or (if a response was
23947// returned at all) in error.(*googleapi.Error).Header. Use
23948// googleapi.IsNotModified to check whether the returned error was
23949// because http.StatusNotModified was returned.
23950func (c *ProjectsAgentEnvironmentsUsersSessionsEntityTypesDeleteCall) Do(opts ...googleapi.CallOption) (*GoogleProtobufEmpty, error) {
23951	gensupport.SetOptions(c.urlParams_, opts...)
23952	res, err := c.doRequest("json")
23953	if res != nil && res.StatusCode == http.StatusNotModified {
23954		if res.Body != nil {
23955			res.Body.Close()
23956		}
23957		return nil, &googleapi.Error{
23958			Code:   res.StatusCode,
23959			Header: res.Header,
23960		}
23961	}
23962	if err != nil {
23963		return nil, err
23964	}
23965	defer googleapi.CloseBody(res)
23966	if err := googleapi.CheckResponse(res); err != nil {
23967		return nil, err
23968	}
23969	ret := &GoogleProtobufEmpty{
23970		ServerResponse: googleapi.ServerResponse{
23971			Header:         res.Header,
23972			HTTPStatusCode: res.StatusCode,
23973		},
23974	}
23975	target := &ret
23976	if err := gensupport.DecodeResponse(target, res); err != nil {
23977		return nil, err
23978	}
23979	return ret, nil
23980	// {
23981	//   "description": "Deletes the specified session entity type. This method doesn't work with Google Assistant integration. Contact Dialogflow support if you need to use session entities with Google Assistant integration.",
23982	//   "flatPath": "v2/projects/{projectsId}/agent/environments/{environmentsId}/users/{usersId}/sessions/{sessionsId}/entityTypes/{entityTypesId}",
23983	//   "httpMethod": "DELETE",
23984	//   "id": "dialogflow.projects.agent.environments.users.sessions.entityTypes.delete",
23985	//   "parameterOrder": [
23986	//     "name"
23987	//   ],
23988	//   "parameters": {
23989	//     "name": {
23990	//       "description": "Required. The name of the entity type to delete. Format: `projects//agent/sessions//entityTypes/` or `projects//agent/environments//users//sessions//entityTypes/`. If `Environment ID` is not specified, we assume default 'draft' environment. If `User ID` is not specified, we assume default '-' user.",
23991	//       "location": "path",
23992	//       "pattern": "^projects/[^/]+/agent/environments/[^/]+/users/[^/]+/sessions/[^/]+/entityTypes/[^/]+$",
23993	//       "required": true,
23994	//       "type": "string"
23995	//     }
23996	//   },
23997	//   "path": "v2/{+name}",
23998	//   "response": {
23999	//     "$ref": "GoogleProtobufEmpty"
24000	//   },
24001	//   "scopes": [
24002	//     "https://www.googleapis.com/auth/cloud-platform",
24003	//     "https://www.googleapis.com/auth/dialogflow"
24004	//   ]
24005	// }
24006
24007}
24008
24009// method id "dialogflow.projects.agent.environments.users.sessions.entityTypes.get":
24010
24011type ProjectsAgentEnvironmentsUsersSessionsEntityTypesGetCall struct {
24012	s            *Service
24013	name         string
24014	urlParams_   gensupport.URLParams
24015	ifNoneMatch_ string
24016	ctx_         context.Context
24017	header_      http.Header
24018}
24019
24020// Get: Retrieves the specified session entity type. This method doesn't
24021// work with Google Assistant integration. Contact Dialogflow support if
24022// you need to use session entities with Google Assistant integration.
24023//
24024// - name: The name of the session entity type. Format:
24025//   `projects//agent/sessions//entityTypes/` or
24026//   `projects//agent/environments//users//sessions//entityTypes/`. If
24027//   `Environment ID` is not specified, we assume default 'draft'
24028//   environment. If `User ID` is not specified, we assume default '-'
24029//   user.
24030func (r *ProjectsAgentEnvironmentsUsersSessionsEntityTypesService) Get(name string) *ProjectsAgentEnvironmentsUsersSessionsEntityTypesGetCall {
24031	c := &ProjectsAgentEnvironmentsUsersSessionsEntityTypesGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
24032	c.name = name
24033	return c
24034}
24035
24036// Fields allows partial responses to be retrieved. See
24037// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
24038// for more information.
24039func (c *ProjectsAgentEnvironmentsUsersSessionsEntityTypesGetCall) Fields(s ...googleapi.Field) *ProjectsAgentEnvironmentsUsersSessionsEntityTypesGetCall {
24040	c.urlParams_.Set("fields", googleapi.CombineFields(s))
24041	return c
24042}
24043
24044// IfNoneMatch sets the optional parameter which makes the operation
24045// fail if the object's ETag matches the given value. This is useful for
24046// getting updates only after the object has changed since the last
24047// request. Use googleapi.IsNotModified to check whether the response
24048// error from Do is the result of In-None-Match.
24049func (c *ProjectsAgentEnvironmentsUsersSessionsEntityTypesGetCall) IfNoneMatch(entityTag string) *ProjectsAgentEnvironmentsUsersSessionsEntityTypesGetCall {
24050	c.ifNoneMatch_ = entityTag
24051	return c
24052}
24053
24054// Context sets the context to be used in this call's Do method. Any
24055// pending HTTP request will be aborted if the provided context is
24056// canceled.
24057func (c *ProjectsAgentEnvironmentsUsersSessionsEntityTypesGetCall) Context(ctx context.Context) *ProjectsAgentEnvironmentsUsersSessionsEntityTypesGetCall {
24058	c.ctx_ = ctx
24059	return c
24060}
24061
24062// Header returns an http.Header that can be modified by the caller to
24063// add HTTP headers to the request.
24064func (c *ProjectsAgentEnvironmentsUsersSessionsEntityTypesGetCall) Header() http.Header {
24065	if c.header_ == nil {
24066		c.header_ = make(http.Header)
24067	}
24068	return c.header_
24069}
24070
24071func (c *ProjectsAgentEnvironmentsUsersSessionsEntityTypesGetCall) doRequest(alt string) (*http.Response, error) {
24072	reqHeaders := make(http.Header)
24073	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20211027")
24074	for k, v := range c.header_ {
24075		reqHeaders[k] = v
24076	}
24077	reqHeaders.Set("User-Agent", c.s.userAgent())
24078	if c.ifNoneMatch_ != "" {
24079		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
24080	}
24081	var body io.Reader = nil
24082	c.urlParams_.Set("alt", alt)
24083	c.urlParams_.Set("prettyPrint", "false")
24084	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+name}")
24085	urls += "?" + c.urlParams_.Encode()
24086	req, err := http.NewRequest("GET", urls, body)
24087	if err != nil {
24088		return nil, err
24089	}
24090	req.Header = reqHeaders
24091	googleapi.Expand(req.URL, map[string]string{
24092		"name": c.name,
24093	})
24094	return gensupport.SendRequest(c.ctx_, c.s.client, req)
24095}
24096
24097// Do executes the "dialogflow.projects.agent.environments.users.sessions.entityTypes.get" call.
24098// Exactly one of *GoogleCloudDialogflowV2SessionEntityType or error
24099// will be non-nil. Any non-2xx status code is an error. Response
24100// headers are in either
24101// *GoogleCloudDialogflowV2SessionEntityType.ServerResponse.Header or
24102// (if a response was returned at all) in
24103// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
24104// whether the returned error was because http.StatusNotModified was
24105// returned.
24106func (c *ProjectsAgentEnvironmentsUsersSessionsEntityTypesGetCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDialogflowV2SessionEntityType, error) {
24107	gensupport.SetOptions(c.urlParams_, opts...)
24108	res, err := c.doRequest("json")
24109	if res != nil && res.StatusCode == http.StatusNotModified {
24110		if res.Body != nil {
24111			res.Body.Close()
24112		}
24113		return nil, &googleapi.Error{
24114			Code:   res.StatusCode,
24115			Header: res.Header,
24116		}
24117	}
24118	if err != nil {
24119		return nil, err
24120	}
24121	defer googleapi.CloseBody(res)
24122	if err := googleapi.CheckResponse(res); err != nil {
24123		return nil, err
24124	}
24125	ret := &GoogleCloudDialogflowV2SessionEntityType{
24126		ServerResponse: googleapi.ServerResponse{
24127			Header:         res.Header,
24128			HTTPStatusCode: res.StatusCode,
24129		},
24130	}
24131	target := &ret
24132	if err := gensupport.DecodeResponse(target, res); err != nil {
24133		return nil, err
24134	}
24135	return ret, nil
24136	// {
24137	//   "description": "Retrieves the specified session entity type. This method doesn't work with Google Assistant integration. Contact Dialogflow support if you need to use session entities with Google Assistant integration.",
24138	//   "flatPath": "v2/projects/{projectsId}/agent/environments/{environmentsId}/users/{usersId}/sessions/{sessionsId}/entityTypes/{entityTypesId}",
24139	//   "httpMethod": "GET",
24140	//   "id": "dialogflow.projects.agent.environments.users.sessions.entityTypes.get",
24141	//   "parameterOrder": [
24142	//     "name"
24143	//   ],
24144	//   "parameters": {
24145	//     "name": {
24146	//       "description": "Required. The name of the session entity type. Format: `projects//agent/sessions//entityTypes/` or `projects//agent/environments//users//sessions//entityTypes/`. If `Environment ID` is not specified, we assume default 'draft' environment. If `User ID` is not specified, we assume default '-' user.",
24147	//       "location": "path",
24148	//       "pattern": "^projects/[^/]+/agent/environments/[^/]+/users/[^/]+/sessions/[^/]+/entityTypes/[^/]+$",
24149	//       "required": true,
24150	//       "type": "string"
24151	//     }
24152	//   },
24153	//   "path": "v2/{+name}",
24154	//   "response": {
24155	//     "$ref": "GoogleCloudDialogflowV2SessionEntityType"
24156	//   },
24157	//   "scopes": [
24158	//     "https://www.googleapis.com/auth/cloud-platform",
24159	//     "https://www.googleapis.com/auth/dialogflow"
24160	//   ]
24161	// }
24162
24163}
24164
24165// method id "dialogflow.projects.agent.environments.users.sessions.entityTypes.list":
24166
24167type ProjectsAgentEnvironmentsUsersSessionsEntityTypesListCall struct {
24168	s            *Service
24169	parent       string
24170	urlParams_   gensupport.URLParams
24171	ifNoneMatch_ string
24172	ctx_         context.Context
24173	header_      http.Header
24174}
24175
24176// List: Returns the list of all session entity types in the specified
24177// session. This method doesn't work with Google Assistant integration.
24178// Contact Dialogflow support if you need to use session entities with
24179// Google Assistant integration.
24180//
24181// - parent: The session to list all session entity types from. Format:
24182//   `projects//agent/sessions/` or
24183//   `projects//agent/environments//users// sessions/`. If `Environment
24184//   ID` is not specified, we assume default 'draft' environment. If
24185//   `User ID` is not specified, we assume default '-' user.
24186func (r *ProjectsAgentEnvironmentsUsersSessionsEntityTypesService) List(parent string) *ProjectsAgentEnvironmentsUsersSessionsEntityTypesListCall {
24187	c := &ProjectsAgentEnvironmentsUsersSessionsEntityTypesListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
24188	c.parent = parent
24189	return c
24190}
24191
24192// PageSize sets the optional parameter "pageSize": The maximum number
24193// of items to return in a single page. By default 100 and at most 1000.
24194func (c *ProjectsAgentEnvironmentsUsersSessionsEntityTypesListCall) PageSize(pageSize int64) *ProjectsAgentEnvironmentsUsersSessionsEntityTypesListCall {
24195	c.urlParams_.Set("pageSize", fmt.Sprint(pageSize))
24196	return c
24197}
24198
24199// PageToken sets the optional parameter "pageToken": The
24200// next_page_token value returned from a previous list request.
24201func (c *ProjectsAgentEnvironmentsUsersSessionsEntityTypesListCall) PageToken(pageToken string) *ProjectsAgentEnvironmentsUsersSessionsEntityTypesListCall {
24202	c.urlParams_.Set("pageToken", pageToken)
24203	return c
24204}
24205
24206// Fields allows partial responses to be retrieved. See
24207// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
24208// for more information.
24209func (c *ProjectsAgentEnvironmentsUsersSessionsEntityTypesListCall) Fields(s ...googleapi.Field) *ProjectsAgentEnvironmentsUsersSessionsEntityTypesListCall {
24210	c.urlParams_.Set("fields", googleapi.CombineFields(s))
24211	return c
24212}
24213
24214// IfNoneMatch sets the optional parameter which makes the operation
24215// fail if the object's ETag matches the given value. This is useful for
24216// getting updates only after the object has changed since the last
24217// request. Use googleapi.IsNotModified to check whether the response
24218// error from Do is the result of In-None-Match.
24219func (c *ProjectsAgentEnvironmentsUsersSessionsEntityTypesListCall) IfNoneMatch(entityTag string) *ProjectsAgentEnvironmentsUsersSessionsEntityTypesListCall {
24220	c.ifNoneMatch_ = entityTag
24221	return c
24222}
24223
24224// Context sets the context to be used in this call's Do method. Any
24225// pending HTTP request will be aborted if the provided context is
24226// canceled.
24227func (c *ProjectsAgentEnvironmentsUsersSessionsEntityTypesListCall) Context(ctx context.Context) *ProjectsAgentEnvironmentsUsersSessionsEntityTypesListCall {
24228	c.ctx_ = ctx
24229	return c
24230}
24231
24232// Header returns an http.Header that can be modified by the caller to
24233// add HTTP headers to the request.
24234func (c *ProjectsAgentEnvironmentsUsersSessionsEntityTypesListCall) Header() http.Header {
24235	if c.header_ == nil {
24236		c.header_ = make(http.Header)
24237	}
24238	return c.header_
24239}
24240
24241func (c *ProjectsAgentEnvironmentsUsersSessionsEntityTypesListCall) doRequest(alt string) (*http.Response, error) {
24242	reqHeaders := make(http.Header)
24243	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20211027")
24244	for k, v := range c.header_ {
24245		reqHeaders[k] = v
24246	}
24247	reqHeaders.Set("User-Agent", c.s.userAgent())
24248	if c.ifNoneMatch_ != "" {
24249		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
24250	}
24251	var body io.Reader = nil
24252	c.urlParams_.Set("alt", alt)
24253	c.urlParams_.Set("prettyPrint", "false")
24254	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+parent}/entityTypes")
24255	urls += "?" + c.urlParams_.Encode()
24256	req, err := http.NewRequest("GET", urls, body)
24257	if err != nil {
24258		return nil, err
24259	}
24260	req.Header = reqHeaders
24261	googleapi.Expand(req.URL, map[string]string{
24262		"parent": c.parent,
24263	})
24264	return gensupport.SendRequest(c.ctx_, c.s.client, req)
24265}
24266
24267// Do executes the "dialogflow.projects.agent.environments.users.sessions.entityTypes.list" call.
24268// Exactly one of *GoogleCloudDialogflowV2ListSessionEntityTypesResponse
24269// or error will be non-nil. Any non-2xx status code is an error.
24270// Response headers are in either
24271// *GoogleCloudDialogflowV2ListSessionEntityTypesResponse.ServerResponse.
24272// Header or (if a response was returned at all) in
24273// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
24274// whether the returned error was because http.StatusNotModified was
24275// returned.
24276func (c *ProjectsAgentEnvironmentsUsersSessionsEntityTypesListCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDialogflowV2ListSessionEntityTypesResponse, error) {
24277	gensupport.SetOptions(c.urlParams_, opts...)
24278	res, err := c.doRequest("json")
24279	if res != nil && res.StatusCode == http.StatusNotModified {
24280		if res.Body != nil {
24281			res.Body.Close()
24282		}
24283		return nil, &googleapi.Error{
24284			Code:   res.StatusCode,
24285			Header: res.Header,
24286		}
24287	}
24288	if err != nil {
24289		return nil, err
24290	}
24291	defer googleapi.CloseBody(res)
24292	if err := googleapi.CheckResponse(res); err != nil {
24293		return nil, err
24294	}
24295	ret := &GoogleCloudDialogflowV2ListSessionEntityTypesResponse{
24296		ServerResponse: googleapi.ServerResponse{
24297			Header:         res.Header,
24298			HTTPStatusCode: res.StatusCode,
24299		},
24300	}
24301	target := &ret
24302	if err := gensupport.DecodeResponse(target, res); err != nil {
24303		return nil, err
24304	}
24305	return ret, nil
24306	// {
24307	//   "description": "Returns the list of all session entity types in the specified session. This method doesn't work with Google Assistant integration. Contact Dialogflow support if you need to use session entities with Google Assistant integration.",
24308	//   "flatPath": "v2/projects/{projectsId}/agent/environments/{environmentsId}/users/{usersId}/sessions/{sessionsId}/entityTypes",
24309	//   "httpMethod": "GET",
24310	//   "id": "dialogflow.projects.agent.environments.users.sessions.entityTypes.list",
24311	//   "parameterOrder": [
24312	//     "parent"
24313	//   ],
24314	//   "parameters": {
24315	//     "pageSize": {
24316	//       "description": "Optional. The maximum number of items to return in a single page. By default 100 and at most 1000.",
24317	//       "format": "int32",
24318	//       "location": "query",
24319	//       "type": "integer"
24320	//     },
24321	//     "pageToken": {
24322	//       "description": "Optional. The next_page_token value returned from a previous list request.",
24323	//       "location": "query",
24324	//       "type": "string"
24325	//     },
24326	//     "parent": {
24327	//       "description": "Required. The session to list all session entity types from. Format: `projects//agent/sessions/` or `projects//agent/environments//users// sessions/`. If `Environment ID` is not specified, we assume default 'draft' environment. If `User ID` is not specified, we assume default '-' user.",
24328	//       "location": "path",
24329	//       "pattern": "^projects/[^/]+/agent/environments/[^/]+/users/[^/]+/sessions/[^/]+$",
24330	//       "required": true,
24331	//       "type": "string"
24332	//     }
24333	//   },
24334	//   "path": "v2/{+parent}/entityTypes",
24335	//   "response": {
24336	//     "$ref": "GoogleCloudDialogflowV2ListSessionEntityTypesResponse"
24337	//   },
24338	//   "scopes": [
24339	//     "https://www.googleapis.com/auth/cloud-platform",
24340	//     "https://www.googleapis.com/auth/dialogflow"
24341	//   ]
24342	// }
24343
24344}
24345
24346// Pages invokes f for each page of results.
24347// A non-nil error returned from f will halt the iteration.
24348// The provided context supersedes any context provided to the Context method.
24349func (c *ProjectsAgentEnvironmentsUsersSessionsEntityTypesListCall) Pages(ctx context.Context, f func(*GoogleCloudDialogflowV2ListSessionEntityTypesResponse) error) error {
24350	c.ctx_ = ctx
24351	defer c.PageToken(c.urlParams_.Get("pageToken")) // reset paging to original point
24352	for {
24353		x, err := c.Do()
24354		if err != nil {
24355			return err
24356		}
24357		if err := f(x); err != nil {
24358			return err
24359		}
24360		if x.NextPageToken == "" {
24361			return nil
24362		}
24363		c.PageToken(x.NextPageToken)
24364	}
24365}
24366
24367// method id "dialogflow.projects.agent.environments.users.sessions.entityTypes.patch":
24368
24369type ProjectsAgentEnvironmentsUsersSessionsEntityTypesPatchCall struct {
24370	s                                        *Service
24371	nameid                                   string
24372	googleclouddialogflowv2sessionentitytype *GoogleCloudDialogflowV2SessionEntityType
24373	urlParams_                               gensupport.URLParams
24374	ctx_                                     context.Context
24375	header_                                  http.Header
24376}
24377
24378// Patch: Updates the specified session entity type. This method doesn't
24379// work with Google Assistant integration. Contact Dialogflow support if
24380// you need to use session entities with Google Assistant integration.
24381//
24382// - name: The unique identifier of this session entity type. Format:
24383//   `projects//agent/sessions//entityTypes/`, or
24384//   `projects//agent/environments//users//sessions//entityTypes/`. If
24385//   `Environment ID` is not specified, we assume default 'draft'
24386//   environment. If `User ID` is not specified, we assume default '-'
24387//   user. `` must be the display name of an existing entity type in the
24388//   same agent that will be overridden or supplemented.
24389func (r *ProjectsAgentEnvironmentsUsersSessionsEntityTypesService) Patch(nameid string, googleclouddialogflowv2sessionentitytype *GoogleCloudDialogflowV2SessionEntityType) *ProjectsAgentEnvironmentsUsersSessionsEntityTypesPatchCall {
24390	c := &ProjectsAgentEnvironmentsUsersSessionsEntityTypesPatchCall{s: r.s, urlParams_: make(gensupport.URLParams)}
24391	c.nameid = nameid
24392	c.googleclouddialogflowv2sessionentitytype = googleclouddialogflowv2sessionentitytype
24393	return c
24394}
24395
24396// UpdateMask sets the optional parameter "updateMask": The mask to
24397// control which fields get updated.
24398func (c *ProjectsAgentEnvironmentsUsersSessionsEntityTypesPatchCall) UpdateMask(updateMask string) *ProjectsAgentEnvironmentsUsersSessionsEntityTypesPatchCall {
24399	c.urlParams_.Set("updateMask", updateMask)
24400	return c
24401}
24402
24403// Fields allows partial responses to be retrieved. See
24404// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
24405// for more information.
24406func (c *ProjectsAgentEnvironmentsUsersSessionsEntityTypesPatchCall) Fields(s ...googleapi.Field) *ProjectsAgentEnvironmentsUsersSessionsEntityTypesPatchCall {
24407	c.urlParams_.Set("fields", googleapi.CombineFields(s))
24408	return c
24409}
24410
24411// Context sets the context to be used in this call's Do method. Any
24412// pending HTTP request will be aborted if the provided context is
24413// canceled.
24414func (c *ProjectsAgentEnvironmentsUsersSessionsEntityTypesPatchCall) Context(ctx context.Context) *ProjectsAgentEnvironmentsUsersSessionsEntityTypesPatchCall {
24415	c.ctx_ = ctx
24416	return c
24417}
24418
24419// Header returns an http.Header that can be modified by the caller to
24420// add HTTP headers to the request.
24421func (c *ProjectsAgentEnvironmentsUsersSessionsEntityTypesPatchCall) Header() http.Header {
24422	if c.header_ == nil {
24423		c.header_ = make(http.Header)
24424	}
24425	return c.header_
24426}
24427
24428func (c *ProjectsAgentEnvironmentsUsersSessionsEntityTypesPatchCall) doRequest(alt string) (*http.Response, error) {
24429	reqHeaders := make(http.Header)
24430	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20211027")
24431	for k, v := range c.header_ {
24432		reqHeaders[k] = v
24433	}
24434	reqHeaders.Set("User-Agent", c.s.userAgent())
24435	var body io.Reader = nil
24436	body, err := googleapi.WithoutDataWrapper.JSONReader(c.googleclouddialogflowv2sessionentitytype)
24437	if err != nil {
24438		return nil, err
24439	}
24440	reqHeaders.Set("Content-Type", "application/json")
24441	c.urlParams_.Set("alt", alt)
24442	c.urlParams_.Set("prettyPrint", "false")
24443	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+name}")
24444	urls += "?" + c.urlParams_.Encode()
24445	req, err := http.NewRequest("PATCH", urls, body)
24446	if err != nil {
24447		return nil, err
24448	}
24449	req.Header = reqHeaders
24450	googleapi.Expand(req.URL, map[string]string{
24451		"name": c.nameid,
24452	})
24453	return gensupport.SendRequest(c.ctx_, c.s.client, req)
24454}
24455
24456// Do executes the "dialogflow.projects.agent.environments.users.sessions.entityTypes.patch" call.
24457// Exactly one of *GoogleCloudDialogflowV2SessionEntityType or error
24458// will be non-nil. Any non-2xx status code is an error. Response
24459// headers are in either
24460// *GoogleCloudDialogflowV2SessionEntityType.ServerResponse.Header or
24461// (if a response was returned at all) in
24462// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
24463// whether the returned error was because http.StatusNotModified was
24464// returned.
24465func (c *ProjectsAgentEnvironmentsUsersSessionsEntityTypesPatchCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDialogflowV2SessionEntityType, error) {
24466	gensupport.SetOptions(c.urlParams_, opts...)
24467	res, err := c.doRequest("json")
24468	if res != nil && res.StatusCode == http.StatusNotModified {
24469		if res.Body != nil {
24470			res.Body.Close()
24471		}
24472		return nil, &googleapi.Error{
24473			Code:   res.StatusCode,
24474			Header: res.Header,
24475		}
24476	}
24477	if err != nil {
24478		return nil, err
24479	}
24480	defer googleapi.CloseBody(res)
24481	if err := googleapi.CheckResponse(res); err != nil {
24482		return nil, err
24483	}
24484	ret := &GoogleCloudDialogflowV2SessionEntityType{
24485		ServerResponse: googleapi.ServerResponse{
24486			Header:         res.Header,
24487			HTTPStatusCode: res.StatusCode,
24488		},
24489	}
24490	target := &ret
24491	if err := gensupport.DecodeResponse(target, res); err != nil {
24492		return nil, err
24493	}
24494	return ret, nil
24495	// {
24496	//   "description": "Updates the specified session entity type. This method doesn't work with Google Assistant integration. Contact Dialogflow support if you need to use session entities with Google Assistant integration.",
24497	//   "flatPath": "v2/projects/{projectsId}/agent/environments/{environmentsId}/users/{usersId}/sessions/{sessionsId}/entityTypes/{entityTypesId}",
24498	//   "httpMethod": "PATCH",
24499	//   "id": "dialogflow.projects.agent.environments.users.sessions.entityTypes.patch",
24500	//   "parameterOrder": [
24501	//     "name"
24502	//   ],
24503	//   "parameters": {
24504	//     "name": {
24505	//       "description": "Required. The unique identifier of this session entity type. Format: `projects//agent/sessions//entityTypes/`, or `projects//agent/environments//users//sessions//entityTypes/`. If `Environment ID` is not specified, we assume default 'draft' environment. If `User ID` is not specified, we assume default '-' user. `` must be the display name of an existing entity type in the same agent that will be overridden or supplemented.",
24506	//       "location": "path",
24507	//       "pattern": "^projects/[^/]+/agent/environments/[^/]+/users/[^/]+/sessions/[^/]+/entityTypes/[^/]+$",
24508	//       "required": true,
24509	//       "type": "string"
24510	//     },
24511	//     "updateMask": {
24512	//       "description": "Optional. The mask to control which fields get updated.",
24513	//       "format": "google-fieldmask",
24514	//       "location": "query",
24515	//       "type": "string"
24516	//     }
24517	//   },
24518	//   "path": "v2/{+name}",
24519	//   "request": {
24520	//     "$ref": "GoogleCloudDialogflowV2SessionEntityType"
24521	//   },
24522	//   "response": {
24523	//     "$ref": "GoogleCloudDialogflowV2SessionEntityType"
24524	//   },
24525	//   "scopes": [
24526	//     "https://www.googleapis.com/auth/cloud-platform",
24527	//     "https://www.googleapis.com/auth/dialogflow"
24528	//   ]
24529	// }
24530
24531}
24532
24533// method id "dialogflow.projects.agent.intents.batchDelete":
24534
24535type ProjectsAgentIntentsBatchDeleteCall struct {
24536	s                                                *Service
24537	parent                                           string
24538	googleclouddialogflowv2batchdeleteintentsrequest *GoogleCloudDialogflowV2BatchDeleteIntentsRequest
24539	urlParams_                                       gensupport.URLParams
24540	ctx_                                             context.Context
24541	header_                                          http.Header
24542}
24543
24544// BatchDelete: Deletes intents in the specified agent. This method is a
24545// long-running operation
24546// (https://cloud.google.com/dialogflow/es/docs/how/long-running-operations).
24547// The returned `Operation` type has the following method-specific
24548// fields: - `metadata`: An empty Struct message
24549// (https://developers.google.com/protocol-buffers/docs/reference/google.protobuf#struct)
24550// - `response`: An Empty message
24551// (https://developers.google.com/protocol-buffers/docs/reference/google.protobuf#empty)
24552// Note: You should always train an agent prior to sending it queries.
24553// See the training documentation
24554// (https://cloud.google.com/dialogflow/es/docs/training).
24555//
24556// - parent: The name of the agent to delete all entities types for.
24557//   Format: `projects//agent`.
24558func (r *ProjectsAgentIntentsService) BatchDelete(parent string, googleclouddialogflowv2batchdeleteintentsrequest *GoogleCloudDialogflowV2BatchDeleteIntentsRequest) *ProjectsAgentIntentsBatchDeleteCall {
24559	c := &ProjectsAgentIntentsBatchDeleteCall{s: r.s, urlParams_: make(gensupport.URLParams)}
24560	c.parent = parent
24561	c.googleclouddialogflowv2batchdeleteintentsrequest = googleclouddialogflowv2batchdeleteintentsrequest
24562	return c
24563}
24564
24565// Fields allows partial responses to be retrieved. See
24566// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
24567// for more information.
24568func (c *ProjectsAgentIntentsBatchDeleteCall) Fields(s ...googleapi.Field) *ProjectsAgentIntentsBatchDeleteCall {
24569	c.urlParams_.Set("fields", googleapi.CombineFields(s))
24570	return c
24571}
24572
24573// Context sets the context to be used in this call's Do method. Any
24574// pending HTTP request will be aborted if the provided context is
24575// canceled.
24576func (c *ProjectsAgentIntentsBatchDeleteCall) Context(ctx context.Context) *ProjectsAgentIntentsBatchDeleteCall {
24577	c.ctx_ = ctx
24578	return c
24579}
24580
24581// Header returns an http.Header that can be modified by the caller to
24582// add HTTP headers to the request.
24583func (c *ProjectsAgentIntentsBatchDeleteCall) Header() http.Header {
24584	if c.header_ == nil {
24585		c.header_ = make(http.Header)
24586	}
24587	return c.header_
24588}
24589
24590func (c *ProjectsAgentIntentsBatchDeleteCall) doRequest(alt string) (*http.Response, error) {
24591	reqHeaders := make(http.Header)
24592	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20211027")
24593	for k, v := range c.header_ {
24594		reqHeaders[k] = v
24595	}
24596	reqHeaders.Set("User-Agent", c.s.userAgent())
24597	var body io.Reader = nil
24598	body, err := googleapi.WithoutDataWrapper.JSONReader(c.googleclouddialogflowv2batchdeleteintentsrequest)
24599	if err != nil {
24600		return nil, err
24601	}
24602	reqHeaders.Set("Content-Type", "application/json")
24603	c.urlParams_.Set("alt", alt)
24604	c.urlParams_.Set("prettyPrint", "false")
24605	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+parent}/intents:batchDelete")
24606	urls += "?" + c.urlParams_.Encode()
24607	req, err := http.NewRequest("POST", urls, body)
24608	if err != nil {
24609		return nil, err
24610	}
24611	req.Header = reqHeaders
24612	googleapi.Expand(req.URL, map[string]string{
24613		"parent": c.parent,
24614	})
24615	return gensupport.SendRequest(c.ctx_, c.s.client, req)
24616}
24617
24618// Do executes the "dialogflow.projects.agent.intents.batchDelete" call.
24619// Exactly one of *GoogleLongrunningOperation or error will be non-nil.
24620// Any non-2xx status code is an error. Response headers are in either
24621// *GoogleLongrunningOperation.ServerResponse.Header or (if a response
24622// was returned at all) in error.(*googleapi.Error).Header. Use
24623// googleapi.IsNotModified to check whether the returned error was
24624// because http.StatusNotModified was returned.
24625func (c *ProjectsAgentIntentsBatchDeleteCall) Do(opts ...googleapi.CallOption) (*GoogleLongrunningOperation, error) {
24626	gensupport.SetOptions(c.urlParams_, opts...)
24627	res, err := c.doRequest("json")
24628	if res != nil && res.StatusCode == http.StatusNotModified {
24629		if res.Body != nil {
24630			res.Body.Close()
24631		}
24632		return nil, &googleapi.Error{
24633			Code:   res.StatusCode,
24634			Header: res.Header,
24635		}
24636	}
24637	if err != nil {
24638		return nil, err
24639	}
24640	defer googleapi.CloseBody(res)
24641	if err := googleapi.CheckResponse(res); err != nil {
24642		return nil, err
24643	}
24644	ret := &GoogleLongrunningOperation{
24645		ServerResponse: googleapi.ServerResponse{
24646			Header:         res.Header,
24647			HTTPStatusCode: res.StatusCode,
24648		},
24649	}
24650	target := &ret
24651	if err := gensupport.DecodeResponse(target, res); err != nil {
24652		return nil, err
24653	}
24654	return ret, nil
24655	// {
24656	//   "description": "Deletes intents in the specified agent. This method is a [long-running operation](https://cloud.google.com/dialogflow/es/docs/how/long-running-operations). The returned `Operation` type has the following method-specific fields: - `metadata`: An empty [Struct message](https://developers.google.com/protocol-buffers/docs/reference/google.protobuf#struct) - `response`: An [Empty message](https://developers.google.com/protocol-buffers/docs/reference/google.protobuf#empty) Note: You should always train an agent prior to sending it queries. See the [training documentation](https://cloud.google.com/dialogflow/es/docs/training).",
24657	//   "flatPath": "v2/projects/{projectsId}/agent/intents:batchDelete",
24658	//   "httpMethod": "POST",
24659	//   "id": "dialogflow.projects.agent.intents.batchDelete",
24660	//   "parameterOrder": [
24661	//     "parent"
24662	//   ],
24663	//   "parameters": {
24664	//     "parent": {
24665	//       "description": "Required. The name of the agent to delete all entities types for. Format: `projects//agent`.",
24666	//       "location": "path",
24667	//       "pattern": "^projects/[^/]+/agent$",
24668	//       "required": true,
24669	//       "type": "string"
24670	//     }
24671	//   },
24672	//   "path": "v2/{+parent}/intents:batchDelete",
24673	//   "request": {
24674	//     "$ref": "GoogleCloudDialogflowV2BatchDeleteIntentsRequest"
24675	//   },
24676	//   "response": {
24677	//     "$ref": "GoogleLongrunningOperation"
24678	//   },
24679	//   "scopes": [
24680	//     "https://www.googleapis.com/auth/cloud-platform",
24681	//     "https://www.googleapis.com/auth/dialogflow"
24682	//   ]
24683	// }
24684
24685}
24686
24687// method id "dialogflow.projects.agent.intents.batchUpdate":
24688
24689type ProjectsAgentIntentsBatchUpdateCall struct {
24690	s                                                *Service
24691	parent                                           string
24692	googleclouddialogflowv2batchupdateintentsrequest *GoogleCloudDialogflowV2BatchUpdateIntentsRequest
24693	urlParams_                                       gensupport.URLParams
24694	ctx_                                             context.Context
24695	header_                                          http.Header
24696}
24697
24698// BatchUpdate: Updates/Creates multiple intents in the specified agent.
24699// This method is a long-running operation
24700// (https://cloud.google.com/dialogflow/es/docs/how/long-running-operations).
24701// The returned `Operation` type has the following method-specific
24702// fields: - `metadata`: An empty Struct message
24703// (https://developers.google.com/protocol-buffers/docs/reference/google.protobuf#struct)
24704// - `response`: BatchUpdateIntentsResponse Note: You should always
24705// train an agent prior to sending it queries. See the training
24706// documentation (https://cloud.google.com/dialogflow/es/docs/training).
24707//
24708// - parent: The name of the agent to update or create intents in.
24709//   Format: `projects//agent`.
24710func (r *ProjectsAgentIntentsService) BatchUpdate(parent string, googleclouddialogflowv2batchupdateintentsrequest *GoogleCloudDialogflowV2BatchUpdateIntentsRequest) *ProjectsAgentIntentsBatchUpdateCall {
24711	c := &ProjectsAgentIntentsBatchUpdateCall{s: r.s, urlParams_: make(gensupport.URLParams)}
24712	c.parent = parent
24713	c.googleclouddialogflowv2batchupdateintentsrequest = googleclouddialogflowv2batchupdateintentsrequest
24714	return c
24715}
24716
24717// Fields allows partial responses to be retrieved. See
24718// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
24719// for more information.
24720func (c *ProjectsAgentIntentsBatchUpdateCall) Fields(s ...googleapi.Field) *ProjectsAgentIntentsBatchUpdateCall {
24721	c.urlParams_.Set("fields", googleapi.CombineFields(s))
24722	return c
24723}
24724
24725// Context sets the context to be used in this call's Do method. Any
24726// pending HTTP request will be aborted if the provided context is
24727// canceled.
24728func (c *ProjectsAgentIntentsBatchUpdateCall) Context(ctx context.Context) *ProjectsAgentIntentsBatchUpdateCall {
24729	c.ctx_ = ctx
24730	return c
24731}
24732
24733// Header returns an http.Header that can be modified by the caller to
24734// add HTTP headers to the request.
24735func (c *ProjectsAgentIntentsBatchUpdateCall) Header() http.Header {
24736	if c.header_ == nil {
24737		c.header_ = make(http.Header)
24738	}
24739	return c.header_
24740}
24741
24742func (c *ProjectsAgentIntentsBatchUpdateCall) doRequest(alt string) (*http.Response, error) {
24743	reqHeaders := make(http.Header)
24744	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20211027")
24745	for k, v := range c.header_ {
24746		reqHeaders[k] = v
24747	}
24748	reqHeaders.Set("User-Agent", c.s.userAgent())
24749	var body io.Reader = nil
24750	body, err := googleapi.WithoutDataWrapper.JSONReader(c.googleclouddialogflowv2batchupdateintentsrequest)
24751	if err != nil {
24752		return nil, err
24753	}
24754	reqHeaders.Set("Content-Type", "application/json")
24755	c.urlParams_.Set("alt", alt)
24756	c.urlParams_.Set("prettyPrint", "false")
24757	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+parent}/intents:batchUpdate")
24758	urls += "?" + c.urlParams_.Encode()
24759	req, err := http.NewRequest("POST", urls, body)
24760	if err != nil {
24761		return nil, err
24762	}
24763	req.Header = reqHeaders
24764	googleapi.Expand(req.URL, map[string]string{
24765		"parent": c.parent,
24766	})
24767	return gensupport.SendRequest(c.ctx_, c.s.client, req)
24768}
24769
24770// Do executes the "dialogflow.projects.agent.intents.batchUpdate" call.
24771// Exactly one of *GoogleLongrunningOperation or error will be non-nil.
24772// Any non-2xx status code is an error. Response headers are in either
24773// *GoogleLongrunningOperation.ServerResponse.Header or (if a response
24774// was returned at all) in error.(*googleapi.Error).Header. Use
24775// googleapi.IsNotModified to check whether the returned error was
24776// because http.StatusNotModified was returned.
24777func (c *ProjectsAgentIntentsBatchUpdateCall) Do(opts ...googleapi.CallOption) (*GoogleLongrunningOperation, error) {
24778	gensupport.SetOptions(c.urlParams_, opts...)
24779	res, err := c.doRequest("json")
24780	if res != nil && res.StatusCode == http.StatusNotModified {
24781		if res.Body != nil {
24782			res.Body.Close()
24783		}
24784		return nil, &googleapi.Error{
24785			Code:   res.StatusCode,
24786			Header: res.Header,
24787		}
24788	}
24789	if err != nil {
24790		return nil, err
24791	}
24792	defer googleapi.CloseBody(res)
24793	if err := googleapi.CheckResponse(res); err != nil {
24794		return nil, err
24795	}
24796	ret := &GoogleLongrunningOperation{
24797		ServerResponse: googleapi.ServerResponse{
24798			Header:         res.Header,
24799			HTTPStatusCode: res.StatusCode,
24800		},
24801	}
24802	target := &ret
24803	if err := gensupport.DecodeResponse(target, res); err != nil {
24804		return nil, err
24805	}
24806	return ret, nil
24807	// {
24808	//   "description": "Updates/Creates multiple intents in the specified agent. This method is a [long-running operation](https://cloud.google.com/dialogflow/es/docs/how/long-running-operations). The returned `Operation` type has the following method-specific fields: - `metadata`: An empty [Struct message](https://developers.google.com/protocol-buffers/docs/reference/google.protobuf#struct) - `response`: BatchUpdateIntentsResponse Note: You should always train an agent prior to sending it queries. See the [training documentation](https://cloud.google.com/dialogflow/es/docs/training).",
24809	//   "flatPath": "v2/projects/{projectsId}/agent/intents:batchUpdate",
24810	//   "httpMethod": "POST",
24811	//   "id": "dialogflow.projects.agent.intents.batchUpdate",
24812	//   "parameterOrder": [
24813	//     "parent"
24814	//   ],
24815	//   "parameters": {
24816	//     "parent": {
24817	//       "description": "Required. The name of the agent to update or create intents in. Format: `projects//agent`.",
24818	//       "location": "path",
24819	//       "pattern": "^projects/[^/]+/agent$",
24820	//       "required": true,
24821	//       "type": "string"
24822	//     }
24823	//   },
24824	//   "path": "v2/{+parent}/intents:batchUpdate",
24825	//   "request": {
24826	//     "$ref": "GoogleCloudDialogflowV2BatchUpdateIntentsRequest"
24827	//   },
24828	//   "response": {
24829	//     "$ref": "GoogleLongrunningOperation"
24830	//   },
24831	//   "scopes": [
24832	//     "https://www.googleapis.com/auth/cloud-platform",
24833	//     "https://www.googleapis.com/auth/dialogflow"
24834	//   ]
24835	// }
24836
24837}
24838
24839// method id "dialogflow.projects.agent.intents.create":
24840
24841type ProjectsAgentIntentsCreateCall struct {
24842	s                             *Service
24843	parent                        string
24844	googleclouddialogflowv2intent *GoogleCloudDialogflowV2Intent
24845	urlParams_                    gensupport.URLParams
24846	ctx_                          context.Context
24847	header_                       http.Header
24848}
24849
24850// Create: Creates an intent in the specified agent. Note: You should
24851// always train an agent prior to sending it queries. See the training
24852// documentation (https://cloud.google.com/dialogflow/es/docs/training).
24853//
24854// - parent: The agent to create a intent for. Format:
24855//   `projects//agent`.
24856func (r *ProjectsAgentIntentsService) Create(parent string, googleclouddialogflowv2intent *GoogleCloudDialogflowV2Intent) *ProjectsAgentIntentsCreateCall {
24857	c := &ProjectsAgentIntentsCreateCall{s: r.s, urlParams_: make(gensupport.URLParams)}
24858	c.parent = parent
24859	c.googleclouddialogflowv2intent = googleclouddialogflowv2intent
24860	return c
24861}
24862
24863// IntentView sets the optional parameter "intentView": The resource
24864// view to apply to the returned intent.
24865//
24866// Possible values:
24867//   "INTENT_VIEW_UNSPECIFIED" - Training phrases field is not populated
24868// in the response.
24869//   "INTENT_VIEW_FULL" - All fields are populated.
24870func (c *ProjectsAgentIntentsCreateCall) IntentView(intentView string) *ProjectsAgentIntentsCreateCall {
24871	c.urlParams_.Set("intentView", intentView)
24872	return c
24873}
24874
24875// LanguageCode sets the optional parameter "languageCode": The language
24876// used to access language-specific data. If not specified, the agent's
24877// default language is used. For more information, see Multilingual
24878// intent and entity data
24879// (https://cloud.google.com/dialogflow/docs/agents-multilingual#intent-entity).
24880func (c *ProjectsAgentIntentsCreateCall) LanguageCode(languageCode string) *ProjectsAgentIntentsCreateCall {
24881	c.urlParams_.Set("languageCode", languageCode)
24882	return c
24883}
24884
24885// Fields allows partial responses to be retrieved. See
24886// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
24887// for more information.
24888func (c *ProjectsAgentIntentsCreateCall) Fields(s ...googleapi.Field) *ProjectsAgentIntentsCreateCall {
24889	c.urlParams_.Set("fields", googleapi.CombineFields(s))
24890	return c
24891}
24892
24893// Context sets the context to be used in this call's Do method. Any
24894// pending HTTP request will be aborted if the provided context is
24895// canceled.
24896func (c *ProjectsAgentIntentsCreateCall) Context(ctx context.Context) *ProjectsAgentIntentsCreateCall {
24897	c.ctx_ = ctx
24898	return c
24899}
24900
24901// Header returns an http.Header that can be modified by the caller to
24902// add HTTP headers to the request.
24903func (c *ProjectsAgentIntentsCreateCall) Header() http.Header {
24904	if c.header_ == nil {
24905		c.header_ = make(http.Header)
24906	}
24907	return c.header_
24908}
24909
24910func (c *ProjectsAgentIntentsCreateCall) doRequest(alt string) (*http.Response, error) {
24911	reqHeaders := make(http.Header)
24912	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20211027")
24913	for k, v := range c.header_ {
24914		reqHeaders[k] = v
24915	}
24916	reqHeaders.Set("User-Agent", c.s.userAgent())
24917	var body io.Reader = nil
24918	body, err := googleapi.WithoutDataWrapper.JSONReader(c.googleclouddialogflowv2intent)
24919	if err != nil {
24920		return nil, err
24921	}
24922	reqHeaders.Set("Content-Type", "application/json")
24923	c.urlParams_.Set("alt", alt)
24924	c.urlParams_.Set("prettyPrint", "false")
24925	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+parent}/intents")
24926	urls += "?" + c.urlParams_.Encode()
24927	req, err := http.NewRequest("POST", urls, body)
24928	if err != nil {
24929		return nil, err
24930	}
24931	req.Header = reqHeaders
24932	googleapi.Expand(req.URL, map[string]string{
24933		"parent": c.parent,
24934	})
24935	return gensupport.SendRequest(c.ctx_, c.s.client, req)
24936}
24937
24938// Do executes the "dialogflow.projects.agent.intents.create" call.
24939// Exactly one of *GoogleCloudDialogflowV2Intent or error will be
24940// non-nil. Any non-2xx status code is an error. Response headers are in
24941// either *GoogleCloudDialogflowV2Intent.ServerResponse.Header or (if a
24942// response was returned at all) in error.(*googleapi.Error).Header. Use
24943// googleapi.IsNotModified to check whether the returned error was
24944// because http.StatusNotModified was returned.
24945func (c *ProjectsAgentIntentsCreateCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDialogflowV2Intent, error) {
24946	gensupport.SetOptions(c.urlParams_, opts...)
24947	res, err := c.doRequest("json")
24948	if res != nil && res.StatusCode == http.StatusNotModified {
24949		if res.Body != nil {
24950			res.Body.Close()
24951		}
24952		return nil, &googleapi.Error{
24953			Code:   res.StatusCode,
24954			Header: res.Header,
24955		}
24956	}
24957	if err != nil {
24958		return nil, err
24959	}
24960	defer googleapi.CloseBody(res)
24961	if err := googleapi.CheckResponse(res); err != nil {
24962		return nil, err
24963	}
24964	ret := &GoogleCloudDialogflowV2Intent{
24965		ServerResponse: googleapi.ServerResponse{
24966			Header:         res.Header,
24967			HTTPStatusCode: res.StatusCode,
24968		},
24969	}
24970	target := &ret
24971	if err := gensupport.DecodeResponse(target, res); err != nil {
24972		return nil, err
24973	}
24974	return ret, nil
24975	// {
24976	//   "description": "Creates an intent in the specified agent. Note: You should always train an agent prior to sending it queries. See the [training documentation](https://cloud.google.com/dialogflow/es/docs/training).",
24977	//   "flatPath": "v2/projects/{projectsId}/agent/intents",
24978	//   "httpMethod": "POST",
24979	//   "id": "dialogflow.projects.agent.intents.create",
24980	//   "parameterOrder": [
24981	//     "parent"
24982	//   ],
24983	//   "parameters": {
24984	//     "intentView": {
24985	//       "description": "Optional. The resource view to apply to the returned intent.",
24986	//       "enum": [
24987	//         "INTENT_VIEW_UNSPECIFIED",
24988	//         "INTENT_VIEW_FULL"
24989	//       ],
24990	//       "enumDescriptions": [
24991	//         "Training phrases field is not populated in the response.",
24992	//         "All fields are populated."
24993	//       ],
24994	//       "location": "query",
24995	//       "type": "string"
24996	//     },
24997	//     "languageCode": {
24998	//       "description": "Optional. The language used to access language-specific data. If not specified, the agent's default language is used. For more information, see [Multilingual intent and entity data](https://cloud.google.com/dialogflow/docs/agents-multilingual#intent-entity).",
24999	//       "location": "query",
25000	//       "type": "string"
25001	//     },
25002	//     "parent": {
25003	//       "description": "Required. The agent to create a intent for. Format: `projects//agent`.",
25004	//       "location": "path",
25005	//       "pattern": "^projects/[^/]+/agent$",
25006	//       "required": true,
25007	//       "type": "string"
25008	//     }
25009	//   },
25010	//   "path": "v2/{+parent}/intents",
25011	//   "request": {
25012	//     "$ref": "GoogleCloudDialogflowV2Intent"
25013	//   },
25014	//   "response": {
25015	//     "$ref": "GoogleCloudDialogflowV2Intent"
25016	//   },
25017	//   "scopes": [
25018	//     "https://www.googleapis.com/auth/cloud-platform",
25019	//     "https://www.googleapis.com/auth/dialogflow"
25020	//   ]
25021	// }
25022
25023}
25024
25025// method id "dialogflow.projects.agent.intents.delete":
25026
25027type ProjectsAgentIntentsDeleteCall struct {
25028	s          *Service
25029	name       string
25030	urlParams_ gensupport.URLParams
25031	ctx_       context.Context
25032	header_    http.Header
25033}
25034
25035// Delete: Deletes the specified intent and its direct or indirect
25036// followup intents. Note: You should always train an agent prior to
25037// sending it queries. See the training documentation
25038// (https://cloud.google.com/dialogflow/es/docs/training).
25039//
25040// - name: The name of the intent to delete. If this intent has direct
25041//   or indirect followup intents, we also delete them. Format:
25042//   `projects//agent/intents/`.
25043func (r *ProjectsAgentIntentsService) Delete(name string) *ProjectsAgentIntentsDeleteCall {
25044	c := &ProjectsAgentIntentsDeleteCall{s: r.s, urlParams_: make(gensupport.URLParams)}
25045	c.name = name
25046	return c
25047}
25048
25049// Fields allows partial responses to be retrieved. See
25050// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
25051// for more information.
25052func (c *ProjectsAgentIntentsDeleteCall) Fields(s ...googleapi.Field) *ProjectsAgentIntentsDeleteCall {
25053	c.urlParams_.Set("fields", googleapi.CombineFields(s))
25054	return c
25055}
25056
25057// Context sets the context to be used in this call's Do method. Any
25058// pending HTTP request will be aborted if the provided context is
25059// canceled.
25060func (c *ProjectsAgentIntentsDeleteCall) Context(ctx context.Context) *ProjectsAgentIntentsDeleteCall {
25061	c.ctx_ = ctx
25062	return c
25063}
25064
25065// Header returns an http.Header that can be modified by the caller to
25066// add HTTP headers to the request.
25067func (c *ProjectsAgentIntentsDeleteCall) Header() http.Header {
25068	if c.header_ == nil {
25069		c.header_ = make(http.Header)
25070	}
25071	return c.header_
25072}
25073
25074func (c *ProjectsAgentIntentsDeleteCall) doRequest(alt string) (*http.Response, error) {
25075	reqHeaders := make(http.Header)
25076	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20211027")
25077	for k, v := range c.header_ {
25078		reqHeaders[k] = v
25079	}
25080	reqHeaders.Set("User-Agent", c.s.userAgent())
25081	var body io.Reader = nil
25082	c.urlParams_.Set("alt", alt)
25083	c.urlParams_.Set("prettyPrint", "false")
25084	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+name}")
25085	urls += "?" + c.urlParams_.Encode()
25086	req, err := http.NewRequest("DELETE", urls, body)
25087	if err != nil {
25088		return nil, err
25089	}
25090	req.Header = reqHeaders
25091	googleapi.Expand(req.URL, map[string]string{
25092		"name": c.name,
25093	})
25094	return gensupport.SendRequest(c.ctx_, c.s.client, req)
25095}
25096
25097// Do executes the "dialogflow.projects.agent.intents.delete" call.
25098// Exactly one of *GoogleProtobufEmpty or error will be non-nil. Any
25099// non-2xx status code is an error. Response headers are in either
25100// *GoogleProtobufEmpty.ServerResponse.Header or (if a response was
25101// returned at all) in error.(*googleapi.Error).Header. Use
25102// googleapi.IsNotModified to check whether the returned error was
25103// because http.StatusNotModified was returned.
25104func (c *ProjectsAgentIntentsDeleteCall) Do(opts ...googleapi.CallOption) (*GoogleProtobufEmpty, error) {
25105	gensupport.SetOptions(c.urlParams_, opts...)
25106	res, err := c.doRequest("json")
25107	if res != nil && res.StatusCode == http.StatusNotModified {
25108		if res.Body != nil {
25109			res.Body.Close()
25110		}
25111		return nil, &googleapi.Error{
25112			Code:   res.StatusCode,
25113			Header: res.Header,
25114		}
25115	}
25116	if err != nil {
25117		return nil, err
25118	}
25119	defer googleapi.CloseBody(res)
25120	if err := googleapi.CheckResponse(res); err != nil {
25121		return nil, err
25122	}
25123	ret := &GoogleProtobufEmpty{
25124		ServerResponse: googleapi.ServerResponse{
25125			Header:         res.Header,
25126			HTTPStatusCode: res.StatusCode,
25127		},
25128	}
25129	target := &ret
25130	if err := gensupport.DecodeResponse(target, res); err != nil {
25131		return nil, err
25132	}
25133	return ret, nil
25134	// {
25135	//   "description": "Deletes the specified intent and its direct or indirect followup intents. Note: You should always train an agent prior to sending it queries. See the [training documentation](https://cloud.google.com/dialogflow/es/docs/training).",
25136	//   "flatPath": "v2/projects/{projectsId}/agent/intents/{intentsId}",
25137	//   "httpMethod": "DELETE",
25138	//   "id": "dialogflow.projects.agent.intents.delete",
25139	//   "parameterOrder": [
25140	//     "name"
25141	//   ],
25142	//   "parameters": {
25143	//     "name": {
25144	//       "description": "Required. The name of the intent to delete. If this intent has direct or indirect followup intents, we also delete them. Format: `projects//agent/intents/`.",
25145	//       "location": "path",
25146	//       "pattern": "^projects/[^/]+/agent/intents/[^/]+$",
25147	//       "required": true,
25148	//       "type": "string"
25149	//     }
25150	//   },
25151	//   "path": "v2/{+name}",
25152	//   "response": {
25153	//     "$ref": "GoogleProtobufEmpty"
25154	//   },
25155	//   "scopes": [
25156	//     "https://www.googleapis.com/auth/cloud-platform",
25157	//     "https://www.googleapis.com/auth/dialogflow"
25158	//   ]
25159	// }
25160
25161}
25162
25163// method id "dialogflow.projects.agent.intents.get":
25164
25165type ProjectsAgentIntentsGetCall struct {
25166	s            *Service
25167	name         string
25168	urlParams_   gensupport.URLParams
25169	ifNoneMatch_ string
25170	ctx_         context.Context
25171	header_      http.Header
25172}
25173
25174// Get: Retrieves the specified intent.
25175//
25176// - name: The name of the intent. Format: `projects//agent/intents/`.
25177func (r *ProjectsAgentIntentsService) Get(name string) *ProjectsAgentIntentsGetCall {
25178	c := &ProjectsAgentIntentsGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
25179	c.name = name
25180	return c
25181}
25182
25183// IntentView sets the optional parameter "intentView": The resource
25184// view to apply to the returned intent.
25185//
25186// Possible values:
25187//   "INTENT_VIEW_UNSPECIFIED" - Training phrases field is not populated
25188// in the response.
25189//   "INTENT_VIEW_FULL" - All fields are populated.
25190func (c *ProjectsAgentIntentsGetCall) IntentView(intentView string) *ProjectsAgentIntentsGetCall {
25191	c.urlParams_.Set("intentView", intentView)
25192	return c
25193}
25194
25195// LanguageCode sets the optional parameter "languageCode": The language
25196// used to access language-specific data. If not specified, the agent's
25197// default language is used. For more information, see Multilingual
25198// intent and entity data
25199// (https://cloud.google.com/dialogflow/docs/agents-multilingual#intent-entity).
25200func (c *ProjectsAgentIntentsGetCall) LanguageCode(languageCode string) *ProjectsAgentIntentsGetCall {
25201	c.urlParams_.Set("languageCode", languageCode)
25202	return c
25203}
25204
25205// Fields allows partial responses to be retrieved. See
25206// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
25207// for more information.
25208func (c *ProjectsAgentIntentsGetCall) Fields(s ...googleapi.Field) *ProjectsAgentIntentsGetCall {
25209	c.urlParams_.Set("fields", googleapi.CombineFields(s))
25210	return c
25211}
25212
25213// IfNoneMatch sets the optional parameter which makes the operation
25214// fail if the object's ETag matches the given value. This is useful for
25215// getting updates only after the object has changed since the last
25216// request. Use googleapi.IsNotModified to check whether the response
25217// error from Do is the result of In-None-Match.
25218func (c *ProjectsAgentIntentsGetCall) IfNoneMatch(entityTag string) *ProjectsAgentIntentsGetCall {
25219	c.ifNoneMatch_ = entityTag
25220	return c
25221}
25222
25223// Context sets the context to be used in this call's Do method. Any
25224// pending HTTP request will be aborted if the provided context is
25225// canceled.
25226func (c *ProjectsAgentIntentsGetCall) Context(ctx context.Context) *ProjectsAgentIntentsGetCall {
25227	c.ctx_ = ctx
25228	return c
25229}
25230
25231// Header returns an http.Header that can be modified by the caller to
25232// add HTTP headers to the request.
25233func (c *ProjectsAgentIntentsGetCall) Header() http.Header {
25234	if c.header_ == nil {
25235		c.header_ = make(http.Header)
25236	}
25237	return c.header_
25238}
25239
25240func (c *ProjectsAgentIntentsGetCall) doRequest(alt string) (*http.Response, error) {
25241	reqHeaders := make(http.Header)
25242	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20211027")
25243	for k, v := range c.header_ {
25244		reqHeaders[k] = v
25245	}
25246	reqHeaders.Set("User-Agent", c.s.userAgent())
25247	if c.ifNoneMatch_ != "" {
25248		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
25249	}
25250	var body io.Reader = nil
25251	c.urlParams_.Set("alt", alt)
25252	c.urlParams_.Set("prettyPrint", "false")
25253	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+name}")
25254	urls += "?" + c.urlParams_.Encode()
25255	req, err := http.NewRequest("GET", urls, body)
25256	if err != nil {
25257		return nil, err
25258	}
25259	req.Header = reqHeaders
25260	googleapi.Expand(req.URL, map[string]string{
25261		"name": c.name,
25262	})
25263	return gensupport.SendRequest(c.ctx_, c.s.client, req)
25264}
25265
25266// Do executes the "dialogflow.projects.agent.intents.get" call.
25267// Exactly one of *GoogleCloudDialogflowV2Intent or error will be
25268// non-nil. Any non-2xx status code is an error. Response headers are in
25269// either *GoogleCloudDialogflowV2Intent.ServerResponse.Header or (if a
25270// response was returned at all) in error.(*googleapi.Error).Header. Use
25271// googleapi.IsNotModified to check whether the returned error was
25272// because http.StatusNotModified was returned.
25273func (c *ProjectsAgentIntentsGetCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDialogflowV2Intent, error) {
25274	gensupport.SetOptions(c.urlParams_, opts...)
25275	res, err := c.doRequest("json")
25276	if res != nil && res.StatusCode == http.StatusNotModified {
25277		if res.Body != nil {
25278			res.Body.Close()
25279		}
25280		return nil, &googleapi.Error{
25281			Code:   res.StatusCode,
25282			Header: res.Header,
25283		}
25284	}
25285	if err != nil {
25286		return nil, err
25287	}
25288	defer googleapi.CloseBody(res)
25289	if err := googleapi.CheckResponse(res); err != nil {
25290		return nil, err
25291	}
25292	ret := &GoogleCloudDialogflowV2Intent{
25293		ServerResponse: googleapi.ServerResponse{
25294			Header:         res.Header,
25295			HTTPStatusCode: res.StatusCode,
25296		},
25297	}
25298	target := &ret
25299	if err := gensupport.DecodeResponse(target, res); err != nil {
25300		return nil, err
25301	}
25302	return ret, nil
25303	// {
25304	//   "description": "Retrieves the specified intent.",
25305	//   "flatPath": "v2/projects/{projectsId}/agent/intents/{intentsId}",
25306	//   "httpMethod": "GET",
25307	//   "id": "dialogflow.projects.agent.intents.get",
25308	//   "parameterOrder": [
25309	//     "name"
25310	//   ],
25311	//   "parameters": {
25312	//     "intentView": {
25313	//       "description": "Optional. The resource view to apply to the returned intent.",
25314	//       "enum": [
25315	//         "INTENT_VIEW_UNSPECIFIED",
25316	//         "INTENT_VIEW_FULL"
25317	//       ],
25318	//       "enumDescriptions": [
25319	//         "Training phrases field is not populated in the response.",
25320	//         "All fields are populated."
25321	//       ],
25322	//       "location": "query",
25323	//       "type": "string"
25324	//     },
25325	//     "languageCode": {
25326	//       "description": "Optional. The language used to access language-specific data. If not specified, the agent's default language is used. For more information, see [Multilingual intent and entity data](https://cloud.google.com/dialogflow/docs/agents-multilingual#intent-entity).",
25327	//       "location": "query",
25328	//       "type": "string"
25329	//     },
25330	//     "name": {
25331	//       "description": "Required. The name of the intent. Format: `projects//agent/intents/`.",
25332	//       "location": "path",
25333	//       "pattern": "^projects/[^/]+/agent/intents/[^/]+$",
25334	//       "required": true,
25335	//       "type": "string"
25336	//     }
25337	//   },
25338	//   "path": "v2/{+name}",
25339	//   "response": {
25340	//     "$ref": "GoogleCloudDialogflowV2Intent"
25341	//   },
25342	//   "scopes": [
25343	//     "https://www.googleapis.com/auth/cloud-platform",
25344	//     "https://www.googleapis.com/auth/dialogflow"
25345	//   ]
25346	// }
25347
25348}
25349
25350// method id "dialogflow.projects.agent.intents.list":
25351
25352type ProjectsAgentIntentsListCall struct {
25353	s            *Service
25354	parent       string
25355	urlParams_   gensupport.URLParams
25356	ifNoneMatch_ string
25357	ctx_         context.Context
25358	header_      http.Header
25359}
25360
25361// List: Returns the list of all intents in the specified agent.
25362//
25363// - parent: The agent to list all intents from. Format:
25364//   `projects//agent` or `projects//locations//agent`. Alternatively,
25365//   you can specify the environment to list intents for. Format:
25366//   `projects//agent/environments/` or
25367//   `projects//locations//agent/environments/`. Note: training phrases
25368//   of the intents will not be returned for non-draft environment.
25369func (r *ProjectsAgentIntentsService) List(parent string) *ProjectsAgentIntentsListCall {
25370	c := &ProjectsAgentIntentsListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
25371	c.parent = parent
25372	return c
25373}
25374
25375// IntentView sets the optional parameter "intentView": The resource
25376// view to apply to the returned intent.
25377//
25378// Possible values:
25379//   "INTENT_VIEW_UNSPECIFIED" - Training phrases field is not populated
25380// in the response.
25381//   "INTENT_VIEW_FULL" - All fields are populated.
25382func (c *ProjectsAgentIntentsListCall) IntentView(intentView string) *ProjectsAgentIntentsListCall {
25383	c.urlParams_.Set("intentView", intentView)
25384	return c
25385}
25386
25387// LanguageCode sets the optional parameter "languageCode": The language
25388// used to access language-specific data. If not specified, the agent's
25389// default language is used. For more information, see Multilingual
25390// intent and entity data
25391// (https://cloud.google.com/dialogflow/docs/agents-multilingual#intent-entity).
25392func (c *ProjectsAgentIntentsListCall) LanguageCode(languageCode string) *ProjectsAgentIntentsListCall {
25393	c.urlParams_.Set("languageCode", languageCode)
25394	return c
25395}
25396
25397// PageSize sets the optional parameter "pageSize": The maximum number
25398// of items to return in a single page. By default 100 and at most 1000.
25399func (c *ProjectsAgentIntentsListCall) PageSize(pageSize int64) *ProjectsAgentIntentsListCall {
25400	c.urlParams_.Set("pageSize", fmt.Sprint(pageSize))
25401	return c
25402}
25403
25404// PageToken sets the optional parameter "pageToken": The
25405// next_page_token value returned from a previous list request.
25406func (c *ProjectsAgentIntentsListCall) PageToken(pageToken string) *ProjectsAgentIntentsListCall {
25407	c.urlParams_.Set("pageToken", pageToken)
25408	return c
25409}
25410
25411// Fields allows partial responses to be retrieved. See
25412// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
25413// for more information.
25414func (c *ProjectsAgentIntentsListCall) Fields(s ...googleapi.Field) *ProjectsAgentIntentsListCall {
25415	c.urlParams_.Set("fields", googleapi.CombineFields(s))
25416	return c
25417}
25418
25419// IfNoneMatch sets the optional parameter which makes the operation
25420// fail if the object's ETag matches the given value. This is useful for
25421// getting updates only after the object has changed since the last
25422// request. Use googleapi.IsNotModified to check whether the response
25423// error from Do is the result of In-None-Match.
25424func (c *ProjectsAgentIntentsListCall) IfNoneMatch(entityTag string) *ProjectsAgentIntentsListCall {
25425	c.ifNoneMatch_ = entityTag
25426	return c
25427}
25428
25429// Context sets the context to be used in this call's Do method. Any
25430// pending HTTP request will be aborted if the provided context is
25431// canceled.
25432func (c *ProjectsAgentIntentsListCall) Context(ctx context.Context) *ProjectsAgentIntentsListCall {
25433	c.ctx_ = ctx
25434	return c
25435}
25436
25437// Header returns an http.Header that can be modified by the caller to
25438// add HTTP headers to the request.
25439func (c *ProjectsAgentIntentsListCall) Header() http.Header {
25440	if c.header_ == nil {
25441		c.header_ = make(http.Header)
25442	}
25443	return c.header_
25444}
25445
25446func (c *ProjectsAgentIntentsListCall) doRequest(alt string) (*http.Response, error) {
25447	reqHeaders := make(http.Header)
25448	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20211027")
25449	for k, v := range c.header_ {
25450		reqHeaders[k] = v
25451	}
25452	reqHeaders.Set("User-Agent", c.s.userAgent())
25453	if c.ifNoneMatch_ != "" {
25454		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
25455	}
25456	var body io.Reader = nil
25457	c.urlParams_.Set("alt", alt)
25458	c.urlParams_.Set("prettyPrint", "false")
25459	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+parent}/intents")
25460	urls += "?" + c.urlParams_.Encode()
25461	req, err := http.NewRequest("GET", urls, body)
25462	if err != nil {
25463		return nil, err
25464	}
25465	req.Header = reqHeaders
25466	googleapi.Expand(req.URL, map[string]string{
25467		"parent": c.parent,
25468	})
25469	return gensupport.SendRequest(c.ctx_, c.s.client, req)
25470}
25471
25472// Do executes the "dialogflow.projects.agent.intents.list" call.
25473// Exactly one of *GoogleCloudDialogflowV2ListIntentsResponse or error
25474// will be non-nil. Any non-2xx status code is an error. Response
25475// headers are in either
25476// *GoogleCloudDialogflowV2ListIntentsResponse.ServerResponse.Header or
25477// (if a response was returned at all) in
25478// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
25479// whether the returned error was because http.StatusNotModified was
25480// returned.
25481func (c *ProjectsAgentIntentsListCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDialogflowV2ListIntentsResponse, error) {
25482	gensupport.SetOptions(c.urlParams_, opts...)
25483	res, err := c.doRequest("json")
25484	if res != nil && res.StatusCode == http.StatusNotModified {
25485		if res.Body != nil {
25486			res.Body.Close()
25487		}
25488		return nil, &googleapi.Error{
25489			Code:   res.StatusCode,
25490			Header: res.Header,
25491		}
25492	}
25493	if err != nil {
25494		return nil, err
25495	}
25496	defer googleapi.CloseBody(res)
25497	if err := googleapi.CheckResponse(res); err != nil {
25498		return nil, err
25499	}
25500	ret := &GoogleCloudDialogflowV2ListIntentsResponse{
25501		ServerResponse: googleapi.ServerResponse{
25502			Header:         res.Header,
25503			HTTPStatusCode: res.StatusCode,
25504		},
25505	}
25506	target := &ret
25507	if err := gensupport.DecodeResponse(target, res); err != nil {
25508		return nil, err
25509	}
25510	return ret, nil
25511	// {
25512	//   "description": "Returns the list of all intents in the specified agent.",
25513	//   "flatPath": "v2/projects/{projectsId}/agent/intents",
25514	//   "httpMethod": "GET",
25515	//   "id": "dialogflow.projects.agent.intents.list",
25516	//   "parameterOrder": [
25517	//     "parent"
25518	//   ],
25519	//   "parameters": {
25520	//     "intentView": {
25521	//       "description": "Optional. The resource view to apply to the returned intent.",
25522	//       "enum": [
25523	//         "INTENT_VIEW_UNSPECIFIED",
25524	//         "INTENT_VIEW_FULL"
25525	//       ],
25526	//       "enumDescriptions": [
25527	//         "Training phrases field is not populated in the response.",
25528	//         "All fields are populated."
25529	//       ],
25530	//       "location": "query",
25531	//       "type": "string"
25532	//     },
25533	//     "languageCode": {
25534	//       "description": "Optional. The language used to access language-specific data. If not specified, the agent's default language is used. For more information, see [Multilingual intent and entity data](https://cloud.google.com/dialogflow/docs/agents-multilingual#intent-entity).",
25535	//       "location": "query",
25536	//       "type": "string"
25537	//     },
25538	//     "pageSize": {
25539	//       "description": "Optional. The maximum number of items to return in a single page. By default 100 and at most 1000.",
25540	//       "format": "int32",
25541	//       "location": "query",
25542	//       "type": "integer"
25543	//     },
25544	//     "pageToken": {
25545	//       "description": "Optional. The next_page_token value returned from a previous list request.",
25546	//       "location": "query",
25547	//       "type": "string"
25548	//     },
25549	//     "parent": {
25550	//       "description": "Required. The agent to list all intents from. Format: `projects//agent` or `projects//locations//agent`. Alternatively, you can specify the environment to list intents for. Format: `projects//agent/environments/` or `projects//locations//agent/environments/`. Note: training phrases of the intents will not be returned for non-draft environment.",
25551	//       "location": "path",
25552	//       "pattern": "^projects/[^/]+/agent$",
25553	//       "required": true,
25554	//       "type": "string"
25555	//     }
25556	//   },
25557	//   "path": "v2/{+parent}/intents",
25558	//   "response": {
25559	//     "$ref": "GoogleCloudDialogflowV2ListIntentsResponse"
25560	//   },
25561	//   "scopes": [
25562	//     "https://www.googleapis.com/auth/cloud-platform",
25563	//     "https://www.googleapis.com/auth/dialogflow"
25564	//   ]
25565	// }
25566
25567}
25568
25569// Pages invokes f for each page of results.
25570// A non-nil error returned from f will halt the iteration.
25571// The provided context supersedes any context provided to the Context method.
25572func (c *ProjectsAgentIntentsListCall) Pages(ctx context.Context, f func(*GoogleCloudDialogflowV2ListIntentsResponse) error) error {
25573	c.ctx_ = ctx
25574	defer c.PageToken(c.urlParams_.Get("pageToken")) // reset paging to original point
25575	for {
25576		x, err := c.Do()
25577		if err != nil {
25578			return err
25579		}
25580		if err := f(x); err != nil {
25581			return err
25582		}
25583		if x.NextPageToken == "" {
25584			return nil
25585		}
25586		c.PageToken(x.NextPageToken)
25587	}
25588}
25589
25590// method id "dialogflow.projects.agent.intents.patch":
25591
25592type ProjectsAgentIntentsPatchCall struct {
25593	s                             *Service
25594	nameid                        string
25595	googleclouddialogflowv2intent *GoogleCloudDialogflowV2Intent
25596	urlParams_                    gensupport.URLParams
25597	ctx_                          context.Context
25598	header_                       http.Header
25599}
25600
25601// Patch: Updates the specified intent. Note: You should always train an
25602// agent prior to sending it queries. See the training documentation
25603// (https://cloud.google.com/dialogflow/es/docs/training).
25604//
25605// - name: Optional. The unique identifier of this intent. Required for
25606//   Intents.UpdateIntent and Intents.BatchUpdateIntents methods.
25607//   Format: `projects//agent/intents/`.
25608func (r *ProjectsAgentIntentsService) Patch(nameid string, googleclouddialogflowv2intent *GoogleCloudDialogflowV2Intent) *ProjectsAgentIntentsPatchCall {
25609	c := &ProjectsAgentIntentsPatchCall{s: r.s, urlParams_: make(gensupport.URLParams)}
25610	c.nameid = nameid
25611	c.googleclouddialogflowv2intent = googleclouddialogflowv2intent
25612	return c
25613}
25614
25615// IntentView sets the optional parameter "intentView": The resource
25616// view to apply to the returned intent.
25617//
25618// Possible values:
25619//   "INTENT_VIEW_UNSPECIFIED" - Training phrases field is not populated
25620// in the response.
25621//   "INTENT_VIEW_FULL" - All fields are populated.
25622func (c *ProjectsAgentIntentsPatchCall) IntentView(intentView string) *ProjectsAgentIntentsPatchCall {
25623	c.urlParams_.Set("intentView", intentView)
25624	return c
25625}
25626
25627// LanguageCode sets the optional parameter "languageCode": The language
25628// used to access language-specific data. If not specified, the agent's
25629// default language is used. For more information, see Multilingual
25630// intent and entity data
25631// (https://cloud.google.com/dialogflow/docs/agents-multilingual#intent-entity).
25632func (c *ProjectsAgentIntentsPatchCall) LanguageCode(languageCode string) *ProjectsAgentIntentsPatchCall {
25633	c.urlParams_.Set("languageCode", languageCode)
25634	return c
25635}
25636
25637// UpdateMask sets the optional parameter "updateMask": The mask to
25638// control which fields get updated.
25639func (c *ProjectsAgentIntentsPatchCall) UpdateMask(updateMask string) *ProjectsAgentIntentsPatchCall {
25640	c.urlParams_.Set("updateMask", updateMask)
25641	return c
25642}
25643
25644// Fields allows partial responses to be retrieved. See
25645// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
25646// for more information.
25647func (c *ProjectsAgentIntentsPatchCall) Fields(s ...googleapi.Field) *ProjectsAgentIntentsPatchCall {
25648	c.urlParams_.Set("fields", googleapi.CombineFields(s))
25649	return c
25650}
25651
25652// Context sets the context to be used in this call's Do method. Any
25653// pending HTTP request will be aborted if the provided context is
25654// canceled.
25655func (c *ProjectsAgentIntentsPatchCall) Context(ctx context.Context) *ProjectsAgentIntentsPatchCall {
25656	c.ctx_ = ctx
25657	return c
25658}
25659
25660// Header returns an http.Header that can be modified by the caller to
25661// add HTTP headers to the request.
25662func (c *ProjectsAgentIntentsPatchCall) Header() http.Header {
25663	if c.header_ == nil {
25664		c.header_ = make(http.Header)
25665	}
25666	return c.header_
25667}
25668
25669func (c *ProjectsAgentIntentsPatchCall) doRequest(alt string) (*http.Response, error) {
25670	reqHeaders := make(http.Header)
25671	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20211027")
25672	for k, v := range c.header_ {
25673		reqHeaders[k] = v
25674	}
25675	reqHeaders.Set("User-Agent", c.s.userAgent())
25676	var body io.Reader = nil
25677	body, err := googleapi.WithoutDataWrapper.JSONReader(c.googleclouddialogflowv2intent)
25678	if err != nil {
25679		return nil, err
25680	}
25681	reqHeaders.Set("Content-Type", "application/json")
25682	c.urlParams_.Set("alt", alt)
25683	c.urlParams_.Set("prettyPrint", "false")
25684	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+name}")
25685	urls += "?" + c.urlParams_.Encode()
25686	req, err := http.NewRequest("PATCH", urls, body)
25687	if err != nil {
25688		return nil, err
25689	}
25690	req.Header = reqHeaders
25691	googleapi.Expand(req.URL, map[string]string{
25692		"name": c.nameid,
25693	})
25694	return gensupport.SendRequest(c.ctx_, c.s.client, req)
25695}
25696
25697// Do executes the "dialogflow.projects.agent.intents.patch" call.
25698// Exactly one of *GoogleCloudDialogflowV2Intent or error will be
25699// non-nil. Any non-2xx status code is an error. Response headers are in
25700// either *GoogleCloudDialogflowV2Intent.ServerResponse.Header or (if a
25701// response was returned at all) in error.(*googleapi.Error).Header. Use
25702// googleapi.IsNotModified to check whether the returned error was
25703// because http.StatusNotModified was returned.
25704func (c *ProjectsAgentIntentsPatchCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDialogflowV2Intent, error) {
25705	gensupport.SetOptions(c.urlParams_, opts...)
25706	res, err := c.doRequest("json")
25707	if res != nil && res.StatusCode == http.StatusNotModified {
25708		if res.Body != nil {
25709			res.Body.Close()
25710		}
25711		return nil, &googleapi.Error{
25712			Code:   res.StatusCode,
25713			Header: res.Header,
25714		}
25715	}
25716	if err != nil {
25717		return nil, err
25718	}
25719	defer googleapi.CloseBody(res)
25720	if err := googleapi.CheckResponse(res); err != nil {
25721		return nil, err
25722	}
25723	ret := &GoogleCloudDialogflowV2Intent{
25724		ServerResponse: googleapi.ServerResponse{
25725			Header:         res.Header,
25726			HTTPStatusCode: res.StatusCode,
25727		},
25728	}
25729	target := &ret
25730	if err := gensupport.DecodeResponse(target, res); err != nil {
25731		return nil, err
25732	}
25733	return ret, nil
25734	// {
25735	//   "description": "Updates the specified intent. Note: You should always train an agent prior to sending it queries. See the [training documentation](https://cloud.google.com/dialogflow/es/docs/training).",
25736	//   "flatPath": "v2/projects/{projectsId}/agent/intents/{intentsId}",
25737	//   "httpMethod": "PATCH",
25738	//   "id": "dialogflow.projects.agent.intents.patch",
25739	//   "parameterOrder": [
25740	//     "name"
25741	//   ],
25742	//   "parameters": {
25743	//     "intentView": {
25744	//       "description": "Optional. The resource view to apply to the returned intent.",
25745	//       "enum": [
25746	//         "INTENT_VIEW_UNSPECIFIED",
25747	//         "INTENT_VIEW_FULL"
25748	//       ],
25749	//       "enumDescriptions": [
25750	//         "Training phrases field is not populated in the response.",
25751	//         "All fields are populated."
25752	//       ],
25753	//       "location": "query",
25754	//       "type": "string"
25755	//     },
25756	//     "languageCode": {
25757	//       "description": "Optional. The language used to access language-specific data. If not specified, the agent's default language is used. For more information, see [Multilingual intent and entity data](https://cloud.google.com/dialogflow/docs/agents-multilingual#intent-entity).",
25758	//       "location": "query",
25759	//       "type": "string"
25760	//     },
25761	//     "name": {
25762	//       "description": "Optional. The unique identifier of this intent. Required for Intents.UpdateIntent and Intents.BatchUpdateIntents methods. Format: `projects//agent/intents/`.",
25763	//       "location": "path",
25764	//       "pattern": "^projects/[^/]+/agent/intents/[^/]+$",
25765	//       "required": true,
25766	//       "type": "string"
25767	//     },
25768	//     "updateMask": {
25769	//       "description": "Optional. The mask to control which fields get updated.",
25770	//       "format": "google-fieldmask",
25771	//       "location": "query",
25772	//       "type": "string"
25773	//     }
25774	//   },
25775	//   "path": "v2/{+name}",
25776	//   "request": {
25777	//     "$ref": "GoogleCloudDialogflowV2Intent"
25778	//   },
25779	//   "response": {
25780	//     "$ref": "GoogleCloudDialogflowV2Intent"
25781	//   },
25782	//   "scopes": [
25783	//     "https://www.googleapis.com/auth/cloud-platform",
25784	//     "https://www.googleapis.com/auth/dialogflow"
25785	//   ]
25786	// }
25787
25788}
25789
25790// method id "dialogflow.projects.agent.knowledgeBases.create":
25791
25792type ProjectsAgentKnowledgeBasesCreateCall struct {
25793	s                                    *Service
25794	parent                               string
25795	googleclouddialogflowv2knowledgebase *GoogleCloudDialogflowV2KnowledgeBase
25796	urlParams_                           gensupport.URLParams
25797	ctx_                                 context.Context
25798	header_                              http.Header
25799}
25800
25801// Create: Creates a knowledge base.
25802//
25803// - parent: The project to create a knowledge base for. Format:
25804//   `projects//locations/`.
25805func (r *ProjectsAgentKnowledgeBasesService) Create(parent string, googleclouddialogflowv2knowledgebase *GoogleCloudDialogflowV2KnowledgeBase) *ProjectsAgentKnowledgeBasesCreateCall {
25806	c := &ProjectsAgentKnowledgeBasesCreateCall{s: r.s, urlParams_: make(gensupport.URLParams)}
25807	c.parent = parent
25808	c.googleclouddialogflowv2knowledgebase = googleclouddialogflowv2knowledgebase
25809	return c
25810}
25811
25812// Fields allows partial responses to be retrieved. See
25813// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
25814// for more information.
25815func (c *ProjectsAgentKnowledgeBasesCreateCall) Fields(s ...googleapi.Field) *ProjectsAgentKnowledgeBasesCreateCall {
25816	c.urlParams_.Set("fields", googleapi.CombineFields(s))
25817	return c
25818}
25819
25820// Context sets the context to be used in this call's Do method. Any
25821// pending HTTP request will be aborted if the provided context is
25822// canceled.
25823func (c *ProjectsAgentKnowledgeBasesCreateCall) Context(ctx context.Context) *ProjectsAgentKnowledgeBasesCreateCall {
25824	c.ctx_ = ctx
25825	return c
25826}
25827
25828// Header returns an http.Header that can be modified by the caller to
25829// add HTTP headers to the request.
25830func (c *ProjectsAgentKnowledgeBasesCreateCall) Header() http.Header {
25831	if c.header_ == nil {
25832		c.header_ = make(http.Header)
25833	}
25834	return c.header_
25835}
25836
25837func (c *ProjectsAgentKnowledgeBasesCreateCall) doRequest(alt string) (*http.Response, error) {
25838	reqHeaders := make(http.Header)
25839	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20211027")
25840	for k, v := range c.header_ {
25841		reqHeaders[k] = v
25842	}
25843	reqHeaders.Set("User-Agent", c.s.userAgent())
25844	var body io.Reader = nil
25845	body, err := googleapi.WithoutDataWrapper.JSONReader(c.googleclouddialogflowv2knowledgebase)
25846	if err != nil {
25847		return nil, err
25848	}
25849	reqHeaders.Set("Content-Type", "application/json")
25850	c.urlParams_.Set("alt", alt)
25851	c.urlParams_.Set("prettyPrint", "false")
25852	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+parent}/knowledgeBases")
25853	urls += "?" + c.urlParams_.Encode()
25854	req, err := http.NewRequest("POST", urls, body)
25855	if err != nil {
25856		return nil, err
25857	}
25858	req.Header = reqHeaders
25859	googleapi.Expand(req.URL, map[string]string{
25860		"parent": c.parent,
25861	})
25862	return gensupport.SendRequest(c.ctx_, c.s.client, req)
25863}
25864
25865// Do executes the "dialogflow.projects.agent.knowledgeBases.create" call.
25866// Exactly one of *GoogleCloudDialogflowV2KnowledgeBase or error will be
25867// non-nil. Any non-2xx status code is an error. Response headers are in
25868// either *GoogleCloudDialogflowV2KnowledgeBase.ServerResponse.Header or
25869// (if a response was returned at all) in
25870// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
25871// whether the returned error was because http.StatusNotModified was
25872// returned.
25873func (c *ProjectsAgentKnowledgeBasesCreateCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDialogflowV2KnowledgeBase, error) {
25874	gensupport.SetOptions(c.urlParams_, opts...)
25875	res, err := c.doRequest("json")
25876	if res != nil && res.StatusCode == http.StatusNotModified {
25877		if res.Body != nil {
25878			res.Body.Close()
25879		}
25880		return nil, &googleapi.Error{
25881			Code:   res.StatusCode,
25882			Header: res.Header,
25883		}
25884	}
25885	if err != nil {
25886		return nil, err
25887	}
25888	defer googleapi.CloseBody(res)
25889	if err := googleapi.CheckResponse(res); err != nil {
25890		return nil, err
25891	}
25892	ret := &GoogleCloudDialogflowV2KnowledgeBase{
25893		ServerResponse: googleapi.ServerResponse{
25894			Header:         res.Header,
25895			HTTPStatusCode: res.StatusCode,
25896		},
25897	}
25898	target := &ret
25899	if err := gensupport.DecodeResponse(target, res); err != nil {
25900		return nil, err
25901	}
25902	return ret, nil
25903	// {
25904	//   "description": "Creates a knowledge base.",
25905	//   "flatPath": "v2/projects/{projectsId}/agent/knowledgeBases",
25906	//   "httpMethod": "POST",
25907	//   "id": "dialogflow.projects.agent.knowledgeBases.create",
25908	//   "parameterOrder": [
25909	//     "parent"
25910	//   ],
25911	//   "parameters": {
25912	//     "parent": {
25913	//       "description": "Required. The project to create a knowledge base for. Format: `projects//locations/`.",
25914	//       "location": "path",
25915	//       "pattern": "^projects/[^/]+/agent$",
25916	//       "required": true,
25917	//       "type": "string"
25918	//     }
25919	//   },
25920	//   "path": "v2/{+parent}/knowledgeBases",
25921	//   "request": {
25922	//     "$ref": "GoogleCloudDialogflowV2KnowledgeBase"
25923	//   },
25924	//   "response": {
25925	//     "$ref": "GoogleCloudDialogflowV2KnowledgeBase"
25926	//   },
25927	//   "scopes": [
25928	//     "https://www.googleapis.com/auth/cloud-platform",
25929	//     "https://www.googleapis.com/auth/dialogflow"
25930	//   ]
25931	// }
25932
25933}
25934
25935// method id "dialogflow.projects.agent.knowledgeBases.delete":
25936
25937type ProjectsAgentKnowledgeBasesDeleteCall struct {
25938	s          *Service
25939	name       string
25940	urlParams_ gensupport.URLParams
25941	ctx_       context.Context
25942	header_    http.Header
25943}
25944
25945// Delete: Deletes the specified knowledge base.
25946//
25947// - name: The name of the knowledge base to delete. Format:
25948//   `projects//locations//knowledgeBases/`.
25949func (r *ProjectsAgentKnowledgeBasesService) Delete(name string) *ProjectsAgentKnowledgeBasesDeleteCall {
25950	c := &ProjectsAgentKnowledgeBasesDeleteCall{s: r.s, urlParams_: make(gensupport.URLParams)}
25951	c.name = name
25952	return c
25953}
25954
25955// Force sets the optional parameter "force": Force deletes the
25956// knowledge base. When set to true, any documents in the knowledge base
25957// are also deleted.
25958func (c *ProjectsAgentKnowledgeBasesDeleteCall) Force(force bool) *ProjectsAgentKnowledgeBasesDeleteCall {
25959	c.urlParams_.Set("force", fmt.Sprint(force))
25960	return c
25961}
25962
25963// Fields allows partial responses to be retrieved. See
25964// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
25965// for more information.
25966func (c *ProjectsAgentKnowledgeBasesDeleteCall) Fields(s ...googleapi.Field) *ProjectsAgentKnowledgeBasesDeleteCall {
25967	c.urlParams_.Set("fields", googleapi.CombineFields(s))
25968	return c
25969}
25970
25971// Context sets the context to be used in this call's Do method. Any
25972// pending HTTP request will be aborted if the provided context is
25973// canceled.
25974func (c *ProjectsAgentKnowledgeBasesDeleteCall) Context(ctx context.Context) *ProjectsAgentKnowledgeBasesDeleteCall {
25975	c.ctx_ = ctx
25976	return c
25977}
25978
25979// Header returns an http.Header that can be modified by the caller to
25980// add HTTP headers to the request.
25981func (c *ProjectsAgentKnowledgeBasesDeleteCall) Header() http.Header {
25982	if c.header_ == nil {
25983		c.header_ = make(http.Header)
25984	}
25985	return c.header_
25986}
25987
25988func (c *ProjectsAgentKnowledgeBasesDeleteCall) doRequest(alt string) (*http.Response, error) {
25989	reqHeaders := make(http.Header)
25990	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20211027")
25991	for k, v := range c.header_ {
25992		reqHeaders[k] = v
25993	}
25994	reqHeaders.Set("User-Agent", c.s.userAgent())
25995	var body io.Reader = nil
25996	c.urlParams_.Set("alt", alt)
25997	c.urlParams_.Set("prettyPrint", "false")
25998	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+name}")
25999	urls += "?" + c.urlParams_.Encode()
26000	req, err := http.NewRequest("DELETE", urls, body)
26001	if err != nil {
26002		return nil, err
26003	}
26004	req.Header = reqHeaders
26005	googleapi.Expand(req.URL, map[string]string{
26006		"name": c.name,
26007	})
26008	return gensupport.SendRequest(c.ctx_, c.s.client, req)
26009}
26010
26011// Do executes the "dialogflow.projects.agent.knowledgeBases.delete" call.
26012// Exactly one of *GoogleProtobufEmpty or error will be non-nil. Any
26013// non-2xx status code is an error. Response headers are in either
26014// *GoogleProtobufEmpty.ServerResponse.Header or (if a response was
26015// returned at all) in error.(*googleapi.Error).Header. Use
26016// googleapi.IsNotModified to check whether the returned error was
26017// because http.StatusNotModified was returned.
26018func (c *ProjectsAgentKnowledgeBasesDeleteCall) Do(opts ...googleapi.CallOption) (*GoogleProtobufEmpty, error) {
26019	gensupport.SetOptions(c.urlParams_, opts...)
26020	res, err := c.doRequest("json")
26021	if res != nil && res.StatusCode == http.StatusNotModified {
26022		if res.Body != nil {
26023			res.Body.Close()
26024		}
26025		return nil, &googleapi.Error{
26026			Code:   res.StatusCode,
26027			Header: res.Header,
26028		}
26029	}
26030	if err != nil {
26031		return nil, err
26032	}
26033	defer googleapi.CloseBody(res)
26034	if err := googleapi.CheckResponse(res); err != nil {
26035		return nil, err
26036	}
26037	ret := &GoogleProtobufEmpty{
26038		ServerResponse: googleapi.ServerResponse{
26039			Header:         res.Header,
26040			HTTPStatusCode: res.StatusCode,
26041		},
26042	}
26043	target := &ret
26044	if err := gensupport.DecodeResponse(target, res); err != nil {
26045		return nil, err
26046	}
26047	return ret, nil
26048	// {
26049	//   "description": "Deletes the specified knowledge base.",
26050	//   "flatPath": "v2/projects/{projectsId}/agent/knowledgeBases/{knowledgeBasesId}",
26051	//   "httpMethod": "DELETE",
26052	//   "id": "dialogflow.projects.agent.knowledgeBases.delete",
26053	//   "parameterOrder": [
26054	//     "name"
26055	//   ],
26056	//   "parameters": {
26057	//     "force": {
26058	//       "description": "Optional. Force deletes the knowledge base. When set to true, any documents in the knowledge base are also deleted.",
26059	//       "location": "query",
26060	//       "type": "boolean"
26061	//     },
26062	//     "name": {
26063	//       "description": "Required. The name of the knowledge base to delete. Format: `projects//locations//knowledgeBases/`.",
26064	//       "location": "path",
26065	//       "pattern": "^projects/[^/]+/agent/knowledgeBases/[^/]+$",
26066	//       "required": true,
26067	//       "type": "string"
26068	//     }
26069	//   },
26070	//   "path": "v2/{+name}",
26071	//   "response": {
26072	//     "$ref": "GoogleProtobufEmpty"
26073	//   },
26074	//   "scopes": [
26075	//     "https://www.googleapis.com/auth/cloud-platform",
26076	//     "https://www.googleapis.com/auth/dialogflow"
26077	//   ]
26078	// }
26079
26080}
26081
26082// method id "dialogflow.projects.agent.knowledgeBases.get":
26083
26084type ProjectsAgentKnowledgeBasesGetCall struct {
26085	s            *Service
26086	name         string
26087	urlParams_   gensupport.URLParams
26088	ifNoneMatch_ string
26089	ctx_         context.Context
26090	header_      http.Header
26091}
26092
26093// Get: Retrieves the specified knowledge base.
26094//
26095// - name: The name of the knowledge base to retrieve. Format
26096//   `projects//locations//knowledgeBases/`.
26097func (r *ProjectsAgentKnowledgeBasesService) Get(name string) *ProjectsAgentKnowledgeBasesGetCall {
26098	c := &ProjectsAgentKnowledgeBasesGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
26099	c.name = name
26100	return c
26101}
26102
26103// Fields allows partial responses to be retrieved. See
26104// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
26105// for more information.
26106func (c *ProjectsAgentKnowledgeBasesGetCall) Fields(s ...googleapi.Field) *ProjectsAgentKnowledgeBasesGetCall {
26107	c.urlParams_.Set("fields", googleapi.CombineFields(s))
26108	return c
26109}
26110
26111// IfNoneMatch sets the optional parameter which makes the operation
26112// fail if the object's ETag matches the given value. This is useful for
26113// getting updates only after the object has changed since the last
26114// request. Use googleapi.IsNotModified to check whether the response
26115// error from Do is the result of In-None-Match.
26116func (c *ProjectsAgentKnowledgeBasesGetCall) IfNoneMatch(entityTag string) *ProjectsAgentKnowledgeBasesGetCall {
26117	c.ifNoneMatch_ = entityTag
26118	return c
26119}
26120
26121// Context sets the context to be used in this call's Do method. Any
26122// pending HTTP request will be aborted if the provided context is
26123// canceled.
26124func (c *ProjectsAgentKnowledgeBasesGetCall) Context(ctx context.Context) *ProjectsAgentKnowledgeBasesGetCall {
26125	c.ctx_ = ctx
26126	return c
26127}
26128
26129// Header returns an http.Header that can be modified by the caller to
26130// add HTTP headers to the request.
26131func (c *ProjectsAgentKnowledgeBasesGetCall) Header() http.Header {
26132	if c.header_ == nil {
26133		c.header_ = make(http.Header)
26134	}
26135	return c.header_
26136}
26137
26138func (c *ProjectsAgentKnowledgeBasesGetCall) doRequest(alt string) (*http.Response, error) {
26139	reqHeaders := make(http.Header)
26140	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20211027")
26141	for k, v := range c.header_ {
26142		reqHeaders[k] = v
26143	}
26144	reqHeaders.Set("User-Agent", c.s.userAgent())
26145	if c.ifNoneMatch_ != "" {
26146		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
26147	}
26148	var body io.Reader = nil
26149	c.urlParams_.Set("alt", alt)
26150	c.urlParams_.Set("prettyPrint", "false")
26151	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+name}")
26152	urls += "?" + c.urlParams_.Encode()
26153	req, err := http.NewRequest("GET", urls, body)
26154	if err != nil {
26155		return nil, err
26156	}
26157	req.Header = reqHeaders
26158	googleapi.Expand(req.URL, map[string]string{
26159		"name": c.name,
26160	})
26161	return gensupport.SendRequest(c.ctx_, c.s.client, req)
26162}
26163
26164// Do executes the "dialogflow.projects.agent.knowledgeBases.get" call.
26165// Exactly one of *GoogleCloudDialogflowV2KnowledgeBase or error will be
26166// non-nil. Any non-2xx status code is an error. Response headers are in
26167// either *GoogleCloudDialogflowV2KnowledgeBase.ServerResponse.Header or
26168// (if a response was returned at all) in
26169// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
26170// whether the returned error was because http.StatusNotModified was
26171// returned.
26172func (c *ProjectsAgentKnowledgeBasesGetCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDialogflowV2KnowledgeBase, error) {
26173	gensupport.SetOptions(c.urlParams_, opts...)
26174	res, err := c.doRequest("json")
26175	if res != nil && res.StatusCode == http.StatusNotModified {
26176		if res.Body != nil {
26177			res.Body.Close()
26178		}
26179		return nil, &googleapi.Error{
26180			Code:   res.StatusCode,
26181			Header: res.Header,
26182		}
26183	}
26184	if err != nil {
26185		return nil, err
26186	}
26187	defer googleapi.CloseBody(res)
26188	if err := googleapi.CheckResponse(res); err != nil {
26189		return nil, err
26190	}
26191	ret := &GoogleCloudDialogflowV2KnowledgeBase{
26192		ServerResponse: googleapi.ServerResponse{
26193			Header:         res.Header,
26194			HTTPStatusCode: res.StatusCode,
26195		},
26196	}
26197	target := &ret
26198	if err := gensupport.DecodeResponse(target, res); err != nil {
26199		return nil, err
26200	}
26201	return ret, nil
26202	// {
26203	//   "description": "Retrieves the specified knowledge base.",
26204	//   "flatPath": "v2/projects/{projectsId}/agent/knowledgeBases/{knowledgeBasesId}",
26205	//   "httpMethod": "GET",
26206	//   "id": "dialogflow.projects.agent.knowledgeBases.get",
26207	//   "parameterOrder": [
26208	//     "name"
26209	//   ],
26210	//   "parameters": {
26211	//     "name": {
26212	//       "description": "Required. The name of the knowledge base to retrieve. Format `projects//locations//knowledgeBases/`.",
26213	//       "location": "path",
26214	//       "pattern": "^projects/[^/]+/agent/knowledgeBases/[^/]+$",
26215	//       "required": true,
26216	//       "type": "string"
26217	//     }
26218	//   },
26219	//   "path": "v2/{+name}",
26220	//   "response": {
26221	//     "$ref": "GoogleCloudDialogflowV2KnowledgeBase"
26222	//   },
26223	//   "scopes": [
26224	//     "https://www.googleapis.com/auth/cloud-platform",
26225	//     "https://www.googleapis.com/auth/dialogflow"
26226	//   ]
26227	// }
26228
26229}
26230
26231// method id "dialogflow.projects.agent.knowledgeBases.list":
26232
26233type ProjectsAgentKnowledgeBasesListCall struct {
26234	s            *Service
26235	parent       string
26236	urlParams_   gensupport.URLParams
26237	ifNoneMatch_ string
26238	ctx_         context.Context
26239	header_      http.Header
26240}
26241
26242// List: Returns the list of all knowledge bases of the specified agent.
26243//
26244// - parent: The project to list of knowledge bases for. Format:
26245//   `projects//locations/`.
26246func (r *ProjectsAgentKnowledgeBasesService) List(parent string) *ProjectsAgentKnowledgeBasesListCall {
26247	c := &ProjectsAgentKnowledgeBasesListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
26248	c.parent = parent
26249	return c
26250}
26251
26252// PageSize sets the optional parameter "pageSize": The maximum number
26253// of items to return in a single page. By default 10 and at most 100.
26254func (c *ProjectsAgentKnowledgeBasesListCall) PageSize(pageSize int64) *ProjectsAgentKnowledgeBasesListCall {
26255	c.urlParams_.Set("pageSize", fmt.Sprint(pageSize))
26256	return c
26257}
26258
26259// PageToken sets the optional parameter "pageToken": The
26260// next_page_token value returned from a previous list request.
26261func (c *ProjectsAgentKnowledgeBasesListCall) PageToken(pageToken string) *ProjectsAgentKnowledgeBasesListCall {
26262	c.urlParams_.Set("pageToken", pageToken)
26263	return c
26264}
26265
26266// Fields allows partial responses to be retrieved. See
26267// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
26268// for more information.
26269func (c *ProjectsAgentKnowledgeBasesListCall) Fields(s ...googleapi.Field) *ProjectsAgentKnowledgeBasesListCall {
26270	c.urlParams_.Set("fields", googleapi.CombineFields(s))
26271	return c
26272}
26273
26274// IfNoneMatch sets the optional parameter which makes the operation
26275// fail if the object's ETag matches the given value. This is useful for
26276// getting updates only after the object has changed since the last
26277// request. Use googleapi.IsNotModified to check whether the response
26278// error from Do is the result of In-None-Match.
26279func (c *ProjectsAgentKnowledgeBasesListCall) IfNoneMatch(entityTag string) *ProjectsAgentKnowledgeBasesListCall {
26280	c.ifNoneMatch_ = entityTag
26281	return c
26282}
26283
26284// Context sets the context to be used in this call's Do method. Any
26285// pending HTTP request will be aborted if the provided context is
26286// canceled.
26287func (c *ProjectsAgentKnowledgeBasesListCall) Context(ctx context.Context) *ProjectsAgentKnowledgeBasesListCall {
26288	c.ctx_ = ctx
26289	return c
26290}
26291
26292// Header returns an http.Header that can be modified by the caller to
26293// add HTTP headers to the request.
26294func (c *ProjectsAgentKnowledgeBasesListCall) Header() http.Header {
26295	if c.header_ == nil {
26296		c.header_ = make(http.Header)
26297	}
26298	return c.header_
26299}
26300
26301func (c *ProjectsAgentKnowledgeBasesListCall) doRequest(alt string) (*http.Response, error) {
26302	reqHeaders := make(http.Header)
26303	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20211027")
26304	for k, v := range c.header_ {
26305		reqHeaders[k] = v
26306	}
26307	reqHeaders.Set("User-Agent", c.s.userAgent())
26308	if c.ifNoneMatch_ != "" {
26309		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
26310	}
26311	var body io.Reader = nil
26312	c.urlParams_.Set("alt", alt)
26313	c.urlParams_.Set("prettyPrint", "false")
26314	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+parent}/knowledgeBases")
26315	urls += "?" + c.urlParams_.Encode()
26316	req, err := http.NewRequest("GET", urls, body)
26317	if err != nil {
26318		return nil, err
26319	}
26320	req.Header = reqHeaders
26321	googleapi.Expand(req.URL, map[string]string{
26322		"parent": c.parent,
26323	})
26324	return gensupport.SendRequest(c.ctx_, c.s.client, req)
26325}
26326
26327// Do executes the "dialogflow.projects.agent.knowledgeBases.list" call.
26328// Exactly one of *GoogleCloudDialogflowV2ListKnowledgeBasesResponse or
26329// error will be non-nil. Any non-2xx status code is an error. Response
26330// headers are in either
26331// *GoogleCloudDialogflowV2ListKnowledgeBasesResponse.ServerResponse.Head
26332// er or (if a response was returned at all) in
26333// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
26334// whether the returned error was because http.StatusNotModified was
26335// returned.
26336func (c *ProjectsAgentKnowledgeBasesListCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDialogflowV2ListKnowledgeBasesResponse, error) {
26337	gensupport.SetOptions(c.urlParams_, opts...)
26338	res, err := c.doRequest("json")
26339	if res != nil && res.StatusCode == http.StatusNotModified {
26340		if res.Body != nil {
26341			res.Body.Close()
26342		}
26343		return nil, &googleapi.Error{
26344			Code:   res.StatusCode,
26345			Header: res.Header,
26346		}
26347	}
26348	if err != nil {
26349		return nil, err
26350	}
26351	defer googleapi.CloseBody(res)
26352	if err := googleapi.CheckResponse(res); err != nil {
26353		return nil, err
26354	}
26355	ret := &GoogleCloudDialogflowV2ListKnowledgeBasesResponse{
26356		ServerResponse: googleapi.ServerResponse{
26357			Header:         res.Header,
26358			HTTPStatusCode: res.StatusCode,
26359		},
26360	}
26361	target := &ret
26362	if err := gensupport.DecodeResponse(target, res); err != nil {
26363		return nil, err
26364	}
26365	return ret, nil
26366	// {
26367	//   "description": "Returns the list of all knowledge bases of the specified agent.",
26368	//   "flatPath": "v2/projects/{projectsId}/agent/knowledgeBases",
26369	//   "httpMethod": "GET",
26370	//   "id": "dialogflow.projects.agent.knowledgeBases.list",
26371	//   "parameterOrder": [
26372	//     "parent"
26373	//   ],
26374	//   "parameters": {
26375	//     "pageSize": {
26376	//       "description": "The maximum number of items to return in a single page. By default 10 and at most 100.",
26377	//       "format": "int32",
26378	//       "location": "query",
26379	//       "type": "integer"
26380	//     },
26381	//     "pageToken": {
26382	//       "description": "The next_page_token value returned from a previous list request.",
26383	//       "location": "query",
26384	//       "type": "string"
26385	//     },
26386	//     "parent": {
26387	//       "description": "Required. The project to list of knowledge bases for. Format: `projects//locations/`.",
26388	//       "location": "path",
26389	//       "pattern": "^projects/[^/]+/agent$",
26390	//       "required": true,
26391	//       "type": "string"
26392	//     }
26393	//   },
26394	//   "path": "v2/{+parent}/knowledgeBases",
26395	//   "response": {
26396	//     "$ref": "GoogleCloudDialogflowV2ListKnowledgeBasesResponse"
26397	//   },
26398	//   "scopes": [
26399	//     "https://www.googleapis.com/auth/cloud-platform",
26400	//     "https://www.googleapis.com/auth/dialogflow"
26401	//   ]
26402	// }
26403
26404}
26405
26406// Pages invokes f for each page of results.
26407// A non-nil error returned from f will halt the iteration.
26408// The provided context supersedes any context provided to the Context method.
26409func (c *ProjectsAgentKnowledgeBasesListCall) Pages(ctx context.Context, f func(*GoogleCloudDialogflowV2ListKnowledgeBasesResponse) error) error {
26410	c.ctx_ = ctx
26411	defer c.PageToken(c.urlParams_.Get("pageToken")) // reset paging to original point
26412	for {
26413		x, err := c.Do()
26414		if err != nil {
26415			return err
26416		}
26417		if err := f(x); err != nil {
26418			return err
26419		}
26420		if x.NextPageToken == "" {
26421			return nil
26422		}
26423		c.PageToken(x.NextPageToken)
26424	}
26425}
26426
26427// method id "dialogflow.projects.agent.knowledgeBases.patch":
26428
26429type ProjectsAgentKnowledgeBasesPatchCall struct {
26430	s                                    *Service
26431	name                                 string
26432	googleclouddialogflowv2knowledgebase *GoogleCloudDialogflowV2KnowledgeBase
26433	urlParams_                           gensupport.URLParams
26434	ctx_                                 context.Context
26435	header_                              http.Header
26436}
26437
26438// Patch: Updates the specified knowledge base.
26439//
26440// - name: The knowledge base resource name. The name must be empty when
26441//   creating a knowledge base. Format:
26442//   `projects//locations//knowledgeBases/`.
26443func (r *ProjectsAgentKnowledgeBasesService) Patch(name string, googleclouddialogflowv2knowledgebase *GoogleCloudDialogflowV2KnowledgeBase) *ProjectsAgentKnowledgeBasesPatchCall {
26444	c := &ProjectsAgentKnowledgeBasesPatchCall{s: r.s, urlParams_: make(gensupport.URLParams)}
26445	c.name = name
26446	c.googleclouddialogflowv2knowledgebase = googleclouddialogflowv2knowledgebase
26447	return c
26448}
26449
26450// UpdateMask sets the optional parameter "updateMask": Not specified
26451// means `update all`. Currently, only `display_name` can be updated, an
26452// InvalidArgument will be returned for attempting to update other
26453// fields.
26454func (c *ProjectsAgentKnowledgeBasesPatchCall) UpdateMask(updateMask string) *ProjectsAgentKnowledgeBasesPatchCall {
26455	c.urlParams_.Set("updateMask", updateMask)
26456	return c
26457}
26458
26459// Fields allows partial responses to be retrieved. See
26460// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
26461// for more information.
26462func (c *ProjectsAgentKnowledgeBasesPatchCall) Fields(s ...googleapi.Field) *ProjectsAgentKnowledgeBasesPatchCall {
26463	c.urlParams_.Set("fields", googleapi.CombineFields(s))
26464	return c
26465}
26466
26467// Context sets the context to be used in this call's Do method. Any
26468// pending HTTP request will be aborted if the provided context is
26469// canceled.
26470func (c *ProjectsAgentKnowledgeBasesPatchCall) Context(ctx context.Context) *ProjectsAgentKnowledgeBasesPatchCall {
26471	c.ctx_ = ctx
26472	return c
26473}
26474
26475// Header returns an http.Header that can be modified by the caller to
26476// add HTTP headers to the request.
26477func (c *ProjectsAgentKnowledgeBasesPatchCall) Header() http.Header {
26478	if c.header_ == nil {
26479		c.header_ = make(http.Header)
26480	}
26481	return c.header_
26482}
26483
26484func (c *ProjectsAgentKnowledgeBasesPatchCall) doRequest(alt string) (*http.Response, error) {
26485	reqHeaders := make(http.Header)
26486	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20211027")
26487	for k, v := range c.header_ {
26488		reqHeaders[k] = v
26489	}
26490	reqHeaders.Set("User-Agent", c.s.userAgent())
26491	var body io.Reader = nil
26492	body, err := googleapi.WithoutDataWrapper.JSONReader(c.googleclouddialogflowv2knowledgebase)
26493	if err != nil {
26494		return nil, err
26495	}
26496	reqHeaders.Set("Content-Type", "application/json")
26497	c.urlParams_.Set("alt", alt)
26498	c.urlParams_.Set("prettyPrint", "false")
26499	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+name}")
26500	urls += "?" + c.urlParams_.Encode()
26501	req, err := http.NewRequest("PATCH", urls, body)
26502	if err != nil {
26503		return nil, err
26504	}
26505	req.Header = reqHeaders
26506	googleapi.Expand(req.URL, map[string]string{
26507		"name": c.name,
26508	})
26509	return gensupport.SendRequest(c.ctx_, c.s.client, req)
26510}
26511
26512// Do executes the "dialogflow.projects.agent.knowledgeBases.patch" call.
26513// Exactly one of *GoogleCloudDialogflowV2KnowledgeBase or error will be
26514// non-nil. Any non-2xx status code is an error. Response headers are in
26515// either *GoogleCloudDialogflowV2KnowledgeBase.ServerResponse.Header or
26516// (if a response was returned at all) in
26517// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
26518// whether the returned error was because http.StatusNotModified was
26519// returned.
26520func (c *ProjectsAgentKnowledgeBasesPatchCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDialogflowV2KnowledgeBase, error) {
26521	gensupport.SetOptions(c.urlParams_, opts...)
26522	res, err := c.doRequest("json")
26523	if res != nil && res.StatusCode == http.StatusNotModified {
26524		if res.Body != nil {
26525			res.Body.Close()
26526		}
26527		return nil, &googleapi.Error{
26528			Code:   res.StatusCode,
26529			Header: res.Header,
26530		}
26531	}
26532	if err != nil {
26533		return nil, err
26534	}
26535	defer googleapi.CloseBody(res)
26536	if err := googleapi.CheckResponse(res); err != nil {
26537		return nil, err
26538	}
26539	ret := &GoogleCloudDialogflowV2KnowledgeBase{
26540		ServerResponse: googleapi.ServerResponse{
26541			Header:         res.Header,
26542			HTTPStatusCode: res.StatusCode,
26543		},
26544	}
26545	target := &ret
26546	if err := gensupport.DecodeResponse(target, res); err != nil {
26547		return nil, err
26548	}
26549	return ret, nil
26550	// {
26551	//   "description": "Updates the specified knowledge base.",
26552	//   "flatPath": "v2/projects/{projectsId}/agent/knowledgeBases/{knowledgeBasesId}",
26553	//   "httpMethod": "PATCH",
26554	//   "id": "dialogflow.projects.agent.knowledgeBases.patch",
26555	//   "parameterOrder": [
26556	//     "name"
26557	//   ],
26558	//   "parameters": {
26559	//     "name": {
26560	//       "description": "The knowledge base resource name. The name must be empty when creating a knowledge base. Format: `projects//locations//knowledgeBases/`.",
26561	//       "location": "path",
26562	//       "pattern": "^projects/[^/]+/agent/knowledgeBases/[^/]+$",
26563	//       "required": true,
26564	//       "type": "string"
26565	//     },
26566	//     "updateMask": {
26567	//       "description": "Optional. Not specified means `update all`. Currently, only `display_name` can be updated, an InvalidArgument will be returned for attempting to update other fields.",
26568	//       "format": "google-fieldmask",
26569	//       "location": "query",
26570	//       "type": "string"
26571	//     }
26572	//   },
26573	//   "path": "v2/{+name}",
26574	//   "request": {
26575	//     "$ref": "GoogleCloudDialogflowV2KnowledgeBase"
26576	//   },
26577	//   "response": {
26578	//     "$ref": "GoogleCloudDialogflowV2KnowledgeBase"
26579	//   },
26580	//   "scopes": [
26581	//     "https://www.googleapis.com/auth/cloud-platform",
26582	//     "https://www.googleapis.com/auth/dialogflow"
26583	//   ]
26584	// }
26585
26586}
26587
26588// method id "dialogflow.projects.agent.knowledgeBases.documents.create":
26589
26590type ProjectsAgentKnowledgeBasesDocumentsCreateCall struct {
26591	s                               *Service
26592	parent                          string
26593	googleclouddialogflowv2document *GoogleCloudDialogflowV2Document
26594	urlParams_                      gensupport.URLParams
26595	ctx_                            context.Context
26596	header_                         http.Header
26597}
26598
26599// Create: Creates a new document. This method is a long-running
26600// operation
26601// (https://cloud.google.com/dialogflow/cx/docs/how/long-running-operation).
26602// The returned `Operation` type has the following method-specific
26603// fields: - `metadata`: KnowledgeOperationMetadata - `response`:
26604// Document
26605//
26606// - parent: The knowledge base to create a document for. Format:
26607//   `projects//locations//knowledgeBases/`.
26608func (r *ProjectsAgentKnowledgeBasesDocumentsService) Create(parent string, googleclouddialogflowv2document *GoogleCloudDialogflowV2Document) *ProjectsAgentKnowledgeBasesDocumentsCreateCall {
26609	c := &ProjectsAgentKnowledgeBasesDocumentsCreateCall{s: r.s, urlParams_: make(gensupport.URLParams)}
26610	c.parent = parent
26611	c.googleclouddialogflowv2document = googleclouddialogflowv2document
26612	return c
26613}
26614
26615// Fields allows partial responses to be retrieved. See
26616// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
26617// for more information.
26618func (c *ProjectsAgentKnowledgeBasesDocumentsCreateCall) Fields(s ...googleapi.Field) *ProjectsAgentKnowledgeBasesDocumentsCreateCall {
26619	c.urlParams_.Set("fields", googleapi.CombineFields(s))
26620	return c
26621}
26622
26623// Context sets the context to be used in this call's Do method. Any
26624// pending HTTP request will be aborted if the provided context is
26625// canceled.
26626func (c *ProjectsAgentKnowledgeBasesDocumentsCreateCall) Context(ctx context.Context) *ProjectsAgentKnowledgeBasesDocumentsCreateCall {
26627	c.ctx_ = ctx
26628	return c
26629}
26630
26631// Header returns an http.Header that can be modified by the caller to
26632// add HTTP headers to the request.
26633func (c *ProjectsAgentKnowledgeBasesDocumentsCreateCall) Header() http.Header {
26634	if c.header_ == nil {
26635		c.header_ = make(http.Header)
26636	}
26637	return c.header_
26638}
26639
26640func (c *ProjectsAgentKnowledgeBasesDocumentsCreateCall) doRequest(alt string) (*http.Response, error) {
26641	reqHeaders := make(http.Header)
26642	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20211027")
26643	for k, v := range c.header_ {
26644		reqHeaders[k] = v
26645	}
26646	reqHeaders.Set("User-Agent", c.s.userAgent())
26647	var body io.Reader = nil
26648	body, err := googleapi.WithoutDataWrapper.JSONReader(c.googleclouddialogflowv2document)
26649	if err != nil {
26650		return nil, err
26651	}
26652	reqHeaders.Set("Content-Type", "application/json")
26653	c.urlParams_.Set("alt", alt)
26654	c.urlParams_.Set("prettyPrint", "false")
26655	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+parent}/documents")
26656	urls += "?" + c.urlParams_.Encode()
26657	req, err := http.NewRequest("POST", urls, body)
26658	if err != nil {
26659		return nil, err
26660	}
26661	req.Header = reqHeaders
26662	googleapi.Expand(req.URL, map[string]string{
26663		"parent": c.parent,
26664	})
26665	return gensupport.SendRequest(c.ctx_, c.s.client, req)
26666}
26667
26668// Do executes the "dialogflow.projects.agent.knowledgeBases.documents.create" call.
26669// Exactly one of *GoogleLongrunningOperation or error will be non-nil.
26670// Any non-2xx status code is an error. Response headers are in either
26671// *GoogleLongrunningOperation.ServerResponse.Header or (if a response
26672// was returned at all) in error.(*googleapi.Error).Header. Use
26673// googleapi.IsNotModified to check whether the returned error was
26674// because http.StatusNotModified was returned.
26675func (c *ProjectsAgentKnowledgeBasesDocumentsCreateCall) Do(opts ...googleapi.CallOption) (*GoogleLongrunningOperation, error) {
26676	gensupport.SetOptions(c.urlParams_, opts...)
26677	res, err := c.doRequest("json")
26678	if res != nil && res.StatusCode == http.StatusNotModified {
26679		if res.Body != nil {
26680			res.Body.Close()
26681		}
26682		return nil, &googleapi.Error{
26683			Code:   res.StatusCode,
26684			Header: res.Header,
26685		}
26686	}
26687	if err != nil {
26688		return nil, err
26689	}
26690	defer googleapi.CloseBody(res)
26691	if err := googleapi.CheckResponse(res); err != nil {
26692		return nil, err
26693	}
26694	ret := &GoogleLongrunningOperation{
26695		ServerResponse: googleapi.ServerResponse{
26696			Header:         res.Header,
26697			HTTPStatusCode: res.StatusCode,
26698		},
26699	}
26700	target := &ret
26701	if err := gensupport.DecodeResponse(target, res); err != nil {
26702		return nil, err
26703	}
26704	return ret, nil
26705	// {
26706	//   "description": "Creates a new document. This method is a [long-running operation](https://cloud.google.com/dialogflow/cx/docs/how/long-running-operation). The returned `Operation` type has the following method-specific fields: - `metadata`: KnowledgeOperationMetadata - `response`: Document",
26707	//   "flatPath": "v2/projects/{projectsId}/agent/knowledgeBases/{knowledgeBasesId}/documents",
26708	//   "httpMethod": "POST",
26709	//   "id": "dialogflow.projects.agent.knowledgeBases.documents.create",
26710	//   "parameterOrder": [
26711	//     "parent"
26712	//   ],
26713	//   "parameters": {
26714	//     "parent": {
26715	//       "description": "Required. The knowledge base to create a document for. Format: `projects//locations//knowledgeBases/`.",
26716	//       "location": "path",
26717	//       "pattern": "^projects/[^/]+/agent/knowledgeBases/[^/]+$",
26718	//       "required": true,
26719	//       "type": "string"
26720	//     }
26721	//   },
26722	//   "path": "v2/{+parent}/documents",
26723	//   "request": {
26724	//     "$ref": "GoogleCloudDialogflowV2Document"
26725	//   },
26726	//   "response": {
26727	//     "$ref": "GoogleLongrunningOperation"
26728	//   },
26729	//   "scopes": [
26730	//     "https://www.googleapis.com/auth/cloud-platform",
26731	//     "https://www.googleapis.com/auth/dialogflow"
26732	//   ]
26733	// }
26734
26735}
26736
26737// method id "dialogflow.projects.agent.knowledgeBases.documents.delete":
26738
26739type ProjectsAgentKnowledgeBasesDocumentsDeleteCall struct {
26740	s          *Service
26741	name       string
26742	urlParams_ gensupport.URLParams
26743	ctx_       context.Context
26744	header_    http.Header
26745}
26746
26747// Delete: Deletes the specified document. This method is a long-running
26748// operation
26749// (https://cloud.google.com/dialogflow/cx/docs/how/long-running-operation).
26750// The returned `Operation` type has the following method-specific
26751// fields: - `metadata`: KnowledgeOperationMetadata - `response`: An
26752// Empty message
26753// (https://developers.google.com/protocol-buffers/docs/reference/google.protobuf#empty)
26754//
26755// - name: The name of the document to delete. Format:
26756//   `projects//locations//knowledgeBases//documents/`.
26757func (r *ProjectsAgentKnowledgeBasesDocumentsService) Delete(name string) *ProjectsAgentKnowledgeBasesDocumentsDeleteCall {
26758	c := &ProjectsAgentKnowledgeBasesDocumentsDeleteCall{s: r.s, urlParams_: make(gensupport.URLParams)}
26759	c.name = name
26760	return c
26761}
26762
26763// Fields allows partial responses to be retrieved. See
26764// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
26765// for more information.
26766func (c *ProjectsAgentKnowledgeBasesDocumentsDeleteCall) Fields(s ...googleapi.Field) *ProjectsAgentKnowledgeBasesDocumentsDeleteCall {
26767	c.urlParams_.Set("fields", googleapi.CombineFields(s))
26768	return c
26769}
26770
26771// Context sets the context to be used in this call's Do method. Any
26772// pending HTTP request will be aborted if the provided context is
26773// canceled.
26774func (c *ProjectsAgentKnowledgeBasesDocumentsDeleteCall) Context(ctx context.Context) *ProjectsAgentKnowledgeBasesDocumentsDeleteCall {
26775	c.ctx_ = ctx
26776	return c
26777}
26778
26779// Header returns an http.Header that can be modified by the caller to
26780// add HTTP headers to the request.
26781func (c *ProjectsAgentKnowledgeBasesDocumentsDeleteCall) Header() http.Header {
26782	if c.header_ == nil {
26783		c.header_ = make(http.Header)
26784	}
26785	return c.header_
26786}
26787
26788func (c *ProjectsAgentKnowledgeBasesDocumentsDeleteCall) doRequest(alt string) (*http.Response, error) {
26789	reqHeaders := make(http.Header)
26790	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20211027")
26791	for k, v := range c.header_ {
26792		reqHeaders[k] = v
26793	}
26794	reqHeaders.Set("User-Agent", c.s.userAgent())
26795	var body io.Reader = nil
26796	c.urlParams_.Set("alt", alt)
26797	c.urlParams_.Set("prettyPrint", "false")
26798	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+name}")
26799	urls += "?" + c.urlParams_.Encode()
26800	req, err := http.NewRequest("DELETE", urls, body)
26801	if err != nil {
26802		return nil, err
26803	}
26804	req.Header = reqHeaders
26805	googleapi.Expand(req.URL, map[string]string{
26806		"name": c.name,
26807	})
26808	return gensupport.SendRequest(c.ctx_, c.s.client, req)
26809}
26810
26811// Do executes the "dialogflow.projects.agent.knowledgeBases.documents.delete" call.
26812// Exactly one of *GoogleLongrunningOperation or error will be non-nil.
26813// Any non-2xx status code is an error. Response headers are in either
26814// *GoogleLongrunningOperation.ServerResponse.Header or (if a response
26815// was returned at all) in error.(*googleapi.Error).Header. Use
26816// googleapi.IsNotModified to check whether the returned error was
26817// because http.StatusNotModified was returned.
26818func (c *ProjectsAgentKnowledgeBasesDocumentsDeleteCall) Do(opts ...googleapi.CallOption) (*GoogleLongrunningOperation, error) {
26819	gensupport.SetOptions(c.urlParams_, opts...)
26820	res, err := c.doRequest("json")
26821	if res != nil && res.StatusCode == http.StatusNotModified {
26822		if res.Body != nil {
26823			res.Body.Close()
26824		}
26825		return nil, &googleapi.Error{
26826			Code:   res.StatusCode,
26827			Header: res.Header,
26828		}
26829	}
26830	if err != nil {
26831		return nil, err
26832	}
26833	defer googleapi.CloseBody(res)
26834	if err := googleapi.CheckResponse(res); err != nil {
26835		return nil, err
26836	}
26837	ret := &GoogleLongrunningOperation{
26838		ServerResponse: googleapi.ServerResponse{
26839			Header:         res.Header,
26840			HTTPStatusCode: res.StatusCode,
26841		},
26842	}
26843	target := &ret
26844	if err := gensupport.DecodeResponse(target, res); err != nil {
26845		return nil, err
26846	}
26847	return ret, nil
26848	// {
26849	//   "description": "Deletes the specified document. This method is a [long-running operation](https://cloud.google.com/dialogflow/cx/docs/how/long-running-operation). The returned `Operation` type has the following method-specific fields: - `metadata`: KnowledgeOperationMetadata - `response`: An [Empty message](https://developers.google.com/protocol-buffers/docs/reference/google.protobuf#empty)",
26850	//   "flatPath": "v2/projects/{projectsId}/agent/knowledgeBases/{knowledgeBasesId}/documents/{documentsId}",
26851	//   "httpMethod": "DELETE",
26852	//   "id": "dialogflow.projects.agent.knowledgeBases.documents.delete",
26853	//   "parameterOrder": [
26854	//     "name"
26855	//   ],
26856	//   "parameters": {
26857	//     "name": {
26858	//       "description": "Required. The name of the document to delete. Format: `projects//locations//knowledgeBases//documents/`.",
26859	//       "location": "path",
26860	//       "pattern": "^projects/[^/]+/agent/knowledgeBases/[^/]+/documents/[^/]+$",
26861	//       "required": true,
26862	//       "type": "string"
26863	//     }
26864	//   },
26865	//   "path": "v2/{+name}",
26866	//   "response": {
26867	//     "$ref": "GoogleLongrunningOperation"
26868	//   },
26869	//   "scopes": [
26870	//     "https://www.googleapis.com/auth/cloud-platform",
26871	//     "https://www.googleapis.com/auth/dialogflow"
26872	//   ]
26873	// }
26874
26875}
26876
26877// method id "dialogflow.projects.agent.knowledgeBases.documents.get":
26878
26879type ProjectsAgentKnowledgeBasesDocumentsGetCall struct {
26880	s            *Service
26881	name         string
26882	urlParams_   gensupport.URLParams
26883	ifNoneMatch_ string
26884	ctx_         context.Context
26885	header_      http.Header
26886}
26887
26888// Get: Retrieves the specified document.
26889//
26890// - name: The name of the document to retrieve. Format
26891//   `projects//locations//knowledgeBases//documents/`.
26892func (r *ProjectsAgentKnowledgeBasesDocumentsService) Get(name string) *ProjectsAgentKnowledgeBasesDocumentsGetCall {
26893	c := &ProjectsAgentKnowledgeBasesDocumentsGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
26894	c.name = name
26895	return c
26896}
26897
26898// Fields allows partial responses to be retrieved. See
26899// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
26900// for more information.
26901func (c *ProjectsAgentKnowledgeBasesDocumentsGetCall) Fields(s ...googleapi.Field) *ProjectsAgentKnowledgeBasesDocumentsGetCall {
26902	c.urlParams_.Set("fields", googleapi.CombineFields(s))
26903	return c
26904}
26905
26906// IfNoneMatch sets the optional parameter which makes the operation
26907// fail if the object's ETag matches the given value. This is useful for
26908// getting updates only after the object has changed since the last
26909// request. Use googleapi.IsNotModified to check whether the response
26910// error from Do is the result of In-None-Match.
26911func (c *ProjectsAgentKnowledgeBasesDocumentsGetCall) IfNoneMatch(entityTag string) *ProjectsAgentKnowledgeBasesDocumentsGetCall {
26912	c.ifNoneMatch_ = entityTag
26913	return c
26914}
26915
26916// Context sets the context to be used in this call's Do method. Any
26917// pending HTTP request will be aborted if the provided context is
26918// canceled.
26919func (c *ProjectsAgentKnowledgeBasesDocumentsGetCall) Context(ctx context.Context) *ProjectsAgentKnowledgeBasesDocumentsGetCall {
26920	c.ctx_ = ctx
26921	return c
26922}
26923
26924// Header returns an http.Header that can be modified by the caller to
26925// add HTTP headers to the request.
26926func (c *ProjectsAgentKnowledgeBasesDocumentsGetCall) Header() http.Header {
26927	if c.header_ == nil {
26928		c.header_ = make(http.Header)
26929	}
26930	return c.header_
26931}
26932
26933func (c *ProjectsAgentKnowledgeBasesDocumentsGetCall) doRequest(alt string) (*http.Response, error) {
26934	reqHeaders := make(http.Header)
26935	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20211027")
26936	for k, v := range c.header_ {
26937		reqHeaders[k] = v
26938	}
26939	reqHeaders.Set("User-Agent", c.s.userAgent())
26940	if c.ifNoneMatch_ != "" {
26941		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
26942	}
26943	var body io.Reader = nil
26944	c.urlParams_.Set("alt", alt)
26945	c.urlParams_.Set("prettyPrint", "false")
26946	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+name}")
26947	urls += "?" + c.urlParams_.Encode()
26948	req, err := http.NewRequest("GET", urls, body)
26949	if err != nil {
26950		return nil, err
26951	}
26952	req.Header = reqHeaders
26953	googleapi.Expand(req.URL, map[string]string{
26954		"name": c.name,
26955	})
26956	return gensupport.SendRequest(c.ctx_, c.s.client, req)
26957}
26958
26959// Do executes the "dialogflow.projects.agent.knowledgeBases.documents.get" call.
26960// Exactly one of *GoogleCloudDialogflowV2Document or error will be
26961// non-nil. Any non-2xx status code is an error. Response headers are in
26962// either *GoogleCloudDialogflowV2Document.ServerResponse.Header or (if
26963// a response was returned at all) in error.(*googleapi.Error).Header.
26964// Use googleapi.IsNotModified to check whether the returned error was
26965// because http.StatusNotModified was returned.
26966func (c *ProjectsAgentKnowledgeBasesDocumentsGetCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDialogflowV2Document, error) {
26967	gensupport.SetOptions(c.urlParams_, opts...)
26968	res, err := c.doRequest("json")
26969	if res != nil && res.StatusCode == http.StatusNotModified {
26970		if res.Body != nil {
26971			res.Body.Close()
26972		}
26973		return nil, &googleapi.Error{
26974			Code:   res.StatusCode,
26975			Header: res.Header,
26976		}
26977	}
26978	if err != nil {
26979		return nil, err
26980	}
26981	defer googleapi.CloseBody(res)
26982	if err := googleapi.CheckResponse(res); err != nil {
26983		return nil, err
26984	}
26985	ret := &GoogleCloudDialogflowV2Document{
26986		ServerResponse: googleapi.ServerResponse{
26987			Header:         res.Header,
26988			HTTPStatusCode: res.StatusCode,
26989		},
26990	}
26991	target := &ret
26992	if err := gensupport.DecodeResponse(target, res); err != nil {
26993		return nil, err
26994	}
26995	return ret, nil
26996	// {
26997	//   "description": "Retrieves the specified document.",
26998	//   "flatPath": "v2/projects/{projectsId}/agent/knowledgeBases/{knowledgeBasesId}/documents/{documentsId}",
26999	//   "httpMethod": "GET",
27000	//   "id": "dialogflow.projects.agent.knowledgeBases.documents.get",
27001	//   "parameterOrder": [
27002	//     "name"
27003	//   ],
27004	//   "parameters": {
27005	//     "name": {
27006	//       "description": "Required. The name of the document to retrieve. Format `projects//locations//knowledgeBases//documents/`.",
27007	//       "location": "path",
27008	//       "pattern": "^projects/[^/]+/agent/knowledgeBases/[^/]+/documents/[^/]+$",
27009	//       "required": true,
27010	//       "type": "string"
27011	//     }
27012	//   },
27013	//   "path": "v2/{+name}",
27014	//   "response": {
27015	//     "$ref": "GoogleCloudDialogflowV2Document"
27016	//   },
27017	//   "scopes": [
27018	//     "https://www.googleapis.com/auth/cloud-platform",
27019	//     "https://www.googleapis.com/auth/dialogflow"
27020	//   ]
27021	// }
27022
27023}
27024
27025// method id "dialogflow.projects.agent.knowledgeBases.documents.list":
27026
27027type ProjectsAgentKnowledgeBasesDocumentsListCall struct {
27028	s            *Service
27029	parent       string
27030	urlParams_   gensupport.URLParams
27031	ifNoneMatch_ string
27032	ctx_         context.Context
27033	header_      http.Header
27034}
27035
27036// List: Returns the list of all documents of the knowledge base.
27037//
27038// - parent: The knowledge base to list all documents for. Format:
27039//   `projects//locations//knowledgeBases/`.
27040func (r *ProjectsAgentKnowledgeBasesDocumentsService) List(parent string) *ProjectsAgentKnowledgeBasesDocumentsListCall {
27041	c := &ProjectsAgentKnowledgeBasesDocumentsListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
27042	c.parent = parent
27043	return c
27044}
27045
27046// PageSize sets the optional parameter "pageSize": The maximum number
27047// of items to return in a single page. By default 10 and at most 100.
27048func (c *ProjectsAgentKnowledgeBasesDocumentsListCall) PageSize(pageSize int64) *ProjectsAgentKnowledgeBasesDocumentsListCall {
27049	c.urlParams_.Set("pageSize", fmt.Sprint(pageSize))
27050	return c
27051}
27052
27053// PageToken sets the optional parameter "pageToken": The
27054// next_page_token value returned from a previous list request.
27055func (c *ProjectsAgentKnowledgeBasesDocumentsListCall) PageToken(pageToken string) *ProjectsAgentKnowledgeBasesDocumentsListCall {
27056	c.urlParams_.Set("pageToken", pageToken)
27057	return c
27058}
27059
27060// Fields allows partial responses to be retrieved. See
27061// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
27062// for more information.
27063func (c *ProjectsAgentKnowledgeBasesDocumentsListCall) Fields(s ...googleapi.Field) *ProjectsAgentKnowledgeBasesDocumentsListCall {
27064	c.urlParams_.Set("fields", googleapi.CombineFields(s))
27065	return c
27066}
27067
27068// IfNoneMatch sets the optional parameter which makes the operation
27069// fail if the object's ETag matches the given value. This is useful for
27070// getting updates only after the object has changed since the last
27071// request. Use googleapi.IsNotModified to check whether the response
27072// error from Do is the result of In-None-Match.
27073func (c *ProjectsAgentKnowledgeBasesDocumentsListCall) IfNoneMatch(entityTag string) *ProjectsAgentKnowledgeBasesDocumentsListCall {
27074	c.ifNoneMatch_ = entityTag
27075	return c
27076}
27077
27078// Context sets the context to be used in this call's Do method. Any
27079// pending HTTP request will be aborted if the provided context is
27080// canceled.
27081func (c *ProjectsAgentKnowledgeBasesDocumentsListCall) Context(ctx context.Context) *ProjectsAgentKnowledgeBasesDocumentsListCall {
27082	c.ctx_ = ctx
27083	return c
27084}
27085
27086// Header returns an http.Header that can be modified by the caller to
27087// add HTTP headers to the request.
27088func (c *ProjectsAgentKnowledgeBasesDocumentsListCall) Header() http.Header {
27089	if c.header_ == nil {
27090		c.header_ = make(http.Header)
27091	}
27092	return c.header_
27093}
27094
27095func (c *ProjectsAgentKnowledgeBasesDocumentsListCall) doRequest(alt string) (*http.Response, error) {
27096	reqHeaders := make(http.Header)
27097	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20211027")
27098	for k, v := range c.header_ {
27099		reqHeaders[k] = v
27100	}
27101	reqHeaders.Set("User-Agent", c.s.userAgent())
27102	if c.ifNoneMatch_ != "" {
27103		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
27104	}
27105	var body io.Reader = nil
27106	c.urlParams_.Set("alt", alt)
27107	c.urlParams_.Set("prettyPrint", "false")
27108	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+parent}/documents")
27109	urls += "?" + c.urlParams_.Encode()
27110	req, err := http.NewRequest("GET", urls, body)
27111	if err != nil {
27112		return nil, err
27113	}
27114	req.Header = reqHeaders
27115	googleapi.Expand(req.URL, map[string]string{
27116		"parent": c.parent,
27117	})
27118	return gensupport.SendRequest(c.ctx_, c.s.client, req)
27119}
27120
27121// Do executes the "dialogflow.projects.agent.knowledgeBases.documents.list" call.
27122// Exactly one of *GoogleCloudDialogflowV2ListDocumentsResponse or error
27123// will be non-nil. Any non-2xx status code is an error. Response
27124// headers are in either
27125// *GoogleCloudDialogflowV2ListDocumentsResponse.ServerResponse.Header
27126// or (if a response was returned at all) in
27127// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
27128// whether the returned error was because http.StatusNotModified was
27129// returned.
27130func (c *ProjectsAgentKnowledgeBasesDocumentsListCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDialogflowV2ListDocumentsResponse, error) {
27131	gensupport.SetOptions(c.urlParams_, opts...)
27132	res, err := c.doRequest("json")
27133	if res != nil && res.StatusCode == http.StatusNotModified {
27134		if res.Body != nil {
27135			res.Body.Close()
27136		}
27137		return nil, &googleapi.Error{
27138			Code:   res.StatusCode,
27139			Header: res.Header,
27140		}
27141	}
27142	if err != nil {
27143		return nil, err
27144	}
27145	defer googleapi.CloseBody(res)
27146	if err := googleapi.CheckResponse(res); err != nil {
27147		return nil, err
27148	}
27149	ret := &GoogleCloudDialogflowV2ListDocumentsResponse{
27150		ServerResponse: googleapi.ServerResponse{
27151			Header:         res.Header,
27152			HTTPStatusCode: res.StatusCode,
27153		},
27154	}
27155	target := &ret
27156	if err := gensupport.DecodeResponse(target, res); err != nil {
27157		return nil, err
27158	}
27159	return ret, nil
27160	// {
27161	//   "description": "Returns the list of all documents of the knowledge base.",
27162	//   "flatPath": "v2/projects/{projectsId}/agent/knowledgeBases/{knowledgeBasesId}/documents",
27163	//   "httpMethod": "GET",
27164	//   "id": "dialogflow.projects.agent.knowledgeBases.documents.list",
27165	//   "parameterOrder": [
27166	//     "parent"
27167	//   ],
27168	//   "parameters": {
27169	//     "pageSize": {
27170	//       "description": "The maximum number of items to return in a single page. By default 10 and at most 100.",
27171	//       "format": "int32",
27172	//       "location": "query",
27173	//       "type": "integer"
27174	//     },
27175	//     "pageToken": {
27176	//       "description": "The next_page_token value returned from a previous list request.",
27177	//       "location": "query",
27178	//       "type": "string"
27179	//     },
27180	//     "parent": {
27181	//       "description": "Required. The knowledge base to list all documents for. Format: `projects//locations//knowledgeBases/`.",
27182	//       "location": "path",
27183	//       "pattern": "^projects/[^/]+/agent/knowledgeBases/[^/]+$",
27184	//       "required": true,
27185	//       "type": "string"
27186	//     }
27187	//   },
27188	//   "path": "v2/{+parent}/documents",
27189	//   "response": {
27190	//     "$ref": "GoogleCloudDialogflowV2ListDocumentsResponse"
27191	//   },
27192	//   "scopes": [
27193	//     "https://www.googleapis.com/auth/cloud-platform",
27194	//     "https://www.googleapis.com/auth/dialogflow"
27195	//   ]
27196	// }
27197
27198}
27199
27200// Pages invokes f for each page of results.
27201// A non-nil error returned from f will halt the iteration.
27202// The provided context supersedes any context provided to the Context method.
27203func (c *ProjectsAgentKnowledgeBasesDocumentsListCall) Pages(ctx context.Context, f func(*GoogleCloudDialogflowV2ListDocumentsResponse) error) error {
27204	c.ctx_ = ctx
27205	defer c.PageToken(c.urlParams_.Get("pageToken")) // reset paging to original point
27206	for {
27207		x, err := c.Do()
27208		if err != nil {
27209			return err
27210		}
27211		if err := f(x); err != nil {
27212			return err
27213		}
27214		if x.NextPageToken == "" {
27215			return nil
27216		}
27217		c.PageToken(x.NextPageToken)
27218	}
27219}
27220
27221// method id "dialogflow.projects.agent.knowledgeBases.documents.patch":
27222
27223type ProjectsAgentKnowledgeBasesDocumentsPatchCall struct {
27224	s                               *Service
27225	name                            string
27226	googleclouddialogflowv2document *GoogleCloudDialogflowV2Document
27227	urlParams_                      gensupport.URLParams
27228	ctx_                            context.Context
27229	header_                         http.Header
27230}
27231
27232// Patch: Updates the specified document. This method is a long-running
27233// operation
27234// (https://cloud.google.com/dialogflow/cx/docs/how/long-running-operation).
27235// The returned `Operation` type has the following method-specific
27236// fields: - `metadata`: KnowledgeOperationMetadata - `response`:
27237// Document
27238//
27239// - name: Optional. The document resource name. The name must be empty
27240//   when creating a document. Format:
27241//   `projects//locations//knowledgeBases//documents/`.
27242func (r *ProjectsAgentKnowledgeBasesDocumentsService) Patch(name string, googleclouddialogflowv2document *GoogleCloudDialogflowV2Document) *ProjectsAgentKnowledgeBasesDocumentsPatchCall {
27243	c := &ProjectsAgentKnowledgeBasesDocumentsPatchCall{s: r.s, urlParams_: make(gensupport.URLParams)}
27244	c.name = name
27245	c.googleclouddialogflowv2document = googleclouddialogflowv2document
27246	return c
27247}
27248
27249// UpdateMask sets the optional parameter "updateMask": Not specified
27250// means `update all`. Currently, only `display_name` can be updated, an
27251// InvalidArgument will be returned for attempting to update other
27252// fields.
27253func (c *ProjectsAgentKnowledgeBasesDocumentsPatchCall) UpdateMask(updateMask string) *ProjectsAgentKnowledgeBasesDocumentsPatchCall {
27254	c.urlParams_.Set("updateMask", updateMask)
27255	return c
27256}
27257
27258// Fields allows partial responses to be retrieved. See
27259// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
27260// for more information.
27261func (c *ProjectsAgentKnowledgeBasesDocumentsPatchCall) Fields(s ...googleapi.Field) *ProjectsAgentKnowledgeBasesDocumentsPatchCall {
27262	c.urlParams_.Set("fields", googleapi.CombineFields(s))
27263	return c
27264}
27265
27266// Context sets the context to be used in this call's Do method. Any
27267// pending HTTP request will be aborted if the provided context is
27268// canceled.
27269func (c *ProjectsAgentKnowledgeBasesDocumentsPatchCall) Context(ctx context.Context) *ProjectsAgentKnowledgeBasesDocumentsPatchCall {
27270	c.ctx_ = ctx
27271	return c
27272}
27273
27274// Header returns an http.Header that can be modified by the caller to
27275// add HTTP headers to the request.
27276func (c *ProjectsAgentKnowledgeBasesDocumentsPatchCall) Header() http.Header {
27277	if c.header_ == nil {
27278		c.header_ = make(http.Header)
27279	}
27280	return c.header_
27281}
27282
27283func (c *ProjectsAgentKnowledgeBasesDocumentsPatchCall) doRequest(alt string) (*http.Response, error) {
27284	reqHeaders := make(http.Header)
27285	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20211027")
27286	for k, v := range c.header_ {
27287		reqHeaders[k] = v
27288	}
27289	reqHeaders.Set("User-Agent", c.s.userAgent())
27290	var body io.Reader = nil
27291	body, err := googleapi.WithoutDataWrapper.JSONReader(c.googleclouddialogflowv2document)
27292	if err != nil {
27293		return nil, err
27294	}
27295	reqHeaders.Set("Content-Type", "application/json")
27296	c.urlParams_.Set("alt", alt)
27297	c.urlParams_.Set("prettyPrint", "false")
27298	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+name}")
27299	urls += "?" + c.urlParams_.Encode()
27300	req, err := http.NewRequest("PATCH", urls, body)
27301	if err != nil {
27302		return nil, err
27303	}
27304	req.Header = reqHeaders
27305	googleapi.Expand(req.URL, map[string]string{
27306		"name": c.name,
27307	})
27308	return gensupport.SendRequest(c.ctx_, c.s.client, req)
27309}
27310
27311// Do executes the "dialogflow.projects.agent.knowledgeBases.documents.patch" call.
27312// Exactly one of *GoogleLongrunningOperation or error will be non-nil.
27313// Any non-2xx status code is an error. Response headers are in either
27314// *GoogleLongrunningOperation.ServerResponse.Header or (if a response
27315// was returned at all) in error.(*googleapi.Error).Header. Use
27316// googleapi.IsNotModified to check whether the returned error was
27317// because http.StatusNotModified was returned.
27318func (c *ProjectsAgentKnowledgeBasesDocumentsPatchCall) Do(opts ...googleapi.CallOption) (*GoogleLongrunningOperation, error) {
27319	gensupport.SetOptions(c.urlParams_, opts...)
27320	res, err := c.doRequest("json")
27321	if res != nil && res.StatusCode == http.StatusNotModified {
27322		if res.Body != nil {
27323			res.Body.Close()
27324		}
27325		return nil, &googleapi.Error{
27326			Code:   res.StatusCode,
27327			Header: res.Header,
27328		}
27329	}
27330	if err != nil {
27331		return nil, err
27332	}
27333	defer googleapi.CloseBody(res)
27334	if err := googleapi.CheckResponse(res); err != nil {
27335		return nil, err
27336	}
27337	ret := &GoogleLongrunningOperation{
27338		ServerResponse: googleapi.ServerResponse{
27339			Header:         res.Header,
27340			HTTPStatusCode: res.StatusCode,
27341		},
27342	}
27343	target := &ret
27344	if err := gensupport.DecodeResponse(target, res); err != nil {
27345		return nil, err
27346	}
27347	return ret, nil
27348	// {
27349	//   "description": "Updates the specified document. This method is a [long-running operation](https://cloud.google.com/dialogflow/cx/docs/how/long-running-operation). The returned `Operation` type has the following method-specific fields: - `metadata`: KnowledgeOperationMetadata - `response`: Document",
27350	//   "flatPath": "v2/projects/{projectsId}/agent/knowledgeBases/{knowledgeBasesId}/documents/{documentsId}",
27351	//   "httpMethod": "PATCH",
27352	//   "id": "dialogflow.projects.agent.knowledgeBases.documents.patch",
27353	//   "parameterOrder": [
27354	//     "name"
27355	//   ],
27356	//   "parameters": {
27357	//     "name": {
27358	//       "description": "Optional. The document resource name. The name must be empty when creating a document. Format: `projects//locations//knowledgeBases//documents/`.",
27359	//       "location": "path",
27360	//       "pattern": "^projects/[^/]+/agent/knowledgeBases/[^/]+/documents/[^/]+$",
27361	//       "required": true,
27362	//       "type": "string"
27363	//     },
27364	//     "updateMask": {
27365	//       "description": "Optional. Not specified means `update all`. Currently, only `display_name` can be updated, an InvalidArgument will be returned for attempting to update other fields.",
27366	//       "format": "google-fieldmask",
27367	//       "location": "query",
27368	//       "type": "string"
27369	//     }
27370	//   },
27371	//   "path": "v2/{+name}",
27372	//   "request": {
27373	//     "$ref": "GoogleCloudDialogflowV2Document"
27374	//   },
27375	//   "response": {
27376	//     "$ref": "GoogleLongrunningOperation"
27377	//   },
27378	//   "scopes": [
27379	//     "https://www.googleapis.com/auth/cloud-platform",
27380	//     "https://www.googleapis.com/auth/dialogflow"
27381	//   ]
27382	// }
27383
27384}
27385
27386// method id "dialogflow.projects.agent.knowledgeBases.documents.reload":
27387
27388type ProjectsAgentKnowledgeBasesDocumentsReloadCall struct {
27389	s                                            *Service
27390	name                                         string
27391	googleclouddialogflowv2reloaddocumentrequest *GoogleCloudDialogflowV2ReloadDocumentRequest
27392	urlParams_                                   gensupport.URLParams
27393	ctx_                                         context.Context
27394	header_                                      http.Header
27395}
27396
27397// Reload: Reloads the specified document from its specified source,
27398// content_uri or content. The previously loaded content of the document
27399// will be deleted. Note: Even when the content of the document has not
27400// changed, there still may be side effects because of internal
27401// implementation changes. This method is a long-running operation
27402// (https://cloud.google.com/dialogflow/cx/docs/how/long-running-operation).
27403// The returned `Operation` type has the following method-specific
27404// fields: - `metadata`: KnowledgeOperationMetadata - `response`:
27405// Document Note: The `projects.agent.knowledgeBases.documents` resource
27406// is deprecated; only use `projects.knowledgeBases.documents`.
27407//
27408// - name: The name of the document to reload. Format:
27409//   `projects//locations//knowledgeBases//documents/`.
27410func (r *ProjectsAgentKnowledgeBasesDocumentsService) Reload(name string, googleclouddialogflowv2reloaddocumentrequest *GoogleCloudDialogflowV2ReloadDocumentRequest) *ProjectsAgentKnowledgeBasesDocumentsReloadCall {
27411	c := &ProjectsAgentKnowledgeBasesDocumentsReloadCall{s: r.s, urlParams_: make(gensupport.URLParams)}
27412	c.name = name
27413	c.googleclouddialogflowv2reloaddocumentrequest = googleclouddialogflowv2reloaddocumentrequest
27414	return c
27415}
27416
27417// Fields allows partial responses to be retrieved. See
27418// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
27419// for more information.
27420func (c *ProjectsAgentKnowledgeBasesDocumentsReloadCall) Fields(s ...googleapi.Field) *ProjectsAgentKnowledgeBasesDocumentsReloadCall {
27421	c.urlParams_.Set("fields", googleapi.CombineFields(s))
27422	return c
27423}
27424
27425// Context sets the context to be used in this call's Do method. Any
27426// pending HTTP request will be aborted if the provided context is
27427// canceled.
27428func (c *ProjectsAgentKnowledgeBasesDocumentsReloadCall) Context(ctx context.Context) *ProjectsAgentKnowledgeBasesDocumentsReloadCall {
27429	c.ctx_ = ctx
27430	return c
27431}
27432
27433// Header returns an http.Header that can be modified by the caller to
27434// add HTTP headers to the request.
27435func (c *ProjectsAgentKnowledgeBasesDocumentsReloadCall) Header() http.Header {
27436	if c.header_ == nil {
27437		c.header_ = make(http.Header)
27438	}
27439	return c.header_
27440}
27441
27442func (c *ProjectsAgentKnowledgeBasesDocumentsReloadCall) doRequest(alt string) (*http.Response, error) {
27443	reqHeaders := make(http.Header)
27444	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20211027")
27445	for k, v := range c.header_ {
27446		reqHeaders[k] = v
27447	}
27448	reqHeaders.Set("User-Agent", c.s.userAgent())
27449	var body io.Reader = nil
27450	body, err := googleapi.WithoutDataWrapper.JSONReader(c.googleclouddialogflowv2reloaddocumentrequest)
27451	if err != nil {
27452		return nil, err
27453	}
27454	reqHeaders.Set("Content-Type", "application/json")
27455	c.urlParams_.Set("alt", alt)
27456	c.urlParams_.Set("prettyPrint", "false")
27457	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+name}:reload")
27458	urls += "?" + c.urlParams_.Encode()
27459	req, err := http.NewRequest("POST", urls, body)
27460	if err != nil {
27461		return nil, err
27462	}
27463	req.Header = reqHeaders
27464	googleapi.Expand(req.URL, map[string]string{
27465		"name": c.name,
27466	})
27467	return gensupport.SendRequest(c.ctx_, c.s.client, req)
27468}
27469
27470// Do executes the "dialogflow.projects.agent.knowledgeBases.documents.reload" call.
27471// Exactly one of *GoogleLongrunningOperation or error will be non-nil.
27472// Any non-2xx status code is an error. Response headers are in either
27473// *GoogleLongrunningOperation.ServerResponse.Header or (if a response
27474// was returned at all) in error.(*googleapi.Error).Header. Use
27475// googleapi.IsNotModified to check whether the returned error was
27476// because http.StatusNotModified was returned.
27477func (c *ProjectsAgentKnowledgeBasesDocumentsReloadCall) Do(opts ...googleapi.CallOption) (*GoogleLongrunningOperation, error) {
27478	gensupport.SetOptions(c.urlParams_, opts...)
27479	res, err := c.doRequest("json")
27480	if res != nil && res.StatusCode == http.StatusNotModified {
27481		if res.Body != nil {
27482			res.Body.Close()
27483		}
27484		return nil, &googleapi.Error{
27485			Code:   res.StatusCode,
27486			Header: res.Header,
27487		}
27488	}
27489	if err != nil {
27490		return nil, err
27491	}
27492	defer googleapi.CloseBody(res)
27493	if err := googleapi.CheckResponse(res); err != nil {
27494		return nil, err
27495	}
27496	ret := &GoogleLongrunningOperation{
27497		ServerResponse: googleapi.ServerResponse{
27498			Header:         res.Header,
27499			HTTPStatusCode: res.StatusCode,
27500		},
27501	}
27502	target := &ret
27503	if err := gensupport.DecodeResponse(target, res); err != nil {
27504		return nil, err
27505	}
27506	return ret, nil
27507	// {
27508	//   "description": "Reloads the specified document from its specified source, content_uri or content. The previously loaded content of the document will be deleted. Note: Even when the content of the document has not changed, there still may be side effects because of internal implementation changes. This method is a [long-running operation](https://cloud.google.com/dialogflow/cx/docs/how/long-running-operation). The returned `Operation` type has the following method-specific fields: - `metadata`: KnowledgeOperationMetadata - `response`: Document Note: The `projects.agent.knowledgeBases.documents` resource is deprecated; only use `projects.knowledgeBases.documents`.",
27509	//   "flatPath": "v2/projects/{projectsId}/agent/knowledgeBases/{knowledgeBasesId}/documents/{documentsId}:reload",
27510	//   "httpMethod": "POST",
27511	//   "id": "dialogflow.projects.agent.knowledgeBases.documents.reload",
27512	//   "parameterOrder": [
27513	//     "name"
27514	//   ],
27515	//   "parameters": {
27516	//     "name": {
27517	//       "description": "Required. The name of the document to reload. Format: `projects//locations//knowledgeBases//documents/`",
27518	//       "location": "path",
27519	//       "pattern": "^projects/[^/]+/agent/knowledgeBases/[^/]+/documents/[^/]+$",
27520	//       "required": true,
27521	//       "type": "string"
27522	//     }
27523	//   },
27524	//   "path": "v2/{+name}:reload",
27525	//   "request": {
27526	//     "$ref": "GoogleCloudDialogflowV2ReloadDocumentRequest"
27527	//   },
27528	//   "response": {
27529	//     "$ref": "GoogleLongrunningOperation"
27530	//   },
27531	//   "scopes": [
27532	//     "https://www.googleapis.com/auth/cloud-platform",
27533	//     "https://www.googleapis.com/auth/dialogflow"
27534	//   ]
27535	// }
27536
27537}
27538
27539// method id "dialogflow.projects.agent.sessions.deleteContexts":
27540
27541type ProjectsAgentSessionsDeleteContextsCall struct {
27542	s          *Service
27543	parent     string
27544	urlParams_ gensupport.URLParams
27545	ctx_       context.Context
27546	header_    http.Header
27547}
27548
27549// DeleteContexts: Deletes all active contexts in the specified session.
27550//
27551// - parent: The name of the session to delete all contexts from.
27552//   Format: `projects//agent/sessions/` or
27553//   `projects//agent/environments//users//sessions/`. If `Environment
27554//   ID` is not specified we assume default 'draft' environment. If
27555//   `User ID` is not specified, we assume default '-' user.
27556func (r *ProjectsAgentSessionsService) DeleteContexts(parent string) *ProjectsAgentSessionsDeleteContextsCall {
27557	c := &ProjectsAgentSessionsDeleteContextsCall{s: r.s, urlParams_: make(gensupport.URLParams)}
27558	c.parent = parent
27559	return c
27560}
27561
27562// Fields allows partial responses to be retrieved. See
27563// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
27564// for more information.
27565func (c *ProjectsAgentSessionsDeleteContextsCall) Fields(s ...googleapi.Field) *ProjectsAgentSessionsDeleteContextsCall {
27566	c.urlParams_.Set("fields", googleapi.CombineFields(s))
27567	return c
27568}
27569
27570// Context sets the context to be used in this call's Do method. Any
27571// pending HTTP request will be aborted if the provided context is
27572// canceled.
27573func (c *ProjectsAgentSessionsDeleteContextsCall) Context(ctx context.Context) *ProjectsAgentSessionsDeleteContextsCall {
27574	c.ctx_ = ctx
27575	return c
27576}
27577
27578// Header returns an http.Header that can be modified by the caller to
27579// add HTTP headers to the request.
27580func (c *ProjectsAgentSessionsDeleteContextsCall) Header() http.Header {
27581	if c.header_ == nil {
27582		c.header_ = make(http.Header)
27583	}
27584	return c.header_
27585}
27586
27587func (c *ProjectsAgentSessionsDeleteContextsCall) doRequest(alt string) (*http.Response, error) {
27588	reqHeaders := make(http.Header)
27589	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20211027")
27590	for k, v := range c.header_ {
27591		reqHeaders[k] = v
27592	}
27593	reqHeaders.Set("User-Agent", c.s.userAgent())
27594	var body io.Reader = nil
27595	c.urlParams_.Set("alt", alt)
27596	c.urlParams_.Set("prettyPrint", "false")
27597	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+parent}/contexts")
27598	urls += "?" + c.urlParams_.Encode()
27599	req, err := http.NewRequest("DELETE", urls, body)
27600	if err != nil {
27601		return nil, err
27602	}
27603	req.Header = reqHeaders
27604	googleapi.Expand(req.URL, map[string]string{
27605		"parent": c.parent,
27606	})
27607	return gensupport.SendRequest(c.ctx_, c.s.client, req)
27608}
27609
27610// Do executes the "dialogflow.projects.agent.sessions.deleteContexts" call.
27611// Exactly one of *GoogleProtobufEmpty or error will be non-nil. Any
27612// non-2xx status code is an error. Response headers are in either
27613// *GoogleProtobufEmpty.ServerResponse.Header or (if a response was
27614// returned at all) in error.(*googleapi.Error).Header. Use
27615// googleapi.IsNotModified to check whether the returned error was
27616// because http.StatusNotModified was returned.
27617func (c *ProjectsAgentSessionsDeleteContextsCall) Do(opts ...googleapi.CallOption) (*GoogleProtobufEmpty, error) {
27618	gensupport.SetOptions(c.urlParams_, opts...)
27619	res, err := c.doRequest("json")
27620	if res != nil && res.StatusCode == http.StatusNotModified {
27621		if res.Body != nil {
27622			res.Body.Close()
27623		}
27624		return nil, &googleapi.Error{
27625			Code:   res.StatusCode,
27626			Header: res.Header,
27627		}
27628	}
27629	if err != nil {
27630		return nil, err
27631	}
27632	defer googleapi.CloseBody(res)
27633	if err := googleapi.CheckResponse(res); err != nil {
27634		return nil, err
27635	}
27636	ret := &GoogleProtobufEmpty{
27637		ServerResponse: googleapi.ServerResponse{
27638			Header:         res.Header,
27639			HTTPStatusCode: res.StatusCode,
27640		},
27641	}
27642	target := &ret
27643	if err := gensupport.DecodeResponse(target, res); err != nil {
27644		return nil, err
27645	}
27646	return ret, nil
27647	// {
27648	//   "description": "Deletes all active contexts in the specified session.",
27649	//   "flatPath": "v2/projects/{projectsId}/agent/sessions/{sessionsId}/contexts",
27650	//   "httpMethod": "DELETE",
27651	//   "id": "dialogflow.projects.agent.sessions.deleteContexts",
27652	//   "parameterOrder": [
27653	//     "parent"
27654	//   ],
27655	//   "parameters": {
27656	//     "parent": {
27657	//       "description": "Required. The name of the session to delete all contexts from. Format: `projects//agent/sessions/` or `projects//agent/environments//users//sessions/`. If `Environment ID` is not specified we assume default 'draft' environment. If `User ID` is not specified, we assume default '-' user.",
27658	//       "location": "path",
27659	//       "pattern": "^projects/[^/]+/agent/sessions/[^/]+$",
27660	//       "required": true,
27661	//       "type": "string"
27662	//     }
27663	//   },
27664	//   "path": "v2/{+parent}/contexts",
27665	//   "response": {
27666	//     "$ref": "GoogleProtobufEmpty"
27667	//   },
27668	//   "scopes": [
27669	//     "https://www.googleapis.com/auth/cloud-platform",
27670	//     "https://www.googleapis.com/auth/dialogflow"
27671	//   ]
27672	// }
27673
27674}
27675
27676// method id "dialogflow.projects.agent.sessions.detectIntent":
27677
27678type ProjectsAgentSessionsDetectIntentCall struct {
27679	s                                          *Service
27680	sessionid                                  string
27681	googleclouddialogflowv2detectintentrequest *GoogleCloudDialogflowV2DetectIntentRequest
27682	urlParams_                                 gensupport.URLParams
27683	ctx_                                       context.Context
27684	header_                                    http.Header
27685}
27686
27687// DetectIntent: Processes a natural language query and returns
27688// structured, actionable data as a result. This method is not
27689// idempotent, because it may cause contexts and session entity types to
27690// be updated, which in turn might affect results of future queries. If
27691// you might use Agent Assist
27692// (https://cloud.google.com/dialogflow/docs/#aa) or other CCAI products
27693// now or in the future, consider using AnalyzeContent instead of
27694// `DetectIntent`. `AnalyzeContent` has additional functionality for
27695// Agent Assist and other CCAI products. Note: Always use agent versions
27696// for production traffic. See Versions and environments
27697// (https://cloud.google.com/dialogflow/es/docs/agents-versions).
27698//
27699// - session: The name of the session this query is sent to. Format:
27700//   `projects//agent/sessions/`, or
27701//   `projects//agent/environments//users//sessions/`. If `Environment
27702//   ID` is not specified, we assume default 'draft' environment
27703//   (`Environment ID` might be referred to as environment name at some
27704//   places). If `User ID` is not specified, we are using "-". It's up
27705//   to the API caller to choose an appropriate `Session ID` and `User
27706//   Id`. They can be a random number or some type of user and session
27707//   identifiers (preferably hashed). The length of the `Session ID` and
27708//   `User ID` must not exceed 36 characters. For more information, see
27709//   the API interactions guide
27710//   (https://cloud.google.com/dialogflow/docs/api-overview). Note:
27711//   Always use agent versions for production traffic. See Versions and
27712//   environments
27713//   (https://cloud.google.com/dialogflow/es/docs/agents-versions).
27714func (r *ProjectsAgentSessionsService) DetectIntent(sessionid string, googleclouddialogflowv2detectintentrequest *GoogleCloudDialogflowV2DetectIntentRequest) *ProjectsAgentSessionsDetectIntentCall {
27715	c := &ProjectsAgentSessionsDetectIntentCall{s: r.s, urlParams_: make(gensupport.URLParams)}
27716	c.sessionid = sessionid
27717	c.googleclouddialogflowv2detectintentrequest = googleclouddialogflowv2detectintentrequest
27718	return c
27719}
27720
27721// Fields allows partial responses to be retrieved. See
27722// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
27723// for more information.
27724func (c *ProjectsAgentSessionsDetectIntentCall) Fields(s ...googleapi.Field) *ProjectsAgentSessionsDetectIntentCall {
27725	c.urlParams_.Set("fields", googleapi.CombineFields(s))
27726	return c
27727}
27728
27729// Context sets the context to be used in this call's Do method. Any
27730// pending HTTP request will be aborted if the provided context is
27731// canceled.
27732func (c *ProjectsAgentSessionsDetectIntentCall) Context(ctx context.Context) *ProjectsAgentSessionsDetectIntentCall {
27733	c.ctx_ = ctx
27734	return c
27735}
27736
27737// Header returns an http.Header that can be modified by the caller to
27738// add HTTP headers to the request.
27739func (c *ProjectsAgentSessionsDetectIntentCall) Header() http.Header {
27740	if c.header_ == nil {
27741		c.header_ = make(http.Header)
27742	}
27743	return c.header_
27744}
27745
27746func (c *ProjectsAgentSessionsDetectIntentCall) doRequest(alt string) (*http.Response, error) {
27747	reqHeaders := make(http.Header)
27748	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20211027")
27749	for k, v := range c.header_ {
27750		reqHeaders[k] = v
27751	}
27752	reqHeaders.Set("User-Agent", c.s.userAgent())
27753	var body io.Reader = nil
27754	body, err := googleapi.WithoutDataWrapper.JSONReader(c.googleclouddialogflowv2detectintentrequest)
27755	if err != nil {
27756		return nil, err
27757	}
27758	reqHeaders.Set("Content-Type", "application/json")
27759	c.urlParams_.Set("alt", alt)
27760	c.urlParams_.Set("prettyPrint", "false")
27761	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+session}:detectIntent")
27762	urls += "?" + c.urlParams_.Encode()
27763	req, err := http.NewRequest("POST", urls, body)
27764	if err != nil {
27765		return nil, err
27766	}
27767	req.Header = reqHeaders
27768	googleapi.Expand(req.URL, map[string]string{
27769		"session": c.sessionid,
27770	})
27771	return gensupport.SendRequest(c.ctx_, c.s.client, req)
27772}
27773
27774// Do executes the "dialogflow.projects.agent.sessions.detectIntent" call.
27775// Exactly one of *GoogleCloudDialogflowV2DetectIntentResponse or error
27776// will be non-nil. Any non-2xx status code is an error. Response
27777// headers are in either
27778// *GoogleCloudDialogflowV2DetectIntentResponse.ServerResponse.Header or
27779// (if a response was returned at all) in
27780// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
27781// whether the returned error was because http.StatusNotModified was
27782// returned.
27783func (c *ProjectsAgentSessionsDetectIntentCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDialogflowV2DetectIntentResponse, error) {
27784	gensupport.SetOptions(c.urlParams_, opts...)
27785	res, err := c.doRequest("json")
27786	if res != nil && res.StatusCode == http.StatusNotModified {
27787		if res.Body != nil {
27788			res.Body.Close()
27789		}
27790		return nil, &googleapi.Error{
27791			Code:   res.StatusCode,
27792			Header: res.Header,
27793		}
27794	}
27795	if err != nil {
27796		return nil, err
27797	}
27798	defer googleapi.CloseBody(res)
27799	if err := googleapi.CheckResponse(res); err != nil {
27800		return nil, err
27801	}
27802	ret := &GoogleCloudDialogflowV2DetectIntentResponse{
27803		ServerResponse: googleapi.ServerResponse{
27804			Header:         res.Header,
27805			HTTPStatusCode: res.StatusCode,
27806		},
27807	}
27808	target := &ret
27809	if err := gensupport.DecodeResponse(target, res); err != nil {
27810		return nil, err
27811	}
27812	return ret, nil
27813	// {
27814	//   "description": "Processes a natural language query and returns structured, actionable data as a result. This method is not idempotent, because it may cause contexts and session entity types to be updated, which in turn might affect results of future queries. If you might use [Agent Assist](https://cloud.google.com/dialogflow/docs/#aa) or other CCAI products now or in the future, consider using AnalyzeContent instead of `DetectIntent`. `AnalyzeContent` has additional functionality for Agent Assist and other CCAI products. Note: Always use agent versions for production traffic. See [Versions and environments](https://cloud.google.com/dialogflow/es/docs/agents-versions).",
27815	//   "flatPath": "v2/projects/{projectsId}/agent/sessions/{sessionsId}:detectIntent",
27816	//   "httpMethod": "POST",
27817	//   "id": "dialogflow.projects.agent.sessions.detectIntent",
27818	//   "parameterOrder": [
27819	//     "session"
27820	//   ],
27821	//   "parameters": {
27822	//     "session": {
27823	//       "description": "Required. The name of the session this query is sent to. Format: `projects//agent/sessions/`, or `projects//agent/environments//users//sessions/`. If `Environment ID` is not specified, we assume default 'draft' environment (`Environment ID` might be referred to as environment name at some places). If `User ID` is not specified, we are using \"-\". It's up to the API caller to choose an appropriate `Session ID` and `User Id`. They can be a random number or some type of user and session identifiers (preferably hashed). The length of the `Session ID` and `User ID` must not exceed 36 characters. For more information, see the [API interactions guide](https://cloud.google.com/dialogflow/docs/api-overview). Note: Always use agent versions for production traffic. See [Versions and environments](https://cloud.google.com/dialogflow/es/docs/agents-versions).",
27824	//       "location": "path",
27825	//       "pattern": "^projects/[^/]+/agent/sessions/[^/]+$",
27826	//       "required": true,
27827	//       "type": "string"
27828	//     }
27829	//   },
27830	//   "path": "v2/{+session}:detectIntent",
27831	//   "request": {
27832	//     "$ref": "GoogleCloudDialogflowV2DetectIntentRequest"
27833	//   },
27834	//   "response": {
27835	//     "$ref": "GoogleCloudDialogflowV2DetectIntentResponse"
27836	//   },
27837	//   "scopes": [
27838	//     "https://www.googleapis.com/auth/cloud-platform",
27839	//     "https://www.googleapis.com/auth/dialogflow"
27840	//   ]
27841	// }
27842
27843}
27844
27845// method id "dialogflow.projects.agent.sessions.contexts.create":
27846
27847type ProjectsAgentSessionsContextsCreateCall struct {
27848	s                              *Service
27849	parent                         string
27850	googleclouddialogflowv2context *GoogleCloudDialogflowV2Context
27851	urlParams_                     gensupport.URLParams
27852	ctx_                           context.Context
27853	header_                        http.Header
27854}
27855
27856// Create: Creates a context. If the specified context already exists,
27857// overrides the context.
27858//
27859// - parent: The session to create a context for. Format:
27860//   `projects//agent/sessions/` or
27861//   `projects//agent/environments//users//sessions/`. If `Environment
27862//   ID` is not specified, we assume default 'draft' environment. If
27863//   `User ID` is not specified, we assume default '-' user.
27864func (r *ProjectsAgentSessionsContextsService) Create(parent string, googleclouddialogflowv2context *GoogleCloudDialogflowV2Context) *ProjectsAgentSessionsContextsCreateCall {
27865	c := &ProjectsAgentSessionsContextsCreateCall{s: r.s, urlParams_: make(gensupport.URLParams)}
27866	c.parent = parent
27867	c.googleclouddialogflowv2context = googleclouddialogflowv2context
27868	return c
27869}
27870
27871// Fields allows partial responses to be retrieved. See
27872// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
27873// for more information.
27874func (c *ProjectsAgentSessionsContextsCreateCall) Fields(s ...googleapi.Field) *ProjectsAgentSessionsContextsCreateCall {
27875	c.urlParams_.Set("fields", googleapi.CombineFields(s))
27876	return c
27877}
27878
27879// Context sets the context to be used in this call's Do method. Any
27880// pending HTTP request will be aborted if the provided context is
27881// canceled.
27882func (c *ProjectsAgentSessionsContextsCreateCall) Context(ctx context.Context) *ProjectsAgentSessionsContextsCreateCall {
27883	c.ctx_ = ctx
27884	return c
27885}
27886
27887// Header returns an http.Header that can be modified by the caller to
27888// add HTTP headers to the request.
27889func (c *ProjectsAgentSessionsContextsCreateCall) Header() http.Header {
27890	if c.header_ == nil {
27891		c.header_ = make(http.Header)
27892	}
27893	return c.header_
27894}
27895
27896func (c *ProjectsAgentSessionsContextsCreateCall) doRequest(alt string) (*http.Response, error) {
27897	reqHeaders := make(http.Header)
27898	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20211027")
27899	for k, v := range c.header_ {
27900		reqHeaders[k] = v
27901	}
27902	reqHeaders.Set("User-Agent", c.s.userAgent())
27903	var body io.Reader = nil
27904	body, err := googleapi.WithoutDataWrapper.JSONReader(c.googleclouddialogflowv2context)
27905	if err != nil {
27906		return nil, err
27907	}
27908	reqHeaders.Set("Content-Type", "application/json")
27909	c.urlParams_.Set("alt", alt)
27910	c.urlParams_.Set("prettyPrint", "false")
27911	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+parent}/contexts")
27912	urls += "?" + c.urlParams_.Encode()
27913	req, err := http.NewRequest("POST", urls, body)
27914	if err != nil {
27915		return nil, err
27916	}
27917	req.Header = reqHeaders
27918	googleapi.Expand(req.URL, map[string]string{
27919		"parent": c.parent,
27920	})
27921	return gensupport.SendRequest(c.ctx_, c.s.client, req)
27922}
27923
27924// Do executes the "dialogflow.projects.agent.sessions.contexts.create" call.
27925// Exactly one of *GoogleCloudDialogflowV2Context or error will be
27926// non-nil. Any non-2xx status code is an error. Response headers are in
27927// either *GoogleCloudDialogflowV2Context.ServerResponse.Header or (if a
27928// response was returned at all) in error.(*googleapi.Error).Header. Use
27929// googleapi.IsNotModified to check whether the returned error was
27930// because http.StatusNotModified was returned.
27931func (c *ProjectsAgentSessionsContextsCreateCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDialogflowV2Context, error) {
27932	gensupport.SetOptions(c.urlParams_, opts...)
27933	res, err := c.doRequest("json")
27934	if res != nil && res.StatusCode == http.StatusNotModified {
27935		if res.Body != nil {
27936			res.Body.Close()
27937		}
27938		return nil, &googleapi.Error{
27939			Code:   res.StatusCode,
27940			Header: res.Header,
27941		}
27942	}
27943	if err != nil {
27944		return nil, err
27945	}
27946	defer googleapi.CloseBody(res)
27947	if err := googleapi.CheckResponse(res); err != nil {
27948		return nil, err
27949	}
27950	ret := &GoogleCloudDialogflowV2Context{
27951		ServerResponse: googleapi.ServerResponse{
27952			Header:         res.Header,
27953			HTTPStatusCode: res.StatusCode,
27954		},
27955	}
27956	target := &ret
27957	if err := gensupport.DecodeResponse(target, res); err != nil {
27958		return nil, err
27959	}
27960	return ret, nil
27961	// {
27962	//   "description": "Creates a context. If the specified context already exists, overrides the context.",
27963	//   "flatPath": "v2/projects/{projectsId}/agent/sessions/{sessionsId}/contexts",
27964	//   "httpMethod": "POST",
27965	//   "id": "dialogflow.projects.agent.sessions.contexts.create",
27966	//   "parameterOrder": [
27967	//     "parent"
27968	//   ],
27969	//   "parameters": {
27970	//     "parent": {
27971	//       "description": "Required. The session to create a context for. Format: `projects//agent/sessions/` or `projects//agent/environments//users//sessions/`. If `Environment ID` is not specified, we assume default 'draft' environment. If `User ID` is not specified, we assume default '-' user.",
27972	//       "location": "path",
27973	//       "pattern": "^projects/[^/]+/agent/sessions/[^/]+$",
27974	//       "required": true,
27975	//       "type": "string"
27976	//     }
27977	//   },
27978	//   "path": "v2/{+parent}/contexts",
27979	//   "request": {
27980	//     "$ref": "GoogleCloudDialogflowV2Context"
27981	//   },
27982	//   "response": {
27983	//     "$ref": "GoogleCloudDialogflowV2Context"
27984	//   },
27985	//   "scopes": [
27986	//     "https://www.googleapis.com/auth/cloud-platform",
27987	//     "https://www.googleapis.com/auth/dialogflow"
27988	//   ]
27989	// }
27990
27991}
27992
27993// method id "dialogflow.projects.agent.sessions.contexts.delete":
27994
27995type ProjectsAgentSessionsContextsDeleteCall struct {
27996	s          *Service
27997	name       string
27998	urlParams_ gensupport.URLParams
27999	ctx_       context.Context
28000	header_    http.Header
28001}
28002
28003// Delete: Deletes the specified context.
28004//
28005// - name: The name of the context to delete. Format:
28006//   `projects//agent/sessions//contexts/` or
28007//   `projects//agent/environments//users//sessions//contexts/`. If
28008//   `Environment ID` is not specified, we assume default 'draft'
28009//   environment. If `User ID` is not specified, we assume default '-'
28010//   user.
28011func (r *ProjectsAgentSessionsContextsService) Delete(name string) *ProjectsAgentSessionsContextsDeleteCall {
28012	c := &ProjectsAgentSessionsContextsDeleteCall{s: r.s, urlParams_: make(gensupport.URLParams)}
28013	c.name = name
28014	return c
28015}
28016
28017// Fields allows partial responses to be retrieved. See
28018// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
28019// for more information.
28020func (c *ProjectsAgentSessionsContextsDeleteCall) Fields(s ...googleapi.Field) *ProjectsAgentSessionsContextsDeleteCall {
28021	c.urlParams_.Set("fields", googleapi.CombineFields(s))
28022	return c
28023}
28024
28025// Context sets the context to be used in this call's Do method. Any
28026// pending HTTP request will be aborted if the provided context is
28027// canceled.
28028func (c *ProjectsAgentSessionsContextsDeleteCall) Context(ctx context.Context) *ProjectsAgentSessionsContextsDeleteCall {
28029	c.ctx_ = ctx
28030	return c
28031}
28032
28033// Header returns an http.Header that can be modified by the caller to
28034// add HTTP headers to the request.
28035func (c *ProjectsAgentSessionsContextsDeleteCall) Header() http.Header {
28036	if c.header_ == nil {
28037		c.header_ = make(http.Header)
28038	}
28039	return c.header_
28040}
28041
28042func (c *ProjectsAgentSessionsContextsDeleteCall) doRequest(alt string) (*http.Response, error) {
28043	reqHeaders := make(http.Header)
28044	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20211027")
28045	for k, v := range c.header_ {
28046		reqHeaders[k] = v
28047	}
28048	reqHeaders.Set("User-Agent", c.s.userAgent())
28049	var body io.Reader = nil
28050	c.urlParams_.Set("alt", alt)
28051	c.urlParams_.Set("prettyPrint", "false")
28052	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+name}")
28053	urls += "?" + c.urlParams_.Encode()
28054	req, err := http.NewRequest("DELETE", urls, body)
28055	if err != nil {
28056		return nil, err
28057	}
28058	req.Header = reqHeaders
28059	googleapi.Expand(req.URL, map[string]string{
28060		"name": c.name,
28061	})
28062	return gensupport.SendRequest(c.ctx_, c.s.client, req)
28063}
28064
28065// Do executes the "dialogflow.projects.agent.sessions.contexts.delete" call.
28066// Exactly one of *GoogleProtobufEmpty or error will be non-nil. Any
28067// non-2xx status code is an error. Response headers are in either
28068// *GoogleProtobufEmpty.ServerResponse.Header or (if a response was
28069// returned at all) in error.(*googleapi.Error).Header. Use
28070// googleapi.IsNotModified to check whether the returned error was
28071// because http.StatusNotModified was returned.
28072func (c *ProjectsAgentSessionsContextsDeleteCall) Do(opts ...googleapi.CallOption) (*GoogleProtobufEmpty, error) {
28073	gensupport.SetOptions(c.urlParams_, opts...)
28074	res, err := c.doRequest("json")
28075	if res != nil && res.StatusCode == http.StatusNotModified {
28076		if res.Body != nil {
28077			res.Body.Close()
28078		}
28079		return nil, &googleapi.Error{
28080			Code:   res.StatusCode,
28081			Header: res.Header,
28082		}
28083	}
28084	if err != nil {
28085		return nil, err
28086	}
28087	defer googleapi.CloseBody(res)
28088	if err := googleapi.CheckResponse(res); err != nil {
28089		return nil, err
28090	}
28091	ret := &GoogleProtobufEmpty{
28092		ServerResponse: googleapi.ServerResponse{
28093			Header:         res.Header,
28094			HTTPStatusCode: res.StatusCode,
28095		},
28096	}
28097	target := &ret
28098	if err := gensupport.DecodeResponse(target, res); err != nil {
28099		return nil, err
28100	}
28101	return ret, nil
28102	// {
28103	//   "description": "Deletes the specified context.",
28104	//   "flatPath": "v2/projects/{projectsId}/agent/sessions/{sessionsId}/contexts/{contextsId}",
28105	//   "httpMethod": "DELETE",
28106	//   "id": "dialogflow.projects.agent.sessions.contexts.delete",
28107	//   "parameterOrder": [
28108	//     "name"
28109	//   ],
28110	//   "parameters": {
28111	//     "name": {
28112	//       "description": "Required. The name of the context to delete. Format: `projects//agent/sessions//contexts/` or `projects//agent/environments//users//sessions//contexts/`. If `Environment ID` is not specified, we assume default 'draft' environment. If `User ID` is not specified, we assume default '-' user.",
28113	//       "location": "path",
28114	//       "pattern": "^projects/[^/]+/agent/sessions/[^/]+/contexts/[^/]+$",
28115	//       "required": true,
28116	//       "type": "string"
28117	//     }
28118	//   },
28119	//   "path": "v2/{+name}",
28120	//   "response": {
28121	//     "$ref": "GoogleProtobufEmpty"
28122	//   },
28123	//   "scopes": [
28124	//     "https://www.googleapis.com/auth/cloud-platform",
28125	//     "https://www.googleapis.com/auth/dialogflow"
28126	//   ]
28127	// }
28128
28129}
28130
28131// method id "dialogflow.projects.agent.sessions.contexts.get":
28132
28133type ProjectsAgentSessionsContextsGetCall struct {
28134	s            *Service
28135	name         string
28136	urlParams_   gensupport.URLParams
28137	ifNoneMatch_ string
28138	ctx_         context.Context
28139	header_      http.Header
28140}
28141
28142// Get: Retrieves the specified context.
28143//
28144// - name: The name of the context. Format:
28145//   `projects//agent/sessions//contexts/` or
28146//   `projects//agent/environments//users//sessions//contexts/`. If
28147//   `Environment ID` is not specified, we assume default 'draft'
28148//   environment. If `User ID` is not specified, we assume default '-'
28149//   user.
28150func (r *ProjectsAgentSessionsContextsService) Get(name string) *ProjectsAgentSessionsContextsGetCall {
28151	c := &ProjectsAgentSessionsContextsGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
28152	c.name = name
28153	return c
28154}
28155
28156// Fields allows partial responses to be retrieved. See
28157// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
28158// for more information.
28159func (c *ProjectsAgentSessionsContextsGetCall) Fields(s ...googleapi.Field) *ProjectsAgentSessionsContextsGetCall {
28160	c.urlParams_.Set("fields", googleapi.CombineFields(s))
28161	return c
28162}
28163
28164// IfNoneMatch sets the optional parameter which makes the operation
28165// fail if the object's ETag matches the given value. This is useful for
28166// getting updates only after the object has changed since the last
28167// request. Use googleapi.IsNotModified to check whether the response
28168// error from Do is the result of In-None-Match.
28169func (c *ProjectsAgentSessionsContextsGetCall) IfNoneMatch(entityTag string) *ProjectsAgentSessionsContextsGetCall {
28170	c.ifNoneMatch_ = entityTag
28171	return c
28172}
28173
28174// Context sets the context to be used in this call's Do method. Any
28175// pending HTTP request will be aborted if the provided context is
28176// canceled.
28177func (c *ProjectsAgentSessionsContextsGetCall) Context(ctx context.Context) *ProjectsAgentSessionsContextsGetCall {
28178	c.ctx_ = ctx
28179	return c
28180}
28181
28182// Header returns an http.Header that can be modified by the caller to
28183// add HTTP headers to the request.
28184func (c *ProjectsAgentSessionsContextsGetCall) Header() http.Header {
28185	if c.header_ == nil {
28186		c.header_ = make(http.Header)
28187	}
28188	return c.header_
28189}
28190
28191func (c *ProjectsAgentSessionsContextsGetCall) doRequest(alt string) (*http.Response, error) {
28192	reqHeaders := make(http.Header)
28193	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20211027")
28194	for k, v := range c.header_ {
28195		reqHeaders[k] = v
28196	}
28197	reqHeaders.Set("User-Agent", c.s.userAgent())
28198	if c.ifNoneMatch_ != "" {
28199		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
28200	}
28201	var body io.Reader = nil
28202	c.urlParams_.Set("alt", alt)
28203	c.urlParams_.Set("prettyPrint", "false")
28204	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+name}")
28205	urls += "?" + c.urlParams_.Encode()
28206	req, err := http.NewRequest("GET", urls, body)
28207	if err != nil {
28208		return nil, err
28209	}
28210	req.Header = reqHeaders
28211	googleapi.Expand(req.URL, map[string]string{
28212		"name": c.name,
28213	})
28214	return gensupport.SendRequest(c.ctx_, c.s.client, req)
28215}
28216
28217// Do executes the "dialogflow.projects.agent.sessions.contexts.get" call.
28218// Exactly one of *GoogleCloudDialogflowV2Context or error will be
28219// non-nil. Any non-2xx status code is an error. Response headers are in
28220// either *GoogleCloudDialogflowV2Context.ServerResponse.Header or (if a
28221// response was returned at all) in error.(*googleapi.Error).Header. Use
28222// googleapi.IsNotModified to check whether the returned error was
28223// because http.StatusNotModified was returned.
28224func (c *ProjectsAgentSessionsContextsGetCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDialogflowV2Context, error) {
28225	gensupport.SetOptions(c.urlParams_, opts...)
28226	res, err := c.doRequest("json")
28227	if res != nil && res.StatusCode == http.StatusNotModified {
28228		if res.Body != nil {
28229			res.Body.Close()
28230		}
28231		return nil, &googleapi.Error{
28232			Code:   res.StatusCode,
28233			Header: res.Header,
28234		}
28235	}
28236	if err != nil {
28237		return nil, err
28238	}
28239	defer googleapi.CloseBody(res)
28240	if err := googleapi.CheckResponse(res); err != nil {
28241		return nil, err
28242	}
28243	ret := &GoogleCloudDialogflowV2Context{
28244		ServerResponse: googleapi.ServerResponse{
28245			Header:         res.Header,
28246			HTTPStatusCode: res.StatusCode,
28247		},
28248	}
28249	target := &ret
28250	if err := gensupport.DecodeResponse(target, res); err != nil {
28251		return nil, err
28252	}
28253	return ret, nil
28254	// {
28255	//   "description": "Retrieves the specified context.",
28256	//   "flatPath": "v2/projects/{projectsId}/agent/sessions/{sessionsId}/contexts/{contextsId}",
28257	//   "httpMethod": "GET",
28258	//   "id": "dialogflow.projects.agent.sessions.contexts.get",
28259	//   "parameterOrder": [
28260	//     "name"
28261	//   ],
28262	//   "parameters": {
28263	//     "name": {
28264	//       "description": "Required. The name of the context. Format: `projects//agent/sessions//contexts/` or `projects//agent/environments//users//sessions//contexts/`. If `Environment ID` is not specified, we assume default 'draft' environment. If `User ID` is not specified, we assume default '-' user.",
28265	//       "location": "path",
28266	//       "pattern": "^projects/[^/]+/agent/sessions/[^/]+/contexts/[^/]+$",
28267	//       "required": true,
28268	//       "type": "string"
28269	//     }
28270	//   },
28271	//   "path": "v2/{+name}",
28272	//   "response": {
28273	//     "$ref": "GoogleCloudDialogflowV2Context"
28274	//   },
28275	//   "scopes": [
28276	//     "https://www.googleapis.com/auth/cloud-platform",
28277	//     "https://www.googleapis.com/auth/dialogflow"
28278	//   ]
28279	// }
28280
28281}
28282
28283// method id "dialogflow.projects.agent.sessions.contexts.list":
28284
28285type ProjectsAgentSessionsContextsListCall struct {
28286	s            *Service
28287	parent       string
28288	urlParams_   gensupport.URLParams
28289	ifNoneMatch_ string
28290	ctx_         context.Context
28291	header_      http.Header
28292}
28293
28294// List: Returns the list of all contexts in the specified session.
28295//
28296// - parent: The session to list all contexts from. Format:
28297//   `projects//agent/sessions/` or
28298//   `projects//agent/environments//users//sessions/`. If `Environment
28299//   ID` is not specified, we assume default 'draft' environment. If
28300//   `User ID` is not specified, we assume default '-' user.
28301func (r *ProjectsAgentSessionsContextsService) List(parent string) *ProjectsAgentSessionsContextsListCall {
28302	c := &ProjectsAgentSessionsContextsListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
28303	c.parent = parent
28304	return c
28305}
28306
28307// PageSize sets the optional parameter "pageSize": The maximum number
28308// of items to return in a single page. By default 100 and at most 1000.
28309func (c *ProjectsAgentSessionsContextsListCall) PageSize(pageSize int64) *ProjectsAgentSessionsContextsListCall {
28310	c.urlParams_.Set("pageSize", fmt.Sprint(pageSize))
28311	return c
28312}
28313
28314// PageToken sets the optional parameter "pageToken": The
28315// next_page_token value returned from a previous list request.
28316func (c *ProjectsAgentSessionsContextsListCall) PageToken(pageToken string) *ProjectsAgentSessionsContextsListCall {
28317	c.urlParams_.Set("pageToken", pageToken)
28318	return c
28319}
28320
28321// Fields allows partial responses to be retrieved. See
28322// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
28323// for more information.
28324func (c *ProjectsAgentSessionsContextsListCall) Fields(s ...googleapi.Field) *ProjectsAgentSessionsContextsListCall {
28325	c.urlParams_.Set("fields", googleapi.CombineFields(s))
28326	return c
28327}
28328
28329// IfNoneMatch sets the optional parameter which makes the operation
28330// fail if the object's ETag matches the given value. This is useful for
28331// getting updates only after the object has changed since the last
28332// request. Use googleapi.IsNotModified to check whether the response
28333// error from Do is the result of In-None-Match.
28334func (c *ProjectsAgentSessionsContextsListCall) IfNoneMatch(entityTag string) *ProjectsAgentSessionsContextsListCall {
28335	c.ifNoneMatch_ = entityTag
28336	return c
28337}
28338
28339// Context sets the context to be used in this call's Do method. Any
28340// pending HTTP request will be aborted if the provided context is
28341// canceled.
28342func (c *ProjectsAgentSessionsContextsListCall) Context(ctx context.Context) *ProjectsAgentSessionsContextsListCall {
28343	c.ctx_ = ctx
28344	return c
28345}
28346
28347// Header returns an http.Header that can be modified by the caller to
28348// add HTTP headers to the request.
28349func (c *ProjectsAgentSessionsContextsListCall) Header() http.Header {
28350	if c.header_ == nil {
28351		c.header_ = make(http.Header)
28352	}
28353	return c.header_
28354}
28355
28356func (c *ProjectsAgentSessionsContextsListCall) doRequest(alt string) (*http.Response, error) {
28357	reqHeaders := make(http.Header)
28358	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20211027")
28359	for k, v := range c.header_ {
28360		reqHeaders[k] = v
28361	}
28362	reqHeaders.Set("User-Agent", c.s.userAgent())
28363	if c.ifNoneMatch_ != "" {
28364		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
28365	}
28366	var body io.Reader = nil
28367	c.urlParams_.Set("alt", alt)
28368	c.urlParams_.Set("prettyPrint", "false")
28369	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+parent}/contexts")
28370	urls += "?" + c.urlParams_.Encode()
28371	req, err := http.NewRequest("GET", urls, body)
28372	if err != nil {
28373		return nil, err
28374	}
28375	req.Header = reqHeaders
28376	googleapi.Expand(req.URL, map[string]string{
28377		"parent": c.parent,
28378	})
28379	return gensupport.SendRequest(c.ctx_, c.s.client, req)
28380}
28381
28382// Do executes the "dialogflow.projects.agent.sessions.contexts.list" call.
28383// Exactly one of *GoogleCloudDialogflowV2ListContextsResponse or error
28384// will be non-nil. Any non-2xx status code is an error. Response
28385// headers are in either
28386// *GoogleCloudDialogflowV2ListContextsResponse.ServerResponse.Header or
28387// (if a response was returned at all) in
28388// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
28389// whether the returned error was because http.StatusNotModified was
28390// returned.
28391func (c *ProjectsAgentSessionsContextsListCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDialogflowV2ListContextsResponse, error) {
28392	gensupport.SetOptions(c.urlParams_, opts...)
28393	res, err := c.doRequest("json")
28394	if res != nil && res.StatusCode == http.StatusNotModified {
28395		if res.Body != nil {
28396			res.Body.Close()
28397		}
28398		return nil, &googleapi.Error{
28399			Code:   res.StatusCode,
28400			Header: res.Header,
28401		}
28402	}
28403	if err != nil {
28404		return nil, err
28405	}
28406	defer googleapi.CloseBody(res)
28407	if err := googleapi.CheckResponse(res); err != nil {
28408		return nil, err
28409	}
28410	ret := &GoogleCloudDialogflowV2ListContextsResponse{
28411		ServerResponse: googleapi.ServerResponse{
28412			Header:         res.Header,
28413			HTTPStatusCode: res.StatusCode,
28414		},
28415	}
28416	target := &ret
28417	if err := gensupport.DecodeResponse(target, res); err != nil {
28418		return nil, err
28419	}
28420	return ret, nil
28421	// {
28422	//   "description": "Returns the list of all contexts in the specified session.",
28423	//   "flatPath": "v2/projects/{projectsId}/agent/sessions/{sessionsId}/contexts",
28424	//   "httpMethod": "GET",
28425	//   "id": "dialogflow.projects.agent.sessions.contexts.list",
28426	//   "parameterOrder": [
28427	//     "parent"
28428	//   ],
28429	//   "parameters": {
28430	//     "pageSize": {
28431	//       "description": "Optional. The maximum number of items to return in a single page. By default 100 and at most 1000.",
28432	//       "format": "int32",
28433	//       "location": "query",
28434	//       "type": "integer"
28435	//     },
28436	//     "pageToken": {
28437	//       "description": "Optional. The next_page_token value returned from a previous list request.",
28438	//       "location": "query",
28439	//       "type": "string"
28440	//     },
28441	//     "parent": {
28442	//       "description": "Required. The session to list all contexts from. Format: `projects//agent/sessions/` or `projects//agent/environments//users//sessions/`. If `Environment ID` is not specified, we assume default 'draft' environment. If `User ID` is not specified, we assume default '-' user.",
28443	//       "location": "path",
28444	//       "pattern": "^projects/[^/]+/agent/sessions/[^/]+$",
28445	//       "required": true,
28446	//       "type": "string"
28447	//     }
28448	//   },
28449	//   "path": "v2/{+parent}/contexts",
28450	//   "response": {
28451	//     "$ref": "GoogleCloudDialogflowV2ListContextsResponse"
28452	//   },
28453	//   "scopes": [
28454	//     "https://www.googleapis.com/auth/cloud-platform",
28455	//     "https://www.googleapis.com/auth/dialogflow"
28456	//   ]
28457	// }
28458
28459}
28460
28461// Pages invokes f for each page of results.
28462// A non-nil error returned from f will halt the iteration.
28463// The provided context supersedes any context provided to the Context method.
28464func (c *ProjectsAgentSessionsContextsListCall) Pages(ctx context.Context, f func(*GoogleCloudDialogflowV2ListContextsResponse) error) error {
28465	c.ctx_ = ctx
28466	defer c.PageToken(c.urlParams_.Get("pageToken")) // reset paging to original point
28467	for {
28468		x, err := c.Do()
28469		if err != nil {
28470			return err
28471		}
28472		if err := f(x); err != nil {
28473			return err
28474		}
28475		if x.NextPageToken == "" {
28476			return nil
28477		}
28478		c.PageToken(x.NextPageToken)
28479	}
28480}
28481
28482// method id "dialogflow.projects.agent.sessions.contexts.patch":
28483
28484type ProjectsAgentSessionsContextsPatchCall struct {
28485	s                              *Service
28486	nameid                         string
28487	googleclouddialogflowv2context *GoogleCloudDialogflowV2Context
28488	urlParams_                     gensupport.URLParams
28489	ctx_                           context.Context
28490	header_                        http.Header
28491}
28492
28493// Patch: Updates the specified context.
28494//
28495// - name: The unique identifier of the context. Format:
28496//   `projects//agent/sessions//contexts/`, or
28497//   `projects//agent/environments//users//sessions//contexts/`. The
28498//   `Context ID` is always converted to lowercase, may only contain
28499//   characters in a-zA-Z0-9_-% and may be at most 250 bytes long. If
28500//   `Environment ID` is not specified, we assume default 'draft'
28501//   environment. If `User ID` is not specified, we assume default '-'
28502//   user. The following context names are reserved for internal use by
28503//   Dialogflow. You should not use these contexts or create contexts
28504//   with these names: * `__system_counters__` * `*_id_dialog_context` *
28505//   `*_dialog_params_size`.
28506func (r *ProjectsAgentSessionsContextsService) Patch(nameid string, googleclouddialogflowv2context *GoogleCloudDialogflowV2Context) *ProjectsAgentSessionsContextsPatchCall {
28507	c := &ProjectsAgentSessionsContextsPatchCall{s: r.s, urlParams_: make(gensupport.URLParams)}
28508	c.nameid = nameid
28509	c.googleclouddialogflowv2context = googleclouddialogflowv2context
28510	return c
28511}
28512
28513// UpdateMask sets the optional parameter "updateMask": The mask to
28514// control which fields get updated.
28515func (c *ProjectsAgentSessionsContextsPatchCall) UpdateMask(updateMask string) *ProjectsAgentSessionsContextsPatchCall {
28516	c.urlParams_.Set("updateMask", updateMask)
28517	return c
28518}
28519
28520// Fields allows partial responses to be retrieved. See
28521// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
28522// for more information.
28523func (c *ProjectsAgentSessionsContextsPatchCall) Fields(s ...googleapi.Field) *ProjectsAgentSessionsContextsPatchCall {
28524	c.urlParams_.Set("fields", googleapi.CombineFields(s))
28525	return c
28526}
28527
28528// Context sets the context to be used in this call's Do method. Any
28529// pending HTTP request will be aborted if the provided context is
28530// canceled.
28531func (c *ProjectsAgentSessionsContextsPatchCall) Context(ctx context.Context) *ProjectsAgentSessionsContextsPatchCall {
28532	c.ctx_ = ctx
28533	return c
28534}
28535
28536// Header returns an http.Header that can be modified by the caller to
28537// add HTTP headers to the request.
28538func (c *ProjectsAgentSessionsContextsPatchCall) Header() http.Header {
28539	if c.header_ == nil {
28540		c.header_ = make(http.Header)
28541	}
28542	return c.header_
28543}
28544
28545func (c *ProjectsAgentSessionsContextsPatchCall) doRequest(alt string) (*http.Response, error) {
28546	reqHeaders := make(http.Header)
28547	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20211027")
28548	for k, v := range c.header_ {
28549		reqHeaders[k] = v
28550	}
28551	reqHeaders.Set("User-Agent", c.s.userAgent())
28552	var body io.Reader = nil
28553	body, err := googleapi.WithoutDataWrapper.JSONReader(c.googleclouddialogflowv2context)
28554	if err != nil {
28555		return nil, err
28556	}
28557	reqHeaders.Set("Content-Type", "application/json")
28558	c.urlParams_.Set("alt", alt)
28559	c.urlParams_.Set("prettyPrint", "false")
28560	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+name}")
28561	urls += "?" + c.urlParams_.Encode()
28562	req, err := http.NewRequest("PATCH", urls, body)
28563	if err != nil {
28564		return nil, err
28565	}
28566	req.Header = reqHeaders
28567	googleapi.Expand(req.URL, map[string]string{
28568		"name": c.nameid,
28569	})
28570	return gensupport.SendRequest(c.ctx_, c.s.client, req)
28571}
28572
28573// Do executes the "dialogflow.projects.agent.sessions.contexts.patch" call.
28574// Exactly one of *GoogleCloudDialogflowV2Context or error will be
28575// non-nil. Any non-2xx status code is an error. Response headers are in
28576// either *GoogleCloudDialogflowV2Context.ServerResponse.Header or (if a
28577// response was returned at all) in error.(*googleapi.Error).Header. Use
28578// googleapi.IsNotModified to check whether the returned error was
28579// because http.StatusNotModified was returned.
28580func (c *ProjectsAgentSessionsContextsPatchCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDialogflowV2Context, error) {
28581	gensupport.SetOptions(c.urlParams_, opts...)
28582	res, err := c.doRequest("json")
28583	if res != nil && res.StatusCode == http.StatusNotModified {
28584		if res.Body != nil {
28585			res.Body.Close()
28586		}
28587		return nil, &googleapi.Error{
28588			Code:   res.StatusCode,
28589			Header: res.Header,
28590		}
28591	}
28592	if err != nil {
28593		return nil, err
28594	}
28595	defer googleapi.CloseBody(res)
28596	if err := googleapi.CheckResponse(res); err != nil {
28597		return nil, err
28598	}
28599	ret := &GoogleCloudDialogflowV2Context{
28600		ServerResponse: googleapi.ServerResponse{
28601			Header:         res.Header,
28602			HTTPStatusCode: res.StatusCode,
28603		},
28604	}
28605	target := &ret
28606	if err := gensupport.DecodeResponse(target, res); err != nil {
28607		return nil, err
28608	}
28609	return ret, nil
28610	// {
28611	//   "description": "Updates the specified context.",
28612	//   "flatPath": "v2/projects/{projectsId}/agent/sessions/{sessionsId}/contexts/{contextsId}",
28613	//   "httpMethod": "PATCH",
28614	//   "id": "dialogflow.projects.agent.sessions.contexts.patch",
28615	//   "parameterOrder": [
28616	//     "name"
28617	//   ],
28618	//   "parameters": {
28619	//     "name": {
28620	//       "description": "Required. The unique identifier of the context. Format: `projects//agent/sessions//contexts/`, or `projects//agent/environments//users//sessions//contexts/`. The `Context ID` is always converted to lowercase, may only contain characters in a-zA-Z0-9_-% and may be at most 250 bytes long. If `Environment ID` is not specified, we assume default 'draft' environment. If `User ID` is not specified, we assume default '-' user. The following context names are reserved for internal use by Dialogflow. You should not use these contexts or create contexts with these names: * `__system_counters__` * `*_id_dialog_context` * `*_dialog_params_size`",
28621	//       "location": "path",
28622	//       "pattern": "^projects/[^/]+/agent/sessions/[^/]+/contexts/[^/]+$",
28623	//       "required": true,
28624	//       "type": "string"
28625	//     },
28626	//     "updateMask": {
28627	//       "description": "Optional. The mask to control which fields get updated.",
28628	//       "format": "google-fieldmask",
28629	//       "location": "query",
28630	//       "type": "string"
28631	//     }
28632	//   },
28633	//   "path": "v2/{+name}",
28634	//   "request": {
28635	//     "$ref": "GoogleCloudDialogflowV2Context"
28636	//   },
28637	//   "response": {
28638	//     "$ref": "GoogleCloudDialogflowV2Context"
28639	//   },
28640	//   "scopes": [
28641	//     "https://www.googleapis.com/auth/cloud-platform",
28642	//     "https://www.googleapis.com/auth/dialogflow"
28643	//   ]
28644	// }
28645
28646}
28647
28648// method id "dialogflow.projects.agent.sessions.entityTypes.create":
28649
28650type ProjectsAgentSessionsEntityTypesCreateCall struct {
28651	s                                        *Service
28652	parent                                   string
28653	googleclouddialogflowv2sessionentitytype *GoogleCloudDialogflowV2SessionEntityType
28654	urlParams_                               gensupport.URLParams
28655	ctx_                                     context.Context
28656	header_                                  http.Header
28657}
28658
28659// Create: Creates a session entity type. If the specified session
28660// entity type already exists, overrides the session entity type. This
28661// method doesn't work with Google Assistant integration. Contact
28662// Dialogflow support if you need to use session entities with Google
28663// Assistant integration.
28664//
28665// - parent: The session to create a session entity type for. Format:
28666//   `projects//agent/sessions/` or
28667//   `projects//agent/environments//users// sessions/`. If `Environment
28668//   ID` is not specified, we assume default 'draft' environment. If
28669//   `User ID` is not specified, we assume default '-' user.
28670func (r *ProjectsAgentSessionsEntityTypesService) Create(parent string, googleclouddialogflowv2sessionentitytype *GoogleCloudDialogflowV2SessionEntityType) *ProjectsAgentSessionsEntityTypesCreateCall {
28671	c := &ProjectsAgentSessionsEntityTypesCreateCall{s: r.s, urlParams_: make(gensupport.URLParams)}
28672	c.parent = parent
28673	c.googleclouddialogflowv2sessionentitytype = googleclouddialogflowv2sessionentitytype
28674	return c
28675}
28676
28677// Fields allows partial responses to be retrieved. See
28678// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
28679// for more information.
28680func (c *ProjectsAgentSessionsEntityTypesCreateCall) Fields(s ...googleapi.Field) *ProjectsAgentSessionsEntityTypesCreateCall {
28681	c.urlParams_.Set("fields", googleapi.CombineFields(s))
28682	return c
28683}
28684
28685// Context sets the context to be used in this call's Do method. Any
28686// pending HTTP request will be aborted if the provided context is
28687// canceled.
28688func (c *ProjectsAgentSessionsEntityTypesCreateCall) Context(ctx context.Context) *ProjectsAgentSessionsEntityTypesCreateCall {
28689	c.ctx_ = ctx
28690	return c
28691}
28692
28693// Header returns an http.Header that can be modified by the caller to
28694// add HTTP headers to the request.
28695func (c *ProjectsAgentSessionsEntityTypesCreateCall) Header() http.Header {
28696	if c.header_ == nil {
28697		c.header_ = make(http.Header)
28698	}
28699	return c.header_
28700}
28701
28702func (c *ProjectsAgentSessionsEntityTypesCreateCall) doRequest(alt string) (*http.Response, error) {
28703	reqHeaders := make(http.Header)
28704	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20211027")
28705	for k, v := range c.header_ {
28706		reqHeaders[k] = v
28707	}
28708	reqHeaders.Set("User-Agent", c.s.userAgent())
28709	var body io.Reader = nil
28710	body, err := googleapi.WithoutDataWrapper.JSONReader(c.googleclouddialogflowv2sessionentitytype)
28711	if err != nil {
28712		return nil, err
28713	}
28714	reqHeaders.Set("Content-Type", "application/json")
28715	c.urlParams_.Set("alt", alt)
28716	c.urlParams_.Set("prettyPrint", "false")
28717	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+parent}/entityTypes")
28718	urls += "?" + c.urlParams_.Encode()
28719	req, err := http.NewRequest("POST", urls, body)
28720	if err != nil {
28721		return nil, err
28722	}
28723	req.Header = reqHeaders
28724	googleapi.Expand(req.URL, map[string]string{
28725		"parent": c.parent,
28726	})
28727	return gensupport.SendRequest(c.ctx_, c.s.client, req)
28728}
28729
28730// Do executes the "dialogflow.projects.agent.sessions.entityTypes.create" call.
28731// Exactly one of *GoogleCloudDialogflowV2SessionEntityType or error
28732// will be non-nil. Any non-2xx status code is an error. Response
28733// headers are in either
28734// *GoogleCloudDialogflowV2SessionEntityType.ServerResponse.Header or
28735// (if a response was returned at all) in
28736// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
28737// whether the returned error was because http.StatusNotModified was
28738// returned.
28739func (c *ProjectsAgentSessionsEntityTypesCreateCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDialogflowV2SessionEntityType, error) {
28740	gensupport.SetOptions(c.urlParams_, opts...)
28741	res, err := c.doRequest("json")
28742	if res != nil && res.StatusCode == http.StatusNotModified {
28743		if res.Body != nil {
28744			res.Body.Close()
28745		}
28746		return nil, &googleapi.Error{
28747			Code:   res.StatusCode,
28748			Header: res.Header,
28749		}
28750	}
28751	if err != nil {
28752		return nil, err
28753	}
28754	defer googleapi.CloseBody(res)
28755	if err := googleapi.CheckResponse(res); err != nil {
28756		return nil, err
28757	}
28758	ret := &GoogleCloudDialogflowV2SessionEntityType{
28759		ServerResponse: googleapi.ServerResponse{
28760			Header:         res.Header,
28761			HTTPStatusCode: res.StatusCode,
28762		},
28763	}
28764	target := &ret
28765	if err := gensupport.DecodeResponse(target, res); err != nil {
28766		return nil, err
28767	}
28768	return ret, nil
28769	// {
28770	//   "description": "Creates a session entity type. If the specified session entity type already exists, overrides the session entity type. This method doesn't work with Google Assistant integration. Contact Dialogflow support if you need to use session entities with Google Assistant integration.",
28771	//   "flatPath": "v2/projects/{projectsId}/agent/sessions/{sessionsId}/entityTypes",
28772	//   "httpMethod": "POST",
28773	//   "id": "dialogflow.projects.agent.sessions.entityTypes.create",
28774	//   "parameterOrder": [
28775	//     "parent"
28776	//   ],
28777	//   "parameters": {
28778	//     "parent": {
28779	//       "description": "Required. The session to create a session entity type for. Format: `projects//agent/sessions/` or `projects//agent/environments//users// sessions/`. If `Environment ID` is not specified, we assume default 'draft' environment. If `User ID` is not specified, we assume default '-' user.",
28780	//       "location": "path",
28781	//       "pattern": "^projects/[^/]+/agent/sessions/[^/]+$",
28782	//       "required": true,
28783	//       "type": "string"
28784	//     }
28785	//   },
28786	//   "path": "v2/{+parent}/entityTypes",
28787	//   "request": {
28788	//     "$ref": "GoogleCloudDialogflowV2SessionEntityType"
28789	//   },
28790	//   "response": {
28791	//     "$ref": "GoogleCloudDialogflowV2SessionEntityType"
28792	//   },
28793	//   "scopes": [
28794	//     "https://www.googleapis.com/auth/cloud-platform",
28795	//     "https://www.googleapis.com/auth/dialogflow"
28796	//   ]
28797	// }
28798
28799}
28800
28801// method id "dialogflow.projects.agent.sessions.entityTypes.delete":
28802
28803type ProjectsAgentSessionsEntityTypesDeleteCall struct {
28804	s          *Service
28805	name       string
28806	urlParams_ gensupport.URLParams
28807	ctx_       context.Context
28808	header_    http.Header
28809}
28810
28811// Delete: Deletes the specified session entity type. This method
28812// doesn't work with Google Assistant integration. Contact Dialogflow
28813// support if you need to use session entities with Google Assistant
28814// integration.
28815//
28816// - name: The name of the entity type to delete. Format:
28817//   `projects//agent/sessions//entityTypes/` or
28818//   `projects//agent/environments//users//sessions//entityTypes/`. If
28819//   `Environment ID` is not specified, we assume default 'draft'
28820//   environment. If `User ID` is not specified, we assume default '-'
28821//   user.
28822func (r *ProjectsAgentSessionsEntityTypesService) Delete(name string) *ProjectsAgentSessionsEntityTypesDeleteCall {
28823	c := &ProjectsAgentSessionsEntityTypesDeleteCall{s: r.s, urlParams_: make(gensupport.URLParams)}
28824	c.name = name
28825	return c
28826}
28827
28828// Fields allows partial responses to be retrieved. See
28829// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
28830// for more information.
28831func (c *ProjectsAgentSessionsEntityTypesDeleteCall) Fields(s ...googleapi.Field) *ProjectsAgentSessionsEntityTypesDeleteCall {
28832	c.urlParams_.Set("fields", googleapi.CombineFields(s))
28833	return c
28834}
28835
28836// Context sets the context to be used in this call's Do method. Any
28837// pending HTTP request will be aborted if the provided context is
28838// canceled.
28839func (c *ProjectsAgentSessionsEntityTypesDeleteCall) Context(ctx context.Context) *ProjectsAgentSessionsEntityTypesDeleteCall {
28840	c.ctx_ = ctx
28841	return c
28842}
28843
28844// Header returns an http.Header that can be modified by the caller to
28845// add HTTP headers to the request.
28846func (c *ProjectsAgentSessionsEntityTypesDeleteCall) Header() http.Header {
28847	if c.header_ == nil {
28848		c.header_ = make(http.Header)
28849	}
28850	return c.header_
28851}
28852
28853func (c *ProjectsAgentSessionsEntityTypesDeleteCall) doRequest(alt string) (*http.Response, error) {
28854	reqHeaders := make(http.Header)
28855	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20211027")
28856	for k, v := range c.header_ {
28857		reqHeaders[k] = v
28858	}
28859	reqHeaders.Set("User-Agent", c.s.userAgent())
28860	var body io.Reader = nil
28861	c.urlParams_.Set("alt", alt)
28862	c.urlParams_.Set("prettyPrint", "false")
28863	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+name}")
28864	urls += "?" + c.urlParams_.Encode()
28865	req, err := http.NewRequest("DELETE", urls, body)
28866	if err != nil {
28867		return nil, err
28868	}
28869	req.Header = reqHeaders
28870	googleapi.Expand(req.URL, map[string]string{
28871		"name": c.name,
28872	})
28873	return gensupport.SendRequest(c.ctx_, c.s.client, req)
28874}
28875
28876// Do executes the "dialogflow.projects.agent.sessions.entityTypes.delete" call.
28877// Exactly one of *GoogleProtobufEmpty or error will be non-nil. Any
28878// non-2xx status code is an error. Response headers are in either
28879// *GoogleProtobufEmpty.ServerResponse.Header or (if a response was
28880// returned at all) in error.(*googleapi.Error).Header. Use
28881// googleapi.IsNotModified to check whether the returned error was
28882// because http.StatusNotModified was returned.
28883func (c *ProjectsAgentSessionsEntityTypesDeleteCall) Do(opts ...googleapi.CallOption) (*GoogleProtobufEmpty, error) {
28884	gensupport.SetOptions(c.urlParams_, opts...)
28885	res, err := c.doRequest("json")
28886	if res != nil && res.StatusCode == http.StatusNotModified {
28887		if res.Body != nil {
28888			res.Body.Close()
28889		}
28890		return nil, &googleapi.Error{
28891			Code:   res.StatusCode,
28892			Header: res.Header,
28893		}
28894	}
28895	if err != nil {
28896		return nil, err
28897	}
28898	defer googleapi.CloseBody(res)
28899	if err := googleapi.CheckResponse(res); err != nil {
28900		return nil, err
28901	}
28902	ret := &GoogleProtobufEmpty{
28903		ServerResponse: googleapi.ServerResponse{
28904			Header:         res.Header,
28905			HTTPStatusCode: res.StatusCode,
28906		},
28907	}
28908	target := &ret
28909	if err := gensupport.DecodeResponse(target, res); err != nil {
28910		return nil, err
28911	}
28912	return ret, nil
28913	// {
28914	//   "description": "Deletes the specified session entity type. This method doesn't work with Google Assistant integration. Contact Dialogflow support if you need to use session entities with Google Assistant integration.",
28915	//   "flatPath": "v2/projects/{projectsId}/agent/sessions/{sessionsId}/entityTypes/{entityTypesId}",
28916	//   "httpMethod": "DELETE",
28917	//   "id": "dialogflow.projects.agent.sessions.entityTypes.delete",
28918	//   "parameterOrder": [
28919	//     "name"
28920	//   ],
28921	//   "parameters": {
28922	//     "name": {
28923	//       "description": "Required. The name of the entity type to delete. Format: `projects//agent/sessions//entityTypes/` or `projects//agent/environments//users//sessions//entityTypes/`. If `Environment ID` is not specified, we assume default 'draft' environment. If `User ID` is not specified, we assume default '-' user.",
28924	//       "location": "path",
28925	//       "pattern": "^projects/[^/]+/agent/sessions/[^/]+/entityTypes/[^/]+$",
28926	//       "required": true,
28927	//       "type": "string"
28928	//     }
28929	//   },
28930	//   "path": "v2/{+name}",
28931	//   "response": {
28932	//     "$ref": "GoogleProtobufEmpty"
28933	//   },
28934	//   "scopes": [
28935	//     "https://www.googleapis.com/auth/cloud-platform",
28936	//     "https://www.googleapis.com/auth/dialogflow"
28937	//   ]
28938	// }
28939
28940}
28941
28942// method id "dialogflow.projects.agent.sessions.entityTypes.get":
28943
28944type ProjectsAgentSessionsEntityTypesGetCall struct {
28945	s            *Service
28946	name         string
28947	urlParams_   gensupport.URLParams
28948	ifNoneMatch_ string
28949	ctx_         context.Context
28950	header_      http.Header
28951}
28952
28953// Get: Retrieves the specified session entity type. This method doesn't
28954// work with Google Assistant integration. Contact Dialogflow support if
28955// you need to use session entities with Google Assistant integration.
28956//
28957// - name: The name of the session entity type. Format:
28958//   `projects//agent/sessions//entityTypes/` or
28959//   `projects//agent/environments//users//sessions//entityTypes/`. If
28960//   `Environment ID` is not specified, we assume default 'draft'
28961//   environment. If `User ID` is not specified, we assume default '-'
28962//   user.
28963func (r *ProjectsAgentSessionsEntityTypesService) Get(name string) *ProjectsAgentSessionsEntityTypesGetCall {
28964	c := &ProjectsAgentSessionsEntityTypesGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
28965	c.name = name
28966	return c
28967}
28968
28969// Fields allows partial responses to be retrieved. See
28970// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
28971// for more information.
28972func (c *ProjectsAgentSessionsEntityTypesGetCall) Fields(s ...googleapi.Field) *ProjectsAgentSessionsEntityTypesGetCall {
28973	c.urlParams_.Set("fields", googleapi.CombineFields(s))
28974	return c
28975}
28976
28977// IfNoneMatch sets the optional parameter which makes the operation
28978// fail if the object's ETag matches the given value. This is useful for
28979// getting updates only after the object has changed since the last
28980// request. Use googleapi.IsNotModified to check whether the response
28981// error from Do is the result of In-None-Match.
28982func (c *ProjectsAgentSessionsEntityTypesGetCall) IfNoneMatch(entityTag string) *ProjectsAgentSessionsEntityTypesGetCall {
28983	c.ifNoneMatch_ = entityTag
28984	return c
28985}
28986
28987// Context sets the context to be used in this call's Do method. Any
28988// pending HTTP request will be aborted if the provided context is
28989// canceled.
28990func (c *ProjectsAgentSessionsEntityTypesGetCall) Context(ctx context.Context) *ProjectsAgentSessionsEntityTypesGetCall {
28991	c.ctx_ = ctx
28992	return c
28993}
28994
28995// Header returns an http.Header that can be modified by the caller to
28996// add HTTP headers to the request.
28997func (c *ProjectsAgentSessionsEntityTypesGetCall) Header() http.Header {
28998	if c.header_ == nil {
28999		c.header_ = make(http.Header)
29000	}
29001	return c.header_
29002}
29003
29004func (c *ProjectsAgentSessionsEntityTypesGetCall) doRequest(alt string) (*http.Response, error) {
29005	reqHeaders := make(http.Header)
29006	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20211027")
29007	for k, v := range c.header_ {
29008		reqHeaders[k] = v
29009	}
29010	reqHeaders.Set("User-Agent", c.s.userAgent())
29011	if c.ifNoneMatch_ != "" {
29012		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
29013	}
29014	var body io.Reader = nil
29015	c.urlParams_.Set("alt", alt)
29016	c.urlParams_.Set("prettyPrint", "false")
29017	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+name}")
29018	urls += "?" + c.urlParams_.Encode()
29019	req, err := http.NewRequest("GET", urls, body)
29020	if err != nil {
29021		return nil, err
29022	}
29023	req.Header = reqHeaders
29024	googleapi.Expand(req.URL, map[string]string{
29025		"name": c.name,
29026	})
29027	return gensupport.SendRequest(c.ctx_, c.s.client, req)
29028}
29029
29030// Do executes the "dialogflow.projects.agent.sessions.entityTypes.get" call.
29031// Exactly one of *GoogleCloudDialogflowV2SessionEntityType or error
29032// will be non-nil. Any non-2xx status code is an error. Response
29033// headers are in either
29034// *GoogleCloudDialogflowV2SessionEntityType.ServerResponse.Header or
29035// (if a response was returned at all) in
29036// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
29037// whether the returned error was because http.StatusNotModified was
29038// returned.
29039func (c *ProjectsAgentSessionsEntityTypesGetCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDialogflowV2SessionEntityType, error) {
29040	gensupport.SetOptions(c.urlParams_, opts...)
29041	res, err := c.doRequest("json")
29042	if res != nil && res.StatusCode == http.StatusNotModified {
29043		if res.Body != nil {
29044			res.Body.Close()
29045		}
29046		return nil, &googleapi.Error{
29047			Code:   res.StatusCode,
29048			Header: res.Header,
29049		}
29050	}
29051	if err != nil {
29052		return nil, err
29053	}
29054	defer googleapi.CloseBody(res)
29055	if err := googleapi.CheckResponse(res); err != nil {
29056		return nil, err
29057	}
29058	ret := &GoogleCloudDialogflowV2SessionEntityType{
29059		ServerResponse: googleapi.ServerResponse{
29060			Header:         res.Header,
29061			HTTPStatusCode: res.StatusCode,
29062		},
29063	}
29064	target := &ret
29065	if err := gensupport.DecodeResponse(target, res); err != nil {
29066		return nil, err
29067	}
29068	return ret, nil
29069	// {
29070	//   "description": "Retrieves the specified session entity type. This method doesn't work with Google Assistant integration. Contact Dialogflow support if you need to use session entities with Google Assistant integration.",
29071	//   "flatPath": "v2/projects/{projectsId}/agent/sessions/{sessionsId}/entityTypes/{entityTypesId}",
29072	//   "httpMethod": "GET",
29073	//   "id": "dialogflow.projects.agent.sessions.entityTypes.get",
29074	//   "parameterOrder": [
29075	//     "name"
29076	//   ],
29077	//   "parameters": {
29078	//     "name": {
29079	//       "description": "Required. The name of the session entity type. Format: `projects//agent/sessions//entityTypes/` or `projects//agent/environments//users//sessions//entityTypes/`. If `Environment ID` is not specified, we assume default 'draft' environment. If `User ID` is not specified, we assume default '-' user.",
29080	//       "location": "path",
29081	//       "pattern": "^projects/[^/]+/agent/sessions/[^/]+/entityTypes/[^/]+$",
29082	//       "required": true,
29083	//       "type": "string"
29084	//     }
29085	//   },
29086	//   "path": "v2/{+name}",
29087	//   "response": {
29088	//     "$ref": "GoogleCloudDialogflowV2SessionEntityType"
29089	//   },
29090	//   "scopes": [
29091	//     "https://www.googleapis.com/auth/cloud-platform",
29092	//     "https://www.googleapis.com/auth/dialogflow"
29093	//   ]
29094	// }
29095
29096}
29097
29098// method id "dialogflow.projects.agent.sessions.entityTypes.list":
29099
29100type ProjectsAgentSessionsEntityTypesListCall struct {
29101	s            *Service
29102	parent       string
29103	urlParams_   gensupport.URLParams
29104	ifNoneMatch_ string
29105	ctx_         context.Context
29106	header_      http.Header
29107}
29108
29109// List: Returns the list of all session entity types in the specified
29110// session. This method doesn't work with Google Assistant integration.
29111// Contact Dialogflow support if you need to use session entities with
29112// Google Assistant integration.
29113//
29114// - parent: The session to list all session entity types from. Format:
29115//   `projects//agent/sessions/` or
29116//   `projects//agent/environments//users// sessions/`. If `Environment
29117//   ID` is not specified, we assume default 'draft' environment. If
29118//   `User ID` is not specified, we assume default '-' user.
29119func (r *ProjectsAgentSessionsEntityTypesService) List(parent string) *ProjectsAgentSessionsEntityTypesListCall {
29120	c := &ProjectsAgentSessionsEntityTypesListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
29121	c.parent = parent
29122	return c
29123}
29124
29125// PageSize sets the optional parameter "pageSize": The maximum number
29126// of items to return in a single page. By default 100 and at most 1000.
29127func (c *ProjectsAgentSessionsEntityTypesListCall) PageSize(pageSize int64) *ProjectsAgentSessionsEntityTypesListCall {
29128	c.urlParams_.Set("pageSize", fmt.Sprint(pageSize))
29129	return c
29130}
29131
29132// PageToken sets the optional parameter "pageToken": The
29133// next_page_token value returned from a previous list request.
29134func (c *ProjectsAgentSessionsEntityTypesListCall) PageToken(pageToken string) *ProjectsAgentSessionsEntityTypesListCall {
29135	c.urlParams_.Set("pageToken", pageToken)
29136	return c
29137}
29138
29139// Fields allows partial responses to be retrieved. See
29140// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
29141// for more information.
29142func (c *ProjectsAgentSessionsEntityTypesListCall) Fields(s ...googleapi.Field) *ProjectsAgentSessionsEntityTypesListCall {
29143	c.urlParams_.Set("fields", googleapi.CombineFields(s))
29144	return c
29145}
29146
29147// IfNoneMatch sets the optional parameter which makes the operation
29148// fail if the object's ETag matches the given value. This is useful for
29149// getting updates only after the object has changed since the last
29150// request. Use googleapi.IsNotModified to check whether the response
29151// error from Do is the result of In-None-Match.
29152func (c *ProjectsAgentSessionsEntityTypesListCall) IfNoneMatch(entityTag string) *ProjectsAgentSessionsEntityTypesListCall {
29153	c.ifNoneMatch_ = entityTag
29154	return c
29155}
29156
29157// Context sets the context to be used in this call's Do method. Any
29158// pending HTTP request will be aborted if the provided context is
29159// canceled.
29160func (c *ProjectsAgentSessionsEntityTypesListCall) Context(ctx context.Context) *ProjectsAgentSessionsEntityTypesListCall {
29161	c.ctx_ = ctx
29162	return c
29163}
29164
29165// Header returns an http.Header that can be modified by the caller to
29166// add HTTP headers to the request.
29167func (c *ProjectsAgentSessionsEntityTypesListCall) Header() http.Header {
29168	if c.header_ == nil {
29169		c.header_ = make(http.Header)
29170	}
29171	return c.header_
29172}
29173
29174func (c *ProjectsAgentSessionsEntityTypesListCall) doRequest(alt string) (*http.Response, error) {
29175	reqHeaders := make(http.Header)
29176	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20211027")
29177	for k, v := range c.header_ {
29178		reqHeaders[k] = v
29179	}
29180	reqHeaders.Set("User-Agent", c.s.userAgent())
29181	if c.ifNoneMatch_ != "" {
29182		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
29183	}
29184	var body io.Reader = nil
29185	c.urlParams_.Set("alt", alt)
29186	c.urlParams_.Set("prettyPrint", "false")
29187	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+parent}/entityTypes")
29188	urls += "?" + c.urlParams_.Encode()
29189	req, err := http.NewRequest("GET", urls, body)
29190	if err != nil {
29191		return nil, err
29192	}
29193	req.Header = reqHeaders
29194	googleapi.Expand(req.URL, map[string]string{
29195		"parent": c.parent,
29196	})
29197	return gensupport.SendRequest(c.ctx_, c.s.client, req)
29198}
29199
29200// Do executes the "dialogflow.projects.agent.sessions.entityTypes.list" call.
29201// Exactly one of *GoogleCloudDialogflowV2ListSessionEntityTypesResponse
29202// or error will be non-nil. Any non-2xx status code is an error.
29203// Response headers are in either
29204// *GoogleCloudDialogflowV2ListSessionEntityTypesResponse.ServerResponse.
29205// Header or (if a response was returned at all) in
29206// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
29207// whether the returned error was because http.StatusNotModified was
29208// returned.
29209func (c *ProjectsAgentSessionsEntityTypesListCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDialogflowV2ListSessionEntityTypesResponse, error) {
29210	gensupport.SetOptions(c.urlParams_, opts...)
29211	res, err := c.doRequest("json")
29212	if res != nil && res.StatusCode == http.StatusNotModified {
29213		if res.Body != nil {
29214			res.Body.Close()
29215		}
29216		return nil, &googleapi.Error{
29217			Code:   res.StatusCode,
29218			Header: res.Header,
29219		}
29220	}
29221	if err != nil {
29222		return nil, err
29223	}
29224	defer googleapi.CloseBody(res)
29225	if err := googleapi.CheckResponse(res); err != nil {
29226		return nil, err
29227	}
29228	ret := &GoogleCloudDialogflowV2ListSessionEntityTypesResponse{
29229		ServerResponse: googleapi.ServerResponse{
29230			Header:         res.Header,
29231			HTTPStatusCode: res.StatusCode,
29232		},
29233	}
29234	target := &ret
29235	if err := gensupport.DecodeResponse(target, res); err != nil {
29236		return nil, err
29237	}
29238	return ret, nil
29239	// {
29240	//   "description": "Returns the list of all session entity types in the specified session. This method doesn't work with Google Assistant integration. Contact Dialogflow support if you need to use session entities with Google Assistant integration.",
29241	//   "flatPath": "v2/projects/{projectsId}/agent/sessions/{sessionsId}/entityTypes",
29242	//   "httpMethod": "GET",
29243	//   "id": "dialogflow.projects.agent.sessions.entityTypes.list",
29244	//   "parameterOrder": [
29245	//     "parent"
29246	//   ],
29247	//   "parameters": {
29248	//     "pageSize": {
29249	//       "description": "Optional. The maximum number of items to return in a single page. By default 100 and at most 1000.",
29250	//       "format": "int32",
29251	//       "location": "query",
29252	//       "type": "integer"
29253	//     },
29254	//     "pageToken": {
29255	//       "description": "Optional. The next_page_token value returned from a previous list request.",
29256	//       "location": "query",
29257	//       "type": "string"
29258	//     },
29259	//     "parent": {
29260	//       "description": "Required. The session to list all session entity types from. Format: `projects//agent/sessions/` or `projects//agent/environments//users// sessions/`. If `Environment ID` is not specified, we assume default 'draft' environment. If `User ID` is not specified, we assume default '-' user.",
29261	//       "location": "path",
29262	//       "pattern": "^projects/[^/]+/agent/sessions/[^/]+$",
29263	//       "required": true,
29264	//       "type": "string"
29265	//     }
29266	//   },
29267	//   "path": "v2/{+parent}/entityTypes",
29268	//   "response": {
29269	//     "$ref": "GoogleCloudDialogflowV2ListSessionEntityTypesResponse"
29270	//   },
29271	//   "scopes": [
29272	//     "https://www.googleapis.com/auth/cloud-platform",
29273	//     "https://www.googleapis.com/auth/dialogflow"
29274	//   ]
29275	// }
29276
29277}
29278
29279// Pages invokes f for each page of results.
29280// A non-nil error returned from f will halt the iteration.
29281// The provided context supersedes any context provided to the Context method.
29282func (c *ProjectsAgentSessionsEntityTypesListCall) Pages(ctx context.Context, f func(*GoogleCloudDialogflowV2ListSessionEntityTypesResponse) error) error {
29283	c.ctx_ = ctx
29284	defer c.PageToken(c.urlParams_.Get("pageToken")) // reset paging to original point
29285	for {
29286		x, err := c.Do()
29287		if err != nil {
29288			return err
29289		}
29290		if err := f(x); err != nil {
29291			return err
29292		}
29293		if x.NextPageToken == "" {
29294			return nil
29295		}
29296		c.PageToken(x.NextPageToken)
29297	}
29298}
29299
29300// method id "dialogflow.projects.agent.sessions.entityTypes.patch":
29301
29302type ProjectsAgentSessionsEntityTypesPatchCall struct {
29303	s                                        *Service
29304	nameid                                   string
29305	googleclouddialogflowv2sessionentitytype *GoogleCloudDialogflowV2SessionEntityType
29306	urlParams_                               gensupport.URLParams
29307	ctx_                                     context.Context
29308	header_                                  http.Header
29309}
29310
29311// Patch: Updates the specified session entity type. This method doesn't
29312// work with Google Assistant integration. Contact Dialogflow support if
29313// you need to use session entities with Google Assistant integration.
29314//
29315// - name: The unique identifier of this session entity type. Format:
29316//   `projects//agent/sessions//entityTypes/`, or
29317//   `projects//agent/environments//users//sessions//entityTypes/`. If
29318//   `Environment ID` is not specified, we assume default 'draft'
29319//   environment. If `User ID` is not specified, we assume default '-'
29320//   user. `` must be the display name of an existing entity type in the
29321//   same agent that will be overridden or supplemented.
29322func (r *ProjectsAgentSessionsEntityTypesService) Patch(nameid string, googleclouddialogflowv2sessionentitytype *GoogleCloudDialogflowV2SessionEntityType) *ProjectsAgentSessionsEntityTypesPatchCall {
29323	c := &ProjectsAgentSessionsEntityTypesPatchCall{s: r.s, urlParams_: make(gensupport.URLParams)}
29324	c.nameid = nameid
29325	c.googleclouddialogflowv2sessionentitytype = googleclouddialogflowv2sessionentitytype
29326	return c
29327}
29328
29329// UpdateMask sets the optional parameter "updateMask": The mask to
29330// control which fields get updated.
29331func (c *ProjectsAgentSessionsEntityTypesPatchCall) UpdateMask(updateMask string) *ProjectsAgentSessionsEntityTypesPatchCall {
29332	c.urlParams_.Set("updateMask", updateMask)
29333	return c
29334}
29335
29336// Fields allows partial responses to be retrieved. See
29337// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
29338// for more information.
29339func (c *ProjectsAgentSessionsEntityTypesPatchCall) Fields(s ...googleapi.Field) *ProjectsAgentSessionsEntityTypesPatchCall {
29340	c.urlParams_.Set("fields", googleapi.CombineFields(s))
29341	return c
29342}
29343
29344// Context sets the context to be used in this call's Do method. Any
29345// pending HTTP request will be aborted if the provided context is
29346// canceled.
29347func (c *ProjectsAgentSessionsEntityTypesPatchCall) Context(ctx context.Context) *ProjectsAgentSessionsEntityTypesPatchCall {
29348	c.ctx_ = ctx
29349	return c
29350}
29351
29352// Header returns an http.Header that can be modified by the caller to
29353// add HTTP headers to the request.
29354func (c *ProjectsAgentSessionsEntityTypesPatchCall) Header() http.Header {
29355	if c.header_ == nil {
29356		c.header_ = make(http.Header)
29357	}
29358	return c.header_
29359}
29360
29361func (c *ProjectsAgentSessionsEntityTypesPatchCall) doRequest(alt string) (*http.Response, error) {
29362	reqHeaders := make(http.Header)
29363	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20211027")
29364	for k, v := range c.header_ {
29365		reqHeaders[k] = v
29366	}
29367	reqHeaders.Set("User-Agent", c.s.userAgent())
29368	var body io.Reader = nil
29369	body, err := googleapi.WithoutDataWrapper.JSONReader(c.googleclouddialogflowv2sessionentitytype)
29370	if err != nil {
29371		return nil, err
29372	}
29373	reqHeaders.Set("Content-Type", "application/json")
29374	c.urlParams_.Set("alt", alt)
29375	c.urlParams_.Set("prettyPrint", "false")
29376	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+name}")
29377	urls += "?" + c.urlParams_.Encode()
29378	req, err := http.NewRequest("PATCH", urls, body)
29379	if err != nil {
29380		return nil, err
29381	}
29382	req.Header = reqHeaders
29383	googleapi.Expand(req.URL, map[string]string{
29384		"name": c.nameid,
29385	})
29386	return gensupport.SendRequest(c.ctx_, c.s.client, req)
29387}
29388
29389// Do executes the "dialogflow.projects.agent.sessions.entityTypes.patch" call.
29390// Exactly one of *GoogleCloudDialogflowV2SessionEntityType or error
29391// will be non-nil. Any non-2xx status code is an error. Response
29392// headers are in either
29393// *GoogleCloudDialogflowV2SessionEntityType.ServerResponse.Header or
29394// (if a response was returned at all) in
29395// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
29396// whether the returned error was because http.StatusNotModified was
29397// returned.
29398func (c *ProjectsAgentSessionsEntityTypesPatchCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDialogflowV2SessionEntityType, error) {
29399	gensupport.SetOptions(c.urlParams_, opts...)
29400	res, err := c.doRequest("json")
29401	if res != nil && res.StatusCode == http.StatusNotModified {
29402		if res.Body != nil {
29403			res.Body.Close()
29404		}
29405		return nil, &googleapi.Error{
29406			Code:   res.StatusCode,
29407			Header: res.Header,
29408		}
29409	}
29410	if err != nil {
29411		return nil, err
29412	}
29413	defer googleapi.CloseBody(res)
29414	if err := googleapi.CheckResponse(res); err != nil {
29415		return nil, err
29416	}
29417	ret := &GoogleCloudDialogflowV2SessionEntityType{
29418		ServerResponse: googleapi.ServerResponse{
29419			Header:         res.Header,
29420			HTTPStatusCode: res.StatusCode,
29421		},
29422	}
29423	target := &ret
29424	if err := gensupport.DecodeResponse(target, res); err != nil {
29425		return nil, err
29426	}
29427	return ret, nil
29428	// {
29429	//   "description": "Updates the specified session entity type. This method doesn't work with Google Assistant integration. Contact Dialogflow support if you need to use session entities with Google Assistant integration.",
29430	//   "flatPath": "v2/projects/{projectsId}/agent/sessions/{sessionsId}/entityTypes/{entityTypesId}",
29431	//   "httpMethod": "PATCH",
29432	//   "id": "dialogflow.projects.agent.sessions.entityTypes.patch",
29433	//   "parameterOrder": [
29434	//     "name"
29435	//   ],
29436	//   "parameters": {
29437	//     "name": {
29438	//       "description": "Required. The unique identifier of this session entity type. Format: `projects//agent/sessions//entityTypes/`, or `projects//agent/environments//users//sessions//entityTypes/`. If `Environment ID` is not specified, we assume default 'draft' environment. If `User ID` is not specified, we assume default '-' user. `` must be the display name of an existing entity type in the same agent that will be overridden or supplemented.",
29439	//       "location": "path",
29440	//       "pattern": "^projects/[^/]+/agent/sessions/[^/]+/entityTypes/[^/]+$",
29441	//       "required": true,
29442	//       "type": "string"
29443	//     },
29444	//     "updateMask": {
29445	//       "description": "Optional. The mask to control which fields get updated.",
29446	//       "format": "google-fieldmask",
29447	//       "location": "query",
29448	//       "type": "string"
29449	//     }
29450	//   },
29451	//   "path": "v2/{+name}",
29452	//   "request": {
29453	//     "$ref": "GoogleCloudDialogflowV2SessionEntityType"
29454	//   },
29455	//   "response": {
29456	//     "$ref": "GoogleCloudDialogflowV2SessionEntityType"
29457	//   },
29458	//   "scopes": [
29459	//     "https://www.googleapis.com/auth/cloud-platform",
29460	//     "https://www.googleapis.com/auth/dialogflow"
29461	//   ]
29462	// }
29463
29464}
29465
29466// method id "dialogflow.projects.agent.versions.create":
29467
29468type ProjectsAgentVersionsCreateCall struct {
29469	s                              *Service
29470	parent                         string
29471	googleclouddialogflowv2version *GoogleCloudDialogflowV2Version
29472	urlParams_                     gensupport.URLParams
29473	ctx_                           context.Context
29474	header_                        http.Header
29475}
29476
29477// Create: Creates an agent version. The new version points to the agent
29478// instance in the "default" environment.
29479//
29480// - parent: The agent to create a version for. Supported formats: -
29481//   `projects//agent` - `projects//locations//agent`.
29482func (r *ProjectsAgentVersionsService) Create(parent string, googleclouddialogflowv2version *GoogleCloudDialogflowV2Version) *ProjectsAgentVersionsCreateCall {
29483	c := &ProjectsAgentVersionsCreateCall{s: r.s, urlParams_: make(gensupport.URLParams)}
29484	c.parent = parent
29485	c.googleclouddialogflowv2version = googleclouddialogflowv2version
29486	return c
29487}
29488
29489// Fields allows partial responses to be retrieved. See
29490// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
29491// for more information.
29492func (c *ProjectsAgentVersionsCreateCall) Fields(s ...googleapi.Field) *ProjectsAgentVersionsCreateCall {
29493	c.urlParams_.Set("fields", googleapi.CombineFields(s))
29494	return c
29495}
29496
29497// Context sets the context to be used in this call's Do method. Any
29498// pending HTTP request will be aborted if the provided context is
29499// canceled.
29500func (c *ProjectsAgentVersionsCreateCall) Context(ctx context.Context) *ProjectsAgentVersionsCreateCall {
29501	c.ctx_ = ctx
29502	return c
29503}
29504
29505// Header returns an http.Header that can be modified by the caller to
29506// add HTTP headers to the request.
29507func (c *ProjectsAgentVersionsCreateCall) Header() http.Header {
29508	if c.header_ == nil {
29509		c.header_ = make(http.Header)
29510	}
29511	return c.header_
29512}
29513
29514func (c *ProjectsAgentVersionsCreateCall) doRequest(alt string) (*http.Response, error) {
29515	reqHeaders := make(http.Header)
29516	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20211027")
29517	for k, v := range c.header_ {
29518		reqHeaders[k] = v
29519	}
29520	reqHeaders.Set("User-Agent", c.s.userAgent())
29521	var body io.Reader = nil
29522	body, err := googleapi.WithoutDataWrapper.JSONReader(c.googleclouddialogflowv2version)
29523	if err != nil {
29524		return nil, err
29525	}
29526	reqHeaders.Set("Content-Type", "application/json")
29527	c.urlParams_.Set("alt", alt)
29528	c.urlParams_.Set("prettyPrint", "false")
29529	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+parent}/versions")
29530	urls += "?" + c.urlParams_.Encode()
29531	req, err := http.NewRequest("POST", urls, body)
29532	if err != nil {
29533		return nil, err
29534	}
29535	req.Header = reqHeaders
29536	googleapi.Expand(req.URL, map[string]string{
29537		"parent": c.parent,
29538	})
29539	return gensupport.SendRequest(c.ctx_, c.s.client, req)
29540}
29541
29542// Do executes the "dialogflow.projects.agent.versions.create" call.
29543// Exactly one of *GoogleCloudDialogflowV2Version or error will be
29544// non-nil. Any non-2xx status code is an error. Response headers are in
29545// either *GoogleCloudDialogflowV2Version.ServerResponse.Header or (if a
29546// response was returned at all) in error.(*googleapi.Error).Header. Use
29547// googleapi.IsNotModified to check whether the returned error was
29548// because http.StatusNotModified was returned.
29549func (c *ProjectsAgentVersionsCreateCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDialogflowV2Version, error) {
29550	gensupport.SetOptions(c.urlParams_, opts...)
29551	res, err := c.doRequest("json")
29552	if res != nil && res.StatusCode == http.StatusNotModified {
29553		if res.Body != nil {
29554			res.Body.Close()
29555		}
29556		return nil, &googleapi.Error{
29557			Code:   res.StatusCode,
29558			Header: res.Header,
29559		}
29560	}
29561	if err != nil {
29562		return nil, err
29563	}
29564	defer googleapi.CloseBody(res)
29565	if err := googleapi.CheckResponse(res); err != nil {
29566		return nil, err
29567	}
29568	ret := &GoogleCloudDialogflowV2Version{
29569		ServerResponse: googleapi.ServerResponse{
29570			Header:         res.Header,
29571			HTTPStatusCode: res.StatusCode,
29572		},
29573	}
29574	target := &ret
29575	if err := gensupport.DecodeResponse(target, res); err != nil {
29576		return nil, err
29577	}
29578	return ret, nil
29579	// {
29580	//   "description": "Creates an agent version. The new version points to the agent instance in the \"default\" environment.",
29581	//   "flatPath": "v2/projects/{projectsId}/agent/versions",
29582	//   "httpMethod": "POST",
29583	//   "id": "dialogflow.projects.agent.versions.create",
29584	//   "parameterOrder": [
29585	//     "parent"
29586	//   ],
29587	//   "parameters": {
29588	//     "parent": {
29589	//       "description": "Required. The agent to create a version for. Supported formats: - `projects//agent` - `projects//locations//agent`",
29590	//       "location": "path",
29591	//       "pattern": "^projects/[^/]+/agent$",
29592	//       "required": true,
29593	//       "type": "string"
29594	//     }
29595	//   },
29596	//   "path": "v2/{+parent}/versions",
29597	//   "request": {
29598	//     "$ref": "GoogleCloudDialogflowV2Version"
29599	//   },
29600	//   "response": {
29601	//     "$ref": "GoogleCloudDialogflowV2Version"
29602	//   },
29603	//   "scopes": [
29604	//     "https://www.googleapis.com/auth/cloud-platform",
29605	//     "https://www.googleapis.com/auth/dialogflow"
29606	//   ]
29607	// }
29608
29609}
29610
29611// method id "dialogflow.projects.agent.versions.delete":
29612
29613type ProjectsAgentVersionsDeleteCall struct {
29614	s          *Service
29615	name       string
29616	urlParams_ gensupport.URLParams
29617	ctx_       context.Context
29618	header_    http.Header
29619}
29620
29621// Delete: Delete the specified agent version.
29622//
29623// - name: The name of the version to delete. Supported formats: -
29624//   `projects//agent/versions/` -
29625//   `projects//locations//agent/versions/`.
29626func (r *ProjectsAgentVersionsService) Delete(name string) *ProjectsAgentVersionsDeleteCall {
29627	c := &ProjectsAgentVersionsDeleteCall{s: r.s, urlParams_: make(gensupport.URLParams)}
29628	c.name = name
29629	return c
29630}
29631
29632// Fields allows partial responses to be retrieved. See
29633// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
29634// for more information.
29635func (c *ProjectsAgentVersionsDeleteCall) Fields(s ...googleapi.Field) *ProjectsAgentVersionsDeleteCall {
29636	c.urlParams_.Set("fields", googleapi.CombineFields(s))
29637	return c
29638}
29639
29640// Context sets the context to be used in this call's Do method. Any
29641// pending HTTP request will be aborted if the provided context is
29642// canceled.
29643func (c *ProjectsAgentVersionsDeleteCall) Context(ctx context.Context) *ProjectsAgentVersionsDeleteCall {
29644	c.ctx_ = ctx
29645	return c
29646}
29647
29648// Header returns an http.Header that can be modified by the caller to
29649// add HTTP headers to the request.
29650func (c *ProjectsAgentVersionsDeleteCall) Header() http.Header {
29651	if c.header_ == nil {
29652		c.header_ = make(http.Header)
29653	}
29654	return c.header_
29655}
29656
29657func (c *ProjectsAgentVersionsDeleteCall) doRequest(alt string) (*http.Response, error) {
29658	reqHeaders := make(http.Header)
29659	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20211027")
29660	for k, v := range c.header_ {
29661		reqHeaders[k] = v
29662	}
29663	reqHeaders.Set("User-Agent", c.s.userAgent())
29664	var body io.Reader = nil
29665	c.urlParams_.Set("alt", alt)
29666	c.urlParams_.Set("prettyPrint", "false")
29667	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+name}")
29668	urls += "?" + c.urlParams_.Encode()
29669	req, err := http.NewRequest("DELETE", urls, body)
29670	if err != nil {
29671		return nil, err
29672	}
29673	req.Header = reqHeaders
29674	googleapi.Expand(req.URL, map[string]string{
29675		"name": c.name,
29676	})
29677	return gensupport.SendRequest(c.ctx_, c.s.client, req)
29678}
29679
29680// Do executes the "dialogflow.projects.agent.versions.delete" call.
29681// Exactly one of *GoogleProtobufEmpty or error will be non-nil. Any
29682// non-2xx status code is an error. Response headers are in either
29683// *GoogleProtobufEmpty.ServerResponse.Header or (if a response was
29684// returned at all) in error.(*googleapi.Error).Header. Use
29685// googleapi.IsNotModified to check whether the returned error was
29686// because http.StatusNotModified was returned.
29687func (c *ProjectsAgentVersionsDeleteCall) Do(opts ...googleapi.CallOption) (*GoogleProtobufEmpty, error) {
29688	gensupport.SetOptions(c.urlParams_, opts...)
29689	res, err := c.doRequest("json")
29690	if res != nil && res.StatusCode == http.StatusNotModified {
29691		if res.Body != nil {
29692			res.Body.Close()
29693		}
29694		return nil, &googleapi.Error{
29695			Code:   res.StatusCode,
29696			Header: res.Header,
29697		}
29698	}
29699	if err != nil {
29700		return nil, err
29701	}
29702	defer googleapi.CloseBody(res)
29703	if err := googleapi.CheckResponse(res); err != nil {
29704		return nil, err
29705	}
29706	ret := &GoogleProtobufEmpty{
29707		ServerResponse: googleapi.ServerResponse{
29708			Header:         res.Header,
29709			HTTPStatusCode: res.StatusCode,
29710		},
29711	}
29712	target := &ret
29713	if err := gensupport.DecodeResponse(target, res); err != nil {
29714		return nil, err
29715	}
29716	return ret, nil
29717	// {
29718	//   "description": "Delete the specified agent version.",
29719	//   "flatPath": "v2/projects/{projectsId}/agent/versions/{versionsId}",
29720	//   "httpMethod": "DELETE",
29721	//   "id": "dialogflow.projects.agent.versions.delete",
29722	//   "parameterOrder": [
29723	//     "name"
29724	//   ],
29725	//   "parameters": {
29726	//     "name": {
29727	//       "description": "Required. The name of the version to delete. Supported formats: - `projects//agent/versions/` - `projects//locations//agent/versions/`",
29728	//       "location": "path",
29729	//       "pattern": "^projects/[^/]+/agent/versions/[^/]+$",
29730	//       "required": true,
29731	//       "type": "string"
29732	//     }
29733	//   },
29734	//   "path": "v2/{+name}",
29735	//   "response": {
29736	//     "$ref": "GoogleProtobufEmpty"
29737	//   },
29738	//   "scopes": [
29739	//     "https://www.googleapis.com/auth/cloud-platform",
29740	//     "https://www.googleapis.com/auth/dialogflow"
29741	//   ]
29742	// }
29743
29744}
29745
29746// method id "dialogflow.projects.agent.versions.get":
29747
29748type ProjectsAgentVersionsGetCall struct {
29749	s            *Service
29750	name         string
29751	urlParams_   gensupport.URLParams
29752	ifNoneMatch_ string
29753	ctx_         context.Context
29754	header_      http.Header
29755}
29756
29757// Get: Retrieves the specified agent version.
29758//
29759// - name: The name of the version. Supported formats: -
29760//   `projects//agent/versions/` -
29761//   `projects//locations//agent/versions/`.
29762func (r *ProjectsAgentVersionsService) Get(name string) *ProjectsAgentVersionsGetCall {
29763	c := &ProjectsAgentVersionsGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
29764	c.name = name
29765	return c
29766}
29767
29768// Fields allows partial responses to be retrieved. See
29769// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
29770// for more information.
29771func (c *ProjectsAgentVersionsGetCall) Fields(s ...googleapi.Field) *ProjectsAgentVersionsGetCall {
29772	c.urlParams_.Set("fields", googleapi.CombineFields(s))
29773	return c
29774}
29775
29776// IfNoneMatch sets the optional parameter which makes the operation
29777// fail if the object's ETag matches the given value. This is useful for
29778// getting updates only after the object has changed since the last
29779// request. Use googleapi.IsNotModified to check whether the response
29780// error from Do is the result of In-None-Match.
29781func (c *ProjectsAgentVersionsGetCall) IfNoneMatch(entityTag string) *ProjectsAgentVersionsGetCall {
29782	c.ifNoneMatch_ = entityTag
29783	return c
29784}
29785
29786// Context sets the context to be used in this call's Do method. Any
29787// pending HTTP request will be aborted if the provided context is
29788// canceled.
29789func (c *ProjectsAgentVersionsGetCall) Context(ctx context.Context) *ProjectsAgentVersionsGetCall {
29790	c.ctx_ = ctx
29791	return c
29792}
29793
29794// Header returns an http.Header that can be modified by the caller to
29795// add HTTP headers to the request.
29796func (c *ProjectsAgentVersionsGetCall) Header() http.Header {
29797	if c.header_ == nil {
29798		c.header_ = make(http.Header)
29799	}
29800	return c.header_
29801}
29802
29803func (c *ProjectsAgentVersionsGetCall) doRequest(alt string) (*http.Response, error) {
29804	reqHeaders := make(http.Header)
29805	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20211027")
29806	for k, v := range c.header_ {
29807		reqHeaders[k] = v
29808	}
29809	reqHeaders.Set("User-Agent", c.s.userAgent())
29810	if c.ifNoneMatch_ != "" {
29811		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
29812	}
29813	var body io.Reader = nil
29814	c.urlParams_.Set("alt", alt)
29815	c.urlParams_.Set("prettyPrint", "false")
29816	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+name}")
29817	urls += "?" + c.urlParams_.Encode()
29818	req, err := http.NewRequest("GET", urls, body)
29819	if err != nil {
29820		return nil, err
29821	}
29822	req.Header = reqHeaders
29823	googleapi.Expand(req.URL, map[string]string{
29824		"name": c.name,
29825	})
29826	return gensupport.SendRequest(c.ctx_, c.s.client, req)
29827}
29828
29829// Do executes the "dialogflow.projects.agent.versions.get" call.
29830// Exactly one of *GoogleCloudDialogflowV2Version or error will be
29831// non-nil. Any non-2xx status code is an error. Response headers are in
29832// either *GoogleCloudDialogflowV2Version.ServerResponse.Header or (if a
29833// response was returned at all) in error.(*googleapi.Error).Header. Use
29834// googleapi.IsNotModified to check whether the returned error was
29835// because http.StatusNotModified was returned.
29836func (c *ProjectsAgentVersionsGetCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDialogflowV2Version, error) {
29837	gensupport.SetOptions(c.urlParams_, opts...)
29838	res, err := c.doRequest("json")
29839	if res != nil && res.StatusCode == http.StatusNotModified {
29840		if res.Body != nil {
29841			res.Body.Close()
29842		}
29843		return nil, &googleapi.Error{
29844			Code:   res.StatusCode,
29845			Header: res.Header,
29846		}
29847	}
29848	if err != nil {
29849		return nil, err
29850	}
29851	defer googleapi.CloseBody(res)
29852	if err := googleapi.CheckResponse(res); err != nil {
29853		return nil, err
29854	}
29855	ret := &GoogleCloudDialogflowV2Version{
29856		ServerResponse: googleapi.ServerResponse{
29857			Header:         res.Header,
29858			HTTPStatusCode: res.StatusCode,
29859		},
29860	}
29861	target := &ret
29862	if err := gensupport.DecodeResponse(target, res); err != nil {
29863		return nil, err
29864	}
29865	return ret, nil
29866	// {
29867	//   "description": "Retrieves the specified agent version.",
29868	//   "flatPath": "v2/projects/{projectsId}/agent/versions/{versionsId}",
29869	//   "httpMethod": "GET",
29870	//   "id": "dialogflow.projects.agent.versions.get",
29871	//   "parameterOrder": [
29872	//     "name"
29873	//   ],
29874	//   "parameters": {
29875	//     "name": {
29876	//       "description": "Required. The name of the version. Supported formats: - `projects//agent/versions/` - `projects//locations//agent/versions/`",
29877	//       "location": "path",
29878	//       "pattern": "^projects/[^/]+/agent/versions/[^/]+$",
29879	//       "required": true,
29880	//       "type": "string"
29881	//     }
29882	//   },
29883	//   "path": "v2/{+name}",
29884	//   "response": {
29885	//     "$ref": "GoogleCloudDialogflowV2Version"
29886	//   },
29887	//   "scopes": [
29888	//     "https://www.googleapis.com/auth/cloud-platform",
29889	//     "https://www.googleapis.com/auth/dialogflow"
29890	//   ]
29891	// }
29892
29893}
29894
29895// method id "dialogflow.projects.agent.versions.list":
29896
29897type ProjectsAgentVersionsListCall struct {
29898	s            *Service
29899	parent       string
29900	urlParams_   gensupport.URLParams
29901	ifNoneMatch_ string
29902	ctx_         context.Context
29903	header_      http.Header
29904}
29905
29906// List: Returns the list of all versions of the specified agent.
29907//
29908// - parent: The agent to list all versions from. Supported formats: -
29909//   `projects//agent` - `projects//locations//agent`.
29910func (r *ProjectsAgentVersionsService) List(parent string) *ProjectsAgentVersionsListCall {
29911	c := &ProjectsAgentVersionsListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
29912	c.parent = parent
29913	return c
29914}
29915
29916// PageSize sets the optional parameter "pageSize": The maximum number
29917// of items to return in a single page. By default 100 and at most 1000.
29918func (c *ProjectsAgentVersionsListCall) PageSize(pageSize int64) *ProjectsAgentVersionsListCall {
29919	c.urlParams_.Set("pageSize", fmt.Sprint(pageSize))
29920	return c
29921}
29922
29923// PageToken sets the optional parameter "pageToken": The
29924// next_page_token value returned from a previous list request.
29925func (c *ProjectsAgentVersionsListCall) PageToken(pageToken string) *ProjectsAgentVersionsListCall {
29926	c.urlParams_.Set("pageToken", pageToken)
29927	return c
29928}
29929
29930// Fields allows partial responses to be retrieved. See
29931// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
29932// for more information.
29933func (c *ProjectsAgentVersionsListCall) Fields(s ...googleapi.Field) *ProjectsAgentVersionsListCall {
29934	c.urlParams_.Set("fields", googleapi.CombineFields(s))
29935	return c
29936}
29937
29938// IfNoneMatch sets the optional parameter which makes the operation
29939// fail if the object's ETag matches the given value. This is useful for
29940// getting updates only after the object has changed since the last
29941// request. Use googleapi.IsNotModified to check whether the response
29942// error from Do is the result of In-None-Match.
29943func (c *ProjectsAgentVersionsListCall) IfNoneMatch(entityTag string) *ProjectsAgentVersionsListCall {
29944	c.ifNoneMatch_ = entityTag
29945	return c
29946}
29947
29948// Context sets the context to be used in this call's Do method. Any
29949// pending HTTP request will be aborted if the provided context is
29950// canceled.
29951func (c *ProjectsAgentVersionsListCall) Context(ctx context.Context) *ProjectsAgentVersionsListCall {
29952	c.ctx_ = ctx
29953	return c
29954}
29955
29956// Header returns an http.Header that can be modified by the caller to
29957// add HTTP headers to the request.
29958func (c *ProjectsAgentVersionsListCall) Header() http.Header {
29959	if c.header_ == nil {
29960		c.header_ = make(http.Header)
29961	}
29962	return c.header_
29963}
29964
29965func (c *ProjectsAgentVersionsListCall) doRequest(alt string) (*http.Response, error) {
29966	reqHeaders := make(http.Header)
29967	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20211027")
29968	for k, v := range c.header_ {
29969		reqHeaders[k] = v
29970	}
29971	reqHeaders.Set("User-Agent", c.s.userAgent())
29972	if c.ifNoneMatch_ != "" {
29973		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
29974	}
29975	var body io.Reader = nil
29976	c.urlParams_.Set("alt", alt)
29977	c.urlParams_.Set("prettyPrint", "false")
29978	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+parent}/versions")
29979	urls += "?" + c.urlParams_.Encode()
29980	req, err := http.NewRequest("GET", urls, body)
29981	if err != nil {
29982		return nil, err
29983	}
29984	req.Header = reqHeaders
29985	googleapi.Expand(req.URL, map[string]string{
29986		"parent": c.parent,
29987	})
29988	return gensupport.SendRequest(c.ctx_, c.s.client, req)
29989}
29990
29991// Do executes the "dialogflow.projects.agent.versions.list" call.
29992// Exactly one of *GoogleCloudDialogflowV2ListVersionsResponse or error
29993// will be non-nil. Any non-2xx status code is an error. Response
29994// headers are in either
29995// *GoogleCloudDialogflowV2ListVersionsResponse.ServerResponse.Header or
29996// (if a response was returned at all) in
29997// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
29998// whether the returned error was because http.StatusNotModified was
29999// returned.
30000func (c *ProjectsAgentVersionsListCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDialogflowV2ListVersionsResponse, error) {
30001	gensupport.SetOptions(c.urlParams_, opts...)
30002	res, err := c.doRequest("json")
30003	if res != nil && res.StatusCode == http.StatusNotModified {
30004		if res.Body != nil {
30005			res.Body.Close()
30006		}
30007		return nil, &googleapi.Error{
30008			Code:   res.StatusCode,
30009			Header: res.Header,
30010		}
30011	}
30012	if err != nil {
30013		return nil, err
30014	}
30015	defer googleapi.CloseBody(res)
30016	if err := googleapi.CheckResponse(res); err != nil {
30017		return nil, err
30018	}
30019	ret := &GoogleCloudDialogflowV2ListVersionsResponse{
30020		ServerResponse: googleapi.ServerResponse{
30021			Header:         res.Header,
30022			HTTPStatusCode: res.StatusCode,
30023		},
30024	}
30025	target := &ret
30026	if err := gensupport.DecodeResponse(target, res); err != nil {
30027		return nil, err
30028	}
30029	return ret, nil
30030	// {
30031	//   "description": "Returns the list of all versions of the specified agent.",
30032	//   "flatPath": "v2/projects/{projectsId}/agent/versions",
30033	//   "httpMethod": "GET",
30034	//   "id": "dialogflow.projects.agent.versions.list",
30035	//   "parameterOrder": [
30036	//     "parent"
30037	//   ],
30038	//   "parameters": {
30039	//     "pageSize": {
30040	//       "description": "Optional. The maximum number of items to return in a single page. By default 100 and at most 1000.",
30041	//       "format": "int32",
30042	//       "location": "query",
30043	//       "type": "integer"
30044	//     },
30045	//     "pageToken": {
30046	//       "description": "Optional. The next_page_token value returned from a previous list request.",
30047	//       "location": "query",
30048	//       "type": "string"
30049	//     },
30050	//     "parent": {
30051	//       "description": "Required. The agent to list all versions from. Supported formats: - `projects//agent` - `projects//locations//agent`",
30052	//       "location": "path",
30053	//       "pattern": "^projects/[^/]+/agent$",
30054	//       "required": true,
30055	//       "type": "string"
30056	//     }
30057	//   },
30058	//   "path": "v2/{+parent}/versions",
30059	//   "response": {
30060	//     "$ref": "GoogleCloudDialogflowV2ListVersionsResponse"
30061	//   },
30062	//   "scopes": [
30063	//     "https://www.googleapis.com/auth/cloud-platform",
30064	//     "https://www.googleapis.com/auth/dialogflow"
30065	//   ]
30066	// }
30067
30068}
30069
30070// Pages invokes f for each page of results.
30071// A non-nil error returned from f will halt the iteration.
30072// The provided context supersedes any context provided to the Context method.
30073func (c *ProjectsAgentVersionsListCall) Pages(ctx context.Context, f func(*GoogleCloudDialogflowV2ListVersionsResponse) error) error {
30074	c.ctx_ = ctx
30075	defer c.PageToken(c.urlParams_.Get("pageToken")) // reset paging to original point
30076	for {
30077		x, err := c.Do()
30078		if err != nil {
30079			return err
30080		}
30081		if err := f(x); err != nil {
30082			return err
30083		}
30084		if x.NextPageToken == "" {
30085			return nil
30086		}
30087		c.PageToken(x.NextPageToken)
30088	}
30089}
30090
30091// method id "dialogflow.projects.agent.versions.patch":
30092
30093type ProjectsAgentVersionsPatchCall struct {
30094	s                              *Service
30095	nameid                         string
30096	googleclouddialogflowv2version *GoogleCloudDialogflowV2Version
30097	urlParams_                     gensupport.URLParams
30098	ctx_                           context.Context
30099	header_                        http.Header
30100}
30101
30102// Patch: Updates the specified agent version. Note that this method
30103// does not allow you to update the state of the agent the given version
30104// points to. It allows you to update only mutable properties of the
30105// version resource.
30106//
30107// - name: Output only. The unique identifier of this agent version.
30108//   Supported formats: - `projects//agent/versions/` -
30109//   `projects//locations//agent/versions/`.
30110func (r *ProjectsAgentVersionsService) Patch(nameid string, googleclouddialogflowv2version *GoogleCloudDialogflowV2Version) *ProjectsAgentVersionsPatchCall {
30111	c := &ProjectsAgentVersionsPatchCall{s: r.s, urlParams_: make(gensupport.URLParams)}
30112	c.nameid = nameid
30113	c.googleclouddialogflowv2version = googleclouddialogflowv2version
30114	return c
30115}
30116
30117// UpdateMask sets the optional parameter "updateMask": Required. The
30118// mask to control which fields get updated.
30119func (c *ProjectsAgentVersionsPatchCall) UpdateMask(updateMask string) *ProjectsAgentVersionsPatchCall {
30120	c.urlParams_.Set("updateMask", updateMask)
30121	return c
30122}
30123
30124// Fields allows partial responses to be retrieved. See
30125// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
30126// for more information.
30127func (c *ProjectsAgentVersionsPatchCall) Fields(s ...googleapi.Field) *ProjectsAgentVersionsPatchCall {
30128	c.urlParams_.Set("fields", googleapi.CombineFields(s))
30129	return c
30130}
30131
30132// Context sets the context to be used in this call's Do method. Any
30133// pending HTTP request will be aborted if the provided context is
30134// canceled.
30135func (c *ProjectsAgentVersionsPatchCall) Context(ctx context.Context) *ProjectsAgentVersionsPatchCall {
30136	c.ctx_ = ctx
30137	return c
30138}
30139
30140// Header returns an http.Header that can be modified by the caller to
30141// add HTTP headers to the request.
30142func (c *ProjectsAgentVersionsPatchCall) Header() http.Header {
30143	if c.header_ == nil {
30144		c.header_ = make(http.Header)
30145	}
30146	return c.header_
30147}
30148
30149func (c *ProjectsAgentVersionsPatchCall) doRequest(alt string) (*http.Response, error) {
30150	reqHeaders := make(http.Header)
30151	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20211027")
30152	for k, v := range c.header_ {
30153		reqHeaders[k] = v
30154	}
30155	reqHeaders.Set("User-Agent", c.s.userAgent())
30156	var body io.Reader = nil
30157	body, err := googleapi.WithoutDataWrapper.JSONReader(c.googleclouddialogflowv2version)
30158	if err != nil {
30159		return nil, err
30160	}
30161	reqHeaders.Set("Content-Type", "application/json")
30162	c.urlParams_.Set("alt", alt)
30163	c.urlParams_.Set("prettyPrint", "false")
30164	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+name}")
30165	urls += "?" + c.urlParams_.Encode()
30166	req, err := http.NewRequest("PATCH", urls, body)
30167	if err != nil {
30168		return nil, err
30169	}
30170	req.Header = reqHeaders
30171	googleapi.Expand(req.URL, map[string]string{
30172		"name": c.nameid,
30173	})
30174	return gensupport.SendRequest(c.ctx_, c.s.client, req)
30175}
30176
30177// Do executes the "dialogflow.projects.agent.versions.patch" call.
30178// Exactly one of *GoogleCloudDialogflowV2Version or error will be
30179// non-nil. Any non-2xx status code is an error. Response headers are in
30180// either *GoogleCloudDialogflowV2Version.ServerResponse.Header or (if a
30181// response was returned at all) in error.(*googleapi.Error).Header. Use
30182// googleapi.IsNotModified to check whether the returned error was
30183// because http.StatusNotModified was returned.
30184func (c *ProjectsAgentVersionsPatchCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDialogflowV2Version, error) {
30185	gensupport.SetOptions(c.urlParams_, opts...)
30186	res, err := c.doRequest("json")
30187	if res != nil && res.StatusCode == http.StatusNotModified {
30188		if res.Body != nil {
30189			res.Body.Close()
30190		}
30191		return nil, &googleapi.Error{
30192			Code:   res.StatusCode,
30193			Header: res.Header,
30194		}
30195	}
30196	if err != nil {
30197		return nil, err
30198	}
30199	defer googleapi.CloseBody(res)
30200	if err := googleapi.CheckResponse(res); err != nil {
30201		return nil, err
30202	}
30203	ret := &GoogleCloudDialogflowV2Version{
30204		ServerResponse: googleapi.ServerResponse{
30205			Header:         res.Header,
30206			HTTPStatusCode: res.StatusCode,
30207		},
30208	}
30209	target := &ret
30210	if err := gensupport.DecodeResponse(target, res); err != nil {
30211		return nil, err
30212	}
30213	return ret, nil
30214	// {
30215	//   "description": "Updates the specified agent version. Note that this method does not allow you to update the state of the agent the given version points to. It allows you to update only mutable properties of the version resource.",
30216	//   "flatPath": "v2/projects/{projectsId}/agent/versions/{versionsId}",
30217	//   "httpMethod": "PATCH",
30218	//   "id": "dialogflow.projects.agent.versions.patch",
30219	//   "parameterOrder": [
30220	//     "name"
30221	//   ],
30222	//   "parameters": {
30223	//     "name": {
30224	//       "description": "Output only. The unique identifier of this agent version. Supported formats: - `projects//agent/versions/` - `projects//locations//agent/versions/`",
30225	//       "location": "path",
30226	//       "pattern": "^projects/[^/]+/agent/versions/[^/]+$",
30227	//       "required": true,
30228	//       "type": "string"
30229	//     },
30230	//     "updateMask": {
30231	//       "description": "Required. The mask to control which fields get updated.",
30232	//       "format": "google-fieldmask",
30233	//       "location": "query",
30234	//       "type": "string"
30235	//     }
30236	//   },
30237	//   "path": "v2/{+name}",
30238	//   "request": {
30239	//     "$ref": "GoogleCloudDialogflowV2Version"
30240	//   },
30241	//   "response": {
30242	//     "$ref": "GoogleCloudDialogflowV2Version"
30243	//   },
30244	//   "scopes": [
30245	//     "https://www.googleapis.com/auth/cloud-platform",
30246	//     "https://www.googleapis.com/auth/dialogflow"
30247	//   ]
30248	// }
30249
30250}
30251
30252// method id "dialogflow.projects.answerRecords.list":
30253
30254type ProjectsAnswerRecordsListCall struct {
30255	s            *Service
30256	parent       string
30257	urlParams_   gensupport.URLParams
30258	ifNoneMatch_ string
30259	ctx_         context.Context
30260	header_      http.Header
30261}
30262
30263// List: Returns the list of all answer records in the specified project
30264// in reverse chronological order.
30265//
30266// - parent: The project to list all answer records for in reverse
30267//   chronological order. Format: `projects//locations/`.
30268func (r *ProjectsAnswerRecordsService) List(parent string) *ProjectsAnswerRecordsListCall {
30269	c := &ProjectsAnswerRecordsListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
30270	c.parent = parent
30271	return c
30272}
30273
30274// Filter sets the optional parameter "filter": Required. Filters to
30275// restrict results to specific answer records. Filter on answer record
30276// type. Currently predicates on `type` is supported, valid values are
30277// `ARTICLE_ANSWER`, `FAQ_ANSWER`. For more information about filtering,
30278// see API Filtering (https://aip.dev/160).
30279func (c *ProjectsAnswerRecordsListCall) Filter(filter string) *ProjectsAnswerRecordsListCall {
30280	c.urlParams_.Set("filter", filter)
30281	return c
30282}
30283
30284// PageSize sets the optional parameter "pageSize": The maximum number
30285// of records to return in a single page. The server may return fewer
30286// records than this. If unspecified, we use 10. The maximum is 100.
30287func (c *ProjectsAnswerRecordsListCall) PageSize(pageSize int64) *ProjectsAnswerRecordsListCall {
30288	c.urlParams_.Set("pageSize", fmt.Sprint(pageSize))
30289	return c
30290}
30291
30292// PageToken sets the optional parameter "pageToken": The
30293// ListAnswerRecordsResponse.next_page_token value returned from a
30294// previous list request used to continue listing on the next page.
30295func (c *ProjectsAnswerRecordsListCall) PageToken(pageToken string) *ProjectsAnswerRecordsListCall {
30296	c.urlParams_.Set("pageToken", pageToken)
30297	return c
30298}
30299
30300// Fields allows partial responses to be retrieved. See
30301// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
30302// for more information.
30303func (c *ProjectsAnswerRecordsListCall) Fields(s ...googleapi.Field) *ProjectsAnswerRecordsListCall {
30304	c.urlParams_.Set("fields", googleapi.CombineFields(s))
30305	return c
30306}
30307
30308// IfNoneMatch sets the optional parameter which makes the operation
30309// fail if the object's ETag matches the given value. This is useful for
30310// getting updates only after the object has changed since the last
30311// request. Use googleapi.IsNotModified to check whether the response
30312// error from Do is the result of In-None-Match.
30313func (c *ProjectsAnswerRecordsListCall) IfNoneMatch(entityTag string) *ProjectsAnswerRecordsListCall {
30314	c.ifNoneMatch_ = entityTag
30315	return c
30316}
30317
30318// Context sets the context to be used in this call's Do method. Any
30319// pending HTTP request will be aborted if the provided context is
30320// canceled.
30321func (c *ProjectsAnswerRecordsListCall) Context(ctx context.Context) *ProjectsAnswerRecordsListCall {
30322	c.ctx_ = ctx
30323	return c
30324}
30325
30326// Header returns an http.Header that can be modified by the caller to
30327// add HTTP headers to the request.
30328func (c *ProjectsAnswerRecordsListCall) Header() http.Header {
30329	if c.header_ == nil {
30330		c.header_ = make(http.Header)
30331	}
30332	return c.header_
30333}
30334
30335func (c *ProjectsAnswerRecordsListCall) doRequest(alt string) (*http.Response, error) {
30336	reqHeaders := make(http.Header)
30337	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20211027")
30338	for k, v := range c.header_ {
30339		reqHeaders[k] = v
30340	}
30341	reqHeaders.Set("User-Agent", c.s.userAgent())
30342	if c.ifNoneMatch_ != "" {
30343		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
30344	}
30345	var body io.Reader = nil
30346	c.urlParams_.Set("alt", alt)
30347	c.urlParams_.Set("prettyPrint", "false")
30348	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+parent}/answerRecords")
30349	urls += "?" + c.urlParams_.Encode()
30350	req, err := http.NewRequest("GET", urls, body)
30351	if err != nil {
30352		return nil, err
30353	}
30354	req.Header = reqHeaders
30355	googleapi.Expand(req.URL, map[string]string{
30356		"parent": c.parent,
30357	})
30358	return gensupport.SendRequest(c.ctx_, c.s.client, req)
30359}
30360
30361// Do executes the "dialogflow.projects.answerRecords.list" call.
30362// Exactly one of *GoogleCloudDialogflowV2ListAnswerRecordsResponse or
30363// error will be non-nil. Any non-2xx status code is an error. Response
30364// headers are in either
30365// *GoogleCloudDialogflowV2ListAnswerRecordsResponse.ServerResponse.Heade
30366// r or (if a response was returned at all) in
30367// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
30368// whether the returned error was because http.StatusNotModified was
30369// returned.
30370func (c *ProjectsAnswerRecordsListCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDialogflowV2ListAnswerRecordsResponse, error) {
30371	gensupport.SetOptions(c.urlParams_, opts...)
30372	res, err := c.doRequest("json")
30373	if res != nil && res.StatusCode == http.StatusNotModified {
30374		if res.Body != nil {
30375			res.Body.Close()
30376		}
30377		return nil, &googleapi.Error{
30378			Code:   res.StatusCode,
30379			Header: res.Header,
30380		}
30381	}
30382	if err != nil {
30383		return nil, err
30384	}
30385	defer googleapi.CloseBody(res)
30386	if err := googleapi.CheckResponse(res); err != nil {
30387		return nil, err
30388	}
30389	ret := &GoogleCloudDialogflowV2ListAnswerRecordsResponse{
30390		ServerResponse: googleapi.ServerResponse{
30391			Header:         res.Header,
30392			HTTPStatusCode: res.StatusCode,
30393		},
30394	}
30395	target := &ret
30396	if err := gensupport.DecodeResponse(target, res); err != nil {
30397		return nil, err
30398	}
30399	return ret, nil
30400	// {
30401	//   "description": "Returns the list of all answer records in the specified project in reverse chronological order.",
30402	//   "flatPath": "v2/projects/{projectsId}/answerRecords",
30403	//   "httpMethod": "GET",
30404	//   "id": "dialogflow.projects.answerRecords.list",
30405	//   "parameterOrder": [
30406	//     "parent"
30407	//   ],
30408	//   "parameters": {
30409	//     "filter": {
30410	//       "description": "Required. Filters to restrict results to specific answer records. Filter on answer record type. Currently predicates on `type` is supported, valid values are `ARTICLE_ANSWER`, `FAQ_ANSWER`. For more information about filtering, see [API Filtering](https://aip.dev/160).",
30411	//       "location": "query",
30412	//       "type": "string"
30413	//     },
30414	//     "pageSize": {
30415	//       "description": "Optional. The maximum number of records to return in a single page. The server may return fewer records than this. If unspecified, we use 10. The maximum is 100.",
30416	//       "format": "int32",
30417	//       "location": "query",
30418	//       "type": "integer"
30419	//     },
30420	//     "pageToken": {
30421	//       "description": "Optional. The ListAnswerRecordsResponse.next_page_token value returned from a previous list request used to continue listing on the next page.",
30422	//       "location": "query",
30423	//       "type": "string"
30424	//     },
30425	//     "parent": {
30426	//       "description": "Required. The project to list all answer records for in reverse chronological order. Format: `projects//locations/`.",
30427	//       "location": "path",
30428	//       "pattern": "^projects/[^/]+$",
30429	//       "required": true,
30430	//       "type": "string"
30431	//     }
30432	//   },
30433	//   "path": "v2/{+parent}/answerRecords",
30434	//   "response": {
30435	//     "$ref": "GoogleCloudDialogflowV2ListAnswerRecordsResponse"
30436	//   },
30437	//   "scopes": [
30438	//     "https://www.googleapis.com/auth/cloud-platform",
30439	//     "https://www.googleapis.com/auth/dialogflow"
30440	//   ]
30441	// }
30442
30443}
30444
30445// Pages invokes f for each page of results.
30446// A non-nil error returned from f will halt the iteration.
30447// The provided context supersedes any context provided to the Context method.
30448func (c *ProjectsAnswerRecordsListCall) Pages(ctx context.Context, f func(*GoogleCloudDialogflowV2ListAnswerRecordsResponse) error) error {
30449	c.ctx_ = ctx
30450	defer c.PageToken(c.urlParams_.Get("pageToken")) // reset paging to original point
30451	for {
30452		x, err := c.Do()
30453		if err != nil {
30454			return err
30455		}
30456		if err := f(x); err != nil {
30457			return err
30458		}
30459		if x.NextPageToken == "" {
30460			return nil
30461		}
30462		c.PageToken(x.NextPageToken)
30463	}
30464}
30465
30466// method id "dialogflow.projects.answerRecords.patch":
30467
30468type ProjectsAnswerRecordsPatchCall struct {
30469	s                                   *Service
30470	nameid                              string
30471	googleclouddialogflowv2answerrecord *GoogleCloudDialogflowV2AnswerRecord
30472	urlParams_                          gensupport.URLParams
30473	ctx_                                context.Context
30474	header_                             http.Header
30475}
30476
30477// Patch: Updates the specified answer record.
30478//
30479// - name: The unique identifier of this answer record. Format:
30480//   `projects//locations//answerRecords/`.
30481func (r *ProjectsAnswerRecordsService) Patch(nameid string, googleclouddialogflowv2answerrecord *GoogleCloudDialogflowV2AnswerRecord) *ProjectsAnswerRecordsPatchCall {
30482	c := &ProjectsAnswerRecordsPatchCall{s: r.s, urlParams_: make(gensupport.URLParams)}
30483	c.nameid = nameid
30484	c.googleclouddialogflowv2answerrecord = googleclouddialogflowv2answerrecord
30485	return c
30486}
30487
30488// UpdateMask sets the optional parameter "updateMask": Required. The
30489// mask to control which fields get updated.
30490func (c *ProjectsAnswerRecordsPatchCall) UpdateMask(updateMask string) *ProjectsAnswerRecordsPatchCall {
30491	c.urlParams_.Set("updateMask", updateMask)
30492	return c
30493}
30494
30495// Fields allows partial responses to be retrieved. See
30496// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
30497// for more information.
30498func (c *ProjectsAnswerRecordsPatchCall) Fields(s ...googleapi.Field) *ProjectsAnswerRecordsPatchCall {
30499	c.urlParams_.Set("fields", googleapi.CombineFields(s))
30500	return c
30501}
30502
30503// Context sets the context to be used in this call's Do method. Any
30504// pending HTTP request will be aborted if the provided context is
30505// canceled.
30506func (c *ProjectsAnswerRecordsPatchCall) Context(ctx context.Context) *ProjectsAnswerRecordsPatchCall {
30507	c.ctx_ = ctx
30508	return c
30509}
30510
30511// Header returns an http.Header that can be modified by the caller to
30512// add HTTP headers to the request.
30513func (c *ProjectsAnswerRecordsPatchCall) Header() http.Header {
30514	if c.header_ == nil {
30515		c.header_ = make(http.Header)
30516	}
30517	return c.header_
30518}
30519
30520func (c *ProjectsAnswerRecordsPatchCall) doRequest(alt string) (*http.Response, error) {
30521	reqHeaders := make(http.Header)
30522	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20211027")
30523	for k, v := range c.header_ {
30524		reqHeaders[k] = v
30525	}
30526	reqHeaders.Set("User-Agent", c.s.userAgent())
30527	var body io.Reader = nil
30528	body, err := googleapi.WithoutDataWrapper.JSONReader(c.googleclouddialogflowv2answerrecord)
30529	if err != nil {
30530		return nil, err
30531	}
30532	reqHeaders.Set("Content-Type", "application/json")
30533	c.urlParams_.Set("alt", alt)
30534	c.urlParams_.Set("prettyPrint", "false")
30535	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+name}")
30536	urls += "?" + c.urlParams_.Encode()
30537	req, err := http.NewRequest("PATCH", urls, body)
30538	if err != nil {
30539		return nil, err
30540	}
30541	req.Header = reqHeaders
30542	googleapi.Expand(req.URL, map[string]string{
30543		"name": c.nameid,
30544	})
30545	return gensupport.SendRequest(c.ctx_, c.s.client, req)
30546}
30547
30548// Do executes the "dialogflow.projects.answerRecords.patch" call.
30549// Exactly one of *GoogleCloudDialogflowV2AnswerRecord or error will be
30550// non-nil. Any non-2xx status code is an error. Response headers are in
30551// either *GoogleCloudDialogflowV2AnswerRecord.ServerResponse.Header or
30552// (if a response was returned at all) in
30553// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
30554// whether the returned error was because http.StatusNotModified was
30555// returned.
30556func (c *ProjectsAnswerRecordsPatchCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDialogflowV2AnswerRecord, error) {
30557	gensupport.SetOptions(c.urlParams_, opts...)
30558	res, err := c.doRequest("json")
30559	if res != nil && res.StatusCode == http.StatusNotModified {
30560		if res.Body != nil {
30561			res.Body.Close()
30562		}
30563		return nil, &googleapi.Error{
30564			Code:   res.StatusCode,
30565			Header: res.Header,
30566		}
30567	}
30568	if err != nil {
30569		return nil, err
30570	}
30571	defer googleapi.CloseBody(res)
30572	if err := googleapi.CheckResponse(res); err != nil {
30573		return nil, err
30574	}
30575	ret := &GoogleCloudDialogflowV2AnswerRecord{
30576		ServerResponse: googleapi.ServerResponse{
30577			Header:         res.Header,
30578			HTTPStatusCode: res.StatusCode,
30579		},
30580	}
30581	target := &ret
30582	if err := gensupport.DecodeResponse(target, res); err != nil {
30583		return nil, err
30584	}
30585	return ret, nil
30586	// {
30587	//   "description": "Updates the specified answer record.",
30588	//   "flatPath": "v2/projects/{projectsId}/answerRecords/{answerRecordsId}",
30589	//   "httpMethod": "PATCH",
30590	//   "id": "dialogflow.projects.answerRecords.patch",
30591	//   "parameterOrder": [
30592	//     "name"
30593	//   ],
30594	//   "parameters": {
30595	//     "name": {
30596	//       "description": "The unique identifier of this answer record. Format: `projects//locations//answerRecords/`.",
30597	//       "location": "path",
30598	//       "pattern": "^projects/[^/]+/answerRecords/[^/]+$",
30599	//       "required": true,
30600	//       "type": "string"
30601	//     },
30602	//     "updateMask": {
30603	//       "description": "Required. The mask to control which fields get updated.",
30604	//       "format": "google-fieldmask",
30605	//       "location": "query",
30606	//       "type": "string"
30607	//     }
30608	//   },
30609	//   "path": "v2/{+name}",
30610	//   "request": {
30611	//     "$ref": "GoogleCloudDialogflowV2AnswerRecord"
30612	//   },
30613	//   "response": {
30614	//     "$ref": "GoogleCloudDialogflowV2AnswerRecord"
30615	//   },
30616	//   "scopes": [
30617	//     "https://www.googleapis.com/auth/cloud-platform",
30618	//     "https://www.googleapis.com/auth/dialogflow"
30619	//   ]
30620	// }
30621
30622}
30623
30624// method id "dialogflow.projects.conversationProfiles.create":
30625
30626type ProjectsConversationProfilesCreateCall struct {
30627	s                                          *Service
30628	parent                                     string
30629	googleclouddialogflowv2conversationprofile *GoogleCloudDialogflowV2ConversationProfile
30630	urlParams_                                 gensupport.URLParams
30631	ctx_                                       context.Context
30632	header_                                    http.Header
30633}
30634
30635// Create: Creates a conversation profile in the specified project.
30636// ConversationProfile.CreateTime and ConversationProfile.UpdateTime
30637// aren't populated in the response. You can retrieve them via
30638// GetConversationProfile API.
30639//
30640// - parent: The project to create a conversation profile for. Format:
30641//   `projects//locations/`.
30642func (r *ProjectsConversationProfilesService) Create(parent string, googleclouddialogflowv2conversationprofile *GoogleCloudDialogflowV2ConversationProfile) *ProjectsConversationProfilesCreateCall {
30643	c := &ProjectsConversationProfilesCreateCall{s: r.s, urlParams_: make(gensupport.URLParams)}
30644	c.parent = parent
30645	c.googleclouddialogflowv2conversationprofile = googleclouddialogflowv2conversationprofile
30646	return c
30647}
30648
30649// Fields allows partial responses to be retrieved. See
30650// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
30651// for more information.
30652func (c *ProjectsConversationProfilesCreateCall) Fields(s ...googleapi.Field) *ProjectsConversationProfilesCreateCall {
30653	c.urlParams_.Set("fields", googleapi.CombineFields(s))
30654	return c
30655}
30656
30657// Context sets the context to be used in this call's Do method. Any
30658// pending HTTP request will be aborted if the provided context is
30659// canceled.
30660func (c *ProjectsConversationProfilesCreateCall) Context(ctx context.Context) *ProjectsConversationProfilesCreateCall {
30661	c.ctx_ = ctx
30662	return c
30663}
30664
30665// Header returns an http.Header that can be modified by the caller to
30666// add HTTP headers to the request.
30667func (c *ProjectsConversationProfilesCreateCall) Header() http.Header {
30668	if c.header_ == nil {
30669		c.header_ = make(http.Header)
30670	}
30671	return c.header_
30672}
30673
30674func (c *ProjectsConversationProfilesCreateCall) doRequest(alt string) (*http.Response, error) {
30675	reqHeaders := make(http.Header)
30676	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20211027")
30677	for k, v := range c.header_ {
30678		reqHeaders[k] = v
30679	}
30680	reqHeaders.Set("User-Agent", c.s.userAgent())
30681	var body io.Reader = nil
30682	body, err := googleapi.WithoutDataWrapper.JSONReader(c.googleclouddialogflowv2conversationprofile)
30683	if err != nil {
30684		return nil, err
30685	}
30686	reqHeaders.Set("Content-Type", "application/json")
30687	c.urlParams_.Set("alt", alt)
30688	c.urlParams_.Set("prettyPrint", "false")
30689	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+parent}/conversationProfiles")
30690	urls += "?" + c.urlParams_.Encode()
30691	req, err := http.NewRequest("POST", urls, body)
30692	if err != nil {
30693		return nil, err
30694	}
30695	req.Header = reqHeaders
30696	googleapi.Expand(req.URL, map[string]string{
30697		"parent": c.parent,
30698	})
30699	return gensupport.SendRequest(c.ctx_, c.s.client, req)
30700}
30701
30702// Do executes the "dialogflow.projects.conversationProfiles.create" call.
30703// Exactly one of *GoogleCloudDialogflowV2ConversationProfile or error
30704// will be non-nil. Any non-2xx status code is an error. Response
30705// headers are in either
30706// *GoogleCloudDialogflowV2ConversationProfile.ServerResponse.Header or
30707// (if a response was returned at all) in
30708// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
30709// whether the returned error was because http.StatusNotModified was
30710// returned.
30711func (c *ProjectsConversationProfilesCreateCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDialogflowV2ConversationProfile, error) {
30712	gensupport.SetOptions(c.urlParams_, opts...)
30713	res, err := c.doRequest("json")
30714	if res != nil && res.StatusCode == http.StatusNotModified {
30715		if res.Body != nil {
30716			res.Body.Close()
30717		}
30718		return nil, &googleapi.Error{
30719			Code:   res.StatusCode,
30720			Header: res.Header,
30721		}
30722	}
30723	if err != nil {
30724		return nil, err
30725	}
30726	defer googleapi.CloseBody(res)
30727	if err := googleapi.CheckResponse(res); err != nil {
30728		return nil, err
30729	}
30730	ret := &GoogleCloudDialogflowV2ConversationProfile{
30731		ServerResponse: googleapi.ServerResponse{
30732			Header:         res.Header,
30733			HTTPStatusCode: res.StatusCode,
30734		},
30735	}
30736	target := &ret
30737	if err := gensupport.DecodeResponse(target, res); err != nil {
30738		return nil, err
30739	}
30740	return ret, nil
30741	// {
30742	//   "description": "Creates a conversation profile in the specified project. ConversationProfile.CreateTime and ConversationProfile.UpdateTime aren't populated in the response. You can retrieve them via GetConversationProfile API.",
30743	//   "flatPath": "v2/projects/{projectsId}/conversationProfiles",
30744	//   "httpMethod": "POST",
30745	//   "id": "dialogflow.projects.conversationProfiles.create",
30746	//   "parameterOrder": [
30747	//     "parent"
30748	//   ],
30749	//   "parameters": {
30750	//     "parent": {
30751	//       "description": "Required. The project to create a conversation profile for. Format: `projects//locations/`.",
30752	//       "location": "path",
30753	//       "pattern": "^projects/[^/]+$",
30754	//       "required": true,
30755	//       "type": "string"
30756	//     }
30757	//   },
30758	//   "path": "v2/{+parent}/conversationProfiles",
30759	//   "request": {
30760	//     "$ref": "GoogleCloudDialogflowV2ConversationProfile"
30761	//   },
30762	//   "response": {
30763	//     "$ref": "GoogleCloudDialogflowV2ConversationProfile"
30764	//   },
30765	//   "scopes": [
30766	//     "https://www.googleapis.com/auth/cloud-platform",
30767	//     "https://www.googleapis.com/auth/dialogflow"
30768	//   ]
30769	// }
30770
30771}
30772
30773// method id "dialogflow.projects.conversationProfiles.delete":
30774
30775type ProjectsConversationProfilesDeleteCall struct {
30776	s          *Service
30777	name       string
30778	urlParams_ gensupport.URLParams
30779	ctx_       context.Context
30780	header_    http.Header
30781}
30782
30783// Delete: Deletes the specified conversation profile.
30784//
30785// - name: The name of the conversation profile to delete. Format:
30786//   `projects//locations//conversationProfiles/`.
30787func (r *ProjectsConversationProfilesService) Delete(name string) *ProjectsConversationProfilesDeleteCall {
30788	c := &ProjectsConversationProfilesDeleteCall{s: r.s, urlParams_: make(gensupport.URLParams)}
30789	c.name = name
30790	return c
30791}
30792
30793// Fields allows partial responses to be retrieved. See
30794// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
30795// for more information.
30796func (c *ProjectsConversationProfilesDeleteCall) Fields(s ...googleapi.Field) *ProjectsConversationProfilesDeleteCall {
30797	c.urlParams_.Set("fields", googleapi.CombineFields(s))
30798	return c
30799}
30800
30801// Context sets the context to be used in this call's Do method. Any
30802// pending HTTP request will be aborted if the provided context is
30803// canceled.
30804func (c *ProjectsConversationProfilesDeleteCall) Context(ctx context.Context) *ProjectsConversationProfilesDeleteCall {
30805	c.ctx_ = ctx
30806	return c
30807}
30808
30809// Header returns an http.Header that can be modified by the caller to
30810// add HTTP headers to the request.
30811func (c *ProjectsConversationProfilesDeleteCall) Header() http.Header {
30812	if c.header_ == nil {
30813		c.header_ = make(http.Header)
30814	}
30815	return c.header_
30816}
30817
30818func (c *ProjectsConversationProfilesDeleteCall) doRequest(alt string) (*http.Response, error) {
30819	reqHeaders := make(http.Header)
30820	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20211027")
30821	for k, v := range c.header_ {
30822		reqHeaders[k] = v
30823	}
30824	reqHeaders.Set("User-Agent", c.s.userAgent())
30825	var body io.Reader = nil
30826	c.urlParams_.Set("alt", alt)
30827	c.urlParams_.Set("prettyPrint", "false")
30828	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+name}")
30829	urls += "?" + c.urlParams_.Encode()
30830	req, err := http.NewRequest("DELETE", urls, body)
30831	if err != nil {
30832		return nil, err
30833	}
30834	req.Header = reqHeaders
30835	googleapi.Expand(req.URL, map[string]string{
30836		"name": c.name,
30837	})
30838	return gensupport.SendRequest(c.ctx_, c.s.client, req)
30839}
30840
30841// Do executes the "dialogflow.projects.conversationProfiles.delete" call.
30842// Exactly one of *GoogleProtobufEmpty or error will be non-nil. Any
30843// non-2xx status code is an error. Response headers are in either
30844// *GoogleProtobufEmpty.ServerResponse.Header or (if a response was
30845// returned at all) in error.(*googleapi.Error).Header. Use
30846// googleapi.IsNotModified to check whether the returned error was
30847// because http.StatusNotModified was returned.
30848func (c *ProjectsConversationProfilesDeleteCall) Do(opts ...googleapi.CallOption) (*GoogleProtobufEmpty, error) {
30849	gensupport.SetOptions(c.urlParams_, opts...)
30850	res, err := c.doRequest("json")
30851	if res != nil && res.StatusCode == http.StatusNotModified {
30852		if res.Body != nil {
30853			res.Body.Close()
30854		}
30855		return nil, &googleapi.Error{
30856			Code:   res.StatusCode,
30857			Header: res.Header,
30858		}
30859	}
30860	if err != nil {
30861		return nil, err
30862	}
30863	defer googleapi.CloseBody(res)
30864	if err := googleapi.CheckResponse(res); err != nil {
30865		return nil, err
30866	}
30867	ret := &GoogleProtobufEmpty{
30868		ServerResponse: googleapi.ServerResponse{
30869			Header:         res.Header,
30870			HTTPStatusCode: res.StatusCode,
30871		},
30872	}
30873	target := &ret
30874	if err := gensupport.DecodeResponse(target, res); err != nil {
30875		return nil, err
30876	}
30877	return ret, nil
30878	// {
30879	//   "description": "Deletes the specified conversation profile.",
30880	//   "flatPath": "v2/projects/{projectsId}/conversationProfiles/{conversationProfilesId}",
30881	//   "httpMethod": "DELETE",
30882	//   "id": "dialogflow.projects.conversationProfiles.delete",
30883	//   "parameterOrder": [
30884	//     "name"
30885	//   ],
30886	//   "parameters": {
30887	//     "name": {
30888	//       "description": "Required. The name of the conversation profile to delete. Format: `projects//locations//conversationProfiles/`.",
30889	//       "location": "path",
30890	//       "pattern": "^projects/[^/]+/conversationProfiles/[^/]+$",
30891	//       "required": true,
30892	//       "type": "string"
30893	//     }
30894	//   },
30895	//   "path": "v2/{+name}",
30896	//   "response": {
30897	//     "$ref": "GoogleProtobufEmpty"
30898	//   },
30899	//   "scopes": [
30900	//     "https://www.googleapis.com/auth/cloud-platform",
30901	//     "https://www.googleapis.com/auth/dialogflow"
30902	//   ]
30903	// }
30904
30905}
30906
30907// method id "dialogflow.projects.conversationProfiles.get":
30908
30909type ProjectsConversationProfilesGetCall struct {
30910	s            *Service
30911	name         string
30912	urlParams_   gensupport.URLParams
30913	ifNoneMatch_ string
30914	ctx_         context.Context
30915	header_      http.Header
30916}
30917
30918// Get: Retrieves the specified conversation profile.
30919//
30920// - name: The resource name of the conversation profile. Format:
30921//   `projects//locations//conversationProfiles/`.
30922func (r *ProjectsConversationProfilesService) Get(name string) *ProjectsConversationProfilesGetCall {
30923	c := &ProjectsConversationProfilesGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
30924	c.name = name
30925	return c
30926}
30927
30928// Fields allows partial responses to be retrieved. See
30929// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
30930// for more information.
30931func (c *ProjectsConversationProfilesGetCall) Fields(s ...googleapi.Field) *ProjectsConversationProfilesGetCall {
30932	c.urlParams_.Set("fields", googleapi.CombineFields(s))
30933	return c
30934}
30935
30936// IfNoneMatch sets the optional parameter which makes the operation
30937// fail if the object's ETag matches the given value. This is useful for
30938// getting updates only after the object has changed since the last
30939// request. Use googleapi.IsNotModified to check whether the response
30940// error from Do is the result of In-None-Match.
30941func (c *ProjectsConversationProfilesGetCall) IfNoneMatch(entityTag string) *ProjectsConversationProfilesGetCall {
30942	c.ifNoneMatch_ = entityTag
30943	return c
30944}
30945
30946// Context sets the context to be used in this call's Do method. Any
30947// pending HTTP request will be aborted if the provided context is
30948// canceled.
30949func (c *ProjectsConversationProfilesGetCall) Context(ctx context.Context) *ProjectsConversationProfilesGetCall {
30950	c.ctx_ = ctx
30951	return c
30952}
30953
30954// Header returns an http.Header that can be modified by the caller to
30955// add HTTP headers to the request.
30956func (c *ProjectsConversationProfilesGetCall) Header() http.Header {
30957	if c.header_ == nil {
30958		c.header_ = make(http.Header)
30959	}
30960	return c.header_
30961}
30962
30963func (c *ProjectsConversationProfilesGetCall) doRequest(alt string) (*http.Response, error) {
30964	reqHeaders := make(http.Header)
30965	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20211027")
30966	for k, v := range c.header_ {
30967		reqHeaders[k] = v
30968	}
30969	reqHeaders.Set("User-Agent", c.s.userAgent())
30970	if c.ifNoneMatch_ != "" {
30971		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
30972	}
30973	var body io.Reader = nil
30974	c.urlParams_.Set("alt", alt)
30975	c.urlParams_.Set("prettyPrint", "false")
30976	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+name}")
30977	urls += "?" + c.urlParams_.Encode()
30978	req, err := http.NewRequest("GET", urls, body)
30979	if err != nil {
30980		return nil, err
30981	}
30982	req.Header = reqHeaders
30983	googleapi.Expand(req.URL, map[string]string{
30984		"name": c.name,
30985	})
30986	return gensupport.SendRequest(c.ctx_, c.s.client, req)
30987}
30988
30989// Do executes the "dialogflow.projects.conversationProfiles.get" call.
30990// Exactly one of *GoogleCloudDialogflowV2ConversationProfile or error
30991// will be non-nil. Any non-2xx status code is an error. Response
30992// headers are in either
30993// *GoogleCloudDialogflowV2ConversationProfile.ServerResponse.Header or
30994// (if a response was returned at all) in
30995// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
30996// whether the returned error was because http.StatusNotModified was
30997// returned.
30998func (c *ProjectsConversationProfilesGetCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDialogflowV2ConversationProfile, error) {
30999	gensupport.SetOptions(c.urlParams_, opts...)
31000	res, err := c.doRequest("json")
31001	if res != nil && res.StatusCode == http.StatusNotModified {
31002		if res.Body != nil {
31003			res.Body.Close()
31004		}
31005		return nil, &googleapi.Error{
31006			Code:   res.StatusCode,
31007			Header: res.Header,
31008		}
31009	}
31010	if err != nil {
31011		return nil, err
31012	}
31013	defer googleapi.CloseBody(res)
31014	if err := googleapi.CheckResponse(res); err != nil {
31015		return nil, err
31016	}
31017	ret := &GoogleCloudDialogflowV2ConversationProfile{
31018		ServerResponse: googleapi.ServerResponse{
31019			Header:         res.Header,
31020			HTTPStatusCode: res.StatusCode,
31021		},
31022	}
31023	target := &ret
31024	if err := gensupport.DecodeResponse(target, res); err != nil {
31025		return nil, err
31026	}
31027	return ret, nil
31028	// {
31029	//   "description": "Retrieves the specified conversation profile.",
31030	//   "flatPath": "v2/projects/{projectsId}/conversationProfiles/{conversationProfilesId}",
31031	//   "httpMethod": "GET",
31032	//   "id": "dialogflow.projects.conversationProfiles.get",
31033	//   "parameterOrder": [
31034	//     "name"
31035	//   ],
31036	//   "parameters": {
31037	//     "name": {
31038	//       "description": "Required. The resource name of the conversation profile. Format: `projects//locations//conversationProfiles/`.",
31039	//       "location": "path",
31040	//       "pattern": "^projects/[^/]+/conversationProfiles/[^/]+$",
31041	//       "required": true,
31042	//       "type": "string"
31043	//     }
31044	//   },
31045	//   "path": "v2/{+name}",
31046	//   "response": {
31047	//     "$ref": "GoogleCloudDialogflowV2ConversationProfile"
31048	//   },
31049	//   "scopes": [
31050	//     "https://www.googleapis.com/auth/cloud-platform",
31051	//     "https://www.googleapis.com/auth/dialogflow"
31052	//   ]
31053	// }
31054
31055}
31056
31057// method id "dialogflow.projects.conversationProfiles.list":
31058
31059type ProjectsConversationProfilesListCall struct {
31060	s            *Service
31061	parent       string
31062	urlParams_   gensupport.URLParams
31063	ifNoneMatch_ string
31064	ctx_         context.Context
31065	header_      http.Header
31066}
31067
31068// List: Returns the list of all conversation profiles in the specified
31069// project.
31070//
31071// - parent: The project to list all conversation profiles from. Format:
31072//   `projects//locations/`.
31073func (r *ProjectsConversationProfilesService) List(parent string) *ProjectsConversationProfilesListCall {
31074	c := &ProjectsConversationProfilesListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
31075	c.parent = parent
31076	return c
31077}
31078
31079// PageSize sets the optional parameter "pageSize": The maximum number
31080// of items to return in a single page. By default 100 and at most 1000.
31081func (c *ProjectsConversationProfilesListCall) PageSize(pageSize int64) *ProjectsConversationProfilesListCall {
31082	c.urlParams_.Set("pageSize", fmt.Sprint(pageSize))
31083	return c
31084}
31085
31086// PageToken sets the optional parameter "pageToken": The
31087// next_page_token value returned from a previous list request.
31088func (c *ProjectsConversationProfilesListCall) PageToken(pageToken string) *ProjectsConversationProfilesListCall {
31089	c.urlParams_.Set("pageToken", pageToken)
31090	return c
31091}
31092
31093// Fields allows partial responses to be retrieved. See
31094// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
31095// for more information.
31096func (c *ProjectsConversationProfilesListCall) Fields(s ...googleapi.Field) *ProjectsConversationProfilesListCall {
31097	c.urlParams_.Set("fields", googleapi.CombineFields(s))
31098	return c
31099}
31100
31101// IfNoneMatch sets the optional parameter which makes the operation
31102// fail if the object's ETag matches the given value. This is useful for
31103// getting updates only after the object has changed since the last
31104// request. Use googleapi.IsNotModified to check whether the response
31105// error from Do is the result of In-None-Match.
31106func (c *ProjectsConversationProfilesListCall) IfNoneMatch(entityTag string) *ProjectsConversationProfilesListCall {
31107	c.ifNoneMatch_ = entityTag
31108	return c
31109}
31110
31111// Context sets the context to be used in this call's Do method. Any
31112// pending HTTP request will be aborted if the provided context is
31113// canceled.
31114func (c *ProjectsConversationProfilesListCall) Context(ctx context.Context) *ProjectsConversationProfilesListCall {
31115	c.ctx_ = ctx
31116	return c
31117}
31118
31119// Header returns an http.Header that can be modified by the caller to
31120// add HTTP headers to the request.
31121func (c *ProjectsConversationProfilesListCall) Header() http.Header {
31122	if c.header_ == nil {
31123		c.header_ = make(http.Header)
31124	}
31125	return c.header_
31126}
31127
31128func (c *ProjectsConversationProfilesListCall) doRequest(alt string) (*http.Response, error) {
31129	reqHeaders := make(http.Header)
31130	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20211027")
31131	for k, v := range c.header_ {
31132		reqHeaders[k] = v
31133	}
31134	reqHeaders.Set("User-Agent", c.s.userAgent())
31135	if c.ifNoneMatch_ != "" {
31136		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
31137	}
31138	var body io.Reader = nil
31139	c.urlParams_.Set("alt", alt)
31140	c.urlParams_.Set("prettyPrint", "false")
31141	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+parent}/conversationProfiles")
31142	urls += "?" + c.urlParams_.Encode()
31143	req, err := http.NewRequest("GET", urls, body)
31144	if err != nil {
31145		return nil, err
31146	}
31147	req.Header = reqHeaders
31148	googleapi.Expand(req.URL, map[string]string{
31149		"parent": c.parent,
31150	})
31151	return gensupport.SendRequest(c.ctx_, c.s.client, req)
31152}
31153
31154// Do executes the "dialogflow.projects.conversationProfiles.list" call.
31155// Exactly one of
31156// *GoogleCloudDialogflowV2ListConversationProfilesResponse or error
31157// will be non-nil. Any non-2xx status code is an error. Response
31158// headers are in either
31159// *GoogleCloudDialogflowV2ListConversationProfilesResponse.ServerRespons
31160// e.Header or (if a response was returned at all) in
31161// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
31162// whether the returned error was because http.StatusNotModified was
31163// returned.
31164func (c *ProjectsConversationProfilesListCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDialogflowV2ListConversationProfilesResponse, error) {
31165	gensupport.SetOptions(c.urlParams_, opts...)
31166	res, err := c.doRequest("json")
31167	if res != nil && res.StatusCode == http.StatusNotModified {
31168		if res.Body != nil {
31169			res.Body.Close()
31170		}
31171		return nil, &googleapi.Error{
31172			Code:   res.StatusCode,
31173			Header: res.Header,
31174		}
31175	}
31176	if err != nil {
31177		return nil, err
31178	}
31179	defer googleapi.CloseBody(res)
31180	if err := googleapi.CheckResponse(res); err != nil {
31181		return nil, err
31182	}
31183	ret := &GoogleCloudDialogflowV2ListConversationProfilesResponse{
31184		ServerResponse: googleapi.ServerResponse{
31185			Header:         res.Header,
31186			HTTPStatusCode: res.StatusCode,
31187		},
31188	}
31189	target := &ret
31190	if err := gensupport.DecodeResponse(target, res); err != nil {
31191		return nil, err
31192	}
31193	return ret, nil
31194	// {
31195	//   "description": "Returns the list of all conversation profiles in the specified project.",
31196	//   "flatPath": "v2/projects/{projectsId}/conversationProfiles",
31197	//   "httpMethod": "GET",
31198	//   "id": "dialogflow.projects.conversationProfiles.list",
31199	//   "parameterOrder": [
31200	//     "parent"
31201	//   ],
31202	//   "parameters": {
31203	//     "pageSize": {
31204	//       "description": "The maximum number of items to return in a single page. By default 100 and at most 1000.",
31205	//       "format": "int32",
31206	//       "location": "query",
31207	//       "type": "integer"
31208	//     },
31209	//     "pageToken": {
31210	//       "description": "The next_page_token value returned from a previous list request.",
31211	//       "location": "query",
31212	//       "type": "string"
31213	//     },
31214	//     "parent": {
31215	//       "description": "Required. The project to list all conversation profiles from. Format: `projects//locations/`.",
31216	//       "location": "path",
31217	//       "pattern": "^projects/[^/]+$",
31218	//       "required": true,
31219	//       "type": "string"
31220	//     }
31221	//   },
31222	//   "path": "v2/{+parent}/conversationProfiles",
31223	//   "response": {
31224	//     "$ref": "GoogleCloudDialogflowV2ListConversationProfilesResponse"
31225	//   },
31226	//   "scopes": [
31227	//     "https://www.googleapis.com/auth/cloud-platform",
31228	//     "https://www.googleapis.com/auth/dialogflow"
31229	//   ]
31230	// }
31231
31232}
31233
31234// Pages invokes f for each page of results.
31235// A non-nil error returned from f will halt the iteration.
31236// The provided context supersedes any context provided to the Context method.
31237func (c *ProjectsConversationProfilesListCall) Pages(ctx context.Context, f func(*GoogleCloudDialogflowV2ListConversationProfilesResponse) error) error {
31238	c.ctx_ = ctx
31239	defer c.PageToken(c.urlParams_.Get("pageToken")) // reset paging to original point
31240	for {
31241		x, err := c.Do()
31242		if err != nil {
31243			return err
31244		}
31245		if err := f(x); err != nil {
31246			return err
31247		}
31248		if x.NextPageToken == "" {
31249			return nil
31250		}
31251		c.PageToken(x.NextPageToken)
31252	}
31253}
31254
31255// method id "dialogflow.projects.conversationProfiles.patch":
31256
31257type ProjectsConversationProfilesPatchCall struct {
31258	s                                          *Service
31259	nameid                                     string
31260	googleclouddialogflowv2conversationprofile *GoogleCloudDialogflowV2ConversationProfile
31261	urlParams_                                 gensupport.URLParams
31262	ctx_                                       context.Context
31263	header_                                    http.Header
31264}
31265
31266// Patch: Updates the specified conversation profile.
31267// ConversationProfile.CreateTime and ConversationProfile.UpdateTime
31268// aren't populated in the response. You can retrieve them via
31269// GetConversationProfile API.
31270//
31271// - name: The unique identifier of this conversation profile. Format:
31272//   `projects//locations//conversationProfiles/`.
31273func (r *ProjectsConversationProfilesService) Patch(nameid string, googleclouddialogflowv2conversationprofile *GoogleCloudDialogflowV2ConversationProfile) *ProjectsConversationProfilesPatchCall {
31274	c := &ProjectsConversationProfilesPatchCall{s: r.s, urlParams_: make(gensupport.URLParams)}
31275	c.nameid = nameid
31276	c.googleclouddialogflowv2conversationprofile = googleclouddialogflowv2conversationprofile
31277	return c
31278}
31279
31280// UpdateMask sets the optional parameter "updateMask": Required. The
31281// mask to control which fields to update.
31282func (c *ProjectsConversationProfilesPatchCall) UpdateMask(updateMask string) *ProjectsConversationProfilesPatchCall {
31283	c.urlParams_.Set("updateMask", updateMask)
31284	return c
31285}
31286
31287// Fields allows partial responses to be retrieved. See
31288// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
31289// for more information.
31290func (c *ProjectsConversationProfilesPatchCall) Fields(s ...googleapi.Field) *ProjectsConversationProfilesPatchCall {
31291	c.urlParams_.Set("fields", googleapi.CombineFields(s))
31292	return c
31293}
31294
31295// Context sets the context to be used in this call's Do method. Any
31296// pending HTTP request will be aborted if the provided context is
31297// canceled.
31298func (c *ProjectsConversationProfilesPatchCall) Context(ctx context.Context) *ProjectsConversationProfilesPatchCall {
31299	c.ctx_ = ctx
31300	return c
31301}
31302
31303// Header returns an http.Header that can be modified by the caller to
31304// add HTTP headers to the request.
31305func (c *ProjectsConversationProfilesPatchCall) Header() http.Header {
31306	if c.header_ == nil {
31307		c.header_ = make(http.Header)
31308	}
31309	return c.header_
31310}
31311
31312func (c *ProjectsConversationProfilesPatchCall) doRequest(alt string) (*http.Response, error) {
31313	reqHeaders := make(http.Header)
31314	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20211027")
31315	for k, v := range c.header_ {
31316		reqHeaders[k] = v
31317	}
31318	reqHeaders.Set("User-Agent", c.s.userAgent())
31319	var body io.Reader = nil
31320	body, err := googleapi.WithoutDataWrapper.JSONReader(c.googleclouddialogflowv2conversationprofile)
31321	if err != nil {
31322		return nil, err
31323	}
31324	reqHeaders.Set("Content-Type", "application/json")
31325	c.urlParams_.Set("alt", alt)
31326	c.urlParams_.Set("prettyPrint", "false")
31327	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+name}")
31328	urls += "?" + c.urlParams_.Encode()
31329	req, err := http.NewRequest("PATCH", urls, body)
31330	if err != nil {
31331		return nil, err
31332	}
31333	req.Header = reqHeaders
31334	googleapi.Expand(req.URL, map[string]string{
31335		"name": c.nameid,
31336	})
31337	return gensupport.SendRequest(c.ctx_, c.s.client, req)
31338}
31339
31340// Do executes the "dialogflow.projects.conversationProfiles.patch" call.
31341// Exactly one of *GoogleCloudDialogflowV2ConversationProfile or error
31342// will be non-nil. Any non-2xx status code is an error. Response
31343// headers are in either
31344// *GoogleCloudDialogflowV2ConversationProfile.ServerResponse.Header or
31345// (if a response was returned at all) in
31346// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
31347// whether the returned error was because http.StatusNotModified was
31348// returned.
31349func (c *ProjectsConversationProfilesPatchCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDialogflowV2ConversationProfile, error) {
31350	gensupport.SetOptions(c.urlParams_, opts...)
31351	res, err := c.doRequest("json")
31352	if res != nil && res.StatusCode == http.StatusNotModified {
31353		if res.Body != nil {
31354			res.Body.Close()
31355		}
31356		return nil, &googleapi.Error{
31357			Code:   res.StatusCode,
31358			Header: res.Header,
31359		}
31360	}
31361	if err != nil {
31362		return nil, err
31363	}
31364	defer googleapi.CloseBody(res)
31365	if err := googleapi.CheckResponse(res); err != nil {
31366		return nil, err
31367	}
31368	ret := &GoogleCloudDialogflowV2ConversationProfile{
31369		ServerResponse: googleapi.ServerResponse{
31370			Header:         res.Header,
31371			HTTPStatusCode: res.StatusCode,
31372		},
31373	}
31374	target := &ret
31375	if err := gensupport.DecodeResponse(target, res); err != nil {
31376		return nil, err
31377	}
31378	return ret, nil
31379	// {
31380	//   "description": "Updates the specified conversation profile. ConversationProfile.CreateTime and ConversationProfile.UpdateTime aren't populated in the response. You can retrieve them via GetConversationProfile API.",
31381	//   "flatPath": "v2/projects/{projectsId}/conversationProfiles/{conversationProfilesId}",
31382	//   "httpMethod": "PATCH",
31383	//   "id": "dialogflow.projects.conversationProfiles.patch",
31384	//   "parameterOrder": [
31385	//     "name"
31386	//   ],
31387	//   "parameters": {
31388	//     "name": {
31389	//       "description": "The unique identifier of this conversation profile. Format: `projects//locations//conversationProfiles/`.",
31390	//       "location": "path",
31391	//       "pattern": "^projects/[^/]+/conversationProfiles/[^/]+$",
31392	//       "required": true,
31393	//       "type": "string"
31394	//     },
31395	//     "updateMask": {
31396	//       "description": "Required. The mask to control which fields to update.",
31397	//       "format": "google-fieldmask",
31398	//       "location": "query",
31399	//       "type": "string"
31400	//     }
31401	//   },
31402	//   "path": "v2/{+name}",
31403	//   "request": {
31404	//     "$ref": "GoogleCloudDialogflowV2ConversationProfile"
31405	//   },
31406	//   "response": {
31407	//     "$ref": "GoogleCloudDialogflowV2ConversationProfile"
31408	//   },
31409	//   "scopes": [
31410	//     "https://www.googleapis.com/auth/cloud-platform",
31411	//     "https://www.googleapis.com/auth/dialogflow"
31412	//   ]
31413	// }
31414
31415}
31416
31417// method id "dialogflow.projects.conversations.complete":
31418
31419type ProjectsConversationsCompleteCall struct {
31420	s                                                  *Service
31421	nameid                                             string
31422	googleclouddialogflowv2completeconversationrequest *GoogleCloudDialogflowV2CompleteConversationRequest
31423	urlParams_                                         gensupport.URLParams
31424	ctx_                                               context.Context
31425	header_                                            http.Header
31426}
31427
31428// Complete: Completes the specified conversation. Finished
31429// conversations are purged from the database after 30 days.
31430//
31431// - name: Resource identifier of the conversation to close. Format:
31432//   `projects//locations//conversations/`.
31433func (r *ProjectsConversationsService) Complete(nameid string, googleclouddialogflowv2completeconversationrequest *GoogleCloudDialogflowV2CompleteConversationRequest) *ProjectsConversationsCompleteCall {
31434	c := &ProjectsConversationsCompleteCall{s: r.s, urlParams_: make(gensupport.URLParams)}
31435	c.nameid = nameid
31436	c.googleclouddialogflowv2completeconversationrequest = googleclouddialogflowv2completeconversationrequest
31437	return c
31438}
31439
31440// Fields allows partial responses to be retrieved. See
31441// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
31442// for more information.
31443func (c *ProjectsConversationsCompleteCall) Fields(s ...googleapi.Field) *ProjectsConversationsCompleteCall {
31444	c.urlParams_.Set("fields", googleapi.CombineFields(s))
31445	return c
31446}
31447
31448// Context sets the context to be used in this call's Do method. Any
31449// pending HTTP request will be aborted if the provided context is
31450// canceled.
31451func (c *ProjectsConversationsCompleteCall) Context(ctx context.Context) *ProjectsConversationsCompleteCall {
31452	c.ctx_ = ctx
31453	return c
31454}
31455
31456// Header returns an http.Header that can be modified by the caller to
31457// add HTTP headers to the request.
31458func (c *ProjectsConversationsCompleteCall) Header() http.Header {
31459	if c.header_ == nil {
31460		c.header_ = make(http.Header)
31461	}
31462	return c.header_
31463}
31464
31465func (c *ProjectsConversationsCompleteCall) doRequest(alt string) (*http.Response, error) {
31466	reqHeaders := make(http.Header)
31467	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20211027")
31468	for k, v := range c.header_ {
31469		reqHeaders[k] = v
31470	}
31471	reqHeaders.Set("User-Agent", c.s.userAgent())
31472	var body io.Reader = nil
31473	body, err := googleapi.WithoutDataWrapper.JSONReader(c.googleclouddialogflowv2completeconversationrequest)
31474	if err != nil {
31475		return nil, err
31476	}
31477	reqHeaders.Set("Content-Type", "application/json")
31478	c.urlParams_.Set("alt", alt)
31479	c.urlParams_.Set("prettyPrint", "false")
31480	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+name}:complete")
31481	urls += "?" + c.urlParams_.Encode()
31482	req, err := http.NewRequest("POST", urls, body)
31483	if err != nil {
31484		return nil, err
31485	}
31486	req.Header = reqHeaders
31487	googleapi.Expand(req.URL, map[string]string{
31488		"name": c.nameid,
31489	})
31490	return gensupport.SendRequest(c.ctx_, c.s.client, req)
31491}
31492
31493// Do executes the "dialogflow.projects.conversations.complete" call.
31494// Exactly one of *GoogleCloudDialogflowV2Conversation or error will be
31495// non-nil. Any non-2xx status code is an error. Response headers are in
31496// either *GoogleCloudDialogflowV2Conversation.ServerResponse.Header or
31497// (if a response was returned at all) in
31498// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
31499// whether the returned error was because http.StatusNotModified was
31500// returned.
31501func (c *ProjectsConversationsCompleteCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDialogflowV2Conversation, error) {
31502	gensupport.SetOptions(c.urlParams_, opts...)
31503	res, err := c.doRequest("json")
31504	if res != nil && res.StatusCode == http.StatusNotModified {
31505		if res.Body != nil {
31506			res.Body.Close()
31507		}
31508		return nil, &googleapi.Error{
31509			Code:   res.StatusCode,
31510			Header: res.Header,
31511		}
31512	}
31513	if err != nil {
31514		return nil, err
31515	}
31516	defer googleapi.CloseBody(res)
31517	if err := googleapi.CheckResponse(res); err != nil {
31518		return nil, err
31519	}
31520	ret := &GoogleCloudDialogflowV2Conversation{
31521		ServerResponse: googleapi.ServerResponse{
31522			Header:         res.Header,
31523			HTTPStatusCode: res.StatusCode,
31524		},
31525	}
31526	target := &ret
31527	if err := gensupport.DecodeResponse(target, res); err != nil {
31528		return nil, err
31529	}
31530	return ret, nil
31531	// {
31532	//   "description": "Completes the specified conversation. Finished conversations are purged from the database after 30 days.",
31533	//   "flatPath": "v2/projects/{projectsId}/conversations/{conversationsId}:complete",
31534	//   "httpMethod": "POST",
31535	//   "id": "dialogflow.projects.conversations.complete",
31536	//   "parameterOrder": [
31537	//     "name"
31538	//   ],
31539	//   "parameters": {
31540	//     "name": {
31541	//       "description": "Required. Resource identifier of the conversation to close. Format: `projects//locations//conversations/`.",
31542	//       "location": "path",
31543	//       "pattern": "^projects/[^/]+/conversations/[^/]+$",
31544	//       "required": true,
31545	//       "type": "string"
31546	//     }
31547	//   },
31548	//   "path": "v2/{+name}:complete",
31549	//   "request": {
31550	//     "$ref": "GoogleCloudDialogflowV2CompleteConversationRequest"
31551	//   },
31552	//   "response": {
31553	//     "$ref": "GoogleCloudDialogflowV2Conversation"
31554	//   },
31555	//   "scopes": [
31556	//     "https://www.googleapis.com/auth/cloud-platform",
31557	//     "https://www.googleapis.com/auth/dialogflow"
31558	//   ]
31559	// }
31560
31561}
31562
31563// method id "dialogflow.projects.conversations.create":
31564
31565type ProjectsConversationsCreateCall struct {
31566	s                                   *Service
31567	parentid                            string
31568	googleclouddialogflowv2conversation *GoogleCloudDialogflowV2Conversation
31569	urlParams_                          gensupport.URLParams
31570	ctx_                                context.Context
31571	header_                             http.Header
31572}
31573
31574// Create: Creates a new conversation. Conversations are auto-completed
31575// after 24 hours. Conversation Lifecycle: There are two stages during a
31576// conversation: Automated Agent Stage and Assist Stage. For Automated
31577// Agent Stage, there will be a dialogflow agent responding to user
31578// queries. For Assist Stage, there's no dialogflow agent responding to
31579// user queries. But we will provide suggestions which are generated
31580// from conversation. If Conversation.conversation_profile is configured
31581// for a dialogflow agent, conversation will start from `Automated Agent
31582// Stage`, otherwise, it will start from `Assist Stage`. And during
31583// `Automated Agent Stage`, once an Intent with
31584// Intent.live_agent_handoff is triggered, conversation will transfer to
31585// Assist Stage.
31586//
31587// - parent: Resource identifier of the project creating the
31588//   conversation. Format: `projects//locations/`.
31589func (r *ProjectsConversationsService) Create(parentid string, googleclouddialogflowv2conversation *GoogleCloudDialogflowV2Conversation) *ProjectsConversationsCreateCall {
31590	c := &ProjectsConversationsCreateCall{s: r.s, urlParams_: make(gensupport.URLParams)}
31591	c.parentid = parentid
31592	c.googleclouddialogflowv2conversation = googleclouddialogflowv2conversation
31593	return c
31594}
31595
31596// ConversationId sets the optional parameter "conversationId":
31597// Identifier of the conversation. Generally it's auto generated by
31598// Google. Only set it if you cannot wait for the response to return a
31599// auto-generated one to you. The conversation ID must be compliant with
31600// the regression fomula "a-zA-Z*" with the characters length in range
31601// of [3,64]. If the field is provided, the caller is resposible for 1.
31602// the uniqueness of the ID, otherwise the request will be rejected. 2.
31603// the consistency for whether to use custom ID or not under a project
31604// to better ensure uniqueness.
31605func (c *ProjectsConversationsCreateCall) ConversationId(conversationId string) *ProjectsConversationsCreateCall {
31606	c.urlParams_.Set("conversationId", conversationId)
31607	return c
31608}
31609
31610// Fields allows partial responses to be retrieved. See
31611// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
31612// for more information.
31613func (c *ProjectsConversationsCreateCall) Fields(s ...googleapi.Field) *ProjectsConversationsCreateCall {
31614	c.urlParams_.Set("fields", googleapi.CombineFields(s))
31615	return c
31616}
31617
31618// Context sets the context to be used in this call's Do method. Any
31619// pending HTTP request will be aborted if the provided context is
31620// canceled.
31621func (c *ProjectsConversationsCreateCall) Context(ctx context.Context) *ProjectsConversationsCreateCall {
31622	c.ctx_ = ctx
31623	return c
31624}
31625
31626// Header returns an http.Header that can be modified by the caller to
31627// add HTTP headers to the request.
31628func (c *ProjectsConversationsCreateCall) Header() http.Header {
31629	if c.header_ == nil {
31630		c.header_ = make(http.Header)
31631	}
31632	return c.header_
31633}
31634
31635func (c *ProjectsConversationsCreateCall) doRequest(alt string) (*http.Response, error) {
31636	reqHeaders := make(http.Header)
31637	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20211027")
31638	for k, v := range c.header_ {
31639		reqHeaders[k] = v
31640	}
31641	reqHeaders.Set("User-Agent", c.s.userAgent())
31642	var body io.Reader = nil
31643	body, err := googleapi.WithoutDataWrapper.JSONReader(c.googleclouddialogflowv2conversation)
31644	if err != nil {
31645		return nil, err
31646	}
31647	reqHeaders.Set("Content-Type", "application/json")
31648	c.urlParams_.Set("alt", alt)
31649	c.urlParams_.Set("prettyPrint", "false")
31650	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+parent}/conversations")
31651	urls += "?" + c.urlParams_.Encode()
31652	req, err := http.NewRequest("POST", urls, body)
31653	if err != nil {
31654		return nil, err
31655	}
31656	req.Header = reqHeaders
31657	googleapi.Expand(req.URL, map[string]string{
31658		"parent": c.parentid,
31659	})
31660	return gensupport.SendRequest(c.ctx_, c.s.client, req)
31661}
31662
31663// Do executes the "dialogflow.projects.conversations.create" call.
31664// Exactly one of *GoogleCloudDialogflowV2Conversation or error will be
31665// non-nil. Any non-2xx status code is an error. Response headers are in
31666// either *GoogleCloudDialogflowV2Conversation.ServerResponse.Header or
31667// (if a response was returned at all) in
31668// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
31669// whether the returned error was because http.StatusNotModified was
31670// returned.
31671func (c *ProjectsConversationsCreateCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDialogflowV2Conversation, error) {
31672	gensupport.SetOptions(c.urlParams_, opts...)
31673	res, err := c.doRequest("json")
31674	if res != nil && res.StatusCode == http.StatusNotModified {
31675		if res.Body != nil {
31676			res.Body.Close()
31677		}
31678		return nil, &googleapi.Error{
31679			Code:   res.StatusCode,
31680			Header: res.Header,
31681		}
31682	}
31683	if err != nil {
31684		return nil, err
31685	}
31686	defer googleapi.CloseBody(res)
31687	if err := googleapi.CheckResponse(res); err != nil {
31688		return nil, err
31689	}
31690	ret := &GoogleCloudDialogflowV2Conversation{
31691		ServerResponse: googleapi.ServerResponse{
31692			Header:         res.Header,
31693			HTTPStatusCode: res.StatusCode,
31694		},
31695	}
31696	target := &ret
31697	if err := gensupport.DecodeResponse(target, res); err != nil {
31698		return nil, err
31699	}
31700	return ret, nil
31701	// {
31702	//   "description": "Creates a new conversation. Conversations are auto-completed after 24 hours. Conversation Lifecycle: There are two stages during a conversation: Automated Agent Stage and Assist Stage. For Automated Agent Stage, there will be a dialogflow agent responding to user queries. For Assist Stage, there's no dialogflow agent responding to user queries. But we will provide suggestions which are generated from conversation. If Conversation.conversation_profile is configured for a dialogflow agent, conversation will start from `Automated Agent Stage`, otherwise, it will start from `Assist Stage`. And during `Automated Agent Stage`, once an Intent with Intent.live_agent_handoff is triggered, conversation will transfer to Assist Stage.",
31703	//   "flatPath": "v2/projects/{projectsId}/conversations",
31704	//   "httpMethod": "POST",
31705	//   "id": "dialogflow.projects.conversations.create",
31706	//   "parameterOrder": [
31707	//     "parent"
31708	//   ],
31709	//   "parameters": {
31710	//     "conversationId": {
31711	//       "description": "Optional. Identifier of the conversation. Generally it's auto generated by Google. Only set it if you cannot wait for the response to return a auto-generated one to you. The conversation ID must be compliant with the regression fomula \"a-zA-Z*\" with the characters length in range of [3,64]. 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.",
31712	//       "location": "query",
31713	//       "type": "string"
31714	//     },
31715	//     "parent": {
31716	//       "description": "Required. Resource identifier of the project creating the conversation. Format: `projects//locations/`.",
31717	//       "location": "path",
31718	//       "pattern": "^projects/[^/]+$",
31719	//       "required": true,
31720	//       "type": "string"
31721	//     }
31722	//   },
31723	//   "path": "v2/{+parent}/conversations",
31724	//   "request": {
31725	//     "$ref": "GoogleCloudDialogflowV2Conversation"
31726	//   },
31727	//   "response": {
31728	//     "$ref": "GoogleCloudDialogflowV2Conversation"
31729	//   },
31730	//   "scopes": [
31731	//     "https://www.googleapis.com/auth/cloud-platform",
31732	//     "https://www.googleapis.com/auth/dialogflow"
31733	//   ]
31734	// }
31735
31736}
31737
31738// method id "dialogflow.projects.conversations.get":
31739
31740type ProjectsConversationsGetCall struct {
31741	s            *Service
31742	name         string
31743	urlParams_   gensupport.URLParams
31744	ifNoneMatch_ string
31745	ctx_         context.Context
31746	header_      http.Header
31747}
31748
31749// Get: Retrieves the specific conversation.
31750//
31751// - name: The name of the conversation. Format:
31752//   `projects//locations//conversations/`.
31753func (r *ProjectsConversationsService) Get(name string) *ProjectsConversationsGetCall {
31754	c := &ProjectsConversationsGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
31755	c.name = name
31756	return c
31757}
31758
31759// Fields allows partial responses to be retrieved. See
31760// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
31761// for more information.
31762func (c *ProjectsConversationsGetCall) Fields(s ...googleapi.Field) *ProjectsConversationsGetCall {
31763	c.urlParams_.Set("fields", googleapi.CombineFields(s))
31764	return c
31765}
31766
31767// IfNoneMatch sets the optional parameter which makes the operation
31768// fail if the object's ETag matches the given value. This is useful for
31769// getting updates only after the object has changed since the last
31770// request. Use googleapi.IsNotModified to check whether the response
31771// error from Do is the result of In-None-Match.
31772func (c *ProjectsConversationsGetCall) IfNoneMatch(entityTag string) *ProjectsConversationsGetCall {
31773	c.ifNoneMatch_ = entityTag
31774	return c
31775}
31776
31777// Context sets the context to be used in this call's Do method. Any
31778// pending HTTP request will be aborted if the provided context is
31779// canceled.
31780func (c *ProjectsConversationsGetCall) Context(ctx context.Context) *ProjectsConversationsGetCall {
31781	c.ctx_ = ctx
31782	return c
31783}
31784
31785// Header returns an http.Header that can be modified by the caller to
31786// add HTTP headers to the request.
31787func (c *ProjectsConversationsGetCall) Header() http.Header {
31788	if c.header_ == nil {
31789		c.header_ = make(http.Header)
31790	}
31791	return c.header_
31792}
31793
31794func (c *ProjectsConversationsGetCall) doRequest(alt string) (*http.Response, error) {
31795	reqHeaders := make(http.Header)
31796	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20211027")
31797	for k, v := range c.header_ {
31798		reqHeaders[k] = v
31799	}
31800	reqHeaders.Set("User-Agent", c.s.userAgent())
31801	if c.ifNoneMatch_ != "" {
31802		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
31803	}
31804	var body io.Reader = nil
31805	c.urlParams_.Set("alt", alt)
31806	c.urlParams_.Set("prettyPrint", "false")
31807	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+name}")
31808	urls += "?" + c.urlParams_.Encode()
31809	req, err := http.NewRequest("GET", urls, body)
31810	if err != nil {
31811		return nil, err
31812	}
31813	req.Header = reqHeaders
31814	googleapi.Expand(req.URL, map[string]string{
31815		"name": c.name,
31816	})
31817	return gensupport.SendRequest(c.ctx_, c.s.client, req)
31818}
31819
31820// Do executes the "dialogflow.projects.conversations.get" call.
31821// Exactly one of *GoogleCloudDialogflowV2Conversation or error will be
31822// non-nil. Any non-2xx status code is an error. Response headers are in
31823// either *GoogleCloudDialogflowV2Conversation.ServerResponse.Header or
31824// (if a response was returned at all) in
31825// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
31826// whether the returned error was because http.StatusNotModified was
31827// returned.
31828func (c *ProjectsConversationsGetCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDialogflowV2Conversation, error) {
31829	gensupport.SetOptions(c.urlParams_, opts...)
31830	res, err := c.doRequest("json")
31831	if res != nil && res.StatusCode == http.StatusNotModified {
31832		if res.Body != nil {
31833			res.Body.Close()
31834		}
31835		return nil, &googleapi.Error{
31836			Code:   res.StatusCode,
31837			Header: res.Header,
31838		}
31839	}
31840	if err != nil {
31841		return nil, err
31842	}
31843	defer googleapi.CloseBody(res)
31844	if err := googleapi.CheckResponse(res); err != nil {
31845		return nil, err
31846	}
31847	ret := &GoogleCloudDialogflowV2Conversation{
31848		ServerResponse: googleapi.ServerResponse{
31849			Header:         res.Header,
31850			HTTPStatusCode: res.StatusCode,
31851		},
31852	}
31853	target := &ret
31854	if err := gensupport.DecodeResponse(target, res); err != nil {
31855		return nil, err
31856	}
31857	return ret, nil
31858	// {
31859	//   "description": "Retrieves the specific conversation.",
31860	//   "flatPath": "v2/projects/{projectsId}/conversations/{conversationsId}",
31861	//   "httpMethod": "GET",
31862	//   "id": "dialogflow.projects.conversations.get",
31863	//   "parameterOrder": [
31864	//     "name"
31865	//   ],
31866	//   "parameters": {
31867	//     "name": {
31868	//       "description": "Required. The name of the conversation. Format: `projects//locations//conversations/`.",
31869	//       "location": "path",
31870	//       "pattern": "^projects/[^/]+/conversations/[^/]+$",
31871	//       "required": true,
31872	//       "type": "string"
31873	//     }
31874	//   },
31875	//   "path": "v2/{+name}",
31876	//   "response": {
31877	//     "$ref": "GoogleCloudDialogflowV2Conversation"
31878	//   },
31879	//   "scopes": [
31880	//     "https://www.googleapis.com/auth/cloud-platform",
31881	//     "https://www.googleapis.com/auth/dialogflow"
31882	//   ]
31883	// }
31884
31885}
31886
31887// method id "dialogflow.projects.conversations.list":
31888
31889type ProjectsConversationsListCall struct {
31890	s            *Service
31891	parent       string
31892	urlParams_   gensupport.URLParams
31893	ifNoneMatch_ string
31894	ctx_         context.Context
31895	header_      http.Header
31896}
31897
31898// List: Returns the list of all conversations in the specified project.
31899//
31900// - parent: The project from which to list all conversation. Format:
31901//   `projects//locations/`.
31902func (r *ProjectsConversationsService) List(parent string) *ProjectsConversationsListCall {
31903	c := &ProjectsConversationsListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
31904	c.parent = parent
31905	return c
31906}
31907
31908// Filter sets the optional parameter "filter": A filter expression that
31909// filters conversations listed in the response. In general, the
31910// expression must specify the field name, a comparison operator, and
31911// the value to use for filtering: - The value must be a string, a
31912// number, or a boolean. - The comparison operator must be either
31913// `=`,`!=`, `>`, or `<`. - To filter on multiple expressions, separate
31914// the expressions with `AND` or `OR` (omitting both implies `AND`). -
31915// For clarity, expressions can be enclosed in parentheses. Only
31916// `lifecycle_state` can be filtered on in this way. For example, the
31917// following expression only returns `COMPLETED` conversations:
31918// `lifecycle_state = "COMPLETED" For more information about filtering,
31919// see API Filtering (https://aip.dev/160).
31920func (c *ProjectsConversationsListCall) Filter(filter string) *ProjectsConversationsListCall {
31921	c.urlParams_.Set("filter", filter)
31922	return c
31923}
31924
31925// PageSize sets the optional parameter "pageSize": The maximum number
31926// of items to return in a single page. By default 100 and at most 1000.
31927func (c *ProjectsConversationsListCall) PageSize(pageSize int64) *ProjectsConversationsListCall {
31928	c.urlParams_.Set("pageSize", fmt.Sprint(pageSize))
31929	return c
31930}
31931
31932// PageToken sets the optional parameter "pageToken": The
31933// next_page_token value returned from a previous list request.
31934func (c *ProjectsConversationsListCall) PageToken(pageToken string) *ProjectsConversationsListCall {
31935	c.urlParams_.Set("pageToken", pageToken)
31936	return c
31937}
31938
31939// Fields allows partial responses to be retrieved. See
31940// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
31941// for more information.
31942func (c *ProjectsConversationsListCall) Fields(s ...googleapi.Field) *ProjectsConversationsListCall {
31943	c.urlParams_.Set("fields", googleapi.CombineFields(s))
31944	return c
31945}
31946
31947// IfNoneMatch sets the optional parameter which makes the operation
31948// fail if the object's ETag matches the given value. This is useful for
31949// getting updates only after the object has changed since the last
31950// request. Use googleapi.IsNotModified to check whether the response
31951// error from Do is the result of In-None-Match.
31952func (c *ProjectsConversationsListCall) IfNoneMatch(entityTag string) *ProjectsConversationsListCall {
31953	c.ifNoneMatch_ = entityTag
31954	return c
31955}
31956
31957// Context sets the context to be used in this call's Do method. Any
31958// pending HTTP request will be aborted if the provided context is
31959// canceled.
31960func (c *ProjectsConversationsListCall) Context(ctx context.Context) *ProjectsConversationsListCall {
31961	c.ctx_ = ctx
31962	return c
31963}
31964
31965// Header returns an http.Header that can be modified by the caller to
31966// add HTTP headers to the request.
31967func (c *ProjectsConversationsListCall) Header() http.Header {
31968	if c.header_ == nil {
31969		c.header_ = make(http.Header)
31970	}
31971	return c.header_
31972}
31973
31974func (c *ProjectsConversationsListCall) doRequest(alt string) (*http.Response, error) {
31975	reqHeaders := make(http.Header)
31976	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20211027")
31977	for k, v := range c.header_ {
31978		reqHeaders[k] = v
31979	}
31980	reqHeaders.Set("User-Agent", c.s.userAgent())
31981	if c.ifNoneMatch_ != "" {
31982		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
31983	}
31984	var body io.Reader = nil
31985	c.urlParams_.Set("alt", alt)
31986	c.urlParams_.Set("prettyPrint", "false")
31987	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+parent}/conversations")
31988	urls += "?" + c.urlParams_.Encode()
31989	req, err := http.NewRequest("GET", urls, body)
31990	if err != nil {
31991		return nil, err
31992	}
31993	req.Header = reqHeaders
31994	googleapi.Expand(req.URL, map[string]string{
31995		"parent": c.parent,
31996	})
31997	return gensupport.SendRequest(c.ctx_, c.s.client, req)
31998}
31999
32000// Do executes the "dialogflow.projects.conversations.list" call.
32001// Exactly one of *GoogleCloudDialogflowV2ListConversationsResponse or
32002// error will be non-nil. Any non-2xx status code is an error. Response
32003// headers are in either
32004// *GoogleCloudDialogflowV2ListConversationsResponse.ServerResponse.Heade
32005// r or (if a response was returned at all) in
32006// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
32007// whether the returned error was because http.StatusNotModified was
32008// returned.
32009func (c *ProjectsConversationsListCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDialogflowV2ListConversationsResponse, error) {
32010	gensupport.SetOptions(c.urlParams_, opts...)
32011	res, err := c.doRequest("json")
32012	if res != nil && res.StatusCode == http.StatusNotModified {
32013		if res.Body != nil {
32014			res.Body.Close()
32015		}
32016		return nil, &googleapi.Error{
32017			Code:   res.StatusCode,
32018			Header: res.Header,
32019		}
32020	}
32021	if err != nil {
32022		return nil, err
32023	}
32024	defer googleapi.CloseBody(res)
32025	if err := googleapi.CheckResponse(res); err != nil {
32026		return nil, err
32027	}
32028	ret := &GoogleCloudDialogflowV2ListConversationsResponse{
32029		ServerResponse: googleapi.ServerResponse{
32030			Header:         res.Header,
32031			HTTPStatusCode: res.StatusCode,
32032		},
32033	}
32034	target := &ret
32035	if err := gensupport.DecodeResponse(target, res); err != nil {
32036		return nil, err
32037	}
32038	return ret, nil
32039	// {
32040	//   "description": "Returns the list of all conversations in the specified project.",
32041	//   "flatPath": "v2/projects/{projectsId}/conversations",
32042	//   "httpMethod": "GET",
32043	//   "id": "dialogflow.projects.conversations.list",
32044	//   "parameterOrder": [
32045	//     "parent"
32046	//   ],
32047	//   "parameters": {
32048	//     "filter": {
32049	//       "description": "A filter expression that filters conversations listed in the response. In general, the expression must specify the field name, a comparison operator, and the value to use for filtering: - The value must be a string, a number, or a boolean. - The comparison operator must be either `=`,`!=`, `\u003e`, or `\u003c`. - To filter on multiple expressions, separate the expressions with `AND` or `OR` (omitting both implies `AND`). - For clarity, expressions can be enclosed in parentheses. Only `lifecycle_state` can be filtered on in this way. For example, the following expression only returns `COMPLETED` conversations: `lifecycle_state = \"COMPLETED\"` For more information about filtering, see [API Filtering](https://aip.dev/160).",
32050	//       "location": "query",
32051	//       "type": "string"
32052	//     },
32053	//     "pageSize": {
32054	//       "description": "Optional. The maximum number of items to return in a single page. By default 100 and at most 1000.",
32055	//       "format": "int32",
32056	//       "location": "query",
32057	//       "type": "integer"
32058	//     },
32059	//     "pageToken": {
32060	//       "description": "Optional. The next_page_token value returned from a previous list request.",
32061	//       "location": "query",
32062	//       "type": "string"
32063	//     },
32064	//     "parent": {
32065	//       "description": "Required. The project from which to list all conversation. Format: `projects//locations/`.",
32066	//       "location": "path",
32067	//       "pattern": "^projects/[^/]+$",
32068	//       "required": true,
32069	//       "type": "string"
32070	//     }
32071	//   },
32072	//   "path": "v2/{+parent}/conversations",
32073	//   "response": {
32074	//     "$ref": "GoogleCloudDialogflowV2ListConversationsResponse"
32075	//   },
32076	//   "scopes": [
32077	//     "https://www.googleapis.com/auth/cloud-platform",
32078	//     "https://www.googleapis.com/auth/dialogflow"
32079	//   ]
32080	// }
32081
32082}
32083
32084// Pages invokes f for each page of results.
32085// A non-nil error returned from f will halt the iteration.
32086// The provided context supersedes any context provided to the Context method.
32087func (c *ProjectsConversationsListCall) Pages(ctx context.Context, f func(*GoogleCloudDialogflowV2ListConversationsResponse) error) error {
32088	c.ctx_ = ctx
32089	defer c.PageToken(c.urlParams_.Get("pageToken")) // reset paging to original point
32090	for {
32091		x, err := c.Do()
32092		if err != nil {
32093			return err
32094		}
32095		if err := f(x); err != nil {
32096			return err
32097		}
32098		if x.NextPageToken == "" {
32099			return nil
32100		}
32101		c.PageToken(x.NextPageToken)
32102	}
32103}
32104
32105// method id "dialogflow.projects.conversations.messages.list":
32106
32107type ProjectsConversationsMessagesListCall struct {
32108	s            *Service
32109	parent       string
32110	urlParams_   gensupport.URLParams
32111	ifNoneMatch_ string
32112	ctx_         context.Context
32113	header_      http.Header
32114}
32115
32116// List: Lists messages that belong to a given conversation. `messages`
32117// are ordered by `create_time` in descending order. To fetch updates
32118// without duplication, send request with filter
32119// `create_time_epoch_microseconds > [first item's create_time of
32120// previous request]` and empty page_token.
32121//
32122// - parent: The name of the conversation to list messages for. Format:
32123//   `projects//locations//conversations/`.
32124func (r *ProjectsConversationsMessagesService) List(parent string) *ProjectsConversationsMessagesListCall {
32125	c := &ProjectsConversationsMessagesListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
32126	c.parent = parent
32127	return c
32128}
32129
32130// Filter sets the optional parameter "filter": Filter on message
32131// fields. Currently predicates on `create_time` and
32132// `create_time_epoch_microseconds` are supported. `create_time` only
32133// support milliseconds accuracy. E.g., `create_time_epoch_microseconds
32134// > 1551790877964485` or `create_time > 2017-01-15T01:30:15.01Z`. For
32135// more information about filtering, see API Filtering
32136// (https://aip.dev/160).
32137func (c *ProjectsConversationsMessagesListCall) Filter(filter string) *ProjectsConversationsMessagesListCall {
32138	c.urlParams_.Set("filter", filter)
32139	return c
32140}
32141
32142// PageSize sets the optional parameter "pageSize": The maximum number
32143// of items to return in a single page. By default 100 and at most 1000.
32144func (c *ProjectsConversationsMessagesListCall) PageSize(pageSize int64) *ProjectsConversationsMessagesListCall {
32145	c.urlParams_.Set("pageSize", fmt.Sprint(pageSize))
32146	return c
32147}
32148
32149// PageToken sets the optional parameter "pageToken": The
32150// next_page_token value returned from a previous list request.
32151func (c *ProjectsConversationsMessagesListCall) PageToken(pageToken string) *ProjectsConversationsMessagesListCall {
32152	c.urlParams_.Set("pageToken", pageToken)
32153	return c
32154}
32155
32156// Fields allows partial responses to be retrieved. See
32157// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
32158// for more information.
32159func (c *ProjectsConversationsMessagesListCall) Fields(s ...googleapi.Field) *ProjectsConversationsMessagesListCall {
32160	c.urlParams_.Set("fields", googleapi.CombineFields(s))
32161	return c
32162}
32163
32164// IfNoneMatch sets the optional parameter which makes the operation
32165// fail if the object's ETag matches the given value. This is useful for
32166// getting updates only after the object has changed since the last
32167// request. Use googleapi.IsNotModified to check whether the response
32168// error from Do is the result of In-None-Match.
32169func (c *ProjectsConversationsMessagesListCall) IfNoneMatch(entityTag string) *ProjectsConversationsMessagesListCall {
32170	c.ifNoneMatch_ = entityTag
32171	return c
32172}
32173
32174// Context sets the context to be used in this call's Do method. Any
32175// pending HTTP request will be aborted if the provided context is
32176// canceled.
32177func (c *ProjectsConversationsMessagesListCall) Context(ctx context.Context) *ProjectsConversationsMessagesListCall {
32178	c.ctx_ = ctx
32179	return c
32180}
32181
32182// Header returns an http.Header that can be modified by the caller to
32183// add HTTP headers to the request.
32184func (c *ProjectsConversationsMessagesListCall) Header() http.Header {
32185	if c.header_ == nil {
32186		c.header_ = make(http.Header)
32187	}
32188	return c.header_
32189}
32190
32191func (c *ProjectsConversationsMessagesListCall) doRequest(alt string) (*http.Response, error) {
32192	reqHeaders := make(http.Header)
32193	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20211027")
32194	for k, v := range c.header_ {
32195		reqHeaders[k] = v
32196	}
32197	reqHeaders.Set("User-Agent", c.s.userAgent())
32198	if c.ifNoneMatch_ != "" {
32199		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
32200	}
32201	var body io.Reader = nil
32202	c.urlParams_.Set("alt", alt)
32203	c.urlParams_.Set("prettyPrint", "false")
32204	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+parent}/messages")
32205	urls += "?" + c.urlParams_.Encode()
32206	req, err := http.NewRequest("GET", urls, body)
32207	if err != nil {
32208		return nil, err
32209	}
32210	req.Header = reqHeaders
32211	googleapi.Expand(req.URL, map[string]string{
32212		"parent": c.parent,
32213	})
32214	return gensupport.SendRequest(c.ctx_, c.s.client, req)
32215}
32216
32217// Do executes the "dialogflow.projects.conversations.messages.list" call.
32218// Exactly one of *GoogleCloudDialogflowV2ListMessagesResponse or error
32219// will be non-nil. Any non-2xx status code is an error. Response
32220// headers are in either
32221// *GoogleCloudDialogflowV2ListMessagesResponse.ServerResponse.Header or
32222// (if a response was returned at all) in
32223// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
32224// whether the returned error was because http.StatusNotModified was
32225// returned.
32226func (c *ProjectsConversationsMessagesListCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDialogflowV2ListMessagesResponse, error) {
32227	gensupport.SetOptions(c.urlParams_, opts...)
32228	res, err := c.doRequest("json")
32229	if res != nil && res.StatusCode == http.StatusNotModified {
32230		if res.Body != nil {
32231			res.Body.Close()
32232		}
32233		return nil, &googleapi.Error{
32234			Code:   res.StatusCode,
32235			Header: res.Header,
32236		}
32237	}
32238	if err != nil {
32239		return nil, err
32240	}
32241	defer googleapi.CloseBody(res)
32242	if err := googleapi.CheckResponse(res); err != nil {
32243		return nil, err
32244	}
32245	ret := &GoogleCloudDialogflowV2ListMessagesResponse{
32246		ServerResponse: googleapi.ServerResponse{
32247			Header:         res.Header,
32248			HTTPStatusCode: res.StatusCode,
32249		},
32250	}
32251	target := &ret
32252	if err := gensupport.DecodeResponse(target, res); err != nil {
32253		return nil, err
32254	}
32255	return ret, nil
32256	// {
32257	//   "description": "Lists messages that belong to a given conversation. `messages` are ordered by `create_time` in descending order. To fetch updates without duplication, send request with filter `create_time_epoch_microseconds \u003e [first item's create_time of previous request]` and empty page_token.",
32258	//   "flatPath": "v2/projects/{projectsId}/conversations/{conversationsId}/messages",
32259	//   "httpMethod": "GET",
32260	//   "id": "dialogflow.projects.conversations.messages.list",
32261	//   "parameterOrder": [
32262	//     "parent"
32263	//   ],
32264	//   "parameters": {
32265	//     "filter": {
32266	//       "description": "Optional. Filter on message fields. Currently predicates on `create_time` and `create_time_epoch_microseconds` are supported. `create_time` only support milliseconds accuracy. E.g., `create_time_epoch_microseconds \u003e 1551790877964485` or `create_time \u003e 2017-01-15T01:30:15.01Z`. For more information about filtering, see [API Filtering](https://aip.dev/160).",
32267	//       "location": "query",
32268	//       "type": "string"
32269	//     },
32270	//     "pageSize": {
32271	//       "description": "Optional. The maximum number of items to return in a single page. By default 100 and at most 1000.",
32272	//       "format": "int32",
32273	//       "location": "query",
32274	//       "type": "integer"
32275	//     },
32276	//     "pageToken": {
32277	//       "description": "Optional. The next_page_token value returned from a previous list request.",
32278	//       "location": "query",
32279	//       "type": "string"
32280	//     },
32281	//     "parent": {
32282	//       "description": "Required. The name of the conversation to list messages for. Format: `projects//locations//conversations/`",
32283	//       "location": "path",
32284	//       "pattern": "^projects/[^/]+/conversations/[^/]+$",
32285	//       "required": true,
32286	//       "type": "string"
32287	//     }
32288	//   },
32289	//   "path": "v2/{+parent}/messages",
32290	//   "response": {
32291	//     "$ref": "GoogleCloudDialogflowV2ListMessagesResponse"
32292	//   },
32293	//   "scopes": [
32294	//     "https://www.googleapis.com/auth/cloud-platform",
32295	//     "https://www.googleapis.com/auth/dialogflow"
32296	//   ]
32297	// }
32298
32299}
32300
32301// Pages invokes f for each page of results.
32302// A non-nil error returned from f will halt the iteration.
32303// The provided context supersedes any context provided to the Context method.
32304func (c *ProjectsConversationsMessagesListCall) Pages(ctx context.Context, f func(*GoogleCloudDialogflowV2ListMessagesResponse) error) error {
32305	c.ctx_ = ctx
32306	defer c.PageToken(c.urlParams_.Get("pageToken")) // reset paging to original point
32307	for {
32308		x, err := c.Do()
32309		if err != nil {
32310			return err
32311		}
32312		if err := f(x); err != nil {
32313			return err
32314		}
32315		if x.NextPageToken == "" {
32316			return nil
32317		}
32318		c.PageToken(x.NextPageToken)
32319	}
32320}
32321
32322// method id "dialogflow.projects.conversations.participants.analyzeContent":
32323
32324type ProjectsConversationsParticipantsAnalyzeContentCall struct {
32325	s                                            *Service
32326	participant                                  string
32327	googleclouddialogflowv2analyzecontentrequest *GoogleCloudDialogflowV2AnalyzeContentRequest
32328	urlParams_                                   gensupport.URLParams
32329	ctx_                                         context.Context
32330	header_                                      http.Header
32331}
32332
32333// AnalyzeContent: Adds a text (chat, for example), or audio (phone
32334// recording, for example) message from a participant into the
32335// conversation. Note: Always use agent versions for production traffic
32336// sent to virtual agents. See Versions and environments
32337// (https://cloud.google.com/dialogflow/es/docs/agents-versions).
32338//
32339// - participant: The name of the participant this text comes from.
32340//   Format: `projects//locations//conversations//participants/`.
32341func (r *ProjectsConversationsParticipantsService) AnalyzeContent(participant string, googleclouddialogflowv2analyzecontentrequest *GoogleCloudDialogflowV2AnalyzeContentRequest) *ProjectsConversationsParticipantsAnalyzeContentCall {
32342	c := &ProjectsConversationsParticipantsAnalyzeContentCall{s: r.s, urlParams_: make(gensupport.URLParams)}
32343	c.participant = participant
32344	c.googleclouddialogflowv2analyzecontentrequest = googleclouddialogflowv2analyzecontentrequest
32345	return c
32346}
32347
32348// Fields allows partial responses to be retrieved. See
32349// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
32350// for more information.
32351func (c *ProjectsConversationsParticipantsAnalyzeContentCall) Fields(s ...googleapi.Field) *ProjectsConversationsParticipantsAnalyzeContentCall {
32352	c.urlParams_.Set("fields", googleapi.CombineFields(s))
32353	return c
32354}
32355
32356// Context sets the context to be used in this call's Do method. Any
32357// pending HTTP request will be aborted if the provided context is
32358// canceled.
32359func (c *ProjectsConversationsParticipantsAnalyzeContentCall) Context(ctx context.Context) *ProjectsConversationsParticipantsAnalyzeContentCall {
32360	c.ctx_ = ctx
32361	return c
32362}
32363
32364// Header returns an http.Header that can be modified by the caller to
32365// add HTTP headers to the request.
32366func (c *ProjectsConversationsParticipantsAnalyzeContentCall) Header() http.Header {
32367	if c.header_ == nil {
32368		c.header_ = make(http.Header)
32369	}
32370	return c.header_
32371}
32372
32373func (c *ProjectsConversationsParticipantsAnalyzeContentCall) doRequest(alt string) (*http.Response, error) {
32374	reqHeaders := make(http.Header)
32375	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20211027")
32376	for k, v := range c.header_ {
32377		reqHeaders[k] = v
32378	}
32379	reqHeaders.Set("User-Agent", c.s.userAgent())
32380	var body io.Reader = nil
32381	body, err := googleapi.WithoutDataWrapper.JSONReader(c.googleclouddialogflowv2analyzecontentrequest)
32382	if err != nil {
32383		return nil, err
32384	}
32385	reqHeaders.Set("Content-Type", "application/json")
32386	c.urlParams_.Set("alt", alt)
32387	c.urlParams_.Set("prettyPrint", "false")
32388	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+participant}:analyzeContent")
32389	urls += "?" + c.urlParams_.Encode()
32390	req, err := http.NewRequest("POST", urls, body)
32391	if err != nil {
32392		return nil, err
32393	}
32394	req.Header = reqHeaders
32395	googleapi.Expand(req.URL, map[string]string{
32396		"participant": c.participant,
32397	})
32398	return gensupport.SendRequest(c.ctx_, c.s.client, req)
32399}
32400
32401// Do executes the "dialogflow.projects.conversations.participants.analyzeContent" call.
32402// Exactly one of *GoogleCloudDialogflowV2AnalyzeContentResponse or
32403// error will be non-nil. Any non-2xx status code is an error. Response
32404// headers are in either
32405// *GoogleCloudDialogflowV2AnalyzeContentResponse.ServerResponse.Header
32406// or (if a response was returned at all) in
32407// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
32408// whether the returned error was because http.StatusNotModified was
32409// returned.
32410func (c *ProjectsConversationsParticipantsAnalyzeContentCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDialogflowV2AnalyzeContentResponse, error) {
32411	gensupport.SetOptions(c.urlParams_, opts...)
32412	res, err := c.doRequest("json")
32413	if res != nil && res.StatusCode == http.StatusNotModified {
32414		if res.Body != nil {
32415			res.Body.Close()
32416		}
32417		return nil, &googleapi.Error{
32418			Code:   res.StatusCode,
32419			Header: res.Header,
32420		}
32421	}
32422	if err != nil {
32423		return nil, err
32424	}
32425	defer googleapi.CloseBody(res)
32426	if err := googleapi.CheckResponse(res); err != nil {
32427		return nil, err
32428	}
32429	ret := &GoogleCloudDialogflowV2AnalyzeContentResponse{
32430		ServerResponse: googleapi.ServerResponse{
32431			Header:         res.Header,
32432			HTTPStatusCode: res.StatusCode,
32433		},
32434	}
32435	target := &ret
32436	if err := gensupport.DecodeResponse(target, res); err != nil {
32437		return nil, err
32438	}
32439	return ret, nil
32440	// {
32441	//   "description": "Adds a text (chat, for example), or audio (phone recording, for example) message from a participant into the conversation. Note: Always use agent versions for production traffic sent to virtual agents. See [Versions and environments](https://cloud.google.com/dialogflow/es/docs/agents-versions).",
32442	//   "flatPath": "v2/projects/{projectsId}/conversations/{conversationsId}/participants/{participantsId}:analyzeContent",
32443	//   "httpMethod": "POST",
32444	//   "id": "dialogflow.projects.conversations.participants.analyzeContent",
32445	//   "parameterOrder": [
32446	//     "participant"
32447	//   ],
32448	//   "parameters": {
32449	//     "participant": {
32450	//       "description": "Required. The name of the participant this text comes from. Format: `projects//locations//conversations//participants/`.",
32451	//       "location": "path",
32452	//       "pattern": "^projects/[^/]+/conversations/[^/]+/participants/[^/]+$",
32453	//       "required": true,
32454	//       "type": "string"
32455	//     }
32456	//   },
32457	//   "path": "v2/{+participant}:analyzeContent",
32458	//   "request": {
32459	//     "$ref": "GoogleCloudDialogflowV2AnalyzeContentRequest"
32460	//   },
32461	//   "response": {
32462	//     "$ref": "GoogleCloudDialogflowV2AnalyzeContentResponse"
32463	//   },
32464	//   "scopes": [
32465	//     "https://www.googleapis.com/auth/cloud-platform",
32466	//     "https://www.googleapis.com/auth/dialogflow"
32467	//   ]
32468	// }
32469
32470}
32471
32472// method id "dialogflow.projects.conversations.participants.create":
32473
32474type ProjectsConversationsParticipantsCreateCall struct {
32475	s                                  *Service
32476	parentid                           string
32477	googleclouddialogflowv2participant *GoogleCloudDialogflowV2Participant
32478	urlParams_                         gensupport.URLParams
32479	ctx_                               context.Context
32480	header_                            http.Header
32481}
32482
32483// Create: Creates a new participant in a conversation.
32484//
32485// - parent: Resource identifier of the conversation adding the
32486//   participant. Format: `projects//locations//conversations/`.
32487func (r *ProjectsConversationsParticipantsService) Create(parentid string, googleclouddialogflowv2participant *GoogleCloudDialogflowV2Participant) *ProjectsConversationsParticipantsCreateCall {
32488	c := &ProjectsConversationsParticipantsCreateCall{s: r.s, urlParams_: make(gensupport.URLParams)}
32489	c.parentid = parentid
32490	c.googleclouddialogflowv2participant = googleclouddialogflowv2participant
32491	return c
32492}
32493
32494// Fields allows partial responses to be retrieved. See
32495// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
32496// for more information.
32497func (c *ProjectsConversationsParticipantsCreateCall) Fields(s ...googleapi.Field) *ProjectsConversationsParticipantsCreateCall {
32498	c.urlParams_.Set("fields", googleapi.CombineFields(s))
32499	return c
32500}
32501
32502// Context sets the context to be used in this call's Do method. Any
32503// pending HTTP request will be aborted if the provided context is
32504// canceled.
32505func (c *ProjectsConversationsParticipantsCreateCall) Context(ctx context.Context) *ProjectsConversationsParticipantsCreateCall {
32506	c.ctx_ = ctx
32507	return c
32508}
32509
32510// Header returns an http.Header that can be modified by the caller to
32511// add HTTP headers to the request.
32512func (c *ProjectsConversationsParticipantsCreateCall) Header() http.Header {
32513	if c.header_ == nil {
32514		c.header_ = make(http.Header)
32515	}
32516	return c.header_
32517}
32518
32519func (c *ProjectsConversationsParticipantsCreateCall) doRequest(alt string) (*http.Response, error) {
32520	reqHeaders := make(http.Header)
32521	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20211027")
32522	for k, v := range c.header_ {
32523		reqHeaders[k] = v
32524	}
32525	reqHeaders.Set("User-Agent", c.s.userAgent())
32526	var body io.Reader = nil
32527	body, err := googleapi.WithoutDataWrapper.JSONReader(c.googleclouddialogflowv2participant)
32528	if err != nil {
32529		return nil, err
32530	}
32531	reqHeaders.Set("Content-Type", "application/json")
32532	c.urlParams_.Set("alt", alt)
32533	c.urlParams_.Set("prettyPrint", "false")
32534	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+parent}/participants")
32535	urls += "?" + c.urlParams_.Encode()
32536	req, err := http.NewRequest("POST", urls, body)
32537	if err != nil {
32538		return nil, err
32539	}
32540	req.Header = reqHeaders
32541	googleapi.Expand(req.URL, map[string]string{
32542		"parent": c.parentid,
32543	})
32544	return gensupport.SendRequest(c.ctx_, c.s.client, req)
32545}
32546
32547// Do executes the "dialogflow.projects.conversations.participants.create" call.
32548// Exactly one of *GoogleCloudDialogflowV2Participant or error will be
32549// non-nil. Any non-2xx status code is an error. Response headers are in
32550// either *GoogleCloudDialogflowV2Participant.ServerResponse.Header or
32551// (if a response was returned at all) in
32552// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
32553// whether the returned error was because http.StatusNotModified was
32554// returned.
32555func (c *ProjectsConversationsParticipantsCreateCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDialogflowV2Participant, error) {
32556	gensupport.SetOptions(c.urlParams_, opts...)
32557	res, err := c.doRequest("json")
32558	if res != nil && res.StatusCode == http.StatusNotModified {
32559		if res.Body != nil {
32560			res.Body.Close()
32561		}
32562		return nil, &googleapi.Error{
32563			Code:   res.StatusCode,
32564			Header: res.Header,
32565		}
32566	}
32567	if err != nil {
32568		return nil, err
32569	}
32570	defer googleapi.CloseBody(res)
32571	if err := googleapi.CheckResponse(res); err != nil {
32572		return nil, err
32573	}
32574	ret := &GoogleCloudDialogflowV2Participant{
32575		ServerResponse: googleapi.ServerResponse{
32576			Header:         res.Header,
32577			HTTPStatusCode: res.StatusCode,
32578		},
32579	}
32580	target := &ret
32581	if err := gensupport.DecodeResponse(target, res); err != nil {
32582		return nil, err
32583	}
32584	return ret, nil
32585	// {
32586	//   "description": "Creates a new participant in a conversation.",
32587	//   "flatPath": "v2/projects/{projectsId}/conversations/{conversationsId}/participants",
32588	//   "httpMethod": "POST",
32589	//   "id": "dialogflow.projects.conversations.participants.create",
32590	//   "parameterOrder": [
32591	//     "parent"
32592	//   ],
32593	//   "parameters": {
32594	//     "parent": {
32595	//       "description": "Required. Resource identifier of the conversation adding the participant. Format: `projects//locations//conversations/`.",
32596	//       "location": "path",
32597	//       "pattern": "^projects/[^/]+/conversations/[^/]+$",
32598	//       "required": true,
32599	//       "type": "string"
32600	//     }
32601	//   },
32602	//   "path": "v2/{+parent}/participants",
32603	//   "request": {
32604	//     "$ref": "GoogleCloudDialogflowV2Participant"
32605	//   },
32606	//   "response": {
32607	//     "$ref": "GoogleCloudDialogflowV2Participant"
32608	//   },
32609	//   "scopes": [
32610	//     "https://www.googleapis.com/auth/cloud-platform",
32611	//     "https://www.googleapis.com/auth/dialogflow"
32612	//   ]
32613	// }
32614
32615}
32616
32617// method id "dialogflow.projects.conversations.participants.get":
32618
32619type ProjectsConversationsParticipantsGetCall struct {
32620	s            *Service
32621	name         string
32622	urlParams_   gensupport.URLParams
32623	ifNoneMatch_ string
32624	ctx_         context.Context
32625	header_      http.Header
32626}
32627
32628// Get: Retrieves a conversation participant.
32629//
32630// - name: The name of the participant. Format:
32631//   `projects//locations//conversations//participants/`.
32632func (r *ProjectsConversationsParticipantsService) Get(name string) *ProjectsConversationsParticipantsGetCall {
32633	c := &ProjectsConversationsParticipantsGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
32634	c.name = name
32635	return c
32636}
32637
32638// Fields allows partial responses to be retrieved. See
32639// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
32640// for more information.
32641func (c *ProjectsConversationsParticipantsGetCall) Fields(s ...googleapi.Field) *ProjectsConversationsParticipantsGetCall {
32642	c.urlParams_.Set("fields", googleapi.CombineFields(s))
32643	return c
32644}
32645
32646// IfNoneMatch sets the optional parameter which makes the operation
32647// fail if the object's ETag matches the given value. This is useful for
32648// getting updates only after the object has changed since the last
32649// request. Use googleapi.IsNotModified to check whether the response
32650// error from Do is the result of In-None-Match.
32651func (c *ProjectsConversationsParticipantsGetCall) IfNoneMatch(entityTag string) *ProjectsConversationsParticipantsGetCall {
32652	c.ifNoneMatch_ = entityTag
32653	return c
32654}
32655
32656// Context sets the context to be used in this call's Do method. Any
32657// pending HTTP request will be aborted if the provided context is
32658// canceled.
32659func (c *ProjectsConversationsParticipantsGetCall) Context(ctx context.Context) *ProjectsConversationsParticipantsGetCall {
32660	c.ctx_ = ctx
32661	return c
32662}
32663
32664// Header returns an http.Header that can be modified by the caller to
32665// add HTTP headers to the request.
32666func (c *ProjectsConversationsParticipantsGetCall) Header() http.Header {
32667	if c.header_ == nil {
32668		c.header_ = make(http.Header)
32669	}
32670	return c.header_
32671}
32672
32673func (c *ProjectsConversationsParticipantsGetCall) doRequest(alt string) (*http.Response, error) {
32674	reqHeaders := make(http.Header)
32675	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20211027")
32676	for k, v := range c.header_ {
32677		reqHeaders[k] = v
32678	}
32679	reqHeaders.Set("User-Agent", c.s.userAgent())
32680	if c.ifNoneMatch_ != "" {
32681		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
32682	}
32683	var body io.Reader = nil
32684	c.urlParams_.Set("alt", alt)
32685	c.urlParams_.Set("prettyPrint", "false")
32686	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+name}")
32687	urls += "?" + c.urlParams_.Encode()
32688	req, err := http.NewRequest("GET", urls, body)
32689	if err != nil {
32690		return nil, err
32691	}
32692	req.Header = reqHeaders
32693	googleapi.Expand(req.URL, map[string]string{
32694		"name": c.name,
32695	})
32696	return gensupport.SendRequest(c.ctx_, c.s.client, req)
32697}
32698
32699// Do executes the "dialogflow.projects.conversations.participants.get" call.
32700// Exactly one of *GoogleCloudDialogflowV2Participant or error will be
32701// non-nil. Any non-2xx status code is an error. Response headers are in
32702// either *GoogleCloudDialogflowV2Participant.ServerResponse.Header or
32703// (if a response was returned at all) in
32704// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
32705// whether the returned error was because http.StatusNotModified was
32706// returned.
32707func (c *ProjectsConversationsParticipantsGetCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDialogflowV2Participant, error) {
32708	gensupport.SetOptions(c.urlParams_, opts...)
32709	res, err := c.doRequest("json")
32710	if res != nil && res.StatusCode == http.StatusNotModified {
32711		if res.Body != nil {
32712			res.Body.Close()
32713		}
32714		return nil, &googleapi.Error{
32715			Code:   res.StatusCode,
32716			Header: res.Header,
32717		}
32718	}
32719	if err != nil {
32720		return nil, err
32721	}
32722	defer googleapi.CloseBody(res)
32723	if err := googleapi.CheckResponse(res); err != nil {
32724		return nil, err
32725	}
32726	ret := &GoogleCloudDialogflowV2Participant{
32727		ServerResponse: googleapi.ServerResponse{
32728			Header:         res.Header,
32729			HTTPStatusCode: res.StatusCode,
32730		},
32731	}
32732	target := &ret
32733	if err := gensupport.DecodeResponse(target, res); err != nil {
32734		return nil, err
32735	}
32736	return ret, nil
32737	// {
32738	//   "description": "Retrieves a conversation participant.",
32739	//   "flatPath": "v2/projects/{projectsId}/conversations/{conversationsId}/participants/{participantsId}",
32740	//   "httpMethod": "GET",
32741	//   "id": "dialogflow.projects.conversations.participants.get",
32742	//   "parameterOrder": [
32743	//     "name"
32744	//   ],
32745	//   "parameters": {
32746	//     "name": {
32747	//       "description": "Required. The name of the participant. Format: `projects//locations//conversations//participants/`.",
32748	//       "location": "path",
32749	//       "pattern": "^projects/[^/]+/conversations/[^/]+/participants/[^/]+$",
32750	//       "required": true,
32751	//       "type": "string"
32752	//     }
32753	//   },
32754	//   "path": "v2/{+name}",
32755	//   "response": {
32756	//     "$ref": "GoogleCloudDialogflowV2Participant"
32757	//   },
32758	//   "scopes": [
32759	//     "https://www.googleapis.com/auth/cloud-platform",
32760	//     "https://www.googleapis.com/auth/dialogflow"
32761	//   ]
32762	// }
32763
32764}
32765
32766// method id "dialogflow.projects.conversations.participants.list":
32767
32768type ProjectsConversationsParticipantsListCall struct {
32769	s            *Service
32770	parent       string
32771	urlParams_   gensupport.URLParams
32772	ifNoneMatch_ string
32773	ctx_         context.Context
32774	header_      http.Header
32775}
32776
32777// List: Returns the list of all participants in the specified
32778// conversation.
32779//
32780// - parent: The conversation to list all participants from. Format:
32781//   `projects//locations//conversations/`.
32782func (r *ProjectsConversationsParticipantsService) List(parent string) *ProjectsConversationsParticipantsListCall {
32783	c := &ProjectsConversationsParticipantsListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
32784	c.parent = parent
32785	return c
32786}
32787
32788// PageSize sets the optional parameter "pageSize": The maximum number
32789// of items to return in a single page. By default 100 and at most 1000.
32790func (c *ProjectsConversationsParticipantsListCall) PageSize(pageSize int64) *ProjectsConversationsParticipantsListCall {
32791	c.urlParams_.Set("pageSize", fmt.Sprint(pageSize))
32792	return c
32793}
32794
32795// PageToken sets the optional parameter "pageToken": The
32796// next_page_token value returned from a previous list request.
32797func (c *ProjectsConversationsParticipantsListCall) PageToken(pageToken string) *ProjectsConversationsParticipantsListCall {
32798	c.urlParams_.Set("pageToken", pageToken)
32799	return c
32800}
32801
32802// Fields allows partial responses to be retrieved. See
32803// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
32804// for more information.
32805func (c *ProjectsConversationsParticipantsListCall) Fields(s ...googleapi.Field) *ProjectsConversationsParticipantsListCall {
32806	c.urlParams_.Set("fields", googleapi.CombineFields(s))
32807	return c
32808}
32809
32810// IfNoneMatch sets the optional parameter which makes the operation
32811// fail if the object's ETag matches the given value. This is useful for
32812// getting updates only after the object has changed since the last
32813// request. Use googleapi.IsNotModified to check whether the response
32814// error from Do is the result of In-None-Match.
32815func (c *ProjectsConversationsParticipantsListCall) IfNoneMatch(entityTag string) *ProjectsConversationsParticipantsListCall {
32816	c.ifNoneMatch_ = entityTag
32817	return c
32818}
32819
32820// Context sets the context to be used in this call's Do method. Any
32821// pending HTTP request will be aborted if the provided context is
32822// canceled.
32823func (c *ProjectsConversationsParticipantsListCall) Context(ctx context.Context) *ProjectsConversationsParticipantsListCall {
32824	c.ctx_ = ctx
32825	return c
32826}
32827
32828// Header returns an http.Header that can be modified by the caller to
32829// add HTTP headers to the request.
32830func (c *ProjectsConversationsParticipantsListCall) Header() http.Header {
32831	if c.header_ == nil {
32832		c.header_ = make(http.Header)
32833	}
32834	return c.header_
32835}
32836
32837func (c *ProjectsConversationsParticipantsListCall) doRequest(alt string) (*http.Response, error) {
32838	reqHeaders := make(http.Header)
32839	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20211027")
32840	for k, v := range c.header_ {
32841		reqHeaders[k] = v
32842	}
32843	reqHeaders.Set("User-Agent", c.s.userAgent())
32844	if c.ifNoneMatch_ != "" {
32845		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
32846	}
32847	var body io.Reader = nil
32848	c.urlParams_.Set("alt", alt)
32849	c.urlParams_.Set("prettyPrint", "false")
32850	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+parent}/participants")
32851	urls += "?" + c.urlParams_.Encode()
32852	req, err := http.NewRequest("GET", urls, body)
32853	if err != nil {
32854		return nil, err
32855	}
32856	req.Header = reqHeaders
32857	googleapi.Expand(req.URL, map[string]string{
32858		"parent": c.parent,
32859	})
32860	return gensupport.SendRequest(c.ctx_, c.s.client, req)
32861}
32862
32863// Do executes the "dialogflow.projects.conversations.participants.list" call.
32864// Exactly one of *GoogleCloudDialogflowV2ListParticipantsResponse or
32865// error will be non-nil. Any non-2xx status code is an error. Response
32866// headers are in either
32867// *GoogleCloudDialogflowV2ListParticipantsResponse.ServerResponse.Header
32868//  or (if a response was returned at all) in
32869// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
32870// whether the returned error was because http.StatusNotModified was
32871// returned.
32872func (c *ProjectsConversationsParticipantsListCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDialogflowV2ListParticipantsResponse, error) {
32873	gensupport.SetOptions(c.urlParams_, opts...)
32874	res, err := c.doRequest("json")
32875	if res != nil && res.StatusCode == http.StatusNotModified {
32876		if res.Body != nil {
32877			res.Body.Close()
32878		}
32879		return nil, &googleapi.Error{
32880			Code:   res.StatusCode,
32881			Header: res.Header,
32882		}
32883	}
32884	if err != nil {
32885		return nil, err
32886	}
32887	defer googleapi.CloseBody(res)
32888	if err := googleapi.CheckResponse(res); err != nil {
32889		return nil, err
32890	}
32891	ret := &GoogleCloudDialogflowV2ListParticipantsResponse{
32892		ServerResponse: googleapi.ServerResponse{
32893			Header:         res.Header,
32894			HTTPStatusCode: res.StatusCode,
32895		},
32896	}
32897	target := &ret
32898	if err := gensupport.DecodeResponse(target, res); err != nil {
32899		return nil, err
32900	}
32901	return ret, nil
32902	// {
32903	//   "description": "Returns the list of all participants in the specified conversation.",
32904	//   "flatPath": "v2/projects/{projectsId}/conversations/{conversationsId}/participants",
32905	//   "httpMethod": "GET",
32906	//   "id": "dialogflow.projects.conversations.participants.list",
32907	//   "parameterOrder": [
32908	//     "parent"
32909	//   ],
32910	//   "parameters": {
32911	//     "pageSize": {
32912	//       "description": "Optional. The maximum number of items to return in a single page. By default 100 and at most 1000.",
32913	//       "format": "int32",
32914	//       "location": "query",
32915	//       "type": "integer"
32916	//     },
32917	//     "pageToken": {
32918	//       "description": "Optional. The next_page_token value returned from a previous list request.",
32919	//       "location": "query",
32920	//       "type": "string"
32921	//     },
32922	//     "parent": {
32923	//       "description": "Required. The conversation to list all participants from. Format: `projects//locations//conversations/`.",
32924	//       "location": "path",
32925	//       "pattern": "^projects/[^/]+/conversations/[^/]+$",
32926	//       "required": true,
32927	//       "type": "string"
32928	//     }
32929	//   },
32930	//   "path": "v2/{+parent}/participants",
32931	//   "response": {
32932	//     "$ref": "GoogleCloudDialogflowV2ListParticipantsResponse"
32933	//   },
32934	//   "scopes": [
32935	//     "https://www.googleapis.com/auth/cloud-platform",
32936	//     "https://www.googleapis.com/auth/dialogflow"
32937	//   ]
32938	// }
32939
32940}
32941
32942// Pages invokes f for each page of results.
32943// A non-nil error returned from f will halt the iteration.
32944// The provided context supersedes any context provided to the Context method.
32945func (c *ProjectsConversationsParticipantsListCall) Pages(ctx context.Context, f func(*GoogleCloudDialogflowV2ListParticipantsResponse) error) error {
32946	c.ctx_ = ctx
32947	defer c.PageToken(c.urlParams_.Get("pageToken")) // reset paging to original point
32948	for {
32949		x, err := c.Do()
32950		if err != nil {
32951			return err
32952		}
32953		if err := f(x); err != nil {
32954			return err
32955		}
32956		if x.NextPageToken == "" {
32957			return nil
32958		}
32959		c.PageToken(x.NextPageToken)
32960	}
32961}
32962
32963// method id "dialogflow.projects.conversations.participants.patch":
32964
32965type ProjectsConversationsParticipantsPatchCall struct {
32966	s                                  *Service
32967	nameid                             string
32968	googleclouddialogflowv2participant *GoogleCloudDialogflowV2Participant
32969	urlParams_                         gensupport.URLParams
32970	ctx_                               context.Context
32971	header_                            http.Header
32972}
32973
32974// Patch: Updates the specified participant.
32975//
32976// - name: Optional. The unique identifier of this participant. Format:
32977//   `projects//locations//conversations//participants/`.
32978func (r *ProjectsConversationsParticipantsService) Patch(nameid string, googleclouddialogflowv2participant *GoogleCloudDialogflowV2Participant) *ProjectsConversationsParticipantsPatchCall {
32979	c := &ProjectsConversationsParticipantsPatchCall{s: r.s, urlParams_: make(gensupport.URLParams)}
32980	c.nameid = nameid
32981	c.googleclouddialogflowv2participant = googleclouddialogflowv2participant
32982	return c
32983}
32984
32985// UpdateMask sets the optional parameter "updateMask": Required. The
32986// mask to specify which fields to update.
32987func (c *ProjectsConversationsParticipantsPatchCall) UpdateMask(updateMask string) *ProjectsConversationsParticipantsPatchCall {
32988	c.urlParams_.Set("updateMask", updateMask)
32989	return c
32990}
32991
32992// Fields allows partial responses to be retrieved. See
32993// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
32994// for more information.
32995func (c *ProjectsConversationsParticipantsPatchCall) Fields(s ...googleapi.Field) *ProjectsConversationsParticipantsPatchCall {
32996	c.urlParams_.Set("fields", googleapi.CombineFields(s))
32997	return c
32998}
32999
33000// Context sets the context to be used in this call's Do method. Any
33001// pending HTTP request will be aborted if the provided context is
33002// canceled.
33003func (c *ProjectsConversationsParticipantsPatchCall) Context(ctx context.Context) *ProjectsConversationsParticipantsPatchCall {
33004	c.ctx_ = ctx
33005	return c
33006}
33007
33008// Header returns an http.Header that can be modified by the caller to
33009// add HTTP headers to the request.
33010func (c *ProjectsConversationsParticipantsPatchCall) Header() http.Header {
33011	if c.header_ == nil {
33012		c.header_ = make(http.Header)
33013	}
33014	return c.header_
33015}
33016
33017func (c *ProjectsConversationsParticipantsPatchCall) doRequest(alt string) (*http.Response, error) {
33018	reqHeaders := make(http.Header)
33019	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20211027")
33020	for k, v := range c.header_ {
33021		reqHeaders[k] = v
33022	}
33023	reqHeaders.Set("User-Agent", c.s.userAgent())
33024	var body io.Reader = nil
33025	body, err := googleapi.WithoutDataWrapper.JSONReader(c.googleclouddialogflowv2participant)
33026	if err != nil {
33027		return nil, err
33028	}
33029	reqHeaders.Set("Content-Type", "application/json")
33030	c.urlParams_.Set("alt", alt)
33031	c.urlParams_.Set("prettyPrint", "false")
33032	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+name}")
33033	urls += "?" + c.urlParams_.Encode()
33034	req, err := http.NewRequest("PATCH", urls, body)
33035	if err != nil {
33036		return nil, err
33037	}
33038	req.Header = reqHeaders
33039	googleapi.Expand(req.URL, map[string]string{
33040		"name": c.nameid,
33041	})
33042	return gensupport.SendRequest(c.ctx_, c.s.client, req)
33043}
33044
33045// Do executes the "dialogflow.projects.conversations.participants.patch" call.
33046// Exactly one of *GoogleCloudDialogflowV2Participant or error will be
33047// non-nil. Any non-2xx status code is an error. Response headers are in
33048// either *GoogleCloudDialogflowV2Participant.ServerResponse.Header or
33049// (if a response was returned at all) in
33050// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
33051// whether the returned error was because http.StatusNotModified was
33052// returned.
33053func (c *ProjectsConversationsParticipantsPatchCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDialogflowV2Participant, error) {
33054	gensupport.SetOptions(c.urlParams_, opts...)
33055	res, err := c.doRequest("json")
33056	if res != nil && res.StatusCode == http.StatusNotModified {
33057		if res.Body != nil {
33058			res.Body.Close()
33059		}
33060		return nil, &googleapi.Error{
33061			Code:   res.StatusCode,
33062			Header: res.Header,
33063		}
33064	}
33065	if err != nil {
33066		return nil, err
33067	}
33068	defer googleapi.CloseBody(res)
33069	if err := googleapi.CheckResponse(res); err != nil {
33070		return nil, err
33071	}
33072	ret := &GoogleCloudDialogflowV2Participant{
33073		ServerResponse: googleapi.ServerResponse{
33074			Header:         res.Header,
33075			HTTPStatusCode: res.StatusCode,
33076		},
33077	}
33078	target := &ret
33079	if err := gensupport.DecodeResponse(target, res); err != nil {
33080		return nil, err
33081	}
33082	return ret, nil
33083	// {
33084	//   "description": "Updates the specified participant.",
33085	//   "flatPath": "v2/projects/{projectsId}/conversations/{conversationsId}/participants/{participantsId}",
33086	//   "httpMethod": "PATCH",
33087	//   "id": "dialogflow.projects.conversations.participants.patch",
33088	//   "parameterOrder": [
33089	//     "name"
33090	//   ],
33091	//   "parameters": {
33092	//     "name": {
33093	//       "description": "Optional. The unique identifier of this participant. Format: `projects//locations//conversations//participants/`.",
33094	//       "location": "path",
33095	//       "pattern": "^projects/[^/]+/conversations/[^/]+/participants/[^/]+$",
33096	//       "required": true,
33097	//       "type": "string"
33098	//     },
33099	//     "updateMask": {
33100	//       "description": "Required. The mask to specify which fields to update.",
33101	//       "format": "google-fieldmask",
33102	//       "location": "query",
33103	//       "type": "string"
33104	//     }
33105	//   },
33106	//   "path": "v2/{+name}",
33107	//   "request": {
33108	//     "$ref": "GoogleCloudDialogflowV2Participant"
33109	//   },
33110	//   "response": {
33111	//     "$ref": "GoogleCloudDialogflowV2Participant"
33112	//   },
33113	//   "scopes": [
33114	//     "https://www.googleapis.com/auth/cloud-platform",
33115	//     "https://www.googleapis.com/auth/dialogflow"
33116	//   ]
33117	// }
33118
33119}
33120
33121// method id "dialogflow.projects.conversations.participants.suggestions.suggestArticles":
33122
33123type ProjectsConversationsParticipantsSuggestionsSuggestArticlesCall struct {
33124	s                                             *Service
33125	parent                                        string
33126	googleclouddialogflowv2suggestarticlesrequest *GoogleCloudDialogflowV2SuggestArticlesRequest
33127	urlParams_                                    gensupport.URLParams
33128	ctx_                                          context.Context
33129	header_                                       http.Header
33130}
33131
33132// SuggestArticles: Gets suggested articles for a participant based on
33133// specific historical messages.
33134//
33135// - parent: The name of the participant to fetch suggestion for.
33136//   Format: `projects//locations//conversations//participants/`.
33137func (r *ProjectsConversationsParticipantsSuggestionsService) SuggestArticles(parent string, googleclouddialogflowv2suggestarticlesrequest *GoogleCloudDialogflowV2SuggestArticlesRequest) *ProjectsConversationsParticipantsSuggestionsSuggestArticlesCall {
33138	c := &ProjectsConversationsParticipantsSuggestionsSuggestArticlesCall{s: r.s, urlParams_: make(gensupport.URLParams)}
33139	c.parent = parent
33140	c.googleclouddialogflowv2suggestarticlesrequest = googleclouddialogflowv2suggestarticlesrequest
33141	return c
33142}
33143
33144// Fields allows partial responses to be retrieved. See
33145// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
33146// for more information.
33147func (c *ProjectsConversationsParticipantsSuggestionsSuggestArticlesCall) Fields(s ...googleapi.Field) *ProjectsConversationsParticipantsSuggestionsSuggestArticlesCall {
33148	c.urlParams_.Set("fields", googleapi.CombineFields(s))
33149	return c
33150}
33151
33152// Context sets the context to be used in this call's Do method. Any
33153// pending HTTP request will be aborted if the provided context is
33154// canceled.
33155func (c *ProjectsConversationsParticipantsSuggestionsSuggestArticlesCall) Context(ctx context.Context) *ProjectsConversationsParticipantsSuggestionsSuggestArticlesCall {
33156	c.ctx_ = ctx
33157	return c
33158}
33159
33160// Header returns an http.Header that can be modified by the caller to
33161// add HTTP headers to the request.
33162func (c *ProjectsConversationsParticipantsSuggestionsSuggestArticlesCall) Header() http.Header {
33163	if c.header_ == nil {
33164		c.header_ = make(http.Header)
33165	}
33166	return c.header_
33167}
33168
33169func (c *ProjectsConversationsParticipantsSuggestionsSuggestArticlesCall) doRequest(alt string) (*http.Response, error) {
33170	reqHeaders := make(http.Header)
33171	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20211027")
33172	for k, v := range c.header_ {
33173		reqHeaders[k] = v
33174	}
33175	reqHeaders.Set("User-Agent", c.s.userAgent())
33176	var body io.Reader = nil
33177	body, err := googleapi.WithoutDataWrapper.JSONReader(c.googleclouddialogflowv2suggestarticlesrequest)
33178	if err != nil {
33179		return nil, err
33180	}
33181	reqHeaders.Set("Content-Type", "application/json")
33182	c.urlParams_.Set("alt", alt)
33183	c.urlParams_.Set("prettyPrint", "false")
33184	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+parent}/suggestions:suggestArticles")
33185	urls += "?" + c.urlParams_.Encode()
33186	req, err := http.NewRequest("POST", urls, body)
33187	if err != nil {
33188		return nil, err
33189	}
33190	req.Header = reqHeaders
33191	googleapi.Expand(req.URL, map[string]string{
33192		"parent": c.parent,
33193	})
33194	return gensupport.SendRequest(c.ctx_, c.s.client, req)
33195}
33196
33197// Do executes the "dialogflow.projects.conversations.participants.suggestions.suggestArticles" call.
33198// Exactly one of *GoogleCloudDialogflowV2SuggestArticlesResponse or
33199// error will be non-nil. Any non-2xx status code is an error. Response
33200// headers are in either
33201// *GoogleCloudDialogflowV2SuggestArticlesResponse.ServerResponse.Header
33202// or (if a response was returned at all) in
33203// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
33204// whether the returned error was because http.StatusNotModified was
33205// returned.
33206func (c *ProjectsConversationsParticipantsSuggestionsSuggestArticlesCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDialogflowV2SuggestArticlesResponse, error) {
33207	gensupport.SetOptions(c.urlParams_, opts...)
33208	res, err := c.doRequest("json")
33209	if res != nil && res.StatusCode == http.StatusNotModified {
33210		if res.Body != nil {
33211			res.Body.Close()
33212		}
33213		return nil, &googleapi.Error{
33214			Code:   res.StatusCode,
33215			Header: res.Header,
33216		}
33217	}
33218	if err != nil {
33219		return nil, err
33220	}
33221	defer googleapi.CloseBody(res)
33222	if err := googleapi.CheckResponse(res); err != nil {
33223		return nil, err
33224	}
33225	ret := &GoogleCloudDialogflowV2SuggestArticlesResponse{
33226		ServerResponse: googleapi.ServerResponse{
33227			Header:         res.Header,
33228			HTTPStatusCode: res.StatusCode,
33229		},
33230	}
33231	target := &ret
33232	if err := gensupport.DecodeResponse(target, res); err != nil {
33233		return nil, err
33234	}
33235	return ret, nil
33236	// {
33237	//   "description": "Gets suggested articles for a participant based on specific historical messages.",
33238	//   "flatPath": "v2/projects/{projectsId}/conversations/{conversationsId}/participants/{participantsId}/suggestions:suggestArticles",
33239	//   "httpMethod": "POST",
33240	//   "id": "dialogflow.projects.conversations.participants.suggestions.suggestArticles",
33241	//   "parameterOrder": [
33242	//     "parent"
33243	//   ],
33244	//   "parameters": {
33245	//     "parent": {
33246	//       "description": "Required. The name of the participant to fetch suggestion for. Format: `projects//locations//conversations//participants/`.",
33247	//       "location": "path",
33248	//       "pattern": "^projects/[^/]+/conversations/[^/]+/participants/[^/]+$",
33249	//       "required": true,
33250	//       "type": "string"
33251	//     }
33252	//   },
33253	//   "path": "v2/{+parent}/suggestions:suggestArticles",
33254	//   "request": {
33255	//     "$ref": "GoogleCloudDialogflowV2SuggestArticlesRequest"
33256	//   },
33257	//   "response": {
33258	//     "$ref": "GoogleCloudDialogflowV2SuggestArticlesResponse"
33259	//   },
33260	//   "scopes": [
33261	//     "https://www.googleapis.com/auth/cloud-platform",
33262	//     "https://www.googleapis.com/auth/dialogflow"
33263	//   ]
33264	// }
33265
33266}
33267
33268// method id "dialogflow.projects.conversations.participants.suggestions.suggestFaqAnswers":
33269
33270type ProjectsConversationsParticipantsSuggestionsSuggestFaqAnswersCall struct {
33271	s                                               *Service
33272	parent                                          string
33273	googleclouddialogflowv2suggestfaqanswersrequest *GoogleCloudDialogflowV2SuggestFaqAnswersRequest
33274	urlParams_                                      gensupport.URLParams
33275	ctx_                                            context.Context
33276	header_                                         http.Header
33277}
33278
33279// SuggestFaqAnswers: Gets suggested faq answers for a participant based
33280// on specific historical messages.
33281//
33282// - parent: The name of the participant to fetch suggestion for.
33283//   Format: `projects//locations//conversations//participants/`.
33284func (r *ProjectsConversationsParticipantsSuggestionsService) SuggestFaqAnswers(parent string, googleclouddialogflowv2suggestfaqanswersrequest *GoogleCloudDialogflowV2SuggestFaqAnswersRequest) *ProjectsConversationsParticipantsSuggestionsSuggestFaqAnswersCall {
33285	c := &ProjectsConversationsParticipantsSuggestionsSuggestFaqAnswersCall{s: r.s, urlParams_: make(gensupport.URLParams)}
33286	c.parent = parent
33287	c.googleclouddialogflowv2suggestfaqanswersrequest = googleclouddialogflowv2suggestfaqanswersrequest
33288	return c
33289}
33290
33291// Fields allows partial responses to be retrieved. See
33292// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
33293// for more information.
33294func (c *ProjectsConversationsParticipantsSuggestionsSuggestFaqAnswersCall) Fields(s ...googleapi.Field) *ProjectsConversationsParticipantsSuggestionsSuggestFaqAnswersCall {
33295	c.urlParams_.Set("fields", googleapi.CombineFields(s))
33296	return c
33297}
33298
33299// Context sets the context to be used in this call's Do method. Any
33300// pending HTTP request will be aborted if the provided context is
33301// canceled.
33302func (c *ProjectsConversationsParticipantsSuggestionsSuggestFaqAnswersCall) Context(ctx context.Context) *ProjectsConversationsParticipantsSuggestionsSuggestFaqAnswersCall {
33303	c.ctx_ = ctx
33304	return c
33305}
33306
33307// Header returns an http.Header that can be modified by the caller to
33308// add HTTP headers to the request.
33309func (c *ProjectsConversationsParticipantsSuggestionsSuggestFaqAnswersCall) Header() http.Header {
33310	if c.header_ == nil {
33311		c.header_ = make(http.Header)
33312	}
33313	return c.header_
33314}
33315
33316func (c *ProjectsConversationsParticipantsSuggestionsSuggestFaqAnswersCall) doRequest(alt string) (*http.Response, error) {
33317	reqHeaders := make(http.Header)
33318	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20211027")
33319	for k, v := range c.header_ {
33320		reqHeaders[k] = v
33321	}
33322	reqHeaders.Set("User-Agent", c.s.userAgent())
33323	var body io.Reader = nil
33324	body, err := googleapi.WithoutDataWrapper.JSONReader(c.googleclouddialogflowv2suggestfaqanswersrequest)
33325	if err != nil {
33326		return nil, err
33327	}
33328	reqHeaders.Set("Content-Type", "application/json")
33329	c.urlParams_.Set("alt", alt)
33330	c.urlParams_.Set("prettyPrint", "false")
33331	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+parent}/suggestions:suggestFaqAnswers")
33332	urls += "?" + c.urlParams_.Encode()
33333	req, err := http.NewRequest("POST", urls, body)
33334	if err != nil {
33335		return nil, err
33336	}
33337	req.Header = reqHeaders
33338	googleapi.Expand(req.URL, map[string]string{
33339		"parent": c.parent,
33340	})
33341	return gensupport.SendRequest(c.ctx_, c.s.client, req)
33342}
33343
33344// Do executes the "dialogflow.projects.conversations.participants.suggestions.suggestFaqAnswers" call.
33345// Exactly one of *GoogleCloudDialogflowV2SuggestFaqAnswersResponse or
33346// error will be non-nil. Any non-2xx status code is an error. Response
33347// headers are in either
33348// *GoogleCloudDialogflowV2SuggestFaqAnswersResponse.ServerResponse.Heade
33349// r or (if a response was returned at all) in
33350// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
33351// whether the returned error was because http.StatusNotModified was
33352// returned.
33353func (c *ProjectsConversationsParticipantsSuggestionsSuggestFaqAnswersCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDialogflowV2SuggestFaqAnswersResponse, error) {
33354	gensupport.SetOptions(c.urlParams_, opts...)
33355	res, err := c.doRequest("json")
33356	if res != nil && res.StatusCode == http.StatusNotModified {
33357		if res.Body != nil {
33358			res.Body.Close()
33359		}
33360		return nil, &googleapi.Error{
33361			Code:   res.StatusCode,
33362			Header: res.Header,
33363		}
33364	}
33365	if err != nil {
33366		return nil, err
33367	}
33368	defer googleapi.CloseBody(res)
33369	if err := googleapi.CheckResponse(res); err != nil {
33370		return nil, err
33371	}
33372	ret := &GoogleCloudDialogflowV2SuggestFaqAnswersResponse{
33373		ServerResponse: googleapi.ServerResponse{
33374			Header:         res.Header,
33375			HTTPStatusCode: res.StatusCode,
33376		},
33377	}
33378	target := &ret
33379	if err := gensupport.DecodeResponse(target, res); err != nil {
33380		return nil, err
33381	}
33382	return ret, nil
33383	// {
33384	//   "description": "Gets suggested faq answers for a participant based on specific historical messages.",
33385	//   "flatPath": "v2/projects/{projectsId}/conversations/{conversationsId}/participants/{participantsId}/suggestions:suggestFaqAnswers",
33386	//   "httpMethod": "POST",
33387	//   "id": "dialogflow.projects.conversations.participants.suggestions.suggestFaqAnswers",
33388	//   "parameterOrder": [
33389	//     "parent"
33390	//   ],
33391	//   "parameters": {
33392	//     "parent": {
33393	//       "description": "Required. The name of the participant to fetch suggestion for. Format: `projects//locations//conversations//participants/`.",
33394	//       "location": "path",
33395	//       "pattern": "^projects/[^/]+/conversations/[^/]+/participants/[^/]+$",
33396	//       "required": true,
33397	//       "type": "string"
33398	//     }
33399	//   },
33400	//   "path": "v2/{+parent}/suggestions:suggestFaqAnswers",
33401	//   "request": {
33402	//     "$ref": "GoogleCloudDialogflowV2SuggestFaqAnswersRequest"
33403	//   },
33404	//   "response": {
33405	//     "$ref": "GoogleCloudDialogflowV2SuggestFaqAnswersResponse"
33406	//   },
33407	//   "scopes": [
33408	//     "https://www.googleapis.com/auth/cloud-platform",
33409	//     "https://www.googleapis.com/auth/dialogflow"
33410	//   ]
33411	// }
33412
33413}
33414
33415// method id "dialogflow.projects.knowledgeBases.create":
33416
33417type ProjectsKnowledgeBasesCreateCall struct {
33418	s                                    *Service
33419	parent                               string
33420	googleclouddialogflowv2knowledgebase *GoogleCloudDialogflowV2KnowledgeBase
33421	urlParams_                           gensupport.URLParams
33422	ctx_                                 context.Context
33423	header_                              http.Header
33424}
33425
33426// Create: Creates a knowledge base.
33427//
33428// - parent: The project to create a knowledge base for. Format:
33429//   `projects//locations/`.
33430func (r *ProjectsKnowledgeBasesService) Create(parent string, googleclouddialogflowv2knowledgebase *GoogleCloudDialogflowV2KnowledgeBase) *ProjectsKnowledgeBasesCreateCall {
33431	c := &ProjectsKnowledgeBasesCreateCall{s: r.s, urlParams_: make(gensupport.URLParams)}
33432	c.parent = parent
33433	c.googleclouddialogflowv2knowledgebase = googleclouddialogflowv2knowledgebase
33434	return c
33435}
33436
33437// Fields allows partial responses to be retrieved. See
33438// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
33439// for more information.
33440func (c *ProjectsKnowledgeBasesCreateCall) Fields(s ...googleapi.Field) *ProjectsKnowledgeBasesCreateCall {
33441	c.urlParams_.Set("fields", googleapi.CombineFields(s))
33442	return c
33443}
33444
33445// Context sets the context to be used in this call's Do method. Any
33446// pending HTTP request will be aborted if the provided context is
33447// canceled.
33448func (c *ProjectsKnowledgeBasesCreateCall) Context(ctx context.Context) *ProjectsKnowledgeBasesCreateCall {
33449	c.ctx_ = ctx
33450	return c
33451}
33452
33453// Header returns an http.Header that can be modified by the caller to
33454// add HTTP headers to the request.
33455func (c *ProjectsKnowledgeBasesCreateCall) Header() http.Header {
33456	if c.header_ == nil {
33457		c.header_ = make(http.Header)
33458	}
33459	return c.header_
33460}
33461
33462func (c *ProjectsKnowledgeBasesCreateCall) doRequest(alt string) (*http.Response, error) {
33463	reqHeaders := make(http.Header)
33464	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20211027")
33465	for k, v := range c.header_ {
33466		reqHeaders[k] = v
33467	}
33468	reqHeaders.Set("User-Agent", c.s.userAgent())
33469	var body io.Reader = nil
33470	body, err := googleapi.WithoutDataWrapper.JSONReader(c.googleclouddialogflowv2knowledgebase)
33471	if err != nil {
33472		return nil, err
33473	}
33474	reqHeaders.Set("Content-Type", "application/json")
33475	c.urlParams_.Set("alt", alt)
33476	c.urlParams_.Set("prettyPrint", "false")
33477	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+parent}/knowledgeBases")
33478	urls += "?" + c.urlParams_.Encode()
33479	req, err := http.NewRequest("POST", urls, body)
33480	if err != nil {
33481		return nil, err
33482	}
33483	req.Header = reqHeaders
33484	googleapi.Expand(req.URL, map[string]string{
33485		"parent": c.parent,
33486	})
33487	return gensupport.SendRequest(c.ctx_, c.s.client, req)
33488}
33489
33490// Do executes the "dialogflow.projects.knowledgeBases.create" call.
33491// Exactly one of *GoogleCloudDialogflowV2KnowledgeBase or error will be
33492// non-nil. Any non-2xx status code is an error. Response headers are in
33493// either *GoogleCloudDialogflowV2KnowledgeBase.ServerResponse.Header or
33494// (if a response was returned at all) in
33495// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
33496// whether the returned error was because http.StatusNotModified was
33497// returned.
33498func (c *ProjectsKnowledgeBasesCreateCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDialogflowV2KnowledgeBase, error) {
33499	gensupport.SetOptions(c.urlParams_, opts...)
33500	res, err := c.doRequest("json")
33501	if res != nil && res.StatusCode == http.StatusNotModified {
33502		if res.Body != nil {
33503			res.Body.Close()
33504		}
33505		return nil, &googleapi.Error{
33506			Code:   res.StatusCode,
33507			Header: res.Header,
33508		}
33509	}
33510	if err != nil {
33511		return nil, err
33512	}
33513	defer googleapi.CloseBody(res)
33514	if err := googleapi.CheckResponse(res); err != nil {
33515		return nil, err
33516	}
33517	ret := &GoogleCloudDialogflowV2KnowledgeBase{
33518		ServerResponse: googleapi.ServerResponse{
33519			Header:         res.Header,
33520			HTTPStatusCode: res.StatusCode,
33521		},
33522	}
33523	target := &ret
33524	if err := gensupport.DecodeResponse(target, res); err != nil {
33525		return nil, err
33526	}
33527	return ret, nil
33528	// {
33529	//   "description": "Creates a knowledge base.",
33530	//   "flatPath": "v2/projects/{projectsId}/knowledgeBases",
33531	//   "httpMethod": "POST",
33532	//   "id": "dialogflow.projects.knowledgeBases.create",
33533	//   "parameterOrder": [
33534	//     "parent"
33535	//   ],
33536	//   "parameters": {
33537	//     "parent": {
33538	//       "description": "Required. The project to create a knowledge base for. Format: `projects//locations/`.",
33539	//       "location": "path",
33540	//       "pattern": "^projects/[^/]+$",
33541	//       "required": true,
33542	//       "type": "string"
33543	//     }
33544	//   },
33545	//   "path": "v2/{+parent}/knowledgeBases",
33546	//   "request": {
33547	//     "$ref": "GoogleCloudDialogflowV2KnowledgeBase"
33548	//   },
33549	//   "response": {
33550	//     "$ref": "GoogleCloudDialogflowV2KnowledgeBase"
33551	//   },
33552	//   "scopes": [
33553	//     "https://www.googleapis.com/auth/cloud-platform",
33554	//     "https://www.googleapis.com/auth/dialogflow"
33555	//   ]
33556	// }
33557
33558}
33559
33560// method id "dialogflow.projects.knowledgeBases.delete":
33561
33562type ProjectsKnowledgeBasesDeleteCall struct {
33563	s          *Service
33564	name       string
33565	urlParams_ gensupport.URLParams
33566	ctx_       context.Context
33567	header_    http.Header
33568}
33569
33570// Delete: Deletes the specified knowledge base.
33571//
33572// - name: The name of the knowledge base to delete. Format:
33573//   `projects//locations//knowledgeBases/`.
33574func (r *ProjectsKnowledgeBasesService) Delete(name string) *ProjectsKnowledgeBasesDeleteCall {
33575	c := &ProjectsKnowledgeBasesDeleteCall{s: r.s, urlParams_: make(gensupport.URLParams)}
33576	c.name = name
33577	return c
33578}
33579
33580// Force sets the optional parameter "force": Force deletes the
33581// knowledge base. When set to true, any documents in the knowledge base
33582// are also deleted.
33583func (c *ProjectsKnowledgeBasesDeleteCall) Force(force bool) *ProjectsKnowledgeBasesDeleteCall {
33584	c.urlParams_.Set("force", fmt.Sprint(force))
33585	return c
33586}
33587
33588// Fields allows partial responses to be retrieved. See
33589// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
33590// for more information.
33591func (c *ProjectsKnowledgeBasesDeleteCall) Fields(s ...googleapi.Field) *ProjectsKnowledgeBasesDeleteCall {
33592	c.urlParams_.Set("fields", googleapi.CombineFields(s))
33593	return c
33594}
33595
33596// Context sets the context to be used in this call's Do method. Any
33597// pending HTTP request will be aborted if the provided context is
33598// canceled.
33599func (c *ProjectsKnowledgeBasesDeleteCall) Context(ctx context.Context) *ProjectsKnowledgeBasesDeleteCall {
33600	c.ctx_ = ctx
33601	return c
33602}
33603
33604// Header returns an http.Header that can be modified by the caller to
33605// add HTTP headers to the request.
33606func (c *ProjectsKnowledgeBasesDeleteCall) Header() http.Header {
33607	if c.header_ == nil {
33608		c.header_ = make(http.Header)
33609	}
33610	return c.header_
33611}
33612
33613func (c *ProjectsKnowledgeBasesDeleteCall) doRequest(alt string) (*http.Response, error) {
33614	reqHeaders := make(http.Header)
33615	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20211027")
33616	for k, v := range c.header_ {
33617		reqHeaders[k] = v
33618	}
33619	reqHeaders.Set("User-Agent", c.s.userAgent())
33620	var body io.Reader = nil
33621	c.urlParams_.Set("alt", alt)
33622	c.urlParams_.Set("prettyPrint", "false")
33623	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+name}")
33624	urls += "?" + c.urlParams_.Encode()
33625	req, err := http.NewRequest("DELETE", urls, body)
33626	if err != nil {
33627		return nil, err
33628	}
33629	req.Header = reqHeaders
33630	googleapi.Expand(req.URL, map[string]string{
33631		"name": c.name,
33632	})
33633	return gensupport.SendRequest(c.ctx_, c.s.client, req)
33634}
33635
33636// Do executes the "dialogflow.projects.knowledgeBases.delete" call.
33637// Exactly one of *GoogleProtobufEmpty or error will be non-nil. Any
33638// non-2xx status code is an error. Response headers are in either
33639// *GoogleProtobufEmpty.ServerResponse.Header or (if a response was
33640// returned at all) in error.(*googleapi.Error).Header. Use
33641// googleapi.IsNotModified to check whether the returned error was
33642// because http.StatusNotModified was returned.
33643func (c *ProjectsKnowledgeBasesDeleteCall) Do(opts ...googleapi.CallOption) (*GoogleProtobufEmpty, error) {
33644	gensupport.SetOptions(c.urlParams_, opts...)
33645	res, err := c.doRequest("json")
33646	if res != nil && res.StatusCode == http.StatusNotModified {
33647		if res.Body != nil {
33648			res.Body.Close()
33649		}
33650		return nil, &googleapi.Error{
33651			Code:   res.StatusCode,
33652			Header: res.Header,
33653		}
33654	}
33655	if err != nil {
33656		return nil, err
33657	}
33658	defer googleapi.CloseBody(res)
33659	if err := googleapi.CheckResponse(res); err != nil {
33660		return nil, err
33661	}
33662	ret := &GoogleProtobufEmpty{
33663		ServerResponse: googleapi.ServerResponse{
33664			Header:         res.Header,
33665			HTTPStatusCode: res.StatusCode,
33666		},
33667	}
33668	target := &ret
33669	if err := gensupport.DecodeResponse(target, res); err != nil {
33670		return nil, err
33671	}
33672	return ret, nil
33673	// {
33674	//   "description": "Deletes the specified knowledge base.",
33675	//   "flatPath": "v2/projects/{projectsId}/knowledgeBases/{knowledgeBasesId}",
33676	//   "httpMethod": "DELETE",
33677	//   "id": "dialogflow.projects.knowledgeBases.delete",
33678	//   "parameterOrder": [
33679	//     "name"
33680	//   ],
33681	//   "parameters": {
33682	//     "force": {
33683	//       "description": "Optional. Force deletes the knowledge base. When set to true, any documents in the knowledge base are also deleted.",
33684	//       "location": "query",
33685	//       "type": "boolean"
33686	//     },
33687	//     "name": {
33688	//       "description": "Required. The name of the knowledge base to delete. Format: `projects//locations//knowledgeBases/`.",
33689	//       "location": "path",
33690	//       "pattern": "^projects/[^/]+/knowledgeBases/[^/]+$",
33691	//       "required": true,
33692	//       "type": "string"
33693	//     }
33694	//   },
33695	//   "path": "v2/{+name}",
33696	//   "response": {
33697	//     "$ref": "GoogleProtobufEmpty"
33698	//   },
33699	//   "scopes": [
33700	//     "https://www.googleapis.com/auth/cloud-platform",
33701	//     "https://www.googleapis.com/auth/dialogflow"
33702	//   ]
33703	// }
33704
33705}
33706
33707// method id "dialogflow.projects.knowledgeBases.get":
33708
33709type ProjectsKnowledgeBasesGetCall struct {
33710	s            *Service
33711	name         string
33712	urlParams_   gensupport.URLParams
33713	ifNoneMatch_ string
33714	ctx_         context.Context
33715	header_      http.Header
33716}
33717
33718// Get: Retrieves the specified knowledge base.
33719//
33720// - name: The name of the knowledge base to retrieve. Format
33721//   `projects//locations//knowledgeBases/`.
33722func (r *ProjectsKnowledgeBasesService) Get(name string) *ProjectsKnowledgeBasesGetCall {
33723	c := &ProjectsKnowledgeBasesGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
33724	c.name = name
33725	return c
33726}
33727
33728// Fields allows partial responses to be retrieved. See
33729// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
33730// for more information.
33731func (c *ProjectsKnowledgeBasesGetCall) Fields(s ...googleapi.Field) *ProjectsKnowledgeBasesGetCall {
33732	c.urlParams_.Set("fields", googleapi.CombineFields(s))
33733	return c
33734}
33735
33736// IfNoneMatch sets the optional parameter which makes the operation
33737// fail if the object's ETag matches the given value. This is useful for
33738// getting updates only after the object has changed since the last
33739// request. Use googleapi.IsNotModified to check whether the response
33740// error from Do is the result of In-None-Match.
33741func (c *ProjectsKnowledgeBasesGetCall) IfNoneMatch(entityTag string) *ProjectsKnowledgeBasesGetCall {
33742	c.ifNoneMatch_ = entityTag
33743	return c
33744}
33745
33746// Context sets the context to be used in this call's Do method. Any
33747// pending HTTP request will be aborted if the provided context is
33748// canceled.
33749func (c *ProjectsKnowledgeBasesGetCall) Context(ctx context.Context) *ProjectsKnowledgeBasesGetCall {
33750	c.ctx_ = ctx
33751	return c
33752}
33753
33754// Header returns an http.Header that can be modified by the caller to
33755// add HTTP headers to the request.
33756func (c *ProjectsKnowledgeBasesGetCall) Header() http.Header {
33757	if c.header_ == nil {
33758		c.header_ = make(http.Header)
33759	}
33760	return c.header_
33761}
33762
33763func (c *ProjectsKnowledgeBasesGetCall) doRequest(alt string) (*http.Response, error) {
33764	reqHeaders := make(http.Header)
33765	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20211027")
33766	for k, v := range c.header_ {
33767		reqHeaders[k] = v
33768	}
33769	reqHeaders.Set("User-Agent", c.s.userAgent())
33770	if c.ifNoneMatch_ != "" {
33771		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
33772	}
33773	var body io.Reader = nil
33774	c.urlParams_.Set("alt", alt)
33775	c.urlParams_.Set("prettyPrint", "false")
33776	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+name}")
33777	urls += "?" + c.urlParams_.Encode()
33778	req, err := http.NewRequest("GET", urls, body)
33779	if err != nil {
33780		return nil, err
33781	}
33782	req.Header = reqHeaders
33783	googleapi.Expand(req.URL, map[string]string{
33784		"name": c.name,
33785	})
33786	return gensupport.SendRequest(c.ctx_, c.s.client, req)
33787}
33788
33789// Do executes the "dialogflow.projects.knowledgeBases.get" call.
33790// Exactly one of *GoogleCloudDialogflowV2KnowledgeBase or error will be
33791// non-nil. Any non-2xx status code is an error. Response headers are in
33792// either *GoogleCloudDialogflowV2KnowledgeBase.ServerResponse.Header or
33793// (if a response was returned at all) in
33794// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
33795// whether the returned error was because http.StatusNotModified was
33796// returned.
33797func (c *ProjectsKnowledgeBasesGetCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDialogflowV2KnowledgeBase, error) {
33798	gensupport.SetOptions(c.urlParams_, opts...)
33799	res, err := c.doRequest("json")
33800	if res != nil && res.StatusCode == http.StatusNotModified {
33801		if res.Body != nil {
33802			res.Body.Close()
33803		}
33804		return nil, &googleapi.Error{
33805			Code:   res.StatusCode,
33806			Header: res.Header,
33807		}
33808	}
33809	if err != nil {
33810		return nil, err
33811	}
33812	defer googleapi.CloseBody(res)
33813	if err := googleapi.CheckResponse(res); err != nil {
33814		return nil, err
33815	}
33816	ret := &GoogleCloudDialogflowV2KnowledgeBase{
33817		ServerResponse: googleapi.ServerResponse{
33818			Header:         res.Header,
33819			HTTPStatusCode: res.StatusCode,
33820		},
33821	}
33822	target := &ret
33823	if err := gensupport.DecodeResponse(target, res); err != nil {
33824		return nil, err
33825	}
33826	return ret, nil
33827	// {
33828	//   "description": "Retrieves the specified knowledge base.",
33829	//   "flatPath": "v2/projects/{projectsId}/knowledgeBases/{knowledgeBasesId}",
33830	//   "httpMethod": "GET",
33831	//   "id": "dialogflow.projects.knowledgeBases.get",
33832	//   "parameterOrder": [
33833	//     "name"
33834	//   ],
33835	//   "parameters": {
33836	//     "name": {
33837	//       "description": "Required. The name of the knowledge base to retrieve. Format `projects//locations//knowledgeBases/`.",
33838	//       "location": "path",
33839	//       "pattern": "^projects/[^/]+/knowledgeBases/[^/]+$",
33840	//       "required": true,
33841	//       "type": "string"
33842	//     }
33843	//   },
33844	//   "path": "v2/{+name}",
33845	//   "response": {
33846	//     "$ref": "GoogleCloudDialogflowV2KnowledgeBase"
33847	//   },
33848	//   "scopes": [
33849	//     "https://www.googleapis.com/auth/cloud-platform",
33850	//     "https://www.googleapis.com/auth/dialogflow"
33851	//   ]
33852	// }
33853
33854}
33855
33856// method id "dialogflow.projects.knowledgeBases.list":
33857
33858type ProjectsKnowledgeBasesListCall struct {
33859	s            *Service
33860	parent       string
33861	urlParams_   gensupport.URLParams
33862	ifNoneMatch_ string
33863	ctx_         context.Context
33864	header_      http.Header
33865}
33866
33867// List: Returns the list of all knowledge bases of the specified agent.
33868//
33869// - parent: The project to list of knowledge bases for. Format:
33870//   `projects//locations/`.
33871func (r *ProjectsKnowledgeBasesService) List(parent string) *ProjectsKnowledgeBasesListCall {
33872	c := &ProjectsKnowledgeBasesListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
33873	c.parent = parent
33874	return c
33875}
33876
33877// PageSize sets the optional parameter "pageSize": The maximum number
33878// of items to return in a single page. By default 10 and at most 100.
33879func (c *ProjectsKnowledgeBasesListCall) PageSize(pageSize int64) *ProjectsKnowledgeBasesListCall {
33880	c.urlParams_.Set("pageSize", fmt.Sprint(pageSize))
33881	return c
33882}
33883
33884// PageToken sets the optional parameter "pageToken": The
33885// next_page_token value returned from a previous list request.
33886func (c *ProjectsKnowledgeBasesListCall) PageToken(pageToken string) *ProjectsKnowledgeBasesListCall {
33887	c.urlParams_.Set("pageToken", pageToken)
33888	return c
33889}
33890
33891// Fields allows partial responses to be retrieved. See
33892// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
33893// for more information.
33894func (c *ProjectsKnowledgeBasesListCall) Fields(s ...googleapi.Field) *ProjectsKnowledgeBasesListCall {
33895	c.urlParams_.Set("fields", googleapi.CombineFields(s))
33896	return c
33897}
33898
33899// IfNoneMatch sets the optional parameter which makes the operation
33900// fail if the object's ETag matches the given value. This is useful for
33901// getting updates only after the object has changed since the last
33902// request. Use googleapi.IsNotModified to check whether the response
33903// error from Do is the result of In-None-Match.
33904func (c *ProjectsKnowledgeBasesListCall) IfNoneMatch(entityTag string) *ProjectsKnowledgeBasesListCall {
33905	c.ifNoneMatch_ = entityTag
33906	return c
33907}
33908
33909// Context sets the context to be used in this call's Do method. Any
33910// pending HTTP request will be aborted if the provided context is
33911// canceled.
33912func (c *ProjectsKnowledgeBasesListCall) Context(ctx context.Context) *ProjectsKnowledgeBasesListCall {
33913	c.ctx_ = ctx
33914	return c
33915}
33916
33917// Header returns an http.Header that can be modified by the caller to
33918// add HTTP headers to the request.
33919func (c *ProjectsKnowledgeBasesListCall) Header() http.Header {
33920	if c.header_ == nil {
33921		c.header_ = make(http.Header)
33922	}
33923	return c.header_
33924}
33925
33926func (c *ProjectsKnowledgeBasesListCall) doRequest(alt string) (*http.Response, error) {
33927	reqHeaders := make(http.Header)
33928	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20211027")
33929	for k, v := range c.header_ {
33930		reqHeaders[k] = v
33931	}
33932	reqHeaders.Set("User-Agent", c.s.userAgent())
33933	if c.ifNoneMatch_ != "" {
33934		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
33935	}
33936	var body io.Reader = nil
33937	c.urlParams_.Set("alt", alt)
33938	c.urlParams_.Set("prettyPrint", "false")
33939	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+parent}/knowledgeBases")
33940	urls += "?" + c.urlParams_.Encode()
33941	req, err := http.NewRequest("GET", urls, body)
33942	if err != nil {
33943		return nil, err
33944	}
33945	req.Header = reqHeaders
33946	googleapi.Expand(req.URL, map[string]string{
33947		"parent": c.parent,
33948	})
33949	return gensupport.SendRequest(c.ctx_, c.s.client, req)
33950}
33951
33952// Do executes the "dialogflow.projects.knowledgeBases.list" call.
33953// Exactly one of *GoogleCloudDialogflowV2ListKnowledgeBasesResponse or
33954// error will be non-nil. Any non-2xx status code is an error. Response
33955// headers are in either
33956// *GoogleCloudDialogflowV2ListKnowledgeBasesResponse.ServerResponse.Head
33957// er or (if a response was returned at all) in
33958// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
33959// whether the returned error was because http.StatusNotModified was
33960// returned.
33961func (c *ProjectsKnowledgeBasesListCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDialogflowV2ListKnowledgeBasesResponse, error) {
33962	gensupport.SetOptions(c.urlParams_, opts...)
33963	res, err := c.doRequest("json")
33964	if res != nil && res.StatusCode == http.StatusNotModified {
33965		if res.Body != nil {
33966			res.Body.Close()
33967		}
33968		return nil, &googleapi.Error{
33969			Code:   res.StatusCode,
33970			Header: res.Header,
33971		}
33972	}
33973	if err != nil {
33974		return nil, err
33975	}
33976	defer googleapi.CloseBody(res)
33977	if err := googleapi.CheckResponse(res); err != nil {
33978		return nil, err
33979	}
33980	ret := &GoogleCloudDialogflowV2ListKnowledgeBasesResponse{
33981		ServerResponse: googleapi.ServerResponse{
33982			Header:         res.Header,
33983			HTTPStatusCode: res.StatusCode,
33984		},
33985	}
33986	target := &ret
33987	if err := gensupport.DecodeResponse(target, res); err != nil {
33988		return nil, err
33989	}
33990	return ret, nil
33991	// {
33992	//   "description": "Returns the list of all knowledge bases of the specified agent.",
33993	//   "flatPath": "v2/projects/{projectsId}/knowledgeBases",
33994	//   "httpMethod": "GET",
33995	//   "id": "dialogflow.projects.knowledgeBases.list",
33996	//   "parameterOrder": [
33997	//     "parent"
33998	//   ],
33999	//   "parameters": {
34000	//     "pageSize": {
34001	//       "description": "The maximum number of items to return in a single page. By default 10 and at most 100.",
34002	//       "format": "int32",
34003	//       "location": "query",
34004	//       "type": "integer"
34005	//     },
34006	//     "pageToken": {
34007	//       "description": "The next_page_token value returned from a previous list request.",
34008	//       "location": "query",
34009	//       "type": "string"
34010	//     },
34011	//     "parent": {
34012	//       "description": "Required. The project to list of knowledge bases for. Format: `projects//locations/`.",
34013	//       "location": "path",
34014	//       "pattern": "^projects/[^/]+$",
34015	//       "required": true,
34016	//       "type": "string"
34017	//     }
34018	//   },
34019	//   "path": "v2/{+parent}/knowledgeBases",
34020	//   "response": {
34021	//     "$ref": "GoogleCloudDialogflowV2ListKnowledgeBasesResponse"
34022	//   },
34023	//   "scopes": [
34024	//     "https://www.googleapis.com/auth/cloud-platform",
34025	//     "https://www.googleapis.com/auth/dialogflow"
34026	//   ]
34027	// }
34028
34029}
34030
34031// Pages invokes f for each page of results.
34032// A non-nil error returned from f will halt the iteration.
34033// The provided context supersedes any context provided to the Context method.
34034func (c *ProjectsKnowledgeBasesListCall) Pages(ctx context.Context, f func(*GoogleCloudDialogflowV2ListKnowledgeBasesResponse) error) error {
34035	c.ctx_ = ctx
34036	defer c.PageToken(c.urlParams_.Get("pageToken")) // reset paging to original point
34037	for {
34038		x, err := c.Do()
34039		if err != nil {
34040			return err
34041		}
34042		if err := f(x); err != nil {
34043			return err
34044		}
34045		if x.NextPageToken == "" {
34046			return nil
34047		}
34048		c.PageToken(x.NextPageToken)
34049	}
34050}
34051
34052// method id "dialogflow.projects.knowledgeBases.patch":
34053
34054type ProjectsKnowledgeBasesPatchCall struct {
34055	s                                    *Service
34056	name                                 string
34057	googleclouddialogflowv2knowledgebase *GoogleCloudDialogflowV2KnowledgeBase
34058	urlParams_                           gensupport.URLParams
34059	ctx_                                 context.Context
34060	header_                              http.Header
34061}
34062
34063// Patch: Updates the specified knowledge base.
34064//
34065// - name: The knowledge base resource name. The name must be empty when
34066//   creating a knowledge base. Format:
34067//   `projects//locations//knowledgeBases/`.
34068func (r *ProjectsKnowledgeBasesService) Patch(name string, googleclouddialogflowv2knowledgebase *GoogleCloudDialogflowV2KnowledgeBase) *ProjectsKnowledgeBasesPatchCall {
34069	c := &ProjectsKnowledgeBasesPatchCall{s: r.s, urlParams_: make(gensupport.URLParams)}
34070	c.name = name
34071	c.googleclouddialogflowv2knowledgebase = googleclouddialogflowv2knowledgebase
34072	return c
34073}
34074
34075// UpdateMask sets the optional parameter "updateMask": Not specified
34076// means `update all`. Currently, only `display_name` can be updated, an
34077// InvalidArgument will be returned for attempting to update other
34078// fields.
34079func (c *ProjectsKnowledgeBasesPatchCall) UpdateMask(updateMask string) *ProjectsKnowledgeBasesPatchCall {
34080	c.urlParams_.Set("updateMask", updateMask)
34081	return c
34082}
34083
34084// Fields allows partial responses to be retrieved. See
34085// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
34086// for more information.
34087func (c *ProjectsKnowledgeBasesPatchCall) Fields(s ...googleapi.Field) *ProjectsKnowledgeBasesPatchCall {
34088	c.urlParams_.Set("fields", googleapi.CombineFields(s))
34089	return c
34090}
34091
34092// Context sets the context to be used in this call's Do method. Any
34093// pending HTTP request will be aborted if the provided context is
34094// canceled.
34095func (c *ProjectsKnowledgeBasesPatchCall) Context(ctx context.Context) *ProjectsKnowledgeBasesPatchCall {
34096	c.ctx_ = ctx
34097	return c
34098}
34099
34100// Header returns an http.Header that can be modified by the caller to
34101// add HTTP headers to the request.
34102func (c *ProjectsKnowledgeBasesPatchCall) Header() http.Header {
34103	if c.header_ == nil {
34104		c.header_ = make(http.Header)
34105	}
34106	return c.header_
34107}
34108
34109func (c *ProjectsKnowledgeBasesPatchCall) doRequest(alt string) (*http.Response, error) {
34110	reqHeaders := make(http.Header)
34111	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20211027")
34112	for k, v := range c.header_ {
34113		reqHeaders[k] = v
34114	}
34115	reqHeaders.Set("User-Agent", c.s.userAgent())
34116	var body io.Reader = nil
34117	body, err := googleapi.WithoutDataWrapper.JSONReader(c.googleclouddialogflowv2knowledgebase)
34118	if err != nil {
34119		return nil, err
34120	}
34121	reqHeaders.Set("Content-Type", "application/json")
34122	c.urlParams_.Set("alt", alt)
34123	c.urlParams_.Set("prettyPrint", "false")
34124	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+name}")
34125	urls += "?" + c.urlParams_.Encode()
34126	req, err := http.NewRequest("PATCH", urls, body)
34127	if err != nil {
34128		return nil, err
34129	}
34130	req.Header = reqHeaders
34131	googleapi.Expand(req.URL, map[string]string{
34132		"name": c.name,
34133	})
34134	return gensupport.SendRequest(c.ctx_, c.s.client, req)
34135}
34136
34137// Do executes the "dialogflow.projects.knowledgeBases.patch" call.
34138// Exactly one of *GoogleCloudDialogflowV2KnowledgeBase or error will be
34139// non-nil. Any non-2xx status code is an error. Response headers are in
34140// either *GoogleCloudDialogflowV2KnowledgeBase.ServerResponse.Header or
34141// (if a response was returned at all) in
34142// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
34143// whether the returned error was because http.StatusNotModified was
34144// returned.
34145func (c *ProjectsKnowledgeBasesPatchCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDialogflowV2KnowledgeBase, error) {
34146	gensupport.SetOptions(c.urlParams_, opts...)
34147	res, err := c.doRequest("json")
34148	if res != nil && res.StatusCode == http.StatusNotModified {
34149		if res.Body != nil {
34150			res.Body.Close()
34151		}
34152		return nil, &googleapi.Error{
34153			Code:   res.StatusCode,
34154			Header: res.Header,
34155		}
34156	}
34157	if err != nil {
34158		return nil, err
34159	}
34160	defer googleapi.CloseBody(res)
34161	if err := googleapi.CheckResponse(res); err != nil {
34162		return nil, err
34163	}
34164	ret := &GoogleCloudDialogflowV2KnowledgeBase{
34165		ServerResponse: googleapi.ServerResponse{
34166			Header:         res.Header,
34167			HTTPStatusCode: res.StatusCode,
34168		},
34169	}
34170	target := &ret
34171	if err := gensupport.DecodeResponse(target, res); err != nil {
34172		return nil, err
34173	}
34174	return ret, nil
34175	// {
34176	//   "description": "Updates the specified knowledge base.",
34177	//   "flatPath": "v2/projects/{projectsId}/knowledgeBases/{knowledgeBasesId}",
34178	//   "httpMethod": "PATCH",
34179	//   "id": "dialogflow.projects.knowledgeBases.patch",
34180	//   "parameterOrder": [
34181	//     "name"
34182	//   ],
34183	//   "parameters": {
34184	//     "name": {
34185	//       "description": "The knowledge base resource name. The name must be empty when creating a knowledge base. Format: `projects//locations//knowledgeBases/`.",
34186	//       "location": "path",
34187	//       "pattern": "^projects/[^/]+/knowledgeBases/[^/]+$",
34188	//       "required": true,
34189	//       "type": "string"
34190	//     },
34191	//     "updateMask": {
34192	//       "description": "Optional. Not specified means `update all`. Currently, only `display_name` can be updated, an InvalidArgument will be returned for attempting to update other fields.",
34193	//       "format": "google-fieldmask",
34194	//       "location": "query",
34195	//       "type": "string"
34196	//     }
34197	//   },
34198	//   "path": "v2/{+name}",
34199	//   "request": {
34200	//     "$ref": "GoogleCloudDialogflowV2KnowledgeBase"
34201	//   },
34202	//   "response": {
34203	//     "$ref": "GoogleCloudDialogflowV2KnowledgeBase"
34204	//   },
34205	//   "scopes": [
34206	//     "https://www.googleapis.com/auth/cloud-platform",
34207	//     "https://www.googleapis.com/auth/dialogflow"
34208	//   ]
34209	// }
34210
34211}
34212
34213// method id "dialogflow.projects.knowledgeBases.documents.create":
34214
34215type ProjectsKnowledgeBasesDocumentsCreateCall struct {
34216	s                               *Service
34217	parent                          string
34218	googleclouddialogflowv2document *GoogleCloudDialogflowV2Document
34219	urlParams_                      gensupport.URLParams
34220	ctx_                            context.Context
34221	header_                         http.Header
34222}
34223
34224// Create: Creates a new document. This method is a long-running
34225// operation
34226// (https://cloud.google.com/dialogflow/cx/docs/how/long-running-operation).
34227// The returned `Operation` type has the following method-specific
34228// fields: - `metadata`: KnowledgeOperationMetadata - `response`:
34229// Document
34230//
34231// - parent: The knowledge base to create a document for. Format:
34232//   `projects//locations//knowledgeBases/`.
34233func (r *ProjectsKnowledgeBasesDocumentsService) Create(parent string, googleclouddialogflowv2document *GoogleCloudDialogflowV2Document) *ProjectsKnowledgeBasesDocumentsCreateCall {
34234	c := &ProjectsKnowledgeBasesDocumentsCreateCall{s: r.s, urlParams_: make(gensupport.URLParams)}
34235	c.parent = parent
34236	c.googleclouddialogflowv2document = googleclouddialogflowv2document
34237	return c
34238}
34239
34240// Fields allows partial responses to be retrieved. See
34241// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
34242// for more information.
34243func (c *ProjectsKnowledgeBasesDocumentsCreateCall) Fields(s ...googleapi.Field) *ProjectsKnowledgeBasesDocumentsCreateCall {
34244	c.urlParams_.Set("fields", googleapi.CombineFields(s))
34245	return c
34246}
34247
34248// Context sets the context to be used in this call's Do method. Any
34249// pending HTTP request will be aborted if the provided context is
34250// canceled.
34251func (c *ProjectsKnowledgeBasesDocumentsCreateCall) Context(ctx context.Context) *ProjectsKnowledgeBasesDocumentsCreateCall {
34252	c.ctx_ = ctx
34253	return c
34254}
34255
34256// Header returns an http.Header that can be modified by the caller to
34257// add HTTP headers to the request.
34258func (c *ProjectsKnowledgeBasesDocumentsCreateCall) Header() http.Header {
34259	if c.header_ == nil {
34260		c.header_ = make(http.Header)
34261	}
34262	return c.header_
34263}
34264
34265func (c *ProjectsKnowledgeBasesDocumentsCreateCall) doRequest(alt string) (*http.Response, error) {
34266	reqHeaders := make(http.Header)
34267	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20211027")
34268	for k, v := range c.header_ {
34269		reqHeaders[k] = v
34270	}
34271	reqHeaders.Set("User-Agent", c.s.userAgent())
34272	var body io.Reader = nil
34273	body, err := googleapi.WithoutDataWrapper.JSONReader(c.googleclouddialogflowv2document)
34274	if err != nil {
34275		return nil, err
34276	}
34277	reqHeaders.Set("Content-Type", "application/json")
34278	c.urlParams_.Set("alt", alt)
34279	c.urlParams_.Set("prettyPrint", "false")
34280	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+parent}/documents")
34281	urls += "?" + c.urlParams_.Encode()
34282	req, err := http.NewRequest("POST", urls, body)
34283	if err != nil {
34284		return nil, err
34285	}
34286	req.Header = reqHeaders
34287	googleapi.Expand(req.URL, map[string]string{
34288		"parent": c.parent,
34289	})
34290	return gensupport.SendRequest(c.ctx_, c.s.client, req)
34291}
34292
34293// Do executes the "dialogflow.projects.knowledgeBases.documents.create" call.
34294// Exactly one of *GoogleLongrunningOperation or error will be non-nil.
34295// Any non-2xx status code is an error. Response headers are in either
34296// *GoogleLongrunningOperation.ServerResponse.Header or (if a response
34297// was returned at all) in error.(*googleapi.Error).Header. Use
34298// googleapi.IsNotModified to check whether the returned error was
34299// because http.StatusNotModified was returned.
34300func (c *ProjectsKnowledgeBasesDocumentsCreateCall) Do(opts ...googleapi.CallOption) (*GoogleLongrunningOperation, error) {
34301	gensupport.SetOptions(c.urlParams_, opts...)
34302	res, err := c.doRequest("json")
34303	if res != nil && res.StatusCode == http.StatusNotModified {
34304		if res.Body != nil {
34305			res.Body.Close()
34306		}
34307		return nil, &googleapi.Error{
34308			Code:   res.StatusCode,
34309			Header: res.Header,
34310		}
34311	}
34312	if err != nil {
34313		return nil, err
34314	}
34315	defer googleapi.CloseBody(res)
34316	if err := googleapi.CheckResponse(res); err != nil {
34317		return nil, err
34318	}
34319	ret := &GoogleLongrunningOperation{
34320		ServerResponse: googleapi.ServerResponse{
34321			Header:         res.Header,
34322			HTTPStatusCode: res.StatusCode,
34323		},
34324	}
34325	target := &ret
34326	if err := gensupport.DecodeResponse(target, res); err != nil {
34327		return nil, err
34328	}
34329	return ret, nil
34330	// {
34331	//   "description": "Creates a new document. This method is a [long-running operation](https://cloud.google.com/dialogflow/cx/docs/how/long-running-operation). The returned `Operation` type has the following method-specific fields: - `metadata`: KnowledgeOperationMetadata - `response`: Document",
34332	//   "flatPath": "v2/projects/{projectsId}/knowledgeBases/{knowledgeBasesId}/documents",
34333	//   "httpMethod": "POST",
34334	//   "id": "dialogflow.projects.knowledgeBases.documents.create",
34335	//   "parameterOrder": [
34336	//     "parent"
34337	//   ],
34338	//   "parameters": {
34339	//     "parent": {
34340	//       "description": "Required. The knowledge base to create a document for. Format: `projects//locations//knowledgeBases/`.",
34341	//       "location": "path",
34342	//       "pattern": "^projects/[^/]+/knowledgeBases/[^/]+$",
34343	//       "required": true,
34344	//       "type": "string"
34345	//     }
34346	//   },
34347	//   "path": "v2/{+parent}/documents",
34348	//   "request": {
34349	//     "$ref": "GoogleCloudDialogflowV2Document"
34350	//   },
34351	//   "response": {
34352	//     "$ref": "GoogleLongrunningOperation"
34353	//   },
34354	//   "scopes": [
34355	//     "https://www.googleapis.com/auth/cloud-platform",
34356	//     "https://www.googleapis.com/auth/dialogflow"
34357	//   ]
34358	// }
34359
34360}
34361
34362// method id "dialogflow.projects.knowledgeBases.documents.delete":
34363
34364type ProjectsKnowledgeBasesDocumentsDeleteCall struct {
34365	s          *Service
34366	name       string
34367	urlParams_ gensupport.URLParams
34368	ctx_       context.Context
34369	header_    http.Header
34370}
34371
34372// Delete: Deletes the specified document. This method is a long-running
34373// operation
34374// (https://cloud.google.com/dialogflow/cx/docs/how/long-running-operation).
34375// The returned `Operation` type has the following method-specific
34376// fields: - `metadata`: KnowledgeOperationMetadata - `response`: An
34377// Empty message
34378// (https://developers.google.com/protocol-buffers/docs/reference/google.protobuf#empty)
34379//
34380// - name: The name of the document to delete. Format:
34381//   `projects//locations//knowledgeBases//documents/`.
34382func (r *ProjectsKnowledgeBasesDocumentsService) Delete(name string) *ProjectsKnowledgeBasesDocumentsDeleteCall {
34383	c := &ProjectsKnowledgeBasesDocumentsDeleteCall{s: r.s, urlParams_: make(gensupport.URLParams)}
34384	c.name = name
34385	return c
34386}
34387
34388// Fields allows partial responses to be retrieved. See
34389// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
34390// for more information.
34391func (c *ProjectsKnowledgeBasesDocumentsDeleteCall) Fields(s ...googleapi.Field) *ProjectsKnowledgeBasesDocumentsDeleteCall {
34392	c.urlParams_.Set("fields", googleapi.CombineFields(s))
34393	return c
34394}
34395
34396// Context sets the context to be used in this call's Do method. Any
34397// pending HTTP request will be aborted if the provided context is
34398// canceled.
34399func (c *ProjectsKnowledgeBasesDocumentsDeleteCall) Context(ctx context.Context) *ProjectsKnowledgeBasesDocumentsDeleteCall {
34400	c.ctx_ = ctx
34401	return c
34402}
34403
34404// Header returns an http.Header that can be modified by the caller to
34405// add HTTP headers to the request.
34406func (c *ProjectsKnowledgeBasesDocumentsDeleteCall) Header() http.Header {
34407	if c.header_ == nil {
34408		c.header_ = make(http.Header)
34409	}
34410	return c.header_
34411}
34412
34413func (c *ProjectsKnowledgeBasesDocumentsDeleteCall) doRequest(alt string) (*http.Response, error) {
34414	reqHeaders := make(http.Header)
34415	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20211027")
34416	for k, v := range c.header_ {
34417		reqHeaders[k] = v
34418	}
34419	reqHeaders.Set("User-Agent", c.s.userAgent())
34420	var body io.Reader = nil
34421	c.urlParams_.Set("alt", alt)
34422	c.urlParams_.Set("prettyPrint", "false")
34423	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+name}")
34424	urls += "?" + c.urlParams_.Encode()
34425	req, err := http.NewRequest("DELETE", urls, body)
34426	if err != nil {
34427		return nil, err
34428	}
34429	req.Header = reqHeaders
34430	googleapi.Expand(req.URL, map[string]string{
34431		"name": c.name,
34432	})
34433	return gensupport.SendRequest(c.ctx_, c.s.client, req)
34434}
34435
34436// Do executes the "dialogflow.projects.knowledgeBases.documents.delete" call.
34437// Exactly one of *GoogleLongrunningOperation or error will be non-nil.
34438// Any non-2xx status code is an error. Response headers are in either
34439// *GoogleLongrunningOperation.ServerResponse.Header or (if a response
34440// was returned at all) in error.(*googleapi.Error).Header. Use
34441// googleapi.IsNotModified to check whether the returned error was
34442// because http.StatusNotModified was returned.
34443func (c *ProjectsKnowledgeBasesDocumentsDeleteCall) Do(opts ...googleapi.CallOption) (*GoogleLongrunningOperation, error) {
34444	gensupport.SetOptions(c.urlParams_, opts...)
34445	res, err := c.doRequest("json")
34446	if res != nil && res.StatusCode == http.StatusNotModified {
34447		if res.Body != nil {
34448			res.Body.Close()
34449		}
34450		return nil, &googleapi.Error{
34451			Code:   res.StatusCode,
34452			Header: res.Header,
34453		}
34454	}
34455	if err != nil {
34456		return nil, err
34457	}
34458	defer googleapi.CloseBody(res)
34459	if err := googleapi.CheckResponse(res); err != nil {
34460		return nil, err
34461	}
34462	ret := &GoogleLongrunningOperation{
34463		ServerResponse: googleapi.ServerResponse{
34464			Header:         res.Header,
34465			HTTPStatusCode: res.StatusCode,
34466		},
34467	}
34468	target := &ret
34469	if err := gensupport.DecodeResponse(target, res); err != nil {
34470		return nil, err
34471	}
34472	return ret, nil
34473	// {
34474	//   "description": "Deletes the specified document. This method is a [long-running operation](https://cloud.google.com/dialogflow/cx/docs/how/long-running-operation). The returned `Operation` type has the following method-specific fields: - `metadata`: KnowledgeOperationMetadata - `response`: An [Empty message](https://developers.google.com/protocol-buffers/docs/reference/google.protobuf#empty)",
34475	//   "flatPath": "v2/projects/{projectsId}/knowledgeBases/{knowledgeBasesId}/documents/{documentsId}",
34476	//   "httpMethod": "DELETE",
34477	//   "id": "dialogflow.projects.knowledgeBases.documents.delete",
34478	//   "parameterOrder": [
34479	//     "name"
34480	//   ],
34481	//   "parameters": {
34482	//     "name": {
34483	//       "description": "Required. The name of the document to delete. Format: `projects//locations//knowledgeBases//documents/`.",
34484	//       "location": "path",
34485	//       "pattern": "^projects/[^/]+/knowledgeBases/[^/]+/documents/[^/]+$",
34486	//       "required": true,
34487	//       "type": "string"
34488	//     }
34489	//   },
34490	//   "path": "v2/{+name}",
34491	//   "response": {
34492	//     "$ref": "GoogleLongrunningOperation"
34493	//   },
34494	//   "scopes": [
34495	//     "https://www.googleapis.com/auth/cloud-platform",
34496	//     "https://www.googleapis.com/auth/dialogflow"
34497	//   ]
34498	// }
34499
34500}
34501
34502// method id "dialogflow.projects.knowledgeBases.documents.get":
34503
34504type ProjectsKnowledgeBasesDocumentsGetCall struct {
34505	s            *Service
34506	name         string
34507	urlParams_   gensupport.URLParams
34508	ifNoneMatch_ string
34509	ctx_         context.Context
34510	header_      http.Header
34511}
34512
34513// Get: Retrieves the specified document.
34514//
34515// - name: The name of the document to retrieve. Format
34516//   `projects//locations//knowledgeBases//documents/`.
34517func (r *ProjectsKnowledgeBasesDocumentsService) Get(name string) *ProjectsKnowledgeBasesDocumentsGetCall {
34518	c := &ProjectsKnowledgeBasesDocumentsGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
34519	c.name = name
34520	return c
34521}
34522
34523// Fields allows partial responses to be retrieved. See
34524// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
34525// for more information.
34526func (c *ProjectsKnowledgeBasesDocumentsGetCall) Fields(s ...googleapi.Field) *ProjectsKnowledgeBasesDocumentsGetCall {
34527	c.urlParams_.Set("fields", googleapi.CombineFields(s))
34528	return c
34529}
34530
34531// IfNoneMatch sets the optional parameter which makes the operation
34532// fail if the object's ETag matches the given value. This is useful for
34533// getting updates only after the object has changed since the last
34534// request. Use googleapi.IsNotModified to check whether the response
34535// error from Do is the result of In-None-Match.
34536func (c *ProjectsKnowledgeBasesDocumentsGetCall) IfNoneMatch(entityTag string) *ProjectsKnowledgeBasesDocumentsGetCall {
34537	c.ifNoneMatch_ = entityTag
34538	return c
34539}
34540
34541// Context sets the context to be used in this call's Do method. Any
34542// pending HTTP request will be aborted if the provided context is
34543// canceled.
34544func (c *ProjectsKnowledgeBasesDocumentsGetCall) Context(ctx context.Context) *ProjectsKnowledgeBasesDocumentsGetCall {
34545	c.ctx_ = ctx
34546	return c
34547}
34548
34549// Header returns an http.Header that can be modified by the caller to
34550// add HTTP headers to the request.
34551func (c *ProjectsKnowledgeBasesDocumentsGetCall) Header() http.Header {
34552	if c.header_ == nil {
34553		c.header_ = make(http.Header)
34554	}
34555	return c.header_
34556}
34557
34558func (c *ProjectsKnowledgeBasesDocumentsGetCall) doRequest(alt string) (*http.Response, error) {
34559	reqHeaders := make(http.Header)
34560	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20211027")
34561	for k, v := range c.header_ {
34562		reqHeaders[k] = v
34563	}
34564	reqHeaders.Set("User-Agent", c.s.userAgent())
34565	if c.ifNoneMatch_ != "" {
34566		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
34567	}
34568	var body io.Reader = nil
34569	c.urlParams_.Set("alt", alt)
34570	c.urlParams_.Set("prettyPrint", "false")
34571	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+name}")
34572	urls += "?" + c.urlParams_.Encode()
34573	req, err := http.NewRequest("GET", urls, body)
34574	if err != nil {
34575		return nil, err
34576	}
34577	req.Header = reqHeaders
34578	googleapi.Expand(req.URL, map[string]string{
34579		"name": c.name,
34580	})
34581	return gensupport.SendRequest(c.ctx_, c.s.client, req)
34582}
34583
34584// Do executes the "dialogflow.projects.knowledgeBases.documents.get" call.
34585// Exactly one of *GoogleCloudDialogflowV2Document or error will be
34586// non-nil. Any non-2xx status code is an error. Response headers are in
34587// either *GoogleCloudDialogflowV2Document.ServerResponse.Header or (if
34588// a response was returned at all) in error.(*googleapi.Error).Header.
34589// Use googleapi.IsNotModified to check whether the returned error was
34590// because http.StatusNotModified was returned.
34591func (c *ProjectsKnowledgeBasesDocumentsGetCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDialogflowV2Document, error) {
34592	gensupport.SetOptions(c.urlParams_, opts...)
34593	res, err := c.doRequest("json")
34594	if res != nil && res.StatusCode == http.StatusNotModified {
34595		if res.Body != nil {
34596			res.Body.Close()
34597		}
34598		return nil, &googleapi.Error{
34599			Code:   res.StatusCode,
34600			Header: res.Header,
34601		}
34602	}
34603	if err != nil {
34604		return nil, err
34605	}
34606	defer googleapi.CloseBody(res)
34607	if err := googleapi.CheckResponse(res); err != nil {
34608		return nil, err
34609	}
34610	ret := &GoogleCloudDialogflowV2Document{
34611		ServerResponse: googleapi.ServerResponse{
34612			Header:         res.Header,
34613			HTTPStatusCode: res.StatusCode,
34614		},
34615	}
34616	target := &ret
34617	if err := gensupport.DecodeResponse(target, res); err != nil {
34618		return nil, err
34619	}
34620	return ret, nil
34621	// {
34622	//   "description": "Retrieves the specified document.",
34623	//   "flatPath": "v2/projects/{projectsId}/knowledgeBases/{knowledgeBasesId}/documents/{documentsId}",
34624	//   "httpMethod": "GET",
34625	//   "id": "dialogflow.projects.knowledgeBases.documents.get",
34626	//   "parameterOrder": [
34627	//     "name"
34628	//   ],
34629	//   "parameters": {
34630	//     "name": {
34631	//       "description": "Required. The name of the document to retrieve. Format `projects//locations//knowledgeBases//documents/`.",
34632	//       "location": "path",
34633	//       "pattern": "^projects/[^/]+/knowledgeBases/[^/]+/documents/[^/]+$",
34634	//       "required": true,
34635	//       "type": "string"
34636	//     }
34637	//   },
34638	//   "path": "v2/{+name}",
34639	//   "response": {
34640	//     "$ref": "GoogleCloudDialogflowV2Document"
34641	//   },
34642	//   "scopes": [
34643	//     "https://www.googleapis.com/auth/cloud-platform",
34644	//     "https://www.googleapis.com/auth/dialogflow"
34645	//   ]
34646	// }
34647
34648}
34649
34650// method id "dialogflow.projects.knowledgeBases.documents.list":
34651
34652type ProjectsKnowledgeBasesDocumentsListCall struct {
34653	s            *Service
34654	parent       string
34655	urlParams_   gensupport.URLParams
34656	ifNoneMatch_ string
34657	ctx_         context.Context
34658	header_      http.Header
34659}
34660
34661// List: Returns the list of all documents of the knowledge base.
34662//
34663// - parent: The knowledge base to list all documents for. Format:
34664//   `projects//locations//knowledgeBases/`.
34665func (r *ProjectsKnowledgeBasesDocumentsService) List(parent string) *ProjectsKnowledgeBasesDocumentsListCall {
34666	c := &ProjectsKnowledgeBasesDocumentsListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
34667	c.parent = parent
34668	return c
34669}
34670
34671// PageSize sets the optional parameter "pageSize": The maximum number
34672// of items to return in a single page. By default 10 and at most 100.
34673func (c *ProjectsKnowledgeBasesDocumentsListCall) PageSize(pageSize int64) *ProjectsKnowledgeBasesDocumentsListCall {
34674	c.urlParams_.Set("pageSize", fmt.Sprint(pageSize))
34675	return c
34676}
34677
34678// PageToken sets the optional parameter "pageToken": The
34679// next_page_token value returned from a previous list request.
34680func (c *ProjectsKnowledgeBasesDocumentsListCall) PageToken(pageToken string) *ProjectsKnowledgeBasesDocumentsListCall {
34681	c.urlParams_.Set("pageToken", pageToken)
34682	return c
34683}
34684
34685// Fields allows partial responses to be retrieved. See
34686// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
34687// for more information.
34688func (c *ProjectsKnowledgeBasesDocumentsListCall) Fields(s ...googleapi.Field) *ProjectsKnowledgeBasesDocumentsListCall {
34689	c.urlParams_.Set("fields", googleapi.CombineFields(s))
34690	return c
34691}
34692
34693// IfNoneMatch sets the optional parameter which makes the operation
34694// fail if the object's ETag matches the given value. This is useful for
34695// getting updates only after the object has changed since the last
34696// request. Use googleapi.IsNotModified to check whether the response
34697// error from Do is the result of In-None-Match.
34698func (c *ProjectsKnowledgeBasesDocumentsListCall) IfNoneMatch(entityTag string) *ProjectsKnowledgeBasesDocumentsListCall {
34699	c.ifNoneMatch_ = entityTag
34700	return c
34701}
34702
34703// Context sets the context to be used in this call's Do method. Any
34704// pending HTTP request will be aborted if the provided context is
34705// canceled.
34706func (c *ProjectsKnowledgeBasesDocumentsListCall) Context(ctx context.Context) *ProjectsKnowledgeBasesDocumentsListCall {
34707	c.ctx_ = ctx
34708	return c
34709}
34710
34711// Header returns an http.Header that can be modified by the caller to
34712// add HTTP headers to the request.
34713func (c *ProjectsKnowledgeBasesDocumentsListCall) Header() http.Header {
34714	if c.header_ == nil {
34715		c.header_ = make(http.Header)
34716	}
34717	return c.header_
34718}
34719
34720func (c *ProjectsKnowledgeBasesDocumentsListCall) doRequest(alt string) (*http.Response, error) {
34721	reqHeaders := make(http.Header)
34722	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20211027")
34723	for k, v := range c.header_ {
34724		reqHeaders[k] = v
34725	}
34726	reqHeaders.Set("User-Agent", c.s.userAgent())
34727	if c.ifNoneMatch_ != "" {
34728		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
34729	}
34730	var body io.Reader = nil
34731	c.urlParams_.Set("alt", alt)
34732	c.urlParams_.Set("prettyPrint", "false")
34733	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+parent}/documents")
34734	urls += "?" + c.urlParams_.Encode()
34735	req, err := http.NewRequest("GET", urls, body)
34736	if err != nil {
34737		return nil, err
34738	}
34739	req.Header = reqHeaders
34740	googleapi.Expand(req.URL, map[string]string{
34741		"parent": c.parent,
34742	})
34743	return gensupport.SendRequest(c.ctx_, c.s.client, req)
34744}
34745
34746// Do executes the "dialogflow.projects.knowledgeBases.documents.list" call.
34747// Exactly one of *GoogleCloudDialogflowV2ListDocumentsResponse or error
34748// will be non-nil. Any non-2xx status code is an error. Response
34749// headers are in either
34750// *GoogleCloudDialogflowV2ListDocumentsResponse.ServerResponse.Header
34751// or (if a response was returned at all) in
34752// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
34753// whether the returned error was because http.StatusNotModified was
34754// returned.
34755func (c *ProjectsKnowledgeBasesDocumentsListCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDialogflowV2ListDocumentsResponse, error) {
34756	gensupport.SetOptions(c.urlParams_, opts...)
34757	res, err := c.doRequest("json")
34758	if res != nil && res.StatusCode == http.StatusNotModified {
34759		if res.Body != nil {
34760			res.Body.Close()
34761		}
34762		return nil, &googleapi.Error{
34763			Code:   res.StatusCode,
34764			Header: res.Header,
34765		}
34766	}
34767	if err != nil {
34768		return nil, err
34769	}
34770	defer googleapi.CloseBody(res)
34771	if err := googleapi.CheckResponse(res); err != nil {
34772		return nil, err
34773	}
34774	ret := &GoogleCloudDialogflowV2ListDocumentsResponse{
34775		ServerResponse: googleapi.ServerResponse{
34776			Header:         res.Header,
34777			HTTPStatusCode: res.StatusCode,
34778		},
34779	}
34780	target := &ret
34781	if err := gensupport.DecodeResponse(target, res); err != nil {
34782		return nil, err
34783	}
34784	return ret, nil
34785	// {
34786	//   "description": "Returns the list of all documents of the knowledge base.",
34787	//   "flatPath": "v2/projects/{projectsId}/knowledgeBases/{knowledgeBasesId}/documents",
34788	//   "httpMethod": "GET",
34789	//   "id": "dialogflow.projects.knowledgeBases.documents.list",
34790	//   "parameterOrder": [
34791	//     "parent"
34792	//   ],
34793	//   "parameters": {
34794	//     "pageSize": {
34795	//       "description": "The maximum number of items to return in a single page. By default 10 and at most 100.",
34796	//       "format": "int32",
34797	//       "location": "query",
34798	//       "type": "integer"
34799	//     },
34800	//     "pageToken": {
34801	//       "description": "The next_page_token value returned from a previous list request.",
34802	//       "location": "query",
34803	//       "type": "string"
34804	//     },
34805	//     "parent": {
34806	//       "description": "Required. The knowledge base to list all documents for. Format: `projects//locations//knowledgeBases/`.",
34807	//       "location": "path",
34808	//       "pattern": "^projects/[^/]+/knowledgeBases/[^/]+$",
34809	//       "required": true,
34810	//       "type": "string"
34811	//     }
34812	//   },
34813	//   "path": "v2/{+parent}/documents",
34814	//   "response": {
34815	//     "$ref": "GoogleCloudDialogflowV2ListDocumentsResponse"
34816	//   },
34817	//   "scopes": [
34818	//     "https://www.googleapis.com/auth/cloud-platform",
34819	//     "https://www.googleapis.com/auth/dialogflow"
34820	//   ]
34821	// }
34822
34823}
34824
34825// Pages invokes f for each page of results.
34826// A non-nil error returned from f will halt the iteration.
34827// The provided context supersedes any context provided to the Context method.
34828func (c *ProjectsKnowledgeBasesDocumentsListCall) Pages(ctx context.Context, f func(*GoogleCloudDialogflowV2ListDocumentsResponse) error) error {
34829	c.ctx_ = ctx
34830	defer c.PageToken(c.urlParams_.Get("pageToken")) // reset paging to original point
34831	for {
34832		x, err := c.Do()
34833		if err != nil {
34834			return err
34835		}
34836		if err := f(x); err != nil {
34837			return err
34838		}
34839		if x.NextPageToken == "" {
34840			return nil
34841		}
34842		c.PageToken(x.NextPageToken)
34843	}
34844}
34845
34846// method id "dialogflow.projects.knowledgeBases.documents.patch":
34847
34848type ProjectsKnowledgeBasesDocumentsPatchCall struct {
34849	s                               *Service
34850	name                            string
34851	googleclouddialogflowv2document *GoogleCloudDialogflowV2Document
34852	urlParams_                      gensupport.URLParams
34853	ctx_                            context.Context
34854	header_                         http.Header
34855}
34856
34857// Patch: Updates the specified document. This method is a long-running
34858// operation
34859// (https://cloud.google.com/dialogflow/cx/docs/how/long-running-operation).
34860// The returned `Operation` type has the following method-specific
34861// fields: - `metadata`: KnowledgeOperationMetadata - `response`:
34862// Document
34863//
34864// - name: Optional. The document resource name. The name must be empty
34865//   when creating a document. Format:
34866//   `projects//locations//knowledgeBases//documents/`.
34867func (r *ProjectsKnowledgeBasesDocumentsService) Patch(name string, googleclouddialogflowv2document *GoogleCloudDialogflowV2Document) *ProjectsKnowledgeBasesDocumentsPatchCall {
34868	c := &ProjectsKnowledgeBasesDocumentsPatchCall{s: r.s, urlParams_: make(gensupport.URLParams)}
34869	c.name = name
34870	c.googleclouddialogflowv2document = googleclouddialogflowv2document
34871	return c
34872}
34873
34874// UpdateMask sets the optional parameter "updateMask": Not specified
34875// means `update all`. Currently, only `display_name` can be updated, an
34876// InvalidArgument will be returned for attempting to update other
34877// fields.
34878func (c *ProjectsKnowledgeBasesDocumentsPatchCall) UpdateMask(updateMask string) *ProjectsKnowledgeBasesDocumentsPatchCall {
34879	c.urlParams_.Set("updateMask", updateMask)
34880	return c
34881}
34882
34883// Fields allows partial responses to be retrieved. See
34884// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
34885// for more information.
34886func (c *ProjectsKnowledgeBasesDocumentsPatchCall) Fields(s ...googleapi.Field) *ProjectsKnowledgeBasesDocumentsPatchCall {
34887	c.urlParams_.Set("fields", googleapi.CombineFields(s))
34888	return c
34889}
34890
34891// Context sets the context to be used in this call's Do method. Any
34892// pending HTTP request will be aborted if the provided context is
34893// canceled.
34894func (c *ProjectsKnowledgeBasesDocumentsPatchCall) Context(ctx context.Context) *ProjectsKnowledgeBasesDocumentsPatchCall {
34895	c.ctx_ = ctx
34896	return c
34897}
34898
34899// Header returns an http.Header that can be modified by the caller to
34900// add HTTP headers to the request.
34901func (c *ProjectsKnowledgeBasesDocumentsPatchCall) Header() http.Header {
34902	if c.header_ == nil {
34903		c.header_ = make(http.Header)
34904	}
34905	return c.header_
34906}
34907
34908func (c *ProjectsKnowledgeBasesDocumentsPatchCall) doRequest(alt string) (*http.Response, error) {
34909	reqHeaders := make(http.Header)
34910	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20211027")
34911	for k, v := range c.header_ {
34912		reqHeaders[k] = v
34913	}
34914	reqHeaders.Set("User-Agent", c.s.userAgent())
34915	var body io.Reader = nil
34916	body, err := googleapi.WithoutDataWrapper.JSONReader(c.googleclouddialogflowv2document)
34917	if err != nil {
34918		return nil, err
34919	}
34920	reqHeaders.Set("Content-Type", "application/json")
34921	c.urlParams_.Set("alt", alt)
34922	c.urlParams_.Set("prettyPrint", "false")
34923	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+name}")
34924	urls += "?" + c.urlParams_.Encode()
34925	req, err := http.NewRequest("PATCH", urls, body)
34926	if err != nil {
34927		return nil, err
34928	}
34929	req.Header = reqHeaders
34930	googleapi.Expand(req.URL, map[string]string{
34931		"name": c.name,
34932	})
34933	return gensupport.SendRequest(c.ctx_, c.s.client, req)
34934}
34935
34936// Do executes the "dialogflow.projects.knowledgeBases.documents.patch" call.
34937// Exactly one of *GoogleLongrunningOperation or error will be non-nil.
34938// Any non-2xx status code is an error. Response headers are in either
34939// *GoogleLongrunningOperation.ServerResponse.Header or (if a response
34940// was returned at all) in error.(*googleapi.Error).Header. Use
34941// googleapi.IsNotModified to check whether the returned error was
34942// because http.StatusNotModified was returned.
34943func (c *ProjectsKnowledgeBasesDocumentsPatchCall) Do(opts ...googleapi.CallOption) (*GoogleLongrunningOperation, error) {
34944	gensupport.SetOptions(c.urlParams_, opts...)
34945	res, err := c.doRequest("json")
34946	if res != nil && res.StatusCode == http.StatusNotModified {
34947		if res.Body != nil {
34948			res.Body.Close()
34949		}
34950		return nil, &googleapi.Error{
34951			Code:   res.StatusCode,
34952			Header: res.Header,
34953		}
34954	}
34955	if err != nil {
34956		return nil, err
34957	}
34958	defer googleapi.CloseBody(res)
34959	if err := googleapi.CheckResponse(res); err != nil {
34960		return nil, err
34961	}
34962	ret := &GoogleLongrunningOperation{
34963		ServerResponse: googleapi.ServerResponse{
34964			Header:         res.Header,
34965			HTTPStatusCode: res.StatusCode,
34966		},
34967	}
34968	target := &ret
34969	if err := gensupport.DecodeResponse(target, res); err != nil {
34970		return nil, err
34971	}
34972	return ret, nil
34973	// {
34974	//   "description": "Updates the specified document. This method is a [long-running operation](https://cloud.google.com/dialogflow/cx/docs/how/long-running-operation). The returned `Operation` type has the following method-specific fields: - `metadata`: KnowledgeOperationMetadata - `response`: Document",
34975	//   "flatPath": "v2/projects/{projectsId}/knowledgeBases/{knowledgeBasesId}/documents/{documentsId}",
34976	//   "httpMethod": "PATCH",
34977	//   "id": "dialogflow.projects.knowledgeBases.documents.patch",
34978	//   "parameterOrder": [
34979	//     "name"
34980	//   ],
34981	//   "parameters": {
34982	//     "name": {
34983	//       "description": "Optional. The document resource name. The name must be empty when creating a document. Format: `projects//locations//knowledgeBases//documents/`.",
34984	//       "location": "path",
34985	//       "pattern": "^projects/[^/]+/knowledgeBases/[^/]+/documents/[^/]+$",
34986	//       "required": true,
34987	//       "type": "string"
34988	//     },
34989	//     "updateMask": {
34990	//       "description": "Optional. Not specified means `update all`. Currently, only `display_name` can be updated, an InvalidArgument will be returned for attempting to update other fields.",
34991	//       "format": "google-fieldmask",
34992	//       "location": "query",
34993	//       "type": "string"
34994	//     }
34995	//   },
34996	//   "path": "v2/{+name}",
34997	//   "request": {
34998	//     "$ref": "GoogleCloudDialogflowV2Document"
34999	//   },
35000	//   "response": {
35001	//     "$ref": "GoogleLongrunningOperation"
35002	//   },
35003	//   "scopes": [
35004	//     "https://www.googleapis.com/auth/cloud-platform",
35005	//     "https://www.googleapis.com/auth/dialogflow"
35006	//   ]
35007	// }
35008
35009}
35010
35011// method id "dialogflow.projects.knowledgeBases.documents.reload":
35012
35013type ProjectsKnowledgeBasesDocumentsReloadCall struct {
35014	s                                            *Service
35015	name                                         string
35016	googleclouddialogflowv2reloaddocumentrequest *GoogleCloudDialogflowV2ReloadDocumentRequest
35017	urlParams_                                   gensupport.URLParams
35018	ctx_                                         context.Context
35019	header_                                      http.Header
35020}
35021
35022// Reload: Reloads the specified document from its specified source,
35023// content_uri or content. The previously loaded content of the document
35024// will be deleted. Note: Even when the content of the document has not
35025// changed, there still may be side effects because of internal
35026// implementation changes. This method is a long-running operation
35027// (https://cloud.google.com/dialogflow/cx/docs/how/long-running-operation).
35028// The returned `Operation` type has the following method-specific
35029// fields: - `metadata`: KnowledgeOperationMetadata - `response`:
35030// Document Note: The `projects.agent.knowledgeBases.documents` resource
35031// is deprecated; only use `projects.knowledgeBases.documents`.
35032//
35033// - name: The name of the document to reload. Format:
35034//   `projects//locations//knowledgeBases//documents/`.
35035func (r *ProjectsKnowledgeBasesDocumentsService) Reload(name string, googleclouddialogflowv2reloaddocumentrequest *GoogleCloudDialogflowV2ReloadDocumentRequest) *ProjectsKnowledgeBasesDocumentsReloadCall {
35036	c := &ProjectsKnowledgeBasesDocumentsReloadCall{s: r.s, urlParams_: make(gensupport.URLParams)}
35037	c.name = name
35038	c.googleclouddialogflowv2reloaddocumentrequest = googleclouddialogflowv2reloaddocumentrequest
35039	return c
35040}
35041
35042// Fields allows partial responses to be retrieved. See
35043// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
35044// for more information.
35045func (c *ProjectsKnowledgeBasesDocumentsReloadCall) Fields(s ...googleapi.Field) *ProjectsKnowledgeBasesDocumentsReloadCall {
35046	c.urlParams_.Set("fields", googleapi.CombineFields(s))
35047	return c
35048}
35049
35050// Context sets the context to be used in this call's Do method. Any
35051// pending HTTP request will be aborted if the provided context is
35052// canceled.
35053func (c *ProjectsKnowledgeBasesDocumentsReloadCall) Context(ctx context.Context) *ProjectsKnowledgeBasesDocumentsReloadCall {
35054	c.ctx_ = ctx
35055	return c
35056}
35057
35058// Header returns an http.Header that can be modified by the caller to
35059// add HTTP headers to the request.
35060func (c *ProjectsKnowledgeBasesDocumentsReloadCall) Header() http.Header {
35061	if c.header_ == nil {
35062		c.header_ = make(http.Header)
35063	}
35064	return c.header_
35065}
35066
35067func (c *ProjectsKnowledgeBasesDocumentsReloadCall) doRequest(alt string) (*http.Response, error) {
35068	reqHeaders := make(http.Header)
35069	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20211027")
35070	for k, v := range c.header_ {
35071		reqHeaders[k] = v
35072	}
35073	reqHeaders.Set("User-Agent", c.s.userAgent())
35074	var body io.Reader = nil
35075	body, err := googleapi.WithoutDataWrapper.JSONReader(c.googleclouddialogflowv2reloaddocumentrequest)
35076	if err != nil {
35077		return nil, err
35078	}
35079	reqHeaders.Set("Content-Type", "application/json")
35080	c.urlParams_.Set("alt", alt)
35081	c.urlParams_.Set("prettyPrint", "false")
35082	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+name}:reload")
35083	urls += "?" + c.urlParams_.Encode()
35084	req, err := http.NewRequest("POST", urls, body)
35085	if err != nil {
35086		return nil, err
35087	}
35088	req.Header = reqHeaders
35089	googleapi.Expand(req.URL, map[string]string{
35090		"name": c.name,
35091	})
35092	return gensupport.SendRequest(c.ctx_, c.s.client, req)
35093}
35094
35095// Do executes the "dialogflow.projects.knowledgeBases.documents.reload" call.
35096// Exactly one of *GoogleLongrunningOperation or error will be non-nil.
35097// Any non-2xx status code is an error. Response headers are in either
35098// *GoogleLongrunningOperation.ServerResponse.Header or (if a response
35099// was returned at all) in error.(*googleapi.Error).Header. Use
35100// googleapi.IsNotModified to check whether the returned error was
35101// because http.StatusNotModified was returned.
35102func (c *ProjectsKnowledgeBasesDocumentsReloadCall) Do(opts ...googleapi.CallOption) (*GoogleLongrunningOperation, error) {
35103	gensupport.SetOptions(c.urlParams_, opts...)
35104	res, err := c.doRequest("json")
35105	if res != nil && res.StatusCode == http.StatusNotModified {
35106		if res.Body != nil {
35107			res.Body.Close()
35108		}
35109		return nil, &googleapi.Error{
35110			Code:   res.StatusCode,
35111			Header: res.Header,
35112		}
35113	}
35114	if err != nil {
35115		return nil, err
35116	}
35117	defer googleapi.CloseBody(res)
35118	if err := googleapi.CheckResponse(res); err != nil {
35119		return nil, err
35120	}
35121	ret := &GoogleLongrunningOperation{
35122		ServerResponse: googleapi.ServerResponse{
35123			Header:         res.Header,
35124			HTTPStatusCode: res.StatusCode,
35125		},
35126	}
35127	target := &ret
35128	if err := gensupport.DecodeResponse(target, res); err != nil {
35129		return nil, err
35130	}
35131	return ret, nil
35132	// {
35133	//   "description": "Reloads the specified document from its specified source, content_uri or content. The previously loaded content of the document will be deleted. Note: Even when the content of the document has not changed, there still may be side effects because of internal implementation changes. This method is a [long-running operation](https://cloud.google.com/dialogflow/cx/docs/how/long-running-operation). The returned `Operation` type has the following method-specific fields: - `metadata`: KnowledgeOperationMetadata - `response`: Document Note: The `projects.agent.knowledgeBases.documents` resource is deprecated; only use `projects.knowledgeBases.documents`.",
35134	//   "flatPath": "v2/projects/{projectsId}/knowledgeBases/{knowledgeBasesId}/documents/{documentsId}:reload",
35135	//   "httpMethod": "POST",
35136	//   "id": "dialogflow.projects.knowledgeBases.documents.reload",
35137	//   "parameterOrder": [
35138	//     "name"
35139	//   ],
35140	//   "parameters": {
35141	//     "name": {
35142	//       "description": "Required. The name of the document to reload. Format: `projects//locations//knowledgeBases//documents/`",
35143	//       "location": "path",
35144	//       "pattern": "^projects/[^/]+/knowledgeBases/[^/]+/documents/[^/]+$",
35145	//       "required": true,
35146	//       "type": "string"
35147	//     }
35148	//   },
35149	//   "path": "v2/{+name}:reload",
35150	//   "request": {
35151	//     "$ref": "GoogleCloudDialogflowV2ReloadDocumentRequest"
35152	//   },
35153	//   "response": {
35154	//     "$ref": "GoogleLongrunningOperation"
35155	//   },
35156	//   "scopes": [
35157	//     "https://www.googleapis.com/auth/cloud-platform",
35158	//     "https://www.googleapis.com/auth/dialogflow"
35159	//   ]
35160	// }
35161
35162}
35163
35164// method id "dialogflow.projects.locations.deleteAgent":
35165
35166type ProjectsLocationsDeleteAgentCall struct {
35167	s          *Service
35168	parent     string
35169	urlParams_ gensupport.URLParams
35170	ctx_       context.Context
35171	header_    http.Header
35172}
35173
35174// DeleteAgent: Deletes the specified agent.
35175//
35176// - parent: The project that the agent to delete is associated with.
35177//   Format: `projects/`.
35178func (r *ProjectsLocationsService) DeleteAgent(parent string) *ProjectsLocationsDeleteAgentCall {
35179	c := &ProjectsLocationsDeleteAgentCall{s: r.s, urlParams_: make(gensupport.URLParams)}
35180	c.parent = parent
35181	return c
35182}
35183
35184// Fields allows partial responses to be retrieved. See
35185// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
35186// for more information.
35187func (c *ProjectsLocationsDeleteAgentCall) Fields(s ...googleapi.Field) *ProjectsLocationsDeleteAgentCall {
35188	c.urlParams_.Set("fields", googleapi.CombineFields(s))
35189	return c
35190}
35191
35192// Context sets the context to be used in this call's Do method. Any
35193// pending HTTP request will be aborted if the provided context is
35194// canceled.
35195func (c *ProjectsLocationsDeleteAgentCall) Context(ctx context.Context) *ProjectsLocationsDeleteAgentCall {
35196	c.ctx_ = ctx
35197	return c
35198}
35199
35200// Header returns an http.Header that can be modified by the caller to
35201// add HTTP headers to the request.
35202func (c *ProjectsLocationsDeleteAgentCall) Header() http.Header {
35203	if c.header_ == nil {
35204		c.header_ = make(http.Header)
35205	}
35206	return c.header_
35207}
35208
35209func (c *ProjectsLocationsDeleteAgentCall) doRequest(alt string) (*http.Response, error) {
35210	reqHeaders := make(http.Header)
35211	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20211027")
35212	for k, v := range c.header_ {
35213		reqHeaders[k] = v
35214	}
35215	reqHeaders.Set("User-Agent", c.s.userAgent())
35216	var body io.Reader = nil
35217	c.urlParams_.Set("alt", alt)
35218	c.urlParams_.Set("prettyPrint", "false")
35219	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+parent}/agent")
35220	urls += "?" + c.urlParams_.Encode()
35221	req, err := http.NewRequest("DELETE", urls, body)
35222	if err != nil {
35223		return nil, err
35224	}
35225	req.Header = reqHeaders
35226	googleapi.Expand(req.URL, map[string]string{
35227		"parent": c.parent,
35228	})
35229	return gensupport.SendRequest(c.ctx_, c.s.client, req)
35230}
35231
35232// Do executes the "dialogflow.projects.locations.deleteAgent" call.
35233// Exactly one of *GoogleProtobufEmpty or error will be non-nil. Any
35234// non-2xx status code is an error. Response headers are in either
35235// *GoogleProtobufEmpty.ServerResponse.Header or (if a response was
35236// returned at all) in error.(*googleapi.Error).Header. Use
35237// googleapi.IsNotModified to check whether the returned error was
35238// because http.StatusNotModified was returned.
35239func (c *ProjectsLocationsDeleteAgentCall) Do(opts ...googleapi.CallOption) (*GoogleProtobufEmpty, error) {
35240	gensupport.SetOptions(c.urlParams_, opts...)
35241	res, err := c.doRequest("json")
35242	if res != nil && res.StatusCode == http.StatusNotModified {
35243		if res.Body != nil {
35244			res.Body.Close()
35245		}
35246		return nil, &googleapi.Error{
35247			Code:   res.StatusCode,
35248			Header: res.Header,
35249		}
35250	}
35251	if err != nil {
35252		return nil, err
35253	}
35254	defer googleapi.CloseBody(res)
35255	if err := googleapi.CheckResponse(res); err != nil {
35256		return nil, err
35257	}
35258	ret := &GoogleProtobufEmpty{
35259		ServerResponse: googleapi.ServerResponse{
35260			Header:         res.Header,
35261			HTTPStatusCode: res.StatusCode,
35262		},
35263	}
35264	target := &ret
35265	if err := gensupport.DecodeResponse(target, res); err != nil {
35266		return nil, err
35267	}
35268	return ret, nil
35269	// {
35270	//   "description": "Deletes the specified agent.",
35271	//   "flatPath": "v2/projects/{projectsId}/locations/{locationsId}/agent",
35272	//   "httpMethod": "DELETE",
35273	//   "id": "dialogflow.projects.locations.deleteAgent",
35274	//   "parameterOrder": [
35275	//     "parent"
35276	//   ],
35277	//   "parameters": {
35278	//     "parent": {
35279	//       "description": "Required. The project that the agent to delete is associated with. Format: `projects/`.",
35280	//       "location": "path",
35281	//       "pattern": "^projects/[^/]+/locations/[^/]+$",
35282	//       "required": true,
35283	//       "type": "string"
35284	//     }
35285	//   },
35286	//   "path": "v2/{+parent}/agent",
35287	//   "response": {
35288	//     "$ref": "GoogleProtobufEmpty"
35289	//   },
35290	//   "scopes": [
35291	//     "https://www.googleapis.com/auth/cloud-platform",
35292	//     "https://www.googleapis.com/auth/dialogflow"
35293	//   ]
35294	// }
35295
35296}
35297
35298// method id "dialogflow.projects.locations.get":
35299
35300type ProjectsLocationsGetCall struct {
35301	s            *Service
35302	name         string
35303	urlParams_   gensupport.URLParams
35304	ifNoneMatch_ string
35305	ctx_         context.Context
35306	header_      http.Header
35307}
35308
35309// Get: Gets information about a location.
35310//
35311// - name: Resource name for the location.
35312func (r *ProjectsLocationsService) Get(name string) *ProjectsLocationsGetCall {
35313	c := &ProjectsLocationsGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
35314	c.name = name
35315	return c
35316}
35317
35318// Fields allows partial responses to be retrieved. See
35319// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
35320// for more information.
35321func (c *ProjectsLocationsGetCall) Fields(s ...googleapi.Field) *ProjectsLocationsGetCall {
35322	c.urlParams_.Set("fields", googleapi.CombineFields(s))
35323	return c
35324}
35325
35326// IfNoneMatch sets the optional parameter which makes the operation
35327// fail if the object's ETag matches the given value. This is useful for
35328// getting updates only after the object has changed since the last
35329// request. Use googleapi.IsNotModified to check whether the response
35330// error from Do is the result of In-None-Match.
35331func (c *ProjectsLocationsGetCall) IfNoneMatch(entityTag string) *ProjectsLocationsGetCall {
35332	c.ifNoneMatch_ = entityTag
35333	return c
35334}
35335
35336// Context sets the context to be used in this call's Do method. Any
35337// pending HTTP request will be aborted if the provided context is
35338// canceled.
35339func (c *ProjectsLocationsGetCall) Context(ctx context.Context) *ProjectsLocationsGetCall {
35340	c.ctx_ = ctx
35341	return c
35342}
35343
35344// Header returns an http.Header that can be modified by the caller to
35345// add HTTP headers to the request.
35346func (c *ProjectsLocationsGetCall) Header() http.Header {
35347	if c.header_ == nil {
35348		c.header_ = make(http.Header)
35349	}
35350	return c.header_
35351}
35352
35353func (c *ProjectsLocationsGetCall) doRequest(alt string) (*http.Response, error) {
35354	reqHeaders := make(http.Header)
35355	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20211027")
35356	for k, v := range c.header_ {
35357		reqHeaders[k] = v
35358	}
35359	reqHeaders.Set("User-Agent", c.s.userAgent())
35360	if c.ifNoneMatch_ != "" {
35361		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
35362	}
35363	var body io.Reader = nil
35364	c.urlParams_.Set("alt", alt)
35365	c.urlParams_.Set("prettyPrint", "false")
35366	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+name}")
35367	urls += "?" + c.urlParams_.Encode()
35368	req, err := http.NewRequest("GET", urls, body)
35369	if err != nil {
35370		return nil, err
35371	}
35372	req.Header = reqHeaders
35373	googleapi.Expand(req.URL, map[string]string{
35374		"name": c.name,
35375	})
35376	return gensupport.SendRequest(c.ctx_, c.s.client, req)
35377}
35378
35379// Do executes the "dialogflow.projects.locations.get" call.
35380// Exactly one of *GoogleCloudLocationLocation or error will be non-nil.
35381// Any non-2xx status code is an error. Response headers are in either
35382// *GoogleCloudLocationLocation.ServerResponse.Header or (if a response
35383// was returned at all) in error.(*googleapi.Error).Header. Use
35384// googleapi.IsNotModified to check whether the returned error was
35385// because http.StatusNotModified was returned.
35386func (c *ProjectsLocationsGetCall) Do(opts ...googleapi.CallOption) (*GoogleCloudLocationLocation, error) {
35387	gensupport.SetOptions(c.urlParams_, opts...)
35388	res, err := c.doRequest("json")
35389	if res != nil && res.StatusCode == http.StatusNotModified {
35390		if res.Body != nil {
35391			res.Body.Close()
35392		}
35393		return nil, &googleapi.Error{
35394			Code:   res.StatusCode,
35395			Header: res.Header,
35396		}
35397	}
35398	if err != nil {
35399		return nil, err
35400	}
35401	defer googleapi.CloseBody(res)
35402	if err := googleapi.CheckResponse(res); err != nil {
35403		return nil, err
35404	}
35405	ret := &GoogleCloudLocationLocation{
35406		ServerResponse: googleapi.ServerResponse{
35407			Header:         res.Header,
35408			HTTPStatusCode: res.StatusCode,
35409		},
35410	}
35411	target := &ret
35412	if err := gensupport.DecodeResponse(target, res); err != nil {
35413		return nil, err
35414	}
35415	return ret, nil
35416	// {
35417	//   "description": "Gets information about a location.",
35418	//   "flatPath": "v2/projects/{projectsId}/locations/{locationsId}",
35419	//   "httpMethod": "GET",
35420	//   "id": "dialogflow.projects.locations.get",
35421	//   "parameterOrder": [
35422	//     "name"
35423	//   ],
35424	//   "parameters": {
35425	//     "name": {
35426	//       "description": "Resource name for the location.",
35427	//       "location": "path",
35428	//       "pattern": "^projects/[^/]+/locations/[^/]+$",
35429	//       "required": true,
35430	//       "type": "string"
35431	//     }
35432	//   },
35433	//   "path": "v2/{+name}",
35434	//   "response": {
35435	//     "$ref": "GoogleCloudLocationLocation"
35436	//   },
35437	//   "scopes": [
35438	//     "https://www.googleapis.com/auth/cloud-platform",
35439	//     "https://www.googleapis.com/auth/dialogflow"
35440	//   ]
35441	// }
35442
35443}
35444
35445// method id "dialogflow.projects.locations.getAgent":
35446
35447type ProjectsLocationsGetAgentCall struct {
35448	s            *Service
35449	parent       string
35450	urlParams_   gensupport.URLParams
35451	ifNoneMatch_ string
35452	ctx_         context.Context
35453	header_      http.Header
35454}
35455
35456// GetAgent: Retrieves the specified agent.
35457//
35458// - parent: The project that the agent to fetch is associated with.
35459//   Format: `projects/`.
35460func (r *ProjectsLocationsService) GetAgent(parent string) *ProjectsLocationsGetAgentCall {
35461	c := &ProjectsLocationsGetAgentCall{s: r.s, urlParams_: make(gensupport.URLParams)}
35462	c.parent = parent
35463	return c
35464}
35465
35466// Fields allows partial responses to be retrieved. See
35467// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
35468// for more information.
35469func (c *ProjectsLocationsGetAgentCall) Fields(s ...googleapi.Field) *ProjectsLocationsGetAgentCall {
35470	c.urlParams_.Set("fields", googleapi.CombineFields(s))
35471	return c
35472}
35473
35474// IfNoneMatch sets the optional parameter which makes the operation
35475// fail if the object's ETag matches the given value. This is useful for
35476// getting updates only after the object has changed since the last
35477// request. Use googleapi.IsNotModified to check whether the response
35478// error from Do is the result of In-None-Match.
35479func (c *ProjectsLocationsGetAgentCall) IfNoneMatch(entityTag string) *ProjectsLocationsGetAgentCall {
35480	c.ifNoneMatch_ = entityTag
35481	return c
35482}
35483
35484// Context sets the context to be used in this call's Do method. Any
35485// pending HTTP request will be aborted if the provided context is
35486// canceled.
35487func (c *ProjectsLocationsGetAgentCall) Context(ctx context.Context) *ProjectsLocationsGetAgentCall {
35488	c.ctx_ = ctx
35489	return c
35490}
35491
35492// Header returns an http.Header that can be modified by the caller to
35493// add HTTP headers to the request.
35494func (c *ProjectsLocationsGetAgentCall) Header() http.Header {
35495	if c.header_ == nil {
35496		c.header_ = make(http.Header)
35497	}
35498	return c.header_
35499}
35500
35501func (c *ProjectsLocationsGetAgentCall) doRequest(alt string) (*http.Response, error) {
35502	reqHeaders := make(http.Header)
35503	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20211027")
35504	for k, v := range c.header_ {
35505		reqHeaders[k] = v
35506	}
35507	reqHeaders.Set("User-Agent", c.s.userAgent())
35508	if c.ifNoneMatch_ != "" {
35509		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
35510	}
35511	var body io.Reader = nil
35512	c.urlParams_.Set("alt", alt)
35513	c.urlParams_.Set("prettyPrint", "false")
35514	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+parent}/agent")
35515	urls += "?" + c.urlParams_.Encode()
35516	req, err := http.NewRequest("GET", urls, body)
35517	if err != nil {
35518		return nil, err
35519	}
35520	req.Header = reqHeaders
35521	googleapi.Expand(req.URL, map[string]string{
35522		"parent": c.parent,
35523	})
35524	return gensupport.SendRequest(c.ctx_, c.s.client, req)
35525}
35526
35527// Do executes the "dialogflow.projects.locations.getAgent" call.
35528// Exactly one of *GoogleCloudDialogflowV2Agent or error will be
35529// non-nil. Any non-2xx status code is an error. Response headers are in
35530// either *GoogleCloudDialogflowV2Agent.ServerResponse.Header or (if a
35531// response was returned at all) in error.(*googleapi.Error).Header. Use
35532// googleapi.IsNotModified to check whether the returned error was
35533// because http.StatusNotModified was returned.
35534func (c *ProjectsLocationsGetAgentCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDialogflowV2Agent, error) {
35535	gensupport.SetOptions(c.urlParams_, opts...)
35536	res, err := c.doRequest("json")
35537	if res != nil && res.StatusCode == http.StatusNotModified {
35538		if res.Body != nil {
35539			res.Body.Close()
35540		}
35541		return nil, &googleapi.Error{
35542			Code:   res.StatusCode,
35543			Header: res.Header,
35544		}
35545	}
35546	if err != nil {
35547		return nil, err
35548	}
35549	defer googleapi.CloseBody(res)
35550	if err := googleapi.CheckResponse(res); err != nil {
35551		return nil, err
35552	}
35553	ret := &GoogleCloudDialogflowV2Agent{
35554		ServerResponse: googleapi.ServerResponse{
35555			Header:         res.Header,
35556			HTTPStatusCode: res.StatusCode,
35557		},
35558	}
35559	target := &ret
35560	if err := gensupport.DecodeResponse(target, res); err != nil {
35561		return nil, err
35562	}
35563	return ret, nil
35564	// {
35565	//   "description": "Retrieves the specified agent.",
35566	//   "flatPath": "v2/projects/{projectsId}/locations/{locationsId}/agent",
35567	//   "httpMethod": "GET",
35568	//   "id": "dialogflow.projects.locations.getAgent",
35569	//   "parameterOrder": [
35570	//     "parent"
35571	//   ],
35572	//   "parameters": {
35573	//     "parent": {
35574	//       "description": "Required. The project that the agent to fetch is associated with. Format: `projects/`.",
35575	//       "location": "path",
35576	//       "pattern": "^projects/[^/]+/locations/[^/]+$",
35577	//       "required": true,
35578	//       "type": "string"
35579	//     }
35580	//   },
35581	//   "path": "v2/{+parent}/agent",
35582	//   "response": {
35583	//     "$ref": "GoogleCloudDialogflowV2Agent"
35584	//   },
35585	//   "scopes": [
35586	//     "https://www.googleapis.com/auth/cloud-platform",
35587	//     "https://www.googleapis.com/auth/dialogflow"
35588	//   ]
35589	// }
35590
35591}
35592
35593// method id "dialogflow.projects.locations.list":
35594
35595type ProjectsLocationsListCall struct {
35596	s            *Service
35597	name         string
35598	urlParams_   gensupport.URLParams
35599	ifNoneMatch_ string
35600	ctx_         context.Context
35601	header_      http.Header
35602}
35603
35604// List: Lists information about the supported locations for this
35605// service.
35606//
35607// - name: The resource that owns the locations collection, if
35608//   applicable.
35609func (r *ProjectsLocationsService) List(name string) *ProjectsLocationsListCall {
35610	c := &ProjectsLocationsListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
35611	c.name = name
35612	return c
35613}
35614
35615// Filter sets the optional parameter "filter": A filter to narrow down
35616// results to a preferred subset. The filtering language accepts strings
35617// like "displayName=tokyo", and is documented in more detail in AIP-160
35618// (https://google.aip.dev/160).
35619func (c *ProjectsLocationsListCall) Filter(filter string) *ProjectsLocationsListCall {
35620	c.urlParams_.Set("filter", filter)
35621	return c
35622}
35623
35624// PageSize sets the optional parameter "pageSize": The maximum number
35625// of results to return. If not set, the service selects a default.
35626func (c *ProjectsLocationsListCall) PageSize(pageSize int64) *ProjectsLocationsListCall {
35627	c.urlParams_.Set("pageSize", fmt.Sprint(pageSize))
35628	return c
35629}
35630
35631// PageToken sets the optional parameter "pageToken": A page token
35632// received from the `next_page_token` field in the response. Send that
35633// page token to receive the subsequent page.
35634func (c *ProjectsLocationsListCall) PageToken(pageToken string) *ProjectsLocationsListCall {
35635	c.urlParams_.Set("pageToken", pageToken)
35636	return c
35637}
35638
35639// Fields allows partial responses to be retrieved. See
35640// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
35641// for more information.
35642func (c *ProjectsLocationsListCall) Fields(s ...googleapi.Field) *ProjectsLocationsListCall {
35643	c.urlParams_.Set("fields", googleapi.CombineFields(s))
35644	return c
35645}
35646
35647// IfNoneMatch sets the optional parameter which makes the operation
35648// fail if the object's ETag matches the given value. This is useful for
35649// getting updates only after the object has changed since the last
35650// request. Use googleapi.IsNotModified to check whether the response
35651// error from Do is the result of In-None-Match.
35652func (c *ProjectsLocationsListCall) IfNoneMatch(entityTag string) *ProjectsLocationsListCall {
35653	c.ifNoneMatch_ = entityTag
35654	return c
35655}
35656
35657// Context sets the context to be used in this call's Do method. Any
35658// pending HTTP request will be aborted if the provided context is
35659// canceled.
35660func (c *ProjectsLocationsListCall) Context(ctx context.Context) *ProjectsLocationsListCall {
35661	c.ctx_ = ctx
35662	return c
35663}
35664
35665// Header returns an http.Header that can be modified by the caller to
35666// add HTTP headers to the request.
35667func (c *ProjectsLocationsListCall) Header() http.Header {
35668	if c.header_ == nil {
35669		c.header_ = make(http.Header)
35670	}
35671	return c.header_
35672}
35673
35674func (c *ProjectsLocationsListCall) doRequest(alt string) (*http.Response, error) {
35675	reqHeaders := make(http.Header)
35676	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20211027")
35677	for k, v := range c.header_ {
35678		reqHeaders[k] = v
35679	}
35680	reqHeaders.Set("User-Agent", c.s.userAgent())
35681	if c.ifNoneMatch_ != "" {
35682		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
35683	}
35684	var body io.Reader = nil
35685	c.urlParams_.Set("alt", alt)
35686	c.urlParams_.Set("prettyPrint", "false")
35687	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+name}/locations")
35688	urls += "?" + c.urlParams_.Encode()
35689	req, err := http.NewRequest("GET", urls, body)
35690	if err != nil {
35691		return nil, err
35692	}
35693	req.Header = reqHeaders
35694	googleapi.Expand(req.URL, map[string]string{
35695		"name": c.name,
35696	})
35697	return gensupport.SendRequest(c.ctx_, c.s.client, req)
35698}
35699
35700// Do executes the "dialogflow.projects.locations.list" call.
35701// Exactly one of *GoogleCloudLocationListLocationsResponse or error
35702// will be non-nil. Any non-2xx status code is an error. Response
35703// headers are in either
35704// *GoogleCloudLocationListLocationsResponse.ServerResponse.Header or
35705// (if a response was returned at all) in
35706// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
35707// whether the returned error was because http.StatusNotModified was
35708// returned.
35709func (c *ProjectsLocationsListCall) Do(opts ...googleapi.CallOption) (*GoogleCloudLocationListLocationsResponse, error) {
35710	gensupport.SetOptions(c.urlParams_, opts...)
35711	res, err := c.doRequest("json")
35712	if res != nil && res.StatusCode == http.StatusNotModified {
35713		if res.Body != nil {
35714			res.Body.Close()
35715		}
35716		return nil, &googleapi.Error{
35717			Code:   res.StatusCode,
35718			Header: res.Header,
35719		}
35720	}
35721	if err != nil {
35722		return nil, err
35723	}
35724	defer googleapi.CloseBody(res)
35725	if err := googleapi.CheckResponse(res); err != nil {
35726		return nil, err
35727	}
35728	ret := &GoogleCloudLocationListLocationsResponse{
35729		ServerResponse: googleapi.ServerResponse{
35730			Header:         res.Header,
35731			HTTPStatusCode: res.StatusCode,
35732		},
35733	}
35734	target := &ret
35735	if err := gensupport.DecodeResponse(target, res); err != nil {
35736		return nil, err
35737	}
35738	return ret, nil
35739	// {
35740	//   "description": "Lists information about the supported locations for this service.",
35741	//   "flatPath": "v2/projects/{projectsId}/locations",
35742	//   "httpMethod": "GET",
35743	//   "id": "dialogflow.projects.locations.list",
35744	//   "parameterOrder": [
35745	//     "name"
35746	//   ],
35747	//   "parameters": {
35748	//     "filter": {
35749	//       "description": "A filter to narrow down results to a preferred subset. The filtering language accepts strings like \"displayName=tokyo\", and is documented in more detail in [AIP-160](https://google.aip.dev/160).",
35750	//       "location": "query",
35751	//       "type": "string"
35752	//     },
35753	//     "name": {
35754	//       "description": "The resource that owns the locations collection, if applicable.",
35755	//       "location": "path",
35756	//       "pattern": "^projects/[^/]+$",
35757	//       "required": true,
35758	//       "type": "string"
35759	//     },
35760	//     "pageSize": {
35761	//       "description": "The maximum number of results to return. If not set, the service selects a default.",
35762	//       "format": "int32",
35763	//       "location": "query",
35764	//       "type": "integer"
35765	//     },
35766	//     "pageToken": {
35767	//       "description": "A page token received from the `next_page_token` field in the response. Send that page token to receive the subsequent page.",
35768	//       "location": "query",
35769	//       "type": "string"
35770	//     }
35771	//   },
35772	//   "path": "v2/{+name}/locations",
35773	//   "response": {
35774	//     "$ref": "GoogleCloudLocationListLocationsResponse"
35775	//   },
35776	//   "scopes": [
35777	//     "https://www.googleapis.com/auth/cloud-platform",
35778	//     "https://www.googleapis.com/auth/dialogflow"
35779	//   ]
35780	// }
35781
35782}
35783
35784// Pages invokes f for each page of results.
35785// A non-nil error returned from f will halt the iteration.
35786// The provided context supersedes any context provided to the Context method.
35787func (c *ProjectsLocationsListCall) Pages(ctx context.Context, f func(*GoogleCloudLocationListLocationsResponse) error) error {
35788	c.ctx_ = ctx
35789	defer c.PageToken(c.urlParams_.Get("pageToken")) // reset paging to original point
35790	for {
35791		x, err := c.Do()
35792		if err != nil {
35793			return err
35794		}
35795		if err := f(x); err != nil {
35796			return err
35797		}
35798		if x.NextPageToken == "" {
35799			return nil
35800		}
35801		c.PageToken(x.NextPageToken)
35802	}
35803}
35804
35805// method id "dialogflow.projects.locations.setAgent":
35806
35807type ProjectsLocationsSetAgentCall struct {
35808	s                            *Service
35809	parent                       string
35810	googleclouddialogflowv2agent *GoogleCloudDialogflowV2Agent
35811	urlParams_                   gensupport.URLParams
35812	ctx_                         context.Context
35813	header_                      http.Header
35814}
35815
35816// SetAgent: Creates/updates the specified agent. Note: You should
35817// always train an agent prior to sending it queries. See the training
35818// documentation (https://cloud.google.com/dialogflow/es/docs/training).
35819//
35820// - parent: The project of this agent. Format: `projects/`.
35821func (r *ProjectsLocationsService) SetAgent(parent string, googleclouddialogflowv2agent *GoogleCloudDialogflowV2Agent) *ProjectsLocationsSetAgentCall {
35822	c := &ProjectsLocationsSetAgentCall{s: r.s, urlParams_: make(gensupport.URLParams)}
35823	c.parent = parent
35824	c.googleclouddialogflowv2agent = googleclouddialogflowv2agent
35825	return c
35826}
35827
35828// UpdateMask sets the optional parameter "updateMask": The mask to
35829// control which fields get updated.
35830func (c *ProjectsLocationsSetAgentCall) UpdateMask(updateMask string) *ProjectsLocationsSetAgentCall {
35831	c.urlParams_.Set("updateMask", updateMask)
35832	return c
35833}
35834
35835// Fields allows partial responses to be retrieved. See
35836// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
35837// for more information.
35838func (c *ProjectsLocationsSetAgentCall) Fields(s ...googleapi.Field) *ProjectsLocationsSetAgentCall {
35839	c.urlParams_.Set("fields", googleapi.CombineFields(s))
35840	return c
35841}
35842
35843// Context sets the context to be used in this call's Do method. Any
35844// pending HTTP request will be aborted if the provided context is
35845// canceled.
35846func (c *ProjectsLocationsSetAgentCall) Context(ctx context.Context) *ProjectsLocationsSetAgentCall {
35847	c.ctx_ = ctx
35848	return c
35849}
35850
35851// Header returns an http.Header that can be modified by the caller to
35852// add HTTP headers to the request.
35853func (c *ProjectsLocationsSetAgentCall) Header() http.Header {
35854	if c.header_ == nil {
35855		c.header_ = make(http.Header)
35856	}
35857	return c.header_
35858}
35859
35860func (c *ProjectsLocationsSetAgentCall) doRequest(alt string) (*http.Response, error) {
35861	reqHeaders := make(http.Header)
35862	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20211027")
35863	for k, v := range c.header_ {
35864		reqHeaders[k] = v
35865	}
35866	reqHeaders.Set("User-Agent", c.s.userAgent())
35867	var body io.Reader = nil
35868	body, err := googleapi.WithoutDataWrapper.JSONReader(c.googleclouddialogflowv2agent)
35869	if err != nil {
35870		return nil, err
35871	}
35872	reqHeaders.Set("Content-Type", "application/json")
35873	c.urlParams_.Set("alt", alt)
35874	c.urlParams_.Set("prettyPrint", "false")
35875	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+parent}/agent")
35876	urls += "?" + c.urlParams_.Encode()
35877	req, err := http.NewRequest("POST", urls, body)
35878	if err != nil {
35879		return nil, err
35880	}
35881	req.Header = reqHeaders
35882	googleapi.Expand(req.URL, map[string]string{
35883		"parent": c.parent,
35884	})
35885	return gensupport.SendRequest(c.ctx_, c.s.client, req)
35886}
35887
35888// Do executes the "dialogflow.projects.locations.setAgent" call.
35889// Exactly one of *GoogleCloudDialogflowV2Agent or error will be
35890// non-nil. Any non-2xx status code is an error. Response headers are in
35891// either *GoogleCloudDialogflowV2Agent.ServerResponse.Header or (if a
35892// response was returned at all) in error.(*googleapi.Error).Header. Use
35893// googleapi.IsNotModified to check whether the returned error was
35894// because http.StatusNotModified was returned.
35895func (c *ProjectsLocationsSetAgentCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDialogflowV2Agent, error) {
35896	gensupport.SetOptions(c.urlParams_, opts...)
35897	res, err := c.doRequest("json")
35898	if res != nil && res.StatusCode == http.StatusNotModified {
35899		if res.Body != nil {
35900			res.Body.Close()
35901		}
35902		return nil, &googleapi.Error{
35903			Code:   res.StatusCode,
35904			Header: res.Header,
35905		}
35906	}
35907	if err != nil {
35908		return nil, err
35909	}
35910	defer googleapi.CloseBody(res)
35911	if err := googleapi.CheckResponse(res); err != nil {
35912		return nil, err
35913	}
35914	ret := &GoogleCloudDialogflowV2Agent{
35915		ServerResponse: googleapi.ServerResponse{
35916			Header:         res.Header,
35917			HTTPStatusCode: res.StatusCode,
35918		},
35919	}
35920	target := &ret
35921	if err := gensupport.DecodeResponse(target, res); err != nil {
35922		return nil, err
35923	}
35924	return ret, nil
35925	// {
35926	//   "description": "Creates/updates the specified agent. Note: You should always train an agent prior to sending it queries. See the [training documentation](https://cloud.google.com/dialogflow/es/docs/training).",
35927	//   "flatPath": "v2/projects/{projectsId}/locations/{locationsId}/agent",
35928	//   "httpMethod": "POST",
35929	//   "id": "dialogflow.projects.locations.setAgent",
35930	//   "parameterOrder": [
35931	//     "parent"
35932	//   ],
35933	//   "parameters": {
35934	//     "parent": {
35935	//       "description": "Required. The project of this agent. Format: `projects/`.",
35936	//       "location": "path",
35937	//       "pattern": "^projects/[^/]+/locations/[^/]+$",
35938	//       "required": true,
35939	//       "type": "string"
35940	//     },
35941	//     "updateMask": {
35942	//       "description": "Optional. The mask to control which fields get updated.",
35943	//       "format": "google-fieldmask",
35944	//       "location": "query",
35945	//       "type": "string"
35946	//     }
35947	//   },
35948	//   "path": "v2/{+parent}/agent",
35949	//   "request": {
35950	//     "$ref": "GoogleCloudDialogflowV2Agent"
35951	//   },
35952	//   "response": {
35953	//     "$ref": "GoogleCloudDialogflowV2Agent"
35954	//   },
35955	//   "scopes": [
35956	//     "https://www.googleapis.com/auth/cloud-platform",
35957	//     "https://www.googleapis.com/auth/dialogflow"
35958	//   ]
35959	// }
35960
35961}
35962
35963// method id "dialogflow.projects.locations.agent.export":
35964
35965type ProjectsLocationsAgentExportCall struct {
35966	s                                         *Service
35967	parent                                    string
35968	googleclouddialogflowv2exportagentrequest *GoogleCloudDialogflowV2ExportAgentRequest
35969	urlParams_                                gensupport.URLParams
35970	ctx_                                      context.Context
35971	header_                                   http.Header
35972}
35973
35974// Export: Exports the specified agent to a ZIP file. This method is a
35975// long-running operation
35976// (https://cloud.google.com/dialogflow/es/docs/how/long-running-operations).
35977// The returned `Operation` type has the following method-specific
35978// fields: - `metadata`: An empty Struct message
35979// (https://developers.google.com/protocol-buffers/docs/reference/google.protobuf#struct)
35980// - `response`: ExportAgentResponse
35981//
35982// - parent: The project that the agent to export is associated with.
35983//   Format: `projects/`.
35984func (r *ProjectsLocationsAgentService) Export(parent string, googleclouddialogflowv2exportagentrequest *GoogleCloudDialogflowV2ExportAgentRequest) *ProjectsLocationsAgentExportCall {
35985	c := &ProjectsLocationsAgentExportCall{s: r.s, urlParams_: make(gensupport.URLParams)}
35986	c.parent = parent
35987	c.googleclouddialogflowv2exportagentrequest = googleclouddialogflowv2exportagentrequest
35988	return c
35989}
35990
35991// Fields allows partial responses to be retrieved. See
35992// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
35993// for more information.
35994func (c *ProjectsLocationsAgentExportCall) Fields(s ...googleapi.Field) *ProjectsLocationsAgentExportCall {
35995	c.urlParams_.Set("fields", googleapi.CombineFields(s))
35996	return c
35997}
35998
35999// Context sets the context to be used in this call's Do method. Any
36000// pending HTTP request will be aborted if the provided context is
36001// canceled.
36002func (c *ProjectsLocationsAgentExportCall) Context(ctx context.Context) *ProjectsLocationsAgentExportCall {
36003	c.ctx_ = ctx
36004	return c
36005}
36006
36007// Header returns an http.Header that can be modified by the caller to
36008// add HTTP headers to the request.
36009func (c *ProjectsLocationsAgentExportCall) Header() http.Header {
36010	if c.header_ == nil {
36011		c.header_ = make(http.Header)
36012	}
36013	return c.header_
36014}
36015
36016func (c *ProjectsLocationsAgentExportCall) doRequest(alt string) (*http.Response, error) {
36017	reqHeaders := make(http.Header)
36018	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20211027")
36019	for k, v := range c.header_ {
36020		reqHeaders[k] = v
36021	}
36022	reqHeaders.Set("User-Agent", c.s.userAgent())
36023	var body io.Reader = nil
36024	body, err := googleapi.WithoutDataWrapper.JSONReader(c.googleclouddialogflowv2exportagentrequest)
36025	if err != nil {
36026		return nil, err
36027	}
36028	reqHeaders.Set("Content-Type", "application/json")
36029	c.urlParams_.Set("alt", alt)
36030	c.urlParams_.Set("prettyPrint", "false")
36031	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+parent}/agent:export")
36032	urls += "?" + c.urlParams_.Encode()
36033	req, err := http.NewRequest("POST", urls, body)
36034	if err != nil {
36035		return nil, err
36036	}
36037	req.Header = reqHeaders
36038	googleapi.Expand(req.URL, map[string]string{
36039		"parent": c.parent,
36040	})
36041	return gensupport.SendRequest(c.ctx_, c.s.client, req)
36042}
36043
36044// Do executes the "dialogflow.projects.locations.agent.export" call.
36045// Exactly one of *GoogleLongrunningOperation or error will be non-nil.
36046// Any non-2xx status code is an error. Response headers are in either
36047// *GoogleLongrunningOperation.ServerResponse.Header or (if a response
36048// was returned at all) in error.(*googleapi.Error).Header. Use
36049// googleapi.IsNotModified to check whether the returned error was
36050// because http.StatusNotModified was returned.
36051func (c *ProjectsLocationsAgentExportCall) Do(opts ...googleapi.CallOption) (*GoogleLongrunningOperation, error) {
36052	gensupport.SetOptions(c.urlParams_, opts...)
36053	res, err := c.doRequest("json")
36054	if res != nil && res.StatusCode == http.StatusNotModified {
36055		if res.Body != nil {
36056			res.Body.Close()
36057		}
36058		return nil, &googleapi.Error{
36059			Code:   res.StatusCode,
36060			Header: res.Header,
36061		}
36062	}
36063	if err != nil {
36064		return nil, err
36065	}
36066	defer googleapi.CloseBody(res)
36067	if err := googleapi.CheckResponse(res); err != nil {
36068		return nil, err
36069	}
36070	ret := &GoogleLongrunningOperation{
36071		ServerResponse: googleapi.ServerResponse{
36072			Header:         res.Header,
36073			HTTPStatusCode: res.StatusCode,
36074		},
36075	}
36076	target := &ret
36077	if err := gensupport.DecodeResponse(target, res); err != nil {
36078		return nil, err
36079	}
36080	return ret, nil
36081	// {
36082	//   "description": "Exports the specified agent to a ZIP file. This method is a [long-running operation](https://cloud.google.com/dialogflow/es/docs/how/long-running-operations). The returned `Operation` type has the following method-specific fields: - `metadata`: An empty [Struct message](https://developers.google.com/protocol-buffers/docs/reference/google.protobuf#struct) - `response`: ExportAgentResponse",
36083	//   "flatPath": "v2/projects/{projectsId}/locations/{locationsId}/agent:export",
36084	//   "httpMethod": "POST",
36085	//   "id": "dialogflow.projects.locations.agent.export",
36086	//   "parameterOrder": [
36087	//     "parent"
36088	//   ],
36089	//   "parameters": {
36090	//     "parent": {
36091	//       "description": "Required. The project that the agent to export is associated with. Format: `projects/`.",
36092	//       "location": "path",
36093	//       "pattern": "^projects/[^/]+/locations/[^/]+$",
36094	//       "required": true,
36095	//       "type": "string"
36096	//     }
36097	//   },
36098	//   "path": "v2/{+parent}/agent:export",
36099	//   "request": {
36100	//     "$ref": "GoogleCloudDialogflowV2ExportAgentRequest"
36101	//   },
36102	//   "response": {
36103	//     "$ref": "GoogleLongrunningOperation"
36104	//   },
36105	//   "scopes": [
36106	//     "https://www.googleapis.com/auth/cloud-platform",
36107	//     "https://www.googleapis.com/auth/dialogflow"
36108	//   ]
36109	// }
36110
36111}
36112
36113// method id "dialogflow.projects.locations.agent.getFulfillment":
36114
36115type ProjectsLocationsAgentGetFulfillmentCall struct {
36116	s            *Service
36117	name         string
36118	urlParams_   gensupport.URLParams
36119	ifNoneMatch_ string
36120	ctx_         context.Context
36121	header_      http.Header
36122}
36123
36124// GetFulfillment: Retrieves the fulfillment.
36125//
36126// - name: The name of the fulfillment. Format:
36127//   `projects//agent/fulfillment`.
36128func (r *ProjectsLocationsAgentService) GetFulfillment(name string) *ProjectsLocationsAgentGetFulfillmentCall {
36129	c := &ProjectsLocationsAgentGetFulfillmentCall{s: r.s, urlParams_: make(gensupport.URLParams)}
36130	c.name = name
36131	return c
36132}
36133
36134// Fields allows partial responses to be retrieved. See
36135// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
36136// for more information.
36137func (c *ProjectsLocationsAgentGetFulfillmentCall) Fields(s ...googleapi.Field) *ProjectsLocationsAgentGetFulfillmentCall {
36138	c.urlParams_.Set("fields", googleapi.CombineFields(s))
36139	return c
36140}
36141
36142// IfNoneMatch sets the optional parameter which makes the operation
36143// fail if the object's ETag matches the given value. This is useful for
36144// getting updates only after the object has changed since the last
36145// request. Use googleapi.IsNotModified to check whether the response
36146// error from Do is the result of In-None-Match.
36147func (c *ProjectsLocationsAgentGetFulfillmentCall) IfNoneMatch(entityTag string) *ProjectsLocationsAgentGetFulfillmentCall {
36148	c.ifNoneMatch_ = entityTag
36149	return c
36150}
36151
36152// Context sets the context to be used in this call's Do method. Any
36153// pending HTTP request will be aborted if the provided context is
36154// canceled.
36155func (c *ProjectsLocationsAgentGetFulfillmentCall) Context(ctx context.Context) *ProjectsLocationsAgentGetFulfillmentCall {
36156	c.ctx_ = ctx
36157	return c
36158}
36159
36160// Header returns an http.Header that can be modified by the caller to
36161// add HTTP headers to the request.
36162func (c *ProjectsLocationsAgentGetFulfillmentCall) Header() http.Header {
36163	if c.header_ == nil {
36164		c.header_ = make(http.Header)
36165	}
36166	return c.header_
36167}
36168
36169func (c *ProjectsLocationsAgentGetFulfillmentCall) doRequest(alt string) (*http.Response, error) {
36170	reqHeaders := make(http.Header)
36171	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20211027")
36172	for k, v := range c.header_ {
36173		reqHeaders[k] = v
36174	}
36175	reqHeaders.Set("User-Agent", c.s.userAgent())
36176	if c.ifNoneMatch_ != "" {
36177		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
36178	}
36179	var body io.Reader = nil
36180	c.urlParams_.Set("alt", alt)
36181	c.urlParams_.Set("prettyPrint", "false")
36182	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+name}")
36183	urls += "?" + c.urlParams_.Encode()
36184	req, err := http.NewRequest("GET", urls, body)
36185	if err != nil {
36186		return nil, err
36187	}
36188	req.Header = reqHeaders
36189	googleapi.Expand(req.URL, map[string]string{
36190		"name": c.name,
36191	})
36192	return gensupport.SendRequest(c.ctx_, c.s.client, req)
36193}
36194
36195// Do executes the "dialogflow.projects.locations.agent.getFulfillment" call.
36196// Exactly one of *GoogleCloudDialogflowV2Fulfillment or error will be
36197// non-nil. Any non-2xx status code is an error. Response headers are in
36198// either *GoogleCloudDialogflowV2Fulfillment.ServerResponse.Header or
36199// (if a response was returned at all) in
36200// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
36201// whether the returned error was because http.StatusNotModified was
36202// returned.
36203func (c *ProjectsLocationsAgentGetFulfillmentCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDialogflowV2Fulfillment, error) {
36204	gensupport.SetOptions(c.urlParams_, opts...)
36205	res, err := c.doRequest("json")
36206	if res != nil && res.StatusCode == http.StatusNotModified {
36207		if res.Body != nil {
36208			res.Body.Close()
36209		}
36210		return nil, &googleapi.Error{
36211			Code:   res.StatusCode,
36212			Header: res.Header,
36213		}
36214	}
36215	if err != nil {
36216		return nil, err
36217	}
36218	defer googleapi.CloseBody(res)
36219	if err := googleapi.CheckResponse(res); err != nil {
36220		return nil, err
36221	}
36222	ret := &GoogleCloudDialogflowV2Fulfillment{
36223		ServerResponse: googleapi.ServerResponse{
36224			Header:         res.Header,
36225			HTTPStatusCode: res.StatusCode,
36226		},
36227	}
36228	target := &ret
36229	if err := gensupport.DecodeResponse(target, res); err != nil {
36230		return nil, err
36231	}
36232	return ret, nil
36233	// {
36234	//   "description": "Retrieves the fulfillment.",
36235	//   "flatPath": "v2/projects/{projectsId}/locations/{locationsId}/agent/fulfillment",
36236	//   "httpMethod": "GET",
36237	//   "id": "dialogflow.projects.locations.agent.getFulfillment",
36238	//   "parameterOrder": [
36239	//     "name"
36240	//   ],
36241	//   "parameters": {
36242	//     "name": {
36243	//       "description": "Required. The name of the fulfillment. Format: `projects//agent/fulfillment`.",
36244	//       "location": "path",
36245	//       "pattern": "^projects/[^/]+/locations/[^/]+/agent/fulfillment$",
36246	//       "required": true,
36247	//       "type": "string"
36248	//     }
36249	//   },
36250	//   "path": "v2/{+name}",
36251	//   "response": {
36252	//     "$ref": "GoogleCloudDialogflowV2Fulfillment"
36253	//   },
36254	//   "scopes": [
36255	//     "https://www.googleapis.com/auth/cloud-platform",
36256	//     "https://www.googleapis.com/auth/dialogflow"
36257	//   ]
36258	// }
36259
36260}
36261
36262// method id "dialogflow.projects.locations.agent.getValidationResult":
36263
36264type ProjectsLocationsAgentGetValidationResultCall struct {
36265	s            *Service
36266	parent       string
36267	urlParams_   gensupport.URLParams
36268	ifNoneMatch_ string
36269	ctx_         context.Context
36270	header_      http.Header
36271}
36272
36273// GetValidationResult: Gets agent validation result. Agent validation
36274// is performed during training time and is updated automatically when
36275// training is completed.
36276//
36277// - parent: The project that the agent is associated with. Format:
36278//   `projects/`.
36279func (r *ProjectsLocationsAgentService) GetValidationResult(parent string) *ProjectsLocationsAgentGetValidationResultCall {
36280	c := &ProjectsLocationsAgentGetValidationResultCall{s: r.s, urlParams_: make(gensupport.URLParams)}
36281	c.parent = parent
36282	return c
36283}
36284
36285// LanguageCode sets the optional parameter "languageCode": The language
36286// for which you want a validation result. If not specified, the agent's
36287// default language is used. Many languages
36288// (https://cloud.google.com/dialogflow/docs/reference/language) are
36289// supported. Note: languages must be enabled in the agent before they
36290// can be used.
36291func (c *ProjectsLocationsAgentGetValidationResultCall) LanguageCode(languageCode string) *ProjectsLocationsAgentGetValidationResultCall {
36292	c.urlParams_.Set("languageCode", languageCode)
36293	return c
36294}
36295
36296// Fields allows partial responses to be retrieved. See
36297// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
36298// for more information.
36299func (c *ProjectsLocationsAgentGetValidationResultCall) Fields(s ...googleapi.Field) *ProjectsLocationsAgentGetValidationResultCall {
36300	c.urlParams_.Set("fields", googleapi.CombineFields(s))
36301	return c
36302}
36303
36304// IfNoneMatch sets the optional parameter which makes the operation
36305// fail if the object's ETag matches the given value. This is useful for
36306// getting updates only after the object has changed since the last
36307// request. Use googleapi.IsNotModified to check whether the response
36308// error from Do is the result of In-None-Match.
36309func (c *ProjectsLocationsAgentGetValidationResultCall) IfNoneMatch(entityTag string) *ProjectsLocationsAgentGetValidationResultCall {
36310	c.ifNoneMatch_ = entityTag
36311	return c
36312}
36313
36314// Context sets the context to be used in this call's Do method. Any
36315// pending HTTP request will be aborted if the provided context is
36316// canceled.
36317func (c *ProjectsLocationsAgentGetValidationResultCall) Context(ctx context.Context) *ProjectsLocationsAgentGetValidationResultCall {
36318	c.ctx_ = ctx
36319	return c
36320}
36321
36322// Header returns an http.Header that can be modified by the caller to
36323// add HTTP headers to the request.
36324func (c *ProjectsLocationsAgentGetValidationResultCall) Header() http.Header {
36325	if c.header_ == nil {
36326		c.header_ = make(http.Header)
36327	}
36328	return c.header_
36329}
36330
36331func (c *ProjectsLocationsAgentGetValidationResultCall) doRequest(alt string) (*http.Response, error) {
36332	reqHeaders := make(http.Header)
36333	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20211027")
36334	for k, v := range c.header_ {
36335		reqHeaders[k] = v
36336	}
36337	reqHeaders.Set("User-Agent", c.s.userAgent())
36338	if c.ifNoneMatch_ != "" {
36339		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
36340	}
36341	var body io.Reader = nil
36342	c.urlParams_.Set("alt", alt)
36343	c.urlParams_.Set("prettyPrint", "false")
36344	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+parent}/agent/validationResult")
36345	urls += "?" + c.urlParams_.Encode()
36346	req, err := http.NewRequest("GET", urls, body)
36347	if err != nil {
36348		return nil, err
36349	}
36350	req.Header = reqHeaders
36351	googleapi.Expand(req.URL, map[string]string{
36352		"parent": c.parent,
36353	})
36354	return gensupport.SendRequest(c.ctx_, c.s.client, req)
36355}
36356
36357// Do executes the "dialogflow.projects.locations.agent.getValidationResult" call.
36358// Exactly one of *GoogleCloudDialogflowV2ValidationResult or error will
36359// be non-nil. Any non-2xx status code is an error. Response headers are
36360// in either
36361// *GoogleCloudDialogflowV2ValidationResult.ServerResponse.Header or (if
36362// a response was returned at all) in error.(*googleapi.Error).Header.
36363// Use googleapi.IsNotModified to check whether the returned error was
36364// because http.StatusNotModified was returned.
36365func (c *ProjectsLocationsAgentGetValidationResultCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDialogflowV2ValidationResult, error) {
36366	gensupport.SetOptions(c.urlParams_, opts...)
36367	res, err := c.doRequest("json")
36368	if res != nil && res.StatusCode == http.StatusNotModified {
36369		if res.Body != nil {
36370			res.Body.Close()
36371		}
36372		return nil, &googleapi.Error{
36373			Code:   res.StatusCode,
36374			Header: res.Header,
36375		}
36376	}
36377	if err != nil {
36378		return nil, err
36379	}
36380	defer googleapi.CloseBody(res)
36381	if err := googleapi.CheckResponse(res); err != nil {
36382		return nil, err
36383	}
36384	ret := &GoogleCloudDialogflowV2ValidationResult{
36385		ServerResponse: googleapi.ServerResponse{
36386			Header:         res.Header,
36387			HTTPStatusCode: res.StatusCode,
36388		},
36389	}
36390	target := &ret
36391	if err := gensupport.DecodeResponse(target, res); err != nil {
36392		return nil, err
36393	}
36394	return ret, nil
36395	// {
36396	//   "description": "Gets agent validation result. Agent validation is performed during training time and is updated automatically when training is completed.",
36397	//   "flatPath": "v2/projects/{projectsId}/locations/{locationsId}/agent/validationResult",
36398	//   "httpMethod": "GET",
36399	//   "id": "dialogflow.projects.locations.agent.getValidationResult",
36400	//   "parameterOrder": [
36401	//     "parent"
36402	//   ],
36403	//   "parameters": {
36404	//     "languageCode": {
36405	//       "description": "Optional. The language for which you want a validation result. If not specified, the agent's default language is used. [Many languages](https://cloud.google.com/dialogflow/docs/reference/language) are supported. Note: languages must be enabled in the agent before they can be used.",
36406	//       "location": "query",
36407	//       "type": "string"
36408	//     },
36409	//     "parent": {
36410	//       "description": "Required. The project that the agent is associated with. Format: `projects/`.",
36411	//       "location": "path",
36412	//       "pattern": "^projects/[^/]+/locations/[^/]+$",
36413	//       "required": true,
36414	//       "type": "string"
36415	//     }
36416	//   },
36417	//   "path": "v2/{+parent}/agent/validationResult",
36418	//   "response": {
36419	//     "$ref": "GoogleCloudDialogflowV2ValidationResult"
36420	//   },
36421	//   "scopes": [
36422	//     "https://www.googleapis.com/auth/cloud-platform",
36423	//     "https://www.googleapis.com/auth/dialogflow"
36424	//   ]
36425	// }
36426
36427}
36428
36429// method id "dialogflow.projects.locations.agent.import":
36430
36431type ProjectsLocationsAgentImportCall struct {
36432	s                                         *Service
36433	parent                                    string
36434	googleclouddialogflowv2importagentrequest *GoogleCloudDialogflowV2ImportAgentRequest
36435	urlParams_                                gensupport.URLParams
36436	ctx_                                      context.Context
36437	header_                                   http.Header
36438}
36439
36440// Import: Imports the specified agent from a ZIP file. Uploads new
36441// intents and entity types without deleting the existing ones. Intents
36442// and entity types with the same name are replaced with the new
36443// versions from ImportAgentRequest. After the import, the imported
36444// draft agent will be trained automatically (unless disabled in agent
36445// settings). However, once the import is done, training may not be
36446// completed yet. Please call TrainAgent and wait for the operation it
36447// returns in order to train explicitly. This method is a long-running
36448// operation
36449// (https://cloud.google.com/dialogflow/es/docs/how/long-running-operations).
36450// The returned `Operation` type has the following method-specific
36451// fields: - `metadata`: An empty Struct message
36452// (https://developers.google.com/protocol-buffers/docs/reference/google.protobuf#struct)
36453// - `response`: An Empty message
36454// (https://developers.google.com/protocol-buffers/docs/reference/google.protobuf#empty)
36455// The operation only tracks when importing is complete, not when it is
36456// done training. Note: You should always train an agent prior to
36457// sending it queries. See the training documentation
36458// (https://cloud.google.com/dialogflow/es/docs/training).
36459//
36460// - parent: The project that the agent to import is associated with.
36461//   Format: `projects/`.
36462func (r *ProjectsLocationsAgentService) Import(parent string, googleclouddialogflowv2importagentrequest *GoogleCloudDialogflowV2ImportAgentRequest) *ProjectsLocationsAgentImportCall {
36463	c := &ProjectsLocationsAgentImportCall{s: r.s, urlParams_: make(gensupport.URLParams)}
36464	c.parent = parent
36465	c.googleclouddialogflowv2importagentrequest = googleclouddialogflowv2importagentrequest
36466	return c
36467}
36468
36469// Fields allows partial responses to be retrieved. See
36470// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
36471// for more information.
36472func (c *ProjectsLocationsAgentImportCall) Fields(s ...googleapi.Field) *ProjectsLocationsAgentImportCall {
36473	c.urlParams_.Set("fields", googleapi.CombineFields(s))
36474	return c
36475}
36476
36477// Context sets the context to be used in this call's Do method. Any
36478// pending HTTP request will be aborted if the provided context is
36479// canceled.
36480func (c *ProjectsLocationsAgentImportCall) Context(ctx context.Context) *ProjectsLocationsAgentImportCall {
36481	c.ctx_ = ctx
36482	return c
36483}
36484
36485// Header returns an http.Header that can be modified by the caller to
36486// add HTTP headers to the request.
36487func (c *ProjectsLocationsAgentImportCall) Header() http.Header {
36488	if c.header_ == nil {
36489		c.header_ = make(http.Header)
36490	}
36491	return c.header_
36492}
36493
36494func (c *ProjectsLocationsAgentImportCall) doRequest(alt string) (*http.Response, error) {
36495	reqHeaders := make(http.Header)
36496	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20211027")
36497	for k, v := range c.header_ {
36498		reqHeaders[k] = v
36499	}
36500	reqHeaders.Set("User-Agent", c.s.userAgent())
36501	var body io.Reader = nil
36502	body, err := googleapi.WithoutDataWrapper.JSONReader(c.googleclouddialogflowv2importagentrequest)
36503	if err != nil {
36504		return nil, err
36505	}
36506	reqHeaders.Set("Content-Type", "application/json")
36507	c.urlParams_.Set("alt", alt)
36508	c.urlParams_.Set("prettyPrint", "false")
36509	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+parent}/agent:import")
36510	urls += "?" + c.urlParams_.Encode()
36511	req, err := http.NewRequest("POST", urls, body)
36512	if err != nil {
36513		return nil, err
36514	}
36515	req.Header = reqHeaders
36516	googleapi.Expand(req.URL, map[string]string{
36517		"parent": c.parent,
36518	})
36519	return gensupport.SendRequest(c.ctx_, c.s.client, req)
36520}
36521
36522// Do executes the "dialogflow.projects.locations.agent.import" call.
36523// Exactly one of *GoogleLongrunningOperation or error will be non-nil.
36524// Any non-2xx status code is an error. Response headers are in either
36525// *GoogleLongrunningOperation.ServerResponse.Header or (if a response
36526// was returned at all) in error.(*googleapi.Error).Header. Use
36527// googleapi.IsNotModified to check whether the returned error was
36528// because http.StatusNotModified was returned.
36529func (c *ProjectsLocationsAgentImportCall) Do(opts ...googleapi.CallOption) (*GoogleLongrunningOperation, error) {
36530	gensupport.SetOptions(c.urlParams_, opts...)
36531	res, err := c.doRequest("json")
36532	if res != nil && res.StatusCode == http.StatusNotModified {
36533		if res.Body != nil {
36534			res.Body.Close()
36535		}
36536		return nil, &googleapi.Error{
36537			Code:   res.StatusCode,
36538			Header: res.Header,
36539		}
36540	}
36541	if err != nil {
36542		return nil, err
36543	}
36544	defer googleapi.CloseBody(res)
36545	if err := googleapi.CheckResponse(res); err != nil {
36546		return nil, err
36547	}
36548	ret := &GoogleLongrunningOperation{
36549		ServerResponse: googleapi.ServerResponse{
36550			Header:         res.Header,
36551			HTTPStatusCode: res.StatusCode,
36552		},
36553	}
36554	target := &ret
36555	if err := gensupport.DecodeResponse(target, res); err != nil {
36556		return nil, err
36557	}
36558	return ret, nil
36559	// {
36560	//   "description": "Imports the specified agent from a ZIP file. Uploads new intents and entity types without deleting the existing ones. Intents and entity types with the same name are replaced with the new versions from ImportAgentRequest. After the import, the imported draft agent will be trained automatically (unless disabled in agent settings). However, once the import is done, training may not be completed yet. Please call TrainAgent and wait for the operation it returns in order to train explicitly. This method is a [long-running operation](https://cloud.google.com/dialogflow/es/docs/how/long-running-operations). The returned `Operation` type has the following method-specific fields: - `metadata`: An empty [Struct message](https://developers.google.com/protocol-buffers/docs/reference/google.protobuf#struct) - `response`: An [Empty message](https://developers.google.com/protocol-buffers/docs/reference/google.protobuf#empty) The operation only tracks when importing is complete, not when it is done training. Note: You should always train an agent prior to sending it queries. See the [training documentation](https://cloud.google.com/dialogflow/es/docs/training).",
36561	//   "flatPath": "v2/projects/{projectsId}/locations/{locationsId}/agent:import",
36562	//   "httpMethod": "POST",
36563	//   "id": "dialogflow.projects.locations.agent.import",
36564	//   "parameterOrder": [
36565	//     "parent"
36566	//   ],
36567	//   "parameters": {
36568	//     "parent": {
36569	//       "description": "Required. The project that the agent to import is associated with. Format: `projects/`.",
36570	//       "location": "path",
36571	//       "pattern": "^projects/[^/]+/locations/[^/]+$",
36572	//       "required": true,
36573	//       "type": "string"
36574	//     }
36575	//   },
36576	//   "path": "v2/{+parent}/agent:import",
36577	//   "request": {
36578	//     "$ref": "GoogleCloudDialogflowV2ImportAgentRequest"
36579	//   },
36580	//   "response": {
36581	//     "$ref": "GoogleLongrunningOperation"
36582	//   },
36583	//   "scopes": [
36584	//     "https://www.googleapis.com/auth/cloud-platform",
36585	//     "https://www.googleapis.com/auth/dialogflow"
36586	//   ]
36587	// }
36588
36589}
36590
36591// method id "dialogflow.projects.locations.agent.restore":
36592
36593type ProjectsLocationsAgentRestoreCall struct {
36594	s                                          *Service
36595	parent                                     string
36596	googleclouddialogflowv2restoreagentrequest *GoogleCloudDialogflowV2RestoreAgentRequest
36597	urlParams_                                 gensupport.URLParams
36598	ctx_                                       context.Context
36599	header_                                    http.Header
36600}
36601
36602// Restore: Restores the specified agent from a ZIP file. Replaces the
36603// current agent version with a new one. All the intents and entity
36604// types in the older version are deleted. After the restore, the
36605// restored draft agent will be trained automatically (unless disabled
36606// in agent settings). However, once the restore is done, training may
36607// not be completed yet. Please call TrainAgent and wait for the
36608// operation it returns in order to train explicitly. This method is a
36609// long-running operation
36610// (https://cloud.google.com/dialogflow/es/docs/how/long-running-operations).
36611// The returned `Operation` type has the following method-specific
36612// fields: - `metadata`: An empty Struct message
36613// (https://developers.google.com/protocol-buffers/docs/reference/google.protobuf#struct)
36614// - `response`: An Empty message
36615// (https://developers.google.com/protocol-buffers/docs/reference/google.protobuf#empty)
36616// The operation only tracks when restoring is complete, not when it is
36617// done training. Note: You should always train an agent prior to
36618// sending it queries. See the training documentation
36619// (https://cloud.google.com/dialogflow/es/docs/training).
36620//
36621// - parent: The project that the agent to restore is associated with.
36622//   Format: `projects/`.
36623func (r *ProjectsLocationsAgentService) Restore(parent string, googleclouddialogflowv2restoreagentrequest *GoogleCloudDialogflowV2RestoreAgentRequest) *ProjectsLocationsAgentRestoreCall {
36624	c := &ProjectsLocationsAgentRestoreCall{s: r.s, urlParams_: make(gensupport.URLParams)}
36625	c.parent = parent
36626	c.googleclouddialogflowv2restoreagentrequest = googleclouddialogflowv2restoreagentrequest
36627	return c
36628}
36629
36630// Fields allows partial responses to be retrieved. See
36631// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
36632// for more information.
36633func (c *ProjectsLocationsAgentRestoreCall) Fields(s ...googleapi.Field) *ProjectsLocationsAgentRestoreCall {
36634	c.urlParams_.Set("fields", googleapi.CombineFields(s))
36635	return c
36636}
36637
36638// Context sets the context to be used in this call's Do method. Any
36639// pending HTTP request will be aborted if the provided context is
36640// canceled.
36641func (c *ProjectsLocationsAgentRestoreCall) Context(ctx context.Context) *ProjectsLocationsAgentRestoreCall {
36642	c.ctx_ = ctx
36643	return c
36644}
36645
36646// Header returns an http.Header that can be modified by the caller to
36647// add HTTP headers to the request.
36648func (c *ProjectsLocationsAgentRestoreCall) Header() http.Header {
36649	if c.header_ == nil {
36650		c.header_ = make(http.Header)
36651	}
36652	return c.header_
36653}
36654
36655func (c *ProjectsLocationsAgentRestoreCall) doRequest(alt string) (*http.Response, error) {
36656	reqHeaders := make(http.Header)
36657	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20211027")
36658	for k, v := range c.header_ {
36659		reqHeaders[k] = v
36660	}
36661	reqHeaders.Set("User-Agent", c.s.userAgent())
36662	var body io.Reader = nil
36663	body, err := googleapi.WithoutDataWrapper.JSONReader(c.googleclouddialogflowv2restoreagentrequest)
36664	if err != nil {
36665		return nil, err
36666	}
36667	reqHeaders.Set("Content-Type", "application/json")
36668	c.urlParams_.Set("alt", alt)
36669	c.urlParams_.Set("prettyPrint", "false")
36670	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+parent}/agent:restore")
36671	urls += "?" + c.urlParams_.Encode()
36672	req, err := http.NewRequest("POST", urls, body)
36673	if err != nil {
36674		return nil, err
36675	}
36676	req.Header = reqHeaders
36677	googleapi.Expand(req.URL, map[string]string{
36678		"parent": c.parent,
36679	})
36680	return gensupport.SendRequest(c.ctx_, c.s.client, req)
36681}
36682
36683// Do executes the "dialogflow.projects.locations.agent.restore" call.
36684// Exactly one of *GoogleLongrunningOperation or error will be non-nil.
36685// Any non-2xx status code is an error. Response headers are in either
36686// *GoogleLongrunningOperation.ServerResponse.Header or (if a response
36687// was returned at all) in error.(*googleapi.Error).Header. Use
36688// googleapi.IsNotModified to check whether the returned error was
36689// because http.StatusNotModified was returned.
36690func (c *ProjectsLocationsAgentRestoreCall) Do(opts ...googleapi.CallOption) (*GoogleLongrunningOperation, error) {
36691	gensupport.SetOptions(c.urlParams_, opts...)
36692	res, err := c.doRequest("json")
36693	if res != nil && res.StatusCode == http.StatusNotModified {
36694		if res.Body != nil {
36695			res.Body.Close()
36696		}
36697		return nil, &googleapi.Error{
36698			Code:   res.StatusCode,
36699			Header: res.Header,
36700		}
36701	}
36702	if err != nil {
36703		return nil, err
36704	}
36705	defer googleapi.CloseBody(res)
36706	if err := googleapi.CheckResponse(res); err != nil {
36707		return nil, err
36708	}
36709	ret := &GoogleLongrunningOperation{
36710		ServerResponse: googleapi.ServerResponse{
36711			Header:         res.Header,
36712			HTTPStatusCode: res.StatusCode,
36713		},
36714	}
36715	target := &ret
36716	if err := gensupport.DecodeResponse(target, res); err != nil {
36717		return nil, err
36718	}
36719	return ret, nil
36720	// {
36721	//   "description": "Restores the specified agent from a ZIP file. Replaces the current agent version with a new one. All the intents and entity types in the older version are deleted. After the restore, the restored draft agent will be trained automatically (unless disabled in agent settings). However, once the restore is done, training may not be completed yet. Please call TrainAgent and wait for the operation it returns in order to train explicitly. This method is a [long-running operation](https://cloud.google.com/dialogflow/es/docs/how/long-running-operations). The returned `Operation` type has the following method-specific fields: - `metadata`: An empty [Struct message](https://developers.google.com/protocol-buffers/docs/reference/google.protobuf#struct) - `response`: An [Empty message](https://developers.google.com/protocol-buffers/docs/reference/google.protobuf#empty) The operation only tracks when restoring is complete, not when it is done training. Note: You should always train an agent prior to sending it queries. See the [training documentation](https://cloud.google.com/dialogflow/es/docs/training).",
36722	//   "flatPath": "v2/projects/{projectsId}/locations/{locationsId}/agent:restore",
36723	//   "httpMethod": "POST",
36724	//   "id": "dialogflow.projects.locations.agent.restore",
36725	//   "parameterOrder": [
36726	//     "parent"
36727	//   ],
36728	//   "parameters": {
36729	//     "parent": {
36730	//       "description": "Required. The project that the agent to restore is associated with. Format: `projects/`.",
36731	//       "location": "path",
36732	//       "pattern": "^projects/[^/]+/locations/[^/]+$",
36733	//       "required": true,
36734	//       "type": "string"
36735	//     }
36736	//   },
36737	//   "path": "v2/{+parent}/agent:restore",
36738	//   "request": {
36739	//     "$ref": "GoogleCloudDialogflowV2RestoreAgentRequest"
36740	//   },
36741	//   "response": {
36742	//     "$ref": "GoogleLongrunningOperation"
36743	//   },
36744	//   "scopes": [
36745	//     "https://www.googleapis.com/auth/cloud-platform",
36746	//     "https://www.googleapis.com/auth/dialogflow"
36747	//   ]
36748	// }
36749
36750}
36751
36752// method id "dialogflow.projects.locations.agent.search":
36753
36754type ProjectsLocationsAgentSearchCall struct {
36755	s            *Service
36756	parent       string
36757	urlParams_   gensupport.URLParams
36758	ifNoneMatch_ string
36759	ctx_         context.Context
36760	header_      http.Header
36761}
36762
36763// Search: Returns the list of agents. Since there is at most one
36764// conversational agent per project, this method is useful primarily for
36765// listing all agents across projects the caller has access to. One can
36766// achieve that with a wildcard project collection id "-". Refer to List
36767// Sub-Collections
36768// (https://cloud.google.com/apis/design/design_patterns#list_sub-collections).
36769//
36770// - parent: The project to list agents from. Format: `projects/`.
36771func (r *ProjectsLocationsAgentService) Search(parent string) *ProjectsLocationsAgentSearchCall {
36772	c := &ProjectsLocationsAgentSearchCall{s: r.s, urlParams_: make(gensupport.URLParams)}
36773	c.parent = parent
36774	return c
36775}
36776
36777// PageSize sets the optional parameter "pageSize": The maximum number
36778// of items to return in a single page. By default 100 and at most 1000.
36779func (c *ProjectsLocationsAgentSearchCall) PageSize(pageSize int64) *ProjectsLocationsAgentSearchCall {
36780	c.urlParams_.Set("pageSize", fmt.Sprint(pageSize))
36781	return c
36782}
36783
36784// PageToken sets the optional parameter "pageToken": The
36785// next_page_token value returned from a previous list request.
36786func (c *ProjectsLocationsAgentSearchCall) PageToken(pageToken string) *ProjectsLocationsAgentSearchCall {
36787	c.urlParams_.Set("pageToken", pageToken)
36788	return c
36789}
36790
36791// Fields allows partial responses to be retrieved. See
36792// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
36793// for more information.
36794func (c *ProjectsLocationsAgentSearchCall) Fields(s ...googleapi.Field) *ProjectsLocationsAgentSearchCall {
36795	c.urlParams_.Set("fields", googleapi.CombineFields(s))
36796	return c
36797}
36798
36799// IfNoneMatch sets the optional parameter which makes the operation
36800// fail if the object's ETag matches the given value. This is useful for
36801// getting updates only after the object has changed since the last
36802// request. Use googleapi.IsNotModified to check whether the response
36803// error from Do is the result of In-None-Match.
36804func (c *ProjectsLocationsAgentSearchCall) IfNoneMatch(entityTag string) *ProjectsLocationsAgentSearchCall {
36805	c.ifNoneMatch_ = entityTag
36806	return c
36807}
36808
36809// Context sets the context to be used in this call's Do method. Any
36810// pending HTTP request will be aborted if the provided context is
36811// canceled.
36812func (c *ProjectsLocationsAgentSearchCall) Context(ctx context.Context) *ProjectsLocationsAgentSearchCall {
36813	c.ctx_ = ctx
36814	return c
36815}
36816
36817// Header returns an http.Header that can be modified by the caller to
36818// add HTTP headers to the request.
36819func (c *ProjectsLocationsAgentSearchCall) Header() http.Header {
36820	if c.header_ == nil {
36821		c.header_ = make(http.Header)
36822	}
36823	return c.header_
36824}
36825
36826func (c *ProjectsLocationsAgentSearchCall) doRequest(alt string) (*http.Response, error) {
36827	reqHeaders := make(http.Header)
36828	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20211027")
36829	for k, v := range c.header_ {
36830		reqHeaders[k] = v
36831	}
36832	reqHeaders.Set("User-Agent", c.s.userAgent())
36833	if c.ifNoneMatch_ != "" {
36834		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
36835	}
36836	var body io.Reader = nil
36837	c.urlParams_.Set("alt", alt)
36838	c.urlParams_.Set("prettyPrint", "false")
36839	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+parent}/agent:search")
36840	urls += "?" + c.urlParams_.Encode()
36841	req, err := http.NewRequest("GET", urls, body)
36842	if err != nil {
36843		return nil, err
36844	}
36845	req.Header = reqHeaders
36846	googleapi.Expand(req.URL, map[string]string{
36847		"parent": c.parent,
36848	})
36849	return gensupport.SendRequest(c.ctx_, c.s.client, req)
36850}
36851
36852// Do executes the "dialogflow.projects.locations.agent.search" call.
36853// Exactly one of *GoogleCloudDialogflowV2SearchAgentsResponse or error
36854// will be non-nil. Any non-2xx status code is an error. Response
36855// headers are in either
36856// *GoogleCloudDialogflowV2SearchAgentsResponse.ServerResponse.Header or
36857// (if a response was returned at all) in
36858// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
36859// whether the returned error was because http.StatusNotModified was
36860// returned.
36861func (c *ProjectsLocationsAgentSearchCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDialogflowV2SearchAgentsResponse, error) {
36862	gensupport.SetOptions(c.urlParams_, opts...)
36863	res, err := c.doRequest("json")
36864	if res != nil && res.StatusCode == http.StatusNotModified {
36865		if res.Body != nil {
36866			res.Body.Close()
36867		}
36868		return nil, &googleapi.Error{
36869			Code:   res.StatusCode,
36870			Header: res.Header,
36871		}
36872	}
36873	if err != nil {
36874		return nil, err
36875	}
36876	defer googleapi.CloseBody(res)
36877	if err := googleapi.CheckResponse(res); err != nil {
36878		return nil, err
36879	}
36880	ret := &GoogleCloudDialogflowV2SearchAgentsResponse{
36881		ServerResponse: googleapi.ServerResponse{
36882			Header:         res.Header,
36883			HTTPStatusCode: res.StatusCode,
36884		},
36885	}
36886	target := &ret
36887	if err := gensupport.DecodeResponse(target, res); err != nil {
36888		return nil, err
36889	}
36890	return ret, nil
36891	// {
36892	//   "description": "Returns the list of agents. Since there is at most one conversational agent per project, this method is useful primarily for listing all agents across projects the caller has access to. One can achieve that with a wildcard project collection id \"-\". Refer to [List Sub-Collections](https://cloud.google.com/apis/design/design_patterns#list_sub-collections).",
36893	//   "flatPath": "v2/projects/{projectsId}/locations/{locationsId}/agent:search",
36894	//   "httpMethod": "GET",
36895	//   "id": "dialogflow.projects.locations.agent.search",
36896	//   "parameterOrder": [
36897	//     "parent"
36898	//   ],
36899	//   "parameters": {
36900	//     "pageSize": {
36901	//       "description": "Optional. The maximum number of items to return in a single page. By default 100 and at most 1000.",
36902	//       "format": "int32",
36903	//       "location": "query",
36904	//       "type": "integer"
36905	//     },
36906	//     "pageToken": {
36907	//       "description": "The next_page_token value returned from a previous list request.",
36908	//       "location": "query",
36909	//       "type": "string"
36910	//     },
36911	//     "parent": {
36912	//       "description": "Required. The project to list agents from. Format: `projects/`.",
36913	//       "location": "path",
36914	//       "pattern": "^projects/[^/]+/locations/[^/]+$",
36915	//       "required": true,
36916	//       "type": "string"
36917	//     }
36918	//   },
36919	//   "path": "v2/{+parent}/agent:search",
36920	//   "response": {
36921	//     "$ref": "GoogleCloudDialogflowV2SearchAgentsResponse"
36922	//   },
36923	//   "scopes": [
36924	//     "https://www.googleapis.com/auth/cloud-platform",
36925	//     "https://www.googleapis.com/auth/dialogflow"
36926	//   ]
36927	// }
36928
36929}
36930
36931// Pages invokes f for each page of results.
36932// A non-nil error returned from f will halt the iteration.
36933// The provided context supersedes any context provided to the Context method.
36934func (c *ProjectsLocationsAgentSearchCall) Pages(ctx context.Context, f func(*GoogleCloudDialogflowV2SearchAgentsResponse) error) error {
36935	c.ctx_ = ctx
36936	defer c.PageToken(c.urlParams_.Get("pageToken")) // reset paging to original point
36937	for {
36938		x, err := c.Do()
36939		if err != nil {
36940			return err
36941		}
36942		if err := f(x); err != nil {
36943			return err
36944		}
36945		if x.NextPageToken == "" {
36946			return nil
36947		}
36948		c.PageToken(x.NextPageToken)
36949	}
36950}
36951
36952// method id "dialogflow.projects.locations.agent.train":
36953
36954type ProjectsLocationsAgentTrainCall struct {
36955	s                                        *Service
36956	parent                                   string
36957	googleclouddialogflowv2trainagentrequest *GoogleCloudDialogflowV2TrainAgentRequest
36958	urlParams_                               gensupport.URLParams
36959	ctx_                                     context.Context
36960	header_                                  http.Header
36961}
36962
36963// Train: Trains the specified agent. This method is a long-running
36964// operation
36965// (https://cloud.google.com/dialogflow/es/docs/how/long-running-operations).
36966// The returned `Operation` type has the following method-specific
36967// fields: - `metadata`: An empty Struct message
36968// (https://developers.google.com/protocol-buffers/docs/reference/google.protobuf#struct)
36969// - `response`: An Empty message
36970// (https://developers.google.com/protocol-buffers/docs/reference/google.protobuf#empty)
36971// Note: You should always train an agent prior to sending it queries.
36972// See the training documentation
36973// (https://cloud.google.com/dialogflow/es/docs/training).
36974//
36975// - parent: The project that the agent to train is associated with.
36976//   Format: `projects/`.
36977func (r *ProjectsLocationsAgentService) Train(parent string, googleclouddialogflowv2trainagentrequest *GoogleCloudDialogflowV2TrainAgentRequest) *ProjectsLocationsAgentTrainCall {
36978	c := &ProjectsLocationsAgentTrainCall{s: r.s, urlParams_: make(gensupport.URLParams)}
36979	c.parent = parent
36980	c.googleclouddialogflowv2trainagentrequest = googleclouddialogflowv2trainagentrequest
36981	return c
36982}
36983
36984// Fields allows partial responses to be retrieved. See
36985// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
36986// for more information.
36987func (c *ProjectsLocationsAgentTrainCall) Fields(s ...googleapi.Field) *ProjectsLocationsAgentTrainCall {
36988	c.urlParams_.Set("fields", googleapi.CombineFields(s))
36989	return c
36990}
36991
36992// Context sets the context to be used in this call's Do method. Any
36993// pending HTTP request will be aborted if the provided context is
36994// canceled.
36995func (c *ProjectsLocationsAgentTrainCall) Context(ctx context.Context) *ProjectsLocationsAgentTrainCall {
36996	c.ctx_ = ctx
36997	return c
36998}
36999
37000// Header returns an http.Header that can be modified by the caller to
37001// add HTTP headers to the request.
37002func (c *ProjectsLocationsAgentTrainCall) Header() http.Header {
37003	if c.header_ == nil {
37004		c.header_ = make(http.Header)
37005	}
37006	return c.header_
37007}
37008
37009func (c *ProjectsLocationsAgentTrainCall) doRequest(alt string) (*http.Response, error) {
37010	reqHeaders := make(http.Header)
37011	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20211027")
37012	for k, v := range c.header_ {
37013		reqHeaders[k] = v
37014	}
37015	reqHeaders.Set("User-Agent", c.s.userAgent())
37016	var body io.Reader = nil
37017	body, err := googleapi.WithoutDataWrapper.JSONReader(c.googleclouddialogflowv2trainagentrequest)
37018	if err != nil {
37019		return nil, err
37020	}
37021	reqHeaders.Set("Content-Type", "application/json")
37022	c.urlParams_.Set("alt", alt)
37023	c.urlParams_.Set("prettyPrint", "false")
37024	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+parent}/agent:train")
37025	urls += "?" + c.urlParams_.Encode()
37026	req, err := http.NewRequest("POST", urls, body)
37027	if err != nil {
37028		return nil, err
37029	}
37030	req.Header = reqHeaders
37031	googleapi.Expand(req.URL, map[string]string{
37032		"parent": c.parent,
37033	})
37034	return gensupport.SendRequest(c.ctx_, c.s.client, req)
37035}
37036
37037// Do executes the "dialogflow.projects.locations.agent.train" call.
37038// Exactly one of *GoogleLongrunningOperation or error will be non-nil.
37039// Any non-2xx status code is an error. Response headers are in either
37040// *GoogleLongrunningOperation.ServerResponse.Header or (if a response
37041// was returned at all) in error.(*googleapi.Error).Header. Use
37042// googleapi.IsNotModified to check whether the returned error was
37043// because http.StatusNotModified was returned.
37044func (c *ProjectsLocationsAgentTrainCall) Do(opts ...googleapi.CallOption) (*GoogleLongrunningOperation, error) {
37045	gensupport.SetOptions(c.urlParams_, opts...)
37046	res, err := c.doRequest("json")
37047	if res != nil && res.StatusCode == http.StatusNotModified {
37048		if res.Body != nil {
37049			res.Body.Close()
37050		}
37051		return nil, &googleapi.Error{
37052			Code:   res.StatusCode,
37053			Header: res.Header,
37054		}
37055	}
37056	if err != nil {
37057		return nil, err
37058	}
37059	defer googleapi.CloseBody(res)
37060	if err := googleapi.CheckResponse(res); err != nil {
37061		return nil, err
37062	}
37063	ret := &GoogleLongrunningOperation{
37064		ServerResponse: googleapi.ServerResponse{
37065			Header:         res.Header,
37066			HTTPStatusCode: res.StatusCode,
37067		},
37068	}
37069	target := &ret
37070	if err := gensupport.DecodeResponse(target, res); err != nil {
37071		return nil, err
37072	}
37073	return ret, nil
37074	// {
37075	//   "description": "Trains the specified agent. This method is a [long-running operation](https://cloud.google.com/dialogflow/es/docs/how/long-running-operations). The returned `Operation` type has the following method-specific fields: - `metadata`: An empty [Struct message](https://developers.google.com/protocol-buffers/docs/reference/google.protobuf#struct) - `response`: An [Empty message](https://developers.google.com/protocol-buffers/docs/reference/google.protobuf#empty) Note: You should always train an agent prior to sending it queries. See the [training documentation](https://cloud.google.com/dialogflow/es/docs/training).",
37076	//   "flatPath": "v2/projects/{projectsId}/locations/{locationsId}/agent:train",
37077	//   "httpMethod": "POST",
37078	//   "id": "dialogflow.projects.locations.agent.train",
37079	//   "parameterOrder": [
37080	//     "parent"
37081	//   ],
37082	//   "parameters": {
37083	//     "parent": {
37084	//       "description": "Required. The project that the agent to train is associated with. Format: `projects/`.",
37085	//       "location": "path",
37086	//       "pattern": "^projects/[^/]+/locations/[^/]+$",
37087	//       "required": true,
37088	//       "type": "string"
37089	//     }
37090	//   },
37091	//   "path": "v2/{+parent}/agent:train",
37092	//   "request": {
37093	//     "$ref": "GoogleCloudDialogflowV2TrainAgentRequest"
37094	//   },
37095	//   "response": {
37096	//     "$ref": "GoogleLongrunningOperation"
37097	//   },
37098	//   "scopes": [
37099	//     "https://www.googleapis.com/auth/cloud-platform",
37100	//     "https://www.googleapis.com/auth/dialogflow"
37101	//   ]
37102	// }
37103
37104}
37105
37106// method id "dialogflow.projects.locations.agent.updateFulfillment":
37107
37108type ProjectsLocationsAgentUpdateFulfillmentCall struct {
37109	s                                  *Service
37110	nameid                             string
37111	googleclouddialogflowv2fulfillment *GoogleCloudDialogflowV2Fulfillment
37112	urlParams_                         gensupport.URLParams
37113	ctx_                               context.Context
37114	header_                            http.Header
37115}
37116
37117// UpdateFulfillment: Updates the fulfillment.
37118//
37119// - name: The unique identifier of the fulfillment. Supported formats:
37120//   - `projects//agent/fulfillment` -
37121//   `projects//locations//agent/fulfillment` This field is not used for
37122//   Fulfillment in an Environment.
37123func (r *ProjectsLocationsAgentService) UpdateFulfillment(nameid string, googleclouddialogflowv2fulfillment *GoogleCloudDialogflowV2Fulfillment) *ProjectsLocationsAgentUpdateFulfillmentCall {
37124	c := &ProjectsLocationsAgentUpdateFulfillmentCall{s: r.s, urlParams_: make(gensupport.URLParams)}
37125	c.nameid = nameid
37126	c.googleclouddialogflowv2fulfillment = googleclouddialogflowv2fulfillment
37127	return c
37128}
37129
37130// UpdateMask sets the optional parameter "updateMask": Required. The
37131// mask to control which fields get updated. If the mask is not present,
37132// all fields will be updated.
37133func (c *ProjectsLocationsAgentUpdateFulfillmentCall) UpdateMask(updateMask string) *ProjectsLocationsAgentUpdateFulfillmentCall {
37134	c.urlParams_.Set("updateMask", updateMask)
37135	return c
37136}
37137
37138// Fields allows partial responses to be retrieved. See
37139// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
37140// for more information.
37141func (c *ProjectsLocationsAgentUpdateFulfillmentCall) Fields(s ...googleapi.Field) *ProjectsLocationsAgentUpdateFulfillmentCall {
37142	c.urlParams_.Set("fields", googleapi.CombineFields(s))
37143	return c
37144}
37145
37146// Context sets the context to be used in this call's Do method. Any
37147// pending HTTP request will be aborted if the provided context is
37148// canceled.
37149func (c *ProjectsLocationsAgentUpdateFulfillmentCall) Context(ctx context.Context) *ProjectsLocationsAgentUpdateFulfillmentCall {
37150	c.ctx_ = ctx
37151	return c
37152}
37153
37154// Header returns an http.Header that can be modified by the caller to
37155// add HTTP headers to the request.
37156func (c *ProjectsLocationsAgentUpdateFulfillmentCall) Header() http.Header {
37157	if c.header_ == nil {
37158		c.header_ = make(http.Header)
37159	}
37160	return c.header_
37161}
37162
37163func (c *ProjectsLocationsAgentUpdateFulfillmentCall) doRequest(alt string) (*http.Response, error) {
37164	reqHeaders := make(http.Header)
37165	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20211027")
37166	for k, v := range c.header_ {
37167		reqHeaders[k] = v
37168	}
37169	reqHeaders.Set("User-Agent", c.s.userAgent())
37170	var body io.Reader = nil
37171	body, err := googleapi.WithoutDataWrapper.JSONReader(c.googleclouddialogflowv2fulfillment)
37172	if err != nil {
37173		return nil, err
37174	}
37175	reqHeaders.Set("Content-Type", "application/json")
37176	c.urlParams_.Set("alt", alt)
37177	c.urlParams_.Set("prettyPrint", "false")
37178	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+name}")
37179	urls += "?" + c.urlParams_.Encode()
37180	req, err := http.NewRequest("PATCH", urls, body)
37181	if err != nil {
37182		return nil, err
37183	}
37184	req.Header = reqHeaders
37185	googleapi.Expand(req.URL, map[string]string{
37186		"name": c.nameid,
37187	})
37188	return gensupport.SendRequest(c.ctx_, c.s.client, req)
37189}
37190
37191// Do executes the "dialogflow.projects.locations.agent.updateFulfillment" call.
37192// Exactly one of *GoogleCloudDialogflowV2Fulfillment or error will be
37193// non-nil. Any non-2xx status code is an error. Response headers are in
37194// either *GoogleCloudDialogflowV2Fulfillment.ServerResponse.Header or
37195// (if a response was returned at all) in
37196// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
37197// whether the returned error was because http.StatusNotModified was
37198// returned.
37199func (c *ProjectsLocationsAgentUpdateFulfillmentCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDialogflowV2Fulfillment, error) {
37200	gensupport.SetOptions(c.urlParams_, opts...)
37201	res, err := c.doRequest("json")
37202	if res != nil && res.StatusCode == http.StatusNotModified {
37203		if res.Body != nil {
37204			res.Body.Close()
37205		}
37206		return nil, &googleapi.Error{
37207			Code:   res.StatusCode,
37208			Header: res.Header,
37209		}
37210	}
37211	if err != nil {
37212		return nil, err
37213	}
37214	defer googleapi.CloseBody(res)
37215	if err := googleapi.CheckResponse(res); err != nil {
37216		return nil, err
37217	}
37218	ret := &GoogleCloudDialogflowV2Fulfillment{
37219		ServerResponse: googleapi.ServerResponse{
37220			Header:         res.Header,
37221			HTTPStatusCode: res.StatusCode,
37222		},
37223	}
37224	target := &ret
37225	if err := gensupport.DecodeResponse(target, res); err != nil {
37226		return nil, err
37227	}
37228	return ret, nil
37229	// {
37230	//   "description": "Updates the fulfillment.",
37231	//   "flatPath": "v2/projects/{projectsId}/locations/{locationsId}/agent/fulfillment",
37232	//   "httpMethod": "PATCH",
37233	//   "id": "dialogflow.projects.locations.agent.updateFulfillment",
37234	//   "parameterOrder": [
37235	//     "name"
37236	//   ],
37237	//   "parameters": {
37238	//     "name": {
37239	//       "description": "Required. The unique identifier of the fulfillment. Supported formats: - `projects//agent/fulfillment` - `projects//locations//agent/fulfillment` This field is not used for Fulfillment in an Environment.",
37240	//       "location": "path",
37241	//       "pattern": "^projects/[^/]+/locations/[^/]+/agent/fulfillment$",
37242	//       "required": true,
37243	//       "type": "string"
37244	//     },
37245	//     "updateMask": {
37246	//       "description": "Required. The mask to control which fields get updated. If the mask is not present, all fields will be updated.",
37247	//       "format": "google-fieldmask",
37248	//       "location": "query",
37249	//       "type": "string"
37250	//     }
37251	//   },
37252	//   "path": "v2/{+name}",
37253	//   "request": {
37254	//     "$ref": "GoogleCloudDialogflowV2Fulfillment"
37255	//   },
37256	//   "response": {
37257	//     "$ref": "GoogleCloudDialogflowV2Fulfillment"
37258	//   },
37259	//   "scopes": [
37260	//     "https://www.googleapis.com/auth/cloud-platform",
37261	//     "https://www.googleapis.com/auth/dialogflow"
37262	//   ]
37263	// }
37264
37265}
37266
37267// method id "dialogflow.projects.locations.agent.entityTypes.batchDelete":
37268
37269type ProjectsLocationsAgentEntityTypesBatchDeleteCall struct {
37270	s                                                    *Service
37271	parent                                               string
37272	googleclouddialogflowv2batchdeleteentitytypesrequest *GoogleCloudDialogflowV2BatchDeleteEntityTypesRequest
37273	urlParams_                                           gensupport.URLParams
37274	ctx_                                                 context.Context
37275	header_                                              http.Header
37276}
37277
37278// BatchDelete: Deletes entity types in the specified agent. This method
37279// is a long-running operation
37280// (https://cloud.google.com/dialogflow/es/docs/how/long-running-operations).
37281// The returned `Operation` type has the following method-specific
37282// fields: - `metadata`: An empty Struct message
37283// (https://developers.google.com/protocol-buffers/docs/reference/google.protobuf#struct)
37284// - `response`: An Empty message
37285// (https://developers.google.com/protocol-buffers/docs/reference/google.protobuf#empty)
37286// Note: You should always train an agent prior to sending it queries.
37287// See the training documentation
37288// (https://cloud.google.com/dialogflow/es/docs/training).
37289//
37290// - parent: The name of the agent to delete all entities types for.
37291//   Format: `projects//agent`.
37292func (r *ProjectsLocationsAgentEntityTypesService) BatchDelete(parent string, googleclouddialogflowv2batchdeleteentitytypesrequest *GoogleCloudDialogflowV2BatchDeleteEntityTypesRequest) *ProjectsLocationsAgentEntityTypesBatchDeleteCall {
37293	c := &ProjectsLocationsAgentEntityTypesBatchDeleteCall{s: r.s, urlParams_: make(gensupport.URLParams)}
37294	c.parent = parent
37295	c.googleclouddialogflowv2batchdeleteentitytypesrequest = googleclouddialogflowv2batchdeleteentitytypesrequest
37296	return c
37297}
37298
37299// Fields allows partial responses to be retrieved. See
37300// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
37301// for more information.
37302func (c *ProjectsLocationsAgentEntityTypesBatchDeleteCall) Fields(s ...googleapi.Field) *ProjectsLocationsAgentEntityTypesBatchDeleteCall {
37303	c.urlParams_.Set("fields", googleapi.CombineFields(s))
37304	return c
37305}
37306
37307// Context sets the context to be used in this call's Do method. Any
37308// pending HTTP request will be aborted if the provided context is
37309// canceled.
37310func (c *ProjectsLocationsAgentEntityTypesBatchDeleteCall) Context(ctx context.Context) *ProjectsLocationsAgentEntityTypesBatchDeleteCall {
37311	c.ctx_ = ctx
37312	return c
37313}
37314
37315// Header returns an http.Header that can be modified by the caller to
37316// add HTTP headers to the request.
37317func (c *ProjectsLocationsAgentEntityTypesBatchDeleteCall) Header() http.Header {
37318	if c.header_ == nil {
37319		c.header_ = make(http.Header)
37320	}
37321	return c.header_
37322}
37323
37324func (c *ProjectsLocationsAgentEntityTypesBatchDeleteCall) doRequest(alt string) (*http.Response, error) {
37325	reqHeaders := make(http.Header)
37326	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20211027")
37327	for k, v := range c.header_ {
37328		reqHeaders[k] = v
37329	}
37330	reqHeaders.Set("User-Agent", c.s.userAgent())
37331	var body io.Reader = nil
37332	body, err := googleapi.WithoutDataWrapper.JSONReader(c.googleclouddialogflowv2batchdeleteentitytypesrequest)
37333	if err != nil {
37334		return nil, err
37335	}
37336	reqHeaders.Set("Content-Type", "application/json")
37337	c.urlParams_.Set("alt", alt)
37338	c.urlParams_.Set("prettyPrint", "false")
37339	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+parent}/entityTypes:batchDelete")
37340	urls += "?" + c.urlParams_.Encode()
37341	req, err := http.NewRequest("POST", urls, body)
37342	if err != nil {
37343		return nil, err
37344	}
37345	req.Header = reqHeaders
37346	googleapi.Expand(req.URL, map[string]string{
37347		"parent": c.parent,
37348	})
37349	return gensupport.SendRequest(c.ctx_, c.s.client, req)
37350}
37351
37352// Do executes the "dialogflow.projects.locations.agent.entityTypes.batchDelete" call.
37353// Exactly one of *GoogleLongrunningOperation or error will be non-nil.
37354// Any non-2xx status code is an error. Response headers are in either
37355// *GoogleLongrunningOperation.ServerResponse.Header or (if a response
37356// was returned at all) in error.(*googleapi.Error).Header. Use
37357// googleapi.IsNotModified to check whether the returned error was
37358// because http.StatusNotModified was returned.
37359func (c *ProjectsLocationsAgentEntityTypesBatchDeleteCall) Do(opts ...googleapi.CallOption) (*GoogleLongrunningOperation, error) {
37360	gensupport.SetOptions(c.urlParams_, opts...)
37361	res, err := c.doRequest("json")
37362	if res != nil && res.StatusCode == http.StatusNotModified {
37363		if res.Body != nil {
37364			res.Body.Close()
37365		}
37366		return nil, &googleapi.Error{
37367			Code:   res.StatusCode,
37368			Header: res.Header,
37369		}
37370	}
37371	if err != nil {
37372		return nil, err
37373	}
37374	defer googleapi.CloseBody(res)
37375	if err := googleapi.CheckResponse(res); err != nil {
37376		return nil, err
37377	}
37378	ret := &GoogleLongrunningOperation{
37379		ServerResponse: googleapi.ServerResponse{
37380			Header:         res.Header,
37381			HTTPStatusCode: res.StatusCode,
37382		},
37383	}
37384	target := &ret
37385	if err := gensupport.DecodeResponse(target, res); err != nil {
37386		return nil, err
37387	}
37388	return ret, nil
37389	// {
37390	//   "description": "Deletes entity types in the specified agent. This method is a [long-running operation](https://cloud.google.com/dialogflow/es/docs/how/long-running-operations). The returned `Operation` type has the following method-specific fields: - `metadata`: An empty [Struct message](https://developers.google.com/protocol-buffers/docs/reference/google.protobuf#struct) - `response`: An [Empty message](https://developers.google.com/protocol-buffers/docs/reference/google.protobuf#empty) Note: You should always train an agent prior to sending it queries. See the [training documentation](https://cloud.google.com/dialogflow/es/docs/training).",
37391	//   "flatPath": "v2/projects/{projectsId}/locations/{locationsId}/agent/entityTypes:batchDelete",
37392	//   "httpMethod": "POST",
37393	//   "id": "dialogflow.projects.locations.agent.entityTypes.batchDelete",
37394	//   "parameterOrder": [
37395	//     "parent"
37396	//   ],
37397	//   "parameters": {
37398	//     "parent": {
37399	//       "description": "Required. The name of the agent to delete all entities types for. Format: `projects//agent`.",
37400	//       "location": "path",
37401	//       "pattern": "^projects/[^/]+/locations/[^/]+/agent$",
37402	//       "required": true,
37403	//       "type": "string"
37404	//     }
37405	//   },
37406	//   "path": "v2/{+parent}/entityTypes:batchDelete",
37407	//   "request": {
37408	//     "$ref": "GoogleCloudDialogflowV2BatchDeleteEntityTypesRequest"
37409	//   },
37410	//   "response": {
37411	//     "$ref": "GoogleLongrunningOperation"
37412	//   },
37413	//   "scopes": [
37414	//     "https://www.googleapis.com/auth/cloud-platform",
37415	//     "https://www.googleapis.com/auth/dialogflow"
37416	//   ]
37417	// }
37418
37419}
37420
37421// method id "dialogflow.projects.locations.agent.entityTypes.batchUpdate":
37422
37423type ProjectsLocationsAgentEntityTypesBatchUpdateCall struct {
37424	s                                                    *Service
37425	parent                                               string
37426	googleclouddialogflowv2batchupdateentitytypesrequest *GoogleCloudDialogflowV2BatchUpdateEntityTypesRequest
37427	urlParams_                                           gensupport.URLParams
37428	ctx_                                                 context.Context
37429	header_                                              http.Header
37430}
37431
37432// BatchUpdate: Updates/Creates multiple entity types in the specified
37433// agent. This method is a long-running operation
37434// (https://cloud.google.com/dialogflow/es/docs/how/long-running-operations).
37435// The returned `Operation` type has the following method-specific
37436// fields: - `metadata`: An empty Struct message
37437// (https://developers.google.com/protocol-buffers/docs/reference/google.protobuf#struct)
37438// - `response`: BatchUpdateEntityTypesResponse Note: You should always
37439// train an agent prior to sending it queries. See the training
37440// documentation (https://cloud.google.com/dialogflow/es/docs/training).
37441//
37442// - parent: The name of the agent to update or create entity types in.
37443//   Format: `projects//agent`.
37444func (r *ProjectsLocationsAgentEntityTypesService) BatchUpdate(parent string, googleclouddialogflowv2batchupdateentitytypesrequest *GoogleCloudDialogflowV2BatchUpdateEntityTypesRequest) *ProjectsLocationsAgentEntityTypesBatchUpdateCall {
37445	c := &ProjectsLocationsAgentEntityTypesBatchUpdateCall{s: r.s, urlParams_: make(gensupport.URLParams)}
37446	c.parent = parent
37447	c.googleclouddialogflowv2batchupdateentitytypesrequest = googleclouddialogflowv2batchupdateentitytypesrequest
37448	return c
37449}
37450
37451// Fields allows partial responses to be retrieved. See
37452// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
37453// for more information.
37454func (c *ProjectsLocationsAgentEntityTypesBatchUpdateCall) Fields(s ...googleapi.Field) *ProjectsLocationsAgentEntityTypesBatchUpdateCall {
37455	c.urlParams_.Set("fields", googleapi.CombineFields(s))
37456	return c
37457}
37458
37459// Context sets the context to be used in this call's Do method. Any
37460// pending HTTP request will be aborted if the provided context is
37461// canceled.
37462func (c *ProjectsLocationsAgentEntityTypesBatchUpdateCall) Context(ctx context.Context) *ProjectsLocationsAgentEntityTypesBatchUpdateCall {
37463	c.ctx_ = ctx
37464	return c
37465}
37466
37467// Header returns an http.Header that can be modified by the caller to
37468// add HTTP headers to the request.
37469func (c *ProjectsLocationsAgentEntityTypesBatchUpdateCall) Header() http.Header {
37470	if c.header_ == nil {
37471		c.header_ = make(http.Header)
37472	}
37473	return c.header_
37474}
37475
37476func (c *ProjectsLocationsAgentEntityTypesBatchUpdateCall) doRequest(alt string) (*http.Response, error) {
37477	reqHeaders := make(http.Header)
37478	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20211027")
37479	for k, v := range c.header_ {
37480		reqHeaders[k] = v
37481	}
37482	reqHeaders.Set("User-Agent", c.s.userAgent())
37483	var body io.Reader = nil
37484	body, err := googleapi.WithoutDataWrapper.JSONReader(c.googleclouddialogflowv2batchupdateentitytypesrequest)
37485	if err != nil {
37486		return nil, err
37487	}
37488	reqHeaders.Set("Content-Type", "application/json")
37489	c.urlParams_.Set("alt", alt)
37490	c.urlParams_.Set("prettyPrint", "false")
37491	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+parent}/entityTypes:batchUpdate")
37492	urls += "?" + c.urlParams_.Encode()
37493	req, err := http.NewRequest("POST", urls, body)
37494	if err != nil {
37495		return nil, err
37496	}
37497	req.Header = reqHeaders
37498	googleapi.Expand(req.URL, map[string]string{
37499		"parent": c.parent,
37500	})
37501	return gensupport.SendRequest(c.ctx_, c.s.client, req)
37502}
37503
37504// Do executes the "dialogflow.projects.locations.agent.entityTypes.batchUpdate" call.
37505// Exactly one of *GoogleLongrunningOperation or error will be non-nil.
37506// Any non-2xx status code is an error. Response headers are in either
37507// *GoogleLongrunningOperation.ServerResponse.Header or (if a response
37508// was returned at all) in error.(*googleapi.Error).Header. Use
37509// googleapi.IsNotModified to check whether the returned error was
37510// because http.StatusNotModified was returned.
37511func (c *ProjectsLocationsAgentEntityTypesBatchUpdateCall) Do(opts ...googleapi.CallOption) (*GoogleLongrunningOperation, error) {
37512	gensupport.SetOptions(c.urlParams_, opts...)
37513	res, err := c.doRequest("json")
37514	if res != nil && res.StatusCode == http.StatusNotModified {
37515		if res.Body != nil {
37516			res.Body.Close()
37517		}
37518		return nil, &googleapi.Error{
37519			Code:   res.StatusCode,
37520			Header: res.Header,
37521		}
37522	}
37523	if err != nil {
37524		return nil, err
37525	}
37526	defer googleapi.CloseBody(res)
37527	if err := googleapi.CheckResponse(res); err != nil {
37528		return nil, err
37529	}
37530	ret := &GoogleLongrunningOperation{
37531		ServerResponse: googleapi.ServerResponse{
37532			Header:         res.Header,
37533			HTTPStatusCode: res.StatusCode,
37534		},
37535	}
37536	target := &ret
37537	if err := gensupport.DecodeResponse(target, res); err != nil {
37538		return nil, err
37539	}
37540	return ret, nil
37541	// {
37542	//   "description": "Updates/Creates multiple entity types in the specified agent. This method is a [long-running operation](https://cloud.google.com/dialogflow/es/docs/how/long-running-operations). The returned `Operation` type has the following method-specific fields: - `metadata`: An empty [Struct message](https://developers.google.com/protocol-buffers/docs/reference/google.protobuf#struct) - `response`: BatchUpdateEntityTypesResponse Note: You should always train an agent prior to sending it queries. See the [training documentation](https://cloud.google.com/dialogflow/es/docs/training).",
37543	//   "flatPath": "v2/projects/{projectsId}/locations/{locationsId}/agent/entityTypes:batchUpdate",
37544	//   "httpMethod": "POST",
37545	//   "id": "dialogflow.projects.locations.agent.entityTypes.batchUpdate",
37546	//   "parameterOrder": [
37547	//     "parent"
37548	//   ],
37549	//   "parameters": {
37550	//     "parent": {
37551	//       "description": "Required. The name of the agent to update or create entity types in. Format: `projects//agent`.",
37552	//       "location": "path",
37553	//       "pattern": "^projects/[^/]+/locations/[^/]+/agent$",
37554	//       "required": true,
37555	//       "type": "string"
37556	//     }
37557	//   },
37558	//   "path": "v2/{+parent}/entityTypes:batchUpdate",
37559	//   "request": {
37560	//     "$ref": "GoogleCloudDialogflowV2BatchUpdateEntityTypesRequest"
37561	//   },
37562	//   "response": {
37563	//     "$ref": "GoogleLongrunningOperation"
37564	//   },
37565	//   "scopes": [
37566	//     "https://www.googleapis.com/auth/cloud-platform",
37567	//     "https://www.googleapis.com/auth/dialogflow"
37568	//   ]
37569	// }
37570
37571}
37572
37573// method id "dialogflow.projects.locations.agent.entityTypes.create":
37574
37575type ProjectsLocationsAgentEntityTypesCreateCall struct {
37576	s                                 *Service
37577	parent                            string
37578	googleclouddialogflowv2entitytype *GoogleCloudDialogflowV2EntityType
37579	urlParams_                        gensupport.URLParams
37580	ctx_                              context.Context
37581	header_                           http.Header
37582}
37583
37584// Create: Creates an entity type in the specified agent. Note: You
37585// should always train an agent prior to sending it queries. See the
37586// training documentation
37587// (https://cloud.google.com/dialogflow/es/docs/training).
37588//
37589// - parent: The agent to create a entity type for. Format:
37590//   `projects//agent`.
37591func (r *ProjectsLocationsAgentEntityTypesService) Create(parent string, googleclouddialogflowv2entitytype *GoogleCloudDialogflowV2EntityType) *ProjectsLocationsAgentEntityTypesCreateCall {
37592	c := &ProjectsLocationsAgentEntityTypesCreateCall{s: r.s, urlParams_: make(gensupport.URLParams)}
37593	c.parent = parent
37594	c.googleclouddialogflowv2entitytype = googleclouddialogflowv2entitytype
37595	return c
37596}
37597
37598// LanguageCode sets the optional parameter "languageCode": The language
37599// used to access language-specific data. If not specified, the agent's
37600// default language is used. For more information, see Multilingual
37601// intent and entity data
37602// (https://cloud.google.com/dialogflow/docs/agents-multilingual#intent-entity).
37603func (c *ProjectsLocationsAgentEntityTypesCreateCall) LanguageCode(languageCode string) *ProjectsLocationsAgentEntityTypesCreateCall {
37604	c.urlParams_.Set("languageCode", languageCode)
37605	return c
37606}
37607
37608// Fields allows partial responses to be retrieved. See
37609// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
37610// for more information.
37611func (c *ProjectsLocationsAgentEntityTypesCreateCall) Fields(s ...googleapi.Field) *ProjectsLocationsAgentEntityTypesCreateCall {
37612	c.urlParams_.Set("fields", googleapi.CombineFields(s))
37613	return c
37614}
37615
37616// Context sets the context to be used in this call's Do method. Any
37617// pending HTTP request will be aborted if the provided context is
37618// canceled.
37619func (c *ProjectsLocationsAgentEntityTypesCreateCall) Context(ctx context.Context) *ProjectsLocationsAgentEntityTypesCreateCall {
37620	c.ctx_ = ctx
37621	return c
37622}
37623
37624// Header returns an http.Header that can be modified by the caller to
37625// add HTTP headers to the request.
37626func (c *ProjectsLocationsAgentEntityTypesCreateCall) Header() http.Header {
37627	if c.header_ == nil {
37628		c.header_ = make(http.Header)
37629	}
37630	return c.header_
37631}
37632
37633func (c *ProjectsLocationsAgentEntityTypesCreateCall) doRequest(alt string) (*http.Response, error) {
37634	reqHeaders := make(http.Header)
37635	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20211027")
37636	for k, v := range c.header_ {
37637		reqHeaders[k] = v
37638	}
37639	reqHeaders.Set("User-Agent", c.s.userAgent())
37640	var body io.Reader = nil
37641	body, err := googleapi.WithoutDataWrapper.JSONReader(c.googleclouddialogflowv2entitytype)
37642	if err != nil {
37643		return nil, err
37644	}
37645	reqHeaders.Set("Content-Type", "application/json")
37646	c.urlParams_.Set("alt", alt)
37647	c.urlParams_.Set("prettyPrint", "false")
37648	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+parent}/entityTypes")
37649	urls += "?" + c.urlParams_.Encode()
37650	req, err := http.NewRequest("POST", urls, body)
37651	if err != nil {
37652		return nil, err
37653	}
37654	req.Header = reqHeaders
37655	googleapi.Expand(req.URL, map[string]string{
37656		"parent": c.parent,
37657	})
37658	return gensupport.SendRequest(c.ctx_, c.s.client, req)
37659}
37660
37661// Do executes the "dialogflow.projects.locations.agent.entityTypes.create" call.
37662// Exactly one of *GoogleCloudDialogflowV2EntityType or error will be
37663// non-nil. Any non-2xx status code is an error. Response headers are in
37664// either *GoogleCloudDialogflowV2EntityType.ServerResponse.Header or
37665// (if a response was returned at all) in
37666// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
37667// whether the returned error was because http.StatusNotModified was
37668// returned.
37669func (c *ProjectsLocationsAgentEntityTypesCreateCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDialogflowV2EntityType, error) {
37670	gensupport.SetOptions(c.urlParams_, opts...)
37671	res, err := c.doRequest("json")
37672	if res != nil && res.StatusCode == http.StatusNotModified {
37673		if res.Body != nil {
37674			res.Body.Close()
37675		}
37676		return nil, &googleapi.Error{
37677			Code:   res.StatusCode,
37678			Header: res.Header,
37679		}
37680	}
37681	if err != nil {
37682		return nil, err
37683	}
37684	defer googleapi.CloseBody(res)
37685	if err := googleapi.CheckResponse(res); err != nil {
37686		return nil, err
37687	}
37688	ret := &GoogleCloudDialogflowV2EntityType{
37689		ServerResponse: googleapi.ServerResponse{
37690			Header:         res.Header,
37691			HTTPStatusCode: res.StatusCode,
37692		},
37693	}
37694	target := &ret
37695	if err := gensupport.DecodeResponse(target, res); err != nil {
37696		return nil, err
37697	}
37698	return ret, nil
37699	// {
37700	//   "description": "Creates an entity type in the specified agent. Note: You should always train an agent prior to sending it queries. See the [training documentation](https://cloud.google.com/dialogflow/es/docs/training).",
37701	//   "flatPath": "v2/projects/{projectsId}/locations/{locationsId}/agent/entityTypes",
37702	//   "httpMethod": "POST",
37703	//   "id": "dialogflow.projects.locations.agent.entityTypes.create",
37704	//   "parameterOrder": [
37705	//     "parent"
37706	//   ],
37707	//   "parameters": {
37708	//     "languageCode": {
37709	//       "description": "Optional. The language used to access language-specific data. If not specified, the agent's default language is used. For more information, see [Multilingual intent and entity data](https://cloud.google.com/dialogflow/docs/agents-multilingual#intent-entity).",
37710	//       "location": "query",
37711	//       "type": "string"
37712	//     },
37713	//     "parent": {
37714	//       "description": "Required. The agent to create a entity type for. Format: `projects//agent`.",
37715	//       "location": "path",
37716	//       "pattern": "^projects/[^/]+/locations/[^/]+/agent$",
37717	//       "required": true,
37718	//       "type": "string"
37719	//     }
37720	//   },
37721	//   "path": "v2/{+parent}/entityTypes",
37722	//   "request": {
37723	//     "$ref": "GoogleCloudDialogflowV2EntityType"
37724	//   },
37725	//   "response": {
37726	//     "$ref": "GoogleCloudDialogflowV2EntityType"
37727	//   },
37728	//   "scopes": [
37729	//     "https://www.googleapis.com/auth/cloud-platform",
37730	//     "https://www.googleapis.com/auth/dialogflow"
37731	//   ]
37732	// }
37733
37734}
37735
37736// method id "dialogflow.projects.locations.agent.entityTypes.delete":
37737
37738type ProjectsLocationsAgentEntityTypesDeleteCall struct {
37739	s          *Service
37740	name       string
37741	urlParams_ gensupport.URLParams
37742	ctx_       context.Context
37743	header_    http.Header
37744}
37745
37746// Delete: Deletes the specified entity type. Note: You should always
37747// train an agent prior to sending it queries. See the training
37748// documentation (https://cloud.google.com/dialogflow/es/docs/training).
37749//
37750// - name: The name of the entity type to delete. Format:
37751//   `projects//agent/entityTypes/`.
37752func (r *ProjectsLocationsAgentEntityTypesService) Delete(name string) *ProjectsLocationsAgentEntityTypesDeleteCall {
37753	c := &ProjectsLocationsAgentEntityTypesDeleteCall{s: r.s, urlParams_: make(gensupport.URLParams)}
37754	c.name = name
37755	return c
37756}
37757
37758// Fields allows partial responses to be retrieved. See
37759// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
37760// for more information.
37761func (c *ProjectsLocationsAgentEntityTypesDeleteCall) Fields(s ...googleapi.Field) *ProjectsLocationsAgentEntityTypesDeleteCall {
37762	c.urlParams_.Set("fields", googleapi.CombineFields(s))
37763	return c
37764}
37765
37766// Context sets the context to be used in this call's Do method. Any
37767// pending HTTP request will be aborted if the provided context is
37768// canceled.
37769func (c *ProjectsLocationsAgentEntityTypesDeleteCall) Context(ctx context.Context) *ProjectsLocationsAgentEntityTypesDeleteCall {
37770	c.ctx_ = ctx
37771	return c
37772}
37773
37774// Header returns an http.Header that can be modified by the caller to
37775// add HTTP headers to the request.
37776func (c *ProjectsLocationsAgentEntityTypesDeleteCall) Header() http.Header {
37777	if c.header_ == nil {
37778		c.header_ = make(http.Header)
37779	}
37780	return c.header_
37781}
37782
37783func (c *ProjectsLocationsAgentEntityTypesDeleteCall) doRequest(alt string) (*http.Response, error) {
37784	reqHeaders := make(http.Header)
37785	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20211027")
37786	for k, v := range c.header_ {
37787		reqHeaders[k] = v
37788	}
37789	reqHeaders.Set("User-Agent", c.s.userAgent())
37790	var body io.Reader = nil
37791	c.urlParams_.Set("alt", alt)
37792	c.urlParams_.Set("prettyPrint", "false")
37793	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+name}")
37794	urls += "?" + c.urlParams_.Encode()
37795	req, err := http.NewRequest("DELETE", urls, body)
37796	if err != nil {
37797		return nil, err
37798	}
37799	req.Header = reqHeaders
37800	googleapi.Expand(req.URL, map[string]string{
37801		"name": c.name,
37802	})
37803	return gensupport.SendRequest(c.ctx_, c.s.client, req)
37804}
37805
37806// Do executes the "dialogflow.projects.locations.agent.entityTypes.delete" call.
37807// Exactly one of *GoogleProtobufEmpty or error will be non-nil. Any
37808// non-2xx status code is an error. Response headers are in either
37809// *GoogleProtobufEmpty.ServerResponse.Header or (if a response was
37810// returned at all) in error.(*googleapi.Error).Header. Use
37811// googleapi.IsNotModified to check whether the returned error was
37812// because http.StatusNotModified was returned.
37813func (c *ProjectsLocationsAgentEntityTypesDeleteCall) Do(opts ...googleapi.CallOption) (*GoogleProtobufEmpty, error) {
37814	gensupport.SetOptions(c.urlParams_, opts...)
37815	res, err := c.doRequest("json")
37816	if res != nil && res.StatusCode == http.StatusNotModified {
37817		if res.Body != nil {
37818			res.Body.Close()
37819		}
37820		return nil, &googleapi.Error{
37821			Code:   res.StatusCode,
37822			Header: res.Header,
37823		}
37824	}
37825	if err != nil {
37826		return nil, err
37827	}
37828	defer googleapi.CloseBody(res)
37829	if err := googleapi.CheckResponse(res); err != nil {
37830		return nil, err
37831	}
37832	ret := &GoogleProtobufEmpty{
37833		ServerResponse: googleapi.ServerResponse{
37834			Header:         res.Header,
37835			HTTPStatusCode: res.StatusCode,
37836		},
37837	}
37838	target := &ret
37839	if err := gensupport.DecodeResponse(target, res); err != nil {
37840		return nil, err
37841	}
37842	return ret, nil
37843	// {
37844	//   "description": "Deletes the specified entity type. Note: You should always train an agent prior to sending it queries. See the [training documentation](https://cloud.google.com/dialogflow/es/docs/training).",
37845	//   "flatPath": "v2/projects/{projectsId}/locations/{locationsId}/agent/entityTypes/{entityTypesId}",
37846	//   "httpMethod": "DELETE",
37847	//   "id": "dialogflow.projects.locations.agent.entityTypes.delete",
37848	//   "parameterOrder": [
37849	//     "name"
37850	//   ],
37851	//   "parameters": {
37852	//     "name": {
37853	//       "description": "Required. The name of the entity type to delete. Format: `projects//agent/entityTypes/`.",
37854	//       "location": "path",
37855	//       "pattern": "^projects/[^/]+/locations/[^/]+/agent/entityTypes/[^/]+$",
37856	//       "required": true,
37857	//       "type": "string"
37858	//     }
37859	//   },
37860	//   "path": "v2/{+name}",
37861	//   "response": {
37862	//     "$ref": "GoogleProtobufEmpty"
37863	//   },
37864	//   "scopes": [
37865	//     "https://www.googleapis.com/auth/cloud-platform",
37866	//     "https://www.googleapis.com/auth/dialogflow"
37867	//   ]
37868	// }
37869
37870}
37871
37872// method id "dialogflow.projects.locations.agent.entityTypes.get":
37873
37874type ProjectsLocationsAgentEntityTypesGetCall struct {
37875	s            *Service
37876	name         string
37877	urlParams_   gensupport.URLParams
37878	ifNoneMatch_ string
37879	ctx_         context.Context
37880	header_      http.Header
37881}
37882
37883// Get: Retrieves the specified entity type.
37884//
37885// - name: The name of the entity type. Format:
37886//   `projects//agent/entityTypes/`.
37887func (r *ProjectsLocationsAgentEntityTypesService) Get(name string) *ProjectsLocationsAgentEntityTypesGetCall {
37888	c := &ProjectsLocationsAgentEntityTypesGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
37889	c.name = name
37890	return c
37891}
37892
37893// LanguageCode sets the optional parameter "languageCode": The language
37894// used to access language-specific data. If not specified, the agent's
37895// default language is used. For more information, see Multilingual
37896// intent and entity data
37897// (https://cloud.google.com/dialogflow/docs/agents-multilingual#intent-entity).
37898func (c *ProjectsLocationsAgentEntityTypesGetCall) LanguageCode(languageCode string) *ProjectsLocationsAgentEntityTypesGetCall {
37899	c.urlParams_.Set("languageCode", languageCode)
37900	return c
37901}
37902
37903// Fields allows partial responses to be retrieved. See
37904// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
37905// for more information.
37906func (c *ProjectsLocationsAgentEntityTypesGetCall) Fields(s ...googleapi.Field) *ProjectsLocationsAgentEntityTypesGetCall {
37907	c.urlParams_.Set("fields", googleapi.CombineFields(s))
37908	return c
37909}
37910
37911// IfNoneMatch sets the optional parameter which makes the operation
37912// fail if the object's ETag matches the given value. This is useful for
37913// getting updates only after the object has changed since the last
37914// request. Use googleapi.IsNotModified to check whether the response
37915// error from Do is the result of In-None-Match.
37916func (c *ProjectsLocationsAgentEntityTypesGetCall) IfNoneMatch(entityTag string) *ProjectsLocationsAgentEntityTypesGetCall {
37917	c.ifNoneMatch_ = entityTag
37918	return c
37919}
37920
37921// Context sets the context to be used in this call's Do method. Any
37922// pending HTTP request will be aborted if the provided context is
37923// canceled.
37924func (c *ProjectsLocationsAgentEntityTypesGetCall) Context(ctx context.Context) *ProjectsLocationsAgentEntityTypesGetCall {
37925	c.ctx_ = ctx
37926	return c
37927}
37928
37929// Header returns an http.Header that can be modified by the caller to
37930// add HTTP headers to the request.
37931func (c *ProjectsLocationsAgentEntityTypesGetCall) Header() http.Header {
37932	if c.header_ == nil {
37933		c.header_ = make(http.Header)
37934	}
37935	return c.header_
37936}
37937
37938func (c *ProjectsLocationsAgentEntityTypesGetCall) doRequest(alt string) (*http.Response, error) {
37939	reqHeaders := make(http.Header)
37940	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20211027")
37941	for k, v := range c.header_ {
37942		reqHeaders[k] = v
37943	}
37944	reqHeaders.Set("User-Agent", c.s.userAgent())
37945	if c.ifNoneMatch_ != "" {
37946		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
37947	}
37948	var body io.Reader = nil
37949	c.urlParams_.Set("alt", alt)
37950	c.urlParams_.Set("prettyPrint", "false")
37951	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+name}")
37952	urls += "?" + c.urlParams_.Encode()
37953	req, err := http.NewRequest("GET", urls, body)
37954	if err != nil {
37955		return nil, err
37956	}
37957	req.Header = reqHeaders
37958	googleapi.Expand(req.URL, map[string]string{
37959		"name": c.name,
37960	})
37961	return gensupport.SendRequest(c.ctx_, c.s.client, req)
37962}
37963
37964// Do executes the "dialogflow.projects.locations.agent.entityTypes.get" call.
37965// Exactly one of *GoogleCloudDialogflowV2EntityType or error will be
37966// non-nil. Any non-2xx status code is an error. Response headers are in
37967// either *GoogleCloudDialogflowV2EntityType.ServerResponse.Header or
37968// (if a response was returned at all) in
37969// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
37970// whether the returned error was because http.StatusNotModified was
37971// returned.
37972func (c *ProjectsLocationsAgentEntityTypesGetCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDialogflowV2EntityType, error) {
37973	gensupport.SetOptions(c.urlParams_, opts...)
37974	res, err := c.doRequest("json")
37975	if res != nil && res.StatusCode == http.StatusNotModified {
37976		if res.Body != nil {
37977			res.Body.Close()
37978		}
37979		return nil, &googleapi.Error{
37980			Code:   res.StatusCode,
37981			Header: res.Header,
37982		}
37983	}
37984	if err != nil {
37985		return nil, err
37986	}
37987	defer googleapi.CloseBody(res)
37988	if err := googleapi.CheckResponse(res); err != nil {
37989		return nil, err
37990	}
37991	ret := &GoogleCloudDialogflowV2EntityType{
37992		ServerResponse: googleapi.ServerResponse{
37993			Header:         res.Header,
37994			HTTPStatusCode: res.StatusCode,
37995		},
37996	}
37997	target := &ret
37998	if err := gensupport.DecodeResponse(target, res); err != nil {
37999		return nil, err
38000	}
38001	return ret, nil
38002	// {
38003	//   "description": "Retrieves the specified entity type.",
38004	//   "flatPath": "v2/projects/{projectsId}/locations/{locationsId}/agent/entityTypes/{entityTypesId}",
38005	//   "httpMethod": "GET",
38006	//   "id": "dialogflow.projects.locations.agent.entityTypes.get",
38007	//   "parameterOrder": [
38008	//     "name"
38009	//   ],
38010	//   "parameters": {
38011	//     "languageCode": {
38012	//       "description": "Optional. The language used to access language-specific data. If not specified, the agent's default language is used. For more information, see [Multilingual intent and entity data](https://cloud.google.com/dialogflow/docs/agents-multilingual#intent-entity).",
38013	//       "location": "query",
38014	//       "type": "string"
38015	//     },
38016	//     "name": {
38017	//       "description": "Required. The name of the entity type. Format: `projects//agent/entityTypes/`.",
38018	//       "location": "path",
38019	//       "pattern": "^projects/[^/]+/locations/[^/]+/agent/entityTypes/[^/]+$",
38020	//       "required": true,
38021	//       "type": "string"
38022	//     }
38023	//   },
38024	//   "path": "v2/{+name}",
38025	//   "response": {
38026	//     "$ref": "GoogleCloudDialogflowV2EntityType"
38027	//   },
38028	//   "scopes": [
38029	//     "https://www.googleapis.com/auth/cloud-platform",
38030	//     "https://www.googleapis.com/auth/dialogflow"
38031	//   ]
38032	// }
38033
38034}
38035
38036// method id "dialogflow.projects.locations.agent.entityTypes.list":
38037
38038type ProjectsLocationsAgentEntityTypesListCall struct {
38039	s            *Service
38040	parent       string
38041	urlParams_   gensupport.URLParams
38042	ifNoneMatch_ string
38043	ctx_         context.Context
38044	header_      http.Header
38045}
38046
38047// List: Returns the list of all entity types in the specified agent.
38048//
38049// - parent: The agent to list all entity types from. Format:
38050//   `projects//agent`.
38051func (r *ProjectsLocationsAgentEntityTypesService) List(parent string) *ProjectsLocationsAgentEntityTypesListCall {
38052	c := &ProjectsLocationsAgentEntityTypesListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
38053	c.parent = parent
38054	return c
38055}
38056
38057// LanguageCode sets the optional parameter "languageCode": The language
38058// used to access language-specific data. If not specified, the agent's
38059// default language is used. For more information, see Multilingual
38060// intent and entity data
38061// (https://cloud.google.com/dialogflow/docs/agents-multilingual#intent-entity).
38062func (c *ProjectsLocationsAgentEntityTypesListCall) LanguageCode(languageCode string) *ProjectsLocationsAgentEntityTypesListCall {
38063	c.urlParams_.Set("languageCode", languageCode)
38064	return c
38065}
38066
38067// PageSize sets the optional parameter "pageSize": The maximum number
38068// of items to return in a single page. By default 100 and at most 1000.
38069func (c *ProjectsLocationsAgentEntityTypesListCall) PageSize(pageSize int64) *ProjectsLocationsAgentEntityTypesListCall {
38070	c.urlParams_.Set("pageSize", fmt.Sprint(pageSize))
38071	return c
38072}
38073
38074// PageToken sets the optional parameter "pageToken": The
38075// next_page_token value returned from a previous list request.
38076func (c *ProjectsLocationsAgentEntityTypesListCall) PageToken(pageToken string) *ProjectsLocationsAgentEntityTypesListCall {
38077	c.urlParams_.Set("pageToken", pageToken)
38078	return c
38079}
38080
38081// Fields allows partial responses to be retrieved. See
38082// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
38083// for more information.
38084func (c *ProjectsLocationsAgentEntityTypesListCall) Fields(s ...googleapi.Field) *ProjectsLocationsAgentEntityTypesListCall {
38085	c.urlParams_.Set("fields", googleapi.CombineFields(s))
38086	return c
38087}
38088
38089// IfNoneMatch sets the optional parameter which makes the operation
38090// fail if the object's ETag matches the given value. This is useful for
38091// getting updates only after the object has changed since the last
38092// request. Use googleapi.IsNotModified to check whether the response
38093// error from Do is the result of In-None-Match.
38094func (c *ProjectsLocationsAgentEntityTypesListCall) IfNoneMatch(entityTag string) *ProjectsLocationsAgentEntityTypesListCall {
38095	c.ifNoneMatch_ = entityTag
38096	return c
38097}
38098
38099// Context sets the context to be used in this call's Do method. Any
38100// pending HTTP request will be aborted if the provided context is
38101// canceled.
38102func (c *ProjectsLocationsAgentEntityTypesListCall) Context(ctx context.Context) *ProjectsLocationsAgentEntityTypesListCall {
38103	c.ctx_ = ctx
38104	return c
38105}
38106
38107// Header returns an http.Header that can be modified by the caller to
38108// add HTTP headers to the request.
38109func (c *ProjectsLocationsAgentEntityTypesListCall) Header() http.Header {
38110	if c.header_ == nil {
38111		c.header_ = make(http.Header)
38112	}
38113	return c.header_
38114}
38115
38116func (c *ProjectsLocationsAgentEntityTypesListCall) doRequest(alt string) (*http.Response, error) {
38117	reqHeaders := make(http.Header)
38118	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20211027")
38119	for k, v := range c.header_ {
38120		reqHeaders[k] = v
38121	}
38122	reqHeaders.Set("User-Agent", c.s.userAgent())
38123	if c.ifNoneMatch_ != "" {
38124		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
38125	}
38126	var body io.Reader = nil
38127	c.urlParams_.Set("alt", alt)
38128	c.urlParams_.Set("prettyPrint", "false")
38129	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+parent}/entityTypes")
38130	urls += "?" + c.urlParams_.Encode()
38131	req, err := http.NewRequest("GET", urls, body)
38132	if err != nil {
38133		return nil, err
38134	}
38135	req.Header = reqHeaders
38136	googleapi.Expand(req.URL, map[string]string{
38137		"parent": c.parent,
38138	})
38139	return gensupport.SendRequest(c.ctx_, c.s.client, req)
38140}
38141
38142// Do executes the "dialogflow.projects.locations.agent.entityTypes.list" call.
38143// Exactly one of *GoogleCloudDialogflowV2ListEntityTypesResponse or
38144// error will be non-nil. Any non-2xx status code is an error. Response
38145// headers are in either
38146// *GoogleCloudDialogflowV2ListEntityTypesResponse.ServerResponse.Header
38147// or (if a response was returned at all) in
38148// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
38149// whether the returned error was because http.StatusNotModified was
38150// returned.
38151func (c *ProjectsLocationsAgentEntityTypesListCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDialogflowV2ListEntityTypesResponse, error) {
38152	gensupport.SetOptions(c.urlParams_, opts...)
38153	res, err := c.doRequest("json")
38154	if res != nil && res.StatusCode == http.StatusNotModified {
38155		if res.Body != nil {
38156			res.Body.Close()
38157		}
38158		return nil, &googleapi.Error{
38159			Code:   res.StatusCode,
38160			Header: res.Header,
38161		}
38162	}
38163	if err != nil {
38164		return nil, err
38165	}
38166	defer googleapi.CloseBody(res)
38167	if err := googleapi.CheckResponse(res); err != nil {
38168		return nil, err
38169	}
38170	ret := &GoogleCloudDialogflowV2ListEntityTypesResponse{
38171		ServerResponse: googleapi.ServerResponse{
38172			Header:         res.Header,
38173			HTTPStatusCode: res.StatusCode,
38174		},
38175	}
38176	target := &ret
38177	if err := gensupport.DecodeResponse(target, res); err != nil {
38178		return nil, err
38179	}
38180	return ret, nil
38181	// {
38182	//   "description": "Returns the list of all entity types in the specified agent.",
38183	//   "flatPath": "v2/projects/{projectsId}/locations/{locationsId}/agent/entityTypes",
38184	//   "httpMethod": "GET",
38185	//   "id": "dialogflow.projects.locations.agent.entityTypes.list",
38186	//   "parameterOrder": [
38187	//     "parent"
38188	//   ],
38189	//   "parameters": {
38190	//     "languageCode": {
38191	//       "description": "Optional. The language used to access language-specific data. If not specified, the agent's default language is used. For more information, see [Multilingual intent and entity data](https://cloud.google.com/dialogflow/docs/agents-multilingual#intent-entity).",
38192	//       "location": "query",
38193	//       "type": "string"
38194	//     },
38195	//     "pageSize": {
38196	//       "description": "Optional. The maximum number of items to return in a single page. By default 100 and at most 1000.",
38197	//       "format": "int32",
38198	//       "location": "query",
38199	//       "type": "integer"
38200	//     },
38201	//     "pageToken": {
38202	//       "description": "Optional. The next_page_token value returned from a previous list request.",
38203	//       "location": "query",
38204	//       "type": "string"
38205	//     },
38206	//     "parent": {
38207	//       "description": "Required. The agent to list all entity types from. Format: `projects//agent`.",
38208	//       "location": "path",
38209	//       "pattern": "^projects/[^/]+/locations/[^/]+/agent$",
38210	//       "required": true,
38211	//       "type": "string"
38212	//     }
38213	//   },
38214	//   "path": "v2/{+parent}/entityTypes",
38215	//   "response": {
38216	//     "$ref": "GoogleCloudDialogflowV2ListEntityTypesResponse"
38217	//   },
38218	//   "scopes": [
38219	//     "https://www.googleapis.com/auth/cloud-platform",
38220	//     "https://www.googleapis.com/auth/dialogflow"
38221	//   ]
38222	// }
38223
38224}
38225
38226// Pages invokes f for each page of results.
38227// A non-nil error returned from f will halt the iteration.
38228// The provided context supersedes any context provided to the Context method.
38229func (c *ProjectsLocationsAgentEntityTypesListCall) Pages(ctx context.Context, f func(*GoogleCloudDialogflowV2ListEntityTypesResponse) error) error {
38230	c.ctx_ = ctx
38231	defer c.PageToken(c.urlParams_.Get("pageToken")) // reset paging to original point
38232	for {
38233		x, err := c.Do()
38234		if err != nil {
38235			return err
38236		}
38237		if err := f(x); err != nil {
38238			return err
38239		}
38240		if x.NextPageToken == "" {
38241			return nil
38242		}
38243		c.PageToken(x.NextPageToken)
38244	}
38245}
38246
38247// method id "dialogflow.projects.locations.agent.entityTypes.patch":
38248
38249type ProjectsLocationsAgentEntityTypesPatchCall struct {
38250	s                                 *Service
38251	nameid                            string
38252	googleclouddialogflowv2entitytype *GoogleCloudDialogflowV2EntityType
38253	urlParams_                        gensupport.URLParams
38254	ctx_                              context.Context
38255	header_                           http.Header
38256}
38257
38258// Patch: Updates the specified entity type. Note: You should always
38259// train an agent prior to sending it queries. See the training
38260// documentation (https://cloud.google.com/dialogflow/es/docs/training).
38261//
38262// - name: The unique identifier of the entity type. Required for
38263//   EntityTypes.UpdateEntityType and EntityTypes.BatchUpdateEntityTypes
38264//   methods. Format: `projects//agent/entityTypes/`.
38265func (r *ProjectsLocationsAgentEntityTypesService) Patch(nameid string, googleclouddialogflowv2entitytype *GoogleCloudDialogflowV2EntityType) *ProjectsLocationsAgentEntityTypesPatchCall {
38266	c := &ProjectsLocationsAgentEntityTypesPatchCall{s: r.s, urlParams_: make(gensupport.URLParams)}
38267	c.nameid = nameid
38268	c.googleclouddialogflowv2entitytype = googleclouddialogflowv2entitytype
38269	return c
38270}
38271
38272// LanguageCode sets the optional parameter "languageCode": The language
38273// used to access language-specific data. If not specified, the agent's
38274// default language is used. For more information, see Multilingual
38275// intent and entity data
38276// (https://cloud.google.com/dialogflow/docs/agents-multilingual#intent-entity).
38277func (c *ProjectsLocationsAgentEntityTypesPatchCall) LanguageCode(languageCode string) *ProjectsLocationsAgentEntityTypesPatchCall {
38278	c.urlParams_.Set("languageCode", languageCode)
38279	return c
38280}
38281
38282// UpdateMask sets the optional parameter "updateMask": The mask to
38283// control which fields get updated.
38284func (c *ProjectsLocationsAgentEntityTypesPatchCall) UpdateMask(updateMask string) *ProjectsLocationsAgentEntityTypesPatchCall {
38285	c.urlParams_.Set("updateMask", updateMask)
38286	return c
38287}
38288
38289// Fields allows partial responses to be retrieved. See
38290// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
38291// for more information.
38292func (c *ProjectsLocationsAgentEntityTypesPatchCall) Fields(s ...googleapi.Field) *ProjectsLocationsAgentEntityTypesPatchCall {
38293	c.urlParams_.Set("fields", googleapi.CombineFields(s))
38294	return c
38295}
38296
38297// Context sets the context to be used in this call's Do method. Any
38298// pending HTTP request will be aborted if the provided context is
38299// canceled.
38300func (c *ProjectsLocationsAgentEntityTypesPatchCall) Context(ctx context.Context) *ProjectsLocationsAgentEntityTypesPatchCall {
38301	c.ctx_ = ctx
38302	return c
38303}
38304
38305// Header returns an http.Header that can be modified by the caller to
38306// add HTTP headers to the request.
38307func (c *ProjectsLocationsAgentEntityTypesPatchCall) Header() http.Header {
38308	if c.header_ == nil {
38309		c.header_ = make(http.Header)
38310	}
38311	return c.header_
38312}
38313
38314func (c *ProjectsLocationsAgentEntityTypesPatchCall) doRequest(alt string) (*http.Response, error) {
38315	reqHeaders := make(http.Header)
38316	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20211027")
38317	for k, v := range c.header_ {
38318		reqHeaders[k] = v
38319	}
38320	reqHeaders.Set("User-Agent", c.s.userAgent())
38321	var body io.Reader = nil
38322	body, err := googleapi.WithoutDataWrapper.JSONReader(c.googleclouddialogflowv2entitytype)
38323	if err != nil {
38324		return nil, err
38325	}
38326	reqHeaders.Set("Content-Type", "application/json")
38327	c.urlParams_.Set("alt", alt)
38328	c.urlParams_.Set("prettyPrint", "false")
38329	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+name}")
38330	urls += "?" + c.urlParams_.Encode()
38331	req, err := http.NewRequest("PATCH", urls, body)
38332	if err != nil {
38333		return nil, err
38334	}
38335	req.Header = reqHeaders
38336	googleapi.Expand(req.URL, map[string]string{
38337		"name": c.nameid,
38338	})
38339	return gensupport.SendRequest(c.ctx_, c.s.client, req)
38340}
38341
38342// Do executes the "dialogflow.projects.locations.agent.entityTypes.patch" call.
38343// Exactly one of *GoogleCloudDialogflowV2EntityType or error will be
38344// non-nil. Any non-2xx status code is an error. Response headers are in
38345// either *GoogleCloudDialogflowV2EntityType.ServerResponse.Header or
38346// (if a response was returned at all) in
38347// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
38348// whether the returned error was because http.StatusNotModified was
38349// returned.
38350func (c *ProjectsLocationsAgentEntityTypesPatchCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDialogflowV2EntityType, error) {
38351	gensupport.SetOptions(c.urlParams_, opts...)
38352	res, err := c.doRequest("json")
38353	if res != nil && res.StatusCode == http.StatusNotModified {
38354		if res.Body != nil {
38355			res.Body.Close()
38356		}
38357		return nil, &googleapi.Error{
38358			Code:   res.StatusCode,
38359			Header: res.Header,
38360		}
38361	}
38362	if err != nil {
38363		return nil, err
38364	}
38365	defer googleapi.CloseBody(res)
38366	if err := googleapi.CheckResponse(res); err != nil {
38367		return nil, err
38368	}
38369	ret := &GoogleCloudDialogflowV2EntityType{
38370		ServerResponse: googleapi.ServerResponse{
38371			Header:         res.Header,
38372			HTTPStatusCode: res.StatusCode,
38373		},
38374	}
38375	target := &ret
38376	if err := gensupport.DecodeResponse(target, res); err != nil {
38377		return nil, err
38378	}
38379	return ret, nil
38380	// {
38381	//   "description": "Updates the specified entity type. Note: You should always train an agent prior to sending it queries. See the [training documentation](https://cloud.google.com/dialogflow/es/docs/training).",
38382	//   "flatPath": "v2/projects/{projectsId}/locations/{locationsId}/agent/entityTypes/{entityTypesId}",
38383	//   "httpMethod": "PATCH",
38384	//   "id": "dialogflow.projects.locations.agent.entityTypes.patch",
38385	//   "parameterOrder": [
38386	//     "name"
38387	//   ],
38388	//   "parameters": {
38389	//     "languageCode": {
38390	//       "description": "Optional. The language used to access language-specific data. If not specified, the agent's default language is used. For more information, see [Multilingual intent and entity data](https://cloud.google.com/dialogflow/docs/agents-multilingual#intent-entity).",
38391	//       "location": "query",
38392	//       "type": "string"
38393	//     },
38394	//     "name": {
38395	//       "description": "The unique identifier of the entity type. Required for EntityTypes.UpdateEntityType and EntityTypes.BatchUpdateEntityTypes methods. Format: `projects//agent/entityTypes/`.",
38396	//       "location": "path",
38397	//       "pattern": "^projects/[^/]+/locations/[^/]+/agent/entityTypes/[^/]+$",
38398	//       "required": true,
38399	//       "type": "string"
38400	//     },
38401	//     "updateMask": {
38402	//       "description": "Optional. The mask to control which fields get updated.",
38403	//       "format": "google-fieldmask",
38404	//       "location": "query",
38405	//       "type": "string"
38406	//     }
38407	//   },
38408	//   "path": "v2/{+name}",
38409	//   "request": {
38410	//     "$ref": "GoogleCloudDialogflowV2EntityType"
38411	//   },
38412	//   "response": {
38413	//     "$ref": "GoogleCloudDialogflowV2EntityType"
38414	//   },
38415	//   "scopes": [
38416	//     "https://www.googleapis.com/auth/cloud-platform",
38417	//     "https://www.googleapis.com/auth/dialogflow"
38418	//   ]
38419	// }
38420
38421}
38422
38423// method id "dialogflow.projects.locations.agent.entityTypes.entities.batchCreate":
38424
38425type ProjectsLocationsAgentEntityTypesEntitiesBatchCreateCall struct {
38426	s                                                 *Service
38427	parent                                            string
38428	googleclouddialogflowv2batchcreateentitiesrequest *GoogleCloudDialogflowV2BatchCreateEntitiesRequest
38429	urlParams_                                        gensupport.URLParams
38430	ctx_                                              context.Context
38431	header_                                           http.Header
38432}
38433
38434// BatchCreate: Creates multiple new entities in the specified entity
38435// type. This method is a long-running operation
38436// (https://cloud.google.com/dialogflow/es/docs/how/long-running-operations).
38437// The returned `Operation` type has the following method-specific
38438// fields: - `metadata`: An empty Struct message
38439// (https://developers.google.com/protocol-buffers/docs/reference/google.protobuf#struct)
38440// - `response`: An Empty message
38441// (https://developers.google.com/protocol-buffers/docs/reference/google.protobuf#empty)
38442// Note: You should always train an agent prior to sending it queries.
38443// See the training documentation
38444// (https://cloud.google.com/dialogflow/es/docs/training).
38445//
38446// - parent: The name of the entity type to create entities in. Format:
38447//   `projects//agent/entityTypes/`.
38448func (r *ProjectsLocationsAgentEntityTypesEntitiesService) BatchCreate(parent string, googleclouddialogflowv2batchcreateentitiesrequest *GoogleCloudDialogflowV2BatchCreateEntitiesRequest) *ProjectsLocationsAgentEntityTypesEntitiesBatchCreateCall {
38449	c := &ProjectsLocationsAgentEntityTypesEntitiesBatchCreateCall{s: r.s, urlParams_: make(gensupport.URLParams)}
38450	c.parent = parent
38451	c.googleclouddialogflowv2batchcreateentitiesrequest = googleclouddialogflowv2batchcreateentitiesrequest
38452	return c
38453}
38454
38455// Fields allows partial responses to be retrieved. See
38456// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
38457// for more information.
38458func (c *ProjectsLocationsAgentEntityTypesEntitiesBatchCreateCall) Fields(s ...googleapi.Field) *ProjectsLocationsAgentEntityTypesEntitiesBatchCreateCall {
38459	c.urlParams_.Set("fields", googleapi.CombineFields(s))
38460	return c
38461}
38462
38463// Context sets the context to be used in this call's Do method. Any
38464// pending HTTP request will be aborted if the provided context is
38465// canceled.
38466func (c *ProjectsLocationsAgentEntityTypesEntitiesBatchCreateCall) Context(ctx context.Context) *ProjectsLocationsAgentEntityTypesEntitiesBatchCreateCall {
38467	c.ctx_ = ctx
38468	return c
38469}
38470
38471// Header returns an http.Header that can be modified by the caller to
38472// add HTTP headers to the request.
38473func (c *ProjectsLocationsAgentEntityTypesEntitiesBatchCreateCall) Header() http.Header {
38474	if c.header_ == nil {
38475		c.header_ = make(http.Header)
38476	}
38477	return c.header_
38478}
38479
38480func (c *ProjectsLocationsAgentEntityTypesEntitiesBatchCreateCall) doRequest(alt string) (*http.Response, error) {
38481	reqHeaders := make(http.Header)
38482	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20211027")
38483	for k, v := range c.header_ {
38484		reqHeaders[k] = v
38485	}
38486	reqHeaders.Set("User-Agent", c.s.userAgent())
38487	var body io.Reader = nil
38488	body, err := googleapi.WithoutDataWrapper.JSONReader(c.googleclouddialogflowv2batchcreateentitiesrequest)
38489	if err != nil {
38490		return nil, err
38491	}
38492	reqHeaders.Set("Content-Type", "application/json")
38493	c.urlParams_.Set("alt", alt)
38494	c.urlParams_.Set("prettyPrint", "false")
38495	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+parent}/entities:batchCreate")
38496	urls += "?" + c.urlParams_.Encode()
38497	req, err := http.NewRequest("POST", urls, body)
38498	if err != nil {
38499		return nil, err
38500	}
38501	req.Header = reqHeaders
38502	googleapi.Expand(req.URL, map[string]string{
38503		"parent": c.parent,
38504	})
38505	return gensupport.SendRequest(c.ctx_, c.s.client, req)
38506}
38507
38508// Do executes the "dialogflow.projects.locations.agent.entityTypes.entities.batchCreate" call.
38509// Exactly one of *GoogleLongrunningOperation or error will be non-nil.
38510// Any non-2xx status code is an error. Response headers are in either
38511// *GoogleLongrunningOperation.ServerResponse.Header or (if a response
38512// was returned at all) in error.(*googleapi.Error).Header. Use
38513// googleapi.IsNotModified to check whether the returned error was
38514// because http.StatusNotModified was returned.
38515func (c *ProjectsLocationsAgentEntityTypesEntitiesBatchCreateCall) Do(opts ...googleapi.CallOption) (*GoogleLongrunningOperation, error) {
38516	gensupport.SetOptions(c.urlParams_, opts...)
38517	res, err := c.doRequest("json")
38518	if res != nil && res.StatusCode == http.StatusNotModified {
38519		if res.Body != nil {
38520			res.Body.Close()
38521		}
38522		return nil, &googleapi.Error{
38523			Code:   res.StatusCode,
38524			Header: res.Header,
38525		}
38526	}
38527	if err != nil {
38528		return nil, err
38529	}
38530	defer googleapi.CloseBody(res)
38531	if err := googleapi.CheckResponse(res); err != nil {
38532		return nil, err
38533	}
38534	ret := &GoogleLongrunningOperation{
38535		ServerResponse: googleapi.ServerResponse{
38536			Header:         res.Header,
38537			HTTPStatusCode: res.StatusCode,
38538		},
38539	}
38540	target := &ret
38541	if err := gensupport.DecodeResponse(target, res); err != nil {
38542		return nil, err
38543	}
38544	return ret, nil
38545	// {
38546	//   "description": "Creates multiple new entities in the specified entity type. This method is a [long-running operation](https://cloud.google.com/dialogflow/es/docs/how/long-running-operations). The returned `Operation` type has the following method-specific fields: - `metadata`: An empty [Struct message](https://developers.google.com/protocol-buffers/docs/reference/google.protobuf#struct) - `response`: An [Empty message](https://developers.google.com/protocol-buffers/docs/reference/google.protobuf#empty) Note: You should always train an agent prior to sending it queries. See the [training documentation](https://cloud.google.com/dialogflow/es/docs/training).",
38547	//   "flatPath": "v2/projects/{projectsId}/locations/{locationsId}/agent/entityTypes/{entityTypesId}/entities:batchCreate",
38548	//   "httpMethod": "POST",
38549	//   "id": "dialogflow.projects.locations.agent.entityTypes.entities.batchCreate",
38550	//   "parameterOrder": [
38551	//     "parent"
38552	//   ],
38553	//   "parameters": {
38554	//     "parent": {
38555	//       "description": "Required. The name of the entity type to create entities in. Format: `projects//agent/entityTypes/`.",
38556	//       "location": "path",
38557	//       "pattern": "^projects/[^/]+/locations/[^/]+/agent/entityTypes/[^/]+$",
38558	//       "required": true,
38559	//       "type": "string"
38560	//     }
38561	//   },
38562	//   "path": "v2/{+parent}/entities:batchCreate",
38563	//   "request": {
38564	//     "$ref": "GoogleCloudDialogflowV2BatchCreateEntitiesRequest"
38565	//   },
38566	//   "response": {
38567	//     "$ref": "GoogleLongrunningOperation"
38568	//   },
38569	//   "scopes": [
38570	//     "https://www.googleapis.com/auth/cloud-platform",
38571	//     "https://www.googleapis.com/auth/dialogflow"
38572	//   ]
38573	// }
38574
38575}
38576
38577// method id "dialogflow.projects.locations.agent.entityTypes.entities.batchDelete":
38578
38579type ProjectsLocationsAgentEntityTypesEntitiesBatchDeleteCall struct {
38580	s                                                 *Service
38581	parent                                            string
38582	googleclouddialogflowv2batchdeleteentitiesrequest *GoogleCloudDialogflowV2BatchDeleteEntitiesRequest
38583	urlParams_                                        gensupport.URLParams
38584	ctx_                                              context.Context
38585	header_                                           http.Header
38586}
38587
38588// BatchDelete: Deletes entities in the specified entity type. This
38589// method is a long-running operation
38590// (https://cloud.google.com/dialogflow/es/docs/how/long-running-operations).
38591// The returned `Operation` type has the following method-specific
38592// fields: - `metadata`: An empty Struct message
38593// (https://developers.google.com/protocol-buffers/docs/reference/google.protobuf#struct)
38594// - `response`: An Empty message
38595// (https://developers.google.com/protocol-buffers/docs/reference/google.protobuf#empty)
38596// Note: You should always train an agent prior to sending it queries.
38597// See the training documentation
38598// (https://cloud.google.com/dialogflow/es/docs/training).
38599//
38600// - parent: The name of the entity type to delete entries for. Format:
38601//   `projects//agent/entityTypes/`.
38602func (r *ProjectsLocationsAgentEntityTypesEntitiesService) BatchDelete(parent string, googleclouddialogflowv2batchdeleteentitiesrequest *GoogleCloudDialogflowV2BatchDeleteEntitiesRequest) *ProjectsLocationsAgentEntityTypesEntitiesBatchDeleteCall {
38603	c := &ProjectsLocationsAgentEntityTypesEntitiesBatchDeleteCall{s: r.s, urlParams_: make(gensupport.URLParams)}
38604	c.parent = parent
38605	c.googleclouddialogflowv2batchdeleteentitiesrequest = googleclouddialogflowv2batchdeleteentitiesrequest
38606	return c
38607}
38608
38609// Fields allows partial responses to be retrieved. See
38610// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
38611// for more information.
38612func (c *ProjectsLocationsAgentEntityTypesEntitiesBatchDeleteCall) Fields(s ...googleapi.Field) *ProjectsLocationsAgentEntityTypesEntitiesBatchDeleteCall {
38613	c.urlParams_.Set("fields", googleapi.CombineFields(s))
38614	return c
38615}
38616
38617// Context sets the context to be used in this call's Do method. Any
38618// pending HTTP request will be aborted if the provided context is
38619// canceled.
38620func (c *ProjectsLocationsAgentEntityTypesEntitiesBatchDeleteCall) Context(ctx context.Context) *ProjectsLocationsAgentEntityTypesEntitiesBatchDeleteCall {
38621	c.ctx_ = ctx
38622	return c
38623}
38624
38625// Header returns an http.Header that can be modified by the caller to
38626// add HTTP headers to the request.
38627func (c *ProjectsLocationsAgentEntityTypesEntitiesBatchDeleteCall) Header() http.Header {
38628	if c.header_ == nil {
38629		c.header_ = make(http.Header)
38630	}
38631	return c.header_
38632}
38633
38634func (c *ProjectsLocationsAgentEntityTypesEntitiesBatchDeleteCall) doRequest(alt string) (*http.Response, error) {
38635	reqHeaders := make(http.Header)
38636	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20211027")
38637	for k, v := range c.header_ {
38638		reqHeaders[k] = v
38639	}
38640	reqHeaders.Set("User-Agent", c.s.userAgent())
38641	var body io.Reader = nil
38642	body, err := googleapi.WithoutDataWrapper.JSONReader(c.googleclouddialogflowv2batchdeleteentitiesrequest)
38643	if err != nil {
38644		return nil, err
38645	}
38646	reqHeaders.Set("Content-Type", "application/json")
38647	c.urlParams_.Set("alt", alt)
38648	c.urlParams_.Set("prettyPrint", "false")
38649	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+parent}/entities:batchDelete")
38650	urls += "?" + c.urlParams_.Encode()
38651	req, err := http.NewRequest("POST", urls, body)
38652	if err != nil {
38653		return nil, err
38654	}
38655	req.Header = reqHeaders
38656	googleapi.Expand(req.URL, map[string]string{
38657		"parent": c.parent,
38658	})
38659	return gensupport.SendRequest(c.ctx_, c.s.client, req)
38660}
38661
38662// Do executes the "dialogflow.projects.locations.agent.entityTypes.entities.batchDelete" call.
38663// Exactly one of *GoogleLongrunningOperation or error will be non-nil.
38664// Any non-2xx status code is an error. Response headers are in either
38665// *GoogleLongrunningOperation.ServerResponse.Header or (if a response
38666// was returned at all) in error.(*googleapi.Error).Header. Use
38667// googleapi.IsNotModified to check whether the returned error was
38668// because http.StatusNotModified was returned.
38669func (c *ProjectsLocationsAgentEntityTypesEntitiesBatchDeleteCall) Do(opts ...googleapi.CallOption) (*GoogleLongrunningOperation, error) {
38670	gensupport.SetOptions(c.urlParams_, opts...)
38671	res, err := c.doRequest("json")
38672	if res != nil && res.StatusCode == http.StatusNotModified {
38673		if res.Body != nil {
38674			res.Body.Close()
38675		}
38676		return nil, &googleapi.Error{
38677			Code:   res.StatusCode,
38678			Header: res.Header,
38679		}
38680	}
38681	if err != nil {
38682		return nil, err
38683	}
38684	defer googleapi.CloseBody(res)
38685	if err := googleapi.CheckResponse(res); err != nil {
38686		return nil, err
38687	}
38688	ret := &GoogleLongrunningOperation{
38689		ServerResponse: googleapi.ServerResponse{
38690			Header:         res.Header,
38691			HTTPStatusCode: res.StatusCode,
38692		},
38693	}
38694	target := &ret
38695	if err := gensupport.DecodeResponse(target, res); err != nil {
38696		return nil, err
38697	}
38698	return ret, nil
38699	// {
38700	//   "description": "Deletes entities in the specified entity type. This method is a [long-running operation](https://cloud.google.com/dialogflow/es/docs/how/long-running-operations). The returned `Operation` type has the following method-specific fields: - `metadata`: An empty [Struct message](https://developers.google.com/protocol-buffers/docs/reference/google.protobuf#struct) - `response`: An [Empty message](https://developers.google.com/protocol-buffers/docs/reference/google.protobuf#empty) Note: You should always train an agent prior to sending it queries. See the [training documentation](https://cloud.google.com/dialogflow/es/docs/training).",
38701	//   "flatPath": "v2/projects/{projectsId}/locations/{locationsId}/agent/entityTypes/{entityTypesId}/entities:batchDelete",
38702	//   "httpMethod": "POST",
38703	//   "id": "dialogflow.projects.locations.agent.entityTypes.entities.batchDelete",
38704	//   "parameterOrder": [
38705	//     "parent"
38706	//   ],
38707	//   "parameters": {
38708	//     "parent": {
38709	//       "description": "Required. The name of the entity type to delete entries for. Format: `projects//agent/entityTypes/`.",
38710	//       "location": "path",
38711	//       "pattern": "^projects/[^/]+/locations/[^/]+/agent/entityTypes/[^/]+$",
38712	//       "required": true,
38713	//       "type": "string"
38714	//     }
38715	//   },
38716	//   "path": "v2/{+parent}/entities:batchDelete",
38717	//   "request": {
38718	//     "$ref": "GoogleCloudDialogflowV2BatchDeleteEntitiesRequest"
38719	//   },
38720	//   "response": {
38721	//     "$ref": "GoogleLongrunningOperation"
38722	//   },
38723	//   "scopes": [
38724	//     "https://www.googleapis.com/auth/cloud-platform",
38725	//     "https://www.googleapis.com/auth/dialogflow"
38726	//   ]
38727	// }
38728
38729}
38730
38731// method id "dialogflow.projects.locations.agent.entityTypes.entities.batchUpdate":
38732
38733type ProjectsLocationsAgentEntityTypesEntitiesBatchUpdateCall struct {
38734	s                                                 *Service
38735	parent                                            string
38736	googleclouddialogflowv2batchupdateentitiesrequest *GoogleCloudDialogflowV2BatchUpdateEntitiesRequest
38737	urlParams_                                        gensupport.URLParams
38738	ctx_                                              context.Context
38739	header_                                           http.Header
38740}
38741
38742// BatchUpdate: Updates or creates multiple entities in the specified
38743// entity type. This method does not affect entities in the entity type
38744// that aren't explicitly specified in the request. This method is a
38745// long-running operation
38746// (https://cloud.google.com/dialogflow/es/docs/how/long-running-operations).
38747// The returned `Operation` type has the following method-specific
38748// fields: - `metadata`: An empty Struct message
38749// (https://developers.google.com/protocol-buffers/docs/reference/google.protobuf#struct)
38750// - `response`: An Empty message
38751// (https://developers.google.com/protocol-buffers/docs/reference/google.protobuf#empty)
38752// Note: You should always train an agent prior to sending it queries.
38753// See the training documentation
38754// (https://cloud.google.com/dialogflow/es/docs/training).
38755//
38756// - parent: The name of the entity type to update or create entities
38757//   in. Format: `projects//agent/entityTypes/`.
38758func (r *ProjectsLocationsAgentEntityTypesEntitiesService) BatchUpdate(parent string, googleclouddialogflowv2batchupdateentitiesrequest *GoogleCloudDialogflowV2BatchUpdateEntitiesRequest) *ProjectsLocationsAgentEntityTypesEntitiesBatchUpdateCall {
38759	c := &ProjectsLocationsAgentEntityTypesEntitiesBatchUpdateCall{s: r.s, urlParams_: make(gensupport.URLParams)}
38760	c.parent = parent
38761	c.googleclouddialogflowv2batchupdateentitiesrequest = googleclouddialogflowv2batchupdateentitiesrequest
38762	return c
38763}
38764
38765// Fields allows partial responses to be retrieved. See
38766// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
38767// for more information.
38768func (c *ProjectsLocationsAgentEntityTypesEntitiesBatchUpdateCall) Fields(s ...googleapi.Field) *ProjectsLocationsAgentEntityTypesEntitiesBatchUpdateCall {
38769	c.urlParams_.Set("fields", googleapi.CombineFields(s))
38770	return c
38771}
38772
38773// Context sets the context to be used in this call's Do method. Any
38774// pending HTTP request will be aborted if the provided context is
38775// canceled.
38776func (c *ProjectsLocationsAgentEntityTypesEntitiesBatchUpdateCall) Context(ctx context.Context) *ProjectsLocationsAgentEntityTypesEntitiesBatchUpdateCall {
38777	c.ctx_ = ctx
38778	return c
38779}
38780
38781// Header returns an http.Header that can be modified by the caller to
38782// add HTTP headers to the request.
38783func (c *ProjectsLocationsAgentEntityTypesEntitiesBatchUpdateCall) Header() http.Header {
38784	if c.header_ == nil {
38785		c.header_ = make(http.Header)
38786	}
38787	return c.header_
38788}
38789
38790func (c *ProjectsLocationsAgentEntityTypesEntitiesBatchUpdateCall) doRequest(alt string) (*http.Response, error) {
38791	reqHeaders := make(http.Header)
38792	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20211027")
38793	for k, v := range c.header_ {
38794		reqHeaders[k] = v
38795	}
38796	reqHeaders.Set("User-Agent", c.s.userAgent())
38797	var body io.Reader = nil
38798	body, err := googleapi.WithoutDataWrapper.JSONReader(c.googleclouddialogflowv2batchupdateentitiesrequest)
38799	if err != nil {
38800		return nil, err
38801	}
38802	reqHeaders.Set("Content-Type", "application/json")
38803	c.urlParams_.Set("alt", alt)
38804	c.urlParams_.Set("prettyPrint", "false")
38805	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+parent}/entities:batchUpdate")
38806	urls += "?" + c.urlParams_.Encode()
38807	req, err := http.NewRequest("POST", urls, body)
38808	if err != nil {
38809		return nil, err
38810	}
38811	req.Header = reqHeaders
38812	googleapi.Expand(req.URL, map[string]string{
38813		"parent": c.parent,
38814	})
38815	return gensupport.SendRequest(c.ctx_, c.s.client, req)
38816}
38817
38818// Do executes the "dialogflow.projects.locations.agent.entityTypes.entities.batchUpdate" call.
38819// Exactly one of *GoogleLongrunningOperation or error will be non-nil.
38820// Any non-2xx status code is an error. Response headers are in either
38821// *GoogleLongrunningOperation.ServerResponse.Header or (if a response
38822// was returned at all) in error.(*googleapi.Error).Header. Use
38823// googleapi.IsNotModified to check whether the returned error was
38824// because http.StatusNotModified was returned.
38825func (c *ProjectsLocationsAgentEntityTypesEntitiesBatchUpdateCall) Do(opts ...googleapi.CallOption) (*GoogleLongrunningOperation, error) {
38826	gensupport.SetOptions(c.urlParams_, opts...)
38827	res, err := c.doRequest("json")
38828	if res != nil && res.StatusCode == http.StatusNotModified {
38829		if res.Body != nil {
38830			res.Body.Close()
38831		}
38832		return nil, &googleapi.Error{
38833			Code:   res.StatusCode,
38834			Header: res.Header,
38835		}
38836	}
38837	if err != nil {
38838		return nil, err
38839	}
38840	defer googleapi.CloseBody(res)
38841	if err := googleapi.CheckResponse(res); err != nil {
38842		return nil, err
38843	}
38844	ret := &GoogleLongrunningOperation{
38845		ServerResponse: googleapi.ServerResponse{
38846			Header:         res.Header,
38847			HTTPStatusCode: res.StatusCode,
38848		},
38849	}
38850	target := &ret
38851	if err := gensupport.DecodeResponse(target, res); err != nil {
38852		return nil, err
38853	}
38854	return ret, nil
38855	// {
38856	//   "description": "Updates or creates multiple entities in the specified entity type. This method does not affect entities in the entity type that aren't explicitly specified in the request. This method is a [long-running operation](https://cloud.google.com/dialogflow/es/docs/how/long-running-operations). The returned `Operation` type has the following method-specific fields: - `metadata`: An empty [Struct message](https://developers.google.com/protocol-buffers/docs/reference/google.protobuf#struct) - `response`: An [Empty message](https://developers.google.com/protocol-buffers/docs/reference/google.protobuf#empty) Note: You should always train an agent prior to sending it queries. See the [training documentation](https://cloud.google.com/dialogflow/es/docs/training). ",
38857	//   "flatPath": "v2/projects/{projectsId}/locations/{locationsId}/agent/entityTypes/{entityTypesId}/entities:batchUpdate",
38858	//   "httpMethod": "POST",
38859	//   "id": "dialogflow.projects.locations.agent.entityTypes.entities.batchUpdate",
38860	//   "parameterOrder": [
38861	//     "parent"
38862	//   ],
38863	//   "parameters": {
38864	//     "parent": {
38865	//       "description": "Required. The name of the entity type to update or create entities in. Format: `projects//agent/entityTypes/`.",
38866	//       "location": "path",
38867	//       "pattern": "^projects/[^/]+/locations/[^/]+/agent/entityTypes/[^/]+$",
38868	//       "required": true,
38869	//       "type": "string"
38870	//     }
38871	//   },
38872	//   "path": "v2/{+parent}/entities:batchUpdate",
38873	//   "request": {
38874	//     "$ref": "GoogleCloudDialogflowV2BatchUpdateEntitiesRequest"
38875	//   },
38876	//   "response": {
38877	//     "$ref": "GoogleLongrunningOperation"
38878	//   },
38879	//   "scopes": [
38880	//     "https://www.googleapis.com/auth/cloud-platform",
38881	//     "https://www.googleapis.com/auth/dialogflow"
38882	//   ]
38883	// }
38884
38885}
38886
38887// method id "dialogflow.projects.locations.agent.environments.create":
38888
38889type ProjectsLocationsAgentEnvironmentsCreateCall struct {
38890	s                                  *Service
38891	parent                             string
38892	googleclouddialogflowv2environment *GoogleCloudDialogflowV2Environment
38893	urlParams_                         gensupport.URLParams
38894	ctx_                               context.Context
38895	header_                            http.Header
38896}
38897
38898// Create: Creates an agent environment.
38899//
38900// - parent: The agent to create an environment for. Supported formats:
38901//   - `projects//agent` - `projects//locations//agent`.
38902func (r *ProjectsLocationsAgentEnvironmentsService) Create(parent string, googleclouddialogflowv2environment *GoogleCloudDialogflowV2Environment) *ProjectsLocationsAgentEnvironmentsCreateCall {
38903	c := &ProjectsLocationsAgentEnvironmentsCreateCall{s: r.s, urlParams_: make(gensupport.URLParams)}
38904	c.parent = parent
38905	c.googleclouddialogflowv2environment = googleclouddialogflowv2environment
38906	return c
38907}
38908
38909// EnvironmentId sets the optional parameter "environmentId": Required.
38910// The unique id of the new environment.
38911func (c *ProjectsLocationsAgentEnvironmentsCreateCall) EnvironmentId(environmentId string) *ProjectsLocationsAgentEnvironmentsCreateCall {
38912	c.urlParams_.Set("environmentId", environmentId)
38913	return c
38914}
38915
38916// Fields allows partial responses to be retrieved. See
38917// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
38918// for more information.
38919func (c *ProjectsLocationsAgentEnvironmentsCreateCall) Fields(s ...googleapi.Field) *ProjectsLocationsAgentEnvironmentsCreateCall {
38920	c.urlParams_.Set("fields", googleapi.CombineFields(s))
38921	return c
38922}
38923
38924// Context sets the context to be used in this call's Do method. Any
38925// pending HTTP request will be aborted if the provided context is
38926// canceled.
38927func (c *ProjectsLocationsAgentEnvironmentsCreateCall) Context(ctx context.Context) *ProjectsLocationsAgentEnvironmentsCreateCall {
38928	c.ctx_ = ctx
38929	return c
38930}
38931
38932// Header returns an http.Header that can be modified by the caller to
38933// add HTTP headers to the request.
38934func (c *ProjectsLocationsAgentEnvironmentsCreateCall) Header() http.Header {
38935	if c.header_ == nil {
38936		c.header_ = make(http.Header)
38937	}
38938	return c.header_
38939}
38940
38941func (c *ProjectsLocationsAgentEnvironmentsCreateCall) doRequest(alt string) (*http.Response, error) {
38942	reqHeaders := make(http.Header)
38943	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20211027")
38944	for k, v := range c.header_ {
38945		reqHeaders[k] = v
38946	}
38947	reqHeaders.Set("User-Agent", c.s.userAgent())
38948	var body io.Reader = nil
38949	body, err := googleapi.WithoutDataWrapper.JSONReader(c.googleclouddialogflowv2environment)
38950	if err != nil {
38951		return nil, err
38952	}
38953	reqHeaders.Set("Content-Type", "application/json")
38954	c.urlParams_.Set("alt", alt)
38955	c.urlParams_.Set("prettyPrint", "false")
38956	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+parent}/environments")
38957	urls += "?" + c.urlParams_.Encode()
38958	req, err := http.NewRequest("POST", urls, body)
38959	if err != nil {
38960		return nil, err
38961	}
38962	req.Header = reqHeaders
38963	googleapi.Expand(req.URL, map[string]string{
38964		"parent": c.parent,
38965	})
38966	return gensupport.SendRequest(c.ctx_, c.s.client, req)
38967}
38968
38969// Do executes the "dialogflow.projects.locations.agent.environments.create" call.
38970// Exactly one of *GoogleCloudDialogflowV2Environment or error will be
38971// non-nil. Any non-2xx status code is an error. Response headers are in
38972// either *GoogleCloudDialogflowV2Environment.ServerResponse.Header or
38973// (if a response was returned at all) in
38974// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
38975// whether the returned error was because http.StatusNotModified was
38976// returned.
38977func (c *ProjectsLocationsAgentEnvironmentsCreateCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDialogflowV2Environment, error) {
38978	gensupport.SetOptions(c.urlParams_, opts...)
38979	res, err := c.doRequest("json")
38980	if res != nil && res.StatusCode == http.StatusNotModified {
38981		if res.Body != nil {
38982			res.Body.Close()
38983		}
38984		return nil, &googleapi.Error{
38985			Code:   res.StatusCode,
38986			Header: res.Header,
38987		}
38988	}
38989	if err != nil {
38990		return nil, err
38991	}
38992	defer googleapi.CloseBody(res)
38993	if err := googleapi.CheckResponse(res); err != nil {
38994		return nil, err
38995	}
38996	ret := &GoogleCloudDialogflowV2Environment{
38997		ServerResponse: googleapi.ServerResponse{
38998			Header:         res.Header,
38999			HTTPStatusCode: res.StatusCode,
39000		},
39001	}
39002	target := &ret
39003	if err := gensupport.DecodeResponse(target, res); err != nil {
39004		return nil, err
39005	}
39006	return ret, nil
39007	// {
39008	//   "description": "Creates an agent environment.",
39009	//   "flatPath": "v2/projects/{projectsId}/locations/{locationsId}/agent/environments",
39010	//   "httpMethod": "POST",
39011	//   "id": "dialogflow.projects.locations.agent.environments.create",
39012	//   "parameterOrder": [
39013	//     "parent"
39014	//   ],
39015	//   "parameters": {
39016	//     "environmentId": {
39017	//       "description": "Required. The unique id of the new environment.",
39018	//       "location": "query",
39019	//       "type": "string"
39020	//     },
39021	//     "parent": {
39022	//       "description": "Required. The agent to create an environment for. Supported formats: - `projects//agent` - `projects//locations//agent`",
39023	//       "location": "path",
39024	//       "pattern": "^projects/[^/]+/locations/[^/]+/agent$",
39025	//       "required": true,
39026	//       "type": "string"
39027	//     }
39028	//   },
39029	//   "path": "v2/{+parent}/environments",
39030	//   "request": {
39031	//     "$ref": "GoogleCloudDialogflowV2Environment"
39032	//   },
39033	//   "response": {
39034	//     "$ref": "GoogleCloudDialogflowV2Environment"
39035	//   },
39036	//   "scopes": [
39037	//     "https://www.googleapis.com/auth/cloud-platform",
39038	//     "https://www.googleapis.com/auth/dialogflow"
39039	//   ]
39040	// }
39041
39042}
39043
39044// method id "dialogflow.projects.locations.agent.environments.delete":
39045
39046type ProjectsLocationsAgentEnvironmentsDeleteCall struct {
39047	s          *Service
39048	name       string
39049	urlParams_ gensupport.URLParams
39050	ctx_       context.Context
39051	header_    http.Header
39052}
39053
39054// Delete: Deletes the specified agent environment.
39055//
39056// - name: The name of the environment to delete. / Format: -
39057//   `projects//agent/environments/` -
39058//   `projects//locations//agent/environments/` The environment ID for
39059//   the default environment is `-`.
39060func (r *ProjectsLocationsAgentEnvironmentsService) Delete(name string) *ProjectsLocationsAgentEnvironmentsDeleteCall {
39061	c := &ProjectsLocationsAgentEnvironmentsDeleteCall{s: r.s, urlParams_: make(gensupport.URLParams)}
39062	c.name = name
39063	return c
39064}
39065
39066// Fields allows partial responses to be retrieved. See
39067// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
39068// for more information.
39069func (c *ProjectsLocationsAgentEnvironmentsDeleteCall) Fields(s ...googleapi.Field) *ProjectsLocationsAgentEnvironmentsDeleteCall {
39070	c.urlParams_.Set("fields", googleapi.CombineFields(s))
39071	return c
39072}
39073
39074// Context sets the context to be used in this call's Do method. Any
39075// pending HTTP request will be aborted if the provided context is
39076// canceled.
39077func (c *ProjectsLocationsAgentEnvironmentsDeleteCall) Context(ctx context.Context) *ProjectsLocationsAgentEnvironmentsDeleteCall {
39078	c.ctx_ = ctx
39079	return c
39080}
39081
39082// Header returns an http.Header that can be modified by the caller to
39083// add HTTP headers to the request.
39084func (c *ProjectsLocationsAgentEnvironmentsDeleteCall) Header() http.Header {
39085	if c.header_ == nil {
39086		c.header_ = make(http.Header)
39087	}
39088	return c.header_
39089}
39090
39091func (c *ProjectsLocationsAgentEnvironmentsDeleteCall) doRequest(alt string) (*http.Response, error) {
39092	reqHeaders := make(http.Header)
39093	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20211027")
39094	for k, v := range c.header_ {
39095		reqHeaders[k] = v
39096	}
39097	reqHeaders.Set("User-Agent", c.s.userAgent())
39098	var body io.Reader = nil
39099	c.urlParams_.Set("alt", alt)
39100	c.urlParams_.Set("prettyPrint", "false")
39101	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+name}")
39102	urls += "?" + c.urlParams_.Encode()
39103	req, err := http.NewRequest("DELETE", urls, body)
39104	if err != nil {
39105		return nil, err
39106	}
39107	req.Header = reqHeaders
39108	googleapi.Expand(req.URL, map[string]string{
39109		"name": c.name,
39110	})
39111	return gensupport.SendRequest(c.ctx_, c.s.client, req)
39112}
39113
39114// Do executes the "dialogflow.projects.locations.agent.environments.delete" call.
39115// Exactly one of *GoogleProtobufEmpty or error will be non-nil. Any
39116// non-2xx status code is an error. Response headers are in either
39117// *GoogleProtobufEmpty.ServerResponse.Header or (if a response was
39118// returned at all) in error.(*googleapi.Error).Header. Use
39119// googleapi.IsNotModified to check whether the returned error was
39120// because http.StatusNotModified was returned.
39121func (c *ProjectsLocationsAgentEnvironmentsDeleteCall) Do(opts ...googleapi.CallOption) (*GoogleProtobufEmpty, error) {
39122	gensupport.SetOptions(c.urlParams_, opts...)
39123	res, err := c.doRequest("json")
39124	if res != nil && res.StatusCode == http.StatusNotModified {
39125		if res.Body != nil {
39126			res.Body.Close()
39127		}
39128		return nil, &googleapi.Error{
39129			Code:   res.StatusCode,
39130			Header: res.Header,
39131		}
39132	}
39133	if err != nil {
39134		return nil, err
39135	}
39136	defer googleapi.CloseBody(res)
39137	if err := googleapi.CheckResponse(res); err != nil {
39138		return nil, err
39139	}
39140	ret := &GoogleProtobufEmpty{
39141		ServerResponse: googleapi.ServerResponse{
39142			Header:         res.Header,
39143			HTTPStatusCode: res.StatusCode,
39144		},
39145	}
39146	target := &ret
39147	if err := gensupport.DecodeResponse(target, res); err != nil {
39148		return nil, err
39149	}
39150	return ret, nil
39151	// {
39152	//   "description": "Deletes the specified agent environment.",
39153	//   "flatPath": "v2/projects/{projectsId}/locations/{locationsId}/agent/environments/{environmentsId}",
39154	//   "httpMethod": "DELETE",
39155	//   "id": "dialogflow.projects.locations.agent.environments.delete",
39156	//   "parameterOrder": [
39157	//     "name"
39158	//   ],
39159	//   "parameters": {
39160	//     "name": {
39161	//       "description": "Required. The name of the environment to delete. / Format: - `projects//agent/environments/` - `projects//locations//agent/environments/` The environment ID for the default environment is `-`.",
39162	//       "location": "path",
39163	//       "pattern": "^projects/[^/]+/locations/[^/]+/agent/environments/[^/]+$",
39164	//       "required": true,
39165	//       "type": "string"
39166	//     }
39167	//   },
39168	//   "path": "v2/{+name}",
39169	//   "response": {
39170	//     "$ref": "GoogleProtobufEmpty"
39171	//   },
39172	//   "scopes": [
39173	//     "https://www.googleapis.com/auth/cloud-platform",
39174	//     "https://www.googleapis.com/auth/dialogflow"
39175	//   ]
39176	// }
39177
39178}
39179
39180// method id "dialogflow.projects.locations.agent.environments.get":
39181
39182type ProjectsLocationsAgentEnvironmentsGetCall struct {
39183	s            *Service
39184	name         string
39185	urlParams_   gensupport.URLParams
39186	ifNoneMatch_ string
39187	ctx_         context.Context
39188	header_      http.Header
39189}
39190
39191// Get: Retrieves the specified agent environment.
39192//
39193// - name: The name of the environment. Supported formats: -
39194//   `projects//agent/environments/` -
39195//   `projects//locations//agent/environments/` The environment ID for
39196//   the default environment is `-`.
39197func (r *ProjectsLocationsAgentEnvironmentsService) Get(name string) *ProjectsLocationsAgentEnvironmentsGetCall {
39198	c := &ProjectsLocationsAgentEnvironmentsGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
39199	c.name = name
39200	return c
39201}
39202
39203// Fields allows partial responses to be retrieved. See
39204// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
39205// for more information.
39206func (c *ProjectsLocationsAgentEnvironmentsGetCall) Fields(s ...googleapi.Field) *ProjectsLocationsAgentEnvironmentsGetCall {
39207	c.urlParams_.Set("fields", googleapi.CombineFields(s))
39208	return c
39209}
39210
39211// IfNoneMatch sets the optional parameter which makes the operation
39212// fail if the object's ETag matches the given value. This is useful for
39213// getting updates only after the object has changed since the last
39214// request. Use googleapi.IsNotModified to check whether the response
39215// error from Do is the result of In-None-Match.
39216func (c *ProjectsLocationsAgentEnvironmentsGetCall) IfNoneMatch(entityTag string) *ProjectsLocationsAgentEnvironmentsGetCall {
39217	c.ifNoneMatch_ = entityTag
39218	return c
39219}
39220
39221// Context sets the context to be used in this call's Do method. Any
39222// pending HTTP request will be aborted if the provided context is
39223// canceled.
39224func (c *ProjectsLocationsAgentEnvironmentsGetCall) Context(ctx context.Context) *ProjectsLocationsAgentEnvironmentsGetCall {
39225	c.ctx_ = ctx
39226	return c
39227}
39228
39229// Header returns an http.Header that can be modified by the caller to
39230// add HTTP headers to the request.
39231func (c *ProjectsLocationsAgentEnvironmentsGetCall) Header() http.Header {
39232	if c.header_ == nil {
39233		c.header_ = make(http.Header)
39234	}
39235	return c.header_
39236}
39237
39238func (c *ProjectsLocationsAgentEnvironmentsGetCall) doRequest(alt string) (*http.Response, error) {
39239	reqHeaders := make(http.Header)
39240	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20211027")
39241	for k, v := range c.header_ {
39242		reqHeaders[k] = v
39243	}
39244	reqHeaders.Set("User-Agent", c.s.userAgent())
39245	if c.ifNoneMatch_ != "" {
39246		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
39247	}
39248	var body io.Reader = nil
39249	c.urlParams_.Set("alt", alt)
39250	c.urlParams_.Set("prettyPrint", "false")
39251	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+name}")
39252	urls += "?" + c.urlParams_.Encode()
39253	req, err := http.NewRequest("GET", urls, body)
39254	if err != nil {
39255		return nil, err
39256	}
39257	req.Header = reqHeaders
39258	googleapi.Expand(req.URL, map[string]string{
39259		"name": c.name,
39260	})
39261	return gensupport.SendRequest(c.ctx_, c.s.client, req)
39262}
39263
39264// Do executes the "dialogflow.projects.locations.agent.environments.get" call.
39265// Exactly one of *GoogleCloudDialogflowV2Environment or error will be
39266// non-nil. Any non-2xx status code is an error. Response headers are in
39267// either *GoogleCloudDialogflowV2Environment.ServerResponse.Header or
39268// (if a response was returned at all) in
39269// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
39270// whether the returned error was because http.StatusNotModified was
39271// returned.
39272func (c *ProjectsLocationsAgentEnvironmentsGetCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDialogflowV2Environment, error) {
39273	gensupport.SetOptions(c.urlParams_, opts...)
39274	res, err := c.doRequest("json")
39275	if res != nil && res.StatusCode == http.StatusNotModified {
39276		if res.Body != nil {
39277			res.Body.Close()
39278		}
39279		return nil, &googleapi.Error{
39280			Code:   res.StatusCode,
39281			Header: res.Header,
39282		}
39283	}
39284	if err != nil {
39285		return nil, err
39286	}
39287	defer googleapi.CloseBody(res)
39288	if err := googleapi.CheckResponse(res); err != nil {
39289		return nil, err
39290	}
39291	ret := &GoogleCloudDialogflowV2Environment{
39292		ServerResponse: googleapi.ServerResponse{
39293			Header:         res.Header,
39294			HTTPStatusCode: res.StatusCode,
39295		},
39296	}
39297	target := &ret
39298	if err := gensupport.DecodeResponse(target, res); err != nil {
39299		return nil, err
39300	}
39301	return ret, nil
39302	// {
39303	//   "description": "Retrieves the specified agent environment.",
39304	//   "flatPath": "v2/projects/{projectsId}/locations/{locationsId}/agent/environments/{environmentsId}",
39305	//   "httpMethod": "GET",
39306	//   "id": "dialogflow.projects.locations.agent.environments.get",
39307	//   "parameterOrder": [
39308	//     "name"
39309	//   ],
39310	//   "parameters": {
39311	//     "name": {
39312	//       "description": "Required. The name of the environment. Supported formats: - `projects//agent/environments/` - `projects//locations//agent/environments/` The environment ID for the default environment is `-`.",
39313	//       "location": "path",
39314	//       "pattern": "^projects/[^/]+/locations/[^/]+/agent/environments/[^/]+$",
39315	//       "required": true,
39316	//       "type": "string"
39317	//     }
39318	//   },
39319	//   "path": "v2/{+name}",
39320	//   "response": {
39321	//     "$ref": "GoogleCloudDialogflowV2Environment"
39322	//   },
39323	//   "scopes": [
39324	//     "https://www.googleapis.com/auth/cloud-platform",
39325	//     "https://www.googleapis.com/auth/dialogflow"
39326	//   ]
39327	// }
39328
39329}
39330
39331// method id "dialogflow.projects.locations.agent.environments.getHistory":
39332
39333type ProjectsLocationsAgentEnvironmentsGetHistoryCall struct {
39334	s            *Service
39335	parent       string
39336	urlParams_   gensupport.URLParams
39337	ifNoneMatch_ string
39338	ctx_         context.Context
39339	header_      http.Header
39340}
39341
39342// GetHistory: Gets the history of the specified environment.
39343//
39344// - parent: The name of the environment to retrieve history for.
39345//   Supported formats: - `projects//agent/environments/` -
39346//   `projects//locations//agent/environments/` The environment ID for
39347//   the default environment is `-`.
39348func (r *ProjectsLocationsAgentEnvironmentsService) GetHistory(parent string) *ProjectsLocationsAgentEnvironmentsGetHistoryCall {
39349	c := &ProjectsLocationsAgentEnvironmentsGetHistoryCall{s: r.s, urlParams_: make(gensupport.URLParams)}
39350	c.parent = parent
39351	return c
39352}
39353
39354// PageSize sets the optional parameter "pageSize": The maximum number
39355// of items to return in a single page. By default 100 and at most 1000.
39356func (c *ProjectsLocationsAgentEnvironmentsGetHistoryCall) PageSize(pageSize int64) *ProjectsLocationsAgentEnvironmentsGetHistoryCall {
39357	c.urlParams_.Set("pageSize", fmt.Sprint(pageSize))
39358	return c
39359}
39360
39361// PageToken sets the optional parameter "pageToken": The
39362// next_page_token value returned from a previous list request.
39363func (c *ProjectsLocationsAgentEnvironmentsGetHistoryCall) PageToken(pageToken string) *ProjectsLocationsAgentEnvironmentsGetHistoryCall {
39364	c.urlParams_.Set("pageToken", pageToken)
39365	return c
39366}
39367
39368// Fields allows partial responses to be retrieved. See
39369// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
39370// for more information.
39371func (c *ProjectsLocationsAgentEnvironmentsGetHistoryCall) Fields(s ...googleapi.Field) *ProjectsLocationsAgentEnvironmentsGetHistoryCall {
39372	c.urlParams_.Set("fields", googleapi.CombineFields(s))
39373	return c
39374}
39375
39376// IfNoneMatch sets the optional parameter which makes the operation
39377// fail if the object's ETag matches the given value. This is useful for
39378// getting updates only after the object has changed since the last
39379// request. Use googleapi.IsNotModified to check whether the response
39380// error from Do is the result of In-None-Match.
39381func (c *ProjectsLocationsAgentEnvironmentsGetHistoryCall) IfNoneMatch(entityTag string) *ProjectsLocationsAgentEnvironmentsGetHistoryCall {
39382	c.ifNoneMatch_ = entityTag
39383	return c
39384}
39385
39386// Context sets the context to be used in this call's Do method. Any
39387// pending HTTP request will be aborted if the provided context is
39388// canceled.
39389func (c *ProjectsLocationsAgentEnvironmentsGetHistoryCall) Context(ctx context.Context) *ProjectsLocationsAgentEnvironmentsGetHistoryCall {
39390	c.ctx_ = ctx
39391	return c
39392}
39393
39394// Header returns an http.Header that can be modified by the caller to
39395// add HTTP headers to the request.
39396func (c *ProjectsLocationsAgentEnvironmentsGetHistoryCall) Header() http.Header {
39397	if c.header_ == nil {
39398		c.header_ = make(http.Header)
39399	}
39400	return c.header_
39401}
39402
39403func (c *ProjectsLocationsAgentEnvironmentsGetHistoryCall) doRequest(alt string) (*http.Response, error) {
39404	reqHeaders := make(http.Header)
39405	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20211027")
39406	for k, v := range c.header_ {
39407		reqHeaders[k] = v
39408	}
39409	reqHeaders.Set("User-Agent", c.s.userAgent())
39410	if c.ifNoneMatch_ != "" {
39411		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
39412	}
39413	var body io.Reader = nil
39414	c.urlParams_.Set("alt", alt)
39415	c.urlParams_.Set("prettyPrint", "false")
39416	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+parent}/history")
39417	urls += "?" + c.urlParams_.Encode()
39418	req, err := http.NewRequest("GET", urls, body)
39419	if err != nil {
39420		return nil, err
39421	}
39422	req.Header = reqHeaders
39423	googleapi.Expand(req.URL, map[string]string{
39424		"parent": c.parent,
39425	})
39426	return gensupport.SendRequest(c.ctx_, c.s.client, req)
39427}
39428
39429// Do executes the "dialogflow.projects.locations.agent.environments.getHistory" call.
39430// Exactly one of *GoogleCloudDialogflowV2EnvironmentHistory or error
39431// will be non-nil. Any non-2xx status code is an error. Response
39432// headers are in either
39433// *GoogleCloudDialogflowV2EnvironmentHistory.ServerResponse.Header or
39434// (if a response was returned at all) in
39435// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
39436// whether the returned error was because http.StatusNotModified was
39437// returned.
39438func (c *ProjectsLocationsAgentEnvironmentsGetHistoryCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDialogflowV2EnvironmentHistory, error) {
39439	gensupport.SetOptions(c.urlParams_, opts...)
39440	res, err := c.doRequest("json")
39441	if res != nil && res.StatusCode == http.StatusNotModified {
39442		if res.Body != nil {
39443			res.Body.Close()
39444		}
39445		return nil, &googleapi.Error{
39446			Code:   res.StatusCode,
39447			Header: res.Header,
39448		}
39449	}
39450	if err != nil {
39451		return nil, err
39452	}
39453	defer googleapi.CloseBody(res)
39454	if err := googleapi.CheckResponse(res); err != nil {
39455		return nil, err
39456	}
39457	ret := &GoogleCloudDialogflowV2EnvironmentHistory{
39458		ServerResponse: googleapi.ServerResponse{
39459			Header:         res.Header,
39460			HTTPStatusCode: res.StatusCode,
39461		},
39462	}
39463	target := &ret
39464	if err := gensupport.DecodeResponse(target, res); err != nil {
39465		return nil, err
39466	}
39467	return ret, nil
39468	// {
39469	//   "description": "Gets the history of the specified environment.",
39470	//   "flatPath": "v2/projects/{projectsId}/locations/{locationsId}/agent/environments/{environmentsId}/history",
39471	//   "httpMethod": "GET",
39472	//   "id": "dialogflow.projects.locations.agent.environments.getHistory",
39473	//   "parameterOrder": [
39474	//     "parent"
39475	//   ],
39476	//   "parameters": {
39477	//     "pageSize": {
39478	//       "description": "Optional. The maximum number of items to return in a single page. By default 100 and at most 1000.",
39479	//       "format": "int32",
39480	//       "location": "query",
39481	//       "type": "integer"
39482	//     },
39483	//     "pageToken": {
39484	//       "description": "Optional. The next_page_token value returned from a previous list request.",
39485	//       "location": "query",
39486	//       "type": "string"
39487	//     },
39488	//     "parent": {
39489	//       "description": "Required. The name of the environment to retrieve history for. Supported formats: - `projects//agent/environments/` - `projects//locations//agent/environments/` The environment ID for the default environment is `-`.",
39490	//       "location": "path",
39491	//       "pattern": "^projects/[^/]+/locations/[^/]+/agent/environments/[^/]+$",
39492	//       "required": true,
39493	//       "type": "string"
39494	//     }
39495	//   },
39496	//   "path": "v2/{+parent}/history",
39497	//   "response": {
39498	//     "$ref": "GoogleCloudDialogflowV2EnvironmentHistory"
39499	//   },
39500	//   "scopes": [
39501	//     "https://www.googleapis.com/auth/cloud-platform",
39502	//     "https://www.googleapis.com/auth/dialogflow"
39503	//   ]
39504	// }
39505
39506}
39507
39508// Pages invokes f for each page of results.
39509// A non-nil error returned from f will halt the iteration.
39510// The provided context supersedes any context provided to the Context method.
39511func (c *ProjectsLocationsAgentEnvironmentsGetHistoryCall) Pages(ctx context.Context, f func(*GoogleCloudDialogflowV2EnvironmentHistory) error) error {
39512	c.ctx_ = ctx
39513	defer c.PageToken(c.urlParams_.Get("pageToken")) // reset paging to original point
39514	for {
39515		x, err := c.Do()
39516		if err != nil {
39517			return err
39518		}
39519		if err := f(x); err != nil {
39520			return err
39521		}
39522		if x.NextPageToken == "" {
39523			return nil
39524		}
39525		c.PageToken(x.NextPageToken)
39526	}
39527}
39528
39529// method id "dialogflow.projects.locations.agent.environments.list":
39530
39531type ProjectsLocationsAgentEnvironmentsListCall struct {
39532	s            *Service
39533	parent       string
39534	urlParams_   gensupport.URLParams
39535	ifNoneMatch_ string
39536	ctx_         context.Context
39537	header_      http.Header
39538}
39539
39540// List: Returns the list of all non-default environments of the
39541// specified agent.
39542//
39543// - parent: The agent to list all environments from. Format: -
39544//   `projects//agent` - `projects//locations//agent`.
39545func (r *ProjectsLocationsAgentEnvironmentsService) List(parent string) *ProjectsLocationsAgentEnvironmentsListCall {
39546	c := &ProjectsLocationsAgentEnvironmentsListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
39547	c.parent = parent
39548	return c
39549}
39550
39551// PageSize sets the optional parameter "pageSize": The maximum number
39552// of items to return in a single page. By default 100 and at most 1000.
39553func (c *ProjectsLocationsAgentEnvironmentsListCall) PageSize(pageSize int64) *ProjectsLocationsAgentEnvironmentsListCall {
39554	c.urlParams_.Set("pageSize", fmt.Sprint(pageSize))
39555	return c
39556}
39557
39558// PageToken sets the optional parameter "pageToken": The
39559// next_page_token value returned from a previous list request.
39560func (c *ProjectsLocationsAgentEnvironmentsListCall) PageToken(pageToken string) *ProjectsLocationsAgentEnvironmentsListCall {
39561	c.urlParams_.Set("pageToken", pageToken)
39562	return c
39563}
39564
39565// Fields allows partial responses to be retrieved. See
39566// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
39567// for more information.
39568func (c *ProjectsLocationsAgentEnvironmentsListCall) Fields(s ...googleapi.Field) *ProjectsLocationsAgentEnvironmentsListCall {
39569	c.urlParams_.Set("fields", googleapi.CombineFields(s))
39570	return c
39571}
39572
39573// IfNoneMatch sets the optional parameter which makes the operation
39574// fail if the object's ETag matches the given value. This is useful for
39575// getting updates only after the object has changed since the last
39576// request. Use googleapi.IsNotModified to check whether the response
39577// error from Do is the result of In-None-Match.
39578func (c *ProjectsLocationsAgentEnvironmentsListCall) IfNoneMatch(entityTag string) *ProjectsLocationsAgentEnvironmentsListCall {
39579	c.ifNoneMatch_ = entityTag
39580	return c
39581}
39582
39583// Context sets the context to be used in this call's Do method. Any
39584// pending HTTP request will be aborted if the provided context is
39585// canceled.
39586func (c *ProjectsLocationsAgentEnvironmentsListCall) Context(ctx context.Context) *ProjectsLocationsAgentEnvironmentsListCall {
39587	c.ctx_ = ctx
39588	return c
39589}
39590
39591// Header returns an http.Header that can be modified by the caller to
39592// add HTTP headers to the request.
39593func (c *ProjectsLocationsAgentEnvironmentsListCall) Header() http.Header {
39594	if c.header_ == nil {
39595		c.header_ = make(http.Header)
39596	}
39597	return c.header_
39598}
39599
39600func (c *ProjectsLocationsAgentEnvironmentsListCall) doRequest(alt string) (*http.Response, error) {
39601	reqHeaders := make(http.Header)
39602	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20211027")
39603	for k, v := range c.header_ {
39604		reqHeaders[k] = v
39605	}
39606	reqHeaders.Set("User-Agent", c.s.userAgent())
39607	if c.ifNoneMatch_ != "" {
39608		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
39609	}
39610	var body io.Reader = nil
39611	c.urlParams_.Set("alt", alt)
39612	c.urlParams_.Set("prettyPrint", "false")
39613	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+parent}/environments")
39614	urls += "?" + c.urlParams_.Encode()
39615	req, err := http.NewRequest("GET", urls, body)
39616	if err != nil {
39617		return nil, err
39618	}
39619	req.Header = reqHeaders
39620	googleapi.Expand(req.URL, map[string]string{
39621		"parent": c.parent,
39622	})
39623	return gensupport.SendRequest(c.ctx_, c.s.client, req)
39624}
39625
39626// Do executes the "dialogflow.projects.locations.agent.environments.list" call.
39627// Exactly one of *GoogleCloudDialogflowV2ListEnvironmentsResponse or
39628// error will be non-nil. Any non-2xx status code is an error. Response
39629// headers are in either
39630// *GoogleCloudDialogflowV2ListEnvironmentsResponse.ServerResponse.Header
39631//  or (if a response was returned at all) in
39632// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
39633// whether the returned error was because http.StatusNotModified was
39634// returned.
39635func (c *ProjectsLocationsAgentEnvironmentsListCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDialogflowV2ListEnvironmentsResponse, error) {
39636	gensupport.SetOptions(c.urlParams_, opts...)
39637	res, err := c.doRequest("json")
39638	if res != nil && res.StatusCode == http.StatusNotModified {
39639		if res.Body != nil {
39640			res.Body.Close()
39641		}
39642		return nil, &googleapi.Error{
39643			Code:   res.StatusCode,
39644			Header: res.Header,
39645		}
39646	}
39647	if err != nil {
39648		return nil, err
39649	}
39650	defer googleapi.CloseBody(res)
39651	if err := googleapi.CheckResponse(res); err != nil {
39652		return nil, err
39653	}
39654	ret := &GoogleCloudDialogflowV2ListEnvironmentsResponse{
39655		ServerResponse: googleapi.ServerResponse{
39656			Header:         res.Header,
39657			HTTPStatusCode: res.StatusCode,
39658		},
39659	}
39660	target := &ret
39661	if err := gensupport.DecodeResponse(target, res); err != nil {
39662		return nil, err
39663	}
39664	return ret, nil
39665	// {
39666	//   "description": "Returns the list of all non-default environments of the specified agent.",
39667	//   "flatPath": "v2/projects/{projectsId}/locations/{locationsId}/agent/environments",
39668	//   "httpMethod": "GET",
39669	//   "id": "dialogflow.projects.locations.agent.environments.list",
39670	//   "parameterOrder": [
39671	//     "parent"
39672	//   ],
39673	//   "parameters": {
39674	//     "pageSize": {
39675	//       "description": "Optional. The maximum number of items to return in a single page. By default 100 and at most 1000.",
39676	//       "format": "int32",
39677	//       "location": "query",
39678	//       "type": "integer"
39679	//     },
39680	//     "pageToken": {
39681	//       "description": "Optional. The next_page_token value returned from a previous list request.",
39682	//       "location": "query",
39683	//       "type": "string"
39684	//     },
39685	//     "parent": {
39686	//       "description": "Required. The agent to list all environments from. Format: - `projects//agent` - `projects//locations//agent`",
39687	//       "location": "path",
39688	//       "pattern": "^projects/[^/]+/locations/[^/]+/agent$",
39689	//       "required": true,
39690	//       "type": "string"
39691	//     }
39692	//   },
39693	//   "path": "v2/{+parent}/environments",
39694	//   "response": {
39695	//     "$ref": "GoogleCloudDialogflowV2ListEnvironmentsResponse"
39696	//   },
39697	//   "scopes": [
39698	//     "https://www.googleapis.com/auth/cloud-platform",
39699	//     "https://www.googleapis.com/auth/dialogflow"
39700	//   ]
39701	// }
39702
39703}
39704
39705// Pages invokes f for each page of results.
39706// A non-nil error returned from f will halt the iteration.
39707// The provided context supersedes any context provided to the Context method.
39708func (c *ProjectsLocationsAgentEnvironmentsListCall) Pages(ctx context.Context, f func(*GoogleCloudDialogflowV2ListEnvironmentsResponse) error) error {
39709	c.ctx_ = ctx
39710	defer c.PageToken(c.urlParams_.Get("pageToken")) // reset paging to original point
39711	for {
39712		x, err := c.Do()
39713		if err != nil {
39714			return err
39715		}
39716		if err := f(x); err != nil {
39717			return err
39718		}
39719		if x.NextPageToken == "" {
39720			return nil
39721		}
39722		c.PageToken(x.NextPageToken)
39723	}
39724}
39725
39726// method id "dialogflow.projects.locations.agent.environments.patch":
39727
39728type ProjectsLocationsAgentEnvironmentsPatchCall struct {
39729	s                                  *Service
39730	nameid                             string
39731	googleclouddialogflowv2environment *GoogleCloudDialogflowV2Environment
39732	urlParams_                         gensupport.URLParams
39733	ctx_                               context.Context
39734	header_                            http.Header
39735}
39736
39737// Patch: Updates the specified agent environment. This method allows
39738// you to deploy new agent versions into the environment. When an
39739// environment is pointed to a new agent version by setting
39740// `environment.agent_version`, the environment is temporarily set to
39741// the `LOADING` state. During that time, the environment continues
39742// serving the previous version of the agent. After the new agent
39743// version is done loading, the environment is set back to the `RUNNING`
39744// state. You can use "-" as Environment ID in environment name to
39745// update an agent version in the default environment. WARNING: this
39746// will negate all recent changes to the draft agent and can't be
39747// undone. You may want to save the draft agent to a version before
39748// calling this method.
39749//
39750// - name: Output only. The unique identifier of this agent environment.
39751//   Supported formats: - `projects//agent/environments/` -
39752//   `projects//locations//agent/environments/` The environment ID for
39753//   the default environment is `-`.
39754func (r *ProjectsLocationsAgentEnvironmentsService) Patch(nameid string, googleclouddialogflowv2environment *GoogleCloudDialogflowV2Environment) *ProjectsLocationsAgentEnvironmentsPatchCall {
39755	c := &ProjectsLocationsAgentEnvironmentsPatchCall{s: r.s, urlParams_: make(gensupport.URLParams)}
39756	c.nameid = nameid
39757	c.googleclouddialogflowv2environment = googleclouddialogflowv2environment
39758	return c
39759}
39760
39761// AllowLoadToDraftAndDiscardChanges sets the optional parameter
39762// "allowLoadToDraftAndDiscardChanges": This field is used to prevent
39763// accidental overwrite of the default environment, which is an
39764// operation that cannot be undone. To confirm that the caller desires
39765// this overwrite, this field must be explicitly set to true when
39766// updating the default environment (environment ID = `-`).
39767func (c *ProjectsLocationsAgentEnvironmentsPatchCall) AllowLoadToDraftAndDiscardChanges(allowLoadToDraftAndDiscardChanges bool) *ProjectsLocationsAgentEnvironmentsPatchCall {
39768	c.urlParams_.Set("allowLoadToDraftAndDiscardChanges", fmt.Sprint(allowLoadToDraftAndDiscardChanges))
39769	return c
39770}
39771
39772// UpdateMask sets the optional parameter "updateMask": Required. The
39773// mask to control which fields get updated.
39774func (c *ProjectsLocationsAgentEnvironmentsPatchCall) UpdateMask(updateMask string) *ProjectsLocationsAgentEnvironmentsPatchCall {
39775	c.urlParams_.Set("updateMask", updateMask)
39776	return c
39777}
39778
39779// Fields allows partial responses to be retrieved. See
39780// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
39781// for more information.
39782func (c *ProjectsLocationsAgentEnvironmentsPatchCall) Fields(s ...googleapi.Field) *ProjectsLocationsAgentEnvironmentsPatchCall {
39783	c.urlParams_.Set("fields", googleapi.CombineFields(s))
39784	return c
39785}
39786
39787// Context sets the context to be used in this call's Do method. Any
39788// pending HTTP request will be aborted if the provided context is
39789// canceled.
39790func (c *ProjectsLocationsAgentEnvironmentsPatchCall) Context(ctx context.Context) *ProjectsLocationsAgentEnvironmentsPatchCall {
39791	c.ctx_ = ctx
39792	return c
39793}
39794
39795// Header returns an http.Header that can be modified by the caller to
39796// add HTTP headers to the request.
39797func (c *ProjectsLocationsAgentEnvironmentsPatchCall) Header() http.Header {
39798	if c.header_ == nil {
39799		c.header_ = make(http.Header)
39800	}
39801	return c.header_
39802}
39803
39804func (c *ProjectsLocationsAgentEnvironmentsPatchCall) doRequest(alt string) (*http.Response, error) {
39805	reqHeaders := make(http.Header)
39806	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20211027")
39807	for k, v := range c.header_ {
39808		reqHeaders[k] = v
39809	}
39810	reqHeaders.Set("User-Agent", c.s.userAgent())
39811	var body io.Reader = nil
39812	body, err := googleapi.WithoutDataWrapper.JSONReader(c.googleclouddialogflowv2environment)
39813	if err != nil {
39814		return nil, err
39815	}
39816	reqHeaders.Set("Content-Type", "application/json")
39817	c.urlParams_.Set("alt", alt)
39818	c.urlParams_.Set("prettyPrint", "false")
39819	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+name}")
39820	urls += "?" + c.urlParams_.Encode()
39821	req, err := http.NewRequest("PATCH", urls, body)
39822	if err != nil {
39823		return nil, err
39824	}
39825	req.Header = reqHeaders
39826	googleapi.Expand(req.URL, map[string]string{
39827		"name": c.nameid,
39828	})
39829	return gensupport.SendRequest(c.ctx_, c.s.client, req)
39830}
39831
39832// Do executes the "dialogflow.projects.locations.agent.environments.patch" call.
39833// Exactly one of *GoogleCloudDialogflowV2Environment or error will be
39834// non-nil. Any non-2xx status code is an error. Response headers are in
39835// either *GoogleCloudDialogflowV2Environment.ServerResponse.Header or
39836// (if a response was returned at all) in
39837// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
39838// whether the returned error was because http.StatusNotModified was
39839// returned.
39840func (c *ProjectsLocationsAgentEnvironmentsPatchCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDialogflowV2Environment, error) {
39841	gensupport.SetOptions(c.urlParams_, opts...)
39842	res, err := c.doRequest("json")
39843	if res != nil && res.StatusCode == http.StatusNotModified {
39844		if res.Body != nil {
39845			res.Body.Close()
39846		}
39847		return nil, &googleapi.Error{
39848			Code:   res.StatusCode,
39849			Header: res.Header,
39850		}
39851	}
39852	if err != nil {
39853		return nil, err
39854	}
39855	defer googleapi.CloseBody(res)
39856	if err := googleapi.CheckResponse(res); err != nil {
39857		return nil, err
39858	}
39859	ret := &GoogleCloudDialogflowV2Environment{
39860		ServerResponse: googleapi.ServerResponse{
39861			Header:         res.Header,
39862			HTTPStatusCode: res.StatusCode,
39863		},
39864	}
39865	target := &ret
39866	if err := gensupport.DecodeResponse(target, res); err != nil {
39867		return nil, err
39868	}
39869	return ret, nil
39870	// {
39871	//   "description": "Updates the specified agent environment. This method allows you to deploy new agent versions into the environment. When an environment is pointed to a new agent version by setting `environment.agent_version`, the environment is temporarily set to the `LOADING` state. During that time, the environment continues serving the previous version of the agent. After the new agent version is done loading, the environment is set back to the `RUNNING` state. You can use \"-\" as Environment ID in environment name to update an agent version in the default environment. WARNING: this will negate all recent changes to the draft agent and can't be undone. You may want to save the draft agent to a version before calling this method.",
39872	//   "flatPath": "v2/projects/{projectsId}/locations/{locationsId}/agent/environments/{environmentsId}",
39873	//   "httpMethod": "PATCH",
39874	//   "id": "dialogflow.projects.locations.agent.environments.patch",
39875	//   "parameterOrder": [
39876	//     "name"
39877	//   ],
39878	//   "parameters": {
39879	//     "allowLoadToDraftAndDiscardChanges": {
39880	//       "description": "Optional. This field is used to prevent accidental overwrite of the default environment, which is an operation that cannot be undone. To confirm that the caller desires this overwrite, this field must be explicitly set to true when updating the default environment (environment ID = `-`).",
39881	//       "location": "query",
39882	//       "type": "boolean"
39883	//     },
39884	//     "name": {
39885	//       "description": "Output only. The unique identifier of this agent environment. Supported formats: - `projects//agent/environments/` - `projects//locations//agent/environments/` The environment ID for the default environment is `-`.",
39886	//       "location": "path",
39887	//       "pattern": "^projects/[^/]+/locations/[^/]+/agent/environments/[^/]+$",
39888	//       "required": true,
39889	//       "type": "string"
39890	//     },
39891	//     "updateMask": {
39892	//       "description": "Required. The mask to control which fields get updated.",
39893	//       "format": "google-fieldmask",
39894	//       "location": "query",
39895	//       "type": "string"
39896	//     }
39897	//   },
39898	//   "path": "v2/{+name}",
39899	//   "request": {
39900	//     "$ref": "GoogleCloudDialogflowV2Environment"
39901	//   },
39902	//   "response": {
39903	//     "$ref": "GoogleCloudDialogflowV2Environment"
39904	//   },
39905	//   "scopes": [
39906	//     "https://www.googleapis.com/auth/cloud-platform",
39907	//     "https://www.googleapis.com/auth/dialogflow"
39908	//   ]
39909	// }
39910
39911}
39912
39913// method id "dialogflow.projects.locations.agent.environments.intents.list":
39914
39915type ProjectsLocationsAgentEnvironmentsIntentsListCall struct {
39916	s            *Service
39917	parent       string
39918	urlParams_   gensupport.URLParams
39919	ifNoneMatch_ string
39920	ctx_         context.Context
39921	header_      http.Header
39922}
39923
39924// List: Returns the list of all intents in the specified agent.
39925//
39926// - parent: The agent to list all intents from. Format:
39927//   `projects//agent` or `projects//locations//agent`. Alternatively,
39928//   you can specify the environment to list intents for. Format:
39929//   `projects//agent/environments/` or
39930//   `projects//locations//agent/environments/`. Note: training phrases
39931//   of the intents will not be returned for non-draft environment.
39932func (r *ProjectsLocationsAgentEnvironmentsIntentsService) List(parent string) *ProjectsLocationsAgentEnvironmentsIntentsListCall {
39933	c := &ProjectsLocationsAgentEnvironmentsIntentsListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
39934	c.parent = parent
39935	return c
39936}
39937
39938// IntentView sets the optional parameter "intentView": The resource
39939// view to apply to the returned intent.
39940//
39941// Possible values:
39942//   "INTENT_VIEW_UNSPECIFIED" - Training phrases field is not populated
39943// in the response.
39944//   "INTENT_VIEW_FULL" - All fields are populated.
39945func (c *ProjectsLocationsAgentEnvironmentsIntentsListCall) IntentView(intentView string) *ProjectsLocationsAgentEnvironmentsIntentsListCall {
39946	c.urlParams_.Set("intentView", intentView)
39947	return c
39948}
39949
39950// LanguageCode sets the optional parameter "languageCode": The language
39951// used to access language-specific data. If not specified, the agent's
39952// default language is used. For more information, see Multilingual
39953// intent and entity data
39954// (https://cloud.google.com/dialogflow/docs/agents-multilingual#intent-entity).
39955func (c *ProjectsLocationsAgentEnvironmentsIntentsListCall) LanguageCode(languageCode string) *ProjectsLocationsAgentEnvironmentsIntentsListCall {
39956	c.urlParams_.Set("languageCode", languageCode)
39957	return c
39958}
39959
39960// PageSize sets the optional parameter "pageSize": The maximum number
39961// of items to return in a single page. By default 100 and at most 1000.
39962func (c *ProjectsLocationsAgentEnvironmentsIntentsListCall) PageSize(pageSize int64) *ProjectsLocationsAgentEnvironmentsIntentsListCall {
39963	c.urlParams_.Set("pageSize", fmt.Sprint(pageSize))
39964	return c
39965}
39966
39967// PageToken sets the optional parameter "pageToken": The
39968// next_page_token value returned from a previous list request.
39969func (c *ProjectsLocationsAgentEnvironmentsIntentsListCall) PageToken(pageToken string) *ProjectsLocationsAgentEnvironmentsIntentsListCall {
39970	c.urlParams_.Set("pageToken", pageToken)
39971	return c
39972}
39973
39974// Fields allows partial responses to be retrieved. See
39975// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
39976// for more information.
39977func (c *ProjectsLocationsAgentEnvironmentsIntentsListCall) Fields(s ...googleapi.Field) *ProjectsLocationsAgentEnvironmentsIntentsListCall {
39978	c.urlParams_.Set("fields", googleapi.CombineFields(s))
39979	return c
39980}
39981
39982// IfNoneMatch sets the optional parameter which makes the operation
39983// fail if the object's ETag matches the given value. This is useful for
39984// getting updates only after the object has changed since the last
39985// request. Use googleapi.IsNotModified to check whether the response
39986// error from Do is the result of In-None-Match.
39987func (c *ProjectsLocationsAgentEnvironmentsIntentsListCall) IfNoneMatch(entityTag string) *ProjectsLocationsAgentEnvironmentsIntentsListCall {
39988	c.ifNoneMatch_ = entityTag
39989	return c
39990}
39991
39992// Context sets the context to be used in this call's Do method. Any
39993// pending HTTP request will be aborted if the provided context is
39994// canceled.
39995func (c *ProjectsLocationsAgentEnvironmentsIntentsListCall) Context(ctx context.Context) *ProjectsLocationsAgentEnvironmentsIntentsListCall {
39996	c.ctx_ = ctx
39997	return c
39998}
39999
40000// Header returns an http.Header that can be modified by the caller to
40001// add HTTP headers to the request.
40002func (c *ProjectsLocationsAgentEnvironmentsIntentsListCall) Header() http.Header {
40003	if c.header_ == nil {
40004		c.header_ = make(http.Header)
40005	}
40006	return c.header_
40007}
40008
40009func (c *ProjectsLocationsAgentEnvironmentsIntentsListCall) doRequest(alt string) (*http.Response, error) {
40010	reqHeaders := make(http.Header)
40011	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20211027")
40012	for k, v := range c.header_ {
40013		reqHeaders[k] = v
40014	}
40015	reqHeaders.Set("User-Agent", c.s.userAgent())
40016	if c.ifNoneMatch_ != "" {
40017		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
40018	}
40019	var body io.Reader = nil
40020	c.urlParams_.Set("alt", alt)
40021	c.urlParams_.Set("prettyPrint", "false")
40022	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+parent}/intents")
40023	urls += "?" + c.urlParams_.Encode()
40024	req, err := http.NewRequest("GET", urls, body)
40025	if err != nil {
40026		return nil, err
40027	}
40028	req.Header = reqHeaders
40029	googleapi.Expand(req.URL, map[string]string{
40030		"parent": c.parent,
40031	})
40032	return gensupport.SendRequest(c.ctx_, c.s.client, req)
40033}
40034
40035// Do executes the "dialogflow.projects.locations.agent.environments.intents.list" call.
40036// Exactly one of *GoogleCloudDialogflowV2ListIntentsResponse or error
40037// will be non-nil. Any non-2xx status code is an error. Response
40038// headers are in either
40039// *GoogleCloudDialogflowV2ListIntentsResponse.ServerResponse.Header or
40040// (if a response was returned at all) in
40041// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
40042// whether the returned error was because http.StatusNotModified was
40043// returned.
40044func (c *ProjectsLocationsAgentEnvironmentsIntentsListCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDialogflowV2ListIntentsResponse, error) {
40045	gensupport.SetOptions(c.urlParams_, opts...)
40046	res, err := c.doRequest("json")
40047	if res != nil && res.StatusCode == http.StatusNotModified {
40048		if res.Body != nil {
40049			res.Body.Close()
40050		}
40051		return nil, &googleapi.Error{
40052			Code:   res.StatusCode,
40053			Header: res.Header,
40054		}
40055	}
40056	if err != nil {
40057		return nil, err
40058	}
40059	defer googleapi.CloseBody(res)
40060	if err := googleapi.CheckResponse(res); err != nil {
40061		return nil, err
40062	}
40063	ret := &GoogleCloudDialogflowV2ListIntentsResponse{
40064		ServerResponse: googleapi.ServerResponse{
40065			Header:         res.Header,
40066			HTTPStatusCode: res.StatusCode,
40067		},
40068	}
40069	target := &ret
40070	if err := gensupport.DecodeResponse(target, res); err != nil {
40071		return nil, err
40072	}
40073	return ret, nil
40074	// {
40075	//   "description": "Returns the list of all intents in the specified agent.",
40076	//   "flatPath": "v2/projects/{projectsId}/locations/{locationsId}/agent/environments/{environmentsId}/intents",
40077	//   "httpMethod": "GET",
40078	//   "id": "dialogflow.projects.locations.agent.environments.intents.list",
40079	//   "parameterOrder": [
40080	//     "parent"
40081	//   ],
40082	//   "parameters": {
40083	//     "intentView": {
40084	//       "description": "Optional. The resource view to apply to the returned intent.",
40085	//       "enum": [
40086	//         "INTENT_VIEW_UNSPECIFIED",
40087	//         "INTENT_VIEW_FULL"
40088	//       ],
40089	//       "enumDescriptions": [
40090	//         "Training phrases field is not populated in the response.",
40091	//         "All fields are populated."
40092	//       ],
40093	//       "location": "query",
40094	//       "type": "string"
40095	//     },
40096	//     "languageCode": {
40097	//       "description": "Optional. The language used to access language-specific data. If not specified, the agent's default language is used. For more information, see [Multilingual intent and entity data](https://cloud.google.com/dialogflow/docs/agents-multilingual#intent-entity).",
40098	//       "location": "query",
40099	//       "type": "string"
40100	//     },
40101	//     "pageSize": {
40102	//       "description": "Optional. The maximum number of items to return in a single page. By default 100 and at most 1000.",
40103	//       "format": "int32",
40104	//       "location": "query",
40105	//       "type": "integer"
40106	//     },
40107	//     "pageToken": {
40108	//       "description": "Optional. The next_page_token value returned from a previous list request.",
40109	//       "location": "query",
40110	//       "type": "string"
40111	//     },
40112	//     "parent": {
40113	//       "description": "Required. The agent to list all intents from. Format: `projects//agent` or `projects//locations//agent`. Alternatively, you can specify the environment to list intents for. Format: `projects//agent/environments/` or `projects//locations//agent/environments/`. Note: training phrases of the intents will not be returned for non-draft environment.",
40114	//       "location": "path",
40115	//       "pattern": "^projects/[^/]+/locations/[^/]+/agent/environments/[^/]+$",
40116	//       "required": true,
40117	//       "type": "string"
40118	//     }
40119	//   },
40120	//   "path": "v2/{+parent}/intents",
40121	//   "response": {
40122	//     "$ref": "GoogleCloudDialogflowV2ListIntentsResponse"
40123	//   },
40124	//   "scopes": [
40125	//     "https://www.googleapis.com/auth/cloud-platform",
40126	//     "https://www.googleapis.com/auth/dialogflow"
40127	//   ]
40128	// }
40129
40130}
40131
40132// Pages invokes f for each page of results.
40133// A non-nil error returned from f will halt the iteration.
40134// The provided context supersedes any context provided to the Context method.
40135func (c *ProjectsLocationsAgentEnvironmentsIntentsListCall) Pages(ctx context.Context, f func(*GoogleCloudDialogflowV2ListIntentsResponse) error) error {
40136	c.ctx_ = ctx
40137	defer c.PageToken(c.urlParams_.Get("pageToken")) // reset paging to original point
40138	for {
40139		x, err := c.Do()
40140		if err != nil {
40141			return err
40142		}
40143		if err := f(x); err != nil {
40144			return err
40145		}
40146		if x.NextPageToken == "" {
40147			return nil
40148		}
40149		c.PageToken(x.NextPageToken)
40150	}
40151}
40152
40153// method id "dialogflow.projects.locations.agent.environments.users.sessions.deleteContexts":
40154
40155type ProjectsLocationsAgentEnvironmentsUsersSessionsDeleteContextsCall struct {
40156	s          *Service
40157	parent     string
40158	urlParams_ gensupport.URLParams
40159	ctx_       context.Context
40160	header_    http.Header
40161}
40162
40163// DeleteContexts: Deletes all active contexts in the specified session.
40164//
40165// - parent: The name of the session to delete all contexts from.
40166//   Format: `projects//agent/sessions/` or
40167//   `projects//agent/environments//users//sessions/`. If `Environment
40168//   ID` is not specified we assume default 'draft' environment. If
40169//   `User ID` is not specified, we assume default '-' user.
40170func (r *ProjectsLocationsAgentEnvironmentsUsersSessionsService) DeleteContexts(parent string) *ProjectsLocationsAgentEnvironmentsUsersSessionsDeleteContextsCall {
40171	c := &ProjectsLocationsAgentEnvironmentsUsersSessionsDeleteContextsCall{s: r.s, urlParams_: make(gensupport.URLParams)}
40172	c.parent = parent
40173	return c
40174}
40175
40176// Fields allows partial responses to be retrieved. See
40177// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
40178// for more information.
40179func (c *ProjectsLocationsAgentEnvironmentsUsersSessionsDeleteContextsCall) Fields(s ...googleapi.Field) *ProjectsLocationsAgentEnvironmentsUsersSessionsDeleteContextsCall {
40180	c.urlParams_.Set("fields", googleapi.CombineFields(s))
40181	return c
40182}
40183
40184// Context sets the context to be used in this call's Do method. Any
40185// pending HTTP request will be aborted if the provided context is
40186// canceled.
40187func (c *ProjectsLocationsAgentEnvironmentsUsersSessionsDeleteContextsCall) Context(ctx context.Context) *ProjectsLocationsAgentEnvironmentsUsersSessionsDeleteContextsCall {
40188	c.ctx_ = ctx
40189	return c
40190}
40191
40192// Header returns an http.Header that can be modified by the caller to
40193// add HTTP headers to the request.
40194func (c *ProjectsLocationsAgentEnvironmentsUsersSessionsDeleteContextsCall) Header() http.Header {
40195	if c.header_ == nil {
40196		c.header_ = make(http.Header)
40197	}
40198	return c.header_
40199}
40200
40201func (c *ProjectsLocationsAgentEnvironmentsUsersSessionsDeleteContextsCall) doRequest(alt string) (*http.Response, error) {
40202	reqHeaders := make(http.Header)
40203	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20211027")
40204	for k, v := range c.header_ {
40205		reqHeaders[k] = v
40206	}
40207	reqHeaders.Set("User-Agent", c.s.userAgent())
40208	var body io.Reader = nil
40209	c.urlParams_.Set("alt", alt)
40210	c.urlParams_.Set("prettyPrint", "false")
40211	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+parent}/contexts")
40212	urls += "?" + c.urlParams_.Encode()
40213	req, err := http.NewRequest("DELETE", urls, body)
40214	if err != nil {
40215		return nil, err
40216	}
40217	req.Header = reqHeaders
40218	googleapi.Expand(req.URL, map[string]string{
40219		"parent": c.parent,
40220	})
40221	return gensupport.SendRequest(c.ctx_, c.s.client, req)
40222}
40223
40224// Do executes the "dialogflow.projects.locations.agent.environments.users.sessions.deleteContexts" call.
40225// Exactly one of *GoogleProtobufEmpty or error will be non-nil. Any
40226// non-2xx status code is an error. Response headers are in either
40227// *GoogleProtobufEmpty.ServerResponse.Header or (if a response was
40228// returned at all) in error.(*googleapi.Error).Header. Use
40229// googleapi.IsNotModified to check whether the returned error was
40230// because http.StatusNotModified was returned.
40231func (c *ProjectsLocationsAgentEnvironmentsUsersSessionsDeleteContextsCall) Do(opts ...googleapi.CallOption) (*GoogleProtobufEmpty, error) {
40232	gensupport.SetOptions(c.urlParams_, opts...)
40233	res, err := c.doRequest("json")
40234	if res != nil && res.StatusCode == http.StatusNotModified {
40235		if res.Body != nil {
40236			res.Body.Close()
40237		}
40238		return nil, &googleapi.Error{
40239			Code:   res.StatusCode,
40240			Header: res.Header,
40241		}
40242	}
40243	if err != nil {
40244		return nil, err
40245	}
40246	defer googleapi.CloseBody(res)
40247	if err := googleapi.CheckResponse(res); err != nil {
40248		return nil, err
40249	}
40250	ret := &GoogleProtobufEmpty{
40251		ServerResponse: googleapi.ServerResponse{
40252			Header:         res.Header,
40253			HTTPStatusCode: res.StatusCode,
40254		},
40255	}
40256	target := &ret
40257	if err := gensupport.DecodeResponse(target, res); err != nil {
40258		return nil, err
40259	}
40260	return ret, nil
40261	// {
40262	//   "description": "Deletes all active contexts in the specified session.",
40263	//   "flatPath": "v2/projects/{projectsId}/locations/{locationsId}/agent/environments/{environmentsId}/users/{usersId}/sessions/{sessionsId}/contexts",
40264	//   "httpMethod": "DELETE",
40265	//   "id": "dialogflow.projects.locations.agent.environments.users.sessions.deleteContexts",
40266	//   "parameterOrder": [
40267	//     "parent"
40268	//   ],
40269	//   "parameters": {
40270	//     "parent": {
40271	//       "description": "Required. The name of the session to delete all contexts from. Format: `projects//agent/sessions/` or `projects//agent/environments//users//sessions/`. If `Environment ID` is not specified we assume default 'draft' environment. If `User ID` is not specified, we assume default '-' user.",
40272	//       "location": "path",
40273	//       "pattern": "^projects/[^/]+/locations/[^/]+/agent/environments/[^/]+/users/[^/]+/sessions/[^/]+$",
40274	//       "required": true,
40275	//       "type": "string"
40276	//     }
40277	//   },
40278	//   "path": "v2/{+parent}/contexts",
40279	//   "response": {
40280	//     "$ref": "GoogleProtobufEmpty"
40281	//   },
40282	//   "scopes": [
40283	//     "https://www.googleapis.com/auth/cloud-platform",
40284	//     "https://www.googleapis.com/auth/dialogflow"
40285	//   ]
40286	// }
40287
40288}
40289
40290// method id "dialogflow.projects.locations.agent.environments.users.sessions.detectIntent":
40291
40292type ProjectsLocationsAgentEnvironmentsUsersSessionsDetectIntentCall struct {
40293	s                                          *Service
40294	sessionid                                  string
40295	googleclouddialogflowv2detectintentrequest *GoogleCloudDialogflowV2DetectIntentRequest
40296	urlParams_                                 gensupport.URLParams
40297	ctx_                                       context.Context
40298	header_                                    http.Header
40299}
40300
40301// DetectIntent: Processes a natural language query and returns
40302// structured, actionable data as a result. This method is not
40303// idempotent, because it may cause contexts and session entity types to
40304// be updated, which in turn might affect results of future queries. If
40305// you might use Agent Assist
40306// (https://cloud.google.com/dialogflow/docs/#aa) or other CCAI products
40307// now or in the future, consider using AnalyzeContent instead of
40308// `DetectIntent`. `AnalyzeContent` has additional functionality for
40309// Agent Assist and other CCAI products. Note: Always use agent versions
40310// for production traffic. See Versions and environments
40311// (https://cloud.google.com/dialogflow/es/docs/agents-versions).
40312//
40313// - session: The name of the session this query is sent to. Format:
40314//   `projects//agent/sessions/`, or
40315//   `projects//agent/environments//users//sessions/`. If `Environment
40316//   ID` is not specified, we assume default 'draft' environment
40317//   (`Environment ID` might be referred to as environment name at some
40318//   places). If `User ID` is not specified, we are using "-". It's up
40319//   to the API caller to choose an appropriate `Session ID` and `User
40320//   Id`. They can be a random number or some type of user and session
40321//   identifiers (preferably hashed). The length of the `Session ID` and
40322//   `User ID` must not exceed 36 characters. For more information, see
40323//   the API interactions guide
40324//   (https://cloud.google.com/dialogflow/docs/api-overview). Note:
40325//   Always use agent versions for production traffic. See Versions and
40326//   environments
40327//   (https://cloud.google.com/dialogflow/es/docs/agents-versions).
40328func (r *ProjectsLocationsAgentEnvironmentsUsersSessionsService) DetectIntent(sessionid string, googleclouddialogflowv2detectintentrequest *GoogleCloudDialogflowV2DetectIntentRequest) *ProjectsLocationsAgentEnvironmentsUsersSessionsDetectIntentCall {
40329	c := &ProjectsLocationsAgentEnvironmentsUsersSessionsDetectIntentCall{s: r.s, urlParams_: make(gensupport.URLParams)}
40330	c.sessionid = sessionid
40331	c.googleclouddialogflowv2detectintentrequest = googleclouddialogflowv2detectintentrequest
40332	return c
40333}
40334
40335// Fields allows partial responses to be retrieved. See
40336// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
40337// for more information.
40338func (c *ProjectsLocationsAgentEnvironmentsUsersSessionsDetectIntentCall) Fields(s ...googleapi.Field) *ProjectsLocationsAgentEnvironmentsUsersSessionsDetectIntentCall {
40339	c.urlParams_.Set("fields", googleapi.CombineFields(s))
40340	return c
40341}
40342
40343// Context sets the context to be used in this call's Do method. Any
40344// pending HTTP request will be aborted if the provided context is
40345// canceled.
40346func (c *ProjectsLocationsAgentEnvironmentsUsersSessionsDetectIntentCall) Context(ctx context.Context) *ProjectsLocationsAgentEnvironmentsUsersSessionsDetectIntentCall {
40347	c.ctx_ = ctx
40348	return c
40349}
40350
40351// Header returns an http.Header that can be modified by the caller to
40352// add HTTP headers to the request.
40353func (c *ProjectsLocationsAgentEnvironmentsUsersSessionsDetectIntentCall) Header() http.Header {
40354	if c.header_ == nil {
40355		c.header_ = make(http.Header)
40356	}
40357	return c.header_
40358}
40359
40360func (c *ProjectsLocationsAgentEnvironmentsUsersSessionsDetectIntentCall) doRequest(alt string) (*http.Response, error) {
40361	reqHeaders := make(http.Header)
40362	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20211027")
40363	for k, v := range c.header_ {
40364		reqHeaders[k] = v
40365	}
40366	reqHeaders.Set("User-Agent", c.s.userAgent())
40367	var body io.Reader = nil
40368	body, err := googleapi.WithoutDataWrapper.JSONReader(c.googleclouddialogflowv2detectintentrequest)
40369	if err != nil {
40370		return nil, err
40371	}
40372	reqHeaders.Set("Content-Type", "application/json")
40373	c.urlParams_.Set("alt", alt)
40374	c.urlParams_.Set("prettyPrint", "false")
40375	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+session}:detectIntent")
40376	urls += "?" + c.urlParams_.Encode()
40377	req, err := http.NewRequest("POST", urls, body)
40378	if err != nil {
40379		return nil, err
40380	}
40381	req.Header = reqHeaders
40382	googleapi.Expand(req.URL, map[string]string{
40383		"session": c.sessionid,
40384	})
40385	return gensupport.SendRequest(c.ctx_, c.s.client, req)
40386}
40387
40388// Do executes the "dialogflow.projects.locations.agent.environments.users.sessions.detectIntent" call.
40389// Exactly one of *GoogleCloudDialogflowV2DetectIntentResponse or error
40390// will be non-nil. Any non-2xx status code is an error. Response
40391// headers are in either
40392// *GoogleCloudDialogflowV2DetectIntentResponse.ServerResponse.Header or
40393// (if a response was returned at all) in
40394// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
40395// whether the returned error was because http.StatusNotModified was
40396// returned.
40397func (c *ProjectsLocationsAgentEnvironmentsUsersSessionsDetectIntentCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDialogflowV2DetectIntentResponse, error) {
40398	gensupport.SetOptions(c.urlParams_, opts...)
40399	res, err := c.doRequest("json")
40400	if res != nil && res.StatusCode == http.StatusNotModified {
40401		if res.Body != nil {
40402			res.Body.Close()
40403		}
40404		return nil, &googleapi.Error{
40405			Code:   res.StatusCode,
40406			Header: res.Header,
40407		}
40408	}
40409	if err != nil {
40410		return nil, err
40411	}
40412	defer googleapi.CloseBody(res)
40413	if err := googleapi.CheckResponse(res); err != nil {
40414		return nil, err
40415	}
40416	ret := &GoogleCloudDialogflowV2DetectIntentResponse{
40417		ServerResponse: googleapi.ServerResponse{
40418			Header:         res.Header,
40419			HTTPStatusCode: res.StatusCode,
40420		},
40421	}
40422	target := &ret
40423	if err := gensupport.DecodeResponse(target, res); err != nil {
40424		return nil, err
40425	}
40426	return ret, nil
40427	// {
40428	//   "description": "Processes a natural language query and returns structured, actionable data as a result. This method is not idempotent, because it may cause contexts and session entity types to be updated, which in turn might affect results of future queries. If you might use [Agent Assist](https://cloud.google.com/dialogflow/docs/#aa) or other CCAI products now or in the future, consider using AnalyzeContent instead of `DetectIntent`. `AnalyzeContent` has additional functionality for Agent Assist and other CCAI products. Note: Always use agent versions for production traffic. See [Versions and environments](https://cloud.google.com/dialogflow/es/docs/agents-versions).",
40429	//   "flatPath": "v2/projects/{projectsId}/locations/{locationsId}/agent/environments/{environmentsId}/users/{usersId}/sessions/{sessionsId}:detectIntent",
40430	//   "httpMethod": "POST",
40431	//   "id": "dialogflow.projects.locations.agent.environments.users.sessions.detectIntent",
40432	//   "parameterOrder": [
40433	//     "session"
40434	//   ],
40435	//   "parameters": {
40436	//     "session": {
40437	//       "description": "Required. The name of the session this query is sent to. Format: `projects//agent/sessions/`, or `projects//agent/environments//users//sessions/`. If `Environment ID` is not specified, we assume default 'draft' environment (`Environment ID` might be referred to as environment name at some places). If `User ID` is not specified, we are using \"-\". It's up to the API caller to choose an appropriate `Session ID` and `User Id`. They can be a random number or some type of user and session identifiers (preferably hashed). The length of the `Session ID` and `User ID` must not exceed 36 characters. For more information, see the [API interactions guide](https://cloud.google.com/dialogflow/docs/api-overview). Note: Always use agent versions for production traffic. See [Versions and environments](https://cloud.google.com/dialogflow/es/docs/agents-versions).",
40438	//       "location": "path",
40439	//       "pattern": "^projects/[^/]+/locations/[^/]+/agent/environments/[^/]+/users/[^/]+/sessions/[^/]+$",
40440	//       "required": true,
40441	//       "type": "string"
40442	//     }
40443	//   },
40444	//   "path": "v2/{+session}:detectIntent",
40445	//   "request": {
40446	//     "$ref": "GoogleCloudDialogflowV2DetectIntentRequest"
40447	//   },
40448	//   "response": {
40449	//     "$ref": "GoogleCloudDialogflowV2DetectIntentResponse"
40450	//   },
40451	//   "scopes": [
40452	//     "https://www.googleapis.com/auth/cloud-platform",
40453	//     "https://www.googleapis.com/auth/dialogflow"
40454	//   ]
40455	// }
40456
40457}
40458
40459// method id "dialogflow.projects.locations.agent.environments.users.sessions.contexts.create":
40460
40461type ProjectsLocationsAgentEnvironmentsUsersSessionsContextsCreateCall struct {
40462	s                              *Service
40463	parent                         string
40464	googleclouddialogflowv2context *GoogleCloudDialogflowV2Context
40465	urlParams_                     gensupport.URLParams
40466	ctx_                           context.Context
40467	header_                        http.Header
40468}
40469
40470// Create: Creates a context. If the specified context already exists,
40471// overrides the context.
40472//
40473// - parent: The session to create a context for. Format:
40474//   `projects//agent/sessions/` or
40475//   `projects//agent/environments//users//sessions/`. If `Environment
40476//   ID` is not specified, we assume default 'draft' environment. If
40477//   `User ID` is not specified, we assume default '-' user.
40478func (r *ProjectsLocationsAgentEnvironmentsUsersSessionsContextsService) Create(parent string, googleclouddialogflowv2context *GoogleCloudDialogflowV2Context) *ProjectsLocationsAgentEnvironmentsUsersSessionsContextsCreateCall {
40479	c := &ProjectsLocationsAgentEnvironmentsUsersSessionsContextsCreateCall{s: r.s, urlParams_: make(gensupport.URLParams)}
40480	c.parent = parent
40481	c.googleclouddialogflowv2context = googleclouddialogflowv2context
40482	return c
40483}
40484
40485// Fields allows partial responses to be retrieved. See
40486// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
40487// for more information.
40488func (c *ProjectsLocationsAgentEnvironmentsUsersSessionsContextsCreateCall) Fields(s ...googleapi.Field) *ProjectsLocationsAgentEnvironmentsUsersSessionsContextsCreateCall {
40489	c.urlParams_.Set("fields", googleapi.CombineFields(s))
40490	return c
40491}
40492
40493// Context sets the context to be used in this call's Do method. Any
40494// pending HTTP request will be aborted if the provided context is
40495// canceled.
40496func (c *ProjectsLocationsAgentEnvironmentsUsersSessionsContextsCreateCall) Context(ctx context.Context) *ProjectsLocationsAgentEnvironmentsUsersSessionsContextsCreateCall {
40497	c.ctx_ = ctx
40498	return c
40499}
40500
40501// Header returns an http.Header that can be modified by the caller to
40502// add HTTP headers to the request.
40503func (c *ProjectsLocationsAgentEnvironmentsUsersSessionsContextsCreateCall) Header() http.Header {
40504	if c.header_ == nil {
40505		c.header_ = make(http.Header)
40506	}
40507	return c.header_
40508}
40509
40510func (c *ProjectsLocationsAgentEnvironmentsUsersSessionsContextsCreateCall) doRequest(alt string) (*http.Response, error) {
40511	reqHeaders := make(http.Header)
40512	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20211027")
40513	for k, v := range c.header_ {
40514		reqHeaders[k] = v
40515	}
40516	reqHeaders.Set("User-Agent", c.s.userAgent())
40517	var body io.Reader = nil
40518	body, err := googleapi.WithoutDataWrapper.JSONReader(c.googleclouddialogflowv2context)
40519	if err != nil {
40520		return nil, err
40521	}
40522	reqHeaders.Set("Content-Type", "application/json")
40523	c.urlParams_.Set("alt", alt)
40524	c.urlParams_.Set("prettyPrint", "false")
40525	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+parent}/contexts")
40526	urls += "?" + c.urlParams_.Encode()
40527	req, err := http.NewRequest("POST", urls, body)
40528	if err != nil {
40529		return nil, err
40530	}
40531	req.Header = reqHeaders
40532	googleapi.Expand(req.URL, map[string]string{
40533		"parent": c.parent,
40534	})
40535	return gensupport.SendRequest(c.ctx_, c.s.client, req)
40536}
40537
40538// Do executes the "dialogflow.projects.locations.agent.environments.users.sessions.contexts.create" call.
40539// Exactly one of *GoogleCloudDialogflowV2Context or error will be
40540// non-nil. Any non-2xx status code is an error. Response headers are in
40541// either *GoogleCloudDialogflowV2Context.ServerResponse.Header or (if a
40542// response was returned at all) in error.(*googleapi.Error).Header. Use
40543// googleapi.IsNotModified to check whether the returned error was
40544// because http.StatusNotModified was returned.
40545func (c *ProjectsLocationsAgentEnvironmentsUsersSessionsContextsCreateCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDialogflowV2Context, error) {
40546	gensupport.SetOptions(c.urlParams_, opts...)
40547	res, err := c.doRequest("json")
40548	if res != nil && res.StatusCode == http.StatusNotModified {
40549		if res.Body != nil {
40550			res.Body.Close()
40551		}
40552		return nil, &googleapi.Error{
40553			Code:   res.StatusCode,
40554			Header: res.Header,
40555		}
40556	}
40557	if err != nil {
40558		return nil, err
40559	}
40560	defer googleapi.CloseBody(res)
40561	if err := googleapi.CheckResponse(res); err != nil {
40562		return nil, err
40563	}
40564	ret := &GoogleCloudDialogflowV2Context{
40565		ServerResponse: googleapi.ServerResponse{
40566			Header:         res.Header,
40567			HTTPStatusCode: res.StatusCode,
40568		},
40569	}
40570	target := &ret
40571	if err := gensupport.DecodeResponse(target, res); err != nil {
40572		return nil, err
40573	}
40574	return ret, nil
40575	// {
40576	//   "description": "Creates a context. If the specified context already exists, overrides the context.",
40577	//   "flatPath": "v2/projects/{projectsId}/locations/{locationsId}/agent/environments/{environmentsId}/users/{usersId}/sessions/{sessionsId}/contexts",
40578	//   "httpMethod": "POST",
40579	//   "id": "dialogflow.projects.locations.agent.environments.users.sessions.contexts.create",
40580	//   "parameterOrder": [
40581	//     "parent"
40582	//   ],
40583	//   "parameters": {
40584	//     "parent": {
40585	//       "description": "Required. The session to create a context for. Format: `projects//agent/sessions/` or `projects//agent/environments//users//sessions/`. If `Environment ID` is not specified, we assume default 'draft' environment. If `User ID` is not specified, we assume default '-' user.",
40586	//       "location": "path",
40587	//       "pattern": "^projects/[^/]+/locations/[^/]+/agent/environments/[^/]+/users/[^/]+/sessions/[^/]+$",
40588	//       "required": true,
40589	//       "type": "string"
40590	//     }
40591	//   },
40592	//   "path": "v2/{+parent}/contexts",
40593	//   "request": {
40594	//     "$ref": "GoogleCloudDialogflowV2Context"
40595	//   },
40596	//   "response": {
40597	//     "$ref": "GoogleCloudDialogflowV2Context"
40598	//   },
40599	//   "scopes": [
40600	//     "https://www.googleapis.com/auth/cloud-platform",
40601	//     "https://www.googleapis.com/auth/dialogflow"
40602	//   ]
40603	// }
40604
40605}
40606
40607// method id "dialogflow.projects.locations.agent.environments.users.sessions.contexts.delete":
40608
40609type ProjectsLocationsAgentEnvironmentsUsersSessionsContextsDeleteCall struct {
40610	s          *Service
40611	name       string
40612	urlParams_ gensupport.URLParams
40613	ctx_       context.Context
40614	header_    http.Header
40615}
40616
40617// Delete: Deletes the specified context.
40618//
40619// - name: The name of the context to delete. Format:
40620//   `projects//agent/sessions//contexts/` or
40621//   `projects//agent/environments//users//sessions//contexts/`. If
40622//   `Environment ID` is not specified, we assume default 'draft'
40623//   environment. If `User ID` is not specified, we assume default '-'
40624//   user.
40625func (r *ProjectsLocationsAgentEnvironmentsUsersSessionsContextsService) Delete(name string) *ProjectsLocationsAgentEnvironmentsUsersSessionsContextsDeleteCall {
40626	c := &ProjectsLocationsAgentEnvironmentsUsersSessionsContextsDeleteCall{s: r.s, urlParams_: make(gensupport.URLParams)}
40627	c.name = name
40628	return c
40629}
40630
40631// Fields allows partial responses to be retrieved. See
40632// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
40633// for more information.
40634func (c *ProjectsLocationsAgentEnvironmentsUsersSessionsContextsDeleteCall) Fields(s ...googleapi.Field) *ProjectsLocationsAgentEnvironmentsUsersSessionsContextsDeleteCall {
40635	c.urlParams_.Set("fields", googleapi.CombineFields(s))
40636	return c
40637}
40638
40639// Context sets the context to be used in this call's Do method. Any
40640// pending HTTP request will be aborted if the provided context is
40641// canceled.
40642func (c *ProjectsLocationsAgentEnvironmentsUsersSessionsContextsDeleteCall) Context(ctx context.Context) *ProjectsLocationsAgentEnvironmentsUsersSessionsContextsDeleteCall {
40643	c.ctx_ = ctx
40644	return c
40645}
40646
40647// Header returns an http.Header that can be modified by the caller to
40648// add HTTP headers to the request.
40649func (c *ProjectsLocationsAgentEnvironmentsUsersSessionsContextsDeleteCall) Header() http.Header {
40650	if c.header_ == nil {
40651		c.header_ = make(http.Header)
40652	}
40653	return c.header_
40654}
40655
40656func (c *ProjectsLocationsAgentEnvironmentsUsersSessionsContextsDeleteCall) doRequest(alt string) (*http.Response, error) {
40657	reqHeaders := make(http.Header)
40658	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20211027")
40659	for k, v := range c.header_ {
40660		reqHeaders[k] = v
40661	}
40662	reqHeaders.Set("User-Agent", c.s.userAgent())
40663	var body io.Reader = nil
40664	c.urlParams_.Set("alt", alt)
40665	c.urlParams_.Set("prettyPrint", "false")
40666	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+name}")
40667	urls += "?" + c.urlParams_.Encode()
40668	req, err := http.NewRequest("DELETE", urls, body)
40669	if err != nil {
40670		return nil, err
40671	}
40672	req.Header = reqHeaders
40673	googleapi.Expand(req.URL, map[string]string{
40674		"name": c.name,
40675	})
40676	return gensupport.SendRequest(c.ctx_, c.s.client, req)
40677}
40678
40679// Do executes the "dialogflow.projects.locations.agent.environments.users.sessions.contexts.delete" call.
40680// Exactly one of *GoogleProtobufEmpty or error will be non-nil. Any
40681// non-2xx status code is an error. Response headers are in either
40682// *GoogleProtobufEmpty.ServerResponse.Header or (if a response was
40683// returned at all) in error.(*googleapi.Error).Header. Use
40684// googleapi.IsNotModified to check whether the returned error was
40685// because http.StatusNotModified was returned.
40686func (c *ProjectsLocationsAgentEnvironmentsUsersSessionsContextsDeleteCall) Do(opts ...googleapi.CallOption) (*GoogleProtobufEmpty, error) {
40687	gensupport.SetOptions(c.urlParams_, opts...)
40688	res, err := c.doRequest("json")
40689	if res != nil && res.StatusCode == http.StatusNotModified {
40690		if res.Body != nil {
40691			res.Body.Close()
40692		}
40693		return nil, &googleapi.Error{
40694			Code:   res.StatusCode,
40695			Header: res.Header,
40696		}
40697	}
40698	if err != nil {
40699		return nil, err
40700	}
40701	defer googleapi.CloseBody(res)
40702	if err := googleapi.CheckResponse(res); err != nil {
40703		return nil, err
40704	}
40705	ret := &GoogleProtobufEmpty{
40706		ServerResponse: googleapi.ServerResponse{
40707			Header:         res.Header,
40708			HTTPStatusCode: res.StatusCode,
40709		},
40710	}
40711	target := &ret
40712	if err := gensupport.DecodeResponse(target, res); err != nil {
40713		return nil, err
40714	}
40715	return ret, nil
40716	// {
40717	//   "description": "Deletes the specified context.",
40718	//   "flatPath": "v2/projects/{projectsId}/locations/{locationsId}/agent/environments/{environmentsId}/users/{usersId}/sessions/{sessionsId}/contexts/{contextsId}",
40719	//   "httpMethod": "DELETE",
40720	//   "id": "dialogflow.projects.locations.agent.environments.users.sessions.contexts.delete",
40721	//   "parameterOrder": [
40722	//     "name"
40723	//   ],
40724	//   "parameters": {
40725	//     "name": {
40726	//       "description": "Required. The name of the context to delete. Format: `projects//agent/sessions//contexts/` or `projects//agent/environments//users//sessions//contexts/`. If `Environment ID` is not specified, we assume default 'draft' environment. If `User ID` is not specified, we assume default '-' user.",
40727	//       "location": "path",
40728	//       "pattern": "^projects/[^/]+/locations/[^/]+/agent/environments/[^/]+/users/[^/]+/sessions/[^/]+/contexts/[^/]+$",
40729	//       "required": true,
40730	//       "type": "string"
40731	//     }
40732	//   },
40733	//   "path": "v2/{+name}",
40734	//   "response": {
40735	//     "$ref": "GoogleProtobufEmpty"
40736	//   },
40737	//   "scopes": [
40738	//     "https://www.googleapis.com/auth/cloud-platform",
40739	//     "https://www.googleapis.com/auth/dialogflow"
40740	//   ]
40741	// }
40742
40743}
40744
40745// method id "dialogflow.projects.locations.agent.environments.users.sessions.contexts.get":
40746
40747type ProjectsLocationsAgentEnvironmentsUsersSessionsContextsGetCall struct {
40748	s            *Service
40749	name         string
40750	urlParams_   gensupport.URLParams
40751	ifNoneMatch_ string
40752	ctx_         context.Context
40753	header_      http.Header
40754}
40755
40756// Get: Retrieves the specified context.
40757//
40758// - name: The name of the context. Format:
40759//   `projects//agent/sessions//contexts/` or
40760//   `projects//agent/environments//users//sessions//contexts/`. If
40761//   `Environment ID` is not specified, we assume default 'draft'
40762//   environment. If `User ID` is not specified, we assume default '-'
40763//   user.
40764func (r *ProjectsLocationsAgentEnvironmentsUsersSessionsContextsService) Get(name string) *ProjectsLocationsAgentEnvironmentsUsersSessionsContextsGetCall {
40765	c := &ProjectsLocationsAgentEnvironmentsUsersSessionsContextsGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
40766	c.name = name
40767	return c
40768}
40769
40770// Fields allows partial responses to be retrieved. See
40771// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
40772// for more information.
40773func (c *ProjectsLocationsAgentEnvironmentsUsersSessionsContextsGetCall) Fields(s ...googleapi.Field) *ProjectsLocationsAgentEnvironmentsUsersSessionsContextsGetCall {
40774	c.urlParams_.Set("fields", googleapi.CombineFields(s))
40775	return c
40776}
40777
40778// IfNoneMatch sets the optional parameter which makes the operation
40779// fail if the object's ETag matches the given value. This is useful for
40780// getting updates only after the object has changed since the last
40781// request. Use googleapi.IsNotModified to check whether the response
40782// error from Do is the result of In-None-Match.
40783func (c *ProjectsLocationsAgentEnvironmentsUsersSessionsContextsGetCall) IfNoneMatch(entityTag string) *ProjectsLocationsAgentEnvironmentsUsersSessionsContextsGetCall {
40784	c.ifNoneMatch_ = entityTag
40785	return c
40786}
40787
40788// Context sets the context to be used in this call's Do method. Any
40789// pending HTTP request will be aborted if the provided context is
40790// canceled.
40791func (c *ProjectsLocationsAgentEnvironmentsUsersSessionsContextsGetCall) Context(ctx context.Context) *ProjectsLocationsAgentEnvironmentsUsersSessionsContextsGetCall {
40792	c.ctx_ = ctx
40793	return c
40794}
40795
40796// Header returns an http.Header that can be modified by the caller to
40797// add HTTP headers to the request.
40798func (c *ProjectsLocationsAgentEnvironmentsUsersSessionsContextsGetCall) Header() http.Header {
40799	if c.header_ == nil {
40800		c.header_ = make(http.Header)
40801	}
40802	return c.header_
40803}
40804
40805func (c *ProjectsLocationsAgentEnvironmentsUsersSessionsContextsGetCall) doRequest(alt string) (*http.Response, error) {
40806	reqHeaders := make(http.Header)
40807	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20211027")
40808	for k, v := range c.header_ {
40809		reqHeaders[k] = v
40810	}
40811	reqHeaders.Set("User-Agent", c.s.userAgent())
40812	if c.ifNoneMatch_ != "" {
40813		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
40814	}
40815	var body io.Reader = nil
40816	c.urlParams_.Set("alt", alt)
40817	c.urlParams_.Set("prettyPrint", "false")
40818	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+name}")
40819	urls += "?" + c.urlParams_.Encode()
40820	req, err := http.NewRequest("GET", urls, body)
40821	if err != nil {
40822		return nil, err
40823	}
40824	req.Header = reqHeaders
40825	googleapi.Expand(req.URL, map[string]string{
40826		"name": c.name,
40827	})
40828	return gensupport.SendRequest(c.ctx_, c.s.client, req)
40829}
40830
40831// Do executes the "dialogflow.projects.locations.agent.environments.users.sessions.contexts.get" call.
40832// Exactly one of *GoogleCloudDialogflowV2Context or error will be
40833// non-nil. Any non-2xx status code is an error. Response headers are in
40834// either *GoogleCloudDialogflowV2Context.ServerResponse.Header or (if a
40835// response was returned at all) in error.(*googleapi.Error).Header. Use
40836// googleapi.IsNotModified to check whether the returned error was
40837// because http.StatusNotModified was returned.
40838func (c *ProjectsLocationsAgentEnvironmentsUsersSessionsContextsGetCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDialogflowV2Context, error) {
40839	gensupport.SetOptions(c.urlParams_, opts...)
40840	res, err := c.doRequest("json")
40841	if res != nil && res.StatusCode == http.StatusNotModified {
40842		if res.Body != nil {
40843			res.Body.Close()
40844		}
40845		return nil, &googleapi.Error{
40846			Code:   res.StatusCode,
40847			Header: res.Header,
40848		}
40849	}
40850	if err != nil {
40851		return nil, err
40852	}
40853	defer googleapi.CloseBody(res)
40854	if err := googleapi.CheckResponse(res); err != nil {
40855		return nil, err
40856	}
40857	ret := &GoogleCloudDialogflowV2Context{
40858		ServerResponse: googleapi.ServerResponse{
40859			Header:         res.Header,
40860			HTTPStatusCode: res.StatusCode,
40861		},
40862	}
40863	target := &ret
40864	if err := gensupport.DecodeResponse(target, res); err != nil {
40865		return nil, err
40866	}
40867	return ret, nil
40868	// {
40869	//   "description": "Retrieves the specified context.",
40870	//   "flatPath": "v2/projects/{projectsId}/locations/{locationsId}/agent/environments/{environmentsId}/users/{usersId}/sessions/{sessionsId}/contexts/{contextsId}",
40871	//   "httpMethod": "GET",
40872	//   "id": "dialogflow.projects.locations.agent.environments.users.sessions.contexts.get",
40873	//   "parameterOrder": [
40874	//     "name"
40875	//   ],
40876	//   "parameters": {
40877	//     "name": {
40878	//       "description": "Required. The name of the context. Format: `projects//agent/sessions//contexts/` or `projects//agent/environments//users//sessions//contexts/`. If `Environment ID` is not specified, we assume default 'draft' environment. If `User ID` is not specified, we assume default '-' user.",
40879	//       "location": "path",
40880	//       "pattern": "^projects/[^/]+/locations/[^/]+/agent/environments/[^/]+/users/[^/]+/sessions/[^/]+/contexts/[^/]+$",
40881	//       "required": true,
40882	//       "type": "string"
40883	//     }
40884	//   },
40885	//   "path": "v2/{+name}",
40886	//   "response": {
40887	//     "$ref": "GoogleCloudDialogflowV2Context"
40888	//   },
40889	//   "scopes": [
40890	//     "https://www.googleapis.com/auth/cloud-platform",
40891	//     "https://www.googleapis.com/auth/dialogflow"
40892	//   ]
40893	// }
40894
40895}
40896
40897// method id "dialogflow.projects.locations.agent.environments.users.sessions.contexts.list":
40898
40899type ProjectsLocationsAgentEnvironmentsUsersSessionsContextsListCall struct {
40900	s            *Service
40901	parent       string
40902	urlParams_   gensupport.URLParams
40903	ifNoneMatch_ string
40904	ctx_         context.Context
40905	header_      http.Header
40906}
40907
40908// List: Returns the list of all contexts in the specified session.
40909//
40910// - parent: The session to list all contexts from. Format:
40911//   `projects//agent/sessions/` or
40912//   `projects//agent/environments//users//sessions/`. If `Environment
40913//   ID` is not specified, we assume default 'draft' environment. If
40914//   `User ID` is not specified, we assume default '-' user.
40915func (r *ProjectsLocationsAgentEnvironmentsUsersSessionsContextsService) List(parent string) *ProjectsLocationsAgentEnvironmentsUsersSessionsContextsListCall {
40916	c := &ProjectsLocationsAgentEnvironmentsUsersSessionsContextsListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
40917	c.parent = parent
40918	return c
40919}
40920
40921// PageSize sets the optional parameter "pageSize": The maximum number
40922// of items to return in a single page. By default 100 and at most 1000.
40923func (c *ProjectsLocationsAgentEnvironmentsUsersSessionsContextsListCall) PageSize(pageSize int64) *ProjectsLocationsAgentEnvironmentsUsersSessionsContextsListCall {
40924	c.urlParams_.Set("pageSize", fmt.Sprint(pageSize))
40925	return c
40926}
40927
40928// PageToken sets the optional parameter "pageToken": The
40929// next_page_token value returned from a previous list request.
40930func (c *ProjectsLocationsAgentEnvironmentsUsersSessionsContextsListCall) PageToken(pageToken string) *ProjectsLocationsAgentEnvironmentsUsersSessionsContextsListCall {
40931	c.urlParams_.Set("pageToken", pageToken)
40932	return c
40933}
40934
40935// Fields allows partial responses to be retrieved. See
40936// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
40937// for more information.
40938func (c *ProjectsLocationsAgentEnvironmentsUsersSessionsContextsListCall) Fields(s ...googleapi.Field) *ProjectsLocationsAgentEnvironmentsUsersSessionsContextsListCall {
40939	c.urlParams_.Set("fields", googleapi.CombineFields(s))
40940	return c
40941}
40942
40943// IfNoneMatch sets the optional parameter which makes the operation
40944// fail if the object's ETag matches the given value. This is useful for
40945// getting updates only after the object has changed since the last
40946// request. Use googleapi.IsNotModified to check whether the response
40947// error from Do is the result of In-None-Match.
40948func (c *ProjectsLocationsAgentEnvironmentsUsersSessionsContextsListCall) IfNoneMatch(entityTag string) *ProjectsLocationsAgentEnvironmentsUsersSessionsContextsListCall {
40949	c.ifNoneMatch_ = entityTag
40950	return c
40951}
40952
40953// Context sets the context to be used in this call's Do method. Any
40954// pending HTTP request will be aborted if the provided context is
40955// canceled.
40956func (c *ProjectsLocationsAgentEnvironmentsUsersSessionsContextsListCall) Context(ctx context.Context) *ProjectsLocationsAgentEnvironmentsUsersSessionsContextsListCall {
40957	c.ctx_ = ctx
40958	return c
40959}
40960
40961// Header returns an http.Header that can be modified by the caller to
40962// add HTTP headers to the request.
40963func (c *ProjectsLocationsAgentEnvironmentsUsersSessionsContextsListCall) Header() http.Header {
40964	if c.header_ == nil {
40965		c.header_ = make(http.Header)
40966	}
40967	return c.header_
40968}
40969
40970func (c *ProjectsLocationsAgentEnvironmentsUsersSessionsContextsListCall) doRequest(alt string) (*http.Response, error) {
40971	reqHeaders := make(http.Header)
40972	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20211027")
40973	for k, v := range c.header_ {
40974		reqHeaders[k] = v
40975	}
40976	reqHeaders.Set("User-Agent", c.s.userAgent())
40977	if c.ifNoneMatch_ != "" {
40978		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
40979	}
40980	var body io.Reader = nil
40981	c.urlParams_.Set("alt", alt)
40982	c.urlParams_.Set("prettyPrint", "false")
40983	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+parent}/contexts")
40984	urls += "?" + c.urlParams_.Encode()
40985	req, err := http.NewRequest("GET", urls, body)
40986	if err != nil {
40987		return nil, err
40988	}
40989	req.Header = reqHeaders
40990	googleapi.Expand(req.URL, map[string]string{
40991		"parent": c.parent,
40992	})
40993	return gensupport.SendRequest(c.ctx_, c.s.client, req)
40994}
40995
40996// Do executes the "dialogflow.projects.locations.agent.environments.users.sessions.contexts.list" call.
40997// Exactly one of *GoogleCloudDialogflowV2ListContextsResponse or error
40998// will be non-nil. Any non-2xx status code is an error. Response
40999// headers are in either
41000// *GoogleCloudDialogflowV2ListContextsResponse.ServerResponse.Header or
41001// (if a response was returned at all) in
41002// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
41003// whether the returned error was because http.StatusNotModified was
41004// returned.
41005func (c *ProjectsLocationsAgentEnvironmentsUsersSessionsContextsListCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDialogflowV2ListContextsResponse, error) {
41006	gensupport.SetOptions(c.urlParams_, opts...)
41007	res, err := c.doRequest("json")
41008	if res != nil && res.StatusCode == http.StatusNotModified {
41009		if res.Body != nil {
41010			res.Body.Close()
41011		}
41012		return nil, &googleapi.Error{
41013			Code:   res.StatusCode,
41014			Header: res.Header,
41015		}
41016	}
41017	if err != nil {
41018		return nil, err
41019	}
41020	defer googleapi.CloseBody(res)
41021	if err := googleapi.CheckResponse(res); err != nil {
41022		return nil, err
41023	}
41024	ret := &GoogleCloudDialogflowV2ListContextsResponse{
41025		ServerResponse: googleapi.ServerResponse{
41026			Header:         res.Header,
41027			HTTPStatusCode: res.StatusCode,
41028		},
41029	}
41030	target := &ret
41031	if err := gensupport.DecodeResponse(target, res); err != nil {
41032		return nil, err
41033	}
41034	return ret, nil
41035	// {
41036	//   "description": "Returns the list of all contexts in the specified session.",
41037	//   "flatPath": "v2/projects/{projectsId}/locations/{locationsId}/agent/environments/{environmentsId}/users/{usersId}/sessions/{sessionsId}/contexts",
41038	//   "httpMethod": "GET",
41039	//   "id": "dialogflow.projects.locations.agent.environments.users.sessions.contexts.list",
41040	//   "parameterOrder": [
41041	//     "parent"
41042	//   ],
41043	//   "parameters": {
41044	//     "pageSize": {
41045	//       "description": "Optional. The maximum number of items to return in a single page. By default 100 and at most 1000.",
41046	//       "format": "int32",
41047	//       "location": "query",
41048	//       "type": "integer"
41049	//     },
41050	//     "pageToken": {
41051	//       "description": "Optional. The next_page_token value returned from a previous list request.",
41052	//       "location": "query",
41053	//       "type": "string"
41054	//     },
41055	//     "parent": {
41056	//       "description": "Required. The session to list all contexts from. Format: `projects//agent/sessions/` or `projects//agent/environments//users//sessions/`. If `Environment ID` is not specified, we assume default 'draft' environment. If `User ID` is not specified, we assume default '-' user.",
41057	//       "location": "path",
41058	//       "pattern": "^projects/[^/]+/locations/[^/]+/agent/environments/[^/]+/users/[^/]+/sessions/[^/]+$",
41059	//       "required": true,
41060	//       "type": "string"
41061	//     }
41062	//   },
41063	//   "path": "v2/{+parent}/contexts",
41064	//   "response": {
41065	//     "$ref": "GoogleCloudDialogflowV2ListContextsResponse"
41066	//   },
41067	//   "scopes": [
41068	//     "https://www.googleapis.com/auth/cloud-platform",
41069	//     "https://www.googleapis.com/auth/dialogflow"
41070	//   ]
41071	// }
41072
41073}
41074
41075// Pages invokes f for each page of results.
41076// A non-nil error returned from f will halt the iteration.
41077// The provided context supersedes any context provided to the Context method.
41078func (c *ProjectsLocationsAgentEnvironmentsUsersSessionsContextsListCall) Pages(ctx context.Context, f func(*GoogleCloudDialogflowV2ListContextsResponse) error) error {
41079	c.ctx_ = ctx
41080	defer c.PageToken(c.urlParams_.Get("pageToken")) // reset paging to original point
41081	for {
41082		x, err := c.Do()
41083		if err != nil {
41084			return err
41085		}
41086		if err := f(x); err != nil {
41087			return err
41088		}
41089		if x.NextPageToken == "" {
41090			return nil
41091		}
41092		c.PageToken(x.NextPageToken)
41093	}
41094}
41095
41096// method id "dialogflow.projects.locations.agent.environments.users.sessions.contexts.patch":
41097
41098type ProjectsLocationsAgentEnvironmentsUsersSessionsContextsPatchCall struct {
41099	s                              *Service
41100	nameid                         string
41101	googleclouddialogflowv2context *GoogleCloudDialogflowV2Context
41102	urlParams_                     gensupport.URLParams
41103	ctx_                           context.Context
41104	header_                        http.Header
41105}
41106
41107// Patch: Updates the specified context.
41108//
41109// - name: The unique identifier of the context. Format:
41110//   `projects//agent/sessions//contexts/`, or
41111//   `projects//agent/environments//users//sessions//contexts/`. The
41112//   `Context ID` is always converted to lowercase, may only contain
41113//   characters in a-zA-Z0-9_-% and may be at most 250 bytes long. If
41114//   `Environment ID` is not specified, we assume default 'draft'
41115//   environment. If `User ID` is not specified, we assume default '-'
41116//   user. The following context names are reserved for internal use by
41117//   Dialogflow. You should not use these contexts or create contexts
41118//   with these names: * `__system_counters__` * `*_id_dialog_context` *
41119//   `*_dialog_params_size`.
41120func (r *ProjectsLocationsAgentEnvironmentsUsersSessionsContextsService) Patch(nameid string, googleclouddialogflowv2context *GoogleCloudDialogflowV2Context) *ProjectsLocationsAgentEnvironmentsUsersSessionsContextsPatchCall {
41121	c := &ProjectsLocationsAgentEnvironmentsUsersSessionsContextsPatchCall{s: r.s, urlParams_: make(gensupport.URLParams)}
41122	c.nameid = nameid
41123	c.googleclouddialogflowv2context = googleclouddialogflowv2context
41124	return c
41125}
41126
41127// UpdateMask sets the optional parameter "updateMask": The mask to
41128// control which fields get updated.
41129func (c *ProjectsLocationsAgentEnvironmentsUsersSessionsContextsPatchCall) UpdateMask(updateMask string) *ProjectsLocationsAgentEnvironmentsUsersSessionsContextsPatchCall {
41130	c.urlParams_.Set("updateMask", updateMask)
41131	return c
41132}
41133
41134// Fields allows partial responses to be retrieved. See
41135// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
41136// for more information.
41137func (c *ProjectsLocationsAgentEnvironmentsUsersSessionsContextsPatchCall) Fields(s ...googleapi.Field) *ProjectsLocationsAgentEnvironmentsUsersSessionsContextsPatchCall {
41138	c.urlParams_.Set("fields", googleapi.CombineFields(s))
41139	return c
41140}
41141
41142// Context sets the context to be used in this call's Do method. Any
41143// pending HTTP request will be aborted if the provided context is
41144// canceled.
41145func (c *ProjectsLocationsAgentEnvironmentsUsersSessionsContextsPatchCall) Context(ctx context.Context) *ProjectsLocationsAgentEnvironmentsUsersSessionsContextsPatchCall {
41146	c.ctx_ = ctx
41147	return c
41148}
41149
41150// Header returns an http.Header that can be modified by the caller to
41151// add HTTP headers to the request.
41152func (c *ProjectsLocationsAgentEnvironmentsUsersSessionsContextsPatchCall) Header() http.Header {
41153	if c.header_ == nil {
41154		c.header_ = make(http.Header)
41155	}
41156	return c.header_
41157}
41158
41159func (c *ProjectsLocationsAgentEnvironmentsUsersSessionsContextsPatchCall) doRequest(alt string) (*http.Response, error) {
41160	reqHeaders := make(http.Header)
41161	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20211027")
41162	for k, v := range c.header_ {
41163		reqHeaders[k] = v
41164	}
41165	reqHeaders.Set("User-Agent", c.s.userAgent())
41166	var body io.Reader = nil
41167	body, err := googleapi.WithoutDataWrapper.JSONReader(c.googleclouddialogflowv2context)
41168	if err != nil {
41169		return nil, err
41170	}
41171	reqHeaders.Set("Content-Type", "application/json")
41172	c.urlParams_.Set("alt", alt)
41173	c.urlParams_.Set("prettyPrint", "false")
41174	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+name}")
41175	urls += "?" + c.urlParams_.Encode()
41176	req, err := http.NewRequest("PATCH", urls, body)
41177	if err != nil {
41178		return nil, err
41179	}
41180	req.Header = reqHeaders
41181	googleapi.Expand(req.URL, map[string]string{
41182		"name": c.nameid,
41183	})
41184	return gensupport.SendRequest(c.ctx_, c.s.client, req)
41185}
41186
41187// Do executes the "dialogflow.projects.locations.agent.environments.users.sessions.contexts.patch" call.
41188// Exactly one of *GoogleCloudDialogflowV2Context or error will be
41189// non-nil. Any non-2xx status code is an error. Response headers are in
41190// either *GoogleCloudDialogflowV2Context.ServerResponse.Header or (if a
41191// response was returned at all) in error.(*googleapi.Error).Header. Use
41192// googleapi.IsNotModified to check whether the returned error was
41193// because http.StatusNotModified was returned.
41194func (c *ProjectsLocationsAgentEnvironmentsUsersSessionsContextsPatchCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDialogflowV2Context, error) {
41195	gensupport.SetOptions(c.urlParams_, opts...)
41196	res, err := c.doRequest("json")
41197	if res != nil && res.StatusCode == http.StatusNotModified {
41198		if res.Body != nil {
41199			res.Body.Close()
41200		}
41201		return nil, &googleapi.Error{
41202			Code:   res.StatusCode,
41203			Header: res.Header,
41204		}
41205	}
41206	if err != nil {
41207		return nil, err
41208	}
41209	defer googleapi.CloseBody(res)
41210	if err := googleapi.CheckResponse(res); err != nil {
41211		return nil, err
41212	}
41213	ret := &GoogleCloudDialogflowV2Context{
41214		ServerResponse: googleapi.ServerResponse{
41215			Header:         res.Header,
41216			HTTPStatusCode: res.StatusCode,
41217		},
41218	}
41219	target := &ret
41220	if err := gensupport.DecodeResponse(target, res); err != nil {
41221		return nil, err
41222	}
41223	return ret, nil
41224	// {
41225	//   "description": "Updates the specified context.",
41226	//   "flatPath": "v2/projects/{projectsId}/locations/{locationsId}/agent/environments/{environmentsId}/users/{usersId}/sessions/{sessionsId}/contexts/{contextsId}",
41227	//   "httpMethod": "PATCH",
41228	//   "id": "dialogflow.projects.locations.agent.environments.users.sessions.contexts.patch",
41229	//   "parameterOrder": [
41230	//     "name"
41231	//   ],
41232	//   "parameters": {
41233	//     "name": {
41234	//       "description": "Required. The unique identifier of the context. Format: `projects//agent/sessions//contexts/`, or `projects//agent/environments//users//sessions//contexts/`. The `Context ID` is always converted to lowercase, may only contain characters in a-zA-Z0-9_-% and may be at most 250 bytes long. If `Environment ID` is not specified, we assume default 'draft' environment. If `User ID` is not specified, we assume default '-' user. The following context names are reserved for internal use by Dialogflow. You should not use these contexts or create contexts with these names: * `__system_counters__` * `*_id_dialog_context` * `*_dialog_params_size`",
41235	//       "location": "path",
41236	//       "pattern": "^projects/[^/]+/locations/[^/]+/agent/environments/[^/]+/users/[^/]+/sessions/[^/]+/contexts/[^/]+$",
41237	//       "required": true,
41238	//       "type": "string"
41239	//     },
41240	//     "updateMask": {
41241	//       "description": "Optional. The mask to control which fields get updated.",
41242	//       "format": "google-fieldmask",
41243	//       "location": "query",
41244	//       "type": "string"
41245	//     }
41246	//   },
41247	//   "path": "v2/{+name}",
41248	//   "request": {
41249	//     "$ref": "GoogleCloudDialogflowV2Context"
41250	//   },
41251	//   "response": {
41252	//     "$ref": "GoogleCloudDialogflowV2Context"
41253	//   },
41254	//   "scopes": [
41255	//     "https://www.googleapis.com/auth/cloud-platform",
41256	//     "https://www.googleapis.com/auth/dialogflow"
41257	//   ]
41258	// }
41259
41260}
41261
41262// method id "dialogflow.projects.locations.agent.environments.users.sessions.entityTypes.create":
41263
41264type ProjectsLocationsAgentEnvironmentsUsersSessionsEntityTypesCreateCall struct {
41265	s                                        *Service
41266	parent                                   string
41267	googleclouddialogflowv2sessionentitytype *GoogleCloudDialogflowV2SessionEntityType
41268	urlParams_                               gensupport.URLParams
41269	ctx_                                     context.Context
41270	header_                                  http.Header
41271}
41272
41273// Create: Creates a session entity type. If the specified session
41274// entity type already exists, overrides the session entity type. This
41275// method doesn't work with Google Assistant integration. Contact
41276// Dialogflow support if you need to use session entities with Google
41277// Assistant integration.
41278//
41279// - parent: The session to create a session entity type for. Format:
41280//   `projects//agent/sessions/` or
41281//   `projects//agent/environments//users// sessions/`. If `Environment
41282//   ID` is not specified, we assume default 'draft' environment. If
41283//   `User ID` is not specified, we assume default '-' user.
41284func (r *ProjectsLocationsAgentEnvironmentsUsersSessionsEntityTypesService) Create(parent string, googleclouddialogflowv2sessionentitytype *GoogleCloudDialogflowV2SessionEntityType) *ProjectsLocationsAgentEnvironmentsUsersSessionsEntityTypesCreateCall {
41285	c := &ProjectsLocationsAgentEnvironmentsUsersSessionsEntityTypesCreateCall{s: r.s, urlParams_: make(gensupport.URLParams)}
41286	c.parent = parent
41287	c.googleclouddialogflowv2sessionentitytype = googleclouddialogflowv2sessionentitytype
41288	return c
41289}
41290
41291// Fields allows partial responses to be retrieved. See
41292// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
41293// for more information.
41294func (c *ProjectsLocationsAgentEnvironmentsUsersSessionsEntityTypesCreateCall) Fields(s ...googleapi.Field) *ProjectsLocationsAgentEnvironmentsUsersSessionsEntityTypesCreateCall {
41295	c.urlParams_.Set("fields", googleapi.CombineFields(s))
41296	return c
41297}
41298
41299// Context sets the context to be used in this call's Do method. Any
41300// pending HTTP request will be aborted if the provided context is
41301// canceled.
41302func (c *ProjectsLocationsAgentEnvironmentsUsersSessionsEntityTypesCreateCall) Context(ctx context.Context) *ProjectsLocationsAgentEnvironmentsUsersSessionsEntityTypesCreateCall {
41303	c.ctx_ = ctx
41304	return c
41305}
41306
41307// Header returns an http.Header that can be modified by the caller to
41308// add HTTP headers to the request.
41309func (c *ProjectsLocationsAgentEnvironmentsUsersSessionsEntityTypesCreateCall) Header() http.Header {
41310	if c.header_ == nil {
41311		c.header_ = make(http.Header)
41312	}
41313	return c.header_
41314}
41315
41316func (c *ProjectsLocationsAgentEnvironmentsUsersSessionsEntityTypesCreateCall) doRequest(alt string) (*http.Response, error) {
41317	reqHeaders := make(http.Header)
41318	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20211027")
41319	for k, v := range c.header_ {
41320		reqHeaders[k] = v
41321	}
41322	reqHeaders.Set("User-Agent", c.s.userAgent())
41323	var body io.Reader = nil
41324	body, err := googleapi.WithoutDataWrapper.JSONReader(c.googleclouddialogflowv2sessionentitytype)
41325	if err != nil {
41326		return nil, err
41327	}
41328	reqHeaders.Set("Content-Type", "application/json")
41329	c.urlParams_.Set("alt", alt)
41330	c.urlParams_.Set("prettyPrint", "false")
41331	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+parent}/entityTypes")
41332	urls += "?" + c.urlParams_.Encode()
41333	req, err := http.NewRequest("POST", urls, body)
41334	if err != nil {
41335		return nil, err
41336	}
41337	req.Header = reqHeaders
41338	googleapi.Expand(req.URL, map[string]string{
41339		"parent": c.parent,
41340	})
41341	return gensupport.SendRequest(c.ctx_, c.s.client, req)
41342}
41343
41344// Do executes the "dialogflow.projects.locations.agent.environments.users.sessions.entityTypes.create" call.
41345// Exactly one of *GoogleCloudDialogflowV2SessionEntityType or error
41346// will be non-nil. Any non-2xx status code is an error. Response
41347// headers are in either
41348// *GoogleCloudDialogflowV2SessionEntityType.ServerResponse.Header or
41349// (if a response was returned at all) in
41350// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
41351// whether the returned error was because http.StatusNotModified was
41352// returned.
41353func (c *ProjectsLocationsAgentEnvironmentsUsersSessionsEntityTypesCreateCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDialogflowV2SessionEntityType, error) {
41354	gensupport.SetOptions(c.urlParams_, opts...)
41355	res, err := c.doRequest("json")
41356	if res != nil && res.StatusCode == http.StatusNotModified {
41357		if res.Body != nil {
41358			res.Body.Close()
41359		}
41360		return nil, &googleapi.Error{
41361			Code:   res.StatusCode,
41362			Header: res.Header,
41363		}
41364	}
41365	if err != nil {
41366		return nil, err
41367	}
41368	defer googleapi.CloseBody(res)
41369	if err := googleapi.CheckResponse(res); err != nil {
41370		return nil, err
41371	}
41372	ret := &GoogleCloudDialogflowV2SessionEntityType{
41373		ServerResponse: googleapi.ServerResponse{
41374			Header:         res.Header,
41375			HTTPStatusCode: res.StatusCode,
41376		},
41377	}
41378	target := &ret
41379	if err := gensupport.DecodeResponse(target, res); err != nil {
41380		return nil, err
41381	}
41382	return ret, nil
41383	// {
41384	//   "description": "Creates a session entity type. If the specified session entity type already exists, overrides the session entity type. This method doesn't work with Google Assistant integration. Contact Dialogflow support if you need to use session entities with Google Assistant integration.",
41385	//   "flatPath": "v2/projects/{projectsId}/locations/{locationsId}/agent/environments/{environmentsId}/users/{usersId}/sessions/{sessionsId}/entityTypes",
41386	//   "httpMethod": "POST",
41387	//   "id": "dialogflow.projects.locations.agent.environments.users.sessions.entityTypes.create",
41388	//   "parameterOrder": [
41389	//     "parent"
41390	//   ],
41391	//   "parameters": {
41392	//     "parent": {
41393	//       "description": "Required. The session to create a session entity type for. Format: `projects//agent/sessions/` or `projects//agent/environments//users// sessions/`. If `Environment ID` is not specified, we assume default 'draft' environment. If `User ID` is not specified, we assume default '-' user.",
41394	//       "location": "path",
41395	//       "pattern": "^projects/[^/]+/locations/[^/]+/agent/environments/[^/]+/users/[^/]+/sessions/[^/]+$",
41396	//       "required": true,
41397	//       "type": "string"
41398	//     }
41399	//   },
41400	//   "path": "v2/{+parent}/entityTypes",
41401	//   "request": {
41402	//     "$ref": "GoogleCloudDialogflowV2SessionEntityType"
41403	//   },
41404	//   "response": {
41405	//     "$ref": "GoogleCloudDialogflowV2SessionEntityType"
41406	//   },
41407	//   "scopes": [
41408	//     "https://www.googleapis.com/auth/cloud-platform",
41409	//     "https://www.googleapis.com/auth/dialogflow"
41410	//   ]
41411	// }
41412
41413}
41414
41415// method id "dialogflow.projects.locations.agent.environments.users.sessions.entityTypes.delete":
41416
41417type ProjectsLocationsAgentEnvironmentsUsersSessionsEntityTypesDeleteCall struct {
41418	s          *Service
41419	name       string
41420	urlParams_ gensupport.URLParams
41421	ctx_       context.Context
41422	header_    http.Header
41423}
41424
41425// Delete: Deletes the specified session entity type. This method
41426// doesn't work with Google Assistant integration. Contact Dialogflow
41427// support if you need to use session entities with Google Assistant
41428// integration.
41429//
41430// - name: The name of the entity type to delete. Format:
41431//   `projects//agent/sessions//entityTypes/` or
41432//   `projects//agent/environments//users//sessions//entityTypes/`. If
41433//   `Environment ID` is not specified, we assume default 'draft'
41434//   environment. If `User ID` is not specified, we assume default '-'
41435//   user.
41436func (r *ProjectsLocationsAgentEnvironmentsUsersSessionsEntityTypesService) Delete(name string) *ProjectsLocationsAgentEnvironmentsUsersSessionsEntityTypesDeleteCall {
41437	c := &ProjectsLocationsAgentEnvironmentsUsersSessionsEntityTypesDeleteCall{s: r.s, urlParams_: make(gensupport.URLParams)}
41438	c.name = name
41439	return c
41440}
41441
41442// Fields allows partial responses to be retrieved. See
41443// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
41444// for more information.
41445func (c *ProjectsLocationsAgentEnvironmentsUsersSessionsEntityTypesDeleteCall) Fields(s ...googleapi.Field) *ProjectsLocationsAgentEnvironmentsUsersSessionsEntityTypesDeleteCall {
41446	c.urlParams_.Set("fields", googleapi.CombineFields(s))
41447	return c
41448}
41449
41450// Context sets the context to be used in this call's Do method. Any
41451// pending HTTP request will be aborted if the provided context is
41452// canceled.
41453func (c *ProjectsLocationsAgentEnvironmentsUsersSessionsEntityTypesDeleteCall) Context(ctx context.Context) *ProjectsLocationsAgentEnvironmentsUsersSessionsEntityTypesDeleteCall {
41454	c.ctx_ = ctx
41455	return c
41456}
41457
41458// Header returns an http.Header that can be modified by the caller to
41459// add HTTP headers to the request.
41460func (c *ProjectsLocationsAgentEnvironmentsUsersSessionsEntityTypesDeleteCall) Header() http.Header {
41461	if c.header_ == nil {
41462		c.header_ = make(http.Header)
41463	}
41464	return c.header_
41465}
41466
41467func (c *ProjectsLocationsAgentEnvironmentsUsersSessionsEntityTypesDeleteCall) doRequest(alt string) (*http.Response, error) {
41468	reqHeaders := make(http.Header)
41469	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20211027")
41470	for k, v := range c.header_ {
41471		reqHeaders[k] = v
41472	}
41473	reqHeaders.Set("User-Agent", c.s.userAgent())
41474	var body io.Reader = nil
41475	c.urlParams_.Set("alt", alt)
41476	c.urlParams_.Set("prettyPrint", "false")
41477	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+name}")
41478	urls += "?" + c.urlParams_.Encode()
41479	req, err := http.NewRequest("DELETE", urls, body)
41480	if err != nil {
41481		return nil, err
41482	}
41483	req.Header = reqHeaders
41484	googleapi.Expand(req.URL, map[string]string{
41485		"name": c.name,
41486	})
41487	return gensupport.SendRequest(c.ctx_, c.s.client, req)
41488}
41489
41490// Do executes the "dialogflow.projects.locations.agent.environments.users.sessions.entityTypes.delete" call.
41491// Exactly one of *GoogleProtobufEmpty or error will be non-nil. Any
41492// non-2xx status code is an error. Response headers are in either
41493// *GoogleProtobufEmpty.ServerResponse.Header or (if a response was
41494// returned at all) in error.(*googleapi.Error).Header. Use
41495// googleapi.IsNotModified to check whether the returned error was
41496// because http.StatusNotModified was returned.
41497func (c *ProjectsLocationsAgentEnvironmentsUsersSessionsEntityTypesDeleteCall) Do(opts ...googleapi.CallOption) (*GoogleProtobufEmpty, error) {
41498	gensupport.SetOptions(c.urlParams_, opts...)
41499	res, err := c.doRequest("json")
41500	if res != nil && res.StatusCode == http.StatusNotModified {
41501		if res.Body != nil {
41502			res.Body.Close()
41503		}
41504		return nil, &googleapi.Error{
41505			Code:   res.StatusCode,
41506			Header: res.Header,
41507		}
41508	}
41509	if err != nil {
41510		return nil, err
41511	}
41512	defer googleapi.CloseBody(res)
41513	if err := googleapi.CheckResponse(res); err != nil {
41514		return nil, err
41515	}
41516	ret := &GoogleProtobufEmpty{
41517		ServerResponse: googleapi.ServerResponse{
41518			Header:         res.Header,
41519			HTTPStatusCode: res.StatusCode,
41520		},
41521	}
41522	target := &ret
41523	if err := gensupport.DecodeResponse(target, res); err != nil {
41524		return nil, err
41525	}
41526	return ret, nil
41527	// {
41528	//   "description": "Deletes the specified session entity type. This method doesn't work with Google Assistant integration. Contact Dialogflow support if you need to use session entities with Google Assistant integration.",
41529	//   "flatPath": "v2/projects/{projectsId}/locations/{locationsId}/agent/environments/{environmentsId}/users/{usersId}/sessions/{sessionsId}/entityTypes/{entityTypesId}",
41530	//   "httpMethod": "DELETE",
41531	//   "id": "dialogflow.projects.locations.agent.environments.users.sessions.entityTypes.delete",
41532	//   "parameterOrder": [
41533	//     "name"
41534	//   ],
41535	//   "parameters": {
41536	//     "name": {
41537	//       "description": "Required. The name of the entity type to delete. Format: `projects//agent/sessions//entityTypes/` or `projects//agent/environments//users//sessions//entityTypes/`. If `Environment ID` is not specified, we assume default 'draft' environment. If `User ID` is not specified, we assume default '-' user.",
41538	//       "location": "path",
41539	//       "pattern": "^projects/[^/]+/locations/[^/]+/agent/environments/[^/]+/users/[^/]+/sessions/[^/]+/entityTypes/[^/]+$",
41540	//       "required": true,
41541	//       "type": "string"
41542	//     }
41543	//   },
41544	//   "path": "v2/{+name}",
41545	//   "response": {
41546	//     "$ref": "GoogleProtobufEmpty"
41547	//   },
41548	//   "scopes": [
41549	//     "https://www.googleapis.com/auth/cloud-platform",
41550	//     "https://www.googleapis.com/auth/dialogflow"
41551	//   ]
41552	// }
41553
41554}
41555
41556// method id "dialogflow.projects.locations.agent.environments.users.sessions.entityTypes.get":
41557
41558type ProjectsLocationsAgentEnvironmentsUsersSessionsEntityTypesGetCall struct {
41559	s            *Service
41560	name         string
41561	urlParams_   gensupport.URLParams
41562	ifNoneMatch_ string
41563	ctx_         context.Context
41564	header_      http.Header
41565}
41566
41567// Get: Retrieves the specified session entity type. This method doesn't
41568// work with Google Assistant integration. Contact Dialogflow support if
41569// you need to use session entities with Google Assistant integration.
41570//
41571// - name: The name of the session entity type. Format:
41572//   `projects//agent/sessions//entityTypes/` or
41573//   `projects//agent/environments//users//sessions//entityTypes/`. If
41574//   `Environment ID` is not specified, we assume default 'draft'
41575//   environment. If `User ID` is not specified, we assume default '-'
41576//   user.
41577func (r *ProjectsLocationsAgentEnvironmentsUsersSessionsEntityTypesService) Get(name string) *ProjectsLocationsAgentEnvironmentsUsersSessionsEntityTypesGetCall {
41578	c := &ProjectsLocationsAgentEnvironmentsUsersSessionsEntityTypesGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
41579	c.name = name
41580	return c
41581}
41582
41583// Fields allows partial responses to be retrieved. See
41584// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
41585// for more information.
41586func (c *ProjectsLocationsAgentEnvironmentsUsersSessionsEntityTypesGetCall) Fields(s ...googleapi.Field) *ProjectsLocationsAgentEnvironmentsUsersSessionsEntityTypesGetCall {
41587	c.urlParams_.Set("fields", googleapi.CombineFields(s))
41588	return c
41589}
41590
41591// IfNoneMatch sets the optional parameter which makes the operation
41592// fail if the object's ETag matches the given value. This is useful for
41593// getting updates only after the object has changed since the last
41594// request. Use googleapi.IsNotModified to check whether the response
41595// error from Do is the result of In-None-Match.
41596func (c *ProjectsLocationsAgentEnvironmentsUsersSessionsEntityTypesGetCall) IfNoneMatch(entityTag string) *ProjectsLocationsAgentEnvironmentsUsersSessionsEntityTypesGetCall {
41597	c.ifNoneMatch_ = entityTag
41598	return c
41599}
41600
41601// Context sets the context to be used in this call's Do method. Any
41602// pending HTTP request will be aborted if the provided context is
41603// canceled.
41604func (c *ProjectsLocationsAgentEnvironmentsUsersSessionsEntityTypesGetCall) Context(ctx context.Context) *ProjectsLocationsAgentEnvironmentsUsersSessionsEntityTypesGetCall {
41605	c.ctx_ = ctx
41606	return c
41607}
41608
41609// Header returns an http.Header that can be modified by the caller to
41610// add HTTP headers to the request.
41611func (c *ProjectsLocationsAgentEnvironmentsUsersSessionsEntityTypesGetCall) Header() http.Header {
41612	if c.header_ == nil {
41613		c.header_ = make(http.Header)
41614	}
41615	return c.header_
41616}
41617
41618func (c *ProjectsLocationsAgentEnvironmentsUsersSessionsEntityTypesGetCall) doRequest(alt string) (*http.Response, error) {
41619	reqHeaders := make(http.Header)
41620	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20211027")
41621	for k, v := range c.header_ {
41622		reqHeaders[k] = v
41623	}
41624	reqHeaders.Set("User-Agent", c.s.userAgent())
41625	if c.ifNoneMatch_ != "" {
41626		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
41627	}
41628	var body io.Reader = nil
41629	c.urlParams_.Set("alt", alt)
41630	c.urlParams_.Set("prettyPrint", "false")
41631	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+name}")
41632	urls += "?" + c.urlParams_.Encode()
41633	req, err := http.NewRequest("GET", urls, body)
41634	if err != nil {
41635		return nil, err
41636	}
41637	req.Header = reqHeaders
41638	googleapi.Expand(req.URL, map[string]string{
41639		"name": c.name,
41640	})
41641	return gensupport.SendRequest(c.ctx_, c.s.client, req)
41642}
41643
41644// Do executes the "dialogflow.projects.locations.agent.environments.users.sessions.entityTypes.get" call.
41645// Exactly one of *GoogleCloudDialogflowV2SessionEntityType or error
41646// will be non-nil. Any non-2xx status code is an error. Response
41647// headers are in either
41648// *GoogleCloudDialogflowV2SessionEntityType.ServerResponse.Header or
41649// (if a response was returned at all) in
41650// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
41651// whether the returned error was because http.StatusNotModified was
41652// returned.
41653func (c *ProjectsLocationsAgentEnvironmentsUsersSessionsEntityTypesGetCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDialogflowV2SessionEntityType, error) {
41654	gensupport.SetOptions(c.urlParams_, opts...)
41655	res, err := c.doRequest("json")
41656	if res != nil && res.StatusCode == http.StatusNotModified {
41657		if res.Body != nil {
41658			res.Body.Close()
41659		}
41660		return nil, &googleapi.Error{
41661			Code:   res.StatusCode,
41662			Header: res.Header,
41663		}
41664	}
41665	if err != nil {
41666		return nil, err
41667	}
41668	defer googleapi.CloseBody(res)
41669	if err := googleapi.CheckResponse(res); err != nil {
41670		return nil, err
41671	}
41672	ret := &GoogleCloudDialogflowV2SessionEntityType{
41673		ServerResponse: googleapi.ServerResponse{
41674			Header:         res.Header,
41675			HTTPStatusCode: res.StatusCode,
41676		},
41677	}
41678	target := &ret
41679	if err := gensupport.DecodeResponse(target, res); err != nil {
41680		return nil, err
41681	}
41682	return ret, nil
41683	// {
41684	//   "description": "Retrieves the specified session entity type. This method doesn't work with Google Assistant integration. Contact Dialogflow support if you need to use session entities with Google Assistant integration.",
41685	//   "flatPath": "v2/projects/{projectsId}/locations/{locationsId}/agent/environments/{environmentsId}/users/{usersId}/sessions/{sessionsId}/entityTypes/{entityTypesId}",
41686	//   "httpMethod": "GET",
41687	//   "id": "dialogflow.projects.locations.agent.environments.users.sessions.entityTypes.get",
41688	//   "parameterOrder": [
41689	//     "name"
41690	//   ],
41691	//   "parameters": {
41692	//     "name": {
41693	//       "description": "Required. The name of the session entity type. Format: `projects//agent/sessions//entityTypes/` or `projects//agent/environments//users//sessions//entityTypes/`. If `Environment ID` is not specified, we assume default 'draft' environment. If `User ID` is not specified, we assume default '-' user.",
41694	//       "location": "path",
41695	//       "pattern": "^projects/[^/]+/locations/[^/]+/agent/environments/[^/]+/users/[^/]+/sessions/[^/]+/entityTypes/[^/]+$",
41696	//       "required": true,
41697	//       "type": "string"
41698	//     }
41699	//   },
41700	//   "path": "v2/{+name}",
41701	//   "response": {
41702	//     "$ref": "GoogleCloudDialogflowV2SessionEntityType"
41703	//   },
41704	//   "scopes": [
41705	//     "https://www.googleapis.com/auth/cloud-platform",
41706	//     "https://www.googleapis.com/auth/dialogflow"
41707	//   ]
41708	// }
41709
41710}
41711
41712// method id "dialogflow.projects.locations.agent.environments.users.sessions.entityTypes.list":
41713
41714type ProjectsLocationsAgentEnvironmentsUsersSessionsEntityTypesListCall struct {
41715	s            *Service
41716	parent       string
41717	urlParams_   gensupport.URLParams
41718	ifNoneMatch_ string
41719	ctx_         context.Context
41720	header_      http.Header
41721}
41722
41723// List: Returns the list of all session entity types in the specified
41724// session. This method doesn't work with Google Assistant integration.
41725// Contact Dialogflow support if you need to use session entities with
41726// Google Assistant integration.
41727//
41728// - parent: The session to list all session entity types from. Format:
41729//   `projects//agent/sessions/` or
41730//   `projects//agent/environments//users// sessions/`. If `Environment
41731//   ID` is not specified, we assume default 'draft' environment. If
41732//   `User ID` is not specified, we assume default '-' user.
41733func (r *ProjectsLocationsAgentEnvironmentsUsersSessionsEntityTypesService) List(parent string) *ProjectsLocationsAgentEnvironmentsUsersSessionsEntityTypesListCall {
41734	c := &ProjectsLocationsAgentEnvironmentsUsersSessionsEntityTypesListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
41735	c.parent = parent
41736	return c
41737}
41738
41739// PageSize sets the optional parameter "pageSize": The maximum number
41740// of items to return in a single page. By default 100 and at most 1000.
41741func (c *ProjectsLocationsAgentEnvironmentsUsersSessionsEntityTypesListCall) PageSize(pageSize int64) *ProjectsLocationsAgentEnvironmentsUsersSessionsEntityTypesListCall {
41742	c.urlParams_.Set("pageSize", fmt.Sprint(pageSize))
41743	return c
41744}
41745
41746// PageToken sets the optional parameter "pageToken": The
41747// next_page_token value returned from a previous list request.
41748func (c *ProjectsLocationsAgentEnvironmentsUsersSessionsEntityTypesListCall) PageToken(pageToken string) *ProjectsLocationsAgentEnvironmentsUsersSessionsEntityTypesListCall {
41749	c.urlParams_.Set("pageToken", pageToken)
41750	return c
41751}
41752
41753// Fields allows partial responses to be retrieved. See
41754// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
41755// for more information.
41756func (c *ProjectsLocationsAgentEnvironmentsUsersSessionsEntityTypesListCall) Fields(s ...googleapi.Field) *ProjectsLocationsAgentEnvironmentsUsersSessionsEntityTypesListCall {
41757	c.urlParams_.Set("fields", googleapi.CombineFields(s))
41758	return c
41759}
41760
41761// IfNoneMatch sets the optional parameter which makes the operation
41762// fail if the object's ETag matches the given value. This is useful for
41763// getting updates only after the object has changed since the last
41764// request. Use googleapi.IsNotModified to check whether the response
41765// error from Do is the result of In-None-Match.
41766func (c *ProjectsLocationsAgentEnvironmentsUsersSessionsEntityTypesListCall) IfNoneMatch(entityTag string) *ProjectsLocationsAgentEnvironmentsUsersSessionsEntityTypesListCall {
41767	c.ifNoneMatch_ = entityTag
41768	return c
41769}
41770
41771// Context sets the context to be used in this call's Do method. Any
41772// pending HTTP request will be aborted if the provided context is
41773// canceled.
41774func (c *ProjectsLocationsAgentEnvironmentsUsersSessionsEntityTypesListCall) Context(ctx context.Context) *ProjectsLocationsAgentEnvironmentsUsersSessionsEntityTypesListCall {
41775	c.ctx_ = ctx
41776	return c
41777}
41778
41779// Header returns an http.Header that can be modified by the caller to
41780// add HTTP headers to the request.
41781func (c *ProjectsLocationsAgentEnvironmentsUsersSessionsEntityTypesListCall) Header() http.Header {
41782	if c.header_ == nil {
41783		c.header_ = make(http.Header)
41784	}
41785	return c.header_
41786}
41787
41788func (c *ProjectsLocationsAgentEnvironmentsUsersSessionsEntityTypesListCall) doRequest(alt string) (*http.Response, error) {
41789	reqHeaders := make(http.Header)
41790	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20211027")
41791	for k, v := range c.header_ {
41792		reqHeaders[k] = v
41793	}
41794	reqHeaders.Set("User-Agent", c.s.userAgent())
41795	if c.ifNoneMatch_ != "" {
41796		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
41797	}
41798	var body io.Reader = nil
41799	c.urlParams_.Set("alt", alt)
41800	c.urlParams_.Set("prettyPrint", "false")
41801	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+parent}/entityTypes")
41802	urls += "?" + c.urlParams_.Encode()
41803	req, err := http.NewRequest("GET", urls, body)
41804	if err != nil {
41805		return nil, err
41806	}
41807	req.Header = reqHeaders
41808	googleapi.Expand(req.URL, map[string]string{
41809		"parent": c.parent,
41810	})
41811	return gensupport.SendRequest(c.ctx_, c.s.client, req)
41812}
41813
41814// Do executes the "dialogflow.projects.locations.agent.environments.users.sessions.entityTypes.list" call.
41815// Exactly one of *GoogleCloudDialogflowV2ListSessionEntityTypesResponse
41816// or error will be non-nil. Any non-2xx status code is an error.
41817// Response headers are in either
41818// *GoogleCloudDialogflowV2ListSessionEntityTypesResponse.ServerResponse.
41819// Header or (if a response was returned at all) in
41820// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
41821// whether the returned error was because http.StatusNotModified was
41822// returned.
41823func (c *ProjectsLocationsAgentEnvironmentsUsersSessionsEntityTypesListCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDialogflowV2ListSessionEntityTypesResponse, error) {
41824	gensupport.SetOptions(c.urlParams_, opts...)
41825	res, err := c.doRequest("json")
41826	if res != nil && res.StatusCode == http.StatusNotModified {
41827		if res.Body != nil {
41828			res.Body.Close()
41829		}
41830		return nil, &googleapi.Error{
41831			Code:   res.StatusCode,
41832			Header: res.Header,
41833		}
41834	}
41835	if err != nil {
41836		return nil, err
41837	}
41838	defer googleapi.CloseBody(res)
41839	if err := googleapi.CheckResponse(res); err != nil {
41840		return nil, err
41841	}
41842	ret := &GoogleCloudDialogflowV2ListSessionEntityTypesResponse{
41843		ServerResponse: googleapi.ServerResponse{
41844			Header:         res.Header,
41845			HTTPStatusCode: res.StatusCode,
41846		},
41847	}
41848	target := &ret
41849	if err := gensupport.DecodeResponse(target, res); err != nil {
41850		return nil, err
41851	}
41852	return ret, nil
41853	// {
41854	//   "description": "Returns the list of all session entity types in the specified session. This method doesn't work with Google Assistant integration. Contact Dialogflow support if you need to use session entities with Google Assistant integration.",
41855	//   "flatPath": "v2/projects/{projectsId}/locations/{locationsId}/agent/environments/{environmentsId}/users/{usersId}/sessions/{sessionsId}/entityTypes",
41856	//   "httpMethod": "GET",
41857	//   "id": "dialogflow.projects.locations.agent.environments.users.sessions.entityTypes.list",
41858	//   "parameterOrder": [
41859	//     "parent"
41860	//   ],
41861	//   "parameters": {
41862	//     "pageSize": {
41863	//       "description": "Optional. The maximum number of items to return in a single page. By default 100 and at most 1000.",
41864	//       "format": "int32",
41865	//       "location": "query",
41866	//       "type": "integer"
41867	//     },
41868	//     "pageToken": {
41869	//       "description": "Optional. The next_page_token value returned from a previous list request.",
41870	//       "location": "query",
41871	//       "type": "string"
41872	//     },
41873	//     "parent": {
41874	//       "description": "Required. The session to list all session entity types from. Format: `projects//agent/sessions/` or `projects//agent/environments//users// sessions/`. If `Environment ID` is not specified, we assume default 'draft' environment. If `User ID` is not specified, we assume default '-' user.",
41875	//       "location": "path",
41876	//       "pattern": "^projects/[^/]+/locations/[^/]+/agent/environments/[^/]+/users/[^/]+/sessions/[^/]+$",
41877	//       "required": true,
41878	//       "type": "string"
41879	//     }
41880	//   },
41881	//   "path": "v2/{+parent}/entityTypes",
41882	//   "response": {
41883	//     "$ref": "GoogleCloudDialogflowV2ListSessionEntityTypesResponse"
41884	//   },
41885	//   "scopes": [
41886	//     "https://www.googleapis.com/auth/cloud-platform",
41887	//     "https://www.googleapis.com/auth/dialogflow"
41888	//   ]
41889	// }
41890
41891}
41892
41893// Pages invokes f for each page of results.
41894// A non-nil error returned from f will halt the iteration.
41895// The provided context supersedes any context provided to the Context method.
41896func (c *ProjectsLocationsAgentEnvironmentsUsersSessionsEntityTypesListCall) Pages(ctx context.Context, f func(*GoogleCloudDialogflowV2ListSessionEntityTypesResponse) error) error {
41897	c.ctx_ = ctx
41898	defer c.PageToken(c.urlParams_.Get("pageToken")) // reset paging to original point
41899	for {
41900		x, err := c.Do()
41901		if err != nil {
41902			return err
41903		}
41904		if err := f(x); err != nil {
41905			return err
41906		}
41907		if x.NextPageToken == "" {
41908			return nil
41909		}
41910		c.PageToken(x.NextPageToken)
41911	}
41912}
41913
41914// method id "dialogflow.projects.locations.agent.environments.users.sessions.entityTypes.patch":
41915
41916type ProjectsLocationsAgentEnvironmentsUsersSessionsEntityTypesPatchCall struct {
41917	s                                        *Service
41918	nameid                                   string
41919	googleclouddialogflowv2sessionentitytype *GoogleCloudDialogflowV2SessionEntityType
41920	urlParams_                               gensupport.URLParams
41921	ctx_                                     context.Context
41922	header_                                  http.Header
41923}
41924
41925// Patch: Updates the specified session entity type. This method doesn't
41926// work with Google Assistant integration. Contact Dialogflow support if
41927// you need to use session entities with Google Assistant integration.
41928//
41929// - name: The unique identifier of this session entity type. Format:
41930//   `projects//agent/sessions//entityTypes/`, or
41931//   `projects//agent/environments//users//sessions//entityTypes/`. If
41932//   `Environment ID` is not specified, we assume default 'draft'
41933//   environment. If `User ID` is not specified, we assume default '-'
41934//   user. `` must be the display name of an existing entity type in the
41935//   same agent that will be overridden or supplemented.
41936func (r *ProjectsLocationsAgentEnvironmentsUsersSessionsEntityTypesService) Patch(nameid string, googleclouddialogflowv2sessionentitytype *GoogleCloudDialogflowV2SessionEntityType) *ProjectsLocationsAgentEnvironmentsUsersSessionsEntityTypesPatchCall {
41937	c := &ProjectsLocationsAgentEnvironmentsUsersSessionsEntityTypesPatchCall{s: r.s, urlParams_: make(gensupport.URLParams)}
41938	c.nameid = nameid
41939	c.googleclouddialogflowv2sessionentitytype = googleclouddialogflowv2sessionentitytype
41940	return c
41941}
41942
41943// UpdateMask sets the optional parameter "updateMask": The mask to
41944// control which fields get updated.
41945func (c *ProjectsLocationsAgentEnvironmentsUsersSessionsEntityTypesPatchCall) UpdateMask(updateMask string) *ProjectsLocationsAgentEnvironmentsUsersSessionsEntityTypesPatchCall {
41946	c.urlParams_.Set("updateMask", updateMask)
41947	return c
41948}
41949
41950// Fields allows partial responses to be retrieved. See
41951// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
41952// for more information.
41953func (c *ProjectsLocationsAgentEnvironmentsUsersSessionsEntityTypesPatchCall) Fields(s ...googleapi.Field) *ProjectsLocationsAgentEnvironmentsUsersSessionsEntityTypesPatchCall {
41954	c.urlParams_.Set("fields", googleapi.CombineFields(s))
41955	return c
41956}
41957
41958// Context sets the context to be used in this call's Do method. Any
41959// pending HTTP request will be aborted if the provided context is
41960// canceled.
41961func (c *ProjectsLocationsAgentEnvironmentsUsersSessionsEntityTypesPatchCall) Context(ctx context.Context) *ProjectsLocationsAgentEnvironmentsUsersSessionsEntityTypesPatchCall {
41962	c.ctx_ = ctx
41963	return c
41964}
41965
41966// Header returns an http.Header that can be modified by the caller to
41967// add HTTP headers to the request.
41968func (c *ProjectsLocationsAgentEnvironmentsUsersSessionsEntityTypesPatchCall) Header() http.Header {
41969	if c.header_ == nil {
41970		c.header_ = make(http.Header)
41971	}
41972	return c.header_
41973}
41974
41975func (c *ProjectsLocationsAgentEnvironmentsUsersSessionsEntityTypesPatchCall) doRequest(alt string) (*http.Response, error) {
41976	reqHeaders := make(http.Header)
41977	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20211027")
41978	for k, v := range c.header_ {
41979		reqHeaders[k] = v
41980	}
41981	reqHeaders.Set("User-Agent", c.s.userAgent())
41982	var body io.Reader = nil
41983	body, err := googleapi.WithoutDataWrapper.JSONReader(c.googleclouddialogflowv2sessionentitytype)
41984	if err != nil {
41985		return nil, err
41986	}
41987	reqHeaders.Set("Content-Type", "application/json")
41988	c.urlParams_.Set("alt", alt)
41989	c.urlParams_.Set("prettyPrint", "false")
41990	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+name}")
41991	urls += "?" + c.urlParams_.Encode()
41992	req, err := http.NewRequest("PATCH", urls, body)
41993	if err != nil {
41994		return nil, err
41995	}
41996	req.Header = reqHeaders
41997	googleapi.Expand(req.URL, map[string]string{
41998		"name": c.nameid,
41999	})
42000	return gensupport.SendRequest(c.ctx_, c.s.client, req)
42001}
42002
42003// Do executes the "dialogflow.projects.locations.agent.environments.users.sessions.entityTypes.patch" call.
42004// Exactly one of *GoogleCloudDialogflowV2SessionEntityType or error
42005// will be non-nil. Any non-2xx status code is an error. Response
42006// headers are in either
42007// *GoogleCloudDialogflowV2SessionEntityType.ServerResponse.Header or
42008// (if a response was returned at all) in
42009// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
42010// whether the returned error was because http.StatusNotModified was
42011// returned.
42012func (c *ProjectsLocationsAgentEnvironmentsUsersSessionsEntityTypesPatchCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDialogflowV2SessionEntityType, error) {
42013	gensupport.SetOptions(c.urlParams_, opts...)
42014	res, err := c.doRequest("json")
42015	if res != nil && res.StatusCode == http.StatusNotModified {
42016		if res.Body != nil {
42017			res.Body.Close()
42018		}
42019		return nil, &googleapi.Error{
42020			Code:   res.StatusCode,
42021			Header: res.Header,
42022		}
42023	}
42024	if err != nil {
42025		return nil, err
42026	}
42027	defer googleapi.CloseBody(res)
42028	if err := googleapi.CheckResponse(res); err != nil {
42029		return nil, err
42030	}
42031	ret := &GoogleCloudDialogflowV2SessionEntityType{
42032		ServerResponse: googleapi.ServerResponse{
42033			Header:         res.Header,
42034			HTTPStatusCode: res.StatusCode,
42035		},
42036	}
42037	target := &ret
42038	if err := gensupport.DecodeResponse(target, res); err != nil {
42039		return nil, err
42040	}
42041	return ret, nil
42042	// {
42043	//   "description": "Updates the specified session entity type. This method doesn't work with Google Assistant integration. Contact Dialogflow support if you need to use session entities with Google Assistant integration.",
42044	//   "flatPath": "v2/projects/{projectsId}/locations/{locationsId}/agent/environments/{environmentsId}/users/{usersId}/sessions/{sessionsId}/entityTypes/{entityTypesId}",
42045	//   "httpMethod": "PATCH",
42046	//   "id": "dialogflow.projects.locations.agent.environments.users.sessions.entityTypes.patch",
42047	//   "parameterOrder": [
42048	//     "name"
42049	//   ],
42050	//   "parameters": {
42051	//     "name": {
42052	//       "description": "Required. The unique identifier of this session entity type. Format: `projects//agent/sessions//entityTypes/`, or `projects//agent/environments//users//sessions//entityTypes/`. If `Environment ID` is not specified, we assume default 'draft' environment. If `User ID` is not specified, we assume default '-' user. `` must be the display name of an existing entity type in the same agent that will be overridden or supplemented.",
42053	//       "location": "path",
42054	//       "pattern": "^projects/[^/]+/locations/[^/]+/agent/environments/[^/]+/users/[^/]+/sessions/[^/]+/entityTypes/[^/]+$",
42055	//       "required": true,
42056	//       "type": "string"
42057	//     },
42058	//     "updateMask": {
42059	//       "description": "Optional. The mask to control which fields get updated.",
42060	//       "format": "google-fieldmask",
42061	//       "location": "query",
42062	//       "type": "string"
42063	//     }
42064	//   },
42065	//   "path": "v2/{+name}",
42066	//   "request": {
42067	//     "$ref": "GoogleCloudDialogflowV2SessionEntityType"
42068	//   },
42069	//   "response": {
42070	//     "$ref": "GoogleCloudDialogflowV2SessionEntityType"
42071	//   },
42072	//   "scopes": [
42073	//     "https://www.googleapis.com/auth/cloud-platform",
42074	//     "https://www.googleapis.com/auth/dialogflow"
42075	//   ]
42076	// }
42077
42078}
42079
42080// method id "dialogflow.projects.locations.agent.intents.batchDelete":
42081
42082type ProjectsLocationsAgentIntentsBatchDeleteCall struct {
42083	s                                                *Service
42084	parent                                           string
42085	googleclouddialogflowv2batchdeleteintentsrequest *GoogleCloudDialogflowV2BatchDeleteIntentsRequest
42086	urlParams_                                       gensupport.URLParams
42087	ctx_                                             context.Context
42088	header_                                          http.Header
42089}
42090
42091// BatchDelete: Deletes intents in the specified agent. This method is a
42092// long-running operation
42093// (https://cloud.google.com/dialogflow/es/docs/how/long-running-operations).
42094// The returned `Operation` type has the following method-specific
42095// fields: - `metadata`: An empty Struct message
42096// (https://developers.google.com/protocol-buffers/docs/reference/google.protobuf#struct)
42097// - `response`: An Empty message
42098// (https://developers.google.com/protocol-buffers/docs/reference/google.protobuf#empty)
42099// Note: You should always train an agent prior to sending it queries.
42100// See the training documentation
42101// (https://cloud.google.com/dialogflow/es/docs/training).
42102//
42103// - parent: The name of the agent to delete all entities types for.
42104//   Format: `projects//agent`.
42105func (r *ProjectsLocationsAgentIntentsService) BatchDelete(parent string, googleclouddialogflowv2batchdeleteintentsrequest *GoogleCloudDialogflowV2BatchDeleteIntentsRequest) *ProjectsLocationsAgentIntentsBatchDeleteCall {
42106	c := &ProjectsLocationsAgentIntentsBatchDeleteCall{s: r.s, urlParams_: make(gensupport.URLParams)}
42107	c.parent = parent
42108	c.googleclouddialogflowv2batchdeleteintentsrequest = googleclouddialogflowv2batchdeleteintentsrequest
42109	return c
42110}
42111
42112// Fields allows partial responses to be retrieved. See
42113// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
42114// for more information.
42115func (c *ProjectsLocationsAgentIntentsBatchDeleteCall) Fields(s ...googleapi.Field) *ProjectsLocationsAgentIntentsBatchDeleteCall {
42116	c.urlParams_.Set("fields", googleapi.CombineFields(s))
42117	return c
42118}
42119
42120// Context sets the context to be used in this call's Do method. Any
42121// pending HTTP request will be aborted if the provided context is
42122// canceled.
42123func (c *ProjectsLocationsAgentIntentsBatchDeleteCall) Context(ctx context.Context) *ProjectsLocationsAgentIntentsBatchDeleteCall {
42124	c.ctx_ = ctx
42125	return c
42126}
42127
42128// Header returns an http.Header that can be modified by the caller to
42129// add HTTP headers to the request.
42130func (c *ProjectsLocationsAgentIntentsBatchDeleteCall) Header() http.Header {
42131	if c.header_ == nil {
42132		c.header_ = make(http.Header)
42133	}
42134	return c.header_
42135}
42136
42137func (c *ProjectsLocationsAgentIntentsBatchDeleteCall) doRequest(alt string) (*http.Response, error) {
42138	reqHeaders := make(http.Header)
42139	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20211027")
42140	for k, v := range c.header_ {
42141		reqHeaders[k] = v
42142	}
42143	reqHeaders.Set("User-Agent", c.s.userAgent())
42144	var body io.Reader = nil
42145	body, err := googleapi.WithoutDataWrapper.JSONReader(c.googleclouddialogflowv2batchdeleteintentsrequest)
42146	if err != nil {
42147		return nil, err
42148	}
42149	reqHeaders.Set("Content-Type", "application/json")
42150	c.urlParams_.Set("alt", alt)
42151	c.urlParams_.Set("prettyPrint", "false")
42152	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+parent}/intents:batchDelete")
42153	urls += "?" + c.urlParams_.Encode()
42154	req, err := http.NewRequest("POST", urls, body)
42155	if err != nil {
42156		return nil, err
42157	}
42158	req.Header = reqHeaders
42159	googleapi.Expand(req.URL, map[string]string{
42160		"parent": c.parent,
42161	})
42162	return gensupport.SendRequest(c.ctx_, c.s.client, req)
42163}
42164
42165// Do executes the "dialogflow.projects.locations.agent.intents.batchDelete" call.
42166// Exactly one of *GoogleLongrunningOperation or error will be non-nil.
42167// Any non-2xx status code is an error. Response headers are in either
42168// *GoogleLongrunningOperation.ServerResponse.Header or (if a response
42169// was returned at all) in error.(*googleapi.Error).Header. Use
42170// googleapi.IsNotModified to check whether the returned error was
42171// because http.StatusNotModified was returned.
42172func (c *ProjectsLocationsAgentIntentsBatchDeleteCall) Do(opts ...googleapi.CallOption) (*GoogleLongrunningOperation, error) {
42173	gensupport.SetOptions(c.urlParams_, opts...)
42174	res, err := c.doRequest("json")
42175	if res != nil && res.StatusCode == http.StatusNotModified {
42176		if res.Body != nil {
42177			res.Body.Close()
42178		}
42179		return nil, &googleapi.Error{
42180			Code:   res.StatusCode,
42181			Header: res.Header,
42182		}
42183	}
42184	if err != nil {
42185		return nil, err
42186	}
42187	defer googleapi.CloseBody(res)
42188	if err := googleapi.CheckResponse(res); err != nil {
42189		return nil, err
42190	}
42191	ret := &GoogleLongrunningOperation{
42192		ServerResponse: googleapi.ServerResponse{
42193			Header:         res.Header,
42194			HTTPStatusCode: res.StatusCode,
42195		},
42196	}
42197	target := &ret
42198	if err := gensupport.DecodeResponse(target, res); err != nil {
42199		return nil, err
42200	}
42201	return ret, nil
42202	// {
42203	//   "description": "Deletes intents in the specified agent. This method is a [long-running operation](https://cloud.google.com/dialogflow/es/docs/how/long-running-operations). The returned `Operation` type has the following method-specific fields: - `metadata`: An empty [Struct message](https://developers.google.com/protocol-buffers/docs/reference/google.protobuf#struct) - `response`: An [Empty message](https://developers.google.com/protocol-buffers/docs/reference/google.protobuf#empty) Note: You should always train an agent prior to sending it queries. See the [training documentation](https://cloud.google.com/dialogflow/es/docs/training).",
42204	//   "flatPath": "v2/projects/{projectsId}/locations/{locationsId}/agent/intents:batchDelete",
42205	//   "httpMethod": "POST",
42206	//   "id": "dialogflow.projects.locations.agent.intents.batchDelete",
42207	//   "parameterOrder": [
42208	//     "parent"
42209	//   ],
42210	//   "parameters": {
42211	//     "parent": {
42212	//       "description": "Required. The name of the agent to delete all entities types for. Format: `projects//agent`.",
42213	//       "location": "path",
42214	//       "pattern": "^projects/[^/]+/locations/[^/]+/agent$",
42215	//       "required": true,
42216	//       "type": "string"
42217	//     }
42218	//   },
42219	//   "path": "v2/{+parent}/intents:batchDelete",
42220	//   "request": {
42221	//     "$ref": "GoogleCloudDialogflowV2BatchDeleteIntentsRequest"
42222	//   },
42223	//   "response": {
42224	//     "$ref": "GoogleLongrunningOperation"
42225	//   },
42226	//   "scopes": [
42227	//     "https://www.googleapis.com/auth/cloud-platform",
42228	//     "https://www.googleapis.com/auth/dialogflow"
42229	//   ]
42230	// }
42231
42232}
42233
42234// method id "dialogflow.projects.locations.agent.intents.batchUpdate":
42235
42236type ProjectsLocationsAgentIntentsBatchUpdateCall struct {
42237	s                                                *Service
42238	parent                                           string
42239	googleclouddialogflowv2batchupdateintentsrequest *GoogleCloudDialogflowV2BatchUpdateIntentsRequest
42240	urlParams_                                       gensupport.URLParams
42241	ctx_                                             context.Context
42242	header_                                          http.Header
42243}
42244
42245// BatchUpdate: Updates/Creates multiple intents in the specified agent.
42246// This method is a long-running operation
42247// (https://cloud.google.com/dialogflow/es/docs/how/long-running-operations).
42248// The returned `Operation` type has the following method-specific
42249// fields: - `metadata`: An empty Struct message
42250// (https://developers.google.com/protocol-buffers/docs/reference/google.protobuf#struct)
42251// - `response`: BatchUpdateIntentsResponse Note: You should always
42252// train an agent prior to sending it queries. See the training
42253// documentation (https://cloud.google.com/dialogflow/es/docs/training).
42254//
42255// - parent: The name of the agent to update or create intents in.
42256//   Format: `projects//agent`.
42257func (r *ProjectsLocationsAgentIntentsService) BatchUpdate(parent string, googleclouddialogflowv2batchupdateintentsrequest *GoogleCloudDialogflowV2BatchUpdateIntentsRequest) *ProjectsLocationsAgentIntentsBatchUpdateCall {
42258	c := &ProjectsLocationsAgentIntentsBatchUpdateCall{s: r.s, urlParams_: make(gensupport.URLParams)}
42259	c.parent = parent
42260	c.googleclouddialogflowv2batchupdateintentsrequest = googleclouddialogflowv2batchupdateintentsrequest
42261	return c
42262}
42263
42264// Fields allows partial responses to be retrieved. See
42265// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
42266// for more information.
42267func (c *ProjectsLocationsAgentIntentsBatchUpdateCall) Fields(s ...googleapi.Field) *ProjectsLocationsAgentIntentsBatchUpdateCall {
42268	c.urlParams_.Set("fields", googleapi.CombineFields(s))
42269	return c
42270}
42271
42272// Context sets the context to be used in this call's Do method. Any
42273// pending HTTP request will be aborted if the provided context is
42274// canceled.
42275func (c *ProjectsLocationsAgentIntentsBatchUpdateCall) Context(ctx context.Context) *ProjectsLocationsAgentIntentsBatchUpdateCall {
42276	c.ctx_ = ctx
42277	return c
42278}
42279
42280// Header returns an http.Header that can be modified by the caller to
42281// add HTTP headers to the request.
42282func (c *ProjectsLocationsAgentIntentsBatchUpdateCall) Header() http.Header {
42283	if c.header_ == nil {
42284		c.header_ = make(http.Header)
42285	}
42286	return c.header_
42287}
42288
42289func (c *ProjectsLocationsAgentIntentsBatchUpdateCall) doRequest(alt string) (*http.Response, error) {
42290	reqHeaders := make(http.Header)
42291	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20211027")
42292	for k, v := range c.header_ {
42293		reqHeaders[k] = v
42294	}
42295	reqHeaders.Set("User-Agent", c.s.userAgent())
42296	var body io.Reader = nil
42297	body, err := googleapi.WithoutDataWrapper.JSONReader(c.googleclouddialogflowv2batchupdateintentsrequest)
42298	if err != nil {
42299		return nil, err
42300	}
42301	reqHeaders.Set("Content-Type", "application/json")
42302	c.urlParams_.Set("alt", alt)
42303	c.urlParams_.Set("prettyPrint", "false")
42304	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+parent}/intents:batchUpdate")
42305	urls += "?" + c.urlParams_.Encode()
42306	req, err := http.NewRequest("POST", urls, body)
42307	if err != nil {
42308		return nil, err
42309	}
42310	req.Header = reqHeaders
42311	googleapi.Expand(req.URL, map[string]string{
42312		"parent": c.parent,
42313	})
42314	return gensupport.SendRequest(c.ctx_, c.s.client, req)
42315}
42316
42317// Do executes the "dialogflow.projects.locations.agent.intents.batchUpdate" call.
42318// Exactly one of *GoogleLongrunningOperation or error will be non-nil.
42319// Any non-2xx status code is an error. Response headers are in either
42320// *GoogleLongrunningOperation.ServerResponse.Header or (if a response
42321// was returned at all) in error.(*googleapi.Error).Header. Use
42322// googleapi.IsNotModified to check whether the returned error was
42323// because http.StatusNotModified was returned.
42324func (c *ProjectsLocationsAgentIntentsBatchUpdateCall) Do(opts ...googleapi.CallOption) (*GoogleLongrunningOperation, error) {
42325	gensupport.SetOptions(c.urlParams_, opts...)
42326	res, err := c.doRequest("json")
42327	if res != nil && res.StatusCode == http.StatusNotModified {
42328		if res.Body != nil {
42329			res.Body.Close()
42330		}
42331		return nil, &googleapi.Error{
42332			Code:   res.StatusCode,
42333			Header: res.Header,
42334		}
42335	}
42336	if err != nil {
42337		return nil, err
42338	}
42339	defer googleapi.CloseBody(res)
42340	if err := googleapi.CheckResponse(res); err != nil {
42341		return nil, err
42342	}
42343	ret := &GoogleLongrunningOperation{
42344		ServerResponse: googleapi.ServerResponse{
42345			Header:         res.Header,
42346			HTTPStatusCode: res.StatusCode,
42347		},
42348	}
42349	target := &ret
42350	if err := gensupport.DecodeResponse(target, res); err != nil {
42351		return nil, err
42352	}
42353	return ret, nil
42354	// {
42355	//   "description": "Updates/Creates multiple intents in the specified agent. This method is a [long-running operation](https://cloud.google.com/dialogflow/es/docs/how/long-running-operations). The returned `Operation` type has the following method-specific fields: - `metadata`: An empty [Struct message](https://developers.google.com/protocol-buffers/docs/reference/google.protobuf#struct) - `response`: BatchUpdateIntentsResponse Note: You should always train an agent prior to sending it queries. See the [training documentation](https://cloud.google.com/dialogflow/es/docs/training).",
42356	//   "flatPath": "v2/projects/{projectsId}/locations/{locationsId}/agent/intents:batchUpdate",
42357	//   "httpMethod": "POST",
42358	//   "id": "dialogflow.projects.locations.agent.intents.batchUpdate",
42359	//   "parameterOrder": [
42360	//     "parent"
42361	//   ],
42362	//   "parameters": {
42363	//     "parent": {
42364	//       "description": "Required. The name of the agent to update or create intents in. Format: `projects//agent`.",
42365	//       "location": "path",
42366	//       "pattern": "^projects/[^/]+/locations/[^/]+/agent$",
42367	//       "required": true,
42368	//       "type": "string"
42369	//     }
42370	//   },
42371	//   "path": "v2/{+parent}/intents:batchUpdate",
42372	//   "request": {
42373	//     "$ref": "GoogleCloudDialogflowV2BatchUpdateIntentsRequest"
42374	//   },
42375	//   "response": {
42376	//     "$ref": "GoogleLongrunningOperation"
42377	//   },
42378	//   "scopes": [
42379	//     "https://www.googleapis.com/auth/cloud-platform",
42380	//     "https://www.googleapis.com/auth/dialogflow"
42381	//   ]
42382	// }
42383
42384}
42385
42386// method id "dialogflow.projects.locations.agent.intents.create":
42387
42388type ProjectsLocationsAgentIntentsCreateCall struct {
42389	s                             *Service
42390	parent                        string
42391	googleclouddialogflowv2intent *GoogleCloudDialogflowV2Intent
42392	urlParams_                    gensupport.URLParams
42393	ctx_                          context.Context
42394	header_                       http.Header
42395}
42396
42397// Create: Creates an intent in the specified agent. Note: You should
42398// always train an agent prior to sending it queries. See the training
42399// documentation (https://cloud.google.com/dialogflow/es/docs/training).
42400//
42401// - parent: The agent to create a intent for. Format:
42402//   `projects//agent`.
42403func (r *ProjectsLocationsAgentIntentsService) Create(parent string, googleclouddialogflowv2intent *GoogleCloudDialogflowV2Intent) *ProjectsLocationsAgentIntentsCreateCall {
42404	c := &ProjectsLocationsAgentIntentsCreateCall{s: r.s, urlParams_: make(gensupport.URLParams)}
42405	c.parent = parent
42406	c.googleclouddialogflowv2intent = googleclouddialogflowv2intent
42407	return c
42408}
42409
42410// IntentView sets the optional parameter "intentView": The resource
42411// view to apply to the returned intent.
42412//
42413// Possible values:
42414//   "INTENT_VIEW_UNSPECIFIED" - Training phrases field is not populated
42415// in the response.
42416//   "INTENT_VIEW_FULL" - All fields are populated.
42417func (c *ProjectsLocationsAgentIntentsCreateCall) IntentView(intentView string) *ProjectsLocationsAgentIntentsCreateCall {
42418	c.urlParams_.Set("intentView", intentView)
42419	return c
42420}
42421
42422// LanguageCode sets the optional parameter "languageCode": The language
42423// used to access language-specific data. If not specified, the agent's
42424// default language is used. For more information, see Multilingual
42425// intent and entity data
42426// (https://cloud.google.com/dialogflow/docs/agents-multilingual#intent-entity).
42427func (c *ProjectsLocationsAgentIntentsCreateCall) LanguageCode(languageCode string) *ProjectsLocationsAgentIntentsCreateCall {
42428	c.urlParams_.Set("languageCode", languageCode)
42429	return c
42430}
42431
42432// Fields allows partial responses to be retrieved. See
42433// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
42434// for more information.
42435func (c *ProjectsLocationsAgentIntentsCreateCall) Fields(s ...googleapi.Field) *ProjectsLocationsAgentIntentsCreateCall {
42436	c.urlParams_.Set("fields", googleapi.CombineFields(s))
42437	return c
42438}
42439
42440// Context sets the context to be used in this call's Do method. Any
42441// pending HTTP request will be aborted if the provided context is
42442// canceled.
42443func (c *ProjectsLocationsAgentIntentsCreateCall) Context(ctx context.Context) *ProjectsLocationsAgentIntentsCreateCall {
42444	c.ctx_ = ctx
42445	return c
42446}
42447
42448// Header returns an http.Header that can be modified by the caller to
42449// add HTTP headers to the request.
42450func (c *ProjectsLocationsAgentIntentsCreateCall) Header() http.Header {
42451	if c.header_ == nil {
42452		c.header_ = make(http.Header)
42453	}
42454	return c.header_
42455}
42456
42457func (c *ProjectsLocationsAgentIntentsCreateCall) doRequest(alt string) (*http.Response, error) {
42458	reqHeaders := make(http.Header)
42459	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20211027")
42460	for k, v := range c.header_ {
42461		reqHeaders[k] = v
42462	}
42463	reqHeaders.Set("User-Agent", c.s.userAgent())
42464	var body io.Reader = nil
42465	body, err := googleapi.WithoutDataWrapper.JSONReader(c.googleclouddialogflowv2intent)
42466	if err != nil {
42467		return nil, err
42468	}
42469	reqHeaders.Set("Content-Type", "application/json")
42470	c.urlParams_.Set("alt", alt)
42471	c.urlParams_.Set("prettyPrint", "false")
42472	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+parent}/intents")
42473	urls += "?" + c.urlParams_.Encode()
42474	req, err := http.NewRequest("POST", urls, body)
42475	if err != nil {
42476		return nil, err
42477	}
42478	req.Header = reqHeaders
42479	googleapi.Expand(req.URL, map[string]string{
42480		"parent": c.parent,
42481	})
42482	return gensupport.SendRequest(c.ctx_, c.s.client, req)
42483}
42484
42485// Do executes the "dialogflow.projects.locations.agent.intents.create" call.
42486// Exactly one of *GoogleCloudDialogflowV2Intent or error will be
42487// non-nil. Any non-2xx status code is an error. Response headers are in
42488// either *GoogleCloudDialogflowV2Intent.ServerResponse.Header or (if a
42489// response was returned at all) in error.(*googleapi.Error).Header. Use
42490// googleapi.IsNotModified to check whether the returned error was
42491// because http.StatusNotModified was returned.
42492func (c *ProjectsLocationsAgentIntentsCreateCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDialogflowV2Intent, error) {
42493	gensupport.SetOptions(c.urlParams_, opts...)
42494	res, err := c.doRequest("json")
42495	if res != nil && res.StatusCode == http.StatusNotModified {
42496		if res.Body != nil {
42497			res.Body.Close()
42498		}
42499		return nil, &googleapi.Error{
42500			Code:   res.StatusCode,
42501			Header: res.Header,
42502		}
42503	}
42504	if err != nil {
42505		return nil, err
42506	}
42507	defer googleapi.CloseBody(res)
42508	if err := googleapi.CheckResponse(res); err != nil {
42509		return nil, err
42510	}
42511	ret := &GoogleCloudDialogflowV2Intent{
42512		ServerResponse: googleapi.ServerResponse{
42513			Header:         res.Header,
42514			HTTPStatusCode: res.StatusCode,
42515		},
42516	}
42517	target := &ret
42518	if err := gensupport.DecodeResponse(target, res); err != nil {
42519		return nil, err
42520	}
42521	return ret, nil
42522	// {
42523	//   "description": "Creates an intent in the specified agent. Note: You should always train an agent prior to sending it queries. See the [training documentation](https://cloud.google.com/dialogflow/es/docs/training).",
42524	//   "flatPath": "v2/projects/{projectsId}/locations/{locationsId}/agent/intents",
42525	//   "httpMethod": "POST",
42526	//   "id": "dialogflow.projects.locations.agent.intents.create",
42527	//   "parameterOrder": [
42528	//     "parent"
42529	//   ],
42530	//   "parameters": {
42531	//     "intentView": {
42532	//       "description": "Optional. The resource view to apply to the returned intent.",
42533	//       "enum": [
42534	//         "INTENT_VIEW_UNSPECIFIED",
42535	//         "INTENT_VIEW_FULL"
42536	//       ],
42537	//       "enumDescriptions": [
42538	//         "Training phrases field is not populated in the response.",
42539	//         "All fields are populated."
42540	//       ],
42541	//       "location": "query",
42542	//       "type": "string"
42543	//     },
42544	//     "languageCode": {
42545	//       "description": "Optional. The language used to access language-specific data. If not specified, the agent's default language is used. For more information, see [Multilingual intent and entity data](https://cloud.google.com/dialogflow/docs/agents-multilingual#intent-entity).",
42546	//       "location": "query",
42547	//       "type": "string"
42548	//     },
42549	//     "parent": {
42550	//       "description": "Required. The agent to create a intent for. Format: `projects//agent`.",
42551	//       "location": "path",
42552	//       "pattern": "^projects/[^/]+/locations/[^/]+/agent$",
42553	//       "required": true,
42554	//       "type": "string"
42555	//     }
42556	//   },
42557	//   "path": "v2/{+parent}/intents",
42558	//   "request": {
42559	//     "$ref": "GoogleCloudDialogflowV2Intent"
42560	//   },
42561	//   "response": {
42562	//     "$ref": "GoogleCloudDialogflowV2Intent"
42563	//   },
42564	//   "scopes": [
42565	//     "https://www.googleapis.com/auth/cloud-platform",
42566	//     "https://www.googleapis.com/auth/dialogflow"
42567	//   ]
42568	// }
42569
42570}
42571
42572// method id "dialogflow.projects.locations.agent.intents.delete":
42573
42574type ProjectsLocationsAgentIntentsDeleteCall struct {
42575	s          *Service
42576	name       string
42577	urlParams_ gensupport.URLParams
42578	ctx_       context.Context
42579	header_    http.Header
42580}
42581
42582// Delete: Deletes the specified intent and its direct or indirect
42583// followup intents. Note: You should always train an agent prior to
42584// sending it queries. See the training documentation
42585// (https://cloud.google.com/dialogflow/es/docs/training).
42586//
42587// - name: The name of the intent to delete. If this intent has direct
42588//   or indirect followup intents, we also delete them. Format:
42589//   `projects//agent/intents/`.
42590func (r *ProjectsLocationsAgentIntentsService) Delete(name string) *ProjectsLocationsAgentIntentsDeleteCall {
42591	c := &ProjectsLocationsAgentIntentsDeleteCall{s: r.s, urlParams_: make(gensupport.URLParams)}
42592	c.name = name
42593	return c
42594}
42595
42596// Fields allows partial responses to be retrieved. See
42597// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
42598// for more information.
42599func (c *ProjectsLocationsAgentIntentsDeleteCall) Fields(s ...googleapi.Field) *ProjectsLocationsAgentIntentsDeleteCall {
42600	c.urlParams_.Set("fields", googleapi.CombineFields(s))
42601	return c
42602}
42603
42604// Context sets the context to be used in this call's Do method. Any
42605// pending HTTP request will be aborted if the provided context is
42606// canceled.
42607func (c *ProjectsLocationsAgentIntentsDeleteCall) Context(ctx context.Context) *ProjectsLocationsAgentIntentsDeleteCall {
42608	c.ctx_ = ctx
42609	return c
42610}
42611
42612// Header returns an http.Header that can be modified by the caller to
42613// add HTTP headers to the request.
42614func (c *ProjectsLocationsAgentIntentsDeleteCall) Header() http.Header {
42615	if c.header_ == nil {
42616		c.header_ = make(http.Header)
42617	}
42618	return c.header_
42619}
42620
42621func (c *ProjectsLocationsAgentIntentsDeleteCall) doRequest(alt string) (*http.Response, error) {
42622	reqHeaders := make(http.Header)
42623	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20211027")
42624	for k, v := range c.header_ {
42625		reqHeaders[k] = v
42626	}
42627	reqHeaders.Set("User-Agent", c.s.userAgent())
42628	var body io.Reader = nil
42629	c.urlParams_.Set("alt", alt)
42630	c.urlParams_.Set("prettyPrint", "false")
42631	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+name}")
42632	urls += "?" + c.urlParams_.Encode()
42633	req, err := http.NewRequest("DELETE", urls, body)
42634	if err != nil {
42635		return nil, err
42636	}
42637	req.Header = reqHeaders
42638	googleapi.Expand(req.URL, map[string]string{
42639		"name": c.name,
42640	})
42641	return gensupport.SendRequest(c.ctx_, c.s.client, req)
42642}
42643
42644// Do executes the "dialogflow.projects.locations.agent.intents.delete" call.
42645// Exactly one of *GoogleProtobufEmpty or error will be non-nil. Any
42646// non-2xx status code is an error. Response headers are in either
42647// *GoogleProtobufEmpty.ServerResponse.Header or (if a response was
42648// returned at all) in error.(*googleapi.Error).Header. Use
42649// googleapi.IsNotModified to check whether the returned error was
42650// because http.StatusNotModified was returned.
42651func (c *ProjectsLocationsAgentIntentsDeleteCall) Do(opts ...googleapi.CallOption) (*GoogleProtobufEmpty, error) {
42652	gensupport.SetOptions(c.urlParams_, opts...)
42653	res, err := c.doRequest("json")
42654	if res != nil && res.StatusCode == http.StatusNotModified {
42655		if res.Body != nil {
42656			res.Body.Close()
42657		}
42658		return nil, &googleapi.Error{
42659			Code:   res.StatusCode,
42660			Header: res.Header,
42661		}
42662	}
42663	if err != nil {
42664		return nil, err
42665	}
42666	defer googleapi.CloseBody(res)
42667	if err := googleapi.CheckResponse(res); err != nil {
42668		return nil, err
42669	}
42670	ret := &GoogleProtobufEmpty{
42671		ServerResponse: googleapi.ServerResponse{
42672			Header:         res.Header,
42673			HTTPStatusCode: res.StatusCode,
42674		},
42675	}
42676	target := &ret
42677	if err := gensupport.DecodeResponse(target, res); err != nil {
42678		return nil, err
42679	}
42680	return ret, nil
42681	// {
42682	//   "description": "Deletes the specified intent and its direct or indirect followup intents. Note: You should always train an agent prior to sending it queries. See the [training documentation](https://cloud.google.com/dialogflow/es/docs/training).",
42683	//   "flatPath": "v2/projects/{projectsId}/locations/{locationsId}/agent/intents/{intentsId}",
42684	//   "httpMethod": "DELETE",
42685	//   "id": "dialogflow.projects.locations.agent.intents.delete",
42686	//   "parameterOrder": [
42687	//     "name"
42688	//   ],
42689	//   "parameters": {
42690	//     "name": {
42691	//       "description": "Required. The name of the intent to delete. If this intent has direct or indirect followup intents, we also delete them. Format: `projects//agent/intents/`.",
42692	//       "location": "path",
42693	//       "pattern": "^projects/[^/]+/locations/[^/]+/agent/intents/[^/]+$",
42694	//       "required": true,
42695	//       "type": "string"
42696	//     }
42697	//   },
42698	//   "path": "v2/{+name}",
42699	//   "response": {
42700	//     "$ref": "GoogleProtobufEmpty"
42701	//   },
42702	//   "scopes": [
42703	//     "https://www.googleapis.com/auth/cloud-platform",
42704	//     "https://www.googleapis.com/auth/dialogflow"
42705	//   ]
42706	// }
42707
42708}
42709
42710// method id "dialogflow.projects.locations.agent.intents.get":
42711
42712type ProjectsLocationsAgentIntentsGetCall struct {
42713	s            *Service
42714	name         string
42715	urlParams_   gensupport.URLParams
42716	ifNoneMatch_ string
42717	ctx_         context.Context
42718	header_      http.Header
42719}
42720
42721// Get: Retrieves the specified intent.
42722//
42723// - name: The name of the intent. Format: `projects//agent/intents/`.
42724func (r *ProjectsLocationsAgentIntentsService) Get(name string) *ProjectsLocationsAgentIntentsGetCall {
42725	c := &ProjectsLocationsAgentIntentsGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
42726	c.name = name
42727	return c
42728}
42729
42730// IntentView sets the optional parameter "intentView": The resource
42731// view to apply to the returned intent.
42732//
42733// Possible values:
42734//   "INTENT_VIEW_UNSPECIFIED" - Training phrases field is not populated
42735// in the response.
42736//   "INTENT_VIEW_FULL" - All fields are populated.
42737func (c *ProjectsLocationsAgentIntentsGetCall) IntentView(intentView string) *ProjectsLocationsAgentIntentsGetCall {
42738	c.urlParams_.Set("intentView", intentView)
42739	return c
42740}
42741
42742// LanguageCode sets the optional parameter "languageCode": The language
42743// used to access language-specific data. If not specified, the agent's
42744// default language is used. For more information, see Multilingual
42745// intent and entity data
42746// (https://cloud.google.com/dialogflow/docs/agents-multilingual#intent-entity).
42747func (c *ProjectsLocationsAgentIntentsGetCall) LanguageCode(languageCode string) *ProjectsLocationsAgentIntentsGetCall {
42748	c.urlParams_.Set("languageCode", languageCode)
42749	return c
42750}
42751
42752// Fields allows partial responses to be retrieved. See
42753// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
42754// for more information.
42755func (c *ProjectsLocationsAgentIntentsGetCall) Fields(s ...googleapi.Field) *ProjectsLocationsAgentIntentsGetCall {
42756	c.urlParams_.Set("fields", googleapi.CombineFields(s))
42757	return c
42758}
42759
42760// IfNoneMatch sets the optional parameter which makes the operation
42761// fail if the object's ETag matches the given value. This is useful for
42762// getting updates only after the object has changed since the last
42763// request. Use googleapi.IsNotModified to check whether the response
42764// error from Do is the result of In-None-Match.
42765func (c *ProjectsLocationsAgentIntentsGetCall) IfNoneMatch(entityTag string) *ProjectsLocationsAgentIntentsGetCall {
42766	c.ifNoneMatch_ = entityTag
42767	return c
42768}
42769
42770// Context sets the context to be used in this call's Do method. Any
42771// pending HTTP request will be aborted if the provided context is
42772// canceled.
42773func (c *ProjectsLocationsAgentIntentsGetCall) Context(ctx context.Context) *ProjectsLocationsAgentIntentsGetCall {
42774	c.ctx_ = ctx
42775	return c
42776}
42777
42778// Header returns an http.Header that can be modified by the caller to
42779// add HTTP headers to the request.
42780func (c *ProjectsLocationsAgentIntentsGetCall) Header() http.Header {
42781	if c.header_ == nil {
42782		c.header_ = make(http.Header)
42783	}
42784	return c.header_
42785}
42786
42787func (c *ProjectsLocationsAgentIntentsGetCall) doRequest(alt string) (*http.Response, error) {
42788	reqHeaders := make(http.Header)
42789	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20211027")
42790	for k, v := range c.header_ {
42791		reqHeaders[k] = v
42792	}
42793	reqHeaders.Set("User-Agent", c.s.userAgent())
42794	if c.ifNoneMatch_ != "" {
42795		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
42796	}
42797	var body io.Reader = nil
42798	c.urlParams_.Set("alt", alt)
42799	c.urlParams_.Set("prettyPrint", "false")
42800	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+name}")
42801	urls += "?" + c.urlParams_.Encode()
42802	req, err := http.NewRequest("GET", urls, body)
42803	if err != nil {
42804		return nil, err
42805	}
42806	req.Header = reqHeaders
42807	googleapi.Expand(req.URL, map[string]string{
42808		"name": c.name,
42809	})
42810	return gensupport.SendRequest(c.ctx_, c.s.client, req)
42811}
42812
42813// Do executes the "dialogflow.projects.locations.agent.intents.get" call.
42814// Exactly one of *GoogleCloudDialogflowV2Intent or error will be
42815// non-nil. Any non-2xx status code is an error. Response headers are in
42816// either *GoogleCloudDialogflowV2Intent.ServerResponse.Header or (if a
42817// response was returned at all) in error.(*googleapi.Error).Header. Use
42818// googleapi.IsNotModified to check whether the returned error was
42819// because http.StatusNotModified was returned.
42820func (c *ProjectsLocationsAgentIntentsGetCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDialogflowV2Intent, error) {
42821	gensupport.SetOptions(c.urlParams_, opts...)
42822	res, err := c.doRequest("json")
42823	if res != nil && res.StatusCode == http.StatusNotModified {
42824		if res.Body != nil {
42825			res.Body.Close()
42826		}
42827		return nil, &googleapi.Error{
42828			Code:   res.StatusCode,
42829			Header: res.Header,
42830		}
42831	}
42832	if err != nil {
42833		return nil, err
42834	}
42835	defer googleapi.CloseBody(res)
42836	if err := googleapi.CheckResponse(res); err != nil {
42837		return nil, err
42838	}
42839	ret := &GoogleCloudDialogflowV2Intent{
42840		ServerResponse: googleapi.ServerResponse{
42841			Header:         res.Header,
42842			HTTPStatusCode: res.StatusCode,
42843		},
42844	}
42845	target := &ret
42846	if err := gensupport.DecodeResponse(target, res); err != nil {
42847		return nil, err
42848	}
42849	return ret, nil
42850	// {
42851	//   "description": "Retrieves the specified intent.",
42852	//   "flatPath": "v2/projects/{projectsId}/locations/{locationsId}/agent/intents/{intentsId}",
42853	//   "httpMethod": "GET",
42854	//   "id": "dialogflow.projects.locations.agent.intents.get",
42855	//   "parameterOrder": [
42856	//     "name"
42857	//   ],
42858	//   "parameters": {
42859	//     "intentView": {
42860	//       "description": "Optional. The resource view to apply to the returned intent.",
42861	//       "enum": [
42862	//         "INTENT_VIEW_UNSPECIFIED",
42863	//         "INTENT_VIEW_FULL"
42864	//       ],
42865	//       "enumDescriptions": [
42866	//         "Training phrases field is not populated in the response.",
42867	//         "All fields are populated."
42868	//       ],
42869	//       "location": "query",
42870	//       "type": "string"
42871	//     },
42872	//     "languageCode": {
42873	//       "description": "Optional. The language used to access language-specific data. If not specified, the agent's default language is used. For more information, see [Multilingual intent and entity data](https://cloud.google.com/dialogflow/docs/agents-multilingual#intent-entity).",
42874	//       "location": "query",
42875	//       "type": "string"
42876	//     },
42877	//     "name": {
42878	//       "description": "Required. The name of the intent. Format: `projects//agent/intents/`.",
42879	//       "location": "path",
42880	//       "pattern": "^projects/[^/]+/locations/[^/]+/agent/intents/[^/]+$",
42881	//       "required": true,
42882	//       "type": "string"
42883	//     }
42884	//   },
42885	//   "path": "v2/{+name}",
42886	//   "response": {
42887	//     "$ref": "GoogleCloudDialogflowV2Intent"
42888	//   },
42889	//   "scopes": [
42890	//     "https://www.googleapis.com/auth/cloud-platform",
42891	//     "https://www.googleapis.com/auth/dialogflow"
42892	//   ]
42893	// }
42894
42895}
42896
42897// method id "dialogflow.projects.locations.agent.intents.list":
42898
42899type ProjectsLocationsAgentIntentsListCall struct {
42900	s            *Service
42901	parent       string
42902	urlParams_   gensupport.URLParams
42903	ifNoneMatch_ string
42904	ctx_         context.Context
42905	header_      http.Header
42906}
42907
42908// List: Returns the list of all intents in the specified agent.
42909//
42910// - parent: The agent to list all intents from. Format:
42911//   `projects//agent` or `projects//locations//agent`. Alternatively,
42912//   you can specify the environment to list intents for. Format:
42913//   `projects//agent/environments/` or
42914//   `projects//locations//agent/environments/`. Note: training phrases
42915//   of the intents will not be returned for non-draft environment.
42916func (r *ProjectsLocationsAgentIntentsService) List(parent string) *ProjectsLocationsAgentIntentsListCall {
42917	c := &ProjectsLocationsAgentIntentsListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
42918	c.parent = parent
42919	return c
42920}
42921
42922// IntentView sets the optional parameter "intentView": The resource
42923// view to apply to the returned intent.
42924//
42925// Possible values:
42926//   "INTENT_VIEW_UNSPECIFIED" - Training phrases field is not populated
42927// in the response.
42928//   "INTENT_VIEW_FULL" - All fields are populated.
42929func (c *ProjectsLocationsAgentIntentsListCall) IntentView(intentView string) *ProjectsLocationsAgentIntentsListCall {
42930	c.urlParams_.Set("intentView", intentView)
42931	return c
42932}
42933
42934// LanguageCode sets the optional parameter "languageCode": The language
42935// used to access language-specific data. If not specified, the agent's
42936// default language is used. For more information, see Multilingual
42937// intent and entity data
42938// (https://cloud.google.com/dialogflow/docs/agents-multilingual#intent-entity).
42939func (c *ProjectsLocationsAgentIntentsListCall) LanguageCode(languageCode string) *ProjectsLocationsAgentIntentsListCall {
42940	c.urlParams_.Set("languageCode", languageCode)
42941	return c
42942}
42943
42944// PageSize sets the optional parameter "pageSize": The maximum number
42945// of items to return in a single page. By default 100 and at most 1000.
42946func (c *ProjectsLocationsAgentIntentsListCall) PageSize(pageSize int64) *ProjectsLocationsAgentIntentsListCall {
42947	c.urlParams_.Set("pageSize", fmt.Sprint(pageSize))
42948	return c
42949}
42950
42951// PageToken sets the optional parameter "pageToken": The
42952// next_page_token value returned from a previous list request.
42953func (c *ProjectsLocationsAgentIntentsListCall) PageToken(pageToken string) *ProjectsLocationsAgentIntentsListCall {
42954	c.urlParams_.Set("pageToken", pageToken)
42955	return c
42956}
42957
42958// Fields allows partial responses to be retrieved. See
42959// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
42960// for more information.
42961func (c *ProjectsLocationsAgentIntentsListCall) Fields(s ...googleapi.Field) *ProjectsLocationsAgentIntentsListCall {
42962	c.urlParams_.Set("fields", googleapi.CombineFields(s))
42963	return c
42964}
42965
42966// IfNoneMatch sets the optional parameter which makes the operation
42967// fail if the object's ETag matches the given value. This is useful for
42968// getting updates only after the object has changed since the last
42969// request. Use googleapi.IsNotModified to check whether the response
42970// error from Do is the result of In-None-Match.
42971func (c *ProjectsLocationsAgentIntentsListCall) IfNoneMatch(entityTag string) *ProjectsLocationsAgentIntentsListCall {
42972	c.ifNoneMatch_ = entityTag
42973	return c
42974}
42975
42976// Context sets the context to be used in this call's Do method. Any
42977// pending HTTP request will be aborted if the provided context is
42978// canceled.
42979func (c *ProjectsLocationsAgentIntentsListCall) Context(ctx context.Context) *ProjectsLocationsAgentIntentsListCall {
42980	c.ctx_ = ctx
42981	return c
42982}
42983
42984// Header returns an http.Header that can be modified by the caller to
42985// add HTTP headers to the request.
42986func (c *ProjectsLocationsAgentIntentsListCall) Header() http.Header {
42987	if c.header_ == nil {
42988		c.header_ = make(http.Header)
42989	}
42990	return c.header_
42991}
42992
42993func (c *ProjectsLocationsAgentIntentsListCall) doRequest(alt string) (*http.Response, error) {
42994	reqHeaders := make(http.Header)
42995	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20211027")
42996	for k, v := range c.header_ {
42997		reqHeaders[k] = v
42998	}
42999	reqHeaders.Set("User-Agent", c.s.userAgent())
43000	if c.ifNoneMatch_ != "" {
43001		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
43002	}
43003	var body io.Reader = nil
43004	c.urlParams_.Set("alt", alt)
43005	c.urlParams_.Set("prettyPrint", "false")
43006	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+parent}/intents")
43007	urls += "?" + c.urlParams_.Encode()
43008	req, err := http.NewRequest("GET", urls, body)
43009	if err != nil {
43010		return nil, err
43011	}
43012	req.Header = reqHeaders
43013	googleapi.Expand(req.URL, map[string]string{
43014		"parent": c.parent,
43015	})
43016	return gensupport.SendRequest(c.ctx_, c.s.client, req)
43017}
43018
43019// Do executes the "dialogflow.projects.locations.agent.intents.list" call.
43020// Exactly one of *GoogleCloudDialogflowV2ListIntentsResponse or error
43021// will be non-nil. Any non-2xx status code is an error. Response
43022// headers are in either
43023// *GoogleCloudDialogflowV2ListIntentsResponse.ServerResponse.Header or
43024// (if a response was returned at all) in
43025// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
43026// whether the returned error was because http.StatusNotModified was
43027// returned.
43028func (c *ProjectsLocationsAgentIntentsListCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDialogflowV2ListIntentsResponse, error) {
43029	gensupport.SetOptions(c.urlParams_, opts...)
43030	res, err := c.doRequest("json")
43031	if res != nil && res.StatusCode == http.StatusNotModified {
43032		if res.Body != nil {
43033			res.Body.Close()
43034		}
43035		return nil, &googleapi.Error{
43036			Code:   res.StatusCode,
43037			Header: res.Header,
43038		}
43039	}
43040	if err != nil {
43041		return nil, err
43042	}
43043	defer googleapi.CloseBody(res)
43044	if err := googleapi.CheckResponse(res); err != nil {
43045		return nil, err
43046	}
43047	ret := &GoogleCloudDialogflowV2ListIntentsResponse{
43048		ServerResponse: googleapi.ServerResponse{
43049			Header:         res.Header,
43050			HTTPStatusCode: res.StatusCode,
43051		},
43052	}
43053	target := &ret
43054	if err := gensupport.DecodeResponse(target, res); err != nil {
43055		return nil, err
43056	}
43057	return ret, nil
43058	// {
43059	//   "description": "Returns the list of all intents in the specified agent.",
43060	//   "flatPath": "v2/projects/{projectsId}/locations/{locationsId}/agent/intents",
43061	//   "httpMethod": "GET",
43062	//   "id": "dialogflow.projects.locations.agent.intents.list",
43063	//   "parameterOrder": [
43064	//     "parent"
43065	//   ],
43066	//   "parameters": {
43067	//     "intentView": {
43068	//       "description": "Optional. The resource view to apply to the returned intent.",
43069	//       "enum": [
43070	//         "INTENT_VIEW_UNSPECIFIED",
43071	//         "INTENT_VIEW_FULL"
43072	//       ],
43073	//       "enumDescriptions": [
43074	//         "Training phrases field is not populated in the response.",
43075	//         "All fields are populated."
43076	//       ],
43077	//       "location": "query",
43078	//       "type": "string"
43079	//     },
43080	//     "languageCode": {
43081	//       "description": "Optional. The language used to access language-specific data. If not specified, the agent's default language is used. For more information, see [Multilingual intent and entity data](https://cloud.google.com/dialogflow/docs/agents-multilingual#intent-entity).",
43082	//       "location": "query",
43083	//       "type": "string"
43084	//     },
43085	//     "pageSize": {
43086	//       "description": "Optional. The maximum number of items to return in a single page. By default 100 and at most 1000.",
43087	//       "format": "int32",
43088	//       "location": "query",
43089	//       "type": "integer"
43090	//     },
43091	//     "pageToken": {
43092	//       "description": "Optional. The next_page_token value returned from a previous list request.",
43093	//       "location": "query",
43094	//       "type": "string"
43095	//     },
43096	//     "parent": {
43097	//       "description": "Required. The agent to list all intents from. Format: `projects//agent` or `projects//locations//agent`. Alternatively, you can specify the environment to list intents for. Format: `projects//agent/environments/` or `projects//locations//agent/environments/`. Note: training phrases of the intents will not be returned for non-draft environment.",
43098	//       "location": "path",
43099	//       "pattern": "^projects/[^/]+/locations/[^/]+/agent$",
43100	//       "required": true,
43101	//       "type": "string"
43102	//     }
43103	//   },
43104	//   "path": "v2/{+parent}/intents",
43105	//   "response": {
43106	//     "$ref": "GoogleCloudDialogflowV2ListIntentsResponse"
43107	//   },
43108	//   "scopes": [
43109	//     "https://www.googleapis.com/auth/cloud-platform",
43110	//     "https://www.googleapis.com/auth/dialogflow"
43111	//   ]
43112	// }
43113
43114}
43115
43116// Pages invokes f for each page of results.
43117// A non-nil error returned from f will halt the iteration.
43118// The provided context supersedes any context provided to the Context method.
43119func (c *ProjectsLocationsAgentIntentsListCall) Pages(ctx context.Context, f func(*GoogleCloudDialogflowV2ListIntentsResponse) error) error {
43120	c.ctx_ = ctx
43121	defer c.PageToken(c.urlParams_.Get("pageToken")) // reset paging to original point
43122	for {
43123		x, err := c.Do()
43124		if err != nil {
43125			return err
43126		}
43127		if err := f(x); err != nil {
43128			return err
43129		}
43130		if x.NextPageToken == "" {
43131			return nil
43132		}
43133		c.PageToken(x.NextPageToken)
43134	}
43135}
43136
43137// method id "dialogflow.projects.locations.agent.intents.patch":
43138
43139type ProjectsLocationsAgentIntentsPatchCall struct {
43140	s                             *Service
43141	nameid                        string
43142	googleclouddialogflowv2intent *GoogleCloudDialogflowV2Intent
43143	urlParams_                    gensupport.URLParams
43144	ctx_                          context.Context
43145	header_                       http.Header
43146}
43147
43148// Patch: Updates the specified intent. Note: You should always train an
43149// agent prior to sending it queries. See the training documentation
43150// (https://cloud.google.com/dialogflow/es/docs/training).
43151//
43152// - name: Optional. The unique identifier of this intent. Required for
43153//   Intents.UpdateIntent and Intents.BatchUpdateIntents methods.
43154//   Format: `projects//agent/intents/`.
43155func (r *ProjectsLocationsAgentIntentsService) Patch(nameid string, googleclouddialogflowv2intent *GoogleCloudDialogflowV2Intent) *ProjectsLocationsAgentIntentsPatchCall {
43156	c := &ProjectsLocationsAgentIntentsPatchCall{s: r.s, urlParams_: make(gensupport.URLParams)}
43157	c.nameid = nameid
43158	c.googleclouddialogflowv2intent = googleclouddialogflowv2intent
43159	return c
43160}
43161
43162// IntentView sets the optional parameter "intentView": The resource
43163// view to apply to the returned intent.
43164//
43165// Possible values:
43166//   "INTENT_VIEW_UNSPECIFIED" - Training phrases field is not populated
43167// in the response.
43168//   "INTENT_VIEW_FULL" - All fields are populated.
43169func (c *ProjectsLocationsAgentIntentsPatchCall) IntentView(intentView string) *ProjectsLocationsAgentIntentsPatchCall {
43170	c.urlParams_.Set("intentView", intentView)
43171	return c
43172}
43173
43174// LanguageCode sets the optional parameter "languageCode": The language
43175// used to access language-specific data. If not specified, the agent's
43176// default language is used. For more information, see Multilingual
43177// intent and entity data
43178// (https://cloud.google.com/dialogflow/docs/agents-multilingual#intent-entity).
43179func (c *ProjectsLocationsAgentIntentsPatchCall) LanguageCode(languageCode string) *ProjectsLocationsAgentIntentsPatchCall {
43180	c.urlParams_.Set("languageCode", languageCode)
43181	return c
43182}
43183
43184// UpdateMask sets the optional parameter "updateMask": The mask to
43185// control which fields get updated.
43186func (c *ProjectsLocationsAgentIntentsPatchCall) UpdateMask(updateMask string) *ProjectsLocationsAgentIntentsPatchCall {
43187	c.urlParams_.Set("updateMask", updateMask)
43188	return c
43189}
43190
43191// Fields allows partial responses to be retrieved. See
43192// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
43193// for more information.
43194func (c *ProjectsLocationsAgentIntentsPatchCall) Fields(s ...googleapi.Field) *ProjectsLocationsAgentIntentsPatchCall {
43195	c.urlParams_.Set("fields", googleapi.CombineFields(s))
43196	return c
43197}
43198
43199// Context sets the context to be used in this call's Do method. Any
43200// pending HTTP request will be aborted if the provided context is
43201// canceled.
43202func (c *ProjectsLocationsAgentIntentsPatchCall) Context(ctx context.Context) *ProjectsLocationsAgentIntentsPatchCall {
43203	c.ctx_ = ctx
43204	return c
43205}
43206
43207// Header returns an http.Header that can be modified by the caller to
43208// add HTTP headers to the request.
43209func (c *ProjectsLocationsAgentIntentsPatchCall) Header() http.Header {
43210	if c.header_ == nil {
43211		c.header_ = make(http.Header)
43212	}
43213	return c.header_
43214}
43215
43216func (c *ProjectsLocationsAgentIntentsPatchCall) doRequest(alt string) (*http.Response, error) {
43217	reqHeaders := make(http.Header)
43218	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20211027")
43219	for k, v := range c.header_ {
43220		reqHeaders[k] = v
43221	}
43222	reqHeaders.Set("User-Agent", c.s.userAgent())
43223	var body io.Reader = nil
43224	body, err := googleapi.WithoutDataWrapper.JSONReader(c.googleclouddialogflowv2intent)
43225	if err != nil {
43226		return nil, err
43227	}
43228	reqHeaders.Set("Content-Type", "application/json")
43229	c.urlParams_.Set("alt", alt)
43230	c.urlParams_.Set("prettyPrint", "false")
43231	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+name}")
43232	urls += "?" + c.urlParams_.Encode()
43233	req, err := http.NewRequest("PATCH", urls, body)
43234	if err != nil {
43235		return nil, err
43236	}
43237	req.Header = reqHeaders
43238	googleapi.Expand(req.URL, map[string]string{
43239		"name": c.nameid,
43240	})
43241	return gensupport.SendRequest(c.ctx_, c.s.client, req)
43242}
43243
43244// Do executes the "dialogflow.projects.locations.agent.intents.patch" call.
43245// Exactly one of *GoogleCloudDialogflowV2Intent or error will be
43246// non-nil. Any non-2xx status code is an error. Response headers are in
43247// either *GoogleCloudDialogflowV2Intent.ServerResponse.Header or (if a
43248// response was returned at all) in error.(*googleapi.Error).Header. Use
43249// googleapi.IsNotModified to check whether the returned error was
43250// because http.StatusNotModified was returned.
43251func (c *ProjectsLocationsAgentIntentsPatchCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDialogflowV2Intent, error) {
43252	gensupport.SetOptions(c.urlParams_, opts...)
43253	res, err := c.doRequest("json")
43254	if res != nil && res.StatusCode == http.StatusNotModified {
43255		if res.Body != nil {
43256			res.Body.Close()
43257		}
43258		return nil, &googleapi.Error{
43259			Code:   res.StatusCode,
43260			Header: res.Header,
43261		}
43262	}
43263	if err != nil {
43264		return nil, err
43265	}
43266	defer googleapi.CloseBody(res)
43267	if err := googleapi.CheckResponse(res); err != nil {
43268		return nil, err
43269	}
43270	ret := &GoogleCloudDialogflowV2Intent{
43271		ServerResponse: googleapi.ServerResponse{
43272			Header:         res.Header,
43273			HTTPStatusCode: res.StatusCode,
43274		},
43275	}
43276	target := &ret
43277	if err := gensupport.DecodeResponse(target, res); err != nil {
43278		return nil, err
43279	}
43280	return ret, nil
43281	// {
43282	//   "description": "Updates the specified intent. Note: You should always train an agent prior to sending it queries. See the [training documentation](https://cloud.google.com/dialogflow/es/docs/training).",
43283	//   "flatPath": "v2/projects/{projectsId}/locations/{locationsId}/agent/intents/{intentsId}",
43284	//   "httpMethod": "PATCH",
43285	//   "id": "dialogflow.projects.locations.agent.intents.patch",
43286	//   "parameterOrder": [
43287	//     "name"
43288	//   ],
43289	//   "parameters": {
43290	//     "intentView": {
43291	//       "description": "Optional. The resource view to apply to the returned intent.",
43292	//       "enum": [
43293	//         "INTENT_VIEW_UNSPECIFIED",
43294	//         "INTENT_VIEW_FULL"
43295	//       ],
43296	//       "enumDescriptions": [
43297	//         "Training phrases field is not populated in the response.",
43298	//         "All fields are populated."
43299	//       ],
43300	//       "location": "query",
43301	//       "type": "string"
43302	//     },
43303	//     "languageCode": {
43304	//       "description": "Optional. The language used to access language-specific data. If not specified, the agent's default language is used. For more information, see [Multilingual intent and entity data](https://cloud.google.com/dialogflow/docs/agents-multilingual#intent-entity).",
43305	//       "location": "query",
43306	//       "type": "string"
43307	//     },
43308	//     "name": {
43309	//       "description": "Optional. The unique identifier of this intent. Required for Intents.UpdateIntent and Intents.BatchUpdateIntents methods. Format: `projects//agent/intents/`.",
43310	//       "location": "path",
43311	//       "pattern": "^projects/[^/]+/locations/[^/]+/agent/intents/[^/]+$",
43312	//       "required": true,
43313	//       "type": "string"
43314	//     },
43315	//     "updateMask": {
43316	//       "description": "Optional. The mask to control which fields get updated.",
43317	//       "format": "google-fieldmask",
43318	//       "location": "query",
43319	//       "type": "string"
43320	//     }
43321	//   },
43322	//   "path": "v2/{+name}",
43323	//   "request": {
43324	//     "$ref": "GoogleCloudDialogflowV2Intent"
43325	//   },
43326	//   "response": {
43327	//     "$ref": "GoogleCloudDialogflowV2Intent"
43328	//   },
43329	//   "scopes": [
43330	//     "https://www.googleapis.com/auth/cloud-platform",
43331	//     "https://www.googleapis.com/auth/dialogflow"
43332	//   ]
43333	// }
43334
43335}
43336
43337// method id "dialogflow.projects.locations.agent.sessions.deleteContexts":
43338
43339type ProjectsLocationsAgentSessionsDeleteContextsCall struct {
43340	s          *Service
43341	parent     string
43342	urlParams_ gensupport.URLParams
43343	ctx_       context.Context
43344	header_    http.Header
43345}
43346
43347// DeleteContexts: Deletes all active contexts in the specified session.
43348//
43349// - parent: The name of the session to delete all contexts from.
43350//   Format: `projects//agent/sessions/` or
43351//   `projects//agent/environments//users//sessions/`. If `Environment
43352//   ID` is not specified we assume default 'draft' environment. If
43353//   `User ID` is not specified, we assume default '-' user.
43354func (r *ProjectsLocationsAgentSessionsService) DeleteContexts(parent string) *ProjectsLocationsAgentSessionsDeleteContextsCall {
43355	c := &ProjectsLocationsAgentSessionsDeleteContextsCall{s: r.s, urlParams_: make(gensupport.URLParams)}
43356	c.parent = parent
43357	return c
43358}
43359
43360// Fields allows partial responses to be retrieved. See
43361// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
43362// for more information.
43363func (c *ProjectsLocationsAgentSessionsDeleteContextsCall) Fields(s ...googleapi.Field) *ProjectsLocationsAgentSessionsDeleteContextsCall {
43364	c.urlParams_.Set("fields", googleapi.CombineFields(s))
43365	return c
43366}
43367
43368// Context sets the context to be used in this call's Do method. Any
43369// pending HTTP request will be aborted if the provided context is
43370// canceled.
43371func (c *ProjectsLocationsAgentSessionsDeleteContextsCall) Context(ctx context.Context) *ProjectsLocationsAgentSessionsDeleteContextsCall {
43372	c.ctx_ = ctx
43373	return c
43374}
43375
43376// Header returns an http.Header that can be modified by the caller to
43377// add HTTP headers to the request.
43378func (c *ProjectsLocationsAgentSessionsDeleteContextsCall) Header() http.Header {
43379	if c.header_ == nil {
43380		c.header_ = make(http.Header)
43381	}
43382	return c.header_
43383}
43384
43385func (c *ProjectsLocationsAgentSessionsDeleteContextsCall) doRequest(alt string) (*http.Response, error) {
43386	reqHeaders := make(http.Header)
43387	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20211027")
43388	for k, v := range c.header_ {
43389		reqHeaders[k] = v
43390	}
43391	reqHeaders.Set("User-Agent", c.s.userAgent())
43392	var body io.Reader = nil
43393	c.urlParams_.Set("alt", alt)
43394	c.urlParams_.Set("prettyPrint", "false")
43395	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+parent}/contexts")
43396	urls += "?" + c.urlParams_.Encode()
43397	req, err := http.NewRequest("DELETE", urls, body)
43398	if err != nil {
43399		return nil, err
43400	}
43401	req.Header = reqHeaders
43402	googleapi.Expand(req.URL, map[string]string{
43403		"parent": c.parent,
43404	})
43405	return gensupport.SendRequest(c.ctx_, c.s.client, req)
43406}
43407
43408// Do executes the "dialogflow.projects.locations.agent.sessions.deleteContexts" call.
43409// Exactly one of *GoogleProtobufEmpty or error will be non-nil. Any
43410// non-2xx status code is an error. Response headers are in either
43411// *GoogleProtobufEmpty.ServerResponse.Header or (if a response was
43412// returned at all) in error.(*googleapi.Error).Header. Use
43413// googleapi.IsNotModified to check whether the returned error was
43414// because http.StatusNotModified was returned.
43415func (c *ProjectsLocationsAgentSessionsDeleteContextsCall) Do(opts ...googleapi.CallOption) (*GoogleProtobufEmpty, error) {
43416	gensupport.SetOptions(c.urlParams_, opts...)
43417	res, err := c.doRequest("json")
43418	if res != nil && res.StatusCode == http.StatusNotModified {
43419		if res.Body != nil {
43420			res.Body.Close()
43421		}
43422		return nil, &googleapi.Error{
43423			Code:   res.StatusCode,
43424			Header: res.Header,
43425		}
43426	}
43427	if err != nil {
43428		return nil, err
43429	}
43430	defer googleapi.CloseBody(res)
43431	if err := googleapi.CheckResponse(res); err != nil {
43432		return nil, err
43433	}
43434	ret := &GoogleProtobufEmpty{
43435		ServerResponse: googleapi.ServerResponse{
43436			Header:         res.Header,
43437			HTTPStatusCode: res.StatusCode,
43438		},
43439	}
43440	target := &ret
43441	if err := gensupport.DecodeResponse(target, res); err != nil {
43442		return nil, err
43443	}
43444	return ret, nil
43445	// {
43446	//   "description": "Deletes all active contexts in the specified session.",
43447	//   "flatPath": "v2/projects/{projectsId}/locations/{locationsId}/agent/sessions/{sessionsId}/contexts",
43448	//   "httpMethod": "DELETE",
43449	//   "id": "dialogflow.projects.locations.agent.sessions.deleteContexts",
43450	//   "parameterOrder": [
43451	//     "parent"
43452	//   ],
43453	//   "parameters": {
43454	//     "parent": {
43455	//       "description": "Required. The name of the session to delete all contexts from. Format: `projects//agent/sessions/` or `projects//agent/environments//users//sessions/`. If `Environment ID` is not specified we assume default 'draft' environment. If `User ID` is not specified, we assume default '-' user.",
43456	//       "location": "path",
43457	//       "pattern": "^projects/[^/]+/locations/[^/]+/agent/sessions/[^/]+$",
43458	//       "required": true,
43459	//       "type": "string"
43460	//     }
43461	//   },
43462	//   "path": "v2/{+parent}/contexts",
43463	//   "response": {
43464	//     "$ref": "GoogleProtobufEmpty"
43465	//   },
43466	//   "scopes": [
43467	//     "https://www.googleapis.com/auth/cloud-platform",
43468	//     "https://www.googleapis.com/auth/dialogflow"
43469	//   ]
43470	// }
43471
43472}
43473
43474// method id "dialogflow.projects.locations.agent.sessions.detectIntent":
43475
43476type ProjectsLocationsAgentSessionsDetectIntentCall struct {
43477	s                                          *Service
43478	sessionid                                  string
43479	googleclouddialogflowv2detectintentrequest *GoogleCloudDialogflowV2DetectIntentRequest
43480	urlParams_                                 gensupport.URLParams
43481	ctx_                                       context.Context
43482	header_                                    http.Header
43483}
43484
43485// DetectIntent: Processes a natural language query and returns
43486// structured, actionable data as a result. This method is not
43487// idempotent, because it may cause contexts and session entity types to
43488// be updated, which in turn might affect results of future queries. If
43489// you might use Agent Assist
43490// (https://cloud.google.com/dialogflow/docs/#aa) or other CCAI products
43491// now or in the future, consider using AnalyzeContent instead of
43492// `DetectIntent`. `AnalyzeContent` has additional functionality for
43493// Agent Assist and other CCAI products. Note: Always use agent versions
43494// for production traffic. See Versions and environments
43495// (https://cloud.google.com/dialogflow/es/docs/agents-versions).
43496//
43497// - session: The name of the session this query is sent to. Format:
43498//   `projects//agent/sessions/`, or
43499//   `projects//agent/environments//users//sessions/`. If `Environment
43500//   ID` is not specified, we assume default 'draft' environment
43501//   (`Environment ID` might be referred to as environment name at some
43502//   places). If `User ID` is not specified, we are using "-". It's up
43503//   to the API caller to choose an appropriate `Session ID` and `User
43504//   Id`. They can be a random number or some type of user and session
43505//   identifiers (preferably hashed). The length of the `Session ID` and
43506//   `User ID` must not exceed 36 characters. For more information, see
43507//   the API interactions guide
43508//   (https://cloud.google.com/dialogflow/docs/api-overview). Note:
43509//   Always use agent versions for production traffic. See Versions and
43510//   environments
43511//   (https://cloud.google.com/dialogflow/es/docs/agents-versions).
43512func (r *ProjectsLocationsAgentSessionsService) DetectIntent(sessionid string, googleclouddialogflowv2detectintentrequest *GoogleCloudDialogflowV2DetectIntentRequest) *ProjectsLocationsAgentSessionsDetectIntentCall {
43513	c := &ProjectsLocationsAgentSessionsDetectIntentCall{s: r.s, urlParams_: make(gensupport.URLParams)}
43514	c.sessionid = sessionid
43515	c.googleclouddialogflowv2detectintentrequest = googleclouddialogflowv2detectintentrequest
43516	return c
43517}
43518
43519// Fields allows partial responses to be retrieved. See
43520// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
43521// for more information.
43522func (c *ProjectsLocationsAgentSessionsDetectIntentCall) Fields(s ...googleapi.Field) *ProjectsLocationsAgentSessionsDetectIntentCall {
43523	c.urlParams_.Set("fields", googleapi.CombineFields(s))
43524	return c
43525}
43526
43527// Context sets the context to be used in this call's Do method. Any
43528// pending HTTP request will be aborted if the provided context is
43529// canceled.
43530func (c *ProjectsLocationsAgentSessionsDetectIntentCall) Context(ctx context.Context) *ProjectsLocationsAgentSessionsDetectIntentCall {
43531	c.ctx_ = ctx
43532	return c
43533}
43534
43535// Header returns an http.Header that can be modified by the caller to
43536// add HTTP headers to the request.
43537func (c *ProjectsLocationsAgentSessionsDetectIntentCall) Header() http.Header {
43538	if c.header_ == nil {
43539		c.header_ = make(http.Header)
43540	}
43541	return c.header_
43542}
43543
43544func (c *ProjectsLocationsAgentSessionsDetectIntentCall) doRequest(alt string) (*http.Response, error) {
43545	reqHeaders := make(http.Header)
43546	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20211027")
43547	for k, v := range c.header_ {
43548		reqHeaders[k] = v
43549	}
43550	reqHeaders.Set("User-Agent", c.s.userAgent())
43551	var body io.Reader = nil
43552	body, err := googleapi.WithoutDataWrapper.JSONReader(c.googleclouddialogflowv2detectintentrequest)
43553	if err != nil {
43554		return nil, err
43555	}
43556	reqHeaders.Set("Content-Type", "application/json")
43557	c.urlParams_.Set("alt", alt)
43558	c.urlParams_.Set("prettyPrint", "false")
43559	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+session}:detectIntent")
43560	urls += "?" + c.urlParams_.Encode()
43561	req, err := http.NewRequest("POST", urls, body)
43562	if err != nil {
43563		return nil, err
43564	}
43565	req.Header = reqHeaders
43566	googleapi.Expand(req.URL, map[string]string{
43567		"session": c.sessionid,
43568	})
43569	return gensupport.SendRequest(c.ctx_, c.s.client, req)
43570}
43571
43572// Do executes the "dialogflow.projects.locations.agent.sessions.detectIntent" call.
43573// Exactly one of *GoogleCloudDialogflowV2DetectIntentResponse or error
43574// will be non-nil. Any non-2xx status code is an error. Response
43575// headers are in either
43576// *GoogleCloudDialogflowV2DetectIntentResponse.ServerResponse.Header or
43577// (if a response was returned at all) in
43578// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
43579// whether the returned error was because http.StatusNotModified was
43580// returned.
43581func (c *ProjectsLocationsAgentSessionsDetectIntentCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDialogflowV2DetectIntentResponse, error) {
43582	gensupport.SetOptions(c.urlParams_, opts...)
43583	res, err := c.doRequest("json")
43584	if res != nil && res.StatusCode == http.StatusNotModified {
43585		if res.Body != nil {
43586			res.Body.Close()
43587		}
43588		return nil, &googleapi.Error{
43589			Code:   res.StatusCode,
43590			Header: res.Header,
43591		}
43592	}
43593	if err != nil {
43594		return nil, err
43595	}
43596	defer googleapi.CloseBody(res)
43597	if err := googleapi.CheckResponse(res); err != nil {
43598		return nil, err
43599	}
43600	ret := &GoogleCloudDialogflowV2DetectIntentResponse{
43601		ServerResponse: googleapi.ServerResponse{
43602			Header:         res.Header,
43603			HTTPStatusCode: res.StatusCode,
43604		},
43605	}
43606	target := &ret
43607	if err := gensupport.DecodeResponse(target, res); err != nil {
43608		return nil, err
43609	}
43610	return ret, nil
43611	// {
43612	//   "description": "Processes a natural language query and returns structured, actionable data as a result. This method is not idempotent, because it may cause contexts and session entity types to be updated, which in turn might affect results of future queries. If you might use [Agent Assist](https://cloud.google.com/dialogflow/docs/#aa) or other CCAI products now or in the future, consider using AnalyzeContent instead of `DetectIntent`. `AnalyzeContent` has additional functionality for Agent Assist and other CCAI products. Note: Always use agent versions for production traffic. See [Versions and environments](https://cloud.google.com/dialogflow/es/docs/agents-versions).",
43613	//   "flatPath": "v2/projects/{projectsId}/locations/{locationsId}/agent/sessions/{sessionsId}:detectIntent",
43614	//   "httpMethod": "POST",
43615	//   "id": "dialogflow.projects.locations.agent.sessions.detectIntent",
43616	//   "parameterOrder": [
43617	//     "session"
43618	//   ],
43619	//   "parameters": {
43620	//     "session": {
43621	//       "description": "Required. The name of the session this query is sent to. Format: `projects//agent/sessions/`, or `projects//agent/environments//users//sessions/`. If `Environment ID` is not specified, we assume default 'draft' environment (`Environment ID` might be referred to as environment name at some places). If `User ID` is not specified, we are using \"-\". It's up to the API caller to choose an appropriate `Session ID` and `User Id`. They can be a random number or some type of user and session identifiers (preferably hashed). The length of the `Session ID` and `User ID` must not exceed 36 characters. For more information, see the [API interactions guide](https://cloud.google.com/dialogflow/docs/api-overview). Note: Always use agent versions for production traffic. See [Versions and environments](https://cloud.google.com/dialogflow/es/docs/agents-versions).",
43622	//       "location": "path",
43623	//       "pattern": "^projects/[^/]+/locations/[^/]+/agent/sessions/[^/]+$",
43624	//       "required": true,
43625	//       "type": "string"
43626	//     }
43627	//   },
43628	//   "path": "v2/{+session}:detectIntent",
43629	//   "request": {
43630	//     "$ref": "GoogleCloudDialogflowV2DetectIntentRequest"
43631	//   },
43632	//   "response": {
43633	//     "$ref": "GoogleCloudDialogflowV2DetectIntentResponse"
43634	//   },
43635	//   "scopes": [
43636	//     "https://www.googleapis.com/auth/cloud-platform",
43637	//     "https://www.googleapis.com/auth/dialogflow"
43638	//   ]
43639	// }
43640
43641}
43642
43643// method id "dialogflow.projects.locations.agent.sessions.contexts.create":
43644
43645type ProjectsLocationsAgentSessionsContextsCreateCall struct {
43646	s                              *Service
43647	parent                         string
43648	googleclouddialogflowv2context *GoogleCloudDialogflowV2Context
43649	urlParams_                     gensupport.URLParams
43650	ctx_                           context.Context
43651	header_                        http.Header
43652}
43653
43654// Create: Creates a context. If the specified context already exists,
43655// overrides the context.
43656//
43657// - parent: The session to create a context for. Format:
43658//   `projects//agent/sessions/` or
43659//   `projects//agent/environments//users//sessions/`. If `Environment
43660//   ID` is not specified, we assume default 'draft' environment. If
43661//   `User ID` is not specified, we assume default '-' user.
43662func (r *ProjectsLocationsAgentSessionsContextsService) Create(parent string, googleclouddialogflowv2context *GoogleCloudDialogflowV2Context) *ProjectsLocationsAgentSessionsContextsCreateCall {
43663	c := &ProjectsLocationsAgentSessionsContextsCreateCall{s: r.s, urlParams_: make(gensupport.URLParams)}
43664	c.parent = parent
43665	c.googleclouddialogflowv2context = googleclouddialogflowv2context
43666	return c
43667}
43668
43669// Fields allows partial responses to be retrieved. See
43670// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
43671// for more information.
43672func (c *ProjectsLocationsAgentSessionsContextsCreateCall) Fields(s ...googleapi.Field) *ProjectsLocationsAgentSessionsContextsCreateCall {
43673	c.urlParams_.Set("fields", googleapi.CombineFields(s))
43674	return c
43675}
43676
43677// Context sets the context to be used in this call's Do method. Any
43678// pending HTTP request will be aborted if the provided context is
43679// canceled.
43680func (c *ProjectsLocationsAgentSessionsContextsCreateCall) Context(ctx context.Context) *ProjectsLocationsAgentSessionsContextsCreateCall {
43681	c.ctx_ = ctx
43682	return c
43683}
43684
43685// Header returns an http.Header that can be modified by the caller to
43686// add HTTP headers to the request.
43687func (c *ProjectsLocationsAgentSessionsContextsCreateCall) Header() http.Header {
43688	if c.header_ == nil {
43689		c.header_ = make(http.Header)
43690	}
43691	return c.header_
43692}
43693
43694func (c *ProjectsLocationsAgentSessionsContextsCreateCall) doRequest(alt string) (*http.Response, error) {
43695	reqHeaders := make(http.Header)
43696	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20211027")
43697	for k, v := range c.header_ {
43698		reqHeaders[k] = v
43699	}
43700	reqHeaders.Set("User-Agent", c.s.userAgent())
43701	var body io.Reader = nil
43702	body, err := googleapi.WithoutDataWrapper.JSONReader(c.googleclouddialogflowv2context)
43703	if err != nil {
43704		return nil, err
43705	}
43706	reqHeaders.Set("Content-Type", "application/json")
43707	c.urlParams_.Set("alt", alt)
43708	c.urlParams_.Set("prettyPrint", "false")
43709	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+parent}/contexts")
43710	urls += "?" + c.urlParams_.Encode()
43711	req, err := http.NewRequest("POST", urls, body)
43712	if err != nil {
43713		return nil, err
43714	}
43715	req.Header = reqHeaders
43716	googleapi.Expand(req.URL, map[string]string{
43717		"parent": c.parent,
43718	})
43719	return gensupport.SendRequest(c.ctx_, c.s.client, req)
43720}
43721
43722// Do executes the "dialogflow.projects.locations.agent.sessions.contexts.create" call.
43723// Exactly one of *GoogleCloudDialogflowV2Context or error will be
43724// non-nil. Any non-2xx status code is an error. Response headers are in
43725// either *GoogleCloudDialogflowV2Context.ServerResponse.Header or (if a
43726// response was returned at all) in error.(*googleapi.Error).Header. Use
43727// googleapi.IsNotModified to check whether the returned error was
43728// because http.StatusNotModified was returned.
43729func (c *ProjectsLocationsAgentSessionsContextsCreateCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDialogflowV2Context, error) {
43730	gensupport.SetOptions(c.urlParams_, opts...)
43731	res, err := c.doRequest("json")
43732	if res != nil && res.StatusCode == http.StatusNotModified {
43733		if res.Body != nil {
43734			res.Body.Close()
43735		}
43736		return nil, &googleapi.Error{
43737			Code:   res.StatusCode,
43738			Header: res.Header,
43739		}
43740	}
43741	if err != nil {
43742		return nil, err
43743	}
43744	defer googleapi.CloseBody(res)
43745	if err := googleapi.CheckResponse(res); err != nil {
43746		return nil, err
43747	}
43748	ret := &GoogleCloudDialogflowV2Context{
43749		ServerResponse: googleapi.ServerResponse{
43750			Header:         res.Header,
43751			HTTPStatusCode: res.StatusCode,
43752		},
43753	}
43754	target := &ret
43755	if err := gensupport.DecodeResponse(target, res); err != nil {
43756		return nil, err
43757	}
43758	return ret, nil
43759	// {
43760	//   "description": "Creates a context. If the specified context already exists, overrides the context.",
43761	//   "flatPath": "v2/projects/{projectsId}/locations/{locationsId}/agent/sessions/{sessionsId}/contexts",
43762	//   "httpMethod": "POST",
43763	//   "id": "dialogflow.projects.locations.agent.sessions.contexts.create",
43764	//   "parameterOrder": [
43765	//     "parent"
43766	//   ],
43767	//   "parameters": {
43768	//     "parent": {
43769	//       "description": "Required. The session to create a context for. Format: `projects//agent/sessions/` or `projects//agent/environments//users//sessions/`. If `Environment ID` is not specified, we assume default 'draft' environment. If `User ID` is not specified, we assume default '-' user.",
43770	//       "location": "path",
43771	//       "pattern": "^projects/[^/]+/locations/[^/]+/agent/sessions/[^/]+$",
43772	//       "required": true,
43773	//       "type": "string"
43774	//     }
43775	//   },
43776	//   "path": "v2/{+parent}/contexts",
43777	//   "request": {
43778	//     "$ref": "GoogleCloudDialogflowV2Context"
43779	//   },
43780	//   "response": {
43781	//     "$ref": "GoogleCloudDialogflowV2Context"
43782	//   },
43783	//   "scopes": [
43784	//     "https://www.googleapis.com/auth/cloud-platform",
43785	//     "https://www.googleapis.com/auth/dialogflow"
43786	//   ]
43787	// }
43788
43789}
43790
43791// method id "dialogflow.projects.locations.agent.sessions.contexts.delete":
43792
43793type ProjectsLocationsAgentSessionsContextsDeleteCall struct {
43794	s          *Service
43795	name       string
43796	urlParams_ gensupport.URLParams
43797	ctx_       context.Context
43798	header_    http.Header
43799}
43800
43801// Delete: Deletes the specified context.
43802//
43803// - name: The name of the context to delete. Format:
43804//   `projects//agent/sessions//contexts/` or
43805//   `projects//agent/environments//users//sessions//contexts/`. If
43806//   `Environment ID` is not specified, we assume default 'draft'
43807//   environment. If `User ID` is not specified, we assume default '-'
43808//   user.
43809func (r *ProjectsLocationsAgentSessionsContextsService) Delete(name string) *ProjectsLocationsAgentSessionsContextsDeleteCall {
43810	c := &ProjectsLocationsAgentSessionsContextsDeleteCall{s: r.s, urlParams_: make(gensupport.URLParams)}
43811	c.name = name
43812	return c
43813}
43814
43815// Fields allows partial responses to be retrieved. See
43816// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
43817// for more information.
43818func (c *ProjectsLocationsAgentSessionsContextsDeleteCall) Fields(s ...googleapi.Field) *ProjectsLocationsAgentSessionsContextsDeleteCall {
43819	c.urlParams_.Set("fields", googleapi.CombineFields(s))
43820	return c
43821}
43822
43823// Context sets the context to be used in this call's Do method. Any
43824// pending HTTP request will be aborted if the provided context is
43825// canceled.
43826func (c *ProjectsLocationsAgentSessionsContextsDeleteCall) Context(ctx context.Context) *ProjectsLocationsAgentSessionsContextsDeleteCall {
43827	c.ctx_ = ctx
43828	return c
43829}
43830
43831// Header returns an http.Header that can be modified by the caller to
43832// add HTTP headers to the request.
43833func (c *ProjectsLocationsAgentSessionsContextsDeleteCall) Header() http.Header {
43834	if c.header_ == nil {
43835		c.header_ = make(http.Header)
43836	}
43837	return c.header_
43838}
43839
43840func (c *ProjectsLocationsAgentSessionsContextsDeleteCall) doRequest(alt string) (*http.Response, error) {
43841	reqHeaders := make(http.Header)
43842	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20211027")
43843	for k, v := range c.header_ {
43844		reqHeaders[k] = v
43845	}
43846	reqHeaders.Set("User-Agent", c.s.userAgent())
43847	var body io.Reader = nil
43848	c.urlParams_.Set("alt", alt)
43849	c.urlParams_.Set("prettyPrint", "false")
43850	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+name}")
43851	urls += "?" + c.urlParams_.Encode()
43852	req, err := http.NewRequest("DELETE", urls, body)
43853	if err != nil {
43854		return nil, err
43855	}
43856	req.Header = reqHeaders
43857	googleapi.Expand(req.URL, map[string]string{
43858		"name": c.name,
43859	})
43860	return gensupport.SendRequest(c.ctx_, c.s.client, req)
43861}
43862
43863// Do executes the "dialogflow.projects.locations.agent.sessions.contexts.delete" call.
43864// Exactly one of *GoogleProtobufEmpty or error will be non-nil. Any
43865// non-2xx status code is an error. Response headers are in either
43866// *GoogleProtobufEmpty.ServerResponse.Header or (if a response was
43867// returned at all) in error.(*googleapi.Error).Header. Use
43868// googleapi.IsNotModified to check whether the returned error was
43869// because http.StatusNotModified was returned.
43870func (c *ProjectsLocationsAgentSessionsContextsDeleteCall) Do(opts ...googleapi.CallOption) (*GoogleProtobufEmpty, error) {
43871	gensupport.SetOptions(c.urlParams_, opts...)
43872	res, err := c.doRequest("json")
43873	if res != nil && res.StatusCode == http.StatusNotModified {
43874		if res.Body != nil {
43875			res.Body.Close()
43876		}
43877		return nil, &googleapi.Error{
43878			Code:   res.StatusCode,
43879			Header: res.Header,
43880		}
43881	}
43882	if err != nil {
43883		return nil, err
43884	}
43885	defer googleapi.CloseBody(res)
43886	if err := googleapi.CheckResponse(res); err != nil {
43887		return nil, err
43888	}
43889	ret := &GoogleProtobufEmpty{
43890		ServerResponse: googleapi.ServerResponse{
43891			Header:         res.Header,
43892			HTTPStatusCode: res.StatusCode,
43893		},
43894	}
43895	target := &ret
43896	if err := gensupport.DecodeResponse(target, res); err != nil {
43897		return nil, err
43898	}
43899	return ret, nil
43900	// {
43901	//   "description": "Deletes the specified context.",
43902	//   "flatPath": "v2/projects/{projectsId}/locations/{locationsId}/agent/sessions/{sessionsId}/contexts/{contextsId}",
43903	//   "httpMethod": "DELETE",
43904	//   "id": "dialogflow.projects.locations.agent.sessions.contexts.delete",
43905	//   "parameterOrder": [
43906	//     "name"
43907	//   ],
43908	//   "parameters": {
43909	//     "name": {
43910	//       "description": "Required. The name of the context to delete. Format: `projects//agent/sessions//contexts/` or `projects//agent/environments//users//sessions//contexts/`. If `Environment ID` is not specified, we assume default 'draft' environment. If `User ID` is not specified, we assume default '-' user.",
43911	//       "location": "path",
43912	//       "pattern": "^projects/[^/]+/locations/[^/]+/agent/sessions/[^/]+/contexts/[^/]+$",
43913	//       "required": true,
43914	//       "type": "string"
43915	//     }
43916	//   },
43917	//   "path": "v2/{+name}",
43918	//   "response": {
43919	//     "$ref": "GoogleProtobufEmpty"
43920	//   },
43921	//   "scopes": [
43922	//     "https://www.googleapis.com/auth/cloud-platform",
43923	//     "https://www.googleapis.com/auth/dialogflow"
43924	//   ]
43925	// }
43926
43927}
43928
43929// method id "dialogflow.projects.locations.agent.sessions.contexts.get":
43930
43931type ProjectsLocationsAgentSessionsContextsGetCall struct {
43932	s            *Service
43933	name         string
43934	urlParams_   gensupport.URLParams
43935	ifNoneMatch_ string
43936	ctx_         context.Context
43937	header_      http.Header
43938}
43939
43940// Get: Retrieves the specified context.
43941//
43942// - name: The name of the context. Format:
43943//   `projects//agent/sessions//contexts/` or
43944//   `projects//agent/environments//users//sessions//contexts/`. If
43945//   `Environment ID` is not specified, we assume default 'draft'
43946//   environment. If `User ID` is not specified, we assume default '-'
43947//   user.
43948func (r *ProjectsLocationsAgentSessionsContextsService) Get(name string) *ProjectsLocationsAgentSessionsContextsGetCall {
43949	c := &ProjectsLocationsAgentSessionsContextsGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
43950	c.name = name
43951	return c
43952}
43953
43954// Fields allows partial responses to be retrieved. See
43955// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
43956// for more information.
43957func (c *ProjectsLocationsAgentSessionsContextsGetCall) Fields(s ...googleapi.Field) *ProjectsLocationsAgentSessionsContextsGetCall {
43958	c.urlParams_.Set("fields", googleapi.CombineFields(s))
43959	return c
43960}
43961
43962// IfNoneMatch sets the optional parameter which makes the operation
43963// fail if the object's ETag matches the given value. This is useful for
43964// getting updates only after the object has changed since the last
43965// request. Use googleapi.IsNotModified to check whether the response
43966// error from Do is the result of In-None-Match.
43967func (c *ProjectsLocationsAgentSessionsContextsGetCall) IfNoneMatch(entityTag string) *ProjectsLocationsAgentSessionsContextsGetCall {
43968	c.ifNoneMatch_ = entityTag
43969	return c
43970}
43971
43972// Context sets the context to be used in this call's Do method. Any
43973// pending HTTP request will be aborted if the provided context is
43974// canceled.
43975func (c *ProjectsLocationsAgentSessionsContextsGetCall) Context(ctx context.Context) *ProjectsLocationsAgentSessionsContextsGetCall {
43976	c.ctx_ = ctx
43977	return c
43978}
43979
43980// Header returns an http.Header that can be modified by the caller to
43981// add HTTP headers to the request.
43982func (c *ProjectsLocationsAgentSessionsContextsGetCall) Header() http.Header {
43983	if c.header_ == nil {
43984		c.header_ = make(http.Header)
43985	}
43986	return c.header_
43987}
43988
43989func (c *ProjectsLocationsAgentSessionsContextsGetCall) doRequest(alt string) (*http.Response, error) {
43990	reqHeaders := make(http.Header)
43991	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20211027")
43992	for k, v := range c.header_ {
43993		reqHeaders[k] = v
43994	}
43995	reqHeaders.Set("User-Agent", c.s.userAgent())
43996	if c.ifNoneMatch_ != "" {
43997		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
43998	}
43999	var body io.Reader = nil
44000	c.urlParams_.Set("alt", alt)
44001	c.urlParams_.Set("prettyPrint", "false")
44002	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+name}")
44003	urls += "?" + c.urlParams_.Encode()
44004	req, err := http.NewRequest("GET", urls, body)
44005	if err != nil {
44006		return nil, err
44007	}
44008	req.Header = reqHeaders
44009	googleapi.Expand(req.URL, map[string]string{
44010		"name": c.name,
44011	})
44012	return gensupport.SendRequest(c.ctx_, c.s.client, req)
44013}
44014
44015// Do executes the "dialogflow.projects.locations.agent.sessions.contexts.get" call.
44016// Exactly one of *GoogleCloudDialogflowV2Context or error will be
44017// non-nil. Any non-2xx status code is an error. Response headers are in
44018// either *GoogleCloudDialogflowV2Context.ServerResponse.Header or (if a
44019// response was returned at all) in error.(*googleapi.Error).Header. Use
44020// googleapi.IsNotModified to check whether the returned error was
44021// because http.StatusNotModified was returned.
44022func (c *ProjectsLocationsAgentSessionsContextsGetCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDialogflowV2Context, error) {
44023	gensupport.SetOptions(c.urlParams_, opts...)
44024	res, err := c.doRequest("json")
44025	if res != nil && res.StatusCode == http.StatusNotModified {
44026		if res.Body != nil {
44027			res.Body.Close()
44028		}
44029		return nil, &googleapi.Error{
44030			Code:   res.StatusCode,
44031			Header: res.Header,
44032		}
44033	}
44034	if err != nil {
44035		return nil, err
44036	}
44037	defer googleapi.CloseBody(res)
44038	if err := googleapi.CheckResponse(res); err != nil {
44039		return nil, err
44040	}
44041	ret := &GoogleCloudDialogflowV2Context{
44042		ServerResponse: googleapi.ServerResponse{
44043			Header:         res.Header,
44044			HTTPStatusCode: res.StatusCode,
44045		},
44046	}
44047	target := &ret
44048	if err := gensupport.DecodeResponse(target, res); err != nil {
44049		return nil, err
44050	}
44051	return ret, nil
44052	// {
44053	//   "description": "Retrieves the specified context.",
44054	//   "flatPath": "v2/projects/{projectsId}/locations/{locationsId}/agent/sessions/{sessionsId}/contexts/{contextsId}",
44055	//   "httpMethod": "GET",
44056	//   "id": "dialogflow.projects.locations.agent.sessions.contexts.get",
44057	//   "parameterOrder": [
44058	//     "name"
44059	//   ],
44060	//   "parameters": {
44061	//     "name": {
44062	//       "description": "Required. The name of the context. Format: `projects//agent/sessions//contexts/` or `projects//agent/environments//users//sessions//contexts/`. If `Environment ID` is not specified, we assume default 'draft' environment. If `User ID` is not specified, we assume default '-' user.",
44063	//       "location": "path",
44064	//       "pattern": "^projects/[^/]+/locations/[^/]+/agent/sessions/[^/]+/contexts/[^/]+$",
44065	//       "required": true,
44066	//       "type": "string"
44067	//     }
44068	//   },
44069	//   "path": "v2/{+name}",
44070	//   "response": {
44071	//     "$ref": "GoogleCloudDialogflowV2Context"
44072	//   },
44073	//   "scopes": [
44074	//     "https://www.googleapis.com/auth/cloud-platform",
44075	//     "https://www.googleapis.com/auth/dialogflow"
44076	//   ]
44077	// }
44078
44079}
44080
44081// method id "dialogflow.projects.locations.agent.sessions.contexts.list":
44082
44083type ProjectsLocationsAgentSessionsContextsListCall struct {
44084	s            *Service
44085	parent       string
44086	urlParams_   gensupport.URLParams
44087	ifNoneMatch_ string
44088	ctx_         context.Context
44089	header_      http.Header
44090}
44091
44092// List: Returns the list of all contexts in the specified session.
44093//
44094// - parent: The session to list all contexts from. Format:
44095//   `projects//agent/sessions/` or
44096//   `projects//agent/environments//users//sessions/`. If `Environment
44097//   ID` is not specified, we assume default 'draft' environment. If
44098//   `User ID` is not specified, we assume default '-' user.
44099func (r *ProjectsLocationsAgentSessionsContextsService) List(parent string) *ProjectsLocationsAgentSessionsContextsListCall {
44100	c := &ProjectsLocationsAgentSessionsContextsListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
44101	c.parent = parent
44102	return c
44103}
44104
44105// PageSize sets the optional parameter "pageSize": The maximum number
44106// of items to return in a single page. By default 100 and at most 1000.
44107func (c *ProjectsLocationsAgentSessionsContextsListCall) PageSize(pageSize int64) *ProjectsLocationsAgentSessionsContextsListCall {
44108	c.urlParams_.Set("pageSize", fmt.Sprint(pageSize))
44109	return c
44110}
44111
44112// PageToken sets the optional parameter "pageToken": The
44113// next_page_token value returned from a previous list request.
44114func (c *ProjectsLocationsAgentSessionsContextsListCall) PageToken(pageToken string) *ProjectsLocationsAgentSessionsContextsListCall {
44115	c.urlParams_.Set("pageToken", pageToken)
44116	return c
44117}
44118
44119// Fields allows partial responses to be retrieved. See
44120// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
44121// for more information.
44122func (c *ProjectsLocationsAgentSessionsContextsListCall) Fields(s ...googleapi.Field) *ProjectsLocationsAgentSessionsContextsListCall {
44123	c.urlParams_.Set("fields", googleapi.CombineFields(s))
44124	return c
44125}
44126
44127// IfNoneMatch sets the optional parameter which makes the operation
44128// fail if the object's ETag matches the given value. This is useful for
44129// getting updates only after the object has changed since the last
44130// request. Use googleapi.IsNotModified to check whether the response
44131// error from Do is the result of In-None-Match.
44132func (c *ProjectsLocationsAgentSessionsContextsListCall) IfNoneMatch(entityTag string) *ProjectsLocationsAgentSessionsContextsListCall {
44133	c.ifNoneMatch_ = entityTag
44134	return c
44135}
44136
44137// Context sets the context to be used in this call's Do method. Any
44138// pending HTTP request will be aborted if the provided context is
44139// canceled.
44140func (c *ProjectsLocationsAgentSessionsContextsListCall) Context(ctx context.Context) *ProjectsLocationsAgentSessionsContextsListCall {
44141	c.ctx_ = ctx
44142	return c
44143}
44144
44145// Header returns an http.Header that can be modified by the caller to
44146// add HTTP headers to the request.
44147func (c *ProjectsLocationsAgentSessionsContextsListCall) Header() http.Header {
44148	if c.header_ == nil {
44149		c.header_ = make(http.Header)
44150	}
44151	return c.header_
44152}
44153
44154func (c *ProjectsLocationsAgentSessionsContextsListCall) doRequest(alt string) (*http.Response, error) {
44155	reqHeaders := make(http.Header)
44156	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20211027")
44157	for k, v := range c.header_ {
44158		reqHeaders[k] = v
44159	}
44160	reqHeaders.Set("User-Agent", c.s.userAgent())
44161	if c.ifNoneMatch_ != "" {
44162		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
44163	}
44164	var body io.Reader = nil
44165	c.urlParams_.Set("alt", alt)
44166	c.urlParams_.Set("prettyPrint", "false")
44167	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+parent}/contexts")
44168	urls += "?" + c.urlParams_.Encode()
44169	req, err := http.NewRequest("GET", urls, body)
44170	if err != nil {
44171		return nil, err
44172	}
44173	req.Header = reqHeaders
44174	googleapi.Expand(req.URL, map[string]string{
44175		"parent": c.parent,
44176	})
44177	return gensupport.SendRequest(c.ctx_, c.s.client, req)
44178}
44179
44180// Do executes the "dialogflow.projects.locations.agent.sessions.contexts.list" call.
44181// Exactly one of *GoogleCloudDialogflowV2ListContextsResponse or error
44182// will be non-nil. Any non-2xx status code is an error. Response
44183// headers are in either
44184// *GoogleCloudDialogflowV2ListContextsResponse.ServerResponse.Header or
44185// (if a response was returned at all) in
44186// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
44187// whether the returned error was because http.StatusNotModified was
44188// returned.
44189func (c *ProjectsLocationsAgentSessionsContextsListCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDialogflowV2ListContextsResponse, error) {
44190	gensupport.SetOptions(c.urlParams_, opts...)
44191	res, err := c.doRequest("json")
44192	if res != nil && res.StatusCode == http.StatusNotModified {
44193		if res.Body != nil {
44194			res.Body.Close()
44195		}
44196		return nil, &googleapi.Error{
44197			Code:   res.StatusCode,
44198			Header: res.Header,
44199		}
44200	}
44201	if err != nil {
44202		return nil, err
44203	}
44204	defer googleapi.CloseBody(res)
44205	if err := googleapi.CheckResponse(res); err != nil {
44206		return nil, err
44207	}
44208	ret := &GoogleCloudDialogflowV2ListContextsResponse{
44209		ServerResponse: googleapi.ServerResponse{
44210			Header:         res.Header,
44211			HTTPStatusCode: res.StatusCode,
44212		},
44213	}
44214	target := &ret
44215	if err := gensupport.DecodeResponse(target, res); err != nil {
44216		return nil, err
44217	}
44218	return ret, nil
44219	// {
44220	//   "description": "Returns the list of all contexts in the specified session.",
44221	//   "flatPath": "v2/projects/{projectsId}/locations/{locationsId}/agent/sessions/{sessionsId}/contexts",
44222	//   "httpMethod": "GET",
44223	//   "id": "dialogflow.projects.locations.agent.sessions.contexts.list",
44224	//   "parameterOrder": [
44225	//     "parent"
44226	//   ],
44227	//   "parameters": {
44228	//     "pageSize": {
44229	//       "description": "Optional. The maximum number of items to return in a single page. By default 100 and at most 1000.",
44230	//       "format": "int32",
44231	//       "location": "query",
44232	//       "type": "integer"
44233	//     },
44234	//     "pageToken": {
44235	//       "description": "Optional. The next_page_token value returned from a previous list request.",
44236	//       "location": "query",
44237	//       "type": "string"
44238	//     },
44239	//     "parent": {
44240	//       "description": "Required. The session to list all contexts from. Format: `projects//agent/sessions/` or `projects//agent/environments//users//sessions/`. If `Environment ID` is not specified, we assume default 'draft' environment. If `User ID` is not specified, we assume default '-' user.",
44241	//       "location": "path",
44242	//       "pattern": "^projects/[^/]+/locations/[^/]+/agent/sessions/[^/]+$",
44243	//       "required": true,
44244	//       "type": "string"
44245	//     }
44246	//   },
44247	//   "path": "v2/{+parent}/contexts",
44248	//   "response": {
44249	//     "$ref": "GoogleCloudDialogflowV2ListContextsResponse"
44250	//   },
44251	//   "scopes": [
44252	//     "https://www.googleapis.com/auth/cloud-platform",
44253	//     "https://www.googleapis.com/auth/dialogflow"
44254	//   ]
44255	// }
44256
44257}
44258
44259// Pages invokes f for each page of results.
44260// A non-nil error returned from f will halt the iteration.
44261// The provided context supersedes any context provided to the Context method.
44262func (c *ProjectsLocationsAgentSessionsContextsListCall) Pages(ctx context.Context, f func(*GoogleCloudDialogflowV2ListContextsResponse) error) error {
44263	c.ctx_ = ctx
44264	defer c.PageToken(c.urlParams_.Get("pageToken")) // reset paging to original point
44265	for {
44266		x, err := c.Do()
44267		if err != nil {
44268			return err
44269		}
44270		if err := f(x); err != nil {
44271			return err
44272		}
44273		if x.NextPageToken == "" {
44274			return nil
44275		}
44276		c.PageToken(x.NextPageToken)
44277	}
44278}
44279
44280// method id "dialogflow.projects.locations.agent.sessions.contexts.patch":
44281
44282type ProjectsLocationsAgentSessionsContextsPatchCall struct {
44283	s                              *Service
44284	nameid                         string
44285	googleclouddialogflowv2context *GoogleCloudDialogflowV2Context
44286	urlParams_                     gensupport.URLParams
44287	ctx_                           context.Context
44288	header_                        http.Header
44289}
44290
44291// Patch: Updates the specified context.
44292//
44293// - name: The unique identifier of the context. Format:
44294//   `projects//agent/sessions//contexts/`, or
44295//   `projects//agent/environments//users//sessions//contexts/`. The
44296//   `Context ID` is always converted to lowercase, may only contain
44297//   characters in a-zA-Z0-9_-% and may be at most 250 bytes long. If
44298//   `Environment ID` is not specified, we assume default 'draft'
44299//   environment. If `User ID` is not specified, we assume default '-'
44300//   user. The following context names are reserved for internal use by
44301//   Dialogflow. You should not use these contexts or create contexts
44302//   with these names: * `__system_counters__` * `*_id_dialog_context` *
44303//   `*_dialog_params_size`.
44304func (r *ProjectsLocationsAgentSessionsContextsService) Patch(nameid string, googleclouddialogflowv2context *GoogleCloudDialogflowV2Context) *ProjectsLocationsAgentSessionsContextsPatchCall {
44305	c := &ProjectsLocationsAgentSessionsContextsPatchCall{s: r.s, urlParams_: make(gensupport.URLParams)}
44306	c.nameid = nameid
44307	c.googleclouddialogflowv2context = googleclouddialogflowv2context
44308	return c
44309}
44310
44311// UpdateMask sets the optional parameter "updateMask": The mask to
44312// control which fields get updated.
44313func (c *ProjectsLocationsAgentSessionsContextsPatchCall) UpdateMask(updateMask string) *ProjectsLocationsAgentSessionsContextsPatchCall {
44314	c.urlParams_.Set("updateMask", updateMask)
44315	return c
44316}
44317
44318// Fields allows partial responses to be retrieved. See
44319// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
44320// for more information.
44321func (c *ProjectsLocationsAgentSessionsContextsPatchCall) Fields(s ...googleapi.Field) *ProjectsLocationsAgentSessionsContextsPatchCall {
44322	c.urlParams_.Set("fields", googleapi.CombineFields(s))
44323	return c
44324}
44325
44326// Context sets the context to be used in this call's Do method. Any
44327// pending HTTP request will be aborted if the provided context is
44328// canceled.
44329func (c *ProjectsLocationsAgentSessionsContextsPatchCall) Context(ctx context.Context) *ProjectsLocationsAgentSessionsContextsPatchCall {
44330	c.ctx_ = ctx
44331	return c
44332}
44333
44334// Header returns an http.Header that can be modified by the caller to
44335// add HTTP headers to the request.
44336func (c *ProjectsLocationsAgentSessionsContextsPatchCall) Header() http.Header {
44337	if c.header_ == nil {
44338		c.header_ = make(http.Header)
44339	}
44340	return c.header_
44341}
44342
44343func (c *ProjectsLocationsAgentSessionsContextsPatchCall) doRequest(alt string) (*http.Response, error) {
44344	reqHeaders := make(http.Header)
44345	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20211027")
44346	for k, v := range c.header_ {
44347		reqHeaders[k] = v
44348	}
44349	reqHeaders.Set("User-Agent", c.s.userAgent())
44350	var body io.Reader = nil
44351	body, err := googleapi.WithoutDataWrapper.JSONReader(c.googleclouddialogflowv2context)
44352	if err != nil {
44353		return nil, err
44354	}
44355	reqHeaders.Set("Content-Type", "application/json")
44356	c.urlParams_.Set("alt", alt)
44357	c.urlParams_.Set("prettyPrint", "false")
44358	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+name}")
44359	urls += "?" + c.urlParams_.Encode()
44360	req, err := http.NewRequest("PATCH", urls, body)
44361	if err != nil {
44362		return nil, err
44363	}
44364	req.Header = reqHeaders
44365	googleapi.Expand(req.URL, map[string]string{
44366		"name": c.nameid,
44367	})
44368	return gensupport.SendRequest(c.ctx_, c.s.client, req)
44369}
44370
44371// Do executes the "dialogflow.projects.locations.agent.sessions.contexts.patch" call.
44372// Exactly one of *GoogleCloudDialogflowV2Context or error will be
44373// non-nil. Any non-2xx status code is an error. Response headers are in
44374// either *GoogleCloudDialogflowV2Context.ServerResponse.Header or (if a
44375// response was returned at all) in error.(*googleapi.Error).Header. Use
44376// googleapi.IsNotModified to check whether the returned error was
44377// because http.StatusNotModified was returned.
44378func (c *ProjectsLocationsAgentSessionsContextsPatchCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDialogflowV2Context, error) {
44379	gensupport.SetOptions(c.urlParams_, opts...)
44380	res, err := c.doRequest("json")
44381	if res != nil && res.StatusCode == http.StatusNotModified {
44382		if res.Body != nil {
44383			res.Body.Close()
44384		}
44385		return nil, &googleapi.Error{
44386			Code:   res.StatusCode,
44387			Header: res.Header,
44388		}
44389	}
44390	if err != nil {
44391		return nil, err
44392	}
44393	defer googleapi.CloseBody(res)
44394	if err := googleapi.CheckResponse(res); err != nil {
44395		return nil, err
44396	}
44397	ret := &GoogleCloudDialogflowV2Context{
44398		ServerResponse: googleapi.ServerResponse{
44399			Header:         res.Header,
44400			HTTPStatusCode: res.StatusCode,
44401		},
44402	}
44403	target := &ret
44404	if err := gensupport.DecodeResponse(target, res); err != nil {
44405		return nil, err
44406	}
44407	return ret, nil
44408	// {
44409	//   "description": "Updates the specified context.",
44410	//   "flatPath": "v2/projects/{projectsId}/locations/{locationsId}/agent/sessions/{sessionsId}/contexts/{contextsId}",
44411	//   "httpMethod": "PATCH",
44412	//   "id": "dialogflow.projects.locations.agent.sessions.contexts.patch",
44413	//   "parameterOrder": [
44414	//     "name"
44415	//   ],
44416	//   "parameters": {
44417	//     "name": {
44418	//       "description": "Required. The unique identifier of the context. Format: `projects//agent/sessions//contexts/`, or `projects//agent/environments//users//sessions//contexts/`. The `Context ID` is always converted to lowercase, may only contain characters in a-zA-Z0-9_-% and may be at most 250 bytes long. If `Environment ID` is not specified, we assume default 'draft' environment. If `User ID` is not specified, we assume default '-' user. The following context names are reserved for internal use by Dialogflow. You should not use these contexts or create contexts with these names: * `__system_counters__` * `*_id_dialog_context` * `*_dialog_params_size`",
44419	//       "location": "path",
44420	//       "pattern": "^projects/[^/]+/locations/[^/]+/agent/sessions/[^/]+/contexts/[^/]+$",
44421	//       "required": true,
44422	//       "type": "string"
44423	//     },
44424	//     "updateMask": {
44425	//       "description": "Optional. The mask to control which fields get updated.",
44426	//       "format": "google-fieldmask",
44427	//       "location": "query",
44428	//       "type": "string"
44429	//     }
44430	//   },
44431	//   "path": "v2/{+name}",
44432	//   "request": {
44433	//     "$ref": "GoogleCloudDialogflowV2Context"
44434	//   },
44435	//   "response": {
44436	//     "$ref": "GoogleCloudDialogflowV2Context"
44437	//   },
44438	//   "scopes": [
44439	//     "https://www.googleapis.com/auth/cloud-platform",
44440	//     "https://www.googleapis.com/auth/dialogflow"
44441	//   ]
44442	// }
44443
44444}
44445
44446// method id "dialogflow.projects.locations.agent.sessions.entityTypes.create":
44447
44448type ProjectsLocationsAgentSessionsEntityTypesCreateCall struct {
44449	s                                        *Service
44450	parent                                   string
44451	googleclouddialogflowv2sessionentitytype *GoogleCloudDialogflowV2SessionEntityType
44452	urlParams_                               gensupport.URLParams
44453	ctx_                                     context.Context
44454	header_                                  http.Header
44455}
44456
44457// Create: Creates a session entity type. If the specified session
44458// entity type already exists, overrides the session entity type. This
44459// method doesn't work with Google Assistant integration. Contact
44460// Dialogflow support if you need to use session entities with Google
44461// Assistant integration.
44462//
44463// - parent: The session to create a session entity type for. Format:
44464//   `projects//agent/sessions/` or
44465//   `projects//agent/environments//users// sessions/`. If `Environment
44466//   ID` is not specified, we assume default 'draft' environment. If
44467//   `User ID` is not specified, we assume default '-' user.
44468func (r *ProjectsLocationsAgentSessionsEntityTypesService) Create(parent string, googleclouddialogflowv2sessionentitytype *GoogleCloudDialogflowV2SessionEntityType) *ProjectsLocationsAgentSessionsEntityTypesCreateCall {
44469	c := &ProjectsLocationsAgentSessionsEntityTypesCreateCall{s: r.s, urlParams_: make(gensupport.URLParams)}
44470	c.parent = parent
44471	c.googleclouddialogflowv2sessionentitytype = googleclouddialogflowv2sessionentitytype
44472	return c
44473}
44474
44475// Fields allows partial responses to be retrieved. See
44476// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
44477// for more information.
44478func (c *ProjectsLocationsAgentSessionsEntityTypesCreateCall) Fields(s ...googleapi.Field) *ProjectsLocationsAgentSessionsEntityTypesCreateCall {
44479	c.urlParams_.Set("fields", googleapi.CombineFields(s))
44480	return c
44481}
44482
44483// Context sets the context to be used in this call's Do method. Any
44484// pending HTTP request will be aborted if the provided context is
44485// canceled.
44486func (c *ProjectsLocationsAgentSessionsEntityTypesCreateCall) Context(ctx context.Context) *ProjectsLocationsAgentSessionsEntityTypesCreateCall {
44487	c.ctx_ = ctx
44488	return c
44489}
44490
44491// Header returns an http.Header that can be modified by the caller to
44492// add HTTP headers to the request.
44493func (c *ProjectsLocationsAgentSessionsEntityTypesCreateCall) Header() http.Header {
44494	if c.header_ == nil {
44495		c.header_ = make(http.Header)
44496	}
44497	return c.header_
44498}
44499
44500func (c *ProjectsLocationsAgentSessionsEntityTypesCreateCall) doRequest(alt string) (*http.Response, error) {
44501	reqHeaders := make(http.Header)
44502	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20211027")
44503	for k, v := range c.header_ {
44504		reqHeaders[k] = v
44505	}
44506	reqHeaders.Set("User-Agent", c.s.userAgent())
44507	var body io.Reader = nil
44508	body, err := googleapi.WithoutDataWrapper.JSONReader(c.googleclouddialogflowv2sessionentitytype)
44509	if err != nil {
44510		return nil, err
44511	}
44512	reqHeaders.Set("Content-Type", "application/json")
44513	c.urlParams_.Set("alt", alt)
44514	c.urlParams_.Set("prettyPrint", "false")
44515	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+parent}/entityTypes")
44516	urls += "?" + c.urlParams_.Encode()
44517	req, err := http.NewRequest("POST", urls, body)
44518	if err != nil {
44519		return nil, err
44520	}
44521	req.Header = reqHeaders
44522	googleapi.Expand(req.URL, map[string]string{
44523		"parent": c.parent,
44524	})
44525	return gensupport.SendRequest(c.ctx_, c.s.client, req)
44526}
44527
44528// Do executes the "dialogflow.projects.locations.agent.sessions.entityTypes.create" call.
44529// Exactly one of *GoogleCloudDialogflowV2SessionEntityType or error
44530// will be non-nil. Any non-2xx status code is an error. Response
44531// headers are in either
44532// *GoogleCloudDialogflowV2SessionEntityType.ServerResponse.Header or
44533// (if a response was returned at all) in
44534// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
44535// whether the returned error was because http.StatusNotModified was
44536// returned.
44537func (c *ProjectsLocationsAgentSessionsEntityTypesCreateCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDialogflowV2SessionEntityType, error) {
44538	gensupport.SetOptions(c.urlParams_, opts...)
44539	res, err := c.doRequest("json")
44540	if res != nil && res.StatusCode == http.StatusNotModified {
44541		if res.Body != nil {
44542			res.Body.Close()
44543		}
44544		return nil, &googleapi.Error{
44545			Code:   res.StatusCode,
44546			Header: res.Header,
44547		}
44548	}
44549	if err != nil {
44550		return nil, err
44551	}
44552	defer googleapi.CloseBody(res)
44553	if err := googleapi.CheckResponse(res); err != nil {
44554		return nil, err
44555	}
44556	ret := &GoogleCloudDialogflowV2SessionEntityType{
44557		ServerResponse: googleapi.ServerResponse{
44558			Header:         res.Header,
44559			HTTPStatusCode: res.StatusCode,
44560		},
44561	}
44562	target := &ret
44563	if err := gensupport.DecodeResponse(target, res); err != nil {
44564		return nil, err
44565	}
44566	return ret, nil
44567	// {
44568	//   "description": "Creates a session entity type. If the specified session entity type already exists, overrides the session entity type. This method doesn't work with Google Assistant integration. Contact Dialogflow support if you need to use session entities with Google Assistant integration.",
44569	//   "flatPath": "v2/projects/{projectsId}/locations/{locationsId}/agent/sessions/{sessionsId}/entityTypes",
44570	//   "httpMethod": "POST",
44571	//   "id": "dialogflow.projects.locations.agent.sessions.entityTypes.create",
44572	//   "parameterOrder": [
44573	//     "parent"
44574	//   ],
44575	//   "parameters": {
44576	//     "parent": {
44577	//       "description": "Required. The session to create a session entity type for. Format: `projects//agent/sessions/` or `projects//agent/environments//users// sessions/`. If `Environment ID` is not specified, we assume default 'draft' environment. If `User ID` is not specified, we assume default '-' user.",
44578	//       "location": "path",
44579	//       "pattern": "^projects/[^/]+/locations/[^/]+/agent/sessions/[^/]+$",
44580	//       "required": true,
44581	//       "type": "string"
44582	//     }
44583	//   },
44584	//   "path": "v2/{+parent}/entityTypes",
44585	//   "request": {
44586	//     "$ref": "GoogleCloudDialogflowV2SessionEntityType"
44587	//   },
44588	//   "response": {
44589	//     "$ref": "GoogleCloudDialogflowV2SessionEntityType"
44590	//   },
44591	//   "scopes": [
44592	//     "https://www.googleapis.com/auth/cloud-platform",
44593	//     "https://www.googleapis.com/auth/dialogflow"
44594	//   ]
44595	// }
44596
44597}
44598
44599// method id "dialogflow.projects.locations.agent.sessions.entityTypes.delete":
44600
44601type ProjectsLocationsAgentSessionsEntityTypesDeleteCall struct {
44602	s          *Service
44603	name       string
44604	urlParams_ gensupport.URLParams
44605	ctx_       context.Context
44606	header_    http.Header
44607}
44608
44609// Delete: Deletes the specified session entity type. This method
44610// doesn't work with Google Assistant integration. Contact Dialogflow
44611// support if you need to use session entities with Google Assistant
44612// integration.
44613//
44614// - name: The name of the entity type to delete. Format:
44615//   `projects//agent/sessions//entityTypes/` or
44616//   `projects//agent/environments//users//sessions//entityTypes/`. If
44617//   `Environment ID` is not specified, we assume default 'draft'
44618//   environment. If `User ID` is not specified, we assume default '-'
44619//   user.
44620func (r *ProjectsLocationsAgentSessionsEntityTypesService) Delete(name string) *ProjectsLocationsAgentSessionsEntityTypesDeleteCall {
44621	c := &ProjectsLocationsAgentSessionsEntityTypesDeleteCall{s: r.s, urlParams_: make(gensupport.URLParams)}
44622	c.name = name
44623	return c
44624}
44625
44626// Fields allows partial responses to be retrieved. See
44627// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
44628// for more information.
44629func (c *ProjectsLocationsAgentSessionsEntityTypesDeleteCall) Fields(s ...googleapi.Field) *ProjectsLocationsAgentSessionsEntityTypesDeleteCall {
44630	c.urlParams_.Set("fields", googleapi.CombineFields(s))
44631	return c
44632}
44633
44634// Context sets the context to be used in this call's Do method. Any
44635// pending HTTP request will be aborted if the provided context is
44636// canceled.
44637func (c *ProjectsLocationsAgentSessionsEntityTypesDeleteCall) Context(ctx context.Context) *ProjectsLocationsAgentSessionsEntityTypesDeleteCall {
44638	c.ctx_ = ctx
44639	return c
44640}
44641
44642// Header returns an http.Header that can be modified by the caller to
44643// add HTTP headers to the request.
44644func (c *ProjectsLocationsAgentSessionsEntityTypesDeleteCall) Header() http.Header {
44645	if c.header_ == nil {
44646		c.header_ = make(http.Header)
44647	}
44648	return c.header_
44649}
44650
44651func (c *ProjectsLocationsAgentSessionsEntityTypesDeleteCall) doRequest(alt string) (*http.Response, error) {
44652	reqHeaders := make(http.Header)
44653	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20211027")
44654	for k, v := range c.header_ {
44655		reqHeaders[k] = v
44656	}
44657	reqHeaders.Set("User-Agent", c.s.userAgent())
44658	var body io.Reader = nil
44659	c.urlParams_.Set("alt", alt)
44660	c.urlParams_.Set("prettyPrint", "false")
44661	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+name}")
44662	urls += "?" + c.urlParams_.Encode()
44663	req, err := http.NewRequest("DELETE", urls, body)
44664	if err != nil {
44665		return nil, err
44666	}
44667	req.Header = reqHeaders
44668	googleapi.Expand(req.URL, map[string]string{
44669		"name": c.name,
44670	})
44671	return gensupport.SendRequest(c.ctx_, c.s.client, req)
44672}
44673
44674// Do executes the "dialogflow.projects.locations.agent.sessions.entityTypes.delete" call.
44675// Exactly one of *GoogleProtobufEmpty or error will be non-nil. Any
44676// non-2xx status code is an error. Response headers are in either
44677// *GoogleProtobufEmpty.ServerResponse.Header or (if a response was
44678// returned at all) in error.(*googleapi.Error).Header. Use
44679// googleapi.IsNotModified to check whether the returned error was
44680// because http.StatusNotModified was returned.
44681func (c *ProjectsLocationsAgentSessionsEntityTypesDeleteCall) Do(opts ...googleapi.CallOption) (*GoogleProtobufEmpty, error) {
44682	gensupport.SetOptions(c.urlParams_, opts...)
44683	res, err := c.doRequest("json")
44684	if res != nil && res.StatusCode == http.StatusNotModified {
44685		if res.Body != nil {
44686			res.Body.Close()
44687		}
44688		return nil, &googleapi.Error{
44689			Code:   res.StatusCode,
44690			Header: res.Header,
44691		}
44692	}
44693	if err != nil {
44694		return nil, err
44695	}
44696	defer googleapi.CloseBody(res)
44697	if err := googleapi.CheckResponse(res); err != nil {
44698		return nil, err
44699	}
44700	ret := &GoogleProtobufEmpty{
44701		ServerResponse: googleapi.ServerResponse{
44702			Header:         res.Header,
44703			HTTPStatusCode: res.StatusCode,
44704		},
44705	}
44706	target := &ret
44707	if err := gensupport.DecodeResponse(target, res); err != nil {
44708		return nil, err
44709	}
44710	return ret, nil
44711	// {
44712	//   "description": "Deletes the specified session entity type. This method doesn't work with Google Assistant integration. Contact Dialogflow support if you need to use session entities with Google Assistant integration.",
44713	//   "flatPath": "v2/projects/{projectsId}/locations/{locationsId}/agent/sessions/{sessionsId}/entityTypes/{entityTypesId}",
44714	//   "httpMethod": "DELETE",
44715	//   "id": "dialogflow.projects.locations.agent.sessions.entityTypes.delete",
44716	//   "parameterOrder": [
44717	//     "name"
44718	//   ],
44719	//   "parameters": {
44720	//     "name": {
44721	//       "description": "Required. The name of the entity type to delete. Format: `projects//agent/sessions//entityTypes/` or `projects//agent/environments//users//sessions//entityTypes/`. If `Environment ID` is not specified, we assume default 'draft' environment. If `User ID` is not specified, we assume default '-' user.",
44722	//       "location": "path",
44723	//       "pattern": "^projects/[^/]+/locations/[^/]+/agent/sessions/[^/]+/entityTypes/[^/]+$",
44724	//       "required": true,
44725	//       "type": "string"
44726	//     }
44727	//   },
44728	//   "path": "v2/{+name}",
44729	//   "response": {
44730	//     "$ref": "GoogleProtobufEmpty"
44731	//   },
44732	//   "scopes": [
44733	//     "https://www.googleapis.com/auth/cloud-platform",
44734	//     "https://www.googleapis.com/auth/dialogflow"
44735	//   ]
44736	// }
44737
44738}
44739
44740// method id "dialogflow.projects.locations.agent.sessions.entityTypes.get":
44741
44742type ProjectsLocationsAgentSessionsEntityTypesGetCall struct {
44743	s            *Service
44744	name         string
44745	urlParams_   gensupport.URLParams
44746	ifNoneMatch_ string
44747	ctx_         context.Context
44748	header_      http.Header
44749}
44750
44751// Get: Retrieves the specified session entity type. This method doesn't
44752// work with Google Assistant integration. Contact Dialogflow support if
44753// you need to use session entities with Google Assistant integration.
44754//
44755// - name: The name of the session entity type. Format:
44756//   `projects//agent/sessions//entityTypes/` or
44757//   `projects//agent/environments//users//sessions//entityTypes/`. If
44758//   `Environment ID` is not specified, we assume default 'draft'
44759//   environment. If `User ID` is not specified, we assume default '-'
44760//   user.
44761func (r *ProjectsLocationsAgentSessionsEntityTypesService) Get(name string) *ProjectsLocationsAgentSessionsEntityTypesGetCall {
44762	c := &ProjectsLocationsAgentSessionsEntityTypesGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
44763	c.name = name
44764	return c
44765}
44766
44767// Fields allows partial responses to be retrieved. See
44768// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
44769// for more information.
44770func (c *ProjectsLocationsAgentSessionsEntityTypesGetCall) Fields(s ...googleapi.Field) *ProjectsLocationsAgentSessionsEntityTypesGetCall {
44771	c.urlParams_.Set("fields", googleapi.CombineFields(s))
44772	return c
44773}
44774
44775// IfNoneMatch sets the optional parameter which makes the operation
44776// fail if the object's ETag matches the given value. This is useful for
44777// getting updates only after the object has changed since the last
44778// request. Use googleapi.IsNotModified to check whether the response
44779// error from Do is the result of In-None-Match.
44780func (c *ProjectsLocationsAgentSessionsEntityTypesGetCall) IfNoneMatch(entityTag string) *ProjectsLocationsAgentSessionsEntityTypesGetCall {
44781	c.ifNoneMatch_ = entityTag
44782	return c
44783}
44784
44785// Context sets the context to be used in this call's Do method. Any
44786// pending HTTP request will be aborted if the provided context is
44787// canceled.
44788func (c *ProjectsLocationsAgentSessionsEntityTypesGetCall) Context(ctx context.Context) *ProjectsLocationsAgentSessionsEntityTypesGetCall {
44789	c.ctx_ = ctx
44790	return c
44791}
44792
44793// Header returns an http.Header that can be modified by the caller to
44794// add HTTP headers to the request.
44795func (c *ProjectsLocationsAgentSessionsEntityTypesGetCall) Header() http.Header {
44796	if c.header_ == nil {
44797		c.header_ = make(http.Header)
44798	}
44799	return c.header_
44800}
44801
44802func (c *ProjectsLocationsAgentSessionsEntityTypesGetCall) doRequest(alt string) (*http.Response, error) {
44803	reqHeaders := make(http.Header)
44804	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20211027")
44805	for k, v := range c.header_ {
44806		reqHeaders[k] = v
44807	}
44808	reqHeaders.Set("User-Agent", c.s.userAgent())
44809	if c.ifNoneMatch_ != "" {
44810		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
44811	}
44812	var body io.Reader = nil
44813	c.urlParams_.Set("alt", alt)
44814	c.urlParams_.Set("prettyPrint", "false")
44815	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+name}")
44816	urls += "?" + c.urlParams_.Encode()
44817	req, err := http.NewRequest("GET", urls, body)
44818	if err != nil {
44819		return nil, err
44820	}
44821	req.Header = reqHeaders
44822	googleapi.Expand(req.URL, map[string]string{
44823		"name": c.name,
44824	})
44825	return gensupport.SendRequest(c.ctx_, c.s.client, req)
44826}
44827
44828// Do executes the "dialogflow.projects.locations.agent.sessions.entityTypes.get" call.
44829// Exactly one of *GoogleCloudDialogflowV2SessionEntityType or error
44830// will be non-nil. Any non-2xx status code is an error. Response
44831// headers are in either
44832// *GoogleCloudDialogflowV2SessionEntityType.ServerResponse.Header or
44833// (if a response was returned at all) in
44834// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
44835// whether the returned error was because http.StatusNotModified was
44836// returned.
44837func (c *ProjectsLocationsAgentSessionsEntityTypesGetCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDialogflowV2SessionEntityType, error) {
44838	gensupport.SetOptions(c.urlParams_, opts...)
44839	res, err := c.doRequest("json")
44840	if res != nil && res.StatusCode == http.StatusNotModified {
44841		if res.Body != nil {
44842			res.Body.Close()
44843		}
44844		return nil, &googleapi.Error{
44845			Code:   res.StatusCode,
44846			Header: res.Header,
44847		}
44848	}
44849	if err != nil {
44850		return nil, err
44851	}
44852	defer googleapi.CloseBody(res)
44853	if err := googleapi.CheckResponse(res); err != nil {
44854		return nil, err
44855	}
44856	ret := &GoogleCloudDialogflowV2SessionEntityType{
44857		ServerResponse: googleapi.ServerResponse{
44858			Header:         res.Header,
44859			HTTPStatusCode: res.StatusCode,
44860		},
44861	}
44862	target := &ret
44863	if err := gensupport.DecodeResponse(target, res); err != nil {
44864		return nil, err
44865	}
44866	return ret, nil
44867	// {
44868	//   "description": "Retrieves the specified session entity type. This method doesn't work with Google Assistant integration. Contact Dialogflow support if you need to use session entities with Google Assistant integration.",
44869	//   "flatPath": "v2/projects/{projectsId}/locations/{locationsId}/agent/sessions/{sessionsId}/entityTypes/{entityTypesId}",
44870	//   "httpMethod": "GET",
44871	//   "id": "dialogflow.projects.locations.agent.sessions.entityTypes.get",
44872	//   "parameterOrder": [
44873	//     "name"
44874	//   ],
44875	//   "parameters": {
44876	//     "name": {
44877	//       "description": "Required. The name of the session entity type. Format: `projects//agent/sessions//entityTypes/` or `projects//agent/environments//users//sessions//entityTypes/`. If `Environment ID` is not specified, we assume default 'draft' environment. If `User ID` is not specified, we assume default '-' user.",
44878	//       "location": "path",
44879	//       "pattern": "^projects/[^/]+/locations/[^/]+/agent/sessions/[^/]+/entityTypes/[^/]+$",
44880	//       "required": true,
44881	//       "type": "string"
44882	//     }
44883	//   },
44884	//   "path": "v2/{+name}",
44885	//   "response": {
44886	//     "$ref": "GoogleCloudDialogflowV2SessionEntityType"
44887	//   },
44888	//   "scopes": [
44889	//     "https://www.googleapis.com/auth/cloud-platform",
44890	//     "https://www.googleapis.com/auth/dialogflow"
44891	//   ]
44892	// }
44893
44894}
44895
44896// method id "dialogflow.projects.locations.agent.sessions.entityTypes.list":
44897
44898type ProjectsLocationsAgentSessionsEntityTypesListCall struct {
44899	s            *Service
44900	parent       string
44901	urlParams_   gensupport.URLParams
44902	ifNoneMatch_ string
44903	ctx_         context.Context
44904	header_      http.Header
44905}
44906
44907// List: Returns the list of all session entity types in the specified
44908// session. This method doesn't work with Google Assistant integration.
44909// Contact Dialogflow support if you need to use session entities with
44910// Google Assistant integration.
44911//
44912// - parent: The session to list all session entity types from. Format:
44913//   `projects//agent/sessions/` or
44914//   `projects//agent/environments//users// sessions/`. If `Environment
44915//   ID` is not specified, we assume default 'draft' environment. If
44916//   `User ID` is not specified, we assume default '-' user.
44917func (r *ProjectsLocationsAgentSessionsEntityTypesService) List(parent string) *ProjectsLocationsAgentSessionsEntityTypesListCall {
44918	c := &ProjectsLocationsAgentSessionsEntityTypesListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
44919	c.parent = parent
44920	return c
44921}
44922
44923// PageSize sets the optional parameter "pageSize": The maximum number
44924// of items to return in a single page. By default 100 and at most 1000.
44925func (c *ProjectsLocationsAgentSessionsEntityTypesListCall) PageSize(pageSize int64) *ProjectsLocationsAgentSessionsEntityTypesListCall {
44926	c.urlParams_.Set("pageSize", fmt.Sprint(pageSize))
44927	return c
44928}
44929
44930// PageToken sets the optional parameter "pageToken": The
44931// next_page_token value returned from a previous list request.
44932func (c *ProjectsLocationsAgentSessionsEntityTypesListCall) PageToken(pageToken string) *ProjectsLocationsAgentSessionsEntityTypesListCall {
44933	c.urlParams_.Set("pageToken", pageToken)
44934	return c
44935}
44936
44937// Fields allows partial responses to be retrieved. See
44938// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
44939// for more information.
44940func (c *ProjectsLocationsAgentSessionsEntityTypesListCall) Fields(s ...googleapi.Field) *ProjectsLocationsAgentSessionsEntityTypesListCall {
44941	c.urlParams_.Set("fields", googleapi.CombineFields(s))
44942	return c
44943}
44944
44945// IfNoneMatch sets the optional parameter which makes the operation
44946// fail if the object's ETag matches the given value. This is useful for
44947// getting updates only after the object has changed since the last
44948// request. Use googleapi.IsNotModified to check whether the response
44949// error from Do is the result of In-None-Match.
44950func (c *ProjectsLocationsAgentSessionsEntityTypesListCall) IfNoneMatch(entityTag string) *ProjectsLocationsAgentSessionsEntityTypesListCall {
44951	c.ifNoneMatch_ = entityTag
44952	return c
44953}
44954
44955// Context sets the context to be used in this call's Do method. Any
44956// pending HTTP request will be aborted if the provided context is
44957// canceled.
44958func (c *ProjectsLocationsAgentSessionsEntityTypesListCall) Context(ctx context.Context) *ProjectsLocationsAgentSessionsEntityTypesListCall {
44959	c.ctx_ = ctx
44960	return c
44961}
44962
44963// Header returns an http.Header that can be modified by the caller to
44964// add HTTP headers to the request.
44965func (c *ProjectsLocationsAgentSessionsEntityTypesListCall) Header() http.Header {
44966	if c.header_ == nil {
44967		c.header_ = make(http.Header)
44968	}
44969	return c.header_
44970}
44971
44972func (c *ProjectsLocationsAgentSessionsEntityTypesListCall) doRequest(alt string) (*http.Response, error) {
44973	reqHeaders := make(http.Header)
44974	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20211027")
44975	for k, v := range c.header_ {
44976		reqHeaders[k] = v
44977	}
44978	reqHeaders.Set("User-Agent", c.s.userAgent())
44979	if c.ifNoneMatch_ != "" {
44980		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
44981	}
44982	var body io.Reader = nil
44983	c.urlParams_.Set("alt", alt)
44984	c.urlParams_.Set("prettyPrint", "false")
44985	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+parent}/entityTypes")
44986	urls += "?" + c.urlParams_.Encode()
44987	req, err := http.NewRequest("GET", urls, body)
44988	if err != nil {
44989		return nil, err
44990	}
44991	req.Header = reqHeaders
44992	googleapi.Expand(req.URL, map[string]string{
44993		"parent": c.parent,
44994	})
44995	return gensupport.SendRequest(c.ctx_, c.s.client, req)
44996}
44997
44998// Do executes the "dialogflow.projects.locations.agent.sessions.entityTypes.list" call.
44999// Exactly one of *GoogleCloudDialogflowV2ListSessionEntityTypesResponse
45000// or error will be non-nil. Any non-2xx status code is an error.
45001// Response headers are in either
45002// *GoogleCloudDialogflowV2ListSessionEntityTypesResponse.ServerResponse.
45003// Header or (if a response was returned at all) in
45004// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
45005// whether the returned error was because http.StatusNotModified was
45006// returned.
45007func (c *ProjectsLocationsAgentSessionsEntityTypesListCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDialogflowV2ListSessionEntityTypesResponse, error) {
45008	gensupport.SetOptions(c.urlParams_, opts...)
45009	res, err := c.doRequest("json")
45010	if res != nil && res.StatusCode == http.StatusNotModified {
45011		if res.Body != nil {
45012			res.Body.Close()
45013		}
45014		return nil, &googleapi.Error{
45015			Code:   res.StatusCode,
45016			Header: res.Header,
45017		}
45018	}
45019	if err != nil {
45020		return nil, err
45021	}
45022	defer googleapi.CloseBody(res)
45023	if err := googleapi.CheckResponse(res); err != nil {
45024		return nil, err
45025	}
45026	ret := &GoogleCloudDialogflowV2ListSessionEntityTypesResponse{
45027		ServerResponse: googleapi.ServerResponse{
45028			Header:         res.Header,
45029			HTTPStatusCode: res.StatusCode,
45030		},
45031	}
45032	target := &ret
45033	if err := gensupport.DecodeResponse(target, res); err != nil {
45034		return nil, err
45035	}
45036	return ret, nil
45037	// {
45038	//   "description": "Returns the list of all session entity types in the specified session. This method doesn't work with Google Assistant integration. Contact Dialogflow support if you need to use session entities with Google Assistant integration.",
45039	//   "flatPath": "v2/projects/{projectsId}/locations/{locationsId}/agent/sessions/{sessionsId}/entityTypes",
45040	//   "httpMethod": "GET",
45041	//   "id": "dialogflow.projects.locations.agent.sessions.entityTypes.list",
45042	//   "parameterOrder": [
45043	//     "parent"
45044	//   ],
45045	//   "parameters": {
45046	//     "pageSize": {
45047	//       "description": "Optional. The maximum number of items to return in a single page. By default 100 and at most 1000.",
45048	//       "format": "int32",
45049	//       "location": "query",
45050	//       "type": "integer"
45051	//     },
45052	//     "pageToken": {
45053	//       "description": "Optional. The next_page_token value returned from a previous list request.",
45054	//       "location": "query",
45055	//       "type": "string"
45056	//     },
45057	//     "parent": {
45058	//       "description": "Required. The session to list all session entity types from. Format: `projects//agent/sessions/` or `projects//agent/environments//users// sessions/`. If `Environment ID` is not specified, we assume default 'draft' environment. If `User ID` is not specified, we assume default '-' user.",
45059	//       "location": "path",
45060	//       "pattern": "^projects/[^/]+/locations/[^/]+/agent/sessions/[^/]+$",
45061	//       "required": true,
45062	//       "type": "string"
45063	//     }
45064	//   },
45065	//   "path": "v2/{+parent}/entityTypes",
45066	//   "response": {
45067	//     "$ref": "GoogleCloudDialogflowV2ListSessionEntityTypesResponse"
45068	//   },
45069	//   "scopes": [
45070	//     "https://www.googleapis.com/auth/cloud-platform",
45071	//     "https://www.googleapis.com/auth/dialogflow"
45072	//   ]
45073	// }
45074
45075}
45076
45077// Pages invokes f for each page of results.
45078// A non-nil error returned from f will halt the iteration.
45079// The provided context supersedes any context provided to the Context method.
45080func (c *ProjectsLocationsAgentSessionsEntityTypesListCall) Pages(ctx context.Context, f func(*GoogleCloudDialogflowV2ListSessionEntityTypesResponse) error) error {
45081	c.ctx_ = ctx
45082	defer c.PageToken(c.urlParams_.Get("pageToken")) // reset paging to original point
45083	for {
45084		x, err := c.Do()
45085		if err != nil {
45086			return err
45087		}
45088		if err := f(x); err != nil {
45089			return err
45090		}
45091		if x.NextPageToken == "" {
45092			return nil
45093		}
45094		c.PageToken(x.NextPageToken)
45095	}
45096}
45097
45098// method id "dialogflow.projects.locations.agent.sessions.entityTypes.patch":
45099
45100type ProjectsLocationsAgentSessionsEntityTypesPatchCall struct {
45101	s                                        *Service
45102	nameid                                   string
45103	googleclouddialogflowv2sessionentitytype *GoogleCloudDialogflowV2SessionEntityType
45104	urlParams_                               gensupport.URLParams
45105	ctx_                                     context.Context
45106	header_                                  http.Header
45107}
45108
45109// Patch: Updates the specified session entity type. This method doesn't
45110// work with Google Assistant integration. Contact Dialogflow support if
45111// you need to use session entities with Google Assistant integration.
45112//
45113// - name: The unique identifier of this session entity type. Format:
45114//   `projects//agent/sessions//entityTypes/`, or
45115//   `projects//agent/environments//users//sessions//entityTypes/`. If
45116//   `Environment ID` is not specified, we assume default 'draft'
45117//   environment. If `User ID` is not specified, we assume default '-'
45118//   user. `` must be the display name of an existing entity type in the
45119//   same agent that will be overridden or supplemented.
45120func (r *ProjectsLocationsAgentSessionsEntityTypesService) Patch(nameid string, googleclouddialogflowv2sessionentitytype *GoogleCloudDialogflowV2SessionEntityType) *ProjectsLocationsAgentSessionsEntityTypesPatchCall {
45121	c := &ProjectsLocationsAgentSessionsEntityTypesPatchCall{s: r.s, urlParams_: make(gensupport.URLParams)}
45122	c.nameid = nameid
45123	c.googleclouddialogflowv2sessionentitytype = googleclouddialogflowv2sessionentitytype
45124	return c
45125}
45126
45127// UpdateMask sets the optional parameter "updateMask": The mask to
45128// control which fields get updated.
45129func (c *ProjectsLocationsAgentSessionsEntityTypesPatchCall) UpdateMask(updateMask string) *ProjectsLocationsAgentSessionsEntityTypesPatchCall {
45130	c.urlParams_.Set("updateMask", updateMask)
45131	return c
45132}
45133
45134// Fields allows partial responses to be retrieved. See
45135// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
45136// for more information.
45137func (c *ProjectsLocationsAgentSessionsEntityTypesPatchCall) Fields(s ...googleapi.Field) *ProjectsLocationsAgentSessionsEntityTypesPatchCall {
45138	c.urlParams_.Set("fields", googleapi.CombineFields(s))
45139	return c
45140}
45141
45142// Context sets the context to be used in this call's Do method. Any
45143// pending HTTP request will be aborted if the provided context is
45144// canceled.
45145func (c *ProjectsLocationsAgentSessionsEntityTypesPatchCall) Context(ctx context.Context) *ProjectsLocationsAgentSessionsEntityTypesPatchCall {
45146	c.ctx_ = ctx
45147	return c
45148}
45149
45150// Header returns an http.Header that can be modified by the caller to
45151// add HTTP headers to the request.
45152func (c *ProjectsLocationsAgentSessionsEntityTypesPatchCall) Header() http.Header {
45153	if c.header_ == nil {
45154		c.header_ = make(http.Header)
45155	}
45156	return c.header_
45157}
45158
45159func (c *ProjectsLocationsAgentSessionsEntityTypesPatchCall) doRequest(alt string) (*http.Response, error) {
45160	reqHeaders := make(http.Header)
45161	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20211027")
45162	for k, v := range c.header_ {
45163		reqHeaders[k] = v
45164	}
45165	reqHeaders.Set("User-Agent", c.s.userAgent())
45166	var body io.Reader = nil
45167	body, err := googleapi.WithoutDataWrapper.JSONReader(c.googleclouddialogflowv2sessionentitytype)
45168	if err != nil {
45169		return nil, err
45170	}
45171	reqHeaders.Set("Content-Type", "application/json")
45172	c.urlParams_.Set("alt", alt)
45173	c.urlParams_.Set("prettyPrint", "false")
45174	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+name}")
45175	urls += "?" + c.urlParams_.Encode()
45176	req, err := http.NewRequest("PATCH", urls, body)
45177	if err != nil {
45178		return nil, err
45179	}
45180	req.Header = reqHeaders
45181	googleapi.Expand(req.URL, map[string]string{
45182		"name": c.nameid,
45183	})
45184	return gensupport.SendRequest(c.ctx_, c.s.client, req)
45185}
45186
45187// Do executes the "dialogflow.projects.locations.agent.sessions.entityTypes.patch" call.
45188// Exactly one of *GoogleCloudDialogflowV2SessionEntityType or error
45189// will be non-nil. Any non-2xx status code is an error. Response
45190// headers are in either
45191// *GoogleCloudDialogflowV2SessionEntityType.ServerResponse.Header or
45192// (if a response was returned at all) in
45193// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
45194// whether the returned error was because http.StatusNotModified was
45195// returned.
45196func (c *ProjectsLocationsAgentSessionsEntityTypesPatchCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDialogflowV2SessionEntityType, error) {
45197	gensupport.SetOptions(c.urlParams_, opts...)
45198	res, err := c.doRequest("json")
45199	if res != nil && res.StatusCode == http.StatusNotModified {
45200		if res.Body != nil {
45201			res.Body.Close()
45202		}
45203		return nil, &googleapi.Error{
45204			Code:   res.StatusCode,
45205			Header: res.Header,
45206		}
45207	}
45208	if err != nil {
45209		return nil, err
45210	}
45211	defer googleapi.CloseBody(res)
45212	if err := googleapi.CheckResponse(res); err != nil {
45213		return nil, err
45214	}
45215	ret := &GoogleCloudDialogflowV2SessionEntityType{
45216		ServerResponse: googleapi.ServerResponse{
45217			Header:         res.Header,
45218			HTTPStatusCode: res.StatusCode,
45219		},
45220	}
45221	target := &ret
45222	if err := gensupport.DecodeResponse(target, res); err != nil {
45223		return nil, err
45224	}
45225	return ret, nil
45226	// {
45227	//   "description": "Updates the specified session entity type. This method doesn't work with Google Assistant integration. Contact Dialogflow support if you need to use session entities with Google Assistant integration.",
45228	//   "flatPath": "v2/projects/{projectsId}/locations/{locationsId}/agent/sessions/{sessionsId}/entityTypes/{entityTypesId}",
45229	//   "httpMethod": "PATCH",
45230	//   "id": "dialogflow.projects.locations.agent.sessions.entityTypes.patch",
45231	//   "parameterOrder": [
45232	//     "name"
45233	//   ],
45234	//   "parameters": {
45235	//     "name": {
45236	//       "description": "Required. The unique identifier of this session entity type. Format: `projects//agent/sessions//entityTypes/`, or `projects//agent/environments//users//sessions//entityTypes/`. If `Environment ID` is not specified, we assume default 'draft' environment. If `User ID` is not specified, we assume default '-' user. `` must be the display name of an existing entity type in the same agent that will be overridden or supplemented.",
45237	//       "location": "path",
45238	//       "pattern": "^projects/[^/]+/locations/[^/]+/agent/sessions/[^/]+/entityTypes/[^/]+$",
45239	//       "required": true,
45240	//       "type": "string"
45241	//     },
45242	//     "updateMask": {
45243	//       "description": "Optional. The mask to control which fields get updated.",
45244	//       "format": "google-fieldmask",
45245	//       "location": "query",
45246	//       "type": "string"
45247	//     }
45248	//   },
45249	//   "path": "v2/{+name}",
45250	//   "request": {
45251	//     "$ref": "GoogleCloudDialogflowV2SessionEntityType"
45252	//   },
45253	//   "response": {
45254	//     "$ref": "GoogleCloudDialogflowV2SessionEntityType"
45255	//   },
45256	//   "scopes": [
45257	//     "https://www.googleapis.com/auth/cloud-platform",
45258	//     "https://www.googleapis.com/auth/dialogflow"
45259	//   ]
45260	// }
45261
45262}
45263
45264// method id "dialogflow.projects.locations.agent.versions.create":
45265
45266type ProjectsLocationsAgentVersionsCreateCall struct {
45267	s                              *Service
45268	parent                         string
45269	googleclouddialogflowv2version *GoogleCloudDialogflowV2Version
45270	urlParams_                     gensupport.URLParams
45271	ctx_                           context.Context
45272	header_                        http.Header
45273}
45274
45275// Create: Creates an agent version. The new version points to the agent
45276// instance in the "default" environment.
45277//
45278// - parent: The agent to create a version for. Supported formats: -
45279//   `projects//agent` - `projects//locations//agent`.
45280func (r *ProjectsLocationsAgentVersionsService) Create(parent string, googleclouddialogflowv2version *GoogleCloudDialogflowV2Version) *ProjectsLocationsAgentVersionsCreateCall {
45281	c := &ProjectsLocationsAgentVersionsCreateCall{s: r.s, urlParams_: make(gensupport.URLParams)}
45282	c.parent = parent
45283	c.googleclouddialogflowv2version = googleclouddialogflowv2version
45284	return c
45285}
45286
45287// Fields allows partial responses to be retrieved. See
45288// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
45289// for more information.
45290func (c *ProjectsLocationsAgentVersionsCreateCall) Fields(s ...googleapi.Field) *ProjectsLocationsAgentVersionsCreateCall {
45291	c.urlParams_.Set("fields", googleapi.CombineFields(s))
45292	return c
45293}
45294
45295// Context sets the context to be used in this call's Do method. Any
45296// pending HTTP request will be aborted if the provided context is
45297// canceled.
45298func (c *ProjectsLocationsAgentVersionsCreateCall) Context(ctx context.Context) *ProjectsLocationsAgentVersionsCreateCall {
45299	c.ctx_ = ctx
45300	return c
45301}
45302
45303// Header returns an http.Header that can be modified by the caller to
45304// add HTTP headers to the request.
45305func (c *ProjectsLocationsAgentVersionsCreateCall) Header() http.Header {
45306	if c.header_ == nil {
45307		c.header_ = make(http.Header)
45308	}
45309	return c.header_
45310}
45311
45312func (c *ProjectsLocationsAgentVersionsCreateCall) doRequest(alt string) (*http.Response, error) {
45313	reqHeaders := make(http.Header)
45314	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20211027")
45315	for k, v := range c.header_ {
45316		reqHeaders[k] = v
45317	}
45318	reqHeaders.Set("User-Agent", c.s.userAgent())
45319	var body io.Reader = nil
45320	body, err := googleapi.WithoutDataWrapper.JSONReader(c.googleclouddialogflowv2version)
45321	if err != nil {
45322		return nil, err
45323	}
45324	reqHeaders.Set("Content-Type", "application/json")
45325	c.urlParams_.Set("alt", alt)
45326	c.urlParams_.Set("prettyPrint", "false")
45327	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+parent}/versions")
45328	urls += "?" + c.urlParams_.Encode()
45329	req, err := http.NewRequest("POST", urls, body)
45330	if err != nil {
45331		return nil, err
45332	}
45333	req.Header = reqHeaders
45334	googleapi.Expand(req.URL, map[string]string{
45335		"parent": c.parent,
45336	})
45337	return gensupport.SendRequest(c.ctx_, c.s.client, req)
45338}
45339
45340// Do executes the "dialogflow.projects.locations.agent.versions.create" call.
45341// Exactly one of *GoogleCloudDialogflowV2Version or error will be
45342// non-nil. Any non-2xx status code is an error. Response headers are in
45343// either *GoogleCloudDialogflowV2Version.ServerResponse.Header or (if a
45344// response was returned at all) in error.(*googleapi.Error).Header. Use
45345// googleapi.IsNotModified to check whether the returned error was
45346// because http.StatusNotModified was returned.
45347func (c *ProjectsLocationsAgentVersionsCreateCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDialogflowV2Version, error) {
45348	gensupport.SetOptions(c.urlParams_, opts...)
45349	res, err := c.doRequest("json")
45350	if res != nil && res.StatusCode == http.StatusNotModified {
45351		if res.Body != nil {
45352			res.Body.Close()
45353		}
45354		return nil, &googleapi.Error{
45355			Code:   res.StatusCode,
45356			Header: res.Header,
45357		}
45358	}
45359	if err != nil {
45360		return nil, err
45361	}
45362	defer googleapi.CloseBody(res)
45363	if err := googleapi.CheckResponse(res); err != nil {
45364		return nil, err
45365	}
45366	ret := &GoogleCloudDialogflowV2Version{
45367		ServerResponse: googleapi.ServerResponse{
45368			Header:         res.Header,
45369			HTTPStatusCode: res.StatusCode,
45370		},
45371	}
45372	target := &ret
45373	if err := gensupport.DecodeResponse(target, res); err != nil {
45374		return nil, err
45375	}
45376	return ret, nil
45377	// {
45378	//   "description": "Creates an agent version. The new version points to the agent instance in the \"default\" environment.",
45379	//   "flatPath": "v2/projects/{projectsId}/locations/{locationsId}/agent/versions",
45380	//   "httpMethod": "POST",
45381	//   "id": "dialogflow.projects.locations.agent.versions.create",
45382	//   "parameterOrder": [
45383	//     "parent"
45384	//   ],
45385	//   "parameters": {
45386	//     "parent": {
45387	//       "description": "Required. The agent to create a version for. Supported formats: - `projects//agent` - `projects//locations//agent`",
45388	//       "location": "path",
45389	//       "pattern": "^projects/[^/]+/locations/[^/]+/agent$",
45390	//       "required": true,
45391	//       "type": "string"
45392	//     }
45393	//   },
45394	//   "path": "v2/{+parent}/versions",
45395	//   "request": {
45396	//     "$ref": "GoogleCloudDialogflowV2Version"
45397	//   },
45398	//   "response": {
45399	//     "$ref": "GoogleCloudDialogflowV2Version"
45400	//   },
45401	//   "scopes": [
45402	//     "https://www.googleapis.com/auth/cloud-platform",
45403	//     "https://www.googleapis.com/auth/dialogflow"
45404	//   ]
45405	// }
45406
45407}
45408
45409// method id "dialogflow.projects.locations.agent.versions.delete":
45410
45411type ProjectsLocationsAgentVersionsDeleteCall struct {
45412	s          *Service
45413	name       string
45414	urlParams_ gensupport.URLParams
45415	ctx_       context.Context
45416	header_    http.Header
45417}
45418
45419// Delete: Delete the specified agent version.
45420//
45421// - name: The name of the version to delete. Supported formats: -
45422//   `projects//agent/versions/` -
45423//   `projects//locations//agent/versions/`.
45424func (r *ProjectsLocationsAgentVersionsService) Delete(name string) *ProjectsLocationsAgentVersionsDeleteCall {
45425	c := &ProjectsLocationsAgentVersionsDeleteCall{s: r.s, urlParams_: make(gensupport.URLParams)}
45426	c.name = name
45427	return c
45428}
45429
45430// Fields allows partial responses to be retrieved. See
45431// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
45432// for more information.
45433func (c *ProjectsLocationsAgentVersionsDeleteCall) Fields(s ...googleapi.Field) *ProjectsLocationsAgentVersionsDeleteCall {
45434	c.urlParams_.Set("fields", googleapi.CombineFields(s))
45435	return c
45436}
45437
45438// Context sets the context to be used in this call's Do method. Any
45439// pending HTTP request will be aborted if the provided context is
45440// canceled.
45441func (c *ProjectsLocationsAgentVersionsDeleteCall) Context(ctx context.Context) *ProjectsLocationsAgentVersionsDeleteCall {
45442	c.ctx_ = ctx
45443	return c
45444}
45445
45446// Header returns an http.Header that can be modified by the caller to
45447// add HTTP headers to the request.
45448func (c *ProjectsLocationsAgentVersionsDeleteCall) Header() http.Header {
45449	if c.header_ == nil {
45450		c.header_ = make(http.Header)
45451	}
45452	return c.header_
45453}
45454
45455func (c *ProjectsLocationsAgentVersionsDeleteCall) doRequest(alt string) (*http.Response, error) {
45456	reqHeaders := make(http.Header)
45457	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20211027")
45458	for k, v := range c.header_ {
45459		reqHeaders[k] = v
45460	}
45461	reqHeaders.Set("User-Agent", c.s.userAgent())
45462	var body io.Reader = nil
45463	c.urlParams_.Set("alt", alt)
45464	c.urlParams_.Set("prettyPrint", "false")
45465	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+name}")
45466	urls += "?" + c.urlParams_.Encode()
45467	req, err := http.NewRequest("DELETE", urls, body)
45468	if err != nil {
45469		return nil, err
45470	}
45471	req.Header = reqHeaders
45472	googleapi.Expand(req.URL, map[string]string{
45473		"name": c.name,
45474	})
45475	return gensupport.SendRequest(c.ctx_, c.s.client, req)
45476}
45477
45478// Do executes the "dialogflow.projects.locations.agent.versions.delete" call.
45479// Exactly one of *GoogleProtobufEmpty or error will be non-nil. Any
45480// non-2xx status code is an error. Response headers are in either
45481// *GoogleProtobufEmpty.ServerResponse.Header or (if a response was
45482// returned at all) in error.(*googleapi.Error).Header. Use
45483// googleapi.IsNotModified to check whether the returned error was
45484// because http.StatusNotModified was returned.
45485func (c *ProjectsLocationsAgentVersionsDeleteCall) Do(opts ...googleapi.CallOption) (*GoogleProtobufEmpty, error) {
45486	gensupport.SetOptions(c.urlParams_, opts...)
45487	res, err := c.doRequest("json")
45488	if res != nil && res.StatusCode == http.StatusNotModified {
45489		if res.Body != nil {
45490			res.Body.Close()
45491		}
45492		return nil, &googleapi.Error{
45493			Code:   res.StatusCode,
45494			Header: res.Header,
45495		}
45496	}
45497	if err != nil {
45498		return nil, err
45499	}
45500	defer googleapi.CloseBody(res)
45501	if err := googleapi.CheckResponse(res); err != nil {
45502		return nil, err
45503	}
45504	ret := &GoogleProtobufEmpty{
45505		ServerResponse: googleapi.ServerResponse{
45506			Header:         res.Header,
45507			HTTPStatusCode: res.StatusCode,
45508		},
45509	}
45510	target := &ret
45511	if err := gensupport.DecodeResponse(target, res); err != nil {
45512		return nil, err
45513	}
45514	return ret, nil
45515	// {
45516	//   "description": "Delete the specified agent version.",
45517	//   "flatPath": "v2/projects/{projectsId}/locations/{locationsId}/agent/versions/{versionsId}",
45518	//   "httpMethod": "DELETE",
45519	//   "id": "dialogflow.projects.locations.agent.versions.delete",
45520	//   "parameterOrder": [
45521	//     "name"
45522	//   ],
45523	//   "parameters": {
45524	//     "name": {
45525	//       "description": "Required. The name of the version to delete. Supported formats: - `projects//agent/versions/` - `projects//locations//agent/versions/`",
45526	//       "location": "path",
45527	//       "pattern": "^projects/[^/]+/locations/[^/]+/agent/versions/[^/]+$",
45528	//       "required": true,
45529	//       "type": "string"
45530	//     }
45531	//   },
45532	//   "path": "v2/{+name}",
45533	//   "response": {
45534	//     "$ref": "GoogleProtobufEmpty"
45535	//   },
45536	//   "scopes": [
45537	//     "https://www.googleapis.com/auth/cloud-platform",
45538	//     "https://www.googleapis.com/auth/dialogflow"
45539	//   ]
45540	// }
45541
45542}
45543
45544// method id "dialogflow.projects.locations.agent.versions.get":
45545
45546type ProjectsLocationsAgentVersionsGetCall struct {
45547	s            *Service
45548	name         string
45549	urlParams_   gensupport.URLParams
45550	ifNoneMatch_ string
45551	ctx_         context.Context
45552	header_      http.Header
45553}
45554
45555// Get: Retrieves the specified agent version.
45556//
45557// - name: The name of the version. Supported formats: -
45558//   `projects//agent/versions/` -
45559//   `projects//locations//agent/versions/`.
45560func (r *ProjectsLocationsAgentVersionsService) Get(name string) *ProjectsLocationsAgentVersionsGetCall {
45561	c := &ProjectsLocationsAgentVersionsGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
45562	c.name = name
45563	return c
45564}
45565
45566// Fields allows partial responses to be retrieved. See
45567// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
45568// for more information.
45569func (c *ProjectsLocationsAgentVersionsGetCall) Fields(s ...googleapi.Field) *ProjectsLocationsAgentVersionsGetCall {
45570	c.urlParams_.Set("fields", googleapi.CombineFields(s))
45571	return c
45572}
45573
45574// IfNoneMatch sets the optional parameter which makes the operation
45575// fail if the object's ETag matches the given value. This is useful for
45576// getting updates only after the object has changed since the last
45577// request. Use googleapi.IsNotModified to check whether the response
45578// error from Do is the result of In-None-Match.
45579func (c *ProjectsLocationsAgentVersionsGetCall) IfNoneMatch(entityTag string) *ProjectsLocationsAgentVersionsGetCall {
45580	c.ifNoneMatch_ = entityTag
45581	return c
45582}
45583
45584// Context sets the context to be used in this call's Do method. Any
45585// pending HTTP request will be aborted if the provided context is
45586// canceled.
45587func (c *ProjectsLocationsAgentVersionsGetCall) Context(ctx context.Context) *ProjectsLocationsAgentVersionsGetCall {
45588	c.ctx_ = ctx
45589	return c
45590}
45591
45592// Header returns an http.Header that can be modified by the caller to
45593// add HTTP headers to the request.
45594func (c *ProjectsLocationsAgentVersionsGetCall) Header() http.Header {
45595	if c.header_ == nil {
45596		c.header_ = make(http.Header)
45597	}
45598	return c.header_
45599}
45600
45601func (c *ProjectsLocationsAgentVersionsGetCall) doRequest(alt string) (*http.Response, error) {
45602	reqHeaders := make(http.Header)
45603	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20211027")
45604	for k, v := range c.header_ {
45605		reqHeaders[k] = v
45606	}
45607	reqHeaders.Set("User-Agent", c.s.userAgent())
45608	if c.ifNoneMatch_ != "" {
45609		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
45610	}
45611	var body io.Reader = nil
45612	c.urlParams_.Set("alt", alt)
45613	c.urlParams_.Set("prettyPrint", "false")
45614	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+name}")
45615	urls += "?" + c.urlParams_.Encode()
45616	req, err := http.NewRequest("GET", urls, body)
45617	if err != nil {
45618		return nil, err
45619	}
45620	req.Header = reqHeaders
45621	googleapi.Expand(req.URL, map[string]string{
45622		"name": c.name,
45623	})
45624	return gensupport.SendRequest(c.ctx_, c.s.client, req)
45625}
45626
45627// Do executes the "dialogflow.projects.locations.agent.versions.get" call.
45628// Exactly one of *GoogleCloudDialogflowV2Version or error will be
45629// non-nil. Any non-2xx status code is an error. Response headers are in
45630// either *GoogleCloudDialogflowV2Version.ServerResponse.Header or (if a
45631// response was returned at all) in error.(*googleapi.Error).Header. Use
45632// googleapi.IsNotModified to check whether the returned error was
45633// because http.StatusNotModified was returned.
45634func (c *ProjectsLocationsAgentVersionsGetCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDialogflowV2Version, error) {
45635	gensupport.SetOptions(c.urlParams_, opts...)
45636	res, err := c.doRequest("json")
45637	if res != nil && res.StatusCode == http.StatusNotModified {
45638		if res.Body != nil {
45639			res.Body.Close()
45640		}
45641		return nil, &googleapi.Error{
45642			Code:   res.StatusCode,
45643			Header: res.Header,
45644		}
45645	}
45646	if err != nil {
45647		return nil, err
45648	}
45649	defer googleapi.CloseBody(res)
45650	if err := googleapi.CheckResponse(res); err != nil {
45651		return nil, err
45652	}
45653	ret := &GoogleCloudDialogflowV2Version{
45654		ServerResponse: googleapi.ServerResponse{
45655			Header:         res.Header,
45656			HTTPStatusCode: res.StatusCode,
45657		},
45658	}
45659	target := &ret
45660	if err := gensupport.DecodeResponse(target, res); err != nil {
45661		return nil, err
45662	}
45663	return ret, nil
45664	// {
45665	//   "description": "Retrieves the specified agent version.",
45666	//   "flatPath": "v2/projects/{projectsId}/locations/{locationsId}/agent/versions/{versionsId}",
45667	//   "httpMethod": "GET",
45668	//   "id": "dialogflow.projects.locations.agent.versions.get",
45669	//   "parameterOrder": [
45670	//     "name"
45671	//   ],
45672	//   "parameters": {
45673	//     "name": {
45674	//       "description": "Required. The name of the version. Supported formats: - `projects//agent/versions/` - `projects//locations//agent/versions/`",
45675	//       "location": "path",
45676	//       "pattern": "^projects/[^/]+/locations/[^/]+/agent/versions/[^/]+$",
45677	//       "required": true,
45678	//       "type": "string"
45679	//     }
45680	//   },
45681	//   "path": "v2/{+name}",
45682	//   "response": {
45683	//     "$ref": "GoogleCloudDialogflowV2Version"
45684	//   },
45685	//   "scopes": [
45686	//     "https://www.googleapis.com/auth/cloud-platform",
45687	//     "https://www.googleapis.com/auth/dialogflow"
45688	//   ]
45689	// }
45690
45691}
45692
45693// method id "dialogflow.projects.locations.agent.versions.list":
45694
45695type ProjectsLocationsAgentVersionsListCall struct {
45696	s            *Service
45697	parent       string
45698	urlParams_   gensupport.URLParams
45699	ifNoneMatch_ string
45700	ctx_         context.Context
45701	header_      http.Header
45702}
45703
45704// List: Returns the list of all versions of the specified agent.
45705//
45706// - parent: The agent to list all versions from. Supported formats: -
45707//   `projects//agent` - `projects//locations//agent`.
45708func (r *ProjectsLocationsAgentVersionsService) List(parent string) *ProjectsLocationsAgentVersionsListCall {
45709	c := &ProjectsLocationsAgentVersionsListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
45710	c.parent = parent
45711	return c
45712}
45713
45714// PageSize sets the optional parameter "pageSize": The maximum number
45715// of items to return in a single page. By default 100 and at most 1000.
45716func (c *ProjectsLocationsAgentVersionsListCall) PageSize(pageSize int64) *ProjectsLocationsAgentVersionsListCall {
45717	c.urlParams_.Set("pageSize", fmt.Sprint(pageSize))
45718	return c
45719}
45720
45721// PageToken sets the optional parameter "pageToken": The
45722// next_page_token value returned from a previous list request.
45723func (c *ProjectsLocationsAgentVersionsListCall) PageToken(pageToken string) *ProjectsLocationsAgentVersionsListCall {
45724	c.urlParams_.Set("pageToken", pageToken)
45725	return c
45726}
45727
45728// Fields allows partial responses to be retrieved. See
45729// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
45730// for more information.
45731func (c *ProjectsLocationsAgentVersionsListCall) Fields(s ...googleapi.Field) *ProjectsLocationsAgentVersionsListCall {
45732	c.urlParams_.Set("fields", googleapi.CombineFields(s))
45733	return c
45734}
45735
45736// IfNoneMatch sets the optional parameter which makes the operation
45737// fail if the object's ETag matches the given value. This is useful for
45738// getting updates only after the object has changed since the last
45739// request. Use googleapi.IsNotModified to check whether the response
45740// error from Do is the result of In-None-Match.
45741func (c *ProjectsLocationsAgentVersionsListCall) IfNoneMatch(entityTag string) *ProjectsLocationsAgentVersionsListCall {
45742	c.ifNoneMatch_ = entityTag
45743	return c
45744}
45745
45746// Context sets the context to be used in this call's Do method. Any
45747// pending HTTP request will be aborted if the provided context is
45748// canceled.
45749func (c *ProjectsLocationsAgentVersionsListCall) Context(ctx context.Context) *ProjectsLocationsAgentVersionsListCall {
45750	c.ctx_ = ctx
45751	return c
45752}
45753
45754// Header returns an http.Header that can be modified by the caller to
45755// add HTTP headers to the request.
45756func (c *ProjectsLocationsAgentVersionsListCall) Header() http.Header {
45757	if c.header_ == nil {
45758		c.header_ = make(http.Header)
45759	}
45760	return c.header_
45761}
45762
45763func (c *ProjectsLocationsAgentVersionsListCall) doRequest(alt string) (*http.Response, error) {
45764	reqHeaders := make(http.Header)
45765	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20211027")
45766	for k, v := range c.header_ {
45767		reqHeaders[k] = v
45768	}
45769	reqHeaders.Set("User-Agent", c.s.userAgent())
45770	if c.ifNoneMatch_ != "" {
45771		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
45772	}
45773	var body io.Reader = nil
45774	c.urlParams_.Set("alt", alt)
45775	c.urlParams_.Set("prettyPrint", "false")
45776	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+parent}/versions")
45777	urls += "?" + c.urlParams_.Encode()
45778	req, err := http.NewRequest("GET", urls, body)
45779	if err != nil {
45780		return nil, err
45781	}
45782	req.Header = reqHeaders
45783	googleapi.Expand(req.URL, map[string]string{
45784		"parent": c.parent,
45785	})
45786	return gensupport.SendRequest(c.ctx_, c.s.client, req)
45787}
45788
45789// Do executes the "dialogflow.projects.locations.agent.versions.list" call.
45790// Exactly one of *GoogleCloudDialogflowV2ListVersionsResponse or error
45791// will be non-nil. Any non-2xx status code is an error. Response
45792// headers are in either
45793// *GoogleCloudDialogflowV2ListVersionsResponse.ServerResponse.Header or
45794// (if a response was returned at all) in
45795// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
45796// whether the returned error was because http.StatusNotModified was
45797// returned.
45798func (c *ProjectsLocationsAgentVersionsListCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDialogflowV2ListVersionsResponse, error) {
45799	gensupport.SetOptions(c.urlParams_, opts...)
45800	res, err := c.doRequest("json")
45801	if res != nil && res.StatusCode == http.StatusNotModified {
45802		if res.Body != nil {
45803			res.Body.Close()
45804		}
45805		return nil, &googleapi.Error{
45806			Code:   res.StatusCode,
45807			Header: res.Header,
45808		}
45809	}
45810	if err != nil {
45811		return nil, err
45812	}
45813	defer googleapi.CloseBody(res)
45814	if err := googleapi.CheckResponse(res); err != nil {
45815		return nil, err
45816	}
45817	ret := &GoogleCloudDialogflowV2ListVersionsResponse{
45818		ServerResponse: googleapi.ServerResponse{
45819			Header:         res.Header,
45820			HTTPStatusCode: res.StatusCode,
45821		},
45822	}
45823	target := &ret
45824	if err := gensupport.DecodeResponse(target, res); err != nil {
45825		return nil, err
45826	}
45827	return ret, nil
45828	// {
45829	//   "description": "Returns the list of all versions of the specified agent.",
45830	//   "flatPath": "v2/projects/{projectsId}/locations/{locationsId}/agent/versions",
45831	//   "httpMethod": "GET",
45832	//   "id": "dialogflow.projects.locations.agent.versions.list",
45833	//   "parameterOrder": [
45834	//     "parent"
45835	//   ],
45836	//   "parameters": {
45837	//     "pageSize": {
45838	//       "description": "Optional. The maximum number of items to return in a single page. By default 100 and at most 1000.",
45839	//       "format": "int32",
45840	//       "location": "query",
45841	//       "type": "integer"
45842	//     },
45843	//     "pageToken": {
45844	//       "description": "Optional. The next_page_token value returned from a previous list request.",
45845	//       "location": "query",
45846	//       "type": "string"
45847	//     },
45848	//     "parent": {
45849	//       "description": "Required. The agent to list all versions from. Supported formats: - `projects//agent` - `projects//locations//agent`",
45850	//       "location": "path",
45851	//       "pattern": "^projects/[^/]+/locations/[^/]+/agent$",
45852	//       "required": true,
45853	//       "type": "string"
45854	//     }
45855	//   },
45856	//   "path": "v2/{+parent}/versions",
45857	//   "response": {
45858	//     "$ref": "GoogleCloudDialogflowV2ListVersionsResponse"
45859	//   },
45860	//   "scopes": [
45861	//     "https://www.googleapis.com/auth/cloud-platform",
45862	//     "https://www.googleapis.com/auth/dialogflow"
45863	//   ]
45864	// }
45865
45866}
45867
45868// Pages invokes f for each page of results.
45869// A non-nil error returned from f will halt the iteration.
45870// The provided context supersedes any context provided to the Context method.
45871func (c *ProjectsLocationsAgentVersionsListCall) Pages(ctx context.Context, f func(*GoogleCloudDialogflowV2ListVersionsResponse) error) error {
45872	c.ctx_ = ctx
45873	defer c.PageToken(c.urlParams_.Get("pageToken")) // reset paging to original point
45874	for {
45875		x, err := c.Do()
45876		if err != nil {
45877			return err
45878		}
45879		if err := f(x); err != nil {
45880			return err
45881		}
45882		if x.NextPageToken == "" {
45883			return nil
45884		}
45885		c.PageToken(x.NextPageToken)
45886	}
45887}
45888
45889// method id "dialogflow.projects.locations.agent.versions.patch":
45890
45891type ProjectsLocationsAgentVersionsPatchCall struct {
45892	s                              *Service
45893	nameid                         string
45894	googleclouddialogflowv2version *GoogleCloudDialogflowV2Version
45895	urlParams_                     gensupport.URLParams
45896	ctx_                           context.Context
45897	header_                        http.Header
45898}
45899
45900// Patch: Updates the specified agent version. Note that this method
45901// does not allow you to update the state of the agent the given version
45902// points to. It allows you to update only mutable properties of the
45903// version resource.
45904//
45905// - name: Output only. The unique identifier of this agent version.
45906//   Supported formats: - `projects//agent/versions/` -
45907//   `projects//locations//agent/versions/`.
45908func (r *ProjectsLocationsAgentVersionsService) Patch(nameid string, googleclouddialogflowv2version *GoogleCloudDialogflowV2Version) *ProjectsLocationsAgentVersionsPatchCall {
45909	c := &ProjectsLocationsAgentVersionsPatchCall{s: r.s, urlParams_: make(gensupport.URLParams)}
45910	c.nameid = nameid
45911	c.googleclouddialogflowv2version = googleclouddialogflowv2version
45912	return c
45913}
45914
45915// UpdateMask sets the optional parameter "updateMask": Required. The
45916// mask to control which fields get updated.
45917func (c *ProjectsLocationsAgentVersionsPatchCall) UpdateMask(updateMask string) *ProjectsLocationsAgentVersionsPatchCall {
45918	c.urlParams_.Set("updateMask", updateMask)
45919	return c
45920}
45921
45922// Fields allows partial responses to be retrieved. See
45923// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
45924// for more information.
45925func (c *ProjectsLocationsAgentVersionsPatchCall) Fields(s ...googleapi.Field) *ProjectsLocationsAgentVersionsPatchCall {
45926	c.urlParams_.Set("fields", googleapi.CombineFields(s))
45927	return c
45928}
45929
45930// Context sets the context to be used in this call's Do method. Any
45931// pending HTTP request will be aborted if the provided context is
45932// canceled.
45933func (c *ProjectsLocationsAgentVersionsPatchCall) Context(ctx context.Context) *ProjectsLocationsAgentVersionsPatchCall {
45934	c.ctx_ = ctx
45935	return c
45936}
45937
45938// Header returns an http.Header that can be modified by the caller to
45939// add HTTP headers to the request.
45940func (c *ProjectsLocationsAgentVersionsPatchCall) Header() http.Header {
45941	if c.header_ == nil {
45942		c.header_ = make(http.Header)
45943	}
45944	return c.header_
45945}
45946
45947func (c *ProjectsLocationsAgentVersionsPatchCall) doRequest(alt string) (*http.Response, error) {
45948	reqHeaders := make(http.Header)
45949	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20211027")
45950	for k, v := range c.header_ {
45951		reqHeaders[k] = v
45952	}
45953	reqHeaders.Set("User-Agent", c.s.userAgent())
45954	var body io.Reader = nil
45955	body, err := googleapi.WithoutDataWrapper.JSONReader(c.googleclouddialogflowv2version)
45956	if err != nil {
45957		return nil, err
45958	}
45959	reqHeaders.Set("Content-Type", "application/json")
45960	c.urlParams_.Set("alt", alt)
45961	c.urlParams_.Set("prettyPrint", "false")
45962	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+name}")
45963	urls += "?" + c.urlParams_.Encode()
45964	req, err := http.NewRequest("PATCH", urls, body)
45965	if err != nil {
45966		return nil, err
45967	}
45968	req.Header = reqHeaders
45969	googleapi.Expand(req.URL, map[string]string{
45970		"name": c.nameid,
45971	})
45972	return gensupport.SendRequest(c.ctx_, c.s.client, req)
45973}
45974
45975// Do executes the "dialogflow.projects.locations.agent.versions.patch" call.
45976// Exactly one of *GoogleCloudDialogflowV2Version or error will be
45977// non-nil. Any non-2xx status code is an error. Response headers are in
45978// either *GoogleCloudDialogflowV2Version.ServerResponse.Header or (if a
45979// response was returned at all) in error.(*googleapi.Error).Header. Use
45980// googleapi.IsNotModified to check whether the returned error was
45981// because http.StatusNotModified was returned.
45982func (c *ProjectsLocationsAgentVersionsPatchCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDialogflowV2Version, error) {
45983	gensupport.SetOptions(c.urlParams_, opts...)
45984	res, err := c.doRequest("json")
45985	if res != nil && res.StatusCode == http.StatusNotModified {
45986		if res.Body != nil {
45987			res.Body.Close()
45988		}
45989		return nil, &googleapi.Error{
45990			Code:   res.StatusCode,
45991			Header: res.Header,
45992		}
45993	}
45994	if err != nil {
45995		return nil, err
45996	}
45997	defer googleapi.CloseBody(res)
45998	if err := googleapi.CheckResponse(res); err != nil {
45999		return nil, err
46000	}
46001	ret := &GoogleCloudDialogflowV2Version{
46002		ServerResponse: googleapi.ServerResponse{
46003			Header:         res.Header,
46004			HTTPStatusCode: res.StatusCode,
46005		},
46006	}
46007	target := &ret
46008	if err := gensupport.DecodeResponse(target, res); err != nil {
46009		return nil, err
46010	}
46011	return ret, nil
46012	// {
46013	//   "description": "Updates the specified agent version. Note that this method does not allow you to update the state of the agent the given version points to. It allows you to update only mutable properties of the version resource.",
46014	//   "flatPath": "v2/projects/{projectsId}/locations/{locationsId}/agent/versions/{versionsId}",
46015	//   "httpMethod": "PATCH",
46016	//   "id": "dialogflow.projects.locations.agent.versions.patch",
46017	//   "parameterOrder": [
46018	//     "name"
46019	//   ],
46020	//   "parameters": {
46021	//     "name": {
46022	//       "description": "Output only. The unique identifier of this agent version. Supported formats: - `projects//agent/versions/` - `projects//locations//agent/versions/`",
46023	//       "location": "path",
46024	//       "pattern": "^projects/[^/]+/locations/[^/]+/agent/versions/[^/]+$",
46025	//       "required": true,
46026	//       "type": "string"
46027	//     },
46028	//     "updateMask": {
46029	//       "description": "Required. The mask to control which fields get updated.",
46030	//       "format": "google-fieldmask",
46031	//       "location": "query",
46032	//       "type": "string"
46033	//     }
46034	//   },
46035	//   "path": "v2/{+name}",
46036	//   "request": {
46037	//     "$ref": "GoogleCloudDialogflowV2Version"
46038	//   },
46039	//   "response": {
46040	//     "$ref": "GoogleCloudDialogflowV2Version"
46041	//   },
46042	//   "scopes": [
46043	//     "https://www.googleapis.com/auth/cloud-platform",
46044	//     "https://www.googleapis.com/auth/dialogflow"
46045	//   ]
46046	// }
46047
46048}
46049
46050// method id "dialogflow.projects.locations.answerRecords.list":
46051
46052type ProjectsLocationsAnswerRecordsListCall struct {
46053	s            *Service
46054	parent       string
46055	urlParams_   gensupport.URLParams
46056	ifNoneMatch_ string
46057	ctx_         context.Context
46058	header_      http.Header
46059}
46060
46061// List: Returns the list of all answer records in the specified project
46062// in reverse chronological order.
46063//
46064// - parent: The project to list all answer records for in reverse
46065//   chronological order. Format: `projects//locations/`.
46066func (r *ProjectsLocationsAnswerRecordsService) List(parent string) *ProjectsLocationsAnswerRecordsListCall {
46067	c := &ProjectsLocationsAnswerRecordsListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
46068	c.parent = parent
46069	return c
46070}
46071
46072// Filter sets the optional parameter "filter": Required. Filters to
46073// restrict results to specific answer records. Filter on answer record
46074// type. Currently predicates on `type` is supported, valid values are
46075// `ARTICLE_ANSWER`, `FAQ_ANSWER`. For more information about filtering,
46076// see API Filtering (https://aip.dev/160).
46077func (c *ProjectsLocationsAnswerRecordsListCall) Filter(filter string) *ProjectsLocationsAnswerRecordsListCall {
46078	c.urlParams_.Set("filter", filter)
46079	return c
46080}
46081
46082// PageSize sets the optional parameter "pageSize": The maximum number
46083// of records to return in a single page. The server may return fewer
46084// records than this. If unspecified, we use 10. The maximum is 100.
46085func (c *ProjectsLocationsAnswerRecordsListCall) PageSize(pageSize int64) *ProjectsLocationsAnswerRecordsListCall {
46086	c.urlParams_.Set("pageSize", fmt.Sprint(pageSize))
46087	return c
46088}
46089
46090// PageToken sets the optional parameter "pageToken": The
46091// ListAnswerRecordsResponse.next_page_token value returned from a
46092// previous list request used to continue listing on the next page.
46093func (c *ProjectsLocationsAnswerRecordsListCall) PageToken(pageToken string) *ProjectsLocationsAnswerRecordsListCall {
46094	c.urlParams_.Set("pageToken", pageToken)
46095	return c
46096}
46097
46098// Fields allows partial responses to be retrieved. See
46099// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
46100// for more information.
46101func (c *ProjectsLocationsAnswerRecordsListCall) Fields(s ...googleapi.Field) *ProjectsLocationsAnswerRecordsListCall {
46102	c.urlParams_.Set("fields", googleapi.CombineFields(s))
46103	return c
46104}
46105
46106// IfNoneMatch sets the optional parameter which makes the operation
46107// fail if the object's ETag matches the given value. This is useful for
46108// getting updates only after the object has changed since the last
46109// request. Use googleapi.IsNotModified to check whether the response
46110// error from Do is the result of In-None-Match.
46111func (c *ProjectsLocationsAnswerRecordsListCall) IfNoneMatch(entityTag string) *ProjectsLocationsAnswerRecordsListCall {
46112	c.ifNoneMatch_ = entityTag
46113	return c
46114}
46115
46116// Context sets the context to be used in this call's Do method. Any
46117// pending HTTP request will be aborted if the provided context is
46118// canceled.
46119func (c *ProjectsLocationsAnswerRecordsListCall) Context(ctx context.Context) *ProjectsLocationsAnswerRecordsListCall {
46120	c.ctx_ = ctx
46121	return c
46122}
46123
46124// Header returns an http.Header that can be modified by the caller to
46125// add HTTP headers to the request.
46126func (c *ProjectsLocationsAnswerRecordsListCall) Header() http.Header {
46127	if c.header_ == nil {
46128		c.header_ = make(http.Header)
46129	}
46130	return c.header_
46131}
46132
46133func (c *ProjectsLocationsAnswerRecordsListCall) doRequest(alt string) (*http.Response, error) {
46134	reqHeaders := make(http.Header)
46135	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20211027")
46136	for k, v := range c.header_ {
46137		reqHeaders[k] = v
46138	}
46139	reqHeaders.Set("User-Agent", c.s.userAgent())
46140	if c.ifNoneMatch_ != "" {
46141		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
46142	}
46143	var body io.Reader = nil
46144	c.urlParams_.Set("alt", alt)
46145	c.urlParams_.Set("prettyPrint", "false")
46146	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+parent}/answerRecords")
46147	urls += "?" + c.urlParams_.Encode()
46148	req, err := http.NewRequest("GET", urls, body)
46149	if err != nil {
46150		return nil, err
46151	}
46152	req.Header = reqHeaders
46153	googleapi.Expand(req.URL, map[string]string{
46154		"parent": c.parent,
46155	})
46156	return gensupport.SendRequest(c.ctx_, c.s.client, req)
46157}
46158
46159// Do executes the "dialogflow.projects.locations.answerRecords.list" call.
46160// Exactly one of *GoogleCloudDialogflowV2ListAnswerRecordsResponse or
46161// error will be non-nil. Any non-2xx status code is an error. Response
46162// headers are in either
46163// *GoogleCloudDialogflowV2ListAnswerRecordsResponse.ServerResponse.Heade
46164// r or (if a response was returned at all) in
46165// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
46166// whether the returned error was because http.StatusNotModified was
46167// returned.
46168func (c *ProjectsLocationsAnswerRecordsListCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDialogflowV2ListAnswerRecordsResponse, error) {
46169	gensupport.SetOptions(c.urlParams_, opts...)
46170	res, err := c.doRequest("json")
46171	if res != nil && res.StatusCode == http.StatusNotModified {
46172		if res.Body != nil {
46173			res.Body.Close()
46174		}
46175		return nil, &googleapi.Error{
46176			Code:   res.StatusCode,
46177			Header: res.Header,
46178		}
46179	}
46180	if err != nil {
46181		return nil, err
46182	}
46183	defer googleapi.CloseBody(res)
46184	if err := googleapi.CheckResponse(res); err != nil {
46185		return nil, err
46186	}
46187	ret := &GoogleCloudDialogflowV2ListAnswerRecordsResponse{
46188		ServerResponse: googleapi.ServerResponse{
46189			Header:         res.Header,
46190			HTTPStatusCode: res.StatusCode,
46191		},
46192	}
46193	target := &ret
46194	if err := gensupport.DecodeResponse(target, res); err != nil {
46195		return nil, err
46196	}
46197	return ret, nil
46198	// {
46199	//   "description": "Returns the list of all answer records in the specified project in reverse chronological order.",
46200	//   "flatPath": "v2/projects/{projectsId}/locations/{locationsId}/answerRecords",
46201	//   "httpMethod": "GET",
46202	//   "id": "dialogflow.projects.locations.answerRecords.list",
46203	//   "parameterOrder": [
46204	//     "parent"
46205	//   ],
46206	//   "parameters": {
46207	//     "filter": {
46208	//       "description": "Required. Filters to restrict results to specific answer records. Filter on answer record type. Currently predicates on `type` is supported, valid values are `ARTICLE_ANSWER`, `FAQ_ANSWER`. For more information about filtering, see [API Filtering](https://aip.dev/160).",
46209	//       "location": "query",
46210	//       "type": "string"
46211	//     },
46212	//     "pageSize": {
46213	//       "description": "Optional. The maximum number of records to return in a single page. The server may return fewer records than this. If unspecified, we use 10. The maximum is 100.",
46214	//       "format": "int32",
46215	//       "location": "query",
46216	//       "type": "integer"
46217	//     },
46218	//     "pageToken": {
46219	//       "description": "Optional. The ListAnswerRecordsResponse.next_page_token value returned from a previous list request used to continue listing on the next page.",
46220	//       "location": "query",
46221	//       "type": "string"
46222	//     },
46223	//     "parent": {
46224	//       "description": "Required. The project to list all answer records for in reverse chronological order. Format: `projects//locations/`.",
46225	//       "location": "path",
46226	//       "pattern": "^projects/[^/]+/locations/[^/]+$",
46227	//       "required": true,
46228	//       "type": "string"
46229	//     }
46230	//   },
46231	//   "path": "v2/{+parent}/answerRecords",
46232	//   "response": {
46233	//     "$ref": "GoogleCloudDialogflowV2ListAnswerRecordsResponse"
46234	//   },
46235	//   "scopes": [
46236	//     "https://www.googleapis.com/auth/cloud-platform",
46237	//     "https://www.googleapis.com/auth/dialogflow"
46238	//   ]
46239	// }
46240
46241}
46242
46243// Pages invokes f for each page of results.
46244// A non-nil error returned from f will halt the iteration.
46245// The provided context supersedes any context provided to the Context method.
46246func (c *ProjectsLocationsAnswerRecordsListCall) Pages(ctx context.Context, f func(*GoogleCloudDialogflowV2ListAnswerRecordsResponse) error) error {
46247	c.ctx_ = ctx
46248	defer c.PageToken(c.urlParams_.Get("pageToken")) // reset paging to original point
46249	for {
46250		x, err := c.Do()
46251		if err != nil {
46252			return err
46253		}
46254		if err := f(x); err != nil {
46255			return err
46256		}
46257		if x.NextPageToken == "" {
46258			return nil
46259		}
46260		c.PageToken(x.NextPageToken)
46261	}
46262}
46263
46264// method id "dialogflow.projects.locations.answerRecords.patch":
46265
46266type ProjectsLocationsAnswerRecordsPatchCall struct {
46267	s                                   *Service
46268	nameid                              string
46269	googleclouddialogflowv2answerrecord *GoogleCloudDialogflowV2AnswerRecord
46270	urlParams_                          gensupport.URLParams
46271	ctx_                                context.Context
46272	header_                             http.Header
46273}
46274
46275// Patch: Updates the specified answer record.
46276//
46277// - name: The unique identifier of this answer record. Format:
46278//   `projects//locations//answerRecords/`.
46279func (r *ProjectsLocationsAnswerRecordsService) Patch(nameid string, googleclouddialogflowv2answerrecord *GoogleCloudDialogflowV2AnswerRecord) *ProjectsLocationsAnswerRecordsPatchCall {
46280	c := &ProjectsLocationsAnswerRecordsPatchCall{s: r.s, urlParams_: make(gensupport.URLParams)}
46281	c.nameid = nameid
46282	c.googleclouddialogflowv2answerrecord = googleclouddialogflowv2answerrecord
46283	return c
46284}
46285
46286// UpdateMask sets the optional parameter "updateMask": Required. The
46287// mask to control which fields get updated.
46288func (c *ProjectsLocationsAnswerRecordsPatchCall) UpdateMask(updateMask string) *ProjectsLocationsAnswerRecordsPatchCall {
46289	c.urlParams_.Set("updateMask", updateMask)
46290	return c
46291}
46292
46293// Fields allows partial responses to be retrieved. See
46294// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
46295// for more information.
46296func (c *ProjectsLocationsAnswerRecordsPatchCall) Fields(s ...googleapi.Field) *ProjectsLocationsAnswerRecordsPatchCall {
46297	c.urlParams_.Set("fields", googleapi.CombineFields(s))
46298	return c
46299}
46300
46301// Context sets the context to be used in this call's Do method. Any
46302// pending HTTP request will be aborted if the provided context is
46303// canceled.
46304func (c *ProjectsLocationsAnswerRecordsPatchCall) Context(ctx context.Context) *ProjectsLocationsAnswerRecordsPatchCall {
46305	c.ctx_ = ctx
46306	return c
46307}
46308
46309// Header returns an http.Header that can be modified by the caller to
46310// add HTTP headers to the request.
46311func (c *ProjectsLocationsAnswerRecordsPatchCall) Header() http.Header {
46312	if c.header_ == nil {
46313		c.header_ = make(http.Header)
46314	}
46315	return c.header_
46316}
46317
46318func (c *ProjectsLocationsAnswerRecordsPatchCall) doRequest(alt string) (*http.Response, error) {
46319	reqHeaders := make(http.Header)
46320	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20211027")
46321	for k, v := range c.header_ {
46322		reqHeaders[k] = v
46323	}
46324	reqHeaders.Set("User-Agent", c.s.userAgent())
46325	var body io.Reader = nil
46326	body, err := googleapi.WithoutDataWrapper.JSONReader(c.googleclouddialogflowv2answerrecord)
46327	if err != nil {
46328		return nil, err
46329	}
46330	reqHeaders.Set("Content-Type", "application/json")
46331	c.urlParams_.Set("alt", alt)
46332	c.urlParams_.Set("prettyPrint", "false")
46333	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+name}")
46334	urls += "?" + c.urlParams_.Encode()
46335	req, err := http.NewRequest("PATCH", urls, body)
46336	if err != nil {
46337		return nil, err
46338	}
46339	req.Header = reqHeaders
46340	googleapi.Expand(req.URL, map[string]string{
46341		"name": c.nameid,
46342	})
46343	return gensupport.SendRequest(c.ctx_, c.s.client, req)
46344}
46345
46346// Do executes the "dialogflow.projects.locations.answerRecords.patch" call.
46347// Exactly one of *GoogleCloudDialogflowV2AnswerRecord or error will be
46348// non-nil. Any non-2xx status code is an error. Response headers are in
46349// either *GoogleCloudDialogflowV2AnswerRecord.ServerResponse.Header or
46350// (if a response was returned at all) in
46351// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
46352// whether the returned error was because http.StatusNotModified was
46353// returned.
46354func (c *ProjectsLocationsAnswerRecordsPatchCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDialogflowV2AnswerRecord, error) {
46355	gensupport.SetOptions(c.urlParams_, opts...)
46356	res, err := c.doRequest("json")
46357	if res != nil && res.StatusCode == http.StatusNotModified {
46358		if res.Body != nil {
46359			res.Body.Close()
46360		}
46361		return nil, &googleapi.Error{
46362			Code:   res.StatusCode,
46363			Header: res.Header,
46364		}
46365	}
46366	if err != nil {
46367		return nil, err
46368	}
46369	defer googleapi.CloseBody(res)
46370	if err := googleapi.CheckResponse(res); err != nil {
46371		return nil, err
46372	}
46373	ret := &GoogleCloudDialogflowV2AnswerRecord{
46374		ServerResponse: googleapi.ServerResponse{
46375			Header:         res.Header,
46376			HTTPStatusCode: res.StatusCode,
46377		},
46378	}
46379	target := &ret
46380	if err := gensupport.DecodeResponse(target, res); err != nil {
46381		return nil, err
46382	}
46383	return ret, nil
46384	// {
46385	//   "description": "Updates the specified answer record.",
46386	//   "flatPath": "v2/projects/{projectsId}/locations/{locationsId}/answerRecords/{answerRecordsId}",
46387	//   "httpMethod": "PATCH",
46388	//   "id": "dialogflow.projects.locations.answerRecords.patch",
46389	//   "parameterOrder": [
46390	//     "name"
46391	//   ],
46392	//   "parameters": {
46393	//     "name": {
46394	//       "description": "The unique identifier of this answer record. Format: `projects//locations//answerRecords/`.",
46395	//       "location": "path",
46396	//       "pattern": "^projects/[^/]+/locations/[^/]+/answerRecords/[^/]+$",
46397	//       "required": true,
46398	//       "type": "string"
46399	//     },
46400	//     "updateMask": {
46401	//       "description": "Required. The mask to control which fields get updated.",
46402	//       "format": "google-fieldmask",
46403	//       "location": "query",
46404	//       "type": "string"
46405	//     }
46406	//   },
46407	//   "path": "v2/{+name}",
46408	//   "request": {
46409	//     "$ref": "GoogleCloudDialogflowV2AnswerRecord"
46410	//   },
46411	//   "response": {
46412	//     "$ref": "GoogleCloudDialogflowV2AnswerRecord"
46413	//   },
46414	//   "scopes": [
46415	//     "https://www.googleapis.com/auth/cloud-platform",
46416	//     "https://www.googleapis.com/auth/dialogflow"
46417	//   ]
46418	// }
46419
46420}
46421
46422// method id "dialogflow.projects.locations.conversationProfiles.create":
46423
46424type ProjectsLocationsConversationProfilesCreateCall struct {
46425	s                                          *Service
46426	parent                                     string
46427	googleclouddialogflowv2conversationprofile *GoogleCloudDialogflowV2ConversationProfile
46428	urlParams_                                 gensupport.URLParams
46429	ctx_                                       context.Context
46430	header_                                    http.Header
46431}
46432
46433// Create: Creates a conversation profile in the specified project.
46434// ConversationProfile.CreateTime and ConversationProfile.UpdateTime
46435// aren't populated in the response. You can retrieve them via
46436// GetConversationProfile API.
46437//
46438// - parent: The project to create a conversation profile for. Format:
46439//   `projects//locations/`.
46440func (r *ProjectsLocationsConversationProfilesService) Create(parent string, googleclouddialogflowv2conversationprofile *GoogleCloudDialogflowV2ConversationProfile) *ProjectsLocationsConversationProfilesCreateCall {
46441	c := &ProjectsLocationsConversationProfilesCreateCall{s: r.s, urlParams_: make(gensupport.URLParams)}
46442	c.parent = parent
46443	c.googleclouddialogflowv2conversationprofile = googleclouddialogflowv2conversationprofile
46444	return c
46445}
46446
46447// Fields allows partial responses to be retrieved. See
46448// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
46449// for more information.
46450func (c *ProjectsLocationsConversationProfilesCreateCall) Fields(s ...googleapi.Field) *ProjectsLocationsConversationProfilesCreateCall {
46451	c.urlParams_.Set("fields", googleapi.CombineFields(s))
46452	return c
46453}
46454
46455// Context sets the context to be used in this call's Do method. Any
46456// pending HTTP request will be aborted if the provided context is
46457// canceled.
46458func (c *ProjectsLocationsConversationProfilesCreateCall) Context(ctx context.Context) *ProjectsLocationsConversationProfilesCreateCall {
46459	c.ctx_ = ctx
46460	return c
46461}
46462
46463// Header returns an http.Header that can be modified by the caller to
46464// add HTTP headers to the request.
46465func (c *ProjectsLocationsConversationProfilesCreateCall) Header() http.Header {
46466	if c.header_ == nil {
46467		c.header_ = make(http.Header)
46468	}
46469	return c.header_
46470}
46471
46472func (c *ProjectsLocationsConversationProfilesCreateCall) doRequest(alt string) (*http.Response, error) {
46473	reqHeaders := make(http.Header)
46474	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20211027")
46475	for k, v := range c.header_ {
46476		reqHeaders[k] = v
46477	}
46478	reqHeaders.Set("User-Agent", c.s.userAgent())
46479	var body io.Reader = nil
46480	body, err := googleapi.WithoutDataWrapper.JSONReader(c.googleclouddialogflowv2conversationprofile)
46481	if err != nil {
46482		return nil, err
46483	}
46484	reqHeaders.Set("Content-Type", "application/json")
46485	c.urlParams_.Set("alt", alt)
46486	c.urlParams_.Set("prettyPrint", "false")
46487	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+parent}/conversationProfiles")
46488	urls += "?" + c.urlParams_.Encode()
46489	req, err := http.NewRequest("POST", urls, body)
46490	if err != nil {
46491		return nil, err
46492	}
46493	req.Header = reqHeaders
46494	googleapi.Expand(req.URL, map[string]string{
46495		"parent": c.parent,
46496	})
46497	return gensupport.SendRequest(c.ctx_, c.s.client, req)
46498}
46499
46500// Do executes the "dialogflow.projects.locations.conversationProfiles.create" call.
46501// Exactly one of *GoogleCloudDialogflowV2ConversationProfile or error
46502// will be non-nil. Any non-2xx status code is an error. Response
46503// headers are in either
46504// *GoogleCloudDialogflowV2ConversationProfile.ServerResponse.Header or
46505// (if a response was returned at all) in
46506// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
46507// whether the returned error was because http.StatusNotModified was
46508// returned.
46509func (c *ProjectsLocationsConversationProfilesCreateCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDialogflowV2ConversationProfile, error) {
46510	gensupport.SetOptions(c.urlParams_, opts...)
46511	res, err := c.doRequest("json")
46512	if res != nil && res.StatusCode == http.StatusNotModified {
46513		if res.Body != nil {
46514			res.Body.Close()
46515		}
46516		return nil, &googleapi.Error{
46517			Code:   res.StatusCode,
46518			Header: res.Header,
46519		}
46520	}
46521	if err != nil {
46522		return nil, err
46523	}
46524	defer googleapi.CloseBody(res)
46525	if err := googleapi.CheckResponse(res); err != nil {
46526		return nil, err
46527	}
46528	ret := &GoogleCloudDialogflowV2ConversationProfile{
46529		ServerResponse: googleapi.ServerResponse{
46530			Header:         res.Header,
46531			HTTPStatusCode: res.StatusCode,
46532		},
46533	}
46534	target := &ret
46535	if err := gensupport.DecodeResponse(target, res); err != nil {
46536		return nil, err
46537	}
46538	return ret, nil
46539	// {
46540	//   "description": "Creates a conversation profile in the specified project. ConversationProfile.CreateTime and ConversationProfile.UpdateTime aren't populated in the response. You can retrieve them via GetConversationProfile API.",
46541	//   "flatPath": "v2/projects/{projectsId}/locations/{locationsId}/conversationProfiles",
46542	//   "httpMethod": "POST",
46543	//   "id": "dialogflow.projects.locations.conversationProfiles.create",
46544	//   "parameterOrder": [
46545	//     "parent"
46546	//   ],
46547	//   "parameters": {
46548	//     "parent": {
46549	//       "description": "Required. The project to create a conversation profile for. Format: `projects//locations/`.",
46550	//       "location": "path",
46551	//       "pattern": "^projects/[^/]+/locations/[^/]+$",
46552	//       "required": true,
46553	//       "type": "string"
46554	//     }
46555	//   },
46556	//   "path": "v2/{+parent}/conversationProfiles",
46557	//   "request": {
46558	//     "$ref": "GoogleCloudDialogflowV2ConversationProfile"
46559	//   },
46560	//   "response": {
46561	//     "$ref": "GoogleCloudDialogflowV2ConversationProfile"
46562	//   },
46563	//   "scopes": [
46564	//     "https://www.googleapis.com/auth/cloud-platform",
46565	//     "https://www.googleapis.com/auth/dialogflow"
46566	//   ]
46567	// }
46568
46569}
46570
46571// method id "dialogflow.projects.locations.conversationProfiles.delete":
46572
46573type ProjectsLocationsConversationProfilesDeleteCall struct {
46574	s          *Service
46575	name       string
46576	urlParams_ gensupport.URLParams
46577	ctx_       context.Context
46578	header_    http.Header
46579}
46580
46581// Delete: Deletes the specified conversation profile.
46582//
46583// - name: The name of the conversation profile to delete. Format:
46584//   `projects//locations//conversationProfiles/`.
46585func (r *ProjectsLocationsConversationProfilesService) Delete(name string) *ProjectsLocationsConversationProfilesDeleteCall {
46586	c := &ProjectsLocationsConversationProfilesDeleteCall{s: r.s, urlParams_: make(gensupport.URLParams)}
46587	c.name = name
46588	return c
46589}
46590
46591// Fields allows partial responses to be retrieved. See
46592// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
46593// for more information.
46594func (c *ProjectsLocationsConversationProfilesDeleteCall) Fields(s ...googleapi.Field) *ProjectsLocationsConversationProfilesDeleteCall {
46595	c.urlParams_.Set("fields", googleapi.CombineFields(s))
46596	return c
46597}
46598
46599// Context sets the context to be used in this call's Do method. Any
46600// pending HTTP request will be aborted if the provided context is
46601// canceled.
46602func (c *ProjectsLocationsConversationProfilesDeleteCall) Context(ctx context.Context) *ProjectsLocationsConversationProfilesDeleteCall {
46603	c.ctx_ = ctx
46604	return c
46605}
46606
46607// Header returns an http.Header that can be modified by the caller to
46608// add HTTP headers to the request.
46609func (c *ProjectsLocationsConversationProfilesDeleteCall) Header() http.Header {
46610	if c.header_ == nil {
46611		c.header_ = make(http.Header)
46612	}
46613	return c.header_
46614}
46615
46616func (c *ProjectsLocationsConversationProfilesDeleteCall) doRequest(alt string) (*http.Response, error) {
46617	reqHeaders := make(http.Header)
46618	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20211027")
46619	for k, v := range c.header_ {
46620		reqHeaders[k] = v
46621	}
46622	reqHeaders.Set("User-Agent", c.s.userAgent())
46623	var body io.Reader = nil
46624	c.urlParams_.Set("alt", alt)
46625	c.urlParams_.Set("prettyPrint", "false")
46626	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+name}")
46627	urls += "?" + c.urlParams_.Encode()
46628	req, err := http.NewRequest("DELETE", urls, body)
46629	if err != nil {
46630		return nil, err
46631	}
46632	req.Header = reqHeaders
46633	googleapi.Expand(req.URL, map[string]string{
46634		"name": c.name,
46635	})
46636	return gensupport.SendRequest(c.ctx_, c.s.client, req)
46637}
46638
46639// Do executes the "dialogflow.projects.locations.conversationProfiles.delete" call.
46640// Exactly one of *GoogleProtobufEmpty or error will be non-nil. Any
46641// non-2xx status code is an error. Response headers are in either
46642// *GoogleProtobufEmpty.ServerResponse.Header or (if a response was
46643// returned at all) in error.(*googleapi.Error).Header. Use
46644// googleapi.IsNotModified to check whether the returned error was
46645// because http.StatusNotModified was returned.
46646func (c *ProjectsLocationsConversationProfilesDeleteCall) Do(opts ...googleapi.CallOption) (*GoogleProtobufEmpty, error) {
46647	gensupport.SetOptions(c.urlParams_, opts...)
46648	res, err := c.doRequest("json")
46649	if res != nil && res.StatusCode == http.StatusNotModified {
46650		if res.Body != nil {
46651			res.Body.Close()
46652		}
46653		return nil, &googleapi.Error{
46654			Code:   res.StatusCode,
46655			Header: res.Header,
46656		}
46657	}
46658	if err != nil {
46659		return nil, err
46660	}
46661	defer googleapi.CloseBody(res)
46662	if err := googleapi.CheckResponse(res); err != nil {
46663		return nil, err
46664	}
46665	ret := &GoogleProtobufEmpty{
46666		ServerResponse: googleapi.ServerResponse{
46667			Header:         res.Header,
46668			HTTPStatusCode: res.StatusCode,
46669		},
46670	}
46671	target := &ret
46672	if err := gensupport.DecodeResponse(target, res); err != nil {
46673		return nil, err
46674	}
46675	return ret, nil
46676	// {
46677	//   "description": "Deletes the specified conversation profile.",
46678	//   "flatPath": "v2/projects/{projectsId}/locations/{locationsId}/conversationProfiles/{conversationProfilesId}",
46679	//   "httpMethod": "DELETE",
46680	//   "id": "dialogflow.projects.locations.conversationProfiles.delete",
46681	//   "parameterOrder": [
46682	//     "name"
46683	//   ],
46684	//   "parameters": {
46685	//     "name": {
46686	//       "description": "Required. The name of the conversation profile to delete. Format: `projects//locations//conversationProfiles/`.",
46687	//       "location": "path",
46688	//       "pattern": "^projects/[^/]+/locations/[^/]+/conversationProfiles/[^/]+$",
46689	//       "required": true,
46690	//       "type": "string"
46691	//     }
46692	//   },
46693	//   "path": "v2/{+name}",
46694	//   "response": {
46695	//     "$ref": "GoogleProtobufEmpty"
46696	//   },
46697	//   "scopes": [
46698	//     "https://www.googleapis.com/auth/cloud-platform",
46699	//     "https://www.googleapis.com/auth/dialogflow"
46700	//   ]
46701	// }
46702
46703}
46704
46705// method id "dialogflow.projects.locations.conversationProfiles.get":
46706
46707type ProjectsLocationsConversationProfilesGetCall struct {
46708	s            *Service
46709	name         string
46710	urlParams_   gensupport.URLParams
46711	ifNoneMatch_ string
46712	ctx_         context.Context
46713	header_      http.Header
46714}
46715
46716// Get: Retrieves the specified conversation profile.
46717//
46718// - name: The resource name of the conversation profile. Format:
46719//   `projects//locations//conversationProfiles/`.
46720func (r *ProjectsLocationsConversationProfilesService) Get(name string) *ProjectsLocationsConversationProfilesGetCall {
46721	c := &ProjectsLocationsConversationProfilesGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
46722	c.name = name
46723	return c
46724}
46725
46726// Fields allows partial responses to be retrieved. See
46727// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
46728// for more information.
46729func (c *ProjectsLocationsConversationProfilesGetCall) Fields(s ...googleapi.Field) *ProjectsLocationsConversationProfilesGetCall {
46730	c.urlParams_.Set("fields", googleapi.CombineFields(s))
46731	return c
46732}
46733
46734// IfNoneMatch sets the optional parameter which makes the operation
46735// fail if the object's ETag matches the given value. This is useful for
46736// getting updates only after the object has changed since the last
46737// request. Use googleapi.IsNotModified to check whether the response
46738// error from Do is the result of In-None-Match.
46739func (c *ProjectsLocationsConversationProfilesGetCall) IfNoneMatch(entityTag string) *ProjectsLocationsConversationProfilesGetCall {
46740	c.ifNoneMatch_ = entityTag
46741	return c
46742}
46743
46744// Context sets the context to be used in this call's Do method. Any
46745// pending HTTP request will be aborted if the provided context is
46746// canceled.
46747func (c *ProjectsLocationsConversationProfilesGetCall) Context(ctx context.Context) *ProjectsLocationsConversationProfilesGetCall {
46748	c.ctx_ = ctx
46749	return c
46750}
46751
46752// Header returns an http.Header that can be modified by the caller to
46753// add HTTP headers to the request.
46754func (c *ProjectsLocationsConversationProfilesGetCall) Header() http.Header {
46755	if c.header_ == nil {
46756		c.header_ = make(http.Header)
46757	}
46758	return c.header_
46759}
46760
46761func (c *ProjectsLocationsConversationProfilesGetCall) doRequest(alt string) (*http.Response, error) {
46762	reqHeaders := make(http.Header)
46763	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20211027")
46764	for k, v := range c.header_ {
46765		reqHeaders[k] = v
46766	}
46767	reqHeaders.Set("User-Agent", c.s.userAgent())
46768	if c.ifNoneMatch_ != "" {
46769		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
46770	}
46771	var body io.Reader = nil
46772	c.urlParams_.Set("alt", alt)
46773	c.urlParams_.Set("prettyPrint", "false")
46774	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+name}")
46775	urls += "?" + c.urlParams_.Encode()
46776	req, err := http.NewRequest("GET", urls, body)
46777	if err != nil {
46778		return nil, err
46779	}
46780	req.Header = reqHeaders
46781	googleapi.Expand(req.URL, map[string]string{
46782		"name": c.name,
46783	})
46784	return gensupport.SendRequest(c.ctx_, c.s.client, req)
46785}
46786
46787// Do executes the "dialogflow.projects.locations.conversationProfiles.get" call.
46788// Exactly one of *GoogleCloudDialogflowV2ConversationProfile or error
46789// will be non-nil. Any non-2xx status code is an error. Response
46790// headers are in either
46791// *GoogleCloudDialogflowV2ConversationProfile.ServerResponse.Header or
46792// (if a response was returned at all) in
46793// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
46794// whether the returned error was because http.StatusNotModified was
46795// returned.
46796func (c *ProjectsLocationsConversationProfilesGetCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDialogflowV2ConversationProfile, error) {
46797	gensupport.SetOptions(c.urlParams_, opts...)
46798	res, err := c.doRequest("json")
46799	if res != nil && res.StatusCode == http.StatusNotModified {
46800		if res.Body != nil {
46801			res.Body.Close()
46802		}
46803		return nil, &googleapi.Error{
46804			Code:   res.StatusCode,
46805			Header: res.Header,
46806		}
46807	}
46808	if err != nil {
46809		return nil, err
46810	}
46811	defer googleapi.CloseBody(res)
46812	if err := googleapi.CheckResponse(res); err != nil {
46813		return nil, err
46814	}
46815	ret := &GoogleCloudDialogflowV2ConversationProfile{
46816		ServerResponse: googleapi.ServerResponse{
46817			Header:         res.Header,
46818			HTTPStatusCode: res.StatusCode,
46819		},
46820	}
46821	target := &ret
46822	if err := gensupport.DecodeResponse(target, res); err != nil {
46823		return nil, err
46824	}
46825	return ret, nil
46826	// {
46827	//   "description": "Retrieves the specified conversation profile.",
46828	//   "flatPath": "v2/projects/{projectsId}/locations/{locationsId}/conversationProfiles/{conversationProfilesId}",
46829	//   "httpMethod": "GET",
46830	//   "id": "dialogflow.projects.locations.conversationProfiles.get",
46831	//   "parameterOrder": [
46832	//     "name"
46833	//   ],
46834	//   "parameters": {
46835	//     "name": {
46836	//       "description": "Required. The resource name of the conversation profile. Format: `projects//locations//conversationProfiles/`.",
46837	//       "location": "path",
46838	//       "pattern": "^projects/[^/]+/locations/[^/]+/conversationProfiles/[^/]+$",
46839	//       "required": true,
46840	//       "type": "string"
46841	//     }
46842	//   },
46843	//   "path": "v2/{+name}",
46844	//   "response": {
46845	//     "$ref": "GoogleCloudDialogflowV2ConversationProfile"
46846	//   },
46847	//   "scopes": [
46848	//     "https://www.googleapis.com/auth/cloud-platform",
46849	//     "https://www.googleapis.com/auth/dialogflow"
46850	//   ]
46851	// }
46852
46853}
46854
46855// method id "dialogflow.projects.locations.conversationProfiles.list":
46856
46857type ProjectsLocationsConversationProfilesListCall struct {
46858	s            *Service
46859	parent       string
46860	urlParams_   gensupport.URLParams
46861	ifNoneMatch_ string
46862	ctx_         context.Context
46863	header_      http.Header
46864}
46865
46866// List: Returns the list of all conversation profiles in the specified
46867// project.
46868//
46869// - parent: The project to list all conversation profiles from. Format:
46870//   `projects//locations/`.
46871func (r *ProjectsLocationsConversationProfilesService) List(parent string) *ProjectsLocationsConversationProfilesListCall {
46872	c := &ProjectsLocationsConversationProfilesListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
46873	c.parent = parent
46874	return c
46875}
46876
46877// PageSize sets the optional parameter "pageSize": The maximum number
46878// of items to return in a single page. By default 100 and at most 1000.
46879func (c *ProjectsLocationsConversationProfilesListCall) PageSize(pageSize int64) *ProjectsLocationsConversationProfilesListCall {
46880	c.urlParams_.Set("pageSize", fmt.Sprint(pageSize))
46881	return c
46882}
46883
46884// PageToken sets the optional parameter "pageToken": The
46885// next_page_token value returned from a previous list request.
46886func (c *ProjectsLocationsConversationProfilesListCall) PageToken(pageToken string) *ProjectsLocationsConversationProfilesListCall {
46887	c.urlParams_.Set("pageToken", pageToken)
46888	return c
46889}
46890
46891// Fields allows partial responses to be retrieved. See
46892// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
46893// for more information.
46894func (c *ProjectsLocationsConversationProfilesListCall) Fields(s ...googleapi.Field) *ProjectsLocationsConversationProfilesListCall {
46895	c.urlParams_.Set("fields", googleapi.CombineFields(s))
46896	return c
46897}
46898
46899// IfNoneMatch sets the optional parameter which makes the operation
46900// fail if the object's ETag matches the given value. This is useful for
46901// getting updates only after the object has changed since the last
46902// request. Use googleapi.IsNotModified to check whether the response
46903// error from Do is the result of In-None-Match.
46904func (c *ProjectsLocationsConversationProfilesListCall) IfNoneMatch(entityTag string) *ProjectsLocationsConversationProfilesListCall {
46905	c.ifNoneMatch_ = entityTag
46906	return c
46907}
46908
46909// Context sets the context to be used in this call's Do method. Any
46910// pending HTTP request will be aborted if the provided context is
46911// canceled.
46912func (c *ProjectsLocationsConversationProfilesListCall) Context(ctx context.Context) *ProjectsLocationsConversationProfilesListCall {
46913	c.ctx_ = ctx
46914	return c
46915}
46916
46917// Header returns an http.Header that can be modified by the caller to
46918// add HTTP headers to the request.
46919func (c *ProjectsLocationsConversationProfilesListCall) Header() http.Header {
46920	if c.header_ == nil {
46921		c.header_ = make(http.Header)
46922	}
46923	return c.header_
46924}
46925
46926func (c *ProjectsLocationsConversationProfilesListCall) doRequest(alt string) (*http.Response, error) {
46927	reqHeaders := make(http.Header)
46928	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20211027")
46929	for k, v := range c.header_ {
46930		reqHeaders[k] = v
46931	}
46932	reqHeaders.Set("User-Agent", c.s.userAgent())
46933	if c.ifNoneMatch_ != "" {
46934		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
46935	}
46936	var body io.Reader = nil
46937	c.urlParams_.Set("alt", alt)
46938	c.urlParams_.Set("prettyPrint", "false")
46939	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+parent}/conversationProfiles")
46940	urls += "?" + c.urlParams_.Encode()
46941	req, err := http.NewRequest("GET", urls, body)
46942	if err != nil {
46943		return nil, err
46944	}
46945	req.Header = reqHeaders
46946	googleapi.Expand(req.URL, map[string]string{
46947		"parent": c.parent,
46948	})
46949	return gensupport.SendRequest(c.ctx_, c.s.client, req)
46950}
46951
46952// Do executes the "dialogflow.projects.locations.conversationProfiles.list" call.
46953// Exactly one of
46954// *GoogleCloudDialogflowV2ListConversationProfilesResponse or error
46955// will be non-nil. Any non-2xx status code is an error. Response
46956// headers are in either
46957// *GoogleCloudDialogflowV2ListConversationProfilesResponse.ServerRespons
46958// e.Header or (if a response was returned at all) in
46959// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
46960// whether the returned error was because http.StatusNotModified was
46961// returned.
46962func (c *ProjectsLocationsConversationProfilesListCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDialogflowV2ListConversationProfilesResponse, error) {
46963	gensupport.SetOptions(c.urlParams_, opts...)
46964	res, err := c.doRequest("json")
46965	if res != nil && res.StatusCode == http.StatusNotModified {
46966		if res.Body != nil {
46967			res.Body.Close()
46968		}
46969		return nil, &googleapi.Error{
46970			Code:   res.StatusCode,
46971			Header: res.Header,
46972		}
46973	}
46974	if err != nil {
46975		return nil, err
46976	}
46977	defer googleapi.CloseBody(res)
46978	if err := googleapi.CheckResponse(res); err != nil {
46979		return nil, err
46980	}
46981	ret := &GoogleCloudDialogflowV2ListConversationProfilesResponse{
46982		ServerResponse: googleapi.ServerResponse{
46983			Header:         res.Header,
46984			HTTPStatusCode: res.StatusCode,
46985		},
46986	}
46987	target := &ret
46988	if err := gensupport.DecodeResponse(target, res); err != nil {
46989		return nil, err
46990	}
46991	return ret, nil
46992	// {
46993	//   "description": "Returns the list of all conversation profiles in the specified project.",
46994	//   "flatPath": "v2/projects/{projectsId}/locations/{locationsId}/conversationProfiles",
46995	//   "httpMethod": "GET",
46996	//   "id": "dialogflow.projects.locations.conversationProfiles.list",
46997	//   "parameterOrder": [
46998	//     "parent"
46999	//   ],
47000	//   "parameters": {
47001	//     "pageSize": {
47002	//       "description": "The maximum number of items to return in a single page. By default 100 and at most 1000.",
47003	//       "format": "int32",
47004	//       "location": "query",
47005	//       "type": "integer"
47006	//     },
47007	//     "pageToken": {
47008	//       "description": "The next_page_token value returned from a previous list request.",
47009	//       "location": "query",
47010	//       "type": "string"
47011	//     },
47012	//     "parent": {
47013	//       "description": "Required. The project to list all conversation profiles from. Format: `projects//locations/`.",
47014	//       "location": "path",
47015	//       "pattern": "^projects/[^/]+/locations/[^/]+$",
47016	//       "required": true,
47017	//       "type": "string"
47018	//     }
47019	//   },
47020	//   "path": "v2/{+parent}/conversationProfiles",
47021	//   "response": {
47022	//     "$ref": "GoogleCloudDialogflowV2ListConversationProfilesResponse"
47023	//   },
47024	//   "scopes": [
47025	//     "https://www.googleapis.com/auth/cloud-platform",
47026	//     "https://www.googleapis.com/auth/dialogflow"
47027	//   ]
47028	// }
47029
47030}
47031
47032// Pages invokes f for each page of results.
47033// A non-nil error returned from f will halt the iteration.
47034// The provided context supersedes any context provided to the Context method.
47035func (c *ProjectsLocationsConversationProfilesListCall) Pages(ctx context.Context, f func(*GoogleCloudDialogflowV2ListConversationProfilesResponse) error) error {
47036	c.ctx_ = ctx
47037	defer c.PageToken(c.urlParams_.Get("pageToken")) // reset paging to original point
47038	for {
47039		x, err := c.Do()
47040		if err != nil {
47041			return err
47042		}
47043		if err := f(x); err != nil {
47044			return err
47045		}
47046		if x.NextPageToken == "" {
47047			return nil
47048		}
47049		c.PageToken(x.NextPageToken)
47050	}
47051}
47052
47053// method id "dialogflow.projects.locations.conversationProfiles.patch":
47054
47055type ProjectsLocationsConversationProfilesPatchCall struct {
47056	s                                          *Service
47057	nameid                                     string
47058	googleclouddialogflowv2conversationprofile *GoogleCloudDialogflowV2ConversationProfile
47059	urlParams_                                 gensupport.URLParams
47060	ctx_                                       context.Context
47061	header_                                    http.Header
47062}
47063
47064// Patch: Updates the specified conversation profile.
47065// ConversationProfile.CreateTime and ConversationProfile.UpdateTime
47066// aren't populated in the response. You can retrieve them via
47067// GetConversationProfile API.
47068//
47069// - name: The unique identifier of this conversation profile. Format:
47070//   `projects//locations//conversationProfiles/`.
47071func (r *ProjectsLocationsConversationProfilesService) Patch(nameid string, googleclouddialogflowv2conversationprofile *GoogleCloudDialogflowV2ConversationProfile) *ProjectsLocationsConversationProfilesPatchCall {
47072	c := &ProjectsLocationsConversationProfilesPatchCall{s: r.s, urlParams_: make(gensupport.URLParams)}
47073	c.nameid = nameid
47074	c.googleclouddialogflowv2conversationprofile = googleclouddialogflowv2conversationprofile
47075	return c
47076}
47077
47078// UpdateMask sets the optional parameter "updateMask": Required. The
47079// mask to control which fields to update.
47080func (c *ProjectsLocationsConversationProfilesPatchCall) UpdateMask(updateMask string) *ProjectsLocationsConversationProfilesPatchCall {
47081	c.urlParams_.Set("updateMask", updateMask)
47082	return c
47083}
47084
47085// Fields allows partial responses to be retrieved. See
47086// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
47087// for more information.
47088func (c *ProjectsLocationsConversationProfilesPatchCall) Fields(s ...googleapi.Field) *ProjectsLocationsConversationProfilesPatchCall {
47089	c.urlParams_.Set("fields", googleapi.CombineFields(s))
47090	return c
47091}
47092
47093// Context sets the context to be used in this call's Do method. Any
47094// pending HTTP request will be aborted if the provided context is
47095// canceled.
47096func (c *ProjectsLocationsConversationProfilesPatchCall) Context(ctx context.Context) *ProjectsLocationsConversationProfilesPatchCall {
47097	c.ctx_ = ctx
47098	return c
47099}
47100
47101// Header returns an http.Header that can be modified by the caller to
47102// add HTTP headers to the request.
47103func (c *ProjectsLocationsConversationProfilesPatchCall) Header() http.Header {
47104	if c.header_ == nil {
47105		c.header_ = make(http.Header)
47106	}
47107	return c.header_
47108}
47109
47110func (c *ProjectsLocationsConversationProfilesPatchCall) doRequest(alt string) (*http.Response, error) {
47111	reqHeaders := make(http.Header)
47112	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20211027")
47113	for k, v := range c.header_ {
47114		reqHeaders[k] = v
47115	}
47116	reqHeaders.Set("User-Agent", c.s.userAgent())
47117	var body io.Reader = nil
47118	body, err := googleapi.WithoutDataWrapper.JSONReader(c.googleclouddialogflowv2conversationprofile)
47119	if err != nil {
47120		return nil, err
47121	}
47122	reqHeaders.Set("Content-Type", "application/json")
47123	c.urlParams_.Set("alt", alt)
47124	c.urlParams_.Set("prettyPrint", "false")
47125	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+name}")
47126	urls += "?" + c.urlParams_.Encode()
47127	req, err := http.NewRequest("PATCH", urls, body)
47128	if err != nil {
47129		return nil, err
47130	}
47131	req.Header = reqHeaders
47132	googleapi.Expand(req.URL, map[string]string{
47133		"name": c.nameid,
47134	})
47135	return gensupport.SendRequest(c.ctx_, c.s.client, req)
47136}
47137
47138// Do executes the "dialogflow.projects.locations.conversationProfiles.patch" call.
47139// Exactly one of *GoogleCloudDialogflowV2ConversationProfile or error
47140// will be non-nil. Any non-2xx status code is an error. Response
47141// headers are in either
47142// *GoogleCloudDialogflowV2ConversationProfile.ServerResponse.Header or
47143// (if a response was returned at all) in
47144// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
47145// whether the returned error was because http.StatusNotModified was
47146// returned.
47147func (c *ProjectsLocationsConversationProfilesPatchCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDialogflowV2ConversationProfile, error) {
47148	gensupport.SetOptions(c.urlParams_, opts...)
47149	res, err := c.doRequest("json")
47150	if res != nil && res.StatusCode == http.StatusNotModified {
47151		if res.Body != nil {
47152			res.Body.Close()
47153		}
47154		return nil, &googleapi.Error{
47155			Code:   res.StatusCode,
47156			Header: res.Header,
47157		}
47158	}
47159	if err != nil {
47160		return nil, err
47161	}
47162	defer googleapi.CloseBody(res)
47163	if err := googleapi.CheckResponse(res); err != nil {
47164		return nil, err
47165	}
47166	ret := &GoogleCloudDialogflowV2ConversationProfile{
47167		ServerResponse: googleapi.ServerResponse{
47168			Header:         res.Header,
47169			HTTPStatusCode: res.StatusCode,
47170		},
47171	}
47172	target := &ret
47173	if err := gensupport.DecodeResponse(target, res); err != nil {
47174		return nil, err
47175	}
47176	return ret, nil
47177	// {
47178	//   "description": "Updates the specified conversation profile. ConversationProfile.CreateTime and ConversationProfile.UpdateTime aren't populated in the response. You can retrieve them via GetConversationProfile API.",
47179	//   "flatPath": "v2/projects/{projectsId}/locations/{locationsId}/conversationProfiles/{conversationProfilesId}",
47180	//   "httpMethod": "PATCH",
47181	//   "id": "dialogflow.projects.locations.conversationProfiles.patch",
47182	//   "parameterOrder": [
47183	//     "name"
47184	//   ],
47185	//   "parameters": {
47186	//     "name": {
47187	//       "description": "The unique identifier of this conversation profile. Format: `projects//locations//conversationProfiles/`.",
47188	//       "location": "path",
47189	//       "pattern": "^projects/[^/]+/locations/[^/]+/conversationProfiles/[^/]+$",
47190	//       "required": true,
47191	//       "type": "string"
47192	//     },
47193	//     "updateMask": {
47194	//       "description": "Required. The mask to control which fields to update.",
47195	//       "format": "google-fieldmask",
47196	//       "location": "query",
47197	//       "type": "string"
47198	//     }
47199	//   },
47200	//   "path": "v2/{+name}",
47201	//   "request": {
47202	//     "$ref": "GoogleCloudDialogflowV2ConversationProfile"
47203	//   },
47204	//   "response": {
47205	//     "$ref": "GoogleCloudDialogflowV2ConversationProfile"
47206	//   },
47207	//   "scopes": [
47208	//     "https://www.googleapis.com/auth/cloud-platform",
47209	//     "https://www.googleapis.com/auth/dialogflow"
47210	//   ]
47211	// }
47212
47213}
47214
47215// method id "dialogflow.projects.locations.conversations.complete":
47216
47217type ProjectsLocationsConversationsCompleteCall struct {
47218	s                                                  *Service
47219	nameid                                             string
47220	googleclouddialogflowv2completeconversationrequest *GoogleCloudDialogflowV2CompleteConversationRequest
47221	urlParams_                                         gensupport.URLParams
47222	ctx_                                               context.Context
47223	header_                                            http.Header
47224}
47225
47226// Complete: Completes the specified conversation. Finished
47227// conversations are purged from the database after 30 days.
47228//
47229// - name: Resource identifier of the conversation to close. Format:
47230//   `projects//locations//conversations/`.
47231func (r *ProjectsLocationsConversationsService) Complete(nameid string, googleclouddialogflowv2completeconversationrequest *GoogleCloudDialogflowV2CompleteConversationRequest) *ProjectsLocationsConversationsCompleteCall {
47232	c := &ProjectsLocationsConversationsCompleteCall{s: r.s, urlParams_: make(gensupport.URLParams)}
47233	c.nameid = nameid
47234	c.googleclouddialogflowv2completeconversationrequest = googleclouddialogflowv2completeconversationrequest
47235	return c
47236}
47237
47238// Fields allows partial responses to be retrieved. See
47239// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
47240// for more information.
47241func (c *ProjectsLocationsConversationsCompleteCall) Fields(s ...googleapi.Field) *ProjectsLocationsConversationsCompleteCall {
47242	c.urlParams_.Set("fields", googleapi.CombineFields(s))
47243	return c
47244}
47245
47246// Context sets the context to be used in this call's Do method. Any
47247// pending HTTP request will be aborted if the provided context is
47248// canceled.
47249func (c *ProjectsLocationsConversationsCompleteCall) Context(ctx context.Context) *ProjectsLocationsConversationsCompleteCall {
47250	c.ctx_ = ctx
47251	return c
47252}
47253
47254// Header returns an http.Header that can be modified by the caller to
47255// add HTTP headers to the request.
47256func (c *ProjectsLocationsConversationsCompleteCall) Header() http.Header {
47257	if c.header_ == nil {
47258		c.header_ = make(http.Header)
47259	}
47260	return c.header_
47261}
47262
47263func (c *ProjectsLocationsConversationsCompleteCall) doRequest(alt string) (*http.Response, error) {
47264	reqHeaders := make(http.Header)
47265	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20211027")
47266	for k, v := range c.header_ {
47267		reqHeaders[k] = v
47268	}
47269	reqHeaders.Set("User-Agent", c.s.userAgent())
47270	var body io.Reader = nil
47271	body, err := googleapi.WithoutDataWrapper.JSONReader(c.googleclouddialogflowv2completeconversationrequest)
47272	if err != nil {
47273		return nil, err
47274	}
47275	reqHeaders.Set("Content-Type", "application/json")
47276	c.urlParams_.Set("alt", alt)
47277	c.urlParams_.Set("prettyPrint", "false")
47278	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+name}:complete")
47279	urls += "?" + c.urlParams_.Encode()
47280	req, err := http.NewRequest("POST", urls, body)
47281	if err != nil {
47282		return nil, err
47283	}
47284	req.Header = reqHeaders
47285	googleapi.Expand(req.URL, map[string]string{
47286		"name": c.nameid,
47287	})
47288	return gensupport.SendRequest(c.ctx_, c.s.client, req)
47289}
47290
47291// Do executes the "dialogflow.projects.locations.conversations.complete" call.
47292// Exactly one of *GoogleCloudDialogflowV2Conversation or error will be
47293// non-nil. Any non-2xx status code is an error. Response headers are in
47294// either *GoogleCloudDialogflowV2Conversation.ServerResponse.Header or
47295// (if a response was returned at all) in
47296// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
47297// whether the returned error was because http.StatusNotModified was
47298// returned.
47299func (c *ProjectsLocationsConversationsCompleteCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDialogflowV2Conversation, error) {
47300	gensupport.SetOptions(c.urlParams_, opts...)
47301	res, err := c.doRequest("json")
47302	if res != nil && res.StatusCode == http.StatusNotModified {
47303		if res.Body != nil {
47304			res.Body.Close()
47305		}
47306		return nil, &googleapi.Error{
47307			Code:   res.StatusCode,
47308			Header: res.Header,
47309		}
47310	}
47311	if err != nil {
47312		return nil, err
47313	}
47314	defer googleapi.CloseBody(res)
47315	if err := googleapi.CheckResponse(res); err != nil {
47316		return nil, err
47317	}
47318	ret := &GoogleCloudDialogflowV2Conversation{
47319		ServerResponse: googleapi.ServerResponse{
47320			Header:         res.Header,
47321			HTTPStatusCode: res.StatusCode,
47322		},
47323	}
47324	target := &ret
47325	if err := gensupport.DecodeResponse(target, res); err != nil {
47326		return nil, err
47327	}
47328	return ret, nil
47329	// {
47330	//   "description": "Completes the specified conversation. Finished conversations are purged from the database after 30 days.",
47331	//   "flatPath": "v2/projects/{projectsId}/locations/{locationsId}/conversations/{conversationsId}:complete",
47332	//   "httpMethod": "POST",
47333	//   "id": "dialogflow.projects.locations.conversations.complete",
47334	//   "parameterOrder": [
47335	//     "name"
47336	//   ],
47337	//   "parameters": {
47338	//     "name": {
47339	//       "description": "Required. Resource identifier of the conversation to close. Format: `projects//locations//conversations/`.",
47340	//       "location": "path",
47341	//       "pattern": "^projects/[^/]+/locations/[^/]+/conversations/[^/]+$",
47342	//       "required": true,
47343	//       "type": "string"
47344	//     }
47345	//   },
47346	//   "path": "v2/{+name}:complete",
47347	//   "request": {
47348	//     "$ref": "GoogleCloudDialogflowV2CompleteConversationRequest"
47349	//   },
47350	//   "response": {
47351	//     "$ref": "GoogleCloudDialogflowV2Conversation"
47352	//   },
47353	//   "scopes": [
47354	//     "https://www.googleapis.com/auth/cloud-platform",
47355	//     "https://www.googleapis.com/auth/dialogflow"
47356	//   ]
47357	// }
47358
47359}
47360
47361// method id "dialogflow.projects.locations.conversations.create":
47362
47363type ProjectsLocationsConversationsCreateCall struct {
47364	s                                   *Service
47365	parentid                            string
47366	googleclouddialogflowv2conversation *GoogleCloudDialogflowV2Conversation
47367	urlParams_                          gensupport.URLParams
47368	ctx_                                context.Context
47369	header_                             http.Header
47370}
47371
47372// Create: Creates a new conversation. Conversations are auto-completed
47373// after 24 hours. Conversation Lifecycle: There are two stages during a
47374// conversation: Automated Agent Stage and Assist Stage. For Automated
47375// Agent Stage, there will be a dialogflow agent responding to user
47376// queries. For Assist Stage, there's no dialogflow agent responding to
47377// user queries. But we will provide suggestions which are generated
47378// from conversation. If Conversation.conversation_profile is configured
47379// for a dialogflow agent, conversation will start from `Automated Agent
47380// Stage`, otherwise, it will start from `Assist Stage`. And during
47381// `Automated Agent Stage`, once an Intent with
47382// Intent.live_agent_handoff is triggered, conversation will transfer to
47383// Assist Stage.
47384//
47385// - parent: Resource identifier of the project creating the
47386//   conversation. Format: `projects//locations/`.
47387func (r *ProjectsLocationsConversationsService) Create(parentid string, googleclouddialogflowv2conversation *GoogleCloudDialogflowV2Conversation) *ProjectsLocationsConversationsCreateCall {
47388	c := &ProjectsLocationsConversationsCreateCall{s: r.s, urlParams_: make(gensupport.URLParams)}
47389	c.parentid = parentid
47390	c.googleclouddialogflowv2conversation = googleclouddialogflowv2conversation
47391	return c
47392}
47393
47394// ConversationId sets the optional parameter "conversationId":
47395// Identifier of the conversation. Generally it's auto generated by
47396// Google. Only set it if you cannot wait for the response to return a
47397// auto-generated one to you. The conversation ID must be compliant with
47398// the regression fomula "a-zA-Z*" with the characters length in range
47399// of [3,64]. If the field is provided, the caller is resposible for 1.
47400// the uniqueness of the ID, otherwise the request will be rejected. 2.
47401// the consistency for whether to use custom ID or not under a project
47402// to better ensure uniqueness.
47403func (c *ProjectsLocationsConversationsCreateCall) ConversationId(conversationId string) *ProjectsLocationsConversationsCreateCall {
47404	c.urlParams_.Set("conversationId", conversationId)
47405	return c
47406}
47407
47408// Fields allows partial responses to be retrieved. See
47409// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
47410// for more information.
47411func (c *ProjectsLocationsConversationsCreateCall) Fields(s ...googleapi.Field) *ProjectsLocationsConversationsCreateCall {
47412	c.urlParams_.Set("fields", googleapi.CombineFields(s))
47413	return c
47414}
47415
47416// Context sets the context to be used in this call's Do method. Any
47417// pending HTTP request will be aborted if the provided context is
47418// canceled.
47419func (c *ProjectsLocationsConversationsCreateCall) Context(ctx context.Context) *ProjectsLocationsConversationsCreateCall {
47420	c.ctx_ = ctx
47421	return c
47422}
47423
47424// Header returns an http.Header that can be modified by the caller to
47425// add HTTP headers to the request.
47426func (c *ProjectsLocationsConversationsCreateCall) Header() http.Header {
47427	if c.header_ == nil {
47428		c.header_ = make(http.Header)
47429	}
47430	return c.header_
47431}
47432
47433func (c *ProjectsLocationsConversationsCreateCall) doRequest(alt string) (*http.Response, error) {
47434	reqHeaders := make(http.Header)
47435	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20211027")
47436	for k, v := range c.header_ {
47437		reqHeaders[k] = v
47438	}
47439	reqHeaders.Set("User-Agent", c.s.userAgent())
47440	var body io.Reader = nil
47441	body, err := googleapi.WithoutDataWrapper.JSONReader(c.googleclouddialogflowv2conversation)
47442	if err != nil {
47443		return nil, err
47444	}
47445	reqHeaders.Set("Content-Type", "application/json")
47446	c.urlParams_.Set("alt", alt)
47447	c.urlParams_.Set("prettyPrint", "false")
47448	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+parent}/conversations")
47449	urls += "?" + c.urlParams_.Encode()
47450	req, err := http.NewRequest("POST", urls, body)
47451	if err != nil {
47452		return nil, err
47453	}
47454	req.Header = reqHeaders
47455	googleapi.Expand(req.URL, map[string]string{
47456		"parent": c.parentid,
47457	})
47458	return gensupport.SendRequest(c.ctx_, c.s.client, req)
47459}
47460
47461// Do executes the "dialogflow.projects.locations.conversations.create" call.
47462// Exactly one of *GoogleCloudDialogflowV2Conversation or error will be
47463// non-nil. Any non-2xx status code is an error. Response headers are in
47464// either *GoogleCloudDialogflowV2Conversation.ServerResponse.Header or
47465// (if a response was returned at all) in
47466// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
47467// whether the returned error was because http.StatusNotModified was
47468// returned.
47469func (c *ProjectsLocationsConversationsCreateCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDialogflowV2Conversation, error) {
47470	gensupport.SetOptions(c.urlParams_, opts...)
47471	res, err := c.doRequest("json")
47472	if res != nil && res.StatusCode == http.StatusNotModified {
47473		if res.Body != nil {
47474			res.Body.Close()
47475		}
47476		return nil, &googleapi.Error{
47477			Code:   res.StatusCode,
47478			Header: res.Header,
47479		}
47480	}
47481	if err != nil {
47482		return nil, err
47483	}
47484	defer googleapi.CloseBody(res)
47485	if err := googleapi.CheckResponse(res); err != nil {
47486		return nil, err
47487	}
47488	ret := &GoogleCloudDialogflowV2Conversation{
47489		ServerResponse: googleapi.ServerResponse{
47490			Header:         res.Header,
47491			HTTPStatusCode: res.StatusCode,
47492		},
47493	}
47494	target := &ret
47495	if err := gensupport.DecodeResponse(target, res); err != nil {
47496		return nil, err
47497	}
47498	return ret, nil
47499	// {
47500	//   "description": "Creates a new conversation. Conversations are auto-completed after 24 hours. Conversation Lifecycle: There are two stages during a conversation: Automated Agent Stage and Assist Stage. For Automated Agent Stage, there will be a dialogflow agent responding to user queries. For Assist Stage, there's no dialogflow agent responding to user queries. But we will provide suggestions which are generated from conversation. If Conversation.conversation_profile is configured for a dialogflow agent, conversation will start from `Automated Agent Stage`, otherwise, it will start from `Assist Stage`. And during `Automated Agent Stage`, once an Intent with Intent.live_agent_handoff is triggered, conversation will transfer to Assist Stage.",
47501	//   "flatPath": "v2/projects/{projectsId}/locations/{locationsId}/conversations",
47502	//   "httpMethod": "POST",
47503	//   "id": "dialogflow.projects.locations.conversations.create",
47504	//   "parameterOrder": [
47505	//     "parent"
47506	//   ],
47507	//   "parameters": {
47508	//     "conversationId": {
47509	//       "description": "Optional. Identifier of the conversation. Generally it's auto generated by Google. Only set it if you cannot wait for the response to return a auto-generated one to you. The conversation ID must be compliant with the regression fomula \"a-zA-Z*\" with the characters length in range of [3,64]. 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.",
47510	//       "location": "query",
47511	//       "type": "string"
47512	//     },
47513	//     "parent": {
47514	//       "description": "Required. Resource identifier of the project creating the conversation. Format: `projects//locations/`.",
47515	//       "location": "path",
47516	//       "pattern": "^projects/[^/]+/locations/[^/]+$",
47517	//       "required": true,
47518	//       "type": "string"
47519	//     }
47520	//   },
47521	//   "path": "v2/{+parent}/conversations",
47522	//   "request": {
47523	//     "$ref": "GoogleCloudDialogflowV2Conversation"
47524	//   },
47525	//   "response": {
47526	//     "$ref": "GoogleCloudDialogflowV2Conversation"
47527	//   },
47528	//   "scopes": [
47529	//     "https://www.googleapis.com/auth/cloud-platform",
47530	//     "https://www.googleapis.com/auth/dialogflow"
47531	//   ]
47532	// }
47533
47534}
47535
47536// method id "dialogflow.projects.locations.conversations.get":
47537
47538type ProjectsLocationsConversationsGetCall struct {
47539	s            *Service
47540	name         string
47541	urlParams_   gensupport.URLParams
47542	ifNoneMatch_ string
47543	ctx_         context.Context
47544	header_      http.Header
47545}
47546
47547// Get: Retrieves the specific conversation.
47548//
47549// - name: The name of the conversation. Format:
47550//   `projects//locations//conversations/`.
47551func (r *ProjectsLocationsConversationsService) Get(name string) *ProjectsLocationsConversationsGetCall {
47552	c := &ProjectsLocationsConversationsGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
47553	c.name = name
47554	return c
47555}
47556
47557// Fields allows partial responses to be retrieved. See
47558// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
47559// for more information.
47560func (c *ProjectsLocationsConversationsGetCall) Fields(s ...googleapi.Field) *ProjectsLocationsConversationsGetCall {
47561	c.urlParams_.Set("fields", googleapi.CombineFields(s))
47562	return c
47563}
47564
47565// IfNoneMatch sets the optional parameter which makes the operation
47566// fail if the object's ETag matches the given value. This is useful for
47567// getting updates only after the object has changed since the last
47568// request. Use googleapi.IsNotModified to check whether the response
47569// error from Do is the result of In-None-Match.
47570func (c *ProjectsLocationsConversationsGetCall) IfNoneMatch(entityTag string) *ProjectsLocationsConversationsGetCall {
47571	c.ifNoneMatch_ = entityTag
47572	return c
47573}
47574
47575// Context sets the context to be used in this call's Do method. Any
47576// pending HTTP request will be aborted if the provided context is
47577// canceled.
47578func (c *ProjectsLocationsConversationsGetCall) Context(ctx context.Context) *ProjectsLocationsConversationsGetCall {
47579	c.ctx_ = ctx
47580	return c
47581}
47582
47583// Header returns an http.Header that can be modified by the caller to
47584// add HTTP headers to the request.
47585func (c *ProjectsLocationsConversationsGetCall) Header() http.Header {
47586	if c.header_ == nil {
47587		c.header_ = make(http.Header)
47588	}
47589	return c.header_
47590}
47591
47592func (c *ProjectsLocationsConversationsGetCall) doRequest(alt string) (*http.Response, error) {
47593	reqHeaders := make(http.Header)
47594	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20211027")
47595	for k, v := range c.header_ {
47596		reqHeaders[k] = v
47597	}
47598	reqHeaders.Set("User-Agent", c.s.userAgent())
47599	if c.ifNoneMatch_ != "" {
47600		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
47601	}
47602	var body io.Reader = nil
47603	c.urlParams_.Set("alt", alt)
47604	c.urlParams_.Set("prettyPrint", "false")
47605	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+name}")
47606	urls += "?" + c.urlParams_.Encode()
47607	req, err := http.NewRequest("GET", urls, body)
47608	if err != nil {
47609		return nil, err
47610	}
47611	req.Header = reqHeaders
47612	googleapi.Expand(req.URL, map[string]string{
47613		"name": c.name,
47614	})
47615	return gensupport.SendRequest(c.ctx_, c.s.client, req)
47616}
47617
47618// Do executes the "dialogflow.projects.locations.conversations.get" call.
47619// Exactly one of *GoogleCloudDialogflowV2Conversation or error will be
47620// non-nil. Any non-2xx status code is an error. Response headers are in
47621// either *GoogleCloudDialogflowV2Conversation.ServerResponse.Header or
47622// (if a response was returned at all) in
47623// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
47624// whether the returned error was because http.StatusNotModified was
47625// returned.
47626func (c *ProjectsLocationsConversationsGetCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDialogflowV2Conversation, error) {
47627	gensupport.SetOptions(c.urlParams_, opts...)
47628	res, err := c.doRequest("json")
47629	if res != nil && res.StatusCode == http.StatusNotModified {
47630		if res.Body != nil {
47631			res.Body.Close()
47632		}
47633		return nil, &googleapi.Error{
47634			Code:   res.StatusCode,
47635			Header: res.Header,
47636		}
47637	}
47638	if err != nil {
47639		return nil, err
47640	}
47641	defer googleapi.CloseBody(res)
47642	if err := googleapi.CheckResponse(res); err != nil {
47643		return nil, err
47644	}
47645	ret := &GoogleCloudDialogflowV2Conversation{
47646		ServerResponse: googleapi.ServerResponse{
47647			Header:         res.Header,
47648			HTTPStatusCode: res.StatusCode,
47649		},
47650	}
47651	target := &ret
47652	if err := gensupport.DecodeResponse(target, res); err != nil {
47653		return nil, err
47654	}
47655	return ret, nil
47656	// {
47657	//   "description": "Retrieves the specific conversation.",
47658	//   "flatPath": "v2/projects/{projectsId}/locations/{locationsId}/conversations/{conversationsId}",
47659	//   "httpMethod": "GET",
47660	//   "id": "dialogflow.projects.locations.conversations.get",
47661	//   "parameterOrder": [
47662	//     "name"
47663	//   ],
47664	//   "parameters": {
47665	//     "name": {
47666	//       "description": "Required. The name of the conversation. Format: `projects//locations//conversations/`.",
47667	//       "location": "path",
47668	//       "pattern": "^projects/[^/]+/locations/[^/]+/conversations/[^/]+$",
47669	//       "required": true,
47670	//       "type": "string"
47671	//     }
47672	//   },
47673	//   "path": "v2/{+name}",
47674	//   "response": {
47675	//     "$ref": "GoogleCloudDialogflowV2Conversation"
47676	//   },
47677	//   "scopes": [
47678	//     "https://www.googleapis.com/auth/cloud-platform",
47679	//     "https://www.googleapis.com/auth/dialogflow"
47680	//   ]
47681	// }
47682
47683}
47684
47685// method id "dialogflow.projects.locations.conversations.list":
47686
47687type ProjectsLocationsConversationsListCall struct {
47688	s            *Service
47689	parent       string
47690	urlParams_   gensupport.URLParams
47691	ifNoneMatch_ string
47692	ctx_         context.Context
47693	header_      http.Header
47694}
47695
47696// List: Returns the list of all conversations in the specified project.
47697//
47698// - parent: The project from which to list all conversation. Format:
47699//   `projects//locations/`.
47700func (r *ProjectsLocationsConversationsService) List(parent string) *ProjectsLocationsConversationsListCall {
47701	c := &ProjectsLocationsConversationsListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
47702	c.parent = parent
47703	return c
47704}
47705
47706// Filter sets the optional parameter "filter": A filter expression that
47707// filters conversations listed in the response. In general, the
47708// expression must specify the field name, a comparison operator, and
47709// the value to use for filtering: - The value must be a string, a
47710// number, or a boolean. - The comparison operator must be either
47711// `=`,`!=`, `>`, or `<`. - To filter on multiple expressions, separate
47712// the expressions with `AND` or `OR` (omitting both implies `AND`). -
47713// For clarity, expressions can be enclosed in parentheses. Only
47714// `lifecycle_state` can be filtered on in this way. For example, the
47715// following expression only returns `COMPLETED` conversations:
47716// `lifecycle_state = "COMPLETED" For more information about filtering,
47717// see API Filtering (https://aip.dev/160).
47718func (c *ProjectsLocationsConversationsListCall) Filter(filter string) *ProjectsLocationsConversationsListCall {
47719	c.urlParams_.Set("filter", filter)
47720	return c
47721}
47722
47723// PageSize sets the optional parameter "pageSize": The maximum number
47724// of items to return in a single page. By default 100 and at most 1000.
47725func (c *ProjectsLocationsConversationsListCall) PageSize(pageSize int64) *ProjectsLocationsConversationsListCall {
47726	c.urlParams_.Set("pageSize", fmt.Sprint(pageSize))
47727	return c
47728}
47729
47730// PageToken sets the optional parameter "pageToken": The
47731// next_page_token value returned from a previous list request.
47732func (c *ProjectsLocationsConversationsListCall) PageToken(pageToken string) *ProjectsLocationsConversationsListCall {
47733	c.urlParams_.Set("pageToken", pageToken)
47734	return c
47735}
47736
47737// Fields allows partial responses to be retrieved. See
47738// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
47739// for more information.
47740func (c *ProjectsLocationsConversationsListCall) Fields(s ...googleapi.Field) *ProjectsLocationsConversationsListCall {
47741	c.urlParams_.Set("fields", googleapi.CombineFields(s))
47742	return c
47743}
47744
47745// IfNoneMatch sets the optional parameter which makes the operation
47746// fail if the object's ETag matches the given value. This is useful for
47747// getting updates only after the object has changed since the last
47748// request. Use googleapi.IsNotModified to check whether the response
47749// error from Do is the result of In-None-Match.
47750func (c *ProjectsLocationsConversationsListCall) IfNoneMatch(entityTag string) *ProjectsLocationsConversationsListCall {
47751	c.ifNoneMatch_ = entityTag
47752	return c
47753}
47754
47755// Context sets the context to be used in this call's Do method. Any
47756// pending HTTP request will be aborted if the provided context is
47757// canceled.
47758func (c *ProjectsLocationsConversationsListCall) Context(ctx context.Context) *ProjectsLocationsConversationsListCall {
47759	c.ctx_ = ctx
47760	return c
47761}
47762
47763// Header returns an http.Header that can be modified by the caller to
47764// add HTTP headers to the request.
47765func (c *ProjectsLocationsConversationsListCall) Header() http.Header {
47766	if c.header_ == nil {
47767		c.header_ = make(http.Header)
47768	}
47769	return c.header_
47770}
47771
47772func (c *ProjectsLocationsConversationsListCall) doRequest(alt string) (*http.Response, error) {
47773	reqHeaders := make(http.Header)
47774	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20211027")
47775	for k, v := range c.header_ {
47776		reqHeaders[k] = v
47777	}
47778	reqHeaders.Set("User-Agent", c.s.userAgent())
47779	if c.ifNoneMatch_ != "" {
47780		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
47781	}
47782	var body io.Reader = nil
47783	c.urlParams_.Set("alt", alt)
47784	c.urlParams_.Set("prettyPrint", "false")
47785	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+parent}/conversations")
47786	urls += "?" + c.urlParams_.Encode()
47787	req, err := http.NewRequest("GET", urls, body)
47788	if err != nil {
47789		return nil, err
47790	}
47791	req.Header = reqHeaders
47792	googleapi.Expand(req.URL, map[string]string{
47793		"parent": c.parent,
47794	})
47795	return gensupport.SendRequest(c.ctx_, c.s.client, req)
47796}
47797
47798// Do executes the "dialogflow.projects.locations.conversations.list" call.
47799// Exactly one of *GoogleCloudDialogflowV2ListConversationsResponse or
47800// error will be non-nil. Any non-2xx status code is an error. Response
47801// headers are in either
47802// *GoogleCloudDialogflowV2ListConversationsResponse.ServerResponse.Heade
47803// r or (if a response was returned at all) in
47804// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
47805// whether the returned error was because http.StatusNotModified was
47806// returned.
47807func (c *ProjectsLocationsConversationsListCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDialogflowV2ListConversationsResponse, error) {
47808	gensupport.SetOptions(c.urlParams_, opts...)
47809	res, err := c.doRequest("json")
47810	if res != nil && res.StatusCode == http.StatusNotModified {
47811		if res.Body != nil {
47812			res.Body.Close()
47813		}
47814		return nil, &googleapi.Error{
47815			Code:   res.StatusCode,
47816			Header: res.Header,
47817		}
47818	}
47819	if err != nil {
47820		return nil, err
47821	}
47822	defer googleapi.CloseBody(res)
47823	if err := googleapi.CheckResponse(res); err != nil {
47824		return nil, err
47825	}
47826	ret := &GoogleCloudDialogflowV2ListConversationsResponse{
47827		ServerResponse: googleapi.ServerResponse{
47828			Header:         res.Header,
47829			HTTPStatusCode: res.StatusCode,
47830		},
47831	}
47832	target := &ret
47833	if err := gensupport.DecodeResponse(target, res); err != nil {
47834		return nil, err
47835	}
47836	return ret, nil
47837	// {
47838	//   "description": "Returns the list of all conversations in the specified project.",
47839	//   "flatPath": "v2/projects/{projectsId}/locations/{locationsId}/conversations",
47840	//   "httpMethod": "GET",
47841	//   "id": "dialogflow.projects.locations.conversations.list",
47842	//   "parameterOrder": [
47843	//     "parent"
47844	//   ],
47845	//   "parameters": {
47846	//     "filter": {
47847	//       "description": "A filter expression that filters conversations listed in the response. In general, the expression must specify the field name, a comparison operator, and the value to use for filtering: - The value must be a string, a number, or a boolean. - The comparison operator must be either `=`,`!=`, `\u003e`, or `\u003c`. - To filter on multiple expressions, separate the expressions with `AND` or `OR` (omitting both implies `AND`). - For clarity, expressions can be enclosed in parentheses. Only `lifecycle_state` can be filtered on in this way. For example, the following expression only returns `COMPLETED` conversations: `lifecycle_state = \"COMPLETED\"` For more information about filtering, see [API Filtering](https://aip.dev/160).",
47848	//       "location": "query",
47849	//       "type": "string"
47850	//     },
47851	//     "pageSize": {
47852	//       "description": "Optional. The maximum number of items to return in a single page. By default 100 and at most 1000.",
47853	//       "format": "int32",
47854	//       "location": "query",
47855	//       "type": "integer"
47856	//     },
47857	//     "pageToken": {
47858	//       "description": "Optional. The next_page_token value returned from a previous list request.",
47859	//       "location": "query",
47860	//       "type": "string"
47861	//     },
47862	//     "parent": {
47863	//       "description": "Required. The project from which to list all conversation. Format: `projects//locations/`.",
47864	//       "location": "path",
47865	//       "pattern": "^projects/[^/]+/locations/[^/]+$",
47866	//       "required": true,
47867	//       "type": "string"
47868	//     }
47869	//   },
47870	//   "path": "v2/{+parent}/conversations",
47871	//   "response": {
47872	//     "$ref": "GoogleCloudDialogflowV2ListConversationsResponse"
47873	//   },
47874	//   "scopes": [
47875	//     "https://www.googleapis.com/auth/cloud-platform",
47876	//     "https://www.googleapis.com/auth/dialogflow"
47877	//   ]
47878	// }
47879
47880}
47881
47882// Pages invokes f for each page of results.
47883// A non-nil error returned from f will halt the iteration.
47884// The provided context supersedes any context provided to the Context method.
47885func (c *ProjectsLocationsConversationsListCall) Pages(ctx context.Context, f func(*GoogleCloudDialogflowV2ListConversationsResponse) error) error {
47886	c.ctx_ = ctx
47887	defer c.PageToken(c.urlParams_.Get("pageToken")) // reset paging to original point
47888	for {
47889		x, err := c.Do()
47890		if err != nil {
47891			return err
47892		}
47893		if err := f(x); err != nil {
47894			return err
47895		}
47896		if x.NextPageToken == "" {
47897			return nil
47898		}
47899		c.PageToken(x.NextPageToken)
47900	}
47901}
47902
47903// method id "dialogflow.projects.locations.conversations.messages.list":
47904
47905type ProjectsLocationsConversationsMessagesListCall struct {
47906	s            *Service
47907	parent       string
47908	urlParams_   gensupport.URLParams
47909	ifNoneMatch_ string
47910	ctx_         context.Context
47911	header_      http.Header
47912}
47913
47914// List: Lists messages that belong to a given conversation. `messages`
47915// are ordered by `create_time` in descending order. To fetch updates
47916// without duplication, send request with filter
47917// `create_time_epoch_microseconds > [first item's create_time of
47918// previous request]` and empty page_token.
47919//
47920// - parent: The name of the conversation to list messages for. Format:
47921//   `projects//locations//conversations/`.
47922func (r *ProjectsLocationsConversationsMessagesService) List(parent string) *ProjectsLocationsConversationsMessagesListCall {
47923	c := &ProjectsLocationsConversationsMessagesListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
47924	c.parent = parent
47925	return c
47926}
47927
47928// Filter sets the optional parameter "filter": Filter on message
47929// fields. Currently predicates on `create_time` and
47930// `create_time_epoch_microseconds` are supported. `create_time` only
47931// support milliseconds accuracy. E.g., `create_time_epoch_microseconds
47932// > 1551790877964485` or `create_time > 2017-01-15T01:30:15.01Z`. For
47933// more information about filtering, see API Filtering
47934// (https://aip.dev/160).
47935func (c *ProjectsLocationsConversationsMessagesListCall) Filter(filter string) *ProjectsLocationsConversationsMessagesListCall {
47936	c.urlParams_.Set("filter", filter)
47937	return c
47938}
47939
47940// PageSize sets the optional parameter "pageSize": The maximum number
47941// of items to return in a single page. By default 100 and at most 1000.
47942func (c *ProjectsLocationsConversationsMessagesListCall) PageSize(pageSize int64) *ProjectsLocationsConversationsMessagesListCall {
47943	c.urlParams_.Set("pageSize", fmt.Sprint(pageSize))
47944	return c
47945}
47946
47947// PageToken sets the optional parameter "pageToken": The
47948// next_page_token value returned from a previous list request.
47949func (c *ProjectsLocationsConversationsMessagesListCall) PageToken(pageToken string) *ProjectsLocationsConversationsMessagesListCall {
47950	c.urlParams_.Set("pageToken", pageToken)
47951	return c
47952}
47953
47954// Fields allows partial responses to be retrieved. See
47955// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
47956// for more information.
47957func (c *ProjectsLocationsConversationsMessagesListCall) Fields(s ...googleapi.Field) *ProjectsLocationsConversationsMessagesListCall {
47958	c.urlParams_.Set("fields", googleapi.CombineFields(s))
47959	return c
47960}
47961
47962// IfNoneMatch sets the optional parameter which makes the operation
47963// fail if the object's ETag matches the given value. This is useful for
47964// getting updates only after the object has changed since the last
47965// request. Use googleapi.IsNotModified to check whether the response
47966// error from Do is the result of In-None-Match.
47967func (c *ProjectsLocationsConversationsMessagesListCall) IfNoneMatch(entityTag string) *ProjectsLocationsConversationsMessagesListCall {
47968	c.ifNoneMatch_ = entityTag
47969	return c
47970}
47971
47972// Context sets the context to be used in this call's Do method. Any
47973// pending HTTP request will be aborted if the provided context is
47974// canceled.
47975func (c *ProjectsLocationsConversationsMessagesListCall) Context(ctx context.Context) *ProjectsLocationsConversationsMessagesListCall {
47976	c.ctx_ = ctx
47977	return c
47978}
47979
47980// Header returns an http.Header that can be modified by the caller to
47981// add HTTP headers to the request.
47982func (c *ProjectsLocationsConversationsMessagesListCall) Header() http.Header {
47983	if c.header_ == nil {
47984		c.header_ = make(http.Header)
47985	}
47986	return c.header_
47987}
47988
47989func (c *ProjectsLocationsConversationsMessagesListCall) doRequest(alt string) (*http.Response, error) {
47990	reqHeaders := make(http.Header)
47991	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20211027")
47992	for k, v := range c.header_ {
47993		reqHeaders[k] = v
47994	}
47995	reqHeaders.Set("User-Agent", c.s.userAgent())
47996	if c.ifNoneMatch_ != "" {
47997		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
47998	}
47999	var body io.Reader = nil
48000	c.urlParams_.Set("alt", alt)
48001	c.urlParams_.Set("prettyPrint", "false")
48002	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+parent}/messages")
48003	urls += "?" + c.urlParams_.Encode()
48004	req, err := http.NewRequest("GET", urls, body)
48005	if err != nil {
48006		return nil, err
48007	}
48008	req.Header = reqHeaders
48009	googleapi.Expand(req.URL, map[string]string{
48010		"parent": c.parent,
48011	})
48012	return gensupport.SendRequest(c.ctx_, c.s.client, req)
48013}
48014
48015// Do executes the "dialogflow.projects.locations.conversations.messages.list" call.
48016// Exactly one of *GoogleCloudDialogflowV2ListMessagesResponse or error
48017// will be non-nil. Any non-2xx status code is an error. Response
48018// headers are in either
48019// *GoogleCloudDialogflowV2ListMessagesResponse.ServerResponse.Header or
48020// (if a response was returned at all) in
48021// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
48022// whether the returned error was because http.StatusNotModified was
48023// returned.
48024func (c *ProjectsLocationsConversationsMessagesListCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDialogflowV2ListMessagesResponse, error) {
48025	gensupport.SetOptions(c.urlParams_, opts...)
48026	res, err := c.doRequest("json")
48027	if res != nil && res.StatusCode == http.StatusNotModified {
48028		if res.Body != nil {
48029			res.Body.Close()
48030		}
48031		return nil, &googleapi.Error{
48032			Code:   res.StatusCode,
48033			Header: res.Header,
48034		}
48035	}
48036	if err != nil {
48037		return nil, err
48038	}
48039	defer googleapi.CloseBody(res)
48040	if err := googleapi.CheckResponse(res); err != nil {
48041		return nil, err
48042	}
48043	ret := &GoogleCloudDialogflowV2ListMessagesResponse{
48044		ServerResponse: googleapi.ServerResponse{
48045			Header:         res.Header,
48046			HTTPStatusCode: res.StatusCode,
48047		},
48048	}
48049	target := &ret
48050	if err := gensupport.DecodeResponse(target, res); err != nil {
48051		return nil, err
48052	}
48053	return ret, nil
48054	// {
48055	//   "description": "Lists messages that belong to a given conversation. `messages` are ordered by `create_time` in descending order. To fetch updates without duplication, send request with filter `create_time_epoch_microseconds \u003e [first item's create_time of previous request]` and empty page_token.",
48056	//   "flatPath": "v2/projects/{projectsId}/locations/{locationsId}/conversations/{conversationsId}/messages",
48057	//   "httpMethod": "GET",
48058	//   "id": "dialogflow.projects.locations.conversations.messages.list",
48059	//   "parameterOrder": [
48060	//     "parent"
48061	//   ],
48062	//   "parameters": {
48063	//     "filter": {
48064	//       "description": "Optional. Filter on message fields. Currently predicates on `create_time` and `create_time_epoch_microseconds` are supported. `create_time` only support milliseconds accuracy. E.g., `create_time_epoch_microseconds \u003e 1551790877964485` or `create_time \u003e 2017-01-15T01:30:15.01Z`. For more information about filtering, see [API Filtering](https://aip.dev/160).",
48065	//       "location": "query",
48066	//       "type": "string"
48067	//     },
48068	//     "pageSize": {
48069	//       "description": "Optional. The maximum number of items to return in a single page. By default 100 and at most 1000.",
48070	//       "format": "int32",
48071	//       "location": "query",
48072	//       "type": "integer"
48073	//     },
48074	//     "pageToken": {
48075	//       "description": "Optional. The next_page_token value returned from a previous list request.",
48076	//       "location": "query",
48077	//       "type": "string"
48078	//     },
48079	//     "parent": {
48080	//       "description": "Required. The name of the conversation to list messages for. Format: `projects//locations//conversations/`",
48081	//       "location": "path",
48082	//       "pattern": "^projects/[^/]+/locations/[^/]+/conversations/[^/]+$",
48083	//       "required": true,
48084	//       "type": "string"
48085	//     }
48086	//   },
48087	//   "path": "v2/{+parent}/messages",
48088	//   "response": {
48089	//     "$ref": "GoogleCloudDialogflowV2ListMessagesResponse"
48090	//   },
48091	//   "scopes": [
48092	//     "https://www.googleapis.com/auth/cloud-platform",
48093	//     "https://www.googleapis.com/auth/dialogflow"
48094	//   ]
48095	// }
48096
48097}
48098
48099// Pages invokes f for each page of results.
48100// A non-nil error returned from f will halt the iteration.
48101// The provided context supersedes any context provided to the Context method.
48102func (c *ProjectsLocationsConversationsMessagesListCall) Pages(ctx context.Context, f func(*GoogleCloudDialogflowV2ListMessagesResponse) error) error {
48103	c.ctx_ = ctx
48104	defer c.PageToken(c.urlParams_.Get("pageToken")) // reset paging to original point
48105	for {
48106		x, err := c.Do()
48107		if err != nil {
48108			return err
48109		}
48110		if err := f(x); err != nil {
48111			return err
48112		}
48113		if x.NextPageToken == "" {
48114			return nil
48115		}
48116		c.PageToken(x.NextPageToken)
48117	}
48118}
48119
48120// method id "dialogflow.projects.locations.conversations.participants.analyzeContent":
48121
48122type ProjectsLocationsConversationsParticipantsAnalyzeContentCall struct {
48123	s                                            *Service
48124	participant                                  string
48125	googleclouddialogflowv2analyzecontentrequest *GoogleCloudDialogflowV2AnalyzeContentRequest
48126	urlParams_                                   gensupport.URLParams
48127	ctx_                                         context.Context
48128	header_                                      http.Header
48129}
48130
48131// AnalyzeContent: Adds a text (chat, for example), or audio (phone
48132// recording, for example) message from a participant into the
48133// conversation. Note: Always use agent versions for production traffic
48134// sent to virtual agents. See Versions and environments
48135// (https://cloud.google.com/dialogflow/es/docs/agents-versions).
48136//
48137// - participant: The name of the participant this text comes from.
48138//   Format: `projects//locations//conversations//participants/`.
48139func (r *ProjectsLocationsConversationsParticipantsService) AnalyzeContent(participant string, googleclouddialogflowv2analyzecontentrequest *GoogleCloudDialogflowV2AnalyzeContentRequest) *ProjectsLocationsConversationsParticipantsAnalyzeContentCall {
48140	c := &ProjectsLocationsConversationsParticipantsAnalyzeContentCall{s: r.s, urlParams_: make(gensupport.URLParams)}
48141	c.participant = participant
48142	c.googleclouddialogflowv2analyzecontentrequest = googleclouddialogflowv2analyzecontentrequest
48143	return c
48144}
48145
48146// Fields allows partial responses to be retrieved. See
48147// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
48148// for more information.
48149func (c *ProjectsLocationsConversationsParticipantsAnalyzeContentCall) Fields(s ...googleapi.Field) *ProjectsLocationsConversationsParticipantsAnalyzeContentCall {
48150	c.urlParams_.Set("fields", googleapi.CombineFields(s))
48151	return c
48152}
48153
48154// Context sets the context to be used in this call's Do method. Any
48155// pending HTTP request will be aborted if the provided context is
48156// canceled.
48157func (c *ProjectsLocationsConversationsParticipantsAnalyzeContentCall) Context(ctx context.Context) *ProjectsLocationsConversationsParticipantsAnalyzeContentCall {
48158	c.ctx_ = ctx
48159	return c
48160}
48161
48162// Header returns an http.Header that can be modified by the caller to
48163// add HTTP headers to the request.
48164func (c *ProjectsLocationsConversationsParticipantsAnalyzeContentCall) Header() http.Header {
48165	if c.header_ == nil {
48166		c.header_ = make(http.Header)
48167	}
48168	return c.header_
48169}
48170
48171func (c *ProjectsLocationsConversationsParticipantsAnalyzeContentCall) doRequest(alt string) (*http.Response, error) {
48172	reqHeaders := make(http.Header)
48173	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20211027")
48174	for k, v := range c.header_ {
48175		reqHeaders[k] = v
48176	}
48177	reqHeaders.Set("User-Agent", c.s.userAgent())
48178	var body io.Reader = nil
48179	body, err := googleapi.WithoutDataWrapper.JSONReader(c.googleclouddialogflowv2analyzecontentrequest)
48180	if err != nil {
48181		return nil, err
48182	}
48183	reqHeaders.Set("Content-Type", "application/json")
48184	c.urlParams_.Set("alt", alt)
48185	c.urlParams_.Set("prettyPrint", "false")
48186	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+participant}:analyzeContent")
48187	urls += "?" + c.urlParams_.Encode()
48188	req, err := http.NewRequest("POST", urls, body)
48189	if err != nil {
48190		return nil, err
48191	}
48192	req.Header = reqHeaders
48193	googleapi.Expand(req.URL, map[string]string{
48194		"participant": c.participant,
48195	})
48196	return gensupport.SendRequest(c.ctx_, c.s.client, req)
48197}
48198
48199// Do executes the "dialogflow.projects.locations.conversations.participants.analyzeContent" call.
48200// Exactly one of *GoogleCloudDialogflowV2AnalyzeContentResponse or
48201// error will be non-nil. Any non-2xx status code is an error. Response
48202// headers are in either
48203// *GoogleCloudDialogflowV2AnalyzeContentResponse.ServerResponse.Header
48204// or (if a response was returned at all) in
48205// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
48206// whether the returned error was because http.StatusNotModified was
48207// returned.
48208func (c *ProjectsLocationsConversationsParticipantsAnalyzeContentCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDialogflowV2AnalyzeContentResponse, error) {
48209	gensupport.SetOptions(c.urlParams_, opts...)
48210	res, err := c.doRequest("json")
48211	if res != nil && res.StatusCode == http.StatusNotModified {
48212		if res.Body != nil {
48213			res.Body.Close()
48214		}
48215		return nil, &googleapi.Error{
48216			Code:   res.StatusCode,
48217			Header: res.Header,
48218		}
48219	}
48220	if err != nil {
48221		return nil, err
48222	}
48223	defer googleapi.CloseBody(res)
48224	if err := googleapi.CheckResponse(res); err != nil {
48225		return nil, err
48226	}
48227	ret := &GoogleCloudDialogflowV2AnalyzeContentResponse{
48228		ServerResponse: googleapi.ServerResponse{
48229			Header:         res.Header,
48230			HTTPStatusCode: res.StatusCode,
48231		},
48232	}
48233	target := &ret
48234	if err := gensupport.DecodeResponse(target, res); err != nil {
48235		return nil, err
48236	}
48237	return ret, nil
48238	// {
48239	//   "description": "Adds a text (chat, for example), or audio (phone recording, for example) message from a participant into the conversation. Note: Always use agent versions for production traffic sent to virtual agents. See [Versions and environments](https://cloud.google.com/dialogflow/es/docs/agents-versions).",
48240	//   "flatPath": "v2/projects/{projectsId}/locations/{locationsId}/conversations/{conversationsId}/participants/{participantsId}:analyzeContent",
48241	//   "httpMethod": "POST",
48242	//   "id": "dialogflow.projects.locations.conversations.participants.analyzeContent",
48243	//   "parameterOrder": [
48244	//     "participant"
48245	//   ],
48246	//   "parameters": {
48247	//     "participant": {
48248	//       "description": "Required. The name of the participant this text comes from. Format: `projects//locations//conversations//participants/`.",
48249	//       "location": "path",
48250	//       "pattern": "^projects/[^/]+/locations/[^/]+/conversations/[^/]+/participants/[^/]+$",
48251	//       "required": true,
48252	//       "type": "string"
48253	//     }
48254	//   },
48255	//   "path": "v2/{+participant}:analyzeContent",
48256	//   "request": {
48257	//     "$ref": "GoogleCloudDialogflowV2AnalyzeContentRequest"
48258	//   },
48259	//   "response": {
48260	//     "$ref": "GoogleCloudDialogflowV2AnalyzeContentResponse"
48261	//   },
48262	//   "scopes": [
48263	//     "https://www.googleapis.com/auth/cloud-platform",
48264	//     "https://www.googleapis.com/auth/dialogflow"
48265	//   ]
48266	// }
48267
48268}
48269
48270// method id "dialogflow.projects.locations.conversations.participants.create":
48271
48272type ProjectsLocationsConversationsParticipantsCreateCall struct {
48273	s                                  *Service
48274	parentid                           string
48275	googleclouddialogflowv2participant *GoogleCloudDialogflowV2Participant
48276	urlParams_                         gensupport.URLParams
48277	ctx_                               context.Context
48278	header_                            http.Header
48279}
48280
48281// Create: Creates a new participant in a conversation.
48282//
48283// - parent: Resource identifier of the conversation adding the
48284//   participant. Format: `projects//locations//conversations/`.
48285func (r *ProjectsLocationsConversationsParticipantsService) Create(parentid string, googleclouddialogflowv2participant *GoogleCloudDialogflowV2Participant) *ProjectsLocationsConversationsParticipantsCreateCall {
48286	c := &ProjectsLocationsConversationsParticipantsCreateCall{s: r.s, urlParams_: make(gensupport.URLParams)}
48287	c.parentid = parentid
48288	c.googleclouddialogflowv2participant = googleclouddialogflowv2participant
48289	return c
48290}
48291
48292// Fields allows partial responses to be retrieved. See
48293// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
48294// for more information.
48295func (c *ProjectsLocationsConversationsParticipantsCreateCall) Fields(s ...googleapi.Field) *ProjectsLocationsConversationsParticipantsCreateCall {
48296	c.urlParams_.Set("fields", googleapi.CombineFields(s))
48297	return c
48298}
48299
48300// Context sets the context to be used in this call's Do method. Any
48301// pending HTTP request will be aborted if the provided context is
48302// canceled.
48303func (c *ProjectsLocationsConversationsParticipantsCreateCall) Context(ctx context.Context) *ProjectsLocationsConversationsParticipantsCreateCall {
48304	c.ctx_ = ctx
48305	return c
48306}
48307
48308// Header returns an http.Header that can be modified by the caller to
48309// add HTTP headers to the request.
48310func (c *ProjectsLocationsConversationsParticipantsCreateCall) Header() http.Header {
48311	if c.header_ == nil {
48312		c.header_ = make(http.Header)
48313	}
48314	return c.header_
48315}
48316
48317func (c *ProjectsLocationsConversationsParticipantsCreateCall) doRequest(alt string) (*http.Response, error) {
48318	reqHeaders := make(http.Header)
48319	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20211027")
48320	for k, v := range c.header_ {
48321		reqHeaders[k] = v
48322	}
48323	reqHeaders.Set("User-Agent", c.s.userAgent())
48324	var body io.Reader = nil
48325	body, err := googleapi.WithoutDataWrapper.JSONReader(c.googleclouddialogflowv2participant)
48326	if err != nil {
48327		return nil, err
48328	}
48329	reqHeaders.Set("Content-Type", "application/json")
48330	c.urlParams_.Set("alt", alt)
48331	c.urlParams_.Set("prettyPrint", "false")
48332	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+parent}/participants")
48333	urls += "?" + c.urlParams_.Encode()
48334	req, err := http.NewRequest("POST", urls, body)
48335	if err != nil {
48336		return nil, err
48337	}
48338	req.Header = reqHeaders
48339	googleapi.Expand(req.URL, map[string]string{
48340		"parent": c.parentid,
48341	})
48342	return gensupport.SendRequest(c.ctx_, c.s.client, req)
48343}
48344
48345// Do executes the "dialogflow.projects.locations.conversations.participants.create" call.
48346// Exactly one of *GoogleCloudDialogflowV2Participant or error will be
48347// non-nil. Any non-2xx status code is an error. Response headers are in
48348// either *GoogleCloudDialogflowV2Participant.ServerResponse.Header or
48349// (if a response was returned at all) in
48350// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
48351// whether the returned error was because http.StatusNotModified was
48352// returned.
48353func (c *ProjectsLocationsConversationsParticipantsCreateCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDialogflowV2Participant, error) {
48354	gensupport.SetOptions(c.urlParams_, opts...)
48355	res, err := c.doRequest("json")
48356	if res != nil && res.StatusCode == http.StatusNotModified {
48357		if res.Body != nil {
48358			res.Body.Close()
48359		}
48360		return nil, &googleapi.Error{
48361			Code:   res.StatusCode,
48362			Header: res.Header,
48363		}
48364	}
48365	if err != nil {
48366		return nil, err
48367	}
48368	defer googleapi.CloseBody(res)
48369	if err := googleapi.CheckResponse(res); err != nil {
48370		return nil, err
48371	}
48372	ret := &GoogleCloudDialogflowV2Participant{
48373		ServerResponse: googleapi.ServerResponse{
48374			Header:         res.Header,
48375			HTTPStatusCode: res.StatusCode,
48376		},
48377	}
48378	target := &ret
48379	if err := gensupport.DecodeResponse(target, res); err != nil {
48380		return nil, err
48381	}
48382	return ret, nil
48383	// {
48384	//   "description": "Creates a new participant in a conversation.",
48385	//   "flatPath": "v2/projects/{projectsId}/locations/{locationsId}/conversations/{conversationsId}/participants",
48386	//   "httpMethod": "POST",
48387	//   "id": "dialogflow.projects.locations.conversations.participants.create",
48388	//   "parameterOrder": [
48389	//     "parent"
48390	//   ],
48391	//   "parameters": {
48392	//     "parent": {
48393	//       "description": "Required. Resource identifier of the conversation adding the participant. Format: `projects//locations//conversations/`.",
48394	//       "location": "path",
48395	//       "pattern": "^projects/[^/]+/locations/[^/]+/conversations/[^/]+$",
48396	//       "required": true,
48397	//       "type": "string"
48398	//     }
48399	//   },
48400	//   "path": "v2/{+parent}/participants",
48401	//   "request": {
48402	//     "$ref": "GoogleCloudDialogflowV2Participant"
48403	//   },
48404	//   "response": {
48405	//     "$ref": "GoogleCloudDialogflowV2Participant"
48406	//   },
48407	//   "scopes": [
48408	//     "https://www.googleapis.com/auth/cloud-platform",
48409	//     "https://www.googleapis.com/auth/dialogflow"
48410	//   ]
48411	// }
48412
48413}
48414
48415// method id "dialogflow.projects.locations.conversations.participants.get":
48416
48417type ProjectsLocationsConversationsParticipantsGetCall struct {
48418	s            *Service
48419	name         string
48420	urlParams_   gensupport.URLParams
48421	ifNoneMatch_ string
48422	ctx_         context.Context
48423	header_      http.Header
48424}
48425
48426// Get: Retrieves a conversation participant.
48427//
48428// - name: The name of the participant. Format:
48429//   `projects//locations//conversations//participants/`.
48430func (r *ProjectsLocationsConversationsParticipantsService) Get(name string) *ProjectsLocationsConversationsParticipantsGetCall {
48431	c := &ProjectsLocationsConversationsParticipantsGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
48432	c.name = name
48433	return c
48434}
48435
48436// Fields allows partial responses to be retrieved. See
48437// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
48438// for more information.
48439func (c *ProjectsLocationsConversationsParticipantsGetCall) Fields(s ...googleapi.Field) *ProjectsLocationsConversationsParticipantsGetCall {
48440	c.urlParams_.Set("fields", googleapi.CombineFields(s))
48441	return c
48442}
48443
48444// IfNoneMatch sets the optional parameter which makes the operation
48445// fail if the object's ETag matches the given value. This is useful for
48446// getting updates only after the object has changed since the last
48447// request. Use googleapi.IsNotModified to check whether the response
48448// error from Do is the result of In-None-Match.
48449func (c *ProjectsLocationsConversationsParticipantsGetCall) IfNoneMatch(entityTag string) *ProjectsLocationsConversationsParticipantsGetCall {
48450	c.ifNoneMatch_ = entityTag
48451	return c
48452}
48453
48454// Context sets the context to be used in this call's Do method. Any
48455// pending HTTP request will be aborted if the provided context is
48456// canceled.
48457func (c *ProjectsLocationsConversationsParticipantsGetCall) Context(ctx context.Context) *ProjectsLocationsConversationsParticipantsGetCall {
48458	c.ctx_ = ctx
48459	return c
48460}
48461
48462// Header returns an http.Header that can be modified by the caller to
48463// add HTTP headers to the request.
48464func (c *ProjectsLocationsConversationsParticipantsGetCall) Header() http.Header {
48465	if c.header_ == nil {
48466		c.header_ = make(http.Header)
48467	}
48468	return c.header_
48469}
48470
48471func (c *ProjectsLocationsConversationsParticipantsGetCall) doRequest(alt string) (*http.Response, error) {
48472	reqHeaders := make(http.Header)
48473	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20211027")
48474	for k, v := range c.header_ {
48475		reqHeaders[k] = v
48476	}
48477	reqHeaders.Set("User-Agent", c.s.userAgent())
48478	if c.ifNoneMatch_ != "" {
48479		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
48480	}
48481	var body io.Reader = nil
48482	c.urlParams_.Set("alt", alt)
48483	c.urlParams_.Set("prettyPrint", "false")
48484	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+name}")
48485	urls += "?" + c.urlParams_.Encode()
48486	req, err := http.NewRequest("GET", urls, body)
48487	if err != nil {
48488		return nil, err
48489	}
48490	req.Header = reqHeaders
48491	googleapi.Expand(req.URL, map[string]string{
48492		"name": c.name,
48493	})
48494	return gensupport.SendRequest(c.ctx_, c.s.client, req)
48495}
48496
48497// Do executes the "dialogflow.projects.locations.conversations.participants.get" call.
48498// Exactly one of *GoogleCloudDialogflowV2Participant or error will be
48499// non-nil. Any non-2xx status code is an error. Response headers are in
48500// either *GoogleCloudDialogflowV2Participant.ServerResponse.Header or
48501// (if a response was returned at all) in
48502// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
48503// whether the returned error was because http.StatusNotModified was
48504// returned.
48505func (c *ProjectsLocationsConversationsParticipantsGetCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDialogflowV2Participant, error) {
48506	gensupport.SetOptions(c.urlParams_, opts...)
48507	res, err := c.doRequest("json")
48508	if res != nil && res.StatusCode == http.StatusNotModified {
48509		if res.Body != nil {
48510			res.Body.Close()
48511		}
48512		return nil, &googleapi.Error{
48513			Code:   res.StatusCode,
48514			Header: res.Header,
48515		}
48516	}
48517	if err != nil {
48518		return nil, err
48519	}
48520	defer googleapi.CloseBody(res)
48521	if err := googleapi.CheckResponse(res); err != nil {
48522		return nil, err
48523	}
48524	ret := &GoogleCloudDialogflowV2Participant{
48525		ServerResponse: googleapi.ServerResponse{
48526			Header:         res.Header,
48527			HTTPStatusCode: res.StatusCode,
48528		},
48529	}
48530	target := &ret
48531	if err := gensupport.DecodeResponse(target, res); err != nil {
48532		return nil, err
48533	}
48534	return ret, nil
48535	// {
48536	//   "description": "Retrieves a conversation participant.",
48537	//   "flatPath": "v2/projects/{projectsId}/locations/{locationsId}/conversations/{conversationsId}/participants/{participantsId}",
48538	//   "httpMethod": "GET",
48539	//   "id": "dialogflow.projects.locations.conversations.participants.get",
48540	//   "parameterOrder": [
48541	//     "name"
48542	//   ],
48543	//   "parameters": {
48544	//     "name": {
48545	//       "description": "Required. The name of the participant. Format: `projects//locations//conversations//participants/`.",
48546	//       "location": "path",
48547	//       "pattern": "^projects/[^/]+/locations/[^/]+/conversations/[^/]+/participants/[^/]+$",
48548	//       "required": true,
48549	//       "type": "string"
48550	//     }
48551	//   },
48552	//   "path": "v2/{+name}",
48553	//   "response": {
48554	//     "$ref": "GoogleCloudDialogflowV2Participant"
48555	//   },
48556	//   "scopes": [
48557	//     "https://www.googleapis.com/auth/cloud-platform",
48558	//     "https://www.googleapis.com/auth/dialogflow"
48559	//   ]
48560	// }
48561
48562}
48563
48564// method id "dialogflow.projects.locations.conversations.participants.list":
48565
48566type ProjectsLocationsConversationsParticipantsListCall struct {
48567	s            *Service
48568	parent       string
48569	urlParams_   gensupport.URLParams
48570	ifNoneMatch_ string
48571	ctx_         context.Context
48572	header_      http.Header
48573}
48574
48575// List: Returns the list of all participants in the specified
48576// conversation.
48577//
48578// - parent: The conversation to list all participants from. Format:
48579//   `projects//locations//conversations/`.
48580func (r *ProjectsLocationsConversationsParticipantsService) List(parent string) *ProjectsLocationsConversationsParticipantsListCall {
48581	c := &ProjectsLocationsConversationsParticipantsListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
48582	c.parent = parent
48583	return c
48584}
48585
48586// PageSize sets the optional parameter "pageSize": The maximum number
48587// of items to return in a single page. By default 100 and at most 1000.
48588func (c *ProjectsLocationsConversationsParticipantsListCall) PageSize(pageSize int64) *ProjectsLocationsConversationsParticipantsListCall {
48589	c.urlParams_.Set("pageSize", fmt.Sprint(pageSize))
48590	return c
48591}
48592
48593// PageToken sets the optional parameter "pageToken": The
48594// next_page_token value returned from a previous list request.
48595func (c *ProjectsLocationsConversationsParticipantsListCall) PageToken(pageToken string) *ProjectsLocationsConversationsParticipantsListCall {
48596	c.urlParams_.Set("pageToken", pageToken)
48597	return c
48598}
48599
48600// Fields allows partial responses to be retrieved. See
48601// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
48602// for more information.
48603func (c *ProjectsLocationsConversationsParticipantsListCall) Fields(s ...googleapi.Field) *ProjectsLocationsConversationsParticipantsListCall {
48604	c.urlParams_.Set("fields", googleapi.CombineFields(s))
48605	return c
48606}
48607
48608// IfNoneMatch sets the optional parameter which makes the operation
48609// fail if the object's ETag matches the given value. This is useful for
48610// getting updates only after the object has changed since the last
48611// request. Use googleapi.IsNotModified to check whether the response
48612// error from Do is the result of In-None-Match.
48613func (c *ProjectsLocationsConversationsParticipantsListCall) IfNoneMatch(entityTag string) *ProjectsLocationsConversationsParticipantsListCall {
48614	c.ifNoneMatch_ = entityTag
48615	return c
48616}
48617
48618// Context sets the context to be used in this call's Do method. Any
48619// pending HTTP request will be aborted if the provided context is
48620// canceled.
48621func (c *ProjectsLocationsConversationsParticipantsListCall) Context(ctx context.Context) *ProjectsLocationsConversationsParticipantsListCall {
48622	c.ctx_ = ctx
48623	return c
48624}
48625
48626// Header returns an http.Header that can be modified by the caller to
48627// add HTTP headers to the request.
48628func (c *ProjectsLocationsConversationsParticipantsListCall) Header() http.Header {
48629	if c.header_ == nil {
48630		c.header_ = make(http.Header)
48631	}
48632	return c.header_
48633}
48634
48635func (c *ProjectsLocationsConversationsParticipantsListCall) doRequest(alt string) (*http.Response, error) {
48636	reqHeaders := make(http.Header)
48637	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20211027")
48638	for k, v := range c.header_ {
48639		reqHeaders[k] = v
48640	}
48641	reqHeaders.Set("User-Agent", c.s.userAgent())
48642	if c.ifNoneMatch_ != "" {
48643		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
48644	}
48645	var body io.Reader = nil
48646	c.urlParams_.Set("alt", alt)
48647	c.urlParams_.Set("prettyPrint", "false")
48648	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+parent}/participants")
48649	urls += "?" + c.urlParams_.Encode()
48650	req, err := http.NewRequest("GET", urls, body)
48651	if err != nil {
48652		return nil, err
48653	}
48654	req.Header = reqHeaders
48655	googleapi.Expand(req.URL, map[string]string{
48656		"parent": c.parent,
48657	})
48658	return gensupport.SendRequest(c.ctx_, c.s.client, req)
48659}
48660
48661// Do executes the "dialogflow.projects.locations.conversations.participants.list" call.
48662// Exactly one of *GoogleCloudDialogflowV2ListParticipantsResponse or
48663// error will be non-nil. Any non-2xx status code is an error. Response
48664// headers are in either
48665// *GoogleCloudDialogflowV2ListParticipantsResponse.ServerResponse.Header
48666//  or (if a response was returned at all) in
48667// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
48668// whether the returned error was because http.StatusNotModified was
48669// returned.
48670func (c *ProjectsLocationsConversationsParticipantsListCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDialogflowV2ListParticipantsResponse, error) {
48671	gensupport.SetOptions(c.urlParams_, opts...)
48672	res, err := c.doRequest("json")
48673	if res != nil && res.StatusCode == http.StatusNotModified {
48674		if res.Body != nil {
48675			res.Body.Close()
48676		}
48677		return nil, &googleapi.Error{
48678			Code:   res.StatusCode,
48679			Header: res.Header,
48680		}
48681	}
48682	if err != nil {
48683		return nil, err
48684	}
48685	defer googleapi.CloseBody(res)
48686	if err := googleapi.CheckResponse(res); err != nil {
48687		return nil, err
48688	}
48689	ret := &GoogleCloudDialogflowV2ListParticipantsResponse{
48690		ServerResponse: googleapi.ServerResponse{
48691			Header:         res.Header,
48692			HTTPStatusCode: res.StatusCode,
48693		},
48694	}
48695	target := &ret
48696	if err := gensupport.DecodeResponse(target, res); err != nil {
48697		return nil, err
48698	}
48699	return ret, nil
48700	// {
48701	//   "description": "Returns the list of all participants in the specified conversation.",
48702	//   "flatPath": "v2/projects/{projectsId}/locations/{locationsId}/conversations/{conversationsId}/participants",
48703	//   "httpMethod": "GET",
48704	//   "id": "dialogflow.projects.locations.conversations.participants.list",
48705	//   "parameterOrder": [
48706	//     "parent"
48707	//   ],
48708	//   "parameters": {
48709	//     "pageSize": {
48710	//       "description": "Optional. The maximum number of items to return in a single page. By default 100 and at most 1000.",
48711	//       "format": "int32",
48712	//       "location": "query",
48713	//       "type": "integer"
48714	//     },
48715	//     "pageToken": {
48716	//       "description": "Optional. The next_page_token value returned from a previous list request.",
48717	//       "location": "query",
48718	//       "type": "string"
48719	//     },
48720	//     "parent": {
48721	//       "description": "Required. The conversation to list all participants from. Format: `projects//locations//conversations/`.",
48722	//       "location": "path",
48723	//       "pattern": "^projects/[^/]+/locations/[^/]+/conversations/[^/]+$",
48724	//       "required": true,
48725	//       "type": "string"
48726	//     }
48727	//   },
48728	//   "path": "v2/{+parent}/participants",
48729	//   "response": {
48730	//     "$ref": "GoogleCloudDialogflowV2ListParticipantsResponse"
48731	//   },
48732	//   "scopes": [
48733	//     "https://www.googleapis.com/auth/cloud-platform",
48734	//     "https://www.googleapis.com/auth/dialogflow"
48735	//   ]
48736	// }
48737
48738}
48739
48740// Pages invokes f for each page of results.
48741// A non-nil error returned from f will halt the iteration.
48742// The provided context supersedes any context provided to the Context method.
48743func (c *ProjectsLocationsConversationsParticipantsListCall) Pages(ctx context.Context, f func(*GoogleCloudDialogflowV2ListParticipantsResponse) error) error {
48744	c.ctx_ = ctx
48745	defer c.PageToken(c.urlParams_.Get("pageToken")) // reset paging to original point
48746	for {
48747		x, err := c.Do()
48748		if err != nil {
48749			return err
48750		}
48751		if err := f(x); err != nil {
48752			return err
48753		}
48754		if x.NextPageToken == "" {
48755			return nil
48756		}
48757		c.PageToken(x.NextPageToken)
48758	}
48759}
48760
48761// method id "dialogflow.projects.locations.conversations.participants.patch":
48762
48763type ProjectsLocationsConversationsParticipantsPatchCall struct {
48764	s                                  *Service
48765	nameid                             string
48766	googleclouddialogflowv2participant *GoogleCloudDialogflowV2Participant
48767	urlParams_                         gensupport.URLParams
48768	ctx_                               context.Context
48769	header_                            http.Header
48770}
48771
48772// Patch: Updates the specified participant.
48773//
48774// - name: Optional. The unique identifier of this participant. Format:
48775//   `projects//locations//conversations//participants/`.
48776func (r *ProjectsLocationsConversationsParticipantsService) Patch(nameid string, googleclouddialogflowv2participant *GoogleCloudDialogflowV2Participant) *ProjectsLocationsConversationsParticipantsPatchCall {
48777	c := &ProjectsLocationsConversationsParticipantsPatchCall{s: r.s, urlParams_: make(gensupport.URLParams)}
48778	c.nameid = nameid
48779	c.googleclouddialogflowv2participant = googleclouddialogflowv2participant
48780	return c
48781}
48782
48783// UpdateMask sets the optional parameter "updateMask": Required. The
48784// mask to specify which fields to update.
48785func (c *ProjectsLocationsConversationsParticipantsPatchCall) UpdateMask(updateMask string) *ProjectsLocationsConversationsParticipantsPatchCall {
48786	c.urlParams_.Set("updateMask", updateMask)
48787	return c
48788}
48789
48790// Fields allows partial responses to be retrieved. See
48791// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
48792// for more information.
48793func (c *ProjectsLocationsConversationsParticipantsPatchCall) Fields(s ...googleapi.Field) *ProjectsLocationsConversationsParticipantsPatchCall {
48794	c.urlParams_.Set("fields", googleapi.CombineFields(s))
48795	return c
48796}
48797
48798// Context sets the context to be used in this call's Do method. Any
48799// pending HTTP request will be aborted if the provided context is
48800// canceled.
48801func (c *ProjectsLocationsConversationsParticipantsPatchCall) Context(ctx context.Context) *ProjectsLocationsConversationsParticipantsPatchCall {
48802	c.ctx_ = ctx
48803	return c
48804}
48805
48806// Header returns an http.Header that can be modified by the caller to
48807// add HTTP headers to the request.
48808func (c *ProjectsLocationsConversationsParticipantsPatchCall) Header() http.Header {
48809	if c.header_ == nil {
48810		c.header_ = make(http.Header)
48811	}
48812	return c.header_
48813}
48814
48815func (c *ProjectsLocationsConversationsParticipantsPatchCall) doRequest(alt string) (*http.Response, error) {
48816	reqHeaders := make(http.Header)
48817	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20211027")
48818	for k, v := range c.header_ {
48819		reqHeaders[k] = v
48820	}
48821	reqHeaders.Set("User-Agent", c.s.userAgent())
48822	var body io.Reader = nil
48823	body, err := googleapi.WithoutDataWrapper.JSONReader(c.googleclouddialogflowv2participant)
48824	if err != nil {
48825		return nil, err
48826	}
48827	reqHeaders.Set("Content-Type", "application/json")
48828	c.urlParams_.Set("alt", alt)
48829	c.urlParams_.Set("prettyPrint", "false")
48830	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+name}")
48831	urls += "?" + c.urlParams_.Encode()
48832	req, err := http.NewRequest("PATCH", urls, body)
48833	if err != nil {
48834		return nil, err
48835	}
48836	req.Header = reqHeaders
48837	googleapi.Expand(req.URL, map[string]string{
48838		"name": c.nameid,
48839	})
48840	return gensupport.SendRequest(c.ctx_, c.s.client, req)
48841}
48842
48843// Do executes the "dialogflow.projects.locations.conversations.participants.patch" call.
48844// Exactly one of *GoogleCloudDialogflowV2Participant or error will be
48845// non-nil. Any non-2xx status code is an error. Response headers are in
48846// either *GoogleCloudDialogflowV2Participant.ServerResponse.Header or
48847// (if a response was returned at all) in
48848// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
48849// whether the returned error was because http.StatusNotModified was
48850// returned.
48851func (c *ProjectsLocationsConversationsParticipantsPatchCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDialogflowV2Participant, error) {
48852	gensupport.SetOptions(c.urlParams_, opts...)
48853	res, err := c.doRequest("json")
48854	if res != nil && res.StatusCode == http.StatusNotModified {
48855		if res.Body != nil {
48856			res.Body.Close()
48857		}
48858		return nil, &googleapi.Error{
48859			Code:   res.StatusCode,
48860			Header: res.Header,
48861		}
48862	}
48863	if err != nil {
48864		return nil, err
48865	}
48866	defer googleapi.CloseBody(res)
48867	if err := googleapi.CheckResponse(res); err != nil {
48868		return nil, err
48869	}
48870	ret := &GoogleCloudDialogflowV2Participant{
48871		ServerResponse: googleapi.ServerResponse{
48872			Header:         res.Header,
48873			HTTPStatusCode: res.StatusCode,
48874		},
48875	}
48876	target := &ret
48877	if err := gensupport.DecodeResponse(target, res); err != nil {
48878		return nil, err
48879	}
48880	return ret, nil
48881	// {
48882	//   "description": "Updates the specified participant.",
48883	//   "flatPath": "v2/projects/{projectsId}/locations/{locationsId}/conversations/{conversationsId}/participants/{participantsId}",
48884	//   "httpMethod": "PATCH",
48885	//   "id": "dialogflow.projects.locations.conversations.participants.patch",
48886	//   "parameterOrder": [
48887	//     "name"
48888	//   ],
48889	//   "parameters": {
48890	//     "name": {
48891	//       "description": "Optional. The unique identifier of this participant. Format: `projects//locations//conversations//participants/`.",
48892	//       "location": "path",
48893	//       "pattern": "^projects/[^/]+/locations/[^/]+/conversations/[^/]+/participants/[^/]+$",
48894	//       "required": true,
48895	//       "type": "string"
48896	//     },
48897	//     "updateMask": {
48898	//       "description": "Required. The mask to specify which fields to update.",
48899	//       "format": "google-fieldmask",
48900	//       "location": "query",
48901	//       "type": "string"
48902	//     }
48903	//   },
48904	//   "path": "v2/{+name}",
48905	//   "request": {
48906	//     "$ref": "GoogleCloudDialogflowV2Participant"
48907	//   },
48908	//   "response": {
48909	//     "$ref": "GoogleCloudDialogflowV2Participant"
48910	//   },
48911	//   "scopes": [
48912	//     "https://www.googleapis.com/auth/cloud-platform",
48913	//     "https://www.googleapis.com/auth/dialogflow"
48914	//   ]
48915	// }
48916
48917}
48918
48919// method id "dialogflow.projects.locations.conversations.participants.suggestions.suggestArticles":
48920
48921type ProjectsLocationsConversationsParticipantsSuggestionsSuggestArticlesCall struct {
48922	s                                             *Service
48923	parent                                        string
48924	googleclouddialogflowv2suggestarticlesrequest *GoogleCloudDialogflowV2SuggestArticlesRequest
48925	urlParams_                                    gensupport.URLParams
48926	ctx_                                          context.Context
48927	header_                                       http.Header
48928}
48929
48930// SuggestArticles: Gets suggested articles for a participant based on
48931// specific historical messages.
48932//
48933// - parent: The name of the participant to fetch suggestion for.
48934//   Format: `projects//locations//conversations//participants/`.
48935func (r *ProjectsLocationsConversationsParticipantsSuggestionsService) SuggestArticles(parent string, googleclouddialogflowv2suggestarticlesrequest *GoogleCloudDialogflowV2SuggestArticlesRequest) *ProjectsLocationsConversationsParticipantsSuggestionsSuggestArticlesCall {
48936	c := &ProjectsLocationsConversationsParticipantsSuggestionsSuggestArticlesCall{s: r.s, urlParams_: make(gensupport.URLParams)}
48937	c.parent = parent
48938	c.googleclouddialogflowv2suggestarticlesrequest = googleclouddialogflowv2suggestarticlesrequest
48939	return c
48940}
48941
48942// Fields allows partial responses to be retrieved. See
48943// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
48944// for more information.
48945func (c *ProjectsLocationsConversationsParticipantsSuggestionsSuggestArticlesCall) Fields(s ...googleapi.Field) *ProjectsLocationsConversationsParticipantsSuggestionsSuggestArticlesCall {
48946	c.urlParams_.Set("fields", googleapi.CombineFields(s))
48947	return c
48948}
48949
48950// Context sets the context to be used in this call's Do method. Any
48951// pending HTTP request will be aborted if the provided context is
48952// canceled.
48953func (c *ProjectsLocationsConversationsParticipantsSuggestionsSuggestArticlesCall) Context(ctx context.Context) *ProjectsLocationsConversationsParticipantsSuggestionsSuggestArticlesCall {
48954	c.ctx_ = ctx
48955	return c
48956}
48957
48958// Header returns an http.Header that can be modified by the caller to
48959// add HTTP headers to the request.
48960func (c *ProjectsLocationsConversationsParticipantsSuggestionsSuggestArticlesCall) Header() http.Header {
48961	if c.header_ == nil {
48962		c.header_ = make(http.Header)
48963	}
48964	return c.header_
48965}
48966
48967func (c *ProjectsLocationsConversationsParticipantsSuggestionsSuggestArticlesCall) doRequest(alt string) (*http.Response, error) {
48968	reqHeaders := make(http.Header)
48969	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20211027")
48970	for k, v := range c.header_ {
48971		reqHeaders[k] = v
48972	}
48973	reqHeaders.Set("User-Agent", c.s.userAgent())
48974	var body io.Reader = nil
48975	body, err := googleapi.WithoutDataWrapper.JSONReader(c.googleclouddialogflowv2suggestarticlesrequest)
48976	if err != nil {
48977		return nil, err
48978	}
48979	reqHeaders.Set("Content-Type", "application/json")
48980	c.urlParams_.Set("alt", alt)
48981	c.urlParams_.Set("prettyPrint", "false")
48982	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+parent}/suggestions:suggestArticles")
48983	urls += "?" + c.urlParams_.Encode()
48984	req, err := http.NewRequest("POST", urls, body)
48985	if err != nil {
48986		return nil, err
48987	}
48988	req.Header = reqHeaders
48989	googleapi.Expand(req.URL, map[string]string{
48990		"parent": c.parent,
48991	})
48992	return gensupport.SendRequest(c.ctx_, c.s.client, req)
48993}
48994
48995// Do executes the "dialogflow.projects.locations.conversations.participants.suggestions.suggestArticles" call.
48996// Exactly one of *GoogleCloudDialogflowV2SuggestArticlesResponse or
48997// error will be non-nil. Any non-2xx status code is an error. Response
48998// headers are in either
48999// *GoogleCloudDialogflowV2SuggestArticlesResponse.ServerResponse.Header
49000// or (if a response was returned at all) in
49001// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
49002// whether the returned error was because http.StatusNotModified was
49003// returned.
49004func (c *ProjectsLocationsConversationsParticipantsSuggestionsSuggestArticlesCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDialogflowV2SuggestArticlesResponse, error) {
49005	gensupport.SetOptions(c.urlParams_, opts...)
49006	res, err := c.doRequest("json")
49007	if res != nil && res.StatusCode == http.StatusNotModified {
49008		if res.Body != nil {
49009			res.Body.Close()
49010		}
49011		return nil, &googleapi.Error{
49012			Code:   res.StatusCode,
49013			Header: res.Header,
49014		}
49015	}
49016	if err != nil {
49017		return nil, err
49018	}
49019	defer googleapi.CloseBody(res)
49020	if err := googleapi.CheckResponse(res); err != nil {
49021		return nil, err
49022	}
49023	ret := &GoogleCloudDialogflowV2SuggestArticlesResponse{
49024		ServerResponse: googleapi.ServerResponse{
49025			Header:         res.Header,
49026			HTTPStatusCode: res.StatusCode,
49027		},
49028	}
49029	target := &ret
49030	if err := gensupport.DecodeResponse(target, res); err != nil {
49031		return nil, err
49032	}
49033	return ret, nil
49034	// {
49035	//   "description": "Gets suggested articles for a participant based on specific historical messages.",
49036	//   "flatPath": "v2/projects/{projectsId}/locations/{locationsId}/conversations/{conversationsId}/participants/{participantsId}/suggestions:suggestArticles",
49037	//   "httpMethod": "POST",
49038	//   "id": "dialogflow.projects.locations.conversations.participants.suggestions.suggestArticles",
49039	//   "parameterOrder": [
49040	//     "parent"
49041	//   ],
49042	//   "parameters": {
49043	//     "parent": {
49044	//       "description": "Required. The name of the participant to fetch suggestion for. Format: `projects//locations//conversations//participants/`.",
49045	//       "location": "path",
49046	//       "pattern": "^projects/[^/]+/locations/[^/]+/conversations/[^/]+/participants/[^/]+$",
49047	//       "required": true,
49048	//       "type": "string"
49049	//     }
49050	//   },
49051	//   "path": "v2/{+parent}/suggestions:suggestArticles",
49052	//   "request": {
49053	//     "$ref": "GoogleCloudDialogflowV2SuggestArticlesRequest"
49054	//   },
49055	//   "response": {
49056	//     "$ref": "GoogleCloudDialogflowV2SuggestArticlesResponse"
49057	//   },
49058	//   "scopes": [
49059	//     "https://www.googleapis.com/auth/cloud-platform",
49060	//     "https://www.googleapis.com/auth/dialogflow"
49061	//   ]
49062	// }
49063
49064}
49065
49066// method id "dialogflow.projects.locations.conversations.participants.suggestions.suggestFaqAnswers":
49067
49068type ProjectsLocationsConversationsParticipantsSuggestionsSuggestFaqAnswersCall struct {
49069	s                                               *Service
49070	parent                                          string
49071	googleclouddialogflowv2suggestfaqanswersrequest *GoogleCloudDialogflowV2SuggestFaqAnswersRequest
49072	urlParams_                                      gensupport.URLParams
49073	ctx_                                            context.Context
49074	header_                                         http.Header
49075}
49076
49077// SuggestFaqAnswers: Gets suggested faq answers for a participant based
49078// on specific historical messages.
49079//
49080// - parent: The name of the participant to fetch suggestion for.
49081//   Format: `projects//locations//conversations//participants/`.
49082func (r *ProjectsLocationsConversationsParticipantsSuggestionsService) SuggestFaqAnswers(parent string, googleclouddialogflowv2suggestfaqanswersrequest *GoogleCloudDialogflowV2SuggestFaqAnswersRequest) *ProjectsLocationsConversationsParticipantsSuggestionsSuggestFaqAnswersCall {
49083	c := &ProjectsLocationsConversationsParticipantsSuggestionsSuggestFaqAnswersCall{s: r.s, urlParams_: make(gensupport.URLParams)}
49084	c.parent = parent
49085	c.googleclouddialogflowv2suggestfaqanswersrequest = googleclouddialogflowv2suggestfaqanswersrequest
49086	return c
49087}
49088
49089// Fields allows partial responses to be retrieved. See
49090// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
49091// for more information.
49092func (c *ProjectsLocationsConversationsParticipantsSuggestionsSuggestFaqAnswersCall) Fields(s ...googleapi.Field) *ProjectsLocationsConversationsParticipantsSuggestionsSuggestFaqAnswersCall {
49093	c.urlParams_.Set("fields", googleapi.CombineFields(s))
49094	return c
49095}
49096
49097// Context sets the context to be used in this call's Do method. Any
49098// pending HTTP request will be aborted if the provided context is
49099// canceled.
49100func (c *ProjectsLocationsConversationsParticipantsSuggestionsSuggestFaqAnswersCall) Context(ctx context.Context) *ProjectsLocationsConversationsParticipantsSuggestionsSuggestFaqAnswersCall {
49101	c.ctx_ = ctx
49102	return c
49103}
49104
49105// Header returns an http.Header that can be modified by the caller to
49106// add HTTP headers to the request.
49107func (c *ProjectsLocationsConversationsParticipantsSuggestionsSuggestFaqAnswersCall) Header() http.Header {
49108	if c.header_ == nil {
49109		c.header_ = make(http.Header)
49110	}
49111	return c.header_
49112}
49113
49114func (c *ProjectsLocationsConversationsParticipantsSuggestionsSuggestFaqAnswersCall) doRequest(alt string) (*http.Response, error) {
49115	reqHeaders := make(http.Header)
49116	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20211027")
49117	for k, v := range c.header_ {
49118		reqHeaders[k] = v
49119	}
49120	reqHeaders.Set("User-Agent", c.s.userAgent())
49121	var body io.Reader = nil
49122	body, err := googleapi.WithoutDataWrapper.JSONReader(c.googleclouddialogflowv2suggestfaqanswersrequest)
49123	if err != nil {
49124		return nil, err
49125	}
49126	reqHeaders.Set("Content-Type", "application/json")
49127	c.urlParams_.Set("alt", alt)
49128	c.urlParams_.Set("prettyPrint", "false")
49129	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+parent}/suggestions:suggestFaqAnswers")
49130	urls += "?" + c.urlParams_.Encode()
49131	req, err := http.NewRequest("POST", urls, body)
49132	if err != nil {
49133		return nil, err
49134	}
49135	req.Header = reqHeaders
49136	googleapi.Expand(req.URL, map[string]string{
49137		"parent": c.parent,
49138	})
49139	return gensupport.SendRequest(c.ctx_, c.s.client, req)
49140}
49141
49142// Do executes the "dialogflow.projects.locations.conversations.participants.suggestions.suggestFaqAnswers" call.
49143// Exactly one of *GoogleCloudDialogflowV2SuggestFaqAnswersResponse or
49144// error will be non-nil. Any non-2xx status code is an error. Response
49145// headers are in either
49146// *GoogleCloudDialogflowV2SuggestFaqAnswersResponse.ServerResponse.Heade
49147// r or (if a response was returned at all) in
49148// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
49149// whether the returned error was because http.StatusNotModified was
49150// returned.
49151func (c *ProjectsLocationsConversationsParticipantsSuggestionsSuggestFaqAnswersCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDialogflowV2SuggestFaqAnswersResponse, error) {
49152	gensupport.SetOptions(c.urlParams_, opts...)
49153	res, err := c.doRequest("json")
49154	if res != nil && res.StatusCode == http.StatusNotModified {
49155		if res.Body != nil {
49156			res.Body.Close()
49157		}
49158		return nil, &googleapi.Error{
49159			Code:   res.StatusCode,
49160			Header: res.Header,
49161		}
49162	}
49163	if err != nil {
49164		return nil, err
49165	}
49166	defer googleapi.CloseBody(res)
49167	if err := googleapi.CheckResponse(res); err != nil {
49168		return nil, err
49169	}
49170	ret := &GoogleCloudDialogflowV2SuggestFaqAnswersResponse{
49171		ServerResponse: googleapi.ServerResponse{
49172			Header:         res.Header,
49173			HTTPStatusCode: res.StatusCode,
49174		},
49175	}
49176	target := &ret
49177	if err := gensupport.DecodeResponse(target, res); err != nil {
49178		return nil, err
49179	}
49180	return ret, nil
49181	// {
49182	//   "description": "Gets suggested faq answers for a participant based on specific historical messages.",
49183	//   "flatPath": "v2/projects/{projectsId}/locations/{locationsId}/conversations/{conversationsId}/participants/{participantsId}/suggestions:suggestFaqAnswers",
49184	//   "httpMethod": "POST",
49185	//   "id": "dialogflow.projects.locations.conversations.participants.suggestions.suggestFaqAnswers",
49186	//   "parameterOrder": [
49187	//     "parent"
49188	//   ],
49189	//   "parameters": {
49190	//     "parent": {
49191	//       "description": "Required. The name of the participant to fetch suggestion for. Format: `projects//locations//conversations//participants/`.",
49192	//       "location": "path",
49193	//       "pattern": "^projects/[^/]+/locations/[^/]+/conversations/[^/]+/participants/[^/]+$",
49194	//       "required": true,
49195	//       "type": "string"
49196	//     }
49197	//   },
49198	//   "path": "v2/{+parent}/suggestions:suggestFaqAnswers",
49199	//   "request": {
49200	//     "$ref": "GoogleCloudDialogflowV2SuggestFaqAnswersRequest"
49201	//   },
49202	//   "response": {
49203	//     "$ref": "GoogleCloudDialogflowV2SuggestFaqAnswersResponse"
49204	//   },
49205	//   "scopes": [
49206	//     "https://www.googleapis.com/auth/cloud-platform",
49207	//     "https://www.googleapis.com/auth/dialogflow"
49208	//   ]
49209	// }
49210
49211}
49212
49213// method id "dialogflow.projects.locations.knowledgeBases.create":
49214
49215type ProjectsLocationsKnowledgeBasesCreateCall struct {
49216	s                                    *Service
49217	parent                               string
49218	googleclouddialogflowv2knowledgebase *GoogleCloudDialogflowV2KnowledgeBase
49219	urlParams_                           gensupport.URLParams
49220	ctx_                                 context.Context
49221	header_                              http.Header
49222}
49223
49224// Create: Creates a knowledge base.
49225//
49226// - parent: The project to create a knowledge base for. Format:
49227//   `projects//locations/`.
49228func (r *ProjectsLocationsKnowledgeBasesService) Create(parent string, googleclouddialogflowv2knowledgebase *GoogleCloudDialogflowV2KnowledgeBase) *ProjectsLocationsKnowledgeBasesCreateCall {
49229	c := &ProjectsLocationsKnowledgeBasesCreateCall{s: r.s, urlParams_: make(gensupport.URLParams)}
49230	c.parent = parent
49231	c.googleclouddialogflowv2knowledgebase = googleclouddialogflowv2knowledgebase
49232	return c
49233}
49234
49235// Fields allows partial responses to be retrieved. See
49236// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
49237// for more information.
49238func (c *ProjectsLocationsKnowledgeBasesCreateCall) Fields(s ...googleapi.Field) *ProjectsLocationsKnowledgeBasesCreateCall {
49239	c.urlParams_.Set("fields", googleapi.CombineFields(s))
49240	return c
49241}
49242
49243// Context sets the context to be used in this call's Do method. Any
49244// pending HTTP request will be aborted if the provided context is
49245// canceled.
49246func (c *ProjectsLocationsKnowledgeBasesCreateCall) Context(ctx context.Context) *ProjectsLocationsKnowledgeBasesCreateCall {
49247	c.ctx_ = ctx
49248	return c
49249}
49250
49251// Header returns an http.Header that can be modified by the caller to
49252// add HTTP headers to the request.
49253func (c *ProjectsLocationsKnowledgeBasesCreateCall) Header() http.Header {
49254	if c.header_ == nil {
49255		c.header_ = make(http.Header)
49256	}
49257	return c.header_
49258}
49259
49260func (c *ProjectsLocationsKnowledgeBasesCreateCall) doRequest(alt string) (*http.Response, error) {
49261	reqHeaders := make(http.Header)
49262	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20211027")
49263	for k, v := range c.header_ {
49264		reqHeaders[k] = v
49265	}
49266	reqHeaders.Set("User-Agent", c.s.userAgent())
49267	var body io.Reader = nil
49268	body, err := googleapi.WithoutDataWrapper.JSONReader(c.googleclouddialogflowv2knowledgebase)
49269	if err != nil {
49270		return nil, err
49271	}
49272	reqHeaders.Set("Content-Type", "application/json")
49273	c.urlParams_.Set("alt", alt)
49274	c.urlParams_.Set("prettyPrint", "false")
49275	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+parent}/knowledgeBases")
49276	urls += "?" + c.urlParams_.Encode()
49277	req, err := http.NewRequest("POST", urls, body)
49278	if err != nil {
49279		return nil, err
49280	}
49281	req.Header = reqHeaders
49282	googleapi.Expand(req.URL, map[string]string{
49283		"parent": c.parent,
49284	})
49285	return gensupport.SendRequest(c.ctx_, c.s.client, req)
49286}
49287
49288// Do executes the "dialogflow.projects.locations.knowledgeBases.create" call.
49289// Exactly one of *GoogleCloudDialogflowV2KnowledgeBase or error will be
49290// non-nil. Any non-2xx status code is an error. Response headers are in
49291// either *GoogleCloudDialogflowV2KnowledgeBase.ServerResponse.Header or
49292// (if a response was returned at all) in
49293// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
49294// whether the returned error was because http.StatusNotModified was
49295// returned.
49296func (c *ProjectsLocationsKnowledgeBasesCreateCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDialogflowV2KnowledgeBase, error) {
49297	gensupport.SetOptions(c.urlParams_, opts...)
49298	res, err := c.doRequest("json")
49299	if res != nil && res.StatusCode == http.StatusNotModified {
49300		if res.Body != nil {
49301			res.Body.Close()
49302		}
49303		return nil, &googleapi.Error{
49304			Code:   res.StatusCode,
49305			Header: res.Header,
49306		}
49307	}
49308	if err != nil {
49309		return nil, err
49310	}
49311	defer googleapi.CloseBody(res)
49312	if err := googleapi.CheckResponse(res); err != nil {
49313		return nil, err
49314	}
49315	ret := &GoogleCloudDialogflowV2KnowledgeBase{
49316		ServerResponse: googleapi.ServerResponse{
49317			Header:         res.Header,
49318			HTTPStatusCode: res.StatusCode,
49319		},
49320	}
49321	target := &ret
49322	if err := gensupport.DecodeResponse(target, res); err != nil {
49323		return nil, err
49324	}
49325	return ret, nil
49326	// {
49327	//   "description": "Creates a knowledge base.",
49328	//   "flatPath": "v2/projects/{projectsId}/locations/{locationsId}/knowledgeBases",
49329	//   "httpMethod": "POST",
49330	//   "id": "dialogflow.projects.locations.knowledgeBases.create",
49331	//   "parameterOrder": [
49332	//     "parent"
49333	//   ],
49334	//   "parameters": {
49335	//     "parent": {
49336	//       "description": "Required. The project to create a knowledge base for. Format: `projects//locations/`.",
49337	//       "location": "path",
49338	//       "pattern": "^projects/[^/]+/locations/[^/]+$",
49339	//       "required": true,
49340	//       "type": "string"
49341	//     }
49342	//   },
49343	//   "path": "v2/{+parent}/knowledgeBases",
49344	//   "request": {
49345	//     "$ref": "GoogleCloudDialogflowV2KnowledgeBase"
49346	//   },
49347	//   "response": {
49348	//     "$ref": "GoogleCloudDialogflowV2KnowledgeBase"
49349	//   },
49350	//   "scopes": [
49351	//     "https://www.googleapis.com/auth/cloud-platform",
49352	//     "https://www.googleapis.com/auth/dialogflow"
49353	//   ]
49354	// }
49355
49356}
49357
49358// method id "dialogflow.projects.locations.knowledgeBases.delete":
49359
49360type ProjectsLocationsKnowledgeBasesDeleteCall struct {
49361	s          *Service
49362	name       string
49363	urlParams_ gensupport.URLParams
49364	ctx_       context.Context
49365	header_    http.Header
49366}
49367
49368// Delete: Deletes the specified knowledge base.
49369//
49370// - name: The name of the knowledge base to delete. Format:
49371//   `projects//locations//knowledgeBases/`.
49372func (r *ProjectsLocationsKnowledgeBasesService) Delete(name string) *ProjectsLocationsKnowledgeBasesDeleteCall {
49373	c := &ProjectsLocationsKnowledgeBasesDeleteCall{s: r.s, urlParams_: make(gensupport.URLParams)}
49374	c.name = name
49375	return c
49376}
49377
49378// Force sets the optional parameter "force": Force deletes the
49379// knowledge base. When set to true, any documents in the knowledge base
49380// are also deleted.
49381func (c *ProjectsLocationsKnowledgeBasesDeleteCall) Force(force bool) *ProjectsLocationsKnowledgeBasesDeleteCall {
49382	c.urlParams_.Set("force", fmt.Sprint(force))
49383	return c
49384}
49385
49386// Fields allows partial responses to be retrieved. See
49387// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
49388// for more information.
49389func (c *ProjectsLocationsKnowledgeBasesDeleteCall) Fields(s ...googleapi.Field) *ProjectsLocationsKnowledgeBasesDeleteCall {
49390	c.urlParams_.Set("fields", googleapi.CombineFields(s))
49391	return c
49392}
49393
49394// Context sets the context to be used in this call's Do method. Any
49395// pending HTTP request will be aborted if the provided context is
49396// canceled.
49397func (c *ProjectsLocationsKnowledgeBasesDeleteCall) Context(ctx context.Context) *ProjectsLocationsKnowledgeBasesDeleteCall {
49398	c.ctx_ = ctx
49399	return c
49400}
49401
49402// Header returns an http.Header that can be modified by the caller to
49403// add HTTP headers to the request.
49404func (c *ProjectsLocationsKnowledgeBasesDeleteCall) Header() http.Header {
49405	if c.header_ == nil {
49406		c.header_ = make(http.Header)
49407	}
49408	return c.header_
49409}
49410
49411func (c *ProjectsLocationsKnowledgeBasesDeleteCall) doRequest(alt string) (*http.Response, error) {
49412	reqHeaders := make(http.Header)
49413	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20211027")
49414	for k, v := range c.header_ {
49415		reqHeaders[k] = v
49416	}
49417	reqHeaders.Set("User-Agent", c.s.userAgent())
49418	var body io.Reader = nil
49419	c.urlParams_.Set("alt", alt)
49420	c.urlParams_.Set("prettyPrint", "false")
49421	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+name}")
49422	urls += "?" + c.urlParams_.Encode()
49423	req, err := http.NewRequest("DELETE", urls, body)
49424	if err != nil {
49425		return nil, err
49426	}
49427	req.Header = reqHeaders
49428	googleapi.Expand(req.URL, map[string]string{
49429		"name": c.name,
49430	})
49431	return gensupport.SendRequest(c.ctx_, c.s.client, req)
49432}
49433
49434// Do executes the "dialogflow.projects.locations.knowledgeBases.delete" call.
49435// Exactly one of *GoogleProtobufEmpty or error will be non-nil. Any
49436// non-2xx status code is an error. Response headers are in either
49437// *GoogleProtobufEmpty.ServerResponse.Header or (if a response was
49438// returned at all) in error.(*googleapi.Error).Header. Use
49439// googleapi.IsNotModified to check whether the returned error was
49440// because http.StatusNotModified was returned.
49441func (c *ProjectsLocationsKnowledgeBasesDeleteCall) Do(opts ...googleapi.CallOption) (*GoogleProtobufEmpty, error) {
49442	gensupport.SetOptions(c.urlParams_, opts...)
49443	res, err := c.doRequest("json")
49444	if res != nil && res.StatusCode == http.StatusNotModified {
49445		if res.Body != nil {
49446			res.Body.Close()
49447		}
49448		return nil, &googleapi.Error{
49449			Code:   res.StatusCode,
49450			Header: res.Header,
49451		}
49452	}
49453	if err != nil {
49454		return nil, err
49455	}
49456	defer googleapi.CloseBody(res)
49457	if err := googleapi.CheckResponse(res); err != nil {
49458		return nil, err
49459	}
49460	ret := &GoogleProtobufEmpty{
49461		ServerResponse: googleapi.ServerResponse{
49462			Header:         res.Header,
49463			HTTPStatusCode: res.StatusCode,
49464		},
49465	}
49466	target := &ret
49467	if err := gensupport.DecodeResponse(target, res); err != nil {
49468		return nil, err
49469	}
49470	return ret, nil
49471	// {
49472	//   "description": "Deletes the specified knowledge base.",
49473	//   "flatPath": "v2/projects/{projectsId}/locations/{locationsId}/knowledgeBases/{knowledgeBasesId}",
49474	//   "httpMethod": "DELETE",
49475	//   "id": "dialogflow.projects.locations.knowledgeBases.delete",
49476	//   "parameterOrder": [
49477	//     "name"
49478	//   ],
49479	//   "parameters": {
49480	//     "force": {
49481	//       "description": "Optional. Force deletes the knowledge base. When set to true, any documents in the knowledge base are also deleted.",
49482	//       "location": "query",
49483	//       "type": "boolean"
49484	//     },
49485	//     "name": {
49486	//       "description": "Required. The name of the knowledge base to delete. Format: `projects//locations//knowledgeBases/`.",
49487	//       "location": "path",
49488	//       "pattern": "^projects/[^/]+/locations/[^/]+/knowledgeBases/[^/]+$",
49489	//       "required": true,
49490	//       "type": "string"
49491	//     }
49492	//   },
49493	//   "path": "v2/{+name}",
49494	//   "response": {
49495	//     "$ref": "GoogleProtobufEmpty"
49496	//   },
49497	//   "scopes": [
49498	//     "https://www.googleapis.com/auth/cloud-platform",
49499	//     "https://www.googleapis.com/auth/dialogflow"
49500	//   ]
49501	// }
49502
49503}
49504
49505// method id "dialogflow.projects.locations.knowledgeBases.get":
49506
49507type ProjectsLocationsKnowledgeBasesGetCall struct {
49508	s            *Service
49509	name         string
49510	urlParams_   gensupport.URLParams
49511	ifNoneMatch_ string
49512	ctx_         context.Context
49513	header_      http.Header
49514}
49515
49516// Get: Retrieves the specified knowledge base.
49517//
49518// - name: The name of the knowledge base to retrieve. Format
49519//   `projects//locations//knowledgeBases/`.
49520func (r *ProjectsLocationsKnowledgeBasesService) Get(name string) *ProjectsLocationsKnowledgeBasesGetCall {
49521	c := &ProjectsLocationsKnowledgeBasesGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
49522	c.name = name
49523	return c
49524}
49525
49526// Fields allows partial responses to be retrieved. See
49527// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
49528// for more information.
49529func (c *ProjectsLocationsKnowledgeBasesGetCall) Fields(s ...googleapi.Field) *ProjectsLocationsKnowledgeBasesGetCall {
49530	c.urlParams_.Set("fields", googleapi.CombineFields(s))
49531	return c
49532}
49533
49534// IfNoneMatch sets the optional parameter which makes the operation
49535// fail if the object's ETag matches the given value. This is useful for
49536// getting updates only after the object has changed since the last
49537// request. Use googleapi.IsNotModified to check whether the response
49538// error from Do is the result of In-None-Match.
49539func (c *ProjectsLocationsKnowledgeBasesGetCall) IfNoneMatch(entityTag string) *ProjectsLocationsKnowledgeBasesGetCall {
49540	c.ifNoneMatch_ = entityTag
49541	return c
49542}
49543
49544// Context sets the context to be used in this call's Do method. Any
49545// pending HTTP request will be aborted if the provided context is
49546// canceled.
49547func (c *ProjectsLocationsKnowledgeBasesGetCall) Context(ctx context.Context) *ProjectsLocationsKnowledgeBasesGetCall {
49548	c.ctx_ = ctx
49549	return c
49550}
49551
49552// Header returns an http.Header that can be modified by the caller to
49553// add HTTP headers to the request.
49554func (c *ProjectsLocationsKnowledgeBasesGetCall) Header() http.Header {
49555	if c.header_ == nil {
49556		c.header_ = make(http.Header)
49557	}
49558	return c.header_
49559}
49560
49561func (c *ProjectsLocationsKnowledgeBasesGetCall) doRequest(alt string) (*http.Response, error) {
49562	reqHeaders := make(http.Header)
49563	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20211027")
49564	for k, v := range c.header_ {
49565		reqHeaders[k] = v
49566	}
49567	reqHeaders.Set("User-Agent", c.s.userAgent())
49568	if c.ifNoneMatch_ != "" {
49569		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
49570	}
49571	var body io.Reader = nil
49572	c.urlParams_.Set("alt", alt)
49573	c.urlParams_.Set("prettyPrint", "false")
49574	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+name}")
49575	urls += "?" + c.urlParams_.Encode()
49576	req, err := http.NewRequest("GET", urls, body)
49577	if err != nil {
49578		return nil, err
49579	}
49580	req.Header = reqHeaders
49581	googleapi.Expand(req.URL, map[string]string{
49582		"name": c.name,
49583	})
49584	return gensupport.SendRequest(c.ctx_, c.s.client, req)
49585}
49586
49587// Do executes the "dialogflow.projects.locations.knowledgeBases.get" call.
49588// Exactly one of *GoogleCloudDialogflowV2KnowledgeBase or error will be
49589// non-nil. Any non-2xx status code is an error. Response headers are in
49590// either *GoogleCloudDialogflowV2KnowledgeBase.ServerResponse.Header or
49591// (if a response was returned at all) in
49592// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
49593// whether the returned error was because http.StatusNotModified was
49594// returned.
49595func (c *ProjectsLocationsKnowledgeBasesGetCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDialogflowV2KnowledgeBase, error) {
49596	gensupport.SetOptions(c.urlParams_, opts...)
49597	res, err := c.doRequest("json")
49598	if res != nil && res.StatusCode == http.StatusNotModified {
49599		if res.Body != nil {
49600			res.Body.Close()
49601		}
49602		return nil, &googleapi.Error{
49603			Code:   res.StatusCode,
49604			Header: res.Header,
49605		}
49606	}
49607	if err != nil {
49608		return nil, err
49609	}
49610	defer googleapi.CloseBody(res)
49611	if err := googleapi.CheckResponse(res); err != nil {
49612		return nil, err
49613	}
49614	ret := &GoogleCloudDialogflowV2KnowledgeBase{
49615		ServerResponse: googleapi.ServerResponse{
49616			Header:         res.Header,
49617			HTTPStatusCode: res.StatusCode,
49618		},
49619	}
49620	target := &ret
49621	if err := gensupport.DecodeResponse(target, res); err != nil {
49622		return nil, err
49623	}
49624	return ret, nil
49625	// {
49626	//   "description": "Retrieves the specified knowledge base.",
49627	//   "flatPath": "v2/projects/{projectsId}/locations/{locationsId}/knowledgeBases/{knowledgeBasesId}",
49628	//   "httpMethod": "GET",
49629	//   "id": "dialogflow.projects.locations.knowledgeBases.get",
49630	//   "parameterOrder": [
49631	//     "name"
49632	//   ],
49633	//   "parameters": {
49634	//     "name": {
49635	//       "description": "Required. The name of the knowledge base to retrieve. Format `projects//locations//knowledgeBases/`.",
49636	//       "location": "path",
49637	//       "pattern": "^projects/[^/]+/locations/[^/]+/knowledgeBases/[^/]+$",
49638	//       "required": true,
49639	//       "type": "string"
49640	//     }
49641	//   },
49642	//   "path": "v2/{+name}",
49643	//   "response": {
49644	//     "$ref": "GoogleCloudDialogflowV2KnowledgeBase"
49645	//   },
49646	//   "scopes": [
49647	//     "https://www.googleapis.com/auth/cloud-platform",
49648	//     "https://www.googleapis.com/auth/dialogflow"
49649	//   ]
49650	// }
49651
49652}
49653
49654// method id "dialogflow.projects.locations.knowledgeBases.list":
49655
49656type ProjectsLocationsKnowledgeBasesListCall struct {
49657	s            *Service
49658	parent       string
49659	urlParams_   gensupport.URLParams
49660	ifNoneMatch_ string
49661	ctx_         context.Context
49662	header_      http.Header
49663}
49664
49665// List: Returns the list of all knowledge bases of the specified agent.
49666//
49667// - parent: The project to list of knowledge bases for. Format:
49668//   `projects//locations/`.
49669func (r *ProjectsLocationsKnowledgeBasesService) List(parent string) *ProjectsLocationsKnowledgeBasesListCall {
49670	c := &ProjectsLocationsKnowledgeBasesListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
49671	c.parent = parent
49672	return c
49673}
49674
49675// PageSize sets the optional parameter "pageSize": The maximum number
49676// of items to return in a single page. By default 10 and at most 100.
49677func (c *ProjectsLocationsKnowledgeBasesListCall) PageSize(pageSize int64) *ProjectsLocationsKnowledgeBasesListCall {
49678	c.urlParams_.Set("pageSize", fmt.Sprint(pageSize))
49679	return c
49680}
49681
49682// PageToken sets the optional parameter "pageToken": The
49683// next_page_token value returned from a previous list request.
49684func (c *ProjectsLocationsKnowledgeBasesListCall) PageToken(pageToken string) *ProjectsLocationsKnowledgeBasesListCall {
49685	c.urlParams_.Set("pageToken", pageToken)
49686	return c
49687}
49688
49689// Fields allows partial responses to be retrieved. See
49690// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
49691// for more information.
49692func (c *ProjectsLocationsKnowledgeBasesListCall) Fields(s ...googleapi.Field) *ProjectsLocationsKnowledgeBasesListCall {
49693	c.urlParams_.Set("fields", googleapi.CombineFields(s))
49694	return c
49695}
49696
49697// IfNoneMatch sets the optional parameter which makes the operation
49698// fail if the object's ETag matches the given value. This is useful for
49699// getting updates only after the object has changed since the last
49700// request. Use googleapi.IsNotModified to check whether the response
49701// error from Do is the result of In-None-Match.
49702func (c *ProjectsLocationsKnowledgeBasesListCall) IfNoneMatch(entityTag string) *ProjectsLocationsKnowledgeBasesListCall {
49703	c.ifNoneMatch_ = entityTag
49704	return c
49705}
49706
49707// Context sets the context to be used in this call's Do method. Any
49708// pending HTTP request will be aborted if the provided context is
49709// canceled.
49710func (c *ProjectsLocationsKnowledgeBasesListCall) Context(ctx context.Context) *ProjectsLocationsKnowledgeBasesListCall {
49711	c.ctx_ = ctx
49712	return c
49713}
49714
49715// Header returns an http.Header that can be modified by the caller to
49716// add HTTP headers to the request.
49717func (c *ProjectsLocationsKnowledgeBasesListCall) Header() http.Header {
49718	if c.header_ == nil {
49719		c.header_ = make(http.Header)
49720	}
49721	return c.header_
49722}
49723
49724func (c *ProjectsLocationsKnowledgeBasesListCall) doRequest(alt string) (*http.Response, error) {
49725	reqHeaders := make(http.Header)
49726	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20211027")
49727	for k, v := range c.header_ {
49728		reqHeaders[k] = v
49729	}
49730	reqHeaders.Set("User-Agent", c.s.userAgent())
49731	if c.ifNoneMatch_ != "" {
49732		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
49733	}
49734	var body io.Reader = nil
49735	c.urlParams_.Set("alt", alt)
49736	c.urlParams_.Set("prettyPrint", "false")
49737	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+parent}/knowledgeBases")
49738	urls += "?" + c.urlParams_.Encode()
49739	req, err := http.NewRequest("GET", urls, body)
49740	if err != nil {
49741		return nil, err
49742	}
49743	req.Header = reqHeaders
49744	googleapi.Expand(req.URL, map[string]string{
49745		"parent": c.parent,
49746	})
49747	return gensupport.SendRequest(c.ctx_, c.s.client, req)
49748}
49749
49750// Do executes the "dialogflow.projects.locations.knowledgeBases.list" call.
49751// Exactly one of *GoogleCloudDialogflowV2ListKnowledgeBasesResponse or
49752// error will be non-nil. Any non-2xx status code is an error. Response
49753// headers are in either
49754// *GoogleCloudDialogflowV2ListKnowledgeBasesResponse.ServerResponse.Head
49755// er or (if a response was returned at all) in
49756// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
49757// whether the returned error was because http.StatusNotModified was
49758// returned.
49759func (c *ProjectsLocationsKnowledgeBasesListCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDialogflowV2ListKnowledgeBasesResponse, error) {
49760	gensupport.SetOptions(c.urlParams_, opts...)
49761	res, err := c.doRequest("json")
49762	if res != nil && res.StatusCode == http.StatusNotModified {
49763		if res.Body != nil {
49764			res.Body.Close()
49765		}
49766		return nil, &googleapi.Error{
49767			Code:   res.StatusCode,
49768			Header: res.Header,
49769		}
49770	}
49771	if err != nil {
49772		return nil, err
49773	}
49774	defer googleapi.CloseBody(res)
49775	if err := googleapi.CheckResponse(res); err != nil {
49776		return nil, err
49777	}
49778	ret := &GoogleCloudDialogflowV2ListKnowledgeBasesResponse{
49779		ServerResponse: googleapi.ServerResponse{
49780			Header:         res.Header,
49781			HTTPStatusCode: res.StatusCode,
49782		},
49783	}
49784	target := &ret
49785	if err := gensupport.DecodeResponse(target, res); err != nil {
49786		return nil, err
49787	}
49788	return ret, nil
49789	// {
49790	//   "description": "Returns the list of all knowledge bases of the specified agent.",
49791	//   "flatPath": "v2/projects/{projectsId}/locations/{locationsId}/knowledgeBases",
49792	//   "httpMethod": "GET",
49793	//   "id": "dialogflow.projects.locations.knowledgeBases.list",
49794	//   "parameterOrder": [
49795	//     "parent"
49796	//   ],
49797	//   "parameters": {
49798	//     "pageSize": {
49799	//       "description": "The maximum number of items to return in a single page. By default 10 and at most 100.",
49800	//       "format": "int32",
49801	//       "location": "query",
49802	//       "type": "integer"
49803	//     },
49804	//     "pageToken": {
49805	//       "description": "The next_page_token value returned from a previous list request.",
49806	//       "location": "query",
49807	//       "type": "string"
49808	//     },
49809	//     "parent": {
49810	//       "description": "Required. The project to list of knowledge bases for. Format: `projects//locations/`.",
49811	//       "location": "path",
49812	//       "pattern": "^projects/[^/]+/locations/[^/]+$",
49813	//       "required": true,
49814	//       "type": "string"
49815	//     }
49816	//   },
49817	//   "path": "v2/{+parent}/knowledgeBases",
49818	//   "response": {
49819	//     "$ref": "GoogleCloudDialogflowV2ListKnowledgeBasesResponse"
49820	//   },
49821	//   "scopes": [
49822	//     "https://www.googleapis.com/auth/cloud-platform",
49823	//     "https://www.googleapis.com/auth/dialogflow"
49824	//   ]
49825	// }
49826
49827}
49828
49829// Pages invokes f for each page of results.
49830// A non-nil error returned from f will halt the iteration.
49831// The provided context supersedes any context provided to the Context method.
49832func (c *ProjectsLocationsKnowledgeBasesListCall) Pages(ctx context.Context, f func(*GoogleCloudDialogflowV2ListKnowledgeBasesResponse) error) error {
49833	c.ctx_ = ctx
49834	defer c.PageToken(c.urlParams_.Get("pageToken")) // reset paging to original point
49835	for {
49836		x, err := c.Do()
49837		if err != nil {
49838			return err
49839		}
49840		if err := f(x); err != nil {
49841			return err
49842		}
49843		if x.NextPageToken == "" {
49844			return nil
49845		}
49846		c.PageToken(x.NextPageToken)
49847	}
49848}
49849
49850// method id "dialogflow.projects.locations.knowledgeBases.patch":
49851
49852type ProjectsLocationsKnowledgeBasesPatchCall struct {
49853	s                                    *Service
49854	name                                 string
49855	googleclouddialogflowv2knowledgebase *GoogleCloudDialogflowV2KnowledgeBase
49856	urlParams_                           gensupport.URLParams
49857	ctx_                                 context.Context
49858	header_                              http.Header
49859}
49860
49861// Patch: Updates the specified knowledge base.
49862//
49863// - name: The knowledge base resource name. The name must be empty when
49864//   creating a knowledge base. Format:
49865//   `projects//locations//knowledgeBases/`.
49866func (r *ProjectsLocationsKnowledgeBasesService) Patch(name string, googleclouddialogflowv2knowledgebase *GoogleCloudDialogflowV2KnowledgeBase) *ProjectsLocationsKnowledgeBasesPatchCall {
49867	c := &ProjectsLocationsKnowledgeBasesPatchCall{s: r.s, urlParams_: make(gensupport.URLParams)}
49868	c.name = name
49869	c.googleclouddialogflowv2knowledgebase = googleclouddialogflowv2knowledgebase
49870	return c
49871}
49872
49873// UpdateMask sets the optional parameter "updateMask": Not specified
49874// means `update all`. Currently, only `display_name` can be updated, an
49875// InvalidArgument will be returned for attempting to update other
49876// fields.
49877func (c *ProjectsLocationsKnowledgeBasesPatchCall) UpdateMask(updateMask string) *ProjectsLocationsKnowledgeBasesPatchCall {
49878	c.urlParams_.Set("updateMask", updateMask)
49879	return c
49880}
49881
49882// Fields allows partial responses to be retrieved. See
49883// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
49884// for more information.
49885func (c *ProjectsLocationsKnowledgeBasesPatchCall) Fields(s ...googleapi.Field) *ProjectsLocationsKnowledgeBasesPatchCall {
49886	c.urlParams_.Set("fields", googleapi.CombineFields(s))
49887	return c
49888}
49889
49890// Context sets the context to be used in this call's Do method. Any
49891// pending HTTP request will be aborted if the provided context is
49892// canceled.
49893func (c *ProjectsLocationsKnowledgeBasesPatchCall) Context(ctx context.Context) *ProjectsLocationsKnowledgeBasesPatchCall {
49894	c.ctx_ = ctx
49895	return c
49896}
49897
49898// Header returns an http.Header that can be modified by the caller to
49899// add HTTP headers to the request.
49900func (c *ProjectsLocationsKnowledgeBasesPatchCall) Header() http.Header {
49901	if c.header_ == nil {
49902		c.header_ = make(http.Header)
49903	}
49904	return c.header_
49905}
49906
49907func (c *ProjectsLocationsKnowledgeBasesPatchCall) doRequest(alt string) (*http.Response, error) {
49908	reqHeaders := make(http.Header)
49909	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20211027")
49910	for k, v := range c.header_ {
49911		reqHeaders[k] = v
49912	}
49913	reqHeaders.Set("User-Agent", c.s.userAgent())
49914	var body io.Reader = nil
49915	body, err := googleapi.WithoutDataWrapper.JSONReader(c.googleclouddialogflowv2knowledgebase)
49916	if err != nil {
49917		return nil, err
49918	}
49919	reqHeaders.Set("Content-Type", "application/json")
49920	c.urlParams_.Set("alt", alt)
49921	c.urlParams_.Set("prettyPrint", "false")
49922	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+name}")
49923	urls += "?" + c.urlParams_.Encode()
49924	req, err := http.NewRequest("PATCH", urls, body)
49925	if err != nil {
49926		return nil, err
49927	}
49928	req.Header = reqHeaders
49929	googleapi.Expand(req.URL, map[string]string{
49930		"name": c.name,
49931	})
49932	return gensupport.SendRequest(c.ctx_, c.s.client, req)
49933}
49934
49935// Do executes the "dialogflow.projects.locations.knowledgeBases.patch" call.
49936// Exactly one of *GoogleCloudDialogflowV2KnowledgeBase or error will be
49937// non-nil. Any non-2xx status code is an error. Response headers are in
49938// either *GoogleCloudDialogflowV2KnowledgeBase.ServerResponse.Header or
49939// (if a response was returned at all) in
49940// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
49941// whether the returned error was because http.StatusNotModified was
49942// returned.
49943func (c *ProjectsLocationsKnowledgeBasesPatchCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDialogflowV2KnowledgeBase, error) {
49944	gensupport.SetOptions(c.urlParams_, opts...)
49945	res, err := c.doRequest("json")
49946	if res != nil && res.StatusCode == http.StatusNotModified {
49947		if res.Body != nil {
49948			res.Body.Close()
49949		}
49950		return nil, &googleapi.Error{
49951			Code:   res.StatusCode,
49952			Header: res.Header,
49953		}
49954	}
49955	if err != nil {
49956		return nil, err
49957	}
49958	defer googleapi.CloseBody(res)
49959	if err := googleapi.CheckResponse(res); err != nil {
49960		return nil, err
49961	}
49962	ret := &GoogleCloudDialogflowV2KnowledgeBase{
49963		ServerResponse: googleapi.ServerResponse{
49964			Header:         res.Header,
49965			HTTPStatusCode: res.StatusCode,
49966		},
49967	}
49968	target := &ret
49969	if err := gensupport.DecodeResponse(target, res); err != nil {
49970		return nil, err
49971	}
49972	return ret, nil
49973	// {
49974	//   "description": "Updates the specified knowledge base.",
49975	//   "flatPath": "v2/projects/{projectsId}/locations/{locationsId}/knowledgeBases/{knowledgeBasesId}",
49976	//   "httpMethod": "PATCH",
49977	//   "id": "dialogflow.projects.locations.knowledgeBases.patch",
49978	//   "parameterOrder": [
49979	//     "name"
49980	//   ],
49981	//   "parameters": {
49982	//     "name": {
49983	//       "description": "The knowledge base resource name. The name must be empty when creating a knowledge base. Format: `projects//locations//knowledgeBases/`.",
49984	//       "location": "path",
49985	//       "pattern": "^projects/[^/]+/locations/[^/]+/knowledgeBases/[^/]+$",
49986	//       "required": true,
49987	//       "type": "string"
49988	//     },
49989	//     "updateMask": {
49990	//       "description": "Optional. Not specified means `update all`. Currently, only `display_name` can be updated, an InvalidArgument will be returned for attempting to update other fields.",
49991	//       "format": "google-fieldmask",
49992	//       "location": "query",
49993	//       "type": "string"
49994	//     }
49995	//   },
49996	//   "path": "v2/{+name}",
49997	//   "request": {
49998	//     "$ref": "GoogleCloudDialogflowV2KnowledgeBase"
49999	//   },
50000	//   "response": {
50001	//     "$ref": "GoogleCloudDialogflowV2KnowledgeBase"
50002	//   },
50003	//   "scopes": [
50004	//     "https://www.googleapis.com/auth/cloud-platform",
50005	//     "https://www.googleapis.com/auth/dialogflow"
50006	//   ]
50007	// }
50008
50009}
50010
50011// method id "dialogflow.projects.locations.knowledgeBases.documents.create":
50012
50013type ProjectsLocationsKnowledgeBasesDocumentsCreateCall struct {
50014	s                               *Service
50015	parent                          string
50016	googleclouddialogflowv2document *GoogleCloudDialogflowV2Document
50017	urlParams_                      gensupport.URLParams
50018	ctx_                            context.Context
50019	header_                         http.Header
50020}
50021
50022// Create: Creates a new document. This method is a long-running
50023// operation
50024// (https://cloud.google.com/dialogflow/cx/docs/how/long-running-operation).
50025// The returned `Operation` type has the following method-specific
50026// fields: - `metadata`: KnowledgeOperationMetadata - `response`:
50027// Document
50028//
50029// - parent: The knowledge base to create a document for. Format:
50030//   `projects//locations//knowledgeBases/`.
50031func (r *ProjectsLocationsKnowledgeBasesDocumentsService) Create(parent string, googleclouddialogflowv2document *GoogleCloudDialogflowV2Document) *ProjectsLocationsKnowledgeBasesDocumentsCreateCall {
50032	c := &ProjectsLocationsKnowledgeBasesDocumentsCreateCall{s: r.s, urlParams_: make(gensupport.URLParams)}
50033	c.parent = parent
50034	c.googleclouddialogflowv2document = googleclouddialogflowv2document
50035	return c
50036}
50037
50038// Fields allows partial responses to be retrieved. See
50039// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
50040// for more information.
50041func (c *ProjectsLocationsKnowledgeBasesDocumentsCreateCall) Fields(s ...googleapi.Field) *ProjectsLocationsKnowledgeBasesDocumentsCreateCall {
50042	c.urlParams_.Set("fields", googleapi.CombineFields(s))
50043	return c
50044}
50045
50046// Context sets the context to be used in this call's Do method. Any
50047// pending HTTP request will be aborted if the provided context is
50048// canceled.
50049func (c *ProjectsLocationsKnowledgeBasesDocumentsCreateCall) Context(ctx context.Context) *ProjectsLocationsKnowledgeBasesDocumentsCreateCall {
50050	c.ctx_ = ctx
50051	return c
50052}
50053
50054// Header returns an http.Header that can be modified by the caller to
50055// add HTTP headers to the request.
50056func (c *ProjectsLocationsKnowledgeBasesDocumentsCreateCall) Header() http.Header {
50057	if c.header_ == nil {
50058		c.header_ = make(http.Header)
50059	}
50060	return c.header_
50061}
50062
50063func (c *ProjectsLocationsKnowledgeBasesDocumentsCreateCall) doRequest(alt string) (*http.Response, error) {
50064	reqHeaders := make(http.Header)
50065	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20211027")
50066	for k, v := range c.header_ {
50067		reqHeaders[k] = v
50068	}
50069	reqHeaders.Set("User-Agent", c.s.userAgent())
50070	var body io.Reader = nil
50071	body, err := googleapi.WithoutDataWrapper.JSONReader(c.googleclouddialogflowv2document)
50072	if err != nil {
50073		return nil, err
50074	}
50075	reqHeaders.Set("Content-Type", "application/json")
50076	c.urlParams_.Set("alt", alt)
50077	c.urlParams_.Set("prettyPrint", "false")
50078	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+parent}/documents")
50079	urls += "?" + c.urlParams_.Encode()
50080	req, err := http.NewRequest("POST", urls, body)
50081	if err != nil {
50082		return nil, err
50083	}
50084	req.Header = reqHeaders
50085	googleapi.Expand(req.URL, map[string]string{
50086		"parent": c.parent,
50087	})
50088	return gensupport.SendRequest(c.ctx_, c.s.client, req)
50089}
50090
50091// Do executes the "dialogflow.projects.locations.knowledgeBases.documents.create" call.
50092// Exactly one of *GoogleLongrunningOperation or error will be non-nil.
50093// Any non-2xx status code is an error. Response headers are in either
50094// *GoogleLongrunningOperation.ServerResponse.Header or (if a response
50095// was returned at all) in error.(*googleapi.Error).Header. Use
50096// googleapi.IsNotModified to check whether the returned error was
50097// because http.StatusNotModified was returned.
50098func (c *ProjectsLocationsKnowledgeBasesDocumentsCreateCall) Do(opts ...googleapi.CallOption) (*GoogleLongrunningOperation, error) {
50099	gensupport.SetOptions(c.urlParams_, opts...)
50100	res, err := c.doRequest("json")
50101	if res != nil && res.StatusCode == http.StatusNotModified {
50102		if res.Body != nil {
50103			res.Body.Close()
50104		}
50105		return nil, &googleapi.Error{
50106			Code:   res.StatusCode,
50107			Header: res.Header,
50108		}
50109	}
50110	if err != nil {
50111		return nil, err
50112	}
50113	defer googleapi.CloseBody(res)
50114	if err := googleapi.CheckResponse(res); err != nil {
50115		return nil, err
50116	}
50117	ret := &GoogleLongrunningOperation{
50118		ServerResponse: googleapi.ServerResponse{
50119			Header:         res.Header,
50120			HTTPStatusCode: res.StatusCode,
50121		},
50122	}
50123	target := &ret
50124	if err := gensupport.DecodeResponse(target, res); err != nil {
50125		return nil, err
50126	}
50127	return ret, nil
50128	// {
50129	//   "description": "Creates a new document. This method is a [long-running operation](https://cloud.google.com/dialogflow/cx/docs/how/long-running-operation). The returned `Operation` type has the following method-specific fields: - `metadata`: KnowledgeOperationMetadata - `response`: Document",
50130	//   "flatPath": "v2/projects/{projectsId}/locations/{locationsId}/knowledgeBases/{knowledgeBasesId}/documents",
50131	//   "httpMethod": "POST",
50132	//   "id": "dialogflow.projects.locations.knowledgeBases.documents.create",
50133	//   "parameterOrder": [
50134	//     "parent"
50135	//   ],
50136	//   "parameters": {
50137	//     "parent": {
50138	//       "description": "Required. The knowledge base to create a document for. Format: `projects//locations//knowledgeBases/`.",
50139	//       "location": "path",
50140	//       "pattern": "^projects/[^/]+/locations/[^/]+/knowledgeBases/[^/]+$",
50141	//       "required": true,
50142	//       "type": "string"
50143	//     }
50144	//   },
50145	//   "path": "v2/{+parent}/documents",
50146	//   "request": {
50147	//     "$ref": "GoogleCloudDialogflowV2Document"
50148	//   },
50149	//   "response": {
50150	//     "$ref": "GoogleLongrunningOperation"
50151	//   },
50152	//   "scopes": [
50153	//     "https://www.googleapis.com/auth/cloud-platform",
50154	//     "https://www.googleapis.com/auth/dialogflow"
50155	//   ]
50156	// }
50157
50158}
50159
50160// method id "dialogflow.projects.locations.knowledgeBases.documents.delete":
50161
50162type ProjectsLocationsKnowledgeBasesDocumentsDeleteCall struct {
50163	s          *Service
50164	name       string
50165	urlParams_ gensupport.URLParams
50166	ctx_       context.Context
50167	header_    http.Header
50168}
50169
50170// Delete: Deletes the specified document. This method is a long-running
50171// operation
50172// (https://cloud.google.com/dialogflow/cx/docs/how/long-running-operation).
50173// The returned `Operation` type has the following method-specific
50174// fields: - `metadata`: KnowledgeOperationMetadata - `response`: An
50175// Empty message
50176// (https://developers.google.com/protocol-buffers/docs/reference/google.protobuf#empty)
50177//
50178// - name: The name of the document to delete. Format:
50179//   `projects//locations//knowledgeBases//documents/`.
50180func (r *ProjectsLocationsKnowledgeBasesDocumentsService) Delete(name string) *ProjectsLocationsKnowledgeBasesDocumentsDeleteCall {
50181	c := &ProjectsLocationsKnowledgeBasesDocumentsDeleteCall{s: r.s, urlParams_: make(gensupport.URLParams)}
50182	c.name = name
50183	return c
50184}
50185
50186// Fields allows partial responses to be retrieved. See
50187// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
50188// for more information.
50189func (c *ProjectsLocationsKnowledgeBasesDocumentsDeleteCall) Fields(s ...googleapi.Field) *ProjectsLocationsKnowledgeBasesDocumentsDeleteCall {
50190	c.urlParams_.Set("fields", googleapi.CombineFields(s))
50191	return c
50192}
50193
50194// Context sets the context to be used in this call's Do method. Any
50195// pending HTTP request will be aborted if the provided context is
50196// canceled.
50197func (c *ProjectsLocationsKnowledgeBasesDocumentsDeleteCall) Context(ctx context.Context) *ProjectsLocationsKnowledgeBasesDocumentsDeleteCall {
50198	c.ctx_ = ctx
50199	return c
50200}
50201
50202// Header returns an http.Header that can be modified by the caller to
50203// add HTTP headers to the request.
50204func (c *ProjectsLocationsKnowledgeBasesDocumentsDeleteCall) Header() http.Header {
50205	if c.header_ == nil {
50206		c.header_ = make(http.Header)
50207	}
50208	return c.header_
50209}
50210
50211func (c *ProjectsLocationsKnowledgeBasesDocumentsDeleteCall) doRequest(alt string) (*http.Response, error) {
50212	reqHeaders := make(http.Header)
50213	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20211027")
50214	for k, v := range c.header_ {
50215		reqHeaders[k] = v
50216	}
50217	reqHeaders.Set("User-Agent", c.s.userAgent())
50218	var body io.Reader = nil
50219	c.urlParams_.Set("alt", alt)
50220	c.urlParams_.Set("prettyPrint", "false")
50221	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+name}")
50222	urls += "?" + c.urlParams_.Encode()
50223	req, err := http.NewRequest("DELETE", urls, body)
50224	if err != nil {
50225		return nil, err
50226	}
50227	req.Header = reqHeaders
50228	googleapi.Expand(req.URL, map[string]string{
50229		"name": c.name,
50230	})
50231	return gensupport.SendRequest(c.ctx_, c.s.client, req)
50232}
50233
50234// Do executes the "dialogflow.projects.locations.knowledgeBases.documents.delete" call.
50235// Exactly one of *GoogleLongrunningOperation or error will be non-nil.
50236// Any non-2xx status code is an error. Response headers are in either
50237// *GoogleLongrunningOperation.ServerResponse.Header or (if a response
50238// was returned at all) in error.(*googleapi.Error).Header. Use
50239// googleapi.IsNotModified to check whether the returned error was
50240// because http.StatusNotModified was returned.
50241func (c *ProjectsLocationsKnowledgeBasesDocumentsDeleteCall) Do(opts ...googleapi.CallOption) (*GoogleLongrunningOperation, error) {
50242	gensupport.SetOptions(c.urlParams_, opts...)
50243	res, err := c.doRequest("json")
50244	if res != nil && res.StatusCode == http.StatusNotModified {
50245		if res.Body != nil {
50246			res.Body.Close()
50247		}
50248		return nil, &googleapi.Error{
50249			Code:   res.StatusCode,
50250			Header: res.Header,
50251		}
50252	}
50253	if err != nil {
50254		return nil, err
50255	}
50256	defer googleapi.CloseBody(res)
50257	if err := googleapi.CheckResponse(res); err != nil {
50258		return nil, err
50259	}
50260	ret := &GoogleLongrunningOperation{
50261		ServerResponse: googleapi.ServerResponse{
50262			Header:         res.Header,
50263			HTTPStatusCode: res.StatusCode,
50264		},
50265	}
50266	target := &ret
50267	if err := gensupport.DecodeResponse(target, res); err != nil {
50268		return nil, err
50269	}
50270	return ret, nil
50271	// {
50272	//   "description": "Deletes the specified document. This method is a [long-running operation](https://cloud.google.com/dialogflow/cx/docs/how/long-running-operation). The returned `Operation` type has the following method-specific fields: - `metadata`: KnowledgeOperationMetadata - `response`: An [Empty message](https://developers.google.com/protocol-buffers/docs/reference/google.protobuf#empty)",
50273	//   "flatPath": "v2/projects/{projectsId}/locations/{locationsId}/knowledgeBases/{knowledgeBasesId}/documents/{documentsId}",
50274	//   "httpMethod": "DELETE",
50275	//   "id": "dialogflow.projects.locations.knowledgeBases.documents.delete",
50276	//   "parameterOrder": [
50277	//     "name"
50278	//   ],
50279	//   "parameters": {
50280	//     "name": {
50281	//       "description": "Required. The name of the document to delete. Format: `projects//locations//knowledgeBases//documents/`.",
50282	//       "location": "path",
50283	//       "pattern": "^projects/[^/]+/locations/[^/]+/knowledgeBases/[^/]+/documents/[^/]+$",
50284	//       "required": true,
50285	//       "type": "string"
50286	//     }
50287	//   },
50288	//   "path": "v2/{+name}",
50289	//   "response": {
50290	//     "$ref": "GoogleLongrunningOperation"
50291	//   },
50292	//   "scopes": [
50293	//     "https://www.googleapis.com/auth/cloud-platform",
50294	//     "https://www.googleapis.com/auth/dialogflow"
50295	//   ]
50296	// }
50297
50298}
50299
50300// method id "dialogflow.projects.locations.knowledgeBases.documents.get":
50301
50302type ProjectsLocationsKnowledgeBasesDocumentsGetCall struct {
50303	s            *Service
50304	name         string
50305	urlParams_   gensupport.URLParams
50306	ifNoneMatch_ string
50307	ctx_         context.Context
50308	header_      http.Header
50309}
50310
50311// Get: Retrieves the specified document.
50312//
50313// - name: The name of the document to retrieve. Format
50314//   `projects//locations//knowledgeBases//documents/`.
50315func (r *ProjectsLocationsKnowledgeBasesDocumentsService) Get(name string) *ProjectsLocationsKnowledgeBasesDocumentsGetCall {
50316	c := &ProjectsLocationsKnowledgeBasesDocumentsGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
50317	c.name = name
50318	return c
50319}
50320
50321// Fields allows partial responses to be retrieved. See
50322// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
50323// for more information.
50324func (c *ProjectsLocationsKnowledgeBasesDocumentsGetCall) Fields(s ...googleapi.Field) *ProjectsLocationsKnowledgeBasesDocumentsGetCall {
50325	c.urlParams_.Set("fields", googleapi.CombineFields(s))
50326	return c
50327}
50328
50329// IfNoneMatch sets the optional parameter which makes the operation
50330// fail if the object's ETag matches the given value. This is useful for
50331// getting updates only after the object has changed since the last
50332// request. Use googleapi.IsNotModified to check whether the response
50333// error from Do is the result of In-None-Match.
50334func (c *ProjectsLocationsKnowledgeBasesDocumentsGetCall) IfNoneMatch(entityTag string) *ProjectsLocationsKnowledgeBasesDocumentsGetCall {
50335	c.ifNoneMatch_ = entityTag
50336	return c
50337}
50338
50339// Context sets the context to be used in this call's Do method. Any
50340// pending HTTP request will be aborted if the provided context is
50341// canceled.
50342func (c *ProjectsLocationsKnowledgeBasesDocumentsGetCall) Context(ctx context.Context) *ProjectsLocationsKnowledgeBasesDocumentsGetCall {
50343	c.ctx_ = ctx
50344	return c
50345}
50346
50347// Header returns an http.Header that can be modified by the caller to
50348// add HTTP headers to the request.
50349func (c *ProjectsLocationsKnowledgeBasesDocumentsGetCall) Header() http.Header {
50350	if c.header_ == nil {
50351		c.header_ = make(http.Header)
50352	}
50353	return c.header_
50354}
50355
50356func (c *ProjectsLocationsKnowledgeBasesDocumentsGetCall) doRequest(alt string) (*http.Response, error) {
50357	reqHeaders := make(http.Header)
50358	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20211027")
50359	for k, v := range c.header_ {
50360		reqHeaders[k] = v
50361	}
50362	reqHeaders.Set("User-Agent", c.s.userAgent())
50363	if c.ifNoneMatch_ != "" {
50364		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
50365	}
50366	var body io.Reader = nil
50367	c.urlParams_.Set("alt", alt)
50368	c.urlParams_.Set("prettyPrint", "false")
50369	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+name}")
50370	urls += "?" + c.urlParams_.Encode()
50371	req, err := http.NewRequest("GET", urls, body)
50372	if err != nil {
50373		return nil, err
50374	}
50375	req.Header = reqHeaders
50376	googleapi.Expand(req.URL, map[string]string{
50377		"name": c.name,
50378	})
50379	return gensupport.SendRequest(c.ctx_, c.s.client, req)
50380}
50381
50382// Do executes the "dialogflow.projects.locations.knowledgeBases.documents.get" call.
50383// Exactly one of *GoogleCloudDialogflowV2Document or error will be
50384// non-nil. Any non-2xx status code is an error. Response headers are in
50385// either *GoogleCloudDialogflowV2Document.ServerResponse.Header or (if
50386// a response was returned at all) in error.(*googleapi.Error).Header.
50387// Use googleapi.IsNotModified to check whether the returned error was
50388// because http.StatusNotModified was returned.
50389func (c *ProjectsLocationsKnowledgeBasesDocumentsGetCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDialogflowV2Document, error) {
50390	gensupport.SetOptions(c.urlParams_, opts...)
50391	res, err := c.doRequest("json")
50392	if res != nil && res.StatusCode == http.StatusNotModified {
50393		if res.Body != nil {
50394			res.Body.Close()
50395		}
50396		return nil, &googleapi.Error{
50397			Code:   res.StatusCode,
50398			Header: res.Header,
50399		}
50400	}
50401	if err != nil {
50402		return nil, err
50403	}
50404	defer googleapi.CloseBody(res)
50405	if err := googleapi.CheckResponse(res); err != nil {
50406		return nil, err
50407	}
50408	ret := &GoogleCloudDialogflowV2Document{
50409		ServerResponse: googleapi.ServerResponse{
50410			Header:         res.Header,
50411			HTTPStatusCode: res.StatusCode,
50412		},
50413	}
50414	target := &ret
50415	if err := gensupport.DecodeResponse(target, res); err != nil {
50416		return nil, err
50417	}
50418	return ret, nil
50419	// {
50420	//   "description": "Retrieves the specified document.",
50421	//   "flatPath": "v2/projects/{projectsId}/locations/{locationsId}/knowledgeBases/{knowledgeBasesId}/documents/{documentsId}",
50422	//   "httpMethod": "GET",
50423	//   "id": "dialogflow.projects.locations.knowledgeBases.documents.get",
50424	//   "parameterOrder": [
50425	//     "name"
50426	//   ],
50427	//   "parameters": {
50428	//     "name": {
50429	//       "description": "Required. The name of the document to retrieve. Format `projects//locations//knowledgeBases//documents/`.",
50430	//       "location": "path",
50431	//       "pattern": "^projects/[^/]+/locations/[^/]+/knowledgeBases/[^/]+/documents/[^/]+$",
50432	//       "required": true,
50433	//       "type": "string"
50434	//     }
50435	//   },
50436	//   "path": "v2/{+name}",
50437	//   "response": {
50438	//     "$ref": "GoogleCloudDialogflowV2Document"
50439	//   },
50440	//   "scopes": [
50441	//     "https://www.googleapis.com/auth/cloud-platform",
50442	//     "https://www.googleapis.com/auth/dialogflow"
50443	//   ]
50444	// }
50445
50446}
50447
50448// method id "dialogflow.projects.locations.knowledgeBases.documents.list":
50449
50450type ProjectsLocationsKnowledgeBasesDocumentsListCall struct {
50451	s            *Service
50452	parent       string
50453	urlParams_   gensupport.URLParams
50454	ifNoneMatch_ string
50455	ctx_         context.Context
50456	header_      http.Header
50457}
50458
50459// List: Returns the list of all documents of the knowledge base.
50460//
50461// - parent: The knowledge base to list all documents for. Format:
50462//   `projects//locations//knowledgeBases/`.
50463func (r *ProjectsLocationsKnowledgeBasesDocumentsService) List(parent string) *ProjectsLocationsKnowledgeBasesDocumentsListCall {
50464	c := &ProjectsLocationsKnowledgeBasesDocumentsListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
50465	c.parent = parent
50466	return c
50467}
50468
50469// PageSize sets the optional parameter "pageSize": The maximum number
50470// of items to return in a single page. By default 10 and at most 100.
50471func (c *ProjectsLocationsKnowledgeBasesDocumentsListCall) PageSize(pageSize int64) *ProjectsLocationsKnowledgeBasesDocumentsListCall {
50472	c.urlParams_.Set("pageSize", fmt.Sprint(pageSize))
50473	return c
50474}
50475
50476// PageToken sets the optional parameter "pageToken": The
50477// next_page_token value returned from a previous list request.
50478func (c *ProjectsLocationsKnowledgeBasesDocumentsListCall) PageToken(pageToken string) *ProjectsLocationsKnowledgeBasesDocumentsListCall {
50479	c.urlParams_.Set("pageToken", pageToken)
50480	return c
50481}
50482
50483// Fields allows partial responses to be retrieved. See
50484// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
50485// for more information.
50486func (c *ProjectsLocationsKnowledgeBasesDocumentsListCall) Fields(s ...googleapi.Field) *ProjectsLocationsKnowledgeBasesDocumentsListCall {
50487	c.urlParams_.Set("fields", googleapi.CombineFields(s))
50488	return c
50489}
50490
50491// IfNoneMatch sets the optional parameter which makes the operation
50492// fail if the object's ETag matches the given value. This is useful for
50493// getting updates only after the object has changed since the last
50494// request. Use googleapi.IsNotModified to check whether the response
50495// error from Do is the result of In-None-Match.
50496func (c *ProjectsLocationsKnowledgeBasesDocumentsListCall) IfNoneMatch(entityTag string) *ProjectsLocationsKnowledgeBasesDocumentsListCall {
50497	c.ifNoneMatch_ = entityTag
50498	return c
50499}
50500
50501// Context sets the context to be used in this call's Do method. Any
50502// pending HTTP request will be aborted if the provided context is
50503// canceled.
50504func (c *ProjectsLocationsKnowledgeBasesDocumentsListCall) Context(ctx context.Context) *ProjectsLocationsKnowledgeBasesDocumentsListCall {
50505	c.ctx_ = ctx
50506	return c
50507}
50508
50509// Header returns an http.Header that can be modified by the caller to
50510// add HTTP headers to the request.
50511func (c *ProjectsLocationsKnowledgeBasesDocumentsListCall) Header() http.Header {
50512	if c.header_ == nil {
50513		c.header_ = make(http.Header)
50514	}
50515	return c.header_
50516}
50517
50518func (c *ProjectsLocationsKnowledgeBasesDocumentsListCall) doRequest(alt string) (*http.Response, error) {
50519	reqHeaders := make(http.Header)
50520	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20211027")
50521	for k, v := range c.header_ {
50522		reqHeaders[k] = v
50523	}
50524	reqHeaders.Set("User-Agent", c.s.userAgent())
50525	if c.ifNoneMatch_ != "" {
50526		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
50527	}
50528	var body io.Reader = nil
50529	c.urlParams_.Set("alt", alt)
50530	c.urlParams_.Set("prettyPrint", "false")
50531	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+parent}/documents")
50532	urls += "?" + c.urlParams_.Encode()
50533	req, err := http.NewRequest("GET", urls, body)
50534	if err != nil {
50535		return nil, err
50536	}
50537	req.Header = reqHeaders
50538	googleapi.Expand(req.URL, map[string]string{
50539		"parent": c.parent,
50540	})
50541	return gensupport.SendRequest(c.ctx_, c.s.client, req)
50542}
50543
50544// Do executes the "dialogflow.projects.locations.knowledgeBases.documents.list" call.
50545// Exactly one of *GoogleCloudDialogflowV2ListDocumentsResponse or error
50546// will be non-nil. Any non-2xx status code is an error. Response
50547// headers are in either
50548// *GoogleCloudDialogflowV2ListDocumentsResponse.ServerResponse.Header
50549// or (if a response was returned at all) in
50550// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
50551// whether the returned error was because http.StatusNotModified was
50552// returned.
50553func (c *ProjectsLocationsKnowledgeBasesDocumentsListCall) Do(opts ...googleapi.CallOption) (*GoogleCloudDialogflowV2ListDocumentsResponse, error) {
50554	gensupport.SetOptions(c.urlParams_, opts...)
50555	res, err := c.doRequest("json")
50556	if res != nil && res.StatusCode == http.StatusNotModified {
50557		if res.Body != nil {
50558			res.Body.Close()
50559		}
50560		return nil, &googleapi.Error{
50561			Code:   res.StatusCode,
50562			Header: res.Header,
50563		}
50564	}
50565	if err != nil {
50566		return nil, err
50567	}
50568	defer googleapi.CloseBody(res)
50569	if err := googleapi.CheckResponse(res); err != nil {
50570		return nil, err
50571	}
50572	ret := &GoogleCloudDialogflowV2ListDocumentsResponse{
50573		ServerResponse: googleapi.ServerResponse{
50574			Header:         res.Header,
50575			HTTPStatusCode: res.StatusCode,
50576		},
50577	}
50578	target := &ret
50579	if err := gensupport.DecodeResponse(target, res); err != nil {
50580		return nil, err
50581	}
50582	return ret, nil
50583	// {
50584	//   "description": "Returns the list of all documents of the knowledge base.",
50585	//   "flatPath": "v2/projects/{projectsId}/locations/{locationsId}/knowledgeBases/{knowledgeBasesId}/documents",
50586	//   "httpMethod": "GET",
50587	//   "id": "dialogflow.projects.locations.knowledgeBases.documents.list",
50588	//   "parameterOrder": [
50589	//     "parent"
50590	//   ],
50591	//   "parameters": {
50592	//     "pageSize": {
50593	//       "description": "The maximum number of items to return in a single page. By default 10 and at most 100.",
50594	//       "format": "int32",
50595	//       "location": "query",
50596	//       "type": "integer"
50597	//     },
50598	//     "pageToken": {
50599	//       "description": "The next_page_token value returned from a previous list request.",
50600	//       "location": "query",
50601	//       "type": "string"
50602	//     },
50603	//     "parent": {
50604	//       "description": "Required. The knowledge base to list all documents for. Format: `projects//locations//knowledgeBases/`.",
50605	//       "location": "path",
50606	//       "pattern": "^projects/[^/]+/locations/[^/]+/knowledgeBases/[^/]+$",
50607	//       "required": true,
50608	//       "type": "string"
50609	//     }
50610	//   },
50611	//   "path": "v2/{+parent}/documents",
50612	//   "response": {
50613	//     "$ref": "GoogleCloudDialogflowV2ListDocumentsResponse"
50614	//   },
50615	//   "scopes": [
50616	//     "https://www.googleapis.com/auth/cloud-platform",
50617	//     "https://www.googleapis.com/auth/dialogflow"
50618	//   ]
50619	// }
50620
50621}
50622
50623// Pages invokes f for each page of results.
50624// A non-nil error returned from f will halt the iteration.
50625// The provided context supersedes any context provided to the Context method.
50626func (c *ProjectsLocationsKnowledgeBasesDocumentsListCall) Pages(ctx context.Context, f func(*GoogleCloudDialogflowV2ListDocumentsResponse) error) error {
50627	c.ctx_ = ctx
50628	defer c.PageToken(c.urlParams_.Get("pageToken")) // reset paging to original point
50629	for {
50630		x, err := c.Do()
50631		if err != nil {
50632			return err
50633		}
50634		if err := f(x); err != nil {
50635			return err
50636		}
50637		if x.NextPageToken == "" {
50638			return nil
50639		}
50640		c.PageToken(x.NextPageToken)
50641	}
50642}
50643
50644// method id "dialogflow.projects.locations.knowledgeBases.documents.patch":
50645
50646type ProjectsLocationsKnowledgeBasesDocumentsPatchCall struct {
50647	s                               *Service
50648	name                            string
50649	googleclouddialogflowv2document *GoogleCloudDialogflowV2Document
50650	urlParams_                      gensupport.URLParams
50651	ctx_                            context.Context
50652	header_                         http.Header
50653}
50654
50655// Patch: Updates the specified document. This method is a long-running
50656// operation
50657// (https://cloud.google.com/dialogflow/cx/docs/how/long-running-operation).
50658// The returned `Operation` type has the following method-specific
50659// fields: - `metadata`: KnowledgeOperationMetadata - `response`:
50660// Document
50661//
50662// - name: Optional. The document resource name. The name must be empty
50663//   when creating a document. Format:
50664//   `projects//locations//knowledgeBases//documents/`.
50665func (r *ProjectsLocationsKnowledgeBasesDocumentsService) Patch(name string, googleclouddialogflowv2document *GoogleCloudDialogflowV2Document) *ProjectsLocationsKnowledgeBasesDocumentsPatchCall {
50666	c := &ProjectsLocationsKnowledgeBasesDocumentsPatchCall{s: r.s, urlParams_: make(gensupport.URLParams)}
50667	c.name = name
50668	c.googleclouddialogflowv2document = googleclouddialogflowv2document
50669	return c
50670}
50671
50672// UpdateMask sets the optional parameter "updateMask": Not specified
50673// means `update all`. Currently, only `display_name` can be updated, an
50674// InvalidArgument will be returned for attempting to update other
50675// fields.
50676func (c *ProjectsLocationsKnowledgeBasesDocumentsPatchCall) UpdateMask(updateMask string) *ProjectsLocationsKnowledgeBasesDocumentsPatchCall {
50677	c.urlParams_.Set("updateMask", updateMask)
50678	return c
50679}
50680
50681// Fields allows partial responses to be retrieved. See
50682// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
50683// for more information.
50684func (c *ProjectsLocationsKnowledgeBasesDocumentsPatchCall) Fields(s ...googleapi.Field) *ProjectsLocationsKnowledgeBasesDocumentsPatchCall {
50685	c.urlParams_.Set("fields", googleapi.CombineFields(s))
50686	return c
50687}
50688
50689// Context sets the context to be used in this call's Do method. Any
50690// pending HTTP request will be aborted if the provided context is
50691// canceled.
50692func (c *ProjectsLocationsKnowledgeBasesDocumentsPatchCall) Context(ctx context.Context) *ProjectsLocationsKnowledgeBasesDocumentsPatchCall {
50693	c.ctx_ = ctx
50694	return c
50695}
50696
50697// Header returns an http.Header that can be modified by the caller to
50698// add HTTP headers to the request.
50699func (c *ProjectsLocationsKnowledgeBasesDocumentsPatchCall) Header() http.Header {
50700	if c.header_ == nil {
50701		c.header_ = make(http.Header)
50702	}
50703	return c.header_
50704}
50705
50706func (c *ProjectsLocationsKnowledgeBasesDocumentsPatchCall) doRequest(alt string) (*http.Response, error) {
50707	reqHeaders := make(http.Header)
50708	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20211027")
50709	for k, v := range c.header_ {
50710		reqHeaders[k] = v
50711	}
50712	reqHeaders.Set("User-Agent", c.s.userAgent())
50713	var body io.Reader = nil
50714	body, err := googleapi.WithoutDataWrapper.JSONReader(c.googleclouddialogflowv2document)
50715	if err != nil {
50716		return nil, err
50717	}
50718	reqHeaders.Set("Content-Type", "application/json")
50719	c.urlParams_.Set("alt", alt)
50720	c.urlParams_.Set("prettyPrint", "false")
50721	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+name}")
50722	urls += "?" + c.urlParams_.Encode()
50723	req, err := http.NewRequest("PATCH", urls, body)
50724	if err != nil {
50725		return nil, err
50726	}
50727	req.Header = reqHeaders
50728	googleapi.Expand(req.URL, map[string]string{
50729		"name": c.name,
50730	})
50731	return gensupport.SendRequest(c.ctx_, c.s.client, req)
50732}
50733
50734// Do executes the "dialogflow.projects.locations.knowledgeBases.documents.patch" call.
50735// Exactly one of *GoogleLongrunningOperation or error will be non-nil.
50736// Any non-2xx status code is an error. Response headers are in either
50737// *GoogleLongrunningOperation.ServerResponse.Header or (if a response
50738// was returned at all) in error.(*googleapi.Error).Header. Use
50739// googleapi.IsNotModified to check whether the returned error was
50740// because http.StatusNotModified was returned.
50741func (c *ProjectsLocationsKnowledgeBasesDocumentsPatchCall) Do(opts ...googleapi.CallOption) (*GoogleLongrunningOperation, error) {
50742	gensupport.SetOptions(c.urlParams_, opts...)
50743	res, err := c.doRequest("json")
50744	if res != nil && res.StatusCode == http.StatusNotModified {
50745		if res.Body != nil {
50746			res.Body.Close()
50747		}
50748		return nil, &googleapi.Error{
50749			Code:   res.StatusCode,
50750			Header: res.Header,
50751		}
50752	}
50753	if err != nil {
50754		return nil, err
50755	}
50756	defer googleapi.CloseBody(res)
50757	if err := googleapi.CheckResponse(res); err != nil {
50758		return nil, err
50759	}
50760	ret := &GoogleLongrunningOperation{
50761		ServerResponse: googleapi.ServerResponse{
50762			Header:         res.Header,
50763			HTTPStatusCode: res.StatusCode,
50764		},
50765	}
50766	target := &ret
50767	if err := gensupport.DecodeResponse(target, res); err != nil {
50768		return nil, err
50769	}
50770	return ret, nil
50771	// {
50772	//   "description": "Updates the specified document. This method is a [long-running operation](https://cloud.google.com/dialogflow/cx/docs/how/long-running-operation). The returned `Operation` type has the following method-specific fields: - `metadata`: KnowledgeOperationMetadata - `response`: Document",
50773	//   "flatPath": "v2/projects/{projectsId}/locations/{locationsId}/knowledgeBases/{knowledgeBasesId}/documents/{documentsId}",
50774	//   "httpMethod": "PATCH",
50775	//   "id": "dialogflow.projects.locations.knowledgeBases.documents.patch",
50776	//   "parameterOrder": [
50777	//     "name"
50778	//   ],
50779	//   "parameters": {
50780	//     "name": {
50781	//       "description": "Optional. The document resource name. The name must be empty when creating a document. Format: `projects//locations//knowledgeBases//documents/`.",
50782	//       "location": "path",
50783	//       "pattern": "^projects/[^/]+/locations/[^/]+/knowledgeBases/[^/]+/documents/[^/]+$",
50784	//       "required": true,
50785	//       "type": "string"
50786	//     },
50787	//     "updateMask": {
50788	//       "description": "Optional. Not specified means `update all`. Currently, only `display_name` can be updated, an InvalidArgument will be returned for attempting to update other fields.",
50789	//       "format": "google-fieldmask",
50790	//       "location": "query",
50791	//       "type": "string"
50792	//     }
50793	//   },
50794	//   "path": "v2/{+name}",
50795	//   "request": {
50796	//     "$ref": "GoogleCloudDialogflowV2Document"
50797	//   },
50798	//   "response": {
50799	//     "$ref": "GoogleLongrunningOperation"
50800	//   },
50801	//   "scopes": [
50802	//     "https://www.googleapis.com/auth/cloud-platform",
50803	//     "https://www.googleapis.com/auth/dialogflow"
50804	//   ]
50805	// }
50806
50807}
50808
50809// method id "dialogflow.projects.locations.knowledgeBases.documents.reload":
50810
50811type ProjectsLocationsKnowledgeBasesDocumentsReloadCall struct {
50812	s                                            *Service
50813	name                                         string
50814	googleclouddialogflowv2reloaddocumentrequest *GoogleCloudDialogflowV2ReloadDocumentRequest
50815	urlParams_                                   gensupport.URLParams
50816	ctx_                                         context.Context
50817	header_                                      http.Header
50818}
50819
50820// Reload: Reloads the specified document from its specified source,
50821// content_uri or content. The previously loaded content of the document
50822// will be deleted. Note: Even when the content of the document has not
50823// changed, there still may be side effects because of internal
50824// implementation changes. This method is a long-running operation
50825// (https://cloud.google.com/dialogflow/cx/docs/how/long-running-operation).
50826// The returned `Operation` type has the following method-specific
50827// fields: - `metadata`: KnowledgeOperationMetadata - `response`:
50828// Document Note: The `projects.agent.knowledgeBases.documents` resource
50829// is deprecated; only use `projects.knowledgeBases.documents`.
50830//
50831// - name: The name of the document to reload. Format:
50832//   `projects//locations//knowledgeBases//documents/`.
50833func (r *ProjectsLocationsKnowledgeBasesDocumentsService) Reload(name string, googleclouddialogflowv2reloaddocumentrequest *GoogleCloudDialogflowV2ReloadDocumentRequest) *ProjectsLocationsKnowledgeBasesDocumentsReloadCall {
50834	c := &ProjectsLocationsKnowledgeBasesDocumentsReloadCall{s: r.s, urlParams_: make(gensupport.URLParams)}
50835	c.name = name
50836	c.googleclouddialogflowv2reloaddocumentrequest = googleclouddialogflowv2reloaddocumentrequest
50837	return c
50838}
50839
50840// Fields allows partial responses to be retrieved. See
50841// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
50842// for more information.
50843func (c *ProjectsLocationsKnowledgeBasesDocumentsReloadCall) Fields(s ...googleapi.Field) *ProjectsLocationsKnowledgeBasesDocumentsReloadCall {
50844	c.urlParams_.Set("fields", googleapi.CombineFields(s))
50845	return c
50846}
50847
50848// Context sets the context to be used in this call's Do method. Any
50849// pending HTTP request will be aborted if the provided context is
50850// canceled.
50851func (c *ProjectsLocationsKnowledgeBasesDocumentsReloadCall) Context(ctx context.Context) *ProjectsLocationsKnowledgeBasesDocumentsReloadCall {
50852	c.ctx_ = ctx
50853	return c
50854}
50855
50856// Header returns an http.Header that can be modified by the caller to
50857// add HTTP headers to the request.
50858func (c *ProjectsLocationsKnowledgeBasesDocumentsReloadCall) Header() http.Header {
50859	if c.header_ == nil {
50860		c.header_ = make(http.Header)
50861	}
50862	return c.header_
50863}
50864
50865func (c *ProjectsLocationsKnowledgeBasesDocumentsReloadCall) doRequest(alt string) (*http.Response, error) {
50866	reqHeaders := make(http.Header)
50867	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20211027")
50868	for k, v := range c.header_ {
50869		reqHeaders[k] = v
50870	}
50871	reqHeaders.Set("User-Agent", c.s.userAgent())
50872	var body io.Reader = nil
50873	body, err := googleapi.WithoutDataWrapper.JSONReader(c.googleclouddialogflowv2reloaddocumentrequest)
50874	if err != nil {
50875		return nil, err
50876	}
50877	reqHeaders.Set("Content-Type", "application/json")
50878	c.urlParams_.Set("alt", alt)
50879	c.urlParams_.Set("prettyPrint", "false")
50880	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+name}:reload")
50881	urls += "?" + c.urlParams_.Encode()
50882	req, err := http.NewRequest("POST", urls, body)
50883	if err != nil {
50884		return nil, err
50885	}
50886	req.Header = reqHeaders
50887	googleapi.Expand(req.URL, map[string]string{
50888		"name": c.name,
50889	})
50890	return gensupport.SendRequest(c.ctx_, c.s.client, req)
50891}
50892
50893// Do executes the "dialogflow.projects.locations.knowledgeBases.documents.reload" call.
50894// Exactly one of *GoogleLongrunningOperation or error will be non-nil.
50895// Any non-2xx status code is an error. Response headers are in either
50896// *GoogleLongrunningOperation.ServerResponse.Header or (if a response
50897// was returned at all) in error.(*googleapi.Error).Header. Use
50898// googleapi.IsNotModified to check whether the returned error was
50899// because http.StatusNotModified was returned.
50900func (c *ProjectsLocationsKnowledgeBasesDocumentsReloadCall) Do(opts ...googleapi.CallOption) (*GoogleLongrunningOperation, error) {
50901	gensupport.SetOptions(c.urlParams_, opts...)
50902	res, err := c.doRequest("json")
50903	if res != nil && res.StatusCode == http.StatusNotModified {
50904		if res.Body != nil {
50905			res.Body.Close()
50906		}
50907		return nil, &googleapi.Error{
50908			Code:   res.StatusCode,
50909			Header: res.Header,
50910		}
50911	}
50912	if err != nil {
50913		return nil, err
50914	}
50915	defer googleapi.CloseBody(res)
50916	if err := googleapi.CheckResponse(res); err != nil {
50917		return nil, err
50918	}
50919	ret := &GoogleLongrunningOperation{
50920		ServerResponse: googleapi.ServerResponse{
50921			Header:         res.Header,
50922			HTTPStatusCode: res.StatusCode,
50923		},
50924	}
50925	target := &ret
50926	if err := gensupport.DecodeResponse(target, res); err != nil {
50927		return nil, err
50928	}
50929	return ret, nil
50930	// {
50931	//   "description": "Reloads the specified document from its specified source, content_uri or content. The previously loaded content of the document will be deleted. Note: Even when the content of the document has not changed, there still may be side effects because of internal implementation changes. This method is a [long-running operation](https://cloud.google.com/dialogflow/cx/docs/how/long-running-operation). The returned `Operation` type has the following method-specific fields: - `metadata`: KnowledgeOperationMetadata - `response`: Document Note: The `projects.agent.knowledgeBases.documents` resource is deprecated; only use `projects.knowledgeBases.documents`.",
50932	//   "flatPath": "v2/projects/{projectsId}/locations/{locationsId}/knowledgeBases/{knowledgeBasesId}/documents/{documentsId}:reload",
50933	//   "httpMethod": "POST",
50934	//   "id": "dialogflow.projects.locations.knowledgeBases.documents.reload",
50935	//   "parameterOrder": [
50936	//     "name"
50937	//   ],
50938	//   "parameters": {
50939	//     "name": {
50940	//       "description": "Required. The name of the document to reload. Format: `projects//locations//knowledgeBases//documents/`",
50941	//       "location": "path",
50942	//       "pattern": "^projects/[^/]+/locations/[^/]+/knowledgeBases/[^/]+/documents/[^/]+$",
50943	//       "required": true,
50944	//       "type": "string"
50945	//     }
50946	//   },
50947	//   "path": "v2/{+name}:reload",
50948	//   "request": {
50949	//     "$ref": "GoogleCloudDialogflowV2ReloadDocumentRequest"
50950	//   },
50951	//   "response": {
50952	//     "$ref": "GoogleLongrunningOperation"
50953	//   },
50954	//   "scopes": [
50955	//     "https://www.googleapis.com/auth/cloud-platform",
50956	//     "https://www.googleapis.com/auth/dialogflow"
50957	//   ]
50958	// }
50959
50960}
50961
50962// method id "dialogflow.projects.locations.operations.cancel":
50963
50964type ProjectsLocationsOperationsCancelCall struct {
50965	s          *Service
50966	name       string
50967	urlParams_ gensupport.URLParams
50968	ctx_       context.Context
50969	header_    http.Header
50970}
50971
50972// Cancel: Starts asynchronous cancellation on a long-running operation.
50973// The server makes a best effort to cancel the operation, but success
50974// is not guaranteed. If the server doesn't support this method, it
50975// returns `google.rpc.Code.UNIMPLEMENTED`. Clients can use
50976// Operations.GetOperation or other methods to check whether the
50977// cancellation succeeded or whether the operation completed despite
50978// cancellation. On successful cancellation, the operation is not
50979// deleted; instead, it becomes an operation with an Operation.error
50980// value with a google.rpc.Status.code of 1, corresponding to
50981// `Code.CANCELLED`.
50982//
50983// - name: The name of the operation resource to be cancelled.
50984func (r *ProjectsLocationsOperationsService) Cancel(name string) *ProjectsLocationsOperationsCancelCall {
50985	c := &ProjectsLocationsOperationsCancelCall{s: r.s, urlParams_: make(gensupport.URLParams)}
50986	c.name = name
50987	return c
50988}
50989
50990// Fields allows partial responses to be retrieved. See
50991// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
50992// for more information.
50993func (c *ProjectsLocationsOperationsCancelCall) Fields(s ...googleapi.Field) *ProjectsLocationsOperationsCancelCall {
50994	c.urlParams_.Set("fields", googleapi.CombineFields(s))
50995	return c
50996}
50997
50998// Context sets the context to be used in this call's Do method. Any
50999// pending HTTP request will be aborted if the provided context is
51000// canceled.
51001func (c *ProjectsLocationsOperationsCancelCall) Context(ctx context.Context) *ProjectsLocationsOperationsCancelCall {
51002	c.ctx_ = ctx
51003	return c
51004}
51005
51006// Header returns an http.Header that can be modified by the caller to
51007// add HTTP headers to the request.
51008func (c *ProjectsLocationsOperationsCancelCall) Header() http.Header {
51009	if c.header_ == nil {
51010		c.header_ = make(http.Header)
51011	}
51012	return c.header_
51013}
51014
51015func (c *ProjectsLocationsOperationsCancelCall) doRequest(alt string) (*http.Response, error) {
51016	reqHeaders := make(http.Header)
51017	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20211027")
51018	for k, v := range c.header_ {
51019		reqHeaders[k] = v
51020	}
51021	reqHeaders.Set("User-Agent", c.s.userAgent())
51022	var body io.Reader = nil
51023	c.urlParams_.Set("alt", alt)
51024	c.urlParams_.Set("prettyPrint", "false")
51025	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+name}:cancel")
51026	urls += "?" + c.urlParams_.Encode()
51027	req, err := http.NewRequest("POST", urls, body)
51028	if err != nil {
51029		return nil, err
51030	}
51031	req.Header = reqHeaders
51032	googleapi.Expand(req.URL, map[string]string{
51033		"name": c.name,
51034	})
51035	return gensupport.SendRequest(c.ctx_, c.s.client, req)
51036}
51037
51038// Do executes the "dialogflow.projects.locations.operations.cancel" call.
51039// Exactly one of *GoogleProtobufEmpty or error will be non-nil. Any
51040// non-2xx status code is an error. Response headers are in either
51041// *GoogleProtobufEmpty.ServerResponse.Header or (if a response was
51042// returned at all) in error.(*googleapi.Error).Header. Use
51043// googleapi.IsNotModified to check whether the returned error was
51044// because http.StatusNotModified was returned.
51045func (c *ProjectsLocationsOperationsCancelCall) Do(opts ...googleapi.CallOption) (*GoogleProtobufEmpty, error) {
51046	gensupport.SetOptions(c.urlParams_, opts...)
51047	res, err := c.doRequest("json")
51048	if res != nil && res.StatusCode == http.StatusNotModified {
51049		if res.Body != nil {
51050			res.Body.Close()
51051		}
51052		return nil, &googleapi.Error{
51053			Code:   res.StatusCode,
51054			Header: res.Header,
51055		}
51056	}
51057	if err != nil {
51058		return nil, err
51059	}
51060	defer googleapi.CloseBody(res)
51061	if err := googleapi.CheckResponse(res); err != nil {
51062		return nil, err
51063	}
51064	ret := &GoogleProtobufEmpty{
51065		ServerResponse: googleapi.ServerResponse{
51066			Header:         res.Header,
51067			HTTPStatusCode: res.StatusCode,
51068		},
51069	}
51070	target := &ret
51071	if err := gensupport.DecodeResponse(target, res); err != nil {
51072		return nil, err
51073	}
51074	return ret, nil
51075	// {
51076	//   "description": "Starts asynchronous cancellation on a long-running operation. The server makes a best effort to cancel the operation, but success is not guaranteed. If the server doesn't support this method, it returns `google.rpc.Code.UNIMPLEMENTED`. Clients can use Operations.GetOperation or other methods to check whether the cancellation succeeded or whether the operation completed despite cancellation. On successful cancellation, the operation is not deleted; instead, it becomes an operation with an Operation.error value with a google.rpc.Status.code of 1, corresponding to `Code.CANCELLED`.",
51077	//   "flatPath": "v2/projects/{projectsId}/locations/{locationsId}/operations/{operationsId}:cancel",
51078	//   "httpMethod": "POST",
51079	//   "id": "dialogflow.projects.locations.operations.cancel",
51080	//   "parameterOrder": [
51081	//     "name"
51082	//   ],
51083	//   "parameters": {
51084	//     "name": {
51085	//       "description": "The name of the operation resource to be cancelled.",
51086	//       "location": "path",
51087	//       "pattern": "^projects/[^/]+/locations/[^/]+/operations/[^/]+$",
51088	//       "required": true,
51089	//       "type": "string"
51090	//     }
51091	//   },
51092	//   "path": "v2/{+name}:cancel",
51093	//   "response": {
51094	//     "$ref": "GoogleProtobufEmpty"
51095	//   },
51096	//   "scopes": [
51097	//     "https://www.googleapis.com/auth/cloud-platform",
51098	//     "https://www.googleapis.com/auth/dialogflow"
51099	//   ]
51100	// }
51101
51102}
51103
51104// method id "dialogflow.projects.locations.operations.get":
51105
51106type ProjectsLocationsOperationsGetCall struct {
51107	s            *Service
51108	name         string
51109	urlParams_   gensupport.URLParams
51110	ifNoneMatch_ string
51111	ctx_         context.Context
51112	header_      http.Header
51113}
51114
51115// Get: Gets the latest state of a long-running operation. Clients can
51116// use this method to poll the operation result at intervals as
51117// recommended by the API service.
51118//
51119// - name: The name of the operation resource.
51120func (r *ProjectsLocationsOperationsService) Get(name string) *ProjectsLocationsOperationsGetCall {
51121	c := &ProjectsLocationsOperationsGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
51122	c.name = name
51123	return c
51124}
51125
51126// Fields allows partial responses to be retrieved. See
51127// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
51128// for more information.
51129func (c *ProjectsLocationsOperationsGetCall) Fields(s ...googleapi.Field) *ProjectsLocationsOperationsGetCall {
51130	c.urlParams_.Set("fields", googleapi.CombineFields(s))
51131	return c
51132}
51133
51134// IfNoneMatch sets the optional parameter which makes the operation
51135// fail if the object's ETag matches the given value. This is useful for
51136// getting updates only after the object has changed since the last
51137// request. Use googleapi.IsNotModified to check whether the response
51138// error from Do is the result of In-None-Match.
51139func (c *ProjectsLocationsOperationsGetCall) IfNoneMatch(entityTag string) *ProjectsLocationsOperationsGetCall {
51140	c.ifNoneMatch_ = entityTag
51141	return c
51142}
51143
51144// Context sets the context to be used in this call's Do method. Any
51145// pending HTTP request will be aborted if the provided context is
51146// canceled.
51147func (c *ProjectsLocationsOperationsGetCall) Context(ctx context.Context) *ProjectsLocationsOperationsGetCall {
51148	c.ctx_ = ctx
51149	return c
51150}
51151
51152// Header returns an http.Header that can be modified by the caller to
51153// add HTTP headers to the request.
51154func (c *ProjectsLocationsOperationsGetCall) Header() http.Header {
51155	if c.header_ == nil {
51156		c.header_ = make(http.Header)
51157	}
51158	return c.header_
51159}
51160
51161func (c *ProjectsLocationsOperationsGetCall) doRequest(alt string) (*http.Response, error) {
51162	reqHeaders := make(http.Header)
51163	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20211027")
51164	for k, v := range c.header_ {
51165		reqHeaders[k] = v
51166	}
51167	reqHeaders.Set("User-Agent", c.s.userAgent())
51168	if c.ifNoneMatch_ != "" {
51169		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
51170	}
51171	var body io.Reader = nil
51172	c.urlParams_.Set("alt", alt)
51173	c.urlParams_.Set("prettyPrint", "false")
51174	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+name}")
51175	urls += "?" + c.urlParams_.Encode()
51176	req, err := http.NewRequest("GET", urls, body)
51177	if err != nil {
51178		return nil, err
51179	}
51180	req.Header = reqHeaders
51181	googleapi.Expand(req.URL, map[string]string{
51182		"name": c.name,
51183	})
51184	return gensupport.SendRequest(c.ctx_, c.s.client, req)
51185}
51186
51187// Do executes the "dialogflow.projects.locations.operations.get" call.
51188// Exactly one of *GoogleLongrunningOperation or error will be non-nil.
51189// Any non-2xx status code is an error. Response headers are in either
51190// *GoogleLongrunningOperation.ServerResponse.Header or (if a response
51191// was returned at all) in error.(*googleapi.Error).Header. Use
51192// googleapi.IsNotModified to check whether the returned error was
51193// because http.StatusNotModified was returned.
51194func (c *ProjectsLocationsOperationsGetCall) Do(opts ...googleapi.CallOption) (*GoogleLongrunningOperation, error) {
51195	gensupport.SetOptions(c.urlParams_, opts...)
51196	res, err := c.doRequest("json")
51197	if res != nil && res.StatusCode == http.StatusNotModified {
51198		if res.Body != nil {
51199			res.Body.Close()
51200		}
51201		return nil, &googleapi.Error{
51202			Code:   res.StatusCode,
51203			Header: res.Header,
51204		}
51205	}
51206	if err != nil {
51207		return nil, err
51208	}
51209	defer googleapi.CloseBody(res)
51210	if err := googleapi.CheckResponse(res); err != nil {
51211		return nil, err
51212	}
51213	ret := &GoogleLongrunningOperation{
51214		ServerResponse: googleapi.ServerResponse{
51215			Header:         res.Header,
51216			HTTPStatusCode: res.StatusCode,
51217		},
51218	}
51219	target := &ret
51220	if err := gensupport.DecodeResponse(target, res); err != nil {
51221		return nil, err
51222	}
51223	return ret, nil
51224	// {
51225	//   "description": "Gets the latest state of a long-running operation. Clients can use this method to poll the operation result at intervals as recommended by the API service.",
51226	//   "flatPath": "v2/projects/{projectsId}/locations/{locationsId}/operations/{operationsId}",
51227	//   "httpMethod": "GET",
51228	//   "id": "dialogflow.projects.locations.operations.get",
51229	//   "parameterOrder": [
51230	//     "name"
51231	//   ],
51232	//   "parameters": {
51233	//     "name": {
51234	//       "description": "The name of the operation resource.",
51235	//       "location": "path",
51236	//       "pattern": "^projects/[^/]+/locations/[^/]+/operations/[^/]+$",
51237	//       "required": true,
51238	//       "type": "string"
51239	//     }
51240	//   },
51241	//   "path": "v2/{+name}",
51242	//   "response": {
51243	//     "$ref": "GoogleLongrunningOperation"
51244	//   },
51245	//   "scopes": [
51246	//     "https://www.googleapis.com/auth/cloud-platform",
51247	//     "https://www.googleapis.com/auth/dialogflow"
51248	//   ]
51249	// }
51250
51251}
51252
51253// method id "dialogflow.projects.locations.operations.list":
51254
51255type ProjectsLocationsOperationsListCall struct {
51256	s            *Service
51257	name         string
51258	urlParams_   gensupport.URLParams
51259	ifNoneMatch_ string
51260	ctx_         context.Context
51261	header_      http.Header
51262}
51263
51264// List: Lists operations that match the specified filter in the
51265// request. If the server doesn't support this method, it returns
51266// `UNIMPLEMENTED`. NOTE: the `name` binding allows API services to
51267// override the binding to use different resource name schemes, such as
51268// `users/*/operations`. To override the binding, API services can add a
51269// binding such as "/v1/{name=users/*}/operations" to their service
51270// configuration. For backwards compatibility, the default name includes
51271// the operations collection id, however overriding users must ensure
51272// the name binding is the parent resource, without the operations
51273// collection id.
51274//
51275// - name: The name of the operation's parent resource.
51276func (r *ProjectsLocationsOperationsService) List(name string) *ProjectsLocationsOperationsListCall {
51277	c := &ProjectsLocationsOperationsListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
51278	c.name = name
51279	return c
51280}
51281
51282// Filter sets the optional parameter "filter": The standard list
51283// filter.
51284func (c *ProjectsLocationsOperationsListCall) Filter(filter string) *ProjectsLocationsOperationsListCall {
51285	c.urlParams_.Set("filter", filter)
51286	return c
51287}
51288
51289// PageSize sets the optional parameter "pageSize": The standard list
51290// page size.
51291func (c *ProjectsLocationsOperationsListCall) PageSize(pageSize int64) *ProjectsLocationsOperationsListCall {
51292	c.urlParams_.Set("pageSize", fmt.Sprint(pageSize))
51293	return c
51294}
51295
51296// PageToken sets the optional parameter "pageToken": The standard list
51297// page token.
51298func (c *ProjectsLocationsOperationsListCall) PageToken(pageToken string) *ProjectsLocationsOperationsListCall {
51299	c.urlParams_.Set("pageToken", pageToken)
51300	return c
51301}
51302
51303// Fields allows partial responses to be retrieved. See
51304// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
51305// for more information.
51306func (c *ProjectsLocationsOperationsListCall) Fields(s ...googleapi.Field) *ProjectsLocationsOperationsListCall {
51307	c.urlParams_.Set("fields", googleapi.CombineFields(s))
51308	return c
51309}
51310
51311// IfNoneMatch sets the optional parameter which makes the operation
51312// fail if the object's ETag matches the given value. This is useful for
51313// getting updates only after the object has changed since the last
51314// request. Use googleapi.IsNotModified to check whether the response
51315// error from Do is the result of In-None-Match.
51316func (c *ProjectsLocationsOperationsListCall) IfNoneMatch(entityTag string) *ProjectsLocationsOperationsListCall {
51317	c.ifNoneMatch_ = entityTag
51318	return c
51319}
51320
51321// Context sets the context to be used in this call's Do method. Any
51322// pending HTTP request will be aborted if the provided context is
51323// canceled.
51324func (c *ProjectsLocationsOperationsListCall) Context(ctx context.Context) *ProjectsLocationsOperationsListCall {
51325	c.ctx_ = ctx
51326	return c
51327}
51328
51329// Header returns an http.Header that can be modified by the caller to
51330// add HTTP headers to the request.
51331func (c *ProjectsLocationsOperationsListCall) Header() http.Header {
51332	if c.header_ == nil {
51333		c.header_ = make(http.Header)
51334	}
51335	return c.header_
51336}
51337
51338func (c *ProjectsLocationsOperationsListCall) doRequest(alt string) (*http.Response, error) {
51339	reqHeaders := make(http.Header)
51340	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20211027")
51341	for k, v := range c.header_ {
51342		reqHeaders[k] = v
51343	}
51344	reqHeaders.Set("User-Agent", c.s.userAgent())
51345	if c.ifNoneMatch_ != "" {
51346		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
51347	}
51348	var body io.Reader = nil
51349	c.urlParams_.Set("alt", alt)
51350	c.urlParams_.Set("prettyPrint", "false")
51351	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+name}/operations")
51352	urls += "?" + c.urlParams_.Encode()
51353	req, err := http.NewRequest("GET", urls, body)
51354	if err != nil {
51355		return nil, err
51356	}
51357	req.Header = reqHeaders
51358	googleapi.Expand(req.URL, map[string]string{
51359		"name": c.name,
51360	})
51361	return gensupport.SendRequest(c.ctx_, c.s.client, req)
51362}
51363
51364// Do executes the "dialogflow.projects.locations.operations.list" call.
51365// Exactly one of *GoogleLongrunningListOperationsResponse or error will
51366// be non-nil. Any non-2xx status code is an error. Response headers are
51367// in either
51368// *GoogleLongrunningListOperationsResponse.ServerResponse.Header or (if
51369// a response was returned at all) in error.(*googleapi.Error).Header.
51370// Use googleapi.IsNotModified to check whether the returned error was
51371// because http.StatusNotModified was returned.
51372func (c *ProjectsLocationsOperationsListCall) Do(opts ...googleapi.CallOption) (*GoogleLongrunningListOperationsResponse, error) {
51373	gensupport.SetOptions(c.urlParams_, opts...)
51374	res, err := c.doRequest("json")
51375	if res != nil && res.StatusCode == http.StatusNotModified {
51376		if res.Body != nil {
51377			res.Body.Close()
51378		}
51379		return nil, &googleapi.Error{
51380			Code:   res.StatusCode,
51381			Header: res.Header,
51382		}
51383	}
51384	if err != nil {
51385		return nil, err
51386	}
51387	defer googleapi.CloseBody(res)
51388	if err := googleapi.CheckResponse(res); err != nil {
51389		return nil, err
51390	}
51391	ret := &GoogleLongrunningListOperationsResponse{
51392		ServerResponse: googleapi.ServerResponse{
51393			Header:         res.Header,
51394			HTTPStatusCode: res.StatusCode,
51395		},
51396	}
51397	target := &ret
51398	if err := gensupport.DecodeResponse(target, res); err != nil {
51399		return nil, err
51400	}
51401	return ret, nil
51402	// {
51403	//   "description": "Lists operations that match the specified filter in the request. If the server doesn't support this method, it returns `UNIMPLEMENTED`. NOTE: the `name` binding allows API services to override the binding to use different resource name schemes, such as `users/*/operations`. To override the binding, API services can add a binding such as `\"/v1/{name=users/*}/operations\"` to their service configuration. For backwards compatibility, the default name includes the operations collection id, however overriding users must ensure the name binding is the parent resource, without the operations collection id.",
51404	//   "flatPath": "v2/projects/{projectsId}/locations/{locationsId}/operations",
51405	//   "httpMethod": "GET",
51406	//   "id": "dialogflow.projects.locations.operations.list",
51407	//   "parameterOrder": [
51408	//     "name"
51409	//   ],
51410	//   "parameters": {
51411	//     "filter": {
51412	//       "description": "The standard list filter.",
51413	//       "location": "query",
51414	//       "type": "string"
51415	//     },
51416	//     "name": {
51417	//       "description": "The name of the operation's parent resource.",
51418	//       "location": "path",
51419	//       "pattern": "^projects/[^/]+/locations/[^/]+$",
51420	//       "required": true,
51421	//       "type": "string"
51422	//     },
51423	//     "pageSize": {
51424	//       "description": "The standard list page size.",
51425	//       "format": "int32",
51426	//       "location": "query",
51427	//       "type": "integer"
51428	//     },
51429	//     "pageToken": {
51430	//       "description": "The standard list page token.",
51431	//       "location": "query",
51432	//       "type": "string"
51433	//     }
51434	//   },
51435	//   "path": "v2/{+name}/operations",
51436	//   "response": {
51437	//     "$ref": "GoogleLongrunningListOperationsResponse"
51438	//   },
51439	//   "scopes": [
51440	//     "https://www.googleapis.com/auth/cloud-platform",
51441	//     "https://www.googleapis.com/auth/dialogflow"
51442	//   ]
51443	// }
51444
51445}
51446
51447// Pages invokes f for each page of results.
51448// A non-nil error returned from f will halt the iteration.
51449// The provided context supersedes any context provided to the Context method.
51450func (c *ProjectsLocationsOperationsListCall) Pages(ctx context.Context, f func(*GoogleLongrunningListOperationsResponse) error) error {
51451	c.ctx_ = ctx
51452	defer c.PageToken(c.urlParams_.Get("pageToken")) // reset paging to original point
51453	for {
51454		x, err := c.Do()
51455		if err != nil {
51456			return err
51457		}
51458		if err := f(x); err != nil {
51459			return err
51460		}
51461		if x.NextPageToken == "" {
51462			return nil
51463		}
51464		c.PageToken(x.NextPageToken)
51465	}
51466}
51467
51468// method id "dialogflow.projects.operations.cancel":
51469
51470type ProjectsOperationsCancelCall struct {
51471	s          *Service
51472	name       string
51473	urlParams_ gensupport.URLParams
51474	ctx_       context.Context
51475	header_    http.Header
51476}
51477
51478// Cancel: Starts asynchronous cancellation on a long-running operation.
51479// The server makes a best effort to cancel the operation, but success
51480// is not guaranteed. If the server doesn't support this method, it
51481// returns `google.rpc.Code.UNIMPLEMENTED`. Clients can use
51482// Operations.GetOperation or other methods to check whether the
51483// cancellation succeeded or whether the operation completed despite
51484// cancellation. On successful cancellation, the operation is not
51485// deleted; instead, it becomes an operation with an Operation.error
51486// value with a google.rpc.Status.code of 1, corresponding to
51487// `Code.CANCELLED`.
51488//
51489// - name: The name of the operation resource to be cancelled.
51490func (r *ProjectsOperationsService) Cancel(name string) *ProjectsOperationsCancelCall {
51491	c := &ProjectsOperationsCancelCall{s: r.s, urlParams_: make(gensupport.URLParams)}
51492	c.name = name
51493	return c
51494}
51495
51496// Fields allows partial responses to be retrieved. See
51497// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
51498// for more information.
51499func (c *ProjectsOperationsCancelCall) Fields(s ...googleapi.Field) *ProjectsOperationsCancelCall {
51500	c.urlParams_.Set("fields", googleapi.CombineFields(s))
51501	return c
51502}
51503
51504// Context sets the context to be used in this call's Do method. Any
51505// pending HTTP request will be aborted if the provided context is
51506// canceled.
51507func (c *ProjectsOperationsCancelCall) Context(ctx context.Context) *ProjectsOperationsCancelCall {
51508	c.ctx_ = ctx
51509	return c
51510}
51511
51512// Header returns an http.Header that can be modified by the caller to
51513// add HTTP headers to the request.
51514func (c *ProjectsOperationsCancelCall) Header() http.Header {
51515	if c.header_ == nil {
51516		c.header_ = make(http.Header)
51517	}
51518	return c.header_
51519}
51520
51521func (c *ProjectsOperationsCancelCall) doRequest(alt string) (*http.Response, error) {
51522	reqHeaders := make(http.Header)
51523	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20211027")
51524	for k, v := range c.header_ {
51525		reqHeaders[k] = v
51526	}
51527	reqHeaders.Set("User-Agent", c.s.userAgent())
51528	var body io.Reader = nil
51529	c.urlParams_.Set("alt", alt)
51530	c.urlParams_.Set("prettyPrint", "false")
51531	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+name}:cancel")
51532	urls += "?" + c.urlParams_.Encode()
51533	req, err := http.NewRequest("POST", urls, body)
51534	if err != nil {
51535		return nil, err
51536	}
51537	req.Header = reqHeaders
51538	googleapi.Expand(req.URL, map[string]string{
51539		"name": c.name,
51540	})
51541	return gensupport.SendRequest(c.ctx_, c.s.client, req)
51542}
51543
51544// Do executes the "dialogflow.projects.operations.cancel" call.
51545// Exactly one of *GoogleProtobufEmpty or error will be non-nil. Any
51546// non-2xx status code is an error. Response headers are in either
51547// *GoogleProtobufEmpty.ServerResponse.Header or (if a response was
51548// returned at all) in error.(*googleapi.Error).Header. Use
51549// googleapi.IsNotModified to check whether the returned error was
51550// because http.StatusNotModified was returned.
51551func (c *ProjectsOperationsCancelCall) Do(opts ...googleapi.CallOption) (*GoogleProtobufEmpty, error) {
51552	gensupport.SetOptions(c.urlParams_, opts...)
51553	res, err := c.doRequest("json")
51554	if res != nil && res.StatusCode == http.StatusNotModified {
51555		if res.Body != nil {
51556			res.Body.Close()
51557		}
51558		return nil, &googleapi.Error{
51559			Code:   res.StatusCode,
51560			Header: res.Header,
51561		}
51562	}
51563	if err != nil {
51564		return nil, err
51565	}
51566	defer googleapi.CloseBody(res)
51567	if err := googleapi.CheckResponse(res); err != nil {
51568		return nil, err
51569	}
51570	ret := &GoogleProtobufEmpty{
51571		ServerResponse: googleapi.ServerResponse{
51572			Header:         res.Header,
51573			HTTPStatusCode: res.StatusCode,
51574		},
51575	}
51576	target := &ret
51577	if err := gensupport.DecodeResponse(target, res); err != nil {
51578		return nil, err
51579	}
51580	return ret, nil
51581	// {
51582	//   "description": "Starts asynchronous cancellation on a long-running operation. The server makes a best effort to cancel the operation, but success is not guaranteed. If the server doesn't support this method, it returns `google.rpc.Code.UNIMPLEMENTED`. Clients can use Operations.GetOperation or other methods to check whether the cancellation succeeded or whether the operation completed despite cancellation. On successful cancellation, the operation is not deleted; instead, it becomes an operation with an Operation.error value with a google.rpc.Status.code of 1, corresponding to `Code.CANCELLED`.",
51583	//   "flatPath": "v2/projects/{projectsId}/operations/{operationsId}:cancel",
51584	//   "httpMethod": "POST",
51585	//   "id": "dialogflow.projects.operations.cancel",
51586	//   "parameterOrder": [
51587	//     "name"
51588	//   ],
51589	//   "parameters": {
51590	//     "name": {
51591	//       "description": "The name of the operation resource to be cancelled.",
51592	//       "location": "path",
51593	//       "pattern": "^projects/[^/]+/operations/[^/]+$",
51594	//       "required": true,
51595	//       "type": "string"
51596	//     }
51597	//   },
51598	//   "path": "v2/{+name}:cancel",
51599	//   "response": {
51600	//     "$ref": "GoogleProtobufEmpty"
51601	//   },
51602	//   "scopes": [
51603	//     "https://www.googleapis.com/auth/cloud-platform",
51604	//     "https://www.googleapis.com/auth/dialogflow"
51605	//   ]
51606	// }
51607
51608}
51609
51610// method id "dialogflow.projects.operations.get":
51611
51612type ProjectsOperationsGetCall struct {
51613	s            *Service
51614	name         string
51615	urlParams_   gensupport.URLParams
51616	ifNoneMatch_ string
51617	ctx_         context.Context
51618	header_      http.Header
51619}
51620
51621// Get: Gets the latest state of a long-running operation. Clients can
51622// use this method to poll the operation result at intervals as
51623// recommended by the API service.
51624//
51625// - name: The name of the operation resource.
51626func (r *ProjectsOperationsService) Get(name string) *ProjectsOperationsGetCall {
51627	c := &ProjectsOperationsGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
51628	c.name = name
51629	return c
51630}
51631
51632// Fields allows partial responses to be retrieved. See
51633// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
51634// for more information.
51635func (c *ProjectsOperationsGetCall) Fields(s ...googleapi.Field) *ProjectsOperationsGetCall {
51636	c.urlParams_.Set("fields", googleapi.CombineFields(s))
51637	return c
51638}
51639
51640// IfNoneMatch sets the optional parameter which makes the operation
51641// fail if the object's ETag matches the given value. This is useful for
51642// getting updates only after the object has changed since the last
51643// request. Use googleapi.IsNotModified to check whether the response
51644// error from Do is the result of In-None-Match.
51645func (c *ProjectsOperationsGetCall) IfNoneMatch(entityTag string) *ProjectsOperationsGetCall {
51646	c.ifNoneMatch_ = entityTag
51647	return c
51648}
51649
51650// Context sets the context to be used in this call's Do method. Any
51651// pending HTTP request will be aborted if the provided context is
51652// canceled.
51653func (c *ProjectsOperationsGetCall) Context(ctx context.Context) *ProjectsOperationsGetCall {
51654	c.ctx_ = ctx
51655	return c
51656}
51657
51658// Header returns an http.Header that can be modified by the caller to
51659// add HTTP headers to the request.
51660func (c *ProjectsOperationsGetCall) Header() http.Header {
51661	if c.header_ == nil {
51662		c.header_ = make(http.Header)
51663	}
51664	return c.header_
51665}
51666
51667func (c *ProjectsOperationsGetCall) doRequest(alt string) (*http.Response, error) {
51668	reqHeaders := make(http.Header)
51669	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20211027")
51670	for k, v := range c.header_ {
51671		reqHeaders[k] = v
51672	}
51673	reqHeaders.Set("User-Agent", c.s.userAgent())
51674	if c.ifNoneMatch_ != "" {
51675		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
51676	}
51677	var body io.Reader = nil
51678	c.urlParams_.Set("alt", alt)
51679	c.urlParams_.Set("prettyPrint", "false")
51680	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+name}")
51681	urls += "?" + c.urlParams_.Encode()
51682	req, err := http.NewRequest("GET", urls, body)
51683	if err != nil {
51684		return nil, err
51685	}
51686	req.Header = reqHeaders
51687	googleapi.Expand(req.URL, map[string]string{
51688		"name": c.name,
51689	})
51690	return gensupport.SendRequest(c.ctx_, c.s.client, req)
51691}
51692
51693// Do executes the "dialogflow.projects.operations.get" call.
51694// Exactly one of *GoogleLongrunningOperation or error will be non-nil.
51695// Any non-2xx status code is an error. Response headers are in either
51696// *GoogleLongrunningOperation.ServerResponse.Header or (if a response
51697// was returned at all) in error.(*googleapi.Error).Header. Use
51698// googleapi.IsNotModified to check whether the returned error was
51699// because http.StatusNotModified was returned.
51700func (c *ProjectsOperationsGetCall) Do(opts ...googleapi.CallOption) (*GoogleLongrunningOperation, error) {
51701	gensupport.SetOptions(c.urlParams_, opts...)
51702	res, err := c.doRequest("json")
51703	if res != nil && res.StatusCode == http.StatusNotModified {
51704		if res.Body != nil {
51705			res.Body.Close()
51706		}
51707		return nil, &googleapi.Error{
51708			Code:   res.StatusCode,
51709			Header: res.Header,
51710		}
51711	}
51712	if err != nil {
51713		return nil, err
51714	}
51715	defer googleapi.CloseBody(res)
51716	if err := googleapi.CheckResponse(res); err != nil {
51717		return nil, err
51718	}
51719	ret := &GoogleLongrunningOperation{
51720		ServerResponse: googleapi.ServerResponse{
51721			Header:         res.Header,
51722			HTTPStatusCode: res.StatusCode,
51723		},
51724	}
51725	target := &ret
51726	if err := gensupport.DecodeResponse(target, res); err != nil {
51727		return nil, err
51728	}
51729	return ret, nil
51730	// {
51731	//   "description": "Gets the latest state of a long-running operation. Clients can use this method to poll the operation result at intervals as recommended by the API service.",
51732	//   "flatPath": "v2/projects/{projectsId}/operations/{operationsId}",
51733	//   "httpMethod": "GET",
51734	//   "id": "dialogflow.projects.operations.get",
51735	//   "parameterOrder": [
51736	//     "name"
51737	//   ],
51738	//   "parameters": {
51739	//     "name": {
51740	//       "description": "The name of the operation resource.",
51741	//       "location": "path",
51742	//       "pattern": "^projects/[^/]+/operations/[^/]+$",
51743	//       "required": true,
51744	//       "type": "string"
51745	//     }
51746	//   },
51747	//   "path": "v2/{+name}",
51748	//   "response": {
51749	//     "$ref": "GoogleLongrunningOperation"
51750	//   },
51751	//   "scopes": [
51752	//     "https://www.googleapis.com/auth/cloud-platform",
51753	//     "https://www.googleapis.com/auth/dialogflow"
51754	//   ]
51755	// }
51756
51757}
51758
51759// method id "dialogflow.projects.operations.list":
51760
51761type ProjectsOperationsListCall struct {
51762	s            *Service
51763	name         string
51764	urlParams_   gensupport.URLParams
51765	ifNoneMatch_ string
51766	ctx_         context.Context
51767	header_      http.Header
51768}
51769
51770// List: Lists operations that match the specified filter in the
51771// request. If the server doesn't support this method, it returns
51772// `UNIMPLEMENTED`. NOTE: the `name` binding allows API services to
51773// override the binding to use different resource name schemes, such as
51774// `users/*/operations`. To override the binding, API services can add a
51775// binding such as "/v1/{name=users/*}/operations" to their service
51776// configuration. For backwards compatibility, the default name includes
51777// the operations collection id, however overriding users must ensure
51778// the name binding is the parent resource, without the operations
51779// collection id.
51780//
51781// - name: The name of the operation's parent resource.
51782func (r *ProjectsOperationsService) List(name string) *ProjectsOperationsListCall {
51783	c := &ProjectsOperationsListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
51784	c.name = name
51785	return c
51786}
51787
51788// Filter sets the optional parameter "filter": The standard list
51789// filter.
51790func (c *ProjectsOperationsListCall) Filter(filter string) *ProjectsOperationsListCall {
51791	c.urlParams_.Set("filter", filter)
51792	return c
51793}
51794
51795// PageSize sets the optional parameter "pageSize": The standard list
51796// page size.
51797func (c *ProjectsOperationsListCall) PageSize(pageSize int64) *ProjectsOperationsListCall {
51798	c.urlParams_.Set("pageSize", fmt.Sprint(pageSize))
51799	return c
51800}
51801
51802// PageToken sets the optional parameter "pageToken": The standard list
51803// page token.
51804func (c *ProjectsOperationsListCall) PageToken(pageToken string) *ProjectsOperationsListCall {
51805	c.urlParams_.Set("pageToken", pageToken)
51806	return c
51807}
51808
51809// Fields allows partial responses to be retrieved. See
51810// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
51811// for more information.
51812func (c *ProjectsOperationsListCall) Fields(s ...googleapi.Field) *ProjectsOperationsListCall {
51813	c.urlParams_.Set("fields", googleapi.CombineFields(s))
51814	return c
51815}
51816
51817// IfNoneMatch sets the optional parameter which makes the operation
51818// fail if the object's ETag matches the given value. This is useful for
51819// getting updates only after the object has changed since the last
51820// request. Use googleapi.IsNotModified to check whether the response
51821// error from Do is the result of In-None-Match.
51822func (c *ProjectsOperationsListCall) IfNoneMatch(entityTag string) *ProjectsOperationsListCall {
51823	c.ifNoneMatch_ = entityTag
51824	return c
51825}
51826
51827// Context sets the context to be used in this call's Do method. Any
51828// pending HTTP request will be aborted if the provided context is
51829// canceled.
51830func (c *ProjectsOperationsListCall) Context(ctx context.Context) *ProjectsOperationsListCall {
51831	c.ctx_ = ctx
51832	return c
51833}
51834
51835// Header returns an http.Header that can be modified by the caller to
51836// add HTTP headers to the request.
51837func (c *ProjectsOperationsListCall) Header() http.Header {
51838	if c.header_ == nil {
51839		c.header_ = make(http.Header)
51840	}
51841	return c.header_
51842}
51843
51844func (c *ProjectsOperationsListCall) doRequest(alt string) (*http.Response, error) {
51845	reqHeaders := make(http.Header)
51846	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20211027")
51847	for k, v := range c.header_ {
51848		reqHeaders[k] = v
51849	}
51850	reqHeaders.Set("User-Agent", c.s.userAgent())
51851	if c.ifNoneMatch_ != "" {
51852		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
51853	}
51854	var body io.Reader = nil
51855	c.urlParams_.Set("alt", alt)
51856	c.urlParams_.Set("prettyPrint", "false")
51857	urls := googleapi.ResolveRelative(c.s.BasePath, "v2/{+name}/operations")
51858	urls += "?" + c.urlParams_.Encode()
51859	req, err := http.NewRequest("GET", urls, body)
51860	if err != nil {
51861		return nil, err
51862	}
51863	req.Header = reqHeaders
51864	googleapi.Expand(req.URL, map[string]string{
51865		"name": c.name,
51866	})
51867	return gensupport.SendRequest(c.ctx_, c.s.client, req)
51868}
51869
51870// Do executes the "dialogflow.projects.operations.list" call.
51871// Exactly one of *GoogleLongrunningListOperationsResponse or error will
51872// be non-nil. Any non-2xx status code is an error. Response headers are
51873// in either
51874// *GoogleLongrunningListOperationsResponse.ServerResponse.Header or (if
51875// a response was returned at all) in error.(*googleapi.Error).Header.
51876// Use googleapi.IsNotModified to check whether the returned error was
51877// because http.StatusNotModified was returned.
51878func (c *ProjectsOperationsListCall) Do(opts ...googleapi.CallOption) (*GoogleLongrunningListOperationsResponse, error) {
51879	gensupport.SetOptions(c.urlParams_, opts...)
51880	res, err := c.doRequest("json")
51881	if res != nil && res.StatusCode == http.StatusNotModified {
51882		if res.Body != nil {
51883			res.Body.Close()
51884		}
51885		return nil, &googleapi.Error{
51886			Code:   res.StatusCode,
51887			Header: res.Header,
51888		}
51889	}
51890	if err != nil {
51891		return nil, err
51892	}
51893	defer googleapi.CloseBody(res)
51894	if err := googleapi.CheckResponse(res); err != nil {
51895		return nil, err
51896	}
51897	ret := &GoogleLongrunningListOperationsResponse{
51898		ServerResponse: googleapi.ServerResponse{
51899			Header:         res.Header,
51900			HTTPStatusCode: res.StatusCode,
51901		},
51902	}
51903	target := &ret
51904	if err := gensupport.DecodeResponse(target, res); err != nil {
51905		return nil, err
51906	}
51907	return ret, nil
51908	// {
51909	//   "description": "Lists operations that match the specified filter in the request. If the server doesn't support this method, it returns `UNIMPLEMENTED`. NOTE: the `name` binding allows API services to override the binding to use different resource name schemes, such as `users/*/operations`. To override the binding, API services can add a binding such as `\"/v1/{name=users/*}/operations\"` to their service configuration. For backwards compatibility, the default name includes the operations collection id, however overriding users must ensure the name binding is the parent resource, without the operations collection id.",
51910	//   "flatPath": "v2/projects/{projectsId}/operations",
51911	//   "httpMethod": "GET",
51912	//   "id": "dialogflow.projects.operations.list",
51913	//   "parameterOrder": [
51914	//     "name"
51915	//   ],
51916	//   "parameters": {
51917	//     "filter": {
51918	//       "description": "The standard list filter.",
51919	//       "location": "query",
51920	//       "type": "string"
51921	//     },
51922	//     "name": {
51923	//       "description": "The name of the operation's parent resource.",
51924	//       "location": "path",
51925	//       "pattern": "^projects/[^/]+$",
51926	//       "required": true,
51927	//       "type": "string"
51928	//     },
51929	//     "pageSize": {
51930	//       "description": "The standard list page size.",
51931	//       "format": "int32",
51932	//       "location": "query",
51933	//       "type": "integer"
51934	//     },
51935	//     "pageToken": {
51936	//       "description": "The standard list page token.",
51937	//       "location": "query",
51938	//       "type": "string"
51939	//     }
51940	//   },
51941	//   "path": "v2/{+name}/operations",
51942	//   "response": {
51943	//     "$ref": "GoogleLongrunningListOperationsResponse"
51944	//   },
51945	//   "scopes": [
51946	//     "https://www.googleapis.com/auth/cloud-platform",
51947	//     "https://www.googleapis.com/auth/dialogflow"
51948	//   ]
51949	// }
51950
51951}
51952
51953// Pages invokes f for each page of results.
51954// A non-nil error returned from f will halt the iteration.
51955// The provided context supersedes any context provided to the Context method.
51956func (c *ProjectsOperationsListCall) Pages(ctx context.Context, f func(*GoogleLongrunningListOperationsResponse) error) error {
51957	c.ctx_ = ctx
51958	defer c.PageToken(c.urlParams_.Get("pageToken")) // reset paging to original point
51959	for {
51960		x, err := c.Do()
51961		if err != nil {
51962			return err
51963		}
51964		if err := f(x); err != nil {
51965			return err
51966		}
51967		if x.NextPageToken == "" {
51968			return nil
51969		}
51970		c.PageToken(x.NextPageToken)
51971	}
51972}
51973